From e0f90699279803dd529fd1f41b4c3c62e57e0fcb Mon Sep 17 00:00:00 2001
From: skyouc
Date: 星期一, 23 六月 2025 13:48:13 +0800
Subject: [PATCH] 波次下发任务功能优化 代码优化
---
rsf-admin/src/page/system/serialRule/SerialRuleEdit.jsx | 16 +++++++++-------
1 files changed, 9 insertions(+), 7 deletions(-)
diff --git a/rsf-admin/src/page/system/serialRule/SerialRuleEdit.jsx b/rsf-admin/src/page/system/serialRule/SerialRuleEdit.jsx
index 53cf77d..e950bb9 100644
--- a/rsf-admin/src/page/system/serialRule/SerialRuleEdit.jsx
+++ b/rsf-admin/src/page/system/serialRule/SerialRuleEdit.jsx
@@ -43,6 +43,7 @@
const SerialRuleEdit = () => {
const translate = useTranslate();
+ const dicts = JSON.parse(localStorage.getItem('sys_dicts'))?.filter(dict => (dict.dictTypeCode == 'sys_task_reset_type')) || [];
return (
<>
@@ -60,8 +61,8 @@
defaultValues={{}}
// validate={(values) => { }}
>
- <Grid container width={{ xs: '100%', xl: '80%' }} rowSpacing={3} columnSpacing={3}>
- <Grid item xs={12} md={8}>
+ <Grid container width={{ xs: '100%', xl: '90%' }} rowSpacing={3} columnSpacing={3}>
+ <Grid item xs={16} md={10}>
<Typography variant="h6" gutterBottom>
{translate('common.edit.title.main')}
</Typography>
@@ -84,12 +85,14 @@
/>
</Stack>
<Stack direction='row' gap={2}>
- <TextInput
+ <AutocompleteInput
+ choices={dicts}
+ optionText="label"
label="table.field.serialRule.reset"
source="reset"
+ optionValue="value"
parse={v => v}
- validate={required()}
- />
+ validate={[required()]} />
<TextInput
label="table.field.serialRule.resetDep"
source="resetDep"
@@ -106,9 +109,8 @@
parse={v => v}
/>
</Stack>
-
</Grid>
- <Grid item xs={12} md={4}>
+ <Grid item xs={8} md={2}>
<Typography variant="h6" gutterBottom>
{translate('common.edit.title.common')}
</Typography>
--
Gitblit v1.9.1