From 9ce1b5ea896ace6f2a8cf2566a61410d7020e4c3 Mon Sep 17 00:00:00 2001 From: it-fixcomart Date: Thu, 23 Jan 2025 12:03:55 +0700 Subject: ganti label 3 menjadi label 4 --- src/pages/google_merchant/products/[page].js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/pages') diff --git a/src/pages/google_merchant/products/[page].js b/src/pages/google_merchant/products/[page].js index 8dd28a39..63d52d91 100644 --- a/src/pages/google_merchant/products/[page].js +++ b/src/pages/google_merchant/products/[page].js @@ -98,7 +98,8 @@ export async function getServerSideProps({ res, query }) { 'g:price': { '#text': `${Math.round(product.lowestPrice.price * PPN)} IDR`, }, - 'g:custom_label_3': { + // 'g:custom_label_3': { '#text': product.categories[0]?.name || 'Tidak Ada Kategori' }, + 'g:custom_label_4': { '#text': category_level_1?.name_s || 'Tidak Ada Kategori', }, }; -- cgit v1.2.3 From cb58889bc19bf60ba24f6a38804c990b0f0083a1 Mon Sep 17 00:00:00 2001 From: it-fixcomart Date: Thu, 30 Jan 2025 17:06:25 +0700 Subject: update pengajuan tempo --- src/pages/pengajuan-tempo/index.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/pages') diff --git a/src/pages/pengajuan-tempo/index.jsx b/src/pages/pengajuan-tempo/index.jsx index 6987bd29..5ddd3e18 100644 --- a/src/pages/pengajuan-tempo/index.jsx +++ b/src/pages/pengajuan-tempo/index.jsx @@ -48,7 +48,7 @@ export default function TrackingOrder() { router.push(`/login?next=${nextUrl}`); } else if (auth.tempoProgres === 'approve' || auth?.partnerTempo) { router.push('/pengajuan-tempo/approve'); - } else if (!auth.parentId) { + } else if (!auth.parentId && !auth.company) { router.push('/pengajuan-tempo/switch-account'); } else if (auth.tempoProgres === 'review' && !tempo?.paymentTerm) { router.push('/pengajuan-tempo/review'); -- cgit v1.2.3 From 8efe9fb6dd906431dcaed1818aae07692aeaa094 Mon Sep 17 00:00:00 2001 From: it-fixcomart Date: Tue, 4 Feb 2025 15:16:37 +0700 Subject: update logic switch account --- src/pages/my/profile.jsx | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) (limited to 'src/pages') diff --git a/src/pages/my/profile.jsx b/src/pages/my/profile.jsx index eaf3341c..77c108cb 100644 --- a/src/pages/my/profile.jsx +++ b/src/pages/my/profile.jsx @@ -108,18 +108,19 @@ export default function Profile() {
- {!auth?.parentId && !ubahAkun && ( -
- -

Ubah ke akun bisnis

-
- )} + {auth?.company || + (!ubahAkun && ( +
+ +

Ubah ke akun bisnis

+
+ ))} {isChecked && (
-- cgit v1.2.3 From 5187f40005dd2e391ae601c11886b539dffe4dd7 Mon Sep 17 00:00:00 2001 From: it-fixcomart Date: Tue, 4 Feb 2025 15:19:14 +0700 Subject: update mobile --- src/pages/my/profile.jsx | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) (limited to 'src/pages') diff --git a/src/pages/my/profile.jsx b/src/pages/my/profile.jsx index 77c108cb..54e9024a 100644 --- a/src/pages/my/profile.jsx +++ b/src/pages/my/profile.jsx @@ -71,18 +71,19 @@ export default function Profile() { - {!auth?.parentId && !ubahAkun && ( -
- -

Ubah ke akun bisnis

-
- )} + {auth?.company || + (!ubahAkun && ( +
+ +

Ubah ke akun bisnis

+
+ ))} {isChecked && (
-- cgit v1.2.3 From 7dd2b66958fbe63c1fa68a9c3fb5eab7ee389342 Mon Sep 17 00:00:00 2001 From: it-fixcomart Date: Tue, 4 Feb 2025 17:02:17 +0700 Subject: munculin company profile --- src/pages/my/profile.jsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/pages') diff --git a/src/pages/my/profile.jsx b/src/pages/my/profile.jsx index 54e9024a..859b6960 100644 --- a/src/pages/my/profile.jsx +++ b/src/pages/my/profile.jsx @@ -98,7 +98,7 @@ export default function Profile() { )} */} - {auth?.parentId && } + {(auth?.parentId || auth?.company) && } @@ -136,7 +136,7 @@ export default function Profile() { )} */} - {auth?.parentId && } + {(auth?.parentId || auth?.company) && }
-- cgit v1.2.3 From 818246e40ae6f851224ffb376c77fe8c18cc8c45 Mon Sep 17 00:00:00 2001 From: it-fixcomart Date: Mon, 17 Feb 2025 16:04:49 +0700 Subject: add query sitemap --- src/pages/sitemap/products/[page].js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/pages') diff --git a/src/pages/sitemap/products/[page].js b/src/pages/sitemap/products/[page].js index e39755d6..3419489b 100644 --- a/src/pages/sitemap/products/[page].js +++ b/src/pages/sitemap/products/[page].js @@ -7,7 +7,10 @@ export async function getServerSideProps({ query, res }) { const baseUrl = process.env.SELF_HOST + '/shop/product/' const { page } = query const limit = 2500 - const queries = { limit, page: page.replace('.xml', '') } + const queries = { limit, page: page.replace('.xml', ''), + '-publish_b': false, + product_rating_f: '[8 TO *]', + price_tier1_v2_f: '[1 TO *]', } const products = await productSearchApi({ query: _.toQuery(queries) }) const sitemap = create('urlset', { encoding: 'utf-8' }).att( 'xmlns', -- cgit v1.2.3 From 95322b2c473da6160af0e3d685ec3d5eb924df05 Mon Sep 17 00:00:00 2001 From: it-fixcomart Date: Fri, 21 Feb 2025 15:02:27 +0700 Subject: update code /my/tempo --- src/pages/my/tempo/index.jsx | 54 +++++++++++++++++++++++--------------------- 1 file changed, 28 insertions(+), 26 deletions(-) (limited to 'src/pages') diff --git a/src/pages/my/tempo/index.jsx b/src/pages/my/tempo/index.jsx index 5fb9deba..6ca5c718 100644 --- a/src/pages/my/tempo/index.jsx +++ b/src/pages/my/tempo/index.jsx @@ -13,39 +13,41 @@ export default function MyTempo() { const router = useRouter(); const [isLoading, setIsLoading] = useState(true); useEffect(() => { + setIsLoading(true); if (!auth) { const nextUrl = encodeURIComponent(router.asPath); router.push(`/login?next=${nextUrl}`); - } - // else if ( - // (auth.tempoProgres === '' || auth.tempoProgres === 'rejected') && - // !auth.company - // ) { - // router.push('/pengajuan-tempo'); - // } - else { + } else { + if ( + !auth.partnerTempo && + (!auth.partnerTempo || auth.tempoProgres === 'review') + ) { + setIsLoading(true); + router.push('/pengajuan-tempo'); + } setIsLoading(false); } }, [auth]); - if (isLoading || !auth) { - return null; // Tidak render apa pun selama loading atau auth/tempo belum tersedia - } - return ( - - + if (isLoading && !auth) { + return null; + } else { + return ( + + - - - - - + + + + + - - - - - - - ); + + + + + + + ); + } } -- cgit v1.2.3 From 8aceceb3350c7dd89fae1762c9e415399be14bcd Mon Sep 17 00:00:00 2001 From: trisusilo48 Date: Mon, 3 Mar 2025 15:00:11 +0700 Subject: add og mage di index --- src/pages/index.jsx | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'src/pages') diff --git a/src/pages/index.jsx b/src/pages/index.jsx index fce2202a..84cb061e 100644 --- a/src/pages/index.jsx +++ b/src/pages/index.jsx @@ -97,6 +97,18 @@ export default function Home({ categoryId }) { 'indoteknik, indoteknik.com, toko teknik, toko perkakas, jual genset, jual fogging, jual krisbow, harga krisbow, harga alat safety, harga pompa air', }, ]} + openGraph={ + { + images: [ + { + url: 'https://indoteknik.com/icon.jpg', + width: 800, + height: 600, + alt: 'indoteknik.com', + }, + ], + } + } /> -- cgit v1.2.3 From d81883a63ac49fbcffe77a6a4220d910214b25a4 Mon Sep 17 00:00:00 2001 From: trisusilo48 Date: Tue, 4 Mar 2025 09:49:48 +0700 Subject: opengrap --- src/pages/index.jsx | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/pages') diff --git a/src/pages/index.jsx b/src/pages/index.jsx index 84cb061e..df5047a3 100644 --- a/src/pages/index.jsx +++ b/src/pages/index.jsx @@ -99,6 +99,8 @@ export default function Home({ categoryId }) { ]} openGraph={ { + title : 'Indoteknik.com: B2B Industrial Supply & Solution', + description : 'Temukan pilihan produk B2B Industri & Alat Teknik untuk Perusahaan, UMKM & Pemerintah dengan lengkap, mudah dan transparan.', images: [ { url: 'https://indoteknik.com/icon.jpg', -- cgit v1.2.3 From d9ffc1e045a75629d9debfac12b8be340b57c70c Mon Sep 17 00:00:00 2001 From: trisusilo48 Date: Wed, 19 Mar 2025 16:58:23 +0700 Subject: api webhook biteshi[ --- src/pages/api/webhook/biteship.js | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 src/pages/api/webhook/biteship.js (limited to 'src/pages') diff --git a/src/pages/api/webhook/biteship.js b/src/pages/api/webhook/biteship.js new file mode 100644 index 00000000..f1100d2d --- /dev/null +++ b/src/pages/api/webhook/biteship.js @@ -0,0 +1,13 @@ +import odooApi from '@/core/api/odooApi'; + + +export default async function handler(req, res) { + const body = req.body + + if(req.body){ + let result = odooApi('POST', '/api/v1/webhook/biteship', body) + } + + res.status(200).send("ok"); + +} \ No newline at end of file -- cgit v1.2.3 From f13517139cd9f69488ae44582d90990eab472aa4 Mon Sep 17 00:00:00 2001 From: trisusilo48 Date: Tue, 29 Apr 2025 11:27:29 +0700 Subject: bug fixing flash sale header --- src/pages/api/flashsale-header.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/pages') diff --git a/src/pages/api/flashsale-header.js b/src/pages/api/flashsale-header.js index 578801ae..916a9cd2 100644 --- a/src/pages/api/flashsale-header.js +++ b/src/pages/api/flashsale-header.js @@ -35,7 +35,7 @@ export default async function handler(req, res) { } return res.status(200).json({ data }); } else { - const flashSale = await odooApi('GET', `/api/v1/flashsale/header`); + const flashSale = await odooApi('GET', `/api/v1/flashsale/header?is_show_program=true`); if (flashSale.length === 0) { return res.status(200).json({ data: [] }); } else { -- cgit v1.2.3 From 480e89a0d2ccd274b956b4c4fb7ff520765c6606 Mon Sep 17 00:00:00 2001 From: Azka Nathan Date: Tue, 29 Apr 2025 14:53:53 +0700 Subject: fix bug flashsale --- src/pages/api/shop/search.js | 1 + 1 file changed, 1 insertion(+) (limited to 'src/pages') diff --git a/src/pages/api/shop/search.js b/src/pages/api/shop/search.js index 63ec7ca0..a1eecc52 100644 --- a/src/pages/api/shop/search.js +++ b/src/pages/api/shop/search.js @@ -19,6 +19,7 @@ export default async function handler(req, res) { source = '', } = req.query; + let { stock = '' } = req.query; let paramOrderBy = ''; switch (orderBy) { -- cgit v1.2.3