resolver-egretimp-plus 0.1.55 → 0.1.56
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/package.json
CHANGED
|
@@ -346,9 +346,17 @@ export default {
|
|
|
346
346
|
})
|
|
347
347
|
const defaultTotalFn = (total, val, row) => {
|
|
348
348
|
if (val === undefined || val === null) {
|
|
349
|
-
val =
|
|
349
|
+
val = 0
|
|
350
|
+
if (val === undefined) {
|
|
351
|
+
val = ''
|
|
352
|
+
}
|
|
350
353
|
} else {
|
|
351
|
-
|
|
354
|
+
const strVal = val.toString()
|
|
355
|
+
const negativeFlag = /^-/.test(strVal)
|
|
356
|
+
val = strVal.replace(/[^\d\.]/g, '')
|
|
357
|
+
if (negativeFlag) {
|
|
358
|
+
val = `-${val}`
|
|
359
|
+
}
|
|
352
360
|
}
|
|
353
361
|
const numFlag = !isNaN(Number(val))
|
|
354
362
|
if (total === null || total === undefined) {
|