@veloceapps/sdk 7.0.2-0 → 7.0.2-10
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/cms/modules/federated/federated.component.d.ts +1 -0
- package/cms/utils/ui-definition.utils.d.ts +0 -1
- package/cms/vendor-map.d.ts +2 -0
- package/core/utils/line-item.utils.d.ts +2 -0
- package/esm2020/cms/modules/federated/federated.component.mjs +13 -2
- package/esm2020/cms/utils/ui-definition.utils.mjs +3 -17
- package/esm2020/core/utils/line-item.utils.mjs +22 -10
- package/esm2020/src/components/header/header.component.mjs +15 -3
- package/fesm2015/veloceapps-sdk-cms.mjs +15 -19
- package/fesm2015/veloceapps-sdk-cms.mjs.map +1 -1
- package/fesm2015/veloceapps-sdk-core.mjs +24 -10
- package/fesm2015/veloceapps-sdk-core.mjs.map +1 -1
- package/fesm2015/veloceapps-sdk.mjs +15 -2
- package/fesm2015/veloceapps-sdk.mjs.map +1 -1
- package/fesm2020/veloceapps-sdk-cms.mjs +15 -19
- package/fesm2020/veloceapps-sdk-cms.mjs.map +1 -1
- package/fesm2020/veloceapps-sdk-core.mjs +24 -10
- package/fesm2020/veloceapps-sdk-core.mjs.map +1 -1
- package/fesm2020/veloceapps-sdk.mjs +14 -2
- package/fesm2020/veloceapps-sdk.mjs.map +1 -1
- package/package.json +1 -1
@@ -9,7 +9,7 @@ import { ToastType, LetDirectiveModule, ErrorTooltipModule, HiddenTextTooltipMod
|
|
9
9
|
import * as i5 from '@veloceapps/sdk/cms';
|
10
10
|
import { FlowAction, extractElementMetadata, extendElementMetadata, PreviewModule, OpenDocGenAction, LauncherModule } from '@veloceapps/sdk/cms';
|
11
11
|
import * as i1$1 from '@veloceapps/sdk/core';
|
12
|
-
import { RuntimeOperation, generateModifiedAssetsMap, SdkCoreModule } from '@veloceapps/sdk/core';
|
12
|
+
import { isLineItemModified, getOriginParent, RuntimeOperation, generateModifiedAssetsMap, SdkCoreModule } from '@veloceapps/sdk/core';
|
13
13
|
import * as i3$1 from 'primeng/button';
|
14
14
|
import { ButtonModule } from 'primeng/button';
|
15
15
|
import * as i1 from 'primeng/dynamicdialog';
|
@@ -1076,7 +1076,19 @@ class FlowHeaderComponent {
|
|
1076
1076
|
return combineLatest([
|
1077
1077
|
this.flowConfiguration.get(),
|
1078
1078
|
this.integrationState.state$.pipe(map(state => state.modifiedAssets), distinctUntilChanged()),
|
1079
|
-
]).pipe(map(([lineItems, modifiedAssets]) =>
|
1079
|
+
]).pipe(map(([lineItems, modifiedAssets]) => {
|
1080
|
+
const currentTerms = lineItems.reduce((acc, li) => {
|
1081
|
+
const assetId = li.assetId || li.openOrderLineItemId;
|
1082
|
+
const isModified = isLineItemModified(li);
|
1083
|
+
const currentTerm = getOriginParent(lineItems, li) ?? li;
|
1084
|
+
if (isModified || (assetId && modifiedAssets?.[assetId])) {
|
1085
|
+
acc.push(currentTerm);
|
1086
|
+
}
|
1087
|
+
return acc;
|
1088
|
+
}, []);
|
1089
|
+
const uniqCurrentTerms = currentTerms.filter((value, index, array) => array.indexOf(value) === index);
|
1090
|
+
return uniqCurrentTerms;
|
1091
|
+
}));
|
1080
1092
|
}
|
1081
1093
|
getAssets$() {
|
1082
1094
|
return this.flowConfiguration
|