@salesforce/plugin-bre-to-cml 1.1.5 → 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/README.md +27 -9
- package/lib/commands/cml/convert/surcharge-rules.d.ts +19 -3
- package/lib/commands/cml/convert/surcharge-rules.js +94 -13
- package/lib/commands/cml/convert/surcharge-rules.js.map +1 -1
- package/lib/commands/cml/convert/underwriting-rules.d.ts +16 -4
- package/lib/commands/cml/convert/underwriting-rules.js +37 -40
- package/lib/commands/cml/convert/underwriting-rules.js.map +1 -1
- package/lib/shared/insurance/insurance-cml-merge.d.ts +91 -0
- package/lib/shared/insurance/insurance-cml-merge.js +569 -0
- package/lib/shared/insurance/insurance-cml-merge.js.map +1 -0
- package/lib/shared/insurance/insurance-org.d.ts +19 -1
- package/lib/shared/insurance/insurance-org.js +9 -1
- package/lib/shared/insurance/insurance-org.js.map +1 -1
- package/lib/shared/insurance/insurance-rule-convert-command.d.ts +46 -2
- package/lib/shared/insurance/insurance-rule-convert-command.js +213 -22
- package/lib/shared/insurance/insurance-rule-convert-command.js.map +1 -1
- package/lib/shared/insurance/insurance-rule-generator.d.ts +38 -1
- package/lib/shared/insurance/insurance-rule-generator.js +165 -6
- package/lib/shared/insurance/insurance-rule-generator.js.map +1 -1
- package/lib/shared/insurance/models.d.ts +25 -0
- package/messages/cml.convert.insurance-shared.md +9 -1
- package/messages/cml.convert.surcharge-rules.md +1 -1
- package/messages/cml.convert.underwriting-rules.md +1 -1
- package/oclif.lock +291 -649
- package/oclif.manifest.json +5 -5
- package/package.json +10 -10
package/oclif.manifest.json
CHANGED
|
@@ -113,7 +113,7 @@
|
|
|
113
113
|
"cml:convert:surcharge-rules": {
|
|
114
114
|
"aliases": [],
|
|
115
115
|
"args": {},
|
|
116
|
-
"description": "Reads ProductSurcharge records from the org (or a JSON file), parses their RuleDefinition, and
|
|
116
|
+
"description": "Reads ProductSurcharge records from the org (or a JSON file), parses their RuleDefinition, and merges the generated surcharge rules into the org's existing curated ConstraintModel for the resolved CML API. Each surcharge rule is nested into its leaf product type with a platform-compatible pathed rule key (matching the RuleKey the platform auto-generates), so the rule actually fires for nested products instead of being silently dropped. The command is file-only and never writes to the org. It requires an existing CML model to merge into and outputs a .cml file with the full merged model, a header-only \\_Associations.csv file, a \\_RuleKeyMapping.json with the ProductSurcharge ID to RuleKey mapping, and a \\_SurchargeUpdate.json file enumerating the org-record changes. Review the files, then apply the CML with `sf cml import as-expression-set` and apply the org-record changes enumerated in the \\_SurchargeUpdate.json file to the org separately (in that order).",
|
|
117
117
|
"examples": [
|
|
118
118
|
"<%= config.bin %> <%= command.id %> --cml-api SURCHARGE_CML --target-org myOrg",
|
|
119
119
|
"<%= config.bin %> <%= command.id %> --cml-api SURCHARGE_CML --surcharge-file path/to/surcharges.json --workspace-dir data --target-org myOrg"
|
|
@@ -169,7 +169,7 @@
|
|
|
169
169
|
},
|
|
170
170
|
"update-records": {
|
|
171
171
|
"name": "update-records",
|
|
172
|
-
"summary": "
|
|
172
|
+
"summary": "REMOVED. Convert no longer writes to the org; passing this flag now errors. Convert instead emits a reviewable record-update file enumerating the org-record changes, which you apply to the org separately.",
|
|
173
173
|
"allowNo": false,
|
|
174
174
|
"type": "boolean"
|
|
175
175
|
},
|
|
@@ -212,7 +212,7 @@
|
|
|
212
212
|
"cml:convert:underwriting-rules": {
|
|
213
213
|
"aliases": [],
|
|
214
214
|
"args": {},
|
|
215
|
-
"description": "Reads UnderwritingRule records from the org (or a JSON file), parses their DynamicRuleDefinition, and generates CML constraints that evaluate underwriting eligibility. Each rule becomes a named constraint that returns true/false. The command outputs a .cml file with the constraint model, an \\_Associations.csv file for ExpressionSetConstraintObj records,
|
|
215
|
+
"description": "Reads UnderwritingRule records from the org (or a JSON file), parses their DynamicRuleDefinition, and generates CML constraints that evaluate underwriting eligibility. Each rule becomes a named constraint that returns true/false. The command is file-only and never writes to the org: it outputs a .cml file with the constraint model, an \\_Associations.csv file for ExpressionSetConstraintObj records, a \\_RuleKeyMapping.json with the UnderwritingRule ID to RuleKey mapping, and a \\_UnderwritingUpdate.json file enumerating the org-record changes. Review the files, then apply the CML with `sf cml import as-expression-set` and apply the org-record changes enumerated in the \\_UnderwritingUpdate.json file to the org separately.",
|
|
216
216
|
"examples": [
|
|
217
217
|
"<%= config.bin %> <%= command.id %> --cml-api UW_CML --target-org myOrg",
|
|
218
218
|
"<%= config.bin %> <%= command.id %> --cml-api UW_CML --uw-file data/underwriting.json --workspace-dir data --target-org myOrg"
|
|
@@ -268,7 +268,7 @@
|
|
|
268
268
|
},
|
|
269
269
|
"update-records": {
|
|
270
270
|
"name": "update-records",
|
|
271
|
-
"summary": "
|
|
271
|
+
"summary": "REMOVED. Convert no longer writes to the org; passing this flag now errors. Convert instead emits a reviewable record-update file enumerating the org-record changes, which you apply to the org separately.",
|
|
272
272
|
"allowNo": false,
|
|
273
273
|
"type": "boolean"
|
|
274
274
|
},
|
|
@@ -403,5 +403,5 @@
|
|
|
403
403
|
]
|
|
404
404
|
}
|
|
405
405
|
},
|
|
406
|
-
"version": "1.
|
|
406
|
+
"version": "1.2.5"
|
|
407
407
|
}
|
package/package.json
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@salesforce/plugin-bre-to-cml",
|
|
3
3
|
"description": "Plugin for migrating BRE based configurator rules to CML.",
|
|
4
|
-
"version": "1.
|
|
4
|
+
"version": "1.2.5",
|
|
5
5
|
"salesforceRelease": "256.11",
|
|
6
6
|
"dependencies": {
|
|
7
7
|
"@oclif/core": "^4",
|
|
8
|
-
"@salesforce/core": "^8.
|
|
8
|
+
"@salesforce/core": "^8.32.2",
|
|
9
9
|
"@salesforce/sf-plugins-core": "^12",
|
|
10
10
|
"csv-parse": "^5.6.0",
|
|
11
11
|
"got": "12"
|
|
12
12
|
},
|
|
13
13
|
"devDependencies": {
|
|
14
|
-
"@oclif/plugin-command-snapshot": "^5.3.
|
|
15
|
-
"@oclif/test": "^4.1.
|
|
16
|
-
"@salesforce/cli-plugins-testkit": "^5.3.
|
|
14
|
+
"@oclif/plugin-command-snapshot": "^5.3.29",
|
|
15
|
+
"@oclif/test": "^4.1.20",
|
|
16
|
+
"@salesforce/cli-plugins-testkit": "^5.3.62",
|
|
17
17
|
"@salesforce/dev-scripts": "^11.0.4",
|
|
18
|
-
"@salesforce/plugin-command-reference": "^3.1.
|
|
19
|
-
"@types/node": "^22.
|
|
18
|
+
"@salesforce/plugin-command-reference": "^3.1.119",
|
|
19
|
+
"@types/node": "^22.20.0",
|
|
20
20
|
"eslint-config-salesforce-license": "^1.0.2",
|
|
21
21
|
"eslint-plugin-sf-plugin": "^1.20.33",
|
|
22
|
-
"oclif": "^4.23.
|
|
22
|
+
"oclif": "^4.23.24",
|
|
23
23
|
"ts-node": "^10.9.2",
|
|
24
24
|
"typescript": "^5.9.3"
|
|
25
25
|
},
|
|
@@ -221,7 +221,7 @@
|
|
|
221
221
|
"type": "module",
|
|
222
222
|
"author": "George Kibilov",
|
|
223
223
|
"sfdx": {
|
|
224
|
-
"publicKeyUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-bre-to-cml/1.
|
|
225
|
-
"signatureUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-bre-to-cml/1.
|
|
224
|
+
"publicKeyUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-bre-to-cml/1.2.5.crt",
|
|
225
|
+
"signatureUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-bre-to-cml/1.2.5.sig"
|
|
226
226
|
}
|
|
227
227
|
}
|