Ver a proveniência

update

master
shenjiachi há 1 semana
ascendente
cometimento
9eebd1b085
2 ficheiros alterados com 6 adições e 8 eliminações
  1. +3
    -4
      app/task/svc/svc_deal_fund_data.go
  2. +3
    -4
      app/task/svc/svc_deal_platform_revenue_data.go

+ 3
- 4
app/task/svc/svc_deal_fund_data.go Ver ficheiro

@@ -3,7 +3,6 @@ package svc
import (
"applet/app/utils"
"applet/app/utils/cache"
"applet/app/utils/logx"
"code.fnuoos.com/EggPlanet/egg_models.git/src/implement"
md2 "code.fnuoos.com/EggPlanet/egg_system_rules.git/rule/egg_energy/md"
"code.fnuoos.com/go_rely_warehouse/zyos_go_mq.git/rabbit"
@@ -36,7 +35,7 @@ func DealFundData(eg *xorm.Engine, dbName string, ch *rabbit.Channel) {
fundDataDb := implement.NewEggEnergyFundDataDb(eg)
fundDataList, err := fundDataDb.EggEnergyFundDataFindNotFinish()
if err != nil {
_ = logx.Error(err)
fmt.Println("DealFundData_ERR:::::", err.Error())
return
}

@@ -46,7 +45,7 @@ func DealFundData(eg *xorm.Engine, dbName string, ch *rabbit.Channel) {
// 1、判断是否是第一次执行
lastRecord, err1 := fundDataRecordsDb.EggEnergyFundDataRecordsGetLast(data.Id)
if err1 != nil {
_ = logx.Error(err1)
fmt.Println("DealFundData_ERR:::::", err1.Error())
continue
}
if lastRecord == nil {
@@ -66,7 +65,7 @@ func DealFundData(eg *xorm.Engine, dbName string, ch *rabbit.Channel) {
times := decimal.NewFromInt(int64(data.Hours * 60)).Div(frequency).RoundFloor(8)
totalAmount, err2 := decimal.NewFromString(data.TotalAmount)
if err2 != nil {
fmt.Println(err2)
fmt.Println("DealFundData_ERR:::::", err2.Error())
continue
}
amount := totalAmount.Div(times)


+ 3
- 4
app/task/svc/svc_deal_platform_revenue_data.go Ver ficheiro

@@ -3,7 +3,6 @@ package svc
import (
"applet/app/utils"
"applet/app/utils/cache"
"applet/app/utils/logx"
"code.fnuoos.com/EggPlanet/egg_models.git/src/implement"
md2 "code.fnuoos.com/EggPlanet/egg_system_rules.git/rule/egg_energy/md"
"code.fnuoos.com/go_rely_warehouse/zyos_go_mq.git/rabbit"
@@ -36,7 +35,7 @@ func DealPlatformRevenueData(eg *xorm.Engine, dbName string, ch *rabbit.Channel)
platformRevenueDataDb := implement.NewPlatformRevenueDataDb(eg)
platformRevenueDataList, err := platformRevenueDataDb.PlatformRevenueDataFindNotFinish()
if err != nil {
_ = logx.Error(err)
fmt.Println("DealPlatformRevenueData_ERR:::::", err.Error())
return
}

@@ -46,7 +45,7 @@ func DealPlatformRevenueData(eg *xorm.Engine, dbName string, ch *rabbit.Channel)
// 1、判断是否是第一次执行
lastRecord, err1 := recordsDb.PlatformRevenueDataRecordsGetLast(data.Id)
if err1 != nil {
_ = logx.Error(err1)
fmt.Println("DealPlatformRevenueData_ERR:::::", err1.Error())
continue
}
if lastRecord == nil {
@@ -66,7 +65,7 @@ func DealPlatformRevenueData(eg *xorm.Engine, dbName string, ch *rabbit.Channel)
times := decimal.NewFromInt(int64(data.Hours * 60)).Div(frequency).RoundFloor(8)
totalAmount, err2 := decimal.NewFromString(data.TotalAmount)
if err2 != nil {
fmt.Println(err2)
fmt.Println("DealPlatformRevenueData_ERR:::::", err2.Error())
continue
}
amount := totalAmount.Div(times)


Carregando…
Cancelar
Guardar