@sapui5/sap.fe.core 1.95.0 → 1.98.0
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 +5 -5
- package/src/sap/fe/core/.library +1 -1
- package/src/sap/fe/core/AnnotationHelper.js +3 -3
- package/src/sap/fe/core/AppComponent.js +9 -44
- package/src/sap/fe/core/AppStateHandler.js +2 -2
- package/src/sap/fe/core/BaseController.js +1 -1
- package/src/sap/fe/core/BusyLocker.js +13 -1
- package/src/sap/fe/core/CommonUtils.js +129 -219
- package/src/sap/fe/core/ExtensionAPI.js +14 -6
- package/src/sap/fe/core/PageController.js +9 -35
- package/src/sap/fe/core/RouterProxy.js +79 -75
- package/src/sap/fe/core/Synchronization.js +1 -1
- package/src/sap/fe/core/TemplateComponent.js +16 -7
- package/src/sap/fe/core/TemplateModel.js +1 -1
- package/src/sap/fe/core/TransactionHelper.js +183 -65
- package/src/sap/fe/core/actions/draft.js +50 -23
- package/src/sap/fe/core/actions/messageHandling.js +86 -7
- package/src/sap/fe/core/actions/nonDraft.js +1 -1
- package/src/sap/fe/core/actions/operations.js +75 -33
- package/src/sap/fe/core/actions/sticky.js +1 -1
- package/src/sap/fe/core/controllerextensions/ControllerExtensionMetadata.js +1 -1
- package/src/sap/fe/core/controllerextensions/EditFlow.js +276 -122
- package/src/sap/fe/core/controllerextensions/IntentBasedNavigation.js +1 -1
- package/src/sap/fe/core/controllerextensions/InternalEditFlow.js +14 -6
- package/src/sap/fe/core/controllerextensions/InternalIntentBasedNavigation.js +90 -46
- package/src/sap/fe/core/controllerextensions/InternalRouting.js +234 -232
- package/src/sap/fe/core/controllerextensions/KPIManagement.js +539 -209
- package/src/sap/fe/core/controllerextensions/KPIManagement.ts +550 -213
- package/src/sap/fe/core/controllerextensions/MassEdit.js +79 -0
- package/src/sap/fe/core/controllerextensions/MessageHandler.js +227 -103
- package/src/sap/fe/core/controllerextensions/PageReady.js +2 -2
- package/src/sap/fe/core/controllerextensions/PageReady.ts +3 -7
- package/src/sap/fe/core/controllerextensions/Paginator.js +38 -12
- package/src/sap/fe/core/controllerextensions/Placeholder.js +16 -19
- package/src/sap/fe/core/controllerextensions/Routing.js +17 -2
- package/src/sap/fe/core/controllerextensions/RoutingListener.js +1 -1
- package/src/sap/fe/core/controllerextensions/Share.js +20 -7
- package/src/sap/fe/core/controllerextensions/SideEffects.js +8 -9
- package/src/sap/fe/core/controllerextensions/SideEffects.ts +19 -17
- package/src/sap/fe/core/controllerextensions/ViewState.js +54 -9
- package/src/sap/fe/core/controls/ActionParameterDialog.fragment.xml +40 -34
- package/src/sap/fe/core/controls/ActionParameterDialogValueHelp.fragment.xml +35 -0
- package/src/sap/fe/core/controls/CommandExecution.js +1 -1
- package/src/sap/fe/core/controls/ConditionalWrapper.js +1 -1
- package/src/sap/fe/core/controls/CustomQuickViewPage.js +110 -109
- package/src/sap/fe/core/controls/DataLossOrDraftDiscard/DataLossOrDraftDiscardHandler.js +7 -4
- package/src/sap/fe/core/controls/FieldWrapper.js +10 -4
- package/src/sap/fe/core/controls/FilterBar.js +1 -1
- package/src/sap/fe/core/controls/FormElementWrapper.js +1 -6
- package/src/sap/fe/core/controls/MultiValueParameterDelegate.js +45 -0
- package/src/sap/fe/core/controls/NonComputedVisibleKeyFieldsDialog.fragment.xml +1 -1
- package/src/sap/fe/core/controls/filterbar/FilterContainer.js +1 -1
- package/src/sap/fe/core/controls/filterbar/VisualFilter.js +1 -1
- package/src/sap/fe/core/controls/filterbar/VisualFilterContainer.js +1 -1
- package/src/sap/fe/core/controls/filterbar/utils/VisualFilterUtils.js +1 -1
- package/src/sap/fe/core/controls/massEdit/MassEditDialog.fragment.xml +106 -0
- package/src/sap/fe/core/controls/massEdit/MassEditHandlers.js +78 -0
- package/src/sap/fe/core/converters/ConverterContext.js +13 -1
- package/src/sap/fe/core/converters/ConverterContext.ts +10 -0
- package/src/sap/fe/core/converters/ManifestSettings.js +2 -1
- package/src/sap/fe/core/converters/ManifestSettings.ts +7 -1
- package/src/sap/fe/core/converters/ManifestWrapper.js +18 -7
- package/src/sap/fe/core/converters/ManifestWrapper.ts +15 -6
- package/src/sap/fe/core/converters/MetaModelConverter.js +920 -882
- package/src/sap/fe/core/converters/MetaModelConverter.ts +829 -853
- package/src/sap/fe/core/converters/annotations/DataField.js +54 -4
- package/src/sap/fe/core/converters/annotations/DataField.ts +53 -3
- package/src/sap/fe/core/converters/common/AnnotationConverter.js +83 -48
- package/src/sap/fe/core/converters/controls/Common/Action.js +15 -3
- package/src/sap/fe/core/converters/controls/Common/Action.ts +12 -3
- package/src/sap/fe/core/converters/controls/Common/Chart.js +1 -3
- package/src/sap/fe/core/converters/controls/Common/Chart.ts +0 -2
- package/src/sap/fe/core/converters/controls/Common/Form.js +68 -21
- package/src/sap/fe/core/converters/controls/Common/Form.ts +60 -16
- package/src/sap/fe/core/converters/controls/Common/KPI.js +331 -248
- package/src/sap/fe/core/converters/controls/Common/KPI.ts +355 -287
- package/src/sap/fe/core/converters/controls/Common/Table.js +426 -332
- package/src/sap/fe/core/converters/controls/Common/Table.ts +516 -383
- package/src/sap/fe/core/converters/controls/Common/table/StandardActions.js +468 -0
- package/src/sap/fe/core/converters/controls/Common/table/StandardActions.ts +609 -0
- package/src/sap/fe/core/converters/controls/ListReport/FilterBar.js +30 -13
- package/src/sap/fe/core/converters/controls/ListReport/FilterBar.ts +31 -12
- package/src/sap/fe/core/converters/controls/ListReport/VisualFilters.js +2 -2
- package/src/sap/fe/core/converters/controls/ListReport/VisualFilters.ts +1 -1
- package/src/sap/fe/core/converters/controls/ObjectPage/SubSection.js +15 -7
- package/src/sap/fe/core/converters/controls/ObjectPage/SubSection.ts +27 -6
- package/src/sap/fe/core/converters/helpers/Aggregation.js +8 -1
- package/src/sap/fe/core/converters/helpers/Aggregation.ts +9 -1
- package/src/sap/fe/core/converters/helpers/BindingHelper.js +3 -2
- package/src/sap/fe/core/converters/helpers/BindingHelper.ts +2 -2
- package/src/sap/fe/core/converters/helpers/ID.js +9 -1
- package/src/sap/fe/core/converters/helpers/ID.ts +6 -2
- package/src/sap/fe/core/converters/helpers/IssueManager.js +7 -5
- package/src/sap/fe/core/converters/helpers/IssueManager.ts +6 -4
- package/src/sap/fe/core/converters/objectPage/HeaderAndFooterAction.js +2 -2
- package/src/sap/fe/core/converters/objectPage/HeaderAndFooterAction.ts +1 -1
- package/src/sap/fe/core/converters/templates/ListReportConverter.js +34 -4
- package/src/sap/fe/core/converters/templates/ListReportConverter.ts +36 -7
- package/src/sap/fe/core/converters/templates/ObjectPageConverter.js +2 -5
- package/src/sap/fe/core/converters/templates/ObjectPageConverter.ts +1 -2
- package/src/sap/fe/core/designtime/AppComponent.designtime.js +11 -2
- package/src/sap/fe/core/formatters/FPMFormatter.js +1 -1
- package/src/sap/fe/core/formatters/FPMFormatter.ts +8 -3
- package/src/sap/fe/core/formatters/TableFormatter.js +27 -4
- package/src/sap/fe/core/formatters/TableFormatter.ts +20 -3
- package/src/sap/fe/core/formatters/ValueFormatter.js +30 -5
- package/src/sap/fe/core/formatters/ValueFormatter.ts +25 -3
- package/src/sap/fe/core/fpm/Component.js +2 -2
- package/src/sap/fe/core/helpers/AppStartupHelper.js +359 -0
- package/src/sap/fe/core/helpers/AppStartupHelper.ts +388 -0
- package/src/sap/fe/core/helpers/BindingExpression.js +199 -111
- package/src/sap/fe/core/helpers/BindingExpression.ts +193 -102
- package/src/sap/fe/core/helpers/DynamicAnnotationPathHelper.js +1 -1
- package/src/sap/fe/core/helpers/EditState.js +1 -1
- package/src/sap/fe/core/helpers/ExcelFormatHelper.js +1 -3
- package/src/sap/fe/core/helpers/FPMHelper.js +1 -1
- package/src/sap/fe/core/helpers/KeepAliveHelper.js +211 -0
- package/src/sap/fe/core/helpers/KeepAliveHelper.ts +202 -0
- package/src/sap/fe/core/helpers/KeepAliveRefreshTypes.js +32 -0
- package/src/sap/fe/core/helpers/KeepAliveRefreshTypes.ts +36 -0
- package/src/sap/fe/core/helpers/MassEditHelper.js +678 -0
- package/src/sap/fe/core/helpers/ModelHelper.js +64 -1
- package/src/sap/fe/core/helpers/PasteHelper.js +7 -1
- package/src/sap/fe/core/helpers/SemanticDateOperators.js +1 -1
- package/src/sap/fe/core/helpers/SemanticKeyHelper.js +1 -1
- package/src/sap/fe/core/helpers/StableIdHelper.js +2 -2
- package/src/sap/fe/core/helpers/StableIdHelper.ts +1 -1
- package/src/sap/fe/core/library.js +28 -2
- package/src/sap/fe/core/library.support.js +10 -4
- package/src/sap/fe/core/manifestMerger/ChangePageConfiguration.js +62 -0
- package/src/sap/fe/core/manifestMerger/ChangePageConfiguration.ts +66 -0
- package/src/sap/fe/core/messagebundle.properties +67 -3
- package/src/sap/fe/core/messagebundle_ar.properties +40 -3
- package/src/sap/fe/core/messagebundle_bg.properties +40 -3
- package/src/sap/fe/core/messagebundle_ca.properties +41 -4
- package/src/sap/fe/core/messagebundle_cs.properties +41 -4
- package/src/sap/fe/core/messagebundle_cy.properties +40 -3
- package/src/sap/fe/core/messagebundle_da.properties +40 -3
- package/src/sap/fe/core/messagebundle_de.properties +40 -3
- package/src/sap/fe/core/messagebundle_el.properties +40 -3
- package/src/sap/fe/core/messagebundle_en.properties +37 -0
- package/src/sap/fe/core/messagebundle_en_GB.properties +37 -0
- package/src/sap/fe/core/messagebundle_en_US_sappsd.properties +37 -0
- package/src/sap/fe/core/messagebundle_en_US_saprigi.properties +46 -2
- package/src/sap/fe/core/messagebundle_en_US_saptrc.properties +44 -0
- package/src/sap/fe/core/messagebundle_es.properties +40 -3
- package/src/sap/fe/core/messagebundle_es_MX.properties +41 -4
- package/src/sap/fe/core/messagebundle_et.properties +40 -3
- package/src/sap/fe/core/messagebundle_fi.properties +40 -3
- package/src/sap/fe/core/messagebundle_fr.properties +41 -4
- package/src/sap/fe/core/messagebundle_fr_CA.properties +40 -3
- package/src/sap/fe/core/messagebundle_hi.properties +40 -3
- package/src/sap/fe/core/messagebundle_hr.properties +40 -3
- package/src/sap/fe/core/messagebundle_hu.properties +41 -4
- package/src/sap/fe/core/messagebundle_id.properties +42 -5
- package/src/sap/fe/core/messagebundle_it.properties +40 -3
- package/src/sap/fe/core/messagebundle_iw.properties +40 -3
- package/src/sap/fe/core/messagebundle_ja.properties +49 -12
- package/src/sap/fe/core/messagebundle_kk.properties +40 -3
- package/src/sap/fe/core/messagebundle_ko.properties +40 -3
- package/src/sap/fe/core/messagebundle_lt.properties +40 -3
- package/src/sap/fe/core/messagebundle_lv.properties +40 -3
- package/src/sap/fe/core/messagebundle_ms.properties +40 -3
- package/src/sap/fe/core/messagebundle_nl.properties +40 -3
- package/src/sap/fe/core/messagebundle_no.properties +40 -3
- package/src/sap/fe/core/messagebundle_pl.properties +40 -3
- package/src/sap/fe/core/messagebundle_pt.properties +42 -5
- package/src/sap/fe/core/messagebundle_pt_PT.properties +40 -3
- package/src/sap/fe/core/messagebundle_ro.properties +40 -3
- package/src/sap/fe/core/messagebundle_ru.properties +40 -3
- package/src/sap/fe/core/messagebundle_sh.properties +40 -3
- package/src/sap/fe/core/messagebundle_sk.properties +40 -3
- package/src/sap/fe/core/messagebundle_sl.properties +40 -3
- package/src/sap/fe/core/messagebundle_sv.properties +41 -4
- package/src/sap/fe/core/messagebundle_th.properties +40 -3
- package/src/sap/fe/core/messagebundle_tr.properties +40 -3
- package/src/sap/fe/core/messagebundle_uk.properties +40 -3
- package/src/sap/fe/core/messagebundle_vi.properties +40 -3
- package/src/sap/fe/core/messagebundle_zh_CN.properties +40 -3
- package/src/sap/fe/core/messagebundle_zh_TW.properties +40 -3
- package/src/sap/fe/core/services/AsyncComponentServiceFactory.js +1 -1
- package/src/sap/fe/core/services/CacheHandlerServiceFactory.js +1 -1
- package/src/sap/fe/core/services/EnvironmentServiceFactory.js +4 -3
- package/src/sap/fe/core/services/EnvironmentServiceFactory.ts +3 -0
- package/src/sap/fe/core/services/NavigationServiceFactory.js +1 -1
- package/src/sap/fe/core/services/ResourceModelServiceFactory.js +1 -1
- package/src/sap/fe/core/services/RoutingServiceFactory.js +98 -328
- package/src/sap/fe/core/services/ShellServicesFactory.js +31 -2
- package/src/sap/fe/core/services/ShellServicesFactory.ts +30 -1
- package/src/sap/fe/core/services/SideEffectsServiceFactory.js +8 -5
- package/src/sap/fe/core/services/SideEffectsServiceFactory.ts +11 -6
- package/src/sap/fe/core/services/TemplatedViewServiceFactory.js +14 -5
- package/src/sap/fe/core/services/view/TemplatingErrorPage.controller.js +1 -1
- package/src/sap/fe/core/support/InvalidAnnotationColumnKey.support.js +38 -0
- package/src/sap/fe/core/support/InvalidAnnotationColumnKey.support.ts +18 -0
- package/src/sap/fe/core/templating/DataModelPathHelper.js +8 -37
- package/src/sap/fe/core/templating/DataModelPathHelper.ts +13 -33
- package/src/sap/fe/core/templating/DisplayModeFormatter.js +114 -0
- package/src/sap/fe/core/templating/DisplayModeFormatter.ts +86 -0
- package/src/sap/fe/core/templating/EntitySetHelper.js +86 -3
- package/src/sap/fe/core/templating/EntitySetHelper.ts +44 -0
- package/src/sap/fe/core/templating/FilterHelper.js +10 -7
- package/src/sap/fe/core/templating/FilterHelper.ts +8 -6
- package/src/sap/fe/core/templating/PropertyHelper.js +2 -2
- package/src/sap/fe/core/templating/PropertyHelper.ts +1 -1
- package/src/sap/fe/core/templating/UIFormatters.js +47 -107
- package/src/sap/fe/core/templating/UIFormatters.ts +76 -72
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { ControllerExtension } from "sap/ui/core/mvc";
|
|
2
2
|
import { Binding, Context } from "sap/ui/model";
|
|
3
|
+
import { CheckBox } from "sap/m";
|
|
4
|
+
import { FileUploader } from "sap/ui/unified";
|
|
3
5
|
import { ControllerExtensionMetadata } from "sap/fe/core/controllerextensions";
|
|
4
6
|
import { UI5Class, Override, Public, Final, Private } from "../helpers/ClassSupport";
|
|
5
7
|
import { AppComponent, CommonUtils } from "sap/fe/core";
|
|
@@ -10,7 +12,7 @@ import {
|
|
|
10
12
|
ODataSideEffectsType,
|
|
11
13
|
ControlSideEffectsEntityDictionary
|
|
12
14
|
} from "sap/fe/core/services/SideEffectsServiceFactory";
|
|
13
|
-
import {
|
|
15
|
+
import { FieldRuntime } from "sap/fe/macros/field";
|
|
14
16
|
import { ConverterOutput, PropertyPath, EntityType } from "@sap-ux/vocabularies-types";
|
|
15
17
|
import { Log } from "sap/base";
|
|
16
18
|
|
|
@@ -28,7 +30,7 @@ type FieldEventPropertyType = {
|
|
|
28
30
|
type FieldSideEffectPropertyType = {
|
|
29
31
|
name: string;
|
|
30
32
|
immediate?: boolean;
|
|
31
|
-
context: Context
|
|
33
|
+
context: Context<any>;
|
|
32
34
|
sideEffects: SideEffectsType;
|
|
33
35
|
previouslyFailed?: boolean;
|
|
34
36
|
};
|
|
@@ -62,7 +64,7 @@ class SideEffectsControllerExtension extends ControllerExtension {
|
|
|
62
64
|
public onInit() {
|
|
63
65
|
this._oView = (this as any).base.getView();
|
|
64
66
|
this._oAppComponent = CommonUtils.getAppComponent(this._oView);
|
|
65
|
-
this._oSideEffectsService = this._oAppComponent.getSideEffectsService();
|
|
67
|
+
this._oSideEffectsService = (this._oAppComponent as any).getSideEffectsService();
|
|
66
68
|
this._mFieldGroupQueue = {};
|
|
67
69
|
this._aSourcePropertiesFailure = new Set();
|
|
68
70
|
this._mFailedSideEffects = {};
|
|
@@ -263,7 +265,7 @@ class SideEffectsControllerExtension extends ControllerExtension {
|
|
|
263
265
|
*/
|
|
264
266
|
@Public
|
|
265
267
|
@Final
|
|
266
|
-
public requestSideEffects(oSideEffects: SideEffectsType, oContext: Context): Promise<any> {
|
|
268
|
+
public requestSideEffects(oSideEffects: SideEffectsType, oContext: Context<any>): Promise<any> {
|
|
267
269
|
let fResolver: any, fRejector: any;
|
|
268
270
|
const oPromise = new Promise(function(resolve, reject) {
|
|
269
271
|
fResolver = resolve;
|
|
@@ -315,7 +317,7 @@ class SideEffectsControllerExtension extends ControllerExtension {
|
|
|
315
317
|
*/
|
|
316
318
|
@Private
|
|
317
319
|
@Final
|
|
318
|
-
private _addFailedSideEffects(oSideEffects: SideEffectsType, oContext: Context): void {
|
|
320
|
+
private _addFailedSideEffects(oSideEffects: SideEffectsType, oContext: Context<any>): void {
|
|
319
321
|
const sContextPath: string = oContext.getPath();
|
|
320
322
|
this._mFailedSideEffects[sContextPath] = this._mFailedSideEffects[sContextPath] || [];
|
|
321
323
|
const bIsNotAlreadyListed = this._mFailedSideEffects[sContextPath].every(
|
|
@@ -403,7 +405,7 @@ class SideEffectsControllerExtension extends ControllerExtension {
|
|
|
403
405
|
* @param {object} oContext SAPUI5 Context
|
|
404
406
|
* @returns {string | undefined} Index
|
|
405
407
|
*/
|
|
406
|
-
private _generateStatusIndex(mEntityType: EntityType, sPropertyPath: string, oContext: Context): string | undefined {
|
|
408
|
+
private _generateStatusIndex(mEntityType: EntityType, sPropertyPath: string, oContext: Context<any>): string | undefined {
|
|
407
409
|
const sContextPath = oContext.getPath();
|
|
408
410
|
const mProperty = mEntityType.resolvePath(sPropertyPath);
|
|
409
411
|
if (mProperty) {
|
|
@@ -426,7 +428,7 @@ class SideEffectsControllerExtension extends ControllerExtension {
|
|
|
426
428
|
*/
|
|
427
429
|
@Private
|
|
428
430
|
@Final
|
|
429
|
-
private _getContextForSideEffects(oSourceField: FieldControl, sSideEffectEntityType: string): Context | undefined {
|
|
431
|
+
private _getContextForSideEffects(oSourceField: FieldControl, sSideEffectEntityType: string): Context<any> | undefined {
|
|
430
432
|
const oBindingContext = oSourceField.getBindingContext();
|
|
431
433
|
let oContextForSideEffects = oBindingContext,
|
|
432
434
|
sEntityType = this._oSideEffectsService.getEntityTypeFromContext(oBindingContext);
|
|
@@ -476,7 +478,7 @@ class SideEffectsControllerExtension extends ControllerExtension {
|
|
|
476
478
|
|
|
477
479
|
return promise.then(() => {
|
|
478
480
|
const oPromise = new Promise(function(resolve, reject) {
|
|
479
|
-
if (!getFieldStateOnChange(oEvent).state.validity) {
|
|
481
|
+
if (!FieldRuntime.getFieldStateOnChange(oEvent).state.validity) {
|
|
480
482
|
reject();
|
|
481
483
|
} else {
|
|
482
484
|
resolve(true);
|
|
@@ -536,7 +538,7 @@ class SideEffectsControllerExtension extends ControllerExtension {
|
|
|
536
538
|
oSideEffect: SideEffectsType | undefined = this._oSideEffectsService.getODataEntitySideEffects(sSideEffectEntityType)?.[
|
|
537
539
|
sSideEffectPath
|
|
538
540
|
],
|
|
539
|
-
oContext: Context | undefined = this._getContextForSideEffects(oField, sSideEffectEntityType);
|
|
541
|
+
oContext: Context<any> | undefined = this._getContextForSideEffects(oField, sSideEffectEntityType);
|
|
540
542
|
if (oSideEffect && oContext) {
|
|
541
543
|
mSideEffectsMap[sName] = {
|
|
542
544
|
name: sName,
|
|
@@ -553,7 +555,7 @@ class SideEffectsControllerExtension extends ControllerExtension {
|
|
|
553
555
|
mFieldPath: any = (oField.getAggregation("customData") as any[]).find(oCustomData => {
|
|
554
556
|
return oCustomData.getKey() === "sourcePath";
|
|
555
557
|
}),
|
|
556
|
-
oContext: Context | undefined = this._getContextForSideEffects(oField, sViewEntityType);
|
|
558
|
+
oContext: Context<any> | undefined = this._getContextForSideEffects(oField, sViewEntityType);
|
|
557
559
|
|
|
558
560
|
if (mFieldPath && oContext) {
|
|
559
561
|
const sFieldPath = mFieldPath.getValue().replace("/" + sViewEntitySetSetName + "/", ""),
|
|
@@ -657,7 +659,7 @@ class SideEffectsControllerExtension extends ControllerExtension {
|
|
|
657
659
|
const mEntityType = this._getEntityTypeFromFQN(sEntityType);
|
|
658
660
|
if (mEntityType) {
|
|
659
661
|
// Retrieves all properties used by the field
|
|
660
|
-
const oFieldBinding = this._getBindingForField(oField);
|
|
662
|
+
const oFieldBinding: any = this._getBindingForField(oField);
|
|
661
663
|
const aFieldPaths = oFieldBinding.isA("sap.ui.model.CompositeBinding")
|
|
662
664
|
? ((oFieldBinding as any).getBindings() || []).map((oBinding: any) => oBinding.sPath)
|
|
663
665
|
: [oFieldBinding.getPath()];
|
|
@@ -679,13 +681,13 @@ class SideEffectsControllerExtension extends ControllerExtension {
|
|
|
679
681
|
* @returns {Binding} Binding to the value
|
|
680
682
|
*/
|
|
681
683
|
private _getBindingForField(oField: FieldControl): Binding {
|
|
682
|
-
let
|
|
683
|
-
if (oField.isA("sap.m.CheckBox")) {
|
|
684
|
-
|
|
685
|
-
} else {
|
|
686
|
-
|
|
684
|
+
let sBindingName = "value";
|
|
685
|
+
if (oField.isA<CheckBox>("sap.m.CheckBox")) {
|
|
686
|
+
sBindingName = "selected";
|
|
687
|
+
} else if (oField.isA<FileUploader>("sap.ui.unified.FileUploader")) {
|
|
688
|
+
sBindingName = "uploadUrl";
|
|
687
689
|
}
|
|
688
|
-
return
|
|
690
|
+
return oField.getBinding(sBindingName);
|
|
689
691
|
}
|
|
690
692
|
}
|
|
691
693
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* SAPUI5
|
|
3
|
-
* (c) Copyright 2009-
|
|
3
|
+
* (c) Copyright 2009-2022 SAP SE. All rights reserved.
|
|
4
4
|
*/
|
|
5
5
|
sap.ui.define(
|
|
6
6
|
[
|
|
@@ -11,9 +11,22 @@ sap.ui.define(
|
|
|
11
11
|
"sap/ui/fl/apply/api/ControlVariantApplyAPI",
|
|
12
12
|
"sap/ui/mdc/p13n/StateUtil",
|
|
13
13
|
"sap/fe/navigation/library",
|
|
14
|
-
"sap/fe/core/CommonUtils"
|
|
14
|
+
"sap/fe/core/CommonUtils",
|
|
15
|
+
"sap/fe/core/helpers/KeepAliveHelper",
|
|
16
|
+
"sap/fe/core/helpers/ModelHelper"
|
|
15
17
|
],
|
|
16
|
-
function(
|
|
18
|
+
function(
|
|
19
|
+
ControllerExtension,
|
|
20
|
+
OverrideExecution,
|
|
21
|
+
Log,
|
|
22
|
+
mergeObjects,
|
|
23
|
+
ControlVariantApplyAPI,
|
|
24
|
+
StateUtil,
|
|
25
|
+
NavLibrary,
|
|
26
|
+
CommonUtils,
|
|
27
|
+
KeepAliveHelper,
|
|
28
|
+
ModelHelper
|
|
29
|
+
) {
|
|
17
30
|
"use strict";
|
|
18
31
|
|
|
19
32
|
// additionalStates are stored next to control IDs, so name clash avoidance needed. Fortunately IDs have restrictions:
|
|
@@ -30,14 +43,17 @@ sap.ui.define(
|
|
|
30
43
|
"sap.ui.fl.variants.VariantManagement": {
|
|
31
44
|
retrieve: function(oVM) {
|
|
32
45
|
return {
|
|
33
|
-
"variantId": oVM.
|
|
46
|
+
"variantId": oVM.getCurrentVariantKey()
|
|
34
47
|
};
|
|
35
48
|
},
|
|
36
49
|
apply: function(oVM, oControlState) {
|
|
37
50
|
if (oControlState && oControlState.variantId !== undefined && oControlState.variantId !== oVM.getCurrentVariantKey()) {
|
|
51
|
+
var sVariantReference = this._checkIfVariantIdIsAvailable(oVM, oControlState.variantId)
|
|
52
|
+
? oControlState.variantId
|
|
53
|
+
: oVM.getStandardVariantKey();
|
|
38
54
|
return ControlVariantApplyAPI.activateVariant({
|
|
39
55
|
element: oVM,
|
|
40
|
-
variantReference:
|
|
56
|
+
variantReference: sVariantReference
|
|
41
57
|
});
|
|
42
58
|
}
|
|
43
59
|
}
|
|
@@ -127,8 +143,8 @@ sap.ui.define(
|
|
|
127
143
|
var oBindingContext = oOPLayout.getBindingContext();
|
|
128
144
|
var oBinding = oBindingContext && oBindingContext.getBinding();
|
|
129
145
|
if (oBinding) {
|
|
130
|
-
var sMetaPath =
|
|
131
|
-
var sStrategy =
|
|
146
|
+
var sMetaPath = ModelHelper.getMetaPathForContext(oBindingContext);
|
|
147
|
+
var sStrategy = KeepAliveHelper.getControlRefreshStrategyForContextPath(oOPLayout, sMetaPath);
|
|
132
148
|
if (sStrategy === "self") {
|
|
133
149
|
// Refresh main context and 1-1 navigation properties or OP
|
|
134
150
|
var oModel = oBindingContext.getModel(),
|
|
@@ -299,7 +315,9 @@ sap.ui.define(
|
|
|
299
315
|
},
|
|
300
316
|
applyNavigationParameters: { "public": true, "final": false, overrideExecution: OverrideExecution.After },
|
|
301
317
|
onBeforeStateApplied: { "public": true, "final": false, overrideExecution: OverrideExecution.After },
|
|
302
|
-
onAfterStateApplied: { "public": true, "final": false, overrideExecution: OverrideExecution.After }
|
|
318
|
+
onAfterStateApplied: { "public": true, "final": false, overrideExecution: OverrideExecution.After },
|
|
319
|
+
onSuspend: { "public": true, "final": false, overrideExecution: OverrideExecution.After },
|
|
320
|
+
onRestore: { "public": true, "final": false, overrideExecution: OverrideExecution.After }
|
|
303
321
|
}
|
|
304
322
|
},
|
|
305
323
|
|
|
@@ -393,13 +411,29 @@ sap.ui.define(
|
|
|
393
411
|
* The override execution is: {@link sap.ui.core.mvc.OverrideExecution.After}.
|
|
394
412
|
*
|
|
395
413
|
* @param {sap.ui.base.ManagedObject} oControl The control for which the refresh handler is adapted.
|
|
396
|
-
* @param {Array<object>} oControlHandler A plain object which
|
|
414
|
+
* @param {Array<object>} oControlHandler A plain object which can have one function: <code>refreshBinding</code>
|
|
397
415
|
*
|
|
398
416
|
* @alias sap.fe.core.controllerextensions.ViewState#adaptBindingRefreshHandler
|
|
399
417
|
* @protected
|
|
400
418
|
*/
|
|
401
419
|
adaptBindingRefreshHandler: function(oControl, oControlHandler) {},
|
|
402
420
|
|
|
421
|
+
/**
|
|
422
|
+
* Called when the application is suspended due to keep-alive mode.
|
|
423
|
+
*
|
|
424
|
+
* @alias sap.fe.core.controllerextensions.ViewState#onSuspend
|
|
425
|
+
* @public
|
|
426
|
+
*/
|
|
427
|
+
onSuspend: function() {},
|
|
428
|
+
|
|
429
|
+
/**
|
|
430
|
+
* Called when the application is restored due to keep-alive mode.
|
|
431
|
+
*
|
|
432
|
+
* @alias sap.fe.core.controllerextensions.ViewState#onRestore
|
|
433
|
+
* @public
|
|
434
|
+
*/
|
|
435
|
+
onRestore: function() {},
|
|
436
|
+
|
|
403
437
|
/**
|
|
404
438
|
* Destructor method for objects.
|
|
405
439
|
*/
|
|
@@ -662,6 +696,17 @@ sap.ui.define(
|
|
|
662
696
|
});
|
|
663
697
|
},
|
|
664
698
|
|
|
699
|
+
_checkIfVariantIdIsAvailable: function(oVM, sVariantId) {
|
|
700
|
+
var aVariants = oVM.getVariants(),
|
|
701
|
+
bIsControlStateVariantAvailable = false;
|
|
702
|
+
aVariants.forEach(function(oVariant) {
|
|
703
|
+
if (oVariant.key === sVariantId) {
|
|
704
|
+
bIsControlStateVariantAvailable = true;
|
|
705
|
+
}
|
|
706
|
+
});
|
|
707
|
+
return bIsControlStateVariantAvailable;
|
|
708
|
+
},
|
|
709
|
+
|
|
665
710
|
_setInitialStateApplied: function() {
|
|
666
711
|
if (this._pInitialStateAppliedResolve) {
|
|
667
712
|
var pInitialStateAppliedResolve = this._pInitialStateAppliedResolve;
|
|
@@ -35,40 +35,46 @@
|
|
|
35
35
|
multipleLines?
|
|
36
36
|
-->
|
|
37
37
|
<!-- TODO: use new value helper -->
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
38
|
+
|
|
39
|
+
<template:if test="{= !${parameter>$isCollection} }">
|
|
40
|
+
<template:then>
|
|
41
|
+
<!--The payload of FieldBaseDelegate is used to control the fallback feature 'retrieveTextFromValueList' -->
|
|
42
|
+
<mdc:Field
|
|
43
|
+
delegate="{name:'sap/fe/macros/FieldBaseDelegate', payload:{retrieveTextFromValueList:true}}"
|
|
44
|
+
unittest:id="ActionParameterDialogFieldExpressionTest"
|
|
45
|
+
id="{= ID.generate(['APD_', ${parameter>$Name}]) }"
|
|
46
|
+
value="{parameter>@@MODEL.format}"
|
|
47
|
+
display="{actionParameter>@@FIELD.getAPDialogDisplayFormat}"
|
|
48
|
+
editMode="{actionParameter>@@COMMON.getParameterEditMode}"
|
|
49
|
+
width="100%"
|
|
50
|
+
multipleLines="{= ${actionParameter>@com.sap.vocabularies.UI.v1.MultiLineText} ? (${actionParameter>@com.sap.vocabularies.UI.v1.MultiLineText} !== false) : undefined}"
|
|
51
|
+
required="{= FIELD.isRequired(${actionParameter>@@FIELD.fieldControl}, 'Editable')}"
|
|
52
|
+
change="{= '.handleChange($event, \'' + ${parameter>$Name} + '\')' }"
|
|
53
|
+
fieldHelp="{= FIELD.getActionParameterDialogFieldHelp(${actionParameter>@}, ${actionName>@sapui.name}, ${parameter>$Name}) }"
|
|
54
|
+
visible="{actionParameter>@@COMMON.isVisible}"
|
|
55
|
+
>
|
|
56
|
+
<core:Fragment fragmentName="sap.fe.core.controls.ActionParameterDialogValueHelp" type="XML" />
|
|
57
|
+
</mdc:Field>
|
|
58
|
+
</template:then>
|
|
59
|
+
<template:else>
|
|
60
|
+
<mdc:MultiValueField
|
|
61
|
+
id="{= ID.generate(['APD_', ${parameter>$Name}]) }"
|
|
62
|
+
items="{actionParameter>@@FE_MODEL.getActionParameterItemsModelPath}"
|
|
63
|
+
delegate="{name: 'sap/fe/core/controls/MultiValueParameterDelegate'}"
|
|
64
|
+
unittest:id="ActionParameterDialogMultiValueFieldExpressionTest"
|
|
65
|
+
display="{actionParameter>@@FIELD.getAPDialogDisplayFormat}"
|
|
66
|
+
editMode="{actionParameter>@@COMMON.getParameterEditMode}"
|
|
67
|
+
width="100%"
|
|
68
|
+
multipleLines="{= ${actionParameter>@com.sap.vocabularies.UI.v1.MultiLineText} ? (${actionParameter>@com.sap.vocabularies.UI.v1.MultiLineText} !== false) : undefined}"
|
|
69
|
+
required="{= FIELD.isRequired(${actionParameter>@@FIELD.fieldControl}, 'Editable')}"
|
|
70
|
+
fieldHelp="{= FIELD.getActionParameterDialogFieldHelp(${actionParameter>@}, ${actionName>@sapui.name}, ${parameter>$Name}) }"
|
|
71
|
+
visible="{actionParameter>@@COMMON.isVisible}"
|
|
72
|
+
>
|
|
73
|
+
<mdcField:MultiValueFieldItem key="{path: 'mvfview>Key', type:'sap.ui.model.type.String'}" description="{mvfview>Desc}" />
|
|
74
|
+
<core:Fragment fragmentName="sap.fe.core.controls.ActionParameterDialogValueHelp" type="XML" />
|
|
75
|
+
</mdc:MultiValueField>
|
|
76
|
+
</template:else>
|
|
77
|
+
</template:if>
|
|
72
78
|
</template:if>
|
|
73
79
|
</template:with>
|
|
74
80
|
</template:repeat>
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
<core:FragmentDefinition
|
|
2
|
+
xmlns:template="http://schemas.sap.com/sapui5/extension/sap.ui.core.template/1"
|
|
3
|
+
xmlns="sap.m"
|
|
4
|
+
xmlns:core="sap.ui.core"
|
|
5
|
+
xmlns:mdc="sap.ui.mdc"
|
|
6
|
+
xmlns:mdcField="sap.ui.mdc.field"
|
|
7
|
+
xmlns:unittest="http://schemas.sap.com/sapui5/preprocessorextension/sap.fe.unittesting/1"
|
|
8
|
+
template:require="{
|
|
9
|
+
COMMON: 'sap/fe/macros/CommonHelper',
|
|
10
|
+
FIELD: 'sap/fe/macros/field/FieldHelper',
|
|
11
|
+
ID: 'sap/fe/core/helpers/StableIdHelper',
|
|
12
|
+
ValueHelpTemplating: 'sap/fe/macros/internal/valuehelp/ValueHelpTemplating',
|
|
13
|
+
Property: 'sap/fe/core/templating/PropertyFormatters'
|
|
14
|
+
}"
|
|
15
|
+
>
|
|
16
|
+
<template:if test="{= FIELD.hasValueHelpAnnotation(${actionParameter>@}) }">
|
|
17
|
+
<mdc:dependents>
|
|
18
|
+
<mdcField:FieldValueHelp
|
|
19
|
+
unittest:id="ActionParameterDialogValuehelpExpressionTest"
|
|
20
|
+
id="{= ID.generate([${actionName>@sapui.name},${parameter>$Name}]) }"
|
|
21
|
+
delegate="{= FIELD.getFieldValueHelpDelegate(${action>$IsBound}, ${entitySet>@@COMMON.getContextPath}, ${actionName>@sapui.name}, ${parameter>$Name}) }"
|
|
22
|
+
noDialog="{= ${actionParameter>@com.sap.vocabularies.Common.v1.ValueListWithFixedValues} ? (${actionParameter>@com.sap.vocabularies.Common.v1.ValueListWithFixedValues} !== false) : false}"
|
|
23
|
+
validateInput="{= ValueHelpTemplating.requiresValidation(${actionParameter>@@Property.getProperty})}"
|
|
24
|
+
caseSensitive="{= ValueHelpTemplating.useCaseSensitiveFilterRequests(${actionParameter>@@Property.getPropertyObjectPath}, ${actionParameter>/@Org.OData.Capabilities.V1.FilterFunctions})}"
|
|
25
|
+
>
|
|
26
|
+
<mdcField:dialogContent>
|
|
27
|
+
<mdcField:FieldValueHelpMdcTableWrapper />
|
|
28
|
+
</mdcField:dialogContent>
|
|
29
|
+
<mdcField:suggestContent>
|
|
30
|
+
<mdcField:FieldValueHelpMTableWrapper />
|
|
31
|
+
</mdcField:suggestContent>
|
|
32
|
+
</mdcField:FieldValueHelp>
|
|
33
|
+
</mdc:dependents>
|
|
34
|
+
</template:if>
|
|
35
|
+
</core:FragmentDefinition>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* SAPUI5
|
|
3
|
-
* (c) Copyright 2009-
|
|
3
|
+
* (c) Copyright 2009-2022 SAP SE. All rights reserved.
|
|
4
4
|
*/
|
|
5
5
|
sap.ui.define(["sap/ui/core/CommandExecution", "sap/base/Log", "sap/ui/core/Element", "sap/ui/core/Shortcut"], function(
|
|
6
6
|
CommandExecution,
|
|
@@ -1,126 +1,127 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* SAPUI5
|
|
3
|
-
* (c) Copyright 2009-
|
|
3
|
+
* (c) Copyright 2009-2022 SAP SE. All rights reserved.
|
|
4
4
|
*/
|
|
5
|
-
sap.ui.define(
|
|
6
|
-
QuickViewPage,
|
|
7
|
-
Button,
|
|
8
|
-
|
|
9
|
-
DelegateUtil
|
|
10
|
-
) {
|
|
11
|
-
"use strict";
|
|
5
|
+
sap.ui.define(
|
|
6
|
+
["sap/m/QuickViewPage", "sap/m/Button", "sap/fe/core/CommonUtils", "sap/fe/macros/DelegateUtil", "sap/fe/core/helpers/KeepAliveHelper"],
|
|
7
|
+
function(QuickViewPage, Button, CommonUtils, DelegateUtil, KeepAliveHelper) {
|
|
8
|
+
"use strict";
|
|
12
9
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
10
|
+
return QuickViewPage.extend("sap.fe.core.controls.CustomQuickViewPage", {
|
|
11
|
+
metadata: {
|
|
12
|
+
defaultAggregation: "groups",
|
|
13
|
+
aggregations: {
|
|
14
|
+
customContent: {
|
|
15
|
+
type: "sap.ui.core.Control",
|
|
16
|
+
multiple: true,
|
|
17
|
+
bindable: "bindable"
|
|
18
|
+
},
|
|
19
|
+
groups: { type: "sap.m.QuickViewGroup", multiple: true, singularName: "group", bindable: "bindable" }
|
|
21
20
|
},
|
|
22
|
-
|
|
21
|
+
publicMethods: []
|
|
23
22
|
},
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
};
|
|
50
|
-
var sQuickViewPageTitleLinkIntent = oNavArgs.target.semanticObject + "-" + oNavArgs.target.action;
|
|
23
|
+
renderer: {},
|
|
24
|
+
onAfterRendering: function() {
|
|
25
|
+
QuickViewPage.prototype.onAfterRendering.apply(this, arguments);
|
|
26
|
+
},
|
|
27
|
+
onBeforeRendering: function() {
|
|
28
|
+
if (
|
|
29
|
+
this.getParent() &&
|
|
30
|
+
this.getParent().isA("sap.fe.core.controls.ConditionalWrapper") &&
|
|
31
|
+
this.getParent().getProperty("condition") === true
|
|
32
|
+
) {
|
|
33
|
+
this.setCrossAppNavCallback(
|
|
34
|
+
function() {
|
|
35
|
+
var sQuickViewPageTitleLinkHref = DelegateUtil.getCustomData(this, "titleLink");
|
|
36
|
+
var oView = sap.ui.fl.Utils.getViewForControl(this);
|
|
37
|
+
var oAppComponent = CommonUtils.getAppComponent(oView);
|
|
38
|
+
var oShellServiceHelper = oAppComponent.getShellServices();
|
|
39
|
+
var oShellHash = oShellServiceHelper.parseShellHash(sQuickViewPageTitleLinkHref);
|
|
40
|
+
var oNavArgs = {
|
|
41
|
+
target: {
|
|
42
|
+
semanticObject: oShellHash.semanticObject,
|
|
43
|
+
action: oShellHash.action
|
|
44
|
+
},
|
|
45
|
+
params: oShellHash.params
|
|
46
|
+
};
|
|
47
|
+
var sQuickViewPageTitleLinkIntent = oNavArgs.target.semanticObject + "-" + oNavArgs.target.action;
|
|
51
48
|
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
49
|
+
if (
|
|
50
|
+
sQuickViewPageTitleLinkIntent &&
|
|
51
|
+
this.oCrossAppNavigator &&
|
|
52
|
+
this.oCrossAppNavigator.isNavigationSupported([sQuickViewPageTitleLinkIntent])
|
|
53
|
+
) {
|
|
54
|
+
if (sQuickViewPageTitleLinkIntent && sQuickViewPageTitleLinkIntent !== "") {
|
|
55
|
+
if (typeof sQuickViewPageTitleLinkIntent === "string" && sQuickViewPageTitleLinkIntent !== "") {
|
|
56
|
+
var sTargetHref;
|
|
57
|
+
var oLinkControl = this.getParent();
|
|
58
|
+
while (oLinkControl && !oLinkControl.isA("sap.ui.mdc.Link")) {
|
|
59
|
+
oLinkControl = oLinkControl.getParent();
|
|
60
|
+
}
|
|
61
|
+
var _aLinks = oLinkControl.getModel("$sapuimdcLink").getProperty("/linkItems");
|
|
62
|
+
if (_aLinks) {
|
|
63
|
+
if (_aLinks.length > 0) {
|
|
64
|
+
for (var i = 0; i < _aLinks.length; i++) {
|
|
65
|
+
if (_aLinks[i].key === sQuickViewPageTitleLinkIntent) {
|
|
66
|
+
sTargetHref = _aLinks[i].href;
|
|
67
|
+
break;
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
if (sTargetHref) {
|
|
71
|
+
oShellHash = oShellServiceHelper.parseShellHash(sTargetHref);
|
|
72
|
+
} else {
|
|
73
|
+
oShellHash = oShellServiceHelper.parseShellHash(sQuickViewPageTitleLinkIntent);
|
|
71
74
|
}
|
|
72
75
|
}
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
} else {
|
|
76
|
-
oShellHash = oShellServiceHelper.parseShellHash(sQuickViewPageTitleLinkIntent);
|
|
77
|
-
}
|
|
76
|
+
} else {
|
|
77
|
+
oShellHash = oShellServiceHelper.parseShellHash(sQuickViewPageTitleLinkIntent);
|
|
78
78
|
}
|
|
79
|
-
|
|
80
|
-
|
|
79
|
+
KeepAliveHelper.storeControlRefreshStrategyForHash(oView, oShellHash);
|
|
80
|
+
return {
|
|
81
|
+
target: {
|
|
82
|
+
semanticObject: oShellHash.semanticObject,
|
|
83
|
+
action: oShellHash.action
|
|
84
|
+
},
|
|
85
|
+
params: oShellHash.params
|
|
86
|
+
};
|
|
81
87
|
}
|
|
82
|
-
return {
|
|
83
|
-
target: {
|
|
84
|
-
semanticObject: oShellHash.semanticObject,
|
|
85
|
-
action: oShellHash.action
|
|
86
|
-
},
|
|
87
|
-
params: oShellHash.params
|
|
88
|
-
};
|
|
89
88
|
}
|
|
89
|
+
} else {
|
|
90
|
+
var oCurrentShellHash = oShellServiceHelper.parseShellHash(window.location.hash);
|
|
91
|
+
KeepAliveHelper.storeControlRefreshStrategyForHash(oView, oCurrentShellHash);
|
|
92
|
+
|
|
93
|
+
return {
|
|
94
|
+
target: {
|
|
95
|
+
semanticObject: oCurrentShellHash.semanticObject,
|
|
96
|
+
action: oCurrentShellHash.action,
|
|
97
|
+
appSpecificRoute: oCurrentShellHash.appSpecificRoute
|
|
98
|
+
},
|
|
99
|
+
params: oCurrentShellHash.params
|
|
100
|
+
};
|
|
90
101
|
}
|
|
91
|
-
} else {
|
|
92
|
-
var oCurrentShellHash = oShellServiceHelper.parseShellHash(window.location.hash);
|
|
93
|
-
return {
|
|
94
|
-
target: {
|
|
95
|
-
semanticObject: oCurrentShellHash.semanticObject,
|
|
96
|
-
action: oCurrentShellHash.action,
|
|
97
|
-
appSpecificRoute: oCurrentShellHash.appSpecificRoute
|
|
98
|
-
},
|
|
99
|
-
params: oCurrentShellHash.params
|
|
100
|
-
};
|
|
101
|
-
}
|
|
102
|
-
}.bind(this)
|
|
103
|
-
);
|
|
104
|
-
}
|
|
105
|
-
QuickViewPage.prototype.onBeforeRendering.apply(this, arguments);
|
|
106
|
-
var oPageContent = this.getPageContent();
|
|
107
|
-
var oForm = oPageContent.form;
|
|
108
|
-
if (oForm) {
|
|
109
|
-
var _aContent = this.getAggregation("customContent");
|
|
110
|
-
if (_aContent && _aContent.length > 0) {
|
|
111
|
-
_aContent.forEach(
|
|
112
|
-
function(_oContent) {
|
|
113
|
-
var _oContentClone = _oContent.clone();
|
|
114
|
-
_oContentClone.setModel(this.getModel());
|
|
115
|
-
_oContentClone.setBindingContext(this.getBindingContext());
|
|
116
|
-
oForm.addContent(_oContentClone);
|
|
117
102
|
}.bind(this)
|
|
118
103
|
);
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
104
|
+
}
|
|
105
|
+
QuickViewPage.prototype.onBeforeRendering.apply(this, arguments);
|
|
106
|
+
var oPageContent = this.getPageContent();
|
|
107
|
+
var oForm = oPageContent.form;
|
|
108
|
+
if (oForm) {
|
|
109
|
+
var _aContent = this.getAggregation("customContent");
|
|
110
|
+
if (_aContent && _aContent.length > 0) {
|
|
111
|
+
_aContent.forEach(
|
|
112
|
+
function(_oContent) {
|
|
113
|
+
var _oContentClone = _oContent.clone();
|
|
114
|
+
_oContentClone.setModel(this.getModel());
|
|
115
|
+
_oContentClone.setBindingContext(this.getBindingContext());
|
|
116
|
+
oForm.addContent(_oContentClone);
|
|
117
|
+
}.bind(this)
|
|
118
|
+
);
|
|
119
|
+
setTimeout(function() {
|
|
120
|
+
oForm.rerender();
|
|
121
|
+
}, 0);
|
|
122
|
+
}
|
|
122
123
|
}
|
|
123
124
|
}
|
|
124
|
-
}
|
|
125
|
-
}
|
|
126
|
-
|
|
125
|
+
});
|
|
126
|
+
}
|
|
127
|
+
);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* SAPUI5
|
|
3
|
-
* (c) Copyright 2009-
|
|
3
|
+
* (c) Copyright 2009-2022 SAP SE. All rights reserved.
|
|
4
4
|
*/
|
|
5
5
|
sap.ui.define(
|
|
6
6
|
[
|
|
@@ -110,9 +110,12 @@ sap.ui.define(
|
|
|
110
110
|
|
|
111
111
|
DataLossOrDraftDiscardHandler.discardDraft = function(oController, bSkipBindingToView) {
|
|
112
112
|
var oParamsContext = oController.getView().getBindingContext();
|
|
113
|
-
var mParams = {
|
|
114
|
-
|
|
115
|
-
|
|
113
|
+
var mParams = {
|
|
114
|
+
skipBackNavigation: true,
|
|
115
|
+
skipDiscardPopover: true,
|
|
116
|
+
skipBindingToView: bSkipBindingToView !== undefined ? bSkipBindingToView : true
|
|
117
|
+
};
|
|
118
|
+
|
|
116
119
|
return oController.editFlow.cancelDocument(oParamsContext, mParams);
|
|
117
120
|
};
|
|
118
121
|
|