From 717775a33f61d867b8bdd6cac9b33211dcb5a34e Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期五, 19 二月 2021 16:35:22 +0800 Subject: [PATCH] 2021-02-19 --- src/views/mobmanage/submutilform/index.jsx | 79 ++++++++++++++++++++------------------- 1 files changed, 40 insertions(+), 39 deletions(-) diff --git a/src/views/mobmanage/submutilform/index.jsx b/src/views/mobmanage/submutilform/index.jsx index 4861b60..36af92e 100644 --- a/src/views/mobmanage/submutilform/index.jsx +++ b/src/views/mobmanage/submutilform/index.jsx @@ -1,6 +1,6 @@ import React, {Component} from 'react' import PropTypes from 'prop-types' -import { Form, Row, Col, Input, Select, Radio } from 'antd' +import { Form, Row, Col, Select, Radio } from 'antd' import './index.scss' class MainSearch extends Component { @@ -50,23 +50,9 @@ <Form {...formItemLayout} className="mob-card-edit-form"> <Row gutter={24}> <Col span={24}> - <Form.Item label="搴旂敤鍚�"> - {getFieldDecorator('name', { - initialValue: card ? card.name : '', - rules: [{ - required: true, - message: '璇疯緭鍏ュ簲鐢ㄥ悕!' - }, { - max: 20, - message: '搴旂敤鍚嶄笉鍙秴杩�20涓瓧绗�!' - }] - })(<Input placeholder="" autoComplete="off" onPressEnter={this.handleSubmit} />)} - </Form.Item> - </Col> - <Col span={24}> <Form.Item label="搴旂敤绫诲瀷"> - {getFieldDecorator('type', { - initialValue: card ? card.type : 'mob', + {getFieldDecorator('typename', { + initialValue: card ? card.typename : 'mob', rules: [ { required: true, @@ -74,38 +60,53 @@ } ] })( - <Select> - <Select.Option value="mob">绉诲姩绔�</Select.Option> + <Select disabled={type === 'edit'}> + <Select.Option value="mob">绉诲姩绔�(鍖呮嫭android銆乮os)</Select.Option> <Select.Option value="pc">PC绔�</Select.Option> </Select> )} </Form.Item> </Col> <Col span={24}> - <Form.Item label="搴旂敤缂栫爜"> - {getFieldDecorator('keiNo', { - initialValue: card ? card.keiNo : '', - rules: [{ - required: true, - message: '璇疯緭鍏ュ簲鐢ㄧ紪鐮�!' - }, { - pattern: /^[a-zA-Z_]*$/ig, - message: '搴旂敤缂栫爜鍙厑璁稿寘鍚ぇ灏忓啓瀛楁瘝鍙奯!' - }, { - max: 20, - message: '搴旂敤缂栫爜涓嶅彲瓒呰繃20涓瓧绗�!' - }] - })(<Input placeholder="" disabled={type === 'edit'} autoComplete="off" onPressEnter={this.handleSubmit} />)} + <Form.Item label="璇█"> + {getFieldDecorator('lang', { + initialValue: card ? card.lang || 'zh-CN' : 'zh-CN' + })( + <Radio.Group> + <Radio value="zh-CN">涓枃</Radio> + <Radio value="en-US">鑻辨枃</Radio> + </Radio.Group> + )} + </Form.Item> + </Col> + <Col span={24}> + <Form.Item label="鐧诲綍"> + {getFieldDecorator('login_types', { + initialValue: card ? card.login_types || 'true' : 'true' + })( + <Radio.Group> + <Radio value="true">闇�瑕�</Radio> + <Radio value="false">涓嶉渶瑕�</Radio> + </Radio.Group> + )} </Form.Item> </Col> <Col span={24}> <Form.Item label="鏉冮檺绠$悊"> - {getFieldDecorator('role_manage', { - initialValue: card ? card.role_manage || 'false' : 'false', - rules: [{ - required: true, - message: '璇烽�夋嫨鏄惁鍚敤鏉冮檺绠$悊!' - }] + {getFieldDecorator('role_type', { + initialValue: card ? card.role_type || 'true' : 'true' + })( + <Radio.Group> + <Radio value="true">鍚敤</Radio> + <Radio value="false">涓嶅惎鐢�</Radio> + </Radio.Group> + )} + </Form.Item> + </Col> + <Col span={24}> + <Form.Item label="鐭繛鎺�"> + {getFieldDecorator('link_type', { + initialValue: card ? card.link_type || 'true' : 'true' })( <Radio.Group> <Radio value="true">鍚敤</Radio> -- Gitblit v1.8.0