From e8edfdadb561cd83bf6e1c3e00d55b8cc2aee6d5 Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期一, 17 十月 2022 17:57:34 +0800 Subject: [PATCH] 2022-10-17 --- src/menu/components/chart/antv-bar/chartcompile/formconfig.jsx | 52 ++++++++++++++++++++++++++++++---------------------- 1 files changed, 30 insertions(+), 22 deletions(-) diff --git a/src/menu/components/chart/antv-bar/chartcompile/formconfig.jsx b/src/menu/components/chart/antv-bar/chartcompile/formconfig.jsx index 784141f..432e43f 100644 --- a/src/menu/components/chart/antv-bar/chartcompile/formconfig.jsx +++ b/src/menu/components/chart/antv-bar/chartcompile/formconfig.jsx @@ -1,8 +1,3 @@ -import zhCN from '@/locales/zh-CN/model.js' -import enUS from '@/locales/en-US/model.js' - -const Formdict = sessionStorage.getItem('lang') !== 'en-US' ? zhCN : enUS - /** * @description 鑾峰彇鍥捐〃瑙嗗浘閰嶇疆琛ㄥ崟 * @param {object} card // 鍥捐〃瀵硅薄 @@ -258,6 +253,8 @@ }]) } + let _label = card.label || 'false' + return [ { type: 'radio', @@ -366,10 +363,10 @@ required: false, options: [{ value: 'true', - text: Formdict['model.true'] + text: '鏄�' }, { value: 'false', - text: Formdict['model.false'] + text: '鍚�' }] }, { type: 'radio', @@ -389,7 +386,7 @@ type: labelOptions.length > 20 ? 'select' : 'radio', key: 'label', label: '鏍囨敞', - initVal: card.label || 'false', + initVal: _label, tooltip: '鍥惧舰鑺傜偣澶勭殑鏁板�笺��', required: false, options: labelOptions @@ -400,6 +397,7 @@ initVal: card.labelColor || 'system', tooltip: '浣跨敤绯荤粺鑹叉椂锛屼娇鐢ㄨ壊绯婚�夐」璁剧疆鐨勭郴缁熼鑹诧紝浣跨敤鑷畾涔変负棰滆壊璁剧疆涓畾涔夌殑鍥惧舰棰滆壊銆�', required: false, + hidden: _label !== 'true', options: [{ value: 'system', text: '绯荤粺' @@ -407,20 +405,21 @@ value: 'custom', text: '鑷畾涔�' }] - // }, { - // type: 'radio', - // key: 'offset', - // label: '鏍囨敞浣嶇疆', - // initVal: card.offset || 'outer', - // required: false, - // options: [{ - // value: 'outer', - // text: '澶栭儴' - // }, { - // value: 'inner', - // text: '鍐呴儴' - // }], - // forbid: card.chartType !== 'bar' + }, { + type: 'radio', + key: 'labelValue', + label: '鏍囨敞鍊�', + initVal: card.labelValue || 'default', + tooltip: '鏍囨敞鍊肩殑鏄剧ず瑙勫垯銆�', + required: false, + hidden: _label === 'false', + options: [{ + value: 'default', + text: '榛樿' + }, { + value: 'zero', + text: '闅愯棌 0 鍊�' + }], }, { type: 'radio', key: 'adjust', @@ -568,6 +567,15 @@ initVal: card.max, required: false }, { + type: 'number', + key: 'XLimit', + min: 2, + label: '瀛楃闄愬埗', + tooltip: 'X杞存渶澶у瓧绗﹂檺鍒躲��', + initVal: card.XLimit || 11, + forbid: appType === 'mob', + required: false + }, { type: 'color', key: 'color', label: '鑹茬郴', -- Gitblit v1.8.0