From 63a40e3da5f24b449122fb8b50c16dcbf69d5907 Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期一, 06 三月 2023 09:22:43 +0800 Subject: [PATCH] Merge branch 'master' into positec --- src/tabviews/custom/index.jsx | 41 +++++++++++++++++++++++++++++++++++------ 1 files changed, 35 insertions(+), 6 deletions(-) diff --git a/src/tabviews/custom/index.jsx b/src/tabviews/custom/index.jsx index 2957081..70c202b 100644 --- a/src/tabviews/custom/index.jsx +++ b/src/tabviews/custom/index.jsx @@ -554,6 +554,14 @@ cell.style = {...cell.style, ...cell.btnstyle} } + if (cell.controlField) { + if (/,/ig.test(cell.controlVal)) { + cell.controlVals = cell.controlVal.split(',') + } else { + cell.controlVals = [(cell.controlVal || '')] + } + } + return skip || permAction[cell.uuid] }) } @@ -589,9 +597,12 @@ if (cell.OpenType === 'funcbutton' && cell.funcType === 'print' && cell.verify) { // 鎵撳嵃鏈鸿缃� cell = this.getPrinter(cell, item.uuid) } - if (card.btnstyle) { // 鍏煎 - card.style = card.style || {} - card.style = {...card.style, ...card.btnstyle} + if (cell.controlField) { + if (/,/ig.test(cell.controlVal)) { + cell.controlVals = cell.controlVal.split(',') + } else { + cell.controlVals = [(cell.controlVal || '')] + } } } else if (['text', 'number', 'formula'].includes(cell.eleType)) { if (!cell.height) { @@ -632,9 +643,12 @@ if (cell.OpenType === 'funcbutton' && cell.funcType === 'print' && cell.verify) { // 鎵撳嵃鏈鸿缃� cell = this.getPrinter(cell, item.uuid) } - if (card.btnstyle) { // 鍏煎 - card.style = card.style || {} - card.style = {...card.style, ...card.btnstyle} + if (cell.controlField) { + if (/,/ig.test(cell.controlVal)) { + cell.controlVals = cell.controlVal.split(',') + } else { + cell.controlVals = [(cell.controlVal || '')] + } } } else if (['text', 'number', 'formula'].includes(cell.eleType)) { if (!cell.height) { @@ -680,6 +694,13 @@ if (cell.OpenType === 'funcbutton' && cell.funcType === 'print' && cell.verify) { // 鎵撳嵃鏈鸿缃� cell = this.getPrinter(cell, item.uuid) } + if (cell.controlField) { + if (/,/ig.test(cell.controlVal)) { + cell.controlVals = cell.controlVal.split(',') + } else { + cell.controlVals = [(cell.controlVal || '')] + } + } } else if (['text', 'number', 'formula'].includes(cell.eleType)) { if (!cell.height) { cell.innerHeight = 'auto' @@ -724,6 +745,14 @@ cell.style = {...cell.style, ...cell.btnstyle} } + if (cell.controlField) { + if (/,/ig.test(cell.controlVal)) { + cell.controlVals = cell.controlVal.split(',') + } else { + cell.controlVals = [(cell.controlVal || '')] + } + } + return skip || permAction[cell.uuid] }) return col.elements.length !== 0 -- Gitblit v1.8.0