mirror of
https://github.com/crmeb/CRMEB.git
synced 2026-11-02 16:00:40 +00:00
修复分类显示与筛选
This commit is contained in:
parent
403bb34b81
commit
092e52d9fd
@ -15,6 +15,7 @@ Route::group('product', function () {
|
||||
Route::get('category', 'v1.product.StoreCategory/index')->option(['real_name' => '商品分类列表']);
|
||||
//商品树形列表
|
||||
Route::get('category/tree/:type', 'v1.product.StoreCategory/tree_list')->option(['real_name' => '商品分类树形列表']);
|
||||
Route::get('category/cascader/:type', 'v1.product.StoreCategory/cascader_list')->option(['real_name' => '商品分类树形列表']);
|
||||
//商品分类新增表单
|
||||
Route::get('category/create', 'v1.product.StoreCategory/create')->option(['real_name' => '商品分类新增表单']);
|
||||
//商品分类新增
|
||||
|
||||
@ -310,7 +310,7 @@ abstract class BaseDao
|
||||
if ($responses->hasMethod($method)) {
|
||||
$with[] = $key;
|
||||
} else {
|
||||
if ($key != 'timeKey') {
|
||||
if (!in_array($key, ['timeKey', 'store_stock'])) {
|
||||
$otherWhere[] = is_array($value) ? $value : [$key, '=', $value];
|
||||
}
|
||||
}
|
||||
|
||||
@ -326,8 +326,6 @@ class StoreProduct extends BaseModel
|
||||
$query->whereIn('id', function ($query) use ($store_stock) {
|
||||
$query->name('store_product_attr_value')->where('stock', '<', $store_stock)->where('stock', '>', 0)->where('type', 0)->field('product_id')->select();
|
||||
});
|
||||
// $query->where(['is_show' => 1, 'is_del' => 0])->where('stock', '<=', $store_stock)->where('stock', '>', 0);
|
||||
|
||||
} else {
|
||||
$query->where(['is_show' => 1, 'is_del' => 0])->where('stock', '>', 0);
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user