提交 b3741bad 编写于 作者: qian.jie's avatar qian.jie

上限每天

上级 961d2655
......@@ -221,11 +221,15 @@
</div>
<div class="doctor-info-Num">
<div class="doctor-info-NumToday">
<div class="num-info-much">90</div>
<div class="num-info-much">
90
</div>
<div>今日接诊人数</div>
</div>
<div class="doctor-info-maxToday">
<div class="num-info-much">120</div>
<div class="num-info-much">
120
</div>
<div>今日接诊上限人数</div>
</div>
</div>
......
......@@ -9,7 +9,10 @@
>
<template slot="empty">
<div class="nothing-data">
<img src="../../assets/image/nothingData.png" alt="" >
<img
src="../../assets/image/nothingData.png"
alt=""
>
<span class="nothing-data-title">暂未找到符合条件的医生</span>
</div>
</template>
......
......@@ -6,6 +6,26 @@
border-radius: 6px;
flex: 3.8;
}
.setMaxNum{
display: flex;
justify-content: space-around;
}
.list-item{
width: 86px;
height: 25px;
background: #FFFFFF;
border-radius: 16px;
border: 1px solid rgba(0, 0, 0, 0.15);
text-align: center;
}
.list-item-noth{
width: 86px;
height: 25px;
background: red;
border-radius: 16px;
border: 1px solid rgba(0, 0, 0, 0.15);
text-align: center;
}
.w2{
/deep/.fc-prev-button{
background:#f4f4f5;
......
......@@ -15,8 +15,16 @@
:class="{'w2':week==2,'w3':week==3}"
>
<FullCalendar :options="calendarOptions" />
<div>
设置接诊上限
<span>上限</span>
<div class="setMaxNum">
<div
v-for="(item,index) in maxList"
:key="index"
:class="item.chooseList ? 'list-item-noth' : 'list-item' "
@click="getSetMax(item,index)"
>
<span class="list-item-show">{{ item.value }}</span>
</div>
</div>
</div>
<div
......@@ -71,7 +79,10 @@
</div>
</div>
</div>
<div v-if="this.schedulingType != 3" class="agment-left-copy">
<div
v-if="this.schedulingType != 3"
class="agment-left-copy"
>
<el-button
round
class="copy-submit"
......@@ -108,6 +119,7 @@
<script>
// import '@fullcalendar/core/vdom'
// import moment from 'moment';
import dayjs from 'dayjs';
import FullCalendar from '@fullcalendar/vue';
import dayGridPlugin from '@fullcalendar/daygrid';
import timeGridPlugin from '@fullcalendar/timegrid';
......@@ -125,6 +137,16 @@
},
data() {
return {
maxList:[
{id:1, value:50, chooseList:false},
{id:2, value:50, chooseList:false},
{id:3, value:50, chooseList:false},
{id:4, value:50, chooseList:false},
{id:5, value:50, chooseList:false},
{id:6, value:50, chooseList:false},
{id:7, value:50, chooseList:false},
],
chooseList:true,
id:'',
doctorId:'',
schedulingTypeValue:{},
......@@ -204,7 +226,10 @@
workingTicketVisible: false, // 工作表票详情页面
scrollerHeight: 0,
loading: false,
isDoIt:false
isDoIt:false,
getEveryDay:'',
allShowList:[],
};
},
watch: {
......@@ -264,6 +289,19 @@
}
this.handleInitSearch();
},
getSetMax(item, index) {
console.log(item, index, 'item,index');
item.chooseList = !item.chooseList;
const obj = {};
obj['weekDay'] = dayjs(dayjs(this.getEveryDay ).add(index, 'day')).format('YYYY-MM-DD HH:mm:ss');
obj['preNum'] = item.value;
if(item.chooseList) {
this.allShowList.push(obj);
}else{
this.allShowList.splice(index, 1);
}
console.log( this.allShowList, this.allShowList, 'cList');
},
handleInitSearch(isReset) {
if (isReset) {
this.calendarOptions.events = this.calendarOptions.events.filter((v) => (v.week !== this.week));
......@@ -314,35 +352,41 @@
});
},
handleDatesSet(dataInfo) {
// debugger;
this.getEveryDay = dayjs(dataInfo.startStr).format('YYYY-MM-DD HH:mm:ss');
console.log(this.getEveryDay, 'dataInfo.startStrdataInfo.startStrdataInfo.startStr');
const currentTime = new Date().getTime();
const getTime = new Date(dataInfo.startStr).getTime();
const cz = currentTime - getTime;
const oneHour = 1 * 60 * 60 * 1000 * 24;
const timeDifference = (cz / oneHour) | 0;
const headObj = this.calendarOptions.customButtons.myCustomButton;
if (timeDifference > 0 && timeDifference < 7) {
// debugger;
console.log(timeDifference, 'timeDifference');
if (timeDifference >= 0 && timeDifference < 7) {
// 过去
this.week = 1;
headObj.text = '本周';
}else if (timeDifference == 0) {
}else if (timeDifference == -6) {
// 未来
this.week = 3;
headObj.text = '下周';
} else if (timeDifference == -7) {
} else if (timeDifference == -13) {
// 未来
this.week = 4;
headObj.text = '下二周';
}else if (timeDifference == -14) {
}else if (timeDifference == -20) {
// 未来
this.week = 5;
headObj.text = '下三周';
} else {
} else if (timeDifference == 7) {
// 现在
headObj.text = '上周';
this.week = 2;
}
this.allShowList = [];
this.maxList.map(item => {
return item.chooseList = false;
});
console.log( this.maxList, ' this.maxList');
},
eventResize(event) {
const index = this.getIdDeleteData(event.event.id);
......@@ -378,7 +422,6 @@
.catch((_) => {
console.log(_);
});
// alert("你要取消日期吗");
},
eventDrop(event) {
event.revert();
......@@ -476,6 +519,7 @@
objParms.list.push(obj);
}
});
objParms.countReqList = this.allShowList;
saveDutyRoster(objParms).then((res) => {
if (res.code === '000000') {
// this.$toast(res.message);
......
......@@ -45,7 +45,14 @@
</div>
<div class="agmentSelect-select-right">
设置系统单日接诊总上限
<el-input-number v-model="maxDiaNum" :step="1" :min="10" :max="1000000" step-strictly @change="getInputNumber"></el-input-number>
<el-input-number
v-model="maxDiaNum"
:step="1"
:min="10"
:max="1000000"
step-strictly
@change="getInputNumber"
/>
<el-button
type="primary"
class="submit-btn"
......
......@@ -4663,7 +4663,7 @@ dateformat@^2.0.0:
resolved "http://192.168.110.93:4873/dateformat/-/dateformat-2.2.0.tgz#4065e2013cf9fb916ddfd82efb506ad4c6769062"
integrity sha1-QGXiATz5+5Ft39gu+1Bq1MZ2kGI=
dayjs@^1.8.30, dayjs@^1.8.31:
dayjs@^1.10.7, dayjs@^1.8.31:
version "1.10.7"
resolved "http://192.168.110.93:4873/dayjs/-/dayjs-1.10.7.tgz#2cf5f91add28116748440866a0a1d26f3a6ce468"
integrity sha1-LPX5Gt0oEWdIRAhmoKHSbzps5Gg=
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册