From aff296d79cc148a919b33c2c589d6b803fb39a22 Mon Sep 17 00:00:00 2001 From: trisusilo48 Date: Tue, 10 Sep 2024 14:58:24 +0700 Subject: update --- src/core/api/odooApi.js | 2 +- src/pages/api/shop/search.js | 3 ++- src/pages/index.jsx | 8 ++++---- 3 files changed, 7 insertions(+), 6 deletions(-) (limited to 'src') diff --git a/src/core/api/odooApi.js b/src/core/api/odooApi.js index 3349ff4b..504d097a 100644 --- a/src/core/api/odooApi.js +++ b/src/core/api/odooApi.js @@ -64,7 +64,7 @@ const odooApi = async (method, url, data = {}, headers = {}) => { } return camelcaseObjectDeep(res.data.result) || []; } catch (error) { - console.log(error); + // console.log(error); } }; diff --git a/src/pages/api/shop/search.js b/src/pages/api/shop/search.js index 089a1722..1b6377f4 100644 --- a/src/pages/api/shop/search.js +++ b/src/pages/api/shop/search.js @@ -81,7 +81,8 @@ export default async function handler(req, res) { `start=${parseInt(offset)}`, `rows=${limit}`, `sort=${paramOrderBy}`, - `fq=-publish_b:false, product_rating_f:[8 TO *], price_tier1_v2_f:[1 TO *]` + `fq=-publish_b:false, product_rating_f:[8 TO *], price_tier1_v2_f:[1 TO *]`, + `mm=2` ]; if (priceFrom > 0 || priceTo > 0) { diff --git a/src/pages/index.jsx b/src/pages/index.jsx index 613950a6..0e87205e 100644 --- a/src/pages/index.jsx +++ b/src/pages/index.jsx @@ -10,7 +10,7 @@ import { FlashSaleSkeleton } from '@/lib/flashSale/skeleton/FlashSaleSkeleton'; import PreferredBrandSkeleton from '@/lib/home/components/Skeleton/PreferredBrandSkeleton'; import BannerPromoSkeleton from '@/lib/home/components/Skeleton/BannerPromoSkeleton'; import PromotinProgram from '@/lib/promotinProgram/components/HomePage'; -import PagePopupIformation from '~/modules/popup-information'; +import PagePopupIformation from '~/modules/popup-information'; // need change to dynamic and ssr : false import CategoryPilihan from '../lib/home/components/CategoryPilihan'; import odooApi from '@/core/api/odooApi'; import { getAuth } from '~/libs/auth'; @@ -56,7 +56,7 @@ const ProgramPromotion = dynamic(() => const BannerSection = dynamic(() => import('@/lib/home/components/BannerSection') -); +); const CategoryHomeId = dynamic(() => import('@/lib/home/components/CategoryHomeId') ); @@ -71,8 +71,8 @@ import('@/lib/home/components/CategoryDynamicMobile') const CustomerReviews = dynamic(() => import('@/lib/review/components/CustomerReviews') -); -const ServiceList = dynamic(() => import('@/lib/home/components/ServiceList')); +); // need to ssr:false +const ServiceList = dynamic(() => import('@/lib/home/components/ServiceList')); // need to ssr: false -- cgit v1.2.3