dev01 3 years ago
parent
commit
5c988b1470

+ 1 - 1
js/component/manageCenter/channelList/channelunit/detail/visit.jsx

@@ -42,7 +42,7 @@ const Visit = React.createClass({
           title: "客户名称",
           title: "客户名称",
           dataIndex: "nickname",
           dataIndex: "nickname",
           key: "nickname",
           key: "nickname",
-          width: 100,
+          width: 150,
           render: (text) => {
           render: (text) => {
             return (
             return (
               <Tooltip title={text}>
               <Tooltip title={text}>

+ 335 - 333
js/component/manageCenter/customer/NEW/intentionCustomer/intentionDetail/detail/visit.jsx

@@ -1,8 +1,8 @@
 import React from 'react';
 import React from 'react';
-import {Button, Spin, message, Table, Tooltip, Input, Modal, Alert} from 'antd';
+import { Button, Spin, message, Table, Tooltip, Input, Modal, Alert } from 'antd';
 import $ from 'jquery/src/ajax';
 import $ from 'jquery/src/ajax';
 import FollowDetail from '../../followDetail.jsx'
 import FollowDetail from '../../followDetail.jsx'
-import {getContactType} from '@/tools.js';
+import { getContactType } from '@/tools.js';
 import VisitDetail from './visitDetail.jsx';
 import VisitDetail from './visitDetail.jsx';
 
 
 import PublicSupplement from '../../../../../../publicSupplement';
 import PublicSupplement from '../../../../../../publicSupplement';
@@ -10,271 +10,273 @@ import PublicSupplement from '../../../../../../publicSupplement';
 const confirm = Modal.confirm;
 const confirm = Modal.confirm;
 
 
 const Visit = React.createClass({
 const Visit = React.createClass({
-	getInitialState(){
+	getInitialState() {
 		return {
 		return {
-      visitArrList: [],
+			visitArrList: [],
-      loading: false,
+			loading: false,
-      visitModul: false,
+			visitModul: false,
-      visitModuls: false,
+			visitModuls: false,
-	  followId:0,
+			followId: 0,
-	  ispage:1,
+			ispage: 1,
-      paginations: {
+			paginations: {
-        defaultCurrent: 1,
+				defaultCurrent: 1,
-        defaultPageSize: 10,
+				defaultPageSize: 10,
-        showQuickJumper: true,
+				showQuickJumper: true,
-        pageSize: 10,
+				pageSize: 10,
-        onChange: function (page) {
+				onChange: function (page) {
-          this.loadVisit(page);
+					this.loadVisit(page);
-        }.bind(this),
+				}.bind(this),
-        showTotal: function (total) {
+				showTotal: function (total) {
-          return "共" + total + "条数据";
+					return "共" + total + "条数据";
-        },
+				},
-      },
+			},
-      visitsList: [
+			visitsList: [
-        {
+				{
-          title: "客户名称",
+					title: "客户名称",
-          dataIndex: "nickname",
+					dataIndex: "nickname",
-          key: "nickname",
+					key: "nickname",
-		  width: 100,
+					width: 150,
-		  render: (text) => {
+					render: (text) => {
-				return (
+						return (
-					<Tooltip title={text}>
+							<Tooltip title={text}>
-						<div style={{
+								<div
-							maxWidth:'100px',
+									// style={{
-							overflow:'hidden',
+									// 	maxWidth: '100px',
-							textOverflow: "ellipsis",
+									// 	overflow: 'hidden',
-							whiteSpace:'nowrap',
+									// 	textOverflow: "ellipsis",
-						}}>{text}</div>
+									// 	whiteSpace: 'nowrap',
-					</Tooltip>
+									// }}
-				)
+								>{text}</div>
-		  },
+							</Tooltip>
-        },
+						)
-        {
+					},
-          title: "跟进方式",
+				},
-          dataIndex: "contactType",
+				{
-          key: "contactType",
+					title: "跟进方式",
-		      width: 80,
+					dataIndex: "contactType",
-          render: (text) => {
+					key: "contactType",
-            return getContactType(text);
+					width: 80,
-          },
+					render: (text) => {
-        },
+						return getContactType(text);
-        {
+					},
-          title: "联系人",
+				},
-          dataIndex: "contacts",
+				{
-          key: "contacts",
+					title: "联系人",
-		      width: 100,
+					dataIndex: "contacts",
-          render: (text, record) => {
+					key: "contacts",
-            return (
+					width: 100,
-              <div>
+					render: (text, record) => {
-                {record.readOnly ? <span>***</span> : <span>{text}</span>}
+						return (
-              </div>
+							<div>
-            );
+								{record.readOnly ? <span>***</span> : <span>{text}</span>}
-          },
+							</div>
-        },
+						);
-        {
+					},
-          title: "联系电话",
+				},
-          dataIndex: "contactMobile",
+				{
-          key: "contactMobile",
+					title: "联系电话",
-		      width: 120,
+					dataIndex: "contactMobile",
-          render: (text, record) => {
+					key: "contactMobile",
-            return (
+					width: 120,
-              <div>
+					render: (text, record) => {
-                {record.readOnly ? <span>***</span> : <span>{text}</span>}
+						return (
-              </div>
+							<div>
-            );
+								{record.readOnly ? <span>***</span> : <span>{text}</span>}
-          },
+							</div>
-        },
+						);
-        {
+					},
-          title: "跟进人",
+				},
-          dataIndex: "adminName",
+				{
-          key: "adminName",
+					title: "跟进人",
-		  width: 80
+					dataIndex: "adminName",
-        },
+					key: "adminName",
-        {
+					width: 80
-          title: "跟进时间",
+				},
-          dataIndex: "followTime",
+				{
-          key: "followTime",
+					title: "跟进时间",
-		  width: 65
+					dataIndex: "followTime",
-        },
+					key: "followTime",
-        {
+					width: 65
-          title: "公出目标",
+				},
-          dataIndex: "result",
+				{
-          key: "result",
+					title: "公出目标",
-		      width: 200,
+					dataIndex: "result",
-			// render: (text, record) => {
+					key: "result",
-			// 	return (
+					width: 200,
-			// 		<div style={{wordBreak:"break-all"}}>
+					// render: (text, record) => {
-			// 			<div>{text}</div>
+					// 	return (
-			// 			{
+					// 		<div style={{wordBreak:"break-all"}}>
-			// 				getContactType(record.contactType) === '公出打卡' && <div style={{
+					// 			<div>{text}</div>
-			// 					paddingTop: '15px',
+					// 			{
-			// 					wordBreak: "break-all",
+					// 				getContactType(record.contactType) === '公出打卡' && <div style={{
-			// 					display: "flex",
+					// 					paddingTop: '15px',
-			// 					alignItems: 'flex-end'
+					// 					wordBreak: "break-all",
-			// 				}}>
+					// 					display: "flex",
-			// 					{/* 补充说明:
+					// 					alignItems: 'flex-end'
-			// 					{record.supplement} */}
+					// 				}}>
-			// 					<div style={{paddingLeft: '10px'}}>
+					// 					{/* 补充说明:
-			// 						<PublicSupplement infor={record} onCancel={() => {
+					// 					{record.supplement} */}
-			// 							this.loadVisit(this.state.ispage);
+					// 					<div style={{paddingLeft: '10px'}}>
-			// 						}}/>
+					// 						<PublicSupplement infor={record} onCancel={() => {
-			// 					</div>
+					// 							this.loadVisit(this.state.ispage);
-			// 				</div>
+					// 						}}/>
-			// 			}
+					// 					</div>
-			// 		</div>
+					// 				</div>
-			// 	)
+					// 			}
-			// }
+					// 		</div>
-        },
+					// 	)
-        {
+					// }
-          title: "公出计划",
+				},
-          dataIndex: "plan",
+				{
-          key: "plan",
+					title: "公出计划",
-          width: 200,
+					dataIndex: "plan",
-          render: (text) => {
+					key: "plan",
-            return (
+					width: 200,
-              <div
+					render: (text) => {
-                // style={{
+						return (
-                //   width: 50,
+							<div
-                //   overflow: "hidden",
+							// style={{
-                //   textOverflow: "ellipsis",
+							//   width: 50,
-                //   whiteSpace: "nowrap",
+							//   overflow: "hidden",
-                // }}
+							//   textOverflow: "ellipsis",
-                // title={text}
+							//   whiteSpace: "nowrap",
-              >
+							// }}
-                {text}
+							// title={text}
-              </div>
+							>
-            );
+								{text}
-          },
+							</div>
-        },
+						);
-        {
+					},
-          title: "预计效果",
+				},
-          dataIndex: "expectedEffect",
+				{
-          key: "expectedEffect",
+					title: "预计效果",
-          width: 200,
+					dataIndex: "expectedEffect",
-          render: (text) => {
+					key: "expectedEffect",
-            return (
+					width: 200,
-              <div
+					render: (text) => {
-                // style={{
+						return (
-                //   width: 50,
+							<div
-                //   overflow: "hidden",
+							// style={{
-                //   textOverflow: "ellipsis",
+							//   width: 50,
-                //   whiteSpace: "nowrap",
+							//   overflow: "hidden",
-                // }}
+							//   textOverflow: "ellipsis",
-                // title={text}
+							//   whiteSpace: "nowrap",
-              >
+							// }}
-                {text}
+							// title={text}
-              </div>
+							>
-            );
+								{text}
-          },
+							</div>
-        },
+						);
-        {
+					},
-          title: "本次公出目标总结",
+				},
-          dataIndex: "supplement",
+				{
-          key: "supplement",
+					title: "本次公出目标总结",
-          width: 200,
+					dataIndex: "supplement",
-          render: (text,record) => {
+					key: "supplement",
-            return (
+					width: 200,
-              <div style={{wordBreak:"break-all"}}>
+					render: (text, record) => {
-              {
+						return (
-                getContactType(record.contactType) === '公出打卡' && <div style={{
+							<div style={{ wordBreak: "break-all" }}>
-                  // paddingTop: '15px',
+								{
-                  wordBreak: "break-all",
+									getContactType(record.contactType) === '公出打卡' && <div style={{
-                }}>  
+										// paddingTop: '15px',
-                {text}
+										wordBreak: "break-all",
-                  <div>
+									}}>
-                    <PublicSupplement closeModel={this.closeModel} infor={record} onCancel={() => {
+										{text}
-                      this.loadVisit(this.state.ispage);
+										<div>
-                    }}/>
+											<PublicSupplement closeModel={this.closeModel} infor={record} onCancel={() => {
-                  </div>
+												this.loadVisit(this.state.ispage);
-                </div>
+											}} />
-              }
+										</div>
-            </div>
+									</div>
-            );
+								}
-          },
+							</div>
-        },
+						);
-        {
+					},
-          title: "下一次公出计划",
+				},
-          dataIndex: "nextPlan",
+				{
-          key: "nextPlan",
+					title: "下一次公出计划",
-          width: 200,
+					dataIndex: "nextPlan",
-          render: (text) => {
+					key: "nextPlan",
-            return (
+					width: 200,
-              <div
+					render: (text) => {
-                // style={{
+						return (
-                //   width: 70,
+							<div
-                //   overflow: "hidden",
+							// style={{
-                //   textOverflow: "ellipsis",
+							//   width: 70,
-                //   whiteSpace: "nowrap",
+							//   overflow: "hidden",
-                // }}
+							//   textOverflow: "ellipsis",
-                // title={text}
+							//   whiteSpace: "nowrap",
-              >
+							// }}
-                {text}
+							// title={text}
-              </div>
+							>
-            );
+								{text}
-          },
+							</div>
-        },
+						);
-		{
+					},
-		  title: "指导时间",
+				},
-		  dataIndex: "guidanceTime",
+				{
-		  key: "guidanceTime",
+					title: "指导时间",
-		  width: 105,
+					dataIndex: "guidanceTime",
-		  render: (text, record) => {
+					key: "guidanceTime",
-			  return (
+					width: 105,
-				  <span>{text ? text : ''}</span>
+					render: (text, record) => {
-			  )
+						return (
-		  }
+							<span>{text ? text : ''}</span>
-		},
+						)
-    {
+					}
-		  title: "指导意见",
+				},
-		  dataIndex: "abc",
+				{
-		  key: "abc",
+					title: "指导意见",
-		  width: 200,
+					dataIndex: "abc",
-		  render: (text, record) => {
+					key: "abc",
-			  return (
+					width: 200,
-				  <div>
+					render: (text, record) => {
-					  {record.guidance ?
+						return (
-						  <Tooltip placement="topLeft" title={<div style={{wordBreak:"break-all"}}>{(record.guidanceName ? '('+record.guidanceName+')' : '') + record.guidance}</div>}>
+							<div>
-							  <div style={{
+								{record.guidance ?
-								  cursor:"pointer",
+									<Tooltip placement="topLeft" title={<div style={{ wordBreak: "break-all" }}>{(record.guidanceName ? '(' + record.guidanceName + ')' : '') + record.guidance}</div>}>
-								  width: '150px',
+										<div style={{
-								  whiteSpace: 'nowrap',
+											cursor: "pointer",
-								  overflow: 'hidden',
+											width: '150px',
-								  textOverflow: 'ellipsis',
+											whiteSpace: 'nowrap',
-							  }}>
+											overflow: 'hidden',
-								  {record.guidanceName ? '('+record.guidanceName+')' : null}
+											textOverflow: 'ellipsis',
-								  {record.guidance}
+										}}>
-							  </div>
+											{record.guidanceName ? '(' + record.guidanceName + ')' : null}
-						  </Tooltip> : (this.props.isEditGuidanceLv ? <Button
+											{record.guidance}
-						  onClick={(e) => {
+										</div>
-							  e.stopPropagation();
+									</Tooltip> : (this.props.isEditGuidanceLv ? <Button
-							  this.setState({
+										onClick={(e) => {
-								  guidanceVisible: true,
+											e.stopPropagation();
-								  visitModul: false,
+											this.setState({
-								  followId: record.followId
+												guidanceVisible: true,
-							  })
+												visitModul: false,
-						  }}
+												followId: record.followId
-						  type="primary"
+											})
-					  >
+										}}
-						  立即指导
+										type="primary"
-					  </Button> : <span>暂未指导</span>)}
+									>
-				  </div>
+										立即指导
-			  );
+									</Button> : <span>暂未指导</span>)}
-		  },
+							</div>
-		},
+						);
-      ],
+					},
-	  guidanceVisible: false,
+				},
-	  guidance: ''
+			],
-    };
+			guidanceVisible: false,
+			guidance: ''
+		};
+	},
+	closeModel() {
+		this.setState({
+			visitModul: false
+		})
 	},
 	},
-  closeModel(){
-    this.setState({
-      visitModul:false
-    })
-  },
 	//拜访记录删除
 	//拜访记录删除
 	visitDelet(e) {
 	visitDelet(e) {
 		this.setState({
 		this.setState({
-			visitModul:false,
+			visitModul: false,
 			loading: true
 			loading: true
 		});
 		});
 		$.ajax({
 		$.ajax({
@@ -285,8 +287,8 @@ const Visit = React.createClass({
 			data: {
 			data: {
 				followId: e.followId, //删除的ID
 				followId: e.followId, //删除的ID
 			}
 			}
-		}).done(function(data) {
+		}).done(function (data) {
-			if(!data.error.length) {
+			if (!data.error.length) {
 				message.success('删除成功!');
 				message.success('删除成功!');
 				this.setState({
 				this.setState({
 					loading: false,
 					loading: false,
@@ -312,14 +314,14 @@ const Visit = React.createClass({
 				pageSize: this.state.paginations.pageSize,
 				pageSize: this.state.paginations.pageSize,
 				uid: this.props.data.id, //名称1
 				uid: this.props.data.id, //名称1
 			},
 			},
-			success: function(data) {
+			success: function (data) {
 				let theArr = [];
 				let theArr = [];
-				if(data.error.length || data.data.list == "") {
+				if (data.error.length || data.data.list == "") {
-					if(data.error && data.error.length) {
+					if (data.error && data.error.length) {
 						message.warning(data.error[0].message);
 						message.warning(data.error[0].message);
 					};
 					};
 				} else {
 				} 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];
 						let thisdata = data.data.list[i];
 						theArr.push(thisdata);
 						theArr.push(thisdata);
 					};
 					};
@@ -329,60 +331,60 @@ const Visit = React.createClass({
 						ispage: data.data.pageNo
 						ispage: data.data.pageNo
 					})
 					})
 				};
 				};
-				if(data.data.list&&!data.data.list.length){
+				if (data.data.list && !data.data.list.length) {
-					this.state.paginations.current =0;
+					this.state.paginations.current = 0;
-					this.state.paginations.total =0;
+					this.state.paginations.total = 0;
 				};
 				};
 				this.setState({
 				this.setState({
 					visitArrList: theArr,
 					visitArrList: theArr,
 					paginations: this.state.paginations
 					paginations: this.state.paginations
 				});
 				});
 			}.bind(this),
 			}.bind(this),
-		}).always(function() {
+		}).always(function () {
 			this.setState({
 			this.setState({
 				loading: false
 				loading: false
 			});
 			});
 		}.bind(this));
 		}.bind(this));
 	},
 	},
-	componentWillMount(){
+	componentWillMount() {
 		this.loadVisit();
 		this.loadVisit();
 	},
 	},
-	detailsModal(){
+	detailsModal() {
 		this.props.closeDetail(false, false)
 		this.props.closeDetail(false, false)
 	},
 	},
 	//点击整行
 	//点击整行
-	VisitRowClick(record){
+	VisitRowClick(record) {
 		this.setState({
 		this.setState({
 			followData: record,
 			followData: record,
-			visitModul:true,
+			visitModul: true,
 		})
 		})
 	},
 	},
 	//进入新增拜访记录
 	//进入新增拜访记录
-    visit() {
+	visit() {
 		let obj = {
 		let obj = {
 			id: this.props.data.id
 			id: this.props.data.id
 		}
 		}
 		this.setState({
 		this.setState({
-			followData:obj,
+			followData: obj,
-			visitModuls:true,
+			visitModuls: true,
 		})
 		})
 	},
 	},
-  componentDidMount() {
+	componentDidMount() {
-    this.setState({
+		this.setState({
-			visitModul:false,
+			visitModul: false,
 		})
 		})
-  },
+	},
-	closeDesc(e,s){
+	closeDesc(e, s) {
-		this.state.visitModul=e
+		this.state.visitModul = e
-		this.state.visitModuls=e
+		this.state.visitModuls = e
-		if(s){
+		if (s) {
 			this.loadVisit()
 			this.loadVisit()
 		}
 		}
 	},
 	},
 	//发布指导意见
 	//发布指导意见
-	releaseGuidance(e){
+	releaseGuidance(e) {
 		e.stopPropagation();
 		e.stopPropagation();
-		if(!this.state.guidance){
+		if (!this.state.guidance) {
 			message.info('指导意见不能为空')
 			message.info('指导意见不能为空')
 			return;
 			return;
 		}
 		}
@@ -398,8 +400,8 @@ const Visit = React.createClass({
 				guidance: this.state.guidance,
 				guidance: this.state.guidance,
 				followId: this.state.followId,
 				followId: this.state.followId,
 			},
 			},
-		}).done(function(data) {
+		}).done(function (data) {
-			if(!data.error.length) {
+			if (!data.error.length) {
 				message.success("发布成功");
 				message.success("发布成功");
 				this.loadVisit(this.state.ispage);
 				this.loadVisit(this.state.ispage);
 				this.setState({
 				this.setState({
@@ -412,47 +414,47 @@ const Visit = React.createClass({
 		}.bind(this));
 		}.bind(this));
 	},
 	},
 	componentWillReceiveProps(nextProps) {
 	componentWillReceiveProps(nextProps) {
-		if(nextProps.data.id&&nextProps.visitState){
+		if (nextProps.data.id && nextProps.visitState) {
 			this.loadVisit()
 			this.loadVisit()
 		}
 		}
 		this.setState({
 		this.setState({
-			visitModul:false
+			visitModul: false
 		})
 		})
 	},
 	},
-	render(){
+	render() {
-		return(
+		return (
 			<div className="clearfix">
 			<div className="clearfix">
 				<Alert message="注:面谈公出补充,沟通完后记录今天交流的情况。计划下一次什么时候再面谈?该如何面谈?该如何跟进?" banner />
 				<Alert message="注:面谈公出补充,沟通完后记录今天交流的情况。计划下一次什么时候再面谈?该如何面谈?该如何跟进?" banner />
 				{!this.props.isGuidanceLv ? <Button
 				{!this.props.isGuidanceLv ? <Button
-                    onClick={(e) => {
+					onClick={(e) => {
-                      e.stopPropagation();
+						e.stopPropagation();
-                      this.visit();
+						this.visit();
-                    }}
+					}}
 					type="primary"
 					type="primary"
-					style={{marginTop:'10px',float: 'right'}}
+					style={{ marginTop: '10px', float: 'right' }}
-                  >
+				>
-                    客户跟进
+					客户跟进
-                  </Button> : <div/>}
+				</Button> : <div />}
-			    <Spin spinning={this.state.loading}>
+				<Spin spinning={this.state.loading}>
-				  <Table
+					<Table
-					 size="middle"
+						size="middle"
-				     style={{marginTop:this.props.isGuidanceLv ? '0px' : '60px',cursor: 'pointer',}}
+						style={{ marginTop: this.props.isGuidanceLv ? '0px' : '60px', cursor: 'pointer', }}
-	            	 pagination={this.state.paginations}
+						pagination={this.state.paginations}
-	            	 columns={this.state.visitsList}
+						columns={this.state.visitsList}
-	            	 dataSource={this.state.visitArrList}
+						dataSource={this.state.visitArrList}
-	            	 onRowClick={this.VisitRowClick}
+						onRowClick={this.VisitRowClick}
-					 scroll={{ x:'130%',y: 440 }}
+						scroll={{ x: '130%', y: 440 }}
-	            	 />
+					/>
-			    </Spin>
+				</Spin>
-			    <VisitDetail
+				<VisitDetail
-			    	categoryArr={this.props.categoryArr}
+					categoryArr={this.props.categoryArr}
-			    	followData={this.state.followData}
+					followData={this.state.followData}
-			    	visitModul={this.state.visitModul}
+					visitModul={this.state.visitModul}
-			    	closeDesc={this.closeDesc}
+					closeDesc={this.closeDesc}
-			    	mid={this.props.data.id}
+					mid={this.props.data.id}
-			    />
+				/>
 				<FollowDetail
 				<FollowDetail
-				    categoryArr={this.props.categoryArr}
+					categoryArr={this.props.categoryArr}
 					followData={this.state.followData}
 					followData={this.state.followData}
 					visitModul={this.state.visitModuls}
 					visitModul={this.state.visitModuls}
 					closeDesc={this.closeDesc}
 					closeDesc={this.closeDesc}
@@ -464,19 +466,19 @@ const Visit = React.createClass({
 					title="指导意见"
 					title="指导意见"
 					width='500px'
 					width='500px'
 					visible={this.state.guidanceVisible}
 					visible={this.state.guidanceVisible}
-					onOk={()=>{
+					onOk={() => {
 						this.setState({
 						this.setState({
 							guidanceVisible: false,
 							guidanceVisible: false,
 							guidance: '',
 							guidance: '',
-						},()=>{
+						}, () => {
 							this.loadVisit();
 							this.loadVisit();
 						})
 						})
 					}}
 					}}
-					onCancel={()=>{
+					onCancel={() => {
 						this.setState({
 						this.setState({
 							guidanceVisible: false,
 							guidanceVisible: false,
 							guidance: '',
 							guidance: '',
-						},()=>{
+						}, () => {
 							this.loadVisit();
 							this.loadVisit();
 						})
 						})
 					}}
 					}}
@@ -484,14 +486,14 @@ const Visit = React.createClass({
 				>
 				>
 					<Spin spinning={this.state.loading}>
 					<Spin spinning={this.state.loading}>
 						<div style={{
 						<div style={{
-							display:'flex',
+							display: 'flex',
-							flexFlow:'column',
+							flexFlow: 'column',
 						}}>
 						}}>
 							<Input
 							<Input
-								style={{ width: '400px',height:'50px' }}
+								style={{ width: '400px', height: '50px' }}
 								placeholder="请输入指导意见"
 								placeholder="请输入指导意见"
 								type={'textarea'}
 								type={'textarea'}
-								onChange={(e)=>{
+								onChange={(e) => {
 									this.setState({
 									this.setState({
 										guidance: e.target.value,
 										guidance: e.target.value,
 									})
 									})
@@ -500,7 +502,7 @@ const Visit = React.createClass({
 							<Button
 							<Button
 								type="primary"
 								type="primary"
 								style={{ marginTop: "10px", marginBottom: '10px' }}
 								style={{ marginTop: "10px", marginBottom: '10px' }}
-								onClick={(e)=>{
+								onClick={(e) => {
 									let _this = this;
 									let _this = this;
 									confirm({
 									confirm({
 										title: '确定要提交本次指导意见吗?',
 										title: '确定要提交本次指导意见吗?',
@@ -508,7 +510,7 @@ const Visit = React.createClass({
 										onOk() {
 										onOk() {
 											_this.releaseGuidance(e);
 											_this.releaseGuidance(e);
 										},
 										},
-										onCancel() {},
+										onCancel() { },
 									});
 									});
 								}}
 								}}
 							>
 							>
@@ -516,7 +518,7 @@ const Visit = React.createClass({
 							</Button>
 							</Button>
 						</div>
 						</div>
 					</Spin>
 					</Spin>
-				</Modal> : <div/>}
+				</Modal> : <div />}
 			</div>
 			</div>
 		)
 		)
 	}
 	}

+ 47 - 42
js/component/manageCenter/customer/NEW/query/queryCutomer.jsx

@@ -1,17 +1,17 @@
 import React from 'react';
 import React from 'react';
-import { Button,Modal,Input, Select, Spin, Table,Tabs, message, Form ,Tooltip} from 'antd';
+import { Button, Modal, Input, Select, Spin, Table, Tabs, message, Form, Tooltip } from 'antd';
 import $ from 'jquery/src/ajax';
 import $ from 'jquery/src/ajax';
-import {ShowModal} from '../../../../tools.js'
+import { ShowModal } from '../../../../tools.js'
-import {provinceList } from '@/NewDicProvinceList';
+import { provinceList } from '@/NewDicProvinceList';
 import ShowModalDiv from "@/showModal.jsx";
 import ShowModalDiv from "@/showModal.jsx";
 import ZhuanjiaoDetail from "@/zhuanjiaoDetail.jsx";
 import ZhuanjiaoDetail from "@/zhuanjiaoDetail.jsx";
 import Detaile from './detail.jsx';
 import Detaile from './detail.jsx';
-import {ChooseList} from "../../../order/orderNew/chooseList";
+import { ChooseList } from "../../../order/orderNew/chooseList";
 import EnterpriseNameChange from "../../../../common/enterpriseNameChange";
 import EnterpriseNameChange from "../../../../common/enterpriseNameChange";
 
 
 const confirm = Modal.confirm;
 const confirm = Modal.confirm;
 
 
-const {TabPane} =Tabs
+const { TabPane } = Tabs
 const QueryCustomer = React.createClass({
 const QueryCustomer = React.createClass({
   loadData(pageNo, apiUrl) {
   loadData(pageNo, apiUrl) {
     this.setState({
     this.setState({
@@ -142,26 +142,26 @@ const QueryCustomer = React.createClass({
           title: "客户名称",
           title: "客户名称",
           dataIndex: "name",
           dataIndex: "name",
           key: "name",
           key: "name",
-          width: 350,
+          width: 300,
           render: (text, record) => {
           render: (text, record) => {
             return (
             return (
-                <span style={{display:'flex',alignItems: 'flex-start'}}>
+              <span style={{ display: 'flex', alignItems: 'flex-start' }}>
-                  {record.channel=== 1 ? <div style={{
+                {record.channel === 1 ? <div style={{
-                    whiteSpace:'nowrap',
+                  whiteSpace: 'nowrap',
-                    background:'#ef7207',
+                  background: '#ef7207',
-                    color:'#FFF',
+                  color: '#FFF',
-                    padding: '1px 7px',
+                  padding: '1px 7px',
-                    borderRadius:'5px',
+                  borderRadius: '5px',
-                    fontSize:'12px',
+                  fontSize: '12px',
-                    display: 'inline-block',
+                  display: 'inline-block',
-                    marginRight:'10px'
+                  marginRight: '10px'
-                  }}>
+                }}>
-						外联
+                  外联
-					</div> : null}
+                </div> : null}
-                  <Tooltip title={text}>
+                <Tooltip title={text}>
-                    <div>{text}</div>
+                  <div>{text}</div>
-                  </Tooltip>
+                </Tooltip>
-                </span>
+              </span>
             )
             )
           }
           }
         },
         },
@@ -169,12 +169,13 @@ const QueryCustomer = React.createClass({
           title: "共享类型",
           title: "共享类型",
           dataIndex: "shareType",
           dataIndex: "shareType",
           key: "shareType",
           key: "shareType",
+          width: 100,
           //0-私有 1-公共 2 签单
           //0-私有 1-公共 2 签单
           render: (text) => {
           render: (text) => {
             return (
             return (
-                text === '0' ? '私有':
+              text === '0' ? '私有' :
-                    text === '1' ? '公共':
+                text === '1' ? '公共' :
-                        text === '2' ? '签单': ''
+                  text === '2' ? '签单' : ''
             )
             )
           }
           }
         },
         },
@@ -182,21 +183,25 @@ const QueryCustomer = React.createClass({
           title: "地区",
           title: "地区",
           dataIndex: "locationProvince",
           dataIndex: "locationProvince",
           key: "locationProvince",
           key: "locationProvince",
+          width: 200,
         },
         },
         {
         {
           title: "创建时间",
           title: "创建时间",
           dataIndex: "createTime",
           dataIndex: "createTime",
           key: "createTime",
           key: "createTime",
+          width: 160,
         },
         },
         {
         {
           title: "客户所属人",
           title: "客户所属人",
           dataIndex: "adminName",
           dataIndex: "adminName",
           key: "adminName",
           key: "adminName",
+          width: 160,
         },
         },
         {
         {
           title: "资料所属人",
           title: "资料所属人",
           dataIndex: "informationMaintainer",
           dataIndex: "informationMaintainer",
           key: "informationMaintainer",
           key: "informationMaintainer",
+          width: 160,
         },
         },
         {
         {
           title: "操作",
           title: "操作",
@@ -210,8 +215,8 @@ const QueryCustomer = React.createClass({
                   onClick={(e) => {
                   onClick={(e) => {
                     e.stopPropagation(), this.seeDetail(record);
                     e.stopPropagation(), this.seeDetail(record);
                   }}
                   }}
-				  type="primary"
+                  type="primary"
-				  style={{ marginRight: 10 }}
+                  style={{ marginRight: 10 }}
                 >
                 >
                   {record.signBills === 0 ? '暂未签单' : '查看签单详情'}
                   {record.signBills === 0 ? '暂未签单' : '查看签单详情'}
                 </Button>
                 </Button>
@@ -224,11 +229,11 @@ const QueryCustomer = React.createClass({
                   查看转交记录
                   查看转交记录
                 </Button>
                 </Button>
                 <EnterpriseNameChange
                 <EnterpriseNameChange
-                    type='journal'
+                  type='journal'
-                    style={{ marginLeft: 10 }}
+                  style={{ marginLeft: 10 }}
-                    enterpriseId={record.uid}/>
+                  enterpriseId={record.uid} />
                 {record.shareType === '1' &&
                 {record.shareType === '1' &&
-                  <Button style={{ marginLeft: 10 }} onClick={(e) =>{
+                  <Button style={{ marginLeft: 10 }} onClick={(e) => {
                     e.stopPropagation();
                     e.stopPropagation();
                     let _this = this;
                     let _this = this;
                     confirm({
                     confirm({
@@ -237,7 +242,7 @@ const QueryCustomer = React.createClass({
                       onOk() {
                       onOk() {
                         _this.receive(record);
                         _this.receive(record);
                       },
                       },
-                      onCancel() {},
+                      onCancel() { },
                     });
                     });
                   }} type="primary">领取</Button>
                   }} type="primary">领取</Button>
                 }
                 }
@@ -260,11 +265,11 @@ const QueryCustomer = React.createClass({
       data: {
       data: {
         uid: e.id,
         uid: e.id,
       }
       }
-    }).done(function(data) {
+    }).done(function (data) {
       this.setState({
       this.setState({
         loading: false,
         loading: false,
       });
       });
-      if(data.error.length === 0) {
+      if (data.error.length === 0) {
         message.success('领取成功!');
         message.success('领取成功!');
         this.loadData(this.state.ispage);
         this.loadData(this.state.ispage);
       } else {
       } else {
@@ -478,11 +483,11 @@ const QueryCustomer = React.createClass({
           <TabPane tab="更改表格显示数据" key="2">
           <TabPane tab="更改表格显示数据" key="2">
             <div style={{ marginLeft: 10 }}>
             <div style={{ marginLeft: 10 }}>
               <ChooseList
               <ChooseList
-                  columns={this.state.columns}
+                columns={this.state.columns}
-                  changeFn={this.changeList}
+                changeFn={this.changeList}
-                  changeList={this.state.changeList}
+                changeList={this.state.changeList}
-                  top={55}
+                top={55}
-                  margin={11}
+                margin={11}
               />
               />
             </div>
             </div>
           </TabPane>
           </TabPane>
@@ -493,8 +498,8 @@ const QueryCustomer = React.createClass({
               size="middle"
               size="middle"
               columns={
               columns={
                 this.state.changeList
                 this.state.changeList
-                    ? this.state.changeList
+                  ? this.state.changeList
-                    : this.state.columns
+                  : this.state.columns
               }
               }
               dataSource={this.state.dataSource}
               dataSource={this.state.dataSource}
               rowSelection={rowSelection}
               rowSelection={rowSelection}