|
@@ -755,8 +755,10 @@ function renderPushItem(item, name, index, totalItems) {
|
|
|
}
|
|
|
str = `<span class="pushItemBox" data-name="${item.name}" data-type="${item.type}">`
|
|
|
|
|
|
- if (name === "经典病例") {
|
|
|
- str += `<span class="evaluation"><span class="pushItemName evaluationtitle">${item.type == 8 ? ('【' + item.name + '】') : item.name} ${signalStr}${infoIcon}<i class="hidden-i"></i></span></span>`;
|
|
|
+ if (name === "经典病例" && item.hasInfo == "1") {
|
|
|
+ str += `<span class="evaluation">
|
|
|
+ <span class="pushItemName evaluationtitle">${item.type == 8 ? ('【' + item.name + '】') : item.name} ${signalStr}${infoIcon}<i class="hidden-i"></i></span>
|
|
|
+ </span>`;
|
|
|
} else {
|
|
|
const additionalClasses = [
|
|
|
item.hasScale == "1" ? 'evaluationtitle' : '',
|
|
@@ -770,198 +772,198 @@ function renderPushItem(item, name, index, totalItems) {
|
|
|
// $(".pushItemBox").css("display", "flex")
|
|
|
return str;
|
|
|
}
|
|
|
-function bindOpenInfo() {
|
|
|
- $(".infoImg").on("mouseenter", function () {
|
|
|
- $(this).attr("src", infoImgOn)
|
|
|
- }).on("mouseleave", function () {
|
|
|
- $(this).attr("src", infoImg)
|
|
|
- })
|
|
|
-}
|
|
|
-
|
|
|
-function bindSlide() {
|
|
|
- $(".showMore").off("click").on("click", function () {
|
|
|
- $(this).parent().parent().find(".longBox").css("display", "block")
|
|
|
- $(this).parent().parent().find(".shortBox").css("display", "none")
|
|
|
- })
|
|
|
- $(".showLess").off("click").on("click", function () {
|
|
|
- $(this).parent().parent().find(".longBox").css("display", "none")
|
|
|
- $(this).parent().parent().find(".shortBox").css("display", "block")
|
|
|
- })
|
|
|
-}
|
|
|
+ function bindOpenInfo() {
|
|
|
+ $(".infoImg").on("mouseenter", function () {
|
|
|
+ $(this).attr("src", infoImgOn)
|
|
|
+ }).on("mouseleave", function () {
|
|
|
+ $(this).attr("src", infoImg)
|
|
|
+ })
|
|
|
+ }
|
|
|
|
|
|
-function renderModuleWrapper(moduleList) {
|
|
|
- if (!moduleList) {
|
|
|
- return
|
|
|
+ function bindSlide() {
|
|
|
+ $(".showMore").off("click").on("click", function () {
|
|
|
+ $(this).parent().parent().find(".longBox").css("display", "block")
|
|
|
+ $(this).parent().parent().find(".shortBox").css("display", "none")
|
|
|
+ })
|
|
|
+ $(".showLess").off("click").on("click", function () {
|
|
|
+ $(this).parent().parent().find(".longBox").css("display", "none")
|
|
|
+ $(this).parent().parent().find(".shortBox").css("display", "block")
|
|
|
+ })
|
|
|
}
|
|
|
- let moduleStr = ''
|
|
|
- for (let i = 0; i < moduleList.length; i++) {
|
|
|
- if (moduleList[i].status != '0') {
|
|
|
- if (moduleList[i].code == 'critical') {
|
|
|
- moduleStr += `<div class="moduleItem warning" data-num="${moduleList[i].number}" style="display:none"></div>`
|
|
|
- // moduleStr += `<div class="moduleItem tips" data-num="${moduleList[i].number}" style="display:none"></div>`
|
|
|
- } else {
|
|
|
- moduleStr += `<div class="moduleItem ${moduleList[i].code}" data-num="${moduleList[i].number}" style="display:none"></div>`
|
|
|
+
|
|
|
+ function renderModuleWrapper(moduleList) {
|
|
|
+ if (!moduleList) {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ let moduleStr = ''
|
|
|
+ for (let i = 0; i < moduleList.length; i++) {
|
|
|
+ if (moduleList[i].status != '0') {
|
|
|
+ if (moduleList[i].code == 'critical') {
|
|
|
+ moduleStr += `<div class="moduleItem warning" data-num="${moduleList[i].number}" style="display:none"></div>`
|
|
|
+ // moduleStr += `<div class="moduleItem tips" data-num="${moduleList[i].number}" style="display:none"></div>`
|
|
|
+ } else {
|
|
|
+ moduleStr += `<div class="moduleItem ${moduleList[i].code}" data-num="${moduleList[i].number}" style="display:none"></div>`
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
+ $(".recommendWrap").append(moduleStr)
|
|
|
}
|
|
|
- $(".recommendWrap").append(moduleStr)
|
|
|
-}
|
|
|
|
|
|
-function hasTab(tabName, tabList) {
|
|
|
- if (!tabList) {
|
|
|
- return
|
|
|
- }
|
|
|
- for (let i = 0; i < tabList.length; i++) {
|
|
|
- if (tabList[i].name == tabName) {
|
|
|
- return tabList[i]
|
|
|
+ function hasTab(tabName, tabList) {
|
|
|
+ if (!tabList) {
|
|
|
+ return
|
|
|
}
|
|
|
- }
|
|
|
- return false
|
|
|
-}
|
|
|
-function renderTab(tabList) {
|
|
|
- let tabStr = '<ul>'
|
|
|
- for (let i = 0; i < tabList.length; i++) {
|
|
|
- if (tabList[i].status == '1') {
|
|
|
- tabStr += `<li class="tab" data-name="${tabList[i].code}" ><span>${tabList[i].name}</span></li>`
|
|
|
+ for (let i = 0; i < tabList.length; i++) {
|
|
|
+ if (tabList[i].name == tabName) {
|
|
|
+ return tabList[i]
|
|
|
+ }
|
|
|
}
|
|
|
-
|
|
|
+ return false
|
|
|
}
|
|
|
- tabStr += `</ul><div class="numPop"></div>`;
|
|
|
- $(".tabList").append(tabStr)
|
|
|
- let tabNum = 0;
|
|
|
- if (isTcm == 'true') {
|
|
|
- tabNum = $(".tabList .tab").length - 1;
|
|
|
- }
|
|
|
- $(".tabList .tab").eq(tabNum).addClass("activeTab")
|
|
|
- let showModuleName = $(".tabList .tab").eq(tabNum).attr("data-name")
|
|
|
- getModuleShow(moduleConfig[showModuleName])
|
|
|
- bindTabClick()
|
|
|
-}
|
|
|
-
|
|
|
-function titleStr(type) {
|
|
|
- let titleStr = ''
|
|
|
- titleStr += `<h4 class="moduleTitle" style="background:${titleConfig[type].background}"><img class="titleIcon" src=${titleConfig[type].icon}>${titleConfig[type].name}</h4>`
|
|
|
- return titleStr
|
|
|
-}
|
|
|
-function titleStr2(name) {
|
|
|
- let titleStr = ''
|
|
|
- titleStr += `<p class="moduleBoxTitle">${name}:</p>`
|
|
|
- return titleStr
|
|
|
-}
|
|
|
-
|
|
|
-function bindTabClick() {
|
|
|
- $(".tabList .tab").off("click").on("click", function () {
|
|
|
- $(".activeTab").removeClass("activeTab")
|
|
|
- $(this).addClass("activeTab")
|
|
|
- const moduleName = $(this).attr("data-name")
|
|
|
- getModuleShow(moduleConfig[moduleName])
|
|
|
- if (moduleName == "medical") {
|
|
|
- $(".staticSearchT .ipt").find("input").focus()
|
|
|
- //$(".contentWrapper").css("overflowY","hidden")
|
|
|
- } else if (moduleName == 'followup') {
|
|
|
+ function renderTab(tabList) {
|
|
|
+ let tabStr = '<ul>'
|
|
|
+ for (let i = 0; i < tabList.length; i++) {
|
|
|
+ if (tabList[i].status == '1') {
|
|
|
+ tabStr += `<li class="tab" data-name="${tabList[i].code}" ><span>${tabList[i].name}</span></li>`
|
|
|
+ }
|
|
|
|
|
|
- // $(".contentWrapper").css("overflowY","auto")
|
|
|
}
|
|
|
- })
|
|
|
-}
|
|
|
-
|
|
|
-function getModuleShow(moduleClassName) {
|
|
|
- if ($(`.${moduleClassName}`).css("display") == "none") {
|
|
|
- $(".moduleWrapper").css("display", "none")
|
|
|
- $(`.${moduleClassName}`).css("display", "block")
|
|
|
+ tabStr += `</ul><div class="numPop"></div>`;
|
|
|
+ $(".tabList").append(tabStr)
|
|
|
+ let tabNum = 0;
|
|
|
+ if (isTcm == 'true') {
|
|
|
+ tabNum = $(".tabList .tab").length - 1;
|
|
|
+ }
|
|
|
+ $(".tabList .tab").eq(tabNum).addClass("activeTab")
|
|
|
+ let showModuleName = $(".tabList .tab").eq(tabNum).attr("data-name")
|
|
|
+ getModuleShow(moduleConfig[showModuleName])
|
|
|
+ bindTabClick()
|
|
|
+ }
|
|
|
+
|
|
|
+ function titleStr(type) {
|
|
|
+ let titleStr = ''
|
|
|
+ titleStr += `<h4 class="moduleTitle" style="background:${titleConfig[type].background}"><img class="titleIcon" src=${titleConfig[type].icon}>${titleConfig[type].name}</h4>`
|
|
|
+ return titleStr
|
|
|
+ }
|
|
|
+ function titleStr2(name) {
|
|
|
+ let titleStr = ''
|
|
|
+ titleStr += `<p class="moduleBoxTitle">${name}:</p>`
|
|
|
+ return titleStr
|
|
|
+ }
|
|
|
+
|
|
|
+ function bindTabClick() {
|
|
|
+ $(".tabList .tab").off("click").on("click", function () {
|
|
|
+ $(".activeTab").removeClass("activeTab")
|
|
|
+ $(this).addClass("activeTab")
|
|
|
+ const moduleName = $(this).attr("data-name")
|
|
|
+ getModuleShow(moduleConfig[moduleName])
|
|
|
+ if (moduleName == "medical") {
|
|
|
+ $(".staticSearchT .ipt").find("input").focus()
|
|
|
+ //$(".contentWrapper").css("overflowY","hidden")
|
|
|
+ } else if (moduleName == 'followup') {
|
|
|
+
|
|
|
+ // $(".contentWrapper").css("overflowY","auto")
|
|
|
+ }
|
|
|
+ })
|
|
|
}
|
|
|
-}
|
|
|
-function bindGeneralSlide() {
|
|
|
- $(".showMoreGeneralTreat").off("click").on("click", function () {
|
|
|
- $(".generalTreatInfo").toggleClass("isOverFlow")
|
|
|
- $(".showMoreGeneralTreat").toggle()
|
|
|
- })
|
|
|
- $(".showLessGeneralTreat").off("click").on("click", function () {
|
|
|
- $(".generalTreatInfo").toggleClass("isOverFlow")
|
|
|
- $(".showMoreGeneralTreat").toggle()
|
|
|
- })
|
|
|
-
|
|
|
-}
|
|
|
-function bindSlideCaseWriting() {
|
|
|
- $(".showMoreCaseWriting").off("click").on("click", function () {
|
|
|
- $(this).parents(".casewritingWrapper ").find(".shortStrBox").css("display", "none")
|
|
|
- $(this).parents(".casewritingWrapper ").find(".longStrBox").css("display", "block")
|
|
|
- })
|
|
|
- $(".showLessCaseWriting").off("click").on("click", function () {
|
|
|
- $(this).parents(".casewritingWrapper ").find(".shortStrBox").css("display", "block")
|
|
|
- $(this).parents(".casewritingWrapper ").find(".longStrBox").css("display", "none")
|
|
|
- })
|
|
|
|
|
|
-}
|
|
|
-
|
|
|
-//显示空状态
|
|
|
-function empty() {
|
|
|
- ifInputParam = hasInputParam();
|
|
|
- if (!ifInputParam) { //没有输入数据时
|
|
|
- $(".recommendBox .empty-box").hide();
|
|
|
- $(".recommendBox .empty").show();
|
|
|
- return;
|
|
|
- }
|
|
|
- if (hasCompleteTnterface === allInterface) { //需调的推送接口全部返回后
|
|
|
- setTimeout(function () {
|
|
|
- const emptyShownBox = $('.recommendWrap .empty-box:visible').length;
|
|
|
- const configShownBox = $('.recommendWrap .moduleItem:visible').length;
|
|
|
- if (configShownBox === 0 && emptyShownBox === 0) { //有配置但没数据
|
|
|
- $('.empty-box').hide();
|
|
|
- $('.recommendBox .empty-null').show();
|
|
|
- return;
|
|
|
- }
|
|
|
- $(".empty-box").hide();
|
|
|
- }, 200);
|
|
|
+ function getModuleShow(moduleClassName) {
|
|
|
+ if ($(`.${moduleClassName}`).css("display") == "none") {
|
|
|
+ $(".moduleWrapper").css("display", "none")
|
|
|
+ $(`.${moduleClassName}`).css("display", "block")
|
|
|
+ }
|
|
|
}
|
|
|
- /*setTimeout(function(){
|
|
|
- const emptyShownBox = $('.recommendWrap .empty-box:visible').length;
|
|
|
- const configShownBox = $('.recommendWrap .moduleItem:visible').length;
|
|
|
- if(configShownBox===0&&emptyShownBox===0){ //有配置但没数据
|
|
|
+ function bindGeneralSlide() {
|
|
|
+ $(".showMoreGeneralTreat").off("click").on("click", function () {
|
|
|
+ $(".generalTreatInfo").toggleClass("isOverFlow")
|
|
|
+ $(".showMoreGeneralTreat").toggle()
|
|
|
+ })
|
|
|
+ $(".showLessGeneralTreat").off("click").on("click", function () {
|
|
|
+ $(".generalTreatInfo").toggleClass("isOverFlow")
|
|
|
+ $(".showMoreGeneralTreat").toggle()
|
|
|
+ })
|
|
|
+
|
|
|
+ }
|
|
|
+ function bindSlideCaseWriting() {
|
|
|
+ $(".showMoreCaseWriting").off("click").on("click", function () {
|
|
|
+ $(this).parents(".casewritingWrapper ").find(".shortStrBox").css("display", "none")
|
|
|
+ $(this).parents(".casewritingWrapper ").find(".longStrBox").css("display", "block")
|
|
|
+ })
|
|
|
+ $(".showLessCaseWriting").off("click").on("click", function () {
|
|
|
+ $(this).parents(".casewritingWrapper ").find(".shortStrBox").css("display", "block")
|
|
|
+ $(this).parents(".casewritingWrapper ").find(".longStrBox").css("display", "none")
|
|
|
+ })
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+ //显示空状态
|
|
|
+ function empty() {
|
|
|
+ ifInputParam = hasInputParam();
|
|
|
+ if (!ifInputParam) { //没有输入数据时
|
|
|
+ $(".recommendBox .empty-box").hide();
|
|
|
+ $(".recommendBox .empty").show();
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ if (hasCompleteTnterface === allInterface) { //需调的推送接口全部返回后
|
|
|
+ setTimeout(function () {
|
|
|
+ const emptyShownBox = $('.recommendWrap .empty-box:visible').length;
|
|
|
+ const configShownBox = $('.recommendWrap .moduleItem:visible').length;
|
|
|
+ if (configShownBox === 0 && emptyShownBox === 0) { //有配置但没数据
|
|
|
$('.empty-box').hide();
|
|
|
$('.recommendBox .empty-null').show();
|
|
|
return;
|
|
|
- }
|
|
|
- $(".empty-box").hide();
|
|
|
- },200);*/
|
|
|
-}
|
|
|
-
|
|
|
-$(function () {
|
|
|
- //隐藏logo
|
|
|
- if (getUrlArgObject("hideLg")) {
|
|
|
- $(".disclaimer .logo").hide();
|
|
|
- }
|
|
|
- getDisclaimer(); //获取免责声明
|
|
|
- getVersion(); //获取版本信息
|
|
|
- $(".disclaimerInfo").on("click", function () {
|
|
|
- openNewWin("disclaimer.html")
|
|
|
- });
|
|
|
- $(".version-tip").on("click", function () {
|
|
|
- const ver = localStorage.getItem('versionTime');
|
|
|
- $(".version-tip").removeClass('new-icon');
|
|
|
- localStorage.setItem('versionTime', ver.replace("=new", ""));
|
|
|
- openNewWin("version.html");
|
|
|
- });
|
|
|
- $.fn.extend({
|
|
|
- "preventScroll": function () {
|
|
|
- $(this).each(function () {
|
|
|
- var _this = this;
|
|
|
- if (navigator.userAgent.indexOf('Firefox') >= 0) { //firefox
|
|
|
- _this.addEventListener('DOMMouseScroll', function (e) {
|
|
|
- _this.scrollTop += e.detail > 0 ? 60 : -60;
|
|
|
- e.preventDefault();
|
|
|
- }, false);
|
|
|
- } else {
|
|
|
- _this.onmousewheel = function (e) {
|
|
|
- e = e || window.event;
|
|
|
- _this.scrollTop += e.wheelDelta > 0 ? -60 : 60;
|
|
|
- return false;
|
|
|
- };
|
|
|
}
|
|
|
- })
|
|
|
+ $(".empty-box").hide();
|
|
|
+ }, 200);
|
|
|
}
|
|
|
+ /*setTimeout(function(){
|
|
|
+ const emptyShownBox = $('.recommendWrap .empty-box:visible').length;
|
|
|
+ const configShownBox = $('.recommendWrap .moduleItem:visible').length;
|
|
|
+ if(configShownBox===0&&emptyShownBox===0){ //有配置但没数据
|
|
|
+ $('.empty-box').hide();
|
|
|
+ $('.recommendBox .empty-null').show();
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ $(".empty-box").hide();
|
|
|
+ },200);*/
|
|
|
+ }
|
|
|
+
|
|
|
+ $(function () {
|
|
|
+ //隐藏logo
|
|
|
+ if (getUrlArgObject("hideLg")) {
|
|
|
+ $(".disclaimer .logo").hide();
|
|
|
+ }
|
|
|
+ getDisclaimer(); //获取免责声明
|
|
|
+ getVersion(); //获取版本信息
|
|
|
+ $(".disclaimerInfo").on("click", function () {
|
|
|
+ openNewWin("disclaimer.html")
|
|
|
+ });
|
|
|
+ $(".version-tip").on("click", function () {
|
|
|
+ const ver = localStorage.getItem('versionTime');
|
|
|
+ $(".version-tip").removeClass('new-icon');
|
|
|
+ localStorage.setItem('versionTime', ver.replace("=new", ""));
|
|
|
+ openNewWin("version.html");
|
|
|
+ });
|
|
|
+ $.fn.extend({
|
|
|
+ "preventScroll": function () {
|
|
|
+ $(this).each(function () {
|
|
|
+ var _this = this;
|
|
|
+ if (navigator.userAgent.indexOf('Firefox') >= 0) { //firefox
|
|
|
+ _this.addEventListener('DOMMouseScroll', function (e) {
|
|
|
+ _this.scrollTop += e.detail > 0 ? 60 : -60;
|
|
|
+ e.preventDefault();
|
|
|
+ }, false);
|
|
|
+ } else {
|
|
|
+ _this.onmousewheel = function (e) {
|
|
|
+ e = e || window.event;
|
|
|
+ _this.scrollTop += e.wheelDelta > 0 ? -60 : 60;
|
|
|
+ return false;
|
|
|
+ };
|
|
|
+ }
|
|
|
+ })
|
|
|
+ }
|
|
|
+ });
|
|
|
+ $(window).on("resize", function () {
|
|
|
+ adjustHei()
|
|
|
+ })
|
|
|
});
|
|
|
- $(window).on("resize", function () {
|
|
|
- adjustHei()
|
|
|
- })
|
|
|
-});
|