@xuda.io/xuda-worker-bundle 1.3.1251 → 1.3.1253
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/index.js +9 -13
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -4119,7 +4119,7 @@ func.datasource.update = async function (
|
|
|
4119
4119
|
).system_globals;
|
|
4120
4120
|
}
|
|
4121
4121
|
|
|
4122
|
-
|
|
4122
|
+
|
|
4123
4123
|
|
|
4124
4124
|
const set_fieldComputed_dependencies = async function (dsNo, field_id, parent_ds) {
|
|
4125
4125
|
|
|
@@ -4143,7 +4143,7 @@ func.datasource.update = async function (
|
|
|
4143
4143
|
|
|
4144
4144
|
const fieldId = val.data.field_id;
|
|
4145
4145
|
|
|
4146
|
-
if (fieldId !== field_id) continue
|
|
4146
|
+
// if (fieldId !== field_id) continue
|
|
4147
4147
|
if (val.data.type !== "virtual" || !val.props.fieldComputed) break
|
|
4148
4148
|
|
|
4149
4149
|
const _propExpressions = val.props?.propExpressions?.fieldValue
|
|
@@ -4154,18 +4154,14 @@ func.datasource.update = async function (
|
|
|
4154
4154
|
|
|
4155
4155
|
if (!propExpressions) return
|
|
4156
4156
|
|
|
4157
|
-
|
|
4158
|
-
fieldComputed_datasource_changes[dsSession] = {}
|
|
4159
|
-
}
|
|
4157
|
+
|
|
4160
4158
|
// iterate ds rows
|
|
4161
4159
|
for (const row of _ds.data_feed?.rows || []) {
|
|
4162
4160
|
// iterate row fields
|
|
4163
4161
|
for (const [key, val] of Object.entries(row)) {
|
|
4164
4162
|
if (key !== field_id) return
|
|
4165
4163
|
try {
|
|
4166
|
-
|
|
4167
|
-
fieldComputed_datasource_changes[dsSession][row._ROWID] = {}
|
|
4168
|
-
}
|
|
4164
|
+
|
|
4169
4165
|
let ret = await func.expression.get(
|
|
4170
4166
|
SESSION_ID,
|
|
4171
4167
|
propExpressions,
|
|
@@ -4173,10 +4169,10 @@ func.datasource.update = async function (
|
|
|
4173
4169
|
"update",
|
|
4174
4170
|
row._ROWID
|
|
4175
4171
|
);
|
|
4176
|
-
fieldComputed_datasource_changes[dsSession][row._ROWID][field_id] = ret.result
|
|
4177
|
-
// const row_idx = func.common.find_ROWID_idx(_ds, record_id);
|
|
4178
4172
|
|
|
4179
|
-
|
|
4173
|
+
const row_idx = func.common.find_ROWID_idx(_ds, row._ROWID);
|
|
4174
|
+
|
|
4175
|
+
_ds.data_feed.rows[row_idx][field_id] = ret.result;
|
|
4180
4176
|
} catch (err) {
|
|
4181
4177
|
console.error(err);
|
|
4182
4178
|
}
|
|
@@ -4223,7 +4219,7 @@ func.datasource.update = async function (
|
|
|
4223
4219
|
try {
|
|
4224
4220
|
const row_idx = func.common.find_ROWID_idx(_ds, record_id);
|
|
4225
4221
|
_ds.data_feed.rows[row_idx][field_id] = value;
|
|
4226
|
-
|
|
4222
|
+
await set_fieldComputed_dependencies(dataSource, field_id, null)
|
|
4227
4223
|
|
|
4228
4224
|
if (!update_local_scope_only) {
|
|
4229
4225
|
let tree_ret = await func.utils.TREE_OBJ.get(SESSION_ID, _ds.prog_id);
|
|
@@ -4288,7 +4284,7 @@ func.datasource.update = async function (
|
|
|
4288
4284
|
}
|
|
4289
4285
|
|
|
4290
4286
|
|
|
4291
|
-
|
|
4287
|
+
|
|
4292
4288
|
|
|
4293
4289
|
|
|
4294
4290
|
}
|