feat(dashboard): shipping & location (#7151)
This commit is contained in:
@@ -10,7 +10,6 @@ import {
|
||||
import {
|
||||
AdminCollectionsRes,
|
||||
AdminProductsRes,
|
||||
AdminPromotionRes,
|
||||
AdminRegionsRes,
|
||||
} from "@medusajs/medusa"
|
||||
import { InventoryItemRes, PriceListRes } from "../../types/api-responses"
|
||||
@@ -297,44 +296,6 @@ export const v2Routes: RouteObject[] = [
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
path: "shipping",
|
||||
lazy: () => import("../../v2-routes/shipping/locations-list"),
|
||||
handle: {
|
||||
crumb: () => "Shipping",
|
||||
},
|
||||
children: [
|
||||
{
|
||||
path: "location/:location_id",
|
||||
children: [
|
||||
{
|
||||
path: "fulfillment-set/:fset_id",
|
||||
children: [
|
||||
{
|
||||
path: "service-zones/create",
|
||||
lazy: () =>
|
||||
import(
|
||||
"../../v2-routes/shipping/service-zone-create"
|
||||
),
|
||||
},
|
||||
{
|
||||
path: "service-zone/:zone_id",
|
||||
children: [
|
||||
{
|
||||
path: "shipping-options/create",
|
||||
lazy: () =>
|
||||
import(
|
||||
"../../v2-routes/shipping/shipping-options-create"
|
||||
),
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
path: "/customers",
|
||||
handle: {
|
||||
@@ -641,44 +602,6 @@ export const v2Routes: RouteObject[] = [
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
path: "locations",
|
||||
element: <Outlet />,
|
||||
handle: {
|
||||
crumb: () => "Locations",
|
||||
},
|
||||
children: [
|
||||
{
|
||||
path: "",
|
||||
lazy: () => import("../../v2-routes/locations/location-list"),
|
||||
children: [
|
||||
{
|
||||
path: "create",
|
||||
lazy: () =>
|
||||
import("../../v2-routes/locations/location-create"),
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
path: ":id",
|
||||
lazy: () => import("../../v2-routes/locations/location-detail"),
|
||||
children: [
|
||||
{
|
||||
path: "edit",
|
||||
lazy: () =>
|
||||
import("../../v2-routes/locations/location-edit"),
|
||||
},
|
||||
{
|
||||
path: "add-sales-channels",
|
||||
lazy: () =>
|
||||
import(
|
||||
"../../v2-routes/locations/location-add-sales-channels"
|
||||
),
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
path: "sales-channels",
|
||||
element: <Outlet />,
|
||||
@@ -727,6 +650,89 @@ export const v2Routes: RouteObject[] = [
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
path: "shipping",
|
||||
element: <Outlet />,
|
||||
handle: {
|
||||
crumb: () => "Location & Shipping",
|
||||
},
|
||||
children: [
|
||||
{
|
||||
path: "",
|
||||
lazy: () => import("../../v2-routes/shipping/location-list"),
|
||||
},
|
||||
{
|
||||
path: "create",
|
||||
lazy: () => import("../../v2-routes/shipping/location-create"),
|
||||
},
|
||||
{
|
||||
path: ":location_id",
|
||||
lazy: () => import("../../v2-routes/shipping/location-details"),
|
||||
children: [
|
||||
{
|
||||
path: "edit",
|
||||
lazy: () =>
|
||||
import("../../v2-routes/shipping/location-edit"),
|
||||
},
|
||||
{
|
||||
path: "sales-channels/edit",
|
||||
lazy: () =>
|
||||
import(
|
||||
"../../v2-routes/shipping/location-add-sales-channels"
|
||||
),
|
||||
},
|
||||
{
|
||||
path: "fulfillment-set/:fset_id",
|
||||
children: [
|
||||
{
|
||||
path: "service-zones/create",
|
||||
lazy: () =>
|
||||
import(
|
||||
"../../v2-routes/shipping/service-zone-create"
|
||||
),
|
||||
},
|
||||
{
|
||||
path: "service-zone/:zone_id",
|
||||
children: [
|
||||
{
|
||||
path: "edit",
|
||||
lazy: () =>
|
||||
import(
|
||||
"../../v2-routes/shipping/service-zone-edit"
|
||||
),
|
||||
},
|
||||
{
|
||||
path: "shipping-option",
|
||||
children: [
|
||||
{
|
||||
path: "create",
|
||||
lazy: () =>
|
||||
import(
|
||||
"../../v2-routes/shipping/shipping-options-create"
|
||||
),
|
||||
},
|
||||
{
|
||||
path: ":so_id",
|
||||
children: [
|
||||
{
|
||||
path: "edit",
|
||||
lazy: () =>
|
||||
import(
|
||||
"../../v2-routes/shipping/shipping-option-edit"
|
||||
),
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
path: "workflows",
|
||||
element: <Outlet />,
|
||||
|
||||
Reference in New Issue
Block a user