|
@ -33,28 +33,28 @@
|
|
|
<div class="pt10">
|
|
|
<div class="pb20">
|
|
|
<van-row>
|
|
|
<van-col class="col col-tl" span="12">
|
|
|
<div class="operations-num">{{ maintain.addTotal }}</div>
|
|
|
<div class="operations-text"><span><img class="img" src="../../assets/images/waiting-equipment.png" alt=""></span>待入库设备数</div>
|
|
|
</van-col>
|
|
|
<van-col class="col" span="12">
|
|
|
<div class="operations-num">{{ maintain.hcWaringTotalNum }}</div>
|
|
|
<div class="operations-text"><span><img class="img" src="../../assets/images/thermometer.png" alt=""></span>温湿度预警数</div>
|
|
|
</van-col>
|
|
|
<van-col class="col col-t col-bl" span="12">
|
|
|
<div class="operations-num">{{ maintain.noOnlineTotal1WithUserId }}</div>
|
|
|
<div class="operations-text"><span><img class="img" src="../../assets/images/waiting-equipment.png" alt=""></span>离线设备数</div>
|
|
|
</van-col>
|
|
|
<van-col class="col col-t" span="12">
|
|
|
<div class="operations-num">{{ maintain.noGetDrugNum }}</div>
|
|
|
<div class="operations-text"><span><img class="img" src="../../assets/images/offline-medicine.png" alt=""></span>待取药订单数</div>
|
|
|
</van-col>
|
|
|
</van-row>
|
|
|
<van-col @click="gotoDevice()" class="col col-tl" span="12">
|
|
|
<div class="operations-num">{{ maintain.addTotal }}</div>
|
|
|
<div class="operations-text"><span><img class="img" src="../../assets/images/waiting-equipment.png" alt=""></span>待入库设备数</div>
|
|
|
</van-col>
|
|
|
<van-col @click="gotoDevice()" class="col" span="12">
|
|
|
<div class="operations-num">{{ maintain.hcWaringTotalNum }}</div>
|
|
|
<div class="operations-text"><span><img class="img" src="../../assets/images/thermometer.png" alt=""></span>温湿度预警数</div>
|
|
|
</van-col>
|
|
|
<van-col @click="gotoDevice()" class="col col-t col-bl" span="12">
|
|
|
<div class="operations-num">{{ maintain.noOnlineTotal1WithUserId }}</div>
|
|
|
<div class="operations-text"><span><img class="img" src="../../assets/images/waiting-equipment.png" alt=""></span>离线设备数</div>
|
|
|
</van-col>
|
|
|
<van-col @click="gotoUrl('/order/list')" class="col col-t" span="12">
|
|
|
<div class="operations-num">{{ maintain.noGetDrugNum }}</div>
|
|
|
<div class="operations-text"><span><img class="img" src="../../assets/images/offline-medicine.png" alt=""></span>待取药订单数</div>
|
|
|
</van-col>
|
|
|
</van-row>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
<!-- 取药次数 -->
|
|
|
<div class="panel plr15 mt10 medicine">
|
|
|
<div v-if="medicineShow" class="panel plr15 mt10 medicine">
|
|
|
<div class="kitbox pt15 box-flex-c">
|
|
|
<div class="box-flex-c c-333 fs-16 f-bold">取药次数</div>
|
|
|
<div class="box-flex-c c-333 fs-12 f-bold time">
|
|
@ -103,7 +103,7 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
<!-- 销售额 -->
|
|
|
<div class="panel plr15 mt10 medicine">
|
|
|
<div v-if="sales" class="panel plr15 mt10 medicine">
|
|
|
<div class="kitbox pt15 box-flex-c">
|
|
|
<div class="box-flex-c c-333 fs-16 f-bold">销售额</div>
|
|
|
<div class="box-flex-c c-333 fs-12 f-bold time">
|
|
@ -137,6 +137,9 @@ export default {
|
|
|
data() {
|
|
|
return {
|
|
|
medicineBag:'1',
|
|
|
medicineData:false,
|
|
|
medicineShow:true,
|
|
|
sales:true,
|
|
|
prescriptionBag:'1',
|
|
|
salesBag:'1',
|
|
|
count:[],
|
|
@ -170,6 +173,11 @@ export default {
|
|
|
this.countall();
|
|
|
this.medicine();
|
|
|
this.prescriptions();
|
|
|
console.log('this.$store.user.state',this.$store.state.user.curRoleCode)
|
|
|
if(this.$store.state.user.curRoleCode =='replenisher'){
|
|
|
this.medicineShow = false;
|
|
|
this.sales = false;
|
|
|
}
|
|
|
},
|
|
|
mounted(){
|
|
|
this.echartsData();
|
|
@ -182,7 +190,7 @@ export default {
|
|
|
userId: this.user.id
|
|
|
})
|
|
|
.then(res=>{
|
|
|
console.log('countall', res);
|
|
|
// console.log('countall', res);
|
|
|
this.overview = res.obj.overview;
|
|
|
this.maintain = res.obj.maintain;
|
|
|
})
|
|
@ -190,6 +198,11 @@ export default {
|
|
|
console.error(err)
|
|
|
})
|
|
|
},
|
|
|
//跳转
|
|
|
gotoDevice(){
|
|
|
this.$router.push('/device/index')
|
|
|
this.$store.commit('getDeviceActive' ,0);
|
|
|
},
|
|
|
// 取药次数
|
|
|
medicine(){
|
|
|
medicineAbinetApi
|
|
@ -199,10 +212,12 @@ export default {
|
|
|
})
|
|
|
.then(res=>{
|
|
|
console.log('medicine', res)
|
|
|
this.medicineData = true;
|
|
|
this.shippingType = res.obj;
|
|
|
})
|
|
|
.catch(err=>{
|
|
|
console.error(err)
|
|
|
console.error(err)
|
|
|
this.medicineData = true;
|
|
|
})
|
|
|
},
|
|
|
// 电子处方单
|
|
@ -222,16 +237,18 @@ export default {
|
|
|
},
|
|
|
// 取药时间查询
|
|
|
medicineTime(val){
|
|
|
if(val == '全部'){
|
|
|
this.medicineBag = '';
|
|
|
if(this.medicineData){
|
|
|
if(val == '全部'){
|
|
|
this.medicineBag = '';
|
|
|
console.log('全部')
|
|
|
}else{
|
|
|
this.medicineBag = val;
|
|
|
console.log('1,3,7,9')
|
|
|
}
|
|
|
this.medicineData = false;
|
|
|
this.medicine();
|
|
|
console.log('全部')
|
|
|
}else{
|
|
|
this.medicineBag = val;
|
|
|
this.medicine();
|
|
|
console.log('1,3,7,9')
|
|
|
|
|
|
}
|
|
|
|
|
|
},
|
|
|
// 电子处方单查询
|
|
|
prescriptionTime(val){
|
|
@ -257,13 +274,14 @@ export default {
|
|
|
this.echartsData();
|
|
|
},
|
|
|
echartsData(){
|
|
|
medicineAbinetApi
|
|
|
if(this.sales){
|
|
|
medicineAbinetApi
|
|
|
.getechartsData({
|
|
|
userId: this.user.id,
|
|
|
day:this.salesBag
|
|
|
})
|
|
|
.then(res=>{
|
|
|
console.log('echartsData', res);
|
|
|
// console.log('echartsData', res);
|
|
|
this.amount = res.obj.amount;
|
|
|
this.count = res.obj.amountdateList.map((item) =>{
|
|
|
return item.count
|
|
@ -323,6 +341,7 @@ export default {
|
|
|
.catch(err=>{
|
|
|
console.error(err)
|
|
|
})
|
|
|
}
|
|
|
},
|
|
|
},
|
|
|
}
|