Skip to content

Commit 48d8856

Browse files
authored
Merge pull request #397 from snehaljha-sf/feedback
Feedback
2 parents da36baf + 00aab22 commit 48d8856

20 files changed

+245
-385
lines changed

messages/assess.json

Lines changed: 74 additions & 87 deletions
Large diffs are not rendered by default.

messages/migrate.json

Lines changed: 58 additions & 85 deletions
Large diffs are not rendered by default.

src/migration/flexcard.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -882,7 +882,7 @@ export class CardMigrationTool extends BaseMigrationTool implements MigrationToo
882882
finalKey = finalKey.toLowerCase();
883883
if (storage.fcStorage.has(finalKey)) {
884884
// Key already exists - handle accordingly
885-
Logger.logVerbose(this.messages.getMessage('keyAlreadyInStorage', [finalKey]));
885+
Logger.logVerbose(this.messages.getMessage('keyAlreadyInStorage', ['Flexcard', finalKey]));
886886
value.isDuplicate = true;
887887
storage.fcStorage.set(finalKey, value);
888888
} else {
@@ -929,7 +929,7 @@ export class CardMigrationTool extends BaseMigrationTool implements MigrationToo
929929
finalKey = finalKey.toLowerCase();
930930
if (storage.fcStorage.has(finalKey)) {
931931
// Key already exists - handle accordingly
932-
Logger.logVerbose(this.messages.getMessage('keyAlreadyInStorage', [finalKey]));
932+
Logger.logVerbose(this.messages.getMessage('keyAlreadyInStorage', ['Flexcard', finalKey]));
933933
value.isDuplicate = true;
934934
storage.fcStorage.set(finalKey, value);
935935
} else {
@@ -1078,7 +1078,7 @@ export class CardMigrationTool extends BaseMigrationTool implements MigrationToo
10781078
if (c && this.nameRegistry.hasFlexCardMapping(c)) {
10791079
return this.nameRegistry.getFlexCardCleanedName(c);
10801080
} else {
1081-
Logger.logVerbose(`\n${this.messages.getMessage('componentMappingNotFound', ['FlexCard', c])}`);
1081+
Logger.logVerbose(`\n${this.messages.getMessage('componentMappingNotFound', ['Flexcard', c])}`);
10821082
return this.cleanName(c);
10831083
}
10841084
});
@@ -1237,7 +1237,7 @@ export class CardMigrationTool extends BaseMigrationTool implements MigrationToo
12371237
component.property.cardName = this.nameRegistry.getFlexCardCleanedName(originalCardName);
12381238
} else {
12391239
Logger.logVerbose(
1240-
`\n${this.messages.getMessage('componentMappingNotFound', ['FlexCard', originalCardName])}`
1240+
`\n${this.messages.getMessage('componentMappingNotFound', ['Flexcard', originalCardName])}`
12411241
);
12421242
component.property.cardName = this.cleanName(originalCardName);
12431243
}

src/migration/omniscript.ts

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,6 @@ import {
3434
populateRegexForFunctionMetadata,
3535
} from '../utils/formula/FormulaUtil';
3636
import { StringVal } from '../utils/StringValue/stringval';
37-
import { formatUnicorn } from '../utils/stringUtils';
3837
import { Logger } from '../utils/logger';
3938
import { createProgressBar } from './base';
4039
import { StorageUtil } from '../utils/storageUtil';
@@ -131,7 +130,7 @@ export class OmniScriptMigrationTool extends BaseMigrationTool implements Migrat
131130

132131
let success: boolean = await NetUtils.delete(this.connection, ids);
133132
if (!success) {
134-
throw new Error(formatUnicorn(this.messages.getMessage('couldNotTruncateOmnniProcess'), objectName));
133+
throw new Error(this.messages.getMessage('couldNotTruncateOmnniProcess', [this.getName(), this.getName()]));
135134
}
136135
}
137136

@@ -662,7 +661,7 @@ export class OmniScriptMigrationTool extends BaseMigrationTool implements Migrat
662661
finalKey = finalKey.toLowerCase();
663662
if (storage.osStorage.has(finalKey)) {
664663
// Key already exists - handle accordingly
665-
Logger.logVerbose(this.messages.getMessage('keyAlreadyInStorage', [finalKey]));
664+
Logger.logVerbose(this.messages.getMessage('keyAlreadyInStorage', ['Omniscript', finalKey]));
666665
value.isDuplicate = true;
667666
storage.osStorage.set(finalKey, value);
668667
} else {
@@ -1167,7 +1166,7 @@ export class OmniScriptMigrationTool extends BaseMigrationTool implements Migrat
11671166
finalKey = finalKey.toLowerCase();
11681167
if (storage.osStorage.has(finalKey)) {
11691168
// Key already exists - handle accordingly
1170-
Logger.logVerbose(this.messages.getMessage('keyAlreadyInStorage', [finalKey]));
1169+
Logger.logVerbose(this.messages.getMessage('keyAlreadyInStorage', ['Omniscript', finalKey]));
11711170
value.isDuplicate = true;
11721171
storage.osStorage.set(finalKey, value);
11731172
} else {

src/utils/constants/documentRegistry.ts

Lines changed: 0 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,6 @@
11
export const documentRegistry = {
2-
errorNoOrgResults:
3-
'https://help.salesforce.com/s/articleView?id=xcloud.os_migrate_get_moving_run_the_omnistudio_migration_tool.htm&type=5',
4-
couldNotDeactivateOmniProcesses:
5-
'https://help.salesforce.com/s/articleView?id=ind.insurance_deactivate_and_activate_omniscripts_509999.htm&type=5',
6-
couldNotTruncate:
7-
'https://help.salesforce.com/s/articleView?id=xcloud.os_embed_an_omniscript_in_another_omniscript_20581.htm&type=5',
8-
couldNotTruncateOmnniProcess:
9-
'https://help.salesforce.com/s/articleView?id=xcloud.os_embed_an_omniscript_in_another_omniscript_20581.htm&type=5',
10-
invalidNameTypeSubtypeOrLanguage:
11-
'https://help.salesforce.com/s/articleView?id=xcloud.os_omnistudio_naming_conventions.htm&type=5',
122
invalidOrRepeatingOmniscriptElementNames:
133
'https://help.salesforce.com/s/articleView?id=xcloud.os_omnistudio_naming_conventions.htm&type=5',
14-
invalidDataRaptorName:
15-
'https://help.salesforce.com/s/articleView?id=xcloud.os_omnistudio_naming_conventions.htm&type=5',
164
duplicatedCardName: 'https://help.salesforce.com/s/articleView?id=xcloud.os_omnistudio_naming_conventions.htm&type=5',
175
duplicatedDrName: 'https://help.salesforce.com/s/articleView?id=xcloud.os_omnistudio_naming_conventions.htm&type=5',
186
duplicatedOSName: 'https://help.salesforce.com/s/articleView?id=xcloud.os_omnistudio_naming_conventions.htm&type=5',
@@ -22,31 +10,12 @@ export const documentRegistry = {
2210
'https://help.salesforce.com/s/articleView?id=xcloud.os_activateconfigureand_publish_flexcards_24744.htm&type=5',
2311
errorWhileUploadingCard:
2412
'https://help.salesforce.com/s/articleView?id=xcloud.os_activateconfigureand_publish_flexcards_24744.htm&type=5',
25-
errorWhileCreatingElements:
26-
'https://help.salesforce.com/s/articleView?id=xcloud.os_omniscript_element_reference.htm&type=5',
27-
allVersionsDescription:
28-
'https://help.salesforce.com/s/articleView?id=release-notes.rn_omnistudio_migrate_all_versions.htm&release=248&type=5',
29-
changeMessage: 'https://help.salesforce.com/s/articleView?id=xcloud.os_omnistudio_naming_conventions.htm&type=5',
3013
angularOSWarning:
3114
'https://help.salesforce.com/s/articleView?id=xcloud.os_convert_an_angular_omniscript_to_an_lwc_omniscript.htm&type=5',
3215
formulaSyntaxError: 'https://help.salesforce.com/s/articleView?id=xcloud.os_formulas_and_functions_1.htm&type=5',
3316
fileNoOmnistudioCalls: 'https://help.salesforce.com/s/articleView?id=xcloud.os_callable_implementations.htm&type=5',
34-
fileAlreadyImplementsCallable:
35-
'https://help.salesforce.com/s/articleView?id=xcloud.os_callable_implementations.htm&type=5',
36-
inApexDrNameWillBeUpdated:
37-
'https://help.salesforce.com/s/articleView?id=xcloud.os_migrate_update_references_to_dataraptors_from_apex_after_migration.htm&type=5',
38-
fileUpdatedToAllowRemoteCalls:
39-
'https://help.salesforce.com/s/articleView?id=xcloud.os_make_a_long_running_remote_call_using_omnistudio_omnicontinuation.htm&type=5',
40-
fileUpdatedToAllowCalls:
41-
'https://help.salesforce.com/s/articleView?id=xcloud.os_make_a_long_running_remote_call_using_omnistudio_omnicontinuation.htm&type=5',
42-
fileImplementsVlocityOpenInterface:
43-
'https://help.salesforce.com/s/articleView?id=ind.v_dev_t_vlocityopeninterface_657706.htm&type=5',
44-
methodCallBundleNameUpdated:
45-
'https://help.salesforce.com/s/articleView?id=xcloud.os_migrate_update_omnistudio_custom_functions_after_migration.htm&type=5',
4617
cardNameChangeMessage:
4718
'https://help.salesforce.com/s/articleView?id=xcloud.os_omnistudio_naming_conventions.htm&type=5',
48-
authordNameChangeMessage:
49-
'https://help.salesforce.com/s/articleView?id=xcloud.os_omnistudio_naming_conventions.htm&type=5',
5019
omniScriptNameChangeMessage:
5120
'https://help.salesforce.com/s/articleView?id=xcloud.os_migrate_omniscript_elements_with_overridden_components.htm&type=5',
5221
dataRaptorNameChangeMessage:
@@ -56,8 +25,6 @@ export const documentRegistry = {
5625
integrationProcedureManualUpdateMessage:
5726
'https://help.salesforce.com/s/articleView?id=xcloud.os_migrate_update_references_to_dataraptors_from_apex_after_migration.htm&type=5',
5827
duplicateCardNameMessage: 'https://help.salesforce.com/s/articleView?id=xcloud.os_clone_a_flexcard.htm&type=5',
59-
duplicateGlobalAutoNumberNameMessage:
60-
'https://help.salesforce.com/s/articleView?id=xcloud.os_omnistudio_naming_conventions.htm&type=5',
6128
reservedKeysFoundInPropertySet:
6229
'https://help.salesforce.com/s/articleView?id=xcloud.os_omnistudio_naming_conventions.htm&type=5',
6330
manualDeploymentSteps:

src/utils/constants/stringContants.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ export const Constants = {
1515
OmniScriptComponentName: 'OmniScript',
1616
OmniScriptPluralName: 'OmniScripts',
1717
FlexCardComponentName: 'Flexcard',
18-
FlexCardPluralName: 'FlexCards',
18+
FlexCardPluralName: 'Flexcards',
1919
IntegrationProcedureComponentName: 'IntegrationProcedure',
2020
IntegrationProcedurePluralName: 'IntegrationProcedures',
2121
DataRaptorComponentName: 'DataRaptor',

src/utils/resultsbuilder/ApexAssessmentReporter.ts

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -118,19 +118,17 @@ export class ApexAssessmentReporter {
118118
1,
119119
false,
120120
undefined,
121-
apexAssessmentInfo.infos,
122-
this.getMigrationStatusCssClass(apexAssessmentInfo, true)
121+
[...apexAssessmentInfo.infos, ...apexAssessmentInfo.warnings]
123122
),
124123
createRowDataParam(
125124
'errors',
126-
apexAssessmentInfo.warnings ? apexAssessmentInfo.warnings.join(', ') : '',
125+
apexAssessmentInfo.errors ? apexAssessmentInfo.errors.join(', ') : '',
127126
false,
128127
1,
129128
1,
130129
false,
131130
undefined,
132-
apexAssessmentInfo.warnings,
133-
this.getMigrationStatusCssClass(apexAssessmentInfo, true)
131+
apexAssessmentInfo.errors
134132
),
135133
],
136134
}));

src/utils/resultsbuilder/DRAssessmentReporter.ts

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -207,12 +207,7 @@ export class DRAssessmentReporter {
207207
1,
208208
false,
209209
undefined,
210-
dataRaptorAssessmentInfo.warnings,
211-
dataRaptorAssessmentInfo.migrationStatus === 'Warnings'
212-
? 'text-warning'
213-
: dataRaptorAssessmentInfo.migrationStatus === 'Ready for migration'
214-
? ''
215-
: 'text-error'
210+
dataRaptorAssessmentInfo.warnings
216211
),
217212
createRowDataParam(
218213
'customFunctionDependencies',

src/utils/resultsbuilder/ExperienceSiteAssessmentReporter.ts

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -121,17 +121,7 @@ export class ExperienceSiteAssessmentReporter {
121121
undefined,
122122
FileDiffUtil.getDiffHTML(experienceSiteAssessmentInfo.diff, experienceSiteAssessmentInfo.name)
123123
),
124-
createRowDataParam(
125-
'summary',
126-
'',
127-
false,
128-
1,
129-
1,
130-
false,
131-
undefined,
132-
experienceSiteAssessmentInfo.warnings,
133-
experienceSiteAssessmentInfo.status === 'Ready for migration' ? 'text-success' : 'text-error'
134-
),
124+
createRowDataParam('summary', '', false, 1, 1, false, undefined, experienceSiteAssessmentInfo.warnings),
135125
],
136126
rowId: `${this.rowIdPrefix}${this.rowId++}`,
137127
}));

src/utils/resultsbuilder/FlexcardAssessmentReporter.ts

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -207,12 +207,7 @@ export class FlexcardAssessmentReporter {
207207
1,
208208
false,
209209
undefined,
210-
flexCardAssessmentInfo.warnings,
211-
flexCardAssessmentInfo.migrationStatus === 'Warnings'
212-
? 'text-warning'
213-
: flexCardAssessmentInfo.migrationStatus === 'Ready for migration'
214-
? ''
215-
: 'text-error'
210+
flexCardAssessmentInfo.warnings
216211
),
217212
createRowDataParam(
218213
'omniScriptDependencies',

0 commit comments

Comments
 (0)