报警增加代金券消耗和累计充值
This commit is contained in:
parent
daeac2e263
commit
68fe869945
@ -50,13 +50,17 @@ export class NotifyService {
|
||||
return this._itemTemplate
|
||||
.replace('channel', channel)
|
||||
.replace('itemId', itemId as string)
|
||||
.replace('type', type === 'use' ? '消耗' : '获取') + this.formatNotifyInfo(data);
|
||||
.replace('type', type === 'use' ? '消耗' : '获取') + this.formatItemNotifyInfo(data, type);
|
||||
}
|
||||
private formatRecharge(channel: string, data: INotifyInfo[]) {
|
||||
return this._rechargeTemplate
|
||||
.replace('channel', channel) + this.formatNotifyInfo(data);
|
||||
}
|
||||
|
||||
private formatItemNotifyInfo(data: INotifyInfo[], type: EChangeType) {
|
||||
return data.map(d => `[${d.uid}][${type === 'get' ? '获取' : '消耗'}: ${d.num}][总代金券消耗: ${d.djq}][总充值: ${d.recharge}]`).join('\n');
|
||||
}
|
||||
|
||||
private formatNotifyInfo(data: INotifyInfo[]) {
|
||||
return data.map(d => `[${d.uid}][总代金券消耗: ${d.djq}][总充值: ${d.recharge}]`).join('\n');
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user