|
|
@@ -111,11 +111,13 @@ func SettlementSignInGreenEnergy(engine *xorm.Engine, masterId string) (err erro |
|
|
|
} |
|
|
|
|
|
|
|
//5、减少“活跃赠送” 中的绿色能量 |
|
|
|
err = DealAvailableGreenEnergyCoin(session, int(enum.SignInReward), reduceTotalGreenEnergy, enum.SignInReward.String(), oneCirclesGreenEnergyBasicSetting, oneCirclesGreenEnergyBasicSetting.NowPrice) |
|
|
|
if err != nil { |
|
|
|
_ = session.Rollback() |
|
|
|
fmt.Println("err:::::55555", err) |
|
|
|
return err |
|
|
|
if reduceTotalGreenEnergy > 0 { |
|
|
|
err = DealAvailableGreenEnergyCoin(session, int(enum.SignInReward), reduceTotalGreenEnergy, enum.SignInReward.String(), oneCirclesGreenEnergyBasicSetting, oneCirclesGreenEnergyBasicSetting.NowPrice) |
|
|
|
if err != nil { |
|
|
|
_ = session.Rollback() |
|
|
|
fmt.Println("err:::::55555", err) |
|
|
|
return err |
|
|
|
} |
|
|
|
} |
|
|
|
err = session.Commit() |
|
|
|
if err != nil { |
|
|
|