|
@@ -320,6 +320,7 @@ func statisticsAndDistributeCoinForAirdrop(session *xorm.Session, mid string, pu |
|
|
} |
|
|
} |
|
|
if totalUser > 0 { |
|
|
if totalUser > 0 { |
|
|
now := time.Now() |
|
|
now := time.Now() |
|
|
|
|
|
tday := now.Format("2006-01-02") |
|
|
for _, item := range userList { |
|
|
for _, item := range userList { |
|
|
var singleValue = decimal.NewFromFloat(0) |
|
|
var singleValue = decimal.NewFromFloat(0) |
|
|
|
|
|
|
|
@@ -353,6 +354,12 @@ func statisticsAndDistributeCoinForAirdrop(session *xorm.Session, mid string, pu |
|
|
if err != nil { |
|
|
if err != nil { |
|
|
return err, unassignedTotalCoinValue |
|
|
return err, unassignedTotalCoinValue |
|
|
} |
|
|
} |
|
|
|
|
|
//TODO::更新 airdrop_date(空投日期) |
|
|
|
|
|
item.AirdropDate = tday |
|
|
|
|
|
_, err := db.BlockGreenChainCustomUserAirdropUpdate(session, item.Id, item) |
|
|
|
|
|
if err != nil { |
|
|
|
|
|
return err, unassignedTotalCoinValue |
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|