From efb732fb5988dd752b1ad60bc844f76eb90cbb25 Mon Sep 17 00:00:00 2001 From: shidongli Date: Mon, 9 Dec 2024 16:12:10 +0800 Subject: [PATCH] =?UTF-8?q?=E6=89=8B=E5=8A=A8=E5=88=9B=E5=BB=BA=E4=BB=BB?= =?UTF-8?q?=E5=8A=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../system/ManuallyCreatingTasks/index.vue | 36 ++++++++++++------- 1 file changed, 23 insertions(+), 13 deletions(-) diff --git a/src/views/system/ManuallyCreatingTasks/index.vue b/src/views/system/ManuallyCreatingTasks/index.vue index babf70a..8890559 100644 --- a/src/views/system/ManuallyCreatingTasks/index.vue +++ b/src/views/system/ManuallyCreatingTasks/index.vue @@ -163,8 +163,6 @@ 指定时间: @@ -539,6 +538,7 @@ export default { name: "ManuallyCreatingTasks", data() { return { + time:'', datePickerVisible:true, show: 0, pickerOptions: { @@ -653,20 +653,30 @@ export default { } if(this.$route.query.path=="/patient/patientinfoimport" || this.$route.query.path=="/task/Patientmanagement"){ - this.list[0].checked2=2 this.list[0].routeNodeName='' this.list[0].plantype='APPOINT' } }, + computed: { + currentDate() { + return this.formatDate(new Date()); + }, + }, mounted() { this.getMaxTableHeight() this.screenChange() }, methods: { + formatDate(date) { + // 格式化日期为想要的字符串格式 + // 例如: "2023-04-01 12:00:00" + return `${date.getFullYear()}-${(date.getMonth() + 1).toString().padStart(2, '0')}-${date.getDate().toString().padStart(2, '0')} ${date.getHours().toString().padStart(2, '0')}:${date.getMinutes().toString().padStart(2, '0')}:${date.getSeconds().toString().padStart(2, '0')}`; + }, -// 计划类型:plantype; + +// 计划类型:plantype; // CURRENT:立即执行; // APPOINT:指定日期; // PLUSDAY:第几天 @@ -706,15 +716,15 @@ export default { input(item,index){ this.$forceUpdate() - const dateParts = item.nodePlanTime.split(' '); - const date = new Date(); - // const year = date.getFullYear(); - // const month = String(date.getMonth() + 1).padStart(2, '0'); // 月份从0开始,所以需要加1 - // const day = String(date.getDate()).padStart(2, '0'); - const hours = String(date.getHours()).padStart(2, '0'); - const minutes = String(date.getMinutes()).padStart(2, '0'); + // const dateParts = item.nodePlanTime.split(' '); + // const date = new Date(); + // // const year = date.getFullYear(); + // // const month = String(date.getMonth() + 1).padStart(2, '0'); // 月份从0开始,所以需要加1 + // // const day = String(date.getDate()).padStart(2, '0'); + // const hours = String(date.getHours()).padStart(2, '0'); + // const minutes = String(date.getMinutes()).padStart(2, '0'); // const ss = String(date.getSeconds()).padStart(2, '0'); - item.nodePlanTime = dateParts[0]+ ' ' + hours + ':' + minutes;// + ':' + ss ; + // item.nodePlanTime = dateParts[0]+ ' ' + hours + ':' + minutes + ':' + ss ; }, // 出院/诊后 @@ -775,7 +785,7 @@ export default { }) console.log(newObj, 'this.newObj') console.log(this.updata, 'this.updata') - // return + return signrouteadd(newObj).then((res) => { this.$notify({ type: "success",