added price filter, changed mobile filter ui
This commit is contained in:
@@ -25,20 +25,20 @@ export const brandsApi = baseApi.injectEndpoints({
|
||||
query: (brandId) => `/brands/${brandId}`,
|
||||
transformResponse: (response) => response.data || response,
|
||||
}),
|
||||
|
||||
|
||||
getBrandProducts: builder.query({
|
||||
query: (params) => {
|
||||
if (typeof params === 'string' || typeof params === 'number') {
|
||||
return `/brands/${params}/products`;
|
||||
}
|
||||
|
||||
|
||||
const { id, page = 1, limit } = params;
|
||||
let url = `/brands/${id}/products?page=${page}`;
|
||||
|
||||
|
||||
if (limit) {
|
||||
url += `&limit=${limit}`;
|
||||
}
|
||||
|
||||
|
||||
return url;
|
||||
},
|
||||
transformResponse: (response) => ({
|
||||
|
||||
Reference in New Issue
Block a user