浏览代码

🐞 fix(修复很多bug): 修改

修改
tags/小炒逻辑变更前
txb 2 年前
父节点
当前提交
dfcd14ae35
共有 6 个文件被更改,包括 25 次插入52 次删除
  1. +1
    -2
      src/pages/device/deviceInfo/index.jsx
  2. +5
    -1
      src/pages/device/deviceStock/components/CreateForm.jsx
  3. +14
    -27
      src/pages/erp/basic/product/components/CreateForm.jsx
  4. +0
    -12
      src/pages/erp/basic/product/index.jsx
  5. +2
    -8
      src/pages/goods/goods-boms-manage/index.jsx
  6. +3
    -2
      src/pages/sys/org/components/CreateForm.jsx

+ 1
- 2
src/pages/device/deviceInfo/index.jsx 查看文件

@@ -38,8 +38,7 @@ const handleAdd = async (fields) => {
const handleUpdate = async (fields) => { const handleUpdate = async (fields) => {
try { try {
message.loading('正在修改', key); message.loading('正在修改', key);
message.destroy(key);
await UpdateDeviceInfoPage(JSON.stringify(fields)).then((r) => {
await UpdateDeviceInfo(JSON.stringify(fields)).then((r) => {
message.destroy(key); message.destroy(key);
if (r.data) { if (r.data) {
message.success('修改成功'); message.success('修改成功');


+ 5
- 1
src/pages/device/deviceStock/components/CreateForm.jsx 查看文件

@@ -41,7 +41,11 @@ const CreateForm = (props) => {
label="原料名称" label="原料名称"
rules={[{ required: true, message: '请选择原料名称' }]} rules={[{ required: true, message: '请选择原料名称' }]}
> >
<Select placeholder="请选择原料名称">
<Select placeholder="请选择原料名称" showSearch
optionFilterProp="children"
filterOption={(input, option) =>
option.children.toLowerCase().indexOf(input.toLowerCase()) >= 0
}>
{batchingList.map((item, index) => { {batchingList.map((item, index) => {
return ( return (
<Select.Option index={index} value={item.id} key={item.id}> <Select.Option index={index} value={item.id} key={item.id}>


+ 14
- 27
src/pages/erp/basic/product/components/CreateForm.jsx 查看文件

@@ -119,34 +119,35 @@ const CreateForm = (props) => {
onFinish={props.onFinish} onFinish={props.onFinish}
> >
<Row gutter={16}> <Row gutter={16}>
<Col lg={8} md={12} sm={24}>
<ProFormText name="id" hidden={true} />
<Col lg={8} md={12} sm={24}>
<ProFormText <ProFormText
label={fieldLabels.name}
name="name"
label={fieldLabels.code}
name="code"
rules={[ rules={[
{ {
required: true, required: true,
max: 200,
max: 50,
}, },
]} ]}
placeholder="请输入原料名称"
placeholder="请输入原料编码"
onChange={(item) => {
setCode(item.target.value);
}}
/> />
</Col> </Col>
<Col lg={8} md={12} sm={24}> <Col lg={8} md={12} sm={24}>
<ProFormText name="id" hidden={true} />
<ProFormText <ProFormText
label={fieldLabels.code}
name="code"
label={fieldLabels.name}
name="name"
rules={[ rules={[
{ {
required: true, required: true,
max: 50,
max: 200,
}, },
]} ]}
placeholder="请输入原料编码"
onChange={(item) => {
setCode(item.target.value);
}}
placeholder="请输入原料名称"
/> />
</Col> </Col>
<Col lg={8} md={12} sm={24}> <Col lg={8} md={12} sm={24}>
@@ -205,20 +206,6 @@ const CreateForm = (props) => {
placeholder="请选择物料类型" placeholder="请选择物料类型"
/> />
</Col> </Col>
<Col lg={8} md={12} sm={24}>
<ProFormSelect
label="配料类型"
name="batchingType"
rules={[
{
required: true,
message: '请选择配料类型',
},
]}
request={async () => props.dicData}
placeholder="请选择配料类型"
/>
</Col>
<Col lg={8} md={12} sm={24}> <Col lg={8} md={12} sm={24}>
<ProFormSelect <ProFormSelect
label={fieldLabels.stockUint} label={fieldLabels.stockUint}


+ 0
- 12
src/pages/erp/basic/product/index.jsx 查看文件

@@ -172,12 +172,6 @@ const ProductManage = () => {
], ],
}, },
}, },
{
title: '配料类型',
dataIndex: 'batchingType',
hideInForm: true,
valueEnum: dicDataAny,
},
{ {
title: '物料编码', title: '物料编码',
dataIndex: 'code', dataIndex: 'code',
@@ -239,12 +233,6 @@ const ProductManage = () => {
valueType: 'date', valueType: 'date',
hideInForm: true, hideInForm: true,
}, },
{
title: '更新时间',
dataIndex: 'updateAt',
valueType: 'date',
hideInForm: true,
},
{ {
title: '操作', title: '操作',
dataIndex: 'option', dataIndex: 'option',


+ 2
- 8
src/pages/goods/goods-boms-manage/index.jsx 查看文件

@@ -65,12 +65,12 @@ const GoodsBomsManage = (props) => {
data[item.value] = { text: item.remark }; data[item.value] = { text: item.remark };
}); });
} }
setDicDataAny(data);
//setDicDataAny(data);
console.log(arr); console.log(arr);
setDicData(arr); setDicData(arr);
}); });
} }
intDicData();
// intDicData();
}, []); }, []);


/** /**
@@ -193,12 +193,6 @@ const GoodsBomsManage = (props) => {
valueType: 'select', valueType: 'select',
valueEnum: stockGoods, valueEnum: stockGoods,
}, },
{
title: '配料类型',
dataIndex: 'batchingType',
hideInForm: true,
valueEnum: dicDataAny,
},
{ {
title: '状态', title: '状态',
dataIndex: 'status', dataIndex: 'status',


+ 3
- 2
src/pages/sys/org/components/CreateForm.jsx 查看文件

@@ -61,8 +61,9 @@ const CreateForm = (props) => {
<Form.Item label={'店铺地址'} name="store_Addr" rules={[{ required: true,max:100 }]}> <Form.Item label={'店铺地址'} name="store_Addr" rules={[{ required: true,max:100 }]}>
<Input placeholder="成都市武侯区桂溪街道环球中心N5-9111C" /> <Input placeholder="成都市武侯区桂溪街道环球中心N5-9111C" />
</Form.Item> </Form.Item>
<Form.Item label={'店铺地址坐标'} name="store_Loc" rules={[{ required: true,max:100,pattern: /^(1[1-2][0-9]\.\d{6,12},((3[0-6])|(2[8-9]))\.\d{6,12};){2,}1[1-2][0-9]\.\d{6,12},((3[0-6])|(2[8-9]))\.\d{6,12}$/,
message: '经纬度格式不对'}]}>
{/* ,pattern: /^(1[1-2][0-9]\.\d{6,12},((3[0-6])|(2[8-9]))\.\d{6,12};){2,}1[1-2][0-9]\.\d{6,12},((3[0-6])|(2[8-9]))\.\d{6,12}$/,
message: '经纬度格式不对'} */}
<Form.Item label={'店铺地址坐标'} name="store_Loc" rules={[{ required: true,max:100}]}>
<Input placeholder="104.070734,30.575041" /> <Input placeholder="104.070734,30.575041" />
</Form.Item> </Form.Item>
<Form.Item name="sort" label="排序"> <Form.Item name="sort" label="排序">


正在加载...
取消
保存