fix(#20): 修复在删除充值记录的时候出现问题

This commit is contained in:
ZiHangQin 2023-08-11 14:52:15 +08:00
parent 683907b363
commit e229f3976d
2 changed files with 4 additions and 1 deletions

View File

@ -8,6 +8,7 @@ import (
"electricity_bill_calc/tools"
"electricity_bill_calc/types"
"electricity_bill_calc/vo"
"fmt"
"github.com/gofiber/fiber/v2"
"github.com/jinzhu/copier"
@ -136,7 +137,8 @@ func deleteTopUp(c *fiber.Ctx) error {
topUpLog.Error("删除一条指定的商户充值记录,删除失败", zap.Error(err))
return result.NotAccept("商户充值记录删除不成功")
}
return result.Deleted(
fmt.Println("已经删除一条指定的商户充值记录")
return result.Success(
"已经删除一条指定的商户充值记录",
)
}

View File

@ -22,4 +22,5 @@ type TopUpDetailQueryResponse struct {
Amount decimal.Decimal `json:"amount"`
PaymentType int16 `json:"paymentType"`
SyncStatus int16 `json:"syncStatus" copier:"SyncStatus"`
CancelledAt *types.DateTime `json:"cancelledAt"` // TODO: 2023.08.11 在查询充值记录的时候发现缺少该字段(已添加)
}