portal html css js resource

cmpInformation.js 22KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618
  1. $(function() {
  2. var orgId = $.cookie("orgId");
  3. var rows = 20,
  4. dataO = {
  5. artPublishTime:"",
  6. artShareId:"",
  7. resPublishTime:"",
  8. resShareId:"",
  9. serModifyTime: "",
  10. serId: "",
  11. },
  12. watchO={
  13. beiTime:"",
  14. beiProId:"",
  15. };
  16. var oAjax = function(url, dataS, otype, oFun,beforeFun,completeFun) {
  17. $.ajax({
  18. url:url,
  19. dataType: 'json',
  20. type: otype,
  21. data: dataS,
  22. traditional: true,
  23. beforeSend: beforeFun,
  24. success: function(res) {
  25. if(res.success) {
  26. oFun(res)
  27. }
  28. },
  29. complete:completeFun
  30. });
  31. },
  32. insertNodata = function (targetE,newStr) {
  33. var parent = document.getElementById(targetE).parentNode;
  34. var kong = document.createElement("div");
  35. kong.className = "con-kong";
  36. kong.innerHTML ='<div class="picbox picNull"></div>'+
  37. '<div class="txtbox">暂时没有符合该搜索条件的内容</div>'
  38. if(newStr){
  39. kong.querySelector(".txtbox").innerHTML = newStr;
  40. }
  41. if (parent.firstChild.className == "con-kong") {
  42. return
  43. } else {
  44. parent.insertBefore(kong,parent.firstChild);
  45. }
  46. },
  47. removeNodata = function (targetE) {
  48. var parent = document.getElementById(targetE).parentNode;
  49. if (parent.firstChild.className == "con-kong") {
  50. parent.removeChild(parent.firstChild);
  51. } else {
  52. return
  53. }
  54. },
  55. getCmpInfo=function() {
  56. oAjax("/ajax/org/" + orgId,{}, "get", function(data){
  57. console.log(data)
  58. var $info = data.data;
  59. if($info.resMgr){
  60. resourceListVal(true);
  61. serviceListVal(true);
  62. $(".establishments").show()
  63. }
  64. $.cookie("colMgr",$info.colMgr);
  65. $.cookie("resMgr",$info.resMgr);
  66. //主页浏览量
  67. $("#viewNums").text($info.pageViews);
  68. if($info.hasOrgLogo) {
  69. $("#proHead").attr("src", "/images/org/" + $info.id + ".jpg");
  70. }else{
  71. $("#proHead").attr("src", "/images/default-icon.jpg");
  72. }
  73. if($info.forShort) {
  74. $("#proName").text($info.forShort);
  75. } else {
  76. $("#proName").text($info.name);
  77. }
  78. commerceInfo($info.name);//工商信息
  79. if($info.authStatus == "3") {
  80. $("#proAuth").addClass("authicon-com-ok");
  81. $("#proAuth").attr("title", "科袖认证企业");
  82. }
  83. if($info.city) {
  84. $("#proAddress").html($info.city + "<span style='margin-right:10px;'></span>");
  85. }
  86. var proOther = "";
  87. if($info.industry) {
  88. proOther = $info.industry.replace(/,/gi, " | ");
  89. }
  90. $("#proOther").text(proOther);
  91. if($info.orgType == "2") {
  92. $("#proTit").html(orgTypeShow[$info.orgType] + "<span style='margin-right:10px;'></span>");
  93. }
  94. var llqtitle = $info.name + "-" + proOther + "科袖网"; //修改浏览器title信息
  95. document.title = llqtitle;
  96. //简介
  97. if($info.descp) {
  98. $("#item1user>.nodatabox").addClass("displayNone");
  99. $("#descpS").parents(".coninfobox").removeClass("displayNone");
  100. $("#descpS").text($info.descp);
  101. } else {
  102. $("#descpS").parents(".coninfobox").addClass("displayNone");
  103. }
  104. //学术领域
  105. if($info.subject) {
  106. $("#item1user>.nodatabox").addClass("displayNone");
  107. $("#subjectShow").parents(".coninfobox").removeClass("displayNone");
  108. var subs=strToAry($info.subject)
  109. if(subs.length > 0) {
  110. for(var i = 0; i < subs.length; i++) {
  111. $("#subjectShow").append("<li>" + subs[i] + "</li>");
  112. };
  113. }
  114. } else {
  115. $("#subjectShow").parents(".coninfobox").addClass("displayNone");
  116. }
  117. //企业资质
  118. if($info.qualification) {
  119. var subs=strToAry($info.qualification)
  120. if(subs.length > 0) {
  121. for(var i = 0; i < subs.length; i++) {
  122. $("#qualification").append("<li><div class='h4tit'>" + subs[i] + "</div></li>");
  123. };
  124. }
  125. } else {
  126. $("#qualification").parents(".coninfobox").hide();
  127. }
  128. //企业详情
  129. $("#orgName").text($info.name);
  130. if($info.orgSize) {
  131. $("#orgSize").text(orgSizeShow[$info.orgSize]);
  132. } else {
  133. $("#orgSize").parent("li").hide();
  134. }
  135. if($info.industry) {
  136. $("#orgIndustry").text($info.industry);
  137. } else {
  138. $("#orgIndustry").parent("li").hide();
  139. }
  140. if($info.city) {
  141. $("#orgCity").text($info.city);
  142. } else {
  143. $("#orgCity").parent("li").hide();
  144. }
  145. if($info.orgType) {
  146. $("#orgType").text(orgTypeShow[$info.orgType]);
  147. } else {
  148. $("#orgType").parent("li").hide();
  149. }
  150. if($info.foundTime) {
  151. $("#foundTime").text(TimeTr($info.foundTime));
  152. } else {
  153. $("#foundTime").parent("li").hide();
  154. }
  155. if($info.orgUrl) {
  156. $("#orgUrl").text($info.orgUrl);
  157. } else {
  158. $("#orgUrl").parent("li").hide();
  159. }
  160. if($info.addr) {
  161. $("#cmpAddress").text($info.addr);
  162. } else {
  163. $("#cmpAddress").parent("li").hide();
  164. }
  165. var weibotitle = $info.name;
  166. var weibourl = window.location.href;
  167. var weibopic = "http://" + window.location.host + "/images/org/" + $info.id + ".jpg";
  168. $("#weibo").attr("href", "http://service.weibo.com/share/share.php?appkey=3677230589&title=" + encodeURIComponent(weibotitle) + "&url=" + encodeURIComponent(weibourl) + "&pic=" + encodeURIComponent(weibopic) + "&content=utf-8" + "&ralateUid=6242830109&searchPic=false&style=simple");
  169. });
  170. },
  171. commerceInfo=function(oName){
  172. oAjax("/ajax/org/regInfo",{
  173. "name": oName
  174. }, "get", function(data){
  175. if(data.data) {
  176. $("#comMes").parents(".coninfobox").show();
  177. var $data = data.data;
  178. var str = "";
  179. if($data.num) {
  180. str += "<li>工商注册号:" + $data.num + "</li>"
  181. }
  182. if($data.code) {
  183. str += "<li>组织机构代码:" + $data.code + "</li>"
  184. }
  185. if($data.creditCode) {
  186. str += "<li>统一信用代码:" + $data.creditCode + "</li>"
  187. }
  188. if($data.type) {
  189. str += "<li>企业类型:" + $data.type + "</li>"
  190. }
  191. if($data.industry) {
  192. str += "<li>行业:" + $data.industry + "</li>"
  193. }
  194. if($data.operatingPeriod) {
  195. str += "<li>营业期限:" + $data.operatingPeriod + "</li>"
  196. }
  197. if($data.dayOfApproval) {
  198. str += "<li>核准日期:" + $data.dayOfApproval + "</li>"
  199. }
  200. if($data.manager) {
  201. str += "<li>登记机关:" + $data.manager + "</li>"
  202. }
  203. if($data.addr) {
  204. str += "<li>注册地址:" + $data.addr + "</li>"
  205. }
  206. if($data.scopeOfBusiness) {
  207. str += "<li>经营范围:" + $data.scopeOfBusiness + "</li>"
  208. }
  209. $("#comMes").html(str);
  210. }
  211. });
  212. },
  213. demandListVal=function(isbind) {
  214. oAjax("/ajax/demand/pq",{
  215. "state":'1',
  216. "oid":orgId,
  217. "pageSize":5
  218. }, "get", function(data){
  219. var $info = data.data.data;
  220. if($info.length > 0){
  221. $("#showDemand").parents(".coninfobox").removeClass("displayNone");
  222. $("#item1user>.nodatabox").addClass("displayNone");
  223. for(var i = 0; i < $info.length; i++) {
  224. var liStr=$("<li></li>").appendTo("#showDemand");
  225. var $data=$info[i];
  226. var sowU="";
  227. if($data.pageViews!=0){
  228. sowU='<li><span>浏览量 '+$data.pageViews +'</span></li>'
  229. }
  230. var strCon='';
  231. strCon+='<a class="" target="_blank" href="demandShow.html?demandId='+$data.id+'" class="madiaInfo">'
  232. strCon+='<p class="h1Font ellipsisSty">'+ $data.title +'</p>'
  233. strCon+='<ul class="showliTop h3Font clearfix">'
  234. strCon+='<li><span>发布于 '+TimeTr($data.createTime)+'</span></li>'
  235. strCon+= sowU
  236. strCon+='</ul>'
  237. strCon+='<p class="h2Font ellipsisSty-2">'+$data.descp+'</p>'
  238. strCon+='<ul class="showli clearfix h3Font">'
  239. if($data.city){ strCon+='<li>所在城市:'+$data.city+'</li>' }
  240. if($data.duration!=0){ strCon+='<li>预期时长:'+demandDuration[$data.duration]+'</li>' }
  241. if($data.cost!=0){ strCon+='<li>费用预算:'+demandCost[$data.cost]+'</li>' }
  242. if($data.invalidDay){ strCon+='<li>有效期至:'+TimeTr($data.invalidDay)+'</li>' }
  243. strCon+='</ul>'
  244. strCon+='</a>'
  245. $(strCon).appendTo(liStr);
  246. }
  247. }else{
  248. $("#showDemand").parents(".needinfobox").addClass("displayNone");
  249. }
  250. })
  251. },
  252. articalListVal=function(isbind){
  253. var aimId="proArticel",aimIdF="showArticle",newStr="企业尚未发布任何文章"
  254. oAjax("/ajax/article/publish",{
  255. "category": "2",
  256. "owner":orgId,
  257. "publishTime":dataO.artPublishTime,
  258. "shareId": dataO.artShareId,
  259. "rows": rows
  260. }, "get", function(res){
  261. var $info = res.data;
  262. if($info.length > 0) {
  263. $("#"+aimId).show()
  264. $("#"+aimIdF).parents(".coninfobox").removeClass("displayNone");
  265. dataO.artPublishTime = $info[$info.length - 1].publishTime;
  266. dataO.artShareId = $info[$info.length - 1].shareId;
  267. for(var i = 0; i < $info.length; i++) {
  268. var sowU="",hasImg="/images/default-artical.jpg"
  269. if($info[i].articleImg) {
  270. hasImg="/data/article/" + $info[i].articleImg
  271. }
  272. if($info[i].pageViews!=0){
  273. if($info[i].articleAgree!=0){
  274. sowU='<li><span>阅读量 '+$info[i].pageViews+'</span></li><li><span>赞 '+$info[i].articleAgree+'</span></li>'
  275. }else{
  276. sowU='<li><span>阅读量 '+$info[i].pageViews+'</span></li>'
  277. }
  278. }
  279. var itemlist = '<li>';
  280. itemlist += '<a href="/'+pageUrl('a',$info[i])+'" class="flexCenter urlgo">';
  281. itemlist += '<div class="madiaHead artHead" style="background-image:url(' + hasImg + ')"></div>';
  282. itemlist += '<div class="madiaInfo">';
  283. itemlist += '<p class="h1Font ellipsisSty-2">'+$info[i].articleTitle+'</p>';
  284. itemlist += '<ul class="h2Font clearfix">';
  285. itemlist += '<li><span class="time">' + commenTime($info[i].publishTime) + '</span></li>';
  286. itemlist += sowU
  287. itemlist += '<li><span class="leaveMsgCount"></span></li>';
  288. itemlist += '</ul></div>';
  289. itemlist += '</a></li>';
  290. var $itemlist = $(itemlist);
  291. $("#"+aimId).append($itemlist)
  292. leaveMsgCount($info[i].articleId,1,$itemlist);
  293. if(isbind && i==0){
  294. var $itemlist = $(itemlist);
  295. $("#"+aimIdF).append($itemlist);
  296. leaveMsgCount($info[0].articleId,1,$itemlist);
  297. }
  298. }
  299. }
  300. var liLen=document.getElementById(aimId).querySelectorAll("li").length;
  301. removeNodata(aimId);
  302. if($info.length == 0 && liLen == 0 ){
  303. $("#"+aimId).hide()
  304. insertNodata(aimId,newStr);
  305. }
  306. if(isbind){
  307. $("#"+aimId).parent().find(".js-load-more").unbind("click").on("click",function(){
  308. articalListVal(false)
  309. })
  310. }
  311. if ($info.length < rows) {
  312. $("#"+aimId).parent().find(".js-load-more").unbind("click");
  313. $("#"+aimId).parent().find(".js-load-more").hide();
  314. }
  315. },function(){
  316. $("#"+aimId).parent().find(".js-load-more").attr("disabled",true);
  317. $("#"+aimId).parent().find(".js-load-more").addClass("active");
  318. },function(){
  319. $("#"+aimId).parent().find(".js-load-more").removeAttr("disabled");
  320. $("#"+aimId).parent().find(".js-load-more").removeClass("active");
  321. })
  322. },
  323. resourceListVal=function(isbind){
  324. var aimId="proResource",aimIdF="showResource",newStr="企业尚未发布任何资源"
  325. oAjax("/ajax/resource/publish",{
  326. "category": "2",
  327. "owner":orgId,
  328. "publishTime":dataO.resPublishTime,
  329. "shareId": dataO.resShareId,
  330. "rows": rows
  331. }, "get", function(res){
  332. var $info = res.data;
  333. if($info.length > 0) {
  334. $("#"+aimId).show()
  335. $("#"+aimIdF).parents(".form-item").removeClass("displayNone");
  336. $("#"+aimIdF).parents(".coninfobox").show();
  337. dataO.resPublishTime = $info[$info.length - 1].publishTime;
  338. dataO.resShareId = $info[$info.length - 1].shareId;
  339. for(var i = 0; i < $info.length; i++) {
  340. var hasImg='/images/default-resource.jpg'
  341. if($info[i].images.length) {
  342. hasImg="/data/resource/" + $info[i].images[0].imageSrc
  343. }
  344. var itemlist = '<li>';
  345. itemlist += '<a href="resourceShow.html?resourceId=' + $info[i].resourceId + '" class="flexCenter urlgo">';
  346. itemlist += '<div class="madiaHead resouseHead" style="background-image:url(' + hasImg + ')"></div>';
  347. itemlist += '<div class="madiaInfo"><p class="h1Font ellipsisSty-2">' + $info[i].resourceName + '</p><p class="h2Font ellipsisSty">应用用途:' + $info[i].supportedServices + '</p></div>';
  348. itemlist += '</a></li>';
  349. var $itemlist = $(itemlist);
  350. $("#"+aimId).append($itemlist)
  351. if(isbind && i==0){
  352. var $itemlist = $(itemlist);
  353. $("#"+aimIdF).append($itemlist);
  354. }
  355. }
  356. }
  357. var liLen=document.getElementById(aimId).querySelectorAll("li").length;
  358. removeNodata(aimId);
  359. if($info.length == 0 && liLen == 0 ){
  360. $("#"+aimId).hide()
  361. insertNodata(aimId,newStr);
  362. }
  363. if(isbind){
  364. $("#"+aimId).parent().find(".js-load-more").unbind("click").on("click",function(){
  365. resourceListVal(false)
  366. })
  367. }
  368. if ($info.length < rows) {
  369. $("#"+aimId).parent().find(".js-load-more").unbind("click");
  370. $("#"+aimId).parent().find(".js-load-more").hide();
  371. }
  372. },function(){
  373. $("#"+aimId).parent().find(".js-load-more").attr("disabled",true);
  374. $("#"+aimId).parent().find(".js-load-more").addClass("active");
  375. },function(){
  376. $("#"+aimId).parent().find(".js-load-more").removeAttr("disabled");
  377. $("#"+aimId).parent().find(".js-load-more").removeClass("active");
  378. })
  379. },
  380. serviceListVal=function(isbind){
  381. var aimId="proService",aimIdF="showService",newStr="企业尚未发布任何服务"
  382. oAjax("/ajax/ware/publish",{
  383. "category":"2",
  384. "owner":orgId,
  385. "modifyTime":dataO.serModifyTime,
  386. "rows": rows
  387. }, "get", function(res){
  388. var $info = res.data;
  389. if($info.length > 0) {
  390. $("#"+aimId).show()
  391. $("#"+aimIdF).parents(".form-item").removeClass("displayNone");
  392. $("#"+aimIdF).parents(".coninfobox").show();
  393. dataO.serModifyTime = $info[$info.length - 1].modifyTime;
  394. for(var i = 0; i < $info.length; i++) {
  395. var cnt="", hasImg="../images/default-service.jpg"
  396. if($info[i].images) {
  397. var subs = strToAry($info[i].images)
  398. if(subs.length > 0) {
  399. hasImg="/data/ware" + subs[0]
  400. }
  401. }
  402. var itemlist = '<li>';
  403. itemlist += '<a href="serviceShow.html?serviceId=' + $info[i].id + '" class="flexCenter urlgo">';
  404. itemlist += '<div class="madiaHead resouseHead" style="background-image:url(' + hasImg + ')"></div>';
  405. itemlist += '<div class="madiaInfo"><p class="h1Font ellipsisSty-2">' + $info[i].name + '</p><p class="h2Font ellipsisSty">' + cnt+ '</p></div>';
  406. itemlist += '</a></li>';
  407. var $itemlist = $(itemlist);
  408. $("#"+aimId).append($itemlist)
  409. if(isbind && i==0){
  410. var $itemlist = $(itemlist);
  411. $("#"+aimIdF).append($itemlist);
  412. }
  413. }
  414. }
  415. var liLen=document.getElementById(aimId).querySelectorAll("li").length;
  416. removeNodata(aimId);
  417. if($info.length == 0 && liLen == 0 ){
  418. $("#"+aimId).hide()
  419. insertNodata(aimId,newStr);
  420. }
  421. if(isbind){
  422. $("#"+aimId).parent().find(".js-load-more").unbind("click").on("click",function(){
  423. serviceListVal(false)
  424. })
  425. }
  426. if ($info.length < rows) {
  427. $("#"+aimId).parent().find(".js-load-more").unbind("click");
  428. $("#"+aimId).parent().find(".js-load-more").hide();
  429. }
  430. },function(){
  431. $("#"+aimId).parent().find(".js-load-more").attr("disabled",true);
  432. $("#"+aimId).parent().find(".js-load-more").addClass("active");
  433. },function(){
  434. $("#"+aimId).parent().find(".js-load-more").removeAttr("disabled");
  435. $("#"+aimId).parent().find(".js-load-more").removeClass("active");
  436. })
  437. },
  438. queryPubCount=function(){
  439. oAjax("/ajax/watch/countProfessor",{//关注企业数量
  440. "id": orgId,
  441. "type":"6"
  442. }, "GET", function(data){
  443. $("#attenNum").text(data.data);
  444. });
  445. oAjax("/ajax/article/count/publish",{//文章总数
  446. "owner": orgId,
  447. "category":"2"
  448. }, "GET", function(data){
  449. if(data.data>0){
  450. $("#artCount").text(data.data);
  451. }
  452. if(data.data>0 && data.data>99){
  453. $("#artCount").text("99+");
  454. }
  455. });
  456. oAjax("/ajax/resource/count/publish",{//资源总数
  457. "owner": orgId,
  458. "category":"2"
  459. }, "GET", function(data){
  460. if(data.data>0){
  461. $("#resCount").text(data.data);
  462. }
  463. if(data.data>0 && data.data>99){
  464. $("#resCount").text("99+");
  465. }
  466. });
  467. oAjax("/ajax/ware/count/publish",{//服务总数
  468. "owner": orgId,
  469. "category":"2"
  470. }, "GET", function(data){
  471. if(data.data>0){
  472. $("#serCount").text(data.data);
  473. }
  474. if(data.data>0 && data.data>99){
  475. $("#serCount").text("99+");
  476. }
  477. });
  478. },
  479. attentMyself=function(isbind){
  480. var aimId="attendMy",newStr="企业尚未被任何人关注"
  481. oAjax("/ajax/watch/watchList",{//关注我的列表
  482. "watchObject": orgId,
  483. "createTime": watchO.beiTime,
  484. "professorId":watchO.beiProId,
  485. "rows":rows
  486. }, "GET", function(res){
  487. var $info = res.data;
  488. if($info.length > 0) {
  489. $("#"+aimId).show()
  490. watchO.beiTime = $info[$info.length - 1].createTime;
  491. watchO.beiProId = $info[$info.length - 1].professorId;
  492. for(var i = 0; i < $info.length; i++) {
  493. var liItem = document.createElement("li");
  494. document.getElementById("attendMy").appendChild(liItem);
  495. detailPro($info[i].professorId,liItem);
  496. }
  497. }
  498. var liLen=document.getElementById(aimId).querySelectorAll("li").length;
  499. removeNodata(aimId);
  500. if($info.length == 0 && liLen == 0 ){
  501. $("#"+aimId).hide()
  502. insertNodata(aimId,newStr);
  503. }
  504. if(isbind){
  505. $("#"+aimId).parent().find(".js-load-more").unbind("click").on("click",function(){
  506. attentMyself(false)
  507. })
  508. }
  509. if ($info.length < rows) {
  510. $("#"+aimId).parent().find(".js-load-more").unbind("click");
  511. $("#"+aimId).parent().find(".js-load-more").hide();
  512. }
  513. },function(){
  514. $("#"+aimId).parent().find(".js-load-more").attr("disabled",true);
  515. $("#"+aimId).parent().find(".js-load-more").addClass("active");
  516. },function(){
  517. $("#"+aimId).parent().find(".js-load-more").removeAttr("disabled");
  518. $("#"+aimId).parent().find(".js-load-more").removeClass("active");
  519. })
  520. },
  521. detailPro=function(pid,liItem) {
  522. oAjax("/ajax/professor/baseInfo/" + pid,{},"get",function(data){
  523. var datalist=data.data;
  524. var userType = autho(datalist.authType, datalist.orgAuth, datalist.authStatus);
  525. var os = "";
  526. if(datalist.title) {
  527. if(datalist.orgName) {
  528. os = datalist.title + "," + datalist.orgName;
  529. } else {
  530. os = datalist.title;
  531. }
  532. } else {
  533. if(datalist.office) {
  534. if(datalist.orgName) {
  535. os = datalist.office + "," + datalist.orgName;
  536. } else {
  537. os = datalist.office;
  538. }
  539. } else {
  540. if(datalist.orgName) {
  541. os = datalist.orgName;
  542. }
  543. }
  544. }
  545. var baImg = "../images/default-photo.jpg";
  546. if(datalist.hasHeadImage == 1) {
  547. baImg = "/images/head/" + datalist.id + "_l.jpg";
  548. }
  549. var strAdd = '';
  550. strAdd += '<a target="_blank" href="userInforShow.html?professorId='+ datalist.id +'" class="flexCenter urlgo">';
  551. strAdd += '<div class="madiaHead useHead" style="width: 80px;height: 80px;margin-top: -40px;background-image:url(' + baImg + ')"></div>';
  552. strAdd += '<div class="madiaInfo" style="padding-left:92px"><p class="h1Font ellipsisSty">' + datalist.name + '</span><em class="authicon ' + userType.sty + '" title="'+userType.title+'"></em></p>';
  553. strAdd += '<p class="h2Font ellipsisSty">' + os + '</p>';
  554. strAdd += '</div>';
  555. strAdd += '</a>';
  556. liItem.innerHTML = strAdd
  557. })
  558. },
  559. bindClickFun=function(){
  560. //点击查看全部服务
  561. $(".coninfobox").on("click", "#seeMoreS", function() {
  562. document.body.scrollTop = document.documentElement.scrollTop = 0;
  563. $("#tab9user").addClass("liNow").siblings().removeClass("liNow");
  564. $("#item1user").hide();
  565. $("#item9user").show();
  566. })
  567. //点击查看全部资源
  568. $(".coninfobox").on("click", "#seeMoreR", function() {
  569. document.body.scrollTop = document.documentElement.scrollTop = 0;
  570. $("#tab2user").addClass("liNow").siblings().removeClass("liNow");
  571. $("#item1user").hide();
  572. $("#item2user").show();
  573. })
  574. //点击查看全部文章
  575. $(".coninfobox").on("click", "#seeMoreA", function() {
  576. document.body.scrollTop = document.documentElement.scrollTop = 0;
  577. $("#tab3user").addClass("liNow").siblings().removeClass("liNow");
  578. $("#item1user").hide();
  579. $("#item3user").show();
  580. })
  581. $("#attendmyGo").on("click",function(){
  582. $(".mainNavUl li.rightbtn").addClass("liNow").siblings().removeClass("liNow");
  583. $("#item8more").show();
  584. $("#item8user").show().siblings().hide();
  585. $(".moreBuUl li.attendMy").addClass("liNow").siblings().removeClass("liNow");
  586. $("#item8drop1").show().siblings().hide();
  587. })
  588. }
  589. queryPubCount();
  590. getCmpInfo(); //获取详细信息
  591. demandListVal(true);
  592. articalListVal(true);
  593. bindClickFun();
  594. attentMyself(true);
  595. })