@outliant/sunrise-utils 1.2.3 → 1.2.5
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/CHANGELOG.md
CHANGED
|
@@ -4,8 +4,22 @@ All notable changes to this project will be documented in this file. Dates are d
|
|
|
4
4
|
|
|
5
5
|
Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
|
|
6
6
|
|
|
7
|
+
#### [1.2.5](https://github.com/outliant/sunrise-utils/compare/1.2.4...1.2.5)
|
|
8
|
+
|
|
9
|
+
- chore: added task archived status [`602a04a`](https://github.com/outliant/sunrise-utils/commit/602a04a95d8592c85237a74607e3acea130ec278)
|
|
10
|
+
|
|
11
|
+
#### [1.2.4](https://github.com/outliant/sunrise-utils/compare/1.2.3...1.2.4)
|
|
12
|
+
|
|
13
|
+
> 8 October 2024
|
|
14
|
+
|
|
15
|
+
- chore(release): 1.2.4 [`d681a97`](https://github.com/outliant/sunrise-utils/commit/d681a970cf3363e1eec51a637c91a76f27e5bbca)
|
|
16
|
+
- chore: Rough DC Inspection banner [`6bbc072`](https://github.com/outliant/sunrise-utils/commit/6bbc07291cec53eb6061f022248f2924f86f02b9)
|
|
17
|
+
|
|
7
18
|
#### [1.2.3](https://github.com/outliant/sunrise-utils/compare/1.2.2...1.2.3)
|
|
8
19
|
|
|
20
|
+
> 3 October 2024
|
|
21
|
+
|
|
22
|
+
- chore(release): 1.2.3 [`ee46b3f`](https://github.com/outliant/sunrise-utils/commit/ee46b3f994c3defd7dd20dcd71a999b26b0c0837)
|
|
9
23
|
- chore: updated pause column department validator #86b29g6de [`5fb0258`](https://github.com/outliant/sunrise-utils/commit/5fb025812f3a92c34d4dc733e9454a466f9148a1)
|
|
10
24
|
|
|
11
25
|
#### [1.2.2](https://github.com/outliant/sunrise-utils/compare/1.2.1...1.2.2)
|
package/constants.js
CHANGED
|
@@ -39,6 +39,10 @@ module.exports.taskStatusOptions = [
|
|
|
39
39
|
validator && (validator.isCommercial() || validator.isService()),
|
|
40
40
|
label: 'Paused',
|
|
41
41
|
value: 'paused'
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
label: 'Archived',
|
|
45
|
+
value: 'archived'
|
|
42
46
|
}
|
|
43
47
|
];
|
|
44
48
|
|
|
@@ -110,7 +114,7 @@ module.exports.defaultCustomColumns = [
|
|
|
110
114
|
type: 'status',
|
|
111
115
|
field_type: 'select',
|
|
112
116
|
options: [],
|
|
113
|
-
select_fields: ['is_complete', 'is_ready']
|
|
117
|
+
select_fields: ['is_complete', 'is_ready', 'deleted']
|
|
114
118
|
},
|
|
115
119
|
{
|
|
116
120
|
name: 'Region',
|
|
@@ -14,10 +14,7 @@ module.exports = (filter) => {
|
|
|
14
14
|
case 'is_any_of':
|
|
15
15
|
return module.exports.isAnyOf(filter);
|
|
16
16
|
case 'is_none_of':
|
|
17
|
-
return isNoneOf(
|
|
18
|
-
filter,
|
|
19
|
-
module.exports.isEqual
|
|
20
|
-
);
|
|
17
|
+
return isNoneOf(filter, module.exports.isEqual);
|
|
21
18
|
default:
|
|
22
19
|
return null;
|
|
23
20
|
}
|
|
@@ -41,6 +38,11 @@ module.exports.isEmpty = () => {
|
|
|
41
38
|
exists: {
|
|
42
39
|
field: 'on_hold'
|
|
43
40
|
}
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
exists: {
|
|
44
|
+
field: 'deleted'
|
|
45
|
+
}
|
|
44
46
|
}
|
|
45
47
|
]
|
|
46
48
|
}
|
|
@@ -173,6 +175,18 @@ module.exports.isEqual = (filter) => {
|
|
|
173
175
|
]
|
|
174
176
|
}
|
|
175
177
|
};
|
|
178
|
+
case 'archived':
|
|
179
|
+
return {
|
|
180
|
+
bool: {
|
|
181
|
+
must: [
|
|
182
|
+
{
|
|
183
|
+
term: {
|
|
184
|
+
deleted: true
|
|
185
|
+
}
|
|
186
|
+
}
|
|
187
|
+
]
|
|
188
|
+
}
|
|
189
|
+
};
|
|
176
190
|
default:
|
|
177
191
|
return null;
|
|
178
192
|
}
|
|
@@ -214,4 +228,4 @@ module.exports.isNotEqual = (filter) => {
|
|
|
214
228
|
}
|
|
215
229
|
|
|
216
230
|
return null;
|
|
217
|
-
};
|
|
231
|
+
};
|
package/package.json
CHANGED
|
@@ -96,9 +96,7 @@ describe('taskFilter/statusFilter', function () {
|
|
|
96
96
|
},
|
|
97
97
|
output: {
|
|
98
98
|
bool: {
|
|
99
|
-
must: [
|
|
100
|
-
{ term: { is_paused: true } }
|
|
101
|
-
]
|
|
99
|
+
must: [{ term: { is_paused: true } }]
|
|
102
100
|
}
|
|
103
101
|
}
|
|
104
102
|
},
|
|
@@ -128,6 +126,21 @@ describe('taskFilter/statusFilter', function () {
|
|
|
128
126
|
}
|
|
129
127
|
}
|
|
130
128
|
},
|
|
129
|
+
{
|
|
130
|
+
input: {
|
|
131
|
+
condition: 'is_equal',
|
|
132
|
+
field_id: '',
|
|
133
|
+
type: 'status',
|
|
134
|
+
field_type: 'select',
|
|
135
|
+
value: 'archived',
|
|
136
|
+
second_value: ''
|
|
137
|
+
},
|
|
138
|
+
output: {
|
|
139
|
+
bool: {
|
|
140
|
+
must: [{ term: { deleted: true } }]
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
},
|
|
131
144
|
{
|
|
132
145
|
input: {
|
|
133
146
|
condition: 'is_empty',
|
|
@@ -142,7 +155,8 @@ describe('taskFilter/statusFilter', function () {
|
|
|
142
155
|
must_not: [
|
|
143
156
|
{ exists: { field: 'is_complete' } },
|
|
144
157
|
{ exists: { field: 'is_ready' } },
|
|
145
|
-
{ exists: { field: 'on_hold' } }
|
|
158
|
+
{ exists: { field: 'on_hold' } },
|
|
159
|
+
{ exists: { field: 'deleted' } }
|
|
146
160
|
]
|
|
147
161
|
}
|
|
148
162
|
}
|
|
@@ -163,7 +177,8 @@ describe('taskFilter/statusFilter', function () {
|
|
|
163
177
|
must_not: [
|
|
164
178
|
{ exists: { field: 'is_complete' } },
|
|
165
179
|
{ exists: { field: 'is_ready' } },
|
|
166
|
-
{ exists: { field: 'on_hold' } }
|
|
180
|
+
{ exists: { field: 'on_hold' } },
|
|
181
|
+
{ exists: { field: 'deleted' } }
|
|
167
182
|
]
|
|
168
183
|
}
|
|
169
184
|
}
|
|
@@ -281,9 +296,7 @@ describe('taskFilter/statusFilter', function () {
|
|
|
281
296
|
},
|
|
282
297
|
{
|
|
283
298
|
bool: {
|
|
284
|
-
must: [
|
|
285
|
-
{ term: { on_hold: true } }
|
|
286
|
-
]
|
|
299
|
+
must: [{ term: { on_hold: true } }]
|
|
287
300
|
}
|
|
288
301
|
}
|
|
289
302
|
]
|
|
@@ -312,9 +325,7 @@ describe('taskFilter/statusFilter', function () {
|
|
|
312
325
|
},
|
|
313
326
|
{
|
|
314
327
|
bool: {
|
|
315
|
-
must: [
|
|
316
|
-
{ term: { on_hold: true } }
|
|
317
|
-
]
|
|
328
|
+
must: [{ term: { on_hold: true } }]
|
|
318
329
|
}
|
|
319
330
|
}
|
|
320
331
|
]
|