@sapui5/sap.fe.core 1.96.4 → 1.99.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 +6 -5
- package/src/sap/fe/core/.library +1 -1
- package/src/sap/fe/core/AnnotationHelper.js +377 -405
- package/src/sap/fe/core/AnnotationHelper.ts +385 -0
- package/src/sap/fe/core/AppComponent.js +5 -3
- package/src/sap/fe/core/AppStateHandler.js +229 -195
- package/src/sap/fe/core/AppStateHandler.ts +171 -0
- package/src/sap/fe/core/BaseController.js +3 -2
- package/src/sap/fe/core/BusyLocker.js +105 -121
- package/src/sap/fe/core/BusyLocker.ts +98 -0
- package/src/sap/fe/core/CommonUtils.js +2073 -2606
- package/src/sap/fe/core/CommonUtils.ts +2078 -0
- package/src/sap/fe/core/ExtensionAPI.js +16 -7
- package/src/sap/fe/core/PageController.js +84 -119
- package/src/sap/fe/core/PageController.ts +101 -0
- package/src/sap/fe/core/RouterProxy.js +986 -809
- package/src/sap/fe/core/RouterProxy.ts +838 -0
- package/src/sap/fe/core/Synchronization.js +51 -35
- package/src/sap/fe/core/Synchronization.ts +29 -0
- package/src/sap/fe/core/TemplateComponent.js +173 -155
- package/src/sap/fe/core/TemplateComponent.ts +166 -0
- package/src/sap/fe/core/TemplateModel.js +97 -54
- package/src/sap/fe/core/TemplateModel.ts +63 -0
- package/src/sap/fe/core/TransactionHelper.js +1576 -1627
- package/src/sap/fe/core/TransactionHelper.ts +1706 -0
- package/src/sap/fe/core/actions/draft.js +559 -581
- package/src/sap/fe/core/actions/draft.ts +593 -0
- package/src/sap/fe/core/actions/messageHandling.js +545 -435
- package/src/sap/fe/core/actions/messageHandling.ts +532 -0
- package/src/sap/fe/core/actions/nonDraft.js +17 -19
- package/src/sap/fe/core/actions/nonDraft.ts +12 -0
- package/src/sap/fe/core/actions/operations.js +1074 -1192
- package/src/sap/fe/core/actions/operations.ts +1162 -0
- package/src/sap/fe/core/actions/sticky.js +102 -105
- package/src/sap/fe/core/actions/sticky.ts +102 -0
- package/src/sap/fe/core/controllerextensions/ControllerExtensionMetadata.js +3 -2
- package/src/sap/fe/core/controllerextensions/EditFlow.js +235 -264
- package/src/sap/fe/core/controllerextensions/IntentBasedNavigation.js +3 -2
- package/src/sap/fe/core/controllerextensions/InternalEditFlow.js +288 -13
- package/src/sap/fe/core/controllerextensions/InternalIntentBasedNavigation.js +35 -25
- package/src/sap/fe/core/controllerextensions/InternalRouting.js +79 -46
- package/src/sap/fe/core/controllerextensions/KPIManagement.js +86 -10
- package/src/sap/fe/core/controllerextensions/KPIManagement.ts +109 -31
- package/src/sap/fe/core/controllerextensions/MassEdit.js +172 -0
- package/src/sap/fe/core/controllerextensions/MessageHandler.js +237 -104
- package/src/sap/fe/core/controllerextensions/PageReady.js +3 -3
- package/src/sap/fe/core/controllerextensions/PageReady.ts +12 -8
- package/src/sap/fe/core/controllerextensions/Paginator.js +37 -9
- package/src/sap/fe/core/controllerextensions/Placeholder.js +8 -4
- package/src/sap/fe/core/controllerextensions/Routing.js +25 -5
- package/src/sap/fe/core/controllerextensions/RoutingListener.js +3 -2
- package/src/sap/fe/core/controllerextensions/Share.js +3 -2
- package/src/sap/fe/core/controllerextensions/SideEffects.js +9 -9
- package/src/sap/fe/core/controllerextensions/SideEffects.ts +22 -21
- package/src/sap/fe/core/controllerextensions/ViewState.js +36 -8
- package/src/sap/fe/core/controls/ActionParameterDialog.fragment.xml +2 -1
- package/src/sap/fe/core/controls/CommandExecution.js +3 -2
- package/src/sap/fe/core/controls/ConditionalWrapper.js +3 -2
- package/src/sap/fe/core/controls/CustomQuickViewPage.js +112 -113
- package/src/sap/fe/core/controls/DataLossOrDraftDiscard/DataLossOrDraftDiscardHandler.js +9 -5
- package/src/sap/fe/core/controls/FieldWrapper.js +18 -23
- package/src/sap/fe/core/controls/FilterBar.js +3 -2
- package/src/sap/fe/core/controls/FormElementWrapper.js +3 -7
- package/src/sap/fe/core/controls/MultiValueParameterDelegate.js +3 -2
- package/src/sap/fe/core/controls/NonComputedVisibleKeyFieldsDialog.fragment.xml +2 -1
- package/src/sap/fe/core/controls/filterbar/FilterContainer.js +3 -2
- package/src/sap/fe/core/controls/filterbar/VisualFilter.js +5 -4
- package/src/sap/fe/core/controls/filterbar/VisualFilterContainer.js +3 -2
- package/src/sap/fe/core/controls/filterbar/utils/VisualFilterUtils.js +3 -2
- package/src/sap/fe/core/controls/massEdit/MassEditDialog.fragment.xml +106 -0
- package/src/sap/fe/core/controls/massEdit/MassEditHandlers.js +79 -0
- package/src/sap/fe/core/converters/ConverterContext.js +14 -2
- package/src/sap/fe/core/converters/ConverterContext.ts +14 -3
- package/src/sap/fe/core/converters/ManifestSettings.js +2 -1
- package/src/sap/fe/core/converters/ManifestSettings.ts +8 -1
- package/src/sap/fe/core/converters/ManifestWrapper.js +56 -32
- package/src/sap/fe/core/converters/ManifestWrapper.ts +24 -6
- package/src/sap/fe/core/converters/MetaModelConverter.js +76 -6
- package/src/sap/fe/core/converters/MetaModelConverter.ts +79 -15
- package/src/sap/fe/core/converters/TemplateConverter.js +1 -1
- package/src/sap/fe/core/converters/TemplateConverter.ts +2 -2
- package/src/sap/fe/core/converters/annotations/DataField.js +3 -3
- package/src/sap/fe/core/converters/annotations/DataField.ts +1 -1
- package/src/sap/fe/core/converters/common/AnnotationConverter.js +85 -46
- package/src/sap/fe/core/converters/controls/Common/Action.js +16 -4
- package/src/sap/fe/core/converters/controls/Common/Action.ts +14 -5
- package/src/sap/fe/core/converters/controls/Common/Chart.js +5 -3
- package/src/sap/fe/core/converters/controls/Common/Chart.ts +11 -3
- package/src/sap/fe/core/converters/controls/Common/DataVisualization.js +3 -3
- package/src/sap/fe/core/converters/controls/Common/DataVisualization.ts +2 -2
- package/src/sap/fe/core/converters/controls/Common/Form.js +60 -19
- package/src/sap/fe/core/converters/controls/Common/Form.ts +66 -14
- package/src/sap/fe/core/converters/controls/Common/KPI.js +69 -4
- package/src/sap/fe/core/converters/controls/Common/KPI.ts +72 -0
- package/src/sap/fe/core/converters/controls/Common/Table.js +503 -399
- package/src/sap/fe/core/converters/controls/Common/Table.ts +615 -480
- package/src/sap/fe/core/converters/controls/Common/table/StandardActions.js +527 -0
- package/src/sap/fe/core/converters/controls/Common/table/StandardActions.ts +655 -0
- package/src/sap/fe/core/converters/controls/ListReport/FilterBar.js +489 -37
- package/src/sap/fe/core/converters/controls/ListReport/FilterBar.ts +506 -58
- 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 +6 -6
- package/src/sap/fe/core/converters/controls/ObjectPage/SubSection.ts +9 -15
- package/src/sap/fe/core/converters/helpers/Aggregation.js +18 -3
- package/src/sap/fe/core/converters/helpers/Aggregation.ts +28 -5
- package/src/sap/fe/core/converters/helpers/ID.js +9 -1
- package/src/sap/fe/core/converters/helpers/ID.ts +4 -0
- package/src/sap/fe/core/converters/helpers/IssueManager.js +7 -1
- package/src/sap/fe/core/converters/helpers/IssueManager.ts +6 -0
- package/src/sap/fe/core/converters/objectPage/HeaderAndFooterAction.js +4 -4
- package/src/sap/fe/core/converters/objectPage/HeaderAndFooterAction.ts +3 -3
- package/src/sap/fe/core/converters/templates/ListReportConverter.js +29 -11
- package/src/sap/fe/core/converters/templates/ListReportConverter.ts +36 -20
- package/src/sap/fe/core/designtime/AppComponent.designtime.js +13 -3
- package/src/sap/fe/core/formatters/CriticalityFormatter.js +1 -1
- package/src/sap/fe/core/formatters/CriticalityFormatter.ts +1 -1
- package/src/sap/fe/core/formatters/FPMFormatter.js +1 -1
- package/src/sap/fe/core/formatters/FPMFormatter.ts +4 -10
- package/src/sap/fe/core/formatters/KPIFormatter.js +1 -1
- package/src/sap/fe/core/formatters/KPIFormatter.ts +3 -1
- package/src/sap/fe/core/formatters/TableFormatter.js +65 -31
- package/src/sap/fe/core/formatters/TableFormatter.ts +62 -30
- package/src/sap/fe/core/formatters/ValueFormatter.js +30 -5
- package/src/sap/fe/core/formatters/ValueFormatter.ts +30 -7
- package/src/sap/fe/core/fpm/Component.js +3 -2
- package/src/sap/fe/core/helpers/AppStartupHelper.js +359 -0
- package/src/sap/fe/core/helpers/AppStartupHelper.ts +391 -0
- package/src/sap/fe/core/helpers/BindingExpression.js +479 -464
- package/src/sap/fe/core/helpers/BindingExpression.ts +477 -483
- package/src/sap/fe/core/helpers/ClassSupport.js +27 -15
- package/src/sap/fe/core/helpers/ClassSupport.ts +31 -20
- package/src/sap/fe/core/helpers/DynamicAnnotationPathHelper.js +63 -59
- package/src/sap/fe/core/helpers/DynamicAnnotationPathHelper.ts +56 -0
- package/src/sap/fe/core/helpers/EditState.js +81 -84
- package/src/sap/fe/core/helpers/EditState.ts +81 -0
- package/src/sap/fe/core/helpers/ExcelFormatHelper.js +62 -48
- package/src/sap/fe/core/helpers/ExcelFormatHelper.ts +49 -0
- package/src/sap/fe/core/helpers/FPMHelper.js +52 -56
- package/src/sap/fe/core/helpers/FPMHelper.ts +62 -0
- package/src/sap/fe/core/helpers/KeepAliveHelper.js +210 -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 +687 -0
- package/src/sap/fe/core/helpers/ModelHelper.js +229 -174
- package/src/sap/fe/core/helpers/ModelHelper.ts +227 -0
- package/src/sap/fe/core/helpers/PasteHelper.js +210 -132
- package/src/sap/fe/core/helpers/PasteHelper.ts +196 -0
- package/src/sap/fe/core/helpers/SemanticDateOperators.js +332 -313
- package/src/sap/fe/core/helpers/SemanticDateOperators.ts +330 -0
- package/src/sap/fe/core/helpers/SemanticKeyHelper.js +66 -67
- package/src/sap/fe/core/helpers/SemanticKeyHelper.ts +73 -0
- package/src/sap/fe/core/helpers/StableIdHelper.js +4 -7
- package/src/sap/fe/core/helpers/StableIdHelper.ts +2 -6
- package/src/sap/fe/core/jsx-runtime/jsx.js +1 -1
- package/src/sap/fe/core/jsx-runtime/jsx.ts +1 -1
- package/src/sap/fe/core/library.js +30 -3
- package/src/sap/fe/core/library.support.js +12 -5
- 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 +72 -10
- package/src/sap/fe/core/messagebundle_ar.properties +41 -0
- package/src/sap/fe/core/messagebundle_bg.properties +41 -0
- package/src/sap/fe/core/messagebundle_ca.properties +41 -0
- package/src/sap/fe/core/messagebundle_cs.properties +42 -1
- package/src/sap/fe/core/messagebundle_cy.properties +41 -0
- package/src/sap/fe/core/messagebundle_da.properties +41 -0
- package/src/sap/fe/core/messagebundle_de.properties +41 -0
- package/src/sap/fe/core/messagebundle_el.properties +41 -0
- package/src/sap/fe/core/messagebundle_en.properties +41 -0
- package/src/sap/fe/core/messagebundle_en_GB.properties +41 -0
- package/src/sap/fe/core/messagebundle_en_US_sappsd.properties +41 -0
- package/src/sap/fe/core/messagebundle_en_US_saprigi.properties +35 -0
- package/src/sap/fe/core/messagebundle_en_US_saptrc.properties +41 -0
- package/src/sap/fe/core/messagebundle_es.properties +41 -0
- package/src/sap/fe/core/messagebundle_es_MX.properties +41 -0
- package/src/sap/fe/core/messagebundle_et.properties +41 -0
- package/src/sap/fe/core/messagebundle_fi.properties +41 -0
- package/src/sap/fe/core/messagebundle_fr.properties +46 -5
- package/src/sap/fe/core/messagebundle_fr_CA.properties +41 -0
- package/src/sap/fe/core/messagebundle_hi.properties +41 -0
- package/src/sap/fe/core/messagebundle_hr.properties +41 -0
- package/src/sap/fe/core/messagebundle_hu.properties +42 -1
- package/src/sap/fe/core/messagebundle_id.properties +45 -4
- package/src/sap/fe/core/messagebundle_it.properties +41 -0
- package/src/sap/fe/core/messagebundle_iw.properties +41 -0
- package/src/sap/fe/core/messagebundle_ja.properties +50 -9
- package/src/sap/fe/core/messagebundle_kk.properties +41 -0
- package/src/sap/fe/core/messagebundle_ko.properties +41 -0
- package/src/sap/fe/core/messagebundle_lt.properties +41 -0
- package/src/sap/fe/core/messagebundle_lv.properties +41 -0
- package/src/sap/fe/core/messagebundle_ms.properties +41 -0
- package/src/sap/fe/core/messagebundle_nl.properties +41 -0
- package/src/sap/fe/core/messagebundle_no.properties +41 -0
- package/src/sap/fe/core/messagebundle_pl.properties +41 -0
- package/src/sap/fe/core/messagebundle_pt.properties +43 -2
- package/src/sap/fe/core/messagebundle_pt_PT.properties +41 -0
- package/src/sap/fe/core/messagebundle_ro.properties +41 -0
- package/src/sap/fe/core/messagebundle_ru.properties +41 -0
- package/src/sap/fe/core/messagebundle_sh.properties +41 -0
- package/src/sap/fe/core/messagebundle_sk.properties +41 -0
- package/src/sap/fe/core/messagebundle_sl.properties +41 -0
- package/src/sap/fe/core/messagebundle_sv.properties +42 -1
- package/src/sap/fe/core/messagebundle_th.properties +41 -0
- package/src/sap/fe/core/messagebundle_tr.properties +41 -0
- package/src/sap/fe/core/messagebundle_uk.properties +41 -0
- package/src/sap/fe/core/messagebundle_vi.properties +41 -0
- package/src/sap/fe/core/messagebundle_zh_CN.properties +41 -0
- package/src/sap/fe/core/messagebundle_zh_TW.properties +41 -0
- package/src/sap/fe/core/services/AsyncComponentServiceFactory.js +2 -2
- package/src/sap/fe/core/services/AsyncComponentServiceFactory.ts +3 -1
- package/src/sap/fe/core/services/CacheHandlerServiceFactory.js +269 -202
- package/src/sap/fe/core/services/CacheHandlerServiceFactory.ts +212 -0
- package/src/sap/fe/core/services/EnvironmentServiceFactory.js +4 -3
- package/src/sap/fe/core/services/EnvironmentServiceFactory.ts +9 -5
- package/src/sap/fe/core/services/NavigationServiceFactory.js +406 -300
- package/src/sap/fe/core/services/NavigationServiceFactory.ts +316 -0
- package/src/sap/fe/core/services/ResourceModelServiceFactory.js +149 -81
- package/src/sap/fe/core/services/ResourceModelServiceFactory.ts +80 -0
- package/src/sap/fe/core/services/RoutingServiceFactory.js +987 -1166
- package/src/sap/fe/core/services/RoutingServiceFactory.ts +898 -0
- package/src/sap/fe/core/services/ShellServicesFactory.js +31 -2
- package/src/sap/fe/core/services/ShellServicesFactory.ts +45 -11
- package/src/sap/fe/core/services/SideEffectsServiceFactory.js +41 -84
- package/src/sap/fe/core/services/SideEffectsServiceFactory.ts +56 -99
- package/src/sap/fe/core/services/TemplatedViewServiceFactory.js +461 -478
- package/src/sap/fe/core/services/TemplatedViewServiceFactory.ts +453 -0
- package/src/sap/fe/core/services/view/TemplatingErrorPage.controller.js +10 -8
- package/src/sap/fe/core/services/view/TemplatingErrorPage.controller.ts +8 -0
- package/src/sap/fe/core/support/AnnotationIssue.support.js +15 -3
- package/src/sap/fe/core/support/AnnotationIssue.support.ts +16 -2
- package/src/sap/fe/core/support/CollectionFacetUnsupportedLevel.support.js +2 -2
- package/src/sap/fe/core/support/CollectionFacetUnsupportedLevel.support.ts +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 +6 -24
- package/src/sap/fe/core/templating/DataModelPathHelper.ts +10 -23
- 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 +80 -7
- package/src/sap/fe/core/templating/EntitySetHelper.ts +42 -2
- package/src/sap/fe/core/templating/FieldControlHelper.js +8 -8
- package/src/sap/fe/core/templating/FieldControlHelper.ts +25 -7
- package/src/sap/fe/core/templating/FilterHelper.js +139 -70
- package/src/sap/fe/core/templating/FilterHelper.ts +140 -70
- 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 +45 -113
- package/src/sap/fe/core/templating/UIFormatters.ts +39 -76
- package/src/sap/fe/core/type/Email.js +1 -1
- package/src/sap/fe/core/type/Email.ts +4 -6
- package/ui5.yaml +0 -3
|
@@ -0,0 +1,453 @@
|
|
|
1
|
+
import Service from "sap/ui/core/service/Service";
|
|
2
|
+
import ServiceFactory from "sap/ui/core/service/ServiceFactory";
|
|
3
|
+
import ServiceFactoryRegistry from "sap/ui/core/service/ServiceFactoryRegistry";
|
|
4
|
+
import ManagedObjectModel from "sap/ui/model/base/ManagedObjectModel";
|
|
5
|
+
import View from "sap/ui/core/mvc/View";
|
|
6
|
+
import Component from "sap/ui/core/Component";
|
|
7
|
+
import JSONModel from "sap/ui/model/json/JSONModel";
|
|
8
|
+
import Log from "sap/base/Log";
|
|
9
|
+
import TemplateModel from "sap/fe/core/TemplateModel";
|
|
10
|
+
import DynamicAnnotationPathHelper from "sap/fe/core/helpers/DynamicAnnotationPathHelper";
|
|
11
|
+
import CacheManager from "sap/ui/core/cache/CacheManager";
|
|
12
|
+
import VersionInfo from "sap/ui/VersionInfo";
|
|
13
|
+
import Device from "sap/ui/Device";
|
|
14
|
+
import UriParameters from "sap/base/util/UriParameters";
|
|
15
|
+
import { ServiceContext } from "sap/ui/core/service";
|
|
16
|
+
import { ResourceModelService } from "./ResourceModelServiceFactory";
|
|
17
|
+
import { AppComponent } from "sap/fe/core";
|
|
18
|
+
import { CacheHandlerService } from "sap/fe/core/services/CacheHandlerServiceFactory";
|
|
19
|
+
import { ResourceModel } from "sap/fe/macros";
|
|
20
|
+
import Model from "sap/ui/model/Model";
|
|
21
|
+
|
|
22
|
+
type TemplatedViewServiceSettings = {};
|
|
23
|
+
|
|
24
|
+
class TemplatedViewService extends Service<TemplatedViewServiceSettings> {
|
|
25
|
+
initPromise!: Promise<any>;
|
|
26
|
+
oView!: View;
|
|
27
|
+
oResourceModelService!: ResourceModelService;
|
|
28
|
+
oCacheHandlerService!: CacheHandlerService;
|
|
29
|
+
oFactory!: TemplatedViewServiceFactory;
|
|
30
|
+
resourceModel!: ResourceModel;
|
|
31
|
+
stableId!: string;
|
|
32
|
+
TemplateConverter: any;
|
|
33
|
+
MetaModelConverter: any;
|
|
34
|
+
init() {
|
|
35
|
+
const aServiceDependencies = [];
|
|
36
|
+
const oContext = this.getContext();
|
|
37
|
+
const oComponent = oContext.scopeObject;
|
|
38
|
+
const oAppComponent = Component.getOwnerComponentFor(oComponent) as AppComponent;
|
|
39
|
+
const oMetaModel = oAppComponent.getMetaModel();
|
|
40
|
+
const sStableId = oAppComponent.getMetadata().getComponentName() + "::" + oAppComponent.getLocalId(oComponent.getId());
|
|
41
|
+
const aEnhanceI18n = oComponent.getEnhanceI18n() || [];
|
|
42
|
+
let sAppNamespace;
|
|
43
|
+
this.oFactory = oContext.factory;
|
|
44
|
+
if (aEnhanceI18n) {
|
|
45
|
+
sAppNamespace = oAppComponent.getMetadata().getComponentName();
|
|
46
|
+
for (let i = 0; i < aEnhanceI18n.length; i++) {
|
|
47
|
+
// In order to support text-verticalization applications can also passs a resource model defined in the manifest
|
|
48
|
+
// UI5 takes care of text-verticalization for resource models defined in the manifest
|
|
49
|
+
// Hence check if the given key is a resource model defined in the manifest
|
|
50
|
+
// if so this model should be used to enhance the sap.fe resource model so pass it as it is
|
|
51
|
+
const oResourceModel = oAppComponent.getModel(aEnhanceI18n[i]);
|
|
52
|
+
if (oResourceModel && oResourceModel.isA("sap.ui.model.resource.ResourceModel")) {
|
|
53
|
+
aEnhanceI18n[i] = oResourceModel;
|
|
54
|
+
} else {
|
|
55
|
+
aEnhanceI18n[i] = sAppNamespace + "." + aEnhanceI18n[i].replace(".properties", "");
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
const sCacheIdentifier =
|
|
61
|
+
oAppComponent.getMetadata().getName() +
|
|
62
|
+
"_" +
|
|
63
|
+
sStableId +
|
|
64
|
+
"_" +
|
|
65
|
+
sap.ui
|
|
66
|
+
.getCore()
|
|
67
|
+
.getConfiguration()
|
|
68
|
+
.getLanguageTag();
|
|
69
|
+
aServiceDependencies.push(
|
|
70
|
+
ServiceFactoryRegistry.get("sap.fe.core.services.ResourceModelService")
|
|
71
|
+
.createInstance({
|
|
72
|
+
scopeType: "component",
|
|
73
|
+
scopeObject: oComponent,
|
|
74
|
+
settings: {
|
|
75
|
+
bundles: ["sap.fe.core.messagebundle", "sap.fe.macros.messagebundle", "sap.fe.templates.messagebundle"],
|
|
76
|
+
enhanceI18n: aEnhanceI18n,
|
|
77
|
+
modelName: "sap.fe.i18n"
|
|
78
|
+
}
|
|
79
|
+
})
|
|
80
|
+
.then((oResourceModelService: ResourceModelService) => {
|
|
81
|
+
this.oResourceModelService = oResourceModelService;
|
|
82
|
+
return oResourceModelService.getResourceModel();
|
|
83
|
+
})
|
|
84
|
+
);
|
|
85
|
+
|
|
86
|
+
aServiceDependencies.push(
|
|
87
|
+
ServiceFactoryRegistry.get("sap.fe.core.services.CacheHandlerService")
|
|
88
|
+
.createInstance({
|
|
89
|
+
settings: {
|
|
90
|
+
metaModel: oMetaModel,
|
|
91
|
+
appComponent: oAppComponent,
|
|
92
|
+
component: oComponent
|
|
93
|
+
}
|
|
94
|
+
})
|
|
95
|
+
.then((oCacheHandlerService: any) => {
|
|
96
|
+
this.oCacheHandlerService = oCacheHandlerService;
|
|
97
|
+
return oCacheHandlerService.validateCacheKey(sCacheIdentifier);
|
|
98
|
+
})
|
|
99
|
+
);
|
|
100
|
+
aServiceDependencies.push(
|
|
101
|
+
(VersionInfo as any)
|
|
102
|
+
.load()
|
|
103
|
+
.then(function(oInfo: any) {
|
|
104
|
+
let sTimestamp = "";
|
|
105
|
+
if (!oInfo.libraries) {
|
|
106
|
+
sTimestamp = (sap.ui as any).buildinfo.buildtime;
|
|
107
|
+
} else {
|
|
108
|
+
oInfo.libraries.forEach(function(oLibrary: any) {
|
|
109
|
+
sTimestamp += oLibrary.buildTimestamp;
|
|
110
|
+
});
|
|
111
|
+
}
|
|
112
|
+
return sTimestamp;
|
|
113
|
+
})
|
|
114
|
+
.catch(function() {
|
|
115
|
+
return "<NOVALUE>";
|
|
116
|
+
})
|
|
117
|
+
);
|
|
118
|
+
|
|
119
|
+
let sPageModelCacheKey = "";
|
|
120
|
+
this.initPromise = Promise.all(aServiceDependencies)
|
|
121
|
+
.then((aDependenciesResult: any[]) => {
|
|
122
|
+
const sCacheKey = aDependenciesResult[1];
|
|
123
|
+
const sVersionInfo = aDependenciesResult[2];
|
|
124
|
+
const oShellServices = oAppComponent.getShellServices();
|
|
125
|
+
const oSideEffectsServices = oAppComponent.getSideEffectsService();
|
|
126
|
+
|
|
127
|
+
oSideEffectsServices.initializeSideEffects(oAppComponent.getEnvironmentCapabilities().getCapabilities());
|
|
128
|
+
|
|
129
|
+
sPageModelCacheKey = sCacheKey + "-" + sVersionInfo + "-" + sStableId + "-" + oShellServices.instanceType + "-pageModel";
|
|
130
|
+
return Promise.all(aDependenciesResult.concat([this._getCachedModel(sPageModelCacheKey)]));
|
|
131
|
+
})
|
|
132
|
+
.then((aDependenciesResult: any[]) => {
|
|
133
|
+
const oResourceModel = aDependenciesResult[0];
|
|
134
|
+
const sCacheKey = aDependenciesResult[1];
|
|
135
|
+
const oPageModelCache = aDependenciesResult[3];
|
|
136
|
+
return new Promise(resolve => {
|
|
137
|
+
sap.ui.require(
|
|
138
|
+
["sap/fe/core/converters/TemplateConverter", "sap/fe/core/converters/MetaModelConverter"],
|
|
139
|
+
(TemplateConverter: any, MetaModelConverter: any) => {
|
|
140
|
+
resolve(
|
|
141
|
+
this.createView(
|
|
142
|
+
oResourceModel,
|
|
143
|
+
sStableId,
|
|
144
|
+
sCacheKey,
|
|
145
|
+
sPageModelCacheKey,
|
|
146
|
+
oPageModelCache,
|
|
147
|
+
TemplateConverter,
|
|
148
|
+
MetaModelConverter
|
|
149
|
+
)
|
|
150
|
+
);
|
|
151
|
+
}
|
|
152
|
+
);
|
|
153
|
+
});
|
|
154
|
+
})
|
|
155
|
+
.then(function(sCacheKey: any) {
|
|
156
|
+
const oCacheHandlerService = ServiceFactoryRegistry.get("sap.fe.core.services.CacheHandlerService").getInstance(oMetaModel);
|
|
157
|
+
oCacheHandlerService.invalidateIfNeeded(sCacheKey, sCacheIdentifier);
|
|
158
|
+
});
|
|
159
|
+
}
|
|
160
|
+
_getCachedModel(sCacheKey: any) {
|
|
161
|
+
if (
|
|
162
|
+
sap.ui
|
|
163
|
+
.getCore()
|
|
164
|
+
.getConfiguration()
|
|
165
|
+
.getViewCache()
|
|
166
|
+
) {
|
|
167
|
+
return CacheManager.get(sCacheKey);
|
|
168
|
+
}
|
|
169
|
+
return undefined;
|
|
170
|
+
}
|
|
171
|
+
_setCachedModel(sCacheKey: string, oCacheModel: any) {
|
|
172
|
+
if (
|
|
173
|
+
sap.ui
|
|
174
|
+
.getCore()
|
|
175
|
+
.getConfiguration()
|
|
176
|
+
.getViewCache()
|
|
177
|
+
) {
|
|
178
|
+
CacheManager.set(sCacheKey, oCacheModel);
|
|
179
|
+
}
|
|
180
|
+
return undefined;
|
|
181
|
+
}
|
|
182
|
+
/**
|
|
183
|
+
* Refresh the current view using the same configuration as before.
|
|
184
|
+
* This is useful for our demokit !
|
|
185
|
+
*
|
|
186
|
+
* @param oComponent
|
|
187
|
+
* @returns {Promise<void>}
|
|
188
|
+
* @private
|
|
189
|
+
*/
|
|
190
|
+
refreshView(oComponent: any) {
|
|
191
|
+
const oRootView = oComponent.getRootControl();
|
|
192
|
+
if (oRootView) {
|
|
193
|
+
oRootView.destroy();
|
|
194
|
+
} else if (this.oView) {
|
|
195
|
+
this.oView.destroy();
|
|
196
|
+
}
|
|
197
|
+
return this.createView(this.resourceModel, this.stableId, "", "", undefined, this.TemplateConverter, this.MetaModelConverter)
|
|
198
|
+
.then(function() {
|
|
199
|
+
oComponent.oContainer.invalidate();
|
|
200
|
+
})
|
|
201
|
+
.catch(function(oError: any) {
|
|
202
|
+
oComponent.oContainer.invalidate();
|
|
203
|
+
Log.error(oError);
|
|
204
|
+
});
|
|
205
|
+
}
|
|
206
|
+
createView(
|
|
207
|
+
oResourceModel: any,
|
|
208
|
+
sStableId: any,
|
|
209
|
+
sCacheKey: any,
|
|
210
|
+
sPageModelCacheKey: any,
|
|
211
|
+
oPageModelCache: any,
|
|
212
|
+
TemplateConverter: any,
|
|
213
|
+
MetaModelConverter: any
|
|
214
|
+
) {
|
|
215
|
+
this.resourceModel = oResourceModel;
|
|
216
|
+
this.stableId = sStableId;
|
|
217
|
+
this.TemplateConverter = TemplateConverter;
|
|
218
|
+
this.MetaModelConverter = MetaModelConverter;
|
|
219
|
+
const oContext = this.getContext();
|
|
220
|
+
const mServiceSettings = oContext.settings;
|
|
221
|
+
const sConverterType = mServiceSettings.converterType;
|
|
222
|
+
const oComponent = oContext.scopeObject;
|
|
223
|
+
const oAppComponent: AppComponent = Component.getOwnerComponentFor(oComponent);
|
|
224
|
+
const sFullContextPath = oAppComponent.getRoutingService().getTargetInformationFor(oComponent).options.settings.fullContextPath;
|
|
225
|
+
const oMetaModel = oAppComponent.getMetaModel();
|
|
226
|
+
const oManifestContent: any = oAppComponent.getManifest();
|
|
227
|
+
const oDeviceModel = new JSONModel(sap.ui.Device).setDefaultBindingMode("OneWay");
|
|
228
|
+
const oManifestModel = new JSONModel(oManifestContent);
|
|
229
|
+
const bError = false;
|
|
230
|
+
let oPageModel: TemplateModel, oViewDataModel: Model, oViewSettings: any, mViewData: any;
|
|
231
|
+
|
|
232
|
+
function getViewSettings() {
|
|
233
|
+
const aSplitPath = sFullContextPath.split("/");
|
|
234
|
+
const sEntitySetPath = aSplitPath.reduce(function(sPathSoFar: any, sNextPathPart: any) {
|
|
235
|
+
if (sNextPathPart === "") {
|
|
236
|
+
return sPathSoFar;
|
|
237
|
+
}
|
|
238
|
+
if (sPathSoFar === "") {
|
|
239
|
+
sPathSoFar = "/" + sNextPathPart;
|
|
240
|
+
} else {
|
|
241
|
+
const oTarget = oMetaModel.getObject(sPathSoFar + "/$NavigationPropertyBinding/" + sNextPathPart);
|
|
242
|
+
if (oTarget && Object.keys(oTarget).length > 0) {
|
|
243
|
+
sPathSoFar += "/$NavigationPropertyBinding";
|
|
244
|
+
}
|
|
245
|
+
sPathSoFar += "/" + sNextPathPart;
|
|
246
|
+
}
|
|
247
|
+
return sPathSoFar;
|
|
248
|
+
}, "");
|
|
249
|
+
const oViewSettings = {
|
|
250
|
+
type: "XML",
|
|
251
|
+
preprocessors: {
|
|
252
|
+
xml: {
|
|
253
|
+
bindingContexts: {
|
|
254
|
+
entitySet: sEntitySetPath ? oMetaModel.createBindingContext(sEntitySetPath) : null,
|
|
255
|
+
fullContextPath: sFullContextPath ? oMetaModel.createBindingContext(sFullContextPath) : null,
|
|
256
|
+
contextPath: sFullContextPath ? oMetaModel.createBindingContext(sFullContextPath) : null,
|
|
257
|
+
converterContext: oPageModel.createBindingContext("/", undefined, { noResolve: true }),
|
|
258
|
+
viewData: mViewData ? oViewDataModel.createBindingContext("/") : null
|
|
259
|
+
},
|
|
260
|
+
models: {
|
|
261
|
+
entitySet: oMetaModel,
|
|
262
|
+
fullContextPath: oMetaModel,
|
|
263
|
+
contextPath: oMetaModel,
|
|
264
|
+
"sap.fe.i18n": oResourceModel,
|
|
265
|
+
metaModel: oMetaModel,
|
|
266
|
+
"device": oDeviceModel, // TODO: discuss names here
|
|
267
|
+
manifest: oManifestModel,
|
|
268
|
+
converterContext: oPageModel,
|
|
269
|
+
viewData: oViewDataModel
|
|
270
|
+
},
|
|
271
|
+
appComponent: oAppComponent
|
|
272
|
+
}
|
|
273
|
+
},
|
|
274
|
+
id: sStableId,
|
|
275
|
+
viewName: mServiceSettings.viewName || oComponent.getViewName(),
|
|
276
|
+
viewData: mViewData,
|
|
277
|
+
cache: { keys: [sCacheKey] },
|
|
278
|
+
models: {
|
|
279
|
+
"sap.fe.i18n": oResourceModel
|
|
280
|
+
},
|
|
281
|
+
height: "100%"
|
|
282
|
+
};
|
|
283
|
+
return oViewSettings;
|
|
284
|
+
}
|
|
285
|
+
const createErrorPage = (reason: any) => {
|
|
286
|
+
// just replace the view name and add an additional model containing the reason, but
|
|
287
|
+
// keep the other settings
|
|
288
|
+
Log.error(reason.message, reason);
|
|
289
|
+
oViewSettings.viewName = mServiceSettings.errorViewName || "sap.fe.core.services.view.TemplatingErrorPage";
|
|
290
|
+
oViewSettings.preprocessors.xml.models["error"] = new JSONModel(reason);
|
|
291
|
+
|
|
292
|
+
return oComponent.runAsOwner(() => {
|
|
293
|
+
return View.create(oViewSettings).then((oView: any) => {
|
|
294
|
+
this.oView = oView;
|
|
295
|
+
this.oView.setModel(new ManagedObjectModel(this.oView), "$view");
|
|
296
|
+
oComponent.setAggregation("rootControl", this.oView);
|
|
297
|
+
return sCacheKey;
|
|
298
|
+
});
|
|
299
|
+
});
|
|
300
|
+
};
|
|
301
|
+
return oAppComponent
|
|
302
|
+
.getService("routingService")
|
|
303
|
+
.then((oRoutingService: any) => {
|
|
304
|
+
// Retrieve the viewLevel for the component
|
|
305
|
+
const oTargetInfo = oRoutingService.getTargetInformationFor(oComponent);
|
|
306
|
+
const mOutbounds =
|
|
307
|
+
oManifestContent["sap.app"] &&
|
|
308
|
+
oManifestContent["sap.app"].crossNavigation &&
|
|
309
|
+
oManifestContent["sap.app"].crossNavigation.outbounds;
|
|
310
|
+
const mNavigation = oComponent.getNavigation() || {};
|
|
311
|
+
Object.keys(mNavigation).forEach(function(navigationObjectKey: string) {
|
|
312
|
+
const navigationObject = mNavigation[navigationObjectKey];
|
|
313
|
+
let outboundConfig;
|
|
314
|
+
if (navigationObject.detail && navigationObject.detail.outbound && mOutbounds[navigationObject.detail.outbound]) {
|
|
315
|
+
outboundConfig = mOutbounds[navigationObject.detail.outbound];
|
|
316
|
+
navigationObject.detail.outboundDetail = {
|
|
317
|
+
semanticObject: outboundConfig.semanticObject,
|
|
318
|
+
action: outboundConfig.action,
|
|
319
|
+
parameters: outboundConfig.parameters
|
|
320
|
+
};
|
|
321
|
+
}
|
|
322
|
+
if (navigationObject.create && navigationObject.create.outbound && mOutbounds[navigationObject.create.outbound]) {
|
|
323
|
+
outboundConfig = mOutbounds[navigationObject.create.outbound];
|
|
324
|
+
navigationObject.create.outboundDetail = {
|
|
325
|
+
semanticObject: outboundConfig.semanticObject,
|
|
326
|
+
action: outboundConfig.action,
|
|
327
|
+
parameters: outboundConfig.parameters
|
|
328
|
+
};
|
|
329
|
+
}
|
|
330
|
+
});
|
|
331
|
+
mViewData = {
|
|
332
|
+
navigation: mNavigation,
|
|
333
|
+
viewLevel: oTargetInfo.viewLevel,
|
|
334
|
+
stableId: sStableId,
|
|
335
|
+
contentDensities: oManifestContent["sap.ui5"].contentDensities,
|
|
336
|
+
resourceBundle: oResourceModel.__bundle,
|
|
337
|
+
fullContextPath: sFullContextPath,
|
|
338
|
+
isDesktop: (Device as any).system.desktop,
|
|
339
|
+
isPhone: (Device as any).system.phone
|
|
340
|
+
};
|
|
341
|
+
|
|
342
|
+
if (oComponent.getViewData) {
|
|
343
|
+
Object.assign(mViewData, oComponent.getViewData());
|
|
344
|
+
}
|
|
345
|
+
|
|
346
|
+
const oShellServices = oAppComponent.getShellServices();
|
|
347
|
+
mViewData.converterType = sConverterType;
|
|
348
|
+
mViewData.shellContentDensity = oShellServices.getContentDensity();
|
|
349
|
+
mViewData.useNewLazyLoading = UriParameters.fromQuery(window.location.search).get("sap-fe-xx-lazyloadingtest") === "true";
|
|
350
|
+
mViewData.retrieveTextFromValueList =
|
|
351
|
+
oManifestContent["sap.fe"] && oManifestContent["sap.fe"].form
|
|
352
|
+
? oManifestContent["sap.fe"].form.retrieveTextFromValueList
|
|
353
|
+
: undefined;
|
|
354
|
+
oViewDataModel = new JSONModel(mViewData);
|
|
355
|
+
if (mViewData && mViewData.controlConfiguration) {
|
|
356
|
+
Object.keys(mViewData.controlConfiguration).forEach(function(sAnnotationPath: string) {
|
|
357
|
+
if (sAnnotationPath.indexOf("[") !== -1) {
|
|
358
|
+
const sTargetAnnotationPath = DynamicAnnotationPathHelper.resolveDynamicExpression(sAnnotationPath, oMetaModel);
|
|
359
|
+
mViewData.controlConfiguration[sTargetAnnotationPath] = mViewData.controlConfiguration[sAnnotationPath];
|
|
360
|
+
}
|
|
361
|
+
});
|
|
362
|
+
}
|
|
363
|
+
MetaModelConverter.convertTypes(oMetaModel, oAppComponent.getEnvironmentCapabilities().getCapabilities());
|
|
364
|
+
oPageModel = new TemplateModel(() => {
|
|
365
|
+
try {
|
|
366
|
+
if (!!oPageModelCache) {
|
|
367
|
+
return oPageModelCache;
|
|
368
|
+
} else {
|
|
369
|
+
const oDiagnostics = oAppComponent.getDiagnostics();
|
|
370
|
+
const iIssueCount = oDiagnostics.getIssues().length;
|
|
371
|
+
const oConverterPageModel = TemplateConverter.convertPage(
|
|
372
|
+
sConverterType,
|
|
373
|
+
oMetaModel,
|
|
374
|
+
mViewData,
|
|
375
|
+
oDiagnostics,
|
|
376
|
+
sFullContextPath,
|
|
377
|
+
oAppComponent.getEnvironmentCapabilities().getCapabilities()
|
|
378
|
+
);
|
|
379
|
+
|
|
380
|
+
const aIssues = oDiagnostics.getIssues();
|
|
381
|
+
const aAddedIssues = aIssues.slice(iIssueCount);
|
|
382
|
+
if (aAddedIssues.length > 0) {
|
|
383
|
+
Log.warning(
|
|
384
|
+
"Some issues have been detected in your project, please check the UI5 support assistant rule for sap.fe.core"
|
|
385
|
+
);
|
|
386
|
+
}
|
|
387
|
+
// Fire and forget in the cache
|
|
388
|
+
this._setCachedModel(sPageModelCacheKey, oConverterPageModel);
|
|
389
|
+
return oConverterPageModel;
|
|
390
|
+
}
|
|
391
|
+
} catch (error) {
|
|
392
|
+
Log.error(error, error);
|
|
393
|
+
return {};
|
|
394
|
+
}
|
|
395
|
+
}, oMetaModel);
|
|
396
|
+
|
|
397
|
+
if (!bError) {
|
|
398
|
+
oViewSettings = getViewSettings();
|
|
399
|
+
// Setting the pageModel on the component for potential reuse
|
|
400
|
+
oComponent.setModel(oPageModel, "_pageModel");
|
|
401
|
+
return oComponent.runAsOwner(() => {
|
|
402
|
+
return View.create(oViewSettings)
|
|
403
|
+
.catch(createErrorPage)
|
|
404
|
+
.then((oView: any) => {
|
|
405
|
+
this.oView = oView;
|
|
406
|
+
this.oView.setModel(new ManagedObjectModel(this.oView), "$view");
|
|
407
|
+
this.oView.setModel(oViewDataModel, "viewData");
|
|
408
|
+
oComponent.setAggregation("rootControl", this.oView);
|
|
409
|
+
return sCacheKey;
|
|
410
|
+
})
|
|
411
|
+
.catch(Log.error);
|
|
412
|
+
});
|
|
413
|
+
}
|
|
414
|
+
})
|
|
415
|
+
.catch(function(error: any) {
|
|
416
|
+
Log.error(error.message, error);
|
|
417
|
+
throw new Error("Error while creating view : " + error);
|
|
418
|
+
});
|
|
419
|
+
}
|
|
420
|
+
getView() {
|
|
421
|
+
return this.oView;
|
|
422
|
+
}
|
|
423
|
+
getInterface(): any {
|
|
424
|
+
return this;
|
|
425
|
+
}
|
|
426
|
+
exit() {
|
|
427
|
+
// Deregister global instance
|
|
428
|
+
this.oResourceModelService && this.oResourceModelService.destroy();
|
|
429
|
+
this.oCacheHandlerService && this.oCacheHandlerService.destroy();
|
|
430
|
+
this.oFactory.removeGlobalInstance();
|
|
431
|
+
}
|
|
432
|
+
}
|
|
433
|
+
class TemplatedViewServiceFactory extends ServiceFactory<TemplatedViewServiceSettings> {
|
|
434
|
+
_oInstanceRegistry: Record<string, TemplatedViewService> = {};
|
|
435
|
+
static iCreatingViews: 0;
|
|
436
|
+
createInstance(oServiceContext: ServiceContext<TemplatedViewServiceSettings>) {
|
|
437
|
+
TemplatedViewServiceFactory.iCreatingViews++;
|
|
438
|
+
|
|
439
|
+
const oTemplatedViewService = new TemplatedViewService(Object.assign({ factory: this }, oServiceContext));
|
|
440
|
+
return oTemplatedViewService.initPromise.then(function() {
|
|
441
|
+
TemplatedViewServiceFactory.iCreatingViews--;
|
|
442
|
+
return oTemplatedViewService;
|
|
443
|
+
});
|
|
444
|
+
}
|
|
445
|
+
removeGlobalInstance() {
|
|
446
|
+
this._oInstanceRegistry = {};
|
|
447
|
+
}
|
|
448
|
+
static getNumberOfViewsInCreationState() {
|
|
449
|
+
return TemplatedViewServiceFactory.iCreatingViews;
|
|
450
|
+
}
|
|
451
|
+
}
|
|
452
|
+
|
|
453
|
+
export default TemplatedViewServiceFactory;
|
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* SAPUI5
|
|
3
|
-
*
|
|
2
|
+
* SAP UI development toolkit for HTML5 (SAPUI5)
|
|
3
|
+
* (c) Copyright 2009-2021 SAP SE. All rights reserved
|
|
4
4
|
*/
|
|
5
|
-
sap.ui.define(["sap/ui/core/mvc/Controller", "sap/fe/core/controllerextensions/InternalRouting"], function(Controller, InternalRouting) {
|
|
6
|
-
|
|
5
|
+
sap.ui.define(["sap/ui/core/mvc/Controller", "sap/fe/core/controllerextensions/InternalRouting"], function (Controller, InternalRouting) {
|
|
6
|
+
"use strict";
|
|
7
7
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
8
|
+
var TemplatingErrorPage = Controller.extend("sap.fe.core.services.view.TemplatingErrorPage", {
|
|
9
|
+
_routing: InternalRouting
|
|
10
|
+
});
|
|
11
|
+
return TemplatingErrorPage;
|
|
12
|
+
}, false);
|
|
13
|
+
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIlRlbXBsYXRpbmdFcnJvclBhZ2UuY29udHJvbGxlci50cyJdLCJuYW1lcyI6WyJUZW1wbGF0aW5nRXJyb3JQYWdlIiwiQ29udHJvbGxlciIsImV4dGVuZCIsIl9yb3V0aW5nIiwiSW50ZXJuYWxSb3V0aW5nIl0sIm1hcHBpbmdzIjoiO0FBQUE7QUFDQTtBQUNBOzs7O0FBQ0EsTUFBTUEsbUJBQW1CLEdBQUdDLFVBQVUsQ0FBQ0MsTUFBWCxDQUFrQiwrQ0FBbEIsRUFBbUU7QUFDOUZDLElBQUFBLFFBQVEsRUFBRUM7QUFEb0YsR0FBbkUsQ0FBNUI7U0FJZUosbUIiLCJzb3VyY2VSb290IjoiLiIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCBDb250cm9sbGVyIGZyb20gXCJzYXAvdWkvY29yZS9tdmMvQ29udHJvbGxlclwiO1xuaW1wb3J0IHsgSW50ZXJuYWxSb3V0aW5nIH0gZnJvbSBcInNhcC9mZS9jb3JlL2NvbnRyb2xsZXJleHRlbnNpb25zXCI7XG5cbmNvbnN0IFRlbXBsYXRpbmdFcnJvclBhZ2UgPSBDb250cm9sbGVyLmV4dGVuZChcInNhcC5mZS5jb3JlLnNlcnZpY2VzLnZpZXcuVGVtcGxhdGluZ0Vycm9yUGFnZVwiLCB7XG5cdF9yb3V0aW5nOiBJbnRlcm5hbFJvdXRpbmdcbn0pO1xuXG5leHBvcnQgZGVmYXVsdCBUZW1wbGF0aW5nRXJyb3JQYWdlO1xuIl19
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import Controller from "sap/ui/core/mvc/Controller";
|
|
2
|
+
import { InternalRouting } from "sap/fe/core/controllerextensions";
|
|
3
|
+
|
|
4
|
+
const TemplatingErrorPage = Controller.extend("sap.fe.core.services.view.TemplatingErrorPage", {
|
|
5
|
+
_routing: InternalRouting
|
|
6
|
+
});
|
|
7
|
+
|
|
8
|
+
export default TemplatingErrorPage;
|
|
@@ -11,7 +11,7 @@ sap.ui.define(["sap/fe/core/support/CommonHelper", "sap/fe/core/converters/helpe
|
|
|
11
11
|
var getIssueByCategory = CommonHelper.getIssueByCategory;
|
|
12
12
|
var Categories = CommonHelper.Categories;
|
|
13
13
|
|
|
14
|
-
var
|
|
14
|
+
var oIncorrectPathAnnotationIssue = {
|
|
15
15
|
id: "annotationIssue",
|
|
16
16
|
title: "Annotations: Incorrect path or target",
|
|
17
17
|
minversion: "1.85",
|
|
@@ -27,12 +27,24 @@ sap.ui.define(["sap/fe/core/support/CommonHelper", "sap/fe/core/converters/helpe
|
|
|
27
27
|
getIssueByCategory(oIssueManager, oCoreFacade, IssueCategory.Annotation);
|
|
28
28
|
}
|
|
29
29
|
};
|
|
30
|
+
var oIgnoredComputedDVAnnotationIssue = {
|
|
31
|
+
id: "ignoredAnnotationIssue",
|
|
32
|
+
title: "Annotations: Ignore Annotation",
|
|
33
|
+
minversion: "1.99",
|
|
34
|
+
audiences: [Audiences.Application],
|
|
35
|
+
categories: [Categories.Usage],
|
|
36
|
+
description: "This rule identifies the ignored annotations",
|
|
37
|
+
resolution: "Only one annotation from either Core.Computed or ComputedDefaultValue must be used",
|
|
38
|
+
check: function (oIssueManager, oCoreFacade) {
|
|
39
|
+
getIssueByCategory(oIssueManager, oCoreFacade, IssueCategory.Annotation, "IgnoredAnnotation");
|
|
40
|
+
}
|
|
41
|
+
};
|
|
30
42
|
|
|
31
43
|
function getRules() {
|
|
32
|
-
return [
|
|
44
|
+
return [oIncorrectPathAnnotationIssue, oIgnoredComputedDVAnnotationIssue];
|
|
33
45
|
}
|
|
34
46
|
|
|
35
47
|
_exports.getRules = getRules;
|
|
36
48
|
return _exports;
|
|
37
49
|
}, false);
|
|
38
|
-
//# sourceMappingURL=data:application/json;charset=utf-8;base64,
|
|
50
|
+
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIkFubm90YXRpb25Jc3N1ZS5zdXBwb3J0LnRzIl0sIm5hbWVzIjpbIm9JbmNvcnJlY3RQYXRoQW5ub3RhdGlvbklzc3VlIiwiaWQiLCJ0aXRsZSIsIm1pbnZlcnNpb24iLCJhdWRpZW5jZXMiLCJBdWRpZW5jZXMiLCJBcHBsaWNhdGlvbiIsImNhdGVnb3JpZXMiLCJDYXRlZ29yaWVzIiwiVXNhZ2UiLCJkZXNjcmlwdGlvbiIsInJlc29sdXRpb24iLCJyZXNvbHV0aW9udXJscyIsImNoZWNrIiwib0lzc3VlTWFuYWdlciIsIm9Db3JlRmFjYWRlIiwiZ2V0SXNzdWVCeUNhdGVnb3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GFubm90YXRpb24gZnJvbSBlaXRoZXIgQ29yZS5Db21wdXRlZCBvciBDb21wdXRlZERlZmF1bHRWYWx1ZSBtdXN0IGJlIHVzZWRcIixcblx0Y2hlY2s6IGZ1bmN0aW9uKG9Jc3N1ZU1hbmFnZXI6IGFueSwgb0NvcmVGYWNhZGU6IGFueSAvKm9TY29wZTogYW55Ki8pIHtcblx0XHRnZXRJc3N1ZUJ5Q2F0ZWdvcnkob0lzc3VlTWFuYWdlciwgb0NvcmVGYWNhZGUsIElzc3VlQ2F0ZWdvcnkuQW5ub3RhdGlvbiwgXCJJZ25vcmVkQW5ub3RhdGlvblwiKTtcblx0fVxufTtcblxuZXhwb3J0IGZ1bmN0aW9uIGdldFJ1bGVzKCkge1xuXHRyZXR1cm4gW29JbmNvcnJlY3RQYXRoQW5ub3RhdGlvbklzc3VlLCBvSWdub3JlZENvbXB1dGVkRFZBbm5vdGF0aW9uSXNzdWVdO1xufVxuIl19
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Categories, getIssueByCategory, Audiences } from "sap/fe/core/support/CommonHelper";
|
|
2
2
|
import { IssueCategory } from "sap/fe/core/converters/helpers/IssueManager";
|
|
3
3
|
|
|
4
|
-
const
|
|
4
|
+
const oIncorrectPathAnnotationIssue = {
|
|
5
5
|
id: "annotationIssue",
|
|
6
6
|
title: "Annotations: Incorrect path or target",
|
|
7
7
|
minversion: "1.85",
|
|
@@ -15,6 +15,20 @@ const oAnnotationIssue = {
|
|
|
15
15
|
getIssueByCategory(oIssueManager, oCoreFacade, IssueCategory.Annotation);
|
|
16
16
|
}
|
|
17
17
|
};
|
|
18
|
+
|
|
19
|
+
const oIgnoredComputedDVAnnotationIssue = {
|
|
20
|
+
id: "ignoredAnnotationIssue",
|
|
21
|
+
title: "Annotations: Ignore Annotation",
|
|
22
|
+
minversion: "1.99",
|
|
23
|
+
audiences: [Audiences.Application],
|
|
24
|
+
categories: [Categories.Usage],
|
|
25
|
+
description: "This rule identifies the ignored annotations",
|
|
26
|
+
resolution: "Only one annotation from either Core.Computed or ComputedDefaultValue must be used",
|
|
27
|
+
check: function(oIssueManager: any, oCoreFacade: any /*oScope: any*/) {
|
|
28
|
+
getIssueByCategory(oIssueManager, oCoreFacade, IssueCategory.Annotation, "IgnoredAnnotation");
|
|
29
|
+
}
|
|
30
|
+
};
|
|
31
|
+
|
|
18
32
|
export function getRules() {
|
|
19
|
-
return [
|
|
33
|
+
return [oIncorrectPathAnnotationIssue, oIgnoredComputedDVAnnotationIssue];
|
|
20
34
|
}
|
|
@@ -14,7 +14,7 @@ sap.ui.define(["sap/fe/core/support/CommonHelper", "sap/fe/core/converters/helpe
|
|
|
14
14
|
var oCollectionFacetUnsupportedLevelIssue = {
|
|
15
15
|
id: "collectionFacetUnsupportedLevel",
|
|
16
16
|
title: "CollectionFacet: Unsupported Levels",
|
|
17
|
-
minversion: "1.
|
|
17
|
+
minversion: "1.80",
|
|
18
18
|
audiences: [Audiences.Application],
|
|
19
19
|
categories: [Categories.Usage],
|
|
20
20
|
description: "Collection facets at level 3 or lower (level 4, 5…) are not supported and will not be visible on the UI.",
|
|
@@ -35,4 +35,4 @@ sap.ui.define(["sap/fe/core/support/CommonHelper", "sap/fe/core/converters/helpe
|
|
|
35
35
|
_exports.getRules = getRules;
|
|
36
36
|
return _exports;
|
|
37
37
|
}, false);
|
|
38
|
-
//# sourceMappingURL=data:application/json;charset=utf-8;base64,
|
|
38
|
+
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIkNvbGxlY3Rpb25GYWNldFVuc3VwcG9ydGVkTGV2ZWwuc3VwcG9ydC50cyJdLCJuYW1lcyI6WyJvQ29sbGVjdGlvbkZhY2V0VW5zdXBwb3J0ZWRMZXZlbElzc3VlIiwiaWQiLCJ0aXRsZSIsIm1pbnZlcnNpb24iLCJhdWRpZW5jZXMiLCJBdWRpZW5jZXMiLCJBcHBsaWNhdGlvbiIsImNhdGVnb3Jp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lY2s6IGZ1bmN0aW9uKG9Jc3N1ZU1hbmFnZXI6IGFueSwgb0NvcmVGYWNhZGU6IGFueSAvKm9TY29wZTogYW55Ki8pIHtcblx0XHRnZXRJc3N1ZUJ5Q2F0ZWdvcnkob0lzc3VlTWFuYWdlciwgb0NvcmVGYWNhZGUsIElzc3VlQ2F0ZWdvcnkuRmFjZXRzLCBcIlVuc3VwcG9ydGVkTGV2ZWxcIik7XG5cdH1cbn07XG5leHBvcnQgZnVuY3Rpb24gZ2V0UnVsZXMoKSB7XG5cdHJldHVybiBbb0NvbGxlY3Rpb25GYWNldFVuc3VwcG9ydGVkTGV2ZWxJc3N1ZV07XG59XG4iXX0=
|
|
@@ -3,7 +3,7 @@ import { IssueCategory } from "sap/fe/core/converters/helpers/IssueManager";
|
|
|
3
3
|
const oCollectionFacetUnsupportedLevelIssue = {
|
|
4
4
|
id: "collectionFacetUnsupportedLevel",
|
|
5
5
|
title: "CollectionFacet: Unsupported Levels",
|
|
6
|
-
minversion: "1.
|
|
6
|
+
minversion: "1.80",
|
|
7
7
|
audiences: [Audiences.Application],
|
|
8
8
|
categories: [Categories.Usage],
|
|
9
9
|
description: "Collection facets at level 3 or lower (level 4, 5…) are not supported and will not be visible on the UI.",
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* SAP UI development toolkit for HTML5 (SAPUI5)
|
|
3
|
+
* (c) Copyright 2009-2021 SAP SE. All rights reserved
|
|
4
|
+
*/
|
|
5
|
+
sap.ui.define(["sap/fe/core/support/CommonHelper", "sap/fe/core/converters/helpers/IssueManager"], function (CommonHelper, IssueManager) {
|
|
6
|
+
"use strict";
|
|
7
|
+
|
|
8
|
+
var _exports = {};
|
|
9
|
+
var IssueCategory = IssueManager.IssueCategory;
|
|
10
|
+
var Audiences = CommonHelper.Audiences;
|
|
11
|
+
var getIssueByCategory = CommonHelper.getIssueByCategory;
|
|
12
|
+
var Categories = CommonHelper.Categories;
|
|
13
|
+
|
|
14
|
+
var oInvalidAnnotationColumnKey = {
|
|
15
|
+
id: "invalidAnnotationColumnKey",
|
|
16
|
+
title: "AnnotationColumnKey: Invalid Key",
|
|
17
|
+
minversion: "1.98",
|
|
18
|
+
audiences: [Audiences.Application],
|
|
19
|
+
categories: [Categories.Usage],
|
|
20
|
+
description: "The key of the annotation column is needed as a valid identifier in the application manifest.",
|
|
21
|
+
resolution: "A column key set in the application manifest must correspond to an existing annotation column.",
|
|
22
|
+
resolutionurls: [{
|
|
23
|
+
"text": "InvalidAnnotationColumnKey",
|
|
24
|
+
"href": "https://ui5.sap.com/#/topic/d525522c1bf54672ae4e02d66b38e60c"
|
|
25
|
+
}],
|
|
26
|
+
check: function (oIssueManager, oCoreFacade) {
|
|
27
|
+
getIssueByCategory(oIssueManager, oCoreFacade, IssueCategory.Manifest, "InvalidKey");
|
|
28
|
+
}
|
|
29
|
+
};
|
|
30
|
+
|
|
31
|
+
function getRules() {
|
|
32
|
+
return [oInvalidAnnotationColumnKey];
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
_exports.getRules = getRules;
|
|
36
|
+
return _exports;
|
|
37
|
+
}, false);
|
|
38
|
+
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIkludmFsaWRBbm5vdGF0aW9uQ29sdW1uS2V5LnN1cHBvcnQudHMiXSwibmFtZXMiOlsib0ludmFsaWRBbm5vdGF0aW9uQ29sdW1uS2V5IiwiaWQiLCJ0aXRsZSIsIm1pbnZlcnNpb24iLCJhdWRpZW5jZXMiLCJBdWRpZW5jZXMiLCJBcHBsaWNhdGlvbiIsImNhdGVnb3JpZXMiLCJDYXRlZ29yaWVzIiwiVXNhZ2UiLCJkZXNjcmlwdGlvbiIsInJlc29sdXRpb24iLCJyZXNvbHV0aW9udXJscyIsImNoZWNrIiwib0lzc3VlTWFuYWdlciIsIm9Db3JlRmFjYWRlIiwiZ2V0SXNzdWVCeUNhdGVnb3J5IiwiSXNz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VDYXRlZ29yeS5NYW5pZmVzdCwgXCJJbnZhbGlkS2V5XCIpO1xuXHR9XG59O1xuZXhwb3J0IGZ1bmN0aW9uIGdldFJ1bGVzKCkge1xuXHRyZXR1cm4gW29JbnZhbGlkQW5ub3RhdGlvbkNvbHVtbktleV07XG59XG4iXX0=
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Categories, getIssueByCategory, Audiences } from "sap/fe/core/support/CommonHelper";
|
|
2
|
+
import { IssueCategory } from "sap/fe/core/converters/helpers/IssueManager";
|
|
3
|
+
const oInvalidAnnotationColumnKey = {
|
|
4
|
+
id: "invalidAnnotationColumnKey",
|
|
5
|
+
title: "AnnotationColumnKey: Invalid Key",
|
|
6
|
+
minversion: "1.98",
|
|
7
|
+
audiences: [Audiences.Application],
|
|
8
|
+
categories: [Categories.Usage],
|
|
9
|
+
description: "The key of the annotation column is needed as a valid identifier in the application manifest.",
|
|
10
|
+
resolution: "A column key set in the application manifest must correspond to an existing annotation column.",
|
|
11
|
+
resolutionurls: [{ "text": "InvalidAnnotationColumnKey", "href": "https://ui5.sap.com/#/topic/d525522c1bf54672ae4e02d66b38e60c" }],
|
|
12
|
+
check: function(oIssueManager: any, oCoreFacade: any /*oScope: any*/) {
|
|
13
|
+
getIssueByCategory(oIssueManager, oCoreFacade, IssueCategory.Manifest, "InvalidKey");
|
|
14
|
+
}
|
|
15
|
+
};
|
|
16
|
+
export function getRules() {
|
|
17
|
+
return [oInvalidAnnotationColumnKey];
|
|
18
|
+
}
|