|
@@ -3,6 +3,7 @@ import { Icon, Table, Modal, message, Spin, Input, Select, Button, Form ,Upload,
|
|
|
import ajax from 'jquery/src/ajax/xhr.js';
|
|
|
import $ from 'jquery/src/ajax';
|
|
|
import '../userMangagement.less';
|
|
|
+import moment from 'moment';
|
|
|
import {orderTypes,customerType,jiedian,tepi,boutique} from '../../../dataDic.js';
|
|
|
import {splitUrl,getTransactionProject,getChangeState,getTransactionChannel,beforeUploadFile,getProcessStatus,getLiquidationStatus,getboutique} from '../../../tools.js';
|
|
|
const Option = AutoComplete.Option;
|
|
@@ -224,57 +225,7 @@ const NewService = Form.create()(React.createClass({
|
|
|
}
|
|
|
},
|
|
|
],
|
|
|
- flowList:[
|
|
|
- {
|
|
|
- title: '平台流水号',
|
|
|
- dataIndex: 'billNo',
|
|
|
- key: 'billNo',
|
|
|
- }, {
|
|
|
- title: '平台流水时间',
|
|
|
- dataIndex: 'createTime',
|
|
|
- key: 'createTime'
|
|
|
- }, {
|
|
|
- title: '流水金额(万元)',
|
|
|
- dataIndex: 'transactionAmount',
|
|
|
- key: 'transactionAmount'
|
|
|
- },{
|
|
|
- title: '付款人名称',
|
|
|
- dataIndex: 'payerName',
|
|
|
- key: 'payerName'
|
|
|
- }, {
|
|
|
- title: '收款人名称',
|
|
|
- dataIndex: 'payeeName',
|
|
|
- key: 'payeeName'
|
|
|
- },
|
|
|
- {
|
|
|
- title: '流水科目',
|
|
|
- dataIndex: 'transactionSubject',
|
|
|
- key: 'transactionSubject',
|
|
|
- render:(text)=>{return getTransactionProject(text) }
|
|
|
- }, {
|
|
|
- title: '流水渠道',
|
|
|
- dataIndex: 'transactionChannel',
|
|
|
- key: 'transactionChannel',
|
|
|
- render:(text)=>{return getTransactionChannel(text) }
|
|
|
- },{
|
|
|
- title: '财务流水号',
|
|
|
- dataIndex: 'financialPayNo',
|
|
|
- key: 'financialPayNo',
|
|
|
- }, {
|
|
|
- title: '财务流水时间',
|
|
|
- dataIndex: 'financialPayTime',
|
|
|
- key: 'financialPayTime',
|
|
|
- }, {
|
|
|
- title: '流水确认',
|
|
|
- dataIndex: 'confirmSign',
|
|
|
- key: 'confirmSign',
|
|
|
- render:(text)=>{return text?'已确认':'待确认' }
|
|
|
- },{
|
|
|
- title: '确认时间',
|
|
|
- dataIndex: 'confirmTime',
|
|
|
- key: 'confirmTime',
|
|
|
- }
|
|
|
- ],
|
|
|
+
|
|
|
contactList:[],
|
|
|
loading:false,
|
|
|
ContactsLists: [{
|
|
@@ -318,7 +269,7 @@ const NewService = Form.create()(React.createClass({
|
|
|
<Button style={{marginRight:'10px',color:'#ffffff',background:'#f00',border:'none'}}>删除</Button>
|
|
|
</Popconfirm>
|
|
|
:''}
|
|
|
- {record.id?'': <Button type="primary" htmlType="submit" onClick={this.contactSave}>保存</Button>}
|
|
|
+ {record.id?'': <Button type="primary" onClick={this.contactSave}>保存</Button>}
|
|
|
|
|
|
</div>
|
|
|
}
|
|
@@ -376,49 +327,45 @@ const NewService = Form.create()(React.createClass({
|
|
|
};
|
|
|
|
|
|
}
|
|
|
- this.props.form.validateFields((err, values) => {
|
|
|
- if(!err) {
|
|
|
- this.setState({
|
|
|
- loading: true
|
|
|
- });
|
|
|
- let api=this.props.userDetaile?'/api/admin/newOrder/updateServiceOrderNew':'/api/admin/newOrder/createOrder';
|
|
|
- $.ajax({
|
|
|
- method: "POST",
|
|
|
- dataType: "json",
|
|
|
- crossDomain: false,
|
|
|
- url: globalConfig.context + api,
|
|
|
- data: !this.props.userDetaile?{
|
|
|
- uid:this.state.autoId,
|
|
|
- orderType:this.state.orderType,
|
|
|
- contractType:this.state.contractType
|
|
|
- }:{
|
|
|
- orderNo: this.state.orderNo,//订单编号
|
|
|
- totalAmount: this.state.totalAmount,//总金额
|
|
|
- firstAmount: this.state.firstAmount,//首付
|
|
|
- isSubmit: this.state.isSubmit,//保存草稿还是提交
|
|
|
- signDate: this.state.signDate,//签单日期
|
|
|
- contacts: this.state.contacts,//企业负责人
|
|
|
- contactMobile: this.state.contactMobile,//负责人联系方式
|
|
|
- legalPerson: this.state.legalPerson,//企业法人
|
|
|
- legalPersonTel: this.state.legalPersonTel,//企业法人联系电话
|
|
|
- approval: this.state.approval,//特批状态
|
|
|
- contractNo: this.state.contractNo,//合同编号
|
|
|
- orderRemarks: this.state.orderRemarks,//订单备注
|
|
|
- contractPictureUrl:theorgCodeUrl.length?theorgCodeUrl:'',
|
|
|
- }
|
|
|
- }).done(function(data) {
|
|
|
- this.setState({
|
|
|
- loading: false
|
|
|
- });
|
|
|
- if(!data.error.length) {
|
|
|
- message.success('保存成功!');
|
|
|
- this.handleOk()
|
|
|
- } else {
|
|
|
- message.warning(data.error[0].message);
|
|
|
- }
|
|
|
- }.bind(this));
|
|
|
- }
|
|
|
+ this.setState({
|
|
|
+ loading: true
|
|
|
});
|
|
|
+ let api=this.props.userDetaile?'/api/admin/newOrder/updateServiceOrderNew':'/api/admin/newOrder/createOrder';
|
|
|
+ $.ajax({
|
|
|
+ method: "POST",
|
|
|
+ dataType: "json",
|
|
|
+ crossDomain: false,
|
|
|
+ url: globalConfig.context + api,
|
|
|
+ data: !this.props.userDetaile?{
|
|
|
+ uid:this.state.autoId,
|
|
|
+ orderType:this.state.orderType,
|
|
|
+ contractType:this.state.contractType
|
|
|
+ }:{
|
|
|
+ orderNo: this.state.orderNo,//订单编号
|
|
|
+ totalAmount: this.state.totalAmount,//总金额
|
|
|
+ firstAmount: this.state.firstAmount,//首付
|
|
|
+ isSubmit: this.state.isSubmit,//保存草稿还是提交
|
|
|
+ signDate: this.state.signDate,//签单日期
|
|
|
+ contacts: this.state.contacts,//企业负责人
|
|
|
+ contactMobile: this.state.contactMobile,//负责人联系方式
|
|
|
+ legalPerson: this.state.legalPerson,//企业法人
|
|
|
+ legalPersonTel: this.state.legalPersonTel,//企业法人联系电话
|
|
|
+ approval: this.state.approval,//特批状态
|
|
|
+ contractNo: this.state.contractNo,//合同编号
|
|
|
+ orderRemarks: this.state.orderRemarks,//订单备注
|
|
|
+ contractPictureUrl:theorgCodeUrl.length?theorgCodeUrl:'',
|
|
|
+ }
|
|
|
+ }).done(function(data) {
|
|
|
+ this.setState({
|
|
|
+ loading: false
|
|
|
+ });
|
|
|
+ if(!data.error.length) {
|
|
|
+ message.success('保存成功!');
|
|
|
+ this.handleOk()
|
|
|
+ } else {
|
|
|
+ message.warning(data.error[0].message);
|
|
|
+ }
|
|
|
+ }.bind(this));
|
|
|
},
|
|
|
//订单详情修改
|
|
|
xiangqingClick(e) {
|
|
@@ -593,7 +540,6 @@ const NewService = Form.create()(React.createClass({
|
|
|
|
|
|
//删除收款节点
|
|
|
confirmDelet(index) {
|
|
|
- console.log(index);
|
|
|
this.state.contactList.splice(index,1);
|
|
|
this.setState({
|
|
|
contactList: this.state.contactList
|
|
@@ -615,20 +561,12 @@ const NewService = Form.create()(React.createClass({
|
|
|
//点击签单
|
|
|
handleCancels(e) {
|
|
|
this.setState({
|
|
|
- //visible: false,
|
|
|
- });
|
|
|
- this.props.closeDesc(false);
|
|
|
- this.setState({
|
|
|
isSubmit:1
|
|
|
})
|
|
|
},
|
|
|
//点击签单
|
|
|
handleCancelq(e) {
|
|
|
this.setState({
|
|
|
- //visible: false,
|
|
|
- });
|
|
|
- this.props.closeDesc(false);
|
|
|
- this.setState({
|
|
|
isSubmit:0
|
|
|
})
|
|
|
},
|
|
@@ -1590,19 +1528,15 @@ const NewService = Form.create()(React.createClass({
|
|
|
}
|
|
|
</Select>
|
|
|
</FormItem>
|
|
|
- <FormItem className="half-item"
|
|
|
- {...formItemLayout}
|
|
|
- label="合同签订时间" >
|
|
|
- <DatePicker
|
|
|
- style={{marginTop:"2px",width: '240px',height:"32px" }}
|
|
|
- showTime
|
|
|
- format="YYYY-MM-DD"
|
|
|
- placeholder="合同签订时间"
|
|
|
- value={this.state.signDate}
|
|
|
- onChange={(e,time)=>{this.selTime(e,time)}}
|
|
|
- />
|
|
|
- <span className="mandatory">*</span>
|
|
|
- </FormItem>
|
|
|
+ <FormItem className="half-item" {...formItemLayout} label="合同签订时间">
|
|
|
+ <DatePicker
|
|
|
+ style={{marginTop:"2px",width: '240px',height:"32px" }}
|
|
|
+ showTime
|
|
|
+ format="YYYY-MM-DD"
|
|
|
+ onOk={(e)=>{}}
|
|
|
+ value={this.state.signDate ? moment(this.state.signDate) : null}
|
|
|
+ onChange={(data, dataString) => { this.setState({ signDate: dataString }); }} />
|
|
|
+ </FormItem>
|
|
|
<div className='clearfix'>
|
|
|
<FormItem
|
|
|
labelCol={{ span: 4 }}
|
|
@@ -1821,265 +1755,9 @@ const NewService = Form.create()(React.createClass({
|
|
|
</Spin>
|
|
|
</Form >
|
|
|
</Modal>
|
|
|
- <Modal maskClosable={false} visible={this.state.signBillVisible}
|
|
|
- onOk={this.signBillOk} onCancel={this.signBillOk}
|
|
|
- width='800px'
|
|
|
- title='签单信息'
|
|
|
- footer=''
|
|
|
- className="admin-desc-content">
|
|
|
- <Form layout="horizontal" onSubmit={this.signOk} id="demand-form">
|
|
|
- <Spin spinning={this.state.loading}>
|
|
|
- <div className="clearfix">
|
|
|
- <FormItem className="half-item"
|
|
|
- {...formItemLayout}
|
|
|
- label="订单编号" >
|
|
|
- <span>{this.state.orderNo}</span>
|
|
|
- </FormItem>
|
|
|
- <FormItem className="half-item"
|
|
|
- {...formItemLayout}
|
|
|
- label="客户名称" >
|
|
|
- <span>{this.state.buyerName}</span>
|
|
|
- </FormItem>
|
|
|
- <FormItem className="half-item"
|
|
|
- {...formItemLayout}
|
|
|
- label="实签款项(万元)" >
|
|
|
- <Input placeholder="请输入实签款项" value={this.state.signTotalAmount} style={{width:'200px'}}
|
|
|
- onChange={(e)=>{this.setState({signTotalAmount:e.target.value})}} />
|
|
|
- <span className="mandatory">*</span>
|
|
|
- </FormItem>
|
|
|
- <FormItem className="half-item"
|
|
|
- {...formItemLayout}
|
|
|
- label="实签首款(万元)" >
|
|
|
- <Input placeholder="请输入实签首款" value={this.state.signFirstPayment} style={{width:'200px'}}
|
|
|
- onChange={(e)=>{this.setState({signFirstPayment:e.target.value})}} />
|
|
|
- <span className="mandatory">*</span>
|
|
|
- </FormItem>
|
|
|
- <FormItem className="half-item"
|
|
|
- {...formItemLayout}
|
|
|
- label="特批立项" >
|
|
|
- <Select placeholder="选择特批立项类型"
|
|
|
- style={{ width:'200px'}}
|
|
|
- value={this.state.approval}
|
|
|
- onChange={(e) => { this.setState({ approval: e }) }}>
|
|
|
- <Select.Option value='0'>不申请特批</Select.Option>
|
|
|
- <Select.Option value='1'>申请特批</Select.Option>
|
|
|
- </Select>
|
|
|
- <span className="mandatory">*</span>
|
|
|
- </FormItem>
|
|
|
- <FormItem className="half-item"
|
|
|
- {...formItemLayout}
|
|
|
- label="合同编号" >
|
|
|
- <Input placeholder="请输入合同编号" value={this.state.contractNo}
|
|
|
- onChange={(e)=>{this.setState({contractNo:e.target.value})}} style={{width:'200px'}} />
|
|
|
- <span className="mandatory">*</span>
|
|
|
- </FormItem>
|
|
|
- <div className='clearfix'>
|
|
|
- <FormItem
|
|
|
- labelCol={{ span: 4 }}
|
|
|
- wrapperCol={{ span: 16 }}
|
|
|
- label="签单备注" >
|
|
|
- <Input type="textarea" placeholder="请输入签单备注" rows={4} value={this.state.orderRemarks}
|
|
|
- onChange={(e)=>{this.setState({orderRemarks:e.target.value})}}/>
|
|
|
- </FormItem>
|
|
|
- </div>
|
|
|
- <div className='clearfix'>
|
|
|
- <FormItem
|
|
|
- labelCol={{ span: 4 }}
|
|
|
- wrapperCol={{ span: 18 }}
|
|
|
- label="合同扫描件" >
|
|
|
- <PicturesWall
|
|
|
- listType="picture-card"
|
|
|
- fileList={this.getOrgCodeUrl}
|
|
|
- pictureUrl={this.state.orgCodeUrl} />
|
|
|
- <p>图片建议:要清晰。</p>
|
|
|
- </FormItem>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- <FormItem wrapperCol={{ span: 12, offset: 4 }} className="half-middle">
|
|
|
- <Button className="submitSave" type="primary" htmlType="submit">确定签单</Button>
|
|
|
- <Button className="submitSave" type="ghost" onClick={this.signBillOk}>返回</Button>
|
|
|
- </FormItem>
|
|
|
- </Spin>
|
|
|
- </Form >
|
|
|
- </Modal>
|
|
|
- <Modal maskClosable={false} visible={this.state.signVisible}
|
|
|
- onOk={this.signBittOk} onCancel={this.signBittOk}
|
|
|
- width='600px'
|
|
|
- title='签单信息'
|
|
|
- footer=''
|
|
|
- className="admin-desc-content">
|
|
|
- <Form layout="horizontal" onSubmit={this.signSub} id="demand-form">
|
|
|
- <Spin spinning={this.state.loading}>
|
|
|
- <div className="clearfix">
|
|
|
- <FormItem
|
|
|
- {...formItemLayout}
|
|
|
- label="特批立项" >
|
|
|
- <Select placeholder="选择特批立项类型"
|
|
|
- style={{ width:'200px'}}
|
|
|
- value={this.state.approval}
|
|
|
- onChange={(e) => { this.setState({ approval: e }) }}>
|
|
|
- <Select.Option value='0'>不申请特批</Select.Option>
|
|
|
- <Select.Option value='1'>申请特批</Select.Option>
|
|
|
- </Select>
|
|
|
- <span className="mandatory">*</span>
|
|
|
- </FormItem>
|
|
|
- </div>
|
|
|
- <div className="clearfix">
|
|
|
- <FormItem
|
|
|
- {...formItemLayout}
|
|
|
- label="签单时间" >
|
|
|
- <DatePicker
|
|
|
- style={{marginTop:"2px"}}
|
|
|
- showTime
|
|
|
- format="YYYY-MM-DD"
|
|
|
- placeholder="选择签单时间"
|
|
|
- value={this.state.entryTime}
|
|
|
- onChange={(e,time)=>{this.selTime(e,time)}}
|
|
|
- />
|
|
|
- <span className="mandatory">*</span>
|
|
|
- </FormItem>
|
|
|
- </div>
|
|
|
- <FormItem wrapperCol={{ span: 12, offset: 4 }} className="half-middle">
|
|
|
- <Button className="submitSave" type="primary" htmlType="submit">确定签单</Button>
|
|
|
- <Button className="submitSave" type="ghost" onClick={this.signBittOk}>返回</Button>
|
|
|
- </FormItem>
|
|
|
- </Spin>
|
|
|
- </Form >
|
|
|
- </Modal>
|
|
|
- <Modal maskClosable={false} visible={this.state.lookVisible}
|
|
|
- onOk={this.lookCancel} onCancel={this.lookCancel}
|
|
|
- width='1300px'
|
|
|
- title= '查看流水'
|
|
|
- footer=''
|
|
|
- className="admin-desc-content">
|
|
|
- <Form layout="horizontal" id="demand-form">
|
|
|
- <Spin spinning={this.state.loading}>
|
|
|
- <div className="clearfix">
|
|
|
- <Table columns={this.state.flowList}
|
|
|
- dataSource={this.state.lookflowList}
|
|
|
- pagination={false}
|
|
|
- />
|
|
|
- </div>
|
|
|
- </Spin>
|
|
|
- </Form >
|
|
|
- </Modal>
|
|
|
- <Modal maskClosable={false} visible={this.state.addChangeState}
|
|
|
- onOk={this.addChangeCancel} onCancel={this.addChangeCancel}
|
|
|
- width='800px'
|
|
|
- title= {this.state.stateAdd?'添加变更':'查看变更记录'}
|
|
|
- footer=''
|
|
|
- className="admin-desc-content">
|
|
|
- <Form layout="horizontal" id="demand-form">
|
|
|
- <Spin spinning={this.state.loading}>
|
|
|
- <div className="clearfix">
|
|
|
- {this.state.stateAdd?<div className="clearfix">
|
|
|
- <FormItem
|
|
|
- labelCol={{ span: 4 }}
|
|
|
- wrapperCol={{ span: 16 }}
|
|
|
- label="变更说明" >
|
|
|
- <Input type="textarea" placeholder="请输入变更说明" rows={4} value={this.state.changeRemarks}
|
|
|
- onChange={(e)=>{this.setState({changeRemarks:e.target.value})}}/>
|
|
|
- </FormItem>
|
|
|
- <div className="clearfix">
|
|
|
- <Button type="primary" onClick={this.subChangeState} style={{margin:"10px 50px 10px 128px"}}>保存</Button>
|
|
|
- <Button onClick={this.addChangeCancel}>取消</Button>
|
|
|
- </div>
|
|
|
- </div>:
|
|
|
- <div>
|
|
|
- {
|
|
|
- changeHtml.length?changeHtml.map(function(item,index){
|
|
|
- return (<div className="changeBorder" key={index}>
|
|
|
- <FormItem className="half-item"
|
|
|
- {...formItemLayout}
|
|
|
- label="变更发起人" >
|
|
|
- <span>{item.creater}</span>
|
|
|
- </FormItem>
|
|
|
- <FormItem className="half-item"
|
|
|
- {...formItemLayout}
|
|
|
- label="变更申请时间" >
|
|
|
- <span>{item.createTime}</span>
|
|
|
- </FormItem>
|
|
|
- <div className='clearfix'>
|
|
|
- <FormItem className="half-item"
|
|
|
- {...formItemLayout}
|
|
|
- label="变更状态" >
|
|
|
- <span>{getChangeState(item.changeStatus)}</span>
|
|
|
- </FormItem>
|
|
|
- <FormItem className="half-item"
|
|
|
- {...formItemLayout}
|
|
|
- label="变更操作" >
|
|
|
- <Button onClick={(e)=>{this.modifyChange(item)}}>修改</Button>
|
|
|
- {/*<Button type="danger" onClick={(e)=>{this.modifyDelete(item)}}>删除</Button>*/}
|
|
|
- </FormItem>
|
|
|
- </div>
|
|
|
- <div className='clearfix changeRemark'>
|
|
|
- <FormItem
|
|
|
- labelCol={{ span: 4 }}
|
|
|
- wrapperCol={{ span: 16 }}
|
|
|
- label="变更说明" >
|
|
|
- <p>{item.changeComment}</p>
|
|
|
- </FormItem>
|
|
|
- </div>
|
|
|
- </div>)
|
|
|
- },this):<p style={{textAlign:"center"}}>暂无变更记录</p>}
|
|
|
- </div>
|
|
|
- }
|
|
|
- </div>
|
|
|
- </Spin>
|
|
|
- </Form >
|
|
|
- </Modal>
|
|
|
- <Modal maskClosable={false} visible={this.state.modifyChangeState}
|
|
|
- onOk={this.modifyChangeCancel} onCancel={this.modifyChangeCancel}
|
|
|
- width='600px'
|
|
|
- title= "修改变更 "
|
|
|
- footer=''
|
|
|
- className="admin-desc-content">
|
|
|
- <Form layout="horizontal" id="demand-form">
|
|
|
- <Spin spinning={this.state.loading}>
|
|
|
- <div className="clearfix">
|
|
|
- <div className="clearfix">
|
|
|
- <FormItem className="half-item"
|
|
|
- {...formItemLayout}
|
|
|
- label="变更发起人" >
|
|
|
- <span>{this.state.changePromoter}</span>
|
|
|
- </FormItem>
|
|
|
- <FormItem className="half-item"
|
|
|
- {...formItemLayout}
|
|
|
- label="变更申请时间" >
|
|
|
- <span>{this.state.changeTime}</span>
|
|
|
- </FormItem>
|
|
|
- <div className='clearfix'>
|
|
|
- <FormItem
|
|
|
- labelCol={{ span: 4 }}
|
|
|
- wrapperCol={{ span: 16 }}
|
|
|
- label="变更状态" >
|
|
|
- <Radio.Group onChange={(e)=>{this.setState({changeState:e.target.value})}} value={this.state.changeState}>
|
|
|
- <Radio value={1}>变更中</Radio>
|
|
|
- <Radio value={2}>变更完成</Radio>
|
|
|
- </Radio.Group>
|
|
|
- </FormItem>
|
|
|
- </div>
|
|
|
- <div className='clearfix'>
|
|
|
- <FormItem
|
|
|
- labelCol={{ span: 4 }}
|
|
|
- wrapperCol={{ span: 16 }}
|
|
|
- label="变更说明" >
|
|
|
- <Input type="textarea" placeholder="请输入变更说明" rows={4} value={this.state.changeRemarks}
|
|
|
- onChange={(e)=>{this.setState({changeRemarks:e.target.value})}}/>
|
|
|
- </FormItem>
|
|
|
- </div>
|
|
|
- <div className="clearfix">
|
|
|
- <Button type="primary" onClick={this.changeModify} style={{margin:"10px 95px"}}>保存</Button>
|
|
|
- <Button onClick={this.modifyChangeCancel}>取消</Button>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- </Spin>
|
|
|
- </Form >
|
|
|
- </Modal>
|
|
|
</div>
|
|
|
)
|
|
|
}
|
|
|
}));
|
|
|
|
|
|
-export default NewService;
|
|
|
+export default Form.create()(NewService);
|