Przeglądaj źródła

添加所属机构

lyn7568 5 lat temu
rodzic
commit
6c1c3d4e5b
7 zmienionych plików z 358 dodań i 65 usunięć
  1. 41 7
      e/2.html
  2. 25 19
      js/recommend.js
  3. 30 6
      js/search_h5.js
  4. 98 10
      js/teamInforShow.js
  5. 121 16
      js/teamManage.js
  6. 34 1
      js/unPatentImport.js
  7. 9 6
      js/unPatentList.js

+ 41 - 7
e/2.html

@ -1380,13 +1380,13 @@
1380 1380
					if (dataStr.length > 0) {
1381 1381
						var src = "../images/default-resource.jpg";
1382 1382
						var subject;
1383
						if(dataStr[0].pic) {
1384
							 src = '/data/researchResult' + dataStr[0].pic.split(",")[0]
1383
						if (dataStr[0].pic) {
1384
							src = '/data/researchResult' + dataStr[0].pic.split(",")[0]
1385 1385
						}
1386
						
1386
1387 1387
						if (dataStr[0].subject) {
1388
							 subject = '应用领域:' + dataStr[0].subject
1389
						}else{
1388
							subject = '应用领域:' + dataStr[0].subject
1389
						} else {
1390 1390
							subject = ''
1391 1391
						}
1392 1392
						var department = dataStr[0].department == undefined ? '' : '所属部门: ' + dataStr[0].department
@ -1400,12 +1400,17 @@
1400 1400
							'<div class="madiaInfo OmadiaInfo">' +
1401 1401
							'<p class="ellipsisSty-2 h1Font">' + dataStr[0].name + '</p>' +
1402 1402
							'<p class="ellipsisSty h2Font dis">' + subject + '</p>' +
1403
							'<p class="ellipsisSty h2Font ">' + department + '</p>' +
1403
							'<p class="ellipsisSty h2Font org">'  + '</p>' +
1404 1404
							//.substring(0, dataStr[i].authors.length - 1)    
1405 1405
							'</div>' +
1406 1406
							'</div>'
1407 1407
						document.getElementById('proUnPatent').appendChild(li);
1408
						
1408
						if(dataStr[0].orgId) {
1409
							console.log(dataStr[0].orgId)
1410
							orgname(dataStr[0].orgId,li)
1411
						}
1412
1413
1409 1414
						$("#" + obj).append(strAdd)
1410 1415
						console.log(dataStr.length)
1411 1416
						if (dataStr.length <= 1) {
@ -1448,6 +1453,35 @@
1448 1453
				})
1449 1454
			}
1450 1455
1456
		orgname = function (par, $pa) {
1457
			$.ajax({
1458
				"url": "/ajax/org/" + par,
1459
				"type": "GET",
1460
				"success": function (data) {
1461
					if (data.success) {
1462
						$('.org').html('所属机构:'+data.data.name)
1463
					}
1464
				},
1465
				"data": {
1466
					"id": par
1467
				},
1468
				dataType: "json",
1469
				'error': function () {
1470
					// $.MsgBox.Alert('提示', '服务器连接超时!');
1471
				}
1472
			});
1473
		}
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1451 1485
		// 论文
1452 1486
		paperListVal = function (Id) { //论文
1453 1487
				var aimId = "paperList"

+ 25 - 19
js/recommend.js

@ -132,11 +132,7 @@ $(function () {
132 132
						} else {
133 133
							subject = ''
134 134
						}
135
						if ($info[i].department) {
136
							department = '所属部门:' + $info[i].department
137
						} else {
138
							department = ''
139
						}
135
					
140 136
141 137
						var resIM = '<div class="lefthead patenthead"></div>'
142 138
						if ($info[i].pic) {
@ -148,11 +144,12 @@ $(function () {
148 144
						itemlist += resIM
149 145
						itemlist += '<div class="centercon centercon2">';
150 146
						itemlist += '<p class="h1font ellipsisSty">' + $info[i].name + '</p>';
151
						itemlist += '<p class="h2font ellipsisSty ">' + subject + '<span class="researchers"></span></p>';
152
						itemlist += '<p class="h2font ellipsisSty ">' + department + '<span class="researchers"></span></p>';
153
						// if ($info[i].orgId) {
154
						// 	itemlist += '<p class="h2font ellipsisSty">所属机构:<span class="resOrgName"></span></p>';
155
						// }
147
						itemlist += '<p class="h2font ellipsisSty ">' + '<span class="researchers"></span></p>';
148
						itemlist += '<p class="h2font ellipsisSty ">' + subject + '</p>';
149
						// itemlist += '<p class="h2font ellipsisSty ">' + department + '<span class="researchers"></span></p>';
150
						if ($info[i].orgId) {
151
							itemlist += '<p class="h2font ellipsisSty">所属机构:<span class="resOrgName"></span></p>';
152
						}
156 153
						itemlist += '</div></a></li>';
157 154
						var $itemlist = $(itemlist);
158 155
						$("#" + aimId).append($itemlist)
@ -186,11 +183,17 @@ $(function () {
186 183
				$("#" + aimId).parent().find(".js-load-more").removeClass("active");
187 184
			})
188 185
		},
189
		recommendUnpatent = function () {
186
187
188
189
190
191
192
		recommendUnpatent = function () {   
190 193
			var aimId = "table-item-0"
191 194
			oAjax("/ajax/resResult/pq", {
192 195
				"status": ['1'],
193
				"pageSize": 5,
196
				"pageSize": 20,
194 197
				"pageNo": 1
195 198
			}, "get", function (res) {
196 199
				var $info = res.data.data;
@ -204,11 +207,11 @@ $(function () {
204 207
						} else {
205 208
							subject = ''
206 209
						}
207
						if ($info[i].department) {
208
							department = '所属部门:' + $info[i].department
209
						} else {
210
							department = ''
211
						}
210
						// if ($info[i].department) {
211
						// 	department = '所属部门:' + $info[i].department
212
						// } else {
213
						// 	department = ''
214
						// }
212 215
213 216
						var resIM = '<div class="lefthead patenthead"></div>'
214 217
						if ($info[i].pic) {
@ -221,8 +224,11 @@ $(function () {
221 224
						itemlist += '<div class="centercon centercon2">';
222 225
						itemlist += '<p class="h1font ellipsisSty">' + $info[i].name + '</p>';
223 226
						itemlist += '<p class="h2font ellipsisSty ">' + '<span class="researchers"></span></p>';
224
						itemlist += '<p class="h2font ellipsisSty ">' + subject + '<span class="researchers"></span></p>';
225
						itemlist += '<p class="h2font ellipsisSty">' + department + '<span class="resOrgName"></span></p>';
227
						itemlist += '<p class="h2font ellipsisSty ">' + subject + '</p>';
228
						// itemlist += '<p class="h2font ellipsisSty">' + department + '<span class="resOrgName"></span></p>';
229
						if ($info[i].orgId) {
230
							itemlist += '<p class="h2font ellipsisSty">所属机构:<span class="resOrgName"></span></p>';
231
						}
226 232
						itemlist += '</div></a></li>';
227 233
						var $itemlist = $(itemlist);
228 234
						$("#" + aimId).append($itemlist)

+ 30 - 6
js/search_h5.js

@ -278,14 +278,13 @@ $(function () {
278 278
			}, 'get', function (res) {
279 279
				var $info = res.data
280 280
				if ($info.length > 0) {
281
					dataO.unpCreateTime = $info[$info.length-1].createTime;   //获取最后一个数据的创建时间
281
					dataO.unpCreateTime = $info[$info.length - 1].createTime; //获取最后一个数据的创建时间
282 282
					dataO.unpId = $info[$info.length - 1].id;
283 283
				}
284 284
				for (var i = 0; i < $info.length; i++) {
285 285
					if ($info[i].pic) {
286 286
						var src = '/data/researchResult' + $info[i].pic.split(",")[0]
287 287
					}
288
					var department = $info[i].department == undefined ? '' : '所属部门: ' + $info[i].department
289 288
					var subject = $info[i].subject == undefined ? '' : '应用介绍: ' + $info[i].subject
290 289
					var liItem = document.createElement("li");
291 290
					liItem.setAttribute("data-id", $info[i].id);
@ -295,7 +294,10 @@ $(function () {
295 294
					itemlist += '<div class="madiaInfo OmadiaInfo">';
296 295
					itemlist += '<p class="ellipsisSty-2 h1Font">' + $info[i].name + '</p>';
297 296
					itemlist += '<p class="h2Font ellipsisSty"><span class="ownerName">' + subject + '</span><em class="authiconNew ownerSty"></em></p>'
298
					itemlist += '<p class="h2Font ellipsisSty">' + department + '</p>'
297
					if ($info[i].orgId) {
298
						itemlist += '<p class="h2Font ellipsisSty org">所属机构'+ '</p>'
299
					}
300

299 301
					itemlist += '</div>'
300 302
					itemlist += '</div>';
301 303
					liItem.innerHTML = itemlist;
@ -303,6 +305,10 @@ $(function () {
303 305
					document.getElementById(aimId).appendChild(liItem)
304 306
					// unPerson($info[i].id, $itemlist)
305 307
					removeNodata(aimId);
308
					if($info[i].orgId) {
309
						noOrgname($info[i].orgId,$itemlist)
310

311
					}
306 312
					var liLen = document.getElementById(aimId).querySelectorAll("li").length;
307 313

308 314
					if ($info.length == 0 && liLen == 0) {
@ -318,12 +324,30 @@ $(function () {
318 324
						return;
319 325
					}
320 326

321

322

323

324 327
				}
325 328
			})
326 329
		}
330
	noOrgname = function (par, $pa) { //非专企业
331
		$.ajax({
332
			"url": "/ajax/org/" + par,
333
			"type": "GET",
334
			"success": function (data) {
335
				if (data.success) {
336
					$pa.find('.org').html("所属机构: "+data.data.name)
337
				}
338
			},
339
			"data": {
340
				"id": par
341
			},
342
			dataType: "json",
343
			'error': function () {
344
				// $.MsgBox.Alert('提示', '服务器连接超时!');
345
			}
346
		});
347
	}
348

349

350

327 351

328 352
	//研究人
329 353
	unPerson = function (id, $list) {

+ 98 - 10
js/teamInforShow.js

@ -365,6 +365,7 @@ $(function () {
365 365
			});
366 366
		},
367 367
		detailUnPat = function (obj) {
368
			homepageUnPatent()
368 369
			oAjax("/ajax/resResult/qm", {
369 370
				id: unpatentArr,
370 371
			}, "get", function (data) {
@ -378,11 +379,52 @@ $(function () {
378 379
					} else {
379 380
						subject = ''
380 381
					}
381
					if (dataStr[i].department) {
382
						department = '所属部门:' + dataStr[i].department
382
				
383
					var resIM = '<div class="madiaHead patentHead"></div>'
384
					if (dataStr[i].pic) {
385
						var src = '/data/researchResult' + dataStr[i].pic.split(",")[0]
386
						resIM = '<div class="madiaHead patentHead" style="background-image:url(' + src + ')"></div>';
387
					}
388
					var strAdd = '';
389
					strAdd += '<li class="mui-table-view-cell"><a  target="_blank" href="unPatentShow.html?id=' + dataStr[i].id + '" class="flexCenter urlgo">';
390
					strAdd += resIM
391
					strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">' + dataStr[i].name + '</p>';
392
					strAdd += '<p class="h2Font ellipsisSty ">'+ subject+ '<span class="researchers"></span></p>';
393
					strAdd += '<p class="h2Font ellipsisSty org">'+ '<span class="researchers"></span></p>';
394
					// if (dataStr[i].orgId) {
395
					// 	strAdd += '<p class="h2Font ellipsisSty">所属机构:<span class="resOrgName"></span></p>';
396
					// }
397
					strAdd += '</div>';
398
					strAdd += '</a></li>';
399
					var $itemlist = $(strAdd);
400
401
					$("#" + obj).append($itemlist);
402
					orgN(dataStr[i].orgId, $itemlist)
403
					// if (i < 3) {
404
					// 	$("#showUnPatent").append(strAdd)
405
					// }
406
					// queryResearcher(dataStr[i].id, $itemlist)
407
					// if (dataStr[i].orgId) {
408
					// 	queryReseOrgName(dataStr[i].orgId, $itemlist)
409
					// }
410
				}
411
			});
412
		},
413
		homepageUnPatent = function () {
414
			oAjax("/ajax/resResult/qm", {
415
				id: unpatentArr,
416
			}, "get", function (data) {
417
				var dataStr = data.data;
418
419
				var subject = '',
420
					department = ''
421
				for (var i = 0; i < dataStr.length; i++) {
422
					if (dataStr[i].subject) {
423
						subject = "应用领域:" + dataStr[i].subject
383 424
					} else {
384
						department = ''
425
						subject = ''
385 426
					}
427
				
386 428
					var resIM = '<div class="madiaHead patentHead"></div>'
387 429
					if (dataStr[i].pic) {
388 430
						var src = '/data/researchResult' + dataStr[i].pic.split(",")[0]
@ -393,25 +435,71 @@ $(function () {
393 435
					strAdd += resIM
394 436
					strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">' + dataStr[i].name + '</p>';
395 437
					strAdd += '<p class="h2Font ellipsisSty ">'+ subject+ '<span class="researchers"></span></p>';
396
					strAdd += '<p class="h2Font ellipsisSty ">'+ department+ '<span class="researchers"></span></p>';
438
					strAdd += '<p class="h2Font ellipsisSty org">'+ '<span class="researchers"></span></p>';
397 439
					// if (dataStr[i].orgId) {
398 440
					// 	strAdd += '<p class="h2Font ellipsisSty">所属机构:<span class="resOrgName"></span></p>';
399 441
					// }
400 442
					strAdd += '</div>';
401 443
					strAdd += '</a></li>';
444
					var $itemlist = $(strAdd);
402 445
403
					$("#" + obj).append(strAdd);
446
					// $("#" + obj).append($itemlist);
404 447
					if (i < 3) {
405
						$("#showUnPatent").append(strAdd)
448
						$("#showUnPatent").append($itemlist)
406 449
					}
407
					var $itemlist = $(strAdd);
450
					orgN(dataStr[i].orgId, $itemlist)
451
408 452
					// queryResearcher(dataStr[i].id, $itemlist)
409
					if (dataStr[i].orgId) {
410
						queryReseOrgName(dataStr[i].orgId, $itemlist)
453
					// if (dataStr[i].orgId) {
454
					// 	queryReseOrgName(dataStr[i].orgId, $itemlist)
455
					// }
456
				}
457
			});
458
		}
459
460
461
462
		orgN = function (par, $pa) {
463
			$.ajax({
464
				"url": "ajax/org/" + par,
465
				"type": "GET",
466
				"success": function (data) {
467
					console.log(data)
468
					if (data.success) {
469
						$pa.find('.org').html('所属机构:'+data.data.name)
411 470
					}
471
				},
472
				"data": {
473
					"id": par
474
				},
475
				dataType: "json",
476
				'error': function () {
477
					$.MsgBox.Alert('提示', '服务器连接超时!');
412 478
				}
413 479
			});
414
		},
480
		}
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
415 503
		queryResearcher = function (id, $list) {
416 504
			if (id) {
417 505
				oAjax("/ajax/resResult/researcher", {

+ 121 - 16
js/teamManage.js

@ -163,7 +163,7 @@ $(function () {
163 163
164 164
165 165
166
					       
166
167 167
					// console.log($info[i])
168 168
					if (ff) {
169 169
						detailPro(aimIdF, 1)
@ -283,7 +283,6 @@ $(function () {
283 283
						itemlist += li4
284 284
						itemlist += '</ul>'
285 285
						itemlist += '</li>';
286
287 286
						$("#" + aimId).append(itemlist)
288 287
					}
289 288
				} else {
@ -303,14 +302,12 @@ $(function () {
303 302
				var $info = res.data.data;
304 303
				$("#showUnPatent").html("")
305 304
				if ($info.length > 0) {
306
307 305
					if (res.data.total > 0 && res.data.total < 99) {
308 306
						$("#unpatCount").text(res.data.total);
309 307
						if (res.data.total == 0 || res.data.total == 1) {
310 308
							$("#unpatCount").text('');
311 309
						}
312 310
					}
313
314 311
					if (res.data.total > 99) {
315 312
						// $("#unpatCount").text("99+");
316 313
					}
@ -346,7 +343,7 @@ $(function () {
346 343
				$("#" + aimId).parent().find(".js-load-more").removeClass("active");
347 344
			})
348 345
		},
349
		searchUnPatent = function () {
346
		searchUnPatent = function () { //收缩
350 347
			var keyt = $('#searchUnPatentKey').val()
351 348
			if (keyt === '') {
352 349
				return
@ -390,7 +387,8 @@ $(function () {
390 387
						itemlist += '</li>';
391 388
						var $itemlist = $(itemlist);
392 389
						$("#" + aimId).append($itemlist)
393
						queryResearcher($info[i].id, $itemlist)
390
						console.log($info[i])
391
						queryResearcher($info[i].id, $info[i])
394 392
						if ($info[i].orgId) {
395 393
							queryReseOrgName($info[i].orgId, $itemlist)
396 394
						}
@ -601,16 +599,14 @@ $(function () {
601 599
			})
602 600
		},
603 601
		detailUnPat = function (obj) {
604
605 602
			oAjax("/ajax/resResult/qm", {
606 603
				id: unpatentArr,
607 604
			}, "get", function (data) {
608 605
				var dataStr = data.data;
609 606
				for (var i = 0; i < dataStr.length; i++) {
610 607
					if (dataStr[i].status == 1) {
611
612 608
						// var $itemlist = $(strAdd);
613
						queryResearcher(dataStr[i].id, dataStr[i], )
609
						queryResearcher(dataStr[i].id, dataStr[i])
614 610
						// queryFeiZhuan(dataStr[i].id, $itemlist)   //研究者名称
615 611
						if (dataStr[i].orgId) {
616 612
							// queryReseOrgName(dataStr[i].orgId,)
@ -622,14 +618,15 @@ $(function () {
622 618
		},
623 619
		queryResearcher = function (id, dataStr, $list) {
624 620
			if (id) {
621
				homepageUnPatent(id, dataStr) //主页非专
625 622
				oAjax("/ajax/resResult/researcher", {
626 623
					"id": id
627 624
				}, 'get', function ($data) {
628 625
					var arr = []
629 626
					var show
630 627
					var nameShow
628
					var subject
631 629
					if ($data.data.length) {
632
633 630
						// $list.find('.researchers').parent().removeClass('displayNone')
634 631
						// $list.find('.researchers').parent().addClass('haha')
635 632
						for (var i = 0; i < $data.data.length; i++) {
@ -640,10 +637,15 @@ $(function () {
640 637
								resIM = '<div class="madiaHead patentHead" style="background-image:url(' + src + ')"></div>';
641 638
							}
642 639
							if (dataStr.orgId) { //所属机构渲染
643
								show = '<p class="h2Font ellipsisSty ">所属机构:<span class="resOrgName">' + dataStr.orgId + '</span></p>';
640
								show = '<p class="h2Font ellipsisSty ">所属机构:<span class="resOrgName">' + '</span></p>';
644 641
							} else {
645 642
								show = '<p class="h2Font ellipsisSty displayNone">所属机构:<span class="resOrgName">' + '</span></p>';
646 643
							}
644
							if (dataStr.subject) { //应用领域渲染
645
								subject = '<p class="h2Font ellipsisSty ">应用领域:<span class="">' +dataStr.subject+ '</span></p>';
646
							} else {
647
								subject = '<p class="h2Font ellipsisSty displayNone">应用领域:<span class="resOrgName">' + '</span></p>';
648
							}
647 649
							if ($data.data[i].name) {
648 650
								nameShow = '<p class="h2Font ellipsisSty ">研究者:<span class="researchers">' + $data.data[i].name + '</span></p>';
649 651
							} else {
@ -654,21 +656,124 @@ $(function () {
654 656
							strAdd += resIM
655 657
							strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">' + dataStr.name + '</p>';
656 658
							strAdd += nameShow
659
							strAdd += subject
657 660
							strAdd += show;
658 661
							strAdd += '</div>';
659 662
							strAdd += '</a>'
660 663
							strAdd += '<ul class="madiaEdit">'
661 664
							strAdd += '<li class="deloutPro" data-id="' + dataStr.id + '">取消关联</li>'
662 665
							strAdd += '</ul></li>'
663
							$('#proUnPatent').append(strAdd);
664
							if (i < 3) {
665
								$("#showUnPatent").append(strAdd)
666
							}
666
							var list = $(strAdd)
667
							$('#proUnPatent').append(list);
668
							orgN(dataStr.orgId, list)
669
							// if (i < 3) {
670
							// 	$("#showUnPatent").append(list)
671
							// }
667 672
						}
668 673
					}
669 674
				})
670 675
			}
671 676
		},
677
		orgN = function (par, $pa) {
678
			$.ajax({
679
				"url": "ajax/org/" + par,
680
				"type": "GET",
681
				"success": function (data) {
682
					console.log(data)
683
					if (data.success) {
684
						$pa.find('.resOrgName').html("所属机构"+ data.data.name)
685
					}
686
				},
687
				"data": {
688
					"id": par
689
				},
690
				dataType: "json",
691
				'error': function () {
692
					$.MsgBox.Alert('提示', '服务器连接超时!');
693
				}
694
			});
695
		}
696
697
	//主页非专 
698
	homepageUnPatent = function (id, dataStr) {
699
		oAjax("/ajax/resResult/researcher", {
700
			"id": id
701
		}, 'get', function ($data) {
702
			var show
703
			var nameShow
704
			var subject
705
			if ($data.data.length) {
706
				// $list.find('.researchers').parent().removeClass('displayNone')
707
				// $list.find('.researchers').parent().addClass('haha')
708
				for (var i = 0; i < $data.data.length; i++) {
709
					var resIM = '<div class="madiaHead patentHead"></div>'
710
					if (dataStr.pic) {
711
						var src = '/data/researchResult' + dataStr.pic.split(",")[0]
712
						resIM = '<div class="madiaHead patentHead" style="background-image:url(' + src + ')"></div>';
713
					}
714
					if (dataStr.orgId) { //所属机构渲染
715
						show = '<p class="h2Font ellipsisSty ">所属机构:<span class="resOrgName">' + '</span></p>';
716
					} else {
717
						show = '<p class="h2Font ellipsisSty displayNone">所属机构:<span class="resOrgName">' + '</span></p>';
718
					}
719
					if (dataStr.subject) { //所属机构渲染
720
						subject = '<p class="h2Font ellipsisSty ">应用领域:<span class="resOrgName">' +subject+ '</span></p>';
721
					} else {
722
						subject = '<p class="h2Font ellipsisSty displayNone">所属机构:<span class="resOrgName">' + '</span></p>';
723
					}
724
					if ($data.data[i].name) {
725
						nameShow = '<p class="h2Font ellipsisSty ">研究者:<span class="researchers">' + $data.data[i].name + '</span></p>';
726
					} else {
727
						nameShow = '<p class="h2Font ellipsisSty  displayNone">研究者:<span class="researchers">' + $data.data[i].name + '</span></p>';
728
					}
729
					var strAdd = '';
730
					strAdd += '<li class="mui-table-view-cell"><a  target="_blank" href="unPatentShow.html?id=' + dataStr.id + '" class="flexCenter urlgo">';
731
					strAdd += resIM
732
					strAdd += '<div class="madiaInfo"><p class="h1Font ellipsisSty">' + dataStr.name + '</p>';
733
					strAdd += nameShow
734
					strAdd += subject
735
					strAdd += show;
736
					strAdd += '</div>';
737
					strAdd += '</a>'
738
					strAdd += '<ul class="madiaEdit">'
739
					strAdd += '<li class="deloutPro" data-id="' + dataStr.id + '">取消关联</li>'
740
					strAdd += '</ul></li>'
741
					var list = $(strAdd)
742
					orgN(dataStr.orgId, list)
743
					if (i < 3) {
744
						$("#showUnPatent").append(list)
745
					}
746
				}
747
			}
748
		})
749
	}
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
672 777
673 778
674 779
@ -679,7 +784,7 @@ $(function () {
679 784
680 785
681 786
682
		queryReseOrgName = function (id, $list) {
787
	queryReseOrgName = function (id, $list) {
683 788
			if (id) {
684 789
				cacheModel.getCompany(id, function (sc, value) {
685 790
					if (sc) {

+ 34 - 1
js/unPatentImport.js

@ -122,7 +122,7 @@ $(document).ready(function () {
122 122
							'<p class="h1Font ellipsisSty">' + $data.name + '</p>' +
123 123
							'<p class="h2Font ellipsisSty">' + oSpec + '</p>' +
124 124
							'<p class="h2Font ellipsisSty">应用领域:' + $data.subject + '</p>' +
125
							'<p class="h2Font ellipsisSty">所属部门:' + $data.department + '</p>' +
125
							// '<p class="h2Font ellipsisSty">所属部门:' + $data.department + '</p>' +
126 126
							'<p class="h2Font ellipsisSty">' + '</p>' +
127 127
							'</div>' +
128 128
							'</a>' +
@ -132,12 +132,45 @@ $(document).ready(function () {
132 132
							'<span class="importSpan-3">已导入</span>' +*/
133 133
							'</div>' +
134 134
							'</li>'
135
						var list = $(oString)
135 136
						$(".importUl").append(oString);
137
						console.log($data.orgId)
138
						if($data.orgId) {
139
							orgname($data.orgId,list)
140
						}
136 141
					}
137 142
				})
138 143
			}
139 144
		})
140 145
	}
146
	//所属机构
147
	function orgname(par, $pa) {
148
		$.ajax({
149
			"url": "ajax/org/" + par,
150
			"type": "GET",
151
			"success": function (data) {
152
				console.log(par)
153
				if (data.success) {
154
					$pa.find('.hu1').append('<li>所属机构:' + data.data.name+ '</li>')
155
				}
156
			},
157
			"data": {
158
				"id": par
159
			},
160
			dataType: "json",
161
			'error': function () {
162
				$.MsgBox.Alert('提示', '服务器连接超时!');
163
			}
164
		});
165
	}
166
167
168
169
170
171
172
173
141 174
	/*输入资源名称限制字数*/
142 175
	$("#resouceName").bind({
143 176
		keyup: function () {

+ 9 - 6
js/unPatentList.js

@ -66,6 +66,7 @@ $(document).ready(function () {
66 66
67 67
68 68
	function resourceHtml($data) {
69
		console.log($data)
69 70
		for (var i = 0; i < $data.length; i++) {
70 71
71 72
			var oTime, pageview = "",
@ -110,6 +111,7 @@ $(document).ready(function () {
110 111
			$("#patentList").append($oStr);
111 112
			if ($data[i].status == '1') {
112 113
				proList($data[i].id, $oStr, $data[i].orgId,$data[i].subject,$data[i].department || '')
114
				console.log($data[i])
113 115
			}
114 116
			$oStr.find(".editThis").attr("data-state", $data[i].status);
115 117
		}
@ -134,12 +136,13 @@ $(document).ready(function () {
134 136
						}
135 137
						$pa.find('.hu2').append('<li>研究者:' + arr.join(',') + '</li>')
136 138
						$pa.find('.hu2').append('<li>应用领域:' + subject + '</li>')
137
						$pa.find('.hu2').append('<li>所属部门:' + department + '</li>')
138 139
						$pa.find('.hu2>li').css({'float':'none' , 'margin-bottom':'0px'})
139 140
						$('.itemListBolck .itemListCon .madiaInfo').css('padding-top','0px')
140
						
141
						if (p3)
142
							orgname(p3, $pa)
141
						orgname(p3, $pa)
142
						console.log(p3)
143
						if (p3){
144
							
145
						}
143 146
						$.ajax({
144 147
							'url': '/ajax/resResult/selectbyidandPid',
145 148
							'type': 'get',
@ -150,7 +153,6 @@ $(document).ready(function () {
150 153
							'success': function (res) {
151 154
								var $info = res.data
152 155
								for (var i = 0; i < $info.length; i++) {
153
									console.log($info[i].name)
154 156
									if ($info[i].name == '######' || $info[i].status == 0) {
155 157
										$pa.find('.deteleThis3').css('display', 'none')
156 158
									} else {
@ -178,8 +180,9 @@ $(document).ready(function () {
178 180
			"url": "ajax/org/" + par,
179 181
			"type": "GET",
180 182
			"success": function (data) {
183
				console.log(data)
181 184
				if (data.success) {
182
					$pa.find('.hu1').append('<li>所属机构:' + data.data.name + '</li>')
185
					$pa.find('.hu1').append('<li>所属机构:' + data.data.name+ '</li>')
183 186
				}
184 187
			},
185 188
			"data": {