reward inviter

This commit is contained in:
chaosBreaking
2019-10-07 19:28:55 +08:00
parent 5c2fe29e7b
commit 2b82735eb0

View File

@@ -151,12 +151,14 @@ FundModel.prototype.addFund = async function (txlist = [], option) {
} }
}); });
createAction(4, { createAction(4, {
userId: myId, userId: user.inviter,
amount: award, // 充值记录的数值仍然是区块链的数值 amount: award, // 充值记录的数值仍然是区块链的数值
tokenType: 'vic', // 目前设定只能挖出矿晶vic tokenType: 'vic', // 目前设定只能挖出矿晶vic
remain: this.asset, remain: this.asset,
detail: { detail: {
desc: `${user.id}挖矿充值奖励其推荐人${user.inviter}` desc: `${user.id}充值${newSum} 奖励其推荐人${user.inviter}: ${award}矿晶`,
from: myId,
to: user.inviter
} }
}).save(); }).save();
}).catch(err => { }).catch(err => {