修改手动创建任务

This commit is contained in:
shidongli 2024-12-09 13:17:41 +08:00
parent 430c7aac24
commit 3b33baa286

View File

@ -127,7 +127,7 @@
@click.native="clicktimelineitem(item, index)" @click.native="clicktimelineitem(item, index)"
> >
<div class="top"> <div class="top">
<div class="toptop" @click="topclack(item,index)"> <div class="toptop">
<el-radio v-model="item.checked1" :label="1" @change="handleCheckAllChange1($event, item)"> <el-radio v-model="item.checked1" :label="1" @change="handleCheckAllChange1($event, item)">
<el-select <el-select
style="width: 120px" style="width: 120px"
@ -163,7 +163,8 @@
<el-radio v-model="item.checked2" :label="2" @change="handleCheckAllChange2($event, item, index)"> <el-radio v-model="item.checked2" :label="2" @change="handleCheckAllChange2($event, item, index)">
<span style="width: 78px">指定时间</span> <span style="width: 78px">指定时间</span>
<el-date-picker <el-date-picker
format="yyyy-MM-dd HH:mm" format="yyyy-MM-dd HH:mm"
value-format="yyyy-MM-dd HH:mm" value-format="yyyy-MM-dd HH:mm"
v-model="item.nodePlanTime" v-model="item.nodePlanTime"
@ -171,13 +172,12 @@
placeholder="选择日期时间" placeholder="选择日期时间"
:picker-options="pickerOptions" :picker-options="pickerOptions"
@input="input(item,index)" @input="input(item,index)"
@blur="handleDateChange"
@focus="setCurrentTime(item,index)" @focus="setCurrentTime(item,index)"
ref="datePicker" ref="datePicker"
> >
</el-date-picker> </el-date-picker>
</el-radio> </el-radio>
</div> </div>
</div> </div>
<div class="top"> <div class="top">
@ -190,7 +190,7 @@
<el-radio v-model="item.checked3" :label="3" @change="handleCheckAllChange3($event, item)"> <el-radio v-model="item.checked3" :label="3" @change="handleCheckAllChange3($event, item)">
<span>立即执行</span> <span>立即执行</span>
</el-radio> </el-radio>
</div> </div>
</div> </div>
<el-card :class="listindex == index ? 'cards' : ''"> <el-card :class="listindex == index ? 'cards' : ''">
@ -539,6 +539,7 @@ export default {
name: "ManuallyCreatingTasks", name: "ManuallyCreatingTasks",
data() { data() {
return { return {
datePickerVisible:true,
show: 0, show: 0,
pickerOptions: { pickerOptions: {
disabledDate(time) { disabledDate(time) {
@ -618,9 +619,6 @@ export default {
checked1: '', checked1: '',
checked2: '', checked2: '',
checked3: '', checked3: '',
disabled: true,
}, },
], ],
listindex: 0, listindex: 0,
@ -633,7 +631,7 @@ export default {
created() { created() {
console.log(this.$route.query,'this.$route.quer') console.log(this.$route.query,'this.$route.quer')
this.infolist(); this.infolist();
this.infolistword(); this.infolistword();
this.infolistMESSAGE(); this.infolistMESSAGE();
@ -652,10 +650,10 @@ export default {
this.list[0].routeNodeName='AFTER_VISIT_DISCHARGE' this.list[0].routeNodeName='AFTER_VISIT_DISCHARGE'
this.list[0].plantype='PLUSDAY' this.list[0].plantype='PLUSDAY'
} }
if(this.$route.query.path=="/patient/patientinfoimport" || this.$route.query.path=="/task/Patientmanagement"){ if(this.$route.query.path=="/patient/patientinfoimport" || this.$route.query.path=="/task/Patientmanagement"){
this.list[0].checked2=2 this.list[0].checked2=2
this.list[0].routeNodeName='' this.list[0].routeNodeName=''
this.list[0].plantype='APPOINT' this.list[0].plantype='APPOINT'
@ -704,26 +702,19 @@ export default {
item.routeNodeDay = "" item.routeNodeDay = ""
item.plantype = "APPOINT" item.plantype = "APPOINT"
item.timedata = "" item.timedata = ""
}, },
topclack(item,index){
},
input(item,index){
// item.nodePlanTime = new Date();
const date = new Date(item.nodePlanTime); input(item,index){
const year = date.getFullYear(); this.$forceUpdate()
const month = String(date.getMonth() + 1).padStart(2, '0'); // 01 const dateParts = item.nodePlanTime.split(' ');
const day = String(date.getDate()).padStart(2, '0'); const date = new Date();
// const year = date.getFullYear();
// const month = String(date.getMonth() + 1).padStart(2, '0'); // 01
// const day = String(date.getDate()).padStart(2, '0');
const hours = String(date.getHours()).padStart(2, '0'); const hours = String(date.getHours()).padStart(2, '0');
const minutes = String(date.getMinutes()).padStart(2, '0'); const minutes = String(date.getMinutes()).padStart(2, '0');
const ss = String(date.getSeconds()).padStart(2, '0'); // const ss = String(date.getSeconds()).padStart(2, '0');
item.nodePlanTime = year + '-' + month + '-' + day + ' ' + hours + ':' + minutes;// + ':' + ss ; item.nodePlanTime = dateParts[0]+ ' ' + hours + ':' + minutes;// + ':' + ss ;
this.$forceUpdate()
},
handleDateChange(value) {
console.log(value)
//
}, },
// / // /
@ -761,33 +752,11 @@ export default {
let ss = new Date().getSeconds() < 10 ? '0' + new Date().getSeconds() : new Date().getSeconds(); let ss = new Date().getSeconds() < 10 ? '0' + new Date().getSeconds() : new Date().getSeconds();
var data = yy + '-' + mm + '-' + dd + ' ' + hh + ':' + mf + ':' + ss var data = yy + '-' + mm + '-' + dd + ' ' + hh + ':' + mf + ':' + ss
item.timedata = data item.timedata = data
console.log(data, '日期');
item.plantype = "CURRENT" item.plantype = "CURRENT"
item.nodePlanTime = "" item.nodePlanTime = ""
// if (e == true) {
// console.log('00000000000000000000')
// let yy = new Date().getFullYear();
// let mm = (new Date().getMonth() + 1) < 10 ? '0' + (new Date().getMonth() + 1) : (new Date().getMonth() + 1);
// let dd = (new Date().getDate()) < 10 ? '0' + (new Date().getDate() + 1) : (new Date().getDate() + 1);
// let hh = new Date().getHours() < 10 ? '0' + new Date().getHours() : new Date().getHours();
// let mf = new Date().getMinutes() < 10 ? '0' + new Date().getMinutes() : new Date().getMinutes();
// let ss = new Date().getSeconds() < 10 ? '0' + new Date().getSeconds() : new Date().getSeconds();
// var data = yy + '-' + mm + '-' + dd + ' ' + hh + ':' + mf + ':' + ss
// item.timedata = data
// console.log(data, '');
// item.plantype = "CURRENT"
// item.disableddata = true
// item.disabledcount = true
// item.disabled = true
// item.nodePlanTime = ""
// } else {
// item.timedata = ""
// }
}, },
upload() { upload() {
// return
this.$confirm('保存此任务, 是否继续?', '提示', { this.$confirm('保存此任务, 是否继续?', '提示', {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',