Commit 3b5cd90c by caoyanzhi

添加默认有效期

parent 5a0f5c70
......@@ -254,6 +254,14 @@ export default {
},
methods: {
// 设置默认的分组有效期
defaultDate() {
let date = new Date(new Date().getTime() + 365 * 24 * 3600 * 1000);
let Y = date.getFullYear() + '-';
let M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '-';
let D = (date.getDate() < 10 ? '0' + date.getDate() : date.getDate()) + ' ';
this.tagConfig.date = Y + M + D + '23:59:59';
},
// 收起右边的
collapseRightList(eve) {
console.log(eve.target.className);
......@@ -571,6 +579,7 @@ export default {
this.handTag = list.handTag;
this.changeTagTitle(list.name);
});
this.defaultDate();
}
};
</script>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment