@xuda.io/runtime-bundle 1.0.367 → 1.0.369
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/js/xuda-runtime-bundle.js +33 -378
- package/js/xuda-runtime-bundle.min.js +1 -1
- package/js/xuda-runtime-slim.js +33 -378
- package/js/xuda-runtime-slim.min.es.js +33 -378
- package/js/xuda-runtime-slim.min.js +1 -1
- package/package.json +1 -1
package/js/xuda-runtime-slim.js
CHANGED
|
@@ -8969,19 +8969,12 @@ func.UI.worker.find_job_index = function (SESSION_ID, jobNoP) {
|
|
|
8969
8969
|
};
|
|
8970
8970
|
|
|
8971
8971
|
func.UI.ds_garbage_collector = function (SESSION_ID = Object.keys(SESSION_OBJ)[0], re_check) {
|
|
8972
|
-
// return;
|
|
8973
8972
|
let _session = SESSION_OBJ[SESSION_ID];
|
|
8974
8973
|
|
|
8975
8974
|
const _data_system = _session?.DS_GLB?.[0]?.data_system;
|
|
8976
8975
|
if (_data_system?.SYS_GLOBAL_BOL_AJAX_BUSY) return;
|
|
8977
8976
|
if (!_data_system?.SYS_GLOBAL_BOL_IDLE) return;
|
|
8978
8977
|
|
|
8979
|
-
// for (const [key, val] of Object.entries(_data_system?.SYS_GLOBAL_OBJ_REFS || {})) {
|
|
8980
|
-
// if (!$(`[xu-ui-id='${val?.$el.attr('xu-ui-id')}'`)?.length) {
|
|
8981
|
-
// delete _data_system.SYS_GLOBAL_OBJ_REFS[key];
|
|
8982
|
-
// }
|
|
8983
|
-
// }
|
|
8984
|
-
|
|
8985
8978
|
let abort;
|
|
8986
8979
|
|
|
8987
8980
|
for (const [dsP, _ds] of Object.entries(_session.DS_GLB)) {
|
|
@@ -9028,7 +9021,7 @@ func.UI.ds_garbage_collector = function (SESSION_ID = Object.keys(SESSION_OBJ)[0
|
|
|
9028
9021
|
func.datasource.del(SESSION_ID, val);
|
|
9029
9022
|
}
|
|
9030
9023
|
};
|
|
9031
|
-
func.UI.refs_garbage_collector = function (SESSION_ID = Object.keys(SESSION_OBJ)[0]
|
|
9024
|
+
func.UI.refs_garbage_collector = function (SESSION_ID = Object.keys(SESSION_OBJ)[0]) {
|
|
9032
9025
|
let _session = SESSION_OBJ[SESSION_ID];
|
|
9033
9026
|
const _data_system = _session?.DS_GLB?.[0]?.data_system;
|
|
9034
9027
|
|
|
@@ -11409,9 +11402,6 @@ func.UI.screen.refresh_xu_attributes = async function (SESSION_ID, fields_arr, j
|
|
|
11409
11402
|
|
|
11410
11403
|
if (!elem_val?.$elm?.data()?.xuData?.ui_type) continue;
|
|
11411
11404
|
|
|
11412
|
-
// // already rended
|
|
11413
|
-
// if (elem_val.$elm[0].tagName !== 'XURENDER' && elem_val?.$elm?.length) continue;
|
|
11414
|
-
|
|
11415
11405
|
new_job = await func.UI.worker.add_to_queue(
|
|
11416
11406
|
SESSION_ID,
|
|
11417
11407
|
'gui event',
|
|
@@ -11927,16 +11917,20 @@ func.UI.screen.execute_xu_functions = async function (SESSION_ID, is_skeleton, $
|
|
|
11927
11917
|
|
|
11928
11918
|
const common_fx = {
|
|
11929
11919
|
'xu-ref': async function ($elm, val) {
|
|
11930
|
-
// console.log('xu-ref', $elm, val);
|
|
11931
11920
|
const _session = SESSION_OBJ[SESSION_ID];
|
|
11932
11921
|
let _ds_0 = _session.DS_GLB[0];
|
|
11933
|
-
|
|
11934
|
-
// _ds_0.data_system['SYS_GLOBAL_OBJ_REFS'] = {};
|
|
11935
|
-
// }
|
|
11936
|
-
// if (!_ds_0.data_system['SYS_GLOBAL_OBJ_REFS'][val]) {
|
|
11922
|
+
|
|
11937
11923
|
const _ds = _session.DS_GLB[paramsP.dsSessionP];
|
|
11938
|
-
|
|
11939
|
-
|
|
11924
|
+
|
|
11925
|
+
const row_idx = func.common.find_ROWID_idx(_ds, _ds.currentRecordId);
|
|
11926
|
+
const data = _.clone(_ds?.data_feed?.rows?.[row_idx]) || {};
|
|
11927
|
+
|
|
11928
|
+
const props = _ds.in_parameters || {};
|
|
11929
|
+
const attributes = $elm?.data()?.xuData?.properties || {};
|
|
11930
|
+
|
|
11931
|
+
// _ds_0.data_system['SYS_GLOBAL_OBJ_REFS'][val.value] = { $el: $elm, ds: _ds, data, attributes, props };
|
|
11932
|
+
_ds_0.data_system['SYS_GLOBAL_OBJ_REFS'][val.value] = { $el: $elm, data, attributes, props };
|
|
11933
|
+
|
|
11940
11934
|
return {};
|
|
11941
11935
|
},
|
|
11942
11936
|
'xu-bind': async function ($elm, val) {
|
|
@@ -12269,14 +12263,12 @@ func.UI.screen.execute_xu_functions = async function (SESSION_ID, is_skeleton, $
|
|
|
12269
12263
|
if (!custom_iterator_key) {
|
|
12270
12264
|
is_key_dynamic_field = true;
|
|
12271
12265
|
|
|
12272
|
-
// iterator_key = $elm.data().xuData.node_org.id.replaceAll("-", "_") + "_FOR_KEY";
|
|
12273
12266
|
iterator_key = '_FOR_KEY';
|
|
12274
12267
|
}
|
|
12275
12268
|
|
|
12276
12269
|
if (!custom_iterator_val) {
|
|
12277
12270
|
is_val_dynamic_field = true;
|
|
12278
12271
|
|
|
12279
|
-
// iterator_val = $elm.data().xuData.node_org.id.replaceAll("-", "_") + "_FOR_VAL";
|
|
12280
12272
|
iterator_val = '_FOR_VAL';
|
|
12281
12273
|
}
|
|
12282
12274
|
|
|
@@ -12323,13 +12315,7 @@ func.UI.screen.execute_xu_functions = async function (SESSION_ID, is_skeleton, $
|
|
|
12323
12315
|
};
|
|
12324
12316
|
let _parent_info = _.cloneDeep(parent_infoP) || {};
|
|
12325
12317
|
_parent_info.iterate_info = iterate_info;
|
|
12326
|
-
|
|
12327
|
-
// _parent_info = iterate_info;
|
|
12328
|
-
// } else {
|
|
12329
|
-
// _parent_info = {
|
|
12330
|
-
// iterate_info,
|
|
12331
|
-
// };
|
|
12332
|
-
// }
|
|
12318
|
+
|
|
12333
12319
|
const $divP = await func.UI.screen.render_ui_tree(
|
|
12334
12320
|
SESSION_ID,
|
|
12335
12321
|
$container,
|
|
@@ -12395,13 +12381,6 @@ func.UI.screen.execute_xu_functions = async function (SESSION_ID, is_skeleton, $
|
|
|
12395
12381
|
},
|
|
12396
12382
|
'xu-exp': async function ($elm, val) {
|
|
12397
12383
|
let exp = val.value === null ? true : val.value;
|
|
12398
|
-
// if (val.value.includes("@_FOR_KEY")) {
|
|
12399
|
-
// exp = exp.replaceAll("@_FOR_KEY", "@" + $elm.data().xuData.iterate_info.iterator_key);
|
|
12400
|
-
// }
|
|
12401
|
-
|
|
12402
|
-
// if (val.value.includes("@_FOR_VAL")) {
|
|
12403
|
-
// exp = exp.replaceAll("@_FOR_VAL", "@" + $elm.data().xuData.iterate_info.iterator_val);
|
|
12404
|
-
// }
|
|
12405
12384
|
|
|
12406
12385
|
let exp_ret = await func.expression.get(SESSION_ID, exp, paramsP.dsSessionP, 'UI Attr EXP', SESSION_OBJ[SESSION_ID].DS_GLB[paramsP.dsSessionP].currentRecordId);
|
|
12407
12386
|
|
|
@@ -12810,10 +12789,6 @@ func.UI.screen.set_attributes_new = async function (SESSION_ID, is_skeleton, $ro
|
|
|
12810
12789
|
_ret = _.assignIn(_ret, ret);
|
|
12811
12790
|
}
|
|
12812
12791
|
|
|
12813
|
-
// if (nodeP.tagName === "svg") {
|
|
12814
|
-
// console.log(svg_attributes_str);
|
|
12815
|
-
// }
|
|
12816
|
-
|
|
12817
12792
|
// EXP for
|
|
12818
12793
|
|
|
12819
12794
|
for await (const [key, val] of Object.entries(nodeP.attributes)) {
|
|
@@ -12922,20 +12897,6 @@ func.UI.screen.panel_post_render_handler = async function (
|
|
|
12922
12897
|
if ($old_panel_div?.length) {
|
|
12923
12898
|
$($old_panel_div[0]).after($wrapper.children());
|
|
12924
12899
|
} else {
|
|
12925
|
-
// $container.append($wrapper.children());
|
|
12926
|
-
|
|
12927
|
-
// find existing xurender
|
|
12928
|
-
// $.each($wrapper.children(), function (key, val) {
|
|
12929
|
-
// console.log(">", `[xu-ui-id=${$(val).attr("xu-ui-id")}]`);
|
|
12930
|
-
// const $elm = $container.find(`[xu-ui-id=${$(val).attr("xu-ui-id")}]`);
|
|
12931
|
-
// if (
|
|
12932
|
-
// // $(val).data().xuData.key_path === cloned_$div.data().xuData.key_path
|
|
12933
|
-
// $elm.length
|
|
12934
|
-
// ) {
|
|
12935
|
-
// $elm.remove();
|
|
12936
|
-
// }
|
|
12937
|
-
// $container.append($(val));
|
|
12938
|
-
// });
|
|
12939
12900
|
$.each($wrapper.children(), function (key, child) {
|
|
12940
12901
|
$.each($container.children(), function (key, elm) {
|
|
12941
12902
|
if ($(elm).data().xuData.elem_key === $(child).data().xuData.elem_key) {
|
|
@@ -13063,59 +13024,7 @@ func.UI.screen.create_container = function (SESSION_ID, $root_container, nodeP,
|
|
|
13063
13024
|
},
|
|
13064
13025
|
xuAttributes: {},
|
|
13065
13026
|
});
|
|
13066
|
-
// }
|
|
13067
13027
|
|
|
13068
|
-
// $div.appendTo($appendTo);
|
|
13069
|
-
|
|
13070
|
-
////////////////////////
|
|
13071
|
-
|
|
13072
|
-
// let svg_attributes_str = ""
|
|
13073
|
-
// if (div_typeP === "svg") {
|
|
13074
|
-
// for (const [key, val] of Object.entries(nodeP.attributes)) {
|
|
13075
|
-
// svg_attributes_str += `${key}="${val}" `
|
|
13076
|
-
// }
|
|
13077
|
-
// }
|
|
13078
|
-
|
|
13079
|
-
// var $div =
|
|
13080
|
-
// // $(`<${div} ${attr_str ? attr_str : ""} ${svg_attributes_str}>`)
|
|
13081
|
-
// $(`<${div} ${attr_str ? attr_str : ""}>`)
|
|
13082
|
-
// .attr("xu-ui-id", ui_id)
|
|
13083
|
-
// .data({
|
|
13084
|
-
// xuData: {
|
|
13085
|
-
// prog_id: _paramsP.prog_id,
|
|
13086
|
-
// nodeid: nodeP.id,
|
|
13087
|
-
// ui_type: nodeP.tagName,
|
|
13088
|
-
// xu_id: xu_id,
|
|
13089
|
-
// recordid: currentRecordId,
|
|
13090
|
-
// paramsP: _paramsP,
|
|
13091
|
-
// key: keyP,
|
|
13092
|
-
// key_path, //:($container?.data()?.xuData?.key || "0") + "-" + (keyP || "0"),
|
|
13093
|
-
// screenId: _paramsP.screenId,
|
|
13094
|
-
// parent_container: $container?.attr("id"),
|
|
13095
|
-
// elem_key,
|
|
13096
|
-
// ui_id,
|
|
13097
|
-
// properties: prop,
|
|
13098
|
-
// node: nodeP,
|
|
13099
|
-
// node_org: _.cloneDeep(nodeP),
|
|
13100
|
-
// is_panelP: _paramsP.is_panelP,
|
|
13101
|
-
|
|
13102
|
-
// elem_prop: elem_propP,
|
|
13103
|
-
// debug_info: {
|
|
13104
|
-
// id: nodeP.id,
|
|
13105
|
-
// parent_id: $container?.data()?.xuData?.ui_id,
|
|
13106
|
-
// items: items,
|
|
13107
|
-
// },
|
|
13108
|
-
// parent_node: parent_nodeP,
|
|
13109
|
-
// currentRecordId: currentRecordId,
|
|
13110
|
-
// $root_container: $root_container,
|
|
13111
|
-
// parent_element_ui_id: $container?.data()?.xuData?.ui_id,
|
|
13112
|
-
// },
|
|
13113
|
-
// xuAttributes: {},
|
|
13114
|
-
// })
|
|
13115
|
-
|
|
13116
|
-
// if (div_typeP === "svg") {
|
|
13117
|
-
// $div.removeAttr("xu-ui-id")
|
|
13118
|
-
// }
|
|
13119
13028
|
if (div_typeP !== 'svg') {
|
|
13120
13029
|
$div.appendTo($appendTo);
|
|
13121
13030
|
}
|
|
@@ -13678,20 +13587,8 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
13678
13587
|
await func.UI.component.create_app_page_component(SESSION_ID, paramsP.dsSessionP);
|
|
13679
13588
|
const page = new UI_FRAMEWORK_PLUGIN.page();
|
|
13680
13589
|
await set_call_screen_properties_values(page);
|
|
13681
|
-
await page.create(
|
|
13682
|
-
|
|
13683
|
-
// SESSION_ID,
|
|
13684
|
-
// paramsP.dsSessionP,
|
|
13685
|
-
// nav,
|
|
13686
|
-
// $nav.data().xuData.nav_params[paramsP.dsSessionP]
|
|
13687
|
-
);
|
|
13688
|
-
await page.init(
|
|
13689
|
-
params,
|
|
13690
|
-
// SESSION_ID,
|
|
13691
|
-
// paramsP.dsSessionP,
|
|
13692
|
-
// nav,
|
|
13693
|
-
// $nav.data().xuData.nav_params[paramsP.dsSessionP]
|
|
13694
|
-
);
|
|
13590
|
+
await page.create(params);
|
|
13591
|
+
await page.init(params);
|
|
13695
13592
|
nav.push(component_name, { params });
|
|
13696
13593
|
} else {
|
|
13697
13594
|
debugger;
|
|
@@ -13927,20 +13824,6 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
13927
13824
|
} catch (err) {
|
|
13928
13825
|
func.utils.debug_report(SESSION_ID, `${plugin_name} widget`, err.message, 'E');
|
|
13929
13826
|
}
|
|
13930
|
-
|
|
13931
|
-
// glb.lifecycle.plugins[plugin_name] = {
|
|
13932
|
-
// plugin_script: fx,
|
|
13933
|
-
// setup_data: plugin_setup_ret.data,
|
|
13934
|
-
// fields,
|
|
13935
|
-
// params,
|
|
13936
|
-
// };
|
|
13937
|
-
|
|
13938
|
-
// await glb.lifecycle.execute(SESSION_ID, "initialized");
|
|
13939
|
-
// await glb.lifecycle.execute(SESSION_ID, method);
|
|
13940
|
-
|
|
13941
|
-
// } catch (err) {
|
|
13942
|
-
// report_error(err);
|
|
13943
|
-
// }
|
|
13944
13827
|
}
|
|
13945
13828
|
return $div;
|
|
13946
13829
|
},
|
|
@@ -13952,10 +13835,6 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
13952
13835
|
var $wrapper = $('<div>');
|
|
13953
13836
|
$div = func.UI.screen.create_container(SESSION_ID, $root_container, nodeP, $container, paramsP, parent_infoP, jobNoP, keyP, parent_nodeP, prop, null, null, 'div', $wrapper, '');
|
|
13954
13837
|
|
|
13955
|
-
// if (paramsP.is_panelP) {
|
|
13956
|
-
// var id = $div.attr('id');
|
|
13957
|
-
// }
|
|
13958
|
-
|
|
13959
13838
|
if (!$div) return;
|
|
13960
13839
|
|
|
13961
13840
|
if (!REFRESHER_IN_PROGRESS && (paramsP.is_mobile_popover || paramsP.is_mobile_page)) {
|
|
@@ -13984,107 +13863,7 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
13984
13863
|
$container.data().xuAttributes[key] = _.cloneDeep(val);
|
|
13985
13864
|
});
|
|
13986
13865
|
|
|
13987
|
-
// var $div_content = $div.children();
|
|
13988
|
-
|
|
13989
|
-
// $.each($div_content, function (key, val) {
|
|
13990
|
-
// $(val).data().xuData.parent_container =
|
|
13991
|
-
// $div.data().xuData.parent_container;
|
|
13992
|
-
// });
|
|
13993
|
-
|
|
13994
13866
|
return await render_screen_type($div);
|
|
13995
|
-
|
|
13996
|
-
// if (paramsP.is_mobile_modal) {
|
|
13997
|
-
// return await open_modal($div);
|
|
13998
|
-
// }
|
|
13999
|
-
// if (paramsP.is_mobile_popover) {
|
|
14000
|
-
// open_popover($div);
|
|
14001
|
-
// func.UI.utils.screen_blocker(
|
|
14002
|
-
// false,
|
|
14003
|
-
// paramsP.prog_id + "_" + paramsP.sourceScreenP
|
|
14004
|
-
// );
|
|
14005
|
-
// return;
|
|
14006
|
-
// }
|
|
14007
|
-
|
|
14008
|
-
// if (paramsP.is_mobile_page) {
|
|
14009
|
-
// const $nav = $(SESSION_OBJ[SESSION_ID].root_element).find("xu-nav");
|
|
14010
|
-
// const nav = $nav[0];
|
|
14011
|
-
|
|
14012
|
-
// var params = {
|
|
14013
|
-
// div: $div_content,
|
|
14014
|
-
// name: paramsP.screenInfo.properties?.menuTitle,
|
|
14015
|
-
// screenId: paramsP.screenId,
|
|
14016
|
-
// $container: $container,
|
|
14017
|
-
// // icon: $div.data().xuData.paramsP.screenInfo.rICN,
|
|
14018
|
-
// dsSession: paramsP.dsSessionP,
|
|
14019
|
-
// };
|
|
14020
|
-
// var component_name = "xu-page-component-" + paramsP.dsSessionP;
|
|
14021
|
-
// if (!$(nav).data().xuData.nav_params) {
|
|
14022
|
-
// $(nav).data().xuData.nav_params = {};
|
|
14023
|
-
// }
|
|
14024
|
-
|
|
14025
|
-
// //restore validate
|
|
14026
|
-
// if ($(nav)?.data()?.xuData?.params?.[paramsP.dsSessionP]) {
|
|
14027
|
-
// params.$container.data().xuData.validate_screen_ready = $(nav)
|
|
14028
|
-
// .data()
|
|
14029
|
-
// .xuData.params[
|
|
14030
|
-
// paramsP.dsSessionP
|
|
14031
|
-
// ].$container.data().xuData.validate_screen_ready;
|
|
14032
|
-
// }
|
|
14033
|
-
|
|
14034
|
-
// if (!$(nav)?.data()?.xuData) return;
|
|
14035
|
-
// $(nav).data().xuData.nav_params[paramsP.dsSessionP] = params;
|
|
14036
|
-
// if (!$(component_name).length) {
|
|
14037
|
-
// await func.UI.component.create_app_page_component(
|
|
14038
|
-
// SESSION_ID,
|
|
14039
|
-
// paramsP.dsSessionP
|
|
14040
|
-
// );
|
|
14041
|
-
// const page = new UI_FRAMEWORK_PLUGIN.page();
|
|
14042
|
-
// await page.create(
|
|
14043
|
-
// SESSION_ID,
|
|
14044
|
-
// paramsP.dsSessionP,
|
|
14045
|
-
// nav,
|
|
14046
|
-
// $nav.data().xuData.nav_params[paramsP.dsSessionP]
|
|
14047
|
-
// );
|
|
14048
|
-
// await page.init(
|
|
14049
|
-
// SESSION_ID,
|
|
14050
|
-
// paramsP.dsSessionP,
|
|
14051
|
-
// nav,
|
|
14052
|
-
// $nav.data().xuData.nav_params[paramsP.dsSessionP]
|
|
14053
|
-
// );
|
|
14054
|
-
// nav.push(component_name, { params });
|
|
14055
|
-
// } else {
|
|
14056
|
-
// debugger;
|
|
14057
|
-
// $(component_name).empty();
|
|
14058
|
-
|
|
14059
|
-
// await UI_FRAMEWORK_PLUGIN.page(SESSION_ID, paramsP.dsSessionP);
|
|
14060
|
-
// }
|
|
14061
|
-
// $div.data().xuData.paramsP = $container.data().xuData.paramsP;
|
|
14062
|
-
|
|
14063
|
-
// return $div;
|
|
14064
|
-
// }
|
|
14065
|
-
|
|
14066
|
-
// if (
|
|
14067
|
-
// !paramsP.is_mobile_page &&
|
|
14068
|
-
// !paramsP.is_mobile_modal &&
|
|
14069
|
-
// !paramsP.is_mobile_popover &&
|
|
14070
|
-
// !paramsP.is_panelP
|
|
14071
|
-
// ) {
|
|
14072
|
-
// var $nav = $(SESSION_OBJ[SESSION_ID].root_element).find("xu-nav");
|
|
14073
|
-
// if ($nav && $nav.length) {
|
|
14074
|
-
// // refresh made
|
|
14075
|
-
// } else {
|
|
14076
|
-
// $nav = $("<xu-nav>");
|
|
14077
|
-
// $container.append($nav);
|
|
14078
|
-
// func.UI.component.init_xu_nav($container, $nav);
|
|
14079
|
-
// }
|
|
14080
|
-
|
|
14081
|
-
// $nav.data().xuData.$div = $div_content; // set data to nav to use in the component
|
|
14082
|
-
|
|
14083
|
-
// await $nav[0].setRoot("xu-root-component-" + SESSION_ID);
|
|
14084
|
-
// } else {
|
|
14085
|
-
// $container.append($div_content);
|
|
14086
|
-
// }
|
|
14087
|
-
// return $container;
|
|
14088
13867
|
},
|
|
14089
13868
|
[`xu-multi-view`]: async function () {
|
|
14090
13869
|
var $div = $container;
|
|
@@ -14101,60 +13880,26 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
14101
13880
|
}
|
|
14102
13881
|
|
|
14103
13882
|
const done = async function (continuous_idx) {
|
|
14104
|
-
const do_callback = async function ($div) {
|
|
14105
|
-
|
|
14106
|
-
|
|
14107
|
-
|
|
14108
|
-
|
|
14109
|
-
|
|
14110
|
-
|
|
14111
|
-
|
|
14112
|
-
|
|
14113
|
-
|
|
14114
|
-
|
|
14115
|
-
|
|
14116
|
-
|
|
14117
|
-
|
|
14118
|
-
}
|
|
14119
|
-
|
|
14120
|
-
return $div;
|
|
14121
|
-
};
|
|
14122
|
-
await func.UI.screen.set_attributes_new(SESSION_ID, is_skeleton, $root_container, nodeP, $container, paramsP, parent_infoP, jobNoP, keyP, parent_nodeP, $container, true);
|
|
14123
|
-
// var $div_content = $div.children();
|
|
14124
|
-
|
|
14125
|
-
// if (continuous_idx !== null || !prop.app_items_per_page) {
|
|
14126
|
-
// $.each($div.data().xuData, function (key, val) {
|
|
14127
|
-
// $container.data().xuData[key] = val;
|
|
14128
|
-
// });
|
|
14129
|
-
// $.each($div.data().xuAttributes, function (key, val) {
|
|
14130
|
-
// $container.data().xuAttributes[key] = val;
|
|
14131
|
-
// });
|
|
14132
|
-
|
|
14133
|
-
// if (!$container.data().xuData.node) {
|
|
14134
|
-
// $container.data().xuData.node = {};
|
|
13883
|
+
// const do_callback = async function ($div) {
|
|
13884
|
+
// // if ($root_container.data().xuData.progress_bar_circle) {
|
|
13885
|
+
// // setTimeout(function () {
|
|
13886
|
+
// // $.each(
|
|
13887
|
+
// // $root_container.data().xuData.progress_bar_circle,
|
|
13888
|
+
// // function (key, val) {
|
|
13889
|
+
// // val.bar.set(parseFloat(val.value)); // Number from 0.0 to 1.0
|
|
13890
|
+
// // }
|
|
13891
|
+
// // );
|
|
13892
|
+
// // }, 2000);
|
|
13893
|
+
// // }
|
|
13894
|
+
|
|
13895
|
+
// if (paramsP.screenInfo.properties?.rtl) {
|
|
13896
|
+
// $div_content.attr('dir', 'rtl');
|
|
14135
13897
|
// }
|
|
14136
13898
|
|
|
14137
|
-
// $
|
|
14138
|
-
|
|
14139
|
-
|
|
14140
|
-
// if (!$(val)?.data()?.xuData) return;
|
|
14141
|
-
// if (
|
|
14142
|
-
// continuous_idx === null ||
|
|
14143
|
-
// (continuous_idx && key > continuous_idx)
|
|
14144
|
-
// ) {
|
|
14145
|
-
// $(val).data().xuData.parent_container =
|
|
14146
|
-
// $div.data().xuData.parent_container;
|
|
14147
|
-
// $container
|
|
14148
|
-
// .data()
|
|
14149
|
-
// .xuData.node.children.push($(val).data().xuData.node);
|
|
14150
|
-
// }
|
|
14151
|
-
// });
|
|
14152
|
-
// }
|
|
13899
|
+
// return $div;
|
|
13900
|
+
// };
|
|
13901
|
+
await func.UI.screen.set_attributes_new(SESSION_ID, is_skeleton, $root_container, nodeP, $container, paramsP, parent_infoP, jobNoP, keyP, parent_nodeP, $container, true);
|
|
14153
13902
|
|
|
14154
|
-
// if (continuous_idx !== null) {
|
|
14155
|
-
// if (glb.CURRENT_APP_LOADING === 1) glb.CURRENT_APP_LOADING = 0; // re-activate loader
|
|
14156
|
-
// return;
|
|
14157
|
-
// }
|
|
14158
13903
|
return await render_screen_type($div);
|
|
14159
13904
|
};
|
|
14160
13905
|
|
|
@@ -14188,38 +13933,6 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
14188
13933
|
const ret = await func.UI.screen.render_ui_tree(SESSION_ID, $container, empty_result_node, parent_infoP, paramsP, jobNoP, null, 0, null, nodeP, null, $root_container);
|
|
14189
13934
|
await func.events.validate(SESSION_ID, 'record_not_found', paramsP.dsSessionP);
|
|
14190
13935
|
return await done(null);
|
|
14191
|
-
|
|
14192
|
-
// var text = "";
|
|
14193
|
-
// if (prop?.app_empty_result_text !== "undefined") {
|
|
14194
|
-
// text = prop.app_empty_result_text;
|
|
14195
|
-
// }
|
|
14196
|
-
// if (
|
|
14197
|
-
// prop.app_empty_result_text_EXP &&
|
|
14198
|
-
// prop.app_empty_result_text_EXP !== "undefined"
|
|
14199
|
-
// ) {
|
|
14200
|
-
// let exp = prop.app_empty_result_text_EXP;
|
|
14201
|
-
// if (exp && exp !== "undefined") {
|
|
14202
|
-
// var res = func.expression.get(
|
|
14203
|
-
// SESSION_ID,
|
|
14204
|
-
// exp,
|
|
14205
|
-
// paramsP.dsSessionP,
|
|
14206
|
-
// "app_empty_result_text_EXP",
|
|
14207
|
-
// _ds.currentRecordId
|
|
14208
|
-
// );
|
|
14209
|
-
// text = res.result;
|
|
14210
|
-
// }
|
|
14211
|
-
// }
|
|
14212
|
-
// if (icon || text) {
|
|
14213
|
-
// $container.append(
|
|
14214
|
-
// `<div style="width: 100%;" >${img}<h6 style="text-align: center;">${text}</h6></div>`
|
|
14215
|
-
// );
|
|
14216
|
-
// }
|
|
14217
|
-
// await func.events.validate(
|
|
14218
|
-
// SESSION_ID,
|
|
14219
|
-
// "record_not_found",
|
|
14220
|
-
// paramsP.dsSessionP
|
|
14221
|
-
// );
|
|
14222
|
-
// return await done(null);
|
|
14223
13936
|
};
|
|
14224
13937
|
var _ds = SESSION_OBJ[SESSION_ID].DS_GLB[paramsP.dsSessionP];
|
|
14225
13938
|
|
|
@@ -14232,25 +13945,7 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
14232
13945
|
var i = 0;
|
|
14233
13946
|
for await (const [key, val] of Object.entries(_ds.data_feed.rows)) {
|
|
14234
13947
|
var node = JSON.parse(JSON.stringify(nodeP));
|
|
14235
|
-
|
|
14236
|
-
// if (
|
|
14237
|
-
// continuous_idx === null &&
|
|
14238
|
-
// prop.app_items_per_page &&
|
|
14239
|
-
// i >= Number(prop.app_items_per_page)
|
|
14240
|
-
// ) {
|
|
14241
|
-
// continuous_idx = i;
|
|
14242
|
-
// await done(null);
|
|
14243
|
-
|
|
14244
|
-
// setTimeout(async function () {
|
|
14245
|
-
// await run_item(continuous_idx);
|
|
14246
|
-
// if (!glb.CURRENT_APP_LOADING) {
|
|
14247
|
-
// glb.CURRENT_APP_LOADING = 1;
|
|
14248
|
-
// } // deactivate loader
|
|
14249
|
-
// }, 1000);
|
|
14250
|
-
|
|
14251
|
-
// continue;
|
|
14252
|
-
// }
|
|
14253
|
-
////////
|
|
13948
|
+
|
|
14254
13949
|
_ds.currentRecordId = val._ROWID;
|
|
14255
13950
|
const ret = await iterate_child($div, node, { continuous_idx }, null, $root_container);
|
|
14256
13951
|
|
|
@@ -14302,46 +13997,6 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
14302
13997
|
};
|
|
14303
13998
|
if (!element || element === 'script') return await done();
|
|
14304
13999
|
let str = '';
|
|
14305
|
-
// var $div
|
|
14306
|
-
// const draw_svg = function () {
|
|
14307
|
-
// const get_tag_str = function (element, prop, val) {
|
|
14308
|
-
// let class_str = "";
|
|
14309
|
-
// let attr_str = "";
|
|
14310
|
-
// for (const [key, val] of Object.entries(prop)) {
|
|
14311
|
-
// if (key.substr(0, 2) !== "xu") {
|
|
14312
|
-
// attr_str += ` ${key}="${val}" `;
|
|
14313
|
-
// }
|
|
14314
|
-
// }
|
|
14315
|
-
// if (element === "svg") {
|
|
14316
|
-
// return `<${element} ${attr_str} > `;
|
|
14317
|
-
// }
|
|
14318
|
-
// let ret = "";
|
|
14319
|
-
// if (val?.children?.length) {
|
|
14320
|
-
// ret = iterate_svg(val);
|
|
14321
|
-
// }
|
|
14322
|
-
|
|
14323
|
-
// return `<${element} ${class_str} ${attr_str} > ${ret} </${element}>`;
|
|
14324
|
-
// };
|
|
14325
|
-
// let svg_str = get_tag_str(element, prop);
|
|
14326
|
-
// let inner_str = "";
|
|
14327
|
-
// const iterate_svg = function (node) {
|
|
14328
|
-
// let ret = "";
|
|
14329
|
-
// if (node.children) {
|
|
14330
|
-
// for (let val of node.children) {
|
|
14331
|
-
// let prop = val.attributes;
|
|
14332
|
-
// ret += get_tag_str(val.tagName, prop, val);
|
|
14333
|
-
// }
|
|
14334
|
-
// }
|
|
14335
|
-
// return ret;
|
|
14336
|
-
// };
|
|
14337
|
-
// inner_str = iterate_svg(nodeP);
|
|
14338
|
-
|
|
14339
|
-
// $div = $(svg_str + inner_str + "</svg>").appendTo($container);
|
|
14340
|
-
// };
|
|
14341
|
-
// if (element === "svg") {
|
|
14342
|
-
// draw_svg();
|
|
14343
|
-
// // return await done();
|
|
14344
|
-
// }
|
|
14345
14000
|
|
|
14346
14001
|
var $div = func.UI.screen.create_container(SESSION_ID, $root_container, nodeP, $container, paramsP, parent_infoP, jobNoP, keyP, parent_nodeP, prop, null, null, element, null, str);
|
|
14347
14002
|
|