2021-02-11 13:58:05 +00:00
|
|
|
export const urlList = {
|
|
|
|
apiUri: Cypress.env("API_URI"),
|
|
|
|
channels: "channels/",
|
|
|
|
configuration: "configuration/",
|
2021-03-15 13:16:02 +00:00
|
|
|
draftOrders: "orders/drafts/",
|
2021-02-11 13:58:05 +00:00
|
|
|
homePage: "/",
|
|
|
|
orders: "orders/",
|
|
|
|
products: "products/",
|
2021-07-15 11:17:56 +00:00
|
|
|
addProduct: "products/add",
|
2021-02-18 09:00:08 +00:00
|
|
|
warehouses: "warehouses/",
|
2021-04-02 11:01:38 +00:00
|
|
|
shippingMethods: "shipping/",
|
2021-03-12 14:57:02 +00:00
|
|
|
sales: "discounts/sales/",
|
2021-03-23 10:15:39 +00:00
|
|
|
collections: "collections/",
|
2021-06-02 07:59:34 +00:00
|
|
|
vouchers: "discounts/vouchers/",
|
|
|
|
staffMembers: "staff/",
|
2021-06-07 11:35:53 +00:00
|
|
|
newPassword: "new-password/",
|
2021-07-05 10:21:35 +00:00
|
|
|
permissionsGroups: "permission-groups/",
|
2021-07-15 11:17:56 +00:00
|
|
|
categories: "categories/",
|
2021-07-12 08:50:50 +00:00
|
|
|
weightRete: "weight/",
|
2021-07-09 09:43:45 +00:00
|
|
|
attributes: "attributes/",
|
2021-07-15 10:25:39 +00:00
|
|
|
productTypes: "product-types/",
|
2021-07-15 10:27:07 +00:00
|
|
|
apps: "apps/",
|
2021-07-15 10:25:39 +00:00
|
|
|
customers: "customers/"
|
2021-02-11 13:58:05 +00:00
|
|
|
};
|
2021-07-12 08:50:50 +00:00
|
|
|
|
2021-02-23 14:30:52 +00:00
|
|
|
export const productDetailsUrl = productId => `${urlList.products}${productId}`;
|
2021-06-07 11:35:53 +00:00
|
|
|
|
|
|
|
export const userDetailsUrl = userId => `${urlList.staffMembers}${userId}`;
|
|
|
|
|
2021-06-02 07:59:34 +00:00
|
|
|
export const staffMemberDetailsUrl = staffMemberId =>
|
|
|
|
`${urlList.staffMembers}${staffMemberId}`;
|
2021-06-07 11:35:53 +00:00
|
|
|
|
2021-06-02 07:59:34 +00:00
|
|
|
export const permissionGroupDetails = permissionGroupId =>
|
|
|
|
`${urlList.permissionsGroups}${permissionGroupId}`;
|
2021-07-05 10:21:35 +00:00
|
|
|
|
2021-07-15 11:17:56 +00:00
|
|
|
export const categoryDetails = categoryId =>
|
|
|
|
`${urlList.categories}${categoryId}`;
|
|
|
|
|
2021-07-06 10:32:09 +00:00
|
|
|
export const shippingZoneDetailsUrl = shippingZoneId =>
|
|
|
|
`${urlList.shippingMethods}${shippingZoneId}`;
|
|
|
|
|
2021-07-12 08:50:50 +00:00
|
|
|
export const weightRateUrl = (shippingZoneId, weightRateId) =>
|
|
|
|
`${urlList.shippingMethods}${shippingZoneId}/${urlList.weightRete}${weightRateId}`;
|
|
|
|
|
2021-07-06 10:32:09 +00:00
|
|
|
export const warehouseDetailsUrl = warehouseId =>
|
|
|
|
`${urlList.warehouses}${warehouseId}`;
|
|
|
|
|
2021-07-05 10:21:35 +00:00
|
|
|
export const productTypeDetailsUrl = productTypeId =>
|
2021-07-09 09:43:45 +00:00
|
|
|
`${urlList.productTypes}${productTypeId}`;
|
2021-07-15 10:27:07 +00:00
|
|
|
|
|
|
|
export const appDetailsUrl = appId => `${urlList.apps}custom/${appId}`;
|