Bladeren bron

fix:详情修改

duxin 3 weken geleden
bovenliggende
commit
d4aabf9077
2 gewijzigde bestanden met toevoegingen van 3 en 2 verwijderingen
  1. 2 1
      config.yaml
  2. 1 1
      internal/logic/timedTask/automaticPayment.go

+ 2 - 1
config.yaml

@@ -180,4 +180,5 @@ nsq: "192.168.3.240:4260"
 qsqTopic: "jy_event"
 
 entAnalysisView: 1500
-entAnalysis500: 200
+entAnalysis500: 200
+automaticPaymentTime: 3

+ 1 - 1
internal/logic/timedTask/automaticPayment.go

@@ -40,7 +40,7 @@ func AutomaticPaymentCollection() {
 func AutomaticPayment() {
 	var ctx = context.Background()
 	log.Println("自动回款匹配。。。开始")
-	query := `select * from transaction where ISRELATION = 0 and OTHNAM is not null  and  OTHNAM != "" order by id`
+	query := fmt.Sprintf(`select * from transaction where ISRELATION = 0 and OTHNAM is not null  and  OTHNAM != "" and BNKTIM > '%s' order by id`, time.Now().AddDate(0, -g.Cfg().MustGet(ctx, "automaticPaymentTime", 3).Int(), 0).Format("2006-01-02 15:04:05"))
 	data, _ := g.DB("cbs").Query(ctx, query)
 	if !data.IsEmpty() {
 		returnOrderMap := make(map[string]int)