订单GoodsOrder添加字段InvoiceTitle,InvoiceTaxerID和InvoiceEmail表示开发票信息

GetOrders添加可选参数mustInvoice表示只查询要求开发票的订单
This commit is contained in:
gazebo
2019-10-21 17:44:06 +08:00
parent fceab5848e
commit aa6d673936
9 changed files with 72 additions and 0 deletions

View File

@@ -121,6 +121,10 @@ func (p *PurchaseHandler) Map2Order(orderData map[string]interface{}) (order *mo
OrderCreatedAt: getTimeFromTimestamp(utils.MustInterface2Int64(result["ctime"])),
OriginalData: string(utils.MustMarshal(result)),
ActualPayPrice: jxutils.StandardPrice2Int(utils.MustInterface2Float64(result["total"])),
InvoiceTitle: utils.Interface2String(result["invoice_title"]),
InvoiceTaxerID: utils.Interface2String(result["taxpayer_id"]),
InvoiceEmail: jxutils.GetOneEmailFromStr(utils.Interface2String(result["caution"])),
}
pickType := int(utils.Interface2Int64WithDefault(result["pick_type"], 0))
if pickType == mtwmapi.OrderPickTypeSelf {