|
|
|
|
@ -39,6 +39,7 @@
|
|
|
|
|
:key="item.id"
|
|
|
|
|
></el-option>
|
|
|
|
|
</el-select>
|
|
|
|
|
<el-date-picker v-model="pickedYear" placeholder="选择年份" type="year" size="small" style="width: 160px;margin-right: 10px;" @change="pickYear" />
|
|
|
|
|
<el-date-picker v-model="pickedMonth" placeholder="选择月份" type="month" size="small" style="width: 160px;margin-right: 10px;" @change="pickMonth">
|
|
|
|
|
</el-date-picker>
|
|
|
|
|
<el-select
|
|
|
|
|
@ -211,6 +212,7 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
data() {
|
|
|
|
|
return {
|
|
|
|
|
pickedYear: new Date(),
|
|
|
|
|
pickedMonth:new Date(),
|
|
|
|
|
selectedRow:{},
|
|
|
|
|
customers:[],
|
|
|
|
|
@ -415,10 +417,21 @@ export default {
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
pickYear(e) {
|
|
|
|
|
if (e) {
|
|
|
|
|
this.pickedMonth = ''
|
|
|
|
|
this.select.start_start_time = this.$moment(e).startOf('year').format('YYYY-MM-DD HH:mm:ss')
|
|
|
|
|
this.select.end_start_time = this.$moment(e).endOf('year').format('YYYY-MM-DD HH:mm:ss')
|
|
|
|
|
} else {
|
|
|
|
|
this.select.start_start_time = ''
|
|
|
|
|
this.select.end_start_time = ''
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
pickMonth(e){
|
|
|
|
|
if(e){
|
|
|
|
|
this.select.start_start_time = this.$moment(e).startOf('month').format('YYYY-MM-DD HH:mm:ss')
|
|
|
|
|
this.select.end_start_time = this.$moment(e).endOf('month').format('YYYY-MM-DD HH:mm:ss')
|
|
|
|
|
this.pickedYear = ''
|
|
|
|
|
this.select.start_start_time = this.$moment(`${this.pickedYear.getFullYear()}-${this.$moment(e).format('MM-DD')}`).startOf('month').format('YYYY-MM-DD HH:mm:ss')
|
|
|
|
|
this.select.end_start_time = this.$moment(`${this.pickedYear.getFullYear()}-${this.$moment(e).format('MM-DD')}`).endOf('month').format('YYYY-MM-DD HH:mm:ss')
|
|
|
|
|
}else{
|
|
|
|
|
this.select.start_start_time = ''
|
|
|
|
|
this.select.end_start_time = ''
|
|
|
|
|
@ -455,51 +468,17 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
exports(){
|
|
|
|
|
let pickYear = ''
|
|
|
|
|
const h = this.$createElement
|
|
|
|
|
this.$msgbox({
|
|
|
|
|
title: "导出年份选择",
|
|
|
|
|
message: h('div',[
|
|
|
|
|
h('el-date-picker',{
|
|
|
|
|
ref: "msgbox-date-picker",
|
|
|
|
|
props: {
|
|
|
|
|
type: "year",
|
|
|
|
|
value: pickYear,
|
|
|
|
|
"value-format": "yyyy"
|
|
|
|
|
},
|
|
|
|
|
on: {
|
|
|
|
|
['input']:e => {
|
|
|
|
|
pickYear = e
|
|
|
|
|
this.$nextTick(() => {
|
|
|
|
|
this.$refs['msgbox-date-picker'].$el.children[0].value = e
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
]),
|
|
|
|
|
beforeClose: async (action, instance, done) => {
|
|
|
|
|
if (action === 'confirm') {
|
|
|
|
|
instance.confirmButtonLoading = true;
|
|
|
|
|
instance.confirmButtonText = '执行中...';
|
|
|
|
|
|
|
|
|
|
await download('/api/admin/chart/schedule-list-log','get',{
|
|
|
|
|
page: 1,
|
|
|
|
|
page_size: 9999,
|
|
|
|
|
status:this.select.status,
|
|
|
|
|
nurse_name:this.select.nurse_name,
|
|
|
|
|
customer_name:this.select.customer_name,
|
|
|
|
|
address_name:this.select.address_name,
|
|
|
|
|
start_start_time: this.$moment(new Date(pickYear)).startOf('years').format('YYYY-MM-DD'),
|
|
|
|
|
end_start_time: this.$moment(new Date(pickYear)).endOf('years').format('YYYY-MM-DD'),
|
|
|
|
|
is_export:1
|
|
|
|
|
},`服务明细.xlsx`)
|
|
|
|
|
instance.confirmButtonLoading = false;
|
|
|
|
|
done();
|
|
|
|
|
} else {
|
|
|
|
|
done();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
download('/api/admin/chart/schedule-list-log','get',{
|
|
|
|
|
page: 1,
|
|
|
|
|
page_size: 9999,
|
|
|
|
|
status:this.select.status,
|
|
|
|
|
nurse_name:this.select.nurse_name,
|
|
|
|
|
customer_name:this.select.customer_name,
|
|
|
|
|
address_name:this.select.address_name,
|
|
|
|
|
start_start_time: this.select.start_start_time,
|
|
|
|
|
end_start_time: this.select.end_start_time,
|
|
|
|
|
is_export:1
|
|
|
|
|
},`服务明细.xlsx`)
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
reset() {
|
|
|
|
|
|