@xuda.io/runtime-bundle 1.0.406 → 1.0.408
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.
|
@@ -28078,7 +28078,7 @@ func.UI.worker.execute = async function (SESSION_ID, queue_obj) {
|
|
|
28078
28078
|
null,
|
|
28079
28079
|
queue_obj.paramsP.elem_val.$elm.data().xuData.iterate_info,
|
|
28080
28080
|
);
|
|
28081
|
-
console.log(res);
|
|
28081
|
+
// console.log(res);
|
|
28082
28082
|
}
|
|
28083
28083
|
|
|
28084
28084
|
const attr_new = attr.split('xu-exp:')[1];
|
|
@@ -28246,6 +28246,40 @@ func.UI.update_xu_ref = function (SESSION_ID, dsSessionP, ref_field_id, $elm) {
|
|
|
28246
28246
|
SYS_GLOBAL_OBJ_REFS[ref_field_id].xu_ui_id = $elm.attr('xu-ui-id');
|
|
28247
28247
|
}
|
|
28248
28248
|
};
|
|
28249
|
+
|
|
28250
|
+
func.UI.find_field_in_progUi_attributes = function (progUi, field_id, prop, tag_name) {
|
|
28251
|
+
let elm_node;
|
|
28252
|
+
const iterate_progUi = function (node) {
|
|
28253
|
+
for (let item of node) {
|
|
28254
|
+
if (!tag_name || item.tagName === tag_name) {
|
|
28255
|
+
if (prop) {
|
|
28256
|
+
if (!_.isEmpty(item.attributes)) {
|
|
28257
|
+
for (const [attr, val] of Object.entries(item.attributes)) {
|
|
28258
|
+
if (attr === `xu-exp:${prop}` || attr === prop) {
|
|
28259
|
+
// found = val.includes('@' + field_id);
|
|
28260
|
+
if (val.includes('@' + field_id)) {
|
|
28261
|
+
elm_node = node;
|
|
28262
|
+
break;
|
|
28263
|
+
}
|
|
28264
|
+
}
|
|
28265
|
+
}
|
|
28266
|
+
}
|
|
28267
|
+
if (elm_node) break;
|
|
28268
|
+
|
|
28269
|
+
if (item.children) {
|
|
28270
|
+
iterate_progUi(item.children);
|
|
28271
|
+
}
|
|
28272
|
+
} else {
|
|
28273
|
+
if (tag_name) {
|
|
28274
|
+
elm_node = node;
|
|
28275
|
+
}
|
|
28276
|
+
}
|
|
28277
|
+
}
|
|
28278
|
+
}
|
|
28279
|
+
};
|
|
28280
|
+
iterate_progUi(progUi);
|
|
28281
|
+
return elm_node;
|
|
28282
|
+
};
|
|
28249
28283
|
func.datasource = {};
|
|
28250
28284
|
func.datasource.create = async function (
|
|
28251
28285
|
SESSION_ID,
|
|
@@ -31590,7 +31624,7 @@ func.UI.screen.refresh_xu_attributes = async function (SESSION_ID, fields_arr, j
|
|
|
31590
31624
|
}
|
|
31591
31625
|
}
|
|
31592
31626
|
}
|
|
31593
|
-
|
|
31627
|
+
if (found) break;
|
|
31594
31628
|
|
|
31595
31629
|
if (item.children) {
|
|
31596
31630
|
await iterate_progUi(item.children, item.id);
|
|
@@ -31610,6 +31644,9 @@ func.UI.screen.refresh_xu_attributes = async function (SESSION_ID, fields_arr, j
|
|
|
31610
31644
|
const progUi = $xu_embed_div?.data()?.xuData?.screenInfo?.progUi;
|
|
31611
31645
|
if (progUi) {
|
|
31612
31646
|
await iterate_field_in_progUi(progUi, field_id);
|
|
31647
|
+
// find invisible panels
|
|
31648
|
+
const elm_node = func.UI.find_field_in_progUi_attributes(progUi, field_id, null, 'xu-panel');
|
|
31649
|
+
console.log('elm_node', elm_node);
|
|
31613
31650
|
}
|
|
31614
31651
|
}
|
|
31615
31652
|
// run panels
|
|
@@ -31620,8 +31657,6 @@ func.UI.screen.refresh_xu_attributes = async function (SESSION_ID, fields_arr, j
|
|
|
31620
31657
|
}
|
|
31621
31658
|
}
|
|
31622
31659
|
|
|
31623
|
-
// }
|
|
31624
|
-
|
|
31625
31660
|
func.events.delete_job(SESSION_ID, jobNoP);
|
|
31626
31661
|
};
|
|
31627
31662
|
|
|
@@ -31630,28 +31665,28 @@ func.UI.screen.refresh_screen = async function (SESSION_ID, fields_changed_arr,
|
|
|
31630
31665
|
|
|
31631
31666
|
const panels_obj = func.UI.utils.get_panels_from_dom(SESSION_ID, false);
|
|
31632
31667
|
|
|
31633
|
-
const find_field_in_progUi = function (progUi, field_id, prop) {
|
|
31634
|
-
|
|
31635
|
-
|
|
31636
|
-
|
|
31637
|
-
|
|
31638
|
-
|
|
31639
|
-
|
|
31640
|
-
|
|
31641
|
-
|
|
31642
|
-
|
|
31643
|
-
|
|
31644
|
-
|
|
31645
|
-
|
|
31646
|
-
|
|
31647
|
-
|
|
31648
|
-
|
|
31649
|
-
|
|
31650
|
-
|
|
31651
|
-
|
|
31652
|
-
|
|
31653
|
-
|
|
31654
|
-
};
|
|
31668
|
+
// const find_field_in_progUi = function (progUi, field_id, prop) {
|
|
31669
|
+
// let found;
|
|
31670
|
+
// const iterate_progUi = function (node) {
|
|
31671
|
+
// for (let item of node) {
|
|
31672
|
+
// // if (item.tagName === "xu-panel") {
|
|
31673
|
+
// if (!_.isEmpty(item.attributes)) {
|
|
31674
|
+
// for (const [attr, val] of Object.entries(item.attributes)) {
|
|
31675
|
+
// if (attr === `xu-exp:${prop}`) {
|
|
31676
|
+
// found = val.includes('@' + field_id);
|
|
31677
|
+
// }
|
|
31678
|
+
// }
|
|
31679
|
+
// }
|
|
31680
|
+
// if (found) break;
|
|
31681
|
+
// // }
|
|
31682
|
+
// if (item.children) {
|
|
31683
|
+
// iterate_progUi(item.children);
|
|
31684
|
+
// }
|
|
31685
|
+
// }
|
|
31686
|
+
// };
|
|
31687
|
+
// iterate_progUi(progUi);
|
|
31688
|
+
// return found;
|
|
31689
|
+
// };
|
|
31655
31690
|
|
|
31656
31691
|
for await (const [parent_element_ui_id, panel_val] of Object.entries(panels_obj)) {
|
|
31657
31692
|
const prog_doc = await func.utils.DOCS_OBJ.get(SESSION_ID, panel_val._ds.prog_id);
|
|
@@ -31688,7 +31723,8 @@ func.UI.screen.refresh_screen = async function (SESSION_ID, fields_changed_arr,
|
|
|
31688
31723
|
found = progDataSource_str?.includes('@' + parameter_in_field_id);
|
|
31689
31724
|
if (found) break;
|
|
31690
31725
|
|
|
31691
|
-
found = find_field_in_progUi(prog_doc.progUi, parameter_in_field_id, 'xu-for');
|
|
31726
|
+
// found = find_field_in_progUi(prog_doc.progUi, parameter_in_field_id, 'xu-for');
|
|
31727
|
+
found = func.UI.find_field_in_progUi_attributes(prog_doc.progUi, parameter_in_field_id, 'xu-for');
|
|
31692
31728
|
if (found) break;
|
|
31693
31729
|
}
|
|
31694
31730
|
}
|
|
@@ -31975,6 +32011,9 @@ func.UI.screen.execute_xu_functions = async function (SESSION_ID, is_skeleton, $
|
|
|
31975
32011
|
// Start observing the target node for configured mutations
|
|
31976
32012
|
observer.observe(targetNode, config);
|
|
31977
32013
|
|
|
32014
|
+
// Later, you can stop observing
|
|
32015
|
+
// observer.disconnect();
|
|
32016
|
+
|
|
31978
32017
|
return {};
|
|
31979
32018
|
},
|
|
31980
32019
|
'xu-bind': async function ($elm, val) {
|