x
This commit is contained in:
1 parent
d13dedd215
commit
dba82b26a8
17 files changed
+427
-71
No files matched your search
@@ -114,8 +114,9 @@ export async function getActiveCouponsResult(): Promise<ApiResult<Coupon[]>> {
|
||||
}
|
||||
}
|
||||
|
||||
export async function getOrderResult(id: string | number): Promise<ApiResult<Order>> {
|
||||
return await fetchJsonResult<Order>(`/orders/${id}`, { next: { revalidate: defaultRevalidate } })
|
||||
export async function getOrderResult(id: string | number, lang = 'all'): Promise<ApiResult<Order>> {
|
||||
const query = lang && lang !== 'all' ? `?lang=${lang}` : ''
|
||||
return await fetchJsonResult<Order>(`/orders/${id}${query}`, { next: { revalidate: defaultRevalidate } })
|
||||
}
|
||||
|
||||
export async function getProduct(id: string | number, lang = 'all'): Promise<Product | null> {
|
||||
|
||||
Reference in new issue
Block a user