liting2017 6 år sedan
förälder
incheckning
9abc245590
15 ändrade filer med 91 tillägg och 32 borttagningar
  1. 3 0
      js/component/manageCenter/customer/NEW/intentionCustomer/followDetail.jsx
  2. 1 0
      js/component/manageCenter/customer/NEW/intentionCustomer/followDetail/addContact.jsx
  3. 1 1
      js/component/manageCenter/customer/NEW/intentionCustomer/intentionDetail/detail/basicPerson.jsx
  4. 5 5
      js/component/manageCenter/customer/NEW/intentionCustomer/intentionDetail/detail/businFollow.jsx
  5. 1 0
      js/component/manageCenter/customer/NEW/intentionCustomer/intentionDetail/detail/business.jsx
  6. 25 5
      js/component/manageCenter/customer/NEW/intentionCustomer/intentionDetail/detail/businessDetail.jsx
  7. 1 0
      js/component/manageCenter/customer/NEW/intentionCustomer/intentionDetail/detail/contactPerson.jsx
  8. 1 1
      js/component/manageCenter/customer/NEW/intentionCustomer/intentionDetail/detail/visitDetail.jsx
  9. 3 0
      js/component/manageCenter/customer/NEW/signCustomer/followDetail.jsx
  10. 4 4
      js/component/manageCenter/customer/NEW/signCustomer/intentionDetail/detail/businFollow.jsx
  11. 5 0
      js/component/manageCenter/customer/NEW/signCustomer/intentionDetail/detail/business.jsx
  12. 24 4
      js/component/manageCenter/customer/NEW/signCustomer/intentionDetail/detail/businessDetail.jsx
  13. 1 0
      js/component/manageCenter/customer/NEW/signCustomer/intentionDetail/detail/contactPerson.jsx
  14. 9 9
      js/component/manageCenter/customer/NEW/signCustomer/intentionDetail/detail/visit.jsx
  15. 7 3
      js/component/manageCenter/customer/NEW/signCustomer/intentionDetail/detail/visitDetail.jsx

+ 3 - 0
js/component/manageCenter/customer/NEW/intentionCustomer/followDetail.jsx

@@ -201,6 +201,9 @@ const FollowDetail = React.createClass({
 	},
 	//刷新新增拜访记录刷新
 	deletelist(e) {
+		this.setState({
+			loading:true
+		});
 		$.ajax({
 			method: "get",
 			dataType: "json",

+ 1 - 0
js/component/manageCenter/customer/NEW/intentionCustomer/followDetail/addContact.jsx

@@ -80,6 +80,7 @@ const AddContact = React.createClass({
 				loading:false
 			})
 		};
+		
 	},
 	render() {
 		return(

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

@@ -254,7 +254,7 @@ const Basic = React.createClass({
 				consultant: this.state.consultant,
 				international: this.state.international,
 				fixedTel: this.state.fixedTel,
-				consultationPrice: this.state.consultationPrice ? this.state.consultationPrice : 0,
+				consultationPrice: this.state.consultationPrice ? this.state.consultationPrice : '',
 				qq: this.state.qq,
 				contacts: this.state.contacts,
 				contactMobile: this.state.contactMobile,

+ 5 - 5
js/component/manageCenter/customer/NEW/intentionCustomer/intentionDetail/detail/businFollow.jsx

@@ -19,7 +19,7 @@ const BusinFollow =React.createClass({
 		this.props.closeBusiness(false)
 	},
 	componentWillReceiveProps(nextProps) {
-		if(nextProps.data.ufbId&&nextProps.businessFollowModul){
+		if(nextProps.businessFollowModul){
 			this.setState({
 				businessFollowModul:true
 			})
@@ -44,7 +44,7 @@ const BusinFollow =React.createClass({
 					thedata = {};
 				};
 				this.setState({
-					businessGlossoryIds: thedata.businessGlossoryId,
+					businessProjectName: thedata.businessProjectName,
 					followSituations: thedata.followSituation,
 					customerStatuss: thedata.customerStatus,
 					followTimes: thedata.followTime,
@@ -87,7 +87,7 @@ const BusinFollow =React.createClass({
 		    					<FormItem className="half-item"
 			                            {...formItemLayout}
 			                            label="意向业务名称" >
-			                        <span>{getCompanyIntention(this.state.businessGlossoryIds)}</span>
+			                        <span>{this.state.businessProjectName}</span>
 			                    </FormItem>
 			                    <FormItem className="half-item"
 			                            {...formItemLayout}
@@ -132,12 +132,12 @@ const BusinFollow =React.createClass({
 			                    <FormItem className="half-item"
 			                            {...formItemLayout}
 			                            label="联系人" >
-			                        <span>{this.state.contactss}</span>
+			                        <span>{!this.props.data.readOnly?this.state.contactss:'***'}</span>
 			                    </FormItem>
 			                    <FormItem className="half-item"
 			                            {...formItemLayout}
 			                            label="联系电话" >
-			                        <span>{this.state.contactMobiles}</span>
+			                        <span>{!this.props.data.readOnly?this.state.contactMobiles:'***'}</span>
 			                    </FormItem>
 			                    <FormItem className="half-item"
 			                            {...formItemLayout}

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

@@ -90,6 +90,7 @@ const Business = React.createClass({
 						theArr.push({
 							key: i,
 							businessId: thisdata.businessId,
+							businessProjectId:thisdata.businessProjectId,
 							businessName: thisdata.businessName,
 							identifyName: thisdata.identifyName,
 							followSituation: thisdata.followSituation,

+ 25 - 5
js/component/manageCenter/customer/NEW/intentionCustomer/intentionDetail/detail/businessDetail.jsx

@@ -52,11 +52,29 @@ const BusinessDetail =React.createClass({
 					title: '联系人',
 					dataIndex: 'contacts',
 					key: 'contacts',
+					render:(text,record)=>{
+						return  <div>
+									{
+										!record.readOnly?
+										<span>{text}</span>:
+										<span>***</span>
+									}
+								</div>
+					}
 				},
 				{
 					title: '联系电话',
 					dataIndex: 'contactMobile',
 					key: 'contactMobile',
+					render:(text,record)=>{
+						return  <div>
+									{
+										!record.readOnly?
+										<span>{text}</span>:
+										<span>***</span>
+									}
+								</div>
+					}
 				}, {
 					title: '操作',
 					dataIndex: 'ooo',
@@ -91,7 +109,7 @@ const BusinessDetail =React.createClass({
 					thedata = {};
 				};
 				this.setState({
-					businessGlossoryIds: thedata.businessGlossoryId,
+					businessProjectName: thedata.businessProjectName,
 					followSituations: thedata.followSituation,
 					customerStatuss: thedata.customerStatus,
 					followTimes: thedata.followTime,
@@ -127,7 +145,7 @@ const BusinessDetail =React.createClass({
 				pageNo: pageNo || 1,
 				pageSize: this.state.paginationst.pageSize,
 				uid: this.props.ids, //名称1
-				businessGlossoryId: this.state.businessGlossoryId,
+				businessProjectId:this.props.data.businessProjectId
 			},
 			success: function(data) {
 				let theArr = [];
@@ -139,6 +157,8 @@ const BusinessDetail =React.createClass({
 					for(let i = 0; i < data.data.list.length; i++) {
 						let thisdata = data.data.list[i];
 						theArr.push({
+							key:i,
+							readOnly:thisdata.readOnly,
 							followId: thisdata.followId,
 							followTime: thisdata.followTime,
 							identifyName: thisdata.identifyName,
@@ -177,7 +197,7 @@ const BusinessDetail =React.createClass({
 			crossDomain: false,
 			url: globalConfig.context + '/api/admin/customer/toUpdateBusiness',
 			data: {
-				businessId: e.businessId
+				businessId: e.businessId,
 			},
 			success: function(data) {
 				let thisData = data.data;
@@ -188,7 +208,7 @@ const BusinessDetail =React.createClass({
 					thisData = {};
 				};
 				this.setState({
-					businessGlossoryId: thisData.businessGlossoryId,
+					businessProjectName: thisData.businessProjectName,
 					identifyName: thisData.identifyName,
 					uid: thisData.uid,
 					businessId: thisData.businessId,
@@ -253,7 +273,7 @@ const BusinessDetail =React.createClass({
 				    					<FormItem className="half-item"
 					                            {...formItemLayout}
 					                            label="意向业务名称" >
-					                        <span>{getCompanyIntention(this.state.businessGlossoryId)}</span>
+					                        <span>{this.state.businessProjectName}</span>
 					                    </FormItem>
 					                    <FormItem className="half-item"
 					                            {...formItemLayout}

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

@@ -169,6 +169,7 @@ const ContactPerson = React.createClass({
 					for(let i = 0; i < data.data.length; i++) {
 						let thisdata = data.data[i];
 						theArr.push({
+							key:i,
 							id: thisdata.id,
 							name: thisdata.name,
 							mobile: thisdata.mobile,

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

@@ -95,7 +95,7 @@ const VisitDetail = React.createClass({
 									{!record.readOnly?<Input value={record.remarks} placeholder="跟进说明"
 		                             onChange={(e) => { record.remarks = e.target.value; this.setState({ data: this.state.data }); }}
 		                             style={{width:'120px'}}/>:
-		                             <span>{text}</span>
+	                           		  <span title={text}>{text&&text.length>8?text.substr(0,8)+'…':text}</span>
 		                             }
 	                            </div>
 					}

+ 3 - 0
js/component/manageCenter/customer/NEW/signCustomer/followDetail.jsx

@@ -158,6 +158,9 @@ const FollowDetail = React.createClass({
 	},
 	//刷新新增拜访记录刷新
 	deletelist(e) {
+		this.setState({
+			loading:true
+		})
 		$.ajax({
 			method: "get",
 			dataType: "json",

+ 4 - 4
js/component/manageCenter/customer/NEW/signCustomer/intentionDetail/detail/businFollow.jsx

@@ -44,7 +44,7 @@ const BusinFollow =React.createClass({
 					thedata = {};
 				};
 				this.setState({
-					businessGlossoryIds: thedata.businessGlossoryId,
+					businessProjectName: thedata.businessProjectName,
 					followSituations: thedata.followSituation,
 					customerStatuss: thedata.customerStatus,
 					followTimes: thedata.followTime,
@@ -87,7 +87,7 @@ const BusinFollow =React.createClass({
 		    					<FormItem className="half-item"
 			                            {...formItemLayout}
 			                            label="意向业务名称" >
-			                        <span>{getCompanyIntention(this.state.businessGlossoryIds)}</span>
+			                        <span>{this.state.businessProjectName}</span>
 			                    </FormItem>
 			                    <FormItem className="half-item"
 			                            {...formItemLayout}
@@ -137,12 +137,12 @@ const BusinFollow =React.createClass({
 			                    <FormItem className="half-item"
 			                            {...formItemLayout}
 			                            label="联系电话" >
-			                        <span>{this.state.contactMobiles}</span>
+			                        <span>{!this.props.data.readOnly?this.state.contactMobiles:'***'}</span>
 			                    </FormItem>
 			                    <FormItem className="half-item"
 			                            {...formItemLayout}
 			                            label="拜访时间" >
-			                        <span>{this.state.followTimes}</span>
+			                        <span>{!this.props.data.readOnly?this.state.followTimes:'***'}</span>
 			                    </FormItem>
 			                    <FormItem className="half-item"
 			                            {...formItemLayout}

+ 5 - 0
js/component/manageCenter/customer/NEW/signCustomer/intentionDetail/detail/business.jsx

@@ -90,6 +90,7 @@ const Business = React.createClass({
 						theArr.push({
 							key: i,
 							businessId: thisdata.businessId,
+							businessProjectId:thisdata.businessProjectId,
 							businessName: thisdata.businessName,
 							identifyName: thisdata.identifyName,
 							followSituation: thisdata.followSituation,
@@ -101,6 +102,10 @@ const Business = React.createClass({
 					this.state.paginationt.current = data.data.pageNo;
 					this.state.paginationt.total = data.data.totalCount;
 				};
+				if(data.data&&data.data.list&&!data.data.list.length){
+					this.state.paginationt.current=0
+					this.state.paginationt.total=0
+				}
 				this.setState({
 					dataBusiness: theArr,
 					paginationt: this.state.paginationt||[]

+ 24 - 4
js/component/manageCenter/customer/NEW/signCustomer/intentionDetail/detail/businessDetail.jsx

@@ -52,11 +52,29 @@ const BusinessDetail =React.createClass({
 					title: '联系人',
 					dataIndex: 'contacts',
 					key: 'contacts',
+					render:(text,record)=>{
+						return  <div>
+									{
+										!record.readOnly?
+										<span>{text}</span>:
+										<span>***</span>
+									}
+								</div>
+					}
 				},
 				{
 					title: '联系电话',
 					dataIndex: 'contactMobile',
 					key: 'contactMobile',
+					render:(text,record)=>{
+						return  <div>
+									{
+										!record.readOnly?
+										<span>{text}</span>:
+										<span>***</span>
+									}
+								</div>
+					}
 				}, {
 					title: '操作',
 					dataIndex: 'ooo',
@@ -127,7 +145,7 @@ const BusinessDetail =React.createClass({
 				pageNo: pageNo || 1,
 				pageSize: this.state.paginationst.pageSize,
 				uid: this.props.ids, //名称1
-				businessGlossoryId: this.state.businessGlossoryId,
+				businessProjectId:this.props.data.businessProjectId
 			},
 			success: function(data) {
 				let theArr = [];
@@ -139,6 +157,8 @@ const BusinessDetail =React.createClass({
 					for(let i = 0; i < data.data.list.length; i++) {
 						let thisdata = data.data.list[i];
 						theArr.push({
+							key:i,
+							readOnly:thisdata.readOnly,
 							followId: thisdata.followId,
 							followTime: thisdata.followTime,
 							identifyName: thisdata.identifyName,
@@ -177,7 +197,7 @@ const BusinessDetail =React.createClass({
 			crossDomain: false,
 			url: globalConfig.context + '/api/admin/customer/toUpdateBusiness',
 			data: {
-				businessId: e.businessId
+				businessId: e.businessId,
 			},
 			success: function(data) {
 				let thisData = data.data;
@@ -188,7 +208,7 @@ const BusinessDetail =React.createClass({
 					thisData = {};
 				};
 				this.setState({
-					businessGlossoryId: thisData.businessGlossoryId,
+					businessProjectName: thisData.businessProjectName,
 					identifyName: thisData.identifyName,
 					uid: thisData.uid,
 					businessId: thisData.businessId,
@@ -253,7 +273,7 @@ const BusinessDetail =React.createClass({
 				    					<FormItem className="half-item"
 					                            {...formItemLayout}
 					                            label="意向业务名称" >
-					                        <span>{getCompanyIntention(this.state.businessGlossoryId)}</span>
+					                        <span>{this.state.businessProjectName}</span>
 					                    </FormItem>
 					                    <FormItem className="half-item"
 					                            {...formItemLayout}

+ 1 - 0
js/component/manageCenter/customer/NEW/signCustomer/intentionDetail/detail/contactPerson.jsx

@@ -170,6 +170,7 @@ const ContactPerson = React.createClass({
 					for(let i = 0; i < data.data.length; i++) {
 						let thisdata = data.data[i];
 						theArr.push({
+							key:i,
 							id: thisdata.id,
 							name: thisdata.name,
 							mobile: thisdata.mobile,

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

@@ -64,20 +64,18 @@ const Visit = React.createClass({
 				title: '拜访说明',
 				dataIndex: 'result',
 				key: 'result'
-			}
-			,{
+			}, {
 				title: '操作',
 				dataIndex: 'ttt',
 				key: 'ttt',
 				render: (text, record, index) => {
 					return <div>
-                            {!record.readOnly?<Popconfirm title="是否删除?" onConfirm={(e)=>{this.visitDelet(record)}} okText="删除" cancelText="不删除">
+                            {!record.readOnly&&<Popconfirm title="是否删除?" onConfirm={(e)=>{this.visitDelet(record)}} okText="删除" cancelText="不删除">
 							    <Button style={{marginRight:'10px',color:'#ffffff',background:'#f00',border:'none'}} onClick={(e)=>{e.stopPropagation()}}>删除</Button>
-							</Popconfirm>:''}
+							</Popconfirm>}
                         </div>
 				}
-			}
-		],
+			}],
 		}
 	},
 	//拜访记录删除
@@ -147,9 +145,9 @@ const Visit = React.createClass({
 					this.state.paginations.current = data.data.pageNo;
 					this.state.paginations.total = data.data.totalCount;
 				};
-				if(data.data&&data.data.list&&!data.data.list.lenth){
-					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,
@@ -201,9 +199,11 @@ const Visit = React.createClass({
 	            	 />
 			    </Spin> 
 			    <VisitDetail 
+			    	categoryArr={this.props.categoryArr}
 			    	followData={this.state.followData}
 			    	visitModul={this.state.visitModul}
 			    	closeDesc={this.closeDesc}
+			    	mid={this.props.data.id}
 			    />
 			</div>	
 		)

+ 7 - 3
js/component/manageCenter/customer/NEW/signCustomer/intentionDetail/detail/visitDetail.jsx

@@ -66,9 +66,13 @@ const VisitDetail = React.createClass({
 					dataIndex: 'remarks',
 					key: 'remarks',
 					render: (text, record, index) => {
-						return <Input value={record.remarks} placeholder="跟进说明" 
-	                             onChange={(e) => { record.remarks = e.target.value; this.setState({ data: this.state.data }); }}
-	                             />
+						return <div>{!record.readOnly?
+									<Input value={record.remarks} placeholder="跟进说明"
+	                            	 onChange={(e) => { record.remarks = e.target.value; this.setState({ data: this.state.data }); }}
+	                           		  />:
+	                           		  <span title={text}>{text&&text.length>8?text.substr(0,8)+'…':text}</span>
+	                           		 }
+	                             </div>
 					}
 				}
 			],