904118851 3 luni în urmă
părinte
comite
40b141f1e4
1 a modificat fișierele cu 2 adăugiri și 0 ștergeri
  1. 2 0
      src/helper.js

+ 2 - 0
src/helper.js

@@ -432,6 +432,8 @@ helper.generateSign = function(map, appSecret) {
 
 
 helper.getDate7DaysBefore = function(dateString, inputFormat, outputFormat) {
+    const inputDate = new Date(dateString);
+    
     if (isNaN(inputDate.getTime())) {
         // 如果默认解析失败,尝试手动解析
         // 这里可以添加更多格式的解析逻辑