Procházet zdrojové kódy

需求默认上个月

zhengkaixin před 5 měsíci
rodič
revize
737c419003
1 změnil soubory, kde provedl 6 přidání a 2 odebrání
  1. 6 2
      pagesFinance/user/withdrawal/businessInfo.vue

+ 6 - 2
pagesFinance/user/withdrawal/businessInfo.vue

@@ -805,8 +805,12 @@
 		},
 		onReady() {
 			
-			this.nowTime = parseUnixTime(new Date(), '{y}-{m}-{d}')
-			this.thismonth= parseUnixTime(beforeTimeStamp(1, new Date()), '{y}-{m}')
+			this.nowTime = parseUnixTime(new Date(), '{y}-{m}-{d}')
+			var currentDate = new Date();
+			var currentMonth=currentDate.getMonth();
+			var lastMonthDate = new Date(currentDate.setMonth(currentMonth - 1));
+
+			this.thismonth= parseUnixTime(lastMonthDate, '{y}-{m}')
 			this.endTime =parseUnixTime(new Date(), '{y}-{m}-{d} {h}:{i}:00')
 			this.getStationList()
 		},