修改错误提示
This commit is contained in:
parent
42eb05c210
commit
d43949a246
|
@ -44,7 +44,7 @@ func CreateOrderService(userId int, productId int) (code int, data front.InsertO
|
||||||
var product productsmodel.Products
|
var product productsmodel.Products
|
||||||
has, err := productsmodel.GetInstance().GetDb().Where("id = ? and status = 1", productId).Get(&product)
|
has, err := productsmodel.GetInstance().GetDb().Where("id = ? and status = 1", productId).Get(&product)
|
||||||
if !has {
|
if !has {
|
||||||
return errorcode.SystemError, data
|
return errorcode.ProdcutDiscard, data
|
||||||
}
|
}
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return errorcode.SystemError, data
|
return errorcode.SystemError, data
|
||||||
|
|
Loading…
Reference in New Issue