Browse Source

企业统一社会信用代码添加

dev01 2 years ago
parent
commit
d60707b1ba

+ 152 - 108
js/component/common/enterpriseNameChange/inforChange.jsx

@@ -1,15 +1,15 @@
-import React,{Component} from "react";
-import {AutoComplete, Button, Cascader, message, Modal, Popconfirm, Select, Spin, Table, Tag, Tooltip} from "antd";
-import { areaSelect,getProvince } from '@/NewDicProvinceList';
+import React, { Component } from "react";
+import { AutoComplete, Button, Cascader, Input, message, Modal, Popconfirm, Select, Spin, Table, Tag, Tooltip } from "antd";
+import { areaSelect, getProvince } from '@/NewDicProvinceList';
 import $ from "jquery/src/ajax";
 import TextArea from "antd/es/input/TextArea";
 
-class InforChange extends Component{
+class InforChange extends Component {
     constructor(props) {
         super(props);
-        this.state={
-            visible:false,
-            changeType:0,
+        this.state = {
+            visible: false,
+            changeType: 0,
             colunmn: [
                 {
                     title: "操作人名称",
@@ -20,14 +20,14 @@ class InforChange extends Component{
                     title: "客户名称",
                     dataIndex: "name",
                     key: "name",
-                    render:(text)=>{
+                    render: (text) => {
                         return (
                             <Tooltip title={text}>
                                 <div style={{
-                                    maxWidth:'150px',
-                                    overflow:'hidden',
+                                    maxWidth: '150px',
+                                    overflow: 'hidden',
                                     textOverflow: "ellipsis",
-                                    whiteSpace:'nowrap',
+                                    whiteSpace: 'nowrap',
                                 }}>{text}</div>
                             </Tooltip>
                         )
@@ -39,16 +39,16 @@ class InforChange extends Component{
                     key: "createTimes",
                 },
             ],
-            dataSource:[],
-            inputVisible:false,
-            inputValue:'',
+            dataSource: [],
+            inputVisible: false,
+            inputValue: '',
 
-            dataArrar:[],
-            cooperationProjects:[],
-
-            locationProvince:props.data.locationProvince,
-            businessScope:props.data.businessScope,
-            intendedProject:props.data.intendedProject
+            dataArrar: [],
+            cooperationProjects: [],
+            orgCode: props.data.orgCode,
+            locationProvince: props.data.locationProvince,
+            businessScope: props.data.businessScope,
+            intendedProject: props.data.intendedProject
         }
         this.onChange = this.onChange.bind(this);
         this.onCancel = this.onCancel.bind(this);
@@ -62,20 +62,20 @@ class InforChange extends Component{
         this.onSelect = this.onSelect.bind(this);
     }
 
-    onChange(type){
+    onChange(type) {
         this.setState({
-            visible:true,
-            changeType:type,
+            visible: true,
+            changeType: type,
         })
     }
 
-    onCancel(){
+    onCancel() {
         this.setState({
-            visible:false,
-            loading:false,
-            changeType:0,
+            visible: false,
+            loading: false,
+            changeType: 0,
 
-            dataArrar:[]
+            dataArrar: []
         })
     }
 
@@ -98,9 +98,9 @@ class InforChange extends Component{
                     }
                 } else {
                     this.setState({
-                        initialName:data.data[0] ? data.data[0].name : ''
+                        initialName: data.data[0] ? data.data[0].name : ''
                     })
-                    data.data.splice(0,1);
+                    data.data.splice(0, 1);
                     this.setState({
                         dataSource: data.data,
                     });
@@ -116,80 +116,92 @@ class InforChange extends Component{
 
     }
 
-    onOk(){
-        const {dataArrar} = this.state;
-        if(this.state.changeType=== 0 && dataArrar.length === 0){
+    onOk() {
+        const { dataArrar } = this.state;
+        if (this.state.changeType === 3 && !/^[A-Z0-9]{15}$|^[A-Z0-9]{17}$|^[A-Z0-9]{18}$|^[A-Z0-9]{20}$/.test(dataArrar)) {
+            message.warning('请输入正确的统一社会信用代码')
+            return
+        }
+        if (this.state.changeType === 0 && dataArrar.length === 0) {
             message.warning('请输入省-市-区');
             return;
         }
-        if(this.state.changeType=== 1 && dataArrar.length === 0){
+        if (this.state.changeType === 1 && dataArrar.length === 0) {
             message.warning('请输入企业主管产品/服务');
             return;
         }
-        if(this.state.changeType=== 2 && dataArrar.length === 0){
+        if (this.state.changeType === 2 && dataArrar.length === 0) {
             message.warning('请输入意向合作项目');
             return;
         }
         this.setState({
             loading: true
         });
-        let data ={
-            uid:this.props.enterpriseId,
+        let data = {
+            uid: this.props.enterpriseId,
         }
-        if(this.state.changeType=== 0){
+        if (this.state.changeType === 0) {
             data.province = dataArrar[0] || undefined;
             data.city = dataArrar[1] || undefined;
             data.area = dataArrar[2] || undefined;
         }
-        if(this.state.changeType=== 1){
+        if (this.state.changeType === 1) {
             data.businessScope = dataArrar.join(',')
         }
-        if(this.state.changeType=== 2){
+        if (this.state.changeType === 2) {
             let arr = [];
-            for(let i of dataArrar){
+            for (let i of dataArrar) {
                 arr.push(i.label)
             }
             data.intendedProject = arr.join(',')
         }
+        if (this.state.changeType === 3) {
+            data.orgCode = dataArrar
+        }
         $.ajax({
             url: globalConfig.context + "/api/admin/customer/updateUserDate",
             method: "post",
             data: data
         }).done(
-            function(data) {
+            function (data) {
                 this.setState({
                     loading: false
                 });
                 if (data.error.length === 0) {
                     message.success("恭喜您,更改成功!");
-                    if(this.state.changeType=== 0){
+                    if (this.state.changeType === 0) {
                         this.setState({
-                            locationProvince:getProvince(dataArrar[0],dataArrar[1],dataArrar[2])
+                            locationProvince: getProvince(dataArrar[0], dataArrar[1], dataArrar[2])
                         })
                     }
-                    if(this.state.changeType=== 1){
+                    if (this.state.changeType === 1) {
                         this.setState({
-                            businessScope:dataArrar.join(',')
+                            businessScope: dataArrar.join(',')
                         })
                     }
-                    if(this.state.changeType=== 2){
+                    if (this.state.changeType === 2) {
                         let arr = [];
-                        for(let i of dataArrar){
+                        for (let i of dataArrar) {
                             arr.push(i.label)
                         }
                         this.setState({
-                            intendedProject:arr.join(',')
+                            intendedProject: arr.join(',')
+                        })
+                    }
+                    if (this.state.changeType === 3) {
+                        this.setState({
+                            orgCode: dataArrar
                         })
                     }
                     this.onCancel();
-                }else{
+                } else {
                     message.warning(data.error[0].message);
                 }
             }.bind(this)
         )
     }
 
-    showInput(){
+    showInput() {
         let str = this.state.dataArrar.join('/')
         this.setState({
             inputVisible: true,
@@ -197,35 +209,35 @@ class InforChange extends Component{
         });
     }
 
-    handleInputConfirm(){
+    handleInputConfirm() {
         let inputValue = this.state.inputValue;
         let arr = inputValue.split('/');
         let lv = true;
-        for(let i of arr){
-            if(i.length > 16){
+        for (let i of arr) {
+            if (i.length > 16) {
                 message.warning('单个标签字数不能超过16个字符')
                 lv = false;
                 return;
             }
         }
-        if(lv){
+        if (lv) {
             arr = Array.from(new Set(arr));
-            arr = arr.filter(v=>v);
+            arr = arr.filter(v => v);
             this.setState({
-                dataArrar:arr,
+                dataArrar: arr,
                 inputVisible: false,
                 inputValue: '',
             });
         }
     }
 
-    handleClose(removedTag){
-        let dataArrar = this.state.dataArrar.filter(tag => {return tag !== removedTag});
+    handleClose(removedTag) {
+        let dataArrar = this.state.dataArrar.filter(tag => { return tag !== removedTag });
         this.setState({ dataArrar });
     }
 
-    handleCloseCooperation(removedTag){
-        let dataArrar = this.state.dataArrar.filter(tag => {return tag.value !== removedTag.value});
+    handleCloseCooperation(removedTag) {
+        let dataArrar = this.state.dataArrar.filter(tag => { return tag.value !== removedTag.value });
         this.setState({ dataArrar });
     }
 
@@ -244,7 +256,7 @@ class InforChange extends Component{
                     this.setState({
                         cooperationProjects: thedata,
                     });
-                }else{
+                } else {
                     message.warning(data.error[0].message);
                 }
             }.bind(this),
@@ -255,19 +267,19 @@ class InforChange extends Component{
         );
     }
 
-    onSelect(value){
-        let arr = this.state.cooperationProjects.filter(v=>v.id === value);
-        let arr1 = this.state.dataArrar.filter(v=>v.value === value);
-        if(arr.length > 0){
-            if(arr1.length > 0){
+    onSelect(value) {
+        let arr = this.state.cooperationProjects.filter(v => v.id === value);
+        let arr1 = this.state.dataArrar.filter(v => v.value === value);
+        if (arr.length > 0) {
+            if (arr1.length > 0) {
                 message.warning('选项已存在');
-            }else{
+            } else {
                 this.state.dataArrar.push({
                     label: arr[0].bname,
                     value: arr[0].id,
                 })
                 this.setState({
-                    dataArrar:this.state.dataArrar
+                    dataArrar: this.state.dataArrar
                 })
             }
         }
@@ -281,50 +293,64 @@ class InforChange extends Component{
                 marginTop: 20,
             }}>
                 <div style={{
-                    display:'flex',
-                    alignItems:'center',
-                    paddingBottom:'5px'
+                    display: 'flex',
+                    alignItems: 'center',
+                    paddingBottom: '5px'
                 }}>
-                    <div style={{width:'123px'}}>省-市-区:</div>
+                    <div style={{ width: '123px', color: "#58A3FF" }}>统一社会信用代码:</div>
+                    <div style={{ color: "#58A3FF" }}>
+                        {
+                            !this.state.orgCode ? "待补充" : this.state.orgCode
+                        }
+                    </div>
+                    {this.props.type === 'modify' && <Button style={{ marginLeft: '5px' }} type="primary" onClick={(e) => { e.stopPropagation(); this.onChange(3) }}>修改</Button>}
+                    {this.props.type === 'modify' && <span style={{ color: "red", marginLeft: 20 }}>如,科德集团则填写91430105670766451M</span>}
+                </div>
+                <div style={{
+                    display: 'flex',
+                    alignItems: 'center',
+                    paddingBottom: '5px'
+                }}>
+                    <div style={{ width: '123px' }}>省-市-区:</div>
                     <div>
                         {
                             this.state.locationProvince
                         }
                     </div>
-                    {this.props.type === 'modify' && <Button style={{marginLeft:'5px'}} type="primary" onClick={(e)=>{e.stopPropagation();this.onChange(0)}}>修改</Button>}
+                    {this.props.type === 'modify' && <Button style={{ marginLeft: '5px' }} type="primary" onClick={(e) => { e.stopPropagation(); this.onChange(0) }}>修改</Button>}
                 </div>
                 <div style={{
-                    display:'flex',
-                    alignItems:'center',
-                    paddingBottom:'5px'
+                    display: 'flex',
+                    alignItems: 'center',
+                    paddingBottom: '5px'
                 }}>
-                    <div style={{width:'123px'}}>企业主营产品/服务:</div>
+                    <div style={{ width: '123px' }}>企业主营产品/服务:</div>
                     <div>
                         {
                             this.state.businessScope
                         }
                     </div>
-                    {this.props.type === 'modify' && <Button style={{marginLeft:'5px'}} type="primary" onClick={(e)=>{e.stopPropagation();this.onChange(1)}}>修改</Button>}
+                    {this.props.type === 'modify' && <Button style={{ marginLeft: '5px' }} type="primary" onClick={(e) => { e.stopPropagation(); this.onChange(1) }}>修改</Button>}
                 </div>
                 <div style={{
-                    display:'flex',
-                    alignItems:'center',
-                    paddingBottom:'5px'
+                    display: 'flex',
+                    alignItems: 'center',
+                    paddingBottom: '5px'
                 }}>
-                    <div style={{width:'123px'}}>意向合作项目:</div>
+                    <div style={{ width: '123px' }}>意向合作项目:</div>
                     <div>
                         {
                             this.state.intendedProject
                         }
                     </div>
-                    {this.props.type === 'modify' && <Button style={{marginLeft:'5px'}} type="primary" onClick={(e)=>{e.stopPropagation();this.onChange(2)}}>修改</Button>}
+                    {this.props.type === 'modify' && <Button style={{ marginLeft: '5px' }} type="primary" onClick={(e) => { e.stopPropagation(); this.onChange(2) }}>修改</Button>}
                 </div>
 
                 <Modal
                     footer={null}
                     maskClosable={false}
-                    width={this.props.type === 'journal' ? '1200px': this.props.type === 'modify' ? (this.state.changeType === 0 ? '300px' : '800px'): ''}
-                    title={this.props.type === 'journal' ? '操作日志': this.props.type === 'modify' ? '信息修改': ''}
+                    width={this.props.type === 'journal' ? '1200px' : this.props.type === 'modify' ? '400px' : '800px'}
+                    title={this.props.type === 'journal' ? '操作日志' : this.props.type === 'modify' ? '信息修改' : ''}
                     visible={this.state.visible}
                     onCancel={this.onCancel}>
                     <div>
@@ -335,7 +361,8 @@ class InforChange extends Component{
                                         {
                                             this.state.changeType === 0 ? '省-市-区' :
                                                 this.state.changeType === 1 ? '企业主管产品/服务' :
-                                                    this.state.changeType === 2 ? '意向合作项目' : ''
+                                                    this.state.changeType === 2 ? '意向合作项目' :
+                                                        this.state.changeType === 3 ? '统一社会信用代码' : ''
                                         }
                                         :
                                     </div>
@@ -343,7 +370,8 @@ class InforChange extends Component{
                                         {
                                             this.state.changeType === 0 ? this.state.locationProvince :
                                                 this.state.changeType === 1 ? this.state.businessScope :
-                                                    this.state.changeType === 2 ? this.state.intendedProject : ''
+                                                    this.state.changeType === 2 ? this.state.intendedProject :
+                                                        this.state.changeType === 3 ? this.state.orgCode : ''
                                         }
                                     </div>
                                 </div>
@@ -352,14 +380,14 @@ class InforChange extends Component{
                                     <div className='enterpriseNameValue'>
                                         {
                                             this.state.changeType === 0 ? <Cascader
-                                                    options={areaSelect()}
-                                                    placeholder="选择城市"
-                                                    onChange={(e, pre) => {
-                                                        this.setState({
-                                                            dataArrar:e
-                                                        })
-                                                    }}
-                                                /> :
+                                                options={areaSelect()}
+                                                placeholder="选择城市"
+                                                onChange={(e, pre) => {
+                                                    this.setState({
+                                                        dataArrar: e
+                                                    })
+                                                }}
+                                            /> :
                                                 this.state.changeType === 1 ?
                                                     <div>
                                                         <div>
@@ -384,14 +412,14 @@ class InforChange extends Component{
                                                         </div>
                                                         {this.state.inputVisible && (<div>
                                                             <TextArea
-                                                                style={{width:'300px',height:'100px'}}
+                                                                style={{ width: '300px', height: '100px' }}
                                                                 value={this.state.inputValue}
-                                                                onChange={(e)=>{
+                                                                onChange={(e) => {
                                                                     this.setState({
                                                                         inputValue: e.target.value
                                                                     })
-                                                                }}/>
-                                                            <div style={{color:'#f00'}}>提示:请用 / 符号隔开关键字</div>
+                                                                }} />
+                                                            <div style={{ color: '#f00' }}>提示:请用 / 符号隔开关键字</div>
                                                             <div>
                                                                 <Button
                                                                     size="small"
@@ -401,8 +429,8 @@ class InforChange extends Component{
                                                                 </Button>
                                                                 <Button
                                                                     size="small"
-                                                                    style={{marginLeft:'5px'}}
-                                                                    onClick={()=>{
+                                                                    style={{ marginLeft: '5px' }}
+                                                                    onClick={() => {
                                                                         this.setState({
                                                                             inputVisible: false,
                                                                             inputValue: ''
@@ -416,7 +444,7 @@ class InforChange extends Component{
                                                     :
                                                     this.state.changeType === 2 ?
                                                         <div>
-                                                            <div style={{paddingBottom: this.state.dataArrar.length === 0 ? 0 : '10px'}}>
+                                                            <div style={{ paddingBottom: this.state.dataArrar.length === 0 ? 0 : '10px' }}>
                                                                 {this.state.dataArrar.map((tag, index) => {
                                                                     const isLongTag = tag.label.length > 20;
                                                                     const tagElem = (
@@ -436,13 +464,29 @@ class InforChange extends Component{
                                                                 >
                                                                     {
                                                                         this.state.cooperationProjects.map(function (item) {
-                                                                            return  <Select.Option key={item.id} value={item.id}>{item.bname}</Select.Option>
+                                                                            return <Select.Option key={item.id} value={item.id}>{item.bname}</Select.Option>
                                                                         })
                                                                     }
                                                                 </AutoComplete>
                                                             </div>
                                                         </div>
-                                                        : ''
+                                                        :
+                                                        this.state.changeType === 3 ?
+                                                            <div>
+                                                                <div>
+                                                                    <Input
+                                                                        style={{ width: 200 }}
+                                                                        placeholder="请输入统一社会信用代码"
+                                                                        onChange={(e) => {
+                                                                            this.setState({
+                                                                                dataArrar: e.target.value
+                                                                            })
+                                                                        }}
+                                                                    />
+                                                                </div>
+                                                                <div style={{ color: "red", position: "absolute" }}>如,科德集团则填写91430105670766451M</div>
+                                                            </div>
+                                                            : ''
                                         }
                                     </div>
                                 </div>
@@ -462,7 +506,7 @@ class InforChange extends Component{
                         }
                         {
                             this.props.type === 'modify' ?
-                                <Popconfirm placement="top" title="确定要修改吗?" onConfirm={(e)=>{
+                                <Popconfirm placement="top" title="确定要修改吗?" onConfirm={(e) => {
                                     e.stopPropagation();
                                     this.onOk();
                                 }} okText="确定" cancelText="取消">
@@ -472,8 +516,8 @@ class InforChange extends Component{
                                 </Popconfirm> : null
                         }
                     </div>
-                </Modal>
-            </div>
+                </Modal >
+            </div >
         )
     }
 }

+ 15 - 9
js/component/common/projectOperation/newAddProject.jsx

@@ -1214,16 +1214,22 @@ class NewAddProject extends Component {
                     !this.state.addFrom &&
                     this.state.splitList.length < this.state.yearSum &&
                     <div className="clearfix">
-                      <Button
-                        type="primary"
-                        onClick={() => {
-                          this.setState({
-                            addFrom: true
-                          })
-                        }}
+                      <FormItem
+                        wrapperCol={{ span: 19, offset: 8 }}
+                        className="half-middle"
                       >
-                        + 本次派单
-                      </Button>
+                        <Button
+                          type="primary"
+                          onClick={() => {
+                            this.setState({
+                              addFrom: true
+                            })
+                          }}
+                        >
+                          + 添加本次派单
+                        </Button>
+                        <span style={{ color: "#61BBE2", marginLeft: 10 }}>请填写本次派单的年份,派单表示立即安排人员开始相关的工作!!!</span>
+                      </FormItem>
                     </div>
                   }
                   {

+ 17 - 12
js/component/common/projectOperation/newEditProject.jsx

@@ -1062,19 +1062,18 @@ class newEditProject extends Component {
                 isMedit == 0 && isVip == 6 &&
                 <div className="clearfix">
                   <FormItem
-                    wrapperCol={{ span: 12, offset: 10 }}
+                    wrapperCol={{ span: 12, offset: 8 }}
                     className="half-middle"
                   >
                     <Button
                       className="submitSave"
-                      type="primary"
                       onClick={() => {
                         this.setState({
                           isMedit: 1
                         })
                       }}
                     >
-                      我要编辑
+                      重新编辑项目任务
                     </Button>
                   </FormItem>
                 </div>
@@ -1222,16 +1221,22 @@ class newEditProject extends Component {
                     // this.state.splitList.length < this.state.yearSum &&
                     this.state.splitList.filter((item) => { return item.type != 3 }).length < this.state.yearSum &&
                     <div className="clearfix">
-                      <Button
-                        type="primary"
-                        onClick={() => {
-                          this.setState({
-                            addFrom: true,
-                          })
-                        }}
+                      <FormItem
+                        wrapperCol={{ span: 19, offset: 8 }}
+                        className="half-middle"
                       >
-                        + 本次派单
-                      </Button>
+                        <Button
+                          type="primary"
+                          onClick={() => {
+                            this.setState({
+                              addFrom: true,
+                            })
+                          }}
+                        >
+                          + 添加本次派单
+                        </Button>
+                        <span style={{ color: "#61BBE2", marginLeft: 10 }}>请填写本次派单的年份,派单表示立即安排人员开始相关的工作!!!</span>
+                      </FormItem>
                     </div>
                   }
                   {

+ 20 - 1
js/component/manageCenter/customer/NEW/intentionCustomer/addIntention.jsx

@@ -45,6 +45,10 @@ const AchievementDetailForm = Form.create()(React.createClass({
                 message.warning('公司名称不能存在特殊符号或空格!')
                 return false;
             }
+            if (!/^[A-Z0-9]{15}$|^[A-Z0-9]{17}$|^[A-Z0-9]{18}$|^[A-Z0-9]{20}$/.test(values.orgCode)) {
+                message.warning('请输入正确的统一社会信用代码!')
+                return
+            }
             if (/.*[\u4e00-\u9fa5]+.*$/.test(values.content)) {
             } else {
                 message.error("请填写正确的联系人,且至少包含一个汉字");
@@ -90,6 +94,7 @@ const AchievementDetailForm = Form.create()(React.createClass({
                     url: globalConfig.context + '/api/admin/customer/addCustomer',
                     data: {
                         name: values.name,
+                        orgCode: values.orgCode,
                         contacts: values.content,
                         contactMobile: values.telnum,
                         societyTag: '0',                       //社会属性默认为 社会企业
@@ -172,7 +177,7 @@ const AchievementDetailForm = Form.create()(React.createClass({
             if (!i.replace(/\s+/g, '')) {
                 message.warning("请填写关键词且不为空");
                 return;
-              }
+            }
             if (i.length > 16) {
                 message.warning('单个标签字数不能超过16个字符')
                 lv = false;
@@ -336,6 +341,20 @@ const AchievementDetailForm = Form.create()(React.createClass({
                             <div className="clearfix">
                                 <FormItem
                                     {...formItemLayout}
+                                    label="统一社会信用代码"
+                                >
+                                    {getFieldDecorator('orgCode', {
+                                        rules: [{ required: true, message: '此项为必填项!' }],
+                                        initialValue: this.state.orgCode
+                                    })(
+                                        <Input placeholder="统一社会信用代码" />
+                                    )}
+                                </FormItem>
+                            </div>
+                            <Col style={{ color: 'red', marginBottom: '10px' }} span={12} offset={6}>如,科德集团则填写91430105670766451M</Col>
+                            <div className="clearfix">
+                                <FormItem
+                                    {...formItemLayout}
                                     label="省-市-区"
                                 >
                                     {getFieldDecorator('ProvinceCity', {

+ 33 - 7
js/component/manageCenter/customer/NEW/intentionCustomer/intentionCustomer.jsx

@@ -24,13 +24,14 @@ import { industry, lvl, currentMember } from "@/dataDic.js";
 import ZhuanjiaoDetail from "@/zhuanjiaoDetail.jsx";
 import { getSocialAttribute, ShowModal } from "@/tools.js";
 import FollowDetail from "./followDetail.jsx";
-import IntentionDetail from "./intentionDetail/intentionDetail.jsx";
+import IntentionDetail from "./intentionDetail/intentionDetail";
 import ShowModalDiv from "@/showModal.jsx";
 import "./customer.less";
 import { ChooseList } from "../../../order/orderNew/chooseList";
 import EnterpriseNameChange from "../../../../common/enterpriseNameChange";
 
 const { TabPane } = Tabs;
+const confirm = Modal.confirm;
 const IntentionCustomer = Form.create()(
   React.createClass({
     loadData(pageNo, apiUrl) {
@@ -214,6 +215,16 @@ const IntentionCustomer = Form.create()(
             },
           },
           {
+            title: "统一社会信用代码",
+            dataIndex: "orgCode",
+            key: "orgCode",
+            render: (text) => {
+              return <div style={{ color: !text ? "red" : "#000000A6" }}>
+                {!text ? "待补充" : text}
+              </div>;
+            },
+          },
+          {
             title: "地区",
             dataIndex: "locationProvince",
             key: "locationProvince",
@@ -287,7 +298,22 @@ const IntentionCustomer = Form.create()(
                 >
                   <Button
                     onClick={(e) => {
-                      e.stopPropagation(), this.visit(record);
+                      const _this = this
+                      e.stopPropagation()
+                      if (!record.orgCode) {
+                        confirm({
+                          title: '您暂时不可以跟进客户',
+                          content: `请先完善"企业统一社会信用代码"`,
+                          cancelText: '取消',
+                          okText: '去完善',
+                          onOk() {
+                            _this.tableRowClick(record)
+                          },
+                          onCancel() { },
+                        });
+                      } else {
+                        this.visit(record);
+                      }
                     }}
                     type="primary"
                   >
@@ -316,9 +342,9 @@ const IntentionCustomer = Form.create()(
                       style={
                         text === 1
                           ? {
-                              background: "#F00000",
-                              borderColor: "#F00000",
-                            }
+                            background: "#F00000",
+                            borderColor: "#F00000",
+                          }
                           : {}
                       }
                       onClick={(e) => {
@@ -743,7 +769,7 @@ const IntentionCustomer = Form.create()(
             informationTransferVisible: true,
           });
         },
-        onCancel() {},
+        onCancel() { },
       });
     },
     changeList(arr) {
@@ -775,7 +801,7 @@ const IntentionCustomer = Form.create()(
         onOk() {
           fn(record);
         },
-        onCancel() {},
+        onCancel() { },
       });
     },
     release() {

+ 6 - 1
js/component/manageCenter/customer/NEW/intentionCustomer/intentionDetail/detail/visit.jsx

@@ -425,9 +425,14 @@ const Visit = React.createClass({
 		return (
 			<div className="clearfix">
 				<Alert message="注:面谈公出补充,沟通完后记录今天交流的情况。计划下一次什么时候再面谈?该如何面谈?该如何跟进?" banner />
-				{!this.props.isGuidanceLv ? <Button
+				{!this.props.isGuidanceLv ? 
+				<Button
 					onClick={(e) => {
 						e.stopPropagation();
+						if (!this.props.data.orgCode) {
+							message.warning(`请先完善"企业统一社会信用代码"`)
+							return
+						}
 						this.visit();
 					}}
 					type="primary"

+ 1 - 1
js/component/manageCenter/customer/NEW/intentionCustomer/intentionDetail/intentionDetail.jsx

@@ -133,7 +133,7 @@ const IntentionDetail = React.createClass({
 								/>
 
 							</TabPane>}
-						{!this.props.isGuidanceLv || this.props.isCustomerAdmin ? <TabPane tab="联系人信息" key="2">
+						{!this.props.isGuidanceLv || this.props.isCustomerAdmin ? <TabPane tab="企业&联系人详情" key="2">
 							<ContactPerson
 								isCustomerAdmin={this.props.isCustomerAdmin}
 								closeDetail={this.closeDetail}

+ 7 - 1
js/component/manageCenter/customer/NEW/query/queryCutomer.jsx

@@ -170,6 +170,11 @@ const QueryCustomer = React.createClass({
           }
         },
         {
+          title: "统一社会信用代码",
+          dataIndex: "orgCode",
+          key: "orgCode",
+        },
+        {
           title: "共享类型",
           dataIndex: "shareType",
           key: "shareType",
@@ -462,7 +467,8 @@ const QueryCustomer = React.createClass({
           <TabPane tab="搜索" key="1">
             <div className="user-search">
               <Input
-                placeholder="请输入精确客户全称"
+                style={{ width: 240 }}
+                placeholder="请输入精确客户全称或统一社会信用代码"
                 value={this.state.nameSearch}
                 onChange={(e) => {
                   this.setState({ nameSearch: e.target.value });

+ 290 - 285
js/component/manageCenter/customer/NEW/signCustomer/intentionDetail/detail/visit.jsx

@@ -1,250 +1,250 @@
 import React from 'react';
-import {Form, Button, Spin, message, Table, Popconfirm, Tooltip, Alert} from 'antd';
+import { Form, Button, Spin, message, Table, Popconfirm, Tooltip, Alert } from 'antd';
 import ajax from 'jquery/src/ajax/xhr.js';
 import $ from 'jquery/src/ajax';
 import FollowDetail from '../../followDetail.jsx'
-import {getContactType} from '@/tools.js';
+import { getContactType } from '@/tools.js';
 import VisitDetail from './visitDetail.jsx';
 import PublicSupplement from "../../../../../../publicSupplement";
 
 const Visit = React.createClass({
-	getInitialState(){
+	getInitialState() {
 		return {
-      visitArrList: [],
-      loading: false,
-      visitModul: false,
-      visitModuls: false,
-      paginations: {
-        defaultCurrent: 1,
-        defaultPageSize: 10,
-        showQuickJumper: true,
-        pageSize: 10,
-        onChange: function (page) {
-          this.loadVisit(page);
-        }.bind(this),
-        showTotal: function (total) {
-          return "共" + total + "条数据";
-        },
-      },
-      visitsList: [
-        {
-          title: "客户名称",
-          dataIndex: "nickname",
-          key: "nickname",
-		  width: 150,
-		  render: (text) => {
-				return (
-					<Tooltip title={text}>
-						<div style={{
-							maxWidth:'150px',
-							overflow:'hidden',
-							textOverflow: "ellipsis",
-							whiteSpace:'nowrap',
-						}}>{text}</div>
-					</Tooltip>
-				)
-		  },
-        },
-        {
-          title: "跟进方式",
-          dataIndex: "contactType",
-          key: "contactType",
-		  width: 100,
-          render: (text) => {
-            return getContactType(text);
-          },
-        },
-        {
-          title: "联系人",
-          dataIndex: "contacts",
-          key: "contacts",
-		  width: 150,
-          render: (text, record) => {
-            return (
-              <div>
-                {record.readOnly ? <span>***</span> : <span>{text}</span>}
-              </div>
-            );
-          },
-        },
-        {
-          title: "联系电话",
-          dataIndex: "contactMobile",
-          key: "contactMobile",
-		  width: 120,
-          render: (text, record) => {
-            return (
-              <div>
-                {record.readOnly ? <span>***</span> : <span>{text}</span>}
-              </div>
-            );
-          },
-        },
-        {
-          title: "跟进人",
-          dataIndex: "adminName",
-          key: "adminName",
-		  width: 120
-        },
-      //   {
-      //     title: "跟进说明",
-      //     dataIndex: "result",
-      //     key: "result",
-		  // width: 300,
-			// render: (text, record) => {
-			// 	return (
-			// 		<div style={{wordBreak:"break-all"}}>
-			// 			<div>{text}</div>
-			// 			{
-			// 				getContactType(record.contactType) === '公出打卡' && <div style={{
-			// 					paddingTop: '15px',
-			// 					wordBreak: "break-all",
-			// 					display: "flex",
-			// 					alignItems: 'flex-end'
-			// 				}}>
-			// 					补充说明:
-			// 					{record.supplement}
-			// 					<div style={{paddingLeft: '10px'}}>
-			// 						<PublicSupplement infor={record} onCancel={() => {
-			// 							this.loadVisit(this.state.ispage);
-			// 						}}/>
-			// 					</div>
-			// 				</div>
-			// 			}
-			// 		</div>
-			// 	)
-			// }
-      //   },
+			visitArrList: [],
+			loading: false,
+			visitModul: false,
+			visitModuls: false,
+			paginations: {
+				defaultCurrent: 1,
+				defaultPageSize: 10,
+				showQuickJumper: true,
+				pageSize: 10,
+				onChange: function (page) {
+					this.loadVisit(page);
+				}.bind(this),
+				showTotal: function (total) {
+					return "共" + total + "条数据";
+				},
+			},
+			visitsList: [
+				{
+					title: "客户名称",
+					dataIndex: "nickname",
+					key: "nickname",
+					width: 150,
+					render: (text) => {
+						return (
+							<Tooltip title={text}>
+								<div style={{
+									maxWidth: '150px',
+									overflow: 'hidden',
+									textOverflow: "ellipsis",
+									whiteSpace: 'nowrap',
+								}}>{text}</div>
+							</Tooltip>
+						)
+					},
+				},
+				{
+					title: "跟进方式",
+					dataIndex: "contactType",
+					key: "contactType",
+					width: 100,
+					render: (text) => {
+						return getContactType(text);
+					},
+				},
+				{
+					title: "联系人",
+					dataIndex: "contacts",
+					key: "contacts",
+					width: 150,
+					render: (text, record) => {
+						return (
+							<div>
+								{record.readOnly ? <span>***</span> : <span>{text}</span>}
+							</div>
+						);
+					},
+				},
+				{
+					title: "联系电话",
+					dataIndex: "contactMobile",
+					key: "contactMobile",
+					width: 120,
+					render: (text, record) => {
+						return (
+							<div>
+								{record.readOnly ? <span>***</span> : <span>{text}</span>}
+							</div>
+						);
+					},
+				},
+				{
+					title: "跟进人",
+					dataIndex: "adminName",
+					key: "adminName",
+					width: 120
+				},
+				//   {
+				//     title: "跟进说明",
+				//     dataIndex: "result",
+				//     key: "result",
+				// width: 300,
+				// render: (text, record) => {
+				// 	return (
+				// 		<div style={{wordBreak:"break-all"}}>
+				// 			<div>{text}</div>
+				// 			{
+				// 				getContactType(record.contactType) === '公出打卡' && <div style={{
+				// 					paddingTop: '15px',
+				// 					wordBreak: "break-all",
+				// 					display: "flex",
+				// 					alignItems: 'flex-end'
+				// 				}}>
+				// 					补充说明:
+				// 					{record.supplement}
+				// 					<div style={{paddingLeft: '10px'}}>
+				// 						<PublicSupplement infor={record} onCancel={() => {
+				// 							this.loadVisit(this.state.ispage);
+				// 						}}/>
+				// 					</div>
+				// 				</div>
+				// 			}
+				// 		</div>
+				// 	)
+				// }
+				//   },
+				{
+					title: "跟进时间",
+					dataIndex: "followTime",
+					key: "followTime",
+					width: 125
+				},
 				{
-          title: "跟进时间",
-          dataIndex: "followTime",
-          key: "followTime",
-		  width: 125
-        },
+					title: "公出目标",
+					dataIndex: "result",
+					key: "result",
+					width: 200,
+					// render: (text, record) => {
+					// 	return (
+					// 		<div style={{wordBreak:"break-all"}}>
+					// 			<div>{text}</div>
+					// 			{
+					// 				getContactType(record.contactType) === '公出打卡' && <div style={{
+					// 					paddingTop: '15px',
+					// 					wordBreak: "break-all",
+					// 					display: "flex",
+					// 					alignItems: 'flex-end'
+					// 				}}>
+					// 					{/* 补充说明:
+					// 					{record.supplement} */}
+					// 					<div style={{paddingLeft: '10px'}}>
+					// 						<PublicSupplement infor={record} onCancel={() => {
+					// 							this.loadVisit(this.state.ispage);
+					// 						}}/>
+					// 					</div>
+					// 				</div>
+					// 			}
+					// 		</div>
+					// 	)
+					// }
+				},
 				{
-          title: "公出目标",
-          dataIndex: "result",
-          key: "result",
-		      width: 200,
-			// render: (text, record) => {
-			// 	return (
-			// 		<div style={{wordBreak:"break-all"}}>
-			// 			<div>{text}</div>
-			// 			{
-			// 				getContactType(record.contactType) === '公出打卡' && <div style={{
-			// 					paddingTop: '15px',
-			// 					wordBreak: "break-all",
-			// 					display: "flex",
-			// 					alignItems: 'flex-end'
-			// 				}}>
-			// 					{/* 补充说明:
-			// 					{record.supplement} */}
-			// 					<div style={{paddingLeft: '10px'}}>
-			// 						<PublicSupplement infor={record} onCancel={() => {
-			// 							this.loadVisit(this.state.ispage);
-			// 						}}/>
-			// 					</div>
-			// 				</div>
-			// 			}
-			// 		</div>
-			// 	)
-			// }
-        },
-        {
-          title: "公出计划",
-          dataIndex: "plan",
-          key: "plan",
-          width: 200,
-          render: (text) => {
-            return (
-              <div
-                // style={{
-                //   width: 50,
-                //   overflow: "hidden",
-                //   textOverflow: "ellipsis",
-                //   whiteSpace: "nowrap",
-                // }}
-                // title={text}
-              >
-                {text}
-              </div>
-            );
-          },
-        },
-        {
-          title: "预计效果",
-          dataIndex: "expectedEffect",
-          key: "expectedEffect",
-          width: 200,
-          render: (text) => {
-            return (
-              <div
-                // style={{
-                //   width: 50,
-                //   overflow: "hidden",
-                //   textOverflow: "ellipsis",
-                //   whiteSpace: "nowrap",
-                // }}
-                // title={text}
-              >
-                {text}
-              </div>
-            );
-          },
-        },
-        {
-          title: "本次公出目标总结",
-          dataIndex: "supplement",
-          key: "supplement",
-          width: 200,
-          render: (text,record) => {
-            return (
-              <div style={{wordBreak:"break-all"}}>
-              {
-                getContactType(record.contactType) === '公出打卡' && <div style={{
-                  // paddingTop: '15px',
-                  wordBreak: "break-all",
-                }}>  
-                {text}
-                  <div>
-                    <PublicSupplement closeModel={this.closeModel} infor={record} onCancel={() => {
-                      this.loadVisit(this.state.ispage);
-                    }}/>
-                  </div>
-                </div>
-              }
-            </div>
-            );
-          },
-        },
-        {
-          title: "下一次公出计划",
-          dataIndex: "nextPlan",
-          key: "nextPlan",
-          width: 200,
-          render: (text) => {
-            return (
-              <div
-                // style={{
-                //   width: 70,
-                //   overflow: "hidden",
-                //   textOverflow: "ellipsis",
-                //   whiteSpace: "nowrap",
-                // }}
-                // title={text}
-              >
-                {text}
-              </div>
-            );
-          },
-        },
-      ],
-    };
+					title: "公出计划",
+					dataIndex: "plan",
+					key: "plan",
+					width: 200,
+					render: (text) => {
+						return (
+							<div
+							// style={{
+							//   width: 50,
+							//   overflow: "hidden",
+							//   textOverflow: "ellipsis",
+							//   whiteSpace: "nowrap",
+							// }}
+							// title={text}
+							>
+								{text}
+							</div>
+						);
+					},
+				},
+				{
+					title: "预计效果",
+					dataIndex: "expectedEffect",
+					key: "expectedEffect",
+					width: 200,
+					render: (text) => {
+						return (
+							<div
+							// style={{
+							//   width: 50,
+							//   overflow: "hidden",
+							//   textOverflow: "ellipsis",
+							//   whiteSpace: "nowrap",
+							// }}
+							// title={text}
+							>
+								{text}
+							</div>
+						);
+					},
+				},
+				{
+					title: "本次公出目标总结",
+					dataIndex: "supplement",
+					key: "supplement",
+					width: 200,
+					render: (text, record) => {
+						return (
+							<div style={{ wordBreak: "break-all" }}>
+								{
+									getContactType(record.contactType) === '公出打卡' && <div style={{
+										// paddingTop: '15px',
+										wordBreak: "break-all",
+									}}>
+										{text}
+										<div>
+											<PublicSupplement closeModel={this.closeModel} infor={record} onCancel={() => {
+												this.loadVisit(this.state.ispage);
+											}} />
+										</div>
+									</div>
+								}
+							</div>
+						);
+					},
+				},
+				{
+					title: "下一次公出计划",
+					dataIndex: "nextPlan",
+					key: "nextPlan",
+					width: 200,
+					render: (text) => {
+						return (
+							<div
+							// style={{
+							//   width: 70,
+							//   overflow: "hidden",
+							//   textOverflow: "ellipsis",
+							//   whiteSpace: "nowrap",
+							// }}
+							// title={text}
+							>
+								{text}
+							</div>
+						);
+					},
+				},
+			],
+		};
 	},
 	//拜访记录删除
 	visitDelet(e) {
 		this.setState({
-			visitModul:false,
+			visitModul: false,
 			loading: true
 		});
 		$.ajax({
@@ -255,8 +255,8 @@ const Visit = React.createClass({
 			data: {
 				followId: e.followId, //删除的ID
 			}
-		}).done(function(data) {
-			if(!data.error.length) {
+		}).done(function (data) {
+			if (!data.error.length) {
 				message.success('删除成功!');
 				this.setState({
 					loading: false,
@@ -282,111 +282,116 @@ const Visit = React.createClass({
 				pageSize: this.state.paginations.pageSize,
 				uid: this.props.data.id, //名称1
 			},
-			success: function(data) {
+			success: function (data) {
 				let theArr = [];
-				if(data.error.length || data.data.list == "") {
-					if(data.error && data.error.length) {
+				if (data.error.length || data.data.list == "") {
+					if (data.error && data.error.length) {
 						message.warning(data.error[0].message);
 					};
 				} else {
-					for(let i = 0; i < data.data.list.length; i++) {
+					for (let i = 0; i < data.data.list.length; i++) {
 						let thisdata = data.data.list[i];
 						theArr.push(thisdata);
 					};
 					this.state.paginations.current = data.data.pageNo;
 					this.state.paginations.total = data.data.totalCount;
 				};
-				if(data.data.list&&!data.data.list.length){
-					this.state.paginations.current =0;
-					this.state.paginations.total =0;
+				if (data.data.list && !data.data.list.length) {
+					this.state.paginations.current = 0;
+					this.state.paginations.total = 0;
 				};
 				this.setState({
 					visitArrList: theArr,
 					paginations: this.state.paginations
 				});
 			}.bind(this),
-		}).always(function() {
+		}).always(function () {
 			this.setState({
 				loading: false
 			});
 		}.bind(this));
 	},
-	componentWillMount(){
+	componentWillMount() {
 		this.loadVisit();
 	},
-	detailsModal(){
+	detailsModal() {
 		this.props.closeDetail(false, false)
 	},
 	closeModel() {
 		this.setState({
-      visitModul:false
-    })
+			visitModul: false
+		})
 	},
 	//点击整行
-	VisitRowClick(record){
+	VisitRowClick(record) {
 		this.setState({
 			followData: record,
-			visitModul:true,
+			visitModul: true,
 		})
 	},
 	//进入新增拜访记录
-    visit() {
+	visit() {
 		let obj = {
 			id: this.props.data.id
 		}
 		this.setState({
-			followData:obj,
-			visitModuls:true,
+			followData: obj,
+			visitModuls: true,
 		})
 	},
-	closeDesc(e,s){
-		this.state.visitModul=e
-		this.state.visitModuls=e
-		if(s){
+	closeDesc(e, s) {
+		this.state.visitModul = e
+		this.state.visitModuls = e
+		if (s) {
 			this.loadVisit()
 		}
 	},
 	componentWillReceiveProps(nextProps) {
-		if(nextProps.data.id&&nextProps.visitState){
+		if (nextProps.data.id && nextProps.visitState) {
 			this.loadVisit()
 		}
 		this.setState({
-			visitModul:false
+			visitModul: false
 		})
 	},
-	render(){
-		return(
+	render() {
+		return (
 			<div className="clearfix">
 				<Alert message="注:面谈公出补充,沟通完后记录今天交流的情况。计划下一次什么时候再面谈?该如何面谈?该如何跟进?" banner />
 				<Button
-                    onClick={(e) => {
-                      e.stopPropagation(), this.visit();
-                    }}
+					onClick={(e) => {
+						e.stopPropagation()
+						if (!this.props.data.orgCode) {
+							message.warning(`请先完善"企业统一社会信用代码"`)
+							return
+						}
+						this.visit();
+					}}
 					type="primary"
-					style={{marginTop:'10px',float: 'right'}}
-                  >
-                    客户跟进
-                  </Button>
-			    <Spin spinning={this.state.loading}>
-				  <Table
-					 size="middle"
-				     style={{marginTop:'60px'}}
-	            	 pagination={this.state.paginations}
-	            	 columns={this.state.visitsList}
-	            	 dataSource={this.state.visitArrList}
-					 scroll={{x:'120%', y: 440 }}
-	            	 onRowClick={this.VisitRowClick}
-	            	 />
-			    </Spin>
-			    <VisitDetail
-			    	categoryArr={this.props.categoryArr}
-			    	followData={this.state.followData}
-			    	visitModul={this.state.visitModul}
-			    	closeDesc={this.closeDesc}
-			    	mid={this.props.data.id}
-			    />
+					style={{ marginTop: '10px', float: 'right' }}
+				>
+					客户跟进
+				</Button>
+				<Spin spinning={this.state.loading}>
+					<Table
+						size="middle"
+						style={{ marginTop: '60px' }}
+						pagination={this.state.paginations}
+						columns={this.state.visitsList}
+						dataSource={this.state.visitArrList}
+						scroll={{ x: '120%', y: 440 }}
+						onRowClick={this.VisitRowClick}
+					/>
+				</Spin>
+				<VisitDetail
+					categoryArr={this.props.categoryArr}
+					followData={this.state.followData}
+					visitModul={this.state.visitModul}
+					closeDesc={this.closeDesc}
+					mid={this.props.data.id}
+				/>
 				<FollowDetail
-				    categoryArr={this.props.categoryArr}
+					categoryArr={this.props.categoryArr}
 					followData={this.state.followData}
 					isFlag={true}
 					visitModul={this.state.visitModuls}

+ 125 - 125
js/component/manageCenter/customer/NEW/signCustomer/intentionDetail/intentionDetail.jsx

@@ -1,5 +1,5 @@
 import React from 'react';
-import {Modal,Tabs  } from 'antd';
+import { Modal, Tabs } from 'antd';
 const TabPane = Tabs.TabPane;
 import Basic from './detail/basic.jsx';
 import ajax from 'jquery/src/ajax/xhr.js';
@@ -12,47 +12,47 @@ import LockBusiness from './detail/lockBusiness.jsx';
 import BasicPerson from './detail/basicPerson.jsx';//基本信息
 
 const IntentionDetail = React.createClass({
-	getInitialState(){
-		return{
-			modalVisible:false,
-			switchState:false,
-			contactData:[],
-			contactState:true,
-			IntentionState:false,
-			businessState:false,
-			visitState:false,
-			accountState:false,
-			basicState:false
+	getInitialState() {
+		return {
+			modalVisible: false,
+			switchState: false,
+			contactData: [],
+			contactState: true,
+			IntentionState: false,
+			businessState: false,
+			visitState: false,
+			accountState: false,
+			basicState: false
 		}
 	},
-	detailsModal(){
+	detailsModal() {
 		this.setState({
-			basicState:false,
-			modalVisible:false,
-			callnub:1,
+			basicState: false,
+			modalVisible: false,
+			callnub: 1,
 		});
-		this.props.closeDesc(false,true);
+		this.props.closeDesc(false, true);
 	},
 	//详情tab切换数据处理
 	callback(e) {
-		if(e == '1') {
+		if (e == '1') {
 			this.setState({
-				IntentionState:true,
-				contactState:false,
-				accountState:false,
-				visitState:false,
-				businessState:false,
-				basicState:true
+				IntentionState: true,
+				contactState: false,
+				accountState: false,
+				visitState: false,
+				businessState: false,
+				basicState: true
 			})
 		}
-		if(e == '2') {
+		if (e == '2') {
 			this.setState({
-				IntentionState:false,
-				contactState:true,
-				accountState:false,
-				visitState:false,
-				businessState:false,
-				basicState:false
+				IntentionState: false,
+				contactState: true,
+				accountState: false,
+				visitState: false,
+				businessState: false,
+				basicState: false
 			})
 		}
 		// if(e == '3') {
@@ -65,24 +65,24 @@ const IntentionDetail = React.createClass({
 		// 		basicState:false
 		// 	})
 		// }
-		if(e == '4') {
+		if (e == '4') {
 			this.setState({
-				IntentionState:false,
-				contactState:false,
-				accountState:false,
-				visitState:true,
-				businessState:false,
-				basicState:false
+				IntentionState: false,
+				contactState: false,
+				accountState: false,
+				visitState: true,
+				businessState: false,
+				basicState: false
 			})
 		}
-		if(e == '5') {
+		if (e == '5') {
 			this.setState({
-				IntentionState:false,
-				contactState:false,
-				accountState:false,
-				visitState:false,
-				businessState:true,
-				basicState:false
+				IntentionState: false,
+				contactState: false,
+				accountState: false,
+				visitState: false,
+				businessState: true,
+				basicState: false
 			})
 		}
 		this.setState({
@@ -90,94 +90,94 @@ const IntentionDetail = React.createClass({
 		})
 	},
 	//取消函数
-	closeDetail(e,s){
+	closeDetail(e, s) {
 		this.setState({
-			basicState:false,
+			basicState: false,
 			//contactState:true,
-			modalVisible:e,
+			modalVisible: e,
 		})
-//		if(s){
-//			this.props.closeDesc(false,true)
-//		}
+		//		if(s){
+		//			this.props.closeDesc(false,true)
+		//		}
 	},
 	componentWillReceiveProps(nextProps) {
-		if(nextProps.modalVisible && nextProps.IntentionData.id) {
+		if (nextProps.modalVisible && nextProps.IntentionData.id) {
 			this.setState({
-				modalVisible:true,
-				callnub:this.props.defaultActiveKey ? String(this.props.defaultActiveKey) : (this.props.detailApi.indexOf('Organization'))>0?"2":'1',
+				modalVisible: true,
+				callnub: this.props.defaultActiveKey ? String(this.props.defaultActiveKey) : (this.props.detailApi.indexOf('Organization')) > 0 ? "2" : '1',
 			})
 		};
 		this.setState({
-			basicState:nextProps.basicState,
-			contactState:nextProps.contactState,
+			basicState: nextProps.basicState,
+			contactState: nextProps.contactState,
 		})
 	},
-	render(){
+	render() {
 		return (
-      <div>
-		  {this.state.modalVisible ? <Modal
-          className="customeDetails"
-          title="签单客户详情"
-          width="1300px"
-		  maskClosable={false}
-          visible={this.state.modalVisible}
-          onOk={this.detailsModal}
-          onCancel={this.detailsModal}
-          footer=""
-        >
-          <Tabs onChange={this.callback} activeKey={this.state.callnub}>
-            {this.props.detailApi.indexOf("Organization") > 0 ? (
-              ""
-            ) : (
-              <TabPane tab="基本信息" key="1">
-                <BasicPerson
-                  detailApi={this.props.detailApi}
-                  closeDetail={this.closeDetail}
-                  data={this.props.IntentionData}
-                  IntentionState={this.state.IntentionState}
-                  basicState={this.state.basicState}
-                />
-              </TabPane>
-            )}
-            <TabPane tab="联系人信息" key="2">
-              <ContactPerson
-                closeDetail={this.closeDetail}
-                name={this.props.name}
-                data={this.props.IntentionData}
-                contactState={this.state.contactState}
-              />
-            </TabPane>
-            {/*<TabPane tab="账户信息" key="3">*/}
-            {/*  <Account*/}
-            {/*    closeDetail={this.closeDetail}*/}
-            {/*    data={this.props.IntentionData}*/}
-            {/*    accountState={this.state.accountState}*/}
-            {/*  />*/}
-            {/*</TabPane>*/}
-            <TabPane tab="客户跟进" key="4">
-              <Visit
-			  	loadData={this.props.loadData}
-                closeDetail={this.closeDetail}
-                data={this.props.IntentionData}
-                visitState={this.state.visitState}
-              />
-            </TabPane>
-            <TabPane tab="业务意向" key="5">
-              <Business
-                closeDesc={this.props.closeDesc}
-                closeDetail={this.closeDetail}
-                data={this.props.IntentionData}
-                businessState={this.state.businessState}
-              />
-            </TabPane>
-			<TabPane tab="锁定业务" key="6">
-				{
-					this.state.callnub === '6' ?
-					<LockBusiness uid={this.props.IntentionData && this.props.IntentionData.uid} id={this.props.IntentionData && this.props.IntentionData.id}/> :
-					<div/>
-				}
-			</TabPane>
-            {/*
+			<div>
+				{this.state.modalVisible ? <Modal
+					className="customeDetails"
+					title="签单客户详情"
+					width="1300px"
+					maskClosable={false}
+					visible={this.state.modalVisible}
+					onOk={this.detailsModal}
+					onCancel={this.detailsModal}
+					footer=""
+				>
+					<Tabs onChange={this.callback} activeKey={this.state.callnub}>
+						{this.props.detailApi.indexOf("Organization") > 0 ? (
+							""
+						) : (
+							<TabPane tab="基本信息" key="1">
+								<BasicPerson
+									detailApi={this.props.detailApi}
+									closeDetail={this.closeDetail}
+									data={this.props.IntentionData}
+									IntentionState={this.state.IntentionState}
+									basicState={this.state.basicState}
+								/>
+							</TabPane>
+						)}
+						<TabPane tab="企业&联系人详情" key="2">
+							<ContactPerson
+								closeDetail={this.closeDetail}
+								name={this.props.name}
+								data={this.props.IntentionData}
+								contactState={this.state.contactState}
+							/>
+						</TabPane>
+						{/*<TabPane tab="账户信息" key="3">*/}
+						{/*  <Account*/}
+						{/*    closeDetail={this.closeDetail}*/}
+						{/*    data={this.props.IntentionData}*/}
+						{/*    accountState={this.state.accountState}*/}
+						{/*  />*/}
+						{/*</TabPane>*/}
+						<TabPane tab="客户跟进" key="4">
+							<Visit
+								loadData={this.props.loadData}
+								closeDetail={this.closeDetail}
+								data={this.props.IntentionData}
+								visitState={this.state.visitState}
+							/>
+						</TabPane>
+						<TabPane tab="业务意向" key="5">
+							<Business
+								closeDesc={this.props.closeDesc}
+								closeDetail={this.closeDetail}
+								data={this.props.IntentionData}
+								businessState={this.state.businessState}
+							/>
+						</TabPane>
+						<TabPane tab="锁定业务" key="6">
+							{
+								this.state.callnub === '6' ?
+									<LockBusiness uid={this.props.IntentionData && this.props.IntentionData.uid} id={this.props.IntentionData && this.props.IntentionData.id} /> :
+									<div />
+							}
+						</TabPane>
+						{/*
 							<TabPane tab="业务订单" key="6">
 
 							</TabPane>
@@ -191,10 +191,10 @@ const IntentionDetail = React.createClass({
 
 							</TabPane>
 							*/}
-          </Tabs>
-        </Modal> : <div/>}
-      </div>
-    );
+					</Tabs>
+				</Modal> : <div />}
+			</div>
+		);
 	}
 })
 export default IntentionDetail;

+ 28 - 2
js/component/manageCenter/customer/NEW/signCustomer/signCustomer.jsx

@@ -27,12 +27,13 @@ import { getSocialAttribute, beforeUploadFile, ShowModal } from "@/tools.js";
 import FollowDetail from './followDetail.jsx'
 import ShowModalDiv from "@/showModal.jsx";
 import ZhuanjiaoDetail from "@/zhuanjiaoDetail.jsx";
-import IntentionDetail from './intentionDetail/intentionDetail.jsx'
+import IntentionDetail from './intentionDetail/intentionDetail'
 import './customer.less';
 import { ChooseList } from "../../../order/orderNew/chooseList";
 import EnterpriseNameChange from "../../../../common/enterpriseNameChange";
 
 const { TabPane } = Tabs
+const confirm = Modal.confirm;
 const IntentionCustomer = Form.create()(React.createClass({
 	loadData(pageNo, apiUrl) {
 		this.setState({
@@ -159,6 +160,16 @@ const IntentionCustomer = Form.create()(React.createClass({
 					},
 				},
 				{
+					title: "统一社会信用代码",
+					dataIndex: "orgCode",
+					key: "orgCode",
+					render: (text) => {
+						return <div style={{ color: !text ? "red" : "#000000A6" }}>
+							{!text ? "待补充" : text}
+						</div>;
+					},
+				},
+				{
 					title: "地区",
 					dataIndex: "locationProvince",
 					key: "locationProvince",
@@ -210,7 +221,22 @@ const IntentionCustomer = Form.create()(React.createClass({
 							<div>
 								<Button
 									onClick={(e) => {
-										e.stopPropagation(), this.visit(record);
+										const _this = this
+										e.stopPropagation()
+										if (!record.orgCode) {
+											confirm({
+												title: '您暂时不可以跟进客户',
+												content: `请先完善"企业统一社会信用代码"`,
+												cancelText: '取消',
+												okText: '去完善',
+												onOk() {
+													_this.tableRowClick(record)
+												},
+												onCancel() { },
+											});
+										} else {
+											this.visit(record);
+										}
 									}}
 									type="primary"
 								>

+ 1 - 1
package.json

@@ -1,6 +1,6 @@
 {
   "name": "afanti",
-  "version": "1.2.44",
+  "version": "1.2.45",
   "description": "",
   "main": "index.js",
   "scripts": {