fix
This commit is contained in:
@@ -48,6 +48,6 @@ func (o *FsOrderModel) FindOneAndCreateServiceContact(ctx context.Context, userI
|
||||
|
||||
// 获取用户最近下单成功的订单
|
||||
func (o *FsOrderModel) FindLastSuccessOneOrder(ctx context.Context, userId int64, statusGt int64) (order *FsOrder, err error) {
|
||||
err = o.db.WithContext(ctx).Model(&FsOrder{}).Where("`user_id` = ? and `status` > ?", userId, statusGt).Order("id DESC").Find(&order).Error
|
||||
err = o.db.WithContext(ctx).Model(&FsOrder{}).Where("`user_id` = ? and `status` > ?", userId, statusGt).Order("id DESC").Take(&order).Error
|
||||
return order, err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user