This commit is contained in:
邹宗楠
2023-05-23 15:04:55 +08:00
parent 77e7b21917
commit bb57eacecc
3 changed files with 11 additions and 9 deletions

View File

@@ -1,6 +1,8 @@
package model
import (
"fmt"
"git.rosy.net.cn/baseapi/utils"
"time"
)
@@ -145,8 +147,8 @@ type GoodsOrder struct {
OrderFinishedAt time.Time `orm:"type(datetime)" json:"orderFinishedAt"`
StatusTime time.Time `orm:"type(datetime)" json:"statusTime"` // last status time
PickDeadline time.Time `orm:"type(datetime);null" json:"pickDeadline"`
DeliveryFeeFrom *time.Time `orm:"type(datetime);null" json:"deliveryFeeFrom,omitempty"` // 三方配置费计算的开始基准时间
ModelTimeInfo `json:"-"` // 1
DeliveryFeeFrom *time.Time `orm:"type(datetime);null" json:"deliveryFeeFrom,omitempty"` // 三方配置费计算的开始基准时间
ModelTimeInfo `json:"-"` // 1
Flag int `json:"flag"` // 非运单调整相关的其它状态
InvoiceTitle string `orm:"size(64)" json:"invoiceTitle"` // 发票抬头
InvoiceTaxerID string `orm:"size(32);column(invoice_taxer_id)" json:"invoiceTaxerID"` // 发票纳税人识别码
@@ -324,6 +326,11 @@ func Waybill2Status(bill *Waybill) (retVal *OrderStatus) {
StatusTime: bill.StatusTime,
Remark: bill.Remark,
}
if retVal.Remark == "" {
retVal.Remark = fmt.Sprintf("运费: %s", utils.Float64ToStr(float64(bill.DesiredFee)/float64(100)))
} else {
retVal.Remark += fmt.Sprintf(",运费: %s", utils.Float64ToStr(float64(bill.DesiredFee)/float64(100)))
}
return retVal
}