@xuda.io/runtime-bundle 1.0.804 → 1.0.806
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.
|
@@ -27833,10 +27833,11 @@ func.UI.worker.execute = async function (SESSION_ID, queue_obj) {
|
|
|
27833
27833
|
return func.UI.worker.delete_job(SESSION_ID, queue_obj.job_num);
|
|
27834
27834
|
},
|
|
27835
27835
|
render_viewport: async function () {
|
|
27836
|
-
const { nodeP, $
|
|
27836
|
+
const { nodeP, $div, parent_infoP, $root_container, jobNoP, is_skeleton, paramsP } = queue_obj?.paramsP || {};
|
|
27837
27837
|
if (nodeP?.children?.length) {
|
|
27838
|
+
func.UI.screen.hover_in(SESSION_ID, $div, $container, paramsP);
|
|
27838
27839
|
for await (const [key, val] of Object.entries(nodeP.children)) {
|
|
27839
|
-
const ret = await func.UI.screen.render_ui_tree(SESSION_ID, $
|
|
27840
|
+
const ret = await func.UI.screen.render_ui_tree(SESSION_ID, $div, nodeP.children[key], parent_infoP, paramsP, jobNoP, is_skeleton, Number(key), null, nodeP, null, $root_container);
|
|
27840
27841
|
}
|
|
27841
27842
|
}
|
|
27842
27843
|
return func.UI.worker.delete_job(SESSION_ID, queue_obj.job_num);
|
|
@@ -34418,7 +34419,8 @@ func.UI.screen.render_ui_tree = async function (SESSION_ID, $container, nodeP, p
|
|
|
34418
34419
|
|
|
34419
34420
|
observer.observe($div[0]);
|
|
34420
34421
|
} else {
|
|
34421
|
-
await render_child();
|
|
34422
|
+
// await render_child();
|
|
34423
|
+
await iterate_child($div, nodeP, parent_infoP, $root_container);
|
|
34422
34424
|
}
|
|
34423
34425
|
|
|
34424
34426
|
// const ret_iterate_child = await iterate_child($div, nodeP, parent_infoP, null, $root_container);
|
|
@@ -34466,6 +34468,96 @@ func.UI.screen.refresh_document_changes_for_realtime_update = async function (SE
|
|
|
34466
34468
|
}
|
|
34467
34469
|
}
|
|
34468
34470
|
};
|
|
34471
|
+
|
|
34472
|
+
func.UI.screen.hover_in = function (SESSION_ID, $div, $container, paramsP) {
|
|
34473
|
+
if (is_skeleton || EXP_BUSY) return;
|
|
34474
|
+
|
|
34475
|
+
var _session = SESSION_OBJ[SESSION_ID];
|
|
34476
|
+
var _ds = _session.DS_GLB[paramsP.dsSessionP];
|
|
34477
|
+
|
|
34478
|
+
CLIENT_ACTIVITY_TS = Date.now();
|
|
34479
|
+
if (_$($container)?.data()?.xuData?.debug_info) _$($container).data().xuData.debug_info.hover_item = $div.attr('xu-ui-id');
|
|
34480
|
+
if (!_ds) return;
|
|
34481
|
+
///////// SET Attributes///////////
|
|
34482
|
+
let attributes = {};
|
|
34483
|
+
$.each($div[0].attributes, function (index, attr) {
|
|
34484
|
+
attributes[attr.name] = attr.value;
|
|
34485
|
+
});
|
|
34486
|
+
|
|
34487
|
+
SESSION_OBJ[SESSION_ID].DS_GLB[0].data_system.SYS_OBJ_WIN_ELEMENT_HOVERED_ATTRIBUTES = attributes;
|
|
34488
|
+
//////////////////////////////////
|
|
34489
|
+
if (!$div.data()?.xuData) return;
|
|
34490
|
+
const _iterate_info = $div.data().xuData.iterate_info;
|
|
34491
|
+
if (_iterate_info) {
|
|
34492
|
+
if (_iterate_info.is_key_dynamic_field) {
|
|
34493
|
+
_ds.dynamic_fields[_iterate_info.iterator_key].value = _iterate_info._key;
|
|
34494
|
+
} else {
|
|
34495
|
+
try {
|
|
34496
|
+
const row_idx = func.common.find_ROWID_idx(_ds, _ds.currentRecordId);
|
|
34497
|
+
_ds.data_feed.rows[row_idx][_iterate_info.iterator_key] = _iterate_info._key;
|
|
34498
|
+
} catch (err) {
|
|
34499
|
+
console.error(err);
|
|
34500
|
+
}
|
|
34501
|
+
}
|
|
34502
|
+
|
|
34503
|
+
if (_iterate_info.is_val_dynamic_field) {
|
|
34504
|
+
_ds.dynamic_fields[_iterate_info.iterator_val].value = _iterate_info._val;
|
|
34505
|
+
} else {
|
|
34506
|
+
try {
|
|
34507
|
+
const row_idx = func.common.find_ROWID_idx(_ds, _ds.currentRecordId);
|
|
34508
|
+
_ds.data_feed.rows[row_idx][_iterate_info.iterator_val] = _iterate_info._val;
|
|
34509
|
+
} catch (err) {
|
|
34510
|
+
console.error(err);
|
|
34511
|
+
}
|
|
34512
|
+
}
|
|
34513
|
+
}
|
|
34514
|
+
|
|
34515
|
+
if ($div && _$($div) && _ds && paramsP.renderType === 'grid') {
|
|
34516
|
+
func.UI.worker.add_to_queue(SESSION_ID, 'gui event', 'update_datasource', { currentRecordId: _$($div).data().xuData.currentRecordId }, null, null, paramsP.dsSessionP);
|
|
34517
|
+
}
|
|
34518
|
+
|
|
34519
|
+
const set_value = function (field_id, value) {
|
|
34520
|
+
var currentRecordId = _$($div).data().xuData.currentRecordId;
|
|
34521
|
+
|
|
34522
|
+
func.UI.worker.add_to_queue(
|
|
34523
|
+
SESSION_ID,
|
|
34524
|
+
'gui event',
|
|
34525
|
+
'update_datasource',
|
|
34526
|
+
{
|
|
34527
|
+
currentRecordId,
|
|
34528
|
+
field_id,
|
|
34529
|
+
field_value: value,
|
|
34530
|
+
},
|
|
34531
|
+
null,
|
|
34532
|
+
null,
|
|
34533
|
+
paramsP.dsSessionP,
|
|
34534
|
+
);
|
|
34535
|
+
};
|
|
34536
|
+
|
|
34537
|
+
if ($div?.data()?.iterate_info) {
|
|
34538
|
+
var data = $div.data().xuData.iterate_info;
|
|
34539
|
+
if (data.iterator_key) {
|
|
34540
|
+
set_value(data.iterator_key, data._key);
|
|
34541
|
+
}
|
|
34542
|
+
if (data.iterator_val) {
|
|
34543
|
+
set_value(data.iterator_val, data._val);
|
|
34544
|
+
}
|
|
34545
|
+
}
|
|
34546
|
+
};
|
|
34547
|
+
func.UI.screen.hover_out = function (SESSION_ID, $container, is_skeleton, paramsP) {
|
|
34548
|
+
if (is_skeleton || EXP_BUSY) return;
|
|
34549
|
+
|
|
34550
|
+
var _session = SESSION_OBJ[SESSION_ID];
|
|
34551
|
+
var _ds = _session.DS_GLB[paramsP.dsSessionP];
|
|
34552
|
+
|
|
34553
|
+
CLIENT_ACTIVITY_TS = Date.now();
|
|
34554
|
+
if (_$($container)?.data()?.xuData?.debug_info) {
|
|
34555
|
+
_$($container).data().xuData.debug_info.hover_item = null;
|
|
34556
|
+
}
|
|
34557
|
+
if (_ds?.data_system) {
|
|
34558
|
+
SESSION_OBJ[SESSION_ID].DS_GLB[0].data_system.SYS_OBJ_WIN_ELEMENT_HOVERED_ATTRIBUTES = {};
|
|
34559
|
+
}
|
|
34560
|
+
};
|
|
34469
34561
|
func.UI.component = {};
|
|
34470
34562
|
|
|
34471
34563
|
func.UI.component.create_app_modal_component = function (
|