diff --git a/jnpf-java-boot/jnpf-web/src/views/yys/yysmonthlyproduction/index.vue b/jnpf-java-boot/jnpf-web/src/views/yys/yysmonthlyproduction/index.vue index a4cc2cd..f8ec2c9 100644 --- a/jnpf-java-boot/jnpf-web/src/views/yys/yysmonthlyproduction/index.vue +++ b/jnpf-java-boot/jnpf-web/src/views/yys/yysmonthlyproduction/index.vue @@ -342,6 +342,12 @@ export default { }, //初始化查询的默认数据 async initSearchData() { + const now = new Date(); + const year = now.getFullYear(); + const month = String(now.getMonth() + 1).padStart(2, '0'); + const startDate = `${year}-${month}-01 00:00:00`; + const startDateTimestamp = new Date(startDate).getTime(); + this.query.years = [startDateTimestamp, startDateTimestamp]; }, initData() { this.listLoading = true;