mirror of
https://github.com/abap2UI5/abap2UI5.git
synced 2025-04-30 07:16:10 +08:00
refactoring (#1452)
This commit is contained in:
parent
3e5f73d555
commit
ff3bfc6e66
|
@ -37,12 +37,6 @@ CLASS z2ui5_cl_util DEFINITION
|
||||||
END OF ty_s_range.
|
END OF ty_s_range.
|
||||||
TYPES ty_t_range TYPE STANDARD TABLE OF ty_s_range WITH EMPTY KEY.
|
TYPES ty_t_range TYPE STANDARD TABLE OF ty_s_range WITH EMPTY KEY.
|
||||||
|
|
||||||
TYPES:
|
|
||||||
BEGIN OF ty_s_sql,
|
|
||||||
tabname TYPE string,
|
|
||||||
where TYPE string,
|
|
||||||
END OF ty_s_sql.
|
|
||||||
|
|
||||||
TYPES:
|
TYPES:
|
||||||
BEGIN OF ty_s_filter_multi,
|
BEGIN OF ty_s_filter_multi,
|
||||||
name TYPE string,
|
name TYPE string,
|
||||||
|
@ -50,11 +44,18 @@ CLASS z2ui5_cl_util DEFINITION
|
||||||
t_token TYPE ty_t_token,
|
t_token TYPE ty_t_token,
|
||||||
t_token_added TYPE ty_t_token,
|
t_token_added TYPE ty_t_token,
|
||||||
t_token_removed TYPE ty_t_token,
|
t_token_removed TYPE ty_t_token,
|
||||||
s_sql TYPE ty_S_sql,
|
|
||||||
sql_text TYPE string,
|
|
||||||
END OF ty_s_filter_multi.
|
END OF ty_s_filter_multi.
|
||||||
TYPES ty_t_filter_multi TYPE STANDARD TABLE OF ty_s_filter_multi WITH EMPTY KEY.
|
TYPES ty_t_filter_multi TYPE STANDARD TABLE OF ty_s_filter_multi WITH EMPTY KEY.
|
||||||
|
|
||||||
|
TYPES:
|
||||||
|
BEGIN OF ty_S_sql,
|
||||||
|
tabname TYPE string,
|
||||||
|
up_to_rows TYPE i,
|
||||||
|
t_ref TYPE REF TO data,
|
||||||
|
where TYPE string,
|
||||||
|
t_filter TYPE ty_t_filter_multi,
|
||||||
|
END OF ty_s_sql.
|
||||||
|
|
||||||
CLASS-METHODS rtti_get_t_attri_by_include
|
CLASS-METHODS rtti_get_t_attri_by_include
|
||||||
IMPORTING
|
IMPORTING
|
||||||
type TYPE REF TO cl_abap_datadescr
|
type TYPE REF TO cl_abap_datadescr
|
||||||
|
|
|
@ -168,14 +168,20 @@ CLASS z2ui5_cl_core_ui5_app IMPLEMENTATION.
|
||||||
|
|
||||||
METHOD controller_app_js.
|
METHOD controller_app_js.
|
||||||
|
|
||||||
result = ` sap.ui.define(["sap/ui/core/mvc/Controller", "z2ui5/controller/View1.controller", "sap/ui/core/BusyIndicator" , "z2ui5/cc/DebugTool" ], function(BaseController, Controller, BusyIndicator, DebugTool){` && |\n| &&
|
result = `sap.ui.define([` && |\n| &&
|
||||||
|
` "sap/ui/core/mvc/Controller",` && |\n| &&
|
||||||
|
` "sap/ui/core/BusyIndicator",` && |\n| &&
|
||||||
|
` "z2ui5/controller/View1.controller"` && |\n| &&
|
||||||
|
`], function(BaseController, BusyIndicator, Controller) {` && |\n| &&
|
||||||
` return BaseController.extend("z2ui5.controller.App", {` && |\n| &&
|
` return BaseController.extend("z2ui5.controller.App", {` && |\n| &&
|
||||||
` onInit: async function() {` && |\n| &&
|
` onInit: async function() {` && |\n| &&
|
||||||
|
|\n| &&
|
||||||
` BusyIndicator.show();` && |\n| &&
|
` BusyIndicator.show();` && |\n| &&
|
||||||
` try {` && |\n| &&
|
` try {` && |\n| &&
|
||||||
` sap.z2ui5.oLaunchpadService = await this.getOwnerComponent().getService("ShellUIService");` && |\n| &&
|
` sap.z2ui5.oLaunchpadService = await this.getOwnerComponent().getService("ShellUIService");` && |\n| &&
|
||||||
` } catch (e) {}` && |\n| &&
|
` } catch (e) {}` && |\n| &&
|
||||||
` try {` && |\n| &&
|
` try {` && |\n| &&
|
||||||
|
` sap.z2ui5.ComponentData = this.getOwnerComponent().getComponentData();` && |\n| &&
|
||||||
` sap.z2ui5.startupParameters = this.getOwnerComponent().getComponentData().startupParameters;` && |\n| &&
|
` sap.z2ui5.startupParameters = this.getOwnerComponent().getComponentData().startupParameters;` && |\n| &&
|
||||||
` } catch (e) {}` && |\n| &&
|
` } catch (e) {}` && |\n| &&
|
||||||
` sap.z2ui5.oController = new Controller();` && |\n| &&
|
` sap.z2ui5.oController = new Controller();` && |\n| &&
|
||||||
|
@ -186,12 +192,12 @@ CLASS z2ui5_cl_core_ui5_app IMPLEMENTATION.
|
||||||
` sap.z2ui5.checkNestAfter = false;` && |\n| &&
|
` sap.z2ui5.checkNestAfter = false;` && |\n| &&
|
||||||
` sap.z2ui5.oBody = {};` && |\n| &&
|
` sap.z2ui5.oBody = {};` && |\n| &&
|
||||||
` sap.z2ui5.oController.setApp(this.getView());` && |\n| &&
|
` sap.z2ui5.oController.setApp(this.getView());` && |\n| &&
|
||||||
|
` sap.z2ui5.oController.Roundtrip();` && |\n| &&
|
||||||
` sap.z2ui5.onBeforeRoundtrip = [];` && |\n| &&
|
` sap.z2ui5.onBeforeRoundtrip = [];` && |\n| &&
|
||||||
` sap.z2ui5.onAfterRendering = [];` && |\n| &&
|
` sap.z2ui5.onAfterRendering = [];` && |\n| &&
|
||||||
` sap.z2ui5.onBeforeEventFrontend = [];` && |\n| &&
|
` sap.z2ui5.onBeforeEventFrontend = [];` && |\n| &&
|
||||||
` sap.z2ui5.onAfterRoundtrip = [];` && |\n| &&
|
` sap.z2ui5.onAfterRoundtrip = [];` && |\n| &&
|
||||||
` sap.z2ui5.DebugTool = new DebugTool()` && |\n| &&
|
|\n| &&
|
||||||
` sap.z2ui5.oController.Roundtrip();` && |\n| &&
|
|
||||||
` }` && |\n| &&
|
` }` && |\n| &&
|
||||||
` });` && |\n| &&
|
` });` && |\n| &&
|
||||||
`});`.
|
`});`.
|
||||||
|
|
Loading…
Reference in New Issue
Block a user