zet-lib 1.2.52 → 1.2.53
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 +4 -10
- package/package.json +1 -1
package/lib/zRoute.js
CHANGED
|
@@ -3499,13 +3499,9 @@ zRoute.import = async (req, res, MYMODEL) => {
|
|
|
3499
3499
|
})
|
|
3500
3500
|
hd += `<th>${LANGUAGE['noted']}</th>`
|
|
3501
3501
|
hd += `</tr>`
|
|
3502
|
-
|
|
3503
|
-
console.log(results)
|
|
3504
3502
|
results[1].map((item, index) => {
|
|
3505
3503
|
keys[index] = item
|
|
3506
3504
|
})
|
|
3507
|
-
|
|
3508
|
-
console.log(keys)
|
|
3509
3505
|
let isCut = false
|
|
3510
3506
|
if (columnLength > 20 && resultsLength > 2000) {
|
|
3511
3507
|
io.to(room).emit('message', 'short display data!')
|
|
@@ -3543,16 +3539,14 @@ zRoute.import = async (req, res, MYMODEL) => {
|
|
|
3543
3539
|
if (result_alias.id) {
|
|
3544
3540
|
data[keys[prop]] = result_alias.id
|
|
3545
3541
|
}
|
|
3546
|
-
} else if (MYMODEL.widgets[keys[prop]].name === 'integer') {
|
|
3547
|
-
data[keys[prop]] = parseInt(value) || null
|
|
3548
|
-
} else if (MYMODEL.widgets[keys[prop]].name === 'virtual') {
|
|
3549
|
-
//empty
|
|
3550
3542
|
} else {
|
|
3551
|
-
|
|
3543
|
+
let name = MYMODEL.widgets[keys[prop]] && MYMODEL.widgets[keys[prop]].name ? MYMODEL.widgets[keys[prop]].name : ''
|
|
3544
|
+
if (name != 'virtual') {
|
|
3545
|
+
data[keys[prop]] = value
|
|
3546
|
+
}
|
|
3552
3547
|
}
|
|
3553
3548
|
}
|
|
3554
3549
|
if (isCut) {
|
|
3555
|
-
console.log('cut and column cut')
|
|
3556
3550
|
if (columnCut < 10) {
|
|
3557
3551
|
hd += `<td>${value || ''}</td>`
|
|
3558
3552
|
}
|