@openmrs/esm-stock-management-app 3.3.1 → 3.3.2-pre.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/openmrs-esm-stock-management-app.js +1 -1
- package/dist/openmrs-esm-stock-management-app.js.map +1 -1
- package/dist/routes.json +1 -1
- package/package.json +3 -2
- package/coverage/__mocks__/index.html +0 -161
- package/coverage/__mocks__/index.ts.html +0 -91
- package/coverage/__mocks__/operation-type.mock.ts.html +0 -1681
- package/coverage/__mocks__/react-i18next.js.html +0 -259
- package/coverage/__mocks__/workspace2-props.mock.ts.html +0 -145
- package/coverage/base.css +0 -224
- package/coverage/block-navigation.js +0 -87
- package/coverage/clover.xml +0 -1659
- package/coverage/coverage-final.json +0 -69
- package/coverage/favicon.png +0 -0
- package/coverage/index.html +0 -611
- package/coverage/prettify.css +0 -1
- package/coverage/prettify.js +0 -2
- package/coverage/sort-arrow-sprite.png +0 -0
- package/coverage/sorter.js +0 -210
- package/coverage/src/constants.ts.html +0 -598
- package/coverage/src/core/api/api.ts.html +0 -181
- package/coverage/src/core/api/index.html +0 -116
- package/coverage/src/core/api/types/BatchJob.ts.html +0 -415
- package/coverage/src/core/api/types/index.html +0 -116
- package/coverage/src/core/api/types/stockOperation/StockOperationStatus.ts.html +0 -139
- package/coverage/src/core/api/types/stockOperation/StockOperationType.ts.html +0 -460
- package/coverage/src/core/api/types/stockOperation/index.html +0 -131
- package/coverage/src/core/components/carbon/controlled-number-input.component.tsx.html +0 -226
- package/coverage/src/core/components/carbon/controlled-radio-button-group.component.tsx.html +0 -253
- package/coverage/src/core/components/carbon/controlled-text-input.component.tsx.html +0 -202
- package/coverage/src/core/components/carbon/index.html +0 -146
- package/coverage/src/core/hooks/debounce-hook.ts.html +0 -181
- package/coverage/src/core/hooks/index.html +0 -116
- package/coverage/src/core/utils/datetimeUtils.ts.html +0 -289
- package/coverage/src/core/utils/index.html +0 -131
- package/coverage/src/core/utils/utils.ts.html +0 -382
- package/coverage/src/index.html +0 -131
- package/coverage/src/stock-items/add-bulk-stock-item/add-stock-items-bulk-import-action-button.component.tsx.html +0 -151
- package/coverage/src/stock-items/add-bulk-stock-item/index.html +0 -131
- package/coverage/src/stock-items/add-bulk-stock-item/stock-items-bulk-import.modal.tsx.html +0 -340
- package/coverage/src/stock-items/add-stock-item/add-stock-action-button.component.tsx.html +0 -145
- package/coverage/src/stock-items/add-stock-item/add-stock-item.component.tsx.html +0 -376
- package/coverage/src/stock-items/add-stock-item/batch-information/batch-information.resource.ts.html +0 -262
- package/coverage/src/stock-items/add-stock-item/batch-information/index.html +0 -116
- package/coverage/src/stock-items/add-stock-item/concepts-selector/concepts-selector.component.tsx.html +0 -301
- package/coverage/src/stock-items/add-stock-item/concepts-selector/index.html +0 -116
- package/coverage/src/stock-items/add-stock-item/drug-selector/drug-selector.component.tsx.html +0 -454
- package/coverage/src/stock-items/add-stock-item/drug-selector/index.html +0 -116
- package/coverage/src/stock-items/add-stock-item/index.html +0 -131
- package/coverage/src/stock-items/add-stock-item/stock-item-category-selector/index.html +0 -116
- package/coverage/src/stock-items/add-stock-item/stock-item-category-selector/stock-item-category-selector.component.tsx.html +0 -319
- package/coverage/src/stock-items/add-stock-item/stock-item-details/index.html +0 -131
- package/coverage/src/stock-items/add-stock-item/stock-item-details/stock-item-details.component.tsx.html +0 -862
- package/coverage/src/stock-items/add-stock-item/stock-item-details/stock-item-details.resource.ts.html +0 -142
- package/coverage/src/stock-items/components/filter-stock-items/filter-stock-items.component.tsx.html +0 -166
- package/coverage/src/stock-items/components/filter-stock-items/index.html +0 -116
- package/coverage/src/stock-items/edit-stock-item/edit-stock-item-action-menu.component.tsx.html +0 -169
- package/coverage/src/stock-items/edit-stock-item/index.html +0 -116
- package/coverage/src/stock-items/index.html +0 -161
- package/coverage/src/stock-items/stock-item.utils.tsx.html +0 -103
- package/coverage/src/stock-items/stock-items-table.component.tsx.html +0 -910
- package/coverage/src/stock-items/stock-items.resource.ts.html +0 -1342
- package/coverage/src/stock-items/validationSchema.ts.html +0 -325
- package/coverage/src/stock-locations/add-location.modal.tsx.html +0 -289
- package/coverage/src/stock-locations/index.html +0 -146
- package/coverage/src/stock-locations/location-admin-form.component.tsx.html +0 -574
- package/coverage/src/stock-locations/stock-locations-table.resource.ts.html +0 -370
- package/coverage/src/stock-lookups/index.html +0 -116
- package/coverage/src/stock-lookups/stock-lookups.resource.ts.html +0 -997
- package/coverage/src/stock-operations/index.html +0 -131
- package/coverage/src/stock-operations/stock-operation.utils.tsx.html +0 -184
- package/coverage/src/stock-operations/stock-operations-forms/hooks/index.html +0 -161
- package/coverage/src/stock-operations/stock-operations-forms/hooks/useFilterableStockItems.ts.html +0 -211
- package/coverage/src/stock-operations/stock-operations-forms/hooks/useOperationTypePermisions.ts.html +0 -172
- package/coverage/src/stock-operations/stock-operations-forms/hooks/useSearchUser.ts.html +0 -226
- package/coverage/src/stock-operations/stock-operations-forms/hooks/useStockItemBatchNumbers.ts.html +0 -208
- package/coverage/src/stock-operations/stock-operations-forms/index.html +0 -116
- package/coverage/src/stock-operations/stock-operations-forms/input-components/batch-no-selector.component.tsx.html +0 -439
- package/coverage/src/stock-operations/stock-operations-forms/input-components/index.html +0 -176
- package/coverage/src/stock-operations/stock-operations-forms/input-components/quantity-uom-selector.component.tsx.html +0 -259
- package/coverage/src/stock-operations/stock-operations-forms/input-components/stock-item-search.component.tsx.html +0 -319
- package/coverage/src/stock-operations/stock-operations-forms/input-components/stock-operation-reason-selector.component.tsx.html +0 -286
- package/coverage/src/stock-operations/stock-operations-forms/input-components/users-selector.component.tsx.html +0 -412
- package/coverage/src/stock-operations/stock-operations-forms/steps/base-operation-details-form-step.tsx.html +0 -868
- package/coverage/src/stock-operations/stock-operations-forms/steps/index.html +0 -236
- package/coverage/src/stock-operations/stock-operations-forms/steps/quantity-uom-cell.component.tsx.html +0 -184
- package/coverage/src/stock-operations/stock-operations-forms/steps/received-items.component.tsx.html +0 -433
- package/coverage/src/stock-operations/stock-operations-forms/steps/stock-availability-cell.component.tsx.html +0 -238
- package/coverage/src/stock-operations/stock-operations-forms/steps/stock-operation-item-batch-no-cell.component.tsx.html +0 -205
- package/coverage/src/stock-operations/stock-operations-forms/steps/stock-operation-item-cell.component.tsx.html +0 -232
- package/coverage/src/stock-operations/stock-operations-forms/steps/stock-operation-item-expiry-cell.component.tsx.html +0 -208
- package/coverage/src/stock-operations/stock-operations-forms/steps/stock-operation-items-form-step.component.tsx.html +0 -910
- package/coverage/src/stock-operations/stock-operations-forms/steps/stock-operation-submission-form-step.component.tsx.html +0 -850
- package/coverage/src/stock-operations/stock-operations-forms/stock-item-form/index.html +0 -116
- package/coverage/src/stock-operations/stock-operations-forms/stock-item-form/stock-item-form.workspace.tsx.html +0 -781
- package/coverage/src/stock-operations/stock-operations-forms/stock-operation-form.component.tsx.html +0 -973
- package/coverage/src/stock-operations/stock-operations-forms/stock-operation-stepper/index.html +0 -116
- package/coverage/src/stock-operations/stock-operations-forms/stock-operation-stepper/stock-operation-stepper.component.tsx.html +0 -238
- package/coverage/src/stock-operations/validation-schema.ts.html +0 -847
- package/coverage/src/stock-reports/report-list/index.html +0 -116
- package/coverage/src/stock-reports/report-list/stock-report-status.utils.ts.html +0 -130
- package/coverage/src/stock-sources/add-stock-source-button.component.tsx.html +0 -145
- package/coverage/src/stock-sources/add-stock-sources/add-stock-sources.workspace.tsx.html +0 -550
- package/coverage/src/stock-sources/add-stock-sources/index.html +0 -116
- package/coverage/src/stock-sources/edit-stock-source/edit-stock-source.component.tsx.html +0 -175
- package/coverage/src/stock-sources/edit-stock-source/index.html +0 -116
- package/coverage/src/stock-sources/index.html +0 -146
- package/coverage/src/stock-sources/stock-sources-delete/index.html +0 -116
- package/coverage/src/stock-sources/stock-sources-delete/stock-sources-delete.component.tsx.html +0 -277
- package/coverage/src/stock-sources/stock-sources-filter/index.html +0 -116
- package/coverage/src/stock-sources/stock-sources-filter/stock-sources-filter.component.tsx.html +0 -235
- package/coverage/src/stock-sources/stock-sources-items-table.component.tsx.html +0 -661
- package/coverage/src/stock-sources/stock-sources.resource.ts.html +0 -295
- package/coverage/src/stock-user-role-scopes/delete-stock-user-scope.modal.tsx.html +0 -214
- package/coverage/src/stock-user-role-scopes/index.html +0 -116
- package/coverage/src/utils.ts.html +0 -133
|
@@ -1,289 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
<!doctype html>
|
|
3
|
-
<html lang="en">
|
|
4
|
-
|
|
5
|
-
<head>
|
|
6
|
-
<title>Code coverage report for src/core/utils/datetimeUtils.ts</title>
|
|
7
|
-
<meta charset="utf-8" />
|
|
8
|
-
<link rel="stylesheet" href="../../../prettify.css" />
|
|
9
|
-
<link rel="stylesheet" href="../../../base.css" />
|
|
10
|
-
<link rel="shortcut icon" type="image/x-icon" href="../../../favicon.png" />
|
|
11
|
-
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
12
|
-
<style type='text/css'>
|
|
13
|
-
.coverage-summary .sorter {
|
|
14
|
-
background-image: url(../../../sort-arrow-sprite.png);
|
|
15
|
-
}
|
|
16
|
-
</style>
|
|
17
|
-
</head>
|
|
18
|
-
|
|
19
|
-
<body>
|
|
20
|
-
<div class='wrapper'>
|
|
21
|
-
<div class='pad1'>
|
|
22
|
-
<h1><a href="../../../index.html">All files</a> / <a href="index.html">src/core/utils</a> datetimeUtils.ts</h1>
|
|
23
|
-
<div class='clearfix'>
|
|
24
|
-
|
|
25
|
-
<div class='fl pad1y space-right2'>
|
|
26
|
-
<span class="strong">17.54% </span>
|
|
27
|
-
<span class="quiet">Statements</span>
|
|
28
|
-
<span class='fraction'>10/57</span>
|
|
29
|
-
</div>
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
<div class='fl pad1y space-right2'>
|
|
33
|
-
<span class="strong">4.16% </span>
|
|
34
|
-
<span class="quiet">Branches</span>
|
|
35
|
-
<span class='fraction'>2/48</span>
|
|
36
|
-
</div>
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
<div class='fl pad1y space-right2'>
|
|
40
|
-
<span class="strong">14.28% </span>
|
|
41
|
-
<span class="quiet">Functions</span>
|
|
42
|
-
<span class='fraction'>1/7</span>
|
|
43
|
-
</div>
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
<div class='fl pad1y space-right2'>
|
|
47
|
-
<span class="strong">23.25% </span>
|
|
48
|
-
<span class="quiet">Lines</span>
|
|
49
|
-
<span class='fraction'>10/43</span>
|
|
50
|
-
</div>
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
</div>
|
|
54
|
-
<p class="quiet">
|
|
55
|
-
Press <em>n</em> or <em>j</em> to go to the next uncovered block, <em>b</em>, <em>p</em> or <em>k</em> for the previous block.
|
|
56
|
-
</p>
|
|
57
|
-
<template id="filterTemplate">
|
|
58
|
-
<div class="quiet">
|
|
59
|
-
Filter:
|
|
60
|
-
<input type="search" id="fileSearch">
|
|
61
|
-
</div>
|
|
62
|
-
</template>
|
|
63
|
-
</div>
|
|
64
|
-
<div class='status-line low'></div>
|
|
65
|
-
<pre><table class="coverage">
|
|
66
|
-
<tr><td class="line-count quiet"><a name='L1'></a><a href='#L1'>1</a>
|
|
67
|
-
<a name='L2'></a><a href='#L2'>2</a>
|
|
68
|
-
<a name='L3'></a><a href='#L3'>3</a>
|
|
69
|
-
<a name='L4'></a><a href='#L4'>4</a>
|
|
70
|
-
<a name='L5'></a><a href='#L5'>5</a>
|
|
71
|
-
<a name='L6'></a><a href='#L6'>6</a>
|
|
72
|
-
<a name='L7'></a><a href='#L7'>7</a>
|
|
73
|
-
<a name='L8'></a><a href='#L8'>8</a>
|
|
74
|
-
<a name='L9'></a><a href='#L9'>9</a>
|
|
75
|
-
<a name='L10'></a><a href='#L10'>10</a>
|
|
76
|
-
<a name='L11'></a><a href='#L11'>11</a>
|
|
77
|
-
<a name='L12'></a><a href='#L12'>12</a>
|
|
78
|
-
<a name='L13'></a><a href='#L13'>13</a>
|
|
79
|
-
<a name='L14'></a><a href='#L14'>14</a>
|
|
80
|
-
<a name='L15'></a><a href='#L15'>15</a>
|
|
81
|
-
<a name='L16'></a><a href='#L16'>16</a>
|
|
82
|
-
<a name='L17'></a><a href='#L17'>17</a>
|
|
83
|
-
<a name='L18'></a><a href='#L18'>18</a>
|
|
84
|
-
<a name='L19'></a><a href='#L19'>19</a>
|
|
85
|
-
<a name='L20'></a><a href='#L20'>20</a>
|
|
86
|
-
<a name='L21'></a><a href='#L21'>21</a>
|
|
87
|
-
<a name='L22'></a><a href='#L22'>22</a>
|
|
88
|
-
<a name='L23'></a><a href='#L23'>23</a>
|
|
89
|
-
<a name='L24'></a><a href='#L24'>24</a>
|
|
90
|
-
<a name='L25'></a><a href='#L25'>25</a>
|
|
91
|
-
<a name='L26'></a><a href='#L26'>26</a>
|
|
92
|
-
<a name='L27'></a><a href='#L27'>27</a>
|
|
93
|
-
<a name='L28'></a><a href='#L28'>28</a>
|
|
94
|
-
<a name='L29'></a><a href='#L29'>29</a>
|
|
95
|
-
<a name='L30'></a><a href='#L30'>30</a>
|
|
96
|
-
<a name='L31'></a><a href='#L31'>31</a>
|
|
97
|
-
<a name='L32'></a><a href='#L32'>32</a>
|
|
98
|
-
<a name='L33'></a><a href='#L33'>33</a>
|
|
99
|
-
<a name='L34'></a><a href='#L34'>34</a>
|
|
100
|
-
<a name='L35'></a><a href='#L35'>35</a>
|
|
101
|
-
<a name='L36'></a><a href='#L36'>36</a>
|
|
102
|
-
<a name='L37'></a><a href='#L37'>37</a>
|
|
103
|
-
<a name='L38'></a><a href='#L38'>38</a>
|
|
104
|
-
<a name='L39'></a><a href='#L39'>39</a>
|
|
105
|
-
<a name='L40'></a><a href='#L40'>40</a>
|
|
106
|
-
<a name='L41'></a><a href='#L41'>41</a>
|
|
107
|
-
<a name='L42'></a><a href='#L42'>42</a>
|
|
108
|
-
<a name='L43'></a><a href='#L43'>43</a>
|
|
109
|
-
<a name='L44'></a><a href='#L44'>44</a>
|
|
110
|
-
<a name='L45'></a><a href='#L45'>45</a>
|
|
111
|
-
<a name='L46'></a><a href='#L46'>46</a>
|
|
112
|
-
<a name='L47'></a><a href='#L47'>47</a>
|
|
113
|
-
<a name='L48'></a><a href='#L48'>48</a>
|
|
114
|
-
<a name='L49'></a><a href='#L49'>49</a>
|
|
115
|
-
<a name='L50'></a><a href='#L50'>50</a>
|
|
116
|
-
<a name='L51'></a><a href='#L51'>51</a>
|
|
117
|
-
<a name='L52'></a><a href='#L52'>52</a>
|
|
118
|
-
<a name='L53'></a><a href='#L53'>53</a>
|
|
119
|
-
<a name='L54'></a><a href='#L54'>54</a>
|
|
120
|
-
<a name='L55'></a><a href='#L55'>55</a>
|
|
121
|
-
<a name='L56'></a><a href='#L56'>56</a>
|
|
122
|
-
<a name='L57'></a><a href='#L57'>57</a>
|
|
123
|
-
<a name='L58'></a><a href='#L58'>58</a>
|
|
124
|
-
<a name='L59'></a><a href='#L59'>59</a>
|
|
125
|
-
<a name='L60'></a><a href='#L60'>60</a>
|
|
126
|
-
<a name='L61'></a><a href='#L61'>61</a>
|
|
127
|
-
<a name='L62'></a><a href='#L62'>62</a>
|
|
128
|
-
<a name='L63'></a><a href='#L63'>63</a>
|
|
129
|
-
<a name='L64'></a><a href='#L64'>64</a>
|
|
130
|
-
<a name='L65'></a><a href='#L65'>65</a>
|
|
131
|
-
<a name='L66'></a><a href='#L66'>66</a>
|
|
132
|
-
<a name='L67'></a><a href='#L67'>67</a>
|
|
133
|
-
<a name='L68'></a><a href='#L68'>68</a>
|
|
134
|
-
<a name='L69'></a><a href='#L69'>69</a></td><td class="line-coverage quiet"><span class="cline-any cline-neutral"> </span>
|
|
135
|
-
<span class="cline-any cline-neutral"> </span>
|
|
136
|
-
<span class="cline-any cline-yes">5x</span>
|
|
137
|
-
<span class="cline-any cline-yes">96x</span>
|
|
138
|
-
<span class="cline-any cline-neutral"> </span>
|
|
139
|
-
<span class="cline-any cline-neutral"> </span>
|
|
140
|
-
<span class="cline-any cline-yes">5x</span>
|
|
141
|
-
<span class="cline-any cline-no"> </span>
|
|
142
|
-
<span class="cline-any cline-neutral"> </span>
|
|
143
|
-
<span class="cline-any cline-neutral"> </span>
|
|
144
|
-
<span class="cline-any cline-yes">5x</span>
|
|
145
|
-
<span class="cline-any cline-no"> </span>
|
|
146
|
-
<span class="cline-any cline-neutral"> </span>
|
|
147
|
-
<span class="cline-any cline-neutral"> </span>
|
|
148
|
-
<span class="cline-any cline-yes">5x</span>
|
|
149
|
-
<span class="cline-any cline-yes">5x</span>
|
|
150
|
-
<span class="cline-any cline-no"> </span>
|
|
151
|
-
<span class="cline-any cline-neutral"> </span>
|
|
152
|
-
<span class="cline-any cline-neutral"> </span>
|
|
153
|
-
<span class="cline-any cline-yes">5x</span>
|
|
154
|
-
<span class="cline-any cline-no"> </span>
|
|
155
|
-
<span class="cline-any cline-no"> </span>
|
|
156
|
-
<span class="cline-any cline-neutral"> </span>
|
|
157
|
-
<span class="cline-any cline-neutral"> </span>
|
|
158
|
-
<span class="cline-any cline-yes">5x</span>
|
|
159
|
-
<span class="cline-any cline-neutral"> </span>
|
|
160
|
-
<span class="cline-any cline-yes">5x</span>
|
|
161
|
-
<span class="cline-any cline-no"> </span>
|
|
162
|
-
<span class="cline-any cline-no"> </span>
|
|
163
|
-
<span class="cline-any cline-no"> </span>
|
|
164
|
-
<span class="cline-any cline-neutral"> </span>
|
|
165
|
-
<span class="cline-any cline-neutral"> </span>
|
|
166
|
-
<span class="cline-any cline-no"> </span>
|
|
167
|
-
<span class="cline-any cline-neutral"> </span>
|
|
168
|
-
<span class="cline-any cline-no"> </span>
|
|
169
|
-
<span class="cline-any cline-neutral"> </span>
|
|
170
|
-
<span class="cline-any cline-neutral"> </span>
|
|
171
|
-
<span class="cline-any cline-yes">5x</span>
|
|
172
|
-
<span class="cline-any cline-no"> </span>
|
|
173
|
-
<span class="cline-any cline-no"> </span>
|
|
174
|
-
<span class="cline-any cline-no"> </span>
|
|
175
|
-
<span class="cline-any cline-no"> </span>
|
|
176
|
-
<span class="cline-any cline-no"> </span>
|
|
177
|
-
<span class="cline-any cline-no"> </span>
|
|
178
|
-
<span class="cline-any cline-no"> </span>
|
|
179
|
-
<span class="cline-any cline-no"> </span>
|
|
180
|
-
<span class="cline-any cline-no"> </span>
|
|
181
|
-
<span class="cline-any cline-no"> </span>
|
|
182
|
-
<span class="cline-any cline-no"> </span>
|
|
183
|
-
<span class="cline-any cline-no"> </span>
|
|
184
|
-
<span class="cline-any cline-no"> </span>
|
|
185
|
-
<span class="cline-any cline-no"> </span>
|
|
186
|
-
<span class="cline-any cline-no"> </span>
|
|
187
|
-
<span class="cline-any cline-no"> </span>
|
|
188
|
-
<span class="cline-any cline-no"> </span>
|
|
189
|
-
<span class="cline-any cline-neutral"> </span>
|
|
190
|
-
<span class="cline-any cline-no"> </span>
|
|
191
|
-
<span class="cline-any cline-no"> </span>
|
|
192
|
-
<span class="cline-any cline-no"> </span>
|
|
193
|
-
<span class="cline-any cline-neutral"> </span>
|
|
194
|
-
<span class="cline-any cline-no"> </span>
|
|
195
|
-
<span class="cline-any cline-no"> </span>
|
|
196
|
-
<span class="cline-any cline-neutral"> </span>
|
|
197
|
-
<span class="cline-any cline-neutral"> </span>
|
|
198
|
-
<span class="cline-any cline-neutral"> </span>
|
|
199
|
-
<span class="cline-any cline-neutral"> </span>
|
|
200
|
-
<span class="cline-any cline-no"> </span>
|
|
201
|
-
<span class="cline-any cline-neutral"> </span>
|
|
202
|
-
<span class="cline-any cline-neutral"> </span></td><td class="text"><pre class="prettyprint lang-js">import dayjs from 'dayjs';
|
|
203
|
-
|
|
204
|
-
export const formatDisplayDate = (date: Date | null | undefined, format?: string) => {
|
|
205
|
-
return date ? dayjs(date).format(format ?? <span class="branch-1 cbranch-no" title="branch not covered" >'DD-MMM-YYYY') </span>: <span class="branch-1 cbranch-no" title="branch not covered" >'';</span>
|
|
206
|
-
};
|
|
207
|
-
|
|
208
|
-
export const <span class="fstat-no" title="function not covered" >formatBatchExpiryDate = (d</span>ate: Date | null | undefined, format?: string) => {
|
|
209
|
-
<span class="cstat-no" title="statement not covered" > return date ? dayjs(date).format(format ?? 'YYYY-MMM') : '';</span>
|
|
210
|
-
};
|
|
211
|
-
|
|
212
|
-
export const <span class="fstat-no" title="function not covered" >formatDisplayDateTime = (d</span>ate: Date | null | undefined, format?: string) => {
|
|
213
|
-
<span class="cstat-no" title="statement not covered" > return date ? dayjs(date).format(format ?? 'DD-MMM-YYYY HH:mm') : '';</span>
|
|
214
|
-
};
|
|
215
|
-
|
|
216
|
-
export const DATE_PICKER_FORMAT = 'DD/MM/YYYY';
|
|
217
|
-
export const <span class="fstat-no" title="function not covered" >formatForDatePicker = (d</span>ate: Date | null | undefined) => {
|
|
218
|
-
<span class="cstat-no" title="statement not covered" > return formatDisplayDate(date, DATE_PICKER_FORMAT);</span>
|
|
219
|
-
};
|
|
220
|
-
|
|
221
|
-
export const <span class="fstat-no" title="function not covered" >today = () => {</span>
|
|
222
|
-
const date = <span class="cstat-no" title="statement not covered" >new Date();</span>
|
|
223
|
-
<span class="cstat-no" title="statement not covered" > return new Date(date.getFullYear(), date.getMonth(), date.getDate());</span>
|
|
224
|
-
};
|
|
225
|
-
|
|
226
|
-
export const DATE_PICKER_CONTROL_FORMAT = 'd/m/Y';
|
|
227
|
-
|
|
228
|
-
export const <span class="fstat-no" title="function not covered" >isDateAfterToday = (d</span>ate: Date | null | undefined) => {
|
|
229
|
-
<span class="cstat-no" title="statement not covered" > if (date) {</span>
|
|
230
|
-
<span class="cstat-no" title="statement not covered" > if (typeof date === 'string' || date instanceof String) {</span>
|
|
231
|
-
<span class="cstat-no" title="statement not covered" > date = new Date(date);</span>
|
|
232
|
-
}
|
|
233
|
-
|
|
234
|
-
<span class="cstat-no" title="statement not covered" > return date.getTime() > today().getTime();</span>
|
|
235
|
-
}
|
|
236
|
-
<span class="cstat-no" title="statement not covered" > return false;</span>
|
|
237
|
-
};
|
|
238
|
-
|
|
239
|
-
export const <span class="fstat-no" title="function not covered" >ParseDate = (v</span>alue: string | null | undefined) => {
|
|
240
|
-
let date = <span class="cstat-no" title="statement not covered" >null;</span>
|
|
241
|
-
<span class="cstat-no" title="statement not covered" > try {</span>
|
|
242
|
-
<span class="cstat-no" title="statement not covered" > if (!value) <span class="cstat-no" title="statement not covered" >return date;</span></span>
|
|
243
|
-
<span class="cstat-no" title="statement not covered" > value = value?.toLowerCase();</span>
|
|
244
|
-
<span class="cstat-no" title="statement not covered" > if (value.includes('jan')) <span class="cstat-no" title="statement not covered" >value = value.replace('jan', '01');</span></span>
|
|
245
|
-
else <span class="cstat-no" title="statement not covered" >if (value.includes('feb')) <span class="cstat-no" title="statement not covered" >value = value.replace('feb', '02');</span></span>
|
|
246
|
-
else <span class="cstat-no" title="statement not covered" >if (value.includes('mar')) <span class="cstat-no" title="statement not covered" >value = value.replace('mar', '03');</span></span>
|
|
247
|
-
else <span class="cstat-no" title="statement not covered" >if (value.includes('apr')) <span class="cstat-no" title="statement not covered" >value = value.replace('apr', '04');</span></span>
|
|
248
|
-
else <span class="cstat-no" title="statement not covered" >if (value.includes('may')) <span class="cstat-no" title="statement not covered" >value = value.replace('may', '05');</span></span>
|
|
249
|
-
else <span class="cstat-no" title="statement not covered" >if (value.includes('jun')) <span class="cstat-no" title="statement not covered" >value = value.replace('jun', '06');</span></span>
|
|
250
|
-
else <span class="cstat-no" title="statement not covered" >if (value.includes('jul')) <span class="cstat-no" title="statement not covered" >value = value.replace('jul', '07');</span></span>
|
|
251
|
-
else <span class="cstat-no" title="statement not covered" >if (value.includes('aug')) <span class="cstat-no" title="statement not covered" >value = value.replace('aug', '08');</span></span>
|
|
252
|
-
else <span class="cstat-no" title="statement not covered" >if (value.includes('sep')) <span class="cstat-no" title="statement not covered" >value = value.replace('sep', '09');</span></span>
|
|
253
|
-
else <span class="cstat-no" title="statement not covered" >if (value.includes('oct')) <span class="cstat-no" title="statement not covered" >value = value.replace('oct', '10');</span></span>
|
|
254
|
-
else <span class="cstat-no" title="statement not covered" >if (value.includes('nov')) <span class="cstat-no" title="statement not covered" >value = value.replace('nov', '11');</span></span>
|
|
255
|
-
else <span class="cstat-no" title="statement not covered" >if (value.includes('dec')) <span class="cstat-no" title="statement not covered" >value = value.replace('dec', '12');</span></span>
|
|
256
|
-
<span class="cstat-no" title="statement not covered" > value = value.replace(/-/g, '/');</span>
|
|
257
|
-
let strMonth;
|
|
258
|
-
<span class="cstat-no" title="statement not covered" > if (value!.substring(3, 5).indexOf('0') === 0) <span class="cstat-no" title="statement not covered" >strMonth = value!.substring(4, 5);</span></span>
|
|
259
|
-
else <span class="cstat-no" title="statement not covered" >strMonth = value!.substring(3, 5);</span>
|
|
260
|
-
const month = <span class="cstat-no" title="statement not covered" >parseInt(strMonth) - 1;</span>
|
|
261
|
-
|
|
262
|
-
<span class="cstat-no" title="statement not covered" > if (value) {</span>
|
|
263
|
-
<span class="cstat-no" title="statement not covered" > date = new Date(parseInt(value!.substring(6, 10)), month, parseInt(value!.substring(0, 2)), 0, 0);</span>
|
|
264
|
-
}
|
|
265
|
-
} catch (e) {
|
|
266
|
-
// Err
|
|
267
|
-
}
|
|
268
|
-
<span class="cstat-no" title="statement not covered" > return date;</span>
|
|
269
|
-
};
|
|
270
|
-
</pre></td></tr></table></pre>
|
|
271
|
-
|
|
272
|
-
<div class='push'></div><!-- for sticky footer -->
|
|
273
|
-
</div><!-- /wrapper -->
|
|
274
|
-
<div class='footer quiet pad2 space-top1 center small'>
|
|
275
|
-
Code coverage generated by
|
|
276
|
-
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
277
|
-
at 2026-10-19T11:46:33.626Z
|
|
278
|
-
</div>
|
|
279
|
-
<script src="../../../prettify.js"></script>
|
|
280
|
-
<script>
|
|
281
|
-
window.onload = function () {
|
|
282
|
-
prettyPrint();
|
|
283
|
-
};
|
|
284
|
-
</script>
|
|
285
|
-
<script src="../../../sorter.js"></script>
|
|
286
|
-
<script src="../../../block-navigation.js"></script>
|
|
287
|
-
</body>
|
|
288
|
-
</html>
|
|
289
|
-
|
|
@@ -1,131 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
<!doctype html>
|
|
3
|
-
<html lang="en">
|
|
4
|
-
|
|
5
|
-
<head>
|
|
6
|
-
<title>Code coverage report for src/core/utils</title>
|
|
7
|
-
<meta charset="utf-8" />
|
|
8
|
-
<link rel="stylesheet" href="../../../prettify.css" />
|
|
9
|
-
<link rel="stylesheet" href="../../../base.css" />
|
|
10
|
-
<link rel="shortcut icon" type="image/x-icon" href="../../../favicon.png" />
|
|
11
|
-
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
12
|
-
<style type='text/css'>
|
|
13
|
-
.coverage-summary .sorter {
|
|
14
|
-
background-image: url(../../../sort-arrow-sprite.png);
|
|
15
|
-
}
|
|
16
|
-
</style>
|
|
17
|
-
</head>
|
|
18
|
-
|
|
19
|
-
<body>
|
|
20
|
-
<div class='wrapper'>
|
|
21
|
-
<div class='pad1'>
|
|
22
|
-
<h1><a href="../../../index.html">All files</a> src/core/utils</h1>
|
|
23
|
-
<div class='clearfix'>
|
|
24
|
-
|
|
25
|
-
<div class='fl pad1y space-right2'>
|
|
26
|
-
<span class="strong">16.66% </span>
|
|
27
|
-
<span class="quiet">Statements</span>
|
|
28
|
-
<span class='fraction'>13/78</span>
|
|
29
|
-
</div>
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
<div class='fl pad1y space-right2'>
|
|
33
|
-
<span class="strong">3.22% </span>
|
|
34
|
-
<span class="quiet">Branches</span>
|
|
35
|
-
<span class='fraction'>2/62</span>
|
|
36
|
-
</div>
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
<div class='fl pad1y space-right2'>
|
|
40
|
-
<span class="strong">7.69% </span>
|
|
41
|
-
<span class="quiet">Functions</span>
|
|
42
|
-
<span class='fraction'>1/13</span>
|
|
43
|
-
</div>
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
<div class='fl pad1y space-right2'>
|
|
47
|
-
<span class="strong">20.96% </span>
|
|
48
|
-
<span class="quiet">Lines</span>
|
|
49
|
-
<span class='fraction'>13/62</span>
|
|
50
|
-
</div>
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
</div>
|
|
54
|
-
<p class="quiet">
|
|
55
|
-
Press <em>n</em> or <em>j</em> to go to the next uncovered block, <em>b</em>, <em>p</em> or <em>k</em> for the previous block.
|
|
56
|
-
</p>
|
|
57
|
-
<template id="filterTemplate">
|
|
58
|
-
<div class="quiet">
|
|
59
|
-
Filter:
|
|
60
|
-
<input type="search" id="fileSearch">
|
|
61
|
-
</div>
|
|
62
|
-
</template>
|
|
63
|
-
</div>
|
|
64
|
-
<div class='status-line low'></div>
|
|
65
|
-
<div class="pad1">
|
|
66
|
-
<table class="coverage-summary">
|
|
67
|
-
<thead>
|
|
68
|
-
<tr>
|
|
69
|
-
<th data-col="file" data-fmt="html" data-html="true" class="file">File</th>
|
|
70
|
-
<th data-col="pic" data-type="number" data-fmt="html" data-html="true" class="pic"></th>
|
|
71
|
-
<th data-col="statements" data-type="number" data-fmt="pct" class="pct">Statements</th>
|
|
72
|
-
<th data-col="statements_raw" data-type="number" data-fmt="html" class="abs"></th>
|
|
73
|
-
<th data-col="branches" data-type="number" data-fmt="pct" class="pct">Branches</th>
|
|
74
|
-
<th data-col="branches_raw" data-type="number" data-fmt="html" class="abs"></th>
|
|
75
|
-
<th data-col="functions" data-type="number" data-fmt="pct" class="pct">Functions</th>
|
|
76
|
-
<th data-col="functions_raw" data-type="number" data-fmt="html" class="abs"></th>
|
|
77
|
-
<th data-col="lines" data-type="number" data-fmt="pct" class="pct">Lines</th>
|
|
78
|
-
<th data-col="lines_raw" data-type="number" data-fmt="html" class="abs"></th>
|
|
79
|
-
</tr>
|
|
80
|
-
</thead>
|
|
81
|
-
<tbody><tr>
|
|
82
|
-
<td class="file low" data-value="datetimeUtils.ts"><a href="datetimeUtils.ts.html">datetimeUtils.ts</a></td>
|
|
83
|
-
<td data-value="17.54" class="pic low">
|
|
84
|
-
<div class="chart"><div class="cover-fill" style="width: 17%"></div><div class="cover-empty" style="width: 83%"></div></div>
|
|
85
|
-
</td>
|
|
86
|
-
<td data-value="17.54" class="pct low">17.54%</td>
|
|
87
|
-
<td data-value="57" class="abs low">10/57</td>
|
|
88
|
-
<td data-value="4.16" class="pct low">4.16%</td>
|
|
89
|
-
<td data-value="48" class="abs low">2/48</td>
|
|
90
|
-
<td data-value="14.28" class="pct low">14.28%</td>
|
|
91
|
-
<td data-value="7" class="abs low">1/7</td>
|
|
92
|
-
<td data-value="23.25" class="pct low">23.25%</td>
|
|
93
|
-
<td data-value="43" class="abs low">10/43</td>
|
|
94
|
-
</tr>
|
|
95
|
-
|
|
96
|
-
<tr>
|
|
97
|
-
<td class="file low" data-value="utils.ts"><a href="utils.ts.html">utils.ts</a></td>
|
|
98
|
-
<td data-value="14.28" class="pic low">
|
|
99
|
-
<div class="chart"><div class="cover-fill" style="width: 14%"></div><div class="cover-empty" style="width: 86%"></div></div>
|
|
100
|
-
</td>
|
|
101
|
-
<td data-value="14.28" class="pct low">14.28%</td>
|
|
102
|
-
<td data-value="21" class="abs low">3/21</td>
|
|
103
|
-
<td data-value="0" class="pct low">0%</td>
|
|
104
|
-
<td data-value="14" class="abs low">0/14</td>
|
|
105
|
-
<td data-value="0" class="pct low">0%</td>
|
|
106
|
-
<td data-value="6" class="abs low">0/6</td>
|
|
107
|
-
<td data-value="15.78" class="pct low">15.78%</td>
|
|
108
|
-
<td data-value="19" class="abs low">3/19</td>
|
|
109
|
-
</tr>
|
|
110
|
-
|
|
111
|
-
</tbody>
|
|
112
|
-
</table>
|
|
113
|
-
</div>
|
|
114
|
-
<div class='push'></div><!-- for sticky footer -->
|
|
115
|
-
</div><!-- /wrapper -->
|
|
116
|
-
<div class='footer quiet pad2 space-top1 center small'>
|
|
117
|
-
Code coverage generated by
|
|
118
|
-
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
119
|
-
at 2026-10-19T11:46:33.626Z
|
|
120
|
-
</div>
|
|
121
|
-
<script src="../../../prettify.js"></script>
|
|
122
|
-
<script>
|
|
123
|
-
window.onload = function () {
|
|
124
|
-
prettyPrint();
|
|
125
|
-
};
|
|
126
|
-
</script>
|
|
127
|
-
<script src="../../../sorter.js"></script>
|
|
128
|
-
<script src="../../../block-navigation.js"></script>
|
|
129
|
-
</body>
|
|
130
|
-
</html>
|
|
131
|
-
|