This commit is contained in:
4
api/endpoints/wp/getProductAttributesDetail.ts
Normal file
4
api/endpoints/wp/getProductAttributesDetail.ts
Normal file
@@ -0,0 +1,4 @@
|
||||
import api from '~/api/instance'
|
||||
|
||||
export const getProductAttributesDetail = async (productId: number) =>
|
||||
await api.wc.v3ProductsAttributesDetail(productId)
|
||||
4
api/endpoints/wp/getProductsDetail.ts
Normal file
4
api/endpoints/wp/getProductsDetail.ts
Normal file
@@ -0,0 +1,4 @@
|
||||
import api from '~/api/instance'
|
||||
|
||||
export const getProductsDetail = async (productId: number) =>
|
||||
await api.wc.v3ProductsDetail(productId)
|
||||
4
api/endpoints/wp/getProductsList.ts
Normal file
4
api/endpoints/wp/getProductsList.ts
Normal file
@@ -0,0 +1,4 @@
|
||||
import api from '~/api/instance'
|
||||
|
||||
export const getProductsList = async () =>
|
||||
await api.wc.v3ProductsList()
|
||||
4
api/endpoints/wp/getProductsVariationsList.ts
Normal file
4
api/endpoints/wp/getProductsVariationsList.ts
Normal file
@@ -0,0 +1,4 @@
|
||||
import api from '~/api/instance'
|
||||
|
||||
export const getProductsVariationsList = async (productId: number) =>
|
||||
await api.wc.v3ProductsVariationsList(productId, { per_page: 99 })
|
||||
4
api/endpoints/wp/index.ts
Normal file
4
api/endpoints/wp/index.ts
Normal file
@@ -0,0 +1,4 @@
|
||||
export * from './getProductAttributesDetail'
|
||||
export * from './getProductsDetail'
|
||||
export * from './getProductsList'
|
||||
export * from './getProductsVariationsList'
|
||||
1
api/endpoints/wp/orders/index.ts
Normal file
1
api/endpoints/wp/orders/index.ts
Normal file
@@ -0,0 +1 @@
|
||||
export * from './postOrdersCreate'
|
||||
4
api/endpoints/wp/orders/postOrdersCreate.ts
Normal file
4
api/endpoints/wp/orders/postOrdersCreate.ts
Normal file
@@ -0,0 +1,4 @@
|
||||
import api from '~/api/instance'
|
||||
|
||||
export const postOrdersCreate = async (line_items: object[]) =>
|
||||
await api.wc.v3OrdersCreate({ line_items })
|
||||
Reference in New Issue
Block a user