Commit 90c4de1a authored by 张子雨's avatar 张子雨

feat: 优化

parent 0f7c1776
...@@ -753,7 +753,11 @@ class BusinessInfo extends Component { ...@@ -753,7 +753,11 @@ class BusinessInfo extends Component {
<Col span={12}> <Col span={12}>
<Row gutter={24}> <Row gutter={24}>
<Col span={19}> <Col span={19}>
<FormItem label="身份证结束有效期" labelCol={{ span: 12 }}> <FormItem
label="身份证结束有效期"
labelCol={{ span: 12 }}
wrapperCol={{ span: 12 }}
>
{getFieldDecorator('legalPersonEnd', { {getFieldDecorator('legalPersonEnd', {
rules: [{ required: !checkboxDisabled, message: '身份证结束有效期!' }], rules: [{ required: !checkboxDisabled, message: '身份证结束有效期!' }],
initialValue: businessInfo.legalPersonEnd, initialValue: businessInfo.legalPersonEnd,
......
...@@ -2,7 +2,7 @@ import React, { useState, useEffect, useRef } from 'react'; ...@@ -2,7 +2,7 @@ import React, { useState, useEffect, useRef } from 'react';
import { Form } from '@ant-design/compatible'; import { Form } from '@ant-design/compatible';
import moment from 'moment'; import moment from 'moment';
import { PlusSquareFilled, MinusSquareFilled } from '@ant-design/icons'; import { PlusSquareFilled, MinusSquareFilled } from '@ant-design/icons';
import { Modal, Input, TimePicker, Checkbox, Cascader, Radio, notification } from 'antd'; import { Modal, Input, TimePicker, Checkbox, Cascader, Radio, notification, Button } from 'antd';
import { apiAddrArea, apiCreatStore, apiEditStore } from '../services'; import { apiAddrArea, apiCreatStore, apiEditStore } from '../services';
import { weekOptions, weekDefault, layout, businessModel } from '../data'; import { weekOptions, weekDefault, layout, businessModel } from '../data';
import MapModal from '@/components/GaoDeMap'; import MapModal from '@/components/GaoDeMap';
...@@ -261,8 +261,18 @@ const StoreModal = props => { ...@@ -261,8 +261,18 @@ const StoreModal = props => {
width="1000px" width="1000px"
destroyOnClose destroyOnClose
maskClosable={false} maskClosable={false}
onOk={() => onSubmit()} footer={
onCancel={() => handleCancel()} <>
<Button key="back" onClick={() => handleCancel()}>
取消
</Button>
{!disabled && (
<Button key="submit" type="primary" onClick={() => onSubmit()}>
确定
</Button>
)}
</>
}
> >
<Form {...layout} name="formData"> <Form {...layout} name="formData">
<FormItem label="业务模式"> <FormItem label="业务模式">
......
...@@ -25,5 +25,10 @@ export const businessModel = [ ...@@ -25,5 +25,10 @@ export const businessModel = [
{ label: '到店业务(服务类业务)', value: 3 }, { label: '到店业务(服务类业务)', value: 3 },
]; ];
export const businessList = [
{ label: '外卖', value: 1 },
{ label: '实物类', value: 2 },
{ label: '服务类', value: 3 },
];
// 营业日 // 营业日
export const businessStatus = [{ label: '停业', value: 2 }, { label: '营业中', value: 1 }]; export const businessStatus = [{ label: '休息中', value: 2 }, { label: '营业中', value: 1 }];
...@@ -15,7 +15,7 @@ import { ...@@ -15,7 +15,7 @@ import {
import _ from 'lodash'; import _ from 'lodash';
import { el } from 'date-fns/locale'; import { el } from 'date-fns/locale';
import { searchList, apiEnableStore, apiAddrArea, apiproductBusiness } from './services'; import { searchList, apiEnableStore, apiAddrArea, apiproductBusiness } from './services';
import { stateDesc, weeks, layout, businessStatus, businessModel } from './data'; import { stateDesc, weeks, layout, businessStatus, businessList } from './data';
import StoreModal from './components/storeModal'; import StoreModal from './components/storeModal';
import style from './style.less'; import style from './style.less';
...@@ -215,17 +215,13 @@ export default () => { ...@@ -215,17 +215,13 @@ export default () => {
dataIndex: 'productBusiness', dataIndex: 'productBusiness',
width: 120, width: 120,
align: 'center', align: 'center',
render: v => { render: v => (
let str = ''; <div>
v.forEach(it => { {v.map(it => (
businessModel.forEach(item => { <span>{businessList.find(item => +it === +item.value).label}&nbsp;</span>
if (+it === +item.value) { ))}
str += `${item.label}`; </div>
} ),
});
});
return str;
},
}, },
{ {
title: '门店名称', title: '门店名称',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment