diff --git a/src/views/forceNotice/force/list.vue b/src/views/forceNotice/force/list.vue index 163b8da..6e040b0 100644 --- a/src/views/forceNotice/force/list.vue +++ b/src/views/forceNotice/force/list.vue @@ -331,6 +331,19 @@ export default { if (speList.length > 0) { // 获取选中的第一条记录 const item = speList[0] + + // 验证公告期至是否已过 + const noticeTo = new Date(item.noticeTo) + const today = new Date() + // 将时间设置为0点进行日期比较 + today.setHours(0, 0, 0, 0) + noticeTo.setHours(0, 0, 0, 0) + + if (noticeTo > today) { + this.$message.warning('公告期尚未结束,无法发起强制注销业务') + return + } + this.$confirm('是否确认启动强制注销业务', '提示', { type: 'info', customClass: 'type-1',