瀏覽代碼

限定项目

dev01 9 月之前
父節點
當前提交
386accbf1e
共有 21 個文件被更改,包括 2210 次插入1040 次删除
  1. 22 0
      js/component/dataDic.js
  2. 7 2
      js/component/manageCenter/customer/NEW/intentionCustomer/followDetail.jsx
  3. 1 0
      js/component/manageCenter/customer/NEW/intentionCustomer/intentionCustomer.jsx
  4. 2 2
      js/component/manageCenter/customer/NEW/intentionCustomer/intentionDetail/detail/business.jsx
  5. 67 67
      js/component/manageCenter/customer/NEW/intentionCustomer/intentionDetail/detail/contactPerson.jsx
  6. 542 517
      js/component/manageCenter/customer/NEW/intentionCustomer/intentionDetail/detail/visit.jsx
  7. 162 161
      js/component/manageCenter/customer/NEW/intentionCustomer/intentionDetail/intentionDetail.jsx
  8. 773 0
      js/component/manageCenter/customer/NEW/intentionCustomer/limit.jsx
  9. 6 0
      js/component/manageCenter/customer/NEW/intentionCustomer/limit.less
  10. 325 97
      js/component/manageCenter/customer/NEW/query/detail.jsx
  11. 24 24
      js/component/manageCenter/customer/NEW/query/queryCutomer.jsx
  12. 1 2
      js/component/manageCenter/customer/NEW/signCustomer/followDetail.jsx
  13. 148 146
      js/component/manageCenter/customer/NEW/signCustomer/followDetail/addContact.jsx
  14. 35 10
      js/component/manageCenter/customer/NEW/signCustomer/signCustomer.jsx
  15. 9 0
      js/component/manageCenter/customer/content.jsx
  16. 19 0
      js/component/manageCenter/customer/managementFollow/followUpSummary/index.jsx
  17. 1 1
      js/component/manageCenter/customer/signcustomer/statistics.jsx
  18. 9 7
      js/component/manageCenter/order/orderNew/addService.jsx
  19. 55 2
      js/component/manageCenter/set/business/businessProject.jsx
  20. 1 1
      js/component/manageCenter/standard/stList/index.jsx
  21. 1 1
      package.json

+ 22 - 0
js/component/dataDic.js

@@ -1423,6 +1423,10 @@ module.exports = {
     //   value: "2",
     //   key: "外联客户",
     // },
+    {
+      value: "3",
+      key: "限定项目",
+    },
   ],
   //销售类型
   ssalesType: [
@@ -4067,6 +4071,24 @@ module.exports = {
     }, {
       value: 15,
       label: '领取为私有渠道',
+    }, {
+      value: 16,
+      label: '限定项目移除',
+    }, {
+      value: 17,
+      label: '限定项目转交',
+    }, {
+      value: 18,
+      label: '限定项目释放',
+    }, {
+      value: 19,
+      label: '限定项目签单释放',
+    }, {
+      value: 20,
+      label: '限定项目签单',
+    }, {
+      value: 21,
+      label: '领取为限定项目',
     }
   ],
   //消息提醒状态

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

@@ -321,7 +321,9 @@ const FollowDetail = React.createClass({
     $.ajax({
       method: "get",
       dataType: "json",
-      url: globalConfig.context + "/api/admin/customer/toAddFollowOnHistory",
+      url: globalConfig.context + this.props.isLimit
+        ? "/api/restrict/Project/getFollowDetails"
+        : "/api/admin/customer/toAddFollowOnHistory",
       data: {
         uid: e,
       },
@@ -443,6 +445,8 @@ const FollowDetail = React.createClass({
         contactType: this.state.contactType,
         result: this.state.result,
         followTime: this.state.followTime,
+        type: this.props.isLimit ? 1 : 0,
+        pid: this.props.isLimit ? this.props.details.pid : undefined,
       },
     }).done(
       function (data) {
@@ -502,7 +506,7 @@ const FollowDetail = React.createClass({
           maskClosable={false}
           className="customeDetails"
           footer=""
-          title="新增渠道跟进"
+          title="新增跟进"
           width="1200px"
           visible={this.state.visitModul}
           onOk={this.visitOk}
@@ -659,6 +663,7 @@ const FollowDetail = React.createClass({
           </Form>
         </Modal>
         <AddContact
+          isLimit={this.props.isLimit}
           addcontactModul={this.state.addcontactModul}
           uids={this.state.uids}
           closeFollow={this.closeFollow}

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

@@ -1213,6 +1213,7 @@ const IntentionCustomer = Form.create()(
             closeDesc={this.closeDesc}
           />
           <IntentionDetail
+            isLimit={this.props.isLimit}
             tabsKey={this.state.tabsKey}
             categoryArr={this.state.categoryArr}
             detailApi={this.props.detailApi}

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

@@ -44,7 +44,7 @@ const Business = React.createClass({
           }
         },
         {
-          title: "业务名",
+          title: "项目名称",
           dataIndex: "businessName",
           key: "businessName",
         },
@@ -84,7 +84,7 @@ const Business = React.createClass({
                   this.businessIntentionDetails(record);
                 }}
               >
-                查看
+                查看跟进记录
               </Button>
             );
           },

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

@@ -14,17 +14,17 @@ import AddContact from "../../../signCustomer/followDetail/addContact";
 const ContactPerson = React.createClass({
   getInitialState() {
     return {
-      major:0,
+      major: 0,
       loading: false,
-      addcontactModul:false,
-      enterpriseName:'',
+      addcontactModul: false,
+      enterpriseName: '',
       ContactsLists: [
         {
           title: "姓名",
           dataIndex: "name",
           key: "name",
           render: (text, record, index) => {
-            if(record.id) return <div>{text}</div>
+            if (record.id) return <div>{text}</div>
           }
         },
         {
@@ -32,7 +32,7 @@ const ContactPerson = React.createClass({
           dataIndex: "department",
           key: "department",
           render: (text, record, index) => {
-            if(record.id) return <div>{text}</div>
+            if (record.id) return <div>{text}</div>
           }
         },
         {
@@ -40,7 +40,7 @@ const ContactPerson = React.createClass({
           dataIndex: "position",
           key: "position",
           render: (text, record, index) => {
-            if(record.id) return <div>{text}</div>
+            if (record.id) return <div>{text}</div>
           }
         },
         {
@@ -57,7 +57,7 @@ const ContactPerson = React.createClass({
           dataIndex: "cityName",
           key: "cityName",
           render: (text, record, index) => {
-          if(record.id) return <div>{text}</div>
+            if (record.id) return <div>{text}</div>
           }
         },
         {
@@ -65,7 +65,7 @@ const ContactPerson = React.createClass({
           dataIndex: "mobile",
           key: "mobile",
           render: (text, record, index) => {
-            if(record.id) return <div>{text}</div>
+            if (record.id) return <div>{text}</div>
           }
         },
         {
@@ -73,7 +73,7 @@ const ContactPerson = React.createClass({
           dataIndex: "fixedTel",
           key: "fixedTel",
           render: (text, record, index) => {
-            if(record.id) return <div>{text}</div>
+            if (record.id) return <div>{text}</div>
           }
         },
         {
@@ -81,7 +81,7 @@ const ContactPerson = React.createClass({
           dataIndex: "wechat",
           key: "wechat",
           render: (text, record, index) => {
-            if(record.id) return <div>{text}</div>
+            if (record.id) return <div>{text}</div>
           }
         },
         {
@@ -89,7 +89,7 @@ const ContactPerson = React.createClass({
           dataIndex: "qq",
           key: "qq",
           render: (text, record, index) => {
-            if(record.id) return <div>{text}</div>
+            if (record.id) return <div>{text}</div>
           }
         },
         {
@@ -97,7 +97,7 @@ const ContactPerson = React.createClass({
           dataIndex: "email",
           key: "email",
           render: (text, record, index) => {
-            if(record.id) return <div>{text}</div>
+            if (record.id) return <div>{text}</div>
           }
         },
         {
@@ -105,7 +105,7 @@ const ContactPerson = React.createClass({
           dataIndex: "createTimes",
           key: "createTimes",
           render: (text, record, index) => {
-            if(record.id) return <div>{text}</div>
+            if (record.id) return <div>{text}</div>
           }
         },
         {
@@ -113,7 +113,7 @@ const ContactPerson = React.createClass({
           dataIndex: "aname",
           key: "aname",
           render: (text, record, index) => {
-            if(record.id) return <div>{text}</div>
+            if (record.id) return <div>{text}</div>
           }
         },
         {
@@ -123,7 +123,7 @@ const ContactPerson = React.createClass({
           render: (text, record, index) => {
             return (
               !this.props.isCustomerAdmin && <div>
-                {adminData.isSuperAdmin || !record.id? (
+                {adminData.isSuperAdmin || !record.id ? (
                   <Popconfirm
                     title="是否删除?"
                     onConfirm={e => {
@@ -146,7 +146,7 @@ const ContactPerson = React.createClass({
                 ) : (
                   ""
                 )}
-                {record.major!=1 ? (
+                {record.major != 1 ? (
                   <Button
                     style={{
                       marginRight: "10px",
@@ -185,7 +185,7 @@ const ContactPerson = React.createClass({
           ocbId: e.id //删除的ID
         }
       }).done(
-        function(data) {
+        function (data) {
           if (!data.error.length) {
             message.success("删除成功!");
             this.setState({
@@ -204,27 +204,27 @@ const ContactPerson = React.createClass({
   //选择主要联系人
   mainContact(record) {
     this.setState({
-    	loading: true
+      loading: true
     });
     $.ajax({
-    	method: "get",
-    	dataType: "json",
-    	crossDomain: false,
-    	url: globalConfig.context + "/api/admin/customer/updateMainContact",
-    	data: {
-    		uid:this.props.data.id,
-    		ocbId: record.id
-    	}
-    }).done(function(data) {
-    	if(!data.error.length) {
-    		message.success('设为主要联系人成功!');
-    		this.setState({
-    			loading: false,
-    		});
-    	} else {
-    		message.warning(data.error[0].message);
-    	};
-    	this.contactLists();
+      method: "get",
+      dataType: "json",
+      crossDomain: false,
+      url: globalConfig.context + "/api/admin/customer/updateMainContact",
+      data: {
+        uid: this.props.data.id,
+        ocbId: record.id
+      }
+    }).done(function (data) {
+      if (!data.error.length) {
+        message.success('设为主要联系人成功!');
+        this.setState({
+          loading: false,
+        });
+      } else {
+        message.warning(data.error[0].message);
+      };
+      this.contactLists();
     }.bind(this));
     this.state.contactList.forEach(item => {
       item.major = 0;
@@ -248,7 +248,7 @@ const ContactPerson = React.createClass({
       data: {
         uid: ids || 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) {
@@ -268,10 +268,10 @@ const ContactPerson = React.createClass({
               department: thisdata.department,
               position: thisdata.position,
               major: thisdata.major,
-              createTimes:thisdata.createTimes,
-              fixedTel:thisdata.fixedTel,
-              aname:thisdata.aname,
-              cityName:(thisdata.provinceName || '')+(thisdata.cityName || '')+(thisdata.areaName || '')
+              createTimes: thisdata.createTimes,
+              fixedTel: thisdata.fixedTel,
+              aname: thisdata.aname,
+              cityName: (thisdata.provinceName || '') + (thisdata.cityName || '') + (thisdata.areaName || '')
             });
           }
         }
@@ -280,7 +280,7 @@ const ContactPerson = React.createClass({
         });
       }.bind(this)
     }).always(
-      function() {
+      function () {
         this.setState({
           loading: false
         });
@@ -318,20 +318,20 @@ const ContactPerson = React.createClass({
               display: "inline-block",
             }}
           >
-            公司名称:{this.state.enterpriseName ? this.state.enterpriseName :  this.props.name}
+            公司名称:{this.state.enterpriseName ? this.state.enterpriseName : this.props.name}
             <EnterpriseNameChange
-                type={this.props.isCustomerAdmin ? 'journal' : 'modify'}
-                changeOtherInfor
-                style={{marginLeft:'20px'}}
-                enterpriseId={this.props.data.uid}
-                enterpriseName={this.props.name}
-                data={this.props.data}
-                onCancel={this.props.onCancel}
-                onChangeSuccess={(value)=>{
-                  this.setState({
-                    enterpriseName:value
-                  })
-            }}/>
+              type={this.props.isCustomerAdmin ? 'journal' : 'modify'}
+              changeOtherInfor
+              style={{ marginLeft: '20px' }}
+              enterpriseId={this.props.data.uid}
+              enterpriseName={this.props.name}
+              data={this.props.data}
+              onCancel={this.props.onCancel}
+              onChangeSuccess={(value) => {
+                this.setState({
+                  enterpriseName: value
+                })
+              }} />
           </span>
           {!this.props.isCustomerAdmin ? <Button
             className="ContactsList"
@@ -344,23 +344,23 @@ const ContactPerson = React.createClass({
         <div className="clearfix">
           <Spin spinning={this.state.loading}>
             <Table
-                pagination={false}
-                columns={this.state.ContactsLists}
-                dataSource={this.state.contactList}
+              pagination={false}
+              columns={this.state.ContactsLists}
+              dataSource={this.state.contactList}
             />
           </Spin>
         </div>
         {/* 新增联系人 */}
         <AddContact
-            addcontactModul={this.state.addcontactModul}
-            uids={this.props.data.id}
-            closeFollow={()=>{
-              this.setState({
-                addcontactModul:false
-              },()=>{
-                this.contactLists()
-              })
-            }}
+          addcontactModul={this.state.addcontactModul}
+          uids={this.props.data.id}
+          closeFollow={() => {
+            this.setState({
+              addcontactModul: false
+            }, () => {
+              this.contactLists()
+            })
+          }}
         />
       </div>
     );

File diff suppressed because it is too large
+ 542 - 517
js/component/manageCenter/customer/NEW/intentionCustomer/intentionDetail/detail/visit.jsx


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

@@ -11,167 +11,168 @@ import Business from './detail/business.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
-		}
-	},
-	detailsModal() {
-		this.setState({
-			basicState: false,
-			modalVisible: false
-		})
-		this.props.closeDesc(false, true)
-	},
-	//详情tab切换数据处理
-	callback(e) {
-		if (e == '1') {
-			this.setState({
-				IntentionState: true,
-				contactState: false,
-				accountState: false,
-				visitState: false,
-				businessState: false,
-				basicState: true
-			})
-		}
-		if (e == '2') {
-			this.setState({
-				IntentionState: false,
-				contactState: true,
-				accountState: false,
-				visitState: false,
-				businessState: false,
-				basicState: false
-			})
-		}
-		// if(e == '3') {
-		// 	this.setState({
-		// 		IntentionState:false,
-		// 		contactState:false,
-		// 		accountState:true,
-		// 		visitState:false,
-		// 		businessState:false,
-		// 		basicState:false
-		// 	})
-		// }
-		if (e == '4') {
-			this.setState({
-				IntentionState: false,
-				contactState: false,
-				accountState: false,
-				visitState: true,
-				businessState: false,
-				basicState: false
-			})
-		}
-		if (e == '5') {
-			this.setState({
-				IntentionState: false,
-				contactState: false,
-				accountState: false,
-				visitState: false,
-				businessState: true,
-				basicState: false
-			})
-		}
-		this.setState({
-			callnub: e,
-		})
-	},
-	//取消函数
-	closeDetail(e, s) {
-		this.setState({
-			basicState: false,
-			modalVisible: e,
-		})
-		if (s) {
-			this.props.closeDesc(false, true)
-		}
-	},
-	componentWillReceiveProps(nextProps) {
-		if (nextProps.modalVisible && nextProps.IntentionData.id) {
-			this.setState({
-				modalVisible: true,
-				callnub: this.props.isCustomerAdmin ? '2' : (nextProps.isGuidanceLv ? (nextProps.tabsKey ? nextProps.tabsKey : "4") : (nextProps.tabsKey ? nextProps.tabsKey : (nextProps.detailApi.indexOf('Organization')) > 0 ? "2" : '1')),
-			})
-		};
-		this.setState({
-			basicState: nextProps.basicState,
-			contactState: nextProps.contactState,
-		})
-	},
-	render() {
-		return (
-			<div>
-				{this.state.modalVisible ? <Modal
-					className="customeDetails"
-					title="意向客户详情"
-					width='92%'
-					visible={this.state.modalVisible}
-					onOk={this.detailsModal}
-					onCancel={this.detailsModal}
-					footer=''
-				>
-					<Tabs onChange={this.callback} activeKey={this.state.callnub}>
-						{this.props.isGuidanceLv || 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}
-								/>
+  getInitialState() {
+    return {
+      modalVisible: false,
+      switchState: false,
+      contactData: [],
+      contactState: true,
+      IntentionState: false,
+      businessState: false,
+      visitState: false,
+      accountState: false,
+      basicState: false
+    }
+  },
+  detailsModal() {
+    this.setState({
+      basicState: false,
+      modalVisible: false
+    })
+    this.props.closeDesc(false, true)
+  },
+  //详情tab切换数据处理
+  callback(e) {
+    if (e == '1') {
+      this.setState({
+        IntentionState: true,
+        contactState: false,
+        accountState: false,
+        visitState: false,
+        businessState: false,
+        basicState: true
+      })
+    }
+    if (e == '2') {
+      this.setState({
+        IntentionState: false,
+        contactState: true,
+        accountState: false,
+        visitState: false,
+        businessState: false,
+        basicState: false
+      })
+    }
+    // if(e == '3') {
+    // 	this.setState({
+    // 		IntentionState:false,
+    // 		contactState:false,
+    // 		accountState:true,
+    // 		visitState:false,
+    // 		businessState:false,
+    // 		basicState:false
+    // 	})
+    // }
+    if (e == '4') {
+      this.setState({
+        IntentionState: false,
+        contactState: false,
+        accountState: false,
+        visitState: true,
+        businessState: false,
+        basicState: false
+      })
+    }
+    if (e == '5') {
+      this.setState({
+        IntentionState: false,
+        contactState: false,
+        accountState: false,
+        visitState: false,
+        businessState: true,
+        basicState: false
+      })
+    }
+    this.setState({
+      callnub: e,
+    })
+  },
+  //取消函数
+  closeDetail(e, s) {
+    this.setState({
+      basicState: false,
+      modalVisible: e,
+    })
+    if (s) {
+      this.props.closeDesc(false, true)
+    }
+  },
+  componentWillReceiveProps(nextProps) {
+    if (nextProps.modalVisible && nextProps.IntentionData.id) {
+      this.setState({
+        modalVisible: true,
+        callnub: this.props.isCustomerAdmin ? '2' : (nextProps.isGuidanceLv ? (nextProps.tabsKey ? nextProps.tabsKey : "4") : (nextProps.tabsKey ? nextProps.tabsKey : (nextProps.detailApi.indexOf('Organization')) > 0 ? "2" : '1')),
+      })
+    };
+    this.setState({
+      basicState: nextProps.basicState,
+      contactState: nextProps.contactState,
+    })
+  },
+  render() {
+    return (
+      <div>
+        {this.state.modalVisible ? <Modal
+          className="customeDetails"
+          title="意向客户详情"
+          width='92%'
+          visible={this.state.modalVisible}
+          onOk={this.detailsModal}
+          onCancel={this.detailsModal}
+          footer=''
+        >
+          <Tabs onChange={this.callback} activeKey={this.state.callnub}>
+            {this.props.isGuidanceLv || 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>}
-						{!this.props.isGuidanceLv || this.props.isCustomerAdmin ? <TabPane tab="企业&联系人详情" key="2">
-							<ContactPerson
-								isCustomerAdmin={this.props.isCustomerAdmin}
-								closeDetail={this.closeDetail}
-								name={this.props.name}
-								data={this.props.IntentionData}
-								contactState={this.state.contactState}
-								onCancel={this.detailsModal}
-							/>
-						</TabPane> : ""}
-						{/* {!this.props.isGuidanceLv ? <TabPane tab="账户信息" key="3">*/}
-						{/*	<Account*/}
-						{/*		 isGuidanceLv={this.props.isGuidanceLv}  //用于判断是否为跟进管理页面*/}
-						{/*		 closeDetail={this.closeDetail}*/}
-						{/*         data={this.props.IntentionData}*/}
-						{/*         accountState={this.state.accountState}*/}
-						{/*	/>*/}
-						{/*</TabPane>: ""}*/}
-						<TabPane tab="客户跟进" key="4">
-							<Visit
-								isGuidanceLv={this.props.isGuidanceLv}
-								isEditGuidanceLv={this.props.isEditGuidanceLv}
-								categoryArr={this.props.categoryArr}
-								closeDetail={this.closeDetail}
-								data={this.props.IntentionData}
-								visitState={this.state.visitState}
-							/>
-						</TabPane>
-						<TabPane tab="业务意向" key="5">
-							<Business
-								closeDetail={this.closeDetail}
-								data={this.props.IntentionData}
-								businessState={this.state.businessState}
-							/>
-						</TabPane>
-					</Tabs>
-				</Modal> : <div />}
-			</div>
-		)
-	}
+              </TabPane>}
+            {!this.props.isGuidanceLv || this.props.isCustomerAdmin ? <TabPane tab="企业&联系人详情" key="2">
+              <ContactPerson
+                isCustomerAdmin={this.props.isCustomerAdmin}
+                closeDetail={this.closeDetail}
+                name={this.props.name}
+                data={this.props.IntentionData}
+                contactState={this.state.contactState}
+                onCancel={this.detailsModal}
+              />
+            </TabPane> : ""}
+            {/* {!this.props.isGuidanceLv ? <TabPane tab="账户信息" key="3">*/}
+            {/*	<Account*/}
+            {/*		 isGuidanceLv={this.props.isGuidanceLv}  //用于判断是否为跟进管理页面*/}
+            {/*		 closeDetail={this.closeDetail}*/}
+            {/*         data={this.props.IntentionData}*/}
+            {/*         accountState={this.state.accountState}*/}
+            {/*	/>*/}
+            {/*</TabPane>: ""}*/}
+            <TabPane tab="客户跟进" key="4">
+              <Visit
+                isLimit={this.props.isLimit}
+                isGuidanceLv={this.props.isGuidanceLv}
+                isEditGuidanceLv={this.props.isEditGuidanceLv}
+                categoryArr={this.props.categoryArr}
+                closeDetail={this.closeDetail}
+                data={this.props.IntentionData}
+                visitState={this.state.visitState}
+              />
+            </TabPane>
+            <TabPane tab="业务意向" key="5">
+              <Business
+                closeDetail={this.closeDetail}
+                data={this.props.IntentionData}
+                businessState={this.state.businessState}
+              />
+            </TabPane>
+          </Tabs>
+        </Modal> : <div />}
+      </div>
+    )
+  }
 })
 export default IntentionDetail;

+ 773 - 0
js/component/manageCenter/customer/NEW/intentionCustomer/limit.jsx

@@ -0,0 +1,773 @@
+import React from "react";
+import $ from "jquery/src/ajax";
+import moment from "moment";
+import {
+  Button,
+  Form,
+  Input,
+  Spin,
+  Table,
+  Select,
+  message,
+  Tabs,
+  DatePicker,
+  AutoComplete,
+  Modal,
+  Tooltip,
+  Tag,
+} from "antd";
+import { ChooseList } from "../../../order/orderNew/chooseList";
+import { ShowModal, } from "@/tools.js"
+import { accountType, accountStatus } from "@/dataDic";
+import ZhuanjiaoDetail from "@/zhuanjiaoDetail.jsx";
+import IntentionDetail from "./intentionDetail/intentionDetail";
+import ShowModalDiv from "@/showModal.jsx";
+import FollowDetail from "./followDetail"
+import './limit.less';
+
+const FormItem = Form.Item;
+const { RangePicker } = DatePicker;
+const { TabPane } = Tabs;
+
+const LimitedProject = React.createClass({
+
+  getInitialState() {
+    return {
+      searchValues: {
+        type: ''
+      }, // 列表筛选条件
+      loading: false, //加载动画
+      changeList: undefined, // 更改后的表格显示数据
+      dataSource: [], // 列表数据
+      pagination: {
+        defaultCurrent: 1,
+        defaultPageSize: 10,
+        showQuickJumper: true,
+        pageSize: 10,
+        onChange: function (page) {
+          this.loadData(page);
+        }.bind(this),
+        showTotal: function (total) {
+          return "共" + total + "条数据";
+        },
+      },
+      columns: [
+        {
+          title: "客户名称",
+          dataIndex: "name",
+          key: "name",
+          width: 300,
+          render: (text, record) => {
+            return (
+              <span>
+                <span>{text}</span>
+              </span>
+            );
+          },
+        },
+        {
+          title: "限定项目名称",
+          dataIndex: "projectName",
+          key: "projectName",
+          render: (text, record) => {
+            return (
+              <div>
+                {text}
+              </div>
+            );
+          },
+        },
+        {
+          title: "项目状态",
+          dataIndex: "type",
+          key: "type",
+          render: (text, record) => {
+            return (
+              <div>
+                {['公共', '私有', '签单'][text]}
+              </div>
+            );
+          },
+        },
+        {
+          title: "客户所属",
+          dataIndex: "userAdmin",
+          key: "userAdmin",
+          render: (text, record) => {
+            return (
+              <div>
+                {text}
+              </div>
+            );
+          },
+        },
+        {
+          title: "项目所属",
+          dataIndex: "adminName",
+          key: "adminName",
+          render: (text, record) => {
+            return (
+              <div>
+                {text}
+              </div>
+            );
+          },
+        },
+        // {
+        //   title: "项目初始时间",
+        //   dataIndex: "lockTime",
+        //   key: "lockTime",
+        //   render: (text, record) => {
+        //     return (
+        //       <div>
+        //         {text}
+        //       </div>
+        //     );
+        //   },
+        // },
+        {
+          title: "剩余私有天数",
+          dataIndex: "privateDays",
+          key: "privateDays",
+          render: (text, record) => {
+            return (
+              <div>
+                {record.type == 1
+                  ? text : record.type == 2
+                    ? record.signDays : ""}
+              </div>
+            );
+          },
+        },
+        {
+          title: "最新跟进时间",
+          dataIndex: "lockTime",
+          key: "lockTime",
+          render: (text, record) => {
+            return (
+              <div>
+                {text}
+              </div>
+            );
+          },
+        },
+        {
+          title: "操作",
+          dataIndex: "op",
+          key: "op",
+          render: (text, record) => {
+            return (
+              <div>
+                <Button
+                  style={{ marginLeft: 10 }}
+                  type="primary"
+                  onClick={(e) => {
+                    e.stopPropagation();
+                    let obj = {
+                      id: record.id
+                    }
+                    this.setState({
+                      visitModuls: true,
+                      followData: obj,
+                      RowData: record,
+                    })
+                  }}
+                >
+                  跟进限定项目
+                </Button>
+              </div>
+            );
+          },
+        },
+      ],
+      customerArr: [],
+      selectedRowKeys: [],
+      zhuanjiaoVisible: false,
+      categoryArr: [],
+      followData:{}
+    };
+  },
+
+  componentWillMount() {
+    this.loadData();
+    this.category();
+  },
+
+  // 列表接口
+  loadData(pageNo) {
+    const { searchValues, pagination } = this.state;
+    this.setState({
+      loading: true,
+    });
+    let datas = Object.assign(searchValues, {
+      pageNo: pageNo || 1,
+      pageSize: pagination.pageSize,
+    });
+    $.ajax({
+      method: "get",
+      dataType: "json",
+      crossDomain: false,
+      url: globalConfig.context + "/api/restrict/Project/pageList",
+      data: datas,
+      success: function (data) {
+        ShowModal(this);
+        this.setState({
+          loading: false,
+        });
+        let theArr = [];
+        if (data.error && data.error.length === 0) {
+          if (data.data) {
+            pagination.current = data.data.pageNo;
+            pagination.total = data.data.totalCount;
+            if (data.data && data.data.list && !data.data.list.length) {
+              pagination.current = 0
+              pagination.total = 0
+            };
+            for (var i = 0; i < data.data.list.length; i++) {
+              let thisdata = data.data.list[i];
+              let diqu =
+                (thisdata.province == null ? "" : thisdata.province) +
+                (thisdata.city == null ? "" : "-" + thisdata.city) +
+                (thisdata.area == null ? "" : "-" + thisdata.area);
+              thisdata.opId = thisdata.id;
+              thisdata.id = thisdata.uid;
+              thisdata.locationProvince = diqu;
+              theArr.push(thisdata);
+            }
+            this.setState({
+              dataSource: theArr,
+              pagination: this.state.pagination,
+              pageNo: data.data.pageNo,
+            });
+          }
+        } else {
+          message.warning(data.error[0].message);
+        }
+      }.bind(this),
+    }).always(
+      function () {
+        this.setState({
+          loading: false,
+        });
+      }.bind(this)
+    );
+  },
+  // 搜索
+  search() {
+    this.loadData();
+  },
+  // 重置
+  reset() {
+    this.setState({
+      searchValues: {
+        type: ''
+      },
+    }, () => {
+      this.loadData();
+    })
+  },
+
+  changeList(arr) {
+    const newArr = [];
+    this.state.columns.forEach((item) => {
+      arr.forEach((val) => {
+        if (val === item.title) {
+          newArr.push(item);
+        }
+      });
+    });
+    this.setState({
+      changeList: newArr,
+    });
+  },
+
+  supervisor(e) {
+    $.ajax({
+      method: "get",
+      dataType: "json",
+      crossDomain: false,
+      url: globalConfig.context + "/api/admin/customer/listAdminByName",
+      data: {
+        adminName: e,
+      },
+      success: function (data) {
+        let thedata = data.data;
+        if (!thedata) {
+          if (data.error && data.error.length) {
+            message.warning(data.error[0].message);
+          }
+          thedata = {};
+        }
+        this.setState({
+          customerArr: thedata,
+        });
+      }.bind(this),
+    }).always(
+      function () {
+        this.setState({
+          loading: false,
+        });
+      }.bind(this)
+    );
+  },
+
+  selectAuto(value, options) {
+    this.setState({
+      auto: value,
+    });
+  },
+
+  blurChange(e) {
+    let theType = "";
+    let contactLists = this.state.customerArr || [];
+    if (e) {
+      contactLists.map(function (item) {
+        if (item.name == e.toString()) {
+          theType = item.id;
+        }
+      });
+    }
+    this.setState({
+      theTypes: theType,
+    });
+  },
+
+  httpChange(e) {
+    if (e.length >= 1) {
+      this.supervisor(e);
+    }
+    this.setState({
+      auto: e,
+    });
+  },
+
+  showConfirm() {
+    let _this = this;
+    Modal.confirm({
+      title: "提示",
+      content: (
+        <span style={{ color: "red" }}>
+          确定要转交以下项目吗?
+          {this.state.selectedRows.map((value, index) => (
+            <div key={index} style={{ marginTop: "5px", color: "#000" }}>
+              {value.projectName}
+            </div>
+          ))}
+        </span>
+      ),
+      onOk() {
+        _this.changeAssigner(1)
+      },
+      onCancel() { },
+    });
+  },
+
+  showConfirms() {
+    let _this = this;
+    Modal.confirm({
+      title: "您确定将以下项目移至公共项目吗?",
+      content: (
+        <span style={{ color: "red" }}>
+          移除后,以下项目将被别人领取!
+          {this.state.selectedRows.map((value, index) => (
+            <div key={index} style={{ marginTop: "5px", color: "#000" }}>
+              {value.projectName}
+            </div>
+          ))}
+        </span>
+      ),
+      onOk() {
+        _this.changeAssigner(0);
+      },
+      onCancel() { },
+    });
+  },
+
+  changeAssigner(type) {
+    const _this = this;
+    if (type == 1 && !this.state.theTypes) {
+      message.warning("请输入转交人姓名");
+      return
+    }
+    let changeIds = "";
+    for (let idx = 0; idx < this.state.selectedRows.length; idx++) {
+      let rowItem = this.state.selectedRows[idx];
+      if (rowItem.opId) {
+        changeIds =
+          this.state.selectedRows.length - 1 === idx
+            ? changeIds + rowItem.opId
+            : changeIds + rowItem.opId + ",";
+      }
+    }
+    let loading = message.loading("加载中...");
+    $.ajax({
+      method: "post",
+      dataType: "json",
+      crossDomain: false,
+      url: globalConfig.context + "/api/restrict/Project/update",
+      data: {
+        id: changeIds,
+        type,
+        takeAid: type == 1 ? this.state.theTypes : undefined,
+      },
+    }).done(
+      function (data) {
+        loading();
+        this.setState({
+          selList: [],
+        })
+        if (!data.error.length) {
+          this.setState({
+            auto: "",
+            loading: false,
+            selectedRowKeys: [],
+          });
+          if (data.data == 1) {
+            message.success(type == 1 ? "转交成功!" : "移除成功!");
+            _this.loadData();
+          } else {
+            data.data.forEach(function (e) { message.warning(e) })
+          }
+        } else {
+          message.warning(data.error[0].message);
+        }
+      }.bind(this)
+    );
+  },
+
+  zhuanjiaoDetail(record) {
+    this.setState({
+      zhuanjiaoVisible: true,
+      zhuanjiaoId: record.id,
+    });
+  },
+
+  zhuanjiaoDetailCancel() {
+    this.setState({
+      zhuanjiaoVisible: false,
+    });
+  },
+
+  tableRowClick(record, index) {
+    this.state.visitModul = false;
+    this.setState({
+      // selectedRowKeys: [],
+      modalVisible: true,
+      basicState: true,
+      contactState: true,
+      modalName: record.name,
+      RowData: record,
+    });
+  },
+
+  closeDesc(e, s) {
+    this.state.basicState = e;
+    this.state.visitModul = e;
+    this.state.modalVisible = e;
+    this.state.visitModuls = e;
+    this.state.showDesc = e;
+    this.setState({
+      tabsKey: "",
+    });
+    if (s) {
+      this.loadData(this.state.ispage);
+    }
+  },
+  //品类数据获取
+  category() {
+    $.ajax({
+      method: "get",
+      dataType: "json",
+      crossDomain: false,
+      url: globalConfig.context + "/api/admin/Varieties/getSuperList",
+      data: {},
+      success: function (data) {
+        let thedata = data.data;
+        let theArr = [];
+        if (!thedata) {
+          if (data.error && data.error.length) {
+            message.warning(data.error[0].message);
+          }
+        } else {
+          thedata.map(function (item, index) {
+            theArr.push({
+              value: item.id,
+              key: item.cname,
+            });
+          });
+        }
+        this.setState({
+          categoryArr: theArr,
+        });
+      }.bind(this),
+    });
+  },
+  //查看跟进记录列表
+  loadVisit(pageNo) {
+    this.setState({
+      loading: true
+    });
+    $.ajax({
+      method: "get",
+      dataType: "json",
+      crossDomain: false,
+      url: globalConfig.context + '/api/admin/customer/listFollowHistory',
+      data: {
+        pageNo: pageNo || 1,
+        pageSize: this.state.paginations.pageSize,
+        uid: this.state.RowData.id, //名称1
+      },
+      success: function (data) {
+        let theArr = [];
+        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++) {
+            let thisdata = data.data.list[i];
+            theArr.push(thisdata);
+          };
+          this.state.paginations.current = data.data.pageNo;
+          this.state.paginations.total = data.data.totalCount;
+          this.setState({
+            ispage: data.data.pageNo
+          })
+        };
+        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 () {
+      this.setState({
+        loading: false
+      });
+    }.bind(this));
+  },
+
+  render() {
+    const { searchValues, } = this.state
+    const rowSelection = {
+      hideDefaultSelections: true,
+      selectedRowKeys: this.state.selectedRowKeys,
+      onChange: (selectedRowKeys, selectedRows) => {
+        this.setState({
+          modalVisible: false,
+          selectedRows: selectedRows,
+          selectedRowKeys: selectedRowKeys,
+        });
+      },
+      onSelect: (recordt, selected, selectedRows) => {
+        this.setState({
+          modalVisible: false,
+          recordt: recordt.opId,
+        });
+      },
+    };
+    const hasSelected = this.state.selectedRowKeys.length > 0;
+    const dataSources = this.state.customerArr || [];
+    const options = dataSources.map((group) => (
+      <Select.Option key={group.id} value={group.name}>
+        {group.name}
+      </Select.Option>
+    ));
+    return (
+      <div className="user-content">
+        <ShowModalDiv ShowModal={this.state.showModal} />
+        <div className="content-title" style={{ marginBottom: 10 }}>
+          <span style={{ fontWeight: 900, fontSize: 16 }}>限定项目</span>
+        </div>
+        <Tabs defaultActiveKey="1" className="test">
+          <TabPane tab="搜索" key="1">
+            <div className="user-search" style={{ marginLeft: 10 }}>
+              <Input
+                placeholder="客户名称"
+                value={searchValues["userName"]
+                  ? searchValues["userName"]
+                  : ""}
+                onChange={(e) => {
+                  searchValues["userName"] = e.target.value;
+                  this.setState({
+                    searchValues: searchValues,
+                  });
+                }}
+              />
+              <Input
+                placeholder="请输入限定项目全称"
+                value={searchValues["projectName"]
+                  ? searchValues["projectName"]
+                  : ""}
+                onChange={(e) => {
+                  searchValues["projectName"] = e.target.value;
+                  this.setState({
+                    searchValues: searchValues,
+                  });
+                }}
+              />
+              <Select
+                style={{ width: 140 }}
+                placeholder=""
+                value={searchValues["type"]}
+                onChange={(e) => {
+                  searchValues["type"] = e;
+                  this.setState({
+                    searchValues: searchValues,
+                  });
+                }}
+              >
+                <Option value="">全部</Option>
+                <Option value="1">私有</Option>
+                <Option value="2">已签</Option>
+              </Select>
+              <span>时间:</span>
+              <RangePicker
+                style={{ width: 300 }}
+                value={[
+                  searchValues.startTime ? moment(searchValues.startTime) : null,
+                  searchValues.endTime ? moment(searchValues.endTime) : null,
+                ]}
+                onChange={(data, dataString) => {
+                  this.setState({
+                    searchValues: Object.assign(searchValues, {
+                      startTime: dataString[0],
+                      endTime: dataString[1],
+                    }),
+                  });
+                }}
+              />
+              <Button
+                type="primary"
+                onClick={this.search}
+                style={{ margin: "0 10px" }}
+              >搜索</Button>
+              <Button onClick={this.reset}>重置</Button>
+            </div>
+          </TabPane>
+          <TabPane tab="操作" key="2">
+            <div className="user-search" style={{ marginLeft: 10 }}>
+              <AutoComplete
+                className="certain-category-search"
+                dropdownClassName="certain-category-search-dropdown"
+                dropdownMatchSelectWidth={false}
+                style={{ width: "120px" }}
+                dataSource={options}
+                placeholder="输入转交人姓名"
+                value={this.state.auto}
+                onChange={this.httpChange}
+                filterOption={true}
+                onBlur={this.blurChange}
+                onSelect={this.selectAuto}
+                disabled={!hasSelected}
+              >
+                <Input />
+              </AutoComplete>
+              <Button
+                type="primary"
+                onClick={(e) => {
+                  e.stopPropagation();
+                  this.showConfirm();
+                }}
+                disabled={!hasSelected}
+                style={{ marginRight: 10 }}
+              >
+                转交
+              </Button>
+              <Button
+                style={{ marginLeft: 10 }}
+                onClick={(e) => {
+                  e.stopPropagation();
+                  this.showConfirms();
+                }}
+                type="primary"
+                disabled={!hasSelected}
+              >
+                移除项目
+              </Button>
+              <Button
+                style={{ marginLeft: 10 }}
+                onClick={(e) => {
+                  e.stopPropagation();
+                  this.zhuanjiaoDetail(this.state.selectedRows[0]);
+                }}
+                type="primary"
+                disabled={!hasSelected || this.state.selectedRows.length > 1}
+              >
+                项目日志
+              </Button>
+            </div>
+          </TabPane>
+          <TabPane tab="更改表格显示数据" key="3">
+            <div style={{ marginLeft: 10 }}>
+              <ChooseList
+                columns={this.state.columns}
+                changeFn={this.changeList}
+                changeList={this.state.changeList}
+                top={55}
+                margin={11}
+              />
+            </div>
+          </TabPane>
+        </Tabs>
+        <div className="patent-table">
+          <Spin spinning={this.state.loading}>
+            <Table
+              size="middle"
+              bordered
+              columns={
+                this.state.changeList == undefined
+                  ? this.state.columns
+                  : this.state.changeList
+              }
+              dataSource={this.state.dataSource}
+              rowSelection={rowSelection}
+              pagination={this.state.pagination}
+              onRowDoubleClick={this.tableRowClick}
+            />
+          </Spin>
+        </div>
+        {
+          this.state.zhuanjiaoVisible &&
+          <ZhuanjiaoDetail
+            cancel={this.zhuanjiaoDetailCancel}
+            visible={this.state.zhuanjiaoVisible}
+            id={this.state.zhuanjiaoId}
+          />
+        }
+        {
+          this.state.modalVisible &&
+          <IntentionDetail
+            isLimit={true}
+            isCustomerAdmin={true}
+            tabsKey={this.state.tabsKey}
+            categoryArr={this.state.categoryArr}
+            detailApi={'/api/admin/customer/findOrganizationCustomerDetail'}
+            IntentionData={this.state.RowData}
+            modalVisible={this.state.modalVisible}
+            name={this.state.modalName}
+            closeDesc={this.closeDesc}
+            basicState={this.state.basicState}
+            contactState={this.state.contactState}
+          />
+        }
+        {
+          <FollowDetail
+            isLimit={true}
+            details={this.state.RowData}
+            categoryArr={this.state.categoryArr}
+            followData={this.state.followData}
+            visitModul={this.state.visitModuls}
+            closeDesc={this.closeDesc}
+            loadData={this.loadVisit}
+          />
+        }
+      </div>
+    );
+  },
+});
+
+export default LimitedProject;

+ 6 - 0
js/component/manageCenter/customer/NEW/intentionCustomer/limit.less

@@ -0,0 +1,6 @@
+.ant-table-thead>tr.ant-table-row-hover>td,
+.ant-table-tbody>tr.ant-table-row-hover>td,
+.ant-table-thead>tr:hover>td,
+.ant-table-tbody>tr:hover>td {
+  background: rgba(70, 101, 191, .3);
+}

+ 325 - 97
js/component/manageCenter/customer/NEW/query/detail.jsx

@@ -1,104 +1,332 @@
 import React from 'react';
-import { Table, Spin, message, Modal } from 'antd';
+import { Form, Table, Spin, message, Modal, Button, Select } from 'antd';
 import ajax from 'jquery/src/ajax/xhr.js';
 import $ from 'jquery/src/ajax';
 
 const Detail = React.createClass({
-	loadData(data, apiUrl) {
-		this.setState({
-			loading: true,
-		});
-		$.ajax({
-			method: "get",
-			dataType: "json",
-			crossDomain: false,
-			url: globalConfig.context + apiUrl,
-			data: {
-				uid: data.id,
-			},
-			success: function(data) {
-				let listArr = [];
-				let thedata = data.data;
-				if(!thedata) {
-					if(data.error && data.error.length) {
-						message.warning(data.error[0].message);
-					};
-					thedata = {};
-					return;
-				};
-				for(let i = 0; i < data.data.length; i++) {
-					let thisdata = data.data[i];
-					listArr.push({
-						id: thisdata.id,
-						businessProjectName: thisdata.businessProjectName,
-						salesmanName: thisdata.salesmanName,
-						lockTime: thisdata.lockTime && thisdata.lockTime.split(' ')[0],
-					});
-				};
-				this.setState({
-					dataSource: listArr,
-				});
-			}.bind(this),
-		}).always(function() {
-			this.setState({
-				loading: false
-			});
-		}.bind(this));
-	},
-	getInitialState() {
-		return {
-			loading: false,
-			dataSource: [],
-			columns: [{
-					title: '业务名称',
-					dataIndex: 'businessProjectName',
-					key: 'businessProjectName',
-				}, {
-					title: '签单时间',
-					dataIndex: 'lockTime',
-					key: 'lockTime',
-				},
-				{
-					title: '营销员',
-					dataIndex: 'salesmanName',
-					key: 'salesmanName',
-				}
-			],
-		}
-	},
-	visitCancel() {
-		this.setState({
-			visitModul: false
-		})
-		this.props.closeDesc(false);
-	},
-	componentWillReceiveProps(nextProps) {
-		if(nextProps.visitModul) {
-			this.setState({
-				visitModul: true
-			})
-			this.loadData(nextProps.data, nextProps.detailApi);
-		}
-	},
-	render() {
-		return(
-			<Modal	
-			      className="customeDetails"
-			      footer=''
-		          title="已签业务"
-		          width='800px'
-		          visible={this.state.visitModul}
-		          onOk={this.visitCancel}
-				  onCancel={this.visitCancel}							          							          
-			        >		
-                    <Spin spinning={this.state.loading}>
-                        <Table size="middle" columns={this.state.columns}
-                            dataSource={this.state.dataSource}    
-                            pagination={false} 
-                           />
-                    </Spin>
-			</Modal>
-		)
-	}
+  getInitialState() {
+    return {
+      visible: false,
+      loading: false,
+      dataSource: [],
+      gdataSource: [],
+      columns: [
+        {
+          title: '业务名称',
+          dataIndex: 'businessProjectName',
+          key: 'businessProjectName',
+        },
+        {
+          title: '签单时间',
+          dataIndex: 'lockTime',
+          key: 'lockTime',
+        },
+        {
+          title: '营销员',
+          dataIndex: 'salesmanName',
+          key: 'salesmanName',
+        }
+      ],
+      gcolumns: [
+        {
+          title: '限定项目',
+          dataIndex: 'projectName',
+          key: 'projectName',
+        },
+        {
+          title: '状态',
+          dataIndex: 'type',
+          key: 'type',
+          render: (text) =>
+            <span>
+              {["公共", "私有", "签单"][text]}
+            </span>
+        },
+        {
+          title: '营销员',
+          dataIndex: 'adminName',
+          key: 'adminName',
+        },
+        {
+          title: '操作',
+          dataIndex: 'op',
+          key: 'op',
+          render: (text, record) =>
+            (record.type == 0 && this.props.data.shareType == 2) &&
+            <Button
+              type="primary"
+              onClick={() => {
+                this.setState({
+                  visible: true,
+                  pid: record.pid,
+                  pName: record.projectName,
+                })
+              }}
+            >
+              领取
+            </Button>
+        },
+      ],
+      followList: [
+        { key: "已发项目介绍资料", value: 0 },
+        { key: "已约面谈", value: 1 },
+        { key: "已发合同计划书", value: 2 },
+        { key: "已报价", value: 3 },
+        { key: "已发合同", value: 4 },
+        { key: "已签合同", value: 5 },
+        { key: "面谈中", value: 6 },
+        { key: "已面签", value: 7 },
+        { key: "无进度", value: 8 },
+      ],
+      customerList: [
+        { key: "新客户", value: 0 },
+        { key: "意向客户", value: 1 },
+        { key: "重点客户", value: 2 },
+        { key: "面谈客户", value: 3 },
+        { key: "签单客户", value: 4 },
+        { key: "被拒客户", value: 5 },
+        { key: "停止跟进", value: 6 },
+      ],
+      followSituation: 6,
+      customerStatus: 4,
+    }
+  },
+
+
+  loadData(data, apiUrl) {
+    this.setState({
+      loading: true,
+    });
+    $.ajax({
+      method: "get",
+      dataType: "json",
+      crossDomain: false,
+      url: globalConfig.context + apiUrl,
+      data: {
+        uid: data.id,
+      },
+      success: function (data) {
+        let listArr = [];
+        let thedata = data.data;
+        if (!thedata) {
+          if (data.error && data.error.length) {
+            message.warning(data.error[0].message);
+          };
+          thedata = {};
+          return;
+        };
+        for (let i = 0; i < data.data.length; i++) {
+          let thisdata = data.data[i];
+          listArr.push({
+            id: thisdata.id,
+            businessProjectName: thisdata.businessProjectName,
+            salesmanName: thisdata.salesmanName,
+            lockTime: thisdata.lockTime && thisdata.lockTime.split(' ')[0],
+          });
+        };
+        this.setState({
+          dataSource: listArr,
+        });
+      }.bind(this),
+    }).always(function () {
+      this.setState({
+        loading: false
+      });
+    }.bind(this));
+  },
+
+  gloadData(id) {
+    this.setState({
+      loading: true,
+    });
+    $.ajax({
+      method: "get",
+      dataType: "json",
+      crossDomain: false,
+      url: globalConfig.context + '/api/restrict/Project/list',
+      data: {
+        uid: id,
+      },
+      success: function (data) {
+        let thedata = data.data;
+        if (!thedata) {
+          if (data.error && data.error.length) {
+            message.warning(data.error[0].message);
+          };
+        } else {
+          this.setState({
+            gdataSource: thedata
+          })
+        }
+      }.bind(this),
+    }).always(function () {
+      this.setState({
+        loading: false
+      });
+    }.bind(this));
+  },
+
+  visitCancel() {
+    this.setState({
+      visitModul: false
+    })
+    this.props.closeDesc(false);
+  },
+
+  add() {
+    if (!this.state.followSituation && this.state.followSituation != 0) {
+      message.warning("请选择跟进进度!")
+      return
+    }
+    if (!this.state.customerStatus && this.state.customerStatus != 0) {
+      message.warning("请选择客户状态!")
+      return
+    }
+    this.setState({
+      loading: true,
+    });
+    $.ajax({
+      method: "post",
+      dataType: "json",
+      crossDomain: false,
+      url: globalConfig.context + "/api/restrict/Project/add",
+      data: {
+        pid: this.state.pid,
+        uid: this.state.uid,
+        followSituation: this.state.followSituation,
+        customerStatus: this.state.customerStatus,
+      },
+      success: function (data) {
+        if (data.error && data.error.length) {
+          message.warning(data.error[0].message);
+        } else {
+          Modal.success({
+            title: '领取成功!',
+            content: (
+              <div>
+                本次领取的项目为
+                <span style={{ color: "red" }}>【{this.state.pName}】</span>
+                ,请在我的“客户管理-限定项目列表“查看
+              </div>),
+          });
+          this.setState({
+            visible: false,
+            followSituation: 6,
+            customerStatus: 4,
+          })
+          this.gloadData(this.state.uid)
+        }
+      }.bind(this),
+    }).always(
+      function () {
+        this.setState({
+          loading: false,
+        });
+      }.bind(this)
+    );
+  },
+
+  componentWillReceiveProps(nextProps) {
+    if (nextProps.visitModul) {
+      this.setState({
+        visitModul: true,
+        uid: nextProps.data.id,
+      })
+      this.loadData(nextProps.data, nextProps.detailApi);
+      this.gloadData(nextProps.data.id)
+    }
+  },
+
+
+  render() {
+    const FormItem = Form.Item
+    return (
+      <Modal
+        className="customeDetails"
+        footer=''
+        title=""
+        width='800px'
+        visible={this.state.visitModul}
+        onOk={this.visitCancel}
+        onCancel={this.visitCancel}
+      >
+        <Spin spinning={this.state.loading}>
+          <div style={{ fontSize: "16px", fontWeight: "bold" }}>限定项目</div>
+          <Table
+            size="middle"
+            columns={this.state.gcolumns}
+            dataSource={this.state.gdataSource}
+            pagination={false}
+          />
+          <div style={{ marginTop: 50, fontSize: "16px", fontWeight: "bold" }}>已签业务</div>
+          <Table
+            size="middle"
+            columns={this.state.columns}
+            dataSource={this.state.dataSource}
+            pagination={false}
+          />
+        </Spin>
+        <Modal
+          title="领取限定项目"
+          visible={this.state.visible}
+          onOk={this.add}
+          onCancel={() => {
+            this.setState({
+              visible: false,
+              followSituation: 6,
+              customerStatus: 4,
+            })
+          }}
+        >
+          <FormItem
+            labelCol={{ span: 8 }}
+            wrapperCol={{ span: 10 }}
+            label="跟进进度"
+          >
+            <Select
+              placeholder="跟进进度"
+              value={this.state.followSituation}
+              style={{ width: 200 }}
+              onChange={(e) => {
+                this.setState({ followSituation: e });
+              }}
+            >
+              {this.state.followList.map(function (item) {
+                return (
+                  <Select.Option key={item.value} value={item.value}>
+                    {item.key}
+                  </Select.Option>
+                );
+              })}
+            </Select>
+          </FormItem>
+
+          <FormItem
+            labelCol={{ span: 8 }}
+            wrapperCol={{ span: 10 }}
+            label="客户状态"
+          >
+            <Select
+              placeholder="客户状态"
+              value={this.state.customerStatus}
+              style={{ width: 200 }}
+              onChange={(e) => {
+                this.setState({ customerStatus: e });
+              }}
+            >
+              {this.state.customerList.map(function (item) {
+                return (
+                  <Select.Option key={item.value} value={item.value}>
+                    {item.key}
+                  </Select.Option>
+                );
+              })}
+            </Select>
+          </FormItem>
+
+        </Modal>
+      </Modal>
+    )
+  }
 })
 export default Detail;

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

@@ -479,31 +479,31 @@ const QueryCustomer = React.createClass({
                 }}
               />
               {/* <Select placeholder="选择部门"
-                            style={{ width: 150 ,marginRight:'10px',marginLeft:'10px'}}
-                            value={this.state.departmenttSearch}
-                            onChange={(e) => { this.setState({ departmenttSearch: e }) }}>
-                            {
-                                departmentArr.map(function (item) {
-                                        return <Select.Option key={item.id} >{item.name}</Select.Option>
-                                })
-                            }
-                    </Select>   */}
+                style={{ width: 150, marginRight: '10px', marginLeft: '10px' }}
+                value={this.state.departmenttSearch}
+                onChange={(e) => { this.setState({ departmenttSearch: e }) }}>
+                {
+                  departmentArr.map(function (item) {
+                    return <Select.Option key={item.id} >{item.name}</Select.Option>
+                  })
+                }
+              </Select> */}
               {/* <AutoComplete
-				        className="certain-category-search"
-				        dropdownClassName="certain-category-search-dropdown"
-				        dropdownMatchSelectWidth={false}
-				        dropdownStyle={{ width: 120 }}
-				        style={{ width: '120px'}}
-				        dataSource={options}
-				        placeholder="客户所有人姓名"
-				        value={this.state.auto}
-				        onChange={this.httpChange}
-				        filterOption={true}
-				        onBlur={this.blurChange}
-				        onSelect={this.selectAuto}
-				    >
-				        <Input />
-				    </AutoComplete>   */}
+                className="certain-category-search"
+                dropdownClassName="certain-category-search-dropdown"
+                dropdownMatchSelectWidth={false}
+                dropdownStyle={{ width: 120 }}
+                style={{ width: '120px' }}
+                dataSource={options}
+                placeholder="客户所有人姓名"
+                value={this.state.auto}
+                onChange={this.httpChange}
+                filterOption={true}
+                onBlur={this.blurChange}
+                onSelect={this.selectAuto}
+              >
+                <Input />
+              </AutoComplete> */}
               <Button type="primary" onClick={this.search}>搜索</Button>
               <Button onClick={this.reset}>重置</Button>
             </div>

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

@@ -102,12 +102,11 @@ const FollowDetail = React.createClass({
     });
   },
   visitCancel(e) {
-    console.log('00')
     this.setState({
       addcontactModul: false,
       visitModul: false
     });
-    // this.props.closeDesc(false, false)
+    this.props.closeDesc(false, false)
   },
   //获取联系人下拉框
   getNewWoman(ids) {

+ 148 - 146
js/component/manageCenter/customer/NEW/signCustomer/followDetail/addContact.jsx

@@ -1,105 +1,108 @@
 import React from 'react';
-import {Modal, message, layout, Spin, Input, Button, Form, Row, Col, Radio, Select} from 'antd';
+import { Modal, message, layout, Spin, Input, Button, Form, Row, Col, Radio, Select } from 'antd';
 import ajax from 'jquery/src/ajax/xhr.js';
 import $ from 'jquery/src/ajax';
-const FormItem =Form.Item;
+const FormItem = Form.Item;
 
 const AddContact = React.createClass({
-	getInitialState() {
-		return {
-			addcontactModul: false,
-            major:0,
-		}
-	},
-	addcontactModulOK() {
-		this.setState({
-			addcontactModul: false
-		})
-		this.props.closeFollow(true, true)
-	},
-	addcontactModulcancel() {
-		this.setState({
-			addcontactModul: false
-		})
-		this.props.closeFollow(false, false)
-	},
-	//新增联系人保存函数
-	submitcontactman(e) {
-		e.preventDefault();
-		if (/.*[\u4e00-\u9fa5]+.*$/.test(this.state.newname)) {
-		} else {
-			message.error("请填写正确的姓名,且至少包含一个汉字");
-			return ;
-		};
-		if(this.state.newmobile.length!=11){
-			message.error('请填写正确的手机号码');
-		  return
-		}
-		if (/.*[\u4e00-\u9fa5]+.*$/.test(this.state.newdepatrment)) {
-		} else {
-			message.error("请填写正确的部门,且至少包含一个汉字");
-			return;
-		};
-		if (/.*[\u4e00-\u9fa5]+.*$/.test(this.state.newposition)) {
-		} else {
-			message.error("请填写正确的职位,且至少包含一个汉字");
-			return;
-		};
-		this.setState({
-			loading: true
-		})
-		$.ajax({
-			method: "post",
-			dataType: "json",
-			crossDomain: false,
-			url: globalConfig.context + "/api/admin/customer/addOneContact",
-			data: {
-				uid: this.state.uid,
-				name: this.state.newname,
-				mobile: this.state.newmobile,
-				email: this.state.newemail,
-                fixedTel:this.state.fixedTelModal,
-                major: this.state.major,
-				wechat: this.state.newwechat,
-				department: this.state.newdepatrment,
-				position: this.state.newposition,
-				sex: this.state.newsex,
-				qq: this.state.newqq
-			},
-			success: function(data) {
-				if(!data.error.length) {
-                    message.success('添加成功')
-					this.addcontactModulOK()
-					this.setState({
-						loading: false,
-					})
-				} else {
-					message.warning(data.error[0].message);
-				};
-			}.bind(this)
-		});
-	},
-	componentWillReceiveProps(nextProps) {
-		if(nextProps.addcontactModul && nextProps.uids) {
-			this.setState({
-				newsex: undefined,
-				newname: '',
-				newmobile: '',
-				newwechat: '',
-				newqq: '',
-				newdepatrment: '',
-				newposition: '',
-				newemail: '',
-                fixedTelModal:'',
-                major:0,
-				addcontactModul: true,
-				uid: nextProps.uids,
-				loading:false
-			})
-		};
-	},
-	render() {
-		return (
+  getInitialState() {
+    return {
+      addcontactModul: false,
+      major: 0,
+    }
+  },
+  addcontactModulOK() {
+    this.setState({
+      addcontactModul: false
+    })
+    this.props.closeFollow(true, true)
+  },
+  addcontactModulcancel() {
+    this.setState({
+      addcontactModul: false
+    })
+    this.props.closeFollow(false, false)
+  },
+  //新增联系人保存函数
+  submitcontactman(e) {
+    e.preventDefault();
+    if (/.*[\u4e00-\u9fa5]+.*$/.test(this.state.newname)) {
+    } else {
+      message.error("请填写正确的姓名,且至少包含一个汉字");
+      return;
+    };
+    if (this.state.newmobile.length != 11) {
+      message.error('请填写正确的手机号码');
+      return
+    }
+    if (/.*[\u4e00-\u9fa5]+.*$/.test(this.state.newdepatrment)) {
+    } else {
+      message.error("请填写正确的部门,且至少包含一个汉字");
+      return;
+    };
+    if (/.*[\u4e00-\u9fa5]+.*$/.test(this.state.newposition)) {
+    } else {
+      message.error("请填写正确的职位,且至少包含一个汉字");
+      return;
+    };
+    this.setState({
+      loading: true
+    })
+    $.ajax({
+      method: "post",
+      dataType: "json",
+      crossDomain: false,
+      url: globalConfig.context + "/api/admin/customer/addOneContact",
+      data: {
+        uid: this.state.uid,
+        name: this.state.newname,
+        mobile: this.state.newmobile,
+        email: this.state.newemail,
+        fixedTel: this.state.fixedTelModal,
+        major: this.state.major,
+        wechat: this.state.newwechat,
+        department: this.state.newdepatrment,
+        position: this.state.newposition,
+        sex: this.state.newsex,
+        qq: this.state.newqq
+      },
+      success: function (data) {
+        if (!data.error.length) {
+          message.success('添加成功')
+          this.addcontactModulOK()
+          this.setState({
+            loading: false,
+          })
+        } else {
+          message.warning(data.error[0].message);
+        };
+      }.bind(this)
+    });
+  },
+  componentWillReceiveProps(nextProps) {
+    if (nextProps.addcontactModul && nextProps.uids) {
+      this.setState({
+        newsex: undefined,
+        newname: '',
+        newmobile: '',
+        newwechat: '',
+        newqq: '',
+        newdepatrment: '',
+        newposition: '',
+        newemail: '',
+        fixedTelModal: '',
+        major: 0,
+        addcontactModul: true,
+        uid: nextProps.uids,
+        loading: false
+      })
+    };
+  },
+  render() {
+    const maList = !this.props.isLimit
+      ? [<Select.Option value={1}>是</Select.Option>, <Select.Option value={0}>否</Select.Option>]
+      : [<Select.Option value={0}>否</Select.Option>]
+    return (
       <div>
         <Modal
           maskClosable={false}
@@ -141,32 +144,32 @@ const AddContact = React.createClass({
                   />
                 </Col>
               </Row>
-                <Row style={{ marginTop: "20px", paddingLeft: "50px" }}>
-                    <Col span={2}>
-                        <span style={{ color: "red" }}>*</span>部门:
-                    </Col>
-                    <Col span={8}>
-                        <Input
-                            value={this.state.newdepatrment}
-                            required="required"
-                            onChange={(e) => {
-                                this.setState({ newdepatrment: e.target.value });
-                            }}
-                        />
-                    </Col>
-                    <Col span={2} style={{ marginLeft: "50px" }}>
-                        <span style={{ color: "red" }}>*</span>职位:
-                    </Col>
-                    <Col span={8}>
-                        <Input
-                            value={this.state.newposition}
-                            required="required"
-                            onChange={(e) => {
-                                this.setState({ newposition: e.target.value });
-                            }}
-                        />
-                    </Col>
-                </Row>
+              <Row style={{ marginTop: "20px", paddingLeft: "50px" }}>
+                <Col span={2}>
+                  <span style={{ color: "red" }}>*</span>部门:
+                </Col>
+                <Col span={8}>
+                  <Input
+                    value={this.state.newdepatrment}
+                    required="required"
+                    onChange={(e) => {
+                      this.setState({ newdepatrment: e.target.value });
+                    }}
+                  />
+                </Col>
+                <Col span={2} style={{ marginLeft: "50px" }}>
+                  <span style={{ color: "red" }}>*</span>职位:
+                </Col>
+                <Col span={8}>
+                  <Input
+                    value={this.state.newposition}
+                    required="required"
+                    onChange={(e) => {
+                      this.setState({ newposition: e.target.value });
+                    }}
+                  />
+                </Col>
+              </Row>
               <Row style={{ marginTop: "20px", paddingLeft: "50px" }}>
                 <Col span={2}>微信:</Col>
                 <Col span={8}>
@@ -189,39 +192,38 @@ const AddContact = React.createClass({
                   />
                 </Col>
               </Row>
-            <Row style={{ marginTop: '20px',paddingLeft:'50px' }}>
+              <Row style={{ marginTop: '20px', paddingLeft: '50px' }}>
                 <Col span={2}>邮箱:</Col>
                 <Col span={8}>
-                    <Input
-                        onChange={(e) => { this.setState({ newemail: e.target.value }) }} />
+                  <Input
+                    onChange={(e) => { this.setState({ newemail: e.target.value }) }} />
                 </Col>
                 <Col span={2} style={{ marginLeft: '50px' }}>座机:</Col>
                 <Col span={8}>
-                    <Input
-                        onChange={(e) => { this.setState({ fixedTelModal: e.target.value }) }} />
+                  <Input
+                    onChange={(e) => { this.setState({ fixedTelModal: e.target.value }) }} />
                 </Col>
-            </Row>
-            <Row style={{ marginTop: '20px',paddingLeft:'50px' }}>
-                <Col span={2}><span style={{whiteSpace:'nowrap',marginLeft:'-36px'}}>主要联系人:</span></Col>
+              </Row>
+              <Row style={{ marginTop: '20px', paddingLeft: '50px' }}>
+                <Col span={2}><span style={{ whiteSpace: 'nowrap', marginLeft: '-36px' }}>主要联系人:</span></Col>
                 <Col span={8}>
-                    <Select value={this.state.major} onChange={(e) => { this.setState({ major: e }) }}>
-                        <Select.Option value={1}>是</Select.Option>
-                        <Select.Option value={0}>否</Select.Option>
-                    </Select>
+                  <Select value={this.state.major} onChange={(e) => { this.setState({ major: e }) }}>
+                    {maList}
+                  </Select>
                 </Col>
                 <Col span={2} style={{ marginLeft: "50px" }}><span>性别:</span></Col>
                 <Col span={8}>
-                    <Radio.Group
-                        value={this.state.newsex}
-                        onChange={(e) => {
-                            this.setState({ newsex: e.target.value });
-                        }}
-                    >
-                        <Radio value="男">男</Radio>
-                        <Radio value="女">女</Radio>
-                    </Radio.Group>
+                  <Radio.Group
+                    value={this.state.newsex}
+                    onChange={(e) => {
+                      this.setState({ newsex: e.target.value });
+                    }}
+                  >
+                    <Radio value="男">男</Radio>
+                    <Radio value="女">女</Radio>
+                  </Radio.Group>
                 </Col>
-            </Row>
+              </Row>
               <Row
                 style={{
                   marginTop: "20px",
@@ -252,6 +254,6 @@ const AddContact = React.createClass({
         </Modal>
       </div>
     );
-	}
+  }
 })
 export default AddContact;

+ 35 - 10
js/component/manageCenter/customer/NEW/signCustomer/signCustomer.jsx

@@ -28,6 +28,7 @@ import IntentionDetail from './intentionDetail/intentionDetail'
 import './customer.less';
 import { ChooseList } from "../../../order/orderNew/chooseList";
 import EnterpriseNameChange from "../../../../common/enterpriseNameChange";
+import Detaile from "../query/detail";
 
 const { TabPane } = Tabs
 const confirm = Modal.confirm;
@@ -178,16 +179,16 @@ const IntentionCustomer = Form.create()(React.createClass({
           dataIndex: "transferTime",
           key: "transferTime",
         },
-        // {
-        //   title: "最新跟进日期",
-        //   dataIndex: "lastFollowTime",
-        //   key: "lastFollowTime",
-        // },
-        // {
-        //   title: "剩余私有天数",
-        //   dataIndex: "surplusFollowTime",
-        //   key: "surplusFollowTime",
-        // },
+        {
+          title: "最新跟进日期",
+          dataIndex: "lastFollowTime",
+          key: "lastFollowTime",
+        },
+        {
+          title: "剩余私有天数",
+          dataIndex: "surplusFollowTime",
+          key: "surplusFollowTime",
+        },
         // {
         //   title: "剩余签单天数",
         //   dataIndex: "surplusSignTime",
@@ -215,6 +216,7 @@ const IntentionCustomer = Form.create()(React.createClass({
           title: "操作",
           dataIndex: "abc",
           key: "abc",
+          width: 420,
           render: (text, record, index) => {
             return (
               <div>
@@ -264,6 +266,19 @@ const IntentionCustomer = Form.create()(React.createClass({
                 >
                   转交项目
                 </Button>
+                <Button
+                  style={{ marginLeft: 10 }}
+                  type="primary"
+                  onClick={(e) => {
+                    e.stopPropagation();
+                    this.setState({
+                      visitD: true,
+                      RowData: record,
+                    })
+                  }}
+                >
+                  新增限定项目
+                </Button>
               </div>
             );
           },
@@ -348,6 +363,7 @@ const IntentionCustomer = Form.create()(React.createClass({
     this.loadData();
   },
   closeDesc(e, s) {
+    this.state.visitD = e
     this.state.basicState = e
     this.state.visitModul = e;
     this.state.modalVisible = e;
@@ -618,6 +634,7 @@ const IntentionCustomer = Form.create()(React.createClass({
         )}
         <div className="content-title" style={{ marginBottom: 10 }}>
           <span style={{ fontWeight: 900, fontSize: 16 }}>{!intentionState ? "签单客户" : "签单客户"}</span>
+          <span style={{ color: "red", float: "right" }}>注:签单客户,30天未跟进,将自动释放至公共库!!!</span>
         </div>
         <Tabs defaultActiveKey="1" className="test">
           <TabPane tab="搜索" key="1">
@@ -820,6 +837,14 @@ const IntentionCustomer = Form.create()(React.createClass({
             </Checkbox.Group>
           </div>
         </Modal>}
+
+        <Detaile
+          visitModul={this.state.visitD}
+          data={this.state.RowData}
+          detailApi='/api/admin/customer/getLockedProject'
+          closeDesc={this.closeDesc}
+        />
+
       </div>
     );
   }

+ 9 - 0
js/component/manageCenter/customer/content.jsx

@@ -397,6 +397,15 @@ class Content extends Component {
           });
         });
         break;
+      // 限定项目
+      case 'limit':
+        require.ensure([], () => {
+          const Limit = require('./NEW/intentionCustomer/limit').default;
+          this.setState({
+            component: <Limit  />
+          });
+        });
+        break;
       //客户跟进汇总(看所有人的)
       case 'followUpSummaryAdmin':
         require.ensure([], () => {

+ 19 - 0
js/component/manageCenter/customer/managementFollow/followUpSummary/index.jsx

@@ -78,11 +78,29 @@ class FollowUpSummary extends Component {
           },
         },
         {
+          title: "限定项目名称",
+          dataIndex: "projectName",
+          key: "projectName",
+          width: 160,
+        },
+        {
           title: "跟进人",
           dataIndex: "followName",
           key: "followName",
         },
         {
+          title: "跟进类型",
+          dataIndex: "type",
+          key: "type",
+          render: (text, record) => {
+            return (
+              <div>
+                {["客户跟进", "限定项目跟进"][text]}
+              </div>
+            );
+          },
+        },
+        {
           title: "跟进部门",
           dataIndex: "followDep",
           key: "followDep",
@@ -486,6 +504,7 @@ class FollowUpSummary extends Component {
                     <Select.Option value={2}>公共客户</Select.Option>
                     <Select.Option value={3}>签单客户</Select.Option>
                     <Select.Option value={4}>外联客户</Select.Option>
+                    <Select.Option value={5}>限定项目客户</Select.Option>
                   </Select>
                 </Form.Item>
                 <Form.Item>

+ 1 - 1
js/component/manageCenter/customer/signcustomer/statistics.jsx

@@ -436,7 +436,7 @@ class SignStatistics extends Component {
   closeDesc() {
     this.setState({
       showDetail: false,
-      params: {},
+      // params: {},
     });
     this.loadData(this.state.pageNo);
   }

+ 9 - 7
js/component/manageCenter/order/orderNew/addService.jsx

@@ -5952,14 +5952,16 @@ const NewService = Form.create()(
                         >
                           {(this.state.userType == "0"
                             ? ssalesType : this.state.userType == "1"
-                              ? qsalesType : []).map(function (item) {
-                                return (
-                                  <Select.Option key={item.value} disabled={item.value == "5"}>
-                                    {item.key}
-                                  </Select.Option>
-                                );
-                              })}
+                              ? qsalesType : this.state.userType == "3"
+                                ? qsalesType : []).map(function (item) {
+                                  return (
+                                    <Select.Option key={item.value} disabled={item.value == "5"}>
+                                      {item.key}
+                                    </Select.Option>
+                                  );
+                                })}
                         </Select>
+                        <span className="mandatory">*</span>
                       </FormItem>
                       {
                         (this.state.selectSales == "4" || this.state.selectSales == "5") &&

+ 55 - 2
js/component/manageCenter/set/business/businessProject.jsx

@@ -105,6 +105,7 @@ const BusinessProject = Form.create()(React.createClass({
         district: dis, //区
         activityFlag: this.state.activityFlag, //活动生效标识
         status: this.state.status, //项目状态
+        restrictStatus: this.state.selrestrictStatus, //是否限定项目
         type: this.state.type,
       },
       success: function (data) {
@@ -147,6 +148,7 @@ const BusinessProject = Form.create()(React.createClass({
               activityPrice: thisdata.activityPrice, //活动价
               activityFlag: thisdata.activityFlag, //活动生效标识
               status: thisdata.status, //项目状态
+              restrictStatus: thisdata.restrictStatus, // 是否限定项目
               type: thisdata.type,
               arrProvinceCity: ProvinceCity,
             });
@@ -308,6 +310,16 @@ const BusinessProject = Form.create()(React.createClass({
           key: "bname",
         },
         {
+          title: "是否限定项目",
+          dataIndex: "restrictStatus",
+          key: "restrictStatus",
+          render: (text) => {
+            return (
+              <span>{["否", "是"][text]}</span>
+            );
+          },
+        },
+        {
           title: "业务品类",
           dataIndex: "cname",
           key: "cname",
@@ -515,6 +527,7 @@ const BusinessProject = Form.create()(React.createClass({
             status: this.state.editStatus,//项目状态
             patentTransfer: this.state.typeStatus == 1 ? this.state.patentTransfer : undefined,
             type: this.state.typeStatus,//项目分类
+            restrictStatus: this.state.restrictStatus, // 是否限定项目
             country: isCountry,//是否全国
             province: pro ? pro : '',//省
             city: city ? city : '',//市
@@ -617,6 +630,7 @@ const BusinessProject = Form.create()(React.createClass({
             editName: thisdata.bname,//项目名称
             editCname: thisdata.cname,//项目分类
             editCid: thisdata.cid,//项目分类
+            restrictStatus: thisdata.restrictStatus,//是否限定项目
             editCountry: thisdata.country,//是否全国
             editProvince: thisdata.province,//省
             editCity: thisdata.city,//市
@@ -667,7 +681,8 @@ const BusinessProject = Form.create()(React.createClass({
           editId: thisdata.id, //每一条记录的ID
           editName: thisdata.bname, //项目名称
           editCname: thisdata.cname, //项目分类
-          editCid: thisdata.cid, //项目分类
+          restrictStatus: thisdata.restrictStatus,//是否限定项目
+          editCid: thisdata.cid,
           editCountry: thisdata.country, //是否全国
           editProvince: thisdata.province, //省
           editCity: thisdata.city, //市
@@ -1062,12 +1077,13 @@ const BusinessProject = Form.create()(React.createClass({
   },
   //搜索部分的清零
   reset() {
-    this.state.bname = '';//项目名称清零
+    this.state.bname = undefined;//项目名称清零
     this.state.cid = undefined;//品类名称清零
     this.state.ressSearch = undefined;//省市区清零
     this.state.activityFlag = undefined;//活动生效清零
     this.state.status = undefined;//项目状态清零
     this.state.type = undefined;//项目分类清零
+    this.state.selrestrictStatus = undefined;//是否限定项目
     this.loadData();
   },
   //新增部分的清零
@@ -1171,6 +1187,17 @@ const BusinessProject = Form.create()(React.createClass({
                 >
                   {this.state.contactsOption}
                 </Select>
+                <Select
+                  placeholder="是否限定项目"
+                  style={{ width: "200px", marginRight: "10px" }}
+                  value={this.state.selrestrictStatus}
+                  onChange={(e) => {
+                    this.setState({ selrestrictStatus: e });
+                  }}
+                >
+                  <Select.Option value={0} >否</Select.Option>
+                  <Select.Option value={1} >是</Select.Option>
+                </Select>
                 <Button
                   type="primary"
                   onClick={this.search}
@@ -2265,6 +2292,32 @@ const BusinessProject = Form.create()(React.createClass({
                           className="half-item"
                           labelCol={{ span: 4 }}
                           wrapperCol={{ span: 12 }}
+                          label="是否限定项目"
+                        >
+                          <Select
+                            placeholder="是否限定项目"
+                            value={this.state.restrictStatus}
+                            style={{ width: "94%" }}
+                            onChange={(e) => {
+                              this.setState({ restrictStatus: e });
+                            }}
+                          >
+                            {[
+                              { key: "否", value: 0 },
+                              { key: "是", value: 1 },
+                            ].map(function (item) {
+                              return (
+                                <Select.Option key={item.value} value={item.value}>
+                                  {item.key}
+                                </Select.Option>
+                              );
+                            })}
+                          </Select>
+                        </FormItem>
+                        <FormItem
+                          className="half-item"
+                          labelCol={{ span: 4 }}
+                          wrapperCol={{ span: 12 }}
                           label="创建时间"
                         >
                           <span style={{ width: "94%" }}>

+ 1 - 1
js/component/manageCenter/standard/stList/index.jsx

@@ -719,7 +719,7 @@ const Standard = Form.create()(React.createClass({
                       dropdownMatchSelectWidth={false}
                       style={{ width: 230 }}
                       dataSource={options}
-                      placeholder="营销员名称"
+                      placeholder="负责人名称"
                       value={this.state.adminName}
                       onChange={this.followUp.bind(this)}
                       filterOption={true}

+ 1 - 1
package.json

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