portal html css js resource

index.html 12KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375
  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/bootstrap.min.css" />
  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. <script type="text/javascript" src="../js/jquery-1.11.1.js"></script>
  12. <script type="text/javascript" src="../js/public/baseUtil.js"></script>
  13. <script type="text/javascript" src="../js/public/shareCom.js"></script>
  14. <script type="text/javascript" src="../js/public/openApp.js"></script>
  15. </head>
  16. <body>
  17. <div class="bomb-box" style="top: 15%"></div>
  18. <div class="contentBody2">
  19. <div class="bannerA">
  20. <img class="logoA" src="../images/banner/bglogo.png" />
  21. <img width="100%" src="../images/banner/bg1218.jpg" />
  22. <div class="search-wrap">
  23. <input type="text" placeholder="搜索专家、服务、资源" class="search-input" />
  24. <icon type="search" class="search-icon"></icon>
  25. </div>
  26. </div>
  27. <div class="conblock btnLinkBox clearfix">
  28. <ul class="row clearfix">
  29. <li class="col-xs-6" id="improfessor">
  30. <a href="javascript:;">
  31. <div class="btnLinkIcon proBtn"></div>
  32. <div class="media-body btnLink">
  33. <h4 class='h1Font'>找专家</h4>
  34. <p class='h2Font ellipsisSty'>解决企业研发难题</p>
  35. </div>
  36. </a>
  37. </li>
  38. <li class="col-xs-6" id="demandP">
  39. <a href="javascript:;">
  40. <div class="btnLinkIcon fabuBtn"></div>
  41. <div class="media-body btnLink">
  42. <h4 class='h1Font'>发需求</h4>
  43. <p class='h2Font ellipsisSty'>快速获得专家回复</p>
  44. </div>
  45. </a>
  46. </li>
  47. </ul>
  48. </div>
  49. <div class="mainbox">
  50. <div class="maintitbox">
  51. <div class="maintit">热门领域</div>
  52. </div>
  53. <ul class="row gridbg">
  54. <li class="col-xs-4" data-title="腐蚀与防护">
  55. <a href="#">
  56. <span class="fieldicon fieldicon01"></span>
  57. <div class="media-body">腐蚀与防护</div>
  58. </a>
  59. </li>
  60. <li class="col-xs-4" data-title="材料失效与保护">
  61. <a href="#">
  62. <span class="fieldicon fieldicon02"></span>
  63. <div class="media-body">材料失效与保护</div>
  64. </a>
  65. </li>
  66. <li class="col-xs-4" data-title="材料加工">
  67. <a href="#">
  68. <span class="fieldicon fieldicon03"></span>
  69. <div class="media-body">材料加工</div>
  70. </a>
  71. </li>
  72. <li class="col-xs-4" data-title="复合材料">
  73. <a href="#">
  74. <span class="fieldicon fieldicon04"></span>
  75. <div class="media-body">复合材料</div>
  76. </a>
  77. </li>
  78. <li class="col-xs-4" data-title="金属材料">
  79. <a href="#">
  80. <span class="fieldicon fieldicon05"></span>
  81. <div class="media-body">金属材料</div>
  82. </a>
  83. </li>
  84. <li class="col-xs-4" data-title="">
  85. <a href="#">
  86. <span class="fieldicon fieldicon-more"></span>
  87. <div class="media-body">更多领域</div>
  88. </a>
  89. </li>
  90. </ul>
  91. </div>
  92. <div class="mainbox">
  93. <div class="maintitbox">
  94. <div class="maintit">推荐专家</div>
  95. </div>
  96. <div class="infocon madiaBlock">
  97. <ul class="mui-table-view" id="hotPro">
  98. </ul>
  99. </div>
  100. <div class="seeMore" id="moreHotp"><em>查看更多</em></div>
  101. </div>
  102. <div class="mainbox">
  103. <div class="maintitbox">
  104. <div class="maintit">热门资源</div>
  105. </div>
  106. <div class="infocon madiaBlock">
  107. <ul class="mui-table-view" id="resShare">
  108. </ul>
  109. </div>
  110. <div class="seeMore" id="moreShare"><em>查看更多</em></div>
  111. </div>
  112. <div class="mainbox" style="margin-bottom: 20px;">
  113. <div class="maintitbox">
  114. <div class="maintit">入驻企业</div>
  115. </div>
  116. <div class="infocon madiaBlock">
  117. <ul class="mui-table-view" id="ruZhuCmp">
  118. </ul>
  119. </div>
  120. <div class="seeMore" id="moreRcmp"><em>查看更多</em></div>
  121. </div>
  122. </div>
  123. <script type="text/javascript">
  124. $(document).ready(function() {
  125. proShow()
  126. resShare()
  127. ruZhuCmp()
  128. $("#resShare").on("click","li", function() {
  129. var OdataId=this.getAttribute("data-id");
  130. location.href="http://" + window.location.host + "/e/r.html?id=" + OdataId;
  131. })
  132. $("#hotPro").on("click","li", function() {
  133. var OdataId=this.getAttribute("data-id");
  134. location.href="http://" + window.location.host + "/e/p.html?id=" + OdataId;
  135. })
  136. $("#ruZhuCmp").on("click","li", function() {
  137. var OdataId=this.getAttribute("data-id");
  138. location.href="http://" + window.location.host + "/e/c.html?id=" + OdataId;
  139. })
  140. $("#moreRcmp").on("click", function() {//查看更多企业
  141. location.href="http://" + window.location.host + "/e/search.html?flag=6";
  142. })
  143. $("#moreShare").on("click", function() {//查看更多资源
  144. location.href="http://" + window.location.host + "/e/search.html?flag=2";
  145. })
  146. $("#moreHotp").on("click", function() {//查看更多专家
  147. location.href="http://" + window.location.host + "/e/search.html?flag=1";
  148. })
  149. var this_="../index.html";
  150. wcFresh(this_);
  151. document.getElementById("demandP").addEventListener("click", function() {
  152. isInstalled(this_,true);
  153. })
  154. document.getElementById("improfessor").addEventListener("click", function() {
  155. location.href="http://" + window.location.host + "/e/search.html?flag=1";
  156. })
  157. /*点击热门领域*/
  158. $('.gridbg').on('click', 'li', function() {
  159. var subject = this.getAttribute("data-title");
  160. location.href="http://" + window.location.host + "/e/search.html?flag=1&key=" + subject;
  161. })
  162. $(".search-input").keydown(function(e) {//search Enter
  163. if(e.which == 13) {
  164. var searchContent = $.trim($(".search-input").val());
  165. if(searchContent){
  166. location.href = "search.html?key=" + encodeURI(searchContent);
  167. }else{
  168. bombox("请输入关键词");
  169. return;
  170. }
  171. }
  172. })
  173. function ruZhuCmp(){//入驻企业
  174. $.ajax({
  175. url:"/ajax/org/index/search",
  176. type: "GET",
  177. timeout: 10000,
  178. dataType: "json",
  179. data:{
  180. "rows": 5
  181. },
  182. success: function(data) {
  183. if(data.success) {
  184. var $info = data.data;
  185. for(var i = 0; i < $info.length; i++) {
  186. var liStr=document.createElement("li");
  187. liStr.className="mui-table-view-cell";
  188. liStr.setAttribute("data-id", $info[i].id);
  189. document.getElementById("ruZhuCmp").appendChild(liStr);
  190. var cmpname,imgurl='../images/default-icon.jpg'
  191. if($info[i].hasOrgLogo) {
  192. imgurl='/images/org/' + $info[i].id + '.jpg';
  193. }
  194. if($info[i].forShort){
  195. cmpname = $info[i].forShort;
  196. }else{
  197. cmpname = $info[i].name;
  198. }
  199. var oSty={sty:"",tit:""};
  200. if($info[i].authStatus == 3) {
  201. oSty.sty="authicon-com-ok"
  202. oSty.tit="科袖认证企业"
  203. }
  204. var orgOther = "",orgType="";
  205. if($info[i].industry) {
  206. orgOther = $info[i].industry.replace(/,/gi, " | ");
  207. }
  208. if($info[i].orgType == "2") {
  209. orgType = orgTypeShow[$info[i].orgType] + "<span style='margin-right:16px;'></span>";
  210. }
  211. var strCon='';
  212. strCon += '<div class="flexCenter clearfix">'
  213. strCon += '<div class="madiaHead cmpHead">'
  214. strCon += '<div class="boxBlock"><img class="boxBlockimg" src="'+imgurl+'"></div></div>'
  215. strCon += '<div class="madiaInfo OmadiaInfo">'
  216. strCon += '<div class="h1Font ellipsisSty">'
  217. strCon += '<span class="qiyego">'+cmpname+'</span>'
  218. strCon += '<span class="authiconNew '+oSty.sty+'" title="'+oSty.tit+'"></span>'
  219. strCon += '</div>'
  220. strCon += '<div class="h2Font ellipsisSty">'
  221. strCon += '<span>'+orgType+orgOther+'</span>'
  222. strCon += '</div>'
  223. strCon += '</div></div>'
  224. liStr.innerHTML = strCon;
  225. }
  226. }
  227. },
  228. error: function() {
  229. }
  230. })
  231. }
  232. function resShare(){//资源共享
  233. $.ajax({
  234. url:"/ajax/resource/index/search",
  235. type: "GET",
  236. timeout: 10000,
  237. dataType: "json",
  238. data:{
  239. "rows":5
  240. },
  241. success: function(data) {
  242. if(data.success) {
  243. var $info = data.data;
  244. for(var i = 0; i < $info.length; i++) {
  245. var liStr = document.createElement("li");
  246. liStr.setAttribute("data-id", $info[i].resourceId);
  247. liStr.className = "mui-table-view-cell";
  248. document.getElementById("resShare").appendChild(liStr);
  249. var cmpname,imgurl='../images/default-resource.jpg'
  250. var oSty={sty:"",tit:""};
  251. if($info[i].images.length > 0) {
  252. imgurl='/data/resource/' + $info[i].images[0].imageSrc
  253. }
  254. if($info[i].resourceType == 1) { //个人资源
  255. cmpname = $info[i].editProfessor.name;
  256. oSty = autho($info[i].editProfessor.authType, $info[i].editProfessor.orgAuth, $info[i].editProfessor.authStatus);
  257. } else if($info[i].resourceType == 2) { //企业资源
  258. if($info[i].organization.forShort) {
  259. cmpname = $info[i].organization.forShort;
  260. }else{
  261. cmpname = $info[i].organization.name;
  262. }
  263. if($info[i].organization.authStatus==3){
  264. oSty.sty="authicon-com-ok"
  265. oSty.tit="科袖认证企业"
  266. }
  267. }
  268. var strCon='';
  269. strCon += '<div class="flexCenter clearfix">'
  270. strCon += '<div class="madiaHead resouseHead" style="background-image:url('+imgurl+')"></div>'
  271. strCon += '<div class="madiaInfo OmadiaInfo">'
  272. strCon += '<div class="h1Font ellipsisSty-2">'+$info[i].resourceName+'</div>'
  273. strCon += '<div class="h3Font ellipsisSty">'
  274. strCon += '<span class="qiyego">'+cmpname+'</span>'
  275. strCon += '<span class="authiconNew '+oSty.sty+'" title="'+oSty.tit+'"></span>'
  276. strCon += '<div class=" ellipsisSty h2Font">用途:' + $info[i].supportedServices + '</div>'
  277. strCon += '</div></div>'
  278. liStr.innerHTML = strCon;
  279. }
  280. }
  281. },
  282. error: function() {
  283. }
  284. })
  285. }
  286. function proShow(){//专家
  287. $.ajax({
  288. url:"/ajax/professor/index/search",
  289. type: "GET",
  290. timeout: 10000,
  291. dataType: "json",
  292. data:{
  293. "rows": 5
  294. },
  295. success: function(data) {
  296. if(data.success) {
  297. var $info = data.data;
  298. for(var i = 0; i < $info.length; i++) {
  299. var liStr = document.createElement("li");
  300. liStr.setAttribute("data-id", $info[i].id);
  301. liStr.className = "mui-table-view-cell";
  302. document.getElementById("hotPro").appendChild(liStr);
  303. var cmpname,imgurl='../images/default-photo.jpg'
  304. var oSty=autho($info[i].authType, $info[i].orgAuth, $info[i].authStatus);
  305. cmpname = $info[i].name;
  306. if($info[i].hasHeadImage) {
  307. imgurl='/images/head/' + $info[i].id + '_l.jpg';
  308. }
  309. var oTitle='';
  310. if($info[i].title) {
  311. oTitle = $info[i].title;
  312. if($info[i].orgName){
  313. oTitle = $info[i].title +','+ $info[i].orgName;
  314. }
  315. } else {
  316. if($info[i].office) {
  317. oTitle = $info[i].office;
  318. if($info[i].orgName){
  319. oTitle = $info[i].office +','+ $info[i].orgName;
  320. }
  321. }
  322. }
  323. var oResult=""
  324. if($info[i].researchAreas.length > 0){
  325. oResult = '研究方向:';
  326. for(var n = 0; n < $info[i].researchAreas.length; n++) {
  327. oResult += $info[i].researchAreas[n].caption
  328. if(n < $info[i].researchAreas.length - 1) {
  329. oResult += ";"
  330. }
  331. }
  332. }
  333. var strCon='';
  334. strCon += '<div class="flexCenter clearfix">'
  335. strCon += '<div class="madiaHead useHead" style="background-image:url('+imgurl+')"></div>'
  336. strCon += '<div class="madiaInfo">'
  337. strCon += '<div class="h1Font ellipsisSty">'
  338. strCon += '<span class="qiyego">'+cmpname+'</span>'
  339. strCon += '<span class="authiconNew '+oSty.sty+'" title="'+oSty.tit+'"></span>'
  340. strCon += '</div>'
  341. strCon += '<div class="h3Font ellipsisSty" style="margin-top:0;">'+oTitle+'</div>'
  342. strCon += '<div class="h3Font ellipsisSty">'+oResult+'</div>'
  343. strCon += '</div></div>'
  344. liStr.innerHTML = strCon;
  345. }
  346. }
  347. },
  348. error: function() {
  349. }
  350. })
  351. }
  352. })
  353. </script>
  354. </body>
  355. </html>