Skip to content

Commit bafbf50

Browse files
authored
Merge pull request #33 from abap2UI5-renamed/create-pull-request/patch
Automatic Update
2 parents 7e1d0b7 + 8eb89a3 commit bafbf50

File tree

2 files changed

+15
-6
lines changed

2 files changed

+15
-6
lines changed

src/01/03/z2ui6_cl_app_manifest_json.clas.abap

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,6 @@ CLASS z2ui6_cl_app_manifest_json IMPLEMENTATION.
104104
` "config": {` &&
105105
` "routerClass": "sap.m.routing.Router",` &&
106106
` "viewType": "XML",` &&
107-
` "async": true,` &&
108107
` "viewPath": "z2ui5.view",` &&
109108
` "controlAggregation": "pages",` &&
110109
` "controlId": "app",` &&
@@ -146,7 +145,6 @@ CLASS z2ui6_cl_app_manifest_json IMPLEMENTATION.
146145
` "rootView": {` &&
147146
` "viewName": "z2ui5.view.App",` &&
148147
` "type": "XML",` &&
149-
` "async": true,` &&
150148
` "id": "App"` &&
151149
` }` &&
152150
` },` &&
@@ -155,6 +153,7 @@ CLASS z2ui6_cl_app_manifest_json IMPLEMENTATION.
155153
` "service": "z2ui5"` &&
156154
` }` &&
157155
`}` &&
156+
`` &&
158157
``.
159158

160159
ENDMETHOD.

src/01/03/z2ui6_cl_app_view1_js.clas.abap

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -341,7 +341,12 @@ CLASS z2ui6_cl_app_view1_js IMPLEMENTATION.
341341
` "sap/ushell/Container"` && |\n| &&
342342
` ], async (ushellContainer) => {` && |\n| &&
343343
` // z2ui5.oCrossAppNavigator = await ushellContainer.getServiceAsync("CrossApplicationNavigation");` && |\n| &&
344-
` z2ui5.oCrossAppNavigator = ushellContainer.getService("CrossApplicationNavigation");` && |\n| &&
344+
` if (ushellContainer){` && |\n| &&
345+
` z2ui5.oCrossAppNavigator = ushellContainer.getService("CrossApplicationNavigation");` && |\n| &&
346+
` } else {` && |\n| &&
347+
` // fallback needed for UI5 version < 1.120` && |\n| &&
348+
` z2ui5.oCrossAppNavigator = sap.ushell.Container.getService("CrossApplicationNavigation");` && |\n| &&
349+
` }` && |\n| &&
345350
` z2ui5.oCrossAppNavigator.backToPreviousApp();` && |\n| &&
346351
` });` && |\n| &&
347352
` break;` && |\n| &&
@@ -351,7 +356,12 @@ CLASS z2ui6_cl_app_view1_js IMPLEMENTATION.
351356
` "sap/ushell/Container"` && |\n| &&
352357
` ], async (ushellContainer) => {` && |\n| &&
353358
` // z2ui5.oCrossAppNavigator = await ushellContainer.getServiceAsync("CrossApplicationNavigation");` && |\n| &&
354-
` z2ui5.oCrossAppNavigator = ushellContainer.getService("CrossApplicationNavigation");` && |\n| &&
359+
` if (ushellContainer){` && |\n| &&
360+
` z2ui5.oCrossAppNavigator = ushellContainer.getService("CrossApplicationNavigation");` && |\n| &&
361+
` } else {` && |\n| &&
362+
` // fallback needed for UI5 version < 1.120` && |\n| &&
363+
` z2ui5.oCrossAppNavigator = sap.ushell.Container.getService("CrossApplicationNavigation");` && |\n| &&
364+
` }` && |\n| &&
355365
` const hash = (z2ui5.oCrossAppNavigator.hrefForExternal({` && |\n| &&
356366
` target: z2ui5.args[1],` && |\n| &&
357367
` params: z2ui5.args[2]` && |\n| &&
@@ -408,6 +418,8 @@ CLASS z2ui6_cl_app_view1_js IMPLEMENTATION.
408418
` break;` && |\n| &&
409419
` case 'URLHELPER':` && |\n| &&
410420
` var URLHelper = mobileLibrary.URLHelper;` && |\n| &&
421+
|\n|.
422+
result = result &&
411423
` var params = args[2];` && |\n| &&
412424
` switch (args[1]) {` && |\n| &&
413425
` case 'REDIRECT':` && |\n| &&
@@ -418,8 +430,6 @@ CLASS z2ui6_cl_app_view1_js IMPLEMENTATION.
418430
` break;` && |\n| &&
419431
` case 'TRIGGER_SMS':` && |\n| &&
420432
` URLHelper.triggerSms(params);` && |\n| &&
421-
|\n|.
422-
result = result &&
423433
` break;` && |\n| &&
424434
` case 'TRIGGER_TEL':` && |\n| &&
425435
` URLHelper.triggerTel(params);` && |\n| &&

0 commit comments

Comments
 (0)