|
|
@@ -142,31 +142,15 @@ func ActivityCoinReadyExchangeEggEnergy(engine *xorm.Engine, uid int64, ch *rabb |
|
|
|
} |
|
|
|
|
|
|
|
//TODO::推入rabbitmq 异步处理 |
|
|
|
if egg_system_rules.StrToFloat64(autoExchangeNumsByPersonAmountValue) > 0 { |
|
|
|
ch.Publish(md2.EggEnergyExchange, md2.EggEnergyStructForStartExchangeGreenEnergy{ |
|
|
|
Uid: uid, |
|
|
|
SignId: sign.Id, |
|
|
|
PersonEggEnergyCoinId: eggEnergyBasicSetting.PersonEggEnergyCoinId, |
|
|
|
TeamEggEnergyCoinId: eggEnergyBasicSetting.TeamEggEnergyCoinId, |
|
|
|
PersonPointCoinId: coin1.Id, |
|
|
|
PersonEnergyCoinId: eggEnergyBasicSetting.PersonEggEnergyCoinId, |
|
|
|
TeamPointCoinId: coin2.Id, |
|
|
|
TeamEnergyCoinId: eggEnergyBasicSetting.TeamEggEnergyCoinId, |
|
|
|
}, md2.EggEnergyRoutKeyForStartExchangeGreenEnergy) |
|
|
|
} |
|
|
|
|
|
|
|
if egg_system_rules.StrToFloat64(autoExchangeNumsByTeamAmountValue) > 0 { |
|
|
|
ch.Publish(md2.EggEnergyExchange, md2.EggEnergyStructForStartExchangeGreenEnergy{ |
|
|
|
Uid: uid, |
|
|
|
SignId: sign.Id, |
|
|
|
PersonEggEnergyCoinId: eggEnergyBasicSetting.PersonEggEnergyCoinId, |
|
|
|
TeamEggEnergyCoinId: eggEnergyBasicSetting.TeamEggEnergyCoinId, |
|
|
|
PersonPointCoinId: coin1.Id, |
|
|
|
PersonEnergyCoinId: eggEnergyBasicSetting.PersonEggEnergyCoinId, |
|
|
|
TeamPointCoinId: coin2.Id, |
|
|
|
TeamEnergyCoinId: eggEnergyBasicSetting.TeamEggEnergyCoinId, |
|
|
|
}, md2.EggEnergyRoutKeyForStartExchangeGreenEnergy) |
|
|
|
} |
|
|
|
|
|
|
|
ch.Publish(md2.EggEnergyExchange, md2.EggEnergyStructForStartExchangeGreenEnergy{ |
|
|
|
Uid: uid, |
|
|
|
SignId: sign.Id, |
|
|
|
PersonEggEnergyCoinId: eggEnergyBasicSetting.PersonEggEnergyCoinId, |
|
|
|
TeamEggEnergyCoinId: eggEnergyBasicSetting.TeamEggEnergyCoinId, |
|
|
|
PersonPointCoinId: coin1.Id, |
|
|
|
PersonEnergyCoinId: eggEnergyBasicSetting.PersonEggEnergyCoinId, |
|
|
|
TeamPointCoinId: coin2.Id, |
|
|
|
TeamEnergyCoinId: eggEnergyBasicSetting.TeamEggEnergyCoinId, |
|
|
|
}, md2.EggEnergyRoutKeyForStartExchangeGreenEnergy) |
|
|
|
return |
|
|
|
} |