From 010fdcf8abd58bde5c1106db8ed8448effc75b4b Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期二, 25 二月 2025 16:37:46 +0800 Subject: [PATCH] 2025-02-25 --- src/menu/components/module/voucher/options.jsx | 99 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 99 insertions(+), 0 deletions(-) diff --git a/src/menu/components/module/voucher/options.jsx b/src/menu/components/module/voucher/options.jsx index f03bad5..2f268e6 100644 --- a/src/menu/components/module/voucher/options.jsx +++ b/src/menu/components/module/voucher/options.jsx @@ -1,3 +1,4 @@ +import React from 'react' import MenuUtils from '@/utils/utils-custom.js' /** @@ -17,6 +18,17 @@ bookids.push(item.uuid) } }) + + let menulist = sessionStorage.getItem('fstMenuList') + if (menulist) { + try { + menulist = JSON.parse(menulist) + } catch (e) { + menulist = [] + } + } else { + menulist = [] + } modules = modules.filter(item => !bookids.includes(item.value)) @@ -39,6 +51,15 @@ {value: 'checkVoucher', label: '鏌ョ湅鍑瘉'}, {value: 'createTemp', label: '鏂板妯℃澘'}, {value: 'checkTemp', label: '缂栬緫妯℃澘'}, + ], + controlFields: [ + {field: 'businessType', values: ['createVoucher', 'checkVoucher']}, + {field: 'voucherType', values: ['createVoucher', 'checkVoucher']}, + {field: 'voucherTypeText', values: ['createVoucher', 'checkVoucher']}, + {field: 'voucherSign', values: ['createVoucher', 'checkVoucher']}, + {field: 'printTemp', values: ['createVoucher', 'checkVoucher']}, + {field: 'supModule', values: ['checkTemp', 'checkVoucher']}, + {field: 'attachStatus', values: ['createVoucher', 'checkVoucher']}, ] }, { @@ -70,6 +91,34 @@ allowClear: true }, { + type: 'text', + field: 'businessType', + label: '涓氬姟绫诲瀷', + initval: wrap.businessType || 'fcc01', + required: true + }, + { + type: 'text', + field: 'voucherType', + label: '鍑瘉绫诲瀷', + initval: wrap.voucherType || 'fcc_keeping', + required: true + }, + { + type: 'text', + field: 'voucherTypeText', + label: '鍑瘉绫诲瀷鏂囨湰', + initval: wrap.voucherTypeText || '璁拌处鍑瘉', + required: true + }, + { + type: 'text', + field: 'voucherSign', + label: '鍑瘉绫诲瀷鏍囪瘑', + initval: wrap.voucherSign || 'fcc_keeping', + required: true + }, + { type: 'cascader', field: 'supModule', label: '涓婄骇缁勪欢', @@ -78,6 +127,56 @@ options: modules, allowClear: true, }, + { + type: 'radio', + field: 'attachStatus', + label: '闄勪欢鐘舵��', + initval: wrap.attachStatus || 0, + tooltip: '娣诲姞鎴栦慨鏀瑰嚟璇佹椂锛屼笂浼犻檮浠剁殑鐘舵�併��', + required: true, + options: [ + {value: 0, label: '寰呭鏍�'}, + {value: 10, label: '宸插鏍�'}, + ] + }, + { + type: 'printTemps', + field: 'printTemp', + label: '鎵撳嵃妯℃澘', + initval: wrap.printTemp || '', + help: (record) => { + if (record.printTemp) { + return <span onClick={() => { + sessionStorage.setItem('mk-print-temp', record.printTemp) + window.open('#/hs') + + setTimeout(() => { + sessionStorage.removeItem('mk-print-temp') + }, 50) + }} style={{color: '#1890ff', cursor: 'pointer', fontSize: '13px'}}>#鏌ョ湅妯℃澘</span> + } + return '' + }, + required: true + }, + { + type: 'number', + field: 'space', + label: '鐣欑櫧', + initval: wrap.space || 0, + tooltip: '琛ㄦ牸涓讳綋閮ㄥ垎涓ょ鐨勭┖鐧借窛绂伙紝琛ㄦ牸鍦ㄧ紪杈戞椂涓ょ浼氭湁娣诲姞鍜屽垹闄ゅ浘鏍囥��', + required: false + }, + { + type: 'cascader', + field: 'linkmenu', + label: '鍒锋柊鑿滃崟', + initval: wrap.linkmenu || [], + tooltip: '鐐瑰嚮淇濆瓨鏃堕渶瑕佸埛鏂扮殑鑿滃崟銆�', + required: false, + allowClear: true, + options: menulist + } ] return wrapForm -- Gitblit v1.8.0