@cyberismo/assets 0.0.15 → 0.0.17
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/index.js +25 -15
- package/dist/schemas.d.ts +35 -0
- package/package.json +1 -1
- package/src/calculations/common/base.lp +3 -0
- package/src/calculations/queries/tree.lp +13 -1
- package/src/hub/moduleList.json +2 -1
- package/src/schema/cardTreeDirectorySchema.json +29 -0
- package/src/schema/cardsConfigSchema.json +4 -0
- package/src/schema/hubSchema.json +6 -1
- package/src/schema/version.json +3 -0
- package/src/schemas.ts +3 -0
package/dist/schemas.d.ts
CHANGED
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
details. You should have received a copy of the GNU Affero General Public
|
|
11
11
|
License along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
12
12
|
*/
|
|
13
|
+
export declare const SCHEMA_VERSION: number;
|
|
13
14
|
export declare const schemas: ({
|
|
14
15
|
$id: string;
|
|
15
16
|
additionalProperties: boolean;
|
|
@@ -169,6 +170,11 @@ export declare const schemas: ({
|
|
|
169
170
|
type: string;
|
|
170
171
|
minLength: number;
|
|
171
172
|
};
|
|
173
|
+
version: {
|
|
174
|
+
description: string;
|
|
175
|
+
minimum: number;
|
|
176
|
+
type: string;
|
|
177
|
+
};
|
|
172
178
|
modules: {
|
|
173
179
|
description: string;
|
|
174
180
|
type: string;
|
|
@@ -40385,6 +40391,32 @@ export declare const parentSchema: {
|
|
|
40385
40391
|
};
|
|
40386
40392
|
})[];
|
|
40387
40393
|
};
|
|
40394
|
+
migrationsSchema: {
|
|
40395
|
+
type: string;
|
|
40396
|
+
$comment: string;
|
|
40397
|
+
properties: {
|
|
40398
|
+
directories: {
|
|
40399
|
+
additionalProperties: boolean;
|
|
40400
|
+
patternProperties: {
|
|
40401
|
+
"([0-9]+|current)": {
|
|
40402
|
+
type: string;
|
|
40403
|
+
properties: {
|
|
40404
|
+
files: {
|
|
40405
|
+
additionalProperties: boolean;
|
|
40406
|
+
type: string;
|
|
40407
|
+
properties: {
|
|
40408
|
+
"migrationLog.jsonl": {
|
|
40409
|
+
type: string;
|
|
40410
|
+
};
|
|
40411
|
+
};
|
|
40412
|
+
};
|
|
40413
|
+
};
|
|
40414
|
+
};
|
|
40415
|
+
};
|
|
40416
|
+
type: string;
|
|
40417
|
+
};
|
|
40418
|
+
};
|
|
40419
|
+
};
|
|
40388
40420
|
reportResourceSchema: {
|
|
40389
40421
|
type: string;
|
|
40390
40422
|
properties: {
|
|
@@ -40612,6 +40644,9 @@ export declare const parentSchema: {
|
|
|
40612
40644
|
type: string;
|
|
40613
40645
|
additionalProperties: boolean;
|
|
40614
40646
|
properties: {
|
|
40647
|
+
migrations: {
|
|
40648
|
+
$ref: string;
|
|
40649
|
+
};
|
|
40615
40650
|
calculations: {
|
|
40616
40651
|
$ref: string;
|
|
40617
40652
|
};
|
package/package.json
CHANGED
|
@@ -19,6 +19,9 @@ templateCard(C) :- card(C), field(C, "container", "template").
|
|
|
19
19
|
dataType(Card, "lastUpdated", "dateTime") :-
|
|
20
20
|
field(Card, "lastUpdated", _).
|
|
21
21
|
|
|
22
|
+
dataType(Connector, "lastSynchronised", "dateTime") :-
|
|
23
|
+
field(Connector, "lastSynchronised", _).
|
|
24
|
+
|
|
22
25
|
% add workflow state category as a calculated field for Cards
|
|
23
26
|
field(Card, "workflowStateCategory", Category) :-
|
|
24
27
|
card(Card),
|
|
@@ -1,6 +1,18 @@
|
|
|
1
1
|
select("title";"statusIndicator";"progress";"rank";"cardType").
|
|
2
|
-
|
|
2
|
+
|
|
3
|
+
{{#if cardKey}}
|
|
4
|
+
result({{cardKey}}).
|
|
5
|
+
{{#if recursive}}
|
|
6
|
+
% child below
|
|
7
|
+
childResult({{cardKey}}, Card, "children") :- parent(Card, {{cardKey}}), not hiddenInTreeView(Card).
|
|
8
|
+
childResult(Parent, Card, "children") :- childResult(_, Parent, "children"), parent(Card, Parent), not hiddenInTreeView(Card).
|
|
9
|
+
{{/if}}
|
|
10
|
+
|
|
11
|
+
{{else}}
|
|
12
|
+
result(Card) :- projectCard(Card), not parent(Card, _), not hiddenInTreeView(Card).
|
|
3
13
|
childResult(Parent, Card, "children") :- card(Card), parent(Card, Parent), not hiddenInTreeView(Card).
|
|
14
|
+
{{/if}}
|
|
15
|
+
|
|
4
16
|
order(Level, "children", 1, "rank", "ASC") :-
|
|
5
17
|
level(Level).
|
|
6
18
|
|
package/src/hub/moduleList.json
CHANGED
|
@@ -302,6 +302,32 @@
|
|
|
302
302
|
}
|
|
303
303
|
]
|
|
304
304
|
},
|
|
305
|
+
"migrationsSchema": {
|
|
306
|
+
"type": "object",
|
|
307
|
+
"$comment": "migrations folder contain one folder for each migration",
|
|
308
|
+
"properties": {
|
|
309
|
+
"directories": {
|
|
310
|
+
"additionalProperties": false,
|
|
311
|
+
"patternProperties": {
|
|
312
|
+
"([0-9]+|current)": {
|
|
313
|
+
"type": "object",
|
|
314
|
+
"properties": {
|
|
315
|
+
"files": {
|
|
316
|
+
"additionalProperties": false,
|
|
317
|
+
"type": "object",
|
|
318
|
+
"properties": {
|
|
319
|
+
"migrationLog.jsonl": {
|
|
320
|
+
"type": "object"
|
|
321
|
+
}
|
|
322
|
+
}
|
|
323
|
+
}
|
|
324
|
+
}
|
|
325
|
+
}
|
|
326
|
+
},
|
|
327
|
+
"type": "object"
|
|
328
|
+
}
|
|
329
|
+
}
|
|
330
|
+
},
|
|
305
331
|
"reportResourceSchema": {
|
|
306
332
|
"type": "object",
|
|
307
333
|
"properties": {
|
|
@@ -523,6 +549,9 @@
|
|
|
523
549
|
"type": "object",
|
|
524
550
|
"additionalProperties": false,
|
|
525
551
|
"properties": {
|
|
552
|
+
"migrations": {
|
|
553
|
+
"$ref": "#/$defs/migrationsSchema"
|
|
554
|
+
},
|
|
526
555
|
"calculations": {
|
|
527
556
|
"$ref": "#/$defs/calculationResourceSchema"
|
|
528
557
|
},
|
|
@@ -3,6 +3,10 @@
|
|
|
3
3
|
"additionalProperties": false,
|
|
4
4
|
"description": "General configuration settings for the card tree.",
|
|
5
5
|
"properties": {
|
|
6
|
+
"schemaVersion": {
|
|
7
|
+
"type": "number",
|
|
8
|
+
"description": "Version of the schema used by this project"
|
|
9
|
+
},
|
|
6
10
|
"cardKeyPrefix": {
|
|
7
11
|
"type": "string",
|
|
8
12
|
"description": "The prefix or the fist component of the card key. For example, ABC",
|
|
@@ -13,6 +13,11 @@
|
|
|
13
13
|
"type": "string",
|
|
14
14
|
"minLength": 1
|
|
15
15
|
},
|
|
16
|
+
"version": {
|
|
17
|
+
"description": "Version of the hub data",
|
|
18
|
+
"minimum": 1,
|
|
19
|
+
"type": "number"
|
|
20
|
+
},
|
|
16
21
|
"modules": {
|
|
17
22
|
"description": "List of modules that are available in the hub",
|
|
18
23
|
"type": "array",
|
|
@@ -52,7 +57,7 @@
|
|
|
52
57
|
}
|
|
53
58
|
}
|
|
54
59
|
},
|
|
55
|
-
"required": ["displayName", "
|
|
60
|
+
"required": ["description", "displayName", "version"],
|
|
56
61
|
"title": "Hub",
|
|
57
62
|
"type": "object"
|
|
58
63
|
}
|
package/src/schemas.ts
CHANGED
|
@@ -38,6 +38,9 @@ import vegaMacroSchema from './schema/macros/vegaMacroSchema.json' with { type:
|
|
|
38
38
|
import workflowSchema from './schema/resources/workflowSchema.json' with { type: 'json' };
|
|
39
39
|
import xrefMacroSchema from './schema/macros/xrefMacroSchema.json' with { type: 'json' };
|
|
40
40
|
import cardTreeDirectorySchema from './schema/cardTreeDirectorySchema.json' with { type: 'json' };
|
|
41
|
+
import version from './schema/version.json' with { type: 'json' };
|
|
42
|
+
|
|
43
|
+
export const SCHEMA_VERSION = version.schemaVersion;
|
|
41
44
|
|
|
42
45
|
export const schemas = [
|
|
43
46
|
calculationSchema,
|