zet-lib 1.3.3 → 1.3.5
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/lib/zRoute.js +10 -5
- package/package.json +1 -1
package/lib/zRoute.js
CHANGED
|
@@ -2475,6 +2475,7 @@ zRoute.forms = (req, res, MYMODEL, relations, data = {}, tableRelations = {}) =>
|
|
|
2475
2475
|
break
|
|
2476
2476
|
case 'radio':
|
|
2477
2477
|
obj.type = 'radio'
|
|
2478
|
+
obj.class = '';
|
|
2478
2479
|
obj.data = relations[key]
|
|
2479
2480
|
obj.array = relations[key + 'Array']
|
|
2480
2481
|
break
|
|
@@ -4527,11 +4528,14 @@ zRoute.modelsCacheRenew = (table, companyId) => {
|
|
|
4527
4528
|
}
|
|
4528
4529
|
|
|
4529
4530
|
let MODELS_DRAGDROPS = myCache.get('MODELS_DRAGDROPS')
|
|
4530
|
-
|
|
4531
|
-
MODELS_DRAGDROPS[
|
|
4532
|
-
|
|
4533
|
-
|
|
4534
|
-
|
|
4531
|
+
for (let key in MODELS_DRAGDROPS) {
|
|
4532
|
+
let DRAGDROPS = MODELS_DRAGDROPS[key] || []
|
|
4533
|
+
DRAGDROPS.map((item) => {
|
|
4534
|
+
if (item.objectSQL.table == table) {
|
|
4535
|
+
connection.results(item.objectSQL).then(function (results) {
|
|
4536
|
+
myCache.set(item.key, results)
|
|
4537
|
+
})
|
|
4538
|
+
}
|
|
4535
4539
|
})
|
|
4536
4540
|
}
|
|
4537
4541
|
}
|
|
@@ -4539,6 +4543,7 @@ zRoute.modelsCacheRenew = (table, companyId) => {
|
|
|
4539
4543
|
console.log(err)
|
|
4540
4544
|
}
|
|
4541
4545
|
}
|
|
4546
|
+
|
|
4542
4547
|
zRoute.makeFunctionsSystem = () => {
|
|
4543
4548
|
try {
|
|
4544
4549
|
let obj = myCache.get('ZFUNCTIONS')
|