lyn7568 vor 5 Jahren
Ursprung
Commit
222b9a8719
5 geänderte Dateien mit 1575 neuen und 1528 gelöschten Zeilen
  1. 1 1
      js/productShow.js
  2. 2 2
      js/public/genCom.js
  3. 2 2
      js/teamInforShow.js
  4. 1569 1522
      js/userInforShow.js
  5. 1 1
      userInforShow.html

+ 1 - 1
js/productShow.js

406
			});
406
			});
407
		}
407
		}
408
	})
408
	})
409
	relatedArticles()
409
	// relatedArticles()
410
	/*产品里面相关文章*/
410
	/*产品里面相关文章*/
411
	function relatedArticles() {
411
	function relatedArticles() {
412
		$.ajax({
412
		$.ajax({

+ 2 - 2
js/public/genCom.js

386
		success: function(data) {
386
		success: function(data) {
387
			if(data.success) {
387
			if(data.success) {
388
				console.log(data)
388
				console.log(data)
389
				if(num == "1" || num == "6") {
389
				if(num == "1" || num == "6" || num== '13') {
390
					$(that).addClass("attenedSpan");
390
					$(that).addClass("attenedSpan");
391
					$(that).text("已关注");
391
					$(that).text("已关注");
392
				} else {
392
				} else {
415
		async: true,
415
		async: true,
416
		success: function(data) {
416
		success: function(data) {
417
			console.log(data.success)
417
			console.log(data.success)
418
			if(num == "1" || num == "6") { //关注专家
418
			if(num == "1" || num == "6" ||num == "13") { //关注专家
419
				$(that).removeClass("attenedSpan");
419
				$(that).removeClass("attenedSpan");
420
				$(that).text("关注");
420
				$(that).text("关注");
421
			} else { //收藏资源或文章
421
			} else { //收藏资源或文章

+ 2 - 2
js/teamInforShow.js

518
			$("#attentBtn").on('click', function() {
518
			$("#attentBtn").on('click', function() {
519
				if(userid && userid != null && userid != "null") {
519
				if(userid && userid != null && userid != "null") {
520
					if($(this).is('.attenedSpan')){
520
					if($(this).is('.attenedSpan')){
521
						cancelCollectionAbout(tId,$(this),6)
521
						cancelCollectionAbout(tId,$(this),13)
522
					} else {
522
					} else {
523
						collectionAbout(tId,$(this), 6);
523
						collectionAbout(tId,$(this),13);
524
					}
524
					}
525
				}else{
525
				}else{
526
					quickLog();
526
					quickLog();

+ 1569 - 1522
js/userInforShow.js

1
$(function() {
2
	loginStatus();//判断个人是否登录
1
$(function () {
2
	loginStatus(); //判断个人是否登录
3
	var userid = $.cookie("userid");
3
	var userid = $.cookie("userid");
4
	var professorId = GetQueryString("professorId");
4
	var professorId = GetQueryString("professorId");
5
	if(navigator.userAgent.match(/(iPhone|iPod|Android|ios)/i)){
6
	 	location.href="http://" + window.location.host + "/e/p.html?id="+professorId;
5
	if (navigator.userAgent.match(/(iPhone|iPod|Android|ios)/i)) {
6
		location.href = "http://" + window.location.host + "/e/p.html?id=" + professorId;
7
	}
7
	}
8
	var oArray=[];
8
	var oArray = [];
9
9
	function subjectShow(data) {
10
	function subjectShow(data) {
10
		if(data != undefined && data.length != 0) {
11
			var subs=strToAry(data)
12
			if(subs.length > 0) {
13
				for(var i = 0; i < subs.length; i++) {
11
		if (data != undefined && data.length != 0) {
12
			var subs = strToAry(data)
13
			if (subs.length > 0) {
14
				for (var i = 0; i < subs.length; i++) {
14
					$("#subjectShow").append("<li>" + subs[i] + "</li>");
15
					$("#subjectShow").append("<li>" + subs[i] + "</li>");
15
				};
16
				};
16
			}
17
			}
17
		}
18
		}
18
	}
19
	}
20
19
	function researchAreaShow(dataStrs, dataStrrecords) {
21
	function researchAreaShow(dataStrs, dataStrrecords) {
20
		if(dataStrs != undefined && dataStrs.length != 0) {
22
		if (dataStrs != undefined && dataStrs.length != 0) {
21
			var html = [];
23
			var html = [];
22
			for(var i = 0; i < dataStrs.length; ++i) {
24
			for (var i = 0; i < dataStrs.length; ++i) {
23
				var dataStr = dataStrs[i];
25
				var dataStr = dataStrs[i];
24
				var $photos = [];
26
				var $photos = [];
25
				//获取头像					
27
				//获取头像					
26
				if(dataStrrecords.length > 0) {
28
				if (dataStrrecords.length > 0) {
27
					$photos = getRecords(dataStrrecords, dataStr.caption);
29
					$photos = getRecords(dataStrrecords, dataStr.caption);
28
				}
30
				}
29
				var isAgree = -1;
31
				var isAgree = -1;
30
				for(var j = 0; j < $photos.length; j++) {
31
					if(userid == $photos[j].id)
32
				for (var j = 0; j < $photos.length; j++) {
33
					if (userid == $photos[j].id)
32
						isAgree++;
34
						isAgree++;
33
				}
35
				}
34
				oArray[i]=dataStr.caption;
35
				if(professorId != userid) {
36
					if(isAgree) {
37
						var showDiv = '<li><div class="favorBox" caption="'+ dataStr.caption +'"><span class="like">'+ dataStr.count +'</span>'+ dataStr.caption +'</div><span class="plus" data-pid="'+ dataStr.professorId +'" data-caption="'+ i + '" data-isagree="' + isAgree + '"></span><div class="favorCount" caption="'+ dataStr.caption +'">';
36
				oArray[i] = dataStr.caption;
37
				if (professorId != userid) {
38
					if (isAgree) {
39
						var showDiv = '<li><div class="favorBox" caption="' + dataStr.caption + '"><span class="like">' + dataStr.count + '</span>' + dataStr.caption + '</div><span class="plus" data-pid="' + dataStr.professorId + '" data-caption="' + i + '" data-isagree="' + isAgree + '"></span><div class="favorCount" caption="' + dataStr.caption + '">';
38
					} else {
40
					} else {
39
						var showDiv = '<li><div class="favorBox" caption="'+ dataStr.caption +'"><span class="like">'+ dataStr.count +'</span>'+ dataStr.caption +'</div><span class="plus" style="background-position-y:-26px" data-pid="'+ dataStr.professorId +'" data-caption="'+ i + '" data-isagree="' + isAgree + '"></span><div class="favorCount" caption="'+ dataStr.caption +'">';
41
						var showDiv = '<li><div class="favorBox" caption="' + dataStr.caption + '"><span class="like">' + dataStr.count + '</span>' + dataStr.caption + '</div><span class="plus" style="background-position-y:-26px" data-pid="' + dataStr.professorId + '" data-caption="' + i + '" data-isagree="' + isAgree + '"></span><div class="favorCount" caption="' + dataStr.caption + '">';
40
					}
42
					}
41
				} else {
43
				} else {
42
					var showDiv = '<li><div class="favorBox" caption="'+ dataStr.caption +'"><span class="like">'+ dataStr.count +'</span>'+ dataStr.caption +'</div><div class="favorCount" caption="'+ dataStr.caption +'">';
44
					var showDiv = '<li><div class="favorBox" caption="' + dataStr.caption + '"><span class="like">' + dataStr.count + '</span>' + dataStr.caption + '</div><div class="favorCount" caption="' + dataStr.caption + '">';
43
				}
45
				}
44
				if($photos.length < 6) {
45
					for(var j = 0; j < $photos.length; ++j) {
46
						if($photos[j].img) {
47
							showDiv += '<span class="like-people" style="background-image: url(../images/head/'+ $photos[j].id +'_s.jpg);"></span>';
46
				if ($photos.length < 6) {
47
					for (var j = 0; j < $photos.length; ++j) {
48
						if ($photos[j].img) {
49
							showDiv += '<span class="like-people" style="background-image: url(../images/head/' + $photos[j].id + '_s.jpg);"></span>';
48
						} else {
50
						} else {
49
							showDiv += '<span class="like-people" style="background-image: url(../images/default-photo.jpg);"></span>';
51
							showDiv += '<span class="like-people" style="background-image: url(../images/default-photo.jpg);"></span>';
50
						}
52
						}
51
					}
53
					}
52
				} else {
54
				} else {
53
					for(var j = $photos.length - 5; j < $photos.length; ++j) {
54
						if($photos[j].img) {
55
							showDiv +='<span class="like-people" style="background-image: url(../images/head/'+ $photos[j].id +'_s.jpg);"></span>';
55
					for (var j = $photos.length - 5; j < $photos.length; ++j) {
56
						if ($photos[j].img) {
57
							showDiv += '<span class="like-people" style="background-image: url(../images/head/' + $photos[j].id + '_s.jpg);"></span>';
56
						} else {
58
						} else {
57
							showDiv += '<span class="like-people" style="background-image: url(../images/default-photo.jpg);"></span>';
59
							showDiv += '<span class="like-people" style="background-image: url(../images/default-photo.jpg);"></span>';
58
						}
60
						}
65
			document.getElementById("researchAreaShow").innerHTML = html.join('');
67
			document.getElementById("researchAreaShow").innerHTML = html.join('');
66
		}
68
		}
67
	}
69
	}
70
68
	function industryShow(data) {
71
	function industryShow(data) {
69
		if(data != undefined && data.length != 0) {
70
			var subs=strToAry(data)
71
			if(subs.length > 0) {
72
				for(var i = 0; i < subs.length; i++) {
72
		if (data != undefined && data.length != 0) {
73
			var subs = strToAry(data)
74
			if (subs.length > 0) {
75
				for (var i = 0; i < subs.length; i++) {
73
					$("#industryShow").append("<li><div class='h4tit'>" + subs[i] + "</div></li>");
76
					$("#industryShow").append("<li><div class='h4tit'>" + subs[i] + "</div></li>");
74
				};
77
				};
75
			}
78
			}
76
		}
79
		}
77
	}
80
	}
81
78
	function projectShow(data) {
82
	function projectShow(data) {
79
		if(data.length > 0) {
80
			for(var i = 0; i < data.length; i++) {
81
				if(!data[i].descp) {
83
		if (data.length > 0) {
84
			for (var i = 0; i < data.length; i++) {
85
				if (!data[i].descp) {
82
					data[i].descp = "";
86
					data[i].descp = "";
83
				}
87
				}
84
				var sDate = "";
88
				var sDate = "";
85
				var eDate = "";
89
				var eDate = "";
86
				if(data[i].startMonth) {
90
				if (data[i].startMonth) {
87
					sDate = data[i].startMonth.substr(0, 4) + "年" + data[i].startMonth.substr(4, 6) + "月";
91
					sDate = data[i].startMonth.substr(0, 4) + "年" + data[i].startMonth.substr(4, 6) + "月";
88
					sDateV = data[i].startMonth.substr(0, 4) + "-" + data[i].startMonth.substr(4, 6);
92
					sDateV = data[i].startMonth.substr(0, 4) + "-" + data[i].startMonth.substr(4, 6);
89
					if(data[i].stopMonth) {
90
						eDate =" - "+ data[i].stopMonth.substr(0, 4) + "年" + data[i].stopMonth.substr(4, 6) + "月";
93
					if (data[i].stopMonth) {
94
						eDate = " - " + data[i].stopMonth.substr(0, 4) + "年" + data[i].stopMonth.substr(4, 6) + "月";
91
					} else {
95
					} else {
92
						eDate = " - "+ "至今";
96
						eDate = " - " + "至今";
93
					}
97
					}
94
				}
98
				}
95
				var projectHtml = '<li>';
99
				var projectHtml = '<li>';
101
			}
105
			}
102
		}
106
		}
103
	}
107
	}
108
104
	function honorShow(data) {
109
	function honorShow(data) {
105
		if(data.length > 0) {
106
			for(var i = 0; i < data.length; i++) {
107
				var timeho="";
108
				if(data[i].year){
109
					timeho = data[i].year+'年';
110
				}else{
111
					data[i].year="";
112
				}
113
				if(!data[i].descp) {
110
		if (data.length > 0) {
111
			for (var i = 0; i < data.length; i++) {
112
				var timeho = "";
113
				if (data[i].year) {
114
					timeho = data[i].year + '年';
115
				} else {
116
					data[i].year = "";
117
				}
118
				if (!data[i].descp) {
114
					data[i].descp = "";
119
					data[i].descp = "";
115
				}
120
				}
116
				var honorHtml = '<li>';
121
				var honorHtml = '<li>';
121
			}
126
			}
122
		}
127
		}
123
	}
128
	}
129
124
	function timeJobShow(data) {
130
	function timeJobShow(data) {
125
		if(data.length > 0) {
126
			for(var i = 0; i < data.length; i++) {
127
				if(data[i].department) {
131
		if (data.length > 0) {
132
			for (var i = 0; i < data.length; i++) {
133
				if (data[i].department) {
128
					var dep = " - " + data[i].department;
134
					var dep = " - " + data[i].department;
129
				} else {
135
				} else {
130
					var dep = ""
136
					var dep = ""
131
				}
137
				}
132
				var sDate = "";
138
				var sDate = "";
133
				var eDate = "";
139
				var eDate = "";
134
				if(data[i].startMonth) {
140
				if (data[i].startMonth) {
135
					sDate = data[i].startMonth.substr(0, 4) + "年" + data[i].startMonth.substr(4, 6) + "月";
141
					sDate = data[i].startMonth.substr(0, 4) + "年" + data[i].startMonth.substr(4, 6) + "月";
136
					sDateV = data[i].startMonth.substr(0, 4) + "-" + data[i].startMonth.substr(4, 6);
142
					sDateV = data[i].startMonth.substr(0, 4) + "-" + data[i].startMonth.substr(4, 6);
137
					if(data[i].stopMonth) {
138
						eDate =" - "+ data[i].stopMonth.substr(0, 4) + "年" + data[i].stopMonth.substr(4, 6) + "月";
143
					if (data[i].stopMonth) {
144
						eDate = " - " + data[i].stopMonth.substr(0, 4) + "年" + data[i].stopMonth.substr(4, 6) + "月";
139
					} else {
145
					} else {
140
						eDate = " - "+ "至今";
146
						eDate = " - " + "至今";
141
					}
147
					}
142
				}
148
				}
143
				var JobHtml = '<li>';
149
				var JobHtml = '<li>';
147
			}
153
			}
148
		}
154
		}
149
	}
155
	}
156
150
	function eduBgShow(data) {
157
	function eduBgShow(data) {
151
		if(data.length > 0) {
152
			for(var i = 0; i < data.length; i++) {
153
				var college="",major="",degree=""
154
				if(data[i].college){
155
					college =' - ' + data[i].college
156
				}else{
157
					data[i].college="";
158
				}
159
				if(data[i].major){
160
					major =' - ' + data[i].major
161
				}else{
162
					data[i].major="";
163
				}
164
				if(data[i].degree){
165
				    degree =' - ' + data[i].degree
166
				     if(data[i].degree==0){
167
				     	degree =""
168
				     }
169
				}else{
170
					data[i].degree="";
171
				}
172
				var timebiye="";
173
				if(data[i].year){
174
					if(data[i].year.trim()=="至今"){
175
						timebiye=data[i].year;
176
					}else{
177
						timebiye=data[i].year+'年';
158
		if (data.length > 0) {
159
			for (var i = 0; i < data.length; i++) {
160
				var college = "",
161
					major = "",
162
					degree = ""
163
				if (data[i].college) {
164
					college = ' - ' + data[i].college
165
				} else {
166
					data[i].college = "";
167
				}
168
				if (data[i].major) {
169
					major = ' - ' + data[i].major
170
				} else {
171
					data[i].major = "";
172
				}
173
				if (data[i].degree) {
174
					degree = ' - ' + data[i].degree
175
					if (data[i].degree == 0) {
176
						degree = ""
178
					}
177
					}
179
				}else{
180
					timebiye="";
178
				} else {
179
					data[i].degree = "";
181
				}
180
				}
182
				
181
				var timebiye = "";
182
				if (data[i].year) {
183
					if (data[i].year.trim() == "至今") {
184
						timebiye = data[i].year;
185
					} else {
186
						timebiye = data[i].year + '年';
187
					}
188
				} else {
189
					timebiye = "";
190
				}
191
183
				var showHtml = '<li><div class="h4Font h4tit">'
192
				var showHtml = '<li><div class="h4Font h4tit">'
184
				showHtml += data[i].school + college + major + degree;
193
				showHtml += data[i].school + college + major + degree;
185
				showHtml +='<small class="h6Font">' + timebiye + '</small></div></li>';
194
				showHtml += '<small class="h6Font">' + timebiye + '</small></div></li>';
186
				$("#eduBgShow").append(showHtml);
195
				$("#eduBgShow").append(showHtml);
187
			}
196
			}
188
		}
197
		}
191
	function getRecords($researchAreaLogs, caption) {
200
	function getRecords($researchAreaLogs, caption) {
192
		var ret = [];
201
		var ret = [];
193
		var t = 0;
202
		var t = 0;
194
		for(var i = 0; i < $researchAreaLogs.length; i++) {
195
			if(caption == $researchAreaLogs[i].caption) {
203
		for (var i = 0; i < $researchAreaLogs.length; i++) {
204
			if (caption == $researchAreaLogs[i].caption) {
196
				ret[t] = {
205
				ret[t] = {
197
					id: $researchAreaLogs[i].opreteProfessorId,
206
					id: $researchAreaLogs[i].opreteProfessorId,
198
					img: $researchAreaLogs[i].hasHeadImage
207
					img: $researchAreaLogs[i].hasHeadImage
202
		}
211
		}
203
		return ret;
212
		return ret;
204
	}
213
	}
205
	function openAttend(){//打开收藏与关注
214
215
	function openAttend() { //打开收藏与关注
206
		$(".mainNavUl li.rightbtn").addClass("liNow").siblings().removeClass("liNow");
216
		$(".mainNavUl li.rightbtn").addClass("liNow").siblings().removeClass("liNow");
207
		$(".navconBox .moreBu").show();
217
		$(".navconBox .moreBu").show();
208
		$(".wendaNav").hide();
218
		$(".wendaNav").hide();
209
		$("#item8user").show().siblings().hide();
219
		$("#item8user").show().siblings().hide();
210
		$(".moreBuUl li.attentType").eq(0).addClass("liNow").siblings().removeClass("liNow");
220
		$(".moreBuUl li.attentType").eq(0).addClass("liNow").siblings().removeClass("liNow");
211
		$("#item8drop1").show().siblings().hide();
221
		$("#item8drop1").show().siblings().hide();
212
		watchO={
213
			watchTime:"",
214
			watchObjId:"",
222
		watchO = {
223
			watchTime: "",
224
			watchObjId: "",
215
		};
225
		};
216
		var pa=$(".moreNavUl.moreBuUl>li.liNow").attr("rel")
217
		$("#"+pa).find("ul").html("")
218
		$("#"+pa).find(".js-load-more").show();
219
		collectSorts(1,true);
226
		var pa = $(".moreNavUl.moreBuUl>li.liNow").attr("rel")
227
		$("#" + pa).find("ul").html("")
228
		$("#" + pa).find(".js-load-more").show();
229
		collectSorts(1, true);
220
	}
230
	}
221
	function researchAlert(cap){
231
232
	function researchAlert(cap) {
222
		$.ajax({
233
		$.ajax({
223
			"url": "/ajax/researchAreaLog/ql",
234
			"url": "/ajax/researchAreaLog/ql",
224
			"type": "get",
235
			"type": "get",
227
				"caption": cap,
238
				"caption": cap,
228
				"rows": 1000
239
				"rows": 1000
229
			},
240
			},
230
			"success": function(data) {
231
				if(data.success) {
241
			"success": function (data) {
242
				if (data.success) {
232
					console.log(data)
243
					console.log(data)
233
					$("#areaCon").html("");
244
					$("#areaCon").html("");
234
					var $info = data.data;
245
					var $info = data.data;
236
					$(".resAreaCover").fadeIn();
247
					$(".resAreaCover").fadeIn();
237
					$(".resAreaTip").addClass("displayNone")
248
					$(".resAreaTip").addClass("displayNone")
238
					$(".resAreaCon").show()
249
					$(".resAreaCon").show()
239
					if($info.length == 0) {
250
					if ($info.length == 0) {
240
						$(".resAreaCon").hide();
251
						$(".resAreaCon").hide();
241
						$(".resAreaTip").removeClass("displayNone")
252
						$(".resAreaTip").removeClass("displayNone")
242
						return;
253
						return;
243
					}
254
					}
244
					var arr=[];
245
					for(var i in $info) {
246
						arr[i]=$info[i].opreteProfessorId;
255
					var arr = [];
256
					for (var i in $info) {
257
						arr[i] = $info[i].opreteProfessorId;
247
					}
258
					}
248
					detailPro(arr,"areaCon");
259
					detailPro(arr, "areaCon");
249
				}
260
				}
250
			}
261
			}
251
		});
262
		});
254
	var rows = 20,
265
	var rows = 20,
255
		pageNo = 1,
266
		pageNo = 1,
256
		dataO = {
267
		dataO = {
257
			artPublishTime:"",
258
			artShareId:"",
259
			
260
			resPublishTime:"",
261
			resShareId:"",
262
			
268
			artPublishTime: "",
269
			artShareId: "",
270
271
			resPublishTime: "",
272
			resShareId: "",
273
263
			serModifyTime: "",
274
			serModifyTime: "",
264
			serId: "",
275
			serId: "",
265
			
266
			patTime:"",
267
			patId:"",
268
			
269
			parTime:"",
270
			parId:"",
271
			
272
			AnsTime:"",
273
			AnsId:"",
274
			
275
			QuTime:"",
276
			QuId:"",
276
277
			patTime: "",
278
			patId: "",
279
280
			parTime: "",
281
			parId: "",
282
283
			AnsTime: "",
284
			AnsId: "",
285
286
			QuTime: "",
287
			QuId: "",
277
		},
288
		},
278
		watchO={
279
			beiTime:"",
280
			beiProId:"",
281
			
282
			watchTime:"",
283
			watchObjId:"",
284
			
285
			WATime:"",
286
			WAId:"",
287
			
288
			WQTime:"",
289
			WQId:"",
289
		watchO = {
290
			beiTime: "",
291
			beiProId: "",
292
293
			watchTime: "",
294
			watchObjId: "",
295
296
			WATime: "",
297
			WAId: "",
298
299
			WQTime: "",
300
			WQId: "",
290
		};
301
		};
291
	var oAjax = function(url, dataS, otype, oFun,beforeFun,completeFun) {
302
	var oAjax = function (url, dataS, otype, oFun, beforeFun, completeFun) {
292
			$.ajax({
303
			$.ajax({
293
				url:url,
304
				url: url,
294
				dataType: 'json',
305
				dataType: 'json',
295
				type: otype,
306
				type: otype,
296
				data: dataS,
307
				data: dataS,
297
				traditional: true,
308
				traditional: true,
298
				beforeSend: beforeFun,
309
				beforeSend: beforeFun,
299
				success: function(res) {
300
					if(res.success) {
310
				success: function (res) {
311
					if (res.success) {
301
						oFun(res)
312
						oFun(res)
302
					}
313
					}
303
				},
314
				},
304
				complete:completeFun
305
	            
315
				complete: completeFun
316
306
			});
317
			});
307
		},	
308
		insertNodata = function (targetE,newStr) {
309
            var parent = document.getElementById(targetE).parentNode;
310
            var kong = document.createElement("div");
311
            kong.className = "con-kong";
312
            kong.innerHTML ='<div class="picbox picNull"></div>'+
313
			            '<div class="txtbox">暂时没有符合该搜索条件的内容</div>'
314
            if(newStr){
315
            	kong.querySelector(".txtbox").innerHTML = newStr;
316
            }
317
            if (parent.firstChild.className == "con-kong") {
318
                return
319
            } else {
320
                parent.insertBefore(kong,parent.firstChild);
321
            }
322
323
        },
324
        removeNodata = function (targetE) {
325
            var parent = document.getElementById(targetE).parentNode;
326
            if (parent.firstChild.className == "con-kong") {
327
                parent.removeChild(parent.firstChild);
328
            } else {
329
                return
330
            }
331
        },
332
       	getUserInfo=function() {
333
       		oAjax("/ajax/professor/info/"+ professorId,{}, "get", function(data){
318
		},
319
		insertNodata = function (targetE, newStr) {
320
			var parent = document.getElementById(targetE).parentNode;
321
			var kong = document.createElement("div");
322
			kong.className = "con-kong";
323
			kong.innerHTML = '<div class="picbox picNull"></div>' +
324
				'<div class="txtbox">暂时没有符合该搜索条件的内容</div>'
325
			if (newStr) {
326
				kong.querySelector(".txtbox").innerHTML = newStr;
327
			}
328
			if (parent.firstChild.className == "con-kong") {
329
				return
330
			} else {
331
				parent.insertBefore(kong, parent.firstChild);
332
			}
333
334
		},
335
		removeNodata = function (targetE) {
336
			var parent = document.getElementById(targetE).parentNode;
337
			if (parent.firstChild.className == "con-kong") {
338
				parent.removeChild(parent.firstChild);
339
			} else {
340
				return
341
			}
342
		},
343
		getUserInfo = function () {
344
			oAjax("/ajax/professor/info/" + professorId, {}, "get", function (data) {
334
				var $info = data.data;
345
				var $info = data.data;
335
				if($info.hasHeadImage){
336
					$("#proHead").css("background-image","url(/images/head/"+ $info.id +"_l.jpg)");
346
				if ($info.hasHeadImage) {
347
					$("#proHead").css("background-image", "url(/images/head/" + $info.id + "_l.jpg)");
337
				}
348
				}
338
				$("#proName").text($info.name);
349
				$("#proName").text($info.name);
339
				var oStyS=autho($info.authType,$info.orgAuth,$info.authStatus);
340
				$("#proAuth").addClass(oStyS.sty); $("#proAuth").attr("title",oStyS.title);
341
				if($info.address){
350
				var oStyS = autho($info.authType, $info.orgAuth, $info.authStatus);
351
				$("#proAuth").addClass(oStyS.sty);
352
				$("#proAuth").attr("title", oStyS.title);
353
				if ($info.address) {
342
					$("#proAddress").html($info.address + "<span style='margin-right:10px;'></span>");
354
					$("#proAddress").html($info.address + "<span style='margin-right:10px;'></span>");
343
				}
355
				}
344
				var proOther="";
345
				if($info.orgName){
346
					if($info.department){
347
						if($info.office){
356
				var proOther = "";
357
				if ($info.orgName) {
358
					if ($info.department) {
359
						if ($info.office) {
348
							proOther = $info.orgName + "," + $info.department + "," + $info.office
360
							proOther = $info.orgName + "," + $info.department + "," + $info.office
349
						}else{
361
						} else {
350
							proOther = $info.orgName + "," + $info.department
362
							proOther = $info.orgName + "," + $info.department
351
						}
363
						}
352
					}else{
353
						if($info.office){
354
							proOther = $info.orgName +"," + $info.office
355
						}else{
364
					} else {
365
						if ($info.office) {
366
							proOther = $info.orgName + "," + $info.office
367
						} else {
356
							proOther = $info.orgName
368
							proOther = $info.orgName
357
						}
369
						}
358
					}
370
					}
359
				}else{
360
					if($info.department){
361
						if($info.office){
362
							proOther =  $info.department + "," + $info.office
363
						}else{
364
							proOther =  $info.department
371
				} else {
372
					if ($info.department) {
373
						if ($info.office) {
374
							proOther = $info.department + "," + $info.office
375
						} else {
376
							proOther = $info.department
365
						}
377
						}
366
					}else{
367
						if($info.office){
378
					} else {
379
						if ($info.office) {
368
							proOther = $info.office
380
							proOther = $info.office
369
						}
381
						}
370
					}
382
					}
371
				}
383
				}
372
				$("#proOther").text(proOther);
384
				$("#proOther").text(proOther);
373
				var llqtitle=$info.name + "-" + proOther.replace(/,/gi,"-") + "-科袖网";//修改浏览器title信息
374
				if($info.title){
385
				var llqtitle = $info.name + "-" + proOther.replace(/,/gi, "-") + "-科袖网"; //修改浏览器title信息
386
				if ($info.title) {
375
					$("#proTit").html($info.title + "<span style='margin-right:10px;'></span>");
387
					$("#proTit").html($info.title + "<span style='margin-right:10px;'></span>");
376
					llqtitle = $info.name + "-" + $info.title + "-" + proOther.replace(/,/gi,"-") + "-科袖网";
388
					llqtitle = $info.name + "-" + $info.title + "-" + proOther.replace(/,/gi, "-") + "-科袖网";
377
				}
389
				}
378
				document.title = llqtitle;
390
				document.title = llqtitle;
379
				
391
380
				//主页浏览量
392
				//主页浏览量
381
				$("#viewNums").text($info.pageViews);
393
				$("#viewNums").text($info.pageViews);
382
				//个人简介
394
				//个人简介
383
				if($info.descp) {
395
				if ($info.descp) {
384
					$("#descpS").parents(".coninfobox").removeClass("displayNone");
396
					$("#descpS").parents(".coninfobox").removeClass("displayNone");
385
					$("#item1user>.nodatabox").addClass("displayNone");
397
					$("#item1user>.nodatabox").addClass("displayNone");
386
					$("#descpS").text($info.descp);
398
					$("#descpS").text($info.descp);
387
				}
399
				}
388
				//学术领域					
400
				//学术领域					
389
				if($info.subject) {
401
				if ($info.subject) {
390
					$("#subjectShow").parents(".coninfobox").removeClass("displayNone");
402
					$("#subjectShow").parents(".coninfobox").removeClass("displayNone");
391
					$("#item1user>.nodatabox").addClass("displayNone");
403
					$("#item1user>.nodatabox").addClass("displayNone");
392
					subjectShow($info.subject);
404
					subjectShow($info.subject);
393
				}
405
				}
394
				//研究方向
406
				//研究方向
395
				if($info.researchAreas.length) {
407
				if ($info.researchAreas.length) {
396
					$("#researchAreaShow").parents(".coninfobox").removeClass("displayNone");
408
					$("#researchAreaShow").parents(".coninfobox").removeClass("displayNone");
397
					$("#item1user>.nodatabox").addClass("displayNone");
409
					$("#item1user>.nodatabox").addClass("displayNone");
398
					researchAreaShow($info.researchAreas, $info.editResearchAreaLogs);
410
					researchAreaShow($info.researchAreas, $info.editResearchAreaLogs);
399
				}
411
				}
400
				//行业领域	
412
				//行业领域	
401
				if($info.industry) {
413
				if ($info.industry) {
402
					$("#industryShow").parents(".coninfobox").removeClass("displayNone");
414
					$("#industryShow").parents(".coninfobox").removeClass("displayNone");
403
					$("#item1user>.nodatabox").addClass("displayNone");
415
					$("#item1user>.nodatabox").addClass("displayNone");
404
					industryShow($info.industry);
416
					industryShow($info.industry);
405
				}
417
				}
406
				//教育背景					
418
				//教育背景					
407
				if($info.edus.length) {
419
				if ($info.edus.length) {
408
					eduBgShow($info.edus);
420
					eduBgShow($info.edus);
409
				} else {
421
				} else {
410
					$("#eduBgShow").parents(".coninfobox").hide();
422
					$("#eduBgShow").parents(".coninfobox").hide();
411
				}
423
				}
412
				//兼职
424
				//兼职
413
				if($info.jobs.length) {
425
				if ($info.jobs.length) {
414
					timeJobShow($info.jobs);
426
					timeJobShow($info.jobs);
415
				} else {
427
				} else {
416
					$("#timeJobShow").parents(".coninfobox").hide();
428
					$("#timeJobShow").parents(".coninfobox").hide();
417
				}
429
				}
418
				//项目
430
				//项目
419
				if($info.projects.length) {
431
				if ($info.projects.length) {
420
					projectShow($info.projects)
432
					projectShow($info.projects)
421
				} else {
433
				} else {
422
					$("#projectShow").parents(".coninfobox").hide();
434
					$("#projectShow").parents(".coninfobox").hide();
423
				}
435
				}
424
				//荣誉
436
				//荣誉
425
				if($info.honors.length) {
437
				if ($info.honors.length) {
426
					honorShow($info.honors);
438
					honorShow($info.honors);
427
				} else {
439
				} else {
428
					$("#honorShow").parents(".coninfobox").hide();
440
					$("#honorShow").parents(".coninfobox").hide();
429
				}
441
				}
430
				
431
				if($info.honors.length == 0 && $info.projects.length == 0 && $info.jobs.length == 0 && $info.edus.length == 0){
442
443
				if ($info.honors.length == 0 && $info.projects.length == 0 && $info.jobs.length == 0 && $info.edus.length == 0) {
432
					$("#item7user>.nodatabox").show();
444
					$("#item7user>.nodatabox").show();
433
					$("#item7user>.nodatabox").find(".noContip").text("用户尚未完善详细资料")
445
					$("#item7user>.nodatabox").find(".noContip").text("用户尚未完善详细资料")
434
				}
446
				}
435
				
447
436
				var weibotitle = $info.name;
448
				var weibotitle = $info.name;
437
				var weibourl = window.location.href;
449
				var weibourl = window.location.href;
438
				var weibopic ="http://"+window.location.host+"/images/head/"+ $info.id +"_l.jpg";
439
				$("#weibo").attr("href","http://service.weibo.com/share/share.php?appkey=3677230589&title="+weibotitle+"&url="+weibourl+"&pic="+weibopic+"&ralateUid=6242830109&searchPic=false&style=simple");
450
				var weibopic = "http://" + window.location.host + "/images/head/" + $info.id + "_l.jpg";
451
				$("#weibo").attr("href", "http://service.weibo.com/share/share.php?appkey=3677230589&title=" + weibotitle + "&url=" + weibourl + "&pic=" + weibopic + "&ralateUid=6242830109&searchPic=false&style=simple");
440
			});
452
			});
441
		},
453
		},
442
		teamListVal=function(isbind) {
443
			var aimId="proTeam",aimIdF="showTeam",newStr="用户暂无专家团队"
444
			oAjax("/ajax/team/myTeam",{
454
		teamListVal = function (isbind) {
455
			var aimId = "proTeam",
456
				aimIdF = "showTeam",
457
				newStr = "用户暂无专家团队"
458
			oAjax("/ajax/team/myTeam", {
445
				professor: professorId,
459
				professor: professorId,
446
				status: 3,
460
				status: 3,
447
				pageSize: rows,
461
				pageSize: rows,
448
				pageNo: pageNo
462
				pageNo: pageNo
449
			}, "get", function(res){
463
			}, "get", function (res) {
450
				var $info = res.data.data;
464
				var $info = res.data.data;
451
				if($info.length > 0) {
452
					$("#"+aimId).show()
453
					$("#"+aimIdF).parents(".leftconItem").find(".nodatabox").hide()
454
					if(userid!=professorId){
455
						$("#"+aimIdF).parents(".conItem").removeClass("displayNone");
465
				if ($info.length > 0) {
466
					$("#" + aimId).show()
467
					$("#" + aimIdF).parents(".leftconItem").find(".nodatabox").hide()
468
					if (userid != professorId) {
469
						$("#" + aimIdF).parents(".conItem").removeClass("displayNone");
456
					}
470
					}
457
			
458
					for(var i = 0; i < $info.length; i++) {
471
					for (var i = 0; i < $info.length; i++) {
459
						var itemlist = '<li>';
472
						var itemlist = '<li>';
460
							itemlist += '<a target="_blank" href="teamInfoShow.html?id='+$info[i].id+'" class="flexCenter urlgo" style="min-height:60px;">';
461
							itemlist += '<div class="madiaInfo" style="padding-left:0">';
462
							itemlist += '<p class="h1Font ellipsisSty-2">'+$info[i].name+' <small> 团队人数 <span class="teamMembers"></span>人</small></p>';
463
							itemlist += '<div class="h2Font clearfix">';
464
							itemlist += '<span>' + $info[i].city + '</span>';
465
							itemlist += ' <span>' + $info[i].orgName + '</span>'
466
							itemlist += '</div></div>';
467
							itemlist += '</a></li>';
473
						itemlist += '<a target="_blank" href="teamInfoShow.html?id=' + $info[i].id + '" class="flexCenter urlgo" style="min-height:60px;">';
474
						itemlist += '<div class="madiaInfo" style="padding-left:0">';
475
						itemlist += '<p class="h1Font ellipsisSty-2">' + $info[i].name + ' <small> 团队人数 <span class="teamMembers"></span>人</small></p>';
476
						itemlist += '<div class="h2Font clearfix">';
477
						itemlist += '<span>' + $info[i].city + '</span>';
478
						itemlist += ' <span>' + $info[i].orgName + '</span>'
479
						itemlist += '</div></div>';
480
						itemlist += '</a></li>';
468
						var $itemlist = $(itemlist);
481
						var $itemlist = $(itemlist);
469
						$("#"+aimId).append($itemlist)
482
						$("#" + aimId).append($itemlist)
470
						teamProCount($info[i].id, $itemlist)
483
						teamProCount($info[i].id, $itemlist)
471
						if(isbind && i < 5 && userid!=professorId){
484
						if (isbind && i < 5 && userid != professorId) {
472
							var $itemlist = $(itemlist);
485
							var $itemlist = $(itemlist);
473
							$("#"+aimIdF).append($itemlist);
486
							$("#" + aimIdF).append($itemlist);
474
							teamProCount($info[i].id, $itemlist)
487
							teamProCount($info[i].id, $itemlist)
475
						}
488
						}
476
					}
489
					}
477
				}
490
				}
478
				var liLen=document.getElementById(aimId).querySelectorAll("li").length;
479
                removeNodata(aimId);
480
                if($info.length == 0 && liLen == 0 ){
481
                	$("#"+aimId).hide()
482
                    insertNodata(aimId,newStr);
483
                }
484
                if(isbind){
485
                	$("#"+aimId).parent().find(".js-load-more").unbind("click").on("click",function(){
491
				var liLen = document.getElementById(aimId).querySelectorAll("li").length;
492
				removeNodata(aimId);
493
				if ($info.length == 0 && liLen == 0) {
494
					$("#" + aimId).hide()
495
					insertNodata(aimId, newStr);
496
				}
497
				if (isbind) {
498
					$("#" + aimId).parent().find(".js-load-more").unbind("click").on("click", function () {
486
						pageNo++
499
						pageNo++
487
						teamListVal(false)
500
						teamListVal(false)
488
					})
501
					})
489
                }
502
				}
490
				if ($info.length < rows) {
503
				if ($info.length < rows) {
491
                    $("#"+aimId).parent().find(".js-load-more").unbind("click");
492
                    $("#"+aimId).parent().find(".js-load-more").hide();
493
                }
494
			},function(){
495
				$("#"+aimId).parent().find(".js-load-more").attr("disabled",true);
496
	       		$("#"+aimId).parent().find(".js-load-more").addClass("active");
497
			},function(){
498
				$("#"+aimId).parent().find(".js-load-more").removeAttr("disabled");
499
	        	$("#"+aimId).parent().find(".js-load-more").removeClass("active");
504
					$("#" + aimId).parent().find(".js-load-more").unbind("click");
505
					$("#" + aimId).parent().find(".js-load-more").hide();
506
				}
507
			}, function () {
508
				$("#" + aimId).parent().find(".js-load-more").attr("disabled", true);
509
				$("#" + aimId).parent().find(".js-load-more").addClass("active");
510
			}, function () {
511
				$("#" + aimId).parent().find(".js-load-more").removeAttr("disabled");
512
				$("#" + aimId).parent().find(".js-load-more").removeClass("active");
500
			})
513
			})
501
		},
514
		},
502
       	demandListVal=function(isbind) {
503
			oAjax("/ajax/demand/pq",{
504
				"state":[1],
505
				"uid":professorId,
506
				"pageSize":5
507
			}, "get", function(data){
515
		demandListVal = function (isbind) {
516
			oAjax("/ajax/demand/pq", {
517
				"state": [1],
518
				"uid": professorId,
519
				"pageSize": 5
520
			}, "get", function (data) {
508
				var $info = data.data.data;
521
				var $info = data.data.data;
509
				if($info.length > 0){
522
				if ($info.length > 0) {
510
					$("#showDemand").parents(".coninfobox").removeClass("displayNone");
523
					$("#showDemand").parents(".coninfobox").removeClass("displayNone");
511
					$("#item1user>.nodatabox").addClass("displayNone");
524
					$("#item1user>.nodatabox").addClass("displayNone");
512
					for(var i = 0; i < $info.length; i++) {
513
						var liStr=$("<li></li>").appendTo("#showDemand");
514
						var $data=$info[i];
515
						var sowU="";
516
						if($data.pageViews!=0){
517
							sowU='<li><span>浏览量 '+$data.pageViews +'</span></li>'
525
					for (var i = 0; i < $info.length; i++) {
526
						var liStr = $("<li></li>").appendTo("#showDemand");
527
						var $data = $info[i];
528
						var sowU = "";
529
						if ($data.pageViews != 0) {
530
							sowU = '<li><span>浏览量 ' + $data.pageViews + '</span></li>'
531
						}
532
						var strCon = '';
533
						strCon += '<a class="" target="_blank" href="demandShow.html?demandId=' + $data.id + '" class="madiaInfo">'
534
						strCon += '<p class="h1Font ellipsisSty">' + $data.title + '</p>'
535
						strCon += '<ul class="showliTop h3Font clearfix">'
536
						strCon += '<li><span>发布于 ' + TimeTr($data.createTime) + '</span></li>'
537
						strCon += sowU
538
						strCon += '</ul>'
539
						strCon += '<p class="h2Font ellipsisSty-2">' + $data.descp + '</p>'
540
						strCon += '<ul class="showli clearfix h3Font">'
541
542
						if ($data.city) {
543
							strCon += '<li>所在城市:' + $data.city + '</li>'
518
						}
544
						}
519
						var strCon='';
520
							strCon+='<a class="" target="_blank" href="demandShow.html?demandId='+$data.id+'" class="madiaInfo">'
521
							strCon+='<p class="h1Font ellipsisSty">'+ $data.title +'</p>'
522
							strCon+='<ul class="showliTop h3Font clearfix">'
523
							strCon+='<li><span>发布于 '+TimeTr($data.createTime)+'</span></li>'
524
							strCon+= sowU
525
							strCon+='</ul>'
526
							strCon+='<p class="h2Font ellipsisSty-2">'+$data.descp+'</p>'
527
							strCon+='<ul class="showli clearfix h3Font">'
528
							
529
							if($data.city){ strCon+='<li>所在城市:'+$data.city+'</li>' }
530
							if($data.duration!=0){ strCon+='<li>预计周期:'+demandDuration[$data.duration]+'</li>' }
531
							if($data.cost!=0){ strCon+='<li>费用预算:'+demandCost[$data.cost]+'</li>' }
532
							if($data.invalidDay){ strCon+='<li>有效期至:'+TimeTr($data.invalidDay)+'</li>' }
533
							
534
							strCon+='</ul>'
535
							strCon+='</a>'
545
						if ($data.duration != 0) {
546
							strCon += '<li>预计周期:' + demandDuration[$data.duration] + '</li>'
547
						}
548
						if ($data.cost != 0) {
549
							strCon += '<li>费用预算:' + demandCost[$data.cost] + '</li>'
550
						}
551
						if ($data.invalidDay) {
552
							strCon += '<li>有效期至:' + TimeTr($data.invalidDay) + '</li>'
553
						}
554
555
						strCon += '</ul>'
556
						strCon += '</a>'
536
						$(strCon).appendTo(liStr);
557
						$(strCon).appendTo(liStr);
537
					}
558
					}
538
				}else{
559
				} else {
539
					$("#showDemand").parents(".needinfobox").addClass("displayNone");
560
					$("#showDemand").parents(".needinfobox").addClass("displayNone");
540
				}
561
				}
541
			})
562
			})
542
		},
563
		},
543
        articalListVal=function(isbind){
544
			var aimId="proArticel",aimIdF="showArticle",newStr="用户尚未发布任何文章"
545
			oAjax("/ajax/article/publish",{
564
		articalListVal = function (isbind) {
565
			var aimId = "proArticel",
566
				aimIdF = "showArticle",
567
				newStr = "用户尚未发布任何文章"
568
			oAjax("/ajax/article/publish", {
546
				"category": "1",
569
				"category": "1",
547
				"owner":professorId,
548
				"publishTime":dataO.artPublishTime,
570
				"owner": professorId,
571
				"publishTime": dataO.artPublishTime,
549
				"shareId": dataO.artShareId,
572
				"shareId": dataO.artShareId,
550
				"rows": rows
573
				"rows": rows
551
			}, "get", function(res){
574
			}, "get", function (res) {
552
				var $info = res.data;
575
				var $info = res.data;
553
				if($info.length > 0) {
554
					$("#"+aimId).show()
555
					$("#"+aimIdF).parents(".leftconItem").find(".nodatabox").hide()
556
					$("#"+aimIdF).parents(".coninfobox").removeClass("displayNone");
576
				if ($info.length > 0) {
577
					$("#" + aimId).show()
578
					$("#" + aimIdF).parents(".leftconItem").find(".nodatabox").hide()
579
					$("#" + aimIdF).parents(".coninfobox").removeClass("displayNone");
557
					dataO.artPublishTime = $info[$info.length - 1].publishTime;
580
					dataO.artPublishTime = $info[$info.length - 1].publishTime;
558
					dataO.artShareId = $info[$info.length - 1].shareId;
581
					dataO.artShareId = $info[$info.length - 1].shareId;
559
			
560
					for(var i = 0; i < $info.length; i++) {
561
						var sowU="",hasImg="/images/default-artical.jpg"
562
						if($info[i].articleImg) {
563
							hasImg="/data/article/" + $info[i].articleImg
582
583
					for (var i = 0; i < $info.length; i++) {
584
						var sowU = "",
585
							hasImg = "/images/default-artical.jpg"
586
						if ($info[i].articleImg) {
587
							hasImg = "/data/article/" + $info[i].articleImg
564
						}
588
						}
565
						if($info[i].pageViews!=0){
566
							if($info[i].articleAgree!=0){
567
								sowU='<li><span>阅读量 '+$info[i].pageViews+'</span></li><li><span>赞 '+$info[i].articleAgree+'</span></li>'
568
							}else{
569
								sowU='<li><span>阅读量 '+$info[i].pageViews+'</span></li>'
589
						if ($info[i].pageViews != 0) {
590
							if ($info[i].articleAgree != 0) {
591
								sowU = '<li><span>阅读量 ' + $info[i].pageViews + '</span></li><li><span>赞 ' + $info[i].articleAgree + '</span></li>'
592
							} else {
593
								sowU = '<li><span>阅读量 ' + $info[i].pageViews + '</span></li>'
570
							}
594
							}
571
						}
595
						}
572
						var itemlist = '<li>';
596
						var itemlist = '<li>';
573
							itemlist += '<a href="/'+pageUrl('a',$info[i])+'" class="flexCenter urlgo">';
574
							itemlist += '<div class="madiaHead artHead" style="background-image:url(' + hasImg + ')"></div>';
575
							itemlist += '<div class="madiaInfo">';
576
							itemlist += '<p class="h1Font ellipsisSty-2">'+$info[i].articleTitle+'</p>';
577
							itemlist += '<ul class="h2Font clearfix">';
578
							itemlist += '<li><span class="time">' + commenTime($info[i].publishTime) + '</span></li>';
579
							itemlist += sowU
580
							itemlist += '<li><span class="leaveMsgCount"></span></li>';
581
							itemlist += '</ul></div>';
582
							itemlist += '</a></li>';
597
						itemlist += '<a href="/' + pageUrl('a', $info[i]) + '" class="flexCenter urlgo">';
598
						itemlist += '<div class="madiaHead artHead" style="background-image:url(' + hasImg + ')"></div>';
599
						itemlist += '<div class="madiaInfo">';
600
						itemlist += '<p class="h1Font ellipsisSty-2">' + $info[i].articleTitle + '</p>';
601
						itemlist += '<ul class="h2Font clearfix">';
602
						itemlist += '<li><span class="time">' + commenTime($info[i].publishTime) + '</span></li>';
603
						itemlist += sowU
604
						itemlist += '<li><span class="leaveMsgCount"></span></li>';
605
						itemlist += '</ul></div>';
606
						itemlist += '</a></li>';
583
						var $itemlist = $(itemlist);
607
						var $itemlist = $(itemlist);
584
						$("#"+aimId).append($itemlist)
585
						leaveMsgCount($info[i].articleId,1,$itemlist);
586
						
587
						if(isbind && i==0){
608
						$("#" + aimId).append($itemlist)
609
						leaveMsgCount($info[i].articleId, 1, $itemlist);
610
611
						if (isbind && i == 0) {
588
							var $itemlist = $(itemlist);
612
							var $itemlist = $(itemlist);
589
							$("#"+aimIdF).append($itemlist);
590
							leaveMsgCount($info[0].articleId,1,$itemlist);
613
							$("#" + aimIdF).append($itemlist);
614
							leaveMsgCount($info[0].articleId, 1, $itemlist);
591
						}
615
						}
592
					}
616
					}
593
				}
617
				}
594
				var liLen=document.getElementById(aimId).querySelectorAll("li").length;
595
                removeNodata(aimId);
596
                if($info.length == 0 && liLen == 0 ){
597
                	$("#"+aimId).hide()
598
                    insertNodata(aimId,newStr);
599
                }
600
                if(isbind){
601
                	$("#"+aimId).parent().find(".js-load-more").unbind("click").on("click",function(){
602
					 	articalListVal(false)
618
				var liLen = document.getElementById(aimId).querySelectorAll("li").length;
619
				removeNodata(aimId);
620
				if ($info.length == 0 && liLen == 0) {
621
					$("#" + aimId).hide()
622
					insertNodata(aimId, newStr);
623
				}
624
				if (isbind) {
625
					$("#" + aimId).parent().find(".js-load-more").unbind("click").on("click", function () {
626
						// articalListVal(false)
603
					})
627
					})
604
                }
628
				}
605
				if ($info.length < rows) {
629
				if ($info.length < rows) {
606
                    $("#"+aimId).parent().find(".js-load-more").unbind("click");
607
                    $("#"+aimId).parent().find(".js-load-more").hide();
608
                }
609
			},function(){
610
				$("#"+aimId).parent().find(".js-load-more").attr("disabled",true);
611
	       		$("#"+aimId).parent().find(".js-load-more").addClass("active");
612
			},function(){
613
				$("#"+aimId).parent().find(".js-load-more").removeAttr("disabled");
614
	        	$("#"+aimId).parent().find(".js-load-more").removeClass("active");
630
					$("#" + aimId).parent().find(".js-load-more").unbind("click");
631
					$("#" + aimId).parent().find(".js-load-more").hide();
632
				}
633
			}, function () {
634
				$("#" + aimId).parent().find(".js-load-more").attr("disabled", true);
635
				$("#" + aimId).parent().find(".js-load-more").addClass("active");
636
			}, function () {
637
				$("#" + aimId).parent().find(".js-load-more").removeAttr("disabled");
638
				$("#" + aimId).parent().find(".js-load-more").removeClass("active");
615
			})
639
			})
616
		},
640
		},
617
		resourceListVal=function(isbind){
618
			var aimId="proResource",aimIdF="showResource",newStr="用户尚未发布任何资源"
619
			oAjax("/ajax/resource/publish",{
641
		resourceListVal = function (isbind) {
642
			var aimId = "proResource",
643
				aimIdF = "showResource",
644
				newStr = "用户尚未发布任何资源"
645
			oAjax("/ajax/resource/publish", {
620
				"category": "1",
646
				"category": "1",
621
				"owner":professorId,
622
				"publishTime":dataO.resPublishTime,
647
				"owner": professorId,
648
				"publishTime": dataO.resPublishTime,
623
				"shareId": dataO.resShareId,
649
				"shareId": dataO.resShareId,
624
				"rows": rows
650
				"rows": rows
625
			}, "get", function(res){
651
			}, "get", function (res) {
626
				var $info = res.data;
652
				var $info = res.data;
627
				if($info.length > 0) {
628
					$("#"+aimId).show()
629
					$("#"+aimIdF).parents(".leftconItem").find(".nodatabox").hide()
630
					$("#"+aimIdF).parents(".form-item").removeClass("displayNone");
631
					$("#"+aimIdF).parents(".coninfobox").show();
653
				if ($info.length > 0) {
654
					$("#" + aimId).show()
655
					$("#" + aimIdF).parents(".leftconItem").find(".nodatabox").hide()
656
					$("#" + aimIdF).parents(".form-item").removeClass("displayNone");
657
					$("#" + aimIdF).parents(".coninfobox").show();
632
					dataO.resPublishTime = $info[$info.length - 1].publishTime;
658
					dataO.resPublishTime = $info[$info.length - 1].publishTime;
633
					dataO.resShareId = $info[$info.length - 1].shareId;
659
					dataO.resShareId = $info[$info.length - 1].shareId;
634
			
635
					for(var i = 0; i < $info.length; i++) {
636
						var hasImg='/images/default-resource.jpg'
637
						if($info[i].images.length) {
638
							hasImg="/data/resource/" + $info[i].images[0].imageSrc
660
661
					for (var i = 0; i < $info.length; i++) {
662
						var hasImg = '/images/default-resource.jpg'
663
						if ($info[i].images.length) {
664
							hasImg = "/data/resource/" + $info[i].images[0].imageSrc
639
						}
665
						}
640
						
666
641
						var itemlist = '<li>';
667
						var itemlist = '<li>';
642
							itemlist += '<a href="resourceShow.html?resourceId=' + $info[i].resourceId + '" class="flexCenter urlgo">';
643
							itemlist += '<div class="madiaHead resouseHead" style="background-image:url(' + hasImg + ')"></div>';
644
							itemlist += '<div class="madiaInfo"><p class="h1Font ellipsisSty-2">' + $info[i].resourceName + '</p><p class="h2Font ellipsisSty">用途:' + $info[i].supportedServices + '</p></div>';
645
							itemlist += '</a></li>';
668
						itemlist += '<a href="resourceShow.html?resourceId=' + $info[i].resourceId + '" class="flexCenter urlgo">';
669
						itemlist += '<div class="madiaHead resouseHead" style="background-image:url(' + hasImg + ')"></div>';
670
						itemlist += '<div class="madiaInfo"><p class="h1Font ellipsisSty-2">' + $info[i].resourceName + '</p><p class="h2Font ellipsisSty">用途:' + $info[i].supportedServices + '</p></div>';
671
						itemlist += '</a></li>';
646
						var $itemlist = $(itemlist);
672
						var $itemlist = $(itemlist);
647
						$("#"+aimId).append($itemlist)
648
						
649
						if(isbind && i==0){
673
						$("#" + aimId).append($itemlist)
674
675
						if (isbind && i == 0) {
650
							var $itemlist = $(itemlist);
676
							var $itemlist = $(itemlist);
651
							$("#"+aimIdF).append($itemlist);
677
							$("#" + aimIdF).append($itemlist);
652
						}
678
						}
653
					}
679
					}
654
				}
680
				}
655
				var liLen=document.getElementById(aimId).querySelectorAll("li").length;
656
                removeNodata(aimId);
657
                if($info.length == 0 && liLen == 0 ){
658
                	$("#"+aimId).hide()
659
                    insertNodata(aimId,newStr);
660
                }
661
                if(isbind){
662
                	$("#"+aimId).parent().find(".js-load-more").unbind("click").on("click",function(){
663
					 	resourceListVal(false)
681
				var liLen = document.getElementById(aimId).querySelectorAll("li").length;
682
				removeNodata(aimId);
683
				if ($info.length == 0 && liLen == 0) {
684
					$("#" + aimId).hide()
685
					insertNodata(aimId, newStr);
686
				}
687
				if (isbind) {
688
					$("#" + aimId).parent().find(".js-load-more").unbind("click").on("click", function () {
689
						resourceListVal(false)
664
					})
690
					})
665
                }
691
				}
666
				if ($info.length < rows) {
692
				if ($info.length < rows) {
667
                    $("#"+aimId).parent().find(".js-load-more").unbind("click");
668
                    $("#"+aimId).parent().find(".js-load-more").hide();
669
                }
670
			},function(){
671
				$("#"+aimId).parent().find(".js-load-more").attr("disabled",true);
672
	       		$("#"+aimId).parent().find(".js-load-more").addClass("active");
673
			},function(){
674
				$("#"+aimId).parent().find(".js-load-more").removeAttr("disabled");
675
	        	$("#"+aimId).parent().find(".js-load-more").removeClass("active");
693
					$("#" + aimId).parent().find(".js-load-more").unbind("click");
694
					$("#" + aimId).parent().find(".js-load-more").hide();
695
				}
696
			}, function () {
697
				$("#" + aimId).parent().find(".js-load-more").attr("disabled", true);
698
				$("#" + aimId).parent().find(".js-load-more").addClass("active");
699
			}, function () {
700
				$("#" + aimId).parent().find(".js-load-more").removeAttr("disabled");
701
				$("#" + aimId).parent().find(".js-load-more").removeClass("active");
676
			})
702
			})
677
		},
703
		},
678
		serviceListVal=function(isbind){
679
			var aimId="proService",aimIdF="showService",newStr="用户尚未发布任何服务"
680
			oAjax("/ajax/ware/publish",{
681
				"category":"1",
682
				"owner":professorId,
683
				"modifyTime":dataO.serModifyTime,
704
		serviceListVal = function (isbind) {
705
			var aimId = "proService",
706
				aimIdF = "showService",
707
				newStr = "用户尚未发布任何服务"
708
			oAjax("/ajax/ware/publish", {
709
				"category": "1",
710
				"owner": professorId,
711
				"modifyTime": dataO.serModifyTime,
684
				"rows": rows
712
				"rows": rows
685
			}, "get", function(res){
713
			}, "get", function (res) {
686
				var $info = res.data;
714
				var $info = res.data;
687
				if($info.length > 0) {
688
					$("#"+aimId).show()
689
					$("#"+aimIdF).parents(".leftconItem").find(".nodatabox").hide()
690
					$("#"+aimIdF).parents(".form-item").removeClass("displayNone");
691
					$("#"+aimIdF).parents(".coninfobox").show();
715
				if ($info.length > 0) {
716
					$("#" + aimId).show()
717
					$("#" + aimIdF).parents(".leftconItem").find(".nodatabox").hide()
718
					$("#" + aimIdF).parents(".form-item").removeClass("displayNone");
719
					$("#" + aimIdF).parents(".coninfobox").show();
692
					dataO.serModifyTime = $info[$info.length - 1].modifyTime;
720
					dataO.serModifyTime = $info[$info.length - 1].modifyTime;
693
			
694
					for(var i = 0; i < $info.length; i++) {
695
						var cnt="", hasImg="../images/default-service.jpg";
696
						if($info[i].cnt) {
721
722
					for (var i = 0; i < $info.length; i++) {
723
						var cnt = "",
724
							hasImg = "../images/default-service.jpg";
725
						if ($info[i].cnt) {
697
							cnt = "内容:" + $info[i].cnt
726
							cnt = "内容:" + $info[i].cnt
698
						}
727
						}
699
						if($info[i].images) {
728
						if ($info[i].images) {
700
							var subs = strToAry($info[i].images)
729
							var subs = strToAry($info[i].images)
701
							if(subs.length > 0) {
702
								hasImg="/data/ware" + subs[0]
730
							if (subs.length > 0) {
731
								hasImg = "/data/ware" + subs[0]
703
							}
732
							}
704
						}
733
						}
705
						var itemlist = '<li>';
734
						var itemlist = '<li>';
706
							itemlist += '<a href="sevriceShow.html?sevriceId=' + $info[i].id + '" class="flexCenter urlgo">';
707
							itemlist += '<div class="madiaHead resouseHead" style="background-image:url(' + hasImg + ')"></div>';
708
							itemlist += '<div class="madiaInfo"><p class="h1Font ellipsisSty-2">' + $info[i].name + '</p><p class="h2Font ellipsisSty">' + cnt+ '</p></div>';
709
							itemlist += '</a></li>';
735
						itemlist += '<a href="sevriceShow.html?sevriceId=' + $info[i].id + '" class="flexCenter urlgo">';
736
						itemlist += '<div class="madiaHead resouseHead" style="background-image:url(' + hasImg + ')"></div>';
737
						itemlist += '<div class="madiaInfo"><p class="h1Font ellipsisSty-2">' + $info[i].name + '</p><p class="h2Font ellipsisSty">' + cnt + '</p></div>';
738
						itemlist += '</a></li>';
710
						var $itemlist = $(itemlist);
739
						var $itemlist = $(itemlist);
711
						$("#"+aimId).append($itemlist)
712
						
713
						if(isbind && i==0){
740
						$("#" + aimId).append($itemlist)
741
742
						if (isbind && i == 0) {
714
							var $itemlist = $(itemlist);
743
							var $itemlist = $(itemlist);
715
							$("#"+aimIdF).append($itemlist);
744
							$("#" + aimIdF).append($itemlist);
716
						}
745
						}
717
					}
746
					}
718
				}
747
				}
719
				var liLen=document.getElementById(aimId).querySelectorAll("li").length;
720
                removeNodata(aimId);
721
                if($info.length == 0 && liLen == 0 ){
722
                	$("#"+aimId).hide()
723
                    insertNodata(aimId,newStr);
724
                }
725
                if(isbind){
726
                	$("#"+aimId).parent().find(".js-load-more").unbind("click").on("click",function(){
727
					 	serviceListVal(false)
748
				var liLen = document.getElementById(aimId).querySelectorAll("li").length;
749
				removeNodata(aimId);
750
				if ($info.length == 0 && liLen == 0) {
751
					$("#" + aimId).hide()
752
					insertNodata(aimId, newStr);
753
				}
754
				if (isbind) {
755
					$("#" + aimId).parent().find(".js-load-more").unbind("click").on("click", function () {
756
						serviceListVal(false)
728
					})
757
					})
729
                }
758
				}
730
				if ($info.length < rows) {
759
				if ($info.length < rows) {
731
                    $("#"+aimId).parent().find(".js-load-more").unbind("click");
732
                    $("#"+aimId).parent().find(".js-load-more").hide();
733
                }
734
			},function(){
735
				$("#"+aimId).parent().find(".js-load-more").attr("disabled",true);
736
	       		$("#"+aimId).parent().find(".js-load-more").addClass("active");
737
			},function(){
738
				$("#"+aimId).parent().find(".js-load-more").removeAttr("disabled");
739
	        	$("#"+aimId).parent().find(".js-load-more").removeClass("active");
760
					$("#" + aimId).parent().find(".js-load-more").unbind("click");
761
					$("#" + aimId).parent().find(".js-load-more").hide();
762
				}
763
			}, function () {
764
				$("#" + aimId).parent().find(".js-load-more").attr("disabled", true);
765
				$("#" + aimId).parent().find(".js-load-more").addClass("active");
766
			}, function () {
767
				$("#" + aimId).parent().find(".js-load-more").removeAttr("disabled");
768
				$("#" + aimId).parent().find(".js-load-more").removeClass("active");
740
			})
769
			})
741
		},
770
		},
742
		unPatentListVal=function(isbind) {
743
			var aimId="proUnPatent",newStr="用户尚未参与任何非专利成果的研究"
744
			oAjax("/ajax/resResult/pq/researcher",{
771
		unPatentListVal = function (isbind) {
772
			var aimId = "proUnPatent",
773
				newStr = "用户尚未参与任何非专利成果的研究"
774
			oAjax("/ajax/resResult/pq/researcher", {
745
				id: professorId,
775
				id: professorId,
746
				status: ['1'],
776
				status: ['1'],
747
				pageSize: rows,
777
				pageSize: rows,
748
				pageNo: pageNo
778
				pageNo: pageNo
749
			}, "get", function(res){
779
			}, "get", function (res) {
750
				var $info = res.data.data;
780
				var $info = res.data.data;
751
				if($info.length > 0) {
752
					$("#"+aimId).show()
753
					for(var i = 0; i < $info.length; i++) {
754
						var resIM='<div class="madiaHead patentHead"></div>'
781
				if ($info.length > 0) {
782
					$("#" + aimId).show()
783
					for (var i = 0; i < $info.length; i++) {
784
						var resIM = '<div class="madiaHead patentHead"></div>'
755
						if ($info[i].pic) {
785
						if ($info[i].pic) {
756
							var src = '/data/researchResult' + $info[i].pic.split(",")[0]
786
							var src = '/data/researchResult' + $info[i].pic.split(",")[0]
757
							resIM = '<div class="madiaHead patentHead" style="background-image:url('+ src +')"></div>';
787
							resIM = '<div class="madiaHead patentHead" style="background-image:url(' + src + ')"></div>';
758
						}
788
						}
759
						var itemlist = '<li>';
789
						var itemlist = '<li>';
760
							itemlist += '<a target="_blank" href="unPatentShow.html?id='+$info[i].id+'" class="flexCenter urlgo">';
761
							itemlist += resIM
762
							itemlist += '<div class="madiaInfo"><p class="h1Font ellipsisSty">'+ $info[i].name +'</p>';
763
							itemlist += '<p class="h2Font ellipsisSty displayNone">研究者:<span class="researchers"></span></p>';
764
							if ($info[i].orgId){
765
								itemlist += '<p class="h2Font ellipsisSty">所属机构:<span class="resOrgName"></span></p>';
766
							}
767
							itemlist += '</div>';
768
							itemlist += '</a></li>';
790
						itemlist += '<a target="_blank" href="unPatentShow.html?id=' + $info[i].id + '" class="flexCenter urlgo">';
791
						itemlist += resIM
792
						itemlist += '<div class="madiaInfo"><p class="h1Font ellipsisSty">' + $info[i].name + '</p>';
793
						itemlist += '<p class="h2Font ellipsisSty displayNone">研究者:<span class="researchers"></span></p>';
794
						if ($info[i].orgId) {
795
							itemlist += '<p class="h2Font ellipsisSty">所属机构:<span class="resOrgName"></span></p>';
796
						}
797
						itemlist += '</div>';
798
						itemlist += '</a></li>';
769
						var $itemlist = $(itemlist);
799
						var $itemlist = $(itemlist);
770
						$("#"+aimId).append($itemlist)
800
						$("#" + aimId).append($itemlist)
771
						queryResearcher($info[i].id, $itemlist)
801
						queryResearcher($info[i].id, $itemlist)
772
						if ($info[i].orgId) {
802
						if ($info[i].orgId) {
773
							queryReseOrgName($info[i].orgId, $itemlist)
803
							queryReseOrgName($info[i].orgId, $itemlist)
774
						}
804
						}
775
					}
805
					}
776
				}
806
				}
777
				var liLen=document.getElementById(aimId).querySelectorAll("li").length;
778
                removeNodata(aimId);
779
                if($info.length == 0 && liLen == 0 ){
780
                	$("#"+aimId).hide()
781
                    insertNodata(aimId,newStr);
782
                }
783
                if(isbind){
784
                	$("#"+aimId).parent().find(".js-load-more").unbind("click").on("click",function(){
807
				var liLen = document.getElementById(aimId).querySelectorAll("li").length;
808
				removeNodata(aimId);
809
				if ($info.length == 0 && liLen == 0) {
810
					$("#" + aimId).hide()
811
					insertNodata(aimId, newStr);
812
				}
813
				if (isbind) {
814
					$("#" + aimId).parent().find(".js-load-more").unbind("click").on("click", function () {
785
						pageNo++
815
						pageNo++
786
						unPatentListVal(false)
816
						unPatentListVal(false)
787
					})
817
					})
788
                }
818
				}
789
				if ($info.length < rows) {
819
				if ($info.length < rows) {
790
                    $("#"+aimId).parent().find(".js-load-more").unbind("click");
791
                    $("#"+aimId).parent().find(".js-load-more").hide();
792
                }
793
			},function(){
794
				$("#"+aimId).parent().find(".js-load-more").attr("disabled",true);
795
	       		$("#"+aimId).parent().find(".js-load-more").addClass("active");
796
			},function(){
797
				$("#"+aimId).parent().find(".js-load-more").removeAttr("disabled");
798
	        	$("#"+aimId).parent().find(".js-load-more").removeClass("active");
820
					$("#" + aimId).parent().find(".js-load-more").unbind("click");
821
					$("#" + aimId).parent().find(".js-load-more").hide();
822
				}
823
			}, function () {
824
				$("#" + aimId).parent().find(".js-load-more").attr("disabled", true);
825
				$("#" + aimId).parent().find(".js-load-more").addClass("active");
826
			}, function () {
827
				$("#" + aimId).parent().find(".js-load-more").removeAttr("disabled");
828
				$("#" + aimId).parent().find(".js-load-more").removeClass("active");
799
			})
829
			})
800
		},
830
		},
801
		patentListVal=function(isbind){
802
			var aimId="proPatent",aimIdF="showPatent",newStr="用户尚未发布任何专利"
803
			oAjax("/ajax/ppatent/professor",{
804
				"owner":professorId,
805
				"assTime":dataO.patTime,
806
				"id":dataO.patId,
831
		patentListVal = function (isbind) {
832
			var aimId = "proPatent",
833
				aimIdF = "showPatent",
834
				newStr = "用户尚未发布任何专利"
835
			oAjax("/ajax/ppatent/professor", {
836
				"owner": professorId,
837
				"assTime": dataO.patTime,
838
				"id": dataO.patId,
807
				"rows": rows
839
				"rows": rows
808
			}, "get", function(res){
840
			}, "get", function (res) {
809
				var $info = res.data;
841
				var $info = res.data;
810
				if($info.length > 0) {
811
					$("#"+aimId).show()
812
					$("#"+aimIdF).parents(".leftconItem").find(".nodatabox").hide()
813
					$("#"+aimIdF).parents(".form-item").removeClass("displayNone");
814
					$("#"+aimIdF).parents(".coninfobox").show();
842
				if ($info.length > 0) {
843
					$("#" + aimId).show()
844
					$("#" + aimIdF).parents(".leftconItem").find(".nodatabox").hide()
845
					$("#" + aimIdF).parents(".form-item").removeClass("displayNone");
846
					$("#" + aimIdF).parents(".coninfobox").show();
815
					dataO.patTime = $info[$info.length - 1].assTime;
847
					dataO.patTime = $info[$info.length - 1].assTime;
816
					dataO.patId = $info[$info.length - 1].id;
848
					dataO.patId = $info[$info.length - 1].id;
817
			
818
					for(var i = 0; i < $info.length; i++) {
819
						var dataStr= $info
820
						if(!dataStr[i].reqPerson){
821
								dataStr[i].reqPerson="";
822
							}
849
850
					for (var i = 0; i < $info.length; i++) {
851
						var dataStr = $info
852
						if (!dataStr[i].reqPerson) {
853
							dataStr[i].reqPerson = "";
854
						}
823
						var strAdd = '';
855
						var strAdd = '';
824
							strAdd += '<li><a  target="_blank" href="/'+ pageUrl("pt",dataStr[i]) +'" class="flexCenter urlgo">';
825
							strAdd += '<div class="madiaHead patentHead"></div>';
826
							strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">'+ dataStr[i].name +'</p>';
827
							strAdd += '<p class="h2Font ellipsisSty">发明人:'+ dataStr[i].authors.substring(0, dataStr[i].authors.length - 1) +'</p>';
828
							strAdd += '<p class="h2Font ellipsisSty">申请人:'+ dataStr[i].reqPerson +'</p>';
829
							strAdd += '</div>';
830
							strAdd += '</a></li>';
856
						strAdd += '<li><a  target="_blank" href="/' + pageUrl("pt", dataStr[i]) + '" class="flexCenter urlgo">';
857
						strAdd += '<div class="madiaHead patentHead"></div>';
858
						strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">' + dataStr[i].name + '</p>';
859
						strAdd += '<p class="h2Font ellipsisSty">发明人:' + dataStr[i].authors.substring(0, dataStr[i].authors.length - 1) + '</p>';
860
						strAdd += '<p class="h2Font ellipsisSty">申请人:' + dataStr[i].reqPerson + '</p>';
861
						strAdd += '</div>';
862
						strAdd += '</a></li>';
831
						var $itemlist = $(strAdd);
863
						var $itemlist = $(strAdd);
832
						$("#"+aimId).append($itemlist)
833
						
834
						if(isbind && i==0){
864
						$("#" + aimId).append($itemlist)
865
866
						if (isbind && i == 0) {
835
							var $itemlist = $(strAdd);
867
							var $itemlist = $(strAdd);
836
							$("#"+aimIdF).append($itemlist);
868
							$("#" + aimIdF).append($itemlist);
837
						}
869
						}
838
					}
870
					}
839
				}
871
				}
840
				var liLen=document.getElementById(aimId).querySelectorAll("li").length;
841
                removeNodata(aimId);
842
                if($info.length == 0 && liLen == 0 ){
843
                	$("#"+aimId).hide()
844
                    insertNodata(aimId,newStr);
845
                }
846
                if(isbind){
847
                	$("#"+aimId).parent().find(".js-load-more").unbind("click").on("click",function(){
848
					 	patentListVal(false)
872
				var liLen = document.getElementById(aimId).querySelectorAll("li").length;
873
				removeNodata(aimId);
874
				if ($info.length == 0 && liLen == 0) {
875
					$("#" + aimId).hide()
876
					insertNodata(aimId, newStr);
877
				}
878
				if (isbind) {
879
					$("#" + aimId).parent().find(".js-load-more").unbind("click").on("click", function () {
880
						patentListVal(false)
849
					})
881
					})
850
                }
882
				}
851
				if ($info.length < rows) {
883
				if ($info.length < rows) {
852
                    $("#"+aimId).parent().find(".js-load-more").unbind("click");
853
                    $("#"+aimId).parent().find(".js-load-more").hide();
854
                }
855
			},function(){
856
				$("#"+aimId).parent().find(".js-load-more").attr("disabled",true);
857
	       		$("#"+aimId).parent().find(".js-load-more").addClass("active");
858
			},function(){
859
				$("#"+aimId).parent().find(".js-load-more").removeAttr("disabled");
860
	        	$("#"+aimId).parent().find(".js-load-more").removeClass("active");
884
					$("#" + aimId).parent().find(".js-load-more").unbind("click");
885
					$("#" + aimId).parent().find(".js-load-more").hide();
886
				}
887
			}, function () {
888
				$("#" + aimId).parent().find(".js-load-more").attr("disabled", true);
889
				$("#" + aimId).parent().find(".js-load-more").addClass("active");
890
			}, function () {
891
				$("#" + aimId).parent().find(".js-load-more").removeAttr("disabled");
892
				$("#" + aimId).parent().find(".js-load-more").removeClass("active");
861
			})
893
			})
862
		},
894
		},
863
		paperListVal=function(isbind){   //找论文
864
			var aimId="proPaper",aimIdF="showPaper",newStr="用户尚未发布任何论文"
865
			oAjax("/ajax/ppaper/professor",{
866
				"owner":professorId,
867
				"assTime":dataO.parTime,
868
				"id":dataO.parId,
895
		paperListVal = function (isbind) { //找论文
896
			var aimId = "proPaper",
897
				aimIdF = "showPaper",
898
				newStr = "用户尚未发布任何论文"
899
			oAjax("/ajax/ppaper/professor", {
900
				"owner": professorId,
901
				"assTime": dataO.parTime,
902
				"id": dataO.parId,
869
				"rows": rows
903
				"rows": rows
870
			}, "get", function(res){
904
			}, "get", function (res) {
871
				var $info = res.data;
905
				var $info = res.data;
872
				console.log($info)
873
				if($info.length > 0) {
874
					$("#"+aimId).show()
875
					$("#"+aimIdF).parents(".leftconItem").find(".nodatabox").hide()
876
					$("#"+aimIdF).parents(".form-item").removeClass("displayNone");
877
					$("#"+aimIdF).parents(".coninfobox").show();
906
				if ($info.length > 0) {
907
					$("#" + aimId).show()
908
					$("#" + aimIdF).parents(".leftconItem").find(".nodatabox").hide()
909
					$("#" + aimIdF).parents(".form-item").removeClass("displayNone");
910
					$("#" + aimIdF).parents(".coninfobox").show();
878
					dataO.parTime = $info[$info.length - 1].assTime;
911
					dataO.parTime = $info[$info.length - 1].assTime;
879
					dataO.parId = $info[$info.length - 1].id;
912
					dataO.parId = $info[$info.length - 1].id;
880
			
881
					for(var i = 0; i < $info.length; i++) {
882
						var dataStr= $info
883
						var moreInf=""
884
						if(!dataStr[i].cn4periodical){
885
							dataStr[i].cn4periodical="";
913
914
					for (var i = 0; i < $info.length; i++) {
915
						var dataStr = $info
916
						var moreInf = ""
917
						if (!dataStr[i].cn4periodical) {
918
							dataStr[i].cn4periodical = "";
886
						}
919
						}
887
						if(!dataStr[i].en4periodical){
888
							dataStr[i].en4periodical="";
920
						if (!dataStr[i].en4periodical) {
921
							dataStr[i].en4periodical = "";
889
						}
922
						}
890
						if(!dataStr[i].pubDay){
891
							dataStr[i].pubDay="";
923
						if (!dataStr[i].pubDay) {
924
							dataStr[i].pubDay = "";
892
						}
925
						}
893
						moreInf = dataStr[i].cn4periodical+ " " +dataStr[i].en4periodical+ " " +dataStr[i].pubDay
894
							
926
						moreInf = dataStr[i].cn4periodical + " " + dataStr[i].en4periodical + " " + dataStr[i].pubDay
927
895
						var strAdd = '';
928
						var strAdd = '';
896
							strAdd += '<li><a  target="_blank" href="/'+ pageUrl("pp",dataStr[i]) +'" class="flexCenter urlgo">';
897
							strAdd += '<div class="madiaHead paperHead"></div>';
898
							strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">'+ dataStr[i].name +'</p>';
899
							strAdd += '<p class="h2Font ellipsisSty">作者:'+ dataStr[i].authors.substring(0, dataStr[i].authors.length - 1) +'</p>';
900
							strAdd += '<p class="h2Font ellipsisSty">期刊:'+ moreInf +'</p>';
901
							strAdd += '</div>';
902
							strAdd += '</a></li>';
929
						strAdd += '<li><a  target="_blank" href="/' + pageUrl("pp", dataStr[i]) + '" class="flexCenter urlgo">';
930
						strAdd += '<div class="madiaHead paperHead"></div>';
931
						strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">' + dataStr[i].name + '</p>';
932
						strAdd += '<p class="h2Font ellipsisSty">作者:' + dataStr[i].authors.substring(0, dataStr[i].authors.length - 1) + '</p>';
933
						strAdd += '<p class="h2Font ellipsisSty">期刊:' + moreInf + '</p>';
934
						strAdd += '</div>';
935
						strAdd += '</a></li>';
903
						var $itemlist = $(strAdd);
936
						var $itemlist = $(strAdd);
904
						$("#"+aimId).append($itemlist)
905
						
906
						if(isbind && i==0){
937
						$("#" + aimId).append($itemlist)
938
939
						if (isbind && i == 0) {
907
							var $itemlist = $(strAdd);
940
							var $itemlist = $(strAdd);
908
							$("#"+aimIdF).append($itemlist);
941
							$("#" + aimIdF).append($itemlist);
909
						}
942
						}
910
					}
943
					}
911
				}
944
				}
912
				var liLen=document.getElementById(aimId).querySelectorAll("li").length;
913
                removeNodata(aimId);
914
                if($info.length == 0 && liLen == 0 ){
915
                	$("#"+aimId).hide()
916
                    insertNodata(aimId,newStr);
917
                }
918
                if(isbind){
919
                	$("#"+aimId).parent().find(".js-load-more").unbind("click").on("click",function(){
920
					 	paperListVal(false)
945
				var liLen = document.getElementById(aimId).querySelectorAll("li").length;
946
				removeNodata(aimId);
947
				if ($info.length == 0 && liLen == 0) {
948
					$("#" + aimId).hide()
949
					insertNodata(aimId, newStr);
950
				}
951
				if (isbind) {
952
					$("#" + aimId).parent().find(".js-load-more").unbind("click").on("click", function () {
953
						paperListVal(false)
921
					})
954
					})
922
                }
955
				}
923
				if ($info.length < rows) {
956
				if ($info.length < rows) {
924
                    $("#"+aimId).parent().find(".js-load-more").unbind("click");
925
                    $("#"+aimId).parent().find(".js-load-more").hide();
926
                }
927
			},function(){
928
				$("#"+aimId).parent().find(".js-load-more").attr("disabled",true);
929
	       		$("#"+aimId).parent().find(".js-load-more").addClass("active");
930
			},function(){
931
				$("#"+aimId).parent().find(".js-load-more").removeAttr("disabled");
932
	        	$("#"+aimId).parent().find(".js-load-more").removeClass("active");
957
					$("#" + aimId).parent().find(".js-load-more").unbind("click");
958
					$("#" + aimId).parent().find(".js-load-more").hide();
959
				}
960
			}, function () {
961
				$("#" + aimId).parent().find(".js-load-more").attr("disabled", true);
962
				$("#" + aimId).parent().find(".js-load-more").addClass("active");
963
			}, function () {
964
				$("#" + aimId).parent().find(".js-load-more").removeAttr("disabled");
965
				$("#" + aimId).parent().find(".js-load-more").removeClass("active");
933
			})
966
			})
934
		},
967
		},
935
		answerListVal=function(isbind){//获取问答
936
        	var aimId="proA",aimIdF="showAnswer",newStr="用户尚未任何回答"
937
			oAjax("/ajax/question/answer/bySelf",{
938
				"time":dataO.AnsTime,
939
                "id":dataO.AnsId,
940
                "uid":professorId,
941
                "rows":rows
942
			}, "get", function(res){
968
		answerListVal = function (isbind) { //获取问答
969
			var aimId = "proA",
970
				aimIdF = "showAnswer",
971
				newStr = "用户尚未任何回答"
972
			oAjax("/ajax/question/answer/bySelf", {
973
				"time": dataO.AnsTime,
974
				"id": dataO.AnsId,
975
				"uid": professorId,
976
				"rows": rows
977
			}, "get", function (res) {
943
				var $info = res.data;
978
				var $info = res.data;
944
				if($info.length > 0) {
945
					$("#"+aimId).show()
946
					$("#"+aimIdF).parents(".leftconItem").find(".nodatabox").hide()
947
					$("#"+aimIdF).parents(".form-item").removeClass("displayNone");
948
					$("#"+aimIdF).parents(".coninfobox").show();
979
				if ($info.length > 0) {
980
					$("#" + aimId).show()
981
					$("#" + aimIdF).parents(".leftconItem").find(".nodatabox").hide()
982
					$("#" + aimIdF).parents(".form-item").removeClass("displayNone");
983
					$("#" + aimIdF).parents(".coninfobox").show();
949
					dataO.AnsTime = $info[$info.length - 1].createTime;
984
					dataO.AnsTime = $info[$info.length - 1].createTime;
950
					dataO.AnsId = $info[$info.length - 1].id;
985
					dataO.AnsId = $info[$info.length - 1].id;
951
			
952
					for(var i = 0; i < $info.length; i++) {
986
987
					for (var i = 0; i < $info.length; i++) {
953
						var listLi = $('<li>')
988
						var listLi = $('<li>')
954
						listLi.appendTo($("#"+aimId));
955
                        detailAnswer($info[i], listLi);
956
                        if(isbind && i==0){
957
                            var li = listLi.clone();
958
                            li.appendTo($("#"+aimIdF));
959
                            questioninfo($info[i].qid, li);
960
                            proinfo($info[i].uid, li);
961
                            leaveMsgCount($info[i].id,4, li);
962
                        }
989
						listLi.appendTo($("#" + aimId));
990
						detailAnswer($info[i], listLi);
991
						if (isbind && i == 0) {
992
							var li = listLi.clone();
993
							li.appendTo($("#" + aimIdF));
994
							questioninfo($info[i].qid, li);
995
							proinfo($info[i].uid, li);
996
							leaveMsgCount($info[i].id, 4, li);
997
						}
963
					}
998
					}
964
				}
999
				}
965
				var liLen=document.getElementById(aimId).querySelectorAll("li").length;
966
                removeNodata(aimId);
967
                if($info.length == 0 && liLen == 0 ){
968
                	$("#"+aimId).hide()
969
                    insertNodata(aimId,newStr);
970
                }
971
                if(isbind){
972
                	$("#"+aimId).parent().find(".js-load-more").unbind("click").on("click",function(){
973
					 	answerListVal(false)
1000
				var liLen = document.getElementById(aimId).querySelectorAll("li").length;
1001
				removeNodata(aimId);
1002
				if ($info.length == 0 && liLen == 0) {
1003
					$("#" + aimId).hide()
1004
					insertNodata(aimId, newStr);
1005
				}
1006
				if (isbind) {
1007
					$("#" + aimId).parent().find(".js-load-more").unbind("click").on("click", function () {
1008
						answerListVal(false)
974
					})
1009
					})
975
                }
1010
				}
976
				if ($info.length < rows) {
1011
				if ($info.length < rows) {
977
                    $("#"+aimId).parent().find(".js-load-more").unbind("click");
978
                    $("#"+aimId).parent().find(".js-load-more").hide();
979
                }
980
			},function(){
981
				$("#"+aimId).parent().find(".js-load-more").attr("disabled",true);
982
	       		$("#"+aimId).parent().find(".js-load-more").addClass("active");
983
			},function(){
984
				$("#"+aimId).parent().find(".js-load-more").removeAttr("disabled");
985
	        	$("#"+aimId).parent().find(".js-load-more").removeClass("active");
1012
					$("#" + aimId).parent().find(".js-load-more").unbind("click");
1013
					$("#" + aimId).parent().find(".js-load-more").hide();
1014
				}
1015
			}, function () {
1016
				$("#" + aimId).parent().find(".js-load-more").attr("disabled", true);
1017
				$("#" + aimId).parent().find(".js-load-more").addClass("active");
1018
			}, function () {
1019
				$("#" + aimId).parent().find(".js-load-more").removeAttr("disabled");
1020
				$("#" + aimId).parent().find(".js-load-more").removeClass("active");
986
			})
1021
			})
987
    	},
988
		questionListVal=function(isbind) {
989
			var aimId="proQ",newStr="用户尚未发布任何问题"
990
	        oAjax("/ajax/question/my",{
991
				"uid":professorId,
992
				"time":dataO.QuTime,
993
                "id":dataO.QuId,
994
                "rows":rows,
995
			}, "get", function(res){
1022
		},
1023
		questionListVal = function (isbind) {
1024
			var aimId = "proQ",
1025
				newStr = "用户尚未发布任何问题"
1026
			oAjax("/ajax/question/my", {
1027
				"uid": professorId,
1028
				"time": dataO.QuTime,
1029
				"id": dataO.QuId,
1030
				"rows": rows,
1031
			}, "get", function (res) {
996
				var $info = res.data;
1032
				var $info = res.data;
997
				if($info.length > 0) {
998
					$("#"+aimId).show()
1033
				if ($info.length > 0) {
1034
					$("#" + aimId).show()
999
					dataO.QuTime = $info[$info.length - 1].createTime;
1035
					dataO.QuTime = $info[$info.length - 1].createTime;
1000
					dataO.QuId = $info[$info.length - 1].id;
1036
					dataO.QuId = $info[$info.length - 1].id;
1001
			
1002
					for(var i = 0; i < $info.length; i++) {
1037
1038
					for (var i = 0; i < $info.length; i++) {
1003
						var listLi = $('<li class="mui-table-view-cell">').appendTo($("#proQ"));
1039
						var listLi = $('<li class="mui-table-view-cell">').appendTo($("#proQ"));
1004
                        detailQuestion($info[i], listLi);
1005
                        if(isbind && i==0){
1006
                            $("#"+aimId).html();
1007
                        }
1040
						detailQuestion($info[i], listLi);
1041
						if (isbind && i == 0) {
1042
							$("#" + aimId).html();
1043
						}
1008
					}
1044
					}
1009
				}
1045
				}
1010
				var liLen=document.getElementById(aimId).querySelectorAll("li").length;
1011
                removeNodata(aimId);
1012
                if($info.length == 0 && liLen == 0 ){
1013
                	$("#"+aimId).hide()
1014
                    insertNodata(aimId,newStr);
1015
                }
1016
                if(isbind){
1017
                	$("#"+aimId).parent().find(".js-load-more").unbind("click").on("click",function(){
1018
					 	questionListVal(false)
1046
				var liLen = document.getElementById(aimId).querySelectorAll("li").length;
1047
				removeNodata(aimId);
1048
				if ($info.length == 0 && liLen == 0) {
1049
					$("#" + aimId).hide()
1050
					insertNodata(aimId, newStr);
1051
				}
1052
				if (isbind) {
1053
					$("#" + aimId).parent().find(".js-load-more").unbind("click").on("click", function () {
1054
						questionListVal(false)
1019
					})
1055
					})
1020
                }
1056
				}
1021
				if ($info.length < rows) {
1057
				if ($info.length < rows) {
1022
                    $("#"+aimId).parent().find(".js-load-more").unbind("click");
1023
                    $("#"+aimId).parent().find(".js-load-more").hide();
1024
                }
1025
			},function(){
1026
				$("#"+aimId).parent().find(".js-load-more").attr("disabled",true);
1027
	       		$("#"+aimId).parent().find(".js-load-more").addClass("active");
1028
			},function(){
1029
				$("#"+aimId).parent().find(".js-load-more").removeAttr("disabled");
1030
	        	$("#"+aimId).parent().find(".js-load-more").removeClass("active");
1058
					$("#" + aimId).parent().find(".js-load-more").unbind("click");
1059
					$("#" + aimId).parent().find(".js-load-more").hide();
1060
				}
1061
			}, function () {
1062
				$("#" + aimId).parent().find(".js-load-more").attr("disabled", true);
1063
				$("#" + aimId).parent().find(".js-load-more").addClass("active");
1064
			}, function () {
1065
				$("#" + aimId).parent().find(".js-load-more").removeAttr("disabled");
1066
				$("#" + aimId).parent().find(".js-load-more").removeClass("active");
1031
			})
1067
			})
1032
	    },
1033
		relevantarticalList=function(){//相关文章信息
1034
			oAjax("/ajax/article/byAssProfessor",{
1035
				"id":professorId
1036
			}, "get", function(data){
1037
				if(data.data.length>0){
1068
		},
1069
		relevantarticalList = function () { //相关文章信息
1070
			oAjax("/ajax/article/byAssProfessor", {
1071
				"id": professorId
1072
			}, "get", function (data) {
1073
				if (data.data.length > 0) {
1038
					$("#relateArt").parents(".conBlock").removeClass("displayNone");
1074
					$("#relateArt").parents(".conBlock").removeClass("displayNone");
1039
					var itemlist = '';
1075
					var itemlist = '';
1040
					$("#relateArt").html("");
1076
					$("#relateArt").html("");
1041
					for(var i = 0; i < data.data.length; i++) {
1042
						var itemlist = '<li class="flexCenter"><a target="_blank" href="/'+ pageUrl('a',data.data[i]) +'" class="urlgo">';
1043
							itemlist += '<p class="h2Font ellipsisSty-2"><em class="circlePre"></em>'+data.data[i].articleTitle+'</p>';
1044
							itemlist += '</a></li>';
1045
							$itemlist = $(itemlist);
1077
					for (var i = 0; i < data.data.length; i++) {
1078
						var itemlist = '<li class="flexCenter"><a target="_blank" href="/' + pageUrl('a', data.data[i]) + '" class="urlgo">';
1079
						itemlist += '<p class="h2Font ellipsisSty-2"><em class="circlePre"></em>' + data.data[i].articleTitle + '</p>';
1080
						itemlist += '</a></li>';
1081
						$itemlist = $(itemlist);
1046
						$("#relateArt").append($itemlist);
1082
						$("#relateArt").append($itemlist);
1047
					}
1083
					}
1048
				}
1084
				}
1049
			});
1085
			});
1050
		},
1086
		},
1051
		likeExperts=function(){//感兴趣
1052
			oAjax("/ajax/professor/ralateProfessors",{
1053
				"professorId":professorId
1054
			}, "get", function(data){
1055
					var lengthT;
1056
					if(data.data.length>5){
1057
						lengthT=5;
1058
					}else{
1059
						lengthT=data.data.length
1060
					}
1061
					for(var i = 0; i < lengthT; i++) {
1062
						var ExpId = data.data[i].id;
1063
						(function(Id){
1064
							oAjax("/ajax/professor/info/"+Id,{}, "get", function(data){
1065
								$("#likePro").parents(".conBlock").removeClass("displayNone");
1066
								var itemlist = '<li class="flexCenter"><a  target="_blank" href="" class="urlgo">';
1067
									itemlist += '<div class="madiaHead useHead" id="userimg"></div>';
1068
									itemlist += '<div class="madiaInfo">';
1069
									itemlist += '<p><span class="h1Font" id="userName"></span><em class="authiconNew" title=""></em></p>';
1070
									itemlist += '<p class="ellipsisSty h2Font" id="usertitle"></p>';
1071
									itemlist += '</div></a></li>';
1072
								var $itemlist = $(itemlist);
1073
								$("#likePro").append($itemlist);
1074
								if(data.data.title) {
1075
									if(data.data.orgName) {
1076
										$itemlist.find("#usertitle").text(data.data.title +","+ data.data.orgName);
1077
									}else{
1078
										$itemlist.find("#usertitle").text(data.data.title);
1087
		likeExperts = function () { //感兴趣
1088
			oAjax("/ajax/professor/ralateProfessors", {
1089
				"professorId": professorId
1090
			}, "get", function (data) {
1091
				var lengthT;
1092
				if (data.data.length > 5) {
1093
					lengthT = 5;
1094
				} else {
1095
					lengthT = data.data.length
1096
				}
1097
				for (var i = 0; i < lengthT; i++) {
1098
					var ExpId = data.data[i].id;
1099
					(function (Id) {
1100
						oAjax("/ajax/professor/info/" + Id, {}, "get", function (data) {
1101
							$("#likePro").parents(".conBlock").removeClass("displayNone");
1102
							var itemlist = '<li class="flexCenter"><a  target="_blank" href="" class="urlgo">';
1103
							itemlist += '<div class="madiaHead useHead" id="userimg"></div>';
1104
							itemlist += '<div class="madiaInfo">';
1105
							itemlist += '<p><span class="h1Font" id="userName"></span><em class="authiconNew" title=""></em></p>';
1106
							itemlist += '<p class="ellipsisSty h2Font" id="usertitle"></p>';
1107
							itemlist += '</div></a></li>';
1108
							var $itemlist = $(itemlist);
1109
							$("#likePro").append($itemlist);
1110
							if (data.data.title) {
1111
								if (data.data.orgName) {
1112
									$itemlist.find("#usertitle").text(data.data.title + "," + data.data.orgName);
1113
								} else {
1114
									$itemlist.find("#usertitle").text(data.data.title);
1115
								}
1116
							} else {
1117
								if (data.data.office) {
1118
									if (data.data.orgName) {
1119
										$itemlist.find("#usertitle").text(data.data.office + "," + data.data.orgName);
1120
									} else {
1121
										$itemlist.find("#usertitle").text(data.data.office);
1079
									}
1122
									}
1080
								}else{
1081
									if(data.data.office) {
1082
										if(data.data.orgName) {
1083
											$itemlist.find("#usertitle").text(data.data.office +","+ data.data.orgName);
1084
										}else{
1085
											$itemlist.find("#usertitle").text(data.data.office);
1086
										}
1087
									}else{
1088
										if(data.data.orgName) {
1089
											$itemlist.find("#usertitle").text(data.data.orgName);
1090
										}
1123
								} else {
1124
									if (data.data.orgName) {
1125
										$itemlist.find("#usertitle").text(data.data.orgName);
1091
									}
1126
									}
1092
								}
1127
								}
1093
								$itemlist.find("#userName").text(data.data.name);
1094
								$itemlist.find(".urlgo").attr("href", "userInforShow.html?professorId="+data.data.id);
1095
								
1096
								if(data.data.hasHeadImage == 1) {
1097
									$itemlist.find("#userimg").attr("style", "background-image: url(/images/head/" + data.data.id + "_l.jpg);");
1098
								}
1099
								var userType = autho(data.data.authType, data.data.orgAuth, data.data.authStatus);
1100
								$itemlist.find(".authiconNew").attr("title", userType.title);
1101
								$itemlist.find(".authiconNew").addClass(userType.sty);
1102
							})
1103
						})(ExpId)
1104
					}
1128
							}
1129
							$itemlist.find("#userName").text(data.data.name);
1130
							$itemlist.find(".urlgo").attr("href", "userInforShow.html?professorId=" + data.data.id);
1131
1132
							if (data.data.hasHeadImage == 1) {
1133
								$itemlist.find("#userimg").attr("style", "background-image: url(/images/head/" + data.data.id + "_l.jpg);");
1134
							}
1135
							var userType = autho(data.data.authType, data.data.orgAuth, data.data.authStatus);
1136
							$itemlist.find(".authiconNew").attr("title", userType.title);
1137
							$itemlist.find(".authiconNew").addClass(userType.sty);
1138
						})
1139
					})(ExpId)
1140
				}
1105
			});
1141
			});
1106
		},
1142
		},
1107
		relevantExperts=function(){
1108
			oAjax("/ajax/professor/coadjutant",{
1109
				"id":professorId
1110
			}, "get", function(data){
1111
					var lengthT;
1112
					if(data.data.length>5){
1113
						lengthT=5;
1114
					}else{
1115
						lengthT=data.data.length
1116
					}
1117
					for(var i = 0; i < lengthT; i++) {
1118
						var ExpId = data.data[i].professorId;
1119
						var paperN=data.data[i].paperCount;
1120
						var patentN=data.data[i].patentCount;
1121
						(function(Id,numL,numZ){
1122
							oAjax("/ajax/professor/info/"+Id,{}, "get", function(data){
1123
								$("#relatePro").parents(".conBlock").removeClass("displayNone");
1124
								var itemlist = '<li class="flexCenter"><a target="_blank" href="" class="urlgo">';
1125
									itemlist += '<div class="madiaHead useHead" id="userimg"></div>';
1126
									itemlist += '<div class="madiaInfo">';
1127
									itemlist += '<p><span class="h1Font" id="userName"></span><em class="authiconNew" title=""></em></p>';
1128
									itemlist += '<p class="ellipsisSty h2Font" id="usertitle"></p>';
1129
									itemlist += '<p class="h2Font ellipsisSty" id="copNum"></p>';
1130
									itemlist += '</div></a></li>';
1131
								var $itemlist = $(itemlist);
1132
								$("#relatePro").append($itemlist);
1133
								if(numL){
1134
									if(numZ){
1135
										$itemlist.find("#copNum").text("合作:"+numZ+"项专利,"+numL+"篇论文")
1136
									}else{
1137
										$itemlist.find("#copNum").text("合作:"+numL+"篇论文")
1138
									}
1139
								}else{
1140
									if(numZ){
1141
										$itemlist.find("#copNum").text("合作:"+numZ+"项专利")
1142
									}else{
1143
										
1144
									}
1143
		relevantExperts = function () {
1144
			oAjax("/ajax/professor/coadjutant", {
1145
				"id": professorId
1146
			}, "get", function (data) {
1147
				var lengthT;
1148
				if (data.data.length > 5) {
1149
					lengthT = 5;
1150
				} else {
1151
					lengthT = data.data.length
1152
				}
1153
				for (var i = 0; i < lengthT; i++) {
1154
					var ExpId = data.data[i].professorId;
1155
					var paperN = data.data[i].paperCount;
1156
					var patentN = data.data[i].patentCount;
1157
					(function (Id, numL, numZ) {
1158
						oAjax("/ajax/professor/info/" + Id, {}, "get", function (data) {
1159
							$("#relatePro").parents(".conBlock").removeClass("displayNone");
1160
							var itemlist = '<li class="flexCenter"><a target="_blank" href="" class="urlgo">';
1161
							itemlist += '<div class="madiaHead useHead" id="userimg"></div>';
1162
							itemlist += '<div class="madiaInfo">';
1163
							itemlist += '<p><span class="h1Font" id="userName"></span><em class="authiconNew" title=""></em></p>';
1164
							itemlist += '<p class="ellipsisSty h2Font" id="usertitle"></p>';
1165
							itemlist += '<p class="h2Font ellipsisSty" id="copNum"></p>';
1166
							itemlist += '</div></a></li>';
1167
							var $itemlist = $(itemlist);
1168
							$("#relatePro").append($itemlist);
1169
							if (numL) {
1170
								if (numZ) {
1171
									$itemlist.find("#copNum").text("合作:" + numZ + "项专利," + numL + "篇论文")
1172
								} else {
1173
									$itemlist.find("#copNum").text("合作:" + numL + "篇论文")
1174
								}
1175
							} else {
1176
								if (numZ) {
1177
									$itemlist.find("#copNum").text("合作:" + numZ + "项专利")
1178
								} else {
1179
1180
								}
1181
							}
1182
							if (data.data.title) {
1183
								if (data.data.orgName) {
1184
									$itemlist.find("#usertitle").text(data.data.title + "," + data.data.orgName);
1185
								} else {
1186
									$itemlist.find("#usertitle").text(data.data.title);
1145
								}
1187
								}
1146
								if(data.data.title) {
1147
									if(data.data.orgName) {
1148
										$itemlist.find("#usertitle").text(data.data.title +","+ data.data.orgName);
1149
									}else{
1150
										$itemlist.find("#usertitle").text(data.data.title);
1188
							} else {
1189
								if (data.data.office) {
1190
									if (data.data.orgName) {
1191
										$itemlist.find("#usertitle").text(data.data.office + "," + data.data.orgName);
1192
									} else {
1193
										$itemlist.find("#usertitle").text(data.data.office);
1151
									}
1194
									}
1152
								}else{
1153
									if(data.data.office) {
1154
										if(data.data.orgName) {
1155
											$itemlist.find("#usertitle").text(data.data.office +","+ data.data.orgName);
1156
										}else{
1157
											$itemlist.find("#usertitle").text(data.data.office);
1158
										}
1159
									}else{
1160
										if(data.data.orgName) {
1161
											$itemlist.find("#usertitle").text(data.data.orgName);
1162
										}
1195
								} else {
1196
									if (data.data.orgName) {
1197
										$itemlist.find("#usertitle").text(data.data.orgName);
1163
									}
1198
									}
1164
								}
1199
								}
1165
								$itemlist.find("#userName").text(data.data.name);
1166
								
1167
								$itemlist.find(".urlgo").attr("href", "userInforShow.html?professorId="+data.data.id);
1168
								
1169
								if(data.data.hasHeadImage == 1) {
1170
									$itemlist.find("#userimg").attr("style", "background-image: url(/images/head/" + data.data.id + "_l.jpg);");
1171
								}
1172
								var userType = autho(data.data.authType, data.data.orgAuth, data.data.authStatus);
1173
								$itemlist.find(".authiconNew").attr("title", userType.title);
1174
								$itemlist.find(".authiconNew").addClass(userType.sty);
1175
							})
1176
						})(ExpId,paperN,patentN)
1177
					}
1200
							}
1201
							$itemlist.find("#userName").text(data.data.name);
1202
1203
							$itemlist.find(".urlgo").attr("href", "userInforShow.html?professorId=" + data.data.id);
1204
1205
							if (data.data.hasHeadImage == 1) {
1206
								$itemlist.find("#userimg").attr("style", "background-image: url(/images/head/" + data.data.id + "_l.jpg);");
1207
							}
1208
							var userType = autho(data.data.authType, data.data.orgAuth, data.data.authStatus);
1209
							$itemlist.find(".authiconNew").attr("title", userType.title);
1210
							$itemlist.find(".authiconNew").addClass(userType.sty);
1211
						})
1212
					})(ExpId, paperN, patentN)
1213
				}
1178
			});
1214
			});
1179
		},
1215
		},
1180
		isActUser=function(){
1181
			oAjax("/ajax/baseUserInfo",{
1216
		isActUser = function () {
1217
			oAjax("/ajax/baseUserInfo", {
1182
				"id": professorId
1218
				"id": professorId
1183
			}, "get", function(data){
1184
				if(!data.data.activeTime){
1219
			}, "get", function (data) {
1220
				if (!data.data.activeTime) {
1185
					$(".last_meg").removeClass("displayNone");
1221
					$(".last_meg").removeClass("displayNone");
1186
					$(".message_b").on("click",function(){
1222
					$(".message_b").on("click", function () {
1187
						$(".meg_md5").toggle();
1223
						$(".meg_md5").toggle();
1188
						if(data.data.email && data.data.mobilePhone){
1189
						 	$("#wayTel").text('尾号为 '+data.data.mobilePhone+' 的手机号或邮箱 '+data.data.email);
1190
						}else if(data.data.mobilePhone && !data.data.email){
1191
							$("#wayTel").text('尾号为 '+data.data.mobilePhone+' 的手机号');
1192
						}else if(data.data.email && !data.data.mobilePhone){
1193
							$("#wayTel").text('邮箱 '+data.data.email);
1224
						if (data.data.email && data.data.mobilePhone) {
1225
							$("#wayTel").text('尾号为 ' + data.data.mobilePhone + ' 的手机号或邮箱 ' + data.data.email);
1226
						} else if (data.data.mobilePhone && !data.data.email) {
1227
							$("#wayTel").text('尾号为 ' + data.data.mobilePhone + ' 的手机号');
1228
						} else if (data.data.email && !data.data.mobilePhone) {
1229
							$("#wayTel").text('邮箱 ' + data.data.email);
1194
						}
1230
						}
1195
					})
1231
					})
1196
				}else{
1232
				} else {
1197
					$(".last_meg").addClass("displayNone");
1233
					$(".last_meg").addClass("displayNone");
1198
				}
1234
				}
1199
			})
1235
			})
1200
		},
1236
		},
1201
		queryPubCount=function(){
1202
			oAjax("/ajax/watch/countProfessor",{//关注我的
1237
		queryPubCount = function () {
1238
			oAjax("/ajax/watch/countProfessor", { //关注我的
1203
				"id": professorId,
1239
				"id": professorId,
1204
				"type":"1"
1205
			}, "GET", function(data){
1240
				"type": "1"
1241
			}, "GET", function (data) {
1206
				$("#focusMe").text(data.data);
1242
				$("#focusMe").text(data.data);
1207
			});
1243
			});
1208
			oAjax("/ajax/watch/countObject",{//我关注的
1244
			oAjax("/ajax/watch/countObject", { //我关注的
1209
				"id": professorId,
1245
				"id": professorId,
1210
				"type":"1"
1211
			}, "GET", function(data){
1246
				"type": "1"
1247
			}, "GET", function (data) {
1212
				$("#myFocus").text(data.data);
1248
				$("#myFocus").text(data.data);
1213
			});
1249
			});
1214
			oAjax("/ajax/professor/agree/sum",{//总获赞
1250
			oAjax("/ajax/professor/agree/sum", { //总获赞
1215
				"id": professorId,
1251
				"id": professorId,
1216
			}, "GET", function(data){
1252
			}, "GET", function (data) {
1217
				$("#agreeMecount").text(data.data);
1253
				$("#agreeMecount").text(data.data);
1218
			});
1254
			});
1219
			
1220
			oAjax("/ajax/team/count",{//团队总数
1255
1256
			oAjax("/ajax/team/count", { //团队总数
1221
				"id": professorId
1257
				"id": professorId
1222
			}, "GET", function(data){
1223
				if(data.data>0 && data.data<99){
1258
			}, "GET", function (data) {
1259
				if (data.data > 0 && data.data < 99) {
1224
					$("#teamCount").text(data.data);
1260
					$("#teamCount").text(data.data);
1225
				}
1261
				}
1226
				if(data.data>99){
1262
				if (data.data > 99) {
1227
					$("#teamCount").text("99+");
1263
					$("#teamCount").text("99+");
1228
				}
1264
				}
1229
			});
1265
			});
1230
			oAjax("/ajax/article/count/publish",{//文章总数
1266
			oAjax("/ajax/article/count/publish", { //文章总数
1231
				"owner": professorId,
1267
				"owner": professorId,
1232
				"category":"1"
1233
			}, "GET", function(data){
1234
				if(data.data>0 && data.data<99){
1268
				"category": "1"
1269
			}, "GET", function (data) {
1270
				if (data.data > 0 && data.data < 99) {
1235
					$("#artCount").text(data.data);
1271
					$("#artCount").text(data.data);
1236
				}
1272
				}
1237
				if(data.data>99){
1273
				if (data.data > 99) {
1238
					$("#artCount").text("99+");
1274
					$("#artCount").text("99+");
1239
				}
1275
				}
1240
			});
1276
			});
1241
			oAjax("/ajax/resource/count/publish",{//资源总数
1277
			oAjax("/ajax/resource/count/publish", { //资源总数
1242
				"owner": professorId,
1278
				"owner": professorId,
1243
				"category":"1"
1244
			}, "GET", function(data){
1245
				if(data.data>0 && data.data<99){
1279
				"category": "1"
1280
			}, "GET", function (data) {
1281
				if (data.data > 0 && data.data < 99) {
1246
					$("#resCount").text(data.data);
1282
					$("#resCount").text(data.data);
1247
				}
1283
				}
1248
				if(data.data>99){
1284
				if (data.data > 99) {
1249
					$("#resCount").text("99+");
1285
					$("#resCount").text("99+");
1250
				}
1286
				}
1251
			});
1287
			});
1252
			oAjax("/ajax/ware/count/publish",{//服务总数
1288
			oAjax("/ajax/ware/count/publish", { //服务总数
1253
				"owner": professorId,
1289
				"owner": professorId,
1254
				"category":"1"
1255
			}, "GET", function(data){
1256
				if(data.data>0 && data.data<99){
1290
				"category": "1"
1291
			}, "GET", function (data) {
1292
				if (data.data > 0 && data.data < 99) {
1257
					$("#serCount").text(data.data);
1293
					$("#serCount").text(data.data);
1258
				}
1294
				}
1259
				if(data.data>99){
1295
				if (data.data > 99) {
1260
					$("#serCount").text("99+");
1296
					$("#serCount").text("99+");
1261
				}
1297
				}
1262
			});
1298
			});
1263
			oAjax("/ajax/ppatent/count/publish",{//专利总数
1299
			oAjax("/ajax/ppatent/count/publish", { //专利总数
1264
				"owner": professorId,
1300
				"owner": professorId,
1265
			}, "GET", function(data){
1266
				if(data.data>0 && data.data<99){
1301
			}, "GET", function (data) {
1302
				if (data.data > 0 && data.data < 99) {
1267
					$("#patCount").text(data.data);
1303
					$("#patCount").text(data.data);
1268
				}
1304
				}
1269
				if(data.data>99){
1305
				if (data.data > 99) {
1270
					$("#patCount").text("99+");
1306
					$("#patCount").text("99+");
1271
				}
1307
				}
1272
			});
1308
			});
1273
			oAjax("/ajax/resResult/count/researcher",{//非专利成果总数
1309
			oAjax("/ajax/resResult/count/researcher", { //非专利成果总数
1274
				"id": professorId
1310
				"id": professorId
1275
			}, "GET", function(data){
1276
				if(data.data>0 && data.data<99){
1311
			}, "GET", function (data) {
1312
				if (data.data > 0 && data.data < 99) {
1277
					$("#unpatCount").text(data.data);
1313
					$("#unpatCount").text(data.data);
1278
				}
1314
				}
1279
				if(data.data>99){
1315
				if (data.data > 99) {
1280
					$("#unpatCount").text("99+");
1316
					$("#unpatCount").text("99+");
1281
				}
1317
				}
1282
			});
1318
			});
1283
			oAjax("/ajax/ppaper/count/publish",{//论文总数
1319
			oAjax("/ajax/ppaper/count/publish", { //论文总数
1284
				"owner": professorId,
1320
				"owner": professorId,
1285
			}, "GET", function(data){
1286
				if(data.data>0 && data.data<99){
1321
			}, "GET", function (data) {
1322
				if (data.data > 0 && data.data < 99) {
1287
					$("#parCount").text(data.data);
1323
					$("#parCount").text(data.data);
1288
				}
1324
				}
1289
				if(data.data>99){
1325
				if (data.data > 99) {
1290
					$("#parCount").text("99+");
1326
					$("#parCount").text("99+");
1291
				}
1327
				}
1292
			});
1328
			});
1293
		},
1329
		},
1294
		attentMyself=function(isbind){
1295
			var aimId="attendMy",newStr="用户尚未被任何人关注"
1296
			oAjax("/ajax/watch/watchList",{//关注我的列表
1330
		attentMyself = function (isbind) {
1331
			var aimId = "attendMy",
1332
				newStr = "用户尚未被任何人关注"
1333
			oAjax("/ajax/watch/watchList", { //关注我的列表
1297
				"watchObject": professorId,
1334
				"watchObject": professorId,
1298
				"createTime": watchO.beiTime,
1335
				"createTime": watchO.beiTime,
1299
				"professorId":watchO.beiProId,
1300
				"rows":rows
1301
			}, "GET", function(res){
1336
				"professorId": watchO.beiProId,
1337
				"rows": rows
1338
			}, "GET", function (res) {
1302
				console.log(res)
1339
				console.log(res)
1303
				var $info = res.data;
1340
				var $info = res.data;
1304
				if($info.length > 0) {
1305
					$("#"+aimId).show()
1341
				if ($info.length > 0) {
1342
					$("#" + aimId).show()
1306
					watchO.beiTime = $info[$info.length - 1].createTime;
1343
					watchO.beiTime = $info[$info.length - 1].createTime;
1307
					watchO.beiProId = $info[$info.length - 1].professorId;
1344
					watchO.beiProId = $info[$info.length - 1].professorId;
1308
1345
1309
					var arr=[];
1310
					for(var i in $info) {
1311
						arr[i]=$info[i].professorId;
1346
					var arr = [];
1347
					for (var i in $info) {
1348
						arr[i] = $info[i].professorId;
1312
					}
1349
					}
1313
					detailPro(arr,aimId);
1314
				}
1315
				var liLen=document.getElementById(aimId).querySelectorAll("li").length;
1316
                removeNodata(aimId);
1317
                if($info.length == 0 && liLen == 0 ){
1318
                	$("#"+aimId).hide()
1319
                    insertNodata(aimId,newStr);
1320
                }
1321
                if(isbind){
1322
                	$("#"+aimId).parent().find(".js-load-more").unbind("click").on("click",function(){
1323
					 	attentMyself(false)
1350
					detailPro(arr, aimId);
1351
				}
1352
				var liLen = document.getElementById(aimId).querySelectorAll("li").length;
1353
				removeNodata(aimId);
1354
				if ($info.length == 0 && liLen == 0) {
1355
					$("#" + aimId).hide()
1356
					insertNodata(aimId, newStr);
1357
				}
1358
				if (isbind) {
1359
					$("#" + aimId).parent().find(".js-load-more").unbind("click").on("click", function () {
1360
						attentMyself(false)
1324
					})
1361
					})
1325
                }
1362
				}
1326
				if ($info.length < rows) {
1363
				if ($info.length < rows) {
1327
                    $("#"+aimId).parent().find(".js-load-more").unbind("click");
1328
                    $("#"+aimId).parent().find(".js-load-more").hide();
1329
                }
1330
			},function(){
1331
				$("#"+aimId).parent().find(".js-load-more").attr("disabled",true);
1332
	       		$("#"+aimId).parent().find(".js-load-more").addClass("active");
1333
			},function(){
1334
				$("#"+aimId).parent().find(".js-load-more").removeAttr("disabled");
1335
	        	$("#"+aimId).parent().find(".js-load-more").removeClass("active");
1364
					$("#" + aimId).parent().find(".js-load-more").unbind("click");
1365
					$("#" + aimId).parent().find(".js-load-more").hide();
1366
				}
1367
			}, function () {
1368
				$("#" + aimId).parent().find(".js-load-more").attr("disabled", true);
1369
				$("#" + aimId).parent().find(".js-load-more").addClass("active");
1370
			}, function () {
1371
				$("#" + aimId).parent().find(".js-load-more").removeAttr("disabled");
1372
				$("#" + aimId).parent().find(".js-load-more").removeClass("active");
1336
			})
1373
			})
1337
		},
1374
		},
1338
		collectAnswer=function(isbind){
1339
			var aimId="attendAnswer",newStr="用户还未收藏任何回答"
1340
			oAjax("/ajax/question/answer/byWatch",{
1341
				"time":watchO.WATime,
1342
                "id":watchO.WAId,
1343
                "uid":professorId,
1344
                "rows":rows
1345
			}, "get", function(res){
1375
		collectAnswer = function (isbind) {
1376
			var aimId = "attendAnswer",
1377
				newStr = "用户还未收藏任何回答"
1378
			oAjax("/ajax/question/answer/byWatch", {
1379
				"time": watchO.WATime,
1380
				"id": watchO.WAId,
1381
				"uid": professorId,
1382
				"rows": rows
1383
			}, "get", function (res) {
1346
				var $info = res.data;
1384
				var $info = res.data;
1347
				if($info.length > 0) {
1348
					$("#"+aimId).show()
1385
				if ($info.length > 0) {
1386
					$("#" + aimId).show()
1349
					watchO.WATime = $info[$info.length - 1].createTime;
1387
					watchO.WATime = $info[$info.length - 1].createTime;
1350
					watchO.WAId = $info[$info.length - 1].id;
1388
					watchO.WAId = $info[$info.length - 1].id;
1351
			
1352
					for(var i = 0; i < $info.length; i++) {
1389
1390
					for (var i = 0; i < $info.length; i++) {
1353
						var listLi = $('<li>')
1391
						var listLi = $('<li>')
1354
						listLi.appendTo($("#"+aimId));
1355
                        detailAnswer($info[i], listLi);
1392
						listLi.appendTo($("#" + aimId));
1393
						detailAnswer($info[i], listLi);
1356
					}
1394
					}
1357
				}
1395
				}
1358
				var liLen=document.getElementById(aimId).querySelectorAll("li").length;
1359
                removeNodata(aimId);
1360
                if($info.length == 0 && liLen == 0 ){
1361
                	$("#"+aimId).hide()
1362
                    insertNodata(aimId,newStr);
1363
                }
1364
                if(isbind){
1365
                	$("#"+aimId).parent().find(".js-load-more").unbind("click").on("click",function(){
1366
					 	collectAnswer(false)
1396
				var liLen = document.getElementById(aimId).querySelectorAll("li").length;
1397
				removeNodata(aimId);
1398
				if ($info.length == 0 && liLen == 0) {
1399
					$("#" + aimId).hide()
1400
					insertNodata(aimId, newStr);
1401
				}
1402
				if (isbind) {
1403
					$("#" + aimId).parent().find(".js-load-more").unbind("click").on("click", function () {
1404
						collectAnswer(false)
1367
					})
1405
					})
1368
                }
1406
				}
1369
				if ($info.length < rows) {
1407
				if ($info.length < rows) {
1370
                    $("#"+aimId).parent().find(".js-load-more").unbind("click");
1371
                    $("#"+aimId).parent().find(".js-load-more").hide();
1372
                }
1373
			},function(){
1374
				$("#"+aimId).parent().find(".js-load-more").attr("disabled",true);
1375
	       		$("#"+aimId).parent().find(".js-load-more").addClass("active");
1376
			},function(){
1377
				$("#"+aimId).parent().find(".js-load-more").removeAttr("disabled");
1378
	        	$("#"+aimId).parent().find(".js-load-more").removeClass("active");
1408
					$("#" + aimId).parent().find(".js-load-more").unbind("click");
1409
					$("#" + aimId).parent().find(".js-load-more").hide();
1410
				}
1411
			}, function () {
1412
				$("#" + aimId).parent().find(".js-load-more").attr("disabled", true);
1413
				$("#" + aimId).parent().find(".js-load-more").addClass("active");
1414
			}, function () {
1415
				$("#" + aimId).parent().find(".js-load-more").removeAttr("disabled");
1416
				$("#" + aimId).parent().find(".js-load-more").removeClass("active");
1379
			})
1417
			})
1380
    	},
1381
    	collectQuestion=function(isbind){
1382
			var aimId="attendQuestion",newStr="用户还未关注任何问题"
1383
			oAjax("/ajax/question/watch",{
1384
				"time":watchO.WQTime,
1385
                "id":watchO.WQId,
1386
                "uid":professorId,
1387
                "rows":rows
1388
			}, "get", function(res){
1418
		},
1419
		collectQuestion = function (isbind) {
1420
			var aimId = "attendQuestion",
1421
				newStr = "用户还未关注任何问题"
1422
			oAjax("/ajax/question/watch", {
1423
				"time": watchO.WQTime,
1424
				"id": watchO.WQId,
1425
				"uid": professorId,
1426
				"rows": rows
1427
			}, "get", function (res) {
1389
				var $info = res.data;
1428
				var $info = res.data;
1390
				if($info.length > 0) {
1391
					$("#"+aimId).show()
1429
				if ($info.length > 0) {
1430
					$("#" + aimId).show()
1392
					watchO.WQTime = $info[$info.length - 1].createTime;
1431
					watchO.WQTime = $info[$info.length - 1].createTime;
1393
					watchO.WQId = $info[$info.length - 1].id;
1432
					watchO.WQId = $info[$info.length - 1].id;
1394
			
1395
					for(var i = 0; i < $info.length; i++) {
1433
1434
					for (var i = 0; i < $info.length; i++) {
1396
						var listLi = $('<li>')
1435
						var listLi = $('<li>')
1397
						listLi.appendTo($("#"+aimId));
1398
                        detailQuestion($info[i], listLi);
1436
						listLi.appendTo($("#" + aimId));
1437
						detailQuestion($info[i], listLi);
1399
					}
1438
					}
1400
				}
1439
				}
1401
				var liLen=document.getElementById(aimId).querySelectorAll("li").length;
1402
                removeNodata(aimId);
1403
                if($info.length == 0 && liLen == 0 ){
1404
                	$("#"+aimId).hide()
1405
                    insertNodata(aimId,newStr);
1406
                }
1407
                if(isbind){
1408
                	$("#"+aimId).parent().find(".js-load-more").unbind("click").on("click",function(){
1409
					 	collectQuestion(false)
1440
				var liLen = document.getElementById(aimId).querySelectorAll("li").length;
1441
				removeNodata(aimId);
1442
				if ($info.length == 0 && liLen == 0) {
1443
					$("#" + aimId).hide()
1444
					insertNodata(aimId, newStr);
1445
				}
1446
				if (isbind) {
1447
					$("#" + aimId).parent().find(".js-load-more").unbind("click").on("click", function () {
1448
						collectQuestion(false)
1410
					})
1449
					})
1411
                }
1450
				}
1412
				if ($info.length < rows) {
1451
				if ($info.length < rows) {
1413
                    $("#"+aimId).parent().find(".js-load-more").unbind("click");
1414
                    $("#"+aimId).parent().find(".js-load-more").hide();
1415
                }
1416
			},function(){
1417
				$("#"+aimId).parent().find(".js-load-more").attr("disabled",true);
1418
	       		$("#"+aimId).parent().find(".js-load-more").addClass("active");
1419
			},function(){
1420
				$("#"+aimId).parent().find(".js-load-more").removeAttr("disabled");
1421
	        	$("#"+aimId).parent().find(".js-load-more").removeClass("active");
1452
					$("#" + aimId).parent().find(".js-load-more").unbind("click");
1453
					$("#" + aimId).parent().find(".js-load-more").hide();
1454
				}
1455
			}, function () {
1456
				$("#" + aimId).parent().find(".js-load-more").attr("disabled", true);
1457
				$("#" + aimId).parent().find(".js-load-more").addClass("active");
1458
			}, function () {
1459
				$("#" + aimId).parent().find(".js-load-more").removeAttr("disabled");
1460
				$("#" + aimId).parent().find(".js-load-more").removeClass("active");
1422
			})
1461
			})
1423
		},
1462
		},
1424
		collectSorts=function(type,isbind){
1425
			var aimId="",newStr=""
1426
			oAjax("/ajax/watch/proList",{//我关注的列表
1463
		collectSorts = function (type, isbind) {
1464
			var aimId = "",
1465
				newStr = ""
1466
			oAjax("/ajax/watch/proList", { //我关注的列表
1427
				"professorId": professorId,
1467
				"professorId": professorId,
1428
				"watchType":type,
1468
				"watchType": type,
1429
				"createTime": watchO.watchTime,
1469
				"createTime": watchO.watchTime,
1430
				// "watchObject":watchO.watchObjId,
1431
				"watchObject":1,
1432
				"rows":rows
1433
			}, "GET", function(res){
1434
		console.log(professorId)
1435
				
1470
				"watchObject": watchO.watchObjId,
1471
				// "watchObject": 1,
1472
				"rows": rows
1473
			}, "GET", function (res) {
1474
				console.log(type)
1436
				var $info = res.data;
1475
				var $info = res.data;
1437
				var arr=[];
1438
				if($info.length > 0) {
1439
					$("#"+aimId).show()
1476
				var arr = [];
1477
				console.log(arr)
1478
				if ($info.length > 0) {
1479
					$("#" + aimId).show()
1440
					watchO.watchTime = $info[$info.length - 1].createTime;
1480
					watchO.watchTime = $info[$info.length - 1].createTime;
1441
					watchO.watchObjId = $info[$info.length - 1].watchObject;
1481
					watchO.watchObjId = $info[$info.length - 1].watchObject;
1442
					for(var i in $info) {
1443
						arr[i]=$info[i].watchObject;
1444
						console.log()
1482
					for (var i in $info) {
1483
						arr[i] = $info[i].watchObject;
1445
					}
1484
					}
1446
				}
1485
				}
1447
				if(type==1){
1448
                	aimId="attendPro"
1449
                	newStr="用户还未关注任何专家"
1450
                	detailPro(arr,aimId);
1451
                }else if(type==2){
1452
                	aimId="attendRes"
1453
                	newStr="用户还未收藏任何资源"
1454
                	detailRes(arr,aimId);
1455
				}else if(type==3){
1456
					aimId="attendArt"
1457
					newStr="用户还未收藏任何文章"
1458
					detailArt(arr,aimId);
1459
				}else if(type==4){
1460
					aimId="attendPatent"
1461
					newStr="用户还未收藏任何专利成果"
1462
					detailPat(arr,aimId);
1463
				}else if(type==5){
1464
					aimId="attendPaper"
1465
					newStr="用户还未收藏任何论文"
1466
					detailPer(arr,aimId);
1467
				}else if(type==6){
1468
					aimId="attendCmp"
1469
					newStr="用户还未关注任何企业"
1470
					detailCmp(arr,aimId);
1471
				}else if(type==7){
1472
					aimId="attendDemand"
1473
					newStr="用户还未收藏任何需求"
1474
					detailDemand(arr,aimId);
1475
				}else if(type==10){
1476
					aimId="attendSer"
1477
					newStr="用户还未收藏任何服务"
1478
					detailService(arr,aimId);
1479
				}else if(type==11){
1480
					aimId="attendProduct"
1481
					newStr="用户还未收藏任何产品"
1482
					detailProduct(arr,aimId);
1483
				}
1484
				else if(type==12){
1485
					aimId="attendUnPatent"
1486
					newStr="用户还未收藏任何非专利成果"
1487
					detailUnPat(arr,aimId);
1488
				}else if(type==13){
1489
					aimId="attendTeam"
1490
					newStr="用户还未关注任何团队"
1491
					detailTeam(arr,aimId);
1492
				}
1493
				var liLen=document.getElementById(aimId).querySelectorAll("li").length;
1494
                removeNodata(aimId);
1495
                if($info.length == 0 && liLen == 0 ){
1496
                	$("#"+aimId).hide()
1497
                    insertNodata(aimId,newStr);
1498
                }
1499
                if(isbind){
1500
                	$("#"+aimId).parent().find(".js-load-more").unbind("click").on("click",function(){
1501
					 	collectSorts(type,false)
1486
				if (type == 1) {
1487
					aimId = "attendPro"
1488
					newStr = "用户还未关注任何专家"
1489
					detailPro(arr, aimId);
1490
				} else if (type == 2) {
1491
					aimId = "attendRes"
1492
					newStr = "用户还未收藏任何资源"
1493
					detailRes(arr, aimId);
1494
				} else if (type == 3) {
1495
					aimId = "attendArt"
1496
					newStr = "用户还未收藏任何文章"
1497
					detailArt(arr, aimId);
1498
				} else if (type == 4) {
1499
					aimId = "attendPatent"
1500
					newStr = "用户还未收藏任何专利成果"
1501
					detailPat(arr, aimId);
1502
				} else if (type == 5) {
1503
					aimId = "attendPaper"
1504
					newStr = "用户还未收藏任何论文"
1505
					detailPer(arr, aimId);
1506
				} else if (type == 6) {
1507
					aimId = "attendCmp"
1508
					newStr = "用户还未关注任何企业"
1509
					detailCmp(arr, aimId);
1510
				} else if (type == 7) {
1511
					aimId = "attendDemand"
1512
					newStr = "用户还未收藏任何需求"
1513
					detailDemand(arr, aimId);
1514
				} else if (type == 10) {
1515
					aimId = "attendSer"
1516
					newStr = "用户还未收藏任何服务"
1517
					detailService(arr, aimId);
1518
				} else if (type == 11) {
1519
					aimId = "attendProduct"
1520
					newStr = "用户还未收藏任何产品"
1521
					detailProduct(arr, aimId);
1522
				} else if (type == 12) {
1523
					aimId = "attendUnPatent"
1524
					newStr = "用户还未收藏任何非专利成果"
1525
					detailUnPat(arr, aimId);
1526
				} else if (type == 13) {
1527
					aimId = "attendTeam"
1528
					newStr = "用户还未关注任何团队"
1529
					detailTeam(arr, aimId);
1530
				}
1531
				var liLen = document.getElementById(aimId).querySelectorAll("li").length;
1532
				removeNodata(aimId);
1533
				if ($info.length == 0 && liLen == 0) {
1534
					$("#" + aimId).hide()
1535
					insertNodata(aimId, newStr);
1536
				}
1537
				if (isbind) {
1538
					$("#" + aimId).parent().find(".js-load-more").unbind("click").on("click", function () {
1539
						collectSorts(type, false)
1502
					})
1540
					})
1503
                }
1541
				}
1504
				if ($info.length < rows) {
1542
				if ($info.length < rows) {
1505
                    $("#"+aimId).parent().find(".js-load-more").unbind("click");
1506
                    $("#"+aimId).parent().find(".js-load-more").hide();
1507
                }
1508
			},function(){
1509
				$("#"+aimId).parent().find(".js-load-more").attr("disabled",true);
1510
	       		$("#"+aimId).parent().find(".js-load-more").addClass("active");
1511
			},function(){
1512
				$("#"+aimId).parent().find(".js-load-more").removeAttr("disabled");
1513
	        	$("#"+aimId).parent().find(".js-load-more").removeClass("active");
1543
					$("#" + aimId).parent().find(".js-load-more").unbind("click");
1544
					$("#" + aimId).parent().find(".js-load-more").hide();
1545
				}
1546
			}, function () {
1547
				$("#" + aimId).parent().find(".js-load-more").attr("disabled", true);
1548
				$("#" + aimId).parent().find(".js-load-more").addClass("active");
1549
			}, function () {
1550
				$("#" + aimId).parent().find(".js-load-more").removeAttr("disabled");
1551
				$("#" + aimId).parent().find(".js-load-more").removeClass("active");
1514
			})
1552
			})
1515
		},
1553
		},
1516
		detailTeam=function(arr,obj) {	
1517
			oAjax("/ajax/team/qm",{
1518
				id:arr,
1519
			},"get",function(data){
1520
				var dataStr=data.data;
1521
				for(var i =0; i< dataStr.length; ++i){
1554
		detailTeam = function (arr, obj) {
1555
			oAjax("/ajax/team/qm", {
1556
				id: arr,
1557
			}, "get", function (data) {
1558
				var dataStr = data.data;
1559
				for (var i = 0; i < dataStr.length; ++i) {
1522
					var li = document.createElement("li");
1560
					var li = document.createElement("li");
1523
					li.className = "mui-table-view-cell";
1561
					li.className = "mui-table-view-cell";
1524
				
1525
					var strAdd = '';
1562
					var strAdd = '';
1526
						strAdd += '<a  target="_blank" href="teamInforShow.html?id='+ dataStr[i].id +'" class="flexCenter urlgo">';
1527
						strAdd += '<div class="madiaInfo" style="padding-left:0"><p class="h1Font ellipsisSty">' + dataStr[i].name + '</span> <small> 团队人数 <span class="teamMembers"></span>人</small></p>';
1528
						strAdd += '<p class="h2Font ellipsisSty">' + dataStr[i].city +' '+  dataStr[i].orgName + '</p>';
1529
						strAdd += '</div>';
1530
						strAdd += '</a>'
1563
					strAdd += '<a  target="_blank" href="teamInfoShow.html?id=' + dataStr[i].id + '" class="flexCenter urlgo">';
1564
					strAdd += '<div class="madiaInfo" style="padding-left:0"><p class="h1Font ellipsisSty">' + dataStr[i].name + '</span> </p>';
1565
					strAdd += '<p class="h2Font ellipsisSty">' + dataStr[i].city + ' ' + dataStr[i].orgName + '</p>';
1566
					strAdd += '</div>';
1567
					strAdd += '</a>'
1568
					li.innerHTML = strAdd
1569
					document.getElementById(obj).appendChild(li);
1531
					var $itemlist = $(strAdd);
1570
					var $itemlist = $(strAdd);
1532
					$("#"+obj).append($itemlist);
1533
					teamProCount(dataStr[i].id, $itemlist)
1571
					teamProCount(dataStr[i].id, $itemlist)
1534
				}
1572
				}
1535
			});
1573
			});
1536
		},
1574
		},
1537
		teamProCount=function (id, $list) {
1538
			oAjax("/ajax/team/pro/count",{
1575
		teamProCount = function (id, $list) {
1576
			oAjax("/ajax/team/pro/count", {
1539
				"id": id
1577
				"id": id
1540
			}, 'get', function($data) {
1578
			}, 'get', function ($data) {
1541
				$list.find('.teamMembers').html($data.data)
1579
				$list.find('.teamMembers').html($data.data)
1542
			})
1580
			})
1543
		},
1581
		},
1544
		detailPro=function(arr,obj) {
1545
			oAjax("/ajax/professor/qm",{
1546
				id:arr,
1547
			},"get",function(data){
1548
				var dataStr=data.data;
1549
				for(var i = 0; i < dataStr.length; i++) {
1582
		detailPro = function (arr, obj) {
1583
			oAjax("/ajax/professor/qm", {
1584
				id: arr,
1585
			}, "get", function (data) {
1586
				var dataStr = data.data;
1587
				for (var i = 0; i < dataStr.length; i++) {
1550
					var li = document.createElement("li");
1588
					var li = document.createElement("li");
1551
					li.className = "mui-table-view-cell";
1589
					li.className = "mui-table-view-cell";
1552
					var userType = autho(dataStr[i].authType, dataStr[i].orgAuth, dataStr[i].authStatus);
1590
					var userType = autho(dataStr[i].authType, dataStr[i].orgAuth, dataStr[i].authStatus);
1553
					var os = "";
1591
					var os = "";
1554
					if(dataStr[i].title) {
1555
						if(dataStr[i].orgName) {
1592
					if (dataStr[i].title) {
1593
						if (dataStr[i].orgName) {
1556
							os = dataStr[i].title + "," + dataStr[i].orgName;
1594
							os = dataStr[i].title + "," + dataStr[i].orgName;
1557
						} else {
1595
						} else {
1558
							os = dataStr[i].title;
1596
							os = dataStr[i].title;
1559
						}
1597
						}
1560
					} else {
1598
					} else {
1561
						if(dataStr[i].office) {
1562
							if(dataStr[i].orgName) {
1599
						if (dataStr[i].office) {
1600
							if (dataStr[i].orgName) {
1563
								os = dataStr[i].office + "," + dataStr[i].orgName;
1601
								os = dataStr[i].office + "," + dataStr[i].orgName;
1564
							} else {
1602
							} else {
1565
								os = dataStr[i].office;
1603
								os = dataStr[i].office;
1566
							}
1604
							}
1567
						} else {
1605
						} else {
1568
							if(dataStr[i].orgName) {
1606
							if (dataStr[i].orgName) {
1569
								os = dataStr[i].orgName;
1607
								os = dataStr[i].orgName;
1570
							}
1608
							}
1571
						}
1609
						}
1572
					}
1610
					}
1573
					var baImg = "../images/default-photo.jpg";
1611
					var baImg = "../images/default-photo.jpg";
1574
					if(dataStr[i].hasHeadImage == 1) {
1612
					if (dataStr[i].hasHeadImage == 1) {
1575
						baImg = "/images/head/" + dataStr[i].id + "_l.jpg";
1613
						baImg = "/images/head/" + dataStr[i].id + "_l.jpg";
1576
					}
1614
					}
1577
				
1615
1578
					var strAdd = '';
1616
					var strAdd = '';
1579
						strAdd += '<a  target="_blank" href="userInforShow.html?professorId='+ dataStr[i].id +'" class="flexCenter urlgo">';
1580
						strAdd += '<div class="madiaHead useHead" style="width: 80px;height: 80px;margin-top: -40px;background-image:url(' + baImg + ')"></div>';
1581
						strAdd += '<div class="madiaInfo" style="padding-left:92px"><p class="h1Font ellipsisSty">' + dataStr[i].name + '</span><em class="authicon ' + userType.sty + '" title="'+userType.title+'"></em></p>';
1582
						strAdd += '<p class="h2Font ellipsisSty">' + os + '</p>';
1583
						strAdd += '</div>';
1584
						strAdd += '</a>'
1617
					strAdd += '<a  target="_blank" href="userInforShow.html?professorId=' + dataStr[i].id + '" class="flexCenter urlgo">';
1618
					strAdd += '<div class="madiaHead useHead" style="width: 80px;height: 80px;margin-top: -40px;background-image:url(' + baImg + ')"></div>';
1619
					strAdd += '<div class="madiaInfo" style="padding-left:92px"><p class="h1Font ellipsisSty">' + dataStr[i].name + '</span><em class="authicon ' + userType.sty + '" title="' + userType.title + '"></em></p>';
1620
					strAdd += '<p class="h2Font ellipsisSty">' + os + '</p>';
1621
					strAdd += '</div>';
1622
					strAdd += '</a>'
1585
					li.innerHTML = strAdd
1623
					li.innerHTML = strAdd
1586
					document.getElementById(obj).appendChild(li);
1624
					document.getElementById(obj).appendChild(li);
1587
				}
1625
				}
1588
			});
1626
			});
1589
		},
1627
		},
1590
		detailCmp=function(arr,obj) {
1591
			oAjax("/ajax/org/qm",{
1592
				id:arr,
1593
			},"get",function(data){
1594
				var dataStr=data.data;
1595
				for(var i = 0; i < dataStr.length; i++) {
1628
		detailCmp = function (arr, obj) {
1629
			oAjax("/ajax/org/qm", {
1630
				id: arr,
1631
			}, "get", function (data) {
1632
				var dataStr = data.data;
1633
				for (var i = 0; i < dataStr.length; i++) {
1596
					var li = document.createElement("li");
1634
					var li = document.createElement("li");
1597
					li.setAttribute("data-id", dataStr[i].id);
1635
					li.setAttribute("data-id", dataStr[i].id);
1598
					var oimg = (dataStr[i].hasOrgLogo) ?"/images/org/" + dataStr[i].id + ".jpg" : "../images/default-icon.jpg";
1636
					var oimg = (dataStr[i].hasOrgLogo) ? "/images/org/" + dataStr[i].id + ".jpg" : "../images/default-icon.jpg";
1599
					var oAuth = (dataStr[i].authStatus == 3) ? 'authicon-com-ok' : '';
1637
					var oAuth = (dataStr[i].authStatus == 3) ? 'authicon-com-ok' : '';
1600
					var orgName = (dataStr[i].forShort) ? dataStr[i].forShort : dataStr[i].name;
1638
					var orgName = (dataStr[i].forShort) ? dataStr[i].forShort : dataStr[i].name;
1601
					var orgType = (dataStr[i].orgType == '2') ? "上市企业" : "";
1639
					var orgType = (dataStr[i].orgType == '2') ? "上市企业" : "";
1602
					var orgOther = (dataStr[i].industry) ? dataStr[i].industry.replace(/,/gi, " | ") : "";
1640
					var orgOther = (dataStr[i].industry) ? dataStr[i].industry.replace(/,/gi, " | ") : "";
1603
					li.className = "mui-table-view-cell";
1641
					li.className = "mui-table-view-cell";
1604
					var itemlist=''
1605
						itemlist += '<a class="flexCenter" target="_blank" href="cmpInforShow.html?orgId='+dataStr[i].id+'"><div class="madiaHead cmpHead">';
1606
						itemlist += '<div class="boxBlock"><img class="boxBlockimg" src="' + oimg + '"></div></div>';
1607
						itemlist += '<div class="madiaInfo">';
1608
						itemlist += '<p class="h1Font"><span>' + orgName + '</span><em class="authiconNew ' + oAuth + '" title="科袖认证企业"></em></p>';
1609
	            		itemlist += '<p class="h2Font ellipsisSty"><span>' + orgType + '</span> <span>' + orgOther + '</span></p>';
1610
						itemlist += '</div></a>';
1642
					var itemlist = ''
1643
					itemlist += '<a class="flexCenter" target="_blank" href="cmpInforShow.html?orgId=' + dataStr[i].id + '"><div class="madiaHead cmpHead">';
1644
					itemlist += '<div class="boxBlock"><img class="boxBlockimg" src="' + oimg + '"></div></div>';
1645
					itemlist += '<div class="madiaInfo">';
1646
					itemlist += '<p class="h1Font"><span>' + orgName + '</span><em class="authiconNew ' + oAuth + '" title="科袖认证企业"></em></p>';
1647
					itemlist += '<p class="h2Font ellipsisSty"><span>' + orgType + '</span> <span>' + orgOther + '</span></p>';
1648
					itemlist += '</div></a>';
1611
					li.innerHTML = itemlist
1649
					li.innerHTML = itemlist
1612
					document.getElementById(obj).appendChild(li);
1650
					document.getElementById(obj).appendChild(li);
1613
				}
1651
				}
1614
			});
1652
			});
1615
		},
1653
		},
1616
		detailPat=function(arr,obj) {
1617
			oAjax("/ajax/ppatent/qm",{
1618
				id:arr,
1619
			},"get",function(data){
1620
				var dataStr=data.data;
1621
				for(var i = 0; i < dataStr.length; i++) {
1654
		detailPat = function (arr, obj) {
1655
			oAjax("/ajax/ppatent/qm", {
1656
				id: arr,
1657
			}, "get", function (data) {
1658
				var dataStr = data.data;
1659
				for (var i = 0; i < dataStr.length; i++) {
1622
					var li = document.createElement("li");
1660
					var li = document.createElement("li");
1623
					li.className = "mui-table-view-cell";
1661
					li.className = "mui-table-view-cell";
1624
					var strAdd = '';
1662
					var strAdd = '';
1625
						strAdd += '<a  target="_blank" href="/'+ pageUrl("pt",dataStr[i]) +'" class="flexCenter urlgo">';
1626
						strAdd += '<div class="madiaHead patentHead"></div>';
1627
						strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">'+ dataStr[i].name +'</p>';
1628
						strAdd += '<p class="h2Font ellipsisSty">发明人:'+ dataStr[i].authors.substring(0, dataStr[i].authors.length - 1) +'</p>';
1629
						strAdd += '<p class="h2Font ellipsisSty">申请人:'+ dataStr[i].reqPerson +'</p>';
1630
						strAdd += '</div>';
1631
						strAdd += '</a>';
1663
					strAdd += '<a  target="_blank" href="/' + pageUrl("pt", dataStr[i]) + '" class="flexCenter urlgo">';
1664
					strAdd += '<div class="madiaHead patentHead"></div>';
1665
					strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">' + dataStr[i].name + '</p>';
1666
					strAdd += '<p class="h2Font ellipsisSty">发明人:' + dataStr[i].authors.substring(0, dataStr[i].authors.length - 1) + '</p>';
1667
					strAdd += '<p class="h2Font ellipsisSty">申请人:' + dataStr[i].reqPerson + '</p>';
1668
					strAdd += '</div>';
1669
					strAdd += '</a>';
1632
					li.innerHTML = strAdd
1670
					li.innerHTML = strAdd
1633
					document.getElementById(obj).appendChild(li);
1671
					document.getElementById(obj).appendChild(li);
1634
				}
1672
				}
1635
			});
1673
			});
1636
		},
1674
		},
1637
		detailUnPat=function(arr,obj) {
1638
			oAjax("/ajax/resResult/qm",{
1639
				id:arr,
1640
			},"get",function(data){
1641
				var dataStr=data.data;
1642
				for(var i = 0; i < dataStr.length; i++) {
1675
		detailUnPat = function (arr, obj) {
1676
			oAjax("/ajax/resResult/qm", {
1677
				id: arr,
1678
			}, "get", function (data) {
1679
				var dataStr = data.data;
1680
				for (var i = 0; i < dataStr.length; i++) {
1643
					var li = document.createElement("li");
1681
					var li = document.createElement("li");
1644
					li.className = "mui-table-view-cell";
1682
					li.className = "mui-table-view-cell";
1645
					var resIM='<div class="madiaHead patentHead"></div>'
1683
					var resIM = '<div class="madiaHead patentHead"></div>'
1646
					if (dataStr[i].pic) {
1684
					if (dataStr[i].pic) {
1647
						var src = '/data/researchResult' + dataStr[i].pic.split(",")[0]
1685
						var src = '/data/researchResult' + dataStr[i].pic.split(",")[0]
1648
						resIM = '<div class="madiaHead patentHead" style="background-image:url('+ src +')"></div>';
1686
						resIM = '<div class="madiaHead patentHead" style="background-image:url(' + src + ')"></div>';
1649
					}
1687
					}
1650
					var strAdd = '';
1688
					var strAdd = '';
1651
						strAdd += '<a  target="_blank" href="unPatentShow.html?id='+dataStr[i].id+'" class="flexCenter urlgo">';
1652
						strAdd += resIM
1653
						strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">'+ dataStr[i].name +'</p>';
1654
						strAdd += '<p class="h2Font ellipsisSty displayNone">研究者:<span class="researchers"></span></p>';
1655
						if (dataStr[i].orgId){
1656
							strAdd += '<p class="h2Font ellipsisSty">所属机构:<span class="resOrgName"></span></p>';
1657
						}
1658
						strAdd += '</div>';
1659
						strAdd += '</a>';
1689
					strAdd += '<a  target="_blank" href="unPatentShow.html?id=' + dataStr[i].id + '" class="flexCenter urlgo">';
1690
					strAdd += resIM
1691
					strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">' + dataStr[i].name + '</p>';
1692
					strAdd += '<p class="h2Font ellipsisSty displayNone">研究者:<span class="researchers"></span></p>';
1693
					if (dataStr[i].orgId) {
1694
						strAdd += '<p class="h2Font ellipsisSty">所属机构:<span class="resOrgName"></span></p>';
1695
					}
1696
					strAdd += '</div>';
1697
					strAdd += '</a>';
1660
					li.innerHTML = strAdd
1698
					li.innerHTML = strAdd
1661
					document.getElementById(obj).appendChild(li);
1699
					document.getElementById(obj).appendChild(li);
1662
					var $itemlist = $(li);
1700
					var $itemlist = $(li);
1669
		},
1707
		},
1670
		queryResearcher = function (id, $list) {
1708
		queryResearcher = function (id, $list) {
1671
			if (id) {
1709
			if (id) {
1672
				oAjax("/ajax/resResult/researcher",{
1710
				oAjax("/ajax/resResult/researcher", {
1673
					"id": id
1711
					"id": id
1674
				}, 'get', function($data) {
1712
				}, 'get', function ($data) {
1675
					var arr = []
1713
					var arr = []
1676
					if($data.data.length) {
1714
					if ($data.data.length) {
1677
						$list.find('.researchers').parent().removeClass('displayNone')
1715
						$list.find('.researchers').parent().removeClass('displayNone')
1678
						for (var i = 0; i < $data.data.length;i++) {
1716
						for (var i = 0; i < $data.data.length; i++) {
1679
							arr.push($data.data[i].name)
1717
							arr.push($data.data[i].name)
1680
						}
1718
						}
1681
						$list.find('.researchers').html(arr.join(','))
1719
						$list.find('.researchers').html(arr.join(','))
1685
		},
1723
		},
1686
		queryReseOrgName = function (id, $list) {
1724
		queryReseOrgName = function (id, $list) {
1687
			if (id) {
1725
			if (id) {
1688
				cacheModel.getCompany(id,function(sc,value){
1689
					if(sc){
1690
						if(value.forShort){
1726
				cacheModel.getCompany(id, function (sc, value) {
1727
					if (sc) {
1728
						if (value.forShort) {
1691
							$list.find(".resOrgName").html(value.forShort)
1729
							$list.find(".resOrgName").html(value.forShort)
1692
						}else{
1730
						} else {
1693
							$list.find(".resOrgName").html(value.name)
1731
							$list.find(".resOrgName").html(value.name)
1694
						}
1732
						}
1695
					}
1733
					}
1696
				})
1734
				})
1697
			}
1735
			}
1698
		},
1736
		},
1699
		detailPer=function(arr,obj) {
1700
			oAjax("/ajax/ppaper/qm",{  //论文
1701
				id:arr,
1702
			},"get",function(data){
1703
				var dataStr=data.data;
1737
		detailPer = function (arr, obj) {
1738
			oAjax("/ajax/ppaper/qm", { //论文
1739
				id: arr,
1740
			}, "get", function (data) {
1741
				var dataStr = data.data;
1704
				console.log(dataStr)
1742
				console.log(dataStr)
1705
				for(var i = 0; i < dataStr.length; i++) {
1706
					var moreInf=""
1707
					if(!dataStr[i].cn4periodical){
1708
						dataStr[i].cn4periodical="";
1743
				for (var i = 0; i < dataStr.length; i++) {
1744
					var moreInf = ""
1745
					if (!dataStr[i].cn4periodical) {
1746
						dataStr[i].cn4periodical = "";
1709
					}
1747
					}
1710
					if(!dataStr[i].en4periodical){
1711
						dataStr[i].en4periodical="";
1748
					if (!dataStr[i].en4periodical) {
1749
						dataStr[i].en4periodical = "";
1712
					}
1750
					}
1713
					if(!dataStr[i].pubDay){
1714
						dataStr[i].pubDay="";
1751
					if (!dataStr[i].pubDay) {
1752
						dataStr[i].pubDay = "";
1715
					}
1753
					}
1716
					moreInf = dataStr[i].cn4periodical+ " " +dataStr[i].en4periodical+ " " +dataStr[i].pubDay
1717
					
1754
					moreInf = dataStr[i].cn4periodical + " " + dataStr[i].en4periodical + " " + dataStr[i].pubDay
1755
1718
					var li = document.createElement("li");
1756
					var li = document.createElement("li");
1719
					li.className = "mui-table-view-cell";
1757
					li.className = "mui-table-view-cell";
1720
					var strAdd = '';
1758
					var strAdd = '';
1721
						strAdd += '<a  target="_blank" href="/'+ pageUrl("pp",dataStr[i]) +'" class="flexCenter urlgo">';
1722
						strAdd += '<div class="madiaHead paperHead"></div>';
1723
						strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">'+ dataStr[i].name +'</p>';
1724
						strAdd += '<p class="h2Font ellipsisSty">作者:'+ dataStr[i].authors.substring(0, dataStr[i].authors.length - 1) +'</p>';
1725
						strAdd += '<p class="h2Font ellipsisSty">期刊:'+ moreInf +'</p>';
1726
						strAdd += '</div>';
1727
						strAdd += '</a>';
1759
					strAdd += '<a  target="_blank" href="/' + pageUrl("pp", dataStr[i]) + '" class="flexCenter urlgo">';
1760
					strAdd += '<div class="madiaHead paperHead"></div>';
1761
					strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">' + dataStr[i].name + '</p>';
1762
					strAdd += '<p class="h2Font ellipsisSty">作者:' + dataStr[i].authors.substring(0, dataStr[i].authors.length - 1) + '</p>';
1763
					strAdd += '<p class="h2Font ellipsisSty">期刊:' + moreInf + '</p>';
1764
					strAdd += '</div>';
1765
					strAdd += '</a>';
1728
					li.innerHTML = strAdd
1766
					li.innerHTML = strAdd
1729
					document.getElementById(obj).appendChild(li);
1767
					document.getElementById(obj).appendChild(li);
1730
				}
1768
				}
1731
			});
1769
			});
1732
		},
1770
		},
1733
		detailRes=function(arr,obj) {
1734
			oAjax("/ajax/resource/qm",{
1735
				id:arr,
1736
			},"get",function(data){
1771
		detailRes = function (arr, obj) {
1772
			oAjax("/ajax/resource/qm", {
1773
				id: arr,
1774
			}, "get", function (data) {
1737
				console.log(data)
1775
				console.log(data)
1738
				var dataItem=data.data;
1739
				for(var i = 0; i < dataItem.length; i++) {
1740
					var dataStr=dataItem[i]
1776
				var dataItem = data.data;
1777
				for (var i = 0; i < dataItem.length; i++) {
1778
					var dataStr = dataItem[i]
1741
					var rImg = "../images/default-resource.jpg";
1779
					var rImg = "../images/default-resource.jpg";
1742
					if(dataStr.images.length) {
1780
					if (dataStr.images.length) {
1743
						rImg = "/data/resource/" + dataStr.images[0].imageSrc;
1781
						rImg = "/data/resource/" + dataStr.images[0].imageSrc;
1744
					}
1782
					}
1745
					var li = document.createElement("li");
1783
					var li = document.createElement("li");
1746
					li.className = "mui-table-view-cell";
1784
					li.className = "mui-table-view-cell";
1747
					var strAdd = '';
1785
					var strAdd = '';
1748
						strAdd += '<a target="_blank" href="resourceShow.html?resourceId='+ dataStr.resourceId +'" class="flexCenter urlgo">';
1749
						strAdd += '<div class="madiaHead resouseHead" style="background-image:url('+ rImg +')"></div>';
1750
						strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">'+ dataStr.resourceName +'</p>';
1751
						strAdd += '<p class="h1Font ellipsisSty"><span class="ownerName"></span><em class="authiconNew ownerSty"></em></p>';
1752
						strAdd += '<p class="h2Font ellipsisSty-2">用途:'+ dataStr.supportedServices+'</p></div>';
1753
						strAdd += '</a>';
1754
					li.innerHTML =strAdd
1786
					strAdd += '<a target="_blank" href="resourceShow.html?resourceId=' + dataStr.resourceId + '" class="flexCenter urlgo">';
1787
					strAdd += '<div class="madiaHead resouseHead" style="background-image:url(' + rImg + ')"></div>';
1788
					strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">' + dataStr.resourceName + '</p>';
1789
					strAdd += '<p class="h1Font ellipsisSty"><span class="ownerName"></span><em class="authiconNew ownerSty"></em></p>';
1790
					strAdd += '<p class="h2Font ellipsisSty-2">用途:' + dataStr.supportedServices + '</p></div>';
1791
					strAdd += '</a>';
1792
					li.innerHTML = strAdd
1755
					var $itemlist = $(li);
1793
					var $itemlist = $(li);
1756
					document.getElementById(obj).appendChild(li);
1794
					document.getElementById(obj).appendChild(li);
1757
					if(dataStr.resourceType=="1"){
1758
						(function(mo){
1759
							cacheModel.getProfessor(dataStr.professorId,function(sc,value){
1760
								if(sc){
1795
					if (dataStr.resourceType == "1") {
1796
						(function (mo) {
1797
							cacheModel.getProfessor(dataStr.professorId, function (sc, value) {
1798
								if (sc) {
1761
									mo.find(".ownerName").html(value.name)
1799
									mo.find(".ownerName").html(value.name)
1762
									var userType = autho(value.authType, value.orgAuth, value.authStatus);
1800
									var userType = autho(value.authType, value.orgAuth, value.authStatus);
1763
									mo.find(".ownerSty").addClass(userType.sty).attr("title",userType.title)
1764
								}else{
1801
									mo.find(".ownerSty").addClass(userType.sty).attr("title", userType.title)
1802
								} else {
1765
									console.log("error")
1803
									console.log("error")
1766
								}
1804
								}
1767
							})
1805
							})
1768
						})($itemlist);
1806
						})($itemlist);
1769
					}else if(dataStr.resourceType=="2"){
1770
						(function(mo){
1771
							cacheModel.getCompany(dataStr.orgId,function(sc,value){
1772
								if(sc){
1773
									if(value.forShort){
1807
					} else if (dataStr.resourceType == "2") {
1808
						(function (mo) {
1809
							cacheModel.getCompany(dataStr.orgId, function (sc, value) {
1810
								if (sc) {
1811
									if (value.forShort) {
1774
										mo.find(".ownerName").html(value.forShort)
1812
										mo.find(".ownerName").html(value.forShort)
1775
									}else{
1813
									} else {
1776
										mo.find(".ownerName").html(value.name)
1814
										mo.find(".ownerName").html(value.name)
1777
									}
1815
									}
1778
									if(value.authStatus==3) {
1779
										mo.find(".ownerSty").addClass("authicon-com-ok").attr("title","科袖认证企业")
1816
									if (value.authStatus == 3) {
1817
										mo.find(".ownerSty").addClass("authicon-com-ok").attr("title", "科袖认证企业")
1780
									}
1818
									}
1781
								}else{
1819
								} else {
1782
									console.log("error")
1820
									console.log("error")
1783
								}
1821
								}
1784
							})
1822
							})
1787
				}
1825
				}
1788
			});
1826
			});
1789
		},
1827
		},
1790
		detailArt=function (arr,obj) {
1791
			oAjax("/ajax/article/qm",{
1792
				id:arr,
1793
			},"get",function(data){
1794
				var dataStr=data.data;
1795
				for(var i = 0; i < dataStr.length; i++) {
1796
					var dataItem=dataStr[i]
1828
		detailArt = function (arr, obj) {
1829
			oAjax("/ajax/article/qm", {
1830
				id: arr,
1831
			}, "get", function (data) {
1832
				var dataStr = data.data;
1833
				for (var i = 0; i < dataStr.length; i++) {
1834
					var dataItem = dataStr[i]
1797
					var arImg = "../images/default-artical.jpg";
1835
					var arImg = "../images/default-artical.jpg";
1798
					if(dataItem.articleImg) {
1799
						arImg ="/data/article/" + dataItem.articleImg
1836
					if (dataItem.articleImg) {
1837
						arImg = "/data/article/" + dataItem.articleImg
1800
					}
1838
					}
1801
					var li = document.createElement("li");
1839
					var li = document.createElement("li");
1802
					li.className = "mui-table-view-cell";
1840
					li.className = "mui-table-view-cell";
1803
					var strAdd = '';
1841
					var strAdd = '';
1804
						strAdd += '<a  target="_blank" href="/'+ pageUrl('a',dataItem) +'" class="flexCenter urlgo">';
1805
						strAdd += '<div class="madiaHead artHead" style="background-image:url('+ arImg +')"></div>';
1806
						strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty-2">'+ dataItem.articleTitle +'</p>';
1807
						strAdd += '<ul class="h2Font clearfix">';
1808
						strAdd += '<li><span class="ownerName"></span></li>';
1809
						strAdd += '<li><span class="time">'+ commenTime(dataItem.publishTime) +'</span></li>';
1810
						strAdd += '<li><span class="comment"></span></li>';
1811
						strAdd += '</ul></div>';
1812
						strAdd += '</a>';
1813
					li.innerHTML =strAdd
1842
					strAdd += '<a  target="_blank" href="/' + pageUrl('a', dataItem) + '" class="flexCenter urlgo">';
1843
					strAdd += '<div class="madiaHead artHead" style="background-image:url(' + arImg + ')"></div>';
1844
					strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty-2">' + dataItem.articleTitle + '</p>';
1845
					strAdd += '<ul class="h2Font clearfix">';
1846
					strAdd += '<li><span class="ownerName"></span></li>';
1847
					strAdd += '<li><span class="time">' + commenTime(dataItem.publishTime) + '</span></li>';
1848
					strAdd += '<li><span class="comment"></span></li>';
1849
					strAdd += '</ul></div>';
1850
					strAdd += '</a>';
1851
					li.innerHTML = strAdd
1814
					var $itemlist = $(li);
1852
					var $itemlist = $(li);
1815
					document.getElementById(obj).appendChild(li);
1853
					document.getElementById(obj).appendChild(li);
1816
					if(dataItem.articleType=="1"){
1817
						(function(mo){
1818
							cacheModel.getProfessor(dataItem.ownerId,function(sc,value){
1819
								if(sc){
1854
					if (dataItem.articleType == "1") {
1855
						(function (mo) {
1856
							cacheModel.getProfessor(dataItem.ownerId, function (sc, value) {
1857
								if (sc) {
1820
									mo.find(".ownerName").html(value.name)
1858
									mo.find(".ownerName").html(value.name)
1821
								}else{
1859
								} else {
1822
									console.log("error")
1860
									console.log("error")
1823
								}
1861
								}
1824
							})
1862
							})
1825
						})($itemlist);
1863
						})($itemlist);
1826
					}else if(dataItem.articleType=="2"){
1827
						(function(mo){
1828
							cacheModel.getCompany(dataItem.ownerId,function(sc,value){
1829
								if(sc){
1830
									if(value.forShort){
1864
					} else if (dataItem.articleType == "2") {
1865
						(function (mo) {
1866
							cacheModel.getCompany(dataItem.ownerId, function (sc, value) {
1867
								if (sc) {
1868
									if (value.forShort) {
1831
										mo.find(".ownerName").html(value.forShort)
1869
										mo.find(".ownerName").html(value.forShort)
1832
									}else{
1870
									} else {
1833
										mo.find(".ownerName").html(value.name)
1871
										mo.find(".ownerName").html(value.name)
1834
									}
1872
									}
1835
								}else{
1873
								} else {
1836
									console.log("error")
1874
									console.log("error")
1837
								}
1875
								}
1838
							})
1876
							})
1839
						})($itemlist);
1877
						})($itemlist);
1840
					}else if(dataItem.articleType=="3"){
1841
						(function(mo){
1842
							cacheModel.getPlatform(dataItem.ownerId,function(sc,value){
1843
								if(sc){
1878
					} else if (dataItem.articleType == "3") {
1879
						(function (mo) {
1880
							cacheModel.getPlatform(dataItem.ownerId, function (sc, value) {
1881
								if (sc) {
1844
									mo.find(".ownerName").html(value.name)
1882
									mo.find(".ownerName").html(value.name)
1845
								}else{
1883
								} else {
1846
									console.log("error")
1884
									console.log("error")
1847
								}
1885
								}
1848
							})
1886
							})
1851
				}
1889
				}
1852
			});
1890
			});
1853
		},
1891
		},
1854
		detailDemand=function(arr,obj) {
1855
			oAjax("/ajax/demand/qm",{
1856
				id:arr,
1857
			},"get",function(data){
1858
				var dataStr=data.data;
1859
				for(var i = 0; i < dataStr.length; i++) {
1892
		detailDemand = function (arr, obj) {
1893
			oAjax("/ajax/demand/qm", {
1894
				id: arr,
1895
			}, "get", function (data) {
1896
				var dataStr = data.data;
1897
				for (var i = 0; i < dataStr.length; i++) {
1860
					var li = document.createElement("li");
1898
					var li = document.createElement("li");
1861
					li.className = "mui-table-view-cell";
1899
					li.className = "mui-table-view-cell";
1862
					var strCon='<a  target="_blank" href="demandShow.html?demandId='+ dataStr[i].id +'" class="flexCenter urlgo">';
1863
					strCon+='<div class="madiaInfo" style="padding-left:0">'
1864
					strCon+='<p class="h1Font ellipsisSty">'+ dataStr[i].title +'</p>'
1865
					strCon+='<ul class="showli clearfix h3Font">'
1866
					
1867
					if(dataStr[i].city){ strCon+='<li>'+dataStr[i].city+'</li>' }
1868
					if(dataStr[i].duration!=0){ strCon+='<li>预期 '+demandDuration[dataStr[i].duration]+'</li>' }
1869
					if(dataStr[i].cost!=0){ strCon+='<li>预算 '+demandCost[dataStr[i].cost]+'</li>' }
1870
					if(dataStr[i].invalidDay){ strCon+='<li>有效期至 '+TimeTr(dataStr[i].invalidDay)+'</li>' }
1871
					
1872
					strCon+='</ul></div></a>'
1873
					
1900
					var strCon = '<a  target="_blank" href="demandShow.html?demandId=' + dataStr[i].id + '" class="flexCenter urlgo">';
1901
					strCon += '<div class="madiaInfo" style="padding-left:0">'
1902
					strCon += '<p class="h1Font ellipsisSty">' + dataStr[i].title + '</p>'
1903
					strCon += '<ul class="showli clearfix h3Font">'
1904
1905
					if (dataStr[i].city) {
1906
						strCon += '<li>' + dataStr[i].city + '</li>'
1907
					}
1908
					if (dataStr[i].duration != 0) {
1909
						strCon += '<li>预期 ' + demandDuration[dataStr[i].duration] + '</li>'
1910
					}
1911
					if (dataStr[i].cost != 0) {
1912
						strCon += '<li>预算 ' + demandCost[dataStr[i].cost] + '</li>'
1913
					}
1914
					if (dataStr[i].invalidDay) {
1915
						strCon += '<li>有效期至 ' + TimeTr(dataStr[i].invalidDay) + '</li>'
1916
					}
1917
1918
					strCon += '</ul></div></a>'
1919
1874
					li.innerHTML = strCon
1920
					li.innerHTML = strCon
1875
					document.getElementById(obj).appendChild(li);
1921
					document.getElementById(obj).appendChild(li);
1876
				}
1922
				}
1877
				
1923
1878
			});
1924
			});
1879
		},
1925
		},
1880
		detailAnswer=function(dataStr,listLi){
1881
	        var strAdd = '<a target="_blank" href="/qa-show.html?id='+dataStr.qid+'&topid='+dataStr.id+'">'+
1882
	            '<div class="madiaInfo" style="padding-left: 0">' +
1883
	            '<div class="ellipsisSty qa-question"></div>' +
1884
	            '<div class="flexCenter qa-owner">' +
1885
	            '</div>' +
1886
	            '<div class="qa-con ellipsisSty-3">' + listConCut(dataStr.cnt) +'</div>' +
1887
	            '<div class="showspan">' +
1888
	            '<span>'+commenTime(dataStr.createTime)+'</span>' +
1889
	            '<span class="agree"></span>' +
1890
	            '<span class="leaveMsgCount"></span>' +
1891
	            '</div>' +
1892
	            '</div></a>';
1893
	        var $strAdd = $(strAdd);
1894
	        listLi.append( $strAdd);
1895
	        if(dataStr.agree > 0) {
1896
	            $strAdd.find(".agree").html("赞	"+dataStr.agree);
1897
	        }
1898
	        questioninfo(dataStr.qid, $strAdd);
1899
	        proinfo(dataStr.uid, $strAdd);
1900
	        leaveMsgCount(dataStr.id,4, $strAdd);
1901
	    },
1902
		detailQuestion=function(dataStr,listLi) {
1903
	        var baImg = "../images/default-q&a.jpg";
1904
	        var subs = new Array();
1905
	        if(dataStr.img) {
1906
	        	var subs=strToAry(dataStr.img)
1907
	            baImg = "/data/question"+ subs[0];
1908
	        }
1909
	        var hd = "";
1910
	        if (dataStr.replyCount > 0) {
1911
	            hd = '<li><span>回答 ' + dataStr.replyCount + '</span></li>'
1912
	        }
1913
	        var strAdd = '<a target="_blank" href="/qa-show.html?id='+dataStr.id+'" class="flexCenter urlgo">'
1914
	        strAdd += '<div class="madiaHead qa-Head" style="background-image:url('+ baImg +')"></div>';
1915
	        strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty-2">'+ dataStr.title +'</p>';
1916
	        strAdd += '<ul class="h2Font clearfix">'
1917
	        strAdd += '<li><span class="time">'+commenTime(dataStr.createTime)+'</span></li><li><span class="qaPageview"></span></li>'+hd+'<li><span class="attendCount"></span></li>'
1918
	        strAdd += '</ul></div></a>'
1919
	
1920
	        var $str = $(strAdd);
1921
	        listLi.append($str);
1922
	   },
1923
		detailService=function(arr,obj) {
1924
			oAjax("/ajax/ware/qm",{
1925
				id:arr,
1926
			},"get",function(data){
1926
		detailAnswer = function (dataStr, listLi) {
1927
			var strAdd = '<a target="_blank" href="/qa-show.html?id=' + dataStr.qid + '&topid=' + dataStr.id + '">' +
1928
				'<div class="madiaInfo" style="padding-left: 0">' +
1929
				'<div class="ellipsisSty qa-question"></div>' +
1930
				'<div class="flexCenter qa-owner">' +
1931
				'</div>' +
1932
				'<div class="qa-con ellipsisSty-3">' + listConCut(dataStr.cnt) + '</div>' +
1933
				'<div class="showspan">' +
1934
				'<span>' + commenTime(dataStr.createTime) + '</span>' +
1935
				'<span class="agree"></span>' +
1936
				'<span class="leaveMsgCount"></span>' +
1937
				'</div>' +
1938
				'</div></a>';
1939
			var $strAdd = $(strAdd);
1940
			listLi.append($strAdd);
1941
			if (dataStr.agree > 0) {
1942
				$strAdd.find(".agree").html("赞	" + dataStr.agree);
1943
			}
1944
			questioninfo(dataStr.qid, $strAdd);
1945
			proinfo(dataStr.uid, $strAdd);
1946
			leaveMsgCount(dataStr.id, 4, $strAdd);
1947
		},
1948
		detailQuestion = function (dataStr, listLi) {
1949
			var baImg = "../images/default-q&a.jpg";
1950
			var subs = new Array();
1951
			if (dataStr.img) {
1952
				var subs = strToAry(dataStr.img)
1953
				baImg = "/data/question" + subs[0];
1954
			}
1955
			var hd = "";
1956
			if (dataStr.replyCount > 0) {
1957
				hd = '<li><span>回答 ' + dataStr.replyCount + '</span></li>'
1958
			}
1959
			var strAdd = '<a target="_blank" href="/qa-show.html?id=' + dataStr.id + '" class="flexCenter urlgo">'
1960
			strAdd += '<div class="madiaHead qa-Head" style="background-image:url(' + baImg + ')"></div>';
1961
			strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty-2">' + dataStr.title + '</p>';
1962
			strAdd += '<ul class="h2Font clearfix">'
1963
			strAdd += '<li><span class="time">' + commenTime(dataStr.createTime) + '</span></li><li><span class="qaPageview"></span></li>' + hd + '<li><span class="attendCount"></span></li>'
1964
			strAdd += '</ul></div></a>'
1965
1966
			var $str = $(strAdd);
1967
			listLi.append($str);
1968
		},
1969
		detailService = function (arr, obj) {
1970
			oAjax("/ajax/ware/qm", {
1971
				id: arr,
1972
			}, "get", function (data) {
1927
				console.log(data)
1973
				console.log(data)
1928
				var dataItem=data.data;
1929
				for(var i = 0; i < dataItem.length; i++) {
1930
					var dataStr=dataItem[i]
1974
				var dataItem = data.data;
1975
				for (var i = 0; i < dataItem.length; i++) {
1976
					var dataStr = dataItem[i]
1931
					var li = document.createElement("li");
1977
					var li = document.createElement("li");
1932
					li.className = "mui-table-view-cell";
1978
					li.className = "mui-table-view-cell";
1933
					var cnt="", rImg = "../images/default-service.jpg";
1934
					if(dataStr.images) {
1979
					var cnt = "",
1980
						rImg = "../images/default-service.jpg";
1981
					if (dataStr.images) {
1935
						var subs = strToAry(dataStr.images)
1982
						var subs = strToAry(dataStr.images)
1936
						if(subs.length > 0) {
1937
							rImg="/data/ware" + subs[0]
1983
						if (subs.length > 0) {
1984
							rImg = "/data/ware" + subs[0]
1938
						}
1985
						}
1939
					}
1986
					}
1940
					if(dataStr.cnt){
1941
						cnt="内容:"+dataStr.cnt
1987
					if (dataStr.cnt) {
1988
						cnt = "内容:" + dataStr.cnt
1942
					}
1989
					}
1943
					var strAdd = '';
1990
					var strAdd = '';
1944
						strAdd += '<a target="_blank" href="sevriceShow.html?sevriceId='+dataStr.id+'" class="flexCenter urlgo">';
1945
						strAdd += '<div class="madiaHead resouseHead" style="background-image:url('+ rImg +')"></div>';
1946
						strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">'+ dataStr.name +'</p>';
1947
						strAdd += '<p class="h1Font ellipsisSty"><span class="ownerName"></span><em class="authiconNew ownerSty"></em></p>';
1948
						strAdd += '<p class="h2Font ellipsisSty-2">'+ cnt+'</p></div>';
1949
						strAdd += '</a>';
1991
					strAdd += '<a target="_blank" href="sevriceShow.html?sevriceId=' + dataStr.id + '" class="flexCenter urlgo">';
1992
					strAdd += '<div class="madiaHead resouseHead" style="background-image:url(' + rImg + ')"></div>';
1993
					strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">' + dataStr.name + '</p>';
1994
					strAdd += '<p class="h1Font ellipsisSty"><span class="ownerName"></span><em class="authiconNew ownerSty"></em></p>';
1995
					strAdd += '<p class="h2Font ellipsisSty-2">' + cnt + '</p></div>';
1996
					strAdd += '</a>';
1950
					li.innerHTML = strAdd
1997
					li.innerHTML = strAdd
1951
					var $itemlist = $(li);
1998
					var $itemlist = $(li);
1952
					document.getElementById(obj).appendChild(li);
1999
					document.getElementById(obj).appendChild(li);
1953
					if(dataStr.category=="1"){
1954
						(function(mo){
1955
							cacheModel.getProfessor(dataStr.owner,function(sc,value){
1956
								if(sc){
2000
					if (dataStr.category == "1") {
2001
						(function (mo) {
2002
							cacheModel.getProfessor(dataStr.owner, function (sc, value) {
2003
								if (sc) {
1957
									mo.find(".ownerName").html(value.name)
2004
									mo.find(".ownerName").html(value.name)
1958
									var userType = autho(value.authType, value.orgAuth, value.authStatus);
2005
									var userType = autho(value.authType, value.orgAuth, value.authStatus);
1959
									mo.find(".ownerSty").addClass(userType.sty).attr("title",userType.title)
1960
								}else{
2006
									mo.find(".ownerSty").addClass(userType.sty).attr("title", userType.title)
2007
								} else {
1961
									console.log("error")
2008
									console.log("error")
1962
								}
2009
								}
1963
							})
2010
							})
1964
						})($itemlist);
2011
						})($itemlist);
1965
					}else if(dataStr.category=="2"){
1966
						(function(mo){
1967
							cacheModel.getCompany(dataStr.owner,function(sc,value){
1968
								if(sc){
1969
									if(value.forShort){
2012
					} else if (dataStr.category == "2") {
2013
						(function (mo) {
2014
							cacheModel.getCompany(dataStr.owner, function (sc, value) {
2015
								if (sc) {
2016
									if (value.forShort) {
1970
										mo.find(".ownerName").html(value.forShort)
2017
										mo.find(".ownerName").html(value.forShort)
1971
									}else{
2018
									} else {
1972
										mo.find(".ownerName").html(value.name)
2019
										mo.find(".ownerName").html(value.name)
1973
									}
2020
									}
1974
									if(value.authStatus==3) {
1975
										mo.find(".ownerSty").addClass("authicon-com-ok").attr("title","科袖认证企业")
2021
									if (value.authStatus == 3) {
2022
										mo.find(".ownerSty").addClass("authicon-com-ok").attr("title", "科袖认证企业")
1976
									}
2023
									}
1977
								}else{
2024
								} else {
1978
									console.log("error")
2025
									console.log("error")
1979
								}
2026
								}
1980
							})
2027
							})
1981
						})($itemlist);
2028
						})($itemlist);
1982
					}
2029
					}
1983
					
2030
1984
				}
2031
				}
1985
			});
2032
			});
1986
		},
2033
		},
1987
		detailProduct=function(arr,obj) {
1988
			oAjax("/ajax/product/qm",{
1989
				id:arr,
1990
			},"get",function(data){
2034
		detailProduct = function (arr, obj) {
2035
			oAjax("/ajax/product/qm", {
2036
				id: arr,
2037
			}, "get", function (data) {
1991
				console.log(data)
2038
				console.log(data)
1992
				var dataItem=data.data;
1993
				for(var i = 0; i < dataItem.length; i++) {
1994
					var dataStr=dataItem[i]
2039
				var dataItem = data.data;
2040
				for (var i = 0; i < dataItem.length; i++) {
2041
					var dataStr = dataItem[i]
1995
					var li = document.createElement("li");
2042
					var li = document.createElement("li");
1996
					li.className = "mui-table-view-cell";
2043
					li.className = "mui-table-view-cell";
1997
					var cnt="", rImg = "../images/default-product.jpg";
1998
					if(dataStr.images) {
2044
					var cnt = "",
2045
						rImg = "../images/default-product.jpg";
2046
					if (dataStr.images) {
1999
						var subs = strToAry(dataStr.images)
2047
						var subs = strToAry(dataStr.images)
2000
						if(subs.length > 0) {
2001
							rImg="/data/product" + subs[0]
2048
						if (subs.length > 0) {
2049
							rImg = "/data/product" + subs[0]
2002
						}
2050
						}
2003
					}
2051
					}
2004
					if(dataStr.cnt){
2005
						cnt="简介:"+dataStr.cnt
2052
					if (dataStr.cnt) {
2053
						cnt = "简介:" + dataStr.cnt
2006
					}
2054
					}
2007
					var strAdd = '';
2055
					var strAdd = '';
2008
						strAdd += '<a target="_blank" href="productShow.html?productId='+dataStr.id+'" class="flexCenter urlgo">';
2009
						strAdd += '<div class="madiaHead resouseHead" style="background-image:url('+ rImg +')"></div>';
2010
						strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">'+ dataStr.name +'</p>';
2011
						strAdd += '<p class="h1Font ellipsisSty"><span class="ownerName"></span><em class="authiconNew ownerSty"></em></p>';
2012
						strAdd += '<p class="h2Font ellipsisSty-2">'+ cnt+'</p></div>';
2013
						strAdd += '</a>';
2056
					strAdd += '<a target="_blank" href="productShow.html?productId=' + dataStr.id + '" class="flexCenter urlgo">';
2057
					strAdd += '<div class="madiaHead resouseHead" style="background-image:url(' + rImg + ')"></div>';
2058
					strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">' + dataStr.name + '</p>';
2059
					strAdd += '<p class="h1Font ellipsisSty"><span class="ownerName"></span><em class="authiconNew ownerSty"></em></p>';
2060
					strAdd += '<p class="h2Font ellipsisSty-2">' + cnt + '</p></div>';
2061
					strAdd += '</a>';
2014
					li.innerHTML = strAdd
2062
					li.innerHTML = strAdd
2015
					var $itemlist = $(li);
2063
					var $itemlist = $(li);
2016
					document.getElementById(obj).appendChild(li);
2064
					document.getElementById(obj).appendChild(li);
2017
					(function(mo){
2018
						cacheModel.getCompany(dataStr.owner,function(sc,value){
2019
							if(sc){
2020
								if(value.forShort){
2065
					(function (mo) {
2066
						cacheModel.getCompany(dataStr.owner, function (sc, value) {
2067
							if (sc) {
2068
								if (value.forShort) {
2021
									mo.find(".ownerName").html(value.forShort)
2069
									mo.find(".ownerName").html(value.forShort)
2022
								}else{
2070
								} else {
2023
									mo.find(".ownerName").html(value.name)
2071
									mo.find(".ownerName").html(value.name)
2024
								}
2072
								}
2025
								if(value.authStatus==3) {
2026
									mo.find(".ownerSty").addClass("authicon-com-ok").attr("title","科袖认证企业")
2073
								if (value.authStatus == 3) {
2074
									mo.find(".ownerSty").addClass("authicon-com-ok").attr("title", "科袖认证企业")
2027
								}
2075
								}
2028
							}else{
2076
							} else {
2029
								console.log("error")
2077
								console.log("error")
2030
							}
2078
							}
2031
						})
2079
						})
2033
				}
2081
				}
2034
			});
2082
			});
2035
		},
2083
		},
2036
		proinfo=function(pid, $str) {
2037
			oAjax("/ajax/professor/baseInfo/" + pid,{}, "get", function(data){
2038
                var dataStr = data.data
2039
                var baImg = "../images/default-photo.jpg";
2040
                if (dataStr.hasHeadImage == 1) {
2041
                    baImg = "/images/head/" + dataStr.id + "_l.jpg";
2042
                }
2043
                var userType = autho(dataStr.authType, dataStr.orgAuth, dataStr.authStatus);
2044
                var os = "";
2045
                if (dataStr.title) {
2046
                    if (dataStr.orgName) {
2047
                        os = dataStr.title + "," + dataStr.orgName;
2048
                    } else {
2049
                        os = dataStr.title;
2050
                    }
2051
                } else {
2052
                    if (dataStr.office) {
2053
                        if (dataStr.orgName) {
2054
                            os = dataStr.office + "," + dataStr.orgName;
2055
                        } else {
2056
                            os = dataStr.office;
2057
                        }
2058
                    } else {
2059
                        if (dataStr.orgName) {
2060
                            os = dataStr.orgName;
2061
                        }
2062
                    }
2063
                }
2064
                var str = '<div class="owner-head useHead" style="background-image:url(' + baImg + ')"></div>' +
2065
                    '<div class="owner-info">' +
2066
                    '<div class="owner-name"><span class="h1Font">' + dataStr.name + '</span><em class="authiconNew ' + userType.sty + '" title="' + userType.title + '"></em></div>' +
2067
                    '<div class="owner-tit mui-ellipsis h2Font">' + os + '</div>' +
2068
                    '</div>'
2069
                $str.find(".qa-owner").html(str)
2070
	        });
2071
	    },
2072
	    questioninfo=function(qid, $str) {
2073
	        oAjax("/ajax/question/qo",{
2074
	        	id:qid
2075
	        }, "get", function(data){
2076
                $str.find(".qa-question").html(data.data.title);
2077
                if(data.data.pageViews>0){
2078
                    $str.find(".qaPageview").html("阅读量 "+data.data.pageViews);
2079
                }else{
2080
                    $str.find(".qaPageview").hide()
2081
                }
2082
	        });
2083
	    },
2084
		attendCount=function(id, $str) {
2085
			 oAjax("/ajax/watch/countProfessor",{
2086
	        	id:id,
2087
            	type: "8"
2088
	        }, "get", function(data){
2089
                if(data.data > 0) {
2090
                    $str.find(".attendCount").html("关注 "+data.data);
2091
                }
2092
		    });
2084
		proinfo = function (pid, $str) {
2085
			oAjax("/ajax/professor/baseInfo/" + pid, {}, "get", function (data) {
2086
				var dataStr = data.data
2087
				var baImg = "../images/default-photo.jpg";
2088
				if (dataStr.hasHeadImage == 1) {
2089
					baImg = "/images/head/" + dataStr.id + "_l.jpg";
2090
				}
2091
				var userType = autho(dataStr.authType, dataStr.orgAuth, dataStr.authStatus);
2092
				var os = "";
2093
				if (dataStr.title) {
2094
					if (dataStr.orgName) {
2095
						os = dataStr.title + "," + dataStr.orgName;
2096
					} else {
2097
						os = dataStr.title;
2098
					}
2099
				} else {
2100
					if (dataStr.office) {
2101
						if (dataStr.orgName) {
2102
							os = dataStr.office + "," + dataStr.orgName;
2103
						} else {
2104
							os = dataStr.office;
2105
						}
2106
					} else {
2107
						if (dataStr.orgName) {
2108
							os = dataStr.orgName;
2109
						}
2110
					}
2111
				}
2112
				var str = '<div class="owner-head useHead" style="background-image:url(' + baImg + ')"></div>' +
2113
					'<div class="owner-info">' +
2114
					'<div class="owner-name"><span class="h1Font">' + dataStr.name + '</span><em class="authiconNew ' + userType.sty + '" title="' + userType.title + '"></em></div>' +
2115
					'<div class="owner-tit mui-ellipsis h2Font">' + os + '</div>' +
2116
					'</div>'
2117
				$str.find(".qa-owner").html(str)
2118
			});
2093
		},
2119
		},
2094
		bindClickFun=function(){
2095
			$("#myAttends").unbind("click").on("click",function(){//关注与收藏
2120
		questioninfo = function (qid, $str) {
2121
			oAjax("/ajax/question/qo", {
2122
				id: qid
2123
			}, "get", function (data) {
2124
				$str.find(".qa-question").html(data.data.title);
2125
				if (data.data.pageViews > 0) {
2126
					$str.find(".qaPageview").html("阅读量 " + data.data.pageViews);
2127
				} else {
2128
					$str.find(".qaPageview").hide()
2129
				}
2130
			});
2131
		},
2132
		attendCount = function (id, $str) {
2133
			oAjax("/ajax/watch/countProfessor", {
2134
				id: id,
2135
				type: "8"
2136
			}, "get", function (data) {
2137
				if (data.data > 0) {
2138
					$str.find(".attendCount").html("关注 " + data.data);
2139
				}
2140
			});
2141
		},
2142
		bindClickFun = function () {
2143
			$("#myAttends").unbind("click").on("click", function () { //关注与收藏
2096
				openAttend()
2144
				openAttend()
2097
			})
2145
			})
2098
			
2099
			$("#tab8user").unbind("click").on("click",function(){//点击更多
2100
				watchO={
2101
					beiTime:"",
2102
					beiProId:"",
2103
					
2104
					watchTime:"",
2105
					watchObjId:"",
2146
2147
			$("#tab8user").unbind("click").on("click", function () { //点击更多
2148
				watchO = {
2149
					beiTime: "",
2150
					beiProId: "",
2151
2152
					watchTime: "",
2153
					watchObjId: "",
2106
				};
2154
				};
2107
				var pa=$(".moreNavUl.moreBuUl>li.liNow").attr("rel")
2108
				$("#"+pa).find("ul").html("")
2109
				$("#"+pa).find(".js-load-more").show();
2110
				if(userid!=professorId){
2155
				var pa = $(".moreNavUl.moreBuUl>li.liNow").attr("rel")
2156
				$("#" + pa).find("ul").html("")
2157
				$("#" + pa).find(".js-load-more").show();
2158
				if (userid != professorId) {
2111
					//关注他的人
2159
					//关注他的人
2112
					$(".moreNavUl.moreBuUl>li.attentType").hide();
2160
					$(".moreNavUl.moreBuUl>li.attentType").hide();
2113
					$(".moreNavUl.moreBuUl>li.attendMy").addClass("liNow").text("关注他的人");
2161
					$(".moreNavUl.moreBuUl>li.attendMy").addClass("liNow").text("关注他的人");
2114
					$("#item8drop5").show().siblings().hide();
2162
					$("#item8drop5").show().siblings().hide();
2115
					attentMyself(true);
2163
					attentMyself(true);
2116
				}else{
2164
				} else {
2117
					$("#item8drop1").show().siblings().hide();
2165
					$("#item8drop1").show().siblings().hide();
2118
					collectSorts(1,true);
2166
					collectSorts(1, true);
2119
				}
2167
				}
2120
				collectSorts(3,true);
2168
				collectSorts(3, true);
2121
			})
2169
			})
2122
			$("#tab6user").unbind("click").on("click",function(){//点击问答
2170
			$("#tab6user").unbind("click").on("click", function () { //点击问答
2123
				dataO = {
2171
				dataO = {
2124
					AnsTime:"",
2125
					AnsId:"",
2126
					
2127
					QuTime:"",
2128
					QuId:"",
2129
					
2172
					AnsTime: "",
2173
					AnsId: "",
2174
2175
					QuTime: "",
2176
					QuId: "",
2177
2130
				};
2178
				};
2131
				var pa=$(".moreNavUl.wendaUl>li.liNow").attr("rel")
2132
				$("#"+pa).find("ul").html("")
2133
				$("#"+pa).find(".js-load-more").show();
2134
				if(userid!=professorId){
2179
				var pa = $(".moreNavUl.wendaUl>li.liNow").attr("rel")
2180
				$("#" + pa).find("ul").html("")
2181
				$("#" + pa).find(".js-load-more").show();
2182
				if (userid != professorId) {
2135
					//他的回答
2183
					//他的回答
2136
					$(".moreNavUl.wendaUl>li").eq(0).hide().siblings().addClass("liNow").text("他的回答");
2184
					$(".moreNavUl.wendaUl>li").eq(0).hide().siblings().addClass("liNow").text("他的回答");
2137
					$("#item6drop2").show().siblings().hide();
2185
					$("#item6drop2").show().siblings().hide();
2138
					answerListVal(true);
2186
					answerListVal(true);
2139
				}else{
2187
				} else {
2140
					$(".wendaNav li").eq(0).addClass("liNow").siblings().removeClass("liNow");
2188
					$(".wendaNav li").eq(0).addClass("liNow").siblings().removeClass("liNow");
2141
					$("#item6drop1").show().siblings().hide();
2189
					$("#item6drop1").show().siblings().hide();
2142
					questionListVal(true);
2190
					questionListVal(true);
2143
				}
2191
				}
2144
			})
2192
			})
2145
			$("#item6more").on("click","li",function(){//问答tab切换
2146
				var pa=$(this).attr("rel")
2147
				$("#"+pa).find("ul").html("")
2148
				$("#"+pa).find(".js-load-more").show();
2149
				var sortN=$(this).attr("data-num");
2193
			$("#item6more").on("click", "li", function () { //问答tab切换
2194
				var pa = $(this).attr("rel")
2195
				$("#" + pa).find("ul").html("")
2196
				$("#" + pa).find(".js-load-more").show();
2197
				var sortN = $(this).attr("data-num");
2150
				dataO = {
2198
				dataO = {
2151
					AnsTime:"",
2152
					AnsId:"",
2153
					
2154
					QuTime:"",
2155
					QuId:"",
2156
					
2199
					AnsTime: "",
2200
					AnsId: "",
2201
2202
					QuTime: "",
2203
					QuId: "",
2204
2157
				};
2205
				};
2158
				if(sortN==1){
2206
				if (sortN == 1) {
2159
					questionListVal(true);
2207
					questionListVal(true);
2160
				}else if(sortN==2){
2208
				} else if (sortN == 2) {
2161
					answerListVal(true);
2209
					answerListVal(true);
2162
				}
2210
				}
2163
			})
2211
			})
2164
			$("#tab4user").unbind("click").on("click",function(){//点击成果
2212
			$("#tab4user").unbind("click").on("click", function () { //点击成果
2165
				pageNo = 1
2213
				pageNo = 1
2166
				var pa=$(".moreNavUl.wendaUl>li.liNow").attr("rel")
2167
				$("#"+pa).find("ul").html("")
2168
				$("#"+pa).find(".js-load-more").show();
2214
				var pa = $(".moreNavUl.wendaUl>li.liNow").attr("rel")
2215
				$("#" + pa).find("ul").html("")
2216
				$("#" + pa).find(".js-load-more").show();
2169
				unPatentListVal(true);
2217
				unPatentListVal(true);
2170
			})
2218
			})
2171
			$("#item4more").on("click","li",function(){
2172
				var pa=$(this).attr("rel")
2173
				$("#"+pa).find("ul").html("")
2174
				$("#"+pa).find(".js-load-more").show();
2175
				var sortN=$(this).attr("data-num");
2219
			$("#item4more").on("click", "li", function () {
2220
				var pa = $(this).attr("rel")
2221
				$("#" + pa).find("ul").html("")
2222
				$("#" + pa).find(".js-load-more").show();
2223
				var sortN = $(this).attr("data-num");
2176
				dataO = {
2224
				dataO = {
2177
					patTime:"",
2178
					patId:""
2225
					patTime: "",
2226
					patId: ""
2179
				};
2227
				};
2180
				pageNo = 1
2228
				pageNo = 1
2181
				if(sortN==1){
2229
				if (sortN == 1) {
2182
					unPatentListVal(true);
2230
					unPatentListVal(true);
2183
				}else if(sortN==2){
2231
				} else if (sortN == 2) {
2184
					patentListVal(true);
2232
					patentListVal(true);
2185
				}
2233
				}
2186
			})
2234
			})
2187
			$(".moreNavUl.moreBuUl").on("click","li.attentType:not(.rightbtn)",function(){//关注tab切换
2188
				var pa=$(this).attr("rel")
2189
				$("#"+pa).find("ul").html("")
2190
				$("#"+pa).find(".js-load-more").show();
2191
				var sortN=$(this).attr("data-num");
2192
				watchO={
2193
					watchTime:"",
2194
					watchObjId:"",
2195
					
2196
					WATime:"",
2197
					WAId:"",
2198
					
2199
					WQTime:"",
2200
					WQId:"",
2235
			$(".moreNavUl.moreBuUl").on("click", "li.attentType:not(.rightbtn)", function () { //关注tab切换
2236
				var pa = $(this).attr("rel")
2237
				$("#" + pa).find("ul").html("")
2238
				$("#" + pa).find(".js-load-more").show();
2239
				var sortN = $(this).attr("data-num");
2240
				watchO = {
2241
					watchTime: "",
2242
					watchObjId: "",
2243
2244
					WATime: "",
2245
					WAId: "",
2246
2247
					WQTime: "",
2248
					WQId: "",
2201
				};
2249
				};
2202
				if(sortN==8){
2203
					collectQuestion(true)	
2204
				}else if(sortN==9){
2205
					collectAnswer(true)	
2206
				}else{
2207
					collectSorts(sortN,true);
2250
				if (sortN == 8) {
2251
					collectQuestion(true)
2252
				} else if (sortN == 9) {
2253
					collectAnswer(true)
2254
				} else {
2255
					collectSorts(sortN, true);
2208
				}
2256
				}
2209
			})
2257
			})
2210
			
2211
			$("#tabAttendMy").unbind("click").on("click",function(){//关注我的人
2212
				var pa=$(this).attr("rel")
2213
				$("#"+pa).find("ul").html("")
2214
				$("#"+pa).find(".js-load-more").show();
2215
				watchO={
2216
					beiTime:"",
2217
					beiProId:"",
2258
2259
			$("#tabAttendMy").unbind("click").on("click", function () { //关注我的人
2260
				var pa = $(this).attr("rel")
2261
				$("#" + pa).find("ul").html("")
2262
				$("#" + pa).find(".js-load-more").show();
2263
				watchO = {
2264
					beiTime: "",
2265
					beiProId: "",
2218
				}
2266
				}
2219
				attentMyself(true);
2267
				attentMyself(true);
2220
			})
2268
			})
2221
			$("#attendmyGo").unbind("click").on("click",function(){
2222
				if(userid!=professorId){
2223
					$(".moreNavUl.moreBuUl>li.attentType").hide();//关注他的人
2269
			$("#attendmyGo").unbind("click").on("click", function () {
2270
				if (userid != professorId) {
2271
					$(".moreNavUl.moreBuUl>li.attentType").hide(); //关注他的人
2224
					$(".moreNavUl.moreBuUl>li.attendMy").addClass("liNow").text("关注他的人");
2272
					$(".moreNavUl.moreBuUl>li.attendMy").addClass("liNow").text("关注他的人");
2225
				}
2273
				}
2226
				$(".mainNavUl li.rightbtn").addClass("liNow").siblings().removeClass("liNow");
2274
				$(".mainNavUl li.rightbtn").addClass("liNow").siblings().removeClass("liNow");
2229
				$("#item8user").show().siblings().hide();
2277
				$("#item8user").show().siblings().hide();
2230
				$(".moreBuUl li.attendMy").addClass("liNow").siblings().removeClass("liNow");
2278
				$(".moreBuUl li.attendMy").addClass("liNow").siblings().removeClass("liNow");
2231
				$("#item8drop5").show().siblings().hide();
2279
				$("#item8drop5").show().siblings().hide();
2232
				watchO={
2233
					beiTime:"",
2234
					beiProId:"",
2280
				watchO = {
2281
					beiTime: "",
2282
					beiProId: "",
2235
				}
2283
				}
2236
				$("#item8drop5").find("ul").html("")
2284
				$("#item8drop5").find("ul").html("")
2237
				$("#item8drop5").find(".js-load-more").show();
2285
				$("#item8drop5").find(".js-load-more").show();
2238
				attentMyself(true);
2286
				attentMyself(true);
2239
			})
2287
			})
2240
			
2288
2241
			/*研究方向点赞*/
2289
			/*研究方向点赞*/
2242
			var clFlag = 1;
2290
			var clFlag = 1;
2243
			$("#researchAreaShow").on("click", ".plus", function() {
2244
				if(userid && userid != null && userid != "null") {
2291
			$("#researchAreaShow").on("click", ".plus", function () {
2292
				if (userid && userid != null && userid != "null") {
2245
					//点赞变化样式
2293
					//点赞变化样式
2246
					if(clFlag) {
2294
					if (clFlag) {
2247
						clFlag = 0;
2295
						clFlag = 0;
2248
					} else {
2296
					} else {
2249
						return;
2297
						return;
2250
					}
2298
					}
2251
					if($(this).data("isagree") > -1) {
2299
					if ($(this).data("isagree") > -1) {
2252
						$(this).stop(true, true).animate({
2300
						$(this).stop(true, true).animate({
2253
							backgroundPositionY: 0
2301
							backgroundPositionY: 0
2254
						}, 300); //变成未点赞样式
2302
						}, 300); //变成未点赞样式
2257
							backgroundPositionY: -26
2305
							backgroundPositionY: -26
2258
						}, 300); //变成点赞样式
2306
						}, 300); //变成点赞样式
2259
					}
2307
					}
2260
	
2308
2261
					$.ajax({
2309
					$.ajax({
2262
						"url": $(this).data("isagree") > -1 ? "/ajax/researchArea/unAgree" : "/ajax/researchArea/agree",
2310
						"url": $(this).data("isagree") > -1 ? "/ajax/researchArea/unAgree" : "/ajax/researchArea/agree",
2263
						"type": "POST",
2311
						"type": "POST",
2265
							"targetId": $(this).data("pid"),
2313
							"targetId": $(this).data("pid"),
2266
							"targetCaption": oArray[$(this).data("caption")],
2314
							"targetCaption": oArray[$(this).data("caption")],
2267
							"opId": userid,
2315
							"opId": userid,
2268
							"uname":$.cookie("userName")
2316
							"uname": $.cookie("userName")
2269
						},
2317
						},
2270
						"contentType": "application/x-www-form-urlencoded",
2318
						"contentType": "application/x-www-form-urlencoded",
2271
						"success": function(dataStr) {
2272
							if(dataStr.success) {
2273
								$.get("/ajax/professor/info/" + professorId, function(dataStr) {
2274
									if(dataStr.success) {
2319
						"success": function (dataStr) {
2320
							if (dataStr.success) {
2321
								$.get("/ajax/professor/info/" + professorId, function (dataStr) {
2322
									if (dataStr.success) {
2275
										clFlag = 1;
2323
										clFlag = 1;
2276
										var $info = dataStr.data;
2324
										var $info = dataStr.data;
2277
										if($info) {
2325
										if ($info) {
2278
											$("#researchAreaShow").empty("")
2326
											$("#researchAreaShow").empty("")
2279
											if($info.researchAreas) {
2327
											if ($info.researchAreas) {
2280
												researchAreaShow($info.researchAreas, $info.editResearchAreaLogs);
2328
												researchAreaShow($info.researchAreas, $info.editResearchAreaLogs);
2281
											}
2329
											}
2282
										}
2330
										}
2293
					closeLog();
2341
					closeLog();
2294
				}
2342
				}
2295
			})
2343
			})
2296
			
2344
2297
			//点击每个研究方向弹出研究方向详情窗口
2345
			//点击每个研究方向弹出研究方向详情窗口
2298
			$("#researchAreaShow").on("click", ".favorBox,.favorCount", function() {
2346
			$("#researchAreaShow").on("click", ".favorBox,.favorCount", function () {
2299
				var cap = $(this).attr("caption");
2347
				var cap = $(this).attr("caption");
2300
				researchAlert(cap)
2348
				researchAlert(cap)
2301
			});
2349
			});
2302
			
2350
2303
			//关闭按钮
2351
			//关闭按钮
2304
			$("#workclose").click(function() {
2352
			$("#workclose").click(function () {
2305
				$(".resAreaCover").fadeOut();
2353
				$(".resAreaCover").fadeOut();
2306
			    $("body").css("position", "");
2354
				$("body").css("position", "");
2307
			});
2355
			});
2308
			
2356
2309
			//点击查看全部资源
2357
			//点击查看全部资源
2310
			$(".coninfobox").on("click","#seeMoreR",function(){
2358
			$(".coninfobox").on("click", "#seeMoreR", function () {
2311
				document.body.scrollTop = document.documentElement.scrollTop = 0;
2359
				document.body.scrollTop = document.documentElement.scrollTop = 0;
2312
				$("#tab2user").addClass("liNow").siblings().removeClass("liNow");
2360
				$("#tab2user").addClass("liNow").siblings().removeClass("liNow");
2313
				$("#item1user").hide();
2361
				$("#item1user").hide();
2314
				$("#item2user").show();
2362
				$("#item2user").show();
2315
			})
2363
			})
2316
			//点击查看全部服务
2364
			//点击查看全部服务
2317
			$(".coninfobox").on("click","#seeMoreS",function(){
2365
			$(".coninfobox").on("click", "#seeMoreS", function () {
2318
				document.body.scrollTop = document.documentElement.scrollTop = 0;
2366
				document.body.scrollTop = document.documentElement.scrollTop = 0;
2319
				$("#tab9user").addClass("liNow").siblings().removeClass("liNow");
2367
				$("#tab9user").addClass("liNow").siblings().removeClass("liNow");
2320
				$("#item1user").hide();
2368
				$("#item1user").hide();
2321
				$("#item9user").show();
2369
				$("#item9user").show();
2322
			})
2370
			})
2323
			//点击查看全部文章
2371
			//点击查看全部文章
2324
			$(".coninfobox").on("click","#seeMoreA",function(){
2372
			$(".coninfobox").on("click", "#seeMoreA", function () {
2325
				document.body.scrollTop = document.documentElement.scrollTop = 0;
2373
				document.body.scrollTop = document.documentElement.scrollTop = 0;
2326
				$("#tab3user").addClass("liNow").siblings().removeClass("liNow");
2374
				$("#tab3user").addClass("liNow").siblings().removeClass("liNow");
2327
				$("#item1user").hide();
2375
				$("#item1user").hide();
2328
				$("#item3user").show();
2376
				$("#item3user").show();
2329
			})
2377
			})
2330
			//点击查看全部专利
2378
			//点击查看全部专利
2331
			$(".coninfobox").on("click","#seeMoreP",function(){
2379
			$(".coninfobox").on("click", "#seeMoreP", function () {
2332
				document.body.scrollTop = document.documentElement.scrollTop = 0;
2380
				document.body.scrollTop = document.documentElement.scrollTop = 0;
2333
				$("#tab4user").addClass("liNow").siblings().removeClass("liNow");
2381
				$("#tab4user").addClass("liNow").siblings().removeClass("liNow");
2334
				$("#item1user").hide();
2382
				$("#item1user").hide();
2335
				$("#item4user").show();
2383
				$("#item4user").show();
2336
			})
2384
			})
2337
			//点击查看全部论文
2385
			//点击查看全部论文
2338
			$(".coninfobox").on("click","#seeMoreL",function(){
2386
			$(".coninfobox").on("click", "#seeMoreL", function () {
2339
				document.body.scrollTop = document.documentElement.scrollTop = 0;
2387
				document.body.scrollTop = document.documentElement.scrollTop = 0;
2340
				$("#tab5user").addClass("liNow").siblings().removeClass("liNow");
2388
				$("#tab5user").addClass("liNow").siblings().removeClass("liNow");
2341
				$("#item1user").hide();
2389
				$("#item1user").hide();
2342
				$("#item5user").show();
2390
				$("#item5user").show();
2343
			})
2391
			})
2344
			//点击查看全部问题
2392
			//点击查看全部问题
2345
	        $(".coninfobox").on("click","#seeMoreQA",function(){
2346
	            document.body.scrollTop = document.documentElement.scrollTop = 0;
2347
	            $("#tab6user").addClass("liNow").siblings().removeClass("liNow");
2348
	            $("#item1user").hide();
2349
	            $("#item6user").show();
2350
	            if(userid === professorId) {
2351
	                $(".wendaNav").show();
2352
	            }
2353
	            $(".wendaNav li").eq(1).addClass("liNow").siblings().removeClass("liNow");
2354
	            $("#item6drop2").show().siblings().hide();
2355
	        })
2356
	
2393
			$(".coninfobox").on("click", "#seeMoreQA", function () {
2394
				document.body.scrollTop = document.documentElement.scrollTop = 0;
2395
				$("#tab6user").addClass("liNow").siblings().removeClass("liNow");
2396
				$("#item1user").hide();
2397
				$("#item6user").show();
2398
				if (userid === professorId) {
2399
					$(".wendaNav").show();
2400
				}
2401
				$(".wendaNav li").eq(1).addClass("liNow").siblings().removeClass("liNow");
2402
				$("#item6drop2").show().siblings().hide();
2403
			})
2404
2357
			//点击关注按钮
2405
			//点击关注按钮
2358
			$("#attentBtn").on('click', function() {
2359
				if(userid && userid != null && userid != "null") {
2360
					if($(this).is('.attenedSpan')){
2361
						cancelCollectionAbout(professorId,$(this),1)
2406
			$("#attentBtn").on('click', function () {
2407
				if (userid && userid != null && userid != "null") {
2408
					if ($(this).is('.attenedSpan')) {
2409
						cancelCollectionAbout(professorId, $(this), 1)
2362
					} else {
2410
					} else {
2363
						collectionAbout(professorId,$(this), 1);
2411
						collectionAbout(professorId, $(this), 1);
2364
					}
2412
					}
2365
					queryPubCount();
2413
					queryPubCount();
2366
					watchO={
2367
						beiTime:"",
2368
						beiProId:"",
2414
					watchO = {
2415
						beiTime: "",
2416
						beiProId: "",
2369
					}
2417
					}
2370
					$("#item8drop5").find("ul").html("")
2418
					$("#item8drop5").find("ul").html("")
2371
					$("#item8drop5").find(".js-load-more").show();
2419
					$("#item8drop5").find(".js-load-more").show();
2372
					attentMyself(true);
2420
					attentMyself(true);
2373
				}else{
2421
				} else {
2374
					quickLog();
2422
					quickLog();
2375
					operatTab();
2423
					operatTab();
2376
					closeLog();
2424
					closeLog();
2377
				}
2425
				}
2378
			});	
2426
			});
2379
			//点击联系按钮
2427
			//点击联系按钮
2380
			$("#conbtn").on('click', function(){
2381
				if(userid && userid != null && userid != 'null' && userid != undefined && userid != 'undefined') {
2382
					location.href="tidings.html?id="+professorId
2428
			$("#conbtn").on('click', function () {
2429
				if (userid && userid != null && userid != 'null' && userid != undefined && userid != 'undefined') {
2430
					location.href = "tidings.html?id=" + professorId
2383
				} else {
2431
				} else {
2384
					quickLog();
2432
					quickLog();
2385
					operatTab();
2433
					operatTab();
2386
					closeLog();
2434
					closeLog();
2387
				}
2435
				}
2388
			});
2436
			});
2389
			
2437
2390
			//纠错反馈
2438
			//纠错反馈
2391
			$(".correctSubmit").on("click",function(){
2392
				var cntCon=$(this).siblings(".correctCon").val();
2393
				var cntUser="";
2394
				if(userid && userid != null && userid != "null") {
2439
			$(".correctSubmit").on("click", function () {
2440
				var cntCon = $(this).siblings(".correctCon").val();
2441
				var cntUser = "";
2442
				if (userid && userid != null && userid != "null") {
2395
					cntUser = userid;
2443
					cntUser = userid;
2396
				}
2444
				}
2397
				if(cntCon.length>500){
2445
				if (cntCon.length > 500) {
2398
					$.MsgBox.Alert('提示', '纠错反馈内容不得超过500个字');
2446
					$.MsgBox.Alert('提示', '纠错反馈内容不得超过500个字');
2399
					return;
2447
					return;
2400
				}else{
2401
					oAjax("/ajax/feedback/error/professor",{
2448
				} else {
2449
					oAjax("/ajax/feedback/error/professor", {
2402
						"id": professorId,
2450
						"id": professorId,
2403
						"cnt":cntCon,
2404
						"user":cntUser
2405
					}, "POST", function(data){
2451
						"cnt": cntCon,
2452
						"user": cntUser
2453
					}, "POST", function (data) {
2406
						backSuccessed();
2454
						backSuccessed();
2407
					});
2455
					});
2408
				}
2456
				}
2409
			})
2457
			})
2410
	
2458
2411
		}
2459
		}
2412
2460
2413
	if(GetQueryString("flag")) {
2461
	if (GetQueryString("flag")) {
2414
		researchAlert(GetQueryString("flag"))
2462
		researchAlert(GetQueryString("flag"))
2415
	}
2463
	}
2416
	if(GetQueryString("iLike")){
2464
	if (GetQueryString("iLike")) {
2417
		openAttend();
2465
		openAttend();
2418
	}
2466
	}
2419
	if(userid!=professorId){
2420
		pageViewLog(professorId,1)
2421
		relevantExperts();//合作专家
2422
		relevantarticalList();//相关文章
2423
		likeExperts();//感兴趣专家
2424
		isActUser();//判断用户是否被激活
2425
		ifcollectionAbout(professorId,$(".goSpan").find(".attenSpan"), 1)
2467
	if (userid != professorId) {
2468
		pageViewLog(professorId, 1)
2469
		relevantExperts(); //合作专家
2470
		// relevantarticalList(); //相关文章
2471
		likeExperts(); //感兴趣专家
2472
		isActUser(); //判断用户是否被激活
2473
		ifcollectionAbout(professorId, $(".goSpan").find(".attenSpan"), 1)
2426
		$(".goSpan").show();
2474
		$(".goSpan").show();
2427
	}else{
2475
	} else {
2428
		$(".goSpanTo").show();
2476
		$(".goSpanTo").show();
2429
		$(".myoneself").show();
2477
		$(".myoneself").show();
2430
	}
2478
	}
2431
	queryPubCount();
2479
	queryPubCount();
2432
	getUserInfo(); //获取详细信息
2480
	getUserInfo(); //获取详细信息
2433
	demandListVal(true);
2481
	demandListVal(true);
2434
	articalListVal(true);
2482
	// articalListVal(true);
2435
	teamListVal(true);
2483
	teamListVal(true);
2436
	resourceListVal(true);
2484
	resourceListVal(true);
2437
	serviceListVal(true);
2485
	serviceListVal(true);
2441
	answerListVal(true);
2489
	answerListVal(true);
2442
	bindClickFun();
2490
	bindClickFun();
2443
2491
2444
	
2445
		
2446
})
2447
2492
2493
2494
})

+ 1 - 1
userInforShow.html

348
						<div id="item8drop6" class="coninfobox form-item dropconItem">
348
						<div id="item8drop6" class="coninfobox form-item dropconItem">
349
							<div class="coninfocon form-result aboutRes">
349
							<div class="coninfocon form-result aboutRes">
350
								<ul id="attendTeam">
350
								<ul id="attendTeam">
351
									
351
								
352
								</ul>
352
								</ul>
353
								<button class="js-load-more"></button>
353
								<button class="js-load-more"></button>
354
							</div>
354
							</div>