Browse Source

分享论文、专利、企业、个人

luyanan 7 years ago
parent
commit
f99c067f7c
11 changed files with 1526 additions and 847 deletions
  1. 82 101
      css/share.css
  2. 31 158
      e/a.html
  3. 274 0
      e/c.html
  4. 261 0
      e/l.html
  5. 406 462
      e/p.html
  6. 35 126
      e/r.html
  7. 275 0
      e/z.html
  8. BIN
      images/enterprise_img_bg_nor@3x.png
  9. BIN
      images/personal_icon_dizhi_nor@3x.png
  10. BIN
      images/personal_img_bg_nor@3x.png
  11. 162 0
      js/public/shareCom.js

+ 82 - 101
css/share.css

@ -2,84 +2,13 @@
2 2
/* CSS Document */
3 3
html,body {margin:0;padding:0px;background: #efeff4;}
4 4
.contentBody2{max-width:640px;margin:auto;}
5
.iconfontnew{display: inline-block;width: 18px;height: 18px;*margin-right: .3em;line-height: 18px;vertical-align: text-top;
6
  background-position: center center; background-repeat: no-repeat;background-size: cover;}
7
.icon-address{width:11px;height:14px;background-image: url("../images/personal_icon_dizhi_nor@3x.png");background-size:cover;line-height: 14px;}
5 8
/*input输入相关*/
6
.frmbox {width: 100%;margin: 2% auto;border-radius: 6px;}
7
.frmtype {width: 100%;margin: auto;line-height: 30px;padding: 1% 2%;font-size: 14px;line-height: 20px;}
8 9
.frmbtn {width: 100%;margin: 4% auto;font-size: 14px;line-height: 24px;padding:2%;border: 1px solid #FF9900;border-radius: 6px;color: #FF9900;outline: none;}
9
.frmbox {border: none;width: 90%;height: 100%;}
10 10
.frmactive {color: #fff;background-color: #FF9900;border: 1px solid #FF9900;}
11
.pull-right {float: right!important}
12
.pull-left {float: left!important}
13
.alignCenter {text-align: center;}
14
.displayNone {display: none;}
15
.displayBlock {display: block;}
16
/*圆角*/
17
/*头像、资源圆角*/
18
.headRadius {border-radius: 4px;}
19
.blockGroup {background: #fff;}
20
.mainbox {width: 96%;margin: 2% auto;}
21
.maincon {padding: 4% 2%;overflow: hidden;}
22
23
.listtit {font-size: 16px;line-height: 26px;color: #333333;}
24
.listtit2 {font-size: 15px;line-height: 20px;color: #666666;}
25
.listtit3 {font-size: 13px;line-height: 18px;color: #888888;}
26
.mui-ellipsis {overflow: hidden;white-space: nowrap;text-overflow: ellipsis;}
27
/*资源图片*/
28
.ResImgBox {display: inline-block;text-align: center;max-width: 64px;width: 64px;height: 60px;padding: 1px;background: #FAFAFA;border: 1px solid #F8F8F8;overflow: hidden;padding: 2px;margin: 6px 0;border-radius: 4px;}
29
.ResImgBox2 {margin: 6px 0 6px 10px;}
30
.ResImgBox .resImg {max-width: 100%;max-height: 100%;vertical-align: middle;position: relative;}
31
.ResImgBox:before {content: ' ';display: inline-block;vertical-align: middle;width: 0;height: 100%;overflow: hidden;margin-left: -6px;}
32
33
/*咨询记录及等级*/
34
.peolevelbox {display: block;padding: 4% 16px;border-top: 1px #F0F0F0 solid;}
35
.peocountbox {width: 150px;}
36
.peocount {font-size: 13px;color: #888888;overflow: hidden;}
37
.peocount span em {font-size: 14px;padding: 0 3px;color: #FF9900;font-weight: 600;}
38
.peocount .dialogicon {display: block;width: 20px;height: 20px;background: url(../images/dialogue.png) center center no-repeat;background-size: 100% 100%;margin-right: 6px;}
39
.peocount:before {position: absolute;right: 0;top: 0;left: 15px;height: 1px;content: '';-webkit-transform: scaleY(.5);transform: scaleY(.5);background-color: #c8c7cc;}
40
.levelbox {margin: auto;overflow: hidden;}
41
.levelbox .iconfont {float: left;margin: 2px;width: 14px;height: 14px;}
42
.levelbox .icon-favor {background: url(../images/favoricon.png) 0 0 no-repeat;background-size: 100% auto;}
43
.levelbox .icon-favorfill {background: url(../images/favoricon.png) 0 -14px no-repeat;background-size: 100% auto;}
44
/*专家相关信息*/
45
.personinfo .listtit3 {font-size: 14px;line-height: 24px;color: #AAAAAA;margin: 0;}
46
.personinfo .listtit {font-size: 18px;line-height: 30px;color: #333333;}
47
.personinfo .listtit3 {font-size: 14px;line-height: 24px;color: #AAAAAA;margin: 0;}
48
.headbox .headimg {width: 100px;overflow: hidden;margin: auto;}
49
50
.infocontit {font-size: 14px;position: relative;}
51
.infocon {padding: 6px 10px;font-size: 13px;line-height: 27px;color: #888888;}	
52
.infocon ul {padding: 0;margin: 0;overflow: hidden;}		
53
.infocon .infoapply li {padding:0;margin:0;padding-left: 6px;padding-right: 2px;list-style: disc inside;width: 46%;float: left;}		
54
.infocon .infosubject li {list-style: none;padding: 2px 16px;margin: 4px;border: 1px solid #BBBBBB;border-radius: 6px;float: left;}
55
.personblock {position: absolute;left: 198px;padding: 0 3%;text-align: center;}
56
.personbox{margin:auto; width:80%;position:relative;}
57
				
58
.listitembox {position: static;width: 100%;}		
59
.listitembox .listitem {padding: 4px;padding-right: 0;}		
60
.listitembox .listitem .media-body {width: 73%;margin-left: 2%;}		
61
.listitembox .listitem .media-body .resbrief {width: 100%;}		
62
.listitembox .listitem .media-object {width: 30%;}	
63
.listitembox .listitem .media-object .iconposition {border-radius: 50%;max-width: 60px;height: 60px;margin: 1% 0;}		
64
.listitembox .listitem>a .mutlinebox {white-space: normal;overflow: auto;word-break: break-word;}		
65
.listbox {margin: 5px 0;max-width: 100%;overflow: hidden;}		
66
.listbrowse {border: 1px solid #FF9900;border-radius: 0 6px 6px 0;text-align: center;font-size: 13px;line-height: 27px;float: left;padding-right: 8px;max-width: 60%;overflow: hidden;}		
67
.like {display: block;float: left;width: 28px;font-size: 12px;background: #FF9900;color: #fff;line-height: 27px;margin-right: 5px;}		
68
.likenum {float: right;max-width: 130px;overflow: hidden;}		
69
.likenum .mui-icon {font-size: 24px;color: #CCCCCC;}		
70
.likepeople {width: 26px;height: 26px;line-height: 20px;float: left;overflow: hidden;margin-right: 5px;}
71
.likepeople img {width: 100%;height: 100%;}		
72
.likemore {display: block;width: 25px;height: 25px;border: 1px solid #CCCCCC;background: url(../images/likemore.png) center center no-repeat;}
73
74
/*文章*/
75
.art_topicBox {max-width: 640px;margin: 0 auto 4px ;}
76
.art_topicBox img {width: 100%;}
77
.art_img {height: 180px;}
78
.line01 {margin:10px 0 4px 0;border-top: 1px dashed #ddd;height: 1px;overflow: hidden;clear: both;width: 100%;}			
79
#artical_topic {font-size: 18px;line-height: 24px;}			
80
#artical_sth {font-size: 12px;line-height: 14px;color: #999999;}
81
.articalBox {max-width: 640px;margin: 6px auto 26px;padding: 4px 16px;color: #555555;}
82
			
11
	
83 12
/*--------------------邀请好友注册科袖2017.4.28--------------*/	
84 13
@media (min-width: 768px){
85 14
	.invitebody .form-inline .form-group {display:block;margin-bottom: 15px;vertical-align: middle;}
@ -138,10 +67,8 @@ html,body {margin:0;padding:0px;background: #efeff4;}
138 67
.showDetail .showFont{font-size:16px;margin-top:-4px; line-height:24px;color:#333;}
139 68
.showDetail .h2Font{font-size:14px;color:#666; line-height:24px;}
140 69
.showDetail .h3Font{font-size:13px;color:#999; line-height:24px;}
141
.showDetail .attenSpan{position:absolute;right:15px;top:50%;margin-top:-13px;padding:6px 8px;padding-left:20px;background: #ff9900;border-radius:4px;display:inline-block;cursor:pointer;color:#fff;font-size:14px;}
142
.showDetail .attenSpan:before{position:absolute;content:"\e468";top:50%;left:2px;margin-top:-10px;font-size:20px;}
143
.showDetail .showMain{font-size:15px;color:#333;line-height:28px;/*text-indent: 2em;*/}
144
.showDetail .showMain img{max-width: 100%;/*margin-left:-32px;*/}
70
.showDetail .showMain{font-size:15px;color:#333;line-height:28px;}
71
.showDetail .showMain img{max-width: 100%;}
145 72
.showDetail .showMain p{margin-bottom:10px;font-size:15px;color:#333;}
146 73
ul.tagList{padding:0;margin:18px 0 8px;overflow: hidden;}
147 74
ul.tagList>li{list-style:none;float: left;margin-right:10px;margin-bottom:10px;padding:4px 12px;color: #666;background:#EFEFEF;}
@ -149,20 +76,21 @@ ul.tagList>li .h2Font{color: #666;}
149 76
.madiaBlock{clear:both;}.madiaBlock:before,.madiaBlock:after{display:table;content:""}.madiaBlock:after{clear: both;}
150 77
.madiaBlock ul.mui-table-view{margin:10px 0;overflow: hidden;}
151 78
.madiaBlock ul.mui-table-view .mui-table-view-cell{position: relative;}
152
.madiaBlock ul.mui-table-view .mui-table-view-cell:after{left:15px;}
153 79
.madiaBlock .madiaTit{position:relative;font-size:16px;color:#666;padding-left:10px;margin-top:15px;}
154 80
.madiaBlock .madiaTit:before{display:inline-block;content:"";width:4px;height: 16px;position:absolute;top:1px;left:0;background: #ff9900;}
155
.madiaBlock .madiaHead{position:absolute;border:1px solid #E5E5E5;top:50%;background-position: center;background-size: cover;}
81
.madiaBlock .madiaHead{width:90px;height:60px;margin-top:-30px;position:absolute;border:1px solid #E5E5E5;top:50%;background-position: center;background-size: cover;}
156 82
.madiaBlock .madiaHead.useHead{width: 50px;height:50px;margin-top:-25px;background-image: url(../images/default-photo.jpg);border-radius: 50%;}
157
.madiaBlock .madiaHead.resouseHead{width:90px;height:60px;margin-top:-30px;background-image: url(../images/default-resource.jpg);border-radius:0;}
158
.madiaBlock .madiaHead.artHead{width:90px;height:60px;margin-top:-30px;background-image: url(../images/default-artical.jpg);border-radius:0;}
159
.madiaBlock .madiaHead.cmpHead{width: 50px;height:50px;margin-top:-25px;background-image: url(../images/default-icon.jpg);border-radius:0;}
160
.madiaBlock .madiaInfo{padding-left:62px; width: 100%;margin:4px 0;}
161
.madiaBlock .madiaInfo .authicon{position:relative;bottom:-2px;}
83
.madiaBlock .madiaHead.resouseHead{background-image: url(../images/default-resource.jpg);}
84
.madiaBlock .madiaHead.artHead{background-image: url(../images/default-artical.jpg);}
85
.madiaBlock .madiaHead.cmpHead{width: 50px;height:50px;margin-top:-25px;background:#FFFFFF;border-radius:0;}
86
.madiaBlock .madiaHead.paperHead{background-image: url(../images/default-paper.jpg);}
87
.madiaBlock .madiaHead.patentHead{background-image: url(../images/default-patent.jpg);}
88
.madiaBlock .madiaInfo{padding-left:62px; width: 100%;margin:4px 0;overflow: hidden;}
162 89
.madiaBlock .madiaInfo.OmadiaInfo{padding-left: 102px;}
163
.madiaBlock .flexCenter{min-height:54px;}
90
.madiaBlock .flexCenter{min-height:64px;}
164 91
.madiaBlock .flexCenter.OflexCenter{min-height:70px;}
165 92
.madiaBlock .madiaInfo .h1Font{font-size: 16px;margin:0;line-height:28px;}
93
.madiaBlock .madiaInfo .ellipsisSty-2{max-height: 44px;}
166 94
/*资源轮播图片样式*/
167 95
#index-container {height:300px;background: #f0f0f0;position: relative;overflow: hidden;z-index: 1;}
168 96
#index-container .swiper-wrapper { position: relative;z-index: 1;
@ -201,26 +129,79 @@ ul.tagList>li .h2Font{color: #666;}
201 129
#index-container .swiper-pagination .swiper-pagination-bullet {width: 6px;height: 6px;margin:0 10px;background: #ccc;display: inline-block;border-radius: 50%;opacity: 0.9;}
202 130
#index-container .swiper-pagination .swiper-pagination-bullet-active {background: #fff}
203 131
/*轮播图片样式 end*/
204
/*资源图片轮播*/
205
/*.img_gallery{height:300px;background: #f0f0f0;overflow:hidden;position:relative;}
206
.main_img{height:300px;overflow:hidden;position:relative;}
207
.main_img ul{width:9999px;height:300px;overflow:hidden;position:absolute;top:0;left:0}
208
.main_img li{float:left;width:100%;height:300px;}
209

210
div.point{position:absolute;bottom:20px;left:50%;z-index:999;width:80px;text-align: center;margin-left: -50px;}
211
div.point a{float:left;width:6px;height:6px;margin:0 10px;padding:0;display:block;text-indent:-1000px;background-color: #ccc;border-radius: 50%;cursor: pointer;}
212
div.point a.on{background-color: #fff;}
213

214
.main_img .tab-re{display: inline-block;text-align: center;max-width:100%;width:100%;height:300px;overflow: hidden;vertical-align:middle;}
215
.main_img .tab-re img{width:auto;max-width: 100%;max-height: 100%;vertical-align: middle;position: relative;}
216
.main_img .tab-re:before{content: ' ';display: inline-block;vertical-align: middle;width: 0;height: 100%;overflow: hidden;margin-left: -6px;}*/
217 132
.showMain>ul{margin:0;padding:0;}
218 133
.showMain.showRes>ul>li{padding:0;margin:0;list-style: none;display: none;}
219 134
.showMain .showTit{position:relative;padding-left:10px;text-indent: 0;}
220 135
.showMain .showTit:before{position:absolute;top:50%;margin-top:-10px;left:0;display:inline-block;content:"";width:4px;height:16px;background:#ff9900;}
136
/*--------------2017.07.12新功能论文和专利相关--------------*/
137
.showMainP{margin-top: 20px;}
138
.showMainP li{overflow: hidden;}
139
.showMainP .showTit{padding-left: 0;color: #666;}
140
.showMainP .showTit:before{content: none;}
141
.showMainP .showCon{color: #333;}
142
/*新版用户和企业相关*/
143
.showCardI{overflow:hidden;background: url(../images/personal_img_bg_nor@3x.png) center 0 no-repeat;background-size:100% 130px;}
144
.cardTop{position:relative;text-align:center;min-height:140px;margin:15px 15px 6px;padding:40px 40px 20px;
145
		background: rgba(256,256,256,.6);background: linear-gradient( rgba(256,256,256,.6), rgba(256,256,256,.9));border-radius:6px;box-shadow: 0px 2px 4px 1px rgba(0,0,0,.1);}
146
.cardImg{position: absolute;left:50%;margin-left: -30px;width: 60px;height: 60px;overflow: hidden;background-size: cover;border:1px solid #E5E5E5;}
147
.cardImg.userCard{background-image:url(../images/default-photo.jpg);border-radius: 50%;}
148
.cardImg.cmpCard{border-radius:4px;}
149
.cardImg.cmpCard .boxBlock{width: 60px;height: 60px;}
150
.cardInfo{margin-top:82px;}
151
.cardInfo .h1Font{font-size:16px;}
152
.cardInfo .h2Font{font-size:14px;color: #666;}
153
.cardInfo .h3Font{font-size:13px;line-height: 16px;color: #666;}
154
155
.mainbox{width:100%;margin:10px auto;background: #FFFFFF;}
156
/*专家相关信息*/
157
.infocontit{font-size:16px;line-height: 40px;min-height:40px;border-bottom: 1px solid #E5E5E5; position: relative;padding-left: 26px;color:#333}
158
.infocontit:before{position:absolute;top:50%;margin-top:-10px;left: 15px;;display:inline-block;content:"";width:4px;height:18px;border-radius:10px;background:#ff9900;}
159
.infocontit em{font-style: normal;position:absolute;right:28px;}
160
.infocontit em:before{border: solid transparent;border-left-color:#ccc;border-width: 7px;content: " ";position: absolute;left: 100%;top: 12px;}
161
.infocontit em:after{border: solid transparent;border-left-color:#fff;border-width: 5px;content: " ";position: absolute;left: 100%;top: 14px;}
162
163
.infocontitM{padding-left: 15px;}
164
.infocontitM:before{content: none;}
165
.OnetitM{border-color: transparent;}
166
.infocon{padding:15px; font-size: 14px;line-height:22px;color:#666;}
167
.infocon .breifinfo{display: -webkit-box;white-space: normal !important;text-overflow: ellipsis;word-wrap: break-word; -webkit-line-clamp:5;-webkit-box-orient: vertical;overflow: hidden;max-height: 110px;}
168
169
.infocon ul{ padding:0; margin: 0; overflow: hidden;}
170
.infocon ul>li{list-style: none;}
171
.infocon>ul.mui-table-view>.mui-table-view-cell{position: relative;overflow: hidden; padding: 11px 15px;}
172
.infocon>ul.mui-table-view>.mui-table-view-cell:after{position: absolute;right: 0;bottom: 0;left:15px;height: 1px;content: '';-webkit-transform: scaleY(.5);transform: scaleY(.5); background-color: #c8c7cc;}
173
.infocon>ul.mui-table-view>.mui-table-view-cell:last-child:after{background: none;}
174
.infocon.listArea>ul{overflow: hidden;margin-right: -10px;margin-top:-10px;}
175
.infocon.listArea>ul>li{float: left;margin-right: 10px;margin-top:10px;border:1px solid #E5E5E5;border-radius:6px;padding:2px 12px;}
176
.infocon.madiaBlock>ul{margin:-15px;}
177
.infocon.madiaBlock>ul>li{padding-left:15px;}
178
.infocon.madiaBlock .h1Font{font-size: 16px;margin: 0;line-height: 24px;color: #333333;}
179
.infocon.madiaBlock .h2Font{font-size: 14px;margin: 0;line-height: 22px;color:#999999;}
180
181
.seeMore{cursor:pointer;text-align:center;font-size:14px;color:#999;line-height:40px;height:40px;border-top:1px solid #E5E5E5;position: relative;}
182
.seeMore em{font-style: normal;position:absolute;left:50%;margin-left: -24px;padding-right:5px;}
183
.seeMore em:before{border: solid transparent;border-left-color:#ccc;border-width: 7px;content: " ";position: absolute;left: 100%;top: 12px;}
184
.seeMore em:after{border: solid transparent;border-left-color:#fff;border-width: 5px;content: " ";position: absolute;left: 100%;top: 14px;}
185
.detailInfo>ul>li{color:#333;padding-left:0;}
186
.detailInfo>ul>li>span{color:#666}
187
188
.listbox{ margin:5px 0;max-width:100%; overflow:hidden;}
189
.listbrowse{border: 1px solid #FF9900; border-radius: 0 6px 6px 0; text-align:center;font-size:13px;line-height:27px; float:left;padding-right: 8px; max-width:60%; overflow:hidden;}
190
.plusbtn{ font-size:20px; line-height: 22px; color:#999999;margin-left:4px; margin-top:2px;  }
191
.plusbtn.icon-appreciatefill{color:#FF9900;}
192
.like {display: block;float: left;width: 28px;font-size:12px;background: #FF9900; color: #fff; line-height: 27px;margin-right: 5px;}
193
.likenum{ float:right;max-width:130px;overflow:hidden; }
194
.likenum .mui-icon{ font-size:24px; color:#CCCCCC;}
195
.likepeople{ width:26px; height:26px; float:left; overflow:hidden; margin-right:5px; }
196
.likepeople img{ width:100%; height:100%;}
197
.likemore{ display: block; width: 26px; height: 26px; border:1px solid #CCCCCC;}
198
199
.infoapply li{position: relative; padding-left:12px;padding-right:2px;}
200
.infoapply li:before{content:''; background: #999;display: block;width: 4px;height: 4px;border-radius: 50%; position: absolute;top:8px;left:0;}
201
221 202
222 203
/*下载按钮及公众二维码*/
223
.shareEcode{padding: 15px;}
204
.shareEcode{padding:25px 15px 15px;}
224 205
.Ecodebox{border-radius:4px;box-shadow: 0 2px 10px #ccc;padding:20px 10px;}
225 206
.Ecodebox .Ecodecon{position: relative;min-height:100px;margin: auto;max-width: 300px;}
226 207
.Ecodebox .Ecodecon img{position: absolute;left:0;top:50%;margin-top:-50px;width:100px;}

+ 31 - 158
e/a.html

@ -10,6 +10,7 @@
10 10
		<link rel="stylesheet" href="../css/share.css" />
11 11
		<script type="text/javascript" src="../js/jquery-1.11.1.js"></script>
12 12
		<script type="text/javascript" src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
13
		<script type="text/javascript" src="../js/public/shareCom.js"></script>	
13 14
		<style>
14 15
			html,
15 16
			body {
@ -73,19 +74,31 @@
73 74
				var appid = '';
74 75
				var articleId = GetQueryString("id");
75 76
				$.ajax({
76
						"url" : "/ajax/article/pageViews",
77
						"type" :  "POST" ,
78
						"dataType" : "json",
79
						"data" :{"articleId":articleId},
80
						"success" : function(data) {
81
							console.log(data);
82
							if (data.success){
83
							}
84
						},
85
						"error":function(){
86
							//$.MsgBox.Alert('提示','链接服务器超时')
77
					"url" : "/ajax/article/pageViews",
78
					"type" :  "POST" ,
79
					"dataType" : "json",
80
					"data" :{"articleId":articleId},
81
					"success" : function(data) {
82
						console.log(data);
83
						if (data.success){
87 84
						}
88
					});
85
					},
86
					"error":function(){
87
						//$.MsgBox.Alert('提示','链接服务器超时')
88
					}
89
				});
90
				//进入发布者详情页面
91
				$("#personAL").on("click", function() {
92
					var reType = this.getAttribute("data-type");
93
					if(reType=="1"){
94
						var proId=this.getAttribute("data-id");
95
						location.href="http://" + window.location.host + "/e/p.html?id=" + proId;
96
					}else{
97
						var cmpId=this.getAttribute("data-id");
98
						location.href="http://" + window.location.host + "/e/c.html?id=" + cmpId;
99
					}
100
						
101
				})
89 102
				var oArticleModule = {
90 103
					articleId: GetQueryString("id"),
91 104
					oAjaxGet: function(url, obj, oType, oFun) {
@ -131,9 +144,12 @@
131 144
								document.getElementsByClassName("tagList")[0].appendChild(oLi);
132 145
							}
133 146
						}
147
						document.getElementById("personAL").setAttribute("data-type",$data.articleType);
134 148
						if($data.articleType == 1) {
149
							document.getElementById("personAL").setAttribute("data-id",$data.professorId);
135 150
							oArticleModule.oAjaxGet("../ajax/professor/editBaseInfo/" + $data.professorId, "", "get", oArticleModule.professorMess);
136 151
						} else {
152
							document.getElementById("personAL").setAttribute("data-id",$data.orgId);
137 153
							oArticleModule.oAjaxGet("../ajax/org/" + $data.orgId, "", "get", oArticleModule.business);
138 154
						}
139 155
					},
@ -146,6 +162,7 @@
146 162
						}
147 163
						var userType = autho($data.authType, $data.orgAuth, $data.authStatus);
148 164
						document.getElementById("auth").classList.add(userType.sty);
165
						
149 166
					},
150 167
					business: function($data) {
151 168
						//console.log(JSON.stringify($data));
@ -160,158 +177,14 @@
160 177
						if($data.authStatus == 3) {
161 178
							document.getElementById("auth").classList.add("authicon-com-ok");
162 179
						}
163

164 180
					}
165 181
				}
166 182
				/*文章详细内容*/
167 183
				oArticleModule.oAjaxGet("../ajax/article/query", {
168 184
					articleId: oArticleModule.articleId
169 185
				}, "get", oArticleModule.articleMess);
170

171
				function GetQueryString(name) {
172
					var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
173
					var r = window.location.search.substr(1).match(reg);
174
					var context = "";
175
					if(r != null)
176
						context = r[2];
177
					reg = null;
178
					r = null;
179
					return context == null || context == "" || context == "undefined" ? "" : decodeURI(context);
180
				}
181
				/*标志*/
182
				function autho() {
183
					if(arguments[0] == 1) {
184
						return {
185
							"sty": "authicon-pro",
186
							"title": "科袖认证专家"
187
						}
188
					} else {
189
						if(arguments[1] == 1) {
190
							return {
191
								"sty": "authicon-staff-ok",
192
								"title": "企业认证员工"
193
							}
194
						} else {
195
							if(arguments[2] == 3) {
196
								return {
197
									"sty": "authicon-real",
198
									"title": "实名认证用户"
199
								}
200
							} else {
201
								return {
202
									"sty": "e",
203
									"title": " "
204
								}
205
							}
206
						}
207
					}
208
				}
209
				/*微信分享*/
210
				$.ajax({
211
					url: "../ajax/weixin/jsapiTicket",
212
					type: 'get',
213
					dataType: 'json',
214
					contentType: "application/x-www-form-urlencoded; charset=utf-8",
215
					data: {
216
						'url': location.href.split('#')[0]
217
					},
218
					success: function(data) {
219
						if(data.data) {
220
							wx.config({
221
								debug: false, //调试模式好犀利
222
								appId: data.data.appId,
223
								timestamp: data.data.timestamp,
224
								nonceStr: data.data.nonceStr,
225
								signature: data.data.signature,
226
								jsApiList: [ // 所有要调用的 API 都要加到这个列表中
227
									"onMenuShareAppMessage",
228
									"onMenuShareTimeline",
229
									"onMenuShareQQ",
230
									"onMenuShareQZone",
231
									"scanQRCode",
232
								]
233
							});
234

235
							wx.ready(function() {
236
								// 在这里调用 API
237
								wx.onMenuShareAppMessage({ //分享给朋友
238
									title: shareTitle, // 分享标题
239
									desc: descContent, // 分享描述
240
									link: lineLink, // 分享链接
241
									imgUrl: imgUrl, // 分享图标
242
									success: share_success_callback,
243
									cancel: share_cancel_callback
244
								});
245

246
								wx.onMenuShareTimeline({ //分享到朋友圈
247
									title: shareTitle, // 分享标题
248
									desc: descContent, // 分享描述
249
									link: lineLink, // 分享链接
250
									imgUrl: imgUrl, // 分享图标
251
									success: share_success_callback,
252
									cancel: share_cancel_callback
253
								});
254

255
								wx.onMenuShareQQ({ //分享到QQ
256
									title: shareTitle, // 分享标题
257
									desc: descContent, // 分享描述
258
									link: lineLink, // 分享链接
259
									imgUrl: imgUrl, // 分享图标
260
									success: share_success_callback,
261
									cancel: share_cancel_callback
262
								});
263

264
								wx.onMenuShareQZone({ //分享到QQ空间
265
									title: shareTitle, // 分享标题
266
									desc: descContent, // 分享描述
267
									link: lineLink, // 分享链接
268
									imgUrl: imgUrl, // 分享图标
269
									success: share_success_callback,
270
									cancel: share_cancel_callback
271
								});
272

273
							});
274

275
							//分享成功后的回调函数	
276
							function share_success_callback() {}
277

278
							//用户取消分享后执行的回调函数	
279
							function share_cancel_callback() {}
280

281
						}
282

283
					}
284
				});
285
			//时间显示规则
286
function commenTime(startTime) {
287
	var nowTimg = new Date();
288
	var startdate = new Date();
289
	startdate.setFullYear(parseInt(startTime.substring(0, 4)));
290
	startdate.setMonth(parseInt(startTime.substring(4, 6)) - 1);
291
	startdate.setDate(parseInt(startTime.substring(6, 8)));
292
	startdate.setHours(parseInt(startTime.substring(8, 10)));
293
	startdate.setMinutes(parseInt(startTime.substring(10, 12)));
294
	startdate.setSeconds(parseInt(startTime.substring(12, 14)));
295
	var date3 = nowTimg.getTime() - startdate.getTime(); //时间差的毫秒数
296
	var hours = parseInt((date3 % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
297
	var minutes = parseInt((date3 % (1000 * 60 * 60)) / (1000 * 60));
298
	if(date3 < 60000) {
299
		return "刚刚";
300
	} else if(date3 >= 60000 && date3 < 3600000) {
301
		return minutes + "分钟前";
302
	} else if(date3 >= 3600000 && date3 < 86400000) {
303
		return hours + "小时前";
304
	} else if(date3 >= 86400000) {
305

306
		if(nowTimg.getFullYear() == startTime.substring(0, 4)) {
307

308
			return startTime.substring(4, 6).replace(/\b(0+)/gi, "") + "月" + startTime.substring(6, 8).replace(/\b(0+)/gi, "") + "日 " + startTime.substring(8, 10) + ":" + startTime.substring(10, 12);
309
		} else {
310

311
			return startTime.substring(0, 4) + "年" + startTime.substring(4, 6).replace(/\b(0+)/gi, "") + "月" + startTime.substring(6, 8).replace(/\b(0+)/gi, "") + "日 " + startTime.substring(8, 10) + ":" + startTime.substring(10, 12);
312
		}
313
	}
314
}
186
				
187
				shareWays();//分享方式
315 188
			})
316 189
		</script>
317 190


+ 274 - 0
e/c.html

@ -0,0 +1,274 @@
1
<!DOCTYPE html>
2
<html>
3
<head>
4
<meta charset="UTF-8">
5
<title>企业分享-科袖网</title>
6
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
7
<link rel="stylesheet" href="../css/reset.css" />
8
<link rel="stylesheet" href="../css/common.css" />
9
<link rel="stylesheet" href="../css/share.css" />
10
<style>
11
	html,body{margin:0;padding:0px;background: #F4F6F8;}
12
	.showCardI{background-image: url(../images/enterprise_img_bg_nor@3x.png)}
13
	.infocontit:before{background: #28b8fa;}
14
</style>
15
<script type="text/javascript" src="../js/jquery-1.11.1.js"></script>
16
<script type="text/javascript" src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
17
<script type="text/javascript" src="../js/public/shareCom.js"></script>		
18
</head>
19
20
<body>
21
	<div class="contentBody2">
22
	    <div class="showCardI">
23
			<div class="cardTop">
24
				<div class="cardImg cmpCard">
25
					<div class="boxBlock"><img class="boxBlockimg companyImg" id="oimg" src="../images/default-icon.jpg"></div>
26
				</div>
27
				<div class="cardInfo">
28
					<p><span class="h1Font" id="companyName"></span><em class="authicon" id="authFlag"></em></p>
29
					<p class="ellipsisSty h2Font" id="industryShow"></p>
30
					<p class="h3Font"><em class="iconfontnew icon-address"></em> <span id="address"></span></p>
31
				</div>		
32
			</div>
33
		</div>
34
		<div class="mainbox">
35
			<div class="infocontit clearfix" style="cursor: pointer;" id="goCmpBrief">企业介绍 <em></em></div>
36
			<div class="infocon">
37
				<span class="breifinfo" id="breifinfo">
38
		        </span>
39
			</div>
40
		</div>
41
		<div class="mainbox">
42
			<div class="infocontit">专注领域</div>
43
			<div class="infocon listArea">
44
				<ul id="subjectShow">
45
					
46
				</ul>
47
			</div>
48
		</div>
49
		<div class="mainbox">
50
			<div class="infocontit">资源 (<span id="resourceNum">0</span>)</div>
51
			<div class="infocon madiaBlock">
52
				<ul class="mui-table-view" id="resourceShow">
53
			    </ul>
54
			</div>
55
			<div class="seeMore displayNone" id="seeMoreResource"><em>查看更多</em></div>
56
		</div>
57
		<div class="mainbox">
58
			<div class="infocontit">文章 (<span id="articalNum">0</span>)</div>
59
			<div class="infocon madiaBlock">
60
				<ul class="mui-table-view" id="articelShow">
61
			    </ul>
62
			</div>
63
			<div class="seeMore displayNone" id="seeMoreArtical"><em>查看更多</em></div>
64
		</div>
65
	    <div class="shareEcode" style="background: #FFFFFF;">
66
	    	<div class="Ecodebox">
67
				<div class="Ecodecon clearfix">
68
					<img src="../images/weixin_code.jpg" />
69
					<div class="codecon">
70
						<h1>「 科袖 」</h1>
71
						<h2>搭建企业与专家的桥梁</h2>
72
						<h3>长按识别科袖公众号</h3>
73
					</div>
74
				</div>
75
			</div>
76
			<div style="margin:20px auto;">
77
				<a href="http://a.app.qq.com/o/simple.jsp?pkgname=com.ekexiu.app"><button class="frmbtn frmactive">下载移动客户端</button></a>
78
			</div>
79
	    </div>
80
	</div>
81
<script type="text/javascript">
82
$(document).ready(function() {
83
	var imgUrl = "http://www.ekexiu.com/images/logo180.png";
84
	var lineLink = document.location.href;
85
	var descContent;
86
	var shareTitle;
87
	var appid = '';
88
	
89
	var orgId = GetQueryString("id");
90
	//orgId = "A93B9348F2094D12A6DC9A23F16E1246";
91
	companyMessage(orgId);
92
	getArticel();
93
	getResource();
94
	shareWays();//分享方式
95
	
96
	$("body").on("click",".seeMore,#goCmpBrief",function(){
97
		location.href="http://a.app.qq.com/o/simple.jsp?pkgname=com.ekexiu.app";
98
	})
99
	$('#articelShow').on('click', 'li', function() {
100
		var id = this.getAttribute("data-id");
101
		location.href="http://" + window.location.host + "/e/a.html?id=" + id;
102
	})
103
	$('#resourceShow').on('click', 'li', function() {
104
		var id = this.getAttribute("data-id");
105
		location.href="http://" + window.location.host + "/e/r.html?id=" + id;
106
	})
107
108
	function companyMessage(id) {
109
		$.ajax({
110
			url: "../ajax/org/" + id, 
111
			dataType: 'json', //数据格式类型
112
			type: 'GET', //http请求类型
113
			timeout: 10000, //超时设置
114
			success: function(data) {
115
				if(data.success) {
116
					var $data = data.data;
117
					if($data.forShort){
118
						document.getElementById("companyName").innerText = $data.forShort;
119
					}else{
120
						document.getElementById("companyName").innerText = $data.name;
121
					}
122
					if($data.hasOrgLogo) {
123
						document.getElementById("oimg").src = "/images/org/" + $data.id + ".jpg";
124
					} else {
125
						document.getElementById("oimg").src = "../images/default-icon.jpg";
126
					}
127
					/*企业标识*/
128
					if($data.authStatus == 3) {
129
						document.getElementById("authFlag").classList.add("authicon-com-ok");
130
					}
131
					
132
					/*所在城市*/
133
					if($data.city) {
134
						document.getElementById("address").innerText = $data.city;
135
					} else {
136
						document.getElementById("address").parentNode.style.display = "none";
137
					}
138
139
					/*企业简介*/
140
					if($data.descp) {
141
						document.getElementById("breifinfo").innerText = $data.descp;
142
					}
143
					/*应用行业*/
144
					var proOther = "";
145
					if($data.industry) {
146
						proOther = $data.industry.replace(/,/gi, " | ");
147
					}
148
					document.getElementById("industryShow").innerText = proOther;
149
					/*专注领域*/
150
					if($data.subject) {
151
						indu($data.subject, 'subjectShow')
152
					} else {
153
						document.getElementById("subjectShow").parentNode.parentNode.style.display = "none";
154
					}
155
					
156
					document.title=$data.name + "-" + proOther; 
157
					//微信再次分享
158
					shareTitle = document.getElementById("companyName").innerText;
159
					descContent = document.getElementById("industryShow").innerText.substring(0,20);
160
					if(document.getElementById("oimg").src !="../images/default-icon.jpg"){
161
						imgUrl= document.getElementById("oimg").src;
162
					}
163
					
164
				}
165
			},
166
			error: function() {
167
			}
168
		});
169
	}
170
	/*应用行业及领域及企业纸质*/
171
	function indu(oString, oSelector) {
172
		var arr = oString.split(",");
173
		var oArr = new Array();
174
		var i;
175
		for(i in arr) {
176
			oArr.push('<li>' + arr[i] + '</li>');
177
		}
178
		document.getElementById(oSelector).innerHTML = oArr.join("");
179
	}
180
	//获取资源
181
	function getResource() {
182
		$.ajax({
183
			url: "../ajax/resource/pqOrgPublish",
184
			type: "GET",
185
			timeout: 10000,
186
			dataType: "json",
187
			data: {
188
				"orgId": orgId
189
			},
190
			success: function(data) {
191
				console.log(data)
192
				if(data.success) {
193
					var obj = data.data.data;
194
					if(obj.length>0){
195
						document.getElementById("resourceNum").innerText = obj.length;
196
						if(obj.length>2){
197
							obj.length =2;
198
							document.getElementById("seeMoreResource").classList.remove("displayNone");
199
						}
200
						for(var i = 0; i < obj.length; i++) {
201
							var liItem = document.createElement("li");
202
							liItem.className = "mui-table-view-cell"
203
							liItem.setAttribute("data-id",obj[i].resourceId)
204
							var oString = '<div class="flexCenter OflexCenter clearfix">'
205
							if(obj[i].images.length) {
206
								oString += '<div class="madiaHead resouseHead" style="background-image:url(../data/resource/' + obj[i].images[0].imageSrc +')"></div>'
207
							} else {
208
								oString += '<div class="madiaHead resouseHead"></div>'
209
							}
210
							oString += '<div class="madiaInfo OmadiaInfo"><p class="ellipsisSty h1Font">' + obj[i].resourceName + '</p><p class="h2Font mui-ellipsis">应用用途:' + obj[i].supportedServices + '</p>'
211
							oString += '</div></div>'
212
							liItem.innerHTML = oString;
213
							document.getElementById("resourceShow").appendChild(liItem);
214
						}
215
					}else{
216
						document.getElementById("resourceShow").parentNode.parentNode.style.display="none";
217
					}
218
				}
219
			},
220
			error: function() {
221
			}
222
		})
223
	}
224
	/*企业文章html*/
225
	function getArticel() {
226
		$.ajax({
227
			url: "../ajax/article/pqOrgPublish", 
228
			type: "GET",
229
			timeout: 10000,
230
			dataType: "json",
231
			data: {
232
				"orgId": orgId
233
			},
234
			success: function(data) {
235
				console.log(data)
236
				if(data.success) {
237
					var obj = data.data.data;
238
					if(obj.length>0){
239
						document.getElementById("articalNum").innerText = obj.length;
240
						if(obj.length>2){
241
							obj.length =2;
242
							document.getElementById("seeMoreArtical").classList.remove("displayNone");
243
						}
244
						for(var i = 0; i < obj.length; i++) {
245
							var liItem = document.createElement("li");
246
							liItem.setAttribute("data-id",obj[i].articleId);
247
							liItem.setAttribute("owner-id",obj[i].orgId);
248
							liItem.className = "mui-table-view-cell"
249
							var oString = '<div class="flexCenter OflexCenter clearfix">'
250
							if(obj[i].articleImg) {
251
								oString += '<div class="madiaHead artHead" style="background-image:url(../data/article/' + obj[i].articleImg + ')"></div>'
252
							} else {
253
								oString += '<div class="madiaHead artHead"></div>'
254
							}
255
							oString += '<div class="madiaInfo OmadiaInfo"><p class="ellipsisSty-2 h1Font">' + obj[i].articleTitle + '</p>'
256
							oString += '</div></div>'
257
							liItem.innerHTML = oString;
258
							document.getElementById("articelShow").appendChild(liItem);
259
						}
260
					}else{
261
						document.getElementById("articelShow").parentNode.parentNode.style.display="none";
262
					}
263
				}
264
			},
265
			error: function() {
266
			}
267
		})
268
	}
269
    
270
})
271
</script>
272
</body>
273
274
</html>

+ 261 - 0
e/l.html

@ -0,0 +1,261 @@
1
<!DOCTYPE html>
2
<html>
3
<head>
4
<meta charset="UTF-8">
5
<title>论文分享-科袖网</title>
6
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
7
<link rel="stylesheet" href="../css/reset.css" />
8
<link rel="stylesheet" href="../css/common.css" />
9
<link rel="stylesheet" href="../css/share.css" />
10
<style>
11
	html,body{margin:0;padding:0px;background: #FFFFFF;}
12
</style>
13
<script type="text/javascript" src="../js/jquery-1.11.1.js"></script>
14
<script type="text/javascript" src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
15
<script type="text/javascript" src="../js/public/shareCom.js"></script>	
16
</head>
17
18
<body>
19
	<div class="contentBody2">
20
	    <div class="showDetail">
21
    		<div class="h1Font hWeight" id="paperName"></div>
22
	    	<!--内容区-->
23
			<div class="showMain showMainP">
24
				<ul>
25
					<li>
26
						<div class="showTit">期刊:<span class="showCon" id="paperJournal"></span></div>
27
					</li>
28
					<li>
29
						<div class="showTit">期卷:<span class="showCon" id="paperVolume"></span></div>
30
					</li>
31
					<li>
32
						<div class="showTit">摘要:</div>
33
						<div class="showCon" id="paperAbstract">
34
							
35
						</div>
36
					</li>
37
				</ul>
38
			</div>
39
    		<!--标签模块-->
40
			<ul class="tagList">
41
				
42
			</ul>
43
			<div class="madiaBlock">
44
				<div class="madiaTit">作者</div>
45
				<ul class="mui-table-view" id="aboutAuthors">
46
			        
47
			    </ul>
48
			</div>
49
	    </div>
50
	    <div class="shareEcode">
51
	    	<div class="Ecodebox">
52
				<div class="Ecodecon clearfix">
53
					<img src="../images/weixin_code.jpg" />
54
					<div class="codecon">
55
						<h1>「 科袖 」</h1>
56
						<h2>搭建企业与专家的桥梁</h2>
57
						<h3>长按识别科袖公众号</h3>
58
					</div>
59
				</div>
60
			</div>
61
			<div style="margin:20px auto;">
62
				<a href="http://a.app.qq.com/o/simple.jsp?pkgname=com.ekexiu.app"><button class="frmbtn frmactive">下载移动客户端</button></a>
63
			</div>
64
	    </div>
65
	</div>
66
<script type="text/javascript">
67
$(document).ready(function() {
68
	var imgUrl = "http://www.ekexiu.com/images/logo180.png";
69
	var lineLink = document.location.href;
70
	var descContent;
71
	var shareTitle;
72
	var appid = '';
73
	
74
	var paperId = GetQueryString("id");
75
	getRecourceMe();/*获取信息*/
76
	shareWays();//分享方式
77
	$.ajax({
78
		"url": "../ajax/ppaper/incPageViews",
79
		"type": "POST",
80
		"dataType": "json",
81
		"data": {
82
			"id": paperId
83
		},
84
		"success": function(data) {
85
			console.log(data);
86
			if(data.success) {}
87
		},
88
		"error": function() {
89
			//$.MsgBox.Alert('提示', '链接服务器超时')
90
		}
91
	});
92
	$("#aboutAuthors").on("click","li",function(){
93
		var oDataId = $(this).attr("data-id");
94
		if(oDataId.substring(0,1)!="#"){
95
			location.href="http://" + window.location.host + "/e/p.html?id=" + oDataId;
96
		}else{
97
			location.href="javascrip:;";
98
		}
99
	})
100
	function getRecourceMe() {
101
		$.ajax({
102
			url:'../ajax/ppaper/qo',
103
			data: {
104
				'id': paperId,
105
			},
106
			dataType: 'json', //服务器返回json格式数据
107
			type: 'get', //HTTP请求类型
108
			timeout: 10000, //超时时间设置为10秒;
109
			success: function(data) {
110
				if(data.success) {
111
					var mydata = data.data;
112
					paperHtml(data.data);
113
					getPaperAuthors(data.data.id)
114
				}
115
			},
116
			error: function(e) {
117
				return;
118
			}
119
		});
120
	}
121
	function paperHtml($da) {
122
		//微信再次分享配置
123
		shareTitle = $da.name;
124
		descContent = $da.summary.substring(0,20);
125
		
126
		document.title = $da.name; 
127
		document.getElementById("paperName").innerHTML = $da.name; //名字
128
		document.getElementById("paperAbstract").innerHTML = $da.summary; //摘要内容
129
		if(!$da.cn4periodical){
130
			$da.cn4periodical=""
131
		}
132
		if(!$da.en4periodical){
133
			$da.en4periodical=""
134
		}
135
		if(!$da.cn4periodical && !$da.en4periodical){
136
			document.getElementById("paperJournal").parentNode.parentNode.style.display="none";
137
		}else{
138
			document.getElementById("paperJournal").innerHTML = $da.cn4periodical + $da.en4periodical;
139
		}
140
141
		if(!$da.pubDay){
142
			document.getElementById("paperVolume").parentNode.parentNode.style.display="none";
143
		}else{
144
			document.getElementById("paperVolume").innerHTML = $da.pubDay;
145
		}
146
		if($da.keywords != undefined && $da.keywords.length != 0 ){
147
			var subs = new Array();
148
			if($da.keywords.indexOf(',')){
149
				subs = $da.keywords.split(',');
150
			}else{
151
				subs[0] = $da.keywords;
152
			}
153
			var pstr=""
154
			if(subs.length>0){
155
				for (var i = 0; i < subs.length; i++) 
156
				{
157
					pstr+='<li><span class="h2Font">'+ subs[i] +'</span></li>'
158
				};
159
				$(".tagList").html(pstr);
160
			}else{
161
				$(".tagList").hide();
162
			}
163
		}		
164
	}
165
	/*获取论文作者信息*/
166
	function getPaperAuthors(stritrm) {
167
		$.ajax({
168
			"url":"../ajax/ppaper/authors",
169
			"type": "GET",
170
			"success": function(data) {
171
				if(data.success) {
172
					if(data.data.length>0){
173
						for(var i=0;i<data.data.length;i++){
174
							var authTy="",authTit="",baseInfo="",imgbg="../images/default-photo.jpg";
175
							if(data.data[i].professorId.substring(0, 1) != "#"){
176
								$.ajax({
177
									url:"../ajax/professor/editBaseInfo/" + data.data[i].professorId,
178
									type:"get",
179
									async:true,
180
									success:function($proData){
181
										if($proData.success){
182
											var showPro = $proData.data;
183
											if(showPro.hasHeadImage == 1) {
184
												imgbg = "/images/head/" + showPro.id + "_l.jpg";
185
											} else {
186
												imgbg = "../images/default-photo.jpg";
187
											}
188
											//认证
189
											var oSty = autho(showPro.authType,showPro.orgAuth,showPro.authStatus);
190
											authTy = oSty.sty;
191
											authTit = oSty.title;
192
											
193
											var title = showPro.title || "";
194
											var orgName = showPro.orgName || "";
195
											var office = showPro.office || "";
196
											if(orgName!=""){
197
												if(title != "") {
198
													baseInfo = title + "," + orgName;
199
												}else{
200
													if(office!=""){
201
														baseInfo = office  + "," + orgName;	
202
													}else{
203
														baseInfo = orgName;	
204
													}
205
												}
206
											}else{
207
												if(title != "") {
208
													baseInfo = title;
209
												}else{
210
													if(office!=""){
211
														baseInfo = office;	
212
													}else{
213
														baseInfo = "";	
214
													}
215
												}
216
											}
217
											var liItem = document.createElement("li");
218
											liItem.setAttribute("data-id",showPro.id);
219
											liItem.className = "mui-table-view-cell"
220
											var oString = '<div class="flexCenter mui-clearfix">'
221
											oString += '<div class="madiaHead useHead" style="background-image:url('+ imgbg +')"></div>'
222
											oString += '<div class="madiaInfo"><p><span class="h1Font">'+ showPro.name +'</span><em class="authicon '+ authTy +'" title="'+ authTit +'"></em></p>'
223
											oString += '<p class="ellipsisSty h2Font">'+ baseInfo +'</p>'
224
											oString += '</div></div>'
225
											liItem.innerHTML = oString;
226
											document.getElementById("aboutAuthors").appendChild(liItem);
227
										}
228
									}
229
								})
230
							}else{
231
								var liItem = document.createElement("li");
232
								liItem.setAttribute("data-id",data.data[i].professorId);
233
								liItem.className = "mui-table-view-cell"
234
								var oString = '<div class="flexCenter mui-clearfix">'
235
								oString += '<div class="madiaHead useHead" style="background-image:url('+ imgbg +')"></div>'
236
								oString += '<div class="madiaInfo"><p><span class="h1Font">'+ data.data[i].name  +'</span></p>'
237
								oString += '</div></div>'
238
								liItem.innerHTML = oString;
239
								document.getElementById("aboutAuthors").appendChild(liItem);
240
							}
241
							
242
						}
243
					}
244
				}
245
			},
246
			"data": {
247
				"id": stritrm
248
			},
249
			dataType: "json",
250
			'error':function() {
251
				//$.MsgBox.Alert('提示', '链接服务器超时')
252
			}
253
		});
254
	}
255
	
256
    
257
})
258
</script>
259
</body>
260
261
</html>

+ 406 - 462
e/p.html

@ -1,507 +1,451 @@
1 1
<!DOCTYPE html>
2 2
<html>
3
<head>
4
<meta charset="UTF-8">
5
<title>用户分享-科袖网</title>
6
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
7
<link rel="stylesheet" href="../css/reset.css" />
8
<link rel="stylesheet" href="../css/common.css" />
9
<link rel="stylesheet" href="../css/share.css" />
10
<style>
11
	html,body{margin:0;padding:0px;background: #F4F6F8;}
12
</style>
13
<script type="text/javascript" src="../js/jquery-1.11.1.js"></script>
14
<script type="text/javascript" src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
15
<script type="text/javascript" src="../js/public/shareCom.js"></script>		
16
</head>
3 17
4
	<head>
5
		<meta charset="UTF-8">
6
		<title></title>
7
		<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
8
		<link rel="stylesheet" href="../css/reset.css" />
9
		<link rel="stylesheet" href="../css/common.css" />
10
		<link rel="stylesheet" href="../css/share.css" />
11
		<style type="text/css">
12
			.ResImgBox:before { margin-left: 0px;}
13
		</style>
14
	</head>
15
	<body>
16
		<div class="contentBody2">
17
			<div class="blockGroup mainbox">
18
				<div class="maincon personinfo">
19
					<div class="headbox alignCenter">
20
						<div class="headimg userRadius"><img src="../images/default-photo.jpg" width="100%" class="headimg1" /></div>
21
						<div class="listtit"><span class="personalMaterial" style="position: relative;"></span><em class="authiconNew" id="nameli"></em></div>
22
						<p class="listtit3"><span class="personalMaterial"></span><span class="personalMaterial"></span></p>
23
						<p class="listtit3"><span class="personalMaterial"></span><span class="personalMaterial"> </span> <span class="personalMaterial"></span></p>
24
					</div>
25
				</div>
26
				<ul>
27
					<li>
28
						<a class="mui-navigate-right clearfix peolevelbox " id="accessHistory">
29
							<div class="pull-left peocountbox">
30
								<div class="peocount clearfix">
31
									<em class="dialogicon pull-left "></em>
32
									<span class="pull-left">已完成咨询<em class="consultCount"></em>次</span>
33
								</div>
34
							</div>
35
							<div class="rightword levelbox pull-right ">
36
								<span class="iconfont  start"></span>
37
								<!--无色星星icon-favor  黄色星icon-favorfill-->
38
								<span class="iconfont  start"></span>
39
								<span class="iconfont icon-favor start"></span>
40
								<span class="iconfont icon-favor start"></span>
41
								<span class="iconfont icon-favor start"></span>
42
							</div>
18
<body>
19
	<div class="contentBody2">
20
	    <div class="showCardI">
21
			<div class="cardTop">
22
				<div class="cardImg userCard" id="proHead"></div>
23
				<div class="cardInfo">
24
					<p><span class="h1Font" id="proName"></span><em class="authiconNew" title="" id="proAuth"></em></p>
25
					<p class="ellipsisSty h2Font"id="proOther"></p>
26
					<p class="h3Font"><em class="mui-icon iconfontnew icon-address"></em> <span id="proAddress"></span></p>
27
				</div>		
28
			</div>
29
		</div>
30
		<div class="mainbox">
31
			<div class="infocontit mui-clearfix" style="cursor: pointer;" id="goCmpBrief">个人介绍 <em></em></div>
32
			<div class="infocon">
33
				<span class="breifinfo" id="breifinfo">
34
        		</span>
35
			</div>
36
		</div>
37
		<div class="mainbox">
38
			<div class="infocontit">学术领域</div>
39
			<div class="infocon listArea">
40
				<ul id="subjectShow">
41
					
42
				</ul>
43
			</div>
44
		</div>
45
		<div class="mainbox">
46
			<div class="infocontit">研究方向</div>
47
			<div class="infocon reserachMess">
43 48
44
						</a>
45
					</li>
49
			</div>
50
		</div>
51
		<div class="mainbox">
52
			<div class="infocontit">行业领域</div>
53
			<div class="infocon listArea">
54
				<ul id="industryShow">
55
					
46 56
				</ul>
47 57
			</div>
48
			<div class="blockGroup mainbox" id="professorresourceList">
49
				<div class="maincon">
50
					<div class="infocontit">合作资源</div>
51
					<div class="infocon" style="padding:10px 0;">
52
						<ul class="listitembox resinfo" id="resourceList">
53
						</ul>
54
					</div>
55
				</div>
58
		</div>
59
		<div class="mainbox">
60
			<div class="infocontit">资源 (<span id="resourceNum">0</span>)</div>
61
			<div class="infocon madiaBlock">
62
				<ul class="mui-table-view" id="resourceShow">
63
			    </ul>
56 64
			</div>
57
			<div class="blockGroup mainbox" id="professorBreifinfo">
58
				<div class="maincon">
59
					<div class="infocontit">个人简介</div>
60
					<div class="infocon">
61
						<span class="breifinfo">
62
                </span>
63
					</div>
64
				</div>
65
			<div class="seeMore displayNone" id="seeMoreResource"><em>查看更多</em></div>
66
		</div>
67
		<div class="mainbox">
68
			<div class="infocontit">专利 (<span id="patentNum">0</span>)</div>
69
			<div class="infocon madiaBlock">
70
				<ul class="mui-table-view" id="patentShow">
71
			    </ul>
65 72
			</div>
66
			<div class="blockGroup mainbox" id="professorInfosubject">
67
				<div class="maincon">
68
					<div class="infocontit">学术领域</div>
69
					<div class="infocon">
70
						<ul class="infosubject">
71
						</ul>
72
					</div>
73
				</div>
73
			<div class="seeMore displayNone" id="seeMorePatent"><em>查看更多</em></div>
74
		</div>
75
		<div class="mainbox">
76
			<div class="infocontit">论文 (<span id="paperNum">0</span>)</div>
77
			<div class="infocon madiaBlock">
78
				<ul class="mui-table-view" id="paperShow">
79
			    </ul>
74 80
			</div>
75
			<div class="blockGroup mainbox" id="professorReserachMess">
76
				<div class="maincon">
77
					<div class="infocontit">研究方向</div>
78
					<div class="infocon reserachMess">
79
						
80
					</div>
81
				</div>
81
			<div class="seeMore displayNone" id="seeMorePaper"><em>查看更多</em></div>
82
		</div>
83
		<div class="mainbox">
84
			<div class="infocontit">文章 (<span id="articalNum">0</span>)</div>
85
			<div class="infocon madiaBlock">
86
				<ul class="mui-table-view" id="articelShow">
87
			    </ul>
82 88
			</div>
83
			<div class="blockGroup mainbox" id="professorinfoapply">
84
				<div class="maincon">
85
					<div class="infocontit">应用行业</div>
86
					<div class="infocon">
87
						<ul class="infoapply">
88
						</ul>
89
			<div class="seeMore displayNone" id="seeMoreArtical"><em>查看更多</em></div>
90
		</div>
91
	    <div class="shareEcode" style="background: #FFFFFF;">
92
	    	<div class="Ecodebox">
93
				<div class="Ecodecon clearfix">
94
					<img src="../images/weixin_code.jpg" />
95
					<div class="codecon">
96
						<h1>「 科袖 」</h1>
97
						<h2>搭建企业与专家的桥梁</h2>
98
						<h3>长按识别科袖公众号</h3>
89 99
					</div>
90 100
				</div>
91 101
			</div>
92
93
			<div class="blockGroup mainbox" style="padding-bottom:40px;">
94
				<div class="maincon alignCenter">
95
					<div style="margin-top: 30px;"><span style="color:#ff9900; font-size: 16px;line-height: 32px;">「 科袖 」</span><br />搭建企业与专家的桥梁</div>
96
					<div class="frmbox" style="margin:20px auto;">
97
						<a href="http://a.app.qq.com/o/simple.jsp?pkgname=com.ekexiu.app"><button class="frmbtn frmactive">下载移动客户端</button></a>
98
					</div>
99
					<div>
100
						<img style="width:120px;" src="../images/weixin_code.jpg" />
101
						<div style="color:#CCCCCC;font-size:13px;">关注科袖公众号</div>
102
					</div>
103
				</div>
102
			<div style="margin:20px auto;">
103
				<a href="http://a.app.qq.com/o/simple.jsp?pkgname=com.ekexiu.app"><button class="frmbtn frmactive">下载移动客户端</button></a>
104 104
			</div>
105
		</div>
106
		<script type="text/javascript" src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
107
		<script type="text/javascript" src="../js/jquery-1.11.1.js"></script>
108
		<script>
109
			//获取URL ID函数
105
	    </div>
106
	</div>
107
<script type="text/javascript">
108
$(document).ready(function() {
109
	var imgUrl = "http://www.ekexiu.com/images/logo180.png";
110
	var lineLink = document.location.href;
111
	var descContent;
112
	var shareTitle;
113
	var appid = '';
114
	
115
	var proId = GetQueryString("id");
116
	//proId = "91E3F49CE63B43EEBA0C68B6DD7F0A19";
117
	userMessage(proId);
118
	getArticel();
119
	getResource();
120
	getPaper();
121
	getPatent();
122
	shareWays();//分享方式
123
	
124
	$("body").on("click",".seeMore,#goCmpBrief",function(){
125
		location.href="http://a.app.qq.com/o/simple.jsp?pkgname=com.ekexiu.app";
126
	})
127
	$('#articelShow').on('click', 'li', function() {
128
		var id = this.getAttribute("data-id");
129
		location.href="http://" + window.location.host + "/e/a.html?id=" + id;
130
	})
131
	$('#resourceShow').on('click', 'li', function() {
132
		var id = this.getAttribute("data-id");
133
		location.href="http://" + window.location.host + "/e/r.html?id=" + id;
134
	})
135
	$('#paperShow').on('click', 'li', function() {
136
		var id = this.getAttribute("data-id");
137
		location.href="http://" + window.location.host + "/e/l.html?id=" + id;
138
	})
139
	$('#patentShow').on('click', 'li', function() {
140
		var id = this.getAttribute("data-id");
141
		location.href="http://" + window.location.host + "/e/z.html?id=" + id;
142
	})
110 143
111
			$(document).ready(function() {
112
				var imgUrl = "http://www.ekexiu.com/images/logo180.png";
113
				var lineLink = document.location.href;
114
				var descContent="研究方向:";
115
				var shareTitle="";
116
				var appid = '';
117
				var personalMaterial = document.getElementsByClassName('personalMaterial');
118
				var nameli = document.getElementById("nameli");
119
				var personSummary = document.getElementsByClassName("breifinfo")[0];
120
				var professorId = GetQueryString("id");
121
			$.ajax({
122
			"url": "/ajax/resource/qaProPublish",
123
			"type": "get",
124
			"data": {
125
				"professorId": professorId,
126
			},
127
			"success": function(data) {
144
	function userMessage(id) {
145
		$.ajax({
146
			type:"get",
147
			url:"/ajax/professor/info/"+ proId,
148
			async:true,
149
			success: function(data) {
150
				var $info = data.data;
128 151
				if(data.success) {
129
					console.log(data)
130
					var $data=data.data
131
					if($data.length) {
132
								professorResource($data);
133
							} else {
134
								document.getElementById("professorresourceList").style.display = "none";
152
					if($info.hasHeadImage){
153
						$("#proHead").css("background-image","url(/images/head/"+ $info.id +"_l.jpg)");
154
					}
155
					$("#proName").text($info.name);
156
					var oStyS=autho($info.authType,$info.orgAuth,$info.authStatus);
157
					$("#proAuth").addClass(oStyS.sty); $("#proAuth").attr("title",oStyS.title);
158
					if($info.address){
159
						$("#proAddress").html($info.address);
160
					}
161
					var proOther="";
162
					if($info.orgName){
163
						if($info.department){
164
							if($info.title){
165
								proOther = $info.title + "," + $info.department + "," + $info.orgName
166
							}else{
167
								if($info.office){
168
									proOther = $info.office + "," + $info.department + "," + $info.orgName
169
								}else{
170
									proOther = $info.department + "," + $info.orgName
171
								}
135 172
							}
173
						}else{
174
							proOther = $info.orgName
136 175
						}
176
					}
177
					$("#proOther").text(proOther);
178
					var llqtitle=$info.name + "-" + proOther.replace(/,/gi,"-");//修改浏览器title信息
179
					document.title = llqtitle;
180
181
					//个人简介
182
					if($info.descp) {
183
						$("#breifinfo").text($info.descp);
184
					}
185
					//学术领域					
186
					if($info.subject) {
187
						indu($info.subject, 'subjectShow')
188
					} else {
189
						document.getElementById("subjectShow").parentNode.parentNode.style.display = "none";
190
					}
191
					//研究方向
192
					if($info.researchAreas.length) {
193
						researchAreaShow($info.researchAreas, $info.editResearchAreaLogs);
194
					} else {
195
						document.getElementById("subjectShow").parentNode.parentNode.style.display = "none";
196
					}
197
					//行业领域	
198
					if($info.industry) {
199
						indu($info.industry, 'industryShow')
200
					} else {
201
						document.getElementById("industryShow").parentNode.parentNode.style.display = "none";
202
					}
203
204
					//微信再次分享
205
					shareTitle = document.getElementById("proName").innerText;
206
					descContent = document.getElementById("subjectShow").innerText.substring(0,20);
207
					
208
				}
137 209
			},
138
			"error": function() {
139
				$.MsgBox.Alert('提示', '链接服务器超时')
210
			error: function() {
140 211
			}
141 212
		});
142
				
143
							
144
				function GetQueryString(name) {
145
					var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
146
					var r = window.location.search.substr(1).match(reg);
147
					var context = "";
148
					if(r != null)
149
						context = r[2];
150
					reg = null;
151
					r = null;
152
					return context == null || context == "" || context == "undefined" ? "" : decodeURI(context);
213
	}
214
	//查询研究方向	
215
	var getRecords = function($researchAreaLogs, caption) {
216
		var ret = [];
217
		var t = 0;
218
		for(var i = 0; i < $researchAreaLogs.length; i++) {
219
			if(caption == $researchAreaLogs[i].caption) {
220
				ret[t] = {
221
					id: $researchAreaLogs[i].opreteProfessorId,
222
					img: $researchAreaLogs[i].hasHeadImage
153 223
				}
154
					//查询学术领域
155
				var subjectShow = function(data) {
156
						if(data != undefined && data.length != 0) {
157
							var subs = new Array();
158
							if(data.indexOf(',')) {
159
								subs = data.split(',');
160
							} else {
161
								subs[0] = data;
162
							}
163
							if(subs.length > 0) {
164
								var html = [];
165
								for(var i = 0; i < subs.length; i++) {
166
									html.push("<li>" + subs[i] + "</li>");
167
								};
168
								document.getElementsByClassName("infosubject")[0].innerHTML = html.join('');
169
							}
170
						}
171
					}
172
					//查询研究方向	
173
				var getRecords = function($researchAreaLogs, caption) {
174
					var ret = [];
175
					var t = 0;
176
					for(var i = 0; i < $researchAreaLogs.length; i++) {
177
						if(caption == $researchAreaLogs[i].caption) {
178
							ret[t] = {
179
								id: $researchAreaLogs[i].opreteProfessorId,
180
								img: $researchAreaLogs[i].hasHeadImage
181
							}
182
							t++;
183
						}
184
					}
185
					return ret;
224
				t++;
225
			}
226
		}
227
		return ret;
228
	}
229
	var resear = "";
230
	var researchAreaShow = function($datas, $datarecords) {
231
		if($datas != undefined && $datas.length != 0) {
232
			var html = [];
233
			for(var i = 0; i < $datas.length; ++i) {
234
				var $data = $datas[i];
235
				var $photos = [];
236
				//获取头像					
237
				if($datarecords.length > 0) {
238
					$photos = getRecords($datarecords, $data.caption);
186 239
				}
187
				var researchAreaShow = function($datas, $datarecords) {
188
						if($datas != undefined && $datas.length != 0) {
189
							var html = [];
190
							for(var i = 0; i < $datas.length; ++i) {
191
								var $data = $datas[i];
192
								var $photos = [];
193
								//获取头像					
194
								if($datarecords.length > 0) {
195
									$photos = getRecords($datarecords, $data.caption);
196
								}
197
								
198
								descContent += " " + $data.caption;
199
								var showDiv = "<div class='listbox'><div class='listbrowse mui-ellipsis'><span class='like'>" + $data.count + "</span>" + $data.caption + "</div><div class='likenum'>";
200
201
								if($photos.length < 4) {
202
									for(var j = 0; j < $photos.length; ++j) {
203
										if($photos[j].img) {
204
											showDiv += "<span class='likepeople userRadius'><img class='like-h' src='../images/head/" + $photos[j].id + "_m.jpg'></span>";
205
										} else {
206
											showDiv += "<span class='likepeople userRadius'><img class='like-h' src='../images/default-photo.jpg'></span>";
207
										}
208
									}
209
								} else {
210
									for(var j = $photos.length - 2; j < $photos.length; ++j) {
211
										if($photos[j].img) {
212
											showDiv += "<span class='likepeople userRadius'><img class='like-h' src='../images/head/" + $photos[j].id + "_m.jpg'></span>";
213
										} else {
214
											showDiv += "<span class='likepeople userRadius'><img class='like-h' src='../images/default-photo.jpg'></span>";
215
										}
216
									}
217
									showDiv += "<span class='mui-icon iconfont icon-more likepeople likemore userRadius'></span>";
218
								}
219
								showDiv += "</div></div></div>";
220
								html.push(showDiv);
221
							}
222
							document.getElementsByClassName("reserachMess")[0].innerHTML = html.join('')
240
				var showDiv = "<div class='listbox'><div class='listbrowse ellipsisSty'dataCaption="+$data.caption+"><span class='like'>" + $data.count + "</span>" + $data.caption + "</div><div class='likenum' dataCaption="+$data.caption+">"
241
				
242
				if($photos.length < 4) {
243
					for(var j = 0; j < $photos.length; ++j) {
244
						if($photos[j].img) {
245
							showDiv += "<span class='likepeople userRadius'><img class='like-h' src='../images/head/" + $photos[j].id + "_m.jpg'></span>";
246
						} else {
247
							showDiv += "<span class='likepeople userRadius'><img class='like-h' src='../images/default-photo.jpg'></span>";
223 248
						}
224 249
					}
225
					//查询应用行业		
226
				var industryShow = function(data) {
227
					if(data != undefined && data.length != 0) {
228
						var subs = new Array();
229
						if(data.indexOf(',')) {
230
							subs = data.split(',');
250
				} else {
251
					for(var j = $photos.length - 2; j < $photos.length; ++j) {
252
						if($photos[j].img) {
253
							showDiv += "<span class='likepeople userRadius'><img class='like-h' src='../images/head/" + $photos[j].id + "_m.jpg'></span>";
231 254
						} else {
232
							subs[0] = data;
233
						}
234
						if(subs.length > 0) {
235
							var html = [];
236
							for(var i = 0; i < subs.length; i++) {
237
								html.push("<li>" + subs[i] + "</li>");
238
							};
239
							document.getElementsByClassName("infoapply")[0].innerHTML = html.join('');
255
							showDiv += "<span class='likepeople userRadius'><img class='like-h' src='../images/default-photo.jpg'></span>";
240 256
						}
241 257
					}
258
					showDiv += "<span class='mui-icon iconfont icon-more likepeople likemore userRadius'></span>";
242 259
				}
243
				var professorResource = function(odata) {
244
						var $data = odata;
245
						var html = [];
246
						for(var i = 0; i < odata.length; i++) {
247
							var string = '<li class="listitem">'
248
							string += '<div class="proinfor clearfix">'
249
							string += '<div class="media-object pull-left ResImgBox">'
250
							if($data[i].images.length) {
251
								string += '<img class="resImg headRadius" src="../data/resource/' + $data[i].images[0].imageSrc+ '">'
252
260
				showDiv += "</div></div></div>";
261
				html.push(showDiv);
262
				resear += (i + 1) + "." + $data.caption + " ";
263
			}
264
			document.getElementsByClassName("reserachMess")[0].innerHTML = html.join('')
265
		}
266
	}
267
	/*应用行业及领域及企业纸质*/
268
	function indu(oString, oSelector) {
269
		var arr = oString.split(",");
270
		var oArr = new Array();
271
		var i;
272
		for(i in arr) {
273
			oArr.push('<li>' + arr[i] + '</li>');
274
		}
275
		document.getElementById(oSelector).innerHTML = oArr.join("");
276
	}
277
	//获取资源
278
	function getResource() {
279
		$.ajax({
280
			url: "../ajax/resource/pqProPublish",
281
			type: "GET",
282
			timeout: 10000,
283
			dataType: "json",
284
			data: {
285
				"professorId": proId,
286
			},
287
			success: function(data) {
288
				console.log(data)
289
				if(data.success) {
290
					var obj = data.data.data;
291
					if(obj.length>0){
292
						document.getElementById("resourceNum").innerText = obj.length;
293
						if(obj.length>2){
294
							obj.length =2;
295
							document.getElementById("seeMoreResource").classList.remove("displayNone");
296
						}
297
						for(var i = 0; i < obj.length; i++) {
298
							var liItem = document.createElement("li");
299
							liItem.className = "mui-table-view-cell"
300
							liItem.setAttribute("data-id",obj[i].resourceId)
301
							var oString = '<div class="flexCenter OflexCenter clearfix">'
302
							if(obj[i].images.length) {
303
								oString += '<div class="madiaHead resouseHead" style="background-image:url(../data/resource/' + obj[i].images[0].imageSrc +')"></div>'
253 304
							} else {
254
255
								string += '<img class="resImg headRadius" src="../images/default-resource.jpg">'
305
								oString += '<div class="madiaHead resouseHead"></div>'
256 306
							}
257
							string += '</div>'
258
							string += '<div class="pull-left media-body">'
259
							string += '<span class="listtit">' + $data[i].resourceName + '</span>'
260
							string += '<p class="listtit2">' + $data[i].supportedServices + '</p>'
261
//							string += '<p class="listtit3 resbrief">'
262
//							if($data[i].descp) {
263
//								string += $data[i].descp;
264
//							}
265
//							string += '</p>'
266
							string += '</div></div></li>'
267
							
268
							html.push(string);
307
							oString += '<div class="madiaInfo OmadiaInfo"><p class="ellipsisSty h1Font">' + obj[i].resourceName + '</p>'
308
							oString += '<p class="h2Font ellipsisSty">应用用途:' + obj[i].supportedServices + '</p>'
309
							oString += '</div></div>'
310
							liItem.innerHTML = oString;
311
							document.getElementById("resourceShow").appendChild(liItem);
269 312
						}
270
						document.getElementById("resourceList").innerHTML = html.join('');
271
313
					}else{
314
						document.getElementById("resourceShow").parentNode.parentNode.style.display="none";
272 315
					}
273
					/*获取个人信息*/
274
				function personalMessage() {
275
					$.ajax({
276
						url: "../ajax/professor/info/" + professorId,
277
						dataType: 'json', //数据格式类型
278
						type: 'GET', //http请求类型
279
						async:false,
280
						timeout: 10000, //超时设置
281
						success: function(data) {
282
							var $data = data.data;
283
							personalMaterial[0].innerText = $data.name;
284
							
285
							//title标题栏
286
							if(!$data.title){
287
								$data.title="";
288
							}
289
							shareTitle = "【科袖名片】" + $data.name + " " + $data.title + "";
290
							window.setTimeout(function() {
291
								document.title = "【科袖名片】" + $data.name + " " + $data.title + "";
292
							}, 500);
293
							
294
							//基本信息
295
							if($data.consultCount) {
296
								document.getElementsByClassName("consultCount")[0].innerText = $data.consultCount;
297
							} else {
298
								document.getElementById("accessHistory").style.display = "none";
299
							}
300
							var startLeval = parseInt($data.starLevel);
301
							var start = document.getElementsByClassName("start");
302
							for(var i = 0; i < startLeval; i++) {
303
								start[i].classList.add("icon-favorfill");
304
								start[i].classList.remove("icon-favor");
305
							}
306
							if($data.hasHeadImage) {
307
								document.getElementsByClassName("headimg1")[0].src = "../images/head/" + $data.id + "_l.jpg";
308
							} else {
309
								document.getElementsByClassName("headimg1")[0].src = "../images/default-photo.jpg";
310
							}
311
							//认证
312
							var oStyT=autho($data.authType,$data.orgAuth,$data.authStatus);
313
							nameli.classList.add(oStyT.sty);
314
							nameli.setAttribute("title",oStyT.title);
315
							
316
							if($data.office) {
317
								if($data.title) {
318
									personalMaterial[1].innerText = $data.office + ",";
319
								} else {
320
									personalMaterial[1].innerText = $data.office;
321
								}
322
							}
323
							if($data.title) {
324
								personalMaterial[2].innerText = $data.title;
325
							}
326
							if($data.orgName) {
327
								if($data.department) {
328
									personalMaterial[3].innerText = $data.orgName + " , ";
329
								} else {
330
									if($data.address) {
331
										personalMaterial[3].innerText = $data.orgName + " | ";
332
									} else {
333
										personalMaterial[3].innerText = $data.orgName;
334
									}
335
								}
336
337
							}
338
							if($data.department) {
339
								if($data.address) {
340
									personalMaterial[4].innerText = $data.department + " | ";
341
								} else {
342
									personalMaterial[4].innerText = $data.department;
343
								}
344
345
							}
346
							if($data.address) {
347
								personalMaterial[5].innerText = $data.address;
348
							}
349
							//个人简介
350
351
							if($data.descp) {
352
								personSummary.innerHTML = $data.descp;
353
							} else {
354
								document.getElementById("professorBreifinfo").style.display = "none";
355
							}
356
							//学术领域
357
							if($data.subject) {
358
								subjectShow($data.subject);
359
							} else {
360
								document.getElementById("professorInfosubject").style.display = "none";
361
							}
362
							//研究方向
363
							if($data.researchAreas.length) {
364
365
								researchAreaShow($data.researchAreas, $data.editResearchAreaLogs);
366
							
367
							} else {
368
								document.getElementById("professorReserachMess").style.display = "none";
369
							}
370
							//应用行业
371
							if($data.industry) {
372
								industryShow($data.industry);
373
							} else {
374
								document.getElementById("professorinfoapply").style.display = "none";
375
							}
376
							//专家资源
377
							/*if($data.resources.length) {
378
								professorResource($data.resources);
316
				}
317
			},
318
			error: function() {
319
			}
320
		})
321
	}
322
	/*企业文章html*/
323
	function getArticel() {
324
		$.ajax({
325
			url: "../ajax/article/pqProPublish", 
326
			type: "GET",
327
			timeout: 10000,
328
			dataType: "json",
329
			data: {
330
				"professorId": proId,
331
			},
332
			success: function(data) {
333
				console.log(data)
334
				if(data.success) {
335
					var obj = data.data.data;
336
					if(obj.length>0){
337
						document.getElementById("articalNum").innerText = obj.length;
338
						if(obj.length>2){
339
							obj.length =2;
340
							document.getElementById("seeMoreArtical").classList.remove("displayNone");
341
						}
342
						for(var i = 0; i < obj.length; i++) {
343
							var liItem = document.createElement("li");
344
							liItem.setAttribute("data-id",obj[i].articleId);
345
							liItem.setAttribute("owner-id",obj[i].orgId);
346
							liItem.className = "mui-table-view-cell"
347
							var oString = '<div class="flexCenter OflexCenter clearfix">'
348
							if(obj[i].articleImg) {
349
								oString += '<div class="madiaHead artHead" style="background-image:url(../data/article/' + obj[i].articleImg + ')"></div>'
379 350
							} else {
380
								document.getElementById("professorresourceList").style.display = "none";
381
							}*/
382
							/*//如无详细内容数据,隐藏详细点击的按钮
383
							if(!$data.edus.length && !$data.jobs.length && !$data.projects.length && !$data.papers.length && !$data.patents.length && !$data.honors.length) {
384
								document.getElementById("detailProfessor").style.display = "none";
351
								oString += '<div class="madiaHead artHead"></div>'
385 352
							}
386
							*/
387
							
388
							
389
						},
390
						error: function(e) {
391
							return;
353
							oString += '<div class="madiaInfo OmadiaInfo"><p class="ellipsisSty-2 h1Font">' + obj[i].articleTitle + '</p>'
354
							oString += '</div></div>'
355
							liItem.innerHTML = oString;
356
							document.getElementById("articelShow").appendChild(liItem);
392 357
						}
393
					});
358
					}else{
359
						document.getElementById("articelShow").parentNode.parentNode.style.display="none";
360
					}
394 361
				}
395
				personalMessage()
396
	
397
				/*微信分享*/
398
				$.ajax({
399
					url: "../ajax/weixin/jsapiTicket",
400
					type: 'get',
401
					dataType: 'json',
402
					contentType: "application/x-www-form-urlencoded; charset=utf-8",
403
					data: {
404
						'url': location.href.split('#')[0]
405
					},
406
					success: function(data) {
407
						if(data.data) {
408
							wx.config({
409
								debug: false, //调试模式好犀利
410
								appId: data.data.appId,
411
								timestamp: data.data.timestamp,
412
								nonceStr: data.data.nonceStr,
413
								signature: data.data.signature,
414
								jsApiList: [ // 所有要调用的 API 都要加到这个列表中
415
									"onMenuShareAppMessage",
416
									"onMenuShareTimeline",
417
									"onMenuShareQQ",
418
									"onMenuShareQZone",
419
									"scanQRCode",
420
								]
421
							});
422
423
							wx.ready(function() {
424
								// 在这里调用 API
425
								wx.onMenuShareAppMessage({ //分享给朋友
426
									title: shareTitle, // 分享标题
427
									desc: descContent, // 分享描述
428
									link: lineLink, // 分享链接
429
									imgUrl: imgUrl, // 分享图标
430
									success: share_success_callback,
431
									cancel: share_cancel_callback
432
								});
433
434
								wx.onMenuShareTimeline({ //分享到朋友圈
435
									title: shareTitle, // 分享标题
436
									desc: descContent, // 分享描述
437
									link: lineLink, // 分享链接
438
									imgUrl: imgUrl, // 分享图标
439
									success: share_success_callback,
440
									cancel: share_cancel_callback
441
								});
442
443
								wx.onMenuShareQQ({ //分享到QQ
444
									title: shareTitle, // 分享标题
445
									desc: descContent, // 分享描述
446
									link: lineLink, // 分享链接
447
									imgUrl: imgUrl, // 分享图标
448
									success: share_success_callback,
449
									cancel: share_cancel_callback
450
								});
451
452
								wx.onMenuShareQZone({ //分享到QQ空间
453
									title: shareTitle, // 分享标题
454
									desc: descContent, // 分享描述
455
									link: lineLink, // 分享链接
456
									imgUrl: imgUrl, // 分享图标
457
									success: share_success_callback,
458
									cancel: share_cancel_callback
459
								});
460
461
							});
462
463
							//分享成功后的回调函数	
464
							function share_success_callback() {}
465
466
							//用户取消分享后执行的回调函数	
467
							function share_cancel_callback() {}
468
362
			},
363
			error: function() {
364
			}
365
		})
366
	}
367
	function getPaper() {
368
		$.ajax({
369
			url: "../ajax/ppaper/byProfessor", 
370
			type: "GET",
371
			timeout: 10000,
372
			dataType: "json",
373
			data: {
374
				"id": proId,
375
			},
376
			success: function(data) {
377
				console.log(data)
378
				if(data.success) {
379
					var obj = data.data.data;
380
					if(obj.length>0){
381
						document.getElementById("paperNum").innerText = obj.length;
382
						if(obj.length>2){
383
							obj.length =2;
384
							document.getElementById("seeMorePaper").classList.remove("displayNone");
469 385
						}
470
386
						for(var i = 0; i < obj.length; i++) {
387
							var liItem = document.createElement("li");
388
							liItem.setAttribute("data-id",obj[i].id);
389
							liItem.className = "mui-table-view-cell"
390
							var oString = '<div class="flexCenter OflexCenter clearfix">'
391
							oString += '<div class="madiaHead paperHead"></div>'
392
							oString += '<div class="madiaInfo OmadiaInfo"><p class="ellipsisSty h1Font">' + obj[i].name + '</p>'
393
							oString += '<p class="ellipsisSty h2Font">作者:' + obj[i].authors + '</p>'
394
							oString += '</div></div>'
395
							liItem.innerHTML = oString;
396
							document.getElementById("paperShow").appendChild(liItem);
397
						}
398
					}else{
399
						document.getElementById("paperShow").parentNode.parentNode.style.display="none";
471 400
					}
472
				});
473
				/*标志*/
474
				function autho() {
475
					if(arguments[0] == 1) {
476
						return {
477
							"sty": "authicon-pro",
478
							"title": "科袖认证专家"
401
				}
402
			},
403
			error: function() {
404
			}
405
		})
406
	}
407
    function getPatent() {
408
		$.ajax({
409
			url: "../ajax/ppatent/byProfessor", 
410
			type: "GET",
411
			timeout: 10000,
412
			dataType: "json",
413
			data: {
414
				"id": proId,
415
			},
416
			success: function(data) {
417
				console.log(data)
418
				if(data.success) {
419
					var obj = data.data.data;
420
					if(obj.length>00){
421
						document.getElementById("patentNum").innerText = obj.length;
422
						if(obj.length>2){
423
							obj.length =2;
424
							document.getElementById("seeMorePatent").classList.remove("displayNone");
479 425
						}
480
					} else {
481
						if(arguments[1] == 1) {
482
							return {
483
								"sty": "authicon-staff-ok",
484
								"title": "企业认证员工"
485
							}
486
						} else {
487
							if(arguments[2] == 3) {
488
								return {
489
									"sty": "authicon-real",
490
									"title": "实名认证用户"
491
								}
492
							} else {
493
								return {
494
									"sty": "e",
495
									"title": " "
496
								}
497
							}
426
						for(var i = 0; i < obj.length; i++) {
427
							var liItem = document.createElement("li");
428
							liItem.setAttribute("data-id",obj[i].id);
429
							liItem.className = "mui-table-view-cell"
430
							var oString = '<div class="flexCenter OflexCenter clearfix">'
431
							oString += '<div class="madiaHead patentHead"></div>'
432
							oString += '<div class="madiaInfo OmadiaInfo"><p class="ellipsisSty h1Font">' + obj[i].name + '</p>'
433
							oString += '<p class="ellipsisSty h2Font">发明人:' + obj[i].authors + '</p>'
434
							oString += '</div></div>'
435
							liItem.innerHTML = oString;
436
							document.getElementById("patentShow").appendChild(liItem);
498 437
						}
438
					}else{
439
						document.getElementById("patentShow").parentNode.parentNode.style.display="none";
499 440
					}
500 441
				}
501
				
502
			})
503
		</script>
504
505
	</body>
442
			},
443
			error: function() {
444
			}
445
		})
446
	}
447
})
448
</script>
449
</body>
506 450
507 451
</html>

+ 35 - 126
e/r.html

@ -13,7 +13,7 @@
13 13
<script type="text/javascript" src="../js/jquery-1.11.1.js"></script>
14 14
<script type="text/javascript" src="../js/public/swiper.min.js"></script>
15 15
<script type="text/javascript" src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
16
	
16
<script type="text/javascript" src="../js/public/shareCom.js"></script>	
17 17
</head>
18 18
19 19
<body>
@ -36,8 +36,8 @@
36 36
				            <div class="flexCenter mui-clearfix" id="thisInfo">
37 37
				                <div class="madiaHead" id="thisPic"></div>
38 38
								<div class="madiaInfo">
39
									<p><span class="h1Font mui-ellipsis" id="thisName"></span><em class="authiconNew" title="" id="authFlag"></em></p>
40
									<p class="h3Font mui-ellipsis" id="thisOther"></p>
39
									<p><span class="h1Font ellipsisSty" id="thisName"></span><em class="authiconNew" title="" id="authFlag"></em></p>
40
									<p class="h3Font ellipsisSty" id="thisOther"></p>
41 41
								</div>
42 42
				            </div>
43 43
				        </li>
@ -114,22 +114,37 @@ $(document).ready(function() {
114 114
	var operformancePa = document.getElementById("performancePa"); //性能参数
115 115
	var oremarkContent = document.getElementById("remarkContent"); //合作备注
116 116
	var odetailDescp = document.getElementById("detailDescp"); //详细描述
117
	getRecourceMe();/*获取资源信息*/
117
	getRecourceMe();/*获取信息*/
118
	shareWays();//分享方式
119
118 120
	$.ajax({
119
			"url": "/ajax/resource/pageViews",
120
			"type": "POST",
121
			"dataType": "json",
122
			"data": {
123
				"resourceId": resourceId
124
			},
125
			"success": function(data) {
126
				console.log(data);
127
				if(data.success) {}
128
			},
129
			"error": function() {
130
				//$.MsgBox.Alert('提示', '链接服务器超时')
131
			}
132
		});
121
		"url": "/ajax/resource/pageViews",
122
		"type": "POST",
123
		"dataType": "json",
124
		"data": {
125
			"resourceId": resourceId
126
		},
127
		"success": function(data) {
128
			console.log(data);
129
			if(data.success) {}
130
		},
131
		"error": function() {
132
			//$.MsgBox.Alert('提示', '链接服务器超时')
133
		}
134
	});
135
	//进入发布者详情页面
136
	$("#thisInfo").on("click", function() {
137
		var reType = this.getAttribute("data-type");
138
		if(reType=="1"){
139
			var proId=this.getAttribute("data-id");
140
			location.href="http://" + window.location.host + "/e/p.html?id=" + proId;
141
		}else{
142
			var cmpId=this.getAttribute("data-id");
143
			location.href="http://" + window.location.host + "/e/c.html?id=" + cmpId;
144
		}
145
			
146
	})
147
	
133 148
	function getRecourceMe() {
134 149
		$.ajax({
135 150
			url:'../ajax/resource/queryOne',
@ -224,7 +239,7 @@ $(document).ready(function() {
224 239
						for(var i = 0; i < oSub.length; i++) {
225 240
							oSt += '<li><span class="h2Font">' + oSub[i] + '</span></li>'
226 241
						}
227
						$(".tagList").innerHTML = oSt;
242
						$(".tagList").html(oSt);
228 243
					} 
229 244
					console.log(mydata.images.length)
230 245
					if(mydata.images.length!=0) {
@ -253,113 +268,7 @@ $(document).ready(function() {
253 268
			}
254 269
		});
255 270
	}
256
	
257
	/*微信分享*/
258
	$.ajax({
259
		url: "../ajax/weixin/jsapiTicket",
260
		type: 'get',
261
		dataType: 'json',
262
		contentType: "application/x-www-form-urlencoded; charset=utf-8",
263
		data: {
264
			'url': location.href.split('#')[0]
265
		},
266
		success: function(data) {
267
			if(data.data) {
268
				wx.config({
269
					debug: false, //调试模式好犀利
270
					appId: data.data.appId,
271
					timestamp: data.data.timestamp,
272
					nonceStr: data.data.nonceStr,
273
					signature: data.data.signature,
274
					jsApiList: [ // 所有要调用的 API 都要加到这个列表中
275
						"onMenuShareAppMessage",
276
						"onMenuShareTimeline",
277
						"onMenuShareQQ",
278
						"onMenuShareQZone",
279
						"scanQRCode",
280
					]
281
				});
282
				wx.ready(function() {
283
					// 在这里调用 API
284
					wx.onMenuShareAppMessage({ //分享给朋友
285
						title: shareTitle, // 分享标题
286
						desc: descContent, // 分享描述
287
						link: lineLink, // 分享链接
288
						imgUrl: imgUrl, // 分享图标
289
						success: share_success_callback,
290
						cancel: share_cancel_callback
291
					});
292
					wx.onMenuShareTimeline({ //分享到朋友圈
293
						title: shareTitle, // 分享标题
294
						desc: descContent, // 分享描述
295
						link: lineLink, // 分享链接
296
						imgUrl: imgUrl, // 分享图标
297
						success: share_success_callback,
298
						cancel: share_cancel_callback
299
					});
300
					wx.onMenuShareQQ({ //分享到QQ
301
						title: shareTitle, // 分享标题
302
						desc: descContent, // 分享描述
303
						link: lineLink, // 分享链接
304
						imgUrl: imgUrl, // 分享图标
305
						success: share_success_callback,
306
						cancel: share_cancel_callback
307
					});
308
					wx.onMenuShareQZone({ //分享到QQ空间
309
						title: shareTitle, // 分享标题
310
						desc: descContent, // 分享描述
311
						link: lineLink, // 分享链接
312
						imgUrl: imgUrl, // 分享图标
313
						success: share_success_callback,
314
						cancel: share_cancel_callback
315
					});
316
				});
317
				//分享成功后的回调函数	
318
				function share_success_callback() {}
319
				//用户取消分享后执行的回调函数	
320
				function share_cancel_callback() {}
321
    		}
322
		}
323
	});
324
    
325
    function GetQueryString(name) {
326
		var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
327
		var r = window.location.search.substr(1).match(reg);
328
		var context = "";
329
		if(r != null)
330
			context = r[2];
331
		reg = null;
332
		r = null;
333
		return context == null || context == "" || context == "undefined" ? "" : decodeURI(context);
334
	}
335
	/*标志*/
336
	function autho() {
337
		if(arguments[0] == 1) {
338
			return {
339
				"sty": "authicon-pro",
340
				"title": "科袖认证专家"
341
			}
342
		} else {
343
			if(arguments[1] == 1) {
344
				return {
345
					"sty": "authicon-staff-ok",
346
					"title": "企业认证员工"
347
				}
348
			} else {
349
				if(arguments[2] == 3) {
350
					return {
351
						"sty": "authicon-real",
352
						"title": "实名认证用户"
353
					}
354
				} else {
355
					return {
356
						"sty": "e",
357
						"title": " "
358
					}
359
				}
360
			}
361
		}
362
	}
271
363 272
})
364 273
</script>
365 274
</body>

+ 275 - 0
e/z.html

@ -0,0 +1,275 @@
1
<!DOCTYPE html>
2
<html>
3
<head>
4
<meta charset="UTF-8">
5
<title>专利分享-科袖网</title>
6
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
7
<link rel="stylesheet" href="../css/reset.css" />
8
<link rel="stylesheet" href="../css/common.css" />
9
<link rel="stylesheet" href="../css/share.css" />
10
<style>
11
	html,body{margin:0;padding:0px;background: #FFFFFF;}
12
</style>
13
<script type="text/javascript" src="../js/jquery-1.11.1.js"></script>
14
<script type="text/javascript" src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
15
<script type="text/javascript" src="../js/public/shareCom.js"></script>		
16
</head>
17
18
<body>
19
	<div class="contentBody2">
20
	    <div class="showDetail">
21
    		<div class="h1Font hWeight" id="patentName"></div>
22
	    	<!--内容区-->
23
			<div class="showMain showMainP">
24
				<ul>
25
					<li>
26
						<div class="showTit">专利号:<span class="showCon" id="Znum1"></span></div>
27
					</li>
28
					<li>
29
						<div class="showTit">公开日:<span class="showCon" id="Znum2"></span></div>
30
					</li>
31
					<li>
32
						<div class="showTit">申请日:<span class="showCon" id="Znum3"></span></div>
33
					</li>
34
					<li>
35
						<div class="showTit">申请号:<span class="showCon" id="Znum4"></span></div>
36
					</li>
37
					<li>
38
						<div class="showTit">申请人:<span class="showCon" id="Znum5"></span></div>
39
					</li>
40
					<li>
41
						<div class="showTit">摘要:</div>
42
						<div class="showCon" id="patentAbstract">
43
							
44
						</div>
45
					</li>
46
				</ul>
47
			</div>
48
    		<!--标签模块-->
49
			<ul class="tagList">
50
				
51
			</ul>
52
			<div class="madiaBlock">
53
				<div class="madiaTit">发明人</div>
54
				<ul class="mui-table-view" id="aboutAuthors">
55
			        
56
			    </ul>
57
			</div>
58
	    </div>
59
	    <div class="shareEcode">
60
	    	<div class="Ecodebox">
61
				<div class="Ecodecon clearfix">
62
					<img src="../images/weixin_code.jpg" />
63
					<div class="codecon">
64
						<h1>「 科袖 」</h1>
65
						<h2>搭建企业与专家的桥梁</h2>
66
						<h3>长按识别科袖公众号</h3>
67
					</div>
68
				</div>
69
			</div>
70
			<div style="margin:20px auto;">
71
				<a href="http://a.app.qq.com/o/simple.jsp?pkgname=com.ekexiu.app"><button class="frmbtn frmactive">下载移动客户端</button></a>
72
			</div>
73
	    </div>
74
	</div>
75
<script type="text/javascript">
76
$(document).ready(function() {
77
	var imgUrl = "http://www.ekexiu.com/images/logo180.png";
78
	var lineLink = document.location.href;
79
	var descContent;
80
	var shareTitle;
81
	var appid = '';
82
	
83
	var patentId = GetQueryString("id");
84
	getRecourceMe();
85
	shareWays();//分享方式
86
	$.ajax({
87
		"url": "../ajax/ppatent/incPageViews",
88
		"type": "POST",
89
		"dataType": "json",
90
		"data": {
91
			"id": patentId
92
		},
93
		"success": function(data) {
94
			console.log(data);
95
			if(data.success) {}
96
		},
97
		"error": function() {
98
			//$.MsgBox.Alert('提示', '链接服务器超时')
99
		}
100
	});
101
	$("#aboutAuthors").on("click","li",function(){
102
		var oDataId = $(this).attr("data-id");
103
		if(oDataId.substring(0,1)!="#"){
104
			location.href="http://" + window.location.host + "/e/p.html?id=" + oDataId;
105
		}else{
106
			location.href="javascrip:;";
107
		}
108
	})
109
		
110
	function getRecourceMe() {
111
		$.ajax({
112
			url:'../ajax/ppatent/qo',
113
			data: {
114
				'id': patentId,
115
			},
116
			dataType: 'json', //服务器返回json格式数据
117
			type: 'get', //HTTP请求类型
118
			timeout: 10000, //超时时间设置为10秒;
119
			success: function(data) {
120
				if(data.success) {
121
					var mydata = data.data;
122
					patentHtml(data.data);
123
					getpatentAuthors(data.data.id)
124
				}
125
			},
126
			error: function(e) {
127
				return;
128
			}
129
		});
130
	}
131
	function patentHtml($da) {
132
		//微信再次分享配置
133
		shareTitle = $da.name;
134
		descContent = $da.summary.substring(0,20);
135
		
136
		document.title = $da.name; 
137
		document.getElementById("patentName").innerHTML = $da.name; //名字
138
		document.getElementById("patentAbstract").innerHTML = $da.summary; //摘要内容
139
		document.getElementById("Znum1").innerHTML = $da.code;//专利号
140
		if($da.pubDay){
141
			document.getElementById("Znum2").innerHTML = TimeTr($da.pubDay);
142
		}else{
143
			document.getElementById("Znum2").parentNode.parentNode.style.display="none";
144
		}
145
		if($da.reqCode){
146
			document.getElementById("Znum4").innerHTML = $da.reqCode;
147
		}else{
148
			document.getElementById("Znum4").parentNode.parentNode.style.display="none";
149
		}
150
		if($da.reqDay){
151
			document.getElementById("Znum3").innerHTML =  TimeTr($da.reqDay);
152
		}else{
153
			document.getElementById("Znum3").parentNode.parentNode.style.display="none";
154
		}
155
		if($da.reqDay){
156
			document.getElementById("Znum5").innerHTML = $da.reqPerson;
157
		}else{
158
			document.getElementById("Znum5").parentNode.parentNode.style.display="none";
159
		}
160
		
161
		if($da.keywords != undefined && $da.keywords.length != 0 ){
162
			var subs = new Array();
163
			if($da.keywords.indexOf(',')){
164
				subs = $da.keywords.split(',');
165
			}else{
166
				subs[0] = $da.keywords;
167
			}
168
			var pstr=""
169
			if(subs.length>0){
170
				for (var i = 0; i < subs.length; i++) 
171
				{
172
					pstr+='<li><span class="h2Font">'+ subs[i] +'</span></li>'
173
				};
174
				$(".tagList").html(pstr);
175
			}else{
176
				$(".tagList").hide();
177
			}
178
		}		
179
	}
180
	/*获取论文作者信息*/
181
	function getpatentAuthors(stritrm) {
182
		$.ajax({
183
			"url":"../ajax/ppatent/authors",
184
			"type": "GET",
185
			"success": function(data) {
186
				if(data.success) {
187
					if(data.data.length>0){
188
						for(var i=0;i<data.data.length;i++){
189
							var authTy="",authTit="",baseInfo="",imgbg="../images/default-photo.jpg";
190
							if(data.data[i].professorId.substring(0, 1) != "#"){
191
								$.ajax({
192
									url:"../ajax/professor/editBaseInfo/" + data.data[i].professorId,
193
									type:"get",
194
									async:true,
195
									success:function($proData){
196
										if($proData.success){
197
											var showPro = $proData.data;
198
											if(showPro.hasHeadImage == 1) {
199
												imgbg = "/images/head/" + showPro.id + "_l.jpg";
200
											} else {
201
												imgbg = "../images/default-photo.jpg";
202
											}
203
											//认证
204
											var oSty = autho(showPro.authType,showPro.orgAuth,showPro.authStatus);
205
											authTy = oSty.sty;
206
											authTit = oSty.title;
207
											
208
											var title = showPro.title || "";
209
											var orgName = showPro.orgName || "";
210
											var office = showPro.office || "";
211
											if(orgName!=""){
212
												if(title != "") {
213
													baseInfo = title + "," + orgName;
214
												}else{
215
													if(office!=""){
216
														baseInfo = office  + "," + orgName;	
217
													}else{
218
														baseInfo = orgName;	
219
													}
220
												}
221
											}else{
222
												if(title != "") {
223
													baseInfo = title;
224
												}else{
225
													if(office!=""){
226
														baseInfo = office;	
227
													}else{
228
														baseInfo = "";	
229
													}
230
												}
231
											}
232
											var liItem = document.createElement("li");
233
											liItem.setAttribute("data-id",showPro.id);
234
											liItem.className = "mui-table-view-cell"
235
											var oString = '<div class="flexCenter mui-clearfix">'
236
											oString += '<div class="madiaHead useHead" style="background-image:url('+ imgbg +')"></div>'
237
											oString += '<div class="madiaInfo"><p><span class="h1Font">'+ showPro.name +'</span><em class="authicon '+ authTy +'" title="'+ authTit +'"></em></p>'
238
											oString += '<p class="ellipsisSty h2Font">'+ baseInfo +'</p>'
239
											oString += '</div></div>'
240
											liItem.innerHTML = oString;
241
											document.getElementById("aboutAuthors").appendChild(liItem);
242
										}
243
									}
244
								})
245
							}else{
246
								var liItem = document.createElement("li");
247
								liItem.setAttribute("data-id",data.data[i].professorId);
248
								liItem.className = "mui-table-view-cell"
249
								var oString = '<div class="flexCenter mui-clearfix">'
250
								oString += '<div class="madiaHead useHead" style="background-image:url('+ imgbg +')"></div>'
251
								oString += '<div class="madiaInfo"><p><span class="h1Font">'+ data.data[i].name  +'</span></p>'
252
								oString += '</div></div>'
253
								liItem.innerHTML = oString;
254
								document.getElementById("aboutAuthors").appendChild(liItem);
255
							}
256
							
257
						}
258
					}
259
				}
260
			},
261
			"data": {
262
				"id": stritrm
263
			},
264
			dataType: "json",
265
			'error':function() {
266
				//$.MsgBox.Alert('提示', '链接服务器超时')
267
			}
268
		});
269
	}
270
	
271
})
272
</script>
273
</body>
274
275
</html>

BIN
images/enterprise_img_bg_nor@3x.png


BIN
images/personal_icon_dizhi_nor@3x.png


BIN
images/personal_img_bg_nor@3x.png


+ 162 - 0
js/public/shareCom.js

@ -0,0 +1,162 @@
1
function GetQueryString(name) {
2
	var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
3
	var r = window.location.search.substr(1).match(reg);
4
	var context = "";
5
	if(r != null)
6
		context = r[2];
7
	reg = null;
8
	r = null;
9
	return context == null || context == "" || context == "undefined" ? "" : decodeURI(context);
10
}
11
/*标志*/
12
function autho() {
13
	if(arguments[0] == 1) {
14
		return {
15
			"sty": "authicon-pro",
16
			"title": "科袖认证专家"
17
		}
18
	} else {
19
		if(arguments[1] == 1) {
20
			return {
21
				"sty": "authicon-staff-ok",
22
				"title": "企业认证员工"
23
			}
24
		} else {
25
			if(arguments[2] == 3) {
26
				return {
27
					"sty": "authicon-real",
28
					"title": "实名认证用户"
29
				}
30
			} else {
31
				return {
32
					"sty": "e",
33
					"title": " "
34
				}
35
			}
36
		}
37
	}
38
}
39

40
//时间显示规则
41
function commenTime(startTime) {
42
	var nowTimg = new Date();
43
	var startdate = new Date();
44
	startdate.setFullYear(parseInt(startTime.substring(0, 4)));
45
	startdate.setMonth(parseInt(startTime.substring(4, 6)) - 1);
46
	startdate.setDate(parseInt(startTime.substring(6, 8)));
47
	startdate.setHours(parseInt(startTime.substring(8, 10)));
48
	startdate.setMinutes(parseInt(startTime.substring(10, 12)));
49
	startdate.setSeconds(parseInt(startTime.substring(12, 14)));
50
	var date3 = nowTimg.getTime() - startdate.getTime(); //时间差的毫秒数
51
	var hours = parseInt((date3 % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
52
	var minutes = parseInt((date3 % (1000 * 60 * 60)) / (1000 * 60));
53
	if(date3 < 60000) {
54
		return "刚刚";
55
	} else if(date3 >= 60000 && date3 < 3600000) {
56
		return minutes + "分钟前";
57
	} else if(date3 >= 3600000 && date3 < 86400000) {
58
		return hours + "小时前";
59
	} else if(date3 >= 86400000) {
60

61
		if(nowTimg.getFullYear() == startTime.substring(0, 4)) {
62

63
			return startTime.substring(4, 6).replace(/\b(0+)/gi, "") + "月" + startTime.substring(6, 8).replace(/\b(0+)/gi, "") + "日 " + startTime.substring(8, 10) + ":" + startTime.substring(10, 12);
64
		} else {
65

66
			return startTime.substring(0, 4) + "年" + startTime.substring(4, 6).replace(/\b(0+)/gi, "") + "月" + startTime.substring(6, 8).replace(/\b(0+)/gi, "") + "日 " + startTime.substring(8, 10) + ":" + startTime.substring(10, 12);
67
		}
68
	}
69
}
70

71
/*时间转换*/
72
function TimeTr(dealtime) {
73
	var myDate = new Date();
74
	var s = dealtime;
75
	var y = s.substr(0, 4);
76
	var m = s.substr(4, 2);
77
	var d = s.substr(6, 2);
78
	var h = s.substr(8, 2);
79
	var minute = s.substr(10, 2);
80
	var formatTime;
81
	if(s.length <= 6) {
82
		formatTime = y + "年" + m.replace(/\b(0+)/gi, "") + "月";
83
	} else if(s.length > 6 && s.length <= 8) {
84
		formatTime = y + "年" + m.replace(/\b(0+)/gi, "") + "月" + d.replace(/\b(0+)/gi, "") + "日 ";
85
	} else {
86
		formatTime = m.replace(/\b(0+)/gi, "") + "月" + d.replace(/\b(0+)/gi, "") + "日 " + h + ":" + minute;
87
		if(y != myDate.getFullYear()) {
88
			formatTime = y + "年" + m.replace(/\b(0+)/gi, "") + "月" + d.replace(/\b(0+)/gi, "") + "日 " + h + ":" + minute;
89
		}
90
	}
91
	return formatTime;
92
}
93

94
function shareWays(){
95
	/*微信分享*/
96
	$.ajax({
97
		url: "../ajax/weixin/jsapiTicket",
98
		type: 'get',
99
		dataType: 'json',
100
		contentType: "application/x-www-form-urlencoded; charset=utf-8",
101
		data: {
102
			'url': location.href.split('#')[0]
103
		},
104
		success: function(data) {
105
			if(data.data) {
106
				wx.config({
107
					debug: false, //调试模式好犀利
108
					appId: data.data.appId,
109
					timestamp: data.data.timestamp,
110
					nonceStr: data.data.nonceStr,
111
					signature: data.data.signature,
112
					jsApiList: [ // 所有要调用的 API 都要加到这个列表中
113
						"onMenuShareAppMessage",
114
						"onMenuShareTimeline",
115
						"onMenuShareQQ",
116
						"onMenuShareQZone",
117
						"scanQRCode",
118
					]
119
				});
120
				wx.ready(function() {
121
					// 在这里调用 API
122
					wx.onMenuShareAppMessage({ //分享给朋友
123
						title: shareTitle, // 分享标题
124
						desc: descContent, // 分享描述
125
						link: lineLink, // 分享链接
126
						imgUrl: imgUrl, // 分享图标
127
						success: share_success_callback,
128
						cancel: share_cancel_callback
129
					});
130
					wx.onMenuShareTimeline({ //分享到朋友圈
131
						title: shareTitle, // 分享标题
132
						desc: descContent, // 分享描述
133
						link: lineLink, // 分享链接
134
						imgUrl: imgUrl, // 分享图标
135
						success: share_success_callback,
136
						cancel: share_cancel_callback
137
					});
138
					wx.onMenuShareQQ({ //分享到QQ
139
						title: shareTitle, // 分享标题
140
						desc: descContent, // 分享描述
141
						link: lineLink, // 分享链接
142
						imgUrl: imgUrl, // 分享图标
143
						success: share_success_callback,
144
						cancel: share_cancel_callback
145
					});
146
					wx.onMenuShareQZone({ //分享到QQ空间
147
						title: shareTitle, // 分享标题
148
						desc: descContent, // 分享描述
149
						link: lineLink, // 分享链接
150
						imgUrl: imgUrl, // 分享图标
151
						success: share_success_callback,
152
						cancel: share_cancel_callback
153
					});
154
				});
155
				//分享成功后的回调函数	
156
				function share_success_callback() {}
157
				//用户取消分享后执行的回调函数	
158
				function share_cancel_callback() {}
159
    		}
160
		}
161
	});
162
}