|
|
@ -155,8 +155,14 @@
|
|
|
|
</el-col>
|
|
|
|
</el-col>
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
<el-form-item label="任务期限" prop="taskDeadline">
|
|
|
|
<el-form-item label="任务期限" prop="taskDeadline">
|
|
|
|
<el-date-picker type="datetime" placeholder="选择日期" v-model="ruleForm.taskDeadline" style="width: 100%;"
|
|
|
|
<el-date-picker
|
|
|
|
value-format="yyyy-MM-dd HH:mm:ss" default-time="23:59:59"></el-date-picker>
|
|
|
|
type="datetime"
|
|
|
|
|
|
|
|
placeholder="选择日期"
|
|
|
|
|
|
|
|
v-model="ruleForm.taskDeadline"
|
|
|
|
|
|
|
|
style="width: 100%;"
|
|
|
|
|
|
|
|
value-format="yyyy-MM-dd HH:mm:ss"
|
|
|
|
|
|
|
|
default-time="23:59:59"
|
|
|
|
|
|
|
|
></el-date-picker>
|
|
|
|
</el-form-item>
|
|
|
|
</el-form-item>
|
|
|
|
<el-form-item class="newTask-form-item">
|
|
|
|
<el-form-item class="newTask-form-item">
|
|
|
|
<el-button @click="resetForm('ruleForm')">取消</el-button>
|
|
|
|
<el-button @click="resetForm('ruleForm')">取消</el-button>
|
|
|
@ -261,7 +267,8 @@ export default {
|
|
|
|
window.removeEventListener('resize', this.cancalDebounce);
|
|
|
|
window.removeEventListener('resize', this.cancalDebounce);
|
|
|
|
},
|
|
|
|
},
|
|
|
|
methods: {
|
|
|
|
methods: {
|
|
|
|
checkboxChange(){
|
|
|
|
|
|
|
|
|
|
|
|
checkboxChange() {
|
|
|
|
console.log(111);
|
|
|
|
console.log(111);
|
|
|
|
this.ruleForm.dwmc = []
|
|
|
|
this.ruleForm.dwmc = []
|
|
|
|
this.tabclicklist = []
|
|
|
|
this.tabclicklist = []
|
|
|
@ -282,9 +289,31 @@ export default {
|
|
|
|
this.tabclicklist = []
|
|
|
|
this.tabclicklist = []
|
|
|
|
this.btnloading = false
|
|
|
|
this.btnloading = false
|
|
|
|
},
|
|
|
|
},
|
|
|
|
submitForm(formName) {
|
|
|
|
fonsisis(data) {
|
|
|
|
console.log(this.ruleForm);
|
|
|
|
// 定义特定的时间字符串
|
|
|
|
|
|
|
|
const specificTimeStr = data;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 将时间字符串转换为Date对象
|
|
|
|
|
|
|
|
const specificTime = new Date(specificTimeStr);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 获取当前时间
|
|
|
|
|
|
|
|
const currentTime = new Date();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 比较当前时间是否大于特定时间
|
|
|
|
|
|
|
|
if (currentTime > specificTime) {
|
|
|
|
|
|
|
|
return false
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
return true
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
submitForm(formName) {
|
|
|
|
|
|
|
|
console.log(this.ruleForm.taskDeadline);
|
|
|
|
|
|
|
|
this.fonsisis(this.ruleForm.taskDeadline)
|
|
|
|
|
|
|
|
if(!this.fonsisis(this.ruleForm.taskDeadline)) {
|
|
|
|
|
|
|
|
this.$message.error('选择时间不能小于当前时间');
|
|
|
|
|
|
|
|
return false
|
|
|
|
|
|
|
|
}
|
|
|
|
this.$refs[formName].validate((valid) => {
|
|
|
|
this.$refs[formName].validate((valid) => {
|
|
|
|
if (valid) {
|
|
|
|
if (valid) {
|
|
|
|
this.btnloading = true
|
|
|
|
this.btnloading = true
|
|
|
@ -295,9 +324,6 @@ export default {
|
|
|
|
this.getInfo();
|
|
|
|
this.getInfo();
|
|
|
|
this.$modal.msgSuccess("新增成功");
|
|
|
|
this.$modal.msgSuccess("新增成功");
|
|
|
|
this.btnloading = false
|
|
|
|
this.btnloading = false
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
})
|
|
|
|
})
|
|
|
|
setTimeout(() => {
|
|
|
|
setTimeout(() => {
|
|
|
|
this.ruleForm.dwmc = this.ruleForm.dwmc.split(",")
|
|
|
|
this.ruleForm.dwmc = this.ruleForm.dwmc.split(",")
|
|
|
@ -445,7 +471,7 @@ export default {
|
|
|
|
type: 'warning'
|
|
|
|
type: 'warning'
|
|
|
|
}).then(() => {
|
|
|
|
}).then(() => {
|
|
|
|
|
|
|
|
|
|
|
|
assetTaskclose({ taskId: row.id,taskName:row.taskName }).then(res => {
|
|
|
|
assetTaskclose({ taskId: row.id, taskName: row.taskName }).then(res => {
|
|
|
|
if (res.code == 200) {
|
|
|
|
if (res.code == 200) {
|
|
|
|
this.$message({
|
|
|
|
this.$message({
|
|
|
|
type: 'success',
|
|
|
|
type: 'success',
|
|
|
|