liting2017 7 years ago
parent
commit
8225ba72f5

File diff suppressed because it is too large
+ 1911 - 1888
js/component/manageCenter/customer/customerData/companyCustomer.jsx


File diff suppressed because it is too large
+ 1807 - 1794
js/component/manageCenter/customer/customerData/myClient.jsx


+ 4 - 3
js/component/manageCenter/customer/customerService/myBusiness.jsx

@@ -54,10 +54,11 @@ const MyBusiness = Form.create()(React.createClass({
                             adminName:thisdata.adminName,
                    			createTime:thisdata.createTime			                
                         });
-                    };  
+                    }; 
+                    this.state.pagination.current = data.data.pageNo;
+               	    this.state.pagination.total = data.data.totalCount;
                 };
-                 this.state.pagination.current = data.data.pageNo?data.data.pageNo:'0';
-                this.state.pagination.total = data.data.totalCount?data.data.totalCount:'0';
+                
                 this.setState({
                     dataSource: theArr,
                     pagination: this.state.pagination

+ 3 - 3
js/component/manageCenter/customer/customerService/serviceQuery.jsx

@@ -52,10 +52,10 @@ const ServiceQuery= Form.create()(React.createClass({
                    			createTime:thisdata.createTime			                
                         });
                     };
-                    
+                    this.state.pagination.current = data.data.pageNo;
+                    this.state.pagination.total = data.data.totalCount;
                 };
-                this.state.pagination.current = data.data.pageNo?data.data.pageNo:'0';
-                this.state.pagination.total = data.data.totalCount?data.data.totalCount:'0';
+               
                 this.setState({
                     dataSource: theArr,
                     pagination: this.state.pagination

+ 193 - 123
js/component/manageCenter/customer/individualCustomer/individualCustomer.jsx

@@ -8,10 +8,11 @@ import { citySelect,provinceList,areaSelect} from '../../../NewDicProvinceList';
 const { Column, ColumnGroup } = Table;
 const TabPane = Tabs.TabPane;
 import  CustomerDetail from './myClientDesc.jsx';
-import {socialAttribute,industry,newFollow,lvl,currentMember,cityArr, statuslist,customerStatus,intentionalService,sex} from '../../../dataDic.js';
-import {getCompanyIntention,getSocialAttribute ,getStatuslist,getIndustry,getContactType,getfllowSituation,beforeUploadFile,getWhether,getcityArr,getcustomerStatue,getfllowSituationOn,getCertification,getcustomerTyp,getLvl,getCurrentMember,getprovince} from '../../../tools.js';
+import {socialAttribute,industry,newFollow,auditStatusL,lvl,currentMember,cityArr, statuslist,customerStatus,intentionalService,sex} from '../../../dataDic.js';
+import {getCompanyIntention,splitUrl,getAuditStatus,getSocialAttribute ,getStatuslist,getIndustry,getContactType,getfllowSituation,beforeUploadFile,getWhether,getcityArr,getcustomerStatue,getfllowSituationOn,getCertification,getcustomerTyp,getLvl,getCurrentMember,getprovince} from '../../../tools.js';
 const monthFormat = 'YYYY/MM';
 //图片组件
+
 const PicturesWall = React.createClass({
     getInitialState() {
         return {
@@ -48,7 +49,7 @@ const PicturesWall = React.createClass({
         return (
             <div style={{display:"inline-block"}}>
                 <Upload
-                    action={globalConfig.context + "/api/admin/customer/attachmentUpload"}
+                    action={globalConfig.context + "/api/admin/customer/uploadCustomerImg"}
                     data={{ 'sign': this.props.pictureSign }}
                     listType="picture-card"
                     fileList={fileList}
@@ -84,8 +85,8 @@ const IndividualCustomer = Form.create()(React.createClass({
                 //area: this.state.addressSearch?this.state.addressSearch[2].value:'',
                 status:this.state.statusSearch,
                 industry:this.state.industrySearch,
-                serviceCertification:this.state.serviceCertificationSearch,
-			    userCertification: this.state.userCertificationSearch,
+                businessAudit:this.state.serviceCertificationSearch,
+			    auditStatus: this.state.userCertificationSearch,
               	currentMemberStatus:this.state.currentMemberStatusSearch,
 				lvl:this.state.lvlSearch,
 				listed:this.state.listedSearch,  //是否上市
@@ -117,8 +118,8 @@ const IndividualCustomer = Form.create()(React.createClass({
                             contactMobile:thisdata.contactMobile,
                             industry:thisdata.industry,
                             createTime:thisdata.createTime,
-                            serviceCertification:thisdata.serviceCertification,
-                            userCertification:thisdata.userCertification, 
+                            businessAudit:thisdata.businessAudit,
+                            auditStatus:thisdata.auditStatus, 
                             lvl:thisdata.lvl,
                             isMember:thisdata.isMember,
                             societyTag:thisdata.societyTag,
@@ -130,12 +131,13 @@ const IndividualCustomer = Form.create()(React.createClass({
                             celebrity:thisdata.celebrity,
                             highTechZone:thisdata.highTechZone,
                             locationProvince:thisdata.province?thisdata.province+'-'+thisdata.city||''+'-'+thisdata.area :'--'                       						                
+                        	
                         });
                     };  
-                   
+                    this.state.pagination.current = data.data.pageNo;
+              		this.state.pagination.total = data.data.totalCount;
                 }; 
-                this.state.pagination.current = data.data.pageNo?data.data.pageNo:'0';
-                this.state.pagination.total = data.data.totalCount?data.data.totalCount:'0';
+                
                 this.setState({
                     dataSource: theArr,
                     pagination: this.state.pagination
@@ -534,15 +536,15 @@ const IndividualCustomer = Form.create()(React.createClass({
                 },
                  {
                     title: '业务认证',
-                    dataIndex: 'serviceCertification',
-                    key: 'serviceCertification',
+                    dataIndex: 'businessAudit',
+                    key: 'businessAudit',
                     render: text => { return getCertification(text) }
                  },
                 {
                     title: '实名认证',
-                    dataIndex: 'userCertification',
-                    key: 'userCertification',
-                    render: text => { return getCertification(text) }
+                    dataIndex: 'auditStatus',
+                    key: 'auditStatus',
+                    render: text => { return getAuditStatus(text) }
                 },
                 {
                     title: '是否专家',
@@ -1186,7 +1188,16 @@ const IndividualCustomer = Form.create()(React.createClass({
                         introduction:this.state.introduction,
                         positiveIdUrl:thecompanyLogoUrl,
                         oppositeIdUrl:thecompanyLogoUrls,
-                        headPortraitUrl:theorgCodeUrl,    
+                        headPortraitUrl:theorgCodeUrl,
+                        
+                        investment:this.state.investment,
+                        professionalTitle:this.state.professionalTitle,
+                        workUnit:this.state.workUnit,
+                        education:this.state.education,
+                        majorCategory:this.state.majorCategory,
+                        qualification:this.state.qualification,
+                        businessAudit:this.state.businessAudit,
+                        auditStatus:this.state.auditStatus, 
                     }
                 }).done(function (data) {                	
                     this.setState({
@@ -1253,7 +1264,15 @@ const IndividualCustomer = Form.create()(React.createClass({
                 	introduction:thisData.introduction,
                 	expert:thisData.expert,
                 	celebrity:thisData.celebrity,
-                	international:thisData.international,	
+                	international:thisData.international,
+                	investment:thisData.investment,
+                	professionalTitle:thisData.professionalTitle,
+                	workUnit:thisData.workUnit,
+                	education:thisData.education,
+                	majorCategory:thisData.majorCategory,
+                	qualification:thisData.qualification,
+                	businessAudit:thisData.businessAudit,
+                    auditStatus:thisData.auditStatus?String(thisData.auditStatus):undefined, 
                 });    
             }.bind(this),
         }).always(function () {
@@ -1300,9 +1319,7 @@ const IndividualCustomer = Form.create()(React.createClass({
                 	isMember:thisData.isMember,
                 	currentMemberStatus:String(thisData.currentMemberStatus),
                 	lvl:String(thisData.lvl),
-                	serviceCertification:thisData.serviceCertification,
-                	status:String(thisData.status),
-                	userCertification:thisData.userCertification,
+                	status:String(thisData.status),                	
                 	createTimes:thisData.createTimes,	
                 });                  
             }.bind(this),
@@ -1898,8 +1915,6 @@ const IndividualCustomer = Form.create()(React.createClass({
                 email: this.state.email,
                 isMember: this.state.isMember,
                 currentMemberStatus: this.state.currentMemberStatus,
-                serviceCertification: this.state.serviceCertification,
-                userCertification: this.state.userCertification,
                 lvl:this.state.lvl,
                 status:this.state.status,
             }
@@ -2172,8 +2187,11 @@ const IndividualCustomer = Form.create()(React.createClass({
 	                            style={{ width: 100 }}
 	                            value={this.state.userCertificationSearch}
 	                            onChange={(e) => { this.setState({ userCertificationSearch: e }) }}>
-	                            <Select.Option value="0" >未认证</Select.Option>
-	                            <Select.Option value="1" >已认证</Select.Option>
+	                           {
+                                    auditStatusL.map(function (item) {
+                                            return <Select.Option key={item.value} >{item.key}</Select.Option>
+                                    })
+                                }
 	                        </Select>
 	                        <span>专家:</span>
 	                        <Select placeholder="专家"
@@ -2310,87 +2328,161 @@ const IndividualCustomer = Form.create()(React.createClass({
 					                           	 >
 						                            <Input placeholder="主要联系人" value={this.state.contacts} onChange={(e) => {
 								                        this.setState({ contacts:  e.target.value })}}/>
-						                     </FormItem>
-						                     <FormItem className="half-item" 
+						                    </FormItem>
+						                    <FormItem className="half-item" 
 							                    	 {...formItemLayout}
 							                        label="主要联系人号码"
 					                           	 >
 						                            <Input placeholder="主要联系人号码" value={this.state.contactMobile} onChange={(e) => {
 								                        this.setState({ contactMobile:  e.target.value })}}/>
-						                     </FormItem>
-						                    <FormItem className="half-item"
-							                    	 {...formItemLayout}
-							                         label="通信地址"
-						                            >
-						                                <Input placeholder="客户通信地址" value={this.state.postalAddress} 
-    												onChange={(e,pre) => { this.setState({ postalAddress: e.target.value }) }}/>
-						                    </FormItem>
-						                    <FormItem className="half-item"
-							                    	 {...formItemLayout}
-							                         label="固定电话"
-						                            >
-						                                <Input placeholder="客户固定电话" value={this.state.fixedTel} 
-    												onChange={(e) => { this.setState({ fixedTel: e.target.value }) }}/>
-						                    </FormItem>
-						                    <FormItem className="half-item"
-							                    	 {...formItemLayout}
-							                         label="客户QQ"
-						                            >
-						                                <Input placeholder="客户QQ" value={this.state.qq} 
-    												onChange={(e) => { this.setState({ qq: e.target.value })}}/>
-						                    </FormItem>
-						                    <FormItem className="half-item"
-							                    	 {...formItemLayout}
-							                         label="电子邮箱"
-						                            >
-						                                <Input placeholder="客户电子邮箱" value={this.state.email} 
-    												onChange={(e) => {this.setState({email: e.target.value })}}/>
 						                    </FormItem>
 						                    <div className="clearfix">
-						                    <FormItem className="half-item"
-								                {...formItemLayout}
-						                        label="专家"
-								                > 
-						                   		 <Radio.Group value={this.state.expert} onChange={(e) => {
-								                        this.setState({ expert:  e.target.value })
-								                    }}>
-								                        <Radio value={0}>否</Radio>
-								                        <Radio value={1}>是</Radio>
-								                  </Radio.Group>
-								            </FormItem>
-								            <FormItem className="half-item"
-								                {...formItemLayout}
-						                        label="明星"
-								                > 
-						                   		 <Radio.Group value={this.state.celebrity} onChange={(e) => {
-								                        this.setState({ celebrity:  e.target.value })
-								                    }}>
-								                        <Radio value={0}>否</Radio>
-								                        <Radio value={1}>是</Radio>
-								                  </Radio.Group>
-								            </FormItem>
-								             <FormItem className="half-item"
-								                {...formItemLayout}
-						                        label="国际化"
-								            > 
-						                   		 <Radio.Group value={this.state.international} onChange={(e) => {
-								                        this.setState({ international:  e.target.value })
-								                    }}>
-								                        <Radio value={0}>否</Radio>
-								                        <Radio value={1}>是</Radio>
-								                  </Radio.Group>
-								             </FormItem>
-					                   		 <FormItem className="half-item" 
-						                            {...formItemLayout}
-						                           label="性别"
-						                         > 
-						                   		 <Radio.Group value={this.state.sex} onChange={(e) => {
-								                        this.setState({sex:e.target.value})
-								                    }}>
-								                        <Radio value={'男'}>男</Radio>
-								                        <Radio value={'女'}>女</Radio>
-								                  </Radio.Group>
-					                   		 </FormItem>
+							                    <FormItem className="half-item" 
+								                    	 {...formItemLayout}
+								                        label="职称名字"
+						                           	 >
+							                            <Input placeholder="职称名字" value={this.state.professionalTitle} onChange={(e) => {
+									                        this.setState({ professionalTitle:  e.target.value })}}/>
+							                    </FormItem>
+							                    <FormItem className="half-item" 
+								                    	 {...formItemLayout}
+								                        label="就业单位"
+						                           	 >
+							                            <Input placeholder="就业单位" value={this.state.workUnit} onChange={(e) => {
+									                        this.setState({ workUnit:  e.target.value })}}/>
+							                    </FormItem>
+							                    <FormItem className="half-item" 
+								                    	 {...formItemLayout}
+								                        label="学历"
+						                           	 >
+							                            <Input placeholder="学历" value={this.state.education} onChange={(e) => {
+									                        this.setState({ education:  e.target.value })}}/>
+							                    </FormItem>
+							                    <FormItem className="half-item" 
+								                    	 {...formItemLayout}
+								                        label="专业类别"
+						                           	 >
+							                            <Input placeholder="专业类别" value={this.state.majorCategory} onChange={(e) => {
+									                        this.setState({ majorCategory:  e.target.value })}}/>
+							                    </FormItem>
+							                    <FormItem className="half-item" 
+								                    	 {...formItemLayout}
+								                        label="执业资格"
+						                           	 >
+							                            <Input placeholder="执业资格" value={this.state.qualification} onChange={(e) => {
+									                        this.setState({ qualification:  e.target.value })}}/>
+							                    </FormItem>
+							                    <FormItem className="half-item"
+								                    	 {...formItemLayout}
+								                         label="通信地址"
+							                            >
+							                                <Input placeholder="客户通信地址" value={this.state.postalAddress} 
+	    												onChange={(e,pre) => { this.setState({ postalAddress: e.target.value }) }}/>
+							                    </FormItem>
+							                    <FormItem className="half-item"
+								                    	 {...formItemLayout}
+								                         label="固定电话"
+							                            >
+							                                <Input placeholder="客户固定电话" value={this.state.fixedTel} 
+	    												onChange={(e) => { this.setState({ fixedTel: e.target.value }) }}/>
+							                    </FormItem>
+							                    <FormItem className="half-item"
+								                    	 {...formItemLayout}
+								                         label="客户QQ"
+							                            >
+							                                <Input placeholder="客户QQ" value={this.state.qq} 
+	    												onChange={(e) => { this.setState({ qq: e.target.value })}}/>
+							                    </FormItem>
+							                    <FormItem className="half-item"
+								                    	 {...formItemLayout}
+								                         label="电子邮箱"
+							                            >
+							                                <Input placeholder="客户电子邮箱" value={this.state.email} 
+	    												onChange={(e) => {this.setState({email: e.target.value })}}/>
+							                    </FormItem>
+							                     <FormItem className="half-item" 
+										            	{...formItemLayout}
+								                        label="实名认证"
+										            >
+										                <Select placeholder="实名认证"
+								                            value={this.state.auditStatus}
+								                            onChange={(e) => { this.setState({ auditStatus: e }) }}>
+								                            {
+							                                    auditStatusL.map(function (item) {
+							                                            return <Select.Option key={item.value} >{item.key}</Select.Option>
+							                                    })
+							                                }
+									                    </Select> 
+										        </FormItem>
+						                    </div>
+						                    <div className="clearfix">
+						                        <FormItem className="half-item"
+									                {...formItemLayout}
+							                        label="投资机构"
+									                > 
+							                   		 <Radio.Group value={this.state.investment} onChange={(e) => {
+									                        this.setState({ investment:  e.target.value })
+									                    }}>
+									                        <Radio value={0}>否</Radio>
+									                        <Radio value={1}>是</Radio>
+									                  </Radio.Group>
+									            </FormItem>
+							                    <FormItem className="half-item"
+							                   			 {...formItemLayout}
+								                           label="业务认证"
+							                   		>
+								                   		 <Radio.Group value={this.state.businessAudit} onChange={(e) => {
+										                        this.setState({ businessAudit:  e.target.value })
+										                    }}>
+										                        <Radio value={0}>未认证</Radio>
+										                        <Radio value={1}>已认证</Radio>
+										                  </Radio.Group>
+										        </FormItem>
+										           
+						                        <FormItem className="half-item"
+									                {...formItemLayout}
+							                        label="专家"
+									                > 
+							                   		 <Radio.Group value={this.state.expert} onChange={(e) => {
+									                        this.setState({ expert:  e.target.value })
+									                    }}>
+									                        <Radio value={0}>否</Radio>
+									                        <Radio value={1}>是</Radio>
+									                  </Radio.Group>
+									            </FormItem>
+									            <FormItem className="half-item"
+									                {...formItemLayout}
+							                        label="明星"
+									                > 
+							                   		 <Radio.Group value={this.state.celebrity} onChange={(e) => {
+									                        this.setState({ celebrity:  e.target.value })
+									                    }}>
+									                        <Radio value={0}>否</Radio>
+									                        <Radio value={1}>是</Radio>
+									                  </Radio.Group>
+									            </FormItem>
+									             <FormItem className="half-item"
+									                {...formItemLayout}
+							                        label="国际化"
+									            > 
+							                   		 <Radio.Group value={this.state.international} onChange={(e) => {
+									                        this.setState({ international:  e.target.value })
+									                    }}>
+									                        <Radio value={0}>否</Radio>
+									                        <Radio value={1}>是</Radio>
+									                  </Radio.Group>
+									             </FormItem>
+						                   		 <FormItem className="half-item" 
+							                            {...formItemLayout}
+							                           label="性别"
+							                         > 
+							                   		 <Radio.Group value={this.state.sex} onChange={(e) => {
+									                        this.setState({sex:e.target.value})
+									                    }}>
+									                        <Radio value={'男'}>男</Radio>
+									                        <Radio value={'女'}>女</Radio>
+									                  </Radio.Group>
+						                   		 </FormItem>
 					                   		 </div>
 						                    <div className='clearfix'>
 							                    <FormItem
@@ -2407,7 +2499,7 @@ const IndividualCustomer = Form.create()(React.createClass({
 							                        wrapperCol={{ span: 10 }}
 							                        label="身份证正面" >
 							                        <PicturesWall
-							                            pictureSign="customer_sys_file"
+							                            pictureSign="ID"
 							                            fileList={this.getPositiveIdUrl}
 							                            pictureUrl={this.state.positiveIdUrl} />
 							                            <p>建议:图片要清晰。</p>
@@ -2417,7 +2509,7 @@ const IndividualCustomer = Form.create()(React.createClass({
 							                        wrapperCol={{ span: 10 }}
 							                        label="身份证反面" > 
 							                        <PicturesWall
-							                            pictureSign="customer_sys_file"
+							                            pictureSign="ID"
 							                            fileList={this.getOppositeIdUrl}
 							                            pictureUrl={this.state.oppositeIdUrl} />
 							                            <p>建议:图片要清晰。</p>
@@ -2427,7 +2519,7 @@ const IndividualCustomer = Form.create()(React.createClass({
 							                        wrapperCol={{ span: 10 }}
 							                        label="客户照片" > 
 							                        <PicturesWall
-							                            pictureSign="customer_sys_file"
+							                            pictureSign="portrait"
 							                            fileList={this.getHeadPortraitUrl}
 							                            pictureUrl={this.state.headPortraitUrl} />
 							                            <p>建议:图片要清晰。</p>
@@ -2545,28 +2637,6 @@ const IndividualCustomer = Form.create()(React.createClass({
 					                                    </Select>
 							                   		</FormItem>
 							                   	</div>
-						                   		<FormItem className="half-item"
-						                   			 {...formItemLayout}
-							                           label="业务认证"
-						                   		>
-							                   		 <Radio.Group value={this.state.serviceCertification} onChange={(e) => {
-									                        this.setState({ serviceCertification:  e.target.value })
-									                    }}>
-									                        <Radio value={0}>未认证</Radio>
-									                        <Radio value={1}>已认证</Radio>
-									                  </Radio.Group>
-									            </FormItem>
-									            <FormItem className="half-item" 
-									            	{...formItemLayout}
-							                        label="实名认证"
-									            >
-							                   		 <Radio.Group value={this.state.userCertification} onChange={(e) => {
-									                        this.setState({ userCertification: e.target.value })
-									                    }}>
-									                        <Radio value={0}>未认证</Radio>
-									                        <Radio value={1}>已认证</Radio>
-									                  </Radio.Group>
-									            </FormItem>
 									            <div className="clearfix">
 									                <Button className='saveBtn' type="primary" htmlType="submit">保存</Button>  
 					                                <Button  type="ghost" onClick={this.detailsModal}>取消</Button>

+ 0 - 1
js/component/manageCenter/customer/individualCustomer/myClient.less

@@ -82,7 +82,6 @@
 .ant-modal-footer button{width: 100px;margin-top: 15px;margin-bottom: 15px;}
 .ant-modal-footer button:first-child{margin-left: 80px;margin-right: 30px;}
 .ant-modal-title{font-size: 20px;}
-.pictures{padding-top: 20px;}
 .ContactsList{float: right;}
 #demand-form {
     .half-item {

File diff suppressed because it is too large
+ 1925 - 1824
js/component/manageCenter/customer/individualCustomer/queryCustomer.jsx


+ 174 - 137
js/component/manageCenter/customer/statistics/followStatistics.jsx

@@ -1,145 +1,181 @@
 import React from 'react';
 import ajax from 'jquery/src/ajax/xhr.js';
 import $ from 'jquery/src/ajax';
-import "./statistics.less"
-import { Button, Select, Table ,Spin, message,Tabs, DatePicker } from 'antd';
+import "./statistics.less";
+import { Button, Select, Table, Spin, message, Tabs, DatePicker } from 'antd';
 const TabPane = Tabs.TabPane;
 import moment from 'moment';
-import {intentionalService} from '../../../dataDic.js';
+import { intentionalService,newFollow } from '../../../dataDic.js';
 
 const FollowStatistics = React.createClass({
 	loadData(pageNo, nub) {
-        this.state.data = [];
-        this.setState({
-            loading: true
-        });
-        let urls='';
-		switch(nub){
-			case "1":urls="/api/admin/achievement/delete";break;//日
-			case "2":urls="/api/admin/achievement/delete2";break;//周
-			case "3":urls="/api/admin/achievement/delete3";break;//月
-			case "4":urls="/api/admin/achievement/delete4";break;//季
-			case "5":urls="/api/admin/achievement/delete5";break;//年
-		}
-        $.ajax({
-            method: "get",
-            dataType: "json",
-            crossDomain: false,
-            url: globalConfig.context + urls?urls:"/api/admin/achievement/delete",
-            data: {
-                pageNo: pageNo || 1,
-                pageSize: this.state.pagination.pageSize,
-                releaseDateStartDate: this.state.releaseDate[0],
-                releaseDateEndDate: this.state.releaseDate[1],   
-            },
-            success: function (data) {
-                let theArr = [];
-                if (!data.data || !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({
-                            key: i,
-                            id: thisdata.id,
-                            serialNumber: thisdata.serialNumber,
-                            
-                        });
-                    };
-                    this.state.pagination.current = data.data.pageNo;
-                    this.state.pagination.total = data.data.totalCount;
-                };
-                this.setState({
-                    dataSource: theArr,
-                    pagination: this.state.pagination
-                });
-            }.bind(this),
-        }).always(function () {
-            this.setState({
-                loading: false
-            });
-        }.bind(this));
-    },
-	getInitialState(){
-		return{
-			releaseDate:[],
-			loading:false,
+		this.state.data = [];
+		this.setState({
+			loading: true
+		});
+		let urls = '';
+		switch(nub) {
+			case "1":
+				urls = "";
+				break; //日
+			case "2":
+				urls = "daySpan";
+				break; //日
+			case "3":
+				urls = "weekSpan";
+				break; //周
+			case "4":
+				urls = "monthSpan";
+				break; //月
+			case "5":
+				urls = "quarterSpan";
+				break; //季
+			case "6":
+				urls = "yearSpan";
+				break; //年
+			default:
+				urls ='';
+		}	
+		$.ajax({
+			method: "get",
+			dataType: "json",
+			crossDomain: false,
+			url: globalConfig.context + "/api/admin/customer/businessStatistic",
+			data: {
+				pageNo: pageNo || 1,
+				pageSize: this.state.pagination.pageSize,
+				startDate: this.state.releaseDate[0],
+				endDate: this.state.releaseDate[1],
+				timeSpan:this.state.releaseDate[0]?'':urls,
+				depId:this.state.depId,
+				businessGlossoryId:this.state.followSearch
+			},
+			success: function(data) {
+				let theArr = [];
+				if(!data.data || !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({
+							key: i,
+							id: thisdata.id,
+							adminName: thisdata.adminName,
+							departmentName: thisdata.departmentName,
+							sendMaterialNo: thisdata.sendMaterialNo,
+							interviewNo: thisdata.interviewNo,
+							sendProspectusNo: thisdata.sendProspectusNo,
+							quoteNo: thisdata.quoteNo,
+							sendContractNo: thisdata.sendContractNo ,
+							signContractNo: thisdata.signContractNo,
+							onVisaNo: thisdata.onVisaNo,
+							visaNo: thisdata.visaNo,
+						});
+					};
+					this.state.pagination.current = data.data.pageNo;
+					this.state.pagination.total = data.data.totalCount;
+				};
+				this.setState({
+					dataSource: theArr,
+					pagination: this.state.pagination
+				});
+			}.bind(this),
+		}).always(function() {
+			this.setState({
+				loading: false
+			});
+		}.bind(this));
+	},
+	getInitialState() {
+		return {
+			releaseDate: [],
+			loading: false,
 			pagination: {
-                defaultCurrent: 1,
-                defaultPageSize: 10,
-                showQuickJumper: true,
-                pageSize: 10,
-                onChange: function (page) {
-                    this.loadData(page,this.satet.callnub);
-                }.bind(this),
-                showTotal: function (total) {
-                    return '共' + total + '条数据';
-                }
-            },
-            columns: [
-                {
-                    title: '营销员',
-                    dataIndex: 'serialNumber',
-                    key: 'serialNumber',
-                }, {
-                    title: '部门',
-                    dataIndex: 'name',
-                    key: 'name',
-                }, {
-                    title: '已发项目介绍资料',
-                    dataIndex: 'keyword',
-                    key: 'keyword',
-                }, {
-                    title: '已约面谈',
-                    dataIndex: 'category',
-                    key: 'category',
-                }, {
-                    title: '已发合同计划书',
-                    dataIndex: 'theName',
-                    key: 'theName',
-                },{
-                    title: '已报价',
-                    dataIndex: 'keyword1',
-                    key: 'keyword1',
-                }, {
-                    title: '已发合同',
-                    dataIndex: 'category2',
-                    key: 'category2',    
-                }, {
-                    title: '已签合同',
-                    dataIndex: 'theName3',
-                    key: 'theName3',
-                }, {
-                    title: '面谈中',
-                    dataIndex: 'category4',
-                    key: 'category4',    
-                }, {
-                    title: '已面签',
-                    dataIndex: 'theName4',
-                    key: 'theName4',
-                }
-            ]
+				defaultCurrent: 1,
+				defaultPageSize: 10,
+				showQuickJumper: true,
+				pageSize: 10,
+				onChange: function(page) {
+					this.call(page)
+				}.bind(this),
+				showTotal: function(total) {
+					return '共' + total + '条数据';
+				}
+			},
+			columns: [{
+				title: '营销员',
+				dataIndex: 'adminName',
+				key: 'adminName',
+			}, {
+				title: '部门',
+				dataIndex: 'departmentName',
+				key: 'departmentName',
+			}, {
+				title: '已发项目介绍资料',
+				dataIndex: 'sendMaterialNo',
+				key: 'sendMaterialNo',
+			}, {
+				title: '已约面谈',
+				dataIndex: 'interviewNo',
+				key: 'interviewNo',
+			}, {
+				title: '已发合同计划书',
+				dataIndex: 'sendProspectusNo',
+				key: 'sendProspectusNo',
+			}, {
+				title: '已报价',
+				dataIndex: 'quoteNo',
+				key: 'quoteNo',
+			}, {
+				title: '已发合同',
+				dataIndex: 'sendContractNo',
+				key: 'sendContractNo',
+			}, {
+				title: '已签合同',
+				dataIndex: 'signContractNo',
+				key: 'signContractNo',
+			}, {
+				title: '面谈中',
+				dataIndex: 'onVisaNo',
+				key: 'onVisaNo',
+			}, {
+				title: '已面签',
+				dataIndex: 'visaNo',
+				key: 'visaNo',
+			}]
 		}
 	},
-	callback(e){
+	callback(e) {
 		this.setState({
-			callnub:e
+			callnub: e,
+			releaseDate:[]
 		})
-		this.loadData(1,e)
+		this.loadData(1, e)
+	},
+	call(a){
+		this.loadData(a, this.state.callnub)
 	},
 	search() {
-        this.loadData(1,this.state.callnub)
-    },
-    reset() {
-        this.state.releaseDate = [];
-        this.loadData(1,this.state.callnub);
-    },
-    componentWillMount(){
-    	this.loadData();
-    },
-	render(){
+		if(this.state.releaseDate[0]){
+			this.setState({
+				callnub:'1'
+			})
+		}else{
+			this.state.releaseDate=[]
+		}
+		this.loadData(1, this.state.callnub)
+	},
+	reset() {
+		this.state.releaseDate = [];
+		this.state.followSearch=undefined;
+		this.loadData(1, this.state.callnub);
+	},
+	componentWillMount() {
+		this.loadData();
+	},
+	render() {
 		const { RangePicker } = DatePicker;
 		return <div className="visitContant">
 					<div className="visitTitle">
@@ -149,8 +185,8 @@ const FollowStatistics = React.createClass({
                             this.state.releaseDate[1] ? moment(this.state.releaseDate[1]) : null]}
                             onChange={(data, dataString) => { this.setState({ releaseDate: dataString }); }} />
                         <span style={{marginRight:'15px',marginLeft:'15px'}}>业务类型:</span>
-                        <Select placeholder="服务意向" value={this.state.businessIdS} onChange={(e) => {
-								        this.setState({businessIdS:e})}} style={{width:'150px'}}>
+                        <Select placeholder="业务类型" value={this.state.followSearch} onChange={(e) => {
+								        this.setState({followSearch:e})}} style={{width:'150px'}}>
 	                      {
 	                        intentionalService.map(function (item) {
 	                            return <Select.Option key={item.value} >{item.key}</Select.Option>
@@ -161,12 +197,13 @@ const FollowStatistics = React.createClass({
                         <Button  onClick={this.reset} className="green" style={{background:'green',color:'#ffffff',border:'none'}}>重置</Button>
                         
 						<div className="clearfix" style={{marginTop:'30px',marginLeft:'20px'}}>
-						    <Tabs onChange={this.callback} type="card">
-								 <TabPane tab="本日新增业务意向" key="1"></TabPane>
-							     <TabPane tab="本周新增业务意向" key="2"></TabPane>
-							     <TabPane tab="本月新增业务意向" key="3"></TabPane>
-							     <TabPane tab="本季新增业务意向" key="4"></TabPane>
-							     <TabPane tab="本年新增业务意向" key="5"></TabPane>
+						    <Tabs onChange={this.callback} type="card" activeKey={this.state.callnub}>
+								 <TabPane tab="所有业务跟进进度" key="1"></TabPane>
+								 <TabPane tab="本日业务跟进进度" key="2"></TabPane>
+							     <TabPane tab="本周业务跟进进度" key="3"></TabPane>
+							     <TabPane tab="本月业务跟进进度" key="4"></TabPane>
+							     <TabPane tab="本季业务跟进进度" key="5"></TabPane>
+							     <TabPane tab="本年业务跟进进度" key="6"></TabPane>
 						    </Tabs>
 						</div>
 						<div className="clearfix">
@@ -183,6 +220,6 @@ const FollowStatistics = React.createClass({
 					
 					</div>
 		      </div>
-	}	
+	}
 });
-export default FollowStatistics;
+export default FollowStatistics;

+ 2 - 2
js/component/manageCenter/customer/statistics/statistics.less

@@ -13,9 +13,9 @@
        
     };
     .titleTime{margin-left: 20px;margin-right: 15px;};
-    .ant-tabs.ant-tabs-card > .ant-tabs-bar .ant-tabs-tab{padding: 8px 40px 8px;margin-right: 20px;font-size: 18px;};
+    .ant-tabs.ant-tabs-card > .ant-tabs-bar .ant-tabs-tab{padding: 6px 20px 6px;margin-right: 20px;font-size: 16px;};
     .maintitle{width: 100%;font-size: 20px;text-align: center;margin-top: 20px;padding-bottom: 20px;}
     .ant-table-thead > tr > th{background: none;}
-    .ant-tabs-bar{padding-bottom: 14px;}
+    .ant-tabs-bar{padding-bottom: 6px;}
     .ant-tabs-nav-container{overflow:inherit;}
 }

+ 165 - 127
js/component/manageCenter/customer/statistics/statusStatistics.jsx

@@ -2,136 +2,173 @@ import React from 'react';
 import ajax from 'jquery/src/ajax/xhr.js';
 import $ from 'jquery/src/ajax';
 import "./statistics.less"
-import { Button, Select, Table ,Spin, message,Tabs, DatePicker } from 'antd';
+import { Button, Select, Table, Spin, message, Tabs, DatePicker } from 'antd';
 const TabPane = Tabs.TabPane;
 import moment from 'moment';
-import {intentionalService} from '../../../dataDic.js';
+import { intentionalService } from '../../../dataDic.js';
 
-const StatusStatistics=React.createClass({
+const StatusStatistics = React.createClass({
 	loadData(pageNo, nub) {
-        this.state.data = [];
-        this.setState({
-            loading: true
-        });
-        let urls='';
-		switch(nub){
-			case "1":urls="/api/admin/achievement/delete";break;//日
-			case "2":urls="/api/admin/achievement/delete2";break;//周
-			case "3":urls="/api/admin/achievement/delete3";break;//月
-			case "4":urls="/api/admin/achievement/delete4";break;//季
-			case "5":urls="/api/admin/achievement/delete5";break;//年
+		this.state.data = [];
+		this.setState({
+			loading: true
+		});
+		let urls = '';
+		switch(nub) {
+			case "1":
+				urls = "";
+				break; //日
+			case "2":
+				urls = "daySpan";
+				break; //日
+			case "3":
+				urls = "weekSpan";
+				break; //周
+			case "4":
+				urls = "monthSpan";
+				break; //月
+			case "5":
+				urls = "quarterSpan";
+				break; //季
+			case "6":
+				urls = "yearSpan";
+				break; //年
+			default:
+				urls ='';
 		}
-        $.ajax({
-            method: "get",
-            dataType: "json",
-            crossDomain: false,
-            url: globalConfig.context + urls?urls:"/api/admin/achievement/delete",
-            data: {
-                pageNo: pageNo || 1,
-                pageSize: this.state.pagination.pageSize,
-                releaseDateStartDate: this.state.releaseDate[0],
-                releaseDateEndDate: this.state.releaseDate[1],   
-            },
-            success: function (data) {
-                let theArr = [];
-                if (!data.data || !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({
-                            key: i,
-                            id: thisdata.id,
-                            serialNumber: thisdata.serialNumber,
-                            
-                        });
-                    };
-                    this.state.pagination.current = data.data.pageNo;
-                    this.state.pagination.total = data.data.totalCount;
-                };
-                this.setState({
-                    dataSource: theArr,
-                    pagination: this.state.pagination
-                });
-            }.bind(this),
-        }).always(function () {
-            this.setState({
-                loading: false
-            });
-        }.bind(this));
-    },
-	getInitialState(){
-		return{
-			releaseDate:[],
-			loading:false,
+		$.ajax({
+			method: "get",
+			dataType: "json",
+			crossDomain: false,
+			url: globalConfig.context + "/api/admin/customer/customerStatistics",
+			data: {
+				pageNo: pageNo || 1,
+				pageSize: this.state.pagination.pageSize,
+				startDate: this.state.releaseDate[0],
+				endDate: this.state.releaseDate[1],
+				timeSpan:this.state.releaseDate[0]?'':urls,
+				businessGlossoryId:this.state.intentionalSearch,
+				depId:this.state.depId,
+			},
+			success: function(data) {
+				let theArr = [];
+				if(!data.data || !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({
+							key: i,
+							id: thisdata.id,
+							adminName: thisdata.adminName,
+							departmentName: thisdata.departmentName,
+							newNo: thisdata.newNo,
+							intentionNo: thisdata.intentionNo,
+							pointNo: thisdata.pointNo,
+							interviewNo: thisdata.interviewNo,
+							signNo: thisdata.signNo,
+							refuseNo: thisdata.refuseNo,
+							stopNo: thisdata.stopNo,
+						});
+					};
+					this.state.pagination.current = data.data.pageNo;
+					this.state.pagination.total = data.data.totalCount;
+				};
+				this.setState({
+					dataSource: theArr,
+					pagination: this.state.pagination
+				});
+			}.bind(this),
+		}).always(function() {
+			this.setState({
+				loading: false
+			});
+		}.bind(this));
+	},
+	getInitialState() {
+		return {
+			releaseDate: [],
+			loading: false,
+			callnub:'1',
 			pagination: {
-                defaultCurrent: 1,
-                defaultPageSize: 10,
-                showQuickJumper: true,
-                pageSize: 10,
-                onChange: function (page) {
-                    this.loadData(page,this.satet.callnub);
-                }.bind(this),
-                showTotal: function (total) {
-                    return '共' + total + '条数据';
-                }
-            },
-            columns: [
-                {
-                    title: '营销员',
-                    dataIndex: 'serialNumber',
-                    key: 'serialNumber',
-                }, {
-                    title: '部门',
-                    dataIndex: 'name',
-                    key: 'name',
-                }, {
-                    title: '新客户数',
-                    dataIndex: 'keyword',
-                    key: 'keyword',
-                }, {
-                    title: '意向客户数',
-                    dataIndex: 'category',
-                    key: 'category',
-                }, {
-                    title: '重点客户数',
-                    dataIndex: 'theName',
-                    key: 'theName',
-                },{
-                    title: '面谈客户数',
-                    dataIndex: 'keyword1',
-                    key: 'keyword1',
-                }, {
-                    title: '签单客户数',
-                    dataIndex: 'category2',
-                    key: 'category2',    
-                }, {
-                    title: '被拒绝客户数',
-                    dataIndex: 'theName3',
-                    key: 'theName3',
-                }
-            ]
+				defaultCurrent: 1,
+				defaultPageSize: 10,
+				showQuickJumper: true,
+				pageSize: 10,
+				onChange: function(page) {
+					this.call(page)
+				}.bind(this),
+				showTotal: function(total) {
+					return '共' + total + '条数据';
+				}
+			},
+			columns: [{
+				title: '营销员',
+				dataIndex: 'adminName',
+				key: 'adminName',
+			}, {
+				title: '部门',
+				dataIndex: 'departmentName',
+				key: 'departmentName',
+			}, {
+				title: '新客户数',
+				dataIndex: 'newNo',
+				key: 'newNo',
+			}, {
+				title: '意向客户数',
+				dataIndex: 'intentionNo',
+				key: 'intentionNo',
+			}, {
+				title: '重点客户数',
+				dataIndex: 'pointNo',
+				key: 'pointNo',
+			}, {
+				title: '面谈客户数',
+				dataIndex: 'interviewNo',
+				key: 'interviewNo',
+			}, {
+				title: '签单客户数',
+				dataIndex: 'stopNo',
+				key: 'stopNo',
+			}, {
+				title: '被拒绝客户数',
+				dataIndex: 'refuseNo',
+				key: 'refuseNo',
+			}]
 		}
 	},
-	callback(e){
+	callback(e) {
 		this.setState({
-			callnub:e
+			callnub: e,
+			releaseDate:[]
 		})
-		this.loadData(1,e)
+		this.loadData(1, e)
+	},
+	call(a){
+		this.loadData(a, this.state.callnub)
 	},
 	search() {
-        this.loadData(1,this.state.callnub)
-    },
-    reset() {
-        this.state.releaseDate = [];
-        this.loadData(1,this.state.callnub);
-    },
-    componentWillMount(){
-    	this.loadData();
-    },
-	render(){
+		if(this.state.releaseDate[0]){
+			this.setState({
+				callnub:'1'
+			})
+		}else{
+			this.state.releaseDate=[]
+		}
+		this.loadData(1, this.state.callnub)
+	},
+	
+	reset() {
+		this.state.releaseDate = [];
+		this.state.intentionalSearch = undefined;
+		this.loadData(1, this.state.callnub);
+	},
+	componentWillMount() {
+		this.loadData();
+	},
+	render() {
 		const { RangePicker } = DatePicker;
 		return <div className="visitContant">
 					<div className="visitTitle">
@@ -141,8 +178,8 @@ const StatusStatistics=React.createClass({
                             this.state.releaseDate[1] ? moment(this.state.releaseDate[1]) : null]}
                             onChange={(data, dataString) => { this.setState({ releaseDate: dataString }); }} />
                         <span style={{marginRight:'15px',marginLeft:'15px'}}>业务类型:</span>
-                        <Select placeholder="服务意向" value={this.state.businessIdS} onChange={(e) => {
-								        this.setState({businessIdS:e})}} style={{width:'150px'}}>
+                        <Select placeholder="业务品种" value={this.state.intentionalSearch} onChange={(e) => {
+								        this.setState({intentionalSearch:e})}} style={{width:'150px'}}>
 	                      {
 	                        intentionalService.map(function (item) {
 	                            return <Select.Option key={item.value} >{item.key}</Select.Option>
@@ -153,12 +190,13 @@ const StatusStatistics=React.createClass({
                         <Button  onClick={this.reset} className="green" style={{background:'green',color:'#ffffff',border:'none'}}>重置</Button>
                         
 						<div className="clearfix" style={{marginTop:'30px',marginLeft:'20px'}}>
-						    <Tabs onChange={this.callback} type="card">
-								 <TabPane tab="本日新增业务意向" key="1"></TabPane>
-							     <TabPane tab="本周新增业务意向" key="2"></TabPane>
-							     <TabPane tab="本月新增业务意向" key="3"></TabPane>
-							     <TabPane tab="本季新增业务意向" key="4"></TabPane>
-							     <TabPane tab="本年新增业务意向" key="5"></TabPane>
+						    <Tabs onChange={this.callback} type="card" activeKey={this.state.callnub}>
+						         <TabPane tab="所有业务客户状态" key="1"></TabPane>
+								 <TabPane tab="本日业务客户状态" key="2"></TabPane>
+							     <TabPane tab="本周业务客户状态" key="3"></TabPane>
+							     <TabPane tab="本月业务客户状态" key="4"></TabPane>
+							     <TabPane tab="本季业务客户状态" key="5"></TabPane>
+							     <TabPane tab="本年业务客户状态" key="6"></TabPane>
 						    </Tabs>
 						</div>
 						<div className="clearfix">
@@ -177,4 +215,4 @@ const StatusStatistics=React.createClass({
 		      </div>
 	}
 });
-export default StatusStatistics;
+export default StatusStatistics;

+ 169 - 134
js/component/manageCenter/customer/statistics/visitStatistics.jsx

@@ -2,145 +2,179 @@ import React from 'react';
 import ajax from 'jquery/src/ajax/xhr.js';
 import $ from 'jquery/src/ajax';
 import "./statistics.less";
-import { Button, Table ,Spin, message,Tabs, DatePicker, } from 'antd';
+import { Button, Table, Spin, message, Tabs, DatePicker, Select } from 'antd';
+var intentionalService = [];
 const TabPane = Tabs.TabPane;
 import moment from 'moment';
 
-const VisitStatistics=React.createClass({
+const VisitStatistics = React.createClass({
 	loadData(pageNo, nub) {
-        this.state.data = [];
-        this.setState({
-            loading: true
-        });
-        let urls='';
-		switch(nub){
-			case "1":urls="/api/admin/achievement/delete";break;//日
-			case "2":urls="/api/admin/achievement/delete2";break;//周
-			case "3":urls="/api/admin/achievement/delete3";break;//月
-			case "4":urls="/api/admin/achievement/delete4";break;//季
-			case "5":urls="/api/admin/achievement/delete5";break;//年
+		this.state.data = [];
+		this.setState({
+			loading: true
+		});
+		let urls = '';
+		switch(nub) {
+			case "1":
+				urls = "";
+				break; //日
+			case "2":
+				urls = "daySpan";
+				break; //日
+			case "3":
+				urls = "weekSpan";
+				break; //周
+			case "4":
+				urls = "monthSpan";
+				break; //月
+			case "5":
+				urls = "quarterSpan";
+				break; //季
+			case "6":
+				urls = "yearSpan";
+				break; //年
+			default:
+				urls = '';
 		}
-        $.ajax({
-            method: "get",
-            dataType: "json",
-            crossDomain: false,
-            url: globalConfig.context + urls?urls:"/api/admin/achievement/delete",
-            data: {
-                pageNo: pageNo || 1,
-                pageSize: this.state.pagination.pageSize,
-                releaseDateStartDate: this.state.releaseDate[0],
-                releaseDateEndDate: this.state.releaseDate[1],   
-            },
-            success: function (data) {
-                let theArr = [];
-                if (!data.data || !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({
-                            key: i,
-                            id: thisdata.id,
-                            serialNumber: thisdata.serialNumber,
-                            
-                        });
-                    };
-                    this.state.pagination.current = data.data.pageNo;
-                    this.state.pagination.total = data.data.totalCount;
-                };
-                this.setState({
-                    dataSource: theArr,
-                    pagination: this.state.pagination
-                });
-            }.bind(this),
-        }).always(function () {
-            this.setState({
-                loading: false
-            });
-        }.bind(this));
-    },
-	getInitialState(){
-		return{
-			releaseDate:[],
-			loading:false,
+		$.ajax({
+			method: "get",
+			dataType: "json",
+			crossDomain: false,
+			url: globalConfig.context + "/api/admin/customer/followStatistic",
+			data: {
+				pageNo: pageNo || 1,
+				pageSize: this.state.pagination.pageSize,
+				startDate: this.state.releaseDate[0],
+				endDate: this.state.releaseDate[1],
+				timeSpan: this.state.releaseDate[0] ? '' : urls,
+				depId: this.state.depId,
+			},
+			success: function(data) {
+				let theArr = [];
+				if(!data.data || !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({
+							key: i,
+							id: thisdata.id,
+							adminName: thisdata.adminName,
+							departmentName: thisdata.departmentName,
+							followNo: thisdata.followNo,
+							customerNo: thisdata.customerNo,
+							telNo: thisdata.telNo,
+							qqNo: thisdata.qqNo,
+							visitNo: thisdata.visitNo,
+							emailNo: thisdata.emailNo,
+							letterNo: thisdata.letterNo,
+							wxNo: thisdata.wxNo,
+						});
+					};
+					this.state.pagination.current = data.data.pageNo;
+					this.state.pagination.total = data.data.totalCount;
+				};
+				this.setState({
+					dataSource: theArr,
+					pagination: this.state.pagination
+				});
+			}.bind(this),
+		}).always(function() {
+			this.setState({
+				loading: false
+			});
+		}.bind(this));
+	},
+	getInitialState() {
+		return {
+			releaseDate: [],
+			loading: false,
+			callnub: '1',
 			pagination: {
-                defaultCurrent: 1,
-                defaultPageSize: 10,
-                showQuickJumper: true,
-                pageSize: 10,
-                onChange: function (page) {
-                    this.loadData(page,this.satet.callnub);
-                }.bind(this),
-                showTotal: function (total) {
-                    return '共' + total + '条数据';
-                }
-            },
-            columns: [
-                {
-                    title: '营销员',
-                    dataIndex: 'serialNumber',
-                    key: 'serialNumber',
-                }, {
-                    title: '部门',
-                    dataIndex: 'name',
-                    key: 'name',
-                }, {
-                    title: '拜访次数',
-                    dataIndex: 'keyword',
-                    key: 'keyword',
-                }, {
-                    title: '拜访客户数',
-                    dataIndex: 'category',
-                    key: 'category',
-                    render: text => { return getAchievementCategory(text); }
-                }, {
-                    title: '电话量',
-                    dataIndex: 'theName',
-                    key: 'theName',
-                },{
-                    title: '外拜量',
-                    dataIndex: 'keyword1',
-                    key: 'keyword1',
-                }, {
-                    title: 'QQ量',
-                    dataIndex: 'category2',
-                    key: 'category2',
-                    render: text => { return getAchievementCategory(text); }
-                }, {
-                    title: '邮件量',
-                    dataIndex: 'theName3',
-                    key: 'theName3',
-                }, {
-                    title: '书信量',
-                    dataIndex: 'theName4',
-                    key: 'theName4',
-                },  {
-                    title: '微信量',
-                    dataIndex: 'theName5',
-                    key: 'theName5',
-                },
-            ]
+				defaultCurrent: 1,
+				defaultPageSize: 10,
+				showQuickJumper: true,
+				pageSize: 10,
+				onChange: function(page) {
+					this.call(page)
+				}.bind(this),
+				showTotal: function(total) {
+					return '共' + total + '条数据';
+				}
+			},
+			columns: [{
+				title: '营销员',
+				dataIndex: 'adminName',
+				key: 'adminName',
+			}, {
+				title: '部门',
+				dataIndex: 'departmentName',
+				key: 'departmentName',
+			}, {
+				title: '拜访次数',
+				dataIndex: 'followNo',
+				key: 'followNo',
+			}, {
+				title: '拜访客户数',
+				dataIndex: 'customerNo',
+				key: 'customerNo',
+			}, {
+				title: '电话量',
+				dataIndex: 'telNo',
+				key: 'telNo',
+			}, {
+				title: '外拜量',
+				dataIndex: 'visitNo',
+				key: 'visitNo',
+			}, {
+				title: 'QQ量',
+				dataIndex: 'qqNo',
+				key: 'qqNo',
+			}, {
+				title: '邮件量',
+				dataIndex: 'emailNo',
+				key: 'emailNo',
+			}, {
+				title: '书信量',
+				dataIndex: 'letterNo',
+				key: 'letterNo',
+			}, {
+				title: '微信量',
+				dataIndex: 'wxNo',
+				key: 'wxNo',
+			}, ]
 		}
 	},
-	callback(e){
+	callback(e) {
 		this.setState({
-			callnub:e
+			callnub: e,
+			releaseDate: []
 		})
-		this.loadData(1,e)
+		this.loadData(1, e)
+	},
+	call(a) {
+		this.loadData(a, this.state.callnub)
 	},
 	search() {
-        this.loadData(1,this.state.callnub)
-    },
-    reset() {
-        this.state.releaseDate = [];
-        this.loadData(1,this.state.callnub);
-    },
-    componentWillMount(){
-    	this.loadData();
-    },
-	render(){
+		if(this.state.releaseDate[0]) {
+			this.setState({
+				callnub: '1'
+			})
+		} else {
+			this.state.releaseDate = []
+		}
+		this.loadData(1, this.state.callnub)
+	},
+	reset() {
+		this.state.releaseDate = [];
+		this.loadData(1, this.state.callnub);
+	},
+	componentWillMount() {
+		this.loadData();
+	},
+	render() {
 		const { RangePicker } = DatePicker;
 		return <div className="visitContant">
 					<div className="visitTitle">
@@ -152,12 +186,13 @@ const VisitStatistics=React.createClass({
                             <Button  onClick={this.search} className="blue" style={{background:'red',color:'#ffffff',border:'none'}}>统计</Button>
                             <Button  onClick={this.reset} className="green" style={{background:'green',color:'#ffffff',border:'none'}}>重置</Button>   
 						<div className="clearfix" style={{marginTop:'30px',marginLeft:'20px'}}>
-						    <Tabs onChange={this.callback} type="card">
-								 <TabPane tab="本日客户拜访统计" key="1"></TabPane>
-							     <TabPane tab="本周客户拜访统计" key="2"></TabPane>
-							     <TabPane tab="本月客户拜访统计" key="3"></TabPane>
-							     <TabPane tab="本季客户拜访统计" key="4"></TabPane>
-							     <TabPane tab="本年客户拜访统计" key="5"></TabPane>
+						    <Tabs onChange={this.callback} type="card" activeKey={this.state.callnub} >
+						         <TabPane tab="所有客户拜访统计" key="1"></TabPane>
+								 <TabPane tab="本日客户拜访统计" key="2"></TabPane>
+							     <TabPane tab="本周客户拜访统计" key="3"></TabPane>
+							     <TabPane tab="本月客户拜访统计" key="4"></TabPane>
+							     <TabPane tab="本季客户拜访统计" key="5"></TabPane>
+							     <TabPane tab="本年客户拜访统计" key="6"></TabPane>
 						    </Tabs>
 						</div>
 						<div className="clearfix">
@@ -177,4 +212,4 @@ const VisitStatistics=React.createClass({
 	}
 })
 
-export default VisitStatistics;
+export default VisitStatistics;