@pega/dx-component-builder-sdk 0.242.3 → 0.242.4
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 +1 -1
- package/src/tasks/create/templates/Constellation/field/Decimal/index.tsx.mustache +3 -6
- package/src/tasks/create/templates/Constellation/field/Decimal-Currency/index.tsx.mustache +1 -3
- package/src/tasks/create/templates/Constellation/field/Decimal-Percentage/index.tsx.mustache +2 -5
- package/src/tasks/create/templates/Constellation/field/Picklist-Autocomplete/index.tsx.mustache +10 -52
- package/src/tasks/create/templates/Constellation/field/Picklist-Autocomplete/utils.ts.mustache +1 -1
- package/src/tasks/create/templates/Constellation/template/DETAILS/Avatar.tsx.mustache +5 -7
- package/src/tasks/create/templates/Constellation/template/DETAILS-region/Avatar.tsx.mustache +5 -7
- package/src/tasks/create/templates/Constellation/widget/PAGE-CASE/Avatar.tsx.mustache +5 -7
- package/src/tasks/create/templates/SDK-React/field/Decimal/index.tsx.mustache +1 -1
- package/src/tasks/create/templates/SDK-React/field/Decimal-Currency/index.tsx.mustache +1 -1
- package/src/tasks/create/templates/SDK-React/field/Decimal-Percentage/index.tsx.mustache +1 -1
- package/src/tasks/create/templates/SDK-React/field/Text-Phone/index.tsx.mustache +5 -5
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyCurrency/index.tsx +1 -3
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyDecimal/index.tsx +3 -6
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MyPercentage/index.tsx +2 -5
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/index.tsx +10 -52
- package/tests/assets/sdk-r/components/createAll/custom-constellation/field/Pega_DXIL_MySearchbox/utils.ts +1 -1
- package/tests/assets/sdk-r/components/createAll/custom-constellation/template/Pega_DXIL_MyDetails/Avatar.tsx +5 -7
- package/tests/assets/sdk-r/components/createAll/custom-constellation/template/Pega_DXIL_MyTwoColumnDetails/Avatar.tsx +5 -7
- package/tests/assets/sdk-r/components/createAll/custom-constellation/widget/Pega_DXIL_MyPageCaseWidget/Avatar.tsx +5 -7
- package/tests/assets/sdk-r/components/createAll/custom-sdk/field/Pega_DXIL_MyCurrency/index.tsx +1 -1
- package/tests/assets/sdk-r/components/createAll/custom-sdk/field/Pega_DXIL_MyDecimal/index.tsx +1 -1
- package/tests/assets/sdk-r/components/createAll/custom-sdk/field/Pega_DXIL_MyPercentage/index.tsx +1 -1
- package/tests/functional/sdk-r/localCreateBuildDeleteOverride.test.js +1 -1
- package/tests/functional/sdk-r/localCreatePublishAllDeleteAllCustom.test.js +1 -1
- package/tests/functional/sdk-r/localCreatePublishAllDeleteAllOverride.test.js +1 -1
- package/tests/functional/sdk-r/localCreatePublishDeleteOverride.test.js +1 -1
package/package.json
CHANGED
|
@@ -88,9 +88,8 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
88
88
|
}, [validatemessage, hasSuggestions, status]);
|
|
89
89
|
|
|
90
90
|
const { decimalPrecision, currencyDecimalPrecision } = props;
|
|
91
|
-
let numberOfDecimals = parseInt(decimalPrecision, 10);
|
|
91
|
+
let numberOfDecimals: number | undefined = parseInt(decimalPrecision, 10);
|
|
92
92
|
if (Number.isNaN(numberOfDecimals)) {
|
|
93
|
-
// @ts-ignore
|
|
94
93
|
numberOfDecimals = decimalPrecision === '' ? undefined : 2;
|
|
95
94
|
}
|
|
96
95
|
let noOfFractionDigits = currencyDecimalPrecision === 'auto' ? undefined : parseInt(currencyDecimalPrecision, 10);
|
|
@@ -226,15 +225,13 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
226
225
|
}
|
|
227
226
|
setDecimalValue(enteredValue);
|
|
228
227
|
if (value !== (enteredValue !== '' ? Number(enteredValue) : '')) {
|
|
229
|
-
|
|
230
|
-
handleEvent(actions, 'change', propName, enteredValue !== '' ? Number(enteredValue) : '');
|
|
228
|
+
handleEvent(actions, 'change', propName, enteredValue !== '' ? Number(enteredValue).toString() : '');
|
|
231
229
|
hasValueChange.current = true;
|
|
232
230
|
}
|
|
233
231
|
}}
|
|
234
232
|
onBlur={() => {
|
|
235
233
|
if (!value || hasValueChange.current) {
|
|
236
|
-
|
|
237
|
-
handleEvent(actions, 'blur', propName, decimalValue !== '' ? Number(decimalValue) : '');
|
|
234
|
+
handleEvent(actions, 'blur', propName, decimalValue !== '' ? Number(decimalValue).toString() : '');
|
|
238
235
|
if (hasSuggestions) {
|
|
239
236
|
pConn.ignoreSuggestion("");
|
|
240
237
|
}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
|
|
2
1
|
import { useState, useEffect } from 'react';
|
|
3
2
|
import {
|
|
4
3
|
CurrencyInput as CosmosCurrency,
|
|
@@ -265,9 +264,8 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
265
264
|
});
|
|
266
265
|
}}
|
|
267
266
|
onBlur={(enteredValue) => {
|
|
268
|
-
const parsedValue = enteredValue !== '' ? Number(enteredValue) : enteredValue;
|
|
267
|
+
const parsedValue = enteredValue !== '' ? Number(enteredValue).toString() : enteredValue;
|
|
269
268
|
if (!readOnly && (!value || value !== parsedValue)) {
|
|
270
|
-
// @ts-ignore
|
|
271
269
|
handleEvent(actions, 'changeNblur', propName, parsedValue);
|
|
272
270
|
if (hasSuggestions) {
|
|
273
271
|
pConn.ignoreSuggestion('');
|
package/src/tasks/create/templates/Constellation/field/Decimal-Percentage/index.tsx.mustache
CHANGED
|
@@ -94,9 +94,8 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
94
94
|
}
|
|
95
95
|
}, [validatemessage, hasSuggestions, status]);
|
|
96
96
|
|
|
97
|
-
let numberOfDecimals = parseInt(decimalPrecision, 10);
|
|
97
|
+
let numberOfDecimals : number | undefined = parseInt(decimalPrecision, 10);
|
|
98
98
|
if (Number.isNaN(numberOfDecimals)) {
|
|
99
|
-
// @ts-ignore
|
|
100
99
|
numberOfDecimals = decimalPrecision === '' ? undefined : 2;
|
|
101
100
|
}
|
|
102
101
|
|
|
@@ -247,15 +246,13 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
247
246
|
}
|
|
248
247
|
setPercentageValue(enteredValue);
|
|
249
248
|
if (value !== enteredValue) {
|
|
250
|
-
// @ts-ignore
|
|
251
249
|
handleEvent(actions, 'change', propName, enteredValue);
|
|
252
250
|
hasValueChange.current = true;
|
|
253
251
|
}
|
|
254
252
|
}}
|
|
255
253
|
onBlur={() => {
|
|
256
|
-
const parsedValue = percentageValue !== '' ? Number(percentageValue) : '';
|
|
254
|
+
const parsedValue = percentageValue !== '' ? Number(percentageValue).toString() : '';
|
|
257
255
|
if (!value || hasValueChange.current) {
|
|
258
|
-
// @ts-ignore
|
|
259
256
|
handleEvent(actions, 'blur', propName, parsedValue);
|
|
260
257
|
if (hasSuggestions) {
|
|
261
258
|
pConn.ignoreSuggestion("");
|
package/src/tasks/create/templates/Constellation/field/Picklist-Autocomplete/index.tsx.mustache
CHANGED
|
@@ -497,14 +497,14 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
497
497
|
const pConn = getPConnect();
|
|
498
498
|
const contextName = getPConnect().getContextName();
|
|
499
499
|
const actions = pConn.getActionsApi();
|
|
500
|
-
const [dataApiObj, setDataApiObj] = useState(() => ({}));
|
|
500
|
+
const [dataApiObj, setDataApiObj] = useState(() => ({} as any));
|
|
501
501
|
const [filterValue, setFilterValue] = useState('');
|
|
502
502
|
const [loading, setLoading] = useState(listType !== 'associated');
|
|
503
503
|
// const selected = useMemo(() => menuHelpers.getSelected(items)[0], [items]);
|
|
504
504
|
const [selected, setSelected] = useState();
|
|
505
505
|
const hasMoreResults = useRef(true);
|
|
506
506
|
const inputValueRef = useRef('');
|
|
507
|
-
const displayFieldMeta = useRef(null);
|
|
507
|
+
const displayFieldMeta: any = useRef(null);
|
|
508
508
|
const [actualValue, setActualValue] = useState();
|
|
509
509
|
const [newRecordCreated, setNewRecordCreated] = useState();
|
|
510
510
|
|
|
@@ -645,15 +645,13 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
645
645
|
}
|
|
646
646
|
PCore.getDataApi()
|
|
647
647
|
.init(dataConfig, contextName)
|
|
648
|
-
.then(dataObj => {
|
|
649
|
-
// @ts-ignore
|
|
648
|
+
.then((dataObj: any) => {
|
|
650
649
|
setDataApiObj(dataObj);
|
|
651
650
|
// To avoid calling doSearch if someone types/pastes value before the API call is made
|
|
652
651
|
if (!filterValue)
|
|
653
652
|
doSearch(
|
|
654
653
|
'',
|
|
655
654
|
getDisplayFieldsMetaData(dataConfig.columns),
|
|
656
|
-
// @ts-ignore
|
|
657
655
|
dataObj,
|
|
658
656
|
setItems as any,
|
|
659
657
|
setLoading,
|
|
@@ -679,12 +677,10 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
679
677
|
if (!dataRefMount && !displayMode && listType === 'datapage') {
|
|
680
678
|
PCore.getDataApi()
|
|
681
679
|
.init(dataConfig, contextName)
|
|
682
|
-
.then(dataObj => {
|
|
683
|
-
// @ts-ignore
|
|
680
|
+
.then((dataObj: any) => {
|
|
684
681
|
setDataApiObj(dataObj);
|
|
685
682
|
// To avoid calling doSearch if someone types/pastes value before the API call is made
|
|
686
683
|
if (!filterValue) {
|
|
687
|
-
// @ts-ignore
|
|
688
684
|
if (displayFieldMeta?.current?.key === displayFieldMeta?.current?.primary) {
|
|
689
685
|
const displayItem = {
|
|
690
686
|
id: value,
|
|
@@ -696,7 +692,6 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
696
692
|
doSearch(
|
|
697
693
|
'',
|
|
698
694
|
getDisplayFieldsMetaData(dataConfig.columns),
|
|
699
|
-
// @ts-ignore
|
|
700
695
|
dataObj,
|
|
701
696
|
setItems as any,
|
|
702
697
|
setLoading,
|
|
@@ -716,7 +711,6 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
716
711
|
doSearch(
|
|
717
712
|
'',
|
|
718
713
|
getDisplayFieldsMetaData(dataConfig.columns),
|
|
719
|
-
// @ts-ignore
|
|
720
714
|
dataObj,
|
|
721
715
|
setItems as any,
|
|
722
716
|
setLoading,
|
|
@@ -775,22 +769,16 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
775
769
|
) {
|
|
776
770
|
PCore.getDataApi()
|
|
777
771
|
.init(dataConfig, contextName)
|
|
778
|
-
.then(dataObj => {
|
|
779
|
-
// @ts-ignore
|
|
772
|
+
.then((dataObj: any) => {
|
|
780
773
|
setDataApiObj(dataObj);
|
|
781
|
-
// @ts-ignore
|
|
782
774
|
buildColumnForDisplayValue(dataObj);
|
|
783
775
|
// SET matchPosition to EQUALS to return exact matching record
|
|
784
|
-
// @ts-ignore
|
|
785
776
|
dataObj.matchPosition = 'equals';
|
|
786
|
-
// @ts-ignore
|
|
787
777
|
dataObj
|
|
788
778
|
.fetchData(value)
|
|
789
779
|
.then((displayResponse: { data: Array<never> }) => {
|
|
790
780
|
let columnsWithSetProperty: string | Array<any> = [];
|
|
791
|
-
// @ts-ignore
|
|
792
781
|
if (dataApiObj.columns) {
|
|
793
|
-
// @ts-ignore
|
|
794
782
|
columnsWithSetProperty = dataApiObj.columns
|
|
795
783
|
.filter(
|
|
796
784
|
(col: { setProperty: string }) =>
|
|
@@ -805,12 +793,9 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
805
793
|
const searchedItem = displayResponseData.map((entry: { [x: string]: any }) => {
|
|
806
794
|
const secondaryArr: Array<any> = [];
|
|
807
795
|
const secondaryFieldValues: Array<any> = [];
|
|
808
|
-
// @ts-ignore
|
|
809
796
|
displayFieldMeta.current.secondary.forEach((col: string) => {
|
|
810
|
-
// @ts-ignore
|
|
811
797
|
if (!displayFieldMeta.hidden.includes(col)) secondaryArr.push(entry[col]);
|
|
812
798
|
if (columnsWithSetProperty.includes(col)) {
|
|
813
|
-
// @ts-ignore
|
|
814
799
|
if (dataApiObj.isQueryable) {
|
|
815
800
|
secondaryFieldValues.push(entry[col]);
|
|
816
801
|
} else {
|
|
@@ -819,9 +804,7 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
819
804
|
}
|
|
820
805
|
});
|
|
821
806
|
return {
|
|
822
|
-
// @ts-ignore
|
|
823
807
|
id: entry[displayFieldMeta.current.key],
|
|
824
|
-
// @ts-ignore
|
|
825
808
|
primary: entry[displayFieldMeta.current.primary],
|
|
826
809
|
secondary: secondaryArr,
|
|
827
810
|
secondaryFieldValues
|
|
@@ -832,13 +815,11 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
832
815
|
setSelected(searchedItem[0]);
|
|
833
816
|
setActualValue(value);
|
|
834
817
|
// RESET matchPosition
|
|
835
|
-
// @ts-ignore
|
|
836
818
|
dataObj.matchPosition = dataConfig.matchPosition;
|
|
837
819
|
})
|
|
838
820
|
.catch(() => {
|
|
839
821
|
setActualValue(value);
|
|
840
822
|
// RESET matchPosition
|
|
841
|
-
// @ts-ignore
|
|
842
823
|
dataObj.matchPosition = dataConfig.matchPosition;
|
|
843
824
|
});
|
|
844
825
|
});
|
|
@@ -856,21 +837,17 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
856
837
|
};
|
|
857
838
|
})
|
|
858
839
|
);
|
|
859
|
-
|
|
860
|
-
setSelected(null);
|
|
840
|
+
setSelected(undefined);
|
|
861
841
|
inputValueRef.current = '';
|
|
862
842
|
};
|
|
863
843
|
|
|
864
844
|
const onChangeHandler = (ev: { target: { value: any } }) => {
|
|
865
845
|
if (hasSuggestions) {
|
|
866
|
-
|
|
867
|
-
pConn.ignoreSuggestion();
|
|
846
|
+
pConn.ignoreSuggestion('');
|
|
868
847
|
setStatus(undefined);
|
|
869
848
|
}
|
|
870
849
|
|
|
871
|
-
// @ts-ignore
|
|
872
850
|
dataApiObj.columns = dataConfig.columns;
|
|
873
|
-
// @ts-ignore
|
|
874
851
|
dataApiObj.matchPosition = dataConfig.matchPosition;
|
|
875
852
|
const searchText = ev.target.value;
|
|
876
853
|
inputValueRef.current = searchText;
|
|
@@ -879,15 +856,14 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
879
856
|
clearSelections();
|
|
880
857
|
}
|
|
881
858
|
setFilterValue(searchText);
|
|
882
|
-
// @ts-ignore
|
|
883
859
|
if (listType === 'datapage' && dataApiObj.isQueryable) {
|
|
884
860
|
hasMoreResults.current = true;
|
|
885
861
|
if (searchText.length < 5) {
|
|
886
862
|
searchHandlerThrottled(
|
|
887
863
|
searchText,
|
|
888
|
-
// @ts-ignore
|
|
889
864
|
displayFieldMeta.current,
|
|
890
865
|
dataApiObj,
|
|
866
|
+
// @ts-ignore
|
|
891
867
|
setItems,
|
|
892
868
|
setLoading,
|
|
893
869
|
hasMoreResults
|
|
@@ -895,9 +871,9 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
895
871
|
} else {
|
|
896
872
|
searchHandlerDebounced(
|
|
897
873
|
searchText,
|
|
898
|
-
// @ts-ignore
|
|
899
874
|
displayFieldMeta.current,
|
|
900
875
|
dataApiObj,
|
|
876
|
+
// @ts-ignore
|
|
901
877
|
setItems,
|
|
902
878
|
setLoading,
|
|
903
879
|
hasMoreResults
|
|
@@ -905,14 +881,12 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
905
881
|
}
|
|
906
882
|
} else if (
|
|
907
883
|
listType === 'associated' ||
|
|
908
|
-
// @ts-ignore
|
|
909
884
|
(listType === 'datapage' && dataApiObj?.isQueryable === false)
|
|
910
885
|
) {
|
|
911
886
|
paginateHelperApis.resetIndexes();
|
|
912
887
|
const progressivePaginatedRecords = paginateHelperApis.fetchData(
|
|
913
888
|
inputValueRef.current,
|
|
914
889
|
false,
|
|
915
|
-
// @ts-ignore
|
|
916
890
|
dataApiObj.columns
|
|
917
891
|
);
|
|
918
892
|
setItems(progressivePaginatedRecords);
|
|
@@ -939,21 +913,19 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
939
913
|
|
|
940
914
|
setFilterValue('');
|
|
941
915
|
if (!selected && inputValueRef.current !== '') {
|
|
942
|
-
// @ts-ignore
|
|
943
916
|
if (listType === 'datapage' && dataApiObj.isQueryable) {
|
|
944
917
|
hasMoreResults.current = true;
|
|
945
918
|
searchHandlerThrottled(
|
|
946
919
|
'',
|
|
947
|
-
// @ts-ignore
|
|
948
920
|
displayFieldMeta.current,
|
|
949
921
|
dataApiObj,
|
|
922
|
+
// @ts-ignore
|
|
950
923
|
setItems,
|
|
951
924
|
setLoading,
|
|
952
925
|
hasMoreResults
|
|
953
926
|
);
|
|
954
927
|
} else if (
|
|
955
928
|
listType === 'associated' ||
|
|
956
|
-
// @ts-ignore
|
|
957
929
|
(listType === 'datapage' && dataApiObj?.isQueryable === false)
|
|
958
930
|
) {
|
|
959
931
|
paginateHelperApis.resetIndexes();
|
|
@@ -976,7 +948,6 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
976
948
|
// @ts-ignore
|
|
977
949
|
setSelected(menuHelpers.getSelected(updatedItems)[0]);
|
|
978
950
|
// const { id: itemId } = menuHelpers.getSelected(updatedItems)[0];
|
|
979
|
-
// @ts-ignore
|
|
980
951
|
const assocProp = pConn.getStateProps().value;
|
|
981
952
|
const propValue = setValueToAssocProp(
|
|
982
953
|
assocProp,
|
|
@@ -1009,7 +980,6 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
1009
980
|
const loadMore = () => {
|
|
1010
981
|
if (
|
|
1011
982
|
(listType === 'associated' ||
|
|
1012
|
-
// @ts-ignore
|
|
1013
983
|
(listType === 'datapage' && dataApiObj?.isQueryable === false)) &&
|
|
1014
984
|
paginateHelperApis.hasMoreResults(inputValueRef.current)
|
|
1015
985
|
) {
|
|
@@ -1019,23 +989,18 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
1019
989
|
progressivePaginatedRecords = removeDuplicates(previousItems, progressivePaginatedRecords);
|
|
1020
990
|
return [...previousItems, ...progressivePaginatedRecords];
|
|
1021
991
|
});
|
|
1022
|
-
// @ts-ignore
|
|
1023
992
|
} else if (listType === 'datapage' && dataApiObj.isQueryable && hasMoreResults.current) {
|
|
1024
993
|
setLoading(true);
|
|
1025
994
|
dataApiObj
|
|
1026
|
-
// @ts-ignore
|
|
1027
995
|
.fetchPaginatedData(inputValueRef.current)
|
|
1028
996
|
.then((response: { pageSize: number; data: Array<never> }) => {
|
|
1029
997
|
setLoading(false);
|
|
1030
|
-
// @ts-ignore
|
|
1031
998
|
if (response.pageSize === 0 || response.pageSize < dataApiObj.pageSize) {
|
|
1032
999
|
hasMoreResults.current = false;
|
|
1033
1000
|
}
|
|
1034
1001
|
const listObjData = response.data || [];
|
|
1035
1002
|
let columnsWithSetProperty: string | Array<any> = [];
|
|
1036
|
-
// @ts-ignore
|
|
1037
1003
|
if (dataApiObj.columns) {
|
|
1038
|
-
// @ts-ignore
|
|
1039
1004
|
columnsWithSetProperty = dataApiObj.columns
|
|
1040
1005
|
.filter(
|
|
1041
1006
|
(col: { setProperty: string }) =>
|
|
@@ -1049,12 +1014,9 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
1049
1014
|
const searchedItems = listObjData.map((entry: { [x: string]: any }) => {
|
|
1050
1015
|
const secondaryArr: Array<any> = [];
|
|
1051
1016
|
const secondaryFieldValues: Array<any> = [];
|
|
1052
|
-
// @ts-ignore
|
|
1053
1017
|
displayFieldMeta.current.secondary.forEach((col: string) => {
|
|
1054
|
-
// @ts-ignore
|
|
1055
1018
|
if (!displayFieldMeta.current.hidden.includes(col)) secondaryArr.push(entry[col]);
|
|
1056
1019
|
if (columnsWithSetProperty.includes(col)) {
|
|
1057
|
-
// @ts-ignore
|
|
1058
1020
|
if (dataApiObj.isQueryable) {
|
|
1059
1021
|
secondaryFieldValues.push(entry[col]);
|
|
1060
1022
|
} else {
|
|
@@ -1063,9 +1025,7 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
1063
1025
|
}
|
|
1064
1026
|
});
|
|
1065
1027
|
return {
|
|
1066
|
-
// @ts-ignore
|
|
1067
1028
|
id: entry[displayFieldMeta.current.key],
|
|
1068
|
-
// @ts-ignore
|
|
1069
1029
|
primary: entry[displayFieldMeta.current.primary],
|
|
1070
1030
|
secondary: secondaryArr,
|
|
1071
1031
|
secondaryFieldValues
|
|
@@ -1076,7 +1036,6 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
1076
1036
|
})
|
|
1077
1037
|
.catch(() => {
|
|
1078
1038
|
setLoading(false);
|
|
1079
|
-
// @ts-ignore
|
|
1080
1039
|
dataApiObj.pageSize -= 1;
|
|
1081
1040
|
});
|
|
1082
1041
|
}
|
|
@@ -1162,7 +1121,6 @@ function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}Props) {
|
|
|
1162
1121
|
selected: item.items ? undefined : !!item.selected || item.id === selected?.id
|
|
1163
1122
|
})),
|
|
1164
1123
|
onItemClick: selectItem,
|
|
1165
|
-
// @ts-ignore
|
|
1166
1124
|
emptyText: pConn.getLocalizedValue('No items'),
|
|
1167
1125
|
loading,
|
|
1168
1126
|
loadMore,
|
package/src/tasks/create/templates/Constellation/field/Picklist-Autocomplete/utils.ts.mustache
CHANGED
|
@@ -187,7 +187,7 @@ export const updatePropertiesForNewRecord = (
|
|
|
187
187
|
dataObj
|
|
188
188
|
.fetchData(newCaseId)
|
|
189
189
|
// @ts-ignore
|
|
190
|
-
.then(displayResponse => {
|
|
190
|
+
.then((displayResponse: any) => {
|
|
191
191
|
let columnsWithSetProperty = [];
|
|
192
192
|
if (dataApiObj.columns) {
|
|
193
193
|
columnsWithSetProperty = dataApiObj.columns
|
|
@@ -22,8 +22,8 @@ function Avatar(props: {{COMPONENT_CLASS_NAME}}AvatarProps) {
|
|
|
22
22
|
// TODO Below if conditions can be removed once we have apis to get worklist/mywork info
|
|
23
23
|
// This is non CaseView case (Dashboard, MyWork etc)
|
|
24
24
|
if (!metaObj) {
|
|
25
|
-
userName = PCore.getEnvironmentInfo().getOperatorName();
|
|
26
|
-
userIdentifier = PCore.getEnvironmentInfo().getOperatorIdentifier();
|
|
25
|
+
userName = PCore.getEnvironmentInfo().getOperatorName() ?? "";
|
|
26
|
+
userIdentifier = PCore.getEnvironmentInfo().getOperatorIdentifier() ?? "";
|
|
27
27
|
} else {
|
|
28
28
|
userName = metaObj.name;
|
|
29
29
|
userIdentifier = metaObj.ID;
|
|
@@ -46,22 +46,20 @@ function Avatar(props: {{COMPONENT_CLASS_NAME}}AvatarProps) {
|
|
|
46
46
|
const currentState = PCore.getMessagingServiceManager().getUserPresence().getUserState(userIdentifier);
|
|
47
47
|
const [userState, setUserState]: any = useState(currentState === 'online' ? 'active' : 'inactive');
|
|
48
48
|
|
|
49
|
-
|
|
50
|
-
const handleUserStateChange = ({ state }) => {
|
|
49
|
+
const handleUserStateChange = ({ state }: any) => {
|
|
51
50
|
setUserState(state === 'online' ? 'active' : 'inactive');
|
|
52
51
|
};
|
|
53
52
|
|
|
54
53
|
useEffect(() => {
|
|
55
54
|
const subId = PCore.getMessagingServiceManager()
|
|
56
55
|
.getUserPresence()
|
|
57
|
-
|
|
58
|
-
.subscribe(userIdentifier, handleUserStateChange);
|
|
56
|
+
.subscribe(userIdentifier, handleUserStateChange, '');
|
|
59
57
|
|
|
60
58
|
return function cleanup() {
|
|
61
59
|
PCore.getMessagingServiceManager().getUserPresence().unsubscribe(userIdentifier, subId);
|
|
62
60
|
};
|
|
63
61
|
}, [userIdentifier, handleUserStateChange]);
|
|
64
|
-
|
|
62
|
+
|
|
65
63
|
return <CosmosAvatar name={userName} imageSrc={imageBlobUrl as React.SetStateAction<any>} status={userState} />;
|
|
66
64
|
}
|
|
67
65
|
|
package/src/tasks/create/templates/Constellation/template/DETAILS-region/Avatar.tsx.mustache
CHANGED
|
@@ -22,8 +22,8 @@ function Avatar(props: {{COMPONENT_CLASS_NAME}}AvatarProps) {
|
|
|
22
22
|
// TODO Below if conditions can be removed once we have apis to get worklist/mywork info
|
|
23
23
|
// This is non CaseView case (Dashboard, MyWork etc)
|
|
24
24
|
if (!metaObj) {
|
|
25
|
-
userName = PCore.getEnvironmentInfo().getOperatorName();
|
|
26
|
-
userIdentifier = PCore.getEnvironmentInfo().getOperatorIdentifier();
|
|
25
|
+
userName = PCore.getEnvironmentInfo().getOperatorName() ?? "";
|
|
26
|
+
userIdentifier = PCore.getEnvironmentInfo().getOperatorIdentifier() ?? "";
|
|
27
27
|
} else {
|
|
28
28
|
userName = metaObj.name;
|
|
29
29
|
userIdentifier = metaObj.ID;
|
|
@@ -46,22 +46,20 @@ function Avatar(props: {{COMPONENT_CLASS_NAME}}AvatarProps) {
|
|
|
46
46
|
const currentState = PCore.getMessagingServiceManager().getUserPresence().getUserState(userIdentifier);
|
|
47
47
|
const [userState, setUserState]: any = useState(currentState === 'online' ? 'active' : 'inactive');
|
|
48
48
|
|
|
49
|
-
|
|
50
|
-
const handleUserStateChange = ({ state }) => {
|
|
49
|
+
const handleUserStateChange = ({ state }: any) => {
|
|
51
50
|
setUserState(state === 'online' ? 'active' : 'inactive');
|
|
52
51
|
};
|
|
53
52
|
|
|
54
53
|
useEffect(() => {
|
|
55
54
|
const subId = PCore.getMessagingServiceManager()
|
|
56
55
|
.getUserPresence()
|
|
57
|
-
|
|
58
|
-
.subscribe(userIdentifier, handleUserStateChange);
|
|
56
|
+
.subscribe(userIdentifier, handleUserStateChange, '');
|
|
59
57
|
|
|
60
58
|
return function cleanup() {
|
|
61
59
|
PCore.getMessagingServiceManager().getUserPresence().unsubscribe(userIdentifier, subId);
|
|
62
60
|
};
|
|
63
61
|
}, [userIdentifier, handleUserStateChange]);
|
|
64
|
-
|
|
62
|
+
|
|
65
63
|
return <CosmosAvatar name={userName} imageSrc={imageBlobUrl as React.SetStateAction<any>} status={userState} />;
|
|
66
64
|
}
|
|
67
65
|
|
|
@@ -22,8 +22,8 @@ function Avatar(props: {{COMPONENT_CLASS_NAME}}AvatarProps) {
|
|
|
22
22
|
// TODO Below if conditions can be removed once we have apis to get worklist/mywork info
|
|
23
23
|
// This is non CaseView case (Dashboard, MyWork etc)
|
|
24
24
|
if (!metaObj) {
|
|
25
|
-
userName = PCore.getEnvironmentInfo().getOperatorName();
|
|
26
|
-
userIdentifier = PCore.getEnvironmentInfo().getOperatorIdentifier();
|
|
25
|
+
userName = PCore.getEnvironmentInfo().getOperatorName() ?? "";
|
|
26
|
+
userIdentifier = PCore.getEnvironmentInfo().getOperatorIdentifier() ?? "";
|
|
27
27
|
} else {
|
|
28
28
|
userName = metaObj.name;
|
|
29
29
|
userIdentifier = metaObj.ID;
|
|
@@ -46,22 +46,20 @@ function Avatar(props: {{COMPONENT_CLASS_NAME}}AvatarProps) {
|
|
|
46
46
|
const currentState = PCore.getMessagingServiceManager().getUserPresence().getUserState(userIdentifier);
|
|
47
47
|
const [userState, setUserState]: any = useState(currentState === 'online' ? 'active' : 'inactive');
|
|
48
48
|
|
|
49
|
-
|
|
50
|
-
const handleUserStateChange = ({ state }) => {
|
|
49
|
+
const handleUserStateChange = ({ state }: any) => {
|
|
51
50
|
setUserState(state === 'online' ? 'active' : 'inactive');
|
|
52
51
|
};
|
|
53
52
|
|
|
54
53
|
useEffect(() => {
|
|
55
54
|
const subId = PCore.getMessagingServiceManager()
|
|
56
55
|
.getUserPresence()
|
|
57
|
-
|
|
58
|
-
.subscribe(userIdentifier, handleUserStateChange);
|
|
56
|
+
.subscribe(userIdentifier, handleUserStateChange, '');
|
|
59
57
|
|
|
60
58
|
return function cleanup() {
|
|
61
59
|
PCore.getMessagingServiceManager().getUserPresence().unsubscribe(userIdentifier, subId);
|
|
62
60
|
};
|
|
63
61
|
}, [userIdentifier, handleUserStateChange]);
|
|
64
|
-
|
|
62
|
+
|
|
65
63
|
return <CosmosAvatar name={userName} imageSrc={imageBlobUrl as React.SetStateAction<any>} status={userState} />;
|
|
66
64
|
}
|
|
67
65
|
|
|
@@ -73,7 +73,7 @@ export default function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}
|
|
|
73
73
|
if (formatter === 'Currency') {
|
|
74
74
|
formattedValue = format(value, formatter.toLowerCase(), theCurrencyOptions);
|
|
75
75
|
} else {
|
|
76
|
-
formattedValue = format(value, pConn.getComponentName()
|
|
76
|
+
formattedValue = format(value, pConn.getComponentName()?.toLowerCase(), theCurrencyOptions);
|
|
77
77
|
}
|
|
78
78
|
|
|
79
79
|
if (displayMode === 'DISPLAY_ONLY') {
|
|
@@ -62,7 +62,7 @@ export default function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}
|
|
|
62
62
|
const theCurrSep = theSymbols.theDigitGroupSeparator;
|
|
63
63
|
|
|
64
64
|
const theCurrencyOptions = getCurrencyOptions(currencyISOCode);
|
|
65
|
-
const formattedValue = format(value, pConn.getComponentName()
|
|
65
|
+
const formattedValue = format(value, pConn.getComponentName()?.toLowerCase(), theCurrencyOptions);
|
|
66
66
|
|
|
67
67
|
let readOnlyProp = {}; // Note: empty if NOT ReadOnly
|
|
68
68
|
|
|
@@ -54,7 +54,7 @@ export default function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}
|
|
|
54
54
|
const helperTextToDisplay = validatemessage || helperText;
|
|
55
55
|
|
|
56
56
|
const theCurrencyOptions = getCurrencyOptions(currencyISOCode);
|
|
57
|
-
const formattedValue = format(value, pConn.getComponentName()
|
|
57
|
+
const formattedValue = format(value, pConn.getComponentName()?.toLowerCase(), theCurrencyOptions);
|
|
58
58
|
|
|
59
59
|
let readOnlyProp = {}; // Note: empty if NOT ReadOnly
|
|
60
60
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import MuiPhoneNumber from 'material-ui-phone-number';
|
|
2
1
|
import { useEffect, useState } from 'react';
|
|
2
|
+
import { MuiTelInput } from 'mui-tel-input';
|
|
3
3
|
|
|
4
4
|
import { getComponentFromMap } from '@pega/react-sdk-components/lib/bridge/helpers/sdk_component_map';
|
|
5
5
|
import { PConnFieldProps } from '@pega/react-sdk-components/lib/types/PConnProps';
|
|
@@ -63,12 +63,12 @@ export default function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}
|
|
|
63
63
|
return (
|
|
64
64
|
<div>
|
|
65
65
|
<Styled{{COMPONENT_CLASS_NAME}}Wrapper>
|
|
66
|
-
<
|
|
66
|
+
<MuiTelInput
|
|
67
67
|
fullWidth
|
|
68
68
|
helperText={helperTextToDisplay}
|
|
69
69
|
placeholder={placeholder ?? ''}
|
|
70
70
|
size='small'
|
|
71
|
-
defaultCountry='
|
|
71
|
+
defaultCountry='US'
|
|
72
72
|
required={required}
|
|
73
73
|
disabled={disabled}
|
|
74
74
|
onChange={onChange}
|
|
@@ -102,13 +102,13 @@ export default function {{COMPONENT_CLASS_NAME}}(props: {{COMPONENT_CLASS_NAME}}
|
|
|
102
102
|
|
|
103
103
|
return (
|
|
104
104
|
<Styled{{COMPONENT_CLASS_NAME}}Wrapper>
|
|
105
|
-
<
|
|
105
|
+
<MuiTelInput
|
|
106
106
|
fullWidth
|
|
107
107
|
variant='outlined'
|
|
108
108
|
helperText={helperTextToDisplay}
|
|
109
109
|
placeholder={placeholder ?? ''}
|
|
110
110
|
size='small'
|
|
111
|
-
defaultCountry='
|
|
111
|
+
defaultCountry='US'
|
|
112
112
|
required={required}
|
|
113
113
|
disabled={disabled}
|
|
114
114
|
onChange={handleChange}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
|
|
2
1
|
import { useState, useEffect } from 'react';
|
|
3
2
|
import {
|
|
4
3
|
CurrencyInput as CosmosCurrency,
|
|
@@ -262,9 +261,8 @@ function PegaDxilMyCurrency(props: PegaDxilMyCurrencyProps) {
|
|
|
262
261
|
});
|
|
263
262
|
}}
|
|
264
263
|
onBlur={(enteredValue) => {
|
|
265
|
-
const parsedValue = enteredValue !== '' ? Number(enteredValue) : enteredValue;
|
|
264
|
+
const parsedValue = enteredValue !== '' ? Number(enteredValue).toString() : enteredValue;
|
|
266
265
|
if (!readOnly && (!value || value !== parsedValue)) {
|
|
267
|
-
// @ts-ignore
|
|
268
266
|
handleEvent(actions, 'changeNblur', propName, parsedValue);
|
|
269
267
|
if (hasSuggestions) {
|
|
270
268
|
pConn.ignoreSuggestion('');
|
|
@@ -88,9 +88,8 @@ function PegaDxilMyDecimal(props: PegaDxilMyDecimalProps) {
|
|
|
88
88
|
}, [validatemessage, hasSuggestions, status]);
|
|
89
89
|
|
|
90
90
|
const { decimalPrecision, currencyDecimalPrecision } = props;
|
|
91
|
-
let numberOfDecimals = parseInt(decimalPrecision, 10);
|
|
91
|
+
let numberOfDecimals: number | undefined = parseInt(decimalPrecision, 10);
|
|
92
92
|
if (Number.isNaN(numberOfDecimals)) {
|
|
93
|
-
// @ts-ignore
|
|
94
93
|
numberOfDecimals = decimalPrecision === '' ? undefined : 2;
|
|
95
94
|
}
|
|
96
95
|
let noOfFractionDigits = currencyDecimalPrecision === 'auto' ? undefined : parseInt(currencyDecimalPrecision, 10);
|
|
@@ -223,15 +222,13 @@ function PegaDxilMyDecimal(props: PegaDxilMyDecimalProps) {
|
|
|
223
222
|
}
|
|
224
223
|
setDecimalValue(enteredValue);
|
|
225
224
|
if (value !== (enteredValue !== '' ? Number(enteredValue) : '')) {
|
|
226
|
-
|
|
227
|
-
handleEvent(actions, 'change', propName, enteredValue !== '' ? Number(enteredValue) : '');
|
|
225
|
+
handleEvent(actions, 'change', propName, enteredValue !== '' ? Number(enteredValue).toString() : '');
|
|
228
226
|
hasValueChange.current = true;
|
|
229
227
|
}
|
|
230
228
|
}}
|
|
231
229
|
onBlur={() => {
|
|
232
230
|
if (!value || hasValueChange.current) {
|
|
233
|
-
|
|
234
|
-
handleEvent(actions, 'blur', propName, decimalValue !== '' ? Number(decimalValue) : '');
|
|
231
|
+
handleEvent(actions, 'blur', propName, decimalValue !== '' ? Number(decimalValue).toString() : '');
|
|
235
232
|
if (hasSuggestions) {
|
|
236
233
|
pConn.ignoreSuggestion("");
|
|
237
234
|
}
|
|
@@ -94,9 +94,8 @@ function PegaDxilMyPercentage(props: PegaDxilMyPercentageProps) {
|
|
|
94
94
|
}
|
|
95
95
|
}, [validatemessage, hasSuggestions, status]);
|
|
96
96
|
|
|
97
|
-
let numberOfDecimals = parseInt(decimalPrecision, 10);
|
|
97
|
+
let numberOfDecimals : number | undefined = parseInt(decimalPrecision, 10);
|
|
98
98
|
if (Number.isNaN(numberOfDecimals)) {
|
|
99
|
-
// @ts-ignore
|
|
100
99
|
numberOfDecimals = decimalPrecision === '' ? undefined : 2;
|
|
101
100
|
}
|
|
102
101
|
|
|
@@ -241,15 +240,13 @@ function PegaDxilMyPercentage(props: PegaDxilMyPercentageProps) {
|
|
|
241
240
|
}
|
|
242
241
|
setPercentageValue(enteredValue);
|
|
243
242
|
if (value !== enteredValue) {
|
|
244
|
-
// @ts-ignore
|
|
245
243
|
handleEvent(actions, 'change', propName, enteredValue);
|
|
246
244
|
hasValueChange.current = true;
|
|
247
245
|
}
|
|
248
246
|
}}
|
|
249
247
|
onBlur={() => {
|
|
250
|
-
const parsedValue = percentageValue !== '' ? Number(percentageValue) : '';
|
|
248
|
+
const parsedValue = percentageValue !== '' ? Number(percentageValue).toString() : '';
|
|
251
249
|
if (!value || hasValueChange.current) {
|
|
252
|
-
// @ts-ignore
|
|
253
250
|
handleEvent(actions, 'blur', propName, parsedValue);
|
|
254
251
|
if (hasSuggestions) {
|
|
255
252
|
pConn.ignoreSuggestion("");
|
|
@@ -497,14 +497,14 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
497
497
|
const pConn = getPConnect();
|
|
498
498
|
const contextName = getPConnect().getContextName();
|
|
499
499
|
const actions = pConn.getActionsApi();
|
|
500
|
-
const [dataApiObj, setDataApiObj] = useState(() => ({}));
|
|
500
|
+
const [dataApiObj, setDataApiObj] = useState(() => ({} as any));
|
|
501
501
|
const [filterValue, setFilterValue] = useState('');
|
|
502
502
|
const [loading, setLoading] = useState(listType !== 'associated');
|
|
503
503
|
// const selected = useMemo(() => menuHelpers.getSelected(items)[0], [items]);
|
|
504
504
|
const [selected, setSelected] = useState();
|
|
505
505
|
const hasMoreResults = useRef(true);
|
|
506
506
|
const inputValueRef = useRef('');
|
|
507
|
-
const displayFieldMeta = useRef(null);
|
|
507
|
+
const displayFieldMeta: any = useRef(null);
|
|
508
508
|
const [actualValue, setActualValue] = useState();
|
|
509
509
|
const [newRecordCreated, setNewRecordCreated] = useState();
|
|
510
510
|
|
|
@@ -645,15 +645,13 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
645
645
|
}
|
|
646
646
|
PCore.getDataApi()
|
|
647
647
|
.init(dataConfig, contextName)
|
|
648
|
-
.then(dataObj => {
|
|
649
|
-
// @ts-ignore
|
|
648
|
+
.then((dataObj: any) => {
|
|
650
649
|
setDataApiObj(dataObj);
|
|
651
650
|
// To avoid calling doSearch if someone types/pastes value before the API call is made
|
|
652
651
|
if (!filterValue)
|
|
653
652
|
doSearch(
|
|
654
653
|
'',
|
|
655
654
|
getDisplayFieldsMetaData(dataConfig.columns),
|
|
656
|
-
// @ts-ignore
|
|
657
655
|
dataObj,
|
|
658
656
|
setItems as any,
|
|
659
657
|
setLoading,
|
|
@@ -679,12 +677,10 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
679
677
|
if (!dataRefMount && !displayMode && listType === 'datapage') {
|
|
680
678
|
PCore.getDataApi()
|
|
681
679
|
.init(dataConfig, contextName)
|
|
682
|
-
.then(dataObj => {
|
|
683
|
-
// @ts-ignore
|
|
680
|
+
.then((dataObj: any) => {
|
|
684
681
|
setDataApiObj(dataObj);
|
|
685
682
|
// To avoid calling doSearch if someone types/pastes value before the API call is made
|
|
686
683
|
if (!filterValue) {
|
|
687
|
-
// @ts-ignore
|
|
688
684
|
if (displayFieldMeta?.current?.key === displayFieldMeta?.current?.primary) {
|
|
689
685
|
const displayItem = {
|
|
690
686
|
id: value,
|
|
@@ -696,7 +692,6 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
696
692
|
doSearch(
|
|
697
693
|
'',
|
|
698
694
|
getDisplayFieldsMetaData(dataConfig.columns),
|
|
699
|
-
// @ts-ignore
|
|
700
695
|
dataObj,
|
|
701
696
|
setItems as any,
|
|
702
697
|
setLoading,
|
|
@@ -716,7 +711,6 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
716
711
|
doSearch(
|
|
717
712
|
'',
|
|
718
713
|
getDisplayFieldsMetaData(dataConfig.columns),
|
|
719
|
-
// @ts-ignore
|
|
720
714
|
dataObj,
|
|
721
715
|
setItems as any,
|
|
722
716
|
setLoading,
|
|
@@ -775,22 +769,16 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
775
769
|
) {
|
|
776
770
|
PCore.getDataApi()
|
|
777
771
|
.init(dataConfig, contextName)
|
|
778
|
-
.then(dataObj => {
|
|
779
|
-
// @ts-ignore
|
|
772
|
+
.then((dataObj: any) => {
|
|
780
773
|
setDataApiObj(dataObj);
|
|
781
|
-
// @ts-ignore
|
|
782
774
|
buildColumnForDisplayValue(dataObj);
|
|
783
775
|
// SET matchPosition to EQUALS to return exact matching record
|
|
784
|
-
// @ts-ignore
|
|
785
776
|
dataObj.matchPosition = 'equals';
|
|
786
|
-
// @ts-ignore
|
|
787
777
|
dataObj
|
|
788
778
|
.fetchData(value)
|
|
789
779
|
.then((displayResponse: { data: Array<never> }) => {
|
|
790
780
|
let columnsWithSetProperty: string | Array<any> = [];
|
|
791
|
-
// @ts-ignore
|
|
792
781
|
if (dataApiObj.columns) {
|
|
793
|
-
// @ts-ignore
|
|
794
782
|
columnsWithSetProperty = dataApiObj.columns
|
|
795
783
|
.filter(
|
|
796
784
|
(col: { setProperty: string }) =>
|
|
@@ -805,12 +793,9 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
805
793
|
const searchedItem = displayResponseData.map((entry: { [x: string]: any }) => {
|
|
806
794
|
const secondaryArr: Array<any> = [];
|
|
807
795
|
const secondaryFieldValues: Array<any> = [];
|
|
808
|
-
// @ts-ignore
|
|
809
796
|
displayFieldMeta.current.secondary.forEach((col: string) => {
|
|
810
|
-
// @ts-ignore
|
|
811
797
|
if (!displayFieldMeta.hidden.includes(col)) secondaryArr.push(entry[col]);
|
|
812
798
|
if (columnsWithSetProperty.includes(col)) {
|
|
813
|
-
// @ts-ignore
|
|
814
799
|
if (dataApiObj.isQueryable) {
|
|
815
800
|
secondaryFieldValues.push(entry[col]);
|
|
816
801
|
} else {
|
|
@@ -819,9 +804,7 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
819
804
|
}
|
|
820
805
|
});
|
|
821
806
|
return {
|
|
822
|
-
// @ts-ignore
|
|
823
807
|
id: entry[displayFieldMeta.current.key],
|
|
824
|
-
// @ts-ignore
|
|
825
808
|
primary: entry[displayFieldMeta.current.primary],
|
|
826
809
|
secondary: secondaryArr,
|
|
827
810
|
secondaryFieldValues
|
|
@@ -832,13 +815,11 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
832
815
|
setSelected(searchedItem[0]);
|
|
833
816
|
setActualValue(value);
|
|
834
817
|
// RESET matchPosition
|
|
835
|
-
// @ts-ignore
|
|
836
818
|
dataObj.matchPosition = dataConfig.matchPosition;
|
|
837
819
|
})
|
|
838
820
|
.catch(() => {
|
|
839
821
|
setActualValue(value);
|
|
840
822
|
// RESET matchPosition
|
|
841
|
-
// @ts-ignore
|
|
842
823
|
dataObj.matchPosition = dataConfig.matchPosition;
|
|
843
824
|
});
|
|
844
825
|
});
|
|
@@ -856,21 +837,17 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
856
837
|
};
|
|
857
838
|
})
|
|
858
839
|
);
|
|
859
|
-
|
|
860
|
-
setSelected(null);
|
|
840
|
+
setSelected(undefined);
|
|
861
841
|
inputValueRef.current = '';
|
|
862
842
|
};
|
|
863
843
|
|
|
864
844
|
const onChangeHandler = (ev: { target: { value: any } }) => {
|
|
865
845
|
if (hasSuggestions) {
|
|
866
|
-
|
|
867
|
-
pConn.ignoreSuggestion();
|
|
846
|
+
pConn.ignoreSuggestion('');
|
|
868
847
|
setStatus(undefined);
|
|
869
848
|
}
|
|
870
849
|
|
|
871
|
-
// @ts-ignore
|
|
872
850
|
dataApiObj.columns = dataConfig.columns;
|
|
873
|
-
// @ts-ignore
|
|
874
851
|
dataApiObj.matchPosition = dataConfig.matchPosition;
|
|
875
852
|
const searchText = ev.target.value;
|
|
876
853
|
inputValueRef.current = searchText;
|
|
@@ -879,15 +856,14 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
879
856
|
clearSelections();
|
|
880
857
|
}
|
|
881
858
|
setFilterValue(searchText);
|
|
882
|
-
// @ts-ignore
|
|
883
859
|
if (listType === 'datapage' && dataApiObj.isQueryable) {
|
|
884
860
|
hasMoreResults.current = true;
|
|
885
861
|
if (searchText.length < 5) {
|
|
886
862
|
searchHandlerThrottled(
|
|
887
863
|
searchText,
|
|
888
|
-
// @ts-ignore
|
|
889
864
|
displayFieldMeta.current,
|
|
890
865
|
dataApiObj,
|
|
866
|
+
// @ts-ignore
|
|
891
867
|
setItems,
|
|
892
868
|
setLoading,
|
|
893
869
|
hasMoreResults
|
|
@@ -895,9 +871,9 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
895
871
|
} else {
|
|
896
872
|
searchHandlerDebounced(
|
|
897
873
|
searchText,
|
|
898
|
-
// @ts-ignore
|
|
899
874
|
displayFieldMeta.current,
|
|
900
875
|
dataApiObj,
|
|
876
|
+
// @ts-ignore
|
|
901
877
|
setItems,
|
|
902
878
|
setLoading,
|
|
903
879
|
hasMoreResults
|
|
@@ -905,14 +881,12 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
905
881
|
}
|
|
906
882
|
} else if (
|
|
907
883
|
listType === 'associated' ||
|
|
908
|
-
// @ts-ignore
|
|
909
884
|
(listType === 'datapage' && dataApiObj?.isQueryable === false)
|
|
910
885
|
) {
|
|
911
886
|
paginateHelperApis.resetIndexes();
|
|
912
887
|
const progressivePaginatedRecords = paginateHelperApis.fetchData(
|
|
913
888
|
inputValueRef.current,
|
|
914
889
|
false,
|
|
915
|
-
// @ts-ignore
|
|
916
890
|
dataApiObj.columns
|
|
917
891
|
);
|
|
918
892
|
setItems(progressivePaginatedRecords);
|
|
@@ -939,21 +913,19 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
939
913
|
|
|
940
914
|
setFilterValue('');
|
|
941
915
|
if (!selected && inputValueRef.current !== '') {
|
|
942
|
-
// @ts-ignore
|
|
943
916
|
if (listType === 'datapage' && dataApiObj.isQueryable) {
|
|
944
917
|
hasMoreResults.current = true;
|
|
945
918
|
searchHandlerThrottled(
|
|
946
919
|
'',
|
|
947
|
-
// @ts-ignore
|
|
948
920
|
displayFieldMeta.current,
|
|
949
921
|
dataApiObj,
|
|
922
|
+
// @ts-ignore
|
|
950
923
|
setItems,
|
|
951
924
|
setLoading,
|
|
952
925
|
hasMoreResults
|
|
953
926
|
);
|
|
954
927
|
} else if (
|
|
955
928
|
listType === 'associated' ||
|
|
956
|
-
// @ts-ignore
|
|
957
929
|
(listType === 'datapage' && dataApiObj?.isQueryable === false)
|
|
958
930
|
) {
|
|
959
931
|
paginateHelperApis.resetIndexes();
|
|
@@ -976,7 +948,6 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
976
948
|
// @ts-ignore
|
|
977
949
|
setSelected(menuHelpers.getSelected(updatedItems)[0]);
|
|
978
950
|
// const { id: itemId } = menuHelpers.getSelected(updatedItems)[0];
|
|
979
|
-
// @ts-ignore
|
|
980
951
|
const assocProp = pConn.getStateProps().value;
|
|
981
952
|
const propValue = setValueToAssocProp(
|
|
982
953
|
assocProp,
|
|
@@ -1009,7 +980,6 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
1009
980
|
const loadMore = () => {
|
|
1010
981
|
if (
|
|
1011
982
|
(listType === 'associated' ||
|
|
1012
|
-
// @ts-ignore
|
|
1013
983
|
(listType === 'datapage' && dataApiObj?.isQueryable === false)) &&
|
|
1014
984
|
paginateHelperApis.hasMoreResults(inputValueRef.current)
|
|
1015
985
|
) {
|
|
@@ -1019,23 +989,18 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
1019
989
|
progressivePaginatedRecords = removeDuplicates(previousItems, progressivePaginatedRecords);
|
|
1020
990
|
return [...previousItems, ...progressivePaginatedRecords];
|
|
1021
991
|
});
|
|
1022
|
-
// @ts-ignore
|
|
1023
992
|
} else if (listType === 'datapage' && dataApiObj.isQueryable && hasMoreResults.current) {
|
|
1024
993
|
setLoading(true);
|
|
1025
994
|
dataApiObj
|
|
1026
|
-
// @ts-ignore
|
|
1027
995
|
.fetchPaginatedData(inputValueRef.current)
|
|
1028
996
|
.then((response: { pageSize: number; data: Array<never> }) => {
|
|
1029
997
|
setLoading(false);
|
|
1030
|
-
// @ts-ignore
|
|
1031
998
|
if (response.pageSize === 0 || response.pageSize < dataApiObj.pageSize) {
|
|
1032
999
|
hasMoreResults.current = false;
|
|
1033
1000
|
}
|
|
1034
1001
|
const listObjData = response.data || [];
|
|
1035
1002
|
let columnsWithSetProperty: string | Array<any> = [];
|
|
1036
|
-
// @ts-ignore
|
|
1037
1003
|
if (dataApiObj.columns) {
|
|
1038
|
-
// @ts-ignore
|
|
1039
1004
|
columnsWithSetProperty = dataApiObj.columns
|
|
1040
1005
|
.filter(
|
|
1041
1006
|
(col: { setProperty: string }) =>
|
|
@@ -1049,12 +1014,9 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
1049
1014
|
const searchedItems = listObjData.map((entry: { [x: string]: any }) => {
|
|
1050
1015
|
const secondaryArr: Array<any> = [];
|
|
1051
1016
|
const secondaryFieldValues: Array<any> = [];
|
|
1052
|
-
// @ts-ignore
|
|
1053
1017
|
displayFieldMeta.current.secondary.forEach((col: string) => {
|
|
1054
|
-
// @ts-ignore
|
|
1055
1018
|
if (!displayFieldMeta.current.hidden.includes(col)) secondaryArr.push(entry[col]);
|
|
1056
1019
|
if (columnsWithSetProperty.includes(col)) {
|
|
1057
|
-
// @ts-ignore
|
|
1058
1020
|
if (dataApiObj.isQueryable) {
|
|
1059
1021
|
secondaryFieldValues.push(entry[col]);
|
|
1060
1022
|
} else {
|
|
@@ -1063,9 +1025,7 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
1063
1025
|
}
|
|
1064
1026
|
});
|
|
1065
1027
|
return {
|
|
1066
|
-
// @ts-ignore
|
|
1067
1028
|
id: entry[displayFieldMeta.current.key],
|
|
1068
|
-
// @ts-ignore
|
|
1069
1029
|
primary: entry[displayFieldMeta.current.primary],
|
|
1070
1030
|
secondary: secondaryArr,
|
|
1071
1031
|
secondaryFieldValues
|
|
@@ -1076,7 +1036,6 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
1076
1036
|
})
|
|
1077
1037
|
.catch(() => {
|
|
1078
1038
|
setLoading(false);
|
|
1079
|
-
// @ts-ignore
|
|
1080
1039
|
dataApiObj.pageSize -= 1;
|
|
1081
1040
|
});
|
|
1082
1041
|
}
|
|
@@ -1160,7 +1119,6 @@ function PegaDxilMySearchbox(props: PegaDxilMySearchboxProps) {
|
|
|
1160
1119
|
selected: item.items ? undefined : !!item.selected || item.id === selected?.id
|
|
1161
1120
|
})),
|
|
1162
1121
|
onItemClick: selectItem,
|
|
1163
|
-
// @ts-ignore
|
|
1164
1122
|
emptyText: pConn.getLocalizedValue('No items'),
|
|
1165
1123
|
loading,
|
|
1166
1124
|
loadMore,
|
|
@@ -187,7 +187,7 @@ export const updatePropertiesForNewRecord = (
|
|
|
187
187
|
dataObj
|
|
188
188
|
.fetchData(newCaseId)
|
|
189
189
|
// @ts-ignore
|
|
190
|
-
.then(displayResponse => {
|
|
190
|
+
.then((displayResponse: any) => {
|
|
191
191
|
let columnsWithSetProperty = [];
|
|
192
192
|
if (dataApiObj.columns) {
|
|
193
193
|
columnsWithSetProperty = dataApiObj.columns
|
|
@@ -22,8 +22,8 @@ function Avatar(props: PegaDxilMyDetailsAvatarProps) {
|
|
|
22
22
|
// TODO Below if conditions can be removed once we have apis to get worklist/mywork info
|
|
23
23
|
// This is non CaseView case (Dashboard, MyWork etc)
|
|
24
24
|
if (!metaObj) {
|
|
25
|
-
userName = PCore.getEnvironmentInfo().getOperatorName();
|
|
26
|
-
userIdentifier = PCore.getEnvironmentInfo().getOperatorIdentifier();
|
|
25
|
+
userName = PCore.getEnvironmentInfo().getOperatorName() ?? "";
|
|
26
|
+
userIdentifier = PCore.getEnvironmentInfo().getOperatorIdentifier() ?? "";
|
|
27
27
|
} else {
|
|
28
28
|
userName = metaObj.name;
|
|
29
29
|
userIdentifier = metaObj.ID;
|
|
@@ -46,22 +46,20 @@ function Avatar(props: PegaDxilMyDetailsAvatarProps) {
|
|
|
46
46
|
const currentState = PCore.getMessagingServiceManager().getUserPresence().getUserState(userIdentifier);
|
|
47
47
|
const [userState, setUserState]: any = useState(currentState === 'online' ? 'active' : 'inactive');
|
|
48
48
|
|
|
49
|
-
|
|
50
|
-
const handleUserStateChange = ({ state }) => {
|
|
49
|
+
const handleUserStateChange = ({ state }: any) => {
|
|
51
50
|
setUserState(state === 'online' ? 'active' : 'inactive');
|
|
52
51
|
};
|
|
53
52
|
|
|
54
53
|
useEffect(() => {
|
|
55
54
|
const subId = PCore.getMessagingServiceManager()
|
|
56
55
|
.getUserPresence()
|
|
57
|
-
|
|
58
|
-
.subscribe(userIdentifier, handleUserStateChange);
|
|
56
|
+
.subscribe(userIdentifier, handleUserStateChange, '');
|
|
59
57
|
|
|
60
58
|
return function cleanup() {
|
|
61
59
|
PCore.getMessagingServiceManager().getUserPresence().unsubscribe(userIdentifier, subId);
|
|
62
60
|
};
|
|
63
61
|
}, [userIdentifier, handleUserStateChange]);
|
|
64
|
-
|
|
62
|
+
|
|
65
63
|
return <CosmosAvatar name={userName} imageSrc={imageBlobUrl as React.SetStateAction<any>} status={userState} />;
|
|
66
64
|
}
|
|
67
65
|
|
|
@@ -22,8 +22,8 @@ function Avatar(props: PegaDxilMyTwoColumnDetailsAvatarProps) {
|
|
|
22
22
|
// TODO Below if conditions can be removed once we have apis to get worklist/mywork info
|
|
23
23
|
// This is non CaseView case (Dashboard, MyWork etc)
|
|
24
24
|
if (!metaObj) {
|
|
25
|
-
userName = PCore.getEnvironmentInfo().getOperatorName();
|
|
26
|
-
userIdentifier = PCore.getEnvironmentInfo().getOperatorIdentifier();
|
|
25
|
+
userName = PCore.getEnvironmentInfo().getOperatorName() ?? "";
|
|
26
|
+
userIdentifier = PCore.getEnvironmentInfo().getOperatorIdentifier() ?? "";
|
|
27
27
|
} else {
|
|
28
28
|
userName = metaObj.name;
|
|
29
29
|
userIdentifier = metaObj.ID;
|
|
@@ -46,22 +46,20 @@ function Avatar(props: PegaDxilMyTwoColumnDetailsAvatarProps) {
|
|
|
46
46
|
const currentState = PCore.getMessagingServiceManager().getUserPresence().getUserState(userIdentifier);
|
|
47
47
|
const [userState, setUserState]: any = useState(currentState === 'online' ? 'active' : 'inactive');
|
|
48
48
|
|
|
49
|
-
|
|
50
|
-
const handleUserStateChange = ({ state }) => {
|
|
49
|
+
const handleUserStateChange = ({ state }: any) => {
|
|
51
50
|
setUserState(state === 'online' ? 'active' : 'inactive');
|
|
52
51
|
};
|
|
53
52
|
|
|
54
53
|
useEffect(() => {
|
|
55
54
|
const subId = PCore.getMessagingServiceManager()
|
|
56
55
|
.getUserPresence()
|
|
57
|
-
|
|
58
|
-
.subscribe(userIdentifier, handleUserStateChange);
|
|
56
|
+
.subscribe(userIdentifier, handleUserStateChange, '');
|
|
59
57
|
|
|
60
58
|
return function cleanup() {
|
|
61
59
|
PCore.getMessagingServiceManager().getUserPresence().unsubscribe(userIdentifier, subId);
|
|
62
60
|
};
|
|
63
61
|
}, [userIdentifier, handleUserStateChange]);
|
|
64
|
-
|
|
62
|
+
|
|
65
63
|
return <CosmosAvatar name={userName} imageSrc={imageBlobUrl as React.SetStateAction<any>} status={userState} />;
|
|
66
64
|
}
|
|
67
65
|
|
|
@@ -22,8 +22,8 @@ function Avatar(props: PegaDxilMyPageCaseWidgetAvatarProps) {
|
|
|
22
22
|
// TODO Below if conditions can be removed once we have apis to get worklist/mywork info
|
|
23
23
|
// This is non CaseView case (Dashboard, MyWork etc)
|
|
24
24
|
if (!metaObj) {
|
|
25
|
-
userName = PCore.getEnvironmentInfo().getOperatorName();
|
|
26
|
-
userIdentifier = PCore.getEnvironmentInfo().getOperatorIdentifier();
|
|
25
|
+
userName = PCore.getEnvironmentInfo().getOperatorName() ?? "";
|
|
26
|
+
userIdentifier = PCore.getEnvironmentInfo().getOperatorIdentifier() ?? "";
|
|
27
27
|
} else {
|
|
28
28
|
userName = metaObj.name;
|
|
29
29
|
userIdentifier = metaObj.ID;
|
|
@@ -46,22 +46,20 @@ function Avatar(props: PegaDxilMyPageCaseWidgetAvatarProps) {
|
|
|
46
46
|
const currentState = PCore.getMessagingServiceManager().getUserPresence().getUserState(userIdentifier);
|
|
47
47
|
const [userState, setUserState]: any = useState(currentState === 'online' ? 'active' : 'inactive');
|
|
48
48
|
|
|
49
|
-
|
|
50
|
-
const handleUserStateChange = ({ state }) => {
|
|
49
|
+
const handleUserStateChange = ({ state }: any) => {
|
|
51
50
|
setUserState(state === 'online' ? 'active' : 'inactive');
|
|
52
51
|
};
|
|
53
52
|
|
|
54
53
|
useEffect(() => {
|
|
55
54
|
const subId = PCore.getMessagingServiceManager()
|
|
56
55
|
.getUserPresence()
|
|
57
|
-
|
|
58
|
-
.subscribe(userIdentifier, handleUserStateChange);
|
|
56
|
+
.subscribe(userIdentifier, handleUserStateChange, '');
|
|
59
57
|
|
|
60
58
|
return function cleanup() {
|
|
61
59
|
PCore.getMessagingServiceManager().getUserPresence().unsubscribe(userIdentifier, subId);
|
|
62
60
|
};
|
|
63
61
|
}, [userIdentifier, handleUserStateChange]);
|
|
64
|
-
|
|
62
|
+
|
|
65
63
|
return <CosmosAvatar name={userName} imageSrc={imageBlobUrl as React.SetStateAction<any>} status={userState} />;
|
|
66
64
|
}
|
|
67
65
|
|
package/tests/assets/sdk-r/components/createAll/custom-sdk/field/Pega_DXIL_MyCurrency/index.tsx
CHANGED
|
@@ -62,7 +62,7 @@ export default function PegaDxilMyCurrency(props: PegaDxilMyCurrencyProps) {
|
|
|
62
62
|
const theCurrSep = theSymbols.theDigitGroupSeparator;
|
|
63
63
|
|
|
64
64
|
const theCurrencyOptions = getCurrencyOptions(currencyISOCode);
|
|
65
|
-
const formattedValue = format(value, pConn.getComponentName()
|
|
65
|
+
const formattedValue = format(value, pConn.getComponentName()?.toLowerCase(), theCurrencyOptions);
|
|
66
66
|
|
|
67
67
|
let readOnlyProp = {}; // Note: empty if NOT ReadOnly
|
|
68
68
|
|
package/tests/assets/sdk-r/components/createAll/custom-sdk/field/Pega_DXIL_MyDecimal/index.tsx
CHANGED
|
@@ -73,7 +73,7 @@ export default function PegaDxilMyDecimal(props: PegaDxilMyDecimalProps) {
|
|
|
73
73
|
if (formatter === 'Currency') {
|
|
74
74
|
formattedValue = format(value, formatter.toLowerCase(), theCurrencyOptions);
|
|
75
75
|
} else {
|
|
76
|
-
formattedValue = format(value, pConn.getComponentName()
|
|
76
|
+
formattedValue = format(value, pConn.getComponentName()?.toLowerCase(), theCurrencyOptions);
|
|
77
77
|
}
|
|
78
78
|
|
|
79
79
|
if (displayMode === 'DISPLAY_ONLY') {
|
package/tests/assets/sdk-r/components/createAll/custom-sdk/field/Pega_DXIL_MyPercentage/index.tsx
CHANGED
|
@@ -54,7 +54,7 @@ export default function PegaDxilMyPercentage(props: PegaDxilMyPercentageProps) {
|
|
|
54
54
|
const helperTextToDisplay = validatemessage || helperText;
|
|
55
55
|
|
|
56
56
|
const theCurrencyOptions = getCurrencyOptions(currencyISOCode);
|
|
57
|
-
const formattedValue = format(value, pConn.getComponentName()
|
|
57
|
+
const formattedValue = format(value, pConn.getComponentName()?.toLowerCase(), theCurrencyOptions);
|
|
58
58
|
|
|
59
59
|
let readOnlyProp = {}; // Note: empty if NOT ReadOnly
|
|
60
60
|
|
|
@@ -49,7 +49,7 @@ describe('create build and delete local override', () => {
|
|
|
49
49
|
// expect(stdout).toContain(`${newFileNameConstellation} schema is valid`);
|
|
50
50
|
// expect(stdout).toContain('Compiled successfully.');
|
|
51
51
|
// done();
|
|
52
|
-
},
|
|
52
|
+
}, 30000);
|
|
53
53
|
|
|
54
54
|
it('npm run delete Local override', async () => {
|
|
55
55
|
const fileName = 'AutoComplete';
|
|
@@ -165,7 +165,7 @@ describe('create publish and deleteAll local', () => {
|
|
|
165
165
|
expect(isInMap).toBeTruthy();
|
|
166
166
|
|
|
167
167
|
// done();
|
|
168
|
-
},
|
|
168
|
+
}, 100000);
|
|
169
169
|
|
|
170
170
|
it('npm run deleteAll Local verify not in map custom', async () => {
|
|
171
171
|
const script = `npm run deleteAll Local custom Y --prefix ../../..`;
|
|
@@ -12,7 +12,7 @@ describe('override publish and deleteAll local override', () => {
|
|
|
12
12
|
// console.log(stdout);
|
|
13
13
|
expect(stdout).not.toBeNull();
|
|
14
14
|
expect(stderr).not.toBeNull();
|
|
15
|
-
}
|
|
15
|
+
});
|
|
16
16
|
|
|
17
17
|
it('npm run override auto complete override', async () => {
|
|
18
18
|
const fileName = 'AutoComplete';
|