|  | @ -3,13 +3,12 @@ $(function() {
 | 
												
													
														
															|  | 		tType = 0;
 |  | 		tType = 0;
 | 
												
													
														
															|  | 	//接口
 |  | 	//接口
 | 
												
													
														
															|  | 	var pi = {
 |  | 	var pi = {
 | 
												
													
														
															|  | 		ztqk: 'statistics/getStatTitleInfo',
 |  | 
 | 
												
													
														
															|  | 		qyqk: 'statistics/getSignCountLineByType',
 |  | 
 | 
												
													
														
															|  | 		zxtj: 'statistics/getReyStatbyTeam',
 |  | 
 | 
												
													
														
															|  | 		jgnfw: 'statistics/getServiceRankingList',
 |  | 
 | 
												
													
														
															|  | 		ccftj: 'statistics/getPrescriptionTotalCount',
 |  | 
 | 
												
													
														
															|  | 		xqzq: 'statistics/getTeamRenewChangeLine',
 |  | 
 | 
												
													
														
															|  | 		pjmyd: 'statistics/getAvgLine'
 |  | 
 | 
												
													
														
															|  | 
 |  | 		ztqk: 'statistics/getStatTitleInfo',//总体情况
 | 
												
													
														
															|  | 
 |  | 		zxtj: 'statistics/getReyStatbyTeam',//咨询统计
 | 
												
													
														
															|  | 
 |  | 		jmgzqs: 'statistics/getConcernbyTeam',//居民关注趋势
 | 
												
													
														
															|  | 
 |  | 		gzbhqs: 'statistics/getConcerAndCancel',//关注变化趋势
 | 
												
													
														
															|  | 
 |  | 		jgnfw: 'statistics/getServiceRankingList',//机构内排行
 | 
												
													
														
															|  | 
 |  | 		pjmyd: 'statistics/getAvgLine'//医生平均分
 | 
												
													
														
															|  | 	};
 |  | 	};
 | 
												
													
														
															|  | 	
 |  | 	
 | 
												
													
														
															|  | 	function openWebview(href,hrefId,extras) {
 |  | 	function openWebview(href,hrefId,extras) {
 | 
												
											
												
													
														
															|  | @ -33,16 +32,11 @@ $(function() {
 | 
												
													
														
															|  | 		$selTit: $('#selTit'),
 |  | 		$selTit: $('#selTit'),
 | 
												
													
														
															|  | //		echarts
 |  | //		echarts
 | 
												
													
														
															|  |  		$qyqkChart: document.getElementById('qyqkChart'),
 |  |  		$qyqkChart: document.getElementById('qyqkChart'),
 | 
												
													
														
															|  | 		$zxtjChart: document.getElementById('zxtjChart'),
 |  | 
 | 
												
													
														
															|  | 
 |  |  		$zxtjChart: document.getElementById('zxtjChart'),
 | 
												
													
														
															|  | 
 |  | 		$jmgzChart: document.getElementById('jmgzChart'),
 | 
												
													
														
															|  | 
 |  | 		$gzbhChart: document.getElementById('gzbhChart'),
 | 
												
													
														
															|  | 		$jgChart: document.getElementById('jgChart'),
 |  | 		$jgChart: document.getElementById('jgChart'),
 | 
												
													
														
															|  | 		$ccfChart: document.getElementById('ccfChart'),
 |  | 
 | 
												
													
														
															|  | 		$xqzqChart: document.getElementById('xqzqChart'),
 |  | 
 | 
												
													
														
															|  | 		$mydChart: document.getElementById('mydChart'),
 |  | 		$mydChart: document.getElementById('mydChart'),
 | 
												
													
														
															|  | 		//	续约/签约切换
 |  | 
 | 
												
													
														
															|  | 		$qiehuan: $('#qiehuan'),
 |  | 
 | 
												
													
														
															|  | 		$qyLab: $('.qy-lab'),
 |  | 
 | 
												
													
														
															|  | 		$qyQh: $('.qy-qh'),
 |  | 
 | 
												
													
														
															|  | 		$jgnph: $('.jgnph'),
 |  | 
 | 
												
													
														
															|  | 		//总体情况
 |  | 		//总体情况
 | 
												
													
														
															|  | 		$qyrs: $('#qyrs'),
 |  | 		$qyrs: $('#qyrs'),
 | 
												
													
														
															|  | 		$fwrs: $('#fwrs'),
 |  | 		$fwrs: $('#fwrs'),
 | 
												
											
												
													
														
															|  | @ -83,50 +77,40 @@ $(function() {
 | 
												
													
														
															|  | 				this.setDateInPage();
 |  | 				this.setDateInPage();
 | 
												
													
														
															|  | 			}
 |  | 			}
 | 
												
													
														
															|  | 		},
 |  | 		},
 | 
												
													
														
															|  | 		getZTQKData: function () {
 |  | 
 | 
												
													
														
															|  | 
 |  | 		getZTQKData: function () {//总体情况
 | 
												
													
														
															|  | 			 return getReqPromise( pi.ztqk, {
 |  | 			 return getReqPromise( pi.ztqk, {
 | 
												
													
														
															|  | 				startDate: this.startDate,
 |  | 				startDate: this.startDate,
 | 
												
													
														
															|  | 				endDate: this.endDate
 |  | 				endDate: this.endDate
 | 
												
													
														
															|  | 			 }, 'GET');
 |  | 			 }, 'GET');
 | 
												
													
														
															|  | 		},
 |  | 		},
 | 
												
													
														
															|  | 		getQYQKData: function (t) {
 |  | 
 | 
												
													
														
															|  | 			 return getReqPromise( pi.qyqk, {
 |  | 
 | 
												
													
														
															|  | 
 |  | 		getZXTJData: function () {//咨询统计
 | 
												
													
														
															|  | 
 |  | 			 return getReqPromise( pi.zxtj, {
 | 
												
													
														
															|  | 
 |  | 				startDate: this.startDate,
 | 
												
													
														
															|  | 
 |  | 				endDate: this.endDate,
 | 
												
													
														
															|  | 
 |  | 				isNow: 1
 | 
												
													
														
															|  | 
 |  | 			 }, 'GET');
 | 
												
													
														
															|  | 
 |  | 		},
 | 
												
													
														
															|  | 
 |  | 		getJMGZQSData: function () {//居民关注趋势
 | 
												
													
														
															|  | 
 |  | 			 return getReqPromise( pi.jmgzqs, {
 | 
												
													
														
															|  | 				startDate: this.startDate,
 |  | 				startDate: this.startDate,
 | 
												
													
														
															|  | 				endDate: this.endDate,
 |  | 				endDate: this.endDate,
 | 
												
													
														
															|  | 				signType: t,
 |  | 
 | 
												
													
														
															|  | 				type: this.type
 |  | 				type: this.type
 | 
												
													
														
															|  | 			 }, 'GET');
 |  | 			 }, 'GET');
 | 
												
													
														
															|  | 		},
 |  | 		},
 | 
												
													
														
															|  | 		getZXTJData: function () {
 |  | 
 | 
												
													
														
															|  | 			 return getReqPromise( pi.zxtj, {
 |  | 
 | 
												
													
														
															|  | 
 |  | 		getGZBHQSData: function () {//关注变化趋势
 | 
												
													
														
															|  | 
 |  | 			 return getReqPromise( pi.gzbhqs, {
 | 
												
													
														
															|  | 				startDate: this.startDate,
 |  | 				startDate: this.startDate,
 | 
												
													
														
															|  | 				endDate: this.endDate,
 |  | 				endDate: this.endDate,
 | 
												
													
														
															|  | 				isNow: 1
 |  | 
 | 
												
													
														
															|  | 
 |  | 				type: this.type
 | 
												
													
														
															|  | 			 }, 'GET');
 |  | 			 }, 'GET');
 | 
												
													
														
															|  | 		},
 |  | 		},
 | 
												
													
														
															|  | 		getJGNFWData: function () {
 |  | 
 | 
												
													
														
															|  | 
 |  | 		getJGNFWData: function () {//机构内排行
 | 
												
													
														
															|  | 			return getReqPromise( pi.jgnfw, {
 |  | 			return getReqPromise( pi.jgnfw, {
 | 
												
													
														
															|  | 				startDate: this.startDate,
 |  | 				startDate: this.startDate,
 | 
												
													
														
															|  | 				endDate: this.endDate
 |  | 				endDate: this.endDate
 | 
												
													
														
															|  | 			}, 'GET');
 |  | 			}, 'GET');
 | 
												
													
														
															|  | 		},
 |  | 		},
 | 
												
													
														
															|  | 		getCCFTJData: function(){
 |  | 
 | 
												
													
														
															|  | 		    //获得长处方统计数据
 |  | 
 | 
												
													
														
															|  | 		    return getReqPromise( pi.ccftj, {
 |  | 
 | 
												
													
														
															|  |                 startDate: this.startDate,
 |  | 
 | 
												
													
														
															|  |                 endDate: this.endDate,
 |  | 
 | 
												
													
														
															|  |                 adminTeamId: teamCode
 |  | 
 | 
												
													
														
															|  |             }, 'GET');
 |  | 
 | 
												
													
														
															|  | 		},
 |  | 
 | 
												
													
														
															|  | 		getXQZQData: function () {
 |  | 
 | 
												
													
														
															|  | 			return getReqPromise( pi.xqzq, {
 |  | 
 | 
												
													
														
															|  | 				teamCode: teamCode,
 |  | 
 | 
												
													
														
															|  | 				startDate: this.startDate,
 |  | 
 | 
												
													
														
															|  | 				endDate: this.endDate,
 |  | 
 | 
												
													
														
															|  | 				type: this.type
 |  | 
 | 
												
													
														
															|  | 			}, 'GET');
 |  | 
 | 
												
													
														
															|  | 		},
 |  | 
 | 
												
													
														
															|  | 		getPJMYDData: function () {
 |  | 
 | 
												
													
														
															|  | 
 |  | 		getPJMYDData: function () {//医生平均分
 | 
												
													
														
															|  | 			return getReqPromise( pi.pjmyd, {
 |  | 			return getReqPromise( pi.pjmyd, {
 | 
												
													
														
															|  | 				startDate: this.startDate,
 |  | 				startDate: this.startDate,
 | 
												
													
														
															|  | 				endDate: this.endDate,
 |  | 				endDate: this.endDate,
 | 
												
											
												
													
														
															|  | @ -136,7 +120,7 @@ $(function() {
 | 
												
													
														
															|  | 		loadDate: function () {
 |  | 		loadDate: function () {
 | 
												
													
														
															|  | 			var me = this;
 |  | 			var me = this;
 | 
												
													
														
															|  | 			plus.nativeUI.showWaiting();
 |  | 			plus.nativeUI.showWaiting();
 | 
												
													
														
															|  | 			Promise.all([ me.getZTQKData(), me.getQYQKData(0), me.getZXTJData()]).then(function (ress) {
 |  | 
 | 
												
													
														
															|  | 
 |  | 			Promise.all([ me.getZTQKData(), me.getZXTJData(),me.getJMGZQSData(),me.getGZBHQSData(),me.getJGNFWData(),me.getPJMYDData()]).then(function (ress) {
 | 
												
													
														
															|  | 				if (me.type === 0) {
 |  | 				if (me.type === 0) {
 | 
												
													
														
															|  | 					me.weeksData = ress;
 |  | 					me.weeksData = ress;
 | 
												
													
														
															|  | 				}
 |  | 				}
 | 
												
											
												
													
														
															|  | @ -144,6 +128,7 @@ $(function() {
 | 
												
													
														
															|  | 					me.monthData = ress;
 |  | 					me.monthData = ress;
 | 
												
													
														
															|  | 				}
 |  | 				}
 | 
												
													
														
															|  | 				console.error(JSON.stringify(ress))
 |  | 				console.error(JSON.stringify(ress))
 | 
												
													
														
															|  | 
 |  | 				console.error(JSON.stringify(ress[3]))
 | 
												
													
														
															|  | 				me.setDateInPage();
 |  | 				me.setDateInPage();
 | 
												
													
														
															|  | 				plus.nativeUI.closeWaiting();
 |  | 				plus.nativeUI.closeWaiting();
 | 
												
													
														
															|  | 			});
 |  | 			});
 | 
												
											
												
													
														
															|  | @ -163,9 +148,9 @@ $(function() {
 | 
												
													
														
															|  | 				fwrs = d[1].consultCount + d[2].reservationCount + d[3].articleCount + d[4].guidanceCount + d[5].followupCount;
 |  | 				fwrs = d[1].consultCount + d[2].reservationCount + d[3].articleCount + d[4].guidanceCount + d[5].followupCount;
 | 
												
													
														
															|  | 				pjmyd = d[6].avgScore;
 |  | 				pjmyd = d[6].avgScore;
 | 
												
													
														
															|  | 			}
 |  | 			}
 | 
												
													
														
															|  | 			if (data[2].status == 200) {
 |  | 
 | 
												
													
														
															|  | 				whfs = data[2].data.onReyCount;
 |  | 
 | 
												
													
														
															|  | 				yhfs = data[2].data.totalCount;
 |  | 
 | 
												
													
														
															|  | 
 |  | 			if (data[1].status == 200) {
 | 
												
													
														
															|  | 
 |  | 				whfs = data[1].data.onReyCount;
 | 
												
													
														
															|  | 
 |  | 				yhfs = data[1].data.totalCount;
 | 
												
													
														
															|  | 			}
 |  | 			}
 | 
												
													
														
															|  | 			me.$qyrs.html(qyrs);//qyrs
 |  | 			me.$qyrs.html(qyrs);//qyrs
 | 
												
													
														
															|  | 			me.$fwrs.html("-");//fwrs
 |  | 			me.$fwrs.html("-");//fwrs
 | 
												
											
												
													
														
															|  | @ -185,96 +170,81 @@ $(function() {
 | 
												
													
														
															|  | 			    qy = {dt:[],da:[]},
 |  | 			    qy = {dt:[],da:[]},
 | 
												
													
														
															|  | 			    zxtj = [],
 |  | 			    zxtj = [],
 | 
												
													
														
															|  | 			    jgnfw = [],
 |  | 			    jgnfw = [],
 | 
												
													
														
															|  | 			    ccftj = [],
 |  | 
 | 
												
													
														
															|  | 
 |  | 			    jmgzqs = [],
 | 
												
													
														
															|  | 
 |  | 			    gzbhqs = [],
 | 
												
													
														
															|  | 			    pjmyd = {dt:[],da:[]},
 |  | 			    pjmyd = {dt:[],da:[]},
 | 
												
													
														
															|  | 			    xqzq = {da1: [], da2: []},
 |  | 			    xqzq = {da1: [], da2: []},
 | 
												
													
														
															|  | 			    dArr = $d.init(5);
 |  | 			    dArr = $d.init(5);
 | 
												
													
														
															|  | 			me.dateArr = $d.init(6);
 |  | 			me.dateArr = $d.init(6);
 | 
												
													
														
															|  | 		    if (data[1].status == 200) {
 |  | 		    if (data[1].status == 200) {
 | 
												
													
														
															|  | 		    	qy = me.getDataXY( data[1].data, 1);
 |  | 
 | 
												
													
														
															|  | 
 |  | 		    	zxtj = data[1].data;
 | 
												
													
														
															|  | 
 |  | 		    }
 | 
												
													
														
															|  | 
 |  | 		    if (data[0].status == 200) {
 | 
												
													
														
															|  | 
 |  | 		    	var datas = data[0];
 | 
												
													
														
															|  | 
 |  | 		    	jgnfw = [datas.data[1].consultCount, datas.data[5].followupCount, datas.data[2].reservationCount, datas.data[4].guidanceCount, datas.data[3].articleCount];
 | 
												
													
														
															|  | 
 |  | 		    }
 | 
												
													
														
															|  | 
 |  | 		    if (data[4].status == 200) {
 | 
												
													
														
															|  | 
 |  | 		    	var html = '';
 | 
												
													
														
															|  | 
 |  | 		    	html += '<li>' + (data[4].data[0].consultRK ? ('第' + data[4].data[0].consultRK + '名') : '') + '</li>';
 | 
												
													
														
															|  | 
 |  | 		    	html += '<li>' + (data[4].data[1].followupRK ? ('第' + data[4].data[1].followupRK + '名') : '') + '</li>';
 | 
												
													
														
															|  | 
 |  | 		    	html += '<li>' + (data[4].data[2].reservationRK ? ('第' + data[4].data[2].reservationRK + '名') : '') + '</li>';
 | 
												
													
														
															|  | 
 |  | 		    	html += '<li>' + (data[4].data[3].guidanceRK ? ('第' + data[4].data[3].guidanceRK + '名') : '') + '</li>';
 | 
												
													
														
															|  | 
 |  | 		    	html += '<li>' + (data[4].data[4].articleRK ? ('第' + data[4].data[4].articleRK + '名') : '') + '</li>';
 | 
												
													
														
															|  | 
 |  | 		    	me.$jgnph.html(html);
 | 
												
													
														
															|  | 
 |  | 		    }
 | 
												
													
														
															|  | 
 |  | 		    if (data[5].status == 200) {
 | 
												
													
														
															|  | 
 |  | 		    	pjmyd = me.getDataXY(data[5].data, 2);
 | 
												
													
														
															|  | 				if (me.type === 0) {
 |  | 				if (me.type === 0) {
 | 
												
													
														
															|  | 					qy = $h.contrastDate( dArr, qy, 'dt', 'da');
 |  | 
 | 
												
													
														
															|  | 
 |  | //  				me.dateArr = $d.init(5);
 | 
												
													
														
															|  | 
 |  | 					pjmyd = $h.contrastDate( dArr, pjmyd, 'dt', 'da');
 | 
												
													
														
															|  | 				}
 |  | 				}
 | 
												
													
														
															|  | 				if (me.type === 1) {
 |  | 				if (me.type === 1) {
 | 
												
													
														
															|  | 					var d1 = $h.getWeeksData( qy, 'dt', 'da'),
 |  | 
 | 
												
													
														
															|  | 					qy = d1.da;
 |  | 
 | 
												
													
														
															|  | 
 |  | 					var d1 = $h.getWeeksData( pjmyd, 'dt', 'da'),
 | 
												
													
														
															|  | 
 |  | 					pjmyd = d1.da;
 | 
												
													
														
															|  |     				me.dateArr = d1.dt;
 |  |     				me.dateArr = d1.dt;
 | 
												
													
														
															|  | 				}
 |  | 				}
 | 
												
													
														
															|  | 		    }
 |  | 		    }
 | 
												
													
														
															|  | 		    if (data[2].status == 200) {
 |  | 
 | 
												
													
														
															|  | 		    	zxtj = data[2].data;
 |  | 
 | 
												
													
														
															|  | 		    }
 |  | 
 | 
												
													
														
															|  | 		    if (data[0].status == 200) {
 |  | 
 | 
												
													
														
															|  | 		    	jgnfw = [data[0].data[1].consultCount, data[0].data[5].followupCount, data[0].data[2].reservationCount, data[0].data[4].guidanceCount, data[0].data[3].articleCount];
 |  | 
 | 
												
													
														
															|  | 
 |  | 		    if(data[2].status == 200){
 | 
												
													
														
															|  | 
 |  | 		    	jmgzqs = me.getDataXY(data[2].data, 3);
 | 
												
													
														
															|  | 
 |  | 				if (me.type === 0) {
 | 
												
													
														
															|  | 
 |  | //  				me.dateArr = $d.init(5);
 | 
												
													
														
															|  | 
 |  | 					jmgzqs = $h.contrastDate(dArr, jmgzqs, 'dt', 'da');
 | 
												
													
														
															|  | 
 |  | 				}
 | 
												
													
														
															|  | 
 |  | 				if (me.type === 1) {
 | 
												
													
														
															|  | 
 |  | 					var d1 = $h.getWeeksData( jmgzqs, 'dt', 'da'),
 | 
												
													
														
															|  | 
 |  | 					jmgzqs = d1.da;
 | 
												
													
														
															|  | 
 |  |     				me.dateArr = d1.dt;
 | 
												
													
														
															|  | 
 |  | 				}
 | 
												
													
														
															|  | 		    }
 |  | 		    }
 | 
												
													
														
															|  | //		    if (data[3].status == 200) {
 |  | 
 | 
												
													
														
															|  | //		    	var html = '';
 |  | 
 | 
												
													
														
															|  | //		    	html += '<li>' + (data[3].data[0].consultRK ? ('第' + data[3].data[0].consultRK + '名') : '') + '</li>';
 |  | 
 | 
												
													
														
															|  | //		    	html += '<li>' + (data[3].data[1].followupRK ? ('第' + data[3].data[1].followupRK + '名') : '') + '</li>';
 |  | 
 | 
												
													
														
															|  | //		    	html += '<li>' + (data[3].data[2].reservationRK ? ('第' + data[3].data[2].reservationRK + '名') : '') + '</li>';
 |  | 
 | 
												
													
														
															|  | //		    	html += '<li>' + (data[3].data[3].guidanceRK ? ('第' + data[3].data[3].guidanceRK + '名') : '') + '</li>';
 |  | 
 | 
												
													
														
															|  | //		    	html += '<li>' + (data[3].data[4].articleRK ? ('第' + data[3].data[4].articleRK + '名') : '') + '</li>';
 |  | 
 | 
												
													
														
															|  | //		    	me.$jgnph.html(html);
 |  | 
 | 
												
													
														
															|  | //		    }
 |  | 
 | 
												
													
														
															|  | //		    if (data[4].status == 200) {
 |  | 
 | 
												
													
														
															|  | //		    	pjmyd = me.getDataXY( data[4].data, 2);
 |  | 
 | 
												
													
														
															|  | //				if (me.type === 0) {
 |  | 
 | 
												
													
														
															|  | ////  				me.dateArr = $d.init(5);
 |  | 
 | 
												
													
														
															|  | //					pjmyd = $h.contrastDate( dArr, pjmyd, 'dt', 'da');
 |  | 
 | 
												
													
														
															|  | //				}
 |  | 
 | 
												
													
														
															|  | //				if (me.type === 1) {
 |  | 
 | 
												
													
														
															|  | //					var d1 = $h.getWeeksData( pjmyd, 'dt', 'da'),
 |  | 
 | 
												
													
														
															|  | //					pjmyd = d1.da;
 |  | 
 | 
												
													
														
															|  | //  				me.dateArr = d1.dt;
 |  | 
 | 
												
													
														
															|  | //				}
 |  | 
 | 
												
													
														
															|  | //		    }
 |  | 
 | 
												
													
														
															|  | //		    if (data[5].status == 200) {
 |  | 
 | 
												
													
														
															|  | //				xqzq.dt1 = me.getXQDataXY( data[5].data.inLine, 1);
 |  | 
 | 
												
													
														
															|  | //				xqzq.dt2 = me.getXQDataXY( data[5].data.outLine, 2);
 |  | 
 | 
												
													
														
															|  | //				if (me.type === 0) {
 |  | 
 | 
												
													
														
															|  | ////  				me.dateArr = $d.init(5);
 |  | 
 | 
												
													
														
															|  | //					xqzq.dt1 = $h.contrastDate( dArr, xqzq.dt1, 'dt', 'da');
 |  | 
 | 
												
													
														
															|  | //					xqzq.dt2 = $h.contrastDate( dArr, xqzq.dt2, 'dt', 'da');
 |  | 
 | 
												
													
														
															|  | //				}
 |  | 
 | 
												
													
														
															|  | //				if (me.type === 1) {
 |  | 
 | 
												
													
														
															|  | //					var d1 = $h.getWeeksData( xqzq.dt1, 'dt', 'da'),
 |  | 
 | 
												
													
														
															|  | //						d2 = $h.getWeeksData( xqzq.dt2, 'dt', 'da');
 |  | 
 | 
												
													
														
															|  | //					xqzq.dt1 = d1.da;
 |  | 
 | 
												
													
														
															|  | //					xqzq.dt2 = d2.da;
 |  | 
 | 
												
													
														
															|  | //  				me.dateArr = d1.dt;
 |  | 
 | 
												
													
														
															|  | //				}
 |  | 
 | 
												
													
														
															|  | //		    }
 |  | 
 | 
												
													
														
															|  | //		    if(data[6].status == 200){
 |  | 
 | 
												
													
														
															|  | //		        var ccfdata = data[6].data;
 |  | 
 | 
												
													
														
															|  | //		        ccftj.push(ccfdata.total);
 |  | 
 | 
												
													
														
															|  | //		        ccftj.push(ccfdata.finishCount);
 |  | 
 | 
												
													
														
															|  | //		        ccftj.push(ccfdata.processingCount);
 |  | 
 | 
												
													
														
															|  | //		        ccftj.push(ccfdata.patientCancelCount);
 |  | 
 | 
												
													
														
															|  | //		        ccftj.push(ccfdata.noReviewedCount);
 |  | 
 | 
												
													
														
															|  | //		        ccftj.push(ccfdata.payOuttimeCount);
 |  | 
 | 
												
													
														
															|  | //		    }
 |  | 
 | 
												
													
														
															|  | // 			me.loadCharts( qy, zxtj, jgnfw, null, pjmyd, [ me.setXQSeries( 1, xqzq.dt1), me.setXQSeries( 2, xqzq.dt2)]);
 |  | 
 | 
												
													
														
															|  | 		    me.loadCharts( qy, zxtj, jgnfw, null, null, null, null);
 |  | 
 | 
												
													
														
															|  | 		},
 |  | 
 | 
												
													
														
															|  | 		initQYQKCharts: function ( t, xd, yd) {
 |  | 
 | 
												
													
														
															|  | //			console.log(t)
 |  | 
 | 
												
													
														
															|  | //			console.log(xd)
 |  | 
 | 
												
													
														
															|  | //			console.log(yd)
 |  | 
 | 
												
													
														
															|  | 			$ic.init({
 |  | 
 | 
												
													
														
															|  | 				el: this.$qyqkChart,
 |  | 
 | 
												
													
														
															|  | 				xAxisData: xd,
 |  | 
 | 
												
													
														
															|  | 				seriesData: this.setSeries(t, yd),
 |  | 
 | 
												
													
														
															|  | 				chartsType: 1
 |  | 
 | 
												
													
														
															|  | 			});
 |  | 
 | 
												
													
														
															|  | 
 |  | 		    gzbhqs = data[3].data;
 | 
												
													
														
															|  | 
 |  | 		    me.loadCharts(qy, zxtj, jgnfw, pjmyd, jmgzqs, gzbhqs);
 | 
												
													
														
															|  | 		},
 |  | 		},
 | 
												
													
														
															|  | 		loadCharts: function ( qy, zxtj, jgnfw, ccftj, pjmyd, xqzq) {
 |  | 
 | 
												
													
														
															|  | 			var me = this;
 |  | 
 | 
												
													
														
															|  | 
 |  | 		loadCharts: function(qy, zxtj, jgnfw, pjmyd, jmgzqs, gzbhqs) {
 | 
												
													
														
															|  | 
 |  | 			var me = this,gzbhxAxisData=[],gzbhSeriesData1=[],gzbhSeriesData2=[];
 | 
												
													
														
															|  | 			var count = zxtj.onReyCount + zxtj.totalCount;
 |  | 			var count = zxtj.onReyCount + zxtj.totalCount;
 | 
												
													
														
															|  | 			var zx = count == 0 ? (1/2)*100 : 0;
 |  | 			var zx = count == 0 ? (1/2)*100 : 0;
 | 
												
													
														
															|  | 
 |  | 			jgnfw.splice(1,2);//删除随访和代预约的值
 | 
												
													
														
															|  | 
 |  | 			if (me.type === 0) {
 | 
												
													
														
															|  | 
 |  | 				_.map(gzbhqs,function(item,idx){
 | 
												
													
														
															|  | 
 |  | 					if(idx==0){
 | 
												
													
														
															|  | 
 |  | 						gzbhxAxisData.push(parseInt(item.date.substring(5,7))+"月"+item.date.substring(8,10));
 | 
												
													
														
															|  | 
 |  | 					}else{
 | 
												
													
														
															|  | 
 |  | 						gzbhxAxisData.push(parseInt(item.date.substring(8,10)));
 | 
												
													
														
															|  | 
 |  | 					}
 | 
												
													
														
															|  | 
 |  | 					gzbhSeriesData1.push(item.concernCount);
 | 
												
													
														
															|  | 
 |  | 					gzbhSeriesData2.push(item.cancelCount);
 | 
												
													
														
															|  | 
 |  | 				})
 | 
												
													
														
															|  | 
 |  | 			}
 | 
												
													
														
															|  | 
 |  | 			if (me.type === 1) {
 | 
												
													
														
															|  | 
 |  | 				_.map(gzbhqs,function(item,idx){
 | 
												
													
														
															|  | 
 |  | 					gzbhxAxisData.push("第"+item.date+"周");
 | 
												
													
														
															|  | 
 |  | 					gzbhSeriesData1.push(item.concernCount);
 | 
												
													
														
															|  | 
 |  | 					gzbhSeriesData2.push(item.cancelCount);
 | 
												
													
														
															|  | 
 |  | 				})
 | 
												
													
														
															|  | 
 |  | 			}
 | 
												
													
														
															|  | 
 |  | 			
 | 
												
													
														
															|  | 			Promise.all([
 |  | 			Promise.all([
 | 
												
													
														
															|  | 				//			签约情况
 |  | 
 | 
												
													
														
															|  | //				me.initQYQKCharts( 1, me.dateArr, qy),
 |  | 
 | 
												
													
														
															|  | 				//			资讯统计
 |  | 
 | 
												
													
														
															|  | 
 |  | 				//咨询统计
 | 
												
													
														
															|  | 				$ic.init({
 |  | 				$ic.init({
 | 
												
													
														
															|  | 					el: me.$zxtjChart,
 |  | 					el: me.$zxtjChart,
 | 
												
													
														
															|  | 					seriesData: [{
 |  | 					seriesData: [{
 | 
												
											
												
													
														
															|  | @ -286,63 +256,65 @@ $(function() {
 | 
												
													
														
															|  | 					}],
 |  | 					}],
 | 
												
													
														
															|  | 					chartsType: 2
 |  | 					chartsType: 2
 | 
												
													
														
															|  | 				}),
 |  | 				}),
 | 
												
													
														
															|  | 				//			机构内服务
 |  | 
 | 
												
													
														
															|  | //				$ic.init({
 |  | 
 | 
												
													
														
															|  | //					el: me.$jgChart,
 |  | 
 | 
												
													
														
															|  | //					xAxisData: ['咨询', '随访', '代预约', '指导', '教育'],
 |  | 
 | 
												
													
														
															|  | //					seriesData: jgnfw,
 |  | 
 | 
												
													
														
															|  | //					chartsType: 3,
 |  | 
 | 
												
													
														
															|  | //					color: '#fbba31',
 |  | 
 | 
												
													
														
															|  | //					cb: me.eConsole
 |  | 
 | 
												
													
														
															|  | //				}),
 |  | 
 | 
												
													
														
															|  | 				//          长处方统计
 |  | 
 | 
												
													
														
															|  | //				$ic.init({
 |  | 
 | 
												
													
														
															|  | //				    el: me.$ccfChart,
 |  | 
 | 
												
													
														
															|  | //				    xAxisData: ['总量', '已完成', '进行中', '居民\n取消', '审核\n未通过', '其他\n原因\n取消'],
 |  | 
 | 
												
													
														
															|  | //				    seriesData: ccftj,
 |  | 
 | 
												
													
														
															|  | //				    chartsType: 3,
 |  | 
 | 
												
													
														
															|  | //				    color: '#17B3EC',
 |  | 
 | 
												
													
														
															|  | //				    grid: {
 |  | 
 | 
												
													
														
															|  | //				        x: 35,
 |  | 
 | 
												
													
														
															|  | //                      y: 30,
 |  | 
 | 
												
													
														
															|  | //                      x2: 20,
 |  | 
 | 
												
													
														
															|  | //                      y2: 60
 |  | 
 | 
												
													
														
															|  | //				    },
 |  | 
 | 
												
													
														
															|  | //				    cb: function(){}
 |  | 
 | 
												
													
														
															|  | //				}),
 |  | 
 | 
												
													
														
															|  | 				//			平均医生评分
 |  | 
 | 
												
													
														
															|  | //				$ic.init({
 |  | 
 | 
												
													
														
															|  | //					el: me.$mydChart,
 |  | 
 | 
												
													
														
															|  | //					xAxisData:  me.dateArr,
 |  | 
 | 
												
													
														
															|  | //					seriesData: me.setSeries(2, pjmyd),
 |  | 
 | 
												
													
														
															|  | //					chartsType: 1
 |  | 
 | 
												
													
														
															|  | //				}),
 |  | 
 | 
												
													
														
															|  | 				//			续签转签
 |  | 
 | 
												
													
														
															|  | //				$ic.init({
 |  | 
 | 
												
													
														
															|  | //					el: me.$xqzqChart,
 |  | 
 | 
												
													
														
															|  | //					xAxisData:  me.dateArr,
 |  | 
 | 
												
													
														
															|  | //					seriesData: xqzq,
 |  | 
 | 
												
													
														
															|  | //					chartsType: 1,
 |  | 
 | 
												
													
														
															|  | //					legend: {
 |  | 
 | 
												
													
														
															|  | //				       x: 'right',
 |  | 
 | 
												
													
														
															|  | //				       data: ["签入人数", "签出人数"]
 |  | 
 | 
												
													
														
															|  | //					}
 |  | 
 | 
												
													
														
															|  | //				})
 |  | 
 | 
												
													
														
															|  | 
 |  | 				//机构内服务
 | 
												
													
														
															|  | 
 |  | 				$ic.init({
 | 
												
													
														
															|  | 
 |  | 					el: me.$jgChart,
 | 
												
													
														
															|  | 
 |  | 					xAxisData: ['咨询', '指导', '教育'],//['咨询', '随访', '代预约', '指导', '教育']
 | 
												
													
														
															|  | 
 |  | 					seriesData: jgnfw,
 | 
												
													
														
															|  | 
 |  | 					chartsType: 3,
 | 
												
													
														
															|  | 
 |  | 					color: '#fbba31',
 | 
												
													
														
															|  | 
 |  | 					cb: me.eConsole
 | 
												
													
														
															|  | 
 |  | 				}),
 | 
												
													
														
															|  | 
 |  | 				//平均医生评分
 | 
												
													
														
															|  | 
 |  | 				$ic.init({
 | 
												
													
														
															|  | 
 |  | 					el: me.$mydChart,
 | 
												
													
														
															|  | 
 |  | 					xAxisData:  me.dateArr,
 | 
												
													
														
															|  | 
 |  | 					seriesData: me.setSeries(1, pjmyd),
 | 
												
													
														
															|  | 
 |  | 					chartsType: 1,
 | 
												
													
														
															|  | 
 |  | 				}),
 | 
												
													
														
															|  | 
 |  | 				//居民关注趋势
 | 
												
													
														
															|  | 
 |  | 				$ic.init({
 | 
												
													
														
															|  | 
 |  | 					el: me.$jmgzChart,
 | 
												
													
														
															|  | 
 |  | 					xAxisData: me.dateArr,
 | 
												
													
														
															|  | 
 |  | 					seriesData: me.setSeries(2, jmgzqs),
 | 
												
													
														
															|  | 
 |  | 					chartsType: 1
 | 
												
													
														
															|  | 
 |  | 				}),
 | 
												
													
														
															|  | 
 |  | 				//关注变化趋势
 | 
												
													
														
															|  | 
 |  | 				$ic.init({
 | 
												
													
														
															|  | 
 |  | 					el: me.$gzbhChart,
 | 
												
													
														
															|  | 
 |  | 					xAxisData:  gzbhxAxisData,
 | 
												
													
														
															|  | 
 |  | 					legend: {
 | 
												
													
														
															|  | 
 |  | 				        data:['新增关注','取消关注']
 | 
												
													
														
															|  | 
 |  | 				    },
 | 
												
													
														
															|  | 
 |  | 					seriesData: [{	
 | 
												
													
														
															|  | 
 |  | 									name:"新增关注",
 | 
												
													
														
															|  | 
 |  | 									type: "line",
 | 
												
													
														
															|  | 
 |  | 									symbol: "emptyCircle",
 | 
												
													
														
															|  | 
 |  | 									data: gzbhSeriesData1
 | 
												
													
														
															|  | 
 |  | 								},
 | 
												
													
														
															|  | 
 |  | 								{
 | 
												
													
														
															|  | 
 |  | 									name:"取消关注",
 | 
												
													
														
															|  | 
 |  | 									type: "line",
 | 
												
													
														
															|  | 
 |  | 									symbol: "emptyCircle",
 | 
												
													
														
															|  | 
 |  | 									data: gzbhSeriesData2
 | 
												
													
														
															|  | 
 |  | 								}],
 | 
												
													
														
															|  | 
 |  | 					chartsType: 1
 | 
												
													
														
															|  | 
 |  | 				}),
 | 
												
													
														
															|  | 			]);
 |  | 			]);
 | 
												
													
														
															|  | 		},
 |  | 		},
 | 
												
													
														
															|  | 		getDataXY: function ( d, t) {
 |  | 		getDataXY: function ( d, t) {
 | 
												
													
														
															|  | 			var data = {dt:[],da:[]};
 |  | 			var data = {dt:[],da:[]};
 | 
												
													
														
															|  | 			if (this.type == 0) {
 |  | 			if (this.type == 0) {
 | 
												
													
														
															|  | 				for (var i = 0, len = d.length; i< len; i++) {
 |  | 				for (var i = 0, len = d.length; i< len; i++) {
 | 
												
													
														
															|  | 					data.dt.push(t == 1 ? d[i].applyDate : d[i].dateNo);
 |  | 
 | 
												
													
														
															|  | 					data.da.push(t == 1 ? d[i].signCount : d[i].avgCount);
 |  | 
 | 
												
													
														
															|  | 
 |  | 					data.dt.push(t == 1 ? d[i].applyDate : t == 2 ?d[i].dateNo:d[i].applyDate);
 | 
												
													
														
															|  | 
 |  | 					data.da.push(t == 1 ? d[i].signCount : t == 2 ?d[i].avgCount:d[i].concernCount);
 | 
												
													
														
															|  | 				}
 |  | 				}
 | 
												
													
														
															|  | 				return data;
 |  | 				return data;
 | 
												
													
														
															|  | 			}
 |  | 			}
 | 
												
													
														
															|  | 			if (this.type == 1) {
 |  | 			if (this.type == 1) {
 | 
												
													
														
															|  | 				for (var i = 0, len = d.length; i< len; i++) {
 |  | 				for (var i = 0, len = d.length; i< len; i++) {
 | 
												
													
														
															|  | 					data.dt.push(t == 1 ? d[i].weekOfMonth : d[i].weekNo);
 |  | 
 | 
												
													
														
															|  | 					data.da.push(t == 1 ? d[i].signCount : d[i].avgCount);
 |  | 
 | 
												
													
														
															|  | 
 |  | 					data.dt.push(t == 1 ? d[i].weekOfMonth : t == 2 ?d[i].weekNo:d[i].weekOfMonth);
 | 
												
													
														
															|  | 
 |  | 					data.da.push(t == 1 ? d[i].signCount : t == 2 ?d[i].avgCount:d[i].concernCount);
 | 
												
													
														
															|  | 				}
 |  | 				}
 | 
												
													
														
															|  | 				return data;
 |  | 				return data;
 | 
												
													
														
															|  | 			}
 |  | 			}
 | 
												
											
												
													
														
															|  | @ -360,17 +332,9 @@ $(function() {
 | 
												
													
														
															|  | 			}
 |  | 			}
 | 
												
													
														
															|  | 			return data;
 |  | 			return data;
 | 
												
													
														
															|  | 		},
 |  | 		},
 | 
												
													
														
															|  | 		setXQSeries: function ( type, seriesData) {
 |  | 
 | 
												
													
														
															|  | 			return {
 |  | 
 | 
												
													
														
															|  | 				name: type == 1 ? '签入人数' : type == 2 ? '签出人数' : '',
 |  | 
 | 
												
													
														
															|  | 				type: "line",
 |  | 
 | 
												
													
														
															|  | 				symbol: "emptyCircle",
 |  | 
 | 
												
													
														
															|  | 				data: seriesData
 |  | 
 | 
												
													
														
															|  | 			}
 |  | 
 | 
												
													
														
															|  | 		},
 |  | 
 | 
												
													
														
															|  | 		setSeries: function ( type, seriesData) {
 |  | 		setSeries: function ( type, seriesData) {
 | 
												
													
														
															|  | 			return [{
 |  | 			return [{
 | 
												
													
														
															|  | 				name: type == 1 ? '签约数' : type == 2 ? '医生评分' : type == 3 ? '续签数' : '',
 |  | 
 | 
												
													
														
															|  | 
 |  | 				name: type == 1 ? '医生评分' :'居民关注' ,
 | 
												
													
														
															|  | 				type: "line",
 |  | 				type: "line",
 | 
												
													
														
															|  | 				symbol: "emptyCircle",
 |  | 				symbol: "emptyCircle",
 | 
												
													
														
															|  | 				data: seriesData
 |  | 				data: seriesData
 | 
												
											
												
													
														
															|  | @ -378,11 +342,7 @@ $(function() {
 | 
												
													
														
															|  | 		},
 |  | 		},
 | 
												
													
														
															|  | 		bindEvent: function () {
 |  | 		bindEvent: function () {
 | 
												
													
														
															|  | 			var me = this;
 |  | 			var me = this;
 | 
												
													
														
															|  | 			//	续约/签约切换
 |  | 
 | 
												
													
														
															|  | 			$h.setEvent([
 |  | 			$h.setEvent([
 | 
												
													
														
															|  | 				[ me.$qiehuan, me.es[0], function () {
 |  | 
 | 
												
													
														
															|  | 					me.xyQyEventFun( this, me);
 |  | 
 | 
												
													
														
															|  | 				}],
 |  | 
 | 
												
													
														
															|  | 				[ me.$demoComtop, me.es[0], function () {
 |  | 				[ me.$demoComtop, me.es[0], function () {
 | 
												
													
														
															|  | 					me.xlEventFun( this, me);
 |  | 					me.xlEventFun( this, me);
 | 
												
													
														
															|  | 				}, 'h1'],
 |  | 				}, 'h1'],
 | 
												
											
												
													
														
															|  | @ -393,17 +353,6 @@ $(function() {
 | 
												
													
														
															|  | 				[ me.$linSelGroup, me.es[0], function () {
 |  | 				[ me.$linSelGroup, me.es[0], function () {
 | 
												
													
														
															|  | 					me.switchWeeksToMonth( this, me);
 |  | 					me.switchWeeksToMonth( this, me);
 | 
												
													
														
															|  | 				}, 'li'],
 |  | 				}, 'li'],
 | 
												
													
														
															|  | 				[ $(me.$xqzqChart), me.es[0], function () {
 |  | 
 | 
												
													
														
															|  | 					openWebview('../html/tuanduizhuanqianxiangqing.html', 'tuanduizhuanqianxiangqing', {
 |  | 
 | 
												
													
														
															|  | 						teamCode: teamCode
 |  | 
 | 
												
													
														
															|  | 					})
 |  | 
 | 
												
													
														
															|  | 				}],
 |  | 
 | 
												
													
														
															|  | 				[ me.$zbdj, me.es[0], function () {
 |  | 
 | 
												
													
														
															|  | 					var o = { seriesIndex:1, dataIndex:0};
 |  | 
 | 
												
													
														
															|  | 					o.dataIndex = $(this).index();
 |  | 
 | 
												
													
														
															|  | 					me.eConsole(o);
 |  | 
 | 
												
													
														
															|  | 					console.log($(this).index());
 |  | 
 | 
												
													
														
															|  | 				}, 'li']
 |  | 
 | 
												
													
														
															|  | 			]);
 |  | 			]);
 | 
												
													
														
															|  | 		},
 |  | 		},
 | 
												
													
														
															|  | 		//周月切换
 |  | 		//周月切换
 | 
												
											
												
													
														
															|  | @ -429,41 +378,6 @@ $(function() {
 | 
												
													
														
															|  | 				me.$linSelGroup.hide();
 |  | 				me.$linSelGroup.hide();
 | 
												
													
														
															|  | 			}
 |  | 			}
 | 
												
													
														
															|  | 		},
 |  | 		},
 | 
												
													
														
															|  | 		getSwitchData: function ( t1, t2, t3, that, me) {
 |  | 
 | 
												
													
														
															|  | 			var qy = {dt:[],da:[]};
 |  | 
 | 
												
													
														
															|  | 			Promise.all([me.getQYQKData(t1)]).then(function (res) {
 |  | 
 | 
												
													
														
															|  | 				if (res[0].status == 200) { 
 |  | 
 | 
												
													
														
															|  | 					qy = me.getDataXY( res[0].data, 1),
 |  | 
 | 
												
													
														
															|  | 					    dArr = $d.init(5);
 |  | 
 | 
												
													
														
															|  | 					me.dateArr = $d.init(6);
 |  | 
 | 
												
													
														
															|  | 					if (me.type === 0) {
 |  | 
 | 
												
													
														
															|  | //	    				me.dateArr = $d.init(5);
 |  | 
 | 
												
													
														
															|  | 						qy = $h.contrastDate( dArr, qy, 'dt', 'da');
 |  | 
 | 
												
													
														
															|  | 					}
 |  | 
 | 
												
													
														
															|  | 					if (me.type === 1) {
 |  | 
 | 
												
													
														
															|  | 						var d1 = $h.getWeeksData( qy, 'dt', 'da'),
 |  | 
 | 
												
													
														
															|  | 						qy = d1.da;
 |  | 
 | 
												
													
														
															|  | 	    				me.dateArr = d1.dt;
 |  | 
 | 
												
													
														
															|  | 					}
 |  | 
 | 
												
													
														
															|  | 					me.initQYQKCharts( t2, me.dateArr, qy);
 |  | 
 | 
												
													
														
															|  | 				}
 |  | 
 | 
												
													
														
															|  | 			});
 |  | 
 | 
												
													
														
															|  | 			$(that).attr('data-type', t3);
 |  | 
 | 
												
													
														
															|  | 		},
 |  | 
 | 
												
													
														
															|  | 		//	续约/签约切换时间函数
 |  | 
 | 
												
													
														
															|  | 		xyQyEventFun: function ( that, me) {
 |  | 
 | 
												
													
														
															|  | 			var type = $(that).attr('data-type');
 |  | 
 | 
												
													
														
															|  | 			if(type == '1') {
 |  | 
 | 
												
													
														
															|  | 				me.$qyLab.html('续约情况');
 |  | 
 | 
												
													
														
															|  | 				me.$qyQh.html('切换签约情况');
 |  | 
 | 
												
													
														
															|  | 				me.getSwitchData( 1, 3, '2', that, me);
 |  | 
 | 
												
													
														
															|  | 			}
 |  | 
 | 
												
													
														
															|  | 			if(type == '2') {
 |  | 
 | 
												
													
														
															|  | 				me.$qyLab.html('签约情况');
 |  | 
 | 
												
													
														
															|  | 				me.$qyQh.html('切换续约情况');
 |  | 
 | 
												
													
														
															|  | 				me.getSwitchData( 0, 1, '1', that, me);
 |  | 
 | 
												
													
														
															|  | 			}
 |  | 
 | 
												
													
														
															|  | 		},
 |  | 
 | 
												
													
														
															|  | 		eConsole: function (param) {
 |  | 		eConsole: function (param) {
 | 
												
													
														
															|  | //			return;
 |  | //			return;
 | 
												
													
														
															|  | 			if(typeof param.seriesIndex != 'undefined') {
 |  | 			if(typeof param.seriesIndex != 'undefined') {
 |