@cyberismo/assets 0.0.6
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/LICENSE +702 -0
- package/README.md +1 -0
- package/dist/index.d.ts +21 -0
- package/dist/index.js +612 -0
- package/dist/schemas.d.ts +1132 -0
- package/dist/static/defaultReport/.schema +7 -0
- package/dist/static/defaultReport/index.adoc.hbs +3 -0
- package/dist/static/defaultReport/parameterSchema.json +18 -0
- package/dist/static/defaultReport/query.lp.hbs +2 -0
- package/package.json +30 -0
- package/src/calculations/common/base.lp +71 -0
- package/src/calculations/common/queryLanguage.lp +418 -0
- package/src/calculations/queries/card.lp +129 -0
- package/src/calculations/queries/onCreation.lp +44 -0
- package/src/calculations/queries/onTransition.lp +26 -0
- package/src/calculations/queries/tree.lp +6 -0
- package/src/calculations/test/model.lp +9 -0
- package/src/declarations.d.ts +9 -0
- package/src/graphvizReport/index.adoc.hbs +34 -0
- package/src/graphvizReport/query.lp.hbs +141 -0
- package/src/index.ts +52 -0
- package/src/schema/cardBaseSchema.json +76 -0
- package/src/schema/cardTreeDirectorySchema.json +663 -0
- package/src/schema/cardsConfigSchema.json +49 -0
- package/src/schema/csvSchema.json +30 -0
- package/src/schema/dotSchema.json +25 -0
- package/src/schema/macros/createCardsMacroSchema.json +39 -0
- package/src/schema/macros/graphMacroBaseSchema.json +17 -0
- package/src/schema/macros/reportMacroBaseSchema.json +13 -0
- package/src/schema/macros/scoreCardMacroSchema.json +24 -0
- package/src/schema/resources/cardTypeSchema.json +65 -0
- package/src/schema/resources/fieldTypeSchema.json +47 -0
- package/src/schema/resources/graphModelSchema.json +28 -0
- package/src/schema/resources/graphViewSchema.json +28 -0
- package/src/schema/resources/linkTypeSchema.json +56 -0
- package/src/schema/resources/reportSchema.json +28 -0
- package/src/schema/resources/templateSchema.json +28 -0
- package/src/schema/resources/workflowSchema.json +75 -0
- package/src/schema/schema.json +166 -0
- package/src/schemas.ts +54 -0
- package/src/static/defaultReport/.schema +7 -0
- package/src/static/defaultReport/index.adoc.hbs +3 -0
- package/src/static/defaultReport/parameterSchema.json +18 -0
- package/src/static/defaultReport/query.lp.hbs +2 -0
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
{
|
|
2
|
+
"title": "CardsConfig",
|
|
3
|
+
"$id": "cardsConfigSchema",
|
|
4
|
+
"description": "General configuration settings for the card tree.",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"properties": {
|
|
8
|
+
"cardKeyPrefix": {
|
|
9
|
+
"type": "string",
|
|
10
|
+
"description": "The prefix or the fist component of the card key. For example, ABC",
|
|
11
|
+
"pattern": "^[a-z]+$",
|
|
12
|
+
"minLength": 3,
|
|
13
|
+
"maxLength": 10
|
|
14
|
+
},
|
|
15
|
+
"name": {
|
|
16
|
+
"description": "Name of the project",
|
|
17
|
+
"type": "string",
|
|
18
|
+
"minLength": 1,
|
|
19
|
+
"pattern": "^[A-Za-z ._-]+$"
|
|
20
|
+
},
|
|
21
|
+
"modules": {
|
|
22
|
+
"description": "List of modules that have been included in the project",
|
|
23
|
+
"type": "array",
|
|
24
|
+
"items": {
|
|
25
|
+
"type": "object",
|
|
26
|
+
"properties": {
|
|
27
|
+
"name": {
|
|
28
|
+
"description": "Module name (project prefix). Must be unique.",
|
|
29
|
+
"type": "string"
|
|
30
|
+
},
|
|
31
|
+
"location": {
|
|
32
|
+
"description": "URI that is either a git URL with HTTPS, or relative file reference",
|
|
33
|
+
"type": "string"
|
|
34
|
+
},
|
|
35
|
+
"branch": {
|
|
36
|
+
"description": "If using git URL in 'location' defines git branch. If empty, assumed to be 'main'. ",
|
|
37
|
+
"type": "string"
|
|
38
|
+
},
|
|
39
|
+
"private": {
|
|
40
|
+
"description": "If true, the module is private and requires credentials (CYBERISMO_GIT_USER / CYBERISMO_GIT_TOKEN)",
|
|
41
|
+
"type": "boolean"
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
"required": ["name", "location"]
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
"required": ["cardKeyPrefix"]
|
|
49
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
{
|
|
2
|
+
"title": "Csv content",
|
|
3
|
+
"$id": "csvSchema",
|
|
4
|
+
"description": "Contains the content of a CSV file as an array of objects. Each object represents a row in the CSV file.",
|
|
5
|
+
"type": "array",
|
|
6
|
+
"items": {
|
|
7
|
+
"type": "object",
|
|
8
|
+
"additionalProperties": true,
|
|
9
|
+
"properties": {
|
|
10
|
+
"title": {
|
|
11
|
+
"type": "string",
|
|
12
|
+
"minLength": 1,
|
|
13
|
+
"description": "The title of the card"
|
|
14
|
+
},
|
|
15
|
+
"template": {
|
|
16
|
+
"type": "string",
|
|
17
|
+
"minLength": 1,
|
|
18
|
+
"description": "the name of the template for creating the card. Notice that the template must have exactly one card"
|
|
19
|
+
},
|
|
20
|
+
"description": {
|
|
21
|
+
"type": "string",
|
|
22
|
+
"description": "The AsciiDoc contents of the card"
|
|
23
|
+
},
|
|
24
|
+
"labels": {
|
|
25
|
+
"type": "string"
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
"required": ["title", "template"]
|
|
29
|
+
}
|
|
30
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
{
|
|
2
|
+
"title": "Dot Schema",
|
|
3
|
+
"$id": "dotSchema",
|
|
4
|
+
"description": "Schema of the .schema ",
|
|
5
|
+
"type": "array",
|
|
6
|
+
"items": {
|
|
7
|
+
"type": "object",
|
|
8
|
+
"additionalProperties": false,
|
|
9
|
+
"properties": {
|
|
10
|
+
"version": {
|
|
11
|
+
"description": "Version of the schema",
|
|
12
|
+
"type": "number"
|
|
13
|
+
},
|
|
14
|
+
"file": {
|
|
15
|
+
"description": "File that is being validated. If empty, validates all json using the schema in the directory.",
|
|
16
|
+
"type": "string"
|
|
17
|
+
},
|
|
18
|
+
"id": {
|
|
19
|
+
"description": "Id of the schema that is used to validate the given file",
|
|
20
|
+
"type": "string"
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
"required": ["version", "id"]
|
|
24
|
+
}
|
|
25
|
+
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
{
|
|
2
|
+
"type": "object",
|
|
3
|
+
"$id": "createCardsMacroSchema",
|
|
4
|
+
"properties": {
|
|
5
|
+
"buttonLabel": {
|
|
6
|
+
"type": "string",
|
|
7
|
+
"description": "The label of the button to create from this template. For example, 'Create a New Decision'."
|
|
8
|
+
},
|
|
9
|
+
"template": {
|
|
10
|
+
"type": "string",
|
|
11
|
+
"description": "The name of the template"
|
|
12
|
+
},
|
|
13
|
+
"cardKey": {
|
|
14
|
+
"type": "string",
|
|
15
|
+
"description": "The card key of the parent under which the template should be instantiated. If not given, the template will be instantiated under the card that includes this macro."
|
|
16
|
+
},
|
|
17
|
+
"link": {
|
|
18
|
+
"type": "object",
|
|
19
|
+
"properties": {
|
|
20
|
+
"linkType": {
|
|
21
|
+
"type": "string",
|
|
22
|
+
"description": "Name of the link type to create"
|
|
23
|
+
},
|
|
24
|
+
"direction": {
|
|
25
|
+
"type": "string",
|
|
26
|
+
"description": "Direction of the link. Can be 'inbound' or 'outbound'."
|
|
27
|
+
},
|
|
28
|
+
"cardKey": {
|
|
29
|
+
"type": "string",
|
|
30
|
+
"description": "Either the source of an inbound link or the target of an outbound link"
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
"additionalProperties": false,
|
|
34
|
+
"required": ["linkType", "direction", "cardKey"]
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
"additionalProperties": false,
|
|
38
|
+
"required": ["buttonLabel", "template"]
|
|
39
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
{
|
|
2
|
+
"title": "Graph",
|
|
3
|
+
"$id": "graphMacroBaseSchema",
|
|
4
|
+
"description": "A graph object provides supplemental information about a graph",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"properties": {
|
|
7
|
+
"model": {
|
|
8
|
+
"description": "Model",
|
|
9
|
+
"type": "string"
|
|
10
|
+
},
|
|
11
|
+
"view": {
|
|
12
|
+
"description": "View",
|
|
13
|
+
"type": "string"
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
"required": ["model", "view"]
|
|
17
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
{
|
|
2
|
+
"title": "Report",
|
|
3
|
+
"$id": "reportMacroBaseSchema",
|
|
4
|
+
"description": "A report object provides supplemental information about a report",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"properties": {
|
|
7
|
+
"name": {
|
|
8
|
+
"description": "The name of the report",
|
|
9
|
+
"type": "string"
|
|
10
|
+
}
|
|
11
|
+
},
|
|
12
|
+
"required": ["name"]
|
|
13
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
{
|
|
2
|
+
"type": "object",
|
|
3
|
+
"$id": "scoreCardMacroSchema",
|
|
4
|
+
"properties": {
|
|
5
|
+
"title": {
|
|
6
|
+
"type": "string",
|
|
7
|
+
"description": "Title text on top of the card (optional)"
|
|
8
|
+
},
|
|
9
|
+
"value": {
|
|
10
|
+
"type": "number",
|
|
11
|
+
"description": "Value shown as content of the card"
|
|
12
|
+
},
|
|
13
|
+
"unit": {
|
|
14
|
+
"type": "string",
|
|
15
|
+
"description": "Unit shown after the value (optional)"
|
|
16
|
+
},
|
|
17
|
+
"legend": {
|
|
18
|
+
"type": "string",
|
|
19
|
+
"description": "Description text shown below the value (optional)"
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"additionalProperties": false,
|
|
23
|
+
"required": ["value"]
|
|
24
|
+
}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
{
|
|
2
|
+
"title": "Cardtype",
|
|
3
|
+
"$id": "cardTypeSchema",
|
|
4
|
+
"description": "Card type defines the workflow and optional additional fields for the cards.",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"properties": {
|
|
8
|
+
"name": {
|
|
9
|
+
"description": "The name of the card type",
|
|
10
|
+
"type": "string",
|
|
11
|
+
"minLength": 1,
|
|
12
|
+
"pattern": "^[A-Za-z0-9]*/?[A-Za-z]*/?[A-Za-z-_]+[.json]*$"
|
|
13
|
+
},
|
|
14
|
+
"description": {
|
|
15
|
+
"description": "A description that describes the card type",
|
|
16
|
+
"type": "string"
|
|
17
|
+
},
|
|
18
|
+
"displayName": {
|
|
19
|
+
"description": "A name by which the card type is referred to in the user interface",
|
|
20
|
+
"type": "string"
|
|
21
|
+
},
|
|
22
|
+
"workflow": {
|
|
23
|
+
"description": "The name of the workflow",
|
|
24
|
+
"type": "string",
|
|
25
|
+
"minLength": 1,
|
|
26
|
+
"pattern": "^[A-Za-z0-9]*/?[A-Za-z0-9]*/?[A-Za-z-_]+[.json]*$"
|
|
27
|
+
},
|
|
28
|
+
"customFields": {
|
|
29
|
+
"type": "array",
|
|
30
|
+
"items": {
|
|
31
|
+
"type": "object",
|
|
32
|
+
"additionalProperties": false,
|
|
33
|
+
"properties": {
|
|
34
|
+
"name": {
|
|
35
|
+
"description": "The technical name by which the field is referred to in JSON files.",
|
|
36
|
+
"type": "string"
|
|
37
|
+
},
|
|
38
|
+
"displayName": {
|
|
39
|
+
"description": "A name by which the field is referred to in the user interface.",
|
|
40
|
+
"type": "string"
|
|
41
|
+
},
|
|
42
|
+
"isCalculated": {
|
|
43
|
+
"description": "Defines if field value is a calculated field.",
|
|
44
|
+
"type": "boolean",
|
|
45
|
+
"default": true
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
"required": ["name"]
|
|
49
|
+
}
|
|
50
|
+
},
|
|
51
|
+
"alwaysVisibleFields": {
|
|
52
|
+
"type": "array",
|
|
53
|
+
"items": {
|
|
54
|
+
"type": "string"
|
|
55
|
+
}
|
|
56
|
+
},
|
|
57
|
+
"optionallyVisibleFields": {
|
|
58
|
+
"type": "array",
|
|
59
|
+
"items": {
|
|
60
|
+
"type": "string"
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
},
|
|
64
|
+
"required": ["displayName", "name", "workflow"]
|
|
65
|
+
}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
{
|
|
2
|
+
"title": "FieldType",
|
|
3
|
+
"$id": "fieldTypeSchema",
|
|
4
|
+
"description": "Field type defines the workflow and optional additional fields for the cards.",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"properties": {
|
|
8
|
+
"name": {
|
|
9
|
+
"type": "string",
|
|
10
|
+
"description": "The technical name by which the field is referred to in JSON files."
|
|
11
|
+
},
|
|
12
|
+
"displayName": {
|
|
13
|
+
"type": "string",
|
|
14
|
+
"description": "A name by which the field is referred to in the user interface."
|
|
15
|
+
},
|
|
16
|
+
"description": {
|
|
17
|
+
"type": "string",
|
|
18
|
+
"description": "A description that describes the field type"
|
|
19
|
+
},
|
|
20
|
+
"dataType": {
|
|
21
|
+
"type": "string",
|
|
22
|
+
"description": "",
|
|
23
|
+
"pattern": "^shortText$|^longText$|^number$|^integer$|^boolean$|^enum$|^list$|^date$|^dateTime$|^person$"
|
|
24
|
+
},
|
|
25
|
+
"enumValues": {
|
|
26
|
+
"description": "An array of available enum values. Used for the enum fieldType only.",
|
|
27
|
+
"type": "array",
|
|
28
|
+
"items": {
|
|
29
|
+
"type": "object",
|
|
30
|
+
"additionalProperties": false,
|
|
31
|
+
"properties": {
|
|
32
|
+
"enumValue": {
|
|
33
|
+
"type": "string"
|
|
34
|
+
},
|
|
35
|
+
"enumDisplayValue": {
|
|
36
|
+
"type": "string"
|
|
37
|
+
},
|
|
38
|
+
"enumDescription": {
|
|
39
|
+
"type": "string"
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
"required": ["enumValue"]
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
"required": ["displayName", "name", "dataType"]
|
|
47
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
{
|
|
2
|
+
"title": "GraphModel",
|
|
3
|
+
"$id": "graphModelSchema",
|
|
4
|
+
"description": "A graph model object provides data for graph views",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"properties": {
|
|
7
|
+
"name": {
|
|
8
|
+
"description": "The name of this graph model",
|
|
9
|
+
"type": "string",
|
|
10
|
+
"minLength": 1,
|
|
11
|
+
"pattern": "^[A-Za-z0-9/._-]+$"
|
|
12
|
+
},
|
|
13
|
+
"displayName": {
|
|
14
|
+
"description": "The name of the graph model as it should be displayed in the user interface. For example, 'Workflow data'.",
|
|
15
|
+
"type": "string"
|
|
16
|
+
},
|
|
17
|
+
"description": {
|
|
18
|
+
"description": "A description of the graph model. For example, 'Workflow data defines necessary data elements to show workflow graphically.'.",
|
|
19
|
+
"type": "string"
|
|
20
|
+
},
|
|
21
|
+
"category": {
|
|
22
|
+
"description": "The category of the graph model. For example, 'UserModels'.",
|
|
23
|
+
"type": "string"
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
"required": ["displayName", "name", "displayName"],
|
|
27
|
+
"additionalProperties": false
|
|
28
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
{
|
|
2
|
+
"title": "GraphView",
|
|
3
|
+
"$id": "graphViewSchema",
|
|
4
|
+
"description": "A graph view object provides means to show graph model data to users",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"properties": {
|
|
7
|
+
"name": {
|
|
8
|
+
"description": "The name of this graph view",
|
|
9
|
+
"type": "string",
|
|
10
|
+
"minLength": 1,
|
|
11
|
+
"pattern": "^[A-Za-z0-9/._-]+$"
|
|
12
|
+
},
|
|
13
|
+
"displayName": {
|
|
14
|
+
"description": "The name of the graph view as it should be displayed in the user interface. For example, 'Workflow view'.",
|
|
15
|
+
"type": "string"
|
|
16
|
+
},
|
|
17
|
+
"description": {
|
|
18
|
+
"description": "A description of the graph view. For example, 'Workflow view defines ways how to show workflow data to the user'.",
|
|
19
|
+
"type": "string"
|
|
20
|
+
},
|
|
21
|
+
"category": {
|
|
22
|
+
"description": "The category of the graph view. For example, 'UserViews'.",
|
|
23
|
+
"type": "string"
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
"required": ["displayName", "name", "displayName"],
|
|
27
|
+
"additionalProperties": false
|
|
28
|
+
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
{
|
|
2
|
+
"title": "LinkType",
|
|
3
|
+
"$id": "linkTypeSchema",
|
|
4
|
+
"description": "Link types defined different ways to link cards together.",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"properties": {
|
|
8
|
+
"description": {
|
|
9
|
+
"description": "A description that describes the link type",
|
|
10
|
+
"type": "string"
|
|
11
|
+
},
|
|
12
|
+
"displayName": {
|
|
13
|
+
"description": "A name by which the link type is referred to in the user interface",
|
|
14
|
+
"type": "string"
|
|
15
|
+
},
|
|
16
|
+
"name": {
|
|
17
|
+
"type": "string",
|
|
18
|
+
"description": "The technical name by which the field is referred to in JSON files."
|
|
19
|
+
},
|
|
20
|
+
"outboundDisplayName": {
|
|
21
|
+
"type": "string",
|
|
22
|
+
"description": "A name by which the field is referred to in the user interface(from-to)."
|
|
23
|
+
},
|
|
24
|
+
"inboundDisplayName": {
|
|
25
|
+
"type": "string",
|
|
26
|
+
"description": "A name by which the field is referred to in the user interface(to-from)."
|
|
27
|
+
},
|
|
28
|
+
"sourceCardTypes": {
|
|
29
|
+
"type": "array",
|
|
30
|
+
"description": "The card types that can be the source of this link type. If empty, all card types are allowed.",
|
|
31
|
+
"items": {
|
|
32
|
+
"type": "string"
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
"destinationCardTypes": {
|
|
36
|
+
"type": "array",
|
|
37
|
+
"description": "The card types that can be the target of this link type. If empty, all card types are allowed.",
|
|
38
|
+
"items": {
|
|
39
|
+
"type": "string"
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
"enableLinkDescription": {
|
|
43
|
+
"type": "boolean",
|
|
44
|
+
"description": "If true, the user can add a description to the link."
|
|
45
|
+
}
|
|
46
|
+
},
|
|
47
|
+
"required": [
|
|
48
|
+
"displayName",
|
|
49
|
+
"name",
|
|
50
|
+
"outboundDisplayName",
|
|
51
|
+
"inboundDisplayName",
|
|
52
|
+
"sourceCardTypes",
|
|
53
|
+
"destinationCardTypes",
|
|
54
|
+
"enableLinkDescription"
|
|
55
|
+
]
|
|
56
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
{
|
|
2
|
+
"title": "Report",
|
|
3
|
+
"$id": "reportSchema",
|
|
4
|
+
"description": "A report object provides supplemental information about a report",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"properties": {
|
|
7
|
+
"name": {
|
|
8
|
+
"description": "The name of this report",
|
|
9
|
+
"type": "string",
|
|
10
|
+
"minLength": 1,
|
|
11
|
+
"pattern": "^[A-Za-z0-9/._-]+$"
|
|
12
|
+
},
|
|
13
|
+
"displayName": {
|
|
14
|
+
"description": "The name of the report as it should be displayed in the user interface. For example, 'Children list'.",
|
|
15
|
+
"type": "string"
|
|
16
|
+
},
|
|
17
|
+
"description": {
|
|
18
|
+
"description": "A description of the report. For example, 'A Children list shows the child cards as an unordered list.'.",
|
|
19
|
+
"type": "string"
|
|
20
|
+
},
|
|
21
|
+
"category": {
|
|
22
|
+
"description": "The category of the report. For example, 'Architecture'.",
|
|
23
|
+
"type": "string"
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
"required": ["name", "displayName", "category"],
|
|
27
|
+
"additionalProperties": false
|
|
28
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
{
|
|
2
|
+
"title": "Template",
|
|
3
|
+
"$id": "templateSchema",
|
|
4
|
+
"description": "A template object provides supplemental information about a template directory structure ",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"properties": {
|
|
8
|
+
"name": {
|
|
9
|
+
"description": "The name of this template",
|
|
10
|
+
"type": "string",
|
|
11
|
+
"minLength": 1,
|
|
12
|
+
"pattern": "^[A-Za-z0-9/._-]+$"
|
|
13
|
+
},
|
|
14
|
+
"displayName": {
|
|
15
|
+
"description": "The name of the template as it should be displayed in the user interface. For example, 'Decision'.",
|
|
16
|
+
"type": "string"
|
|
17
|
+
},
|
|
18
|
+
"description": {
|
|
19
|
+
"description": "A description of the template. For example, 'A decision is a choice between two or more options.'.",
|
|
20
|
+
"type": "string"
|
|
21
|
+
},
|
|
22
|
+
"category": {
|
|
23
|
+
"description": "The category of the template. For example, 'Decision'.",
|
|
24
|
+
"type": "string"
|
|
25
|
+
}
|
|
26
|
+
},
|
|
27
|
+
"required": ["displayName", "name"]
|
|
28
|
+
}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
{
|
|
2
|
+
"title": "Workflow",
|
|
3
|
+
"$id": "workflowSchema",
|
|
4
|
+
"description": "A state machine for the workflow of cards",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"properties": {
|
|
8
|
+
"description": {
|
|
9
|
+
"description": "A description that describes the workflow",
|
|
10
|
+
"type": "string"
|
|
11
|
+
},
|
|
12
|
+
"displayName": {
|
|
13
|
+
"description": "A name by which the workflow is referred to in the user interface",
|
|
14
|
+
"type": "string"
|
|
15
|
+
},
|
|
16
|
+
"name": {
|
|
17
|
+
"description": "The name of this workflow",
|
|
18
|
+
"type": "string",
|
|
19
|
+
"minLength": 1,
|
|
20
|
+
"pattern": "^[A-Za-z0-9/._-]+$"
|
|
21
|
+
},
|
|
22
|
+
"states": {
|
|
23
|
+
"description": "The states of the workflow",
|
|
24
|
+
"type": "array",
|
|
25
|
+
"items": {
|
|
26
|
+
"type": "object",
|
|
27
|
+
"additionalProperties": false,
|
|
28
|
+
"properties": {
|
|
29
|
+
"name": {
|
|
30
|
+
"description": "The name of a workflow state",
|
|
31
|
+
"type": "string",
|
|
32
|
+
"minLength": 1,
|
|
33
|
+
"pattern": "^[A-Za-z ._-]+$"
|
|
34
|
+
},
|
|
35
|
+
"category": {
|
|
36
|
+
"description": "The category of a workflow state",
|
|
37
|
+
"enum": ["none", "initial", "active", "closed"]
|
|
38
|
+
}
|
|
39
|
+
},
|
|
40
|
+
"required": ["name", "category"]
|
|
41
|
+
}
|
|
42
|
+
},
|
|
43
|
+
"transitions": {
|
|
44
|
+
"description": "The state transitions of the workflow",
|
|
45
|
+
"type": "array",
|
|
46
|
+
"items": {
|
|
47
|
+
"type": "object",
|
|
48
|
+
"additionalProperties": false,
|
|
49
|
+
"properties": {
|
|
50
|
+
"name": {
|
|
51
|
+
"type": "string",
|
|
52
|
+
"minLength": 1,
|
|
53
|
+
"pattern": "^[A-Za-z. _-]+$"
|
|
54
|
+
},
|
|
55
|
+
"fromState": {
|
|
56
|
+
"description": "List of states where state transition can start from",
|
|
57
|
+
"type": "array",
|
|
58
|
+
"items": {
|
|
59
|
+
"description": "The name of the starting state of the transition. The wildcard '*' denotes any state and and empty value denotes the transition to create a new card with this workflow.",
|
|
60
|
+
"type": "string",
|
|
61
|
+
"pattern": "^[*]|^$|^[A-Za-z ._-]+$"
|
|
62
|
+
}
|
|
63
|
+
},
|
|
64
|
+
"toState": {
|
|
65
|
+
"description": "The name of the end state of the transition",
|
|
66
|
+
"type": "string",
|
|
67
|
+
"pattern": "^[*]|^$|^[A-Za-z ._-]+$"
|
|
68
|
+
}
|
|
69
|
+
},
|
|
70
|
+
"required": ["name", "fromState", "toState"]
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
},
|
|
74
|
+
"required": ["displayName", "name", "states", "transitions"]
|
|
75
|
+
}
|