预警19
This commit is contained in:
parent
1b960df589
commit
72a6da5ce4
|
|
@ -179,7 +179,7 @@ func (this *VoucherBiz) WarningSend(ctx context.Context, product *bo.ProductBo,
|
|||
return err
|
||||
}
|
||||
|
||||
var warningPerson []*do.WarningPerson
|
||||
var warningPerson []do.WarningPerson
|
||||
if err := json.Unmarshal([]byte(product.WarningPerson), &warningPerson); err != nil {
|
||||
return err
|
||||
}
|
||||
|
|
|
|||
|
|
@ -44,6 +44,14 @@ func TestSendSMS(t *testing.T) {
|
|||
}
|
||||
|
||||
func TestWarningSend(t *testing.T) {
|
||||
|
||||
warningPersonStr := `[{"tag": "CMB", "name": "李子铭", "mobile": "18666173766"}, {"tag": "LSXD", "name": "赵晋琪", "mobile": "13474987525"}]`
|
||||
var warningPerson []do.WarningPerson
|
||||
if err := json.Unmarshal([]byte(warningPersonStr), &warningPerson); err != nil {
|
||||
t.Error(err)
|
||||
return
|
||||
}
|
||||
|
||||
req := &do.WxResp{
|
||||
Amount: 2,
|
||||
AllBudget: 70010,
|
||||
|
|
|
|||
Loading…
Reference in New Issue