wangchuanjin před 2 roky
rodič
revize
446bc57215
1 změnil soubory, kde provedl 2 přidání a 2 odebrání
  1. 2 2
      public/service/power.go

+ 2 - 2
public/service/power.go

@@ -28,12 +28,12 @@ func OpenPower(appid, goods_code string, goods_spec_id, user_id, ent_id int64, b
 		return errors.New("无效的参数user_id、ent_id")
 	}
 	if start_time != "" {
-		if _, err := time.ParseInLocation(start_time, Date_Full_Layout, time.Local); err != nil {
+		if _, err := time.ParseInLocation(Date_Full_Layout, start_time, time.Local); err != nil {
 			return errors.New("无效的参数start_time," + err.Error())
 		}
 	}
 	if end_time != "" {
-		if _, err := time.ParseInLocation(end_time, Date_Full_Layout, time.Local); err != nil {
+		if _, err := time.ParseInLocation(Date_Full_Layout, end_time, time.Local); err != nil {
 			return errors.New("无效的参数end_time," + err.Error())
 		}
 	}