@cxtms/cx-schema 1.5.7 → 1.5.8

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cxtms/cx-schema",
3
- "version": "1.5.7",
3
+ "version": "1.5.8",
4
4
  "description": "Schema validation package for CargoXplorer YAML modules",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -8,103 +8,48 @@ module:
8
8
  en-US: "{{displayName}}"
9
9
  description:
10
10
  en-US: "{{displayName}} configuration module"
11
- application: CargoXplorer
12
- fileName: "{{fileName}}"
11
+ application: System
13
12
 
14
13
  components:
15
- - name: {{displayNameNoSpaces}}/Configuration
14
+ - name: Configurations/{{displayNameNoSpaces}}
16
15
  displayName:
17
- en-US: "{{displayName}}"
16
+ en-US: "{{displayName}} Config"
17
+ platforms:
18
+ - web
19
+ props:
18
20
  layout:
19
- component: form
20
- name: {{name}}Form
21
+ component: layout
22
+ name: {{displayNameNoSpaces}}ConfigLayout
23
+ inputs:
21
24
  props:
25
+ cols: 1
22
26
  title:
23
- en-US: "{{displayName}}"
24
- queries:
25
- - name: getConfiguration
26
- query:
27
- command: |
28
- query GetConfiguration($organizationId: Int!) {
29
- configuration(organizationId: $organizationId) {
30
- settingName
31
- maxRetries
32
- enableNotifications
33
- }
34
- }
35
- variables:
36
- organizationId: "\{{organizationId}}"
37
- initialValues:
38
- fromQuery:
39
- name: getConfiguration
40
- path: configuration
41
- append:
42
- settingName: "Default Setting"
43
- maxRetries: 3
44
- enableNotifications: true
45
- validationSchema:
46
- settingName:
47
- type: string
48
- required: true
49
- maxRetries:
50
- type: number
51
- required: true
52
- enableNotifications:
53
- type: boolean
54
- onSubmit:
55
- - type: mutation
56
- props:
57
- command: |
58
- mutation SaveConfiguration($organizationId: Int!, $input: ConfigurationInput!) {
59
- saveConfiguration(organizationId: $organizationId, input: $input) {
60
- success
61
- }
62
- }
63
- variables:
64
- organizationId: "\{{organizationId}}"
65
- input: "\{{formValues}}"
66
- - type: notification
67
- props:
68
- message:
69
- en-US: "{{displayName}} saved successfully"
70
- severity: success
27
+ en-US: "{{displayName}} Configuration"
28
+ icon: Create
29
+ permission: System/OrganizationConfigs/Update
71
30
  children:
72
- - component: field
73
- name: settingName
74
- props:
75
- label:
76
- en-US: "Setting Name"
77
- type: text
78
- required: true
79
- - component: field
80
- name: maxRetries
81
- props:
82
- label:
83
- en-US: "Max Retries"
84
- type: number
85
- - component: field
86
- name: enableNotifications
31
+ - component: form
32
+ name: organizationConfigForm
33
+ inputs:
87
34
  props:
88
- label:
89
- en-US: "Enable Notifications"
90
- type: checkbox
35
+ cols: 1
36
+ title:
37
+ en-US: "{{displayName}} Settings"
38
+ initialValues:
39
+ children:
40
+ - component: field
41
+ name: customValues.enabled
42
+ props:
43
+ type: checkbox
44
+ label:
45
+ en-US: "Enable {{displayName}}"
91
46
 
92
- routes:
93
- - name: configuration
94
- path: /{{name}}
95
- component: {{displayNameNoSpaces}}/Configuration
96
- props:
97
- title:
98
- en-US: "{{displayName}}"
99
-
100
- permissions:
101
- - name: "{{displayNameNoSpaces}}/View"
47
+ configurations:
48
+ - configName: "apps.{{name}}"
102
49
  displayName:
103
- en-US: "View {{displayName}}"
104
- roles:
105
- - Admin
106
- - name: "{{displayNameNoSpaces}}/Edit"
107
- displayName:
108
- en-US: "Edit {{displayName}}"
109
- roles:
110
- - Admin
50
+ en-US: "{{displayName}}"
51
+ description:
52
+ en-US: "{{displayName}} configuration"
53
+ component: "Configurations/{{displayNameNoSpaces}}"
54
+ defaultValue:
55
+ enabled: false