Merge branch 'mark' of e.coding.net:rosydev/jx-callback into mark
This commit is contained in:
@@ -4602,10 +4602,10 @@ func StoreSkuPriceAudit(ctx *jxcontext.Context, storeSkuAudits []*model.StoreSku
|
|||||||
if len(storeAudits) > 1 {
|
if len(storeAudits) > 1 {
|
||||||
return retVal, fmt.Errorf("查询到该门店该商品的待审核信息大于1条!storeID: %v, nameID: %v", storeAudit.StoreID, storeAudit.NameID)
|
return retVal, fmt.Errorf("查询到该门店该商品的待审核信息大于1条!storeID: %v, nameID: %v", storeAudit.StoreID, storeAudit.NameID)
|
||||||
}
|
}
|
||||||
flag := false
|
// flag := false
|
||||||
//审核通过
|
//审核通过
|
||||||
if status == model.StoreAuditStatusCreated {
|
if status == model.StoreAuditStatusCreated {
|
||||||
flag = true
|
// flag = true
|
||||||
storeAudits[0].UserID = ctx.GetUserID()
|
storeAudits[0].UserID = ctx.GetUserID()
|
||||||
storeAudits[0].Status = model.StoreAuditStatusCreated
|
storeAudits[0].Status = model.StoreAuditStatusCreated
|
||||||
storeAudits[0].Remark = storeAudit.Remark
|
storeAudits[0].Remark = storeAudit.Remark
|
||||||
@@ -4648,19 +4648,20 @@ func StoreSkuPriceAudit(ctx *jxcontext.Context, storeSkuAudits []*model.StoreSku
|
|||||||
} else {
|
} else {
|
||||||
return retVal, fmt.Errorf("审核标志不正确!")
|
return retVal, fmt.Errorf("审核标志不正确!")
|
||||||
}
|
}
|
||||||
|
//TODO 暂时先不推消息了
|
||||||
if err == nil {
|
if err == nil {
|
||||||
if globals.IsProductEnv() {
|
// if globals.IsProductEnv() {
|
||||||
skuAndNames, err := dao.GetSkus(db, nil, []int{storeAudit.NameID}, nil, nil, nil)
|
// skuAndNames, err := dao.GetSkus(db, nil, []int{storeAudit.NameID}, nil, nil, nil)
|
||||||
if len(skuAndNames) > 0 && err == nil {
|
// if len(skuAndNames) > 0 && err == nil {
|
||||||
price := 0
|
// price := 0
|
||||||
if storeAudit.AuditPrice != 0 {
|
// if storeAudit.AuditPrice != 0 {
|
||||||
price = storeAudit.AuditPrice
|
// price = storeAudit.AuditPrice
|
||||||
} else {
|
// } else {
|
||||||
price = storeAudits[0].UnitPrice
|
// price = storeAudits[0].UnitPrice
|
||||||
}
|
// }
|
||||||
weixinmsg.NotifyStoreOpRequestStatus(flag, storeAudit.StoreID, storeAudit.NameID, jxutils.ComposeSpuName(skuAndNames[0].Prefix, skuAndNames[0].Name, 0), storeAudits[0].OriginUnitPrice, price, storeAudit.Remark)
|
// weixinmsg.NotifyStoreOpRequestStatus(flag, storeAudit.StoreID, storeAudit.NameID, jxutils.ComposeSpuName(skuAndNames[0].Prefix, skuAndNames[0].Name, 0), storeAudits[0].OriginUnitPrice, price, storeAudit.Remark)
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
return retVal, err
|
return retVal, err
|
||||||
}, storeSkuAudits)
|
}, storeSkuAudits)
|
||||||
|
|||||||
@@ -35,9 +35,10 @@ type GoodsOrderExt struct {
|
|||||||
WaybillCreatedAt time.Time `orm:"type(datetime);index" json:"waybillCreatedAt"`
|
WaybillCreatedAt time.Time `orm:"type(datetime);index" json:"waybillCreatedAt"`
|
||||||
WaybillFinishedAt time.Time `orm:"type(datetime)" json:"waybillFinishedAt"`
|
WaybillFinishedAt time.Time `orm:"type(datetime)" json:"waybillFinishedAt"`
|
||||||
|
|
||||||
DistrictName string `json:"districtName"`
|
DistrictName string `json:"districtName"`
|
||||||
CityName string `json:"cityName"`
|
CityName string `json:"cityName"`
|
||||||
PayPercentage int `json:"payPercentage"`
|
PayPercentage int `json:"payPercentage"`
|
||||||
|
OldPayPercentage int `json:"oldPayPercentage"`
|
||||||
|
|
||||||
SkuInfo string `json:"skuInfo,omitempty"`
|
SkuInfo string `json:"skuInfo,omitempty"`
|
||||||
SkuInfo2 string `json:"skuInfo2,omitempty"`
|
SkuInfo2 string `json:"skuInfo2,omitempty"`
|
||||||
|
|||||||
@@ -767,7 +767,7 @@ func GetOrders(db *DaoDB, ids []int64, isIncludeSku, isIncludeFake bool, fromDat
|
|||||||
CAST(IF(t1.earning_price <> 0, t1.earning_price, IF(t1.shop_price <> 0 && t1.shop_price < t1.sale_price, t1.shop_price, t1.sale_price) * IF(t5.pay_percentage > 0, t5.pay_percentage, %d) / 100) AS SIGNED) earning_price,
|
CAST(IF(t1.earning_price <> 0, t1.earning_price, IF(t1.shop_price <> 0 && t1.shop_price < t1.sale_price, t1.shop_price, t1.sale_price) * IF(t5.pay_percentage > 0, t5.pay_percentage, %d) / 100) AS SIGNED) earning_price,
|
||||||
t2.status waybill_status, t2.courier_name, t2.courier_mobile,
|
t2.status waybill_status, t2.courier_name, t2.courier_mobile,
|
||||||
t2.actual_fee, t2.desired_fee, t2.waybill_created_at, t2.waybill_finished_at,
|
t2.actual_fee, t2.desired_fee, t2.waybill_created_at, t2.waybill_finished_at,
|
||||||
t5.pay_percentage,
|
t5.pay_percentage, t5.old_pay_percentage,
|
||||||
city.name city_name, district.name district_name`, model.DefaultEarningPricePercentage)
|
city.name city_name, district.name district_name`, model.DefaultEarningPricePercentage)
|
||||||
if isIncludeSku {
|
if isIncludeSku {
|
||||||
sql += `,
|
sql += `,
|
||||||
|
|||||||
@@ -336,6 +336,7 @@ type Store struct {
|
|||||||
PayeeBankBranchName string `orm:"size(255)" json:"payeeBankBranchName"` // 开户支行
|
PayeeBankBranchName string `orm:"size(255)" json:"payeeBankBranchName"` // 开户支行
|
||||||
PayeeBankCode string `orm:"size(8)" json:"payeeBankCode"` // 开户行代码
|
PayeeBankCode string `orm:"size(8)" json:"payeeBankCode"` // 开户行代码
|
||||||
PayPercentage int `json:"payPercentage"`
|
PayPercentage int `json:"payPercentage"`
|
||||||
|
OldPayPercentage int `json:"oldPayPercentage"`
|
||||||
|
|
||||||
// OperatorName string `orm:"size(8)" json:"operatorName"` // 运营人姓名
|
// OperatorName string `orm:"size(8)" json:"operatorName"` // 运营人姓名
|
||||||
OperatorPhone string `orm:"size(16)" json:"operatorPhone"` // 京东运营人电话
|
OperatorPhone string `orm:"size(16)" json:"operatorPhone"` // 京东运营人电话
|
||||||
|
|||||||
Reference in New Issue
Block a user