@xuda.io/runtime-bundle 1.0.557 → 1.0.558

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.
@@ -9326,47 +9326,31 @@ func.UI.update_xu_ref = function (SESSION_ID, dsSessionP, ref_field_id, $elm) {
9326
9326
  let _ds_0 = _session.DS_GLB[0];
9327
9327
 
9328
9328
  const _ds = func.utils.clean_returned_datasource(SESSION_ID, dsSessionP);
9329
+ try {
9330
+ const row_idx = func.common.find_ROWID_idx(_ds, _ds.currentRecordId);
9329
9331
 
9330
- const row_idx = func.common.find_ROWID_idx(_ds, _ds.currentRecordId);
9332
+ let SYS_GLOBAL_OBJ_REFS = _ds_0.data_system['SYS_GLOBAL_OBJ_REFS'];
9331
9333
 
9332
- let SYS_GLOBAL_OBJ_REFS = _ds_0.data_system['SYS_GLOBAL_OBJ_REFS'];
9334
+ let obj = { ds: _ds, data: _ds?.data_feed?.rows?.[row_idx] || {}, props: _ds.in_parameters || {} };
9333
9335
 
9334
- // if (!SYS_GLOBAL_OBJ_REFS[ref_field_id]) {
9335
- // SYS_GLOBAL_OBJ_REFS[ref_field_id] = {};
9336
- // }
9337
- // SYS_GLOBAL_OBJ_REFS[ref_field_id].ds = _ds;
9338
- // SYS_GLOBAL_OBJ_REFS[ref_field_id].data = _ds?.data_feed?.rows?.[row_idx] || {};
9339
- // SYS_GLOBAL_OBJ_REFS[ref_field_id].props = _ds.in_parameters || {};
9340
-
9341
- // if ($elm) {
9342
- // const attributes = $elm?.data()?.xuData?.xuPanelProps || $elm?.data()?.xuData?.debug_info?.attribute_stat || {};
9343
- // SYS_GLOBAL_OBJ_REFS[ref_field_id].attributes = attributes;
9344
- // SYS_GLOBAL_OBJ_REFS[ref_field_id].xu_ui_id = $elm.attr('xu-ui-id');
9345
- // }
9346
-
9347
- let obj = { ds: _ds, data: _ds?.data_feed?.rows?.[row_idx] || {}, props: _ds.in_parameters || {} };
9348
-
9349
- if ($elm) {
9350
- const attributes = $elm?.data()?.xuData?.xuPanelProps || $elm?.data()?.xuData?.debug_info?.attribute_stat || {};
9351
- obj.attributes = attributes;
9352
- obj.xu_ui_id = $elm.attr('xu-ui-id');
9353
- }
9336
+ if ($elm) {
9337
+ const attributes = $elm?.data()?.xuData?.xuPanelProps || $elm?.data()?.xuData?.debug_info?.attribute_stat || {};
9338
+ obj.attributes = attributes;
9339
+ obj.xu_ui_id = $elm.attr('xu-ui-id');
9340
+ }
9354
9341
 
9355
- if (!_.isEqual(SYS_GLOBAL_OBJ_REFS?.[ref_field_id] || {}, obj)) {
9356
- if (!SYS_GLOBAL_OBJ_REFS[ref_field_id]) {
9357
- SYS_GLOBAL_OBJ_REFS[ref_field_id] = {};
9342
+ if (!_.isEqual(SYS_GLOBAL_OBJ_REFS?.[ref_field_id] || {}, obj)) {
9343
+ if (!SYS_GLOBAL_OBJ_REFS[ref_field_id]) {
9344
+ SYS_GLOBAL_OBJ_REFS[ref_field_id] = {};
9345
+ }
9346
+ SYS_GLOBAL_OBJ_REFS[ref_field_id] = obj;
9347
+ ret = true;
9358
9348
  }
9359
- SYS_GLOBAL_OBJ_REFS[ref_field_id] = obj;
9360
- ret = true;
9349
+ } catch (error) {
9350
+ // error normal if find_ROWID_idx fail
9361
9351
  }
9352
+
9362
9353
  return ret;
9363
- // func.datasource.update(SESSION_ID, {
9364
- // [0]: {
9365
- // ['datasource_main']: {
9366
- // 'data_system.SYS_GLOBAL_OBJ_REFS': { [`${ref_field_id}`]: obj },
9367
- // },
9368
- // },
9369
- // });
9370
9354
  };
9371
9355
 
9372
9356
  func.UI.find_field_in_progUi_attributes = function (progUi, field_id, prop, tag_name) {
@@ -9327,47 +9327,31 @@ func.UI.update_xu_ref = function (SESSION_ID, dsSessionP, ref_field_id, $elm) {
9327
9327
  let _ds_0 = _session.DS_GLB[0];
9328
9328
 
9329
9329
  const _ds = func.utils.clean_returned_datasource(SESSION_ID, dsSessionP);
9330
+ try {
9331
+ const row_idx = func.common.find_ROWID_idx(_ds, _ds.currentRecordId);
9330
9332
 
9331
- const row_idx = func.common.find_ROWID_idx(_ds, _ds.currentRecordId);
9333
+ let SYS_GLOBAL_OBJ_REFS = _ds_0.data_system['SYS_GLOBAL_OBJ_REFS'];
9332
9334
 
9333
- let SYS_GLOBAL_OBJ_REFS = _ds_0.data_system['SYS_GLOBAL_OBJ_REFS'];
9335
+ let obj = { ds: _ds, data: _ds?.data_feed?.rows?.[row_idx] || {}, props: _ds.in_parameters || {} };
9334
9336
 
9335
- // if (!SYS_GLOBAL_OBJ_REFS[ref_field_id]) {
9336
- // SYS_GLOBAL_OBJ_REFS[ref_field_id] = {};
9337
- // }
9338
- // SYS_GLOBAL_OBJ_REFS[ref_field_id].ds = _ds;
9339
- // SYS_GLOBAL_OBJ_REFS[ref_field_id].data = _ds?.data_feed?.rows?.[row_idx] || {};
9340
- // SYS_GLOBAL_OBJ_REFS[ref_field_id].props = _ds.in_parameters || {};
9341
-
9342
- // if ($elm) {
9343
- // const attributes = $elm?.data()?.xuData?.xuPanelProps || $elm?.data()?.xuData?.debug_info?.attribute_stat || {};
9344
- // SYS_GLOBAL_OBJ_REFS[ref_field_id].attributes = attributes;
9345
- // SYS_GLOBAL_OBJ_REFS[ref_field_id].xu_ui_id = $elm.attr('xu-ui-id');
9346
- // }
9347
-
9348
- let obj = { ds: _ds, data: _ds?.data_feed?.rows?.[row_idx] || {}, props: _ds.in_parameters || {} };
9349
-
9350
- if ($elm) {
9351
- const attributes = $elm?.data()?.xuData?.xuPanelProps || $elm?.data()?.xuData?.debug_info?.attribute_stat || {};
9352
- obj.attributes = attributes;
9353
- obj.xu_ui_id = $elm.attr('xu-ui-id');
9354
- }
9337
+ if ($elm) {
9338
+ const attributes = $elm?.data()?.xuData?.xuPanelProps || $elm?.data()?.xuData?.debug_info?.attribute_stat || {};
9339
+ obj.attributes = attributes;
9340
+ obj.xu_ui_id = $elm.attr('xu-ui-id');
9341
+ }
9355
9342
 
9356
- if (!_.isEqual(SYS_GLOBAL_OBJ_REFS?.[ref_field_id] || {}, obj)) {
9357
- if (!SYS_GLOBAL_OBJ_REFS[ref_field_id]) {
9358
- SYS_GLOBAL_OBJ_REFS[ref_field_id] = {};
9343
+ if (!_.isEqual(SYS_GLOBAL_OBJ_REFS?.[ref_field_id] || {}, obj)) {
9344
+ if (!SYS_GLOBAL_OBJ_REFS[ref_field_id]) {
9345
+ SYS_GLOBAL_OBJ_REFS[ref_field_id] = {};
9346
+ }
9347
+ SYS_GLOBAL_OBJ_REFS[ref_field_id] = obj;
9348
+ ret = true;
9359
9349
  }
9360
- SYS_GLOBAL_OBJ_REFS[ref_field_id] = obj;
9361
- ret = true;
9350
+ } catch (error) {
9351
+ // error normal if find_ROWID_idx fail
9362
9352
  }
9353
+
9363
9354
  return ret;
9364
- // func.datasource.update(SESSION_ID, {
9365
- // [0]: {
9366
- // ['datasource_main']: {
9367
- // 'data_system.SYS_GLOBAL_OBJ_REFS': { [`${ref_field_id}`]: obj },
9368
- // },
9369
- // },
9370
- // });
9371
9355
  };
9372
9356
 
9373
9357
  func.UI.find_field_in_progUi_attributes = function (progUi, field_id, prop, tag_name) {