@medusajs/draft-order 2.10.4-snapshot-20250925200335 → 2.10.4-snapshot-20250926124023
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.medusa/server/src/admin/index.js +76 -76
- package/.medusa/server/src/admin/index.mjs +76 -76
- package/package.json +16 -16
|
@@ -11385,74 +11385,6 @@ function getPromotionIds(items, shippingMethods) {
|
|
|
11385
11385
|
}
|
|
11386
11386
|
return Array.from(promotionIds);
|
|
11387
11387
|
}
|
|
11388
|
-
const Email = () => {
|
|
11389
|
-
const { id } = reactRouterDom.useParams();
|
|
11390
|
-
const { order, isPending, isError, error } = useOrder(id, {
|
|
11391
|
-
fields: "+email"
|
|
11392
|
-
});
|
|
11393
|
-
if (isError) {
|
|
11394
|
-
throw error;
|
|
11395
|
-
}
|
|
11396
|
-
const isReady = !isPending && !!order;
|
|
11397
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(RouteDrawer, { children: [
|
|
11398
|
-
/* @__PURE__ */ jsxRuntime.jsxs(RouteDrawer.Header, { children: [
|
|
11399
|
-
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Title, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(ui.Heading, { children: "Edit Email" }) }),
|
|
11400
|
-
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Description, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "sr-only", children: "Edit the email for the draft order" }) })
|
|
11401
|
-
] }),
|
|
11402
|
-
isReady && /* @__PURE__ */ jsxRuntime.jsx(EmailForm, { order })
|
|
11403
|
-
] });
|
|
11404
|
-
};
|
|
11405
|
-
const EmailForm = ({ order }) => {
|
|
11406
|
-
const form = reactHookForm.useForm({
|
|
11407
|
-
defaultValues: {
|
|
11408
|
-
email: order.email ?? ""
|
|
11409
|
-
},
|
|
11410
|
-
resolver: zod.zodResolver(schema$3)
|
|
11411
|
-
});
|
|
11412
|
-
const { mutateAsync, isPending } = useUpdateDraftOrder(order.id);
|
|
11413
|
-
const { handleSuccess } = useRouteModal();
|
|
11414
|
-
const onSubmit = form.handleSubmit(async (data) => {
|
|
11415
|
-
await mutateAsync(
|
|
11416
|
-
{ email: data.email },
|
|
11417
|
-
{
|
|
11418
|
-
onSuccess: () => {
|
|
11419
|
-
handleSuccess();
|
|
11420
|
-
},
|
|
11421
|
-
onError: (error) => {
|
|
11422
|
-
ui.toast.error(error.message);
|
|
11423
|
-
}
|
|
11424
|
-
}
|
|
11425
|
-
);
|
|
11426
|
-
});
|
|
11427
|
-
return /* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Form, { form, children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
11428
|
-
KeyboundForm,
|
|
11429
|
-
{
|
|
11430
|
-
className: "flex flex-1 flex-col overflow-hidden",
|
|
11431
|
-
onSubmit,
|
|
11432
|
-
children: [
|
|
11433
|
-
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Body, { className: "flex flex-col gap-y-6 overflow-y-auto", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
11434
|
-
Form$2.Field,
|
|
11435
|
-
{
|
|
11436
|
-
control: form.control,
|
|
11437
|
-
name: "email",
|
|
11438
|
-
render: ({ field }) => /* @__PURE__ */ jsxRuntime.jsxs(Form$2.Item, { children: [
|
|
11439
|
-
/* @__PURE__ */ jsxRuntime.jsx(Form$2.Label, { children: "Email" }),
|
|
11440
|
-
/* @__PURE__ */ jsxRuntime.jsx(Form$2.Control, { children: /* @__PURE__ */ jsxRuntime.jsx(ui.Input, { ...field }) }),
|
|
11441
|
-
/* @__PURE__ */ jsxRuntime.jsx(Form$2.ErrorMessage, {})
|
|
11442
|
-
] })
|
|
11443
|
-
}
|
|
11444
|
-
) }),
|
|
11445
|
-
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Footer, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-end gap-2", children: [
|
|
11446
|
-
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Close, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(ui.Button, { size: "small", variant: "secondary", children: "Cancel" }) }),
|
|
11447
|
-
/* @__PURE__ */ jsxRuntime.jsx(ui.Button, { size: "small", type: "submit", isLoading: isPending, children: "Save" })
|
|
11448
|
-
] }) })
|
|
11449
|
-
]
|
|
11450
|
-
}
|
|
11451
|
-
) });
|
|
11452
|
-
};
|
|
11453
|
-
const schema$3 = objectType({
|
|
11454
|
-
email: stringType().email()
|
|
11455
|
-
});
|
|
11456
11388
|
const STACKED_FOCUS_MODAL_ID = "shipping-form";
|
|
11457
11389
|
const Shipping = () => {
|
|
11458
11390
|
var _a;
|
|
@@ -12292,7 +12224,7 @@ const ShippingAddressForm = ({ order }) => {
|
|
|
12292
12224
|
postal_code: ((_i = order.shipping_address) == null ? void 0 : _i.postal_code) ?? "",
|
|
12293
12225
|
phone: ((_j = order.shipping_address) == null ? void 0 : _j.phone) ?? ""
|
|
12294
12226
|
},
|
|
12295
|
-
resolver: zod.zodResolver(schema$
|
|
12227
|
+
resolver: zod.zodResolver(schema$3)
|
|
12296
12228
|
});
|
|
12297
12229
|
const { mutateAsync, isPending } = useUpdateDraftOrder(order.id);
|
|
12298
12230
|
const { handleSuccess } = useRouteModal();
|
|
@@ -12462,7 +12394,7 @@ const ShippingAddressForm = ({ order }) => {
|
|
|
12462
12394
|
}
|
|
12463
12395
|
) });
|
|
12464
12396
|
};
|
|
12465
|
-
const schema$
|
|
12397
|
+
const schema$3 = addressSchema;
|
|
12466
12398
|
const TransferOwnership = () => {
|
|
12467
12399
|
const { id } = reactRouterDom.useParams();
|
|
12468
12400
|
const { draft_order, isPending, isError, error } = useDraftOrder(id, {
|
|
@@ -12486,7 +12418,7 @@ const TransferOwnershipForm = ({ order }) => {
|
|
|
12486
12418
|
defaultValues: {
|
|
12487
12419
|
customer_id: order.customer_id || ""
|
|
12488
12420
|
},
|
|
12489
|
-
resolver: zod.zodResolver(schema$
|
|
12421
|
+
resolver: zod.zodResolver(schema$2)
|
|
12490
12422
|
});
|
|
12491
12423
|
const { mutateAsync, isPending } = useUpdateDraftOrder(order.id);
|
|
12492
12424
|
const { handleSuccess } = useRouteModal();
|
|
@@ -12936,9 +12868,77 @@ const Illustration = () => {
|
|
|
12936
12868
|
}
|
|
12937
12869
|
);
|
|
12938
12870
|
};
|
|
12939
|
-
const schema$
|
|
12871
|
+
const schema$2 = objectType({
|
|
12940
12872
|
customer_id: stringType().min(1)
|
|
12941
12873
|
});
|
|
12874
|
+
const Email = () => {
|
|
12875
|
+
const { id } = reactRouterDom.useParams();
|
|
12876
|
+
const { order, isPending, isError, error } = useOrder(id, {
|
|
12877
|
+
fields: "+email"
|
|
12878
|
+
});
|
|
12879
|
+
if (isError) {
|
|
12880
|
+
throw error;
|
|
12881
|
+
}
|
|
12882
|
+
const isReady = !isPending && !!order;
|
|
12883
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(RouteDrawer, { children: [
|
|
12884
|
+
/* @__PURE__ */ jsxRuntime.jsxs(RouteDrawer.Header, { children: [
|
|
12885
|
+
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Title, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(ui.Heading, { children: "Edit Email" }) }),
|
|
12886
|
+
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Description, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "sr-only", children: "Edit the email for the draft order" }) })
|
|
12887
|
+
] }),
|
|
12888
|
+
isReady && /* @__PURE__ */ jsxRuntime.jsx(EmailForm, { order })
|
|
12889
|
+
] });
|
|
12890
|
+
};
|
|
12891
|
+
const EmailForm = ({ order }) => {
|
|
12892
|
+
const form = reactHookForm.useForm({
|
|
12893
|
+
defaultValues: {
|
|
12894
|
+
email: order.email ?? ""
|
|
12895
|
+
},
|
|
12896
|
+
resolver: zod.zodResolver(schema$1)
|
|
12897
|
+
});
|
|
12898
|
+
const { mutateAsync, isPending } = useUpdateDraftOrder(order.id);
|
|
12899
|
+
const { handleSuccess } = useRouteModal();
|
|
12900
|
+
const onSubmit = form.handleSubmit(async (data) => {
|
|
12901
|
+
await mutateAsync(
|
|
12902
|
+
{ email: data.email },
|
|
12903
|
+
{
|
|
12904
|
+
onSuccess: () => {
|
|
12905
|
+
handleSuccess();
|
|
12906
|
+
},
|
|
12907
|
+
onError: (error) => {
|
|
12908
|
+
ui.toast.error(error.message);
|
|
12909
|
+
}
|
|
12910
|
+
}
|
|
12911
|
+
);
|
|
12912
|
+
});
|
|
12913
|
+
return /* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Form, { form, children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
12914
|
+
KeyboundForm,
|
|
12915
|
+
{
|
|
12916
|
+
className: "flex flex-1 flex-col overflow-hidden",
|
|
12917
|
+
onSubmit,
|
|
12918
|
+
children: [
|
|
12919
|
+
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Body, { className: "flex flex-col gap-y-6 overflow-y-auto", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
12920
|
+
Form$2.Field,
|
|
12921
|
+
{
|
|
12922
|
+
control: form.control,
|
|
12923
|
+
name: "email",
|
|
12924
|
+
render: ({ field }) => /* @__PURE__ */ jsxRuntime.jsxs(Form$2.Item, { children: [
|
|
12925
|
+
/* @__PURE__ */ jsxRuntime.jsx(Form$2.Label, { children: "Email" }),
|
|
12926
|
+
/* @__PURE__ */ jsxRuntime.jsx(Form$2.Control, { children: /* @__PURE__ */ jsxRuntime.jsx(ui.Input, { ...field }) }),
|
|
12927
|
+
/* @__PURE__ */ jsxRuntime.jsx(Form$2.ErrorMessage, {})
|
|
12928
|
+
] })
|
|
12929
|
+
}
|
|
12930
|
+
) }),
|
|
12931
|
+
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Footer, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-end gap-2", children: [
|
|
12932
|
+
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Close, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(ui.Button, { size: "small", variant: "secondary", children: "Cancel" }) }),
|
|
12933
|
+
/* @__PURE__ */ jsxRuntime.jsx(ui.Button, { size: "small", type: "submit", isLoading: isPending, children: "Save" })
|
|
12934
|
+
] }) })
|
|
12935
|
+
]
|
|
12936
|
+
}
|
|
12937
|
+
) });
|
|
12938
|
+
};
|
|
12939
|
+
const schema$1 = objectType({
|
|
12940
|
+
email: stringType().email()
|
|
12941
|
+
});
|
|
12942
12942
|
const SalesChannel = () => {
|
|
12943
12943
|
const { id } = reactRouterDom.useParams();
|
|
12944
12944
|
const { draft_order, isPending, isError, error } = useDraftOrder(
|
|
@@ -13085,10 +13085,6 @@ const routeModule = {
|
|
|
13085
13085
|
Component: Promotions,
|
|
13086
13086
|
path: "/draft-orders/:id/promotions"
|
|
13087
13087
|
},
|
|
13088
|
-
{
|
|
13089
|
-
Component: Email,
|
|
13090
|
-
path: "/draft-orders/:id/email"
|
|
13091
|
-
},
|
|
13092
13088
|
{
|
|
13093
13089
|
Component: Shipping,
|
|
13094
13090
|
path: "/draft-orders/:id/shipping"
|
|
@@ -13101,6 +13097,10 @@ const routeModule = {
|
|
|
13101
13097
|
Component: TransferOwnership,
|
|
13102
13098
|
path: "/draft-orders/:id/transfer-ownership"
|
|
13103
13099
|
},
|
|
13100
|
+
{
|
|
13101
|
+
Component: Email,
|
|
13102
|
+
path: "/draft-orders/:id/email"
|
|
13103
|
+
},
|
|
13104
13104
|
{
|
|
13105
13105
|
Component: SalesChannel,
|
|
13106
13106
|
path: "/draft-orders/:id/sales-channel"
|
|
@@ -11379,74 +11379,6 @@ function getPromotionIds(items, shippingMethods) {
|
|
|
11379
11379
|
}
|
|
11380
11380
|
return Array.from(promotionIds);
|
|
11381
11381
|
}
|
|
11382
|
-
const Email = () => {
|
|
11383
|
-
const { id } = useParams();
|
|
11384
|
-
const { order, isPending, isError, error } = useOrder(id, {
|
|
11385
|
-
fields: "+email"
|
|
11386
|
-
});
|
|
11387
|
-
if (isError) {
|
|
11388
|
-
throw error;
|
|
11389
|
-
}
|
|
11390
|
-
const isReady = !isPending && !!order;
|
|
11391
|
-
return /* @__PURE__ */ jsxs(RouteDrawer, { children: [
|
|
11392
|
-
/* @__PURE__ */ jsxs(RouteDrawer.Header, { children: [
|
|
11393
|
-
/* @__PURE__ */ jsx(RouteDrawer.Title, { asChild: true, children: /* @__PURE__ */ jsx(Heading, { children: "Edit Email" }) }),
|
|
11394
|
-
/* @__PURE__ */ jsx(RouteDrawer.Description, { asChild: true, children: /* @__PURE__ */ jsx("span", { className: "sr-only", children: "Edit the email for the draft order" }) })
|
|
11395
|
-
] }),
|
|
11396
|
-
isReady && /* @__PURE__ */ jsx(EmailForm, { order })
|
|
11397
|
-
] });
|
|
11398
|
-
};
|
|
11399
|
-
const EmailForm = ({ order }) => {
|
|
11400
|
-
const form = useForm({
|
|
11401
|
-
defaultValues: {
|
|
11402
|
-
email: order.email ?? ""
|
|
11403
|
-
},
|
|
11404
|
-
resolver: zodResolver(schema$3)
|
|
11405
|
-
});
|
|
11406
|
-
const { mutateAsync, isPending } = useUpdateDraftOrder(order.id);
|
|
11407
|
-
const { handleSuccess } = useRouteModal();
|
|
11408
|
-
const onSubmit = form.handleSubmit(async (data) => {
|
|
11409
|
-
await mutateAsync(
|
|
11410
|
-
{ email: data.email },
|
|
11411
|
-
{
|
|
11412
|
-
onSuccess: () => {
|
|
11413
|
-
handleSuccess();
|
|
11414
|
-
},
|
|
11415
|
-
onError: (error) => {
|
|
11416
|
-
toast.error(error.message);
|
|
11417
|
-
}
|
|
11418
|
-
}
|
|
11419
|
-
);
|
|
11420
|
-
});
|
|
11421
|
-
return /* @__PURE__ */ jsx(RouteDrawer.Form, { form, children: /* @__PURE__ */ jsxs(
|
|
11422
|
-
KeyboundForm,
|
|
11423
|
-
{
|
|
11424
|
-
className: "flex flex-1 flex-col overflow-hidden",
|
|
11425
|
-
onSubmit,
|
|
11426
|
-
children: [
|
|
11427
|
-
/* @__PURE__ */ jsx(RouteDrawer.Body, { className: "flex flex-col gap-y-6 overflow-y-auto", children: /* @__PURE__ */ jsx(
|
|
11428
|
-
Form$2.Field,
|
|
11429
|
-
{
|
|
11430
|
-
control: form.control,
|
|
11431
|
-
name: "email",
|
|
11432
|
-
render: ({ field }) => /* @__PURE__ */ jsxs(Form$2.Item, { children: [
|
|
11433
|
-
/* @__PURE__ */ jsx(Form$2.Label, { children: "Email" }),
|
|
11434
|
-
/* @__PURE__ */ jsx(Form$2.Control, { children: /* @__PURE__ */ jsx(Input, { ...field }) }),
|
|
11435
|
-
/* @__PURE__ */ jsx(Form$2.ErrorMessage, {})
|
|
11436
|
-
] })
|
|
11437
|
-
}
|
|
11438
|
-
) }),
|
|
11439
|
-
/* @__PURE__ */ jsx(RouteDrawer.Footer, { children: /* @__PURE__ */ jsxs("div", { className: "flex justify-end gap-2", children: [
|
|
11440
|
-
/* @__PURE__ */ jsx(RouteDrawer.Close, { asChild: true, children: /* @__PURE__ */ jsx(Button, { size: "small", variant: "secondary", children: "Cancel" }) }),
|
|
11441
|
-
/* @__PURE__ */ jsx(Button, { size: "small", type: "submit", isLoading: isPending, children: "Save" })
|
|
11442
|
-
] }) })
|
|
11443
|
-
]
|
|
11444
|
-
}
|
|
11445
|
-
) });
|
|
11446
|
-
};
|
|
11447
|
-
const schema$3 = objectType({
|
|
11448
|
-
email: stringType().email()
|
|
11449
|
-
});
|
|
11450
11382
|
const STACKED_FOCUS_MODAL_ID = "shipping-form";
|
|
11451
11383
|
const Shipping = () => {
|
|
11452
11384
|
var _a;
|
|
@@ -12286,7 +12218,7 @@ const ShippingAddressForm = ({ order }) => {
|
|
|
12286
12218
|
postal_code: ((_i = order.shipping_address) == null ? void 0 : _i.postal_code) ?? "",
|
|
12287
12219
|
phone: ((_j = order.shipping_address) == null ? void 0 : _j.phone) ?? ""
|
|
12288
12220
|
},
|
|
12289
|
-
resolver: zodResolver(schema$
|
|
12221
|
+
resolver: zodResolver(schema$3)
|
|
12290
12222
|
});
|
|
12291
12223
|
const { mutateAsync, isPending } = useUpdateDraftOrder(order.id);
|
|
12292
12224
|
const { handleSuccess } = useRouteModal();
|
|
@@ -12456,7 +12388,7 @@ const ShippingAddressForm = ({ order }) => {
|
|
|
12456
12388
|
}
|
|
12457
12389
|
) });
|
|
12458
12390
|
};
|
|
12459
|
-
const schema$
|
|
12391
|
+
const schema$3 = addressSchema;
|
|
12460
12392
|
const TransferOwnership = () => {
|
|
12461
12393
|
const { id } = useParams();
|
|
12462
12394
|
const { draft_order, isPending, isError, error } = useDraftOrder(id, {
|
|
@@ -12480,7 +12412,7 @@ const TransferOwnershipForm = ({ order }) => {
|
|
|
12480
12412
|
defaultValues: {
|
|
12481
12413
|
customer_id: order.customer_id || ""
|
|
12482
12414
|
},
|
|
12483
|
-
resolver: zodResolver(schema$
|
|
12415
|
+
resolver: zodResolver(schema$2)
|
|
12484
12416
|
});
|
|
12485
12417
|
const { mutateAsync, isPending } = useUpdateDraftOrder(order.id);
|
|
12486
12418
|
const { handleSuccess } = useRouteModal();
|
|
@@ -12930,9 +12862,77 @@ const Illustration = () => {
|
|
|
12930
12862
|
}
|
|
12931
12863
|
);
|
|
12932
12864
|
};
|
|
12933
|
-
const schema$
|
|
12865
|
+
const schema$2 = objectType({
|
|
12934
12866
|
customer_id: stringType().min(1)
|
|
12935
12867
|
});
|
|
12868
|
+
const Email = () => {
|
|
12869
|
+
const { id } = useParams();
|
|
12870
|
+
const { order, isPending, isError, error } = useOrder(id, {
|
|
12871
|
+
fields: "+email"
|
|
12872
|
+
});
|
|
12873
|
+
if (isError) {
|
|
12874
|
+
throw error;
|
|
12875
|
+
}
|
|
12876
|
+
const isReady = !isPending && !!order;
|
|
12877
|
+
return /* @__PURE__ */ jsxs(RouteDrawer, { children: [
|
|
12878
|
+
/* @__PURE__ */ jsxs(RouteDrawer.Header, { children: [
|
|
12879
|
+
/* @__PURE__ */ jsx(RouteDrawer.Title, { asChild: true, children: /* @__PURE__ */ jsx(Heading, { children: "Edit Email" }) }),
|
|
12880
|
+
/* @__PURE__ */ jsx(RouteDrawer.Description, { asChild: true, children: /* @__PURE__ */ jsx("span", { className: "sr-only", children: "Edit the email for the draft order" }) })
|
|
12881
|
+
] }),
|
|
12882
|
+
isReady && /* @__PURE__ */ jsx(EmailForm, { order })
|
|
12883
|
+
] });
|
|
12884
|
+
};
|
|
12885
|
+
const EmailForm = ({ order }) => {
|
|
12886
|
+
const form = useForm({
|
|
12887
|
+
defaultValues: {
|
|
12888
|
+
email: order.email ?? ""
|
|
12889
|
+
},
|
|
12890
|
+
resolver: zodResolver(schema$1)
|
|
12891
|
+
});
|
|
12892
|
+
const { mutateAsync, isPending } = useUpdateDraftOrder(order.id);
|
|
12893
|
+
const { handleSuccess } = useRouteModal();
|
|
12894
|
+
const onSubmit = form.handleSubmit(async (data) => {
|
|
12895
|
+
await mutateAsync(
|
|
12896
|
+
{ email: data.email },
|
|
12897
|
+
{
|
|
12898
|
+
onSuccess: () => {
|
|
12899
|
+
handleSuccess();
|
|
12900
|
+
},
|
|
12901
|
+
onError: (error) => {
|
|
12902
|
+
toast.error(error.message);
|
|
12903
|
+
}
|
|
12904
|
+
}
|
|
12905
|
+
);
|
|
12906
|
+
});
|
|
12907
|
+
return /* @__PURE__ */ jsx(RouteDrawer.Form, { form, children: /* @__PURE__ */ jsxs(
|
|
12908
|
+
KeyboundForm,
|
|
12909
|
+
{
|
|
12910
|
+
className: "flex flex-1 flex-col overflow-hidden",
|
|
12911
|
+
onSubmit,
|
|
12912
|
+
children: [
|
|
12913
|
+
/* @__PURE__ */ jsx(RouteDrawer.Body, { className: "flex flex-col gap-y-6 overflow-y-auto", children: /* @__PURE__ */ jsx(
|
|
12914
|
+
Form$2.Field,
|
|
12915
|
+
{
|
|
12916
|
+
control: form.control,
|
|
12917
|
+
name: "email",
|
|
12918
|
+
render: ({ field }) => /* @__PURE__ */ jsxs(Form$2.Item, { children: [
|
|
12919
|
+
/* @__PURE__ */ jsx(Form$2.Label, { children: "Email" }),
|
|
12920
|
+
/* @__PURE__ */ jsx(Form$2.Control, { children: /* @__PURE__ */ jsx(Input, { ...field }) }),
|
|
12921
|
+
/* @__PURE__ */ jsx(Form$2.ErrorMessage, {})
|
|
12922
|
+
] })
|
|
12923
|
+
}
|
|
12924
|
+
) }),
|
|
12925
|
+
/* @__PURE__ */ jsx(RouteDrawer.Footer, { children: /* @__PURE__ */ jsxs("div", { className: "flex justify-end gap-2", children: [
|
|
12926
|
+
/* @__PURE__ */ jsx(RouteDrawer.Close, { asChild: true, children: /* @__PURE__ */ jsx(Button, { size: "small", variant: "secondary", children: "Cancel" }) }),
|
|
12927
|
+
/* @__PURE__ */ jsx(Button, { size: "small", type: "submit", isLoading: isPending, children: "Save" })
|
|
12928
|
+
] }) })
|
|
12929
|
+
]
|
|
12930
|
+
}
|
|
12931
|
+
) });
|
|
12932
|
+
};
|
|
12933
|
+
const schema$1 = objectType({
|
|
12934
|
+
email: stringType().email()
|
|
12935
|
+
});
|
|
12936
12936
|
const SalesChannel = () => {
|
|
12937
12937
|
const { id } = useParams();
|
|
12938
12938
|
const { draft_order, isPending, isError, error } = useDraftOrder(
|
|
@@ -13079,10 +13079,6 @@ const routeModule = {
|
|
|
13079
13079
|
Component: Promotions,
|
|
13080
13080
|
path: "/draft-orders/:id/promotions"
|
|
13081
13081
|
},
|
|
13082
|
-
{
|
|
13083
|
-
Component: Email,
|
|
13084
|
-
path: "/draft-orders/:id/email"
|
|
13085
|
-
},
|
|
13086
13082
|
{
|
|
13087
13083
|
Component: Shipping,
|
|
13088
13084
|
path: "/draft-orders/:id/shipping"
|
|
@@ -13095,6 +13091,10 @@ const routeModule = {
|
|
|
13095
13091
|
Component: TransferOwnership,
|
|
13096
13092
|
path: "/draft-orders/:id/transfer-ownership"
|
|
13097
13093
|
},
|
|
13094
|
+
{
|
|
13095
|
+
Component: Email,
|
|
13096
|
+
path: "/draft-orders/:id/email"
|
|
13097
|
+
},
|
|
13098
13098
|
{
|
|
13099
13099
|
Component: SalesChannel,
|
|
13100
13100
|
path: "/draft-orders/:id/sales-channel"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@medusajs/draft-order",
|
|
3
|
-
"version": "2.10.4-snapshot-
|
|
3
|
+
"version": "2.10.4-snapshot-20250926124023",
|
|
4
4
|
"description": "A starter for Medusa plugins.",
|
|
5
5
|
"author": "Medusa (https://medusajs.com)",
|
|
6
6
|
"license": "MIT",
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
"dependencies": {
|
|
37
37
|
"@ariakit/react": "^0.4.15",
|
|
38
38
|
"@hookform/resolvers": "3.4.2",
|
|
39
|
-
"@medusajs/js-sdk": "2.10.4-snapshot-
|
|
39
|
+
"@medusajs/js-sdk": "2.10.4-snapshot-20250926124023",
|
|
40
40
|
"@tanstack/react-query": "5.64.2",
|
|
41
41
|
"@uiw/react-json-view": "^2.0.0-alpha.17",
|
|
42
42
|
"date-fns": "^3.6.0",
|
|
@@ -45,14 +45,14 @@
|
|
|
45
45
|
"react-hook-form": "7.49.1"
|
|
46
46
|
},
|
|
47
47
|
"devDependencies": {
|
|
48
|
-
"@medusajs/admin-sdk": "2.10.4-snapshot-
|
|
49
|
-
"@medusajs/cli": "2.10.4-snapshot-
|
|
50
|
-
"@medusajs/framework": "2.10.4-snapshot-
|
|
51
|
-
"@medusajs/icons": "2.10.4-snapshot-
|
|
52
|
-
"@medusajs/test-utils": "2.10.4-snapshot-
|
|
53
|
-
"@medusajs/types": "2.10.4-snapshot-
|
|
54
|
-
"@medusajs/ui": "4.0.24-snapshot-
|
|
55
|
-
"@medusajs/ui-preset": "2.10.4-snapshot-
|
|
48
|
+
"@medusajs/admin-sdk": "2.10.4-snapshot-20250926124023",
|
|
49
|
+
"@medusajs/cli": "2.10.4-snapshot-20250926124023",
|
|
50
|
+
"@medusajs/framework": "2.10.4-snapshot-20250926124023",
|
|
51
|
+
"@medusajs/icons": "2.10.4-snapshot-20250926124023",
|
|
52
|
+
"@medusajs/test-utils": "2.10.4-snapshot-20250926124023",
|
|
53
|
+
"@medusajs/types": "2.10.4-snapshot-20250926124023",
|
|
54
|
+
"@medusajs/ui": "4.0.24-snapshot-20250926124023",
|
|
55
|
+
"@medusajs/ui-preset": "2.10.4-snapshot-20250926124023",
|
|
56
56
|
"@swc/core": "1.5.7",
|
|
57
57
|
"@types/lodash": "^4.17.15",
|
|
58
58
|
"@types/node": "^20.0.0",
|
|
@@ -69,12 +69,12 @@
|
|
|
69
69
|
"yalc": "^1.0.0-pre.53"
|
|
70
70
|
},
|
|
71
71
|
"peerDependencies": {
|
|
72
|
-
"@medusajs/admin-sdk": "2.10.4-snapshot-
|
|
73
|
-
"@medusajs/cli": "2.10.4-snapshot-
|
|
74
|
-
"@medusajs/framework": "2.10.4-snapshot-
|
|
75
|
-
"@medusajs/icons": "2.10.4-snapshot-
|
|
76
|
-
"@medusajs/test-utils": "2.10.4-snapshot-
|
|
77
|
-
"@medusajs/ui": "4.0.24-snapshot-
|
|
72
|
+
"@medusajs/admin-sdk": "2.10.4-snapshot-20250926124023",
|
|
73
|
+
"@medusajs/cli": "2.10.4-snapshot-20250926124023",
|
|
74
|
+
"@medusajs/framework": "2.10.4-snapshot-20250926124023",
|
|
75
|
+
"@medusajs/icons": "2.10.4-snapshot-20250926124023",
|
|
76
|
+
"@medusajs/test-utils": "2.10.4-snapshot-20250926124023",
|
|
77
|
+
"@medusajs/ui": "4.0.24-snapshot-20250926124023",
|
|
78
78
|
"lodash": "^4.17.21",
|
|
79
79
|
"react-router-dom": "6.20.1"
|
|
80
80
|
},
|