|
@@ -18,11 +18,11 @@ let iconMark = require('./../images/icon_mark.png')
|
|
|
const $ = require("jquery");
|
|
|
const { post,config,getUrlArgObject,openNewWin,titleConfig } = require('./promise.js');
|
|
|
const { transConf } = require('./util.js');
|
|
|
-const {renderWrapper, renderCaseStandard,renderWarning,renderRecommendInfo,renderMultRecommendInfo,renderRecommendConditTips} = require('./cdssDom.js');
|
|
|
+// const {renderWrapper, renderCaseStandard,renderWarning,renderRecommendInfo,renderMultRecommendInfo,renderRecommendConditTips} = require('./cdssDom.js');
|
|
|
const { data } = require('jquery');
|
|
|
const { render } = require('less');
|
|
|
|
|
|
-
|
|
|
+//静态知识类型: 1:诊断 2.药品 3.化验套餐 4.化验明细 5.辅检 6.手术和操作
|
|
|
|
|
|
|
|
|
let moduleConfig={
|
|
@@ -41,7 +41,7 @@ let msg;
|
|
|
function getMRInfo() {
|
|
|
return post(config.getMr2,{mrId:mrId})
|
|
|
}
|
|
|
-$('.loading').css("display","block")
|
|
|
+// $('.loading').css("display","block")
|
|
|
$('.empty').css("display","none")
|
|
|
getMRInfo().then(res =>{
|
|
|
if(res.data.code == '0'){
|
|
@@ -90,11 +90,11 @@ function getConf() {
|
|
|
}
|
|
|
|
|
|
function getPushInfo() {
|
|
|
- return post(config.pushInner,Object.assign(msg,{featureType: '1,4,5,6,7,22',hospitalId:2,ruleType:config.ruleTypeMap['22']}))
|
|
|
+ return post(config.pushInner,Object.assign(msg,{featureType: '1,4,5,6,7,8,9',hospitalId:msg.hospitalId||2,ruleType:config.ruleTypeMap['22']}))
|
|
|
|
|
|
}
|
|
|
function getPusgWarning(){
|
|
|
- return post(config.indicationPush,Object.assign(msg,{ruleType: '1,2,3,4',hospitalId:2,ruleType:config.ruleTypeMap['22']}))
|
|
|
+ return post(config.indicationPush,Object.assign(msg,{ruleType: '1,2,3',hospitalId:msg.hospitalId||2}))
|
|
|
}
|
|
|
|
|
|
|
|
@@ -187,10 +187,10 @@ function getVersion() {
|
|
|
})
|
|
|
}
|
|
|
function getDisclaimer() {
|
|
|
- post(config.disclaimer, "").then((res) => {
|
|
|
+ post(config.disclaimer, {}).then((res) => {
|
|
|
const data = res.data.data.find(item => item.disclaimerCode == "2");
|
|
|
$(".responsibility").html(data.description);
|
|
|
- $(".iframeWrap").css({height: $(window).height()-115-$(".responsibility").height()+"px"})
|
|
|
+ // $(".iframeWrap").css({height: $(window).height()-115-$(".responsibility").height()+"px"})
|
|
|
|
|
|
})
|
|
|
}
|
|
@@ -199,7 +199,7 @@ function renderPage(pageSet){
|
|
|
renderTab(pageSet.sysSetInfo)
|
|
|
const iframeHei = $(".bodyWrap").height()
|
|
|
const tabHei = $(".tabList").height()
|
|
|
- $(".contentWrapper").css("height",iframeHei-tabHei-10+'px')
|
|
|
+ $(".contentWrapper").css("height",iframeHei-tabHei-10-20-30+'px')
|
|
|
const hasAuxiliary = hasTab("辅助信息",pageSet.sysSetInfo)
|
|
|
const hasMedical = hasTab("医学知识",pageSet.sysSetInfo)
|
|
|
|
|
@@ -224,26 +224,35 @@ function renderPushData(){
|
|
|
if(res.data.code == "0"){
|
|
|
const result = res.data.data
|
|
|
let diagPush = result.dis
|
|
|
-
|
|
|
let lisPush = result.lis || []
|
|
|
let pacsPush = result.pacs || []
|
|
|
let symptomPush = result.symptom ||[]
|
|
|
let checkupPush = result.vital ||[]
|
|
|
-
|
|
|
+ let medicinesPush = result.medicines || []
|
|
|
+ let operationsPush = result.operations ||[]
|
|
|
// let lisPush =[{name:"血常规",hisNameList:null},{name:"尿常规",hisNameList:null},{name:"尿常规",hisNameList:null},{name:"尿常规",hisNameList:null},{name:"尿常规",hisNameList:null},{name:"尿常规",hisNameList:null}]
|
|
|
// let pacsPush = [{name:"胸部x射线",hisNameList:null},{name:"心电图",hisNameList:null}]
|
|
|
// let checkupPush = [{name:"神志表情",hisNameList:null},{name:"面部表情",hisNameList:null}]
|
|
|
- renderLis(lisPush,5,null,true)
|
|
|
- renderPacs(pacsPush,5,null,true)
|
|
|
- renderCheckup(checkupPush,5,null,false)
|
|
|
- renderSymptomPush(symptomPush,5,null,true)
|
|
|
+ let lisNum = $(".moduleItem.lis").attr("data-num") || 5
|
|
|
+ let pacsNum = $(".moduleItem.pacs").attr("data-num") || 5
|
|
|
+ let checkupNum = $(".moduleItem.vital").attr("data-num") || 5
|
|
|
+ let symptomNum = $(".moduleItem.symptom").attr("data-num") || 5
|
|
|
+ let medicinesNum = $(".moduleItem.medicine").attr("data-num") || 5
|
|
|
+ let operationsNum = $(".moduleItem.operation").attr("data-num") || 5
|
|
|
+
|
|
|
+ renderLis(lisPush,lisNum,3,true)
|
|
|
+ renderPacs(pacsPush,pacsNum,5,true)
|
|
|
+ renderCheckup(checkupPush,checkupNum,null,false)
|
|
|
+ renderSymptomPush(symptomPush,symptomNum,null,false)
|
|
|
renderDiag(diagPush)
|
|
|
- if(hasCompleteTnterface === allInterface){
|
|
|
- $('.loading').css("display","none")
|
|
|
- if(moduleNum === 0){
|
|
|
- empty()
|
|
|
- }
|
|
|
- }
|
|
|
+ renderMedicinesPush(medicinesPush,medicinesNum,2,true)
|
|
|
+ renderOperationPush(operationsPush,operationsNum,6,false)
|
|
|
+ // if(hasCompleteTnterface === allInterface){
|
|
|
+ // $('.loading').css("display","none")
|
|
|
+ // if(moduleNum === 0){
|
|
|
+ // empty()
|
|
|
+ // }
|
|
|
+ // }
|
|
|
bindOpenInfo()
|
|
|
bindSlide()
|
|
|
}
|
|
@@ -285,13 +294,14 @@ function renderPushWarning(){
|
|
|
renderBillingPush(criticalValList,'危急值提醒')
|
|
|
renderBillingPush(noteList,'检查内容注意事项')
|
|
|
// renderBillingPush(dubugStr,'注意调试信息')
|
|
|
- if(hasCompleteTnterface === allInterface){
|
|
|
- $('.loading').css("display","none")
|
|
|
- if(moduleNum === 0){
|
|
|
- empty()
|
|
|
- }
|
|
|
- }
|
|
|
+
|
|
|
}
|
|
|
+ // if(hasCompleteTnterface === allInterface){
|
|
|
+ // $('.loading').css("display","none")
|
|
|
+ // if(moduleNum === 0){
|
|
|
+ // empty()
|
|
|
+ // }
|
|
|
+ // }
|
|
|
|
|
|
})
|
|
|
}
|
|
@@ -310,6 +320,7 @@ function renderBillingPush(list,name){
|
|
|
${str}
|
|
|
</div>`
|
|
|
$(".tips").append(boxStr)
|
|
|
+ $('.moduleItem.tips').css("display","block")
|
|
|
}
|
|
|
|
|
|
|
|
@@ -317,33 +328,49 @@ function renderDiag(diagPush){
|
|
|
let possibleDiagPush = diagPush["可能诊断"] || []
|
|
|
let firstDiagPush = diagPush["初步诊断"] || []
|
|
|
let identifyDiagPush = diagPush["鉴别诊断"] || []
|
|
|
-
|
|
|
+ let warningDiagPush = diagPush["警惕"] || []
|
|
|
+ let number = $('.moduleItem.diag').attr("data-num") || 5
|
|
|
+ let warnNumber = $('.moduleItem.warning').attr("data-num") || 5
|
|
|
+
|
|
|
+ $('.moduleItem.diag').append(titleStr("diagPush"))
|
|
|
// let firstDiagPush = [{name:"血常规",hisNameList:null},{name:"尿常规",hisNameList:null},{name:"尿常规",hisNameList:null},{name:"尿常规",hisNameList:null},{name:"尿常规",hisNameList:null},{name:"尿常规",hisNameList:null}]
|
|
|
// let identifyDiagPush = diagPush["鉴别诊断"] || [{name:"血常规",hisNameList:null},{name:"尿常规",hisNameList:null},{name:"尿常规",hisNameList:null},{name:"尿常规",hisNameList:null},{name:"尿常规",hisNameList:null},{name:"尿常规",hisNameList:null}]
|
|
|
- $('.moduleItem.diag').append(titleStr("diagPush"))
|
|
|
- renderDiagItem(possibleDiagPush,"可能诊断")
|
|
|
- renderDiagItem(firstDiagPush,"初步诊断")
|
|
|
- renderDiagItem(identifyDiagPush,"鉴别诊断")
|
|
|
+ renderDiagItem(possibleDiagPush,"可能诊断",number)
|
|
|
+ renderDiagItem(firstDiagPush,"初步诊断",number)
|
|
|
+ renderDiagItem(identifyDiagPush,"鉴别诊断",number)
|
|
|
+ // renderWarningDiag(warningDiagPush,"警惕",warnNumber)
|
|
|
|
|
|
}
|
|
|
|
|
|
-function renderDiagItem(list,name){
|
|
|
+function renderDiagItem(list,name,number){
|
|
|
if(list.length === 0){
|
|
|
return
|
|
|
}
|
|
|
let titleStr = titleStr2(name)
|
|
|
- let {shortStr, longStr} = renderItemWrapper(list,5,null,true)
|
|
|
+ let {shortStr, longStr} = renderItemWrapper(list,number,1,true)
|
|
|
let boxStr = `<div class="moduleBox">
|
|
|
${titleStr}
|
|
|
${shortStr}
|
|
|
${longStr}
|
|
|
</div>`
|
|
|
$(".diag").append(boxStr)
|
|
|
+ $('.moduleItem.diag').css("display","block")
|
|
|
+}
|
|
|
+function renderWarningDiag(list,name,number){
|
|
|
+ if(list.length > 0 && $(".moduleItem.warning").length > 0){
|
|
|
+ moduleNum++
|
|
|
+ $('.moduleItem.warning').append()
|
|
|
+ let str = ``
|
|
|
+ for(let i = 0; i < list.length; i++){
|
|
|
+ str+= renderPushItem(list[i].name,1,true)
|
|
|
+ }
|
|
|
+ $('.moduleItem.warning').append(str)
|
|
|
+ $('.moduleItem.lis').css("display","block")
|
|
|
+ }
|
|
|
}
|
|
|
-
|
|
|
|
|
|
function renderLis(list,showNum,type,hasInfo){
|
|
|
- if(list.length > 0 && $(".moduleItem.pacs").length > 0){
|
|
|
+ if(list.length > 0 && $(".moduleItem.lis").length > 0){
|
|
|
moduleNum++
|
|
|
$('.moduleItem.lis').append(titleStr("lisPush"))
|
|
|
let {shortStr, longStr} = renderItemWrapper(list,showNum,type,hasInfo)
|
|
@@ -373,15 +400,38 @@ function renderCheckup(list,showNum,type,hasInfo){
|
|
|
}
|
|
|
}
|
|
|
function renderSymptomPush(list,showNum,type,hasInfo){
|
|
|
- if(list.length > 0 && $(".moduleItem.vital").length > 0){
|
|
|
+ $(".moduleItem.symptom").append(titleStr('symptomPush'))
|
|
|
+
|
|
|
+ if(list.length > 0 && $(".moduleItem.symptom").length > 0){
|
|
|
moduleNum++
|
|
|
- $(".moduleItem.symptom").append(titleStr('symptomPush'))
|
|
|
let {shortStr, longStr} = renderItemWrapper(list,showNum,type,hasInfo)
|
|
|
$(".moduleItem.symptom").append(shortStr).append(longStr)
|
|
|
$(".moduleItem.symptom").css("display","block")
|
|
|
}
|
|
|
|
|
|
}
|
|
|
+function renderMedicinesPush(list,showNum,type,hasInfo){
|
|
|
+ $(".moduleItem.medicine").append(titleStr('drugPush'))
|
|
|
+
|
|
|
+ if(list.length > 0 && $(".moduleItem.medicine").length > 0){
|
|
|
+ moduleNum++
|
|
|
+ let {shortStr, longStr} = renderItemWrapper(list,showNum,type,hasInfo)
|
|
|
+ $(".moduleItem.medicine").append(shortStr).append(longStr)
|
|
|
+ $(".moduleItem.medicine").css("display","block")
|
|
|
+ }
|
|
|
+
|
|
|
+}
|
|
|
+function renderOperationPush(list,showNum,type,hasInfo){
|
|
|
+ $(".moduleItem.operation").append(titleStr('operationPush'))
|
|
|
+
|
|
|
+ if(list.length > 0 && $(".moduleItem.operation").length > 0){
|
|
|
+ moduleNum++
|
|
|
+ let {shortStr, longStr} = renderItemWrapper(list,showNum,type,hasInfo)
|
|
|
+ $(".moduleItem.operation").append(shortStr).append(longStr)
|
|
|
+ $(".moduleItem.operation").css("display","block")
|
|
|
+ }
|
|
|
+
|
|
|
+}
|
|
|
|
|
|
|
|
|
|
|
@@ -443,9 +493,17 @@ function bindSlide(){
|
|
|
function renderModuleWrapper(moduleList){
|
|
|
let moduleStr = ''
|
|
|
for(let i = 0; i < moduleList.length; i++){
|
|
|
- if(moduleList[i].status !='0'){
|
|
|
- moduleStr += `<div class="moduleItem ${moduleList[i].code}" style="display:none"></div>`
|
|
|
- }
|
|
|
+ // if(moduleList[i].status !='0'){
|
|
|
+ if(moduleList[i].code == 'treat'){
|
|
|
+ moduleStr += `<div class="moduleItem medicine" data-num="${moduleList[i].number}" style="display:none"></div>`
|
|
|
+ moduleStr += `<div class="moduleItem operation" data-num="${moduleList[i].number}" style="display:none"></div>`
|
|
|
+ }else if(moduleList[i].code == 'tips'){
|
|
|
+ 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)
|
|
@@ -508,8 +566,8 @@ function empty(){
|
|
|
|
|
|
|
|
|
$(function(){
|
|
|
- // getDisclaimer(); //获取免责声明
|
|
|
- // getVersion(); //获取版本信息
|
|
|
+ getDisclaimer(); //获取免责声明
|
|
|
+ getVersion(); //获取版本信息
|
|
|
$(".disclaimerInfo").on("click", function(){
|
|
|
openNewWin("disclaimer.html")
|
|
|
});
|