Commit f4047c8f85cccdc9c4fd3a97389171db463d240c
1 parent
a13a0b0e
1.处理点击取消手动,班次显示成数字的bug
Showing
1 changed file
with
6 additions
and
2 deletions
src/mes/indexMes/index.js
| @@ -988,9 +988,13 @@ const SystemFunComponent = () => { | @@ -988,9 +988,13 @@ const SystemFunComponent = () => { | ||
| 988 | // 切换手动/切换自动 | 988 | // 切换手动/切换自动 |
| 989 | const handleProcedureCall1 = async (params = {}, iFlag) => { | 989 | const handleProcedureCall1 = async (params = {}, iFlag) => { |
| 990 | const extraValues = await new Promise(resolve => { | 990 | const extraValues = await new Promise(resolve => { |
| 991 | + const shiftValue = String(props.app.sShift || '1'); | ||
| 991 | form.setFieldsValue({ | 992 | form.setFieldsValue({ |
| 992 | tReportDate: moment(), | 993 | tReportDate: moment(), |
| 993 | - sTeamType: props.app.sShift | 994 | + sTeamType: { |
| 995 | + value: shiftValue, // 统一为字符串类型 | ||
| 996 | + label: shiftValue === '1' ? '白班' : '夜班' | ||
| 997 | + } | ||
| 994 | }); | 998 | }); |
| 995 | Modal.confirm({ | 999 | Modal.confirm({ |
| 996 | title: "取消手动", | 1000 | title: "取消手动", |
| @@ -1019,7 +1023,7 @@ const SystemFunComponent = () => { | @@ -1019,7 +1023,7 @@ const SystemFunComponent = () => { | ||
| 1019 | onOk() { | 1023 | onOk() { |
| 1020 | const values = form.getFieldsValue(); | 1024 | const values = form.getFieldsValue(); |
| 1021 | const tReportDate = values?.tReportDate.format("YYYY-MM-DD") || ""; | 1025 | const tReportDate = values?.tReportDate.format("YYYY-MM-DD") || ""; |
| 1022 | - const sTeamType = values.sTeamType; | 1026 | + const sTeamType = values.sTeamType?.value || ''; |
| 1023 | resolve({ tReportDate, sTeamType }); | 1027 | resolve({ tReportDate, sTeamType }); |
| 1024 | }, | 1028 | }, |
| 1025 | onCancel() { | 1029 | onCancel() { |