|
@@ -1,7 +1,7 @@
|
|
|
import React from 'react';
|
|
|
-import { Input, Button, Form, Upload, Icon, Spin, message, Row, Col, DatePicker, Select, Radio } from 'antd';
|
|
|
+import { Input, Button, Form, Upload, Icon, Spin, message, Row, Col, DatePicker, Select, Radio, Cascader } from 'antd';
|
|
|
import './certify.less';
|
|
|
-import { addressInit, getBase64, beforeUpload, beforeUploadFile } from '../tools.js';
|
|
|
+import { getBase64, beforeUpload, beforeUploadFile,provinceSelect } from '../tools.js';
|
|
|
import ajax from 'jquery/src/ajax/xhr.js'
|
|
|
import $ from 'jquery/src/ajax';
|
|
|
import moment from 'moment';
|
|
@@ -57,8 +57,6 @@ const Content = Form.create()(React.createClass({
|
|
|
url: globalConfig.context + "/api/user/orgProcess",
|
|
|
success: function (data) {
|
|
|
if (data.data) {
|
|
|
- addressInit('cmbProvince', 'cmbCity', 'cmbArea',
|
|
|
- data.data.licenceProvince, data.data.licenceCity, data.data.licenceArea);
|
|
|
this.setState({
|
|
|
contacts: data.data.contacts,
|
|
|
contactMobile: data.data.contactMobile,
|
|
@@ -66,6 +64,7 @@ const Content = Form.create()(React.createClass({
|
|
|
unitName: data.data.unitName,
|
|
|
registeredCapital: data.data.registeredCapital,
|
|
|
licenceNumber: data.data.licenceNumber,
|
|
|
+ licenceAddress:[data.data.licenceProvince,data.data.licenceCity,data.data.licenceArea],
|
|
|
orgCode: data.data.orgCode,
|
|
|
legalPerson: data.data.legalPerson,
|
|
|
legalPersonIdCard: data.data.legalPersonIdCard,
|
|
@@ -99,14 +98,6 @@ const Content = Form.create()(React.createClass({
|
|
|
handleSubmit(e) {
|
|
|
e.preventDefault();
|
|
|
this.props.form.validateFields((err, values) => {
|
|
|
- //地址值
|
|
|
- let cmbP = document.getElementById('cmbProvince').value;
|
|
|
- let cmbC = document.getElementById('cmbCity').value;
|
|
|
- let cmbA = document.getElementById('cmbArea').value;
|
|
|
- if (!cmbP || !cmbC || !cmbA) {
|
|
|
- message.warning("请选择所在地!");
|
|
|
- return;
|
|
|
- };
|
|
|
if (!this.state.licenceScanningUrl) {
|
|
|
message.warning("请上传营业执照副本!");
|
|
|
return;
|
|
@@ -141,9 +132,9 @@ const Content = Form.create()(React.createClass({
|
|
|
unitName: values.unitName,
|
|
|
registeredCapital: values.registeredCapital,
|
|
|
licenceNumber: values.licenceNumber,
|
|
|
- licenceProvince: cmbP,
|
|
|
- licenceCity: cmbC,
|
|
|
- licenceArea: cmbA,
|
|
|
+ licenceProvince: values.address[0],
|
|
|
+ licenceCity: values.address[1],
|
|
|
+ licenceArea: values.address[2],
|
|
|
licenceScanningUrl: this.state.licenceScanningUrl,
|
|
|
orgCode: values.orgCode,
|
|
|
orgCodeUrl: this.state.orgCodeUrl,
|
|
@@ -211,8 +202,7 @@ const Content = Form.create()(React.createClass({
|
|
|
getLastYearTaxReportUrl(e) {
|
|
|
this.state.lastYearTaxReportUrl = e;
|
|
|
},
|
|
|
- componentDidMount() {
|
|
|
- addressInit('cmbProvince', 'cmbCity', 'cmbArea');
|
|
|
+ componentWillMount() {
|
|
|
this.getData();
|
|
|
},
|
|
|
reloadVCode() {
|
|
@@ -372,12 +362,11 @@ const Content = Form.create()(React.createClass({
|
|
|
wrapperCol={{ span: 18 }}
|
|
|
label="营业执照所在地"
|
|
|
>
|
|
|
- {getFieldDecorator('address')(
|
|
|
- <div>
|
|
|
- <select id="cmbProvince" name="cmbProvince"></select>
|
|
|
- <select id="cmbCity" name="cmbCity"></select>
|
|
|
- <select id="cmbArea" name="cmbArea"></select>
|
|
|
- </div>
|
|
|
+ {getFieldDecorator('address',{
|
|
|
+ initialValue: this.state.address || null,
|
|
|
+ rules: [{type:'array', required: true, message: '请选择地址!' }]
|
|
|
+ })(
|
|
|
+ <Cascader options={provinceSelect()} placeholder="请选择地址" />
|
|
|
)}
|
|
|
</FormItem>
|
|
|
<FormItem
|
|
@@ -426,8 +415,8 @@ const Content = Form.create()(React.createClass({
|
|
|
<div className="hrSituation-roster">
|
|
|
<Upload
|
|
|
name="ratepay"
|
|
|
- action={globalConfig.context + "/api/user/cognizance/upload"}
|
|
|
- data={{ 'sign': 'ratepay_' + (new Date().getFullYear() - 1) }}
|
|
|
+ action={globalConfig.context + "/api/user/cognizance/uploadRatepay"}
|
|
|
+ data={{ 'sign': 'ratepay' }}
|
|
|
beforeUpload={beforeUploadFile}
|
|
|
showUploadList={false}
|
|
|
onChange={(info) => {
|