|
@ -1,292 +0,0 @@
|
|
|
var template = ''
|
|
|
$.ajax('../html/mzfHzcx.html',{
|
|
|
data: {},
|
|
|
dataType: 'html',
|
|
|
cache: false,
|
|
|
timeout: 60000,
|
|
|
async: false,
|
|
|
error: function(res) {
|
|
|
},
|
|
|
success: function(res) {
|
|
|
template = res
|
|
|
}
|
|
|
})
|
|
|
Vue.component('mzf-hzcx', {
|
|
|
props: [],
|
|
|
template: template,
|
|
|
data: function() {
|
|
|
return {
|
|
|
tableData:[],
|
|
|
testArr1: [],
|
|
|
testArr2: [],
|
|
|
testPosition1: 0,
|
|
|
testPosition2: 0,
|
|
|
list:[],
|
|
|
startTime:new Date('2023','05','26'),
|
|
|
endTime:new Date(),
|
|
|
regionData:[
|
|
|
{label:'全部',value:'8'},
|
|
|
{label:'未管理',value:'0'},
|
|
|
{label:'在管',value:'1'},
|
|
|
{label:'失访',value:'2'},
|
|
|
{label:'出组',value:'3'},
|
|
|
{label:'不纳入管理 ',value:'4'},
|
|
|
{label:'入组 ',value:'5'},
|
|
|
{label:'死亡 ',value:'6'},
|
|
|
{label:'已管理 ',value:'7'},
|
|
|
],
|
|
|
region: '8', //管理状态
|
|
|
|
|
|
tertiaryHospitalsData:[],
|
|
|
tertiary: '', //地区
|
|
|
|
|
|
communityHospitalsData:[],
|
|
|
communityHospitals:'', // 三级医院
|
|
|
|
|
|
groupingData:[],
|
|
|
group: '', // 社区
|
|
|
|
|
|
stageType: '0,1,2,10,20',// 阶段
|
|
|
// 0:慢阻肺测试患者 1:第一阶段 2:第二阶段 10:测试账号 20:其他' 全部 0,1,2,10,20
|
|
|
stageData: [
|
|
|
{label:'全部',value:'0,1,2,10,20'},
|
|
|
{label:'慢阻肺测试患者',value:'0'},
|
|
|
{label:'第二阶段 ',value:'1'},
|
|
|
{label:'测试账号',value:'10'},
|
|
|
{label:'其他',value:'20'},
|
|
|
],
|
|
|
|
|
|
queryLevel: 1, // :1.全部 2.区 3.等级医院 4.社区医院
|
|
|
patientName: '', // 患者姓名
|
|
|
administrationStatusList:[],
|
|
|
administrationStatusData:[
|
|
|
{label:'全部',id:'1',type:'5'}
|
|
|
],
|
|
|
show:false,
|
|
|
showTwo:false,
|
|
|
showThree:false,
|
|
|
currentPage:1,
|
|
|
currentSize:10,
|
|
|
datatotal:0, //总数
|
|
|
loadingTwo:false,
|
|
|
setDisabled:{
|
|
|
disabledDate:function(time) {
|
|
|
return time.getTime() < new Date('2023','05','26') || time.getTime() > Date.now();
|
|
|
}
|
|
|
},
|
|
|
s:'',
|
|
|
e:'',
|
|
|
dialogVisible: false,
|
|
|
dataInfo: [],
|
|
|
dialogVisible1: false,
|
|
|
dataJl: []
|
|
|
}
|
|
|
},
|
|
|
created: function(){
|
|
|
this.s = this.startTime.format('yyyy-MM-dd')
|
|
|
this.e = this.endTime.format('yyyy-MM-dd')
|
|
|
this.list.unshift({type:'0',id:'time',label:this.s +"~"+ this.e})
|
|
|
|
|
|
this.getCopdPatientInfoList(1, 1, '350200')
|
|
|
this.cascadingFindHosptail(1, '')
|
|
|
},
|
|
|
watch:{
|
|
|
'startTime':{
|
|
|
handler:function(o) {
|
|
|
if(!o) {
|
|
|
this.list.splice(0,1)
|
|
|
}
|
|
|
},
|
|
|
deep: true,
|
|
|
immediate: true
|
|
|
},
|
|
|
'endTime':{
|
|
|
handler:function(o) {
|
|
|
if(!o) {
|
|
|
this.list.splice(0,1)
|
|
|
}
|
|
|
},
|
|
|
deep: true,
|
|
|
immediate: true
|
|
|
},
|
|
|
},
|
|
|
methods: {
|
|
|
// 获取地区
|
|
|
cascadingFindHosptail: function(type, val, hos) {
|
|
|
var vm = this
|
|
|
var data = {
|
|
|
findType: type ? type: 1,
|
|
|
areaCode: val.length!=0 ? val.join(',') : '',
|
|
|
hosptialCode: hos ? hos.join(',') : ''
|
|
|
}
|
|
|
statisticAPI.cascadingFindHosptail({
|
|
|
jsonStr: JSON.stringify(data)
|
|
|
}).then(function(res){
|
|
|
if(res.status===200) {
|
|
|
console.log(res, 'dq');
|
|
|
if(type == 2) {
|
|
|
vm.communityHospitalsData = res.data
|
|
|
} else if(type == 3) {
|
|
|
vm.groupingData = res.data
|
|
|
}
|
|
|
else {
|
|
|
vm.tertiaryHospitalsData = res.data
|
|
|
}
|
|
|
}
|
|
|
})
|
|
|
},
|
|
|
tertiaryChange: function(val) {
|
|
|
console.log(val, 'xz');
|
|
|
var vm = this
|
|
|
vm.queryLevel = 2
|
|
|
vm.cascadingFindHosptail(2, val)
|
|
|
},
|
|
|
comChange: function (val) {
|
|
|
console.log(val, 'xz');
|
|
|
var vm = this
|
|
|
vm.queryLevel = 3
|
|
|
vm.cascadingFindHosptail(3, vm.tertiary , val)
|
|
|
},
|
|
|
groChange() {
|
|
|
var vm = this
|
|
|
vm.queryLevel = 4
|
|
|
},
|
|
|
getCopdPatientInfoList:function (page, queryLevel, code) {
|
|
|
var vm = this
|
|
|
vm.loadingTwo = true
|
|
|
var data = {
|
|
|
startTime:this.startTime.format('yyyy-MM-dd'),
|
|
|
endTime:this.endTime.format('yyyy-MM-dd'),
|
|
|
stageType: vm.stageType,
|
|
|
findType: 2,
|
|
|
copdState: vm.region,
|
|
|
page: page,
|
|
|
size: 10,
|
|
|
searchKey: vm.patientName,
|
|
|
queryLevel: queryLevel,
|
|
|
queryCode: code,
|
|
|
hosptialCode: '', // 医院code
|
|
|
pageIf: "true"
|
|
|
}
|
|
|
statisticAPI.getCopdPatientInfoList({
|
|
|
json:JSON.stringify(data)
|
|
|
}).then(function(res){
|
|
|
if(res.status == 200) {
|
|
|
console.log(res,'hc');
|
|
|
vm.loadingTwo = false
|
|
|
vm.tableData = res.data.list
|
|
|
vm.datatotal = res.data.count
|
|
|
}
|
|
|
}).catch(function(err){
|
|
|
vm.loadingTwo = false
|
|
|
})
|
|
|
},
|
|
|
startTimeChange:function(o) {
|
|
|
if(!this.list[0] || this.list[0].type!=0) {
|
|
|
this.list.unshift({type:'0',id:'time',label:o.format('yyyy-MM-dd') +"~"+ this.endTime.format('yyyy-MM-dd')})
|
|
|
}else{
|
|
|
this.list[0].label = o.format('yyyy-MM-dd') +"~"+ this.endTime.format('yyyy-MM-dd')
|
|
|
}
|
|
|
},
|
|
|
endTimeChange:function(o) {
|
|
|
if(!this.list[0] || this.list[0].type!=0) {
|
|
|
this.list.unshift({type:'0',id:'time',label:this.startTime.format('yyyy-MM-dd') +"~"+ o.format('yyyy-MM-dd')})
|
|
|
}else{
|
|
|
this.list[0].label = this.startTime.format('yyyy-MM-dd') +"~"+ o.format('yyyy-MM-dd')
|
|
|
}
|
|
|
},
|
|
|
deleteClick:function(item) {
|
|
|
if(item.id == "time") {
|
|
|
this.startTime = ''
|
|
|
this.endTime = ''
|
|
|
this.list.splice(0,1)
|
|
|
}
|
|
|
var index = this.list.findIndex(function(v){
|
|
|
return item.id == v.id
|
|
|
})
|
|
|
this.list.splice(index,1)
|
|
|
},
|
|
|
// 下一页 上一页
|
|
|
handleCurrentChange:function(val) {
|
|
|
var vm = this
|
|
|
vm.currentPage = val
|
|
|
vm.getCopdPatientInfoList(val)
|
|
|
},
|
|
|
change:function(val) {
|
|
|
this.list = this.list.concat(val)
|
|
|
},
|
|
|
// 确定
|
|
|
confirm:function() {
|
|
|
// 全部 , 也是默认
|
|
|
if(this.queryLevel == 1) {
|
|
|
this.findCopdHealthInfoList(1, 1 , '')
|
|
|
} else if(this.queryLevel == 2) {
|
|
|
// 地区
|
|
|
var areaCode = this.tertiary.join(',')
|
|
|
this.findCopdHealthInfoList('', this.queryLevel, areaCode)
|
|
|
}else if(this.queryLevel == 3) {
|
|
|
// 三级医院
|
|
|
var areaCode = this.communityHospitals.join(',')
|
|
|
this.findCopdHealthInfoList('', this.queryLevel, areaCode)
|
|
|
}else if(this.queryLevel == 4) {
|
|
|
// 社区
|
|
|
var areaCode = this.group.join(',')
|
|
|
this.findCopdHealthInfoList('', this.queryLevel, areaCode)
|
|
|
}
|
|
|
|
|
|
},
|
|
|
// 取消
|
|
|
cancel:function() {
|
|
|
this.startTime = new Date('2023','05','26')
|
|
|
this.endTime = new Date()
|
|
|
this.tertiary = '',
|
|
|
this.communityHospitals = ''
|
|
|
this.group = ''
|
|
|
this.queryLevel = 1
|
|
|
},
|
|
|
// 查看
|
|
|
showInfo: function(item) {
|
|
|
var vm = this
|
|
|
vm.dialogVisible = true
|
|
|
// patientCode
|
|
|
var data = {
|
|
|
patientCode: item.patientCode
|
|
|
}
|
|
|
statisticAPI.findCopdHealthInfoByCode({
|
|
|
jsonStr:JSON.stringify(data)
|
|
|
}).then(function(res){
|
|
|
if(res.status == 200) {
|
|
|
console.log(res,'info');
|
|
|
}
|
|
|
})
|
|
|
},
|
|
|
// 记录
|
|
|
showJl: function() {
|
|
|
var vm = this
|
|
|
vm.dialogVisible1 = true
|
|
|
// patientCode
|
|
|
var data = {
|
|
|
patientCode: item.patientCode
|
|
|
}
|
|
|
statisticAPI.findCopdHealthInfoByCode({
|
|
|
jsonStr:JSON.stringify(data)
|
|
|
}).then(function(res){
|
|
|
if(res.status == 200) {
|
|
|
console.log(res,'info');
|
|
|
}
|
|
|
})
|
|
|
},
|
|
|
// 导出
|
|
|
exportHandle:function() {
|
|
|
var vm = this
|
|
|
vm.loadingTwo = true
|
|
|
statisticAPI.exportHospitalWorkStatistics({
|
|
|
startDate:this.startTime.format('yyyy-MM-dd'),
|
|
|
endDate:this.endTime.format('yyyy-MM-dd')
|
|
|
},'慢阻肺入组进度表.xls').then(function(res){
|
|
|
vm.loadingTwo = false
|
|
|
})
|
|
|
},
|
|
|
|
|
|
}
|
|
|
})
|