Browse Source

工具的代码BUG

master
DouDou 1 year ago
parent
commit
540041c9e9
  1. 4
      src/views/modules/tooling/components/com_tool_instance_date_add_update.vue

4
src/views/modules/tooling/components/com_tool_instance_date_add_update.vue

@ -23,7 +23,7 @@
<el-form-item label="开始日期" prop="beginDate">
<el-date-picker
value-format="yyyy-MM-dd"
style="width: 150px;"
style="width: 150px;" :disabled = !addFlag
v-model="pageData.beginDate" @change="checkBeginDate()"
type="date"
placeholder="开始日期">
@ -173,7 +173,7 @@ export default {
}
const begin = this.dayjs(this.pageData.beginDate);
const now = this.dayjs(this.dayjs().format('YYYY-MM-DD'));
if (begin.valueOf() < now.valueOf()) {
if (this.addFlag && begin.valueOf() < now.valueOf()) {
this.$message.error('开始日期不能小于当前日期!');
this.pageData.beginDate = '';
}

Loading…
Cancel
Save