@mercurjs/admin 2.2.0-canary.40 → 2.2.0-canary.41
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/dist/{attribute-create-VGL7LGIH.js → attribute-create-VAR6C5GW.js} +4 -2
- package/dist/{attribute-detail-EKDAYT4B.js → attribute-detail-LBACUDU3.js} +1 -1
- package/dist/{attribute-edit-OBNLNOJS.js → attribute-edit-WXO5FGR6.js} +2 -2
- package/dist/{attribute-edit-possible-value-QDFVWLA3.js → attribute-edit-possible-value-RO7BY3NC.js} +2 -2
- package/dist/{campaign-detail-RNB3FEJZ.js → campaign-detail-6J7PTIIP.js} +1 -1
- package/dist/{campaign-edit-MAS3DCFB.js → campaign-edit-DBAJFIH4.js} +18 -5
- package/dist/{campaign-list-CDV4GWWD.js → campaign-list-XH7UM5JJ.js} +1 -1
- package/dist/{category-create-AIS2MG7E.js → category-create-CJZZZLDD.js} +1 -1
- package/dist/{category-detail-557376TZ.js → category-detail-XV6CDZZL.js} +5 -5
- package/dist/{category-edit-LYR2IOTA.js → category-edit-2NCWDSZY.js} +19 -6
- package/dist/{category-list-XKRI24VN.js → category-list-WYMOJJLW.js} +1 -1
- package/dist/{category-products-44PCDDNN.js → category-products-CQV2TKLY.js} +4 -4
- package/dist/{chunk-HRDVGFS7.js → chunk-27XNPAJP.js} +9 -3
- package/dist/{chunk-KGA2XI6W.js → chunk-2CJIE5MY.js} +18 -7
- package/dist/{chunk-PMVWIBTI.js → chunk-3L4IFGRJ.js} +45 -8
- package/dist/{chunk-HQM7D57C.js → chunk-4RLXMDIJ.js} +2 -2
- package/dist/{chunk-5ACJR6WB.js → chunk-4XYSIVPO.js} +2 -2
- package/dist/{chunk-J3L2FUIA.js → chunk-5DAFNAZJ.js} +49 -33
- package/dist/{chunk-BLR3NTU6.js → chunk-5PNM6QNB.js} +2 -0
- package/dist/{chunk-GCU4LHGY.js → chunk-5UT374IW.js} +69 -24
- package/dist/{chunk-BTJR5RSV.js → chunk-7U2JJYMP.js} +41 -13
- package/dist/{chunk-2Z2M5K5A.js → chunk-ADTYNS4J.js} +1 -1
- package/dist/chunk-APAT344J.js +144 -0
- package/dist/{chunk-NWSKT55Z.js → chunk-BQWSY6FS.js} +1 -1
- package/dist/{chunk-NZVS6B77.js → chunk-CBD7HK2G.js} +54 -17
- package/dist/{chunk-WKDHY2DJ.js → chunk-COOOOQ2N.js} +1 -1
- package/dist/{chunk-56UFDHNO.js → chunk-DJD3MWED.js} +1 -1
- package/dist/{chunk-BVIIRGSW.js → chunk-F3F4JC7E.js} +3 -1
- package/dist/{chunk-7O7LYBHL.js → chunk-FNCDMOOR.js} +50 -18
- package/dist/{chunk-TDJSZ73V.js → chunk-GXU246YJ.js} +31 -4
- package/dist/{chunk-OYZIFLLC.js → chunk-I5HY5Q3K.js} +1 -1
- package/dist/{chunk-MZOINNCV.js → chunk-IASJSRP5.js} +70 -49
- package/dist/{chunk-THPXRTE5.js → chunk-IMLKFVFH.js} +23 -6
- package/dist/{chunk-EX4AGESR.js → chunk-IZBV7MCY.js} +61 -27
- package/dist/{chunk-Q6QXFLUY.js → chunk-JEN37H6L.js} +2 -0
- package/dist/{chunk-FICKHCWL.js → chunk-K2JORJRZ.js} +3 -1
- package/dist/{chunk-NISAIYSW.js → chunk-KRFXBBBU.js} +2 -2
- package/dist/{chunk-OAN4CZKX.js → chunk-KUCNCDST.js} +2 -0
- package/dist/{chunk-VJ4LQXMA.js → chunk-L2D2AMTK.js} +4 -2
- package/dist/{chunk-DPG4AWSG.js → chunk-LBDSZT5Q.js} +17 -6
- package/dist/{chunk-4346EIRG.js → chunk-LGOPKYNG.js} +1 -1
- package/dist/{chunk-VYQ6ASFF.js → chunk-MFCQTAVI.js} +15 -4
- package/dist/{chunk-TH26CWVG.js → chunk-NLJ5F7FS.js} +1 -1
- package/dist/{chunk-MOG7LT73.js → chunk-NPHYCQMP.js} +4 -2
- package/dist/{chunk-LVRCEGL7.js → chunk-ORCMDF54.js} +27 -11
- package/dist/{chunk-65YE4SVL.js → chunk-OVUKVGGD.js} +18 -7
- package/dist/{chunk-VPYI4X6C.js → chunk-PLU2GB4L.js} +27 -7
- package/dist/{chunk-GISFIAGQ.js → chunk-QAONUPAX.js} +42 -13
- package/dist/{chunk-W3P3RP5R.js → chunk-QFFF542X.js} +9 -3
- package/dist/{chunk-JU2O2H7I.js → chunk-RATQZHCS.js} +2 -2
- package/dist/{chunk-DI2M3J5Q.js → chunk-RMB7MPIT.js} +1 -1
- package/dist/{chunk-KFYTUQXT.js → chunk-S2C6DUQJ.js} +2 -2
- package/dist/{chunk-UZ452ISX.js → chunk-U4MV53CS.js} +32 -14
- package/dist/{chunk-VBKFXL2Q.js → chunk-USG4EATH.js} +19 -4
- package/dist/{chunk-IVBNI2QE.js → chunk-VIJXGPDE.js} +78 -24
- package/dist/{chunk-W7CJSBDM.js → chunk-VLYPVR5U.js} +19 -8
- package/dist/{chunk-6KWWJE5P.js → chunk-VXDRQQRZ.js} +3 -3
- package/dist/{chunk-DSTHXHJ5.js → chunk-VYSB4CTB.js} +1356 -1356
- package/dist/{chunk-YRUCTB6M.js → chunk-WEVSVBVF.js} +1 -1
- package/dist/{chunk-3BTRS4AA.js → chunk-WMK3BQPH.js} +1 -1
- package/dist/{chunk-EGHDC6K6.js → chunk-X6KFVVHH.js} +2 -2
- package/dist/{chunk-2FPQHWJZ.js → chunk-X7IR2TVL.js} +106 -24
- package/dist/{collection-add-products-JFUIZEZI.js → collection-add-products-XUKFZOCQ.js} +4 -4
- package/dist/{collection-detail-2WOLOVWF.js → collection-detail-ID4FKP22.js} +5 -5
- package/dist/{collection-edit-UMZN5JZ6.js → collection-edit-GPUKISIV.js} +18 -5
- package/dist/{collection-list-B3Y2ALLZ.js → collection-list-C6U4CPLD.js} +4 -4
- package/dist/{customer-detail-ZGDPIWA4.js → customer-detail-IG2QAAQL.js} +1 -1
- package/dist/{customer-edit-D55FJLIN.js → customer-edit-TADBOMPB.js} +18 -5
- package/dist/{customer-group-detail-FXUICFYC.js → customer-group-detail-2B7XJ7NT.js} +1 -1
- package/dist/{customer-group-edit-NZ5SUPFQ.js → customer-group-edit-BX4HKVNN.js} +33 -18
- package/dist/{customer-group-list-R2DP2D42.js → customer-group-list-7LN5TN3G.js} +1 -1
- package/dist/{customer-list-Z4DUQHCH.js → customer-list-K5TV3PSF.js} +1 -1
- package/dist/{edit-inventory-item-73BY4I5T.js → edit-inventory-item-4RXYRJ7O.js} +19 -6
- package/dist/{edit-reservation-BC5IOLK6.js → edit-reservation-HA6J6U2N.js} +18 -5
- package/dist/extension-targets.d.ts +195 -0
- package/dist/extension-targets.js +1 -0
- package/dist/index.d.ts +6 -2
- package/dist/index.js +136 -108
- package/dist/{inventory-create-XQKH3HZQ.js → inventory-create-B3FHGX6A.js} +1 -1
- package/dist/{inventory-detail-RZJNTJDF.js → inventory-detail-7VEJHRBB.js} +2 -2
- package/dist/{inventory-list-SPSBDJXO.js → inventory-list-IRQUQD4G.js} +1 -1
- package/dist/{location-fulfillment-providers-XXZ7AIUF.js → location-fulfillment-providers-MFM4SHJJ.js} +2 -2
- package/dist/{offer-detail-page-2G5BUOIB.js → offer-detail-page-THKNBFWZ.js} +61 -16
- package/dist/{offer-variant-detail-page-V6TKNYZL.js → offer-variant-detail-page-NDGPFP6P.js} +1 -1
- package/dist/{offers-2QQFKGAX.js → offers-LYLEYD3A.js} +22 -7
- package/dist/{order-detail-QUGH2GXH.js → order-detail-NYKOH7OO.js} +1 -1
- package/dist/{order-list-GMUOLGZY.js → order-list-EZWCH5YW.js} +3 -3
- package/dist/pages/index.js +47 -47
- package/dist/{price-list-create-HKN72A6Q.js → price-list-create-YHSA7U3L.js} +5 -5
- package/dist/{price-list-detail-6JAMNNJW.js → price-list-detail-3SS3DGRU.js} +5 -5
- package/dist/{price-list-edit-RZQMPHXU.js → price-list-edit-TRRPPI43.js} +19 -6
- package/dist/{price-list-list-HLWCOORV.js → price-list-list-REIHOWWT.js} +1 -1
- package/dist/{price-list-prices-add-ST6WNQNH.js → price-list-prices-add-X2GLUD7O.js} +5 -5
- package/dist/{product-add-existing-attributes-J6MML6MT.js → product-add-existing-attributes-GPAZOIXH.js} +2 -2
- package/dist/{product-create-B4DTC2OM.js → product-create-6FDBZUB4.js} +3 -3
- package/dist/{product-create-attribute-BP6NN4GO.js → product-create-attribute-YFIEH7HD.js} +1 -1
- package/dist/{product-create-variant-VDQQNHAK.js → product-create-variant-4O22DW7M.js} +3 -3
- package/dist/{product-detail-MFJ3AIU6.js → product-detail-VORTX3LT.js} +3 -3
- package/dist/{product-edit-attribute-AXPTES26.js → product-edit-attribute-NUJB7M6R.js} +2 -2
- package/dist/{product-list-DMQSLXM4.js → product-list-2WE2JY4F.js} +15 -12
- package/dist/{product-media-XRBLOV7D.js → product-media-LINHO45U.js} +2 -2
- package/dist/{product-tag-detail-4FL4CU5S.js → product-tag-detail-2PMM6RG6.js} +6 -6
- package/dist/{product-tag-list-YPTIDXPX.js → product-tag-list-KBNI6UDN.js} +6 -6
- package/dist/{product-type-detail-RAYCHYAF.js → product-type-detail-UKJ6RIHU.js} +5 -5
- package/dist/{product-variant-edit-C4HXFQFW.js → product-variant-edit-MAM2RQ4V.js} +2 -2
- package/dist/{promotion-create-7VBA6JFM.js → promotion-create-3EDHAI7E.js} +1 -1
- package/dist/{promotion-detail-KXXWEFHW.js → promotion-detail-PLGDC3A7.js} +1 -1
- package/dist/{promotion-edit-details-YM5JPGEC.js → promotion-edit-details-RTLPOQ4H.js} +20 -6
- package/dist/{promotion-list-56ZDROMH.js → promotion-list-D6HSZKGU.js} +1 -1
- package/dist/{refund-reason-list-PBLA5HYO.js → refund-reason-list-OWXAGHOQ.js} +5 -5
- package/dist/{reservation-detail-MAWHNY2H.js → reservation-detail-PWZ3PLC4.js} +2 -2
- package/dist/{reservation-list-UWZRPRPH.js → reservation-list-URKNAFIX.js} +1 -1
- package/dist/{return-reason-list-NPAAMB5H.js → return-reason-list-4ANB2PXX.js} +5 -5
- package/dist/{sales-channel-add-products-2BBIMN6N.js → sales-channel-add-products-NATZ7L5S.js} +4 -4
- package/dist/{sales-channel-detail-D5R7HPC7.js → sales-channel-detail-VDYOKH35.js} +5 -5
- package/dist/{store-bulk-edit-OIYKZ6AZ.js → store-bulk-edit-I2J5YYZK.js} +1 -1
- package/dist/{store-create-Y3BGG5P5.js → store-create-4UHISWQE.js} +1 -1
- package/dist/{store-details-56IHJJQV.js → store-details-4D7MSGVL.js} +5 -5
- package/dist/{store-edit-HWOGEOCH.js → store-edit-MQZMWYXY.js} +22 -8
- package/dist/{store-list-5DRW6QZF.js → store-list-EBAHJOZO.js} +4 -4
- package/dist/{store-member-invite-7ORIMT73.js → store-member-invite-J2JFDOHX.js} +1 -1
- package/dist/{tax-region-tax-override-create-R5GKEOK6.js → tax-region-tax-override-create-5PIUENUZ.js} +6 -6
- package/dist/{tax-region-tax-override-edit-MLJKNLAR.js → tax-region-tax-override-edit-GBPRPUTS.js} +6 -6
- package/package.json +17 -12
- package/dist/chunk-LFKTHNWI.js +0 -83
|
@@ -118,6 +118,7 @@ import {
|
|
|
118
118
|
// src/pages/orders/order-detail/order-detail.tsx
|
|
119
119
|
import { Children } from "react";
|
|
120
120
|
import { useLoaderData, useParams as useParams2 } from "react-router-dom";
|
|
121
|
+
import { WidgetZone } from "@mercurjs/dashboard-shared";
|
|
121
122
|
|
|
122
123
|
// src/pages/orders/order-detail/components/active-order-claim-section/active-order-claim-section.tsx
|
|
123
124
|
import { ExclamationCircle } from "@medusajs/icons";
|
|
@@ -454,6 +455,7 @@ var OrderActiveEditSection = ({
|
|
|
454
455
|
|
|
455
456
|
// src/pages/orders/order-detail/components/order-activity-section/order-activity-section.tsx
|
|
456
457
|
import { Container as Container5, Heading as Heading5 } from "@medusajs/ui";
|
|
458
|
+
import { DisplayExtensionZone } from "@mercurjs/dashboard-shared";
|
|
457
459
|
import { useTranslation as useTranslation8 } from "react-i18next";
|
|
458
460
|
|
|
459
461
|
// src/pages/orders/order-detail/components/order-activity-section/order-timeline.tsx
|
|
@@ -1379,12 +1381,14 @@ var OrderActivitySection = ({ order }) => {
|
|
|
1379
1381
|
const { t } = useTranslation8();
|
|
1380
1382
|
return /* @__PURE__ */ jsxs8(Container5, { className: "flex flex-col gap-y-8 px-6 py-4", "data-testid": "order-activity-section", children: [
|
|
1381
1383
|
/* @__PURE__ */ jsx8("div", { className: "flex flex-col gap-y-4", children: /* @__PURE__ */ jsx8("div", { className: "flex items-center justify-between", "data-testid": "order-activity-header", children: /* @__PURE__ */ jsx8(Heading5, { level: "h2", "data-testid": "order-activity-heading", children: t("orders.activity.header") }) }) }),
|
|
1382
|
-
/* @__PURE__ */ jsx8(OrderTimeline, { order })
|
|
1384
|
+
/* @__PURE__ */ jsx8(OrderTimeline, { order }),
|
|
1385
|
+
/* @__PURE__ */ jsx8(DisplayExtensionZone, { model: "order", zone: "activity", data: order })
|
|
1383
1386
|
] });
|
|
1384
1387
|
};
|
|
1385
1388
|
|
|
1386
1389
|
// src/pages/orders/order-detail/components/order-commission-section/order-commission-section.tsx
|
|
1387
1390
|
import { Container as Container6, Heading as Heading6, Text as Text7 } from "@medusajs/ui";
|
|
1391
|
+
import { DisplayExtensionZone as DisplayExtensionZone2 } from "@mercurjs/dashboard-shared";
|
|
1388
1392
|
import { useMemo as useMemo3 } from "react";
|
|
1389
1393
|
import { useTranslation as useTranslation9 } from "react-i18next";
|
|
1390
1394
|
import { jsx as jsx9, jsxs as jsxs9 } from "react/jsx-runtime";
|
|
@@ -1426,13 +1430,15 @@ var OrderCommissionSection = ({
|
|
|
1426
1430
|
/* @__PURE__ */ jsxs9("div", { className: "flex items-center justify-between px-6 py-4", children: [
|
|
1427
1431
|
/* @__PURE__ */ jsx9(Text7, { size: "small", weight: "plus", leading: "compact", children: t("orders.commission.total") }),
|
|
1428
1432
|
/* @__PURE__ */ jsx9(Text7, { size: "small", weight: "plus", leading: "compact", children: getLocaleAmount(total, order.currency_code) })
|
|
1429
|
-
] })
|
|
1433
|
+
] }),
|
|
1434
|
+
/* @__PURE__ */ jsx9(DisplayExtensionZone2, { model: "order", zone: "commission", data: order })
|
|
1430
1435
|
] });
|
|
1431
1436
|
};
|
|
1432
1437
|
|
|
1433
1438
|
// src/pages/orders/order-detail/components/order-customer-section/order-customer-section.tsx
|
|
1434
1439
|
import { ArrowPath as ArrowPath2, CurrencyDollar, Envelope, FlyingBox } from "@medusajs/icons";
|
|
1435
1440
|
import { Container as Container7, Heading as Heading7 } from "@medusajs/ui";
|
|
1441
|
+
import { DisplayExtensionZone as DisplayExtensionZone3 } from "@mercurjs/dashboard-shared";
|
|
1436
1442
|
import { useTranslation as useTranslation11 } from "react-i18next";
|
|
1437
1443
|
|
|
1438
1444
|
// src/components/common/customer-info/customer-info.tsx
|
|
@@ -1590,7 +1596,8 @@ var OrderCustomerSection = ({ order }) => {
|
|
|
1590
1596
|
/* @__PURE__ */ jsx11(CustomerInfo.ID, { data: order }),
|
|
1591
1597
|
/* @__PURE__ */ jsx11(CustomerInfo.Contact, { data: order }),
|
|
1592
1598
|
/* @__PURE__ */ jsx11(CustomerInfo.Company, { data: order }),
|
|
1593
|
-
/* @__PURE__ */ jsx11(CustomerInfo.Addresses, { data: order })
|
|
1599
|
+
/* @__PURE__ */ jsx11(CustomerInfo.Addresses, { data: order }),
|
|
1600
|
+
/* @__PURE__ */ jsx11(DisplayExtensionZone3, { model: "order", zone: "customer", data: order })
|
|
1594
1601
|
]
|
|
1595
1602
|
}
|
|
1596
1603
|
);
|
|
@@ -1895,7 +1902,15 @@ import {
|
|
|
1895
1902
|
usePrompt as usePrompt2
|
|
1896
1903
|
} from "@medusajs/ui";
|
|
1897
1904
|
import { useTranslation as useTranslation13 } from "react-i18next";
|
|
1905
|
+
import { DisplayExtensionZone as DisplayExtensionZone4, DisplayField } from "@mercurjs/dashboard-shared";
|
|
1898
1906
|
import { jsx as jsx13, jsxs as jsxs13 } from "react/jsx-runtime";
|
|
1907
|
+
var GENERAL_FIELD_IDS = [
|
|
1908
|
+
"display_id",
|
|
1909
|
+
"created_at",
|
|
1910
|
+
"status",
|
|
1911
|
+
"payment_status",
|
|
1912
|
+
"fulfillment_status"
|
|
1913
|
+
];
|
|
1899
1914
|
var OrderGeneralSection = ({ order }) => {
|
|
1900
1915
|
const { t } = useTranslation13();
|
|
1901
1916
|
const prompt = usePrompt2();
|
|
@@ -1930,23 +1945,23 @@ var OrderGeneralSection = ({ order }) => {
|
|
|
1930
1945
|
};
|
|
1931
1946
|
return /* @__PURE__ */ jsxs13(Container9, { className: "flex items-center justify-between px-6 py-4", "data-testid": "order-general-section", children: [
|
|
1932
1947
|
/* @__PURE__ */ jsxs13("div", { children: [
|
|
1933
|
-
/* @__PURE__ */ jsxs13("div", { className: "flex items-center gap-x-1", "data-testid": "order-general-section-id-container", children: [
|
|
1948
|
+
/* @__PURE__ */ jsx13(DisplayField, { model: "order", zone: "general", id: "display_id", data: order, children: /* @__PURE__ */ jsxs13("div", { className: "flex items-center gap-x-1", "data-testid": "order-general-section-id-container", children: [
|
|
1934
1949
|
/* @__PURE__ */ jsxs13(Heading9, { "data-testid": "order-general-section-id-heading", children: [
|
|
1935
1950
|
"#",
|
|
1936
1951
|
order.display_id
|
|
1937
1952
|
] }),
|
|
1938
1953
|
/* @__PURE__ */ jsx13(Copy4, { content: `#${order.display_id}`, className: "text-ui-fg-muted", "data-testid": "order-general-section-id-copy" })
|
|
1939
|
-
] }),
|
|
1940
|
-
/* @__PURE__ */ jsx13(Text10, { size: "small", className: "text-ui-fg-subtle", "data-testid": "order-general-section-date", children: t("orders.onDateFromSalesChannel", {
|
|
1954
|
+
] }) }),
|
|
1955
|
+
/* @__PURE__ */ jsx13(DisplayField, { model: "order", zone: "general", id: "created_at", data: order, children: /* @__PURE__ */ jsx13(Text10, { size: "small", className: "text-ui-fg-subtle", "data-testid": "order-general-section-date", children: t("orders.onDateFromSalesChannel", {
|
|
1941
1956
|
date: getFullDate({ date: order.created_at, includeTime: true }),
|
|
1942
1957
|
salesChannel: order.sales_channel?.name
|
|
1943
|
-
}) })
|
|
1958
|
+
}) }) })
|
|
1944
1959
|
] }),
|
|
1945
1960
|
/* @__PURE__ */ jsxs13("div", { className: "flex items-center gap-x-4", "data-testid": "order-general-section-badges-container", children: [
|
|
1946
1961
|
/* @__PURE__ */ jsxs13("div", { className: "flex items-center gap-x-1.5", "data-testid": "order-general-section-badges", children: [
|
|
1947
|
-
/* @__PURE__ */ jsx13(OrderBadge, { order }),
|
|
1948
|
-
/* @__PURE__ */ jsx13(PaymentBadge, { order }),
|
|
1949
|
-
/* @__PURE__ */ jsx13(FulfillmentBadge, { order })
|
|
1962
|
+
/* @__PURE__ */ jsx13(DisplayField, { model: "order", zone: "general", id: "status", data: order, children: /* @__PURE__ */ jsx13(OrderBadge, { order }) }),
|
|
1963
|
+
/* @__PURE__ */ jsx13(DisplayField, { model: "order", zone: "general", id: "payment_status", data: order, children: /* @__PURE__ */ jsx13(PaymentBadge, { order }) }),
|
|
1964
|
+
/* @__PURE__ */ jsx13(DisplayField, { model: "order", zone: "general", id: "fulfillment_status", data: order, children: /* @__PURE__ */ jsx13(FulfillmentBadge, { order }) })
|
|
1950
1965
|
] }),
|
|
1951
1966
|
/* @__PURE__ */ jsx13(
|
|
1952
1967
|
ActionMenu,
|
|
@@ -1967,7 +1982,16 @@ var OrderGeneralSection = ({ order }) => {
|
|
|
1967
1982
|
"data-testid": "order-general-section-action-menu"
|
|
1968
1983
|
}
|
|
1969
1984
|
)
|
|
1970
|
-
] })
|
|
1985
|
+
] }),
|
|
1986
|
+
/* @__PURE__ */ jsx13(
|
|
1987
|
+
DisplayExtensionZone4,
|
|
1988
|
+
{
|
|
1989
|
+
model: "order",
|
|
1990
|
+
zone: "general",
|
|
1991
|
+
data: order,
|
|
1992
|
+
builtInFieldIds: GENERAL_FIELD_IDS
|
|
1993
|
+
}
|
|
1994
|
+
)
|
|
1971
1995
|
] });
|
|
1972
1996
|
};
|
|
1973
1997
|
var FulfillmentBadge = ({ order }) => {
|
|
@@ -2035,6 +2059,7 @@ import {
|
|
|
2035
2059
|
Tooltip as Tooltip4,
|
|
2036
2060
|
usePrompt as usePrompt3
|
|
2037
2061
|
} from "@medusajs/ui";
|
|
2062
|
+
import { DisplayExtensionZone as DisplayExtensionZone5 } from "@mercurjs/dashboard-shared";
|
|
2038
2063
|
import { format as format2 } from "date-fns";
|
|
2039
2064
|
import { Trans, useTranslation as useTranslation15 } from "react-i18next";
|
|
2040
2065
|
import { jsx as jsx15, jsxs as jsxs15 } from "react/jsx-runtime";
|
|
@@ -2057,7 +2082,8 @@ var OrderPaymentSection = ({ order }) => {
|
|
|
2057
2082
|
currencyCode: order.currency_code
|
|
2058
2083
|
}
|
|
2059
2084
|
),
|
|
2060
|
-
/* @__PURE__ */ jsx15(Total, { order })
|
|
2085
|
+
/* @__PURE__ */ jsx15(Total, { order }),
|
|
2086
|
+
/* @__PURE__ */ jsx15(DisplayExtensionZone5, { model: "order", zone: "payment", data: order })
|
|
2061
2087
|
]
|
|
2062
2088
|
}
|
|
2063
2089
|
);
|
|
@@ -2458,6 +2484,7 @@ import {
|
|
|
2458
2484
|
Tooltip as Tooltip6,
|
|
2459
2485
|
usePrompt as usePrompt4
|
|
2460
2486
|
} from "@medusajs/ui";
|
|
2487
|
+
import { DisplayExtensionZone as DisplayExtensionZone6 } from "@mercurjs/dashboard-shared";
|
|
2461
2488
|
import { format as format3 } from "date-fns";
|
|
2462
2489
|
|
|
2463
2490
|
// src/lib/credit-line.ts
|
|
@@ -2682,7 +2709,8 @@ var OrderSummarySection = ({ order }) => {
|
|
|
2682
2709
|
)
|
|
2683
2710
|
]
|
|
2684
2711
|
}
|
|
2685
|
-
)
|
|
2712
|
+
),
|
|
2713
|
+
/* @__PURE__ */ jsx18(DisplayExtensionZone6, { model: "order", zone: "summary", data: order })
|
|
2686
2714
|
]
|
|
2687
2715
|
}
|
|
2688
2716
|
);
|
|
@@ -3557,6 +3585,7 @@ var Total2 = ({ order }) => {
|
|
|
3557
3585
|
|
|
3558
3586
|
// src/pages/orders/order-detail/components/order-remaining-orders-group-section/order-remaining-orders-group-section.tsx
|
|
3559
3587
|
import { Container as Container12, Heading as Heading12 } from "@medusajs/ui";
|
|
3588
|
+
import { DisplayExtensionZone as DisplayExtensionZone7 } from "@mercurjs/dashboard-shared";
|
|
3560
3589
|
import { createColumnHelper } from "@tanstack/react-table";
|
|
3561
3590
|
import { useMemo as useMemo5 } from "react";
|
|
3562
3591
|
import { useTranslation as useTranslation19 } from "react-i18next";
|
|
@@ -3617,6 +3646,14 @@ var OrderRemainingOrdersGroupSection = () => {
|
|
|
3617
3646
|
message: t("orders.group.noOtherOrders")
|
|
3618
3647
|
}
|
|
3619
3648
|
}
|
|
3649
|
+
),
|
|
3650
|
+
/* @__PURE__ */ jsx19(
|
|
3651
|
+
DisplayExtensionZone7,
|
|
3652
|
+
{
|
|
3653
|
+
model: "order",
|
|
3654
|
+
zone: "order-group",
|
|
3655
|
+
data: order_group
|
|
3656
|
+
}
|
|
3620
3657
|
)
|
|
3621
3658
|
]
|
|
3622
3659
|
}
|
|
@@ -3719,7 +3756,7 @@ var Root = ({ children }) => {
|
|
|
3719
3756
|
hasOutlet: true,
|
|
3720
3757
|
"data-testid": "order-detail-page",
|
|
3721
3758
|
children: [
|
|
3722
|
-
/* @__PURE__ */
|
|
3759
|
+
/* @__PURE__ */ jsx20(TwoColumnPage.Main, { "data-testid": "order-detail-main", children: /* @__PURE__ */ jsxs20(WidgetZone, { id: "orders.detail.main", data: order, children: [
|
|
3723
3760
|
/* @__PURE__ */ jsx20(OrderActiveEditSection, { order }),
|
|
3724
3761
|
/* @__PURE__ */ jsx20(ActiveOrderClaimSection, { orderPreview }),
|
|
3725
3762
|
/* @__PURE__ */ jsx20(ActiveOrderExchangeSection, { orderPreview }),
|
|
@@ -3729,12 +3766,12 @@ var Root = ({ children }) => {
|
|
|
3729
3766
|
/* @__PURE__ */ jsx20(OrderCommissionSection, { order }),
|
|
3730
3767
|
/* @__PURE__ */ jsx20(OrderPaymentSection, { order }),
|
|
3731
3768
|
/* @__PURE__ */ jsx20(OrderFulfillmentSection, { order })
|
|
3732
|
-
] }),
|
|
3733
|
-
/* @__PURE__ */
|
|
3769
|
+
] }) }),
|
|
3770
|
+
/* @__PURE__ */ jsx20(TwoColumnPage.Sidebar, { "data-testid": "order-detail-sidebar", children: /* @__PURE__ */ jsxs20(WidgetZone, { id: "orders.detail.side", data: order, children: [
|
|
3734
3771
|
/* @__PURE__ */ jsx20(OrderCustomerSection, { order }),
|
|
3735
3772
|
/* @__PURE__ */ jsx20(OrderActivitySection, { order }),
|
|
3736
3773
|
/* @__PURE__ */ jsx20(OrderRemainingOrdersGroupSection, {})
|
|
3737
|
-
] })
|
|
3774
|
+
] }) })
|
|
3738
3775
|
]
|
|
3739
3776
|
}
|
|
3740
3777
|
);
|
|
@@ -21,6 +21,7 @@ import {
|
|
|
21
21
|
import { useState } from "react";
|
|
22
22
|
import { useTranslation } from "react-i18next";
|
|
23
23
|
import { Link } from "react-router-dom";
|
|
24
|
+
import { DisplayExtensionZone } from "@mercurjs/dashboard-shared";
|
|
24
25
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
25
26
|
var ProductMediaSection = ({
|
|
26
27
|
product,
|
|
@@ -179,7 +180,8 @@ var ProductMediaSection = ({
|
|
|
179
180
|
"data-testid": "product-media-command-bar-delete"
|
|
180
181
|
}
|
|
181
182
|
)
|
|
182
|
-
] }) })
|
|
183
|
+
] }) }),
|
|
184
|
+
/* @__PURE__ */ jsx(DisplayExtensionZone, { model: "product", zone: "media", data: product })
|
|
183
185
|
] });
|
|
184
186
|
};
|
|
185
187
|
var getMedia = (product) => {
|
|
@@ -31,12 +31,14 @@ import {
|
|
|
31
31
|
// src/pages/promotions/promotion-detail/promotion-detail.tsx
|
|
32
32
|
import { Children } from "react";
|
|
33
33
|
import { useLoaderData, useParams as useParams4 } from "react-router-dom";
|
|
34
|
+
import { WidgetZone } from "@mercurjs/dashboard-shared";
|
|
34
35
|
|
|
35
36
|
// src/pages/promotions/promotion-detail/components/campaign-section/campaign-section.tsx
|
|
36
37
|
import { ArrowUpRightOnBox, PencilSquare } from "@medusajs/icons";
|
|
37
38
|
import { Container, Heading, Text } from "@medusajs/ui";
|
|
38
39
|
import { useTranslation } from "react-i18next";
|
|
39
40
|
import { useParams } from "react-router-dom";
|
|
41
|
+
import { DisplayExtensionZone } from "@mercurjs/dashboard-shared";
|
|
40
42
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
41
43
|
var CampaignDetailSection = ({
|
|
42
44
|
campaign
|
|
@@ -108,7 +110,8 @@ var CampaignSection = ({
|
|
|
108
110
|
buttonVariant: "transparentIconLeft",
|
|
109
111
|
dataTestId: "promotion-campaign-section-add-to-campaign-button"
|
|
110
112
|
}
|
|
111
|
-
) })
|
|
113
|
+
) }),
|
|
114
|
+
/* @__PURE__ */ jsx(DisplayExtensionZone, { model: "promotion", zone: "campaign", data: campaign })
|
|
112
115
|
] });
|
|
113
116
|
};
|
|
114
117
|
|
|
@@ -117,6 +120,7 @@ import { PencilSquare as PencilSquare2 } from "@medusajs/icons";
|
|
|
117
120
|
import { Badge as Badge2, Container as Container2, Heading as Heading2 } from "@medusajs/ui";
|
|
118
121
|
import { useTranslation as useTranslation3 } from "react-i18next";
|
|
119
122
|
import { useParams as useParams2 } from "react-router-dom";
|
|
123
|
+
import { DisplayExtensionZone as DisplayExtensionZone2 } from "@mercurjs/dashboard-shared";
|
|
120
124
|
|
|
121
125
|
// src/components/common/badge-list-summary/badge-list-summary.tsx
|
|
122
126
|
import { Badge, Tooltip, clx } from "@medusajs/ui";
|
|
@@ -287,6 +291,14 @@ var PromotionConditionsSection = ({
|
|
|
287
291
|
))
|
|
288
292
|
]
|
|
289
293
|
}
|
|
294
|
+
),
|
|
295
|
+
/* @__PURE__ */ jsx3(
|
|
296
|
+
DisplayExtensionZone2,
|
|
297
|
+
{
|
|
298
|
+
model: "promotion",
|
|
299
|
+
zone: `conditions-${ruleType}`,
|
|
300
|
+
data: rules
|
|
301
|
+
}
|
|
290
302
|
)
|
|
291
303
|
]
|
|
292
304
|
}
|
|
@@ -307,7 +319,18 @@ import {
|
|
|
307
319
|
import { useTranslation as useTranslation4 } from "react-i18next";
|
|
308
320
|
import { useNavigate } from "react-router-dom";
|
|
309
321
|
import { useParams as useParams3 } from "react-router-dom";
|
|
322
|
+
import { DisplayExtensionZone as DisplayExtensionZone3, DisplayField } from "@mercurjs/dashboard-shared";
|
|
310
323
|
import { jsx as jsx4, jsxs as jsxs4 } from "react/jsx-runtime";
|
|
324
|
+
var GENERAL_FIELD_IDS = [
|
|
325
|
+
"code",
|
|
326
|
+
"status",
|
|
327
|
+
"is_automatic",
|
|
328
|
+
"code_badge",
|
|
329
|
+
"type",
|
|
330
|
+
"value",
|
|
331
|
+
"allocation",
|
|
332
|
+
"is_tax_inclusive"
|
|
333
|
+
];
|
|
311
334
|
function getDisplayValue(promotion) {
|
|
312
335
|
const value = promotion.application_method?.value;
|
|
313
336
|
if (!value) {
|
|
@@ -363,9 +386,9 @@ var PromotionGeneralSection = ({
|
|
|
363
386
|
const displayValue = getDisplayValue(promotion);
|
|
364
387
|
return /* @__PURE__ */ jsxs4(Container3, { className: "divide-y p-0", "data-testid": "promotion-general-section-container", children: [
|
|
365
388
|
/* @__PURE__ */ jsxs4("div", { className: "flex items-center justify-between px-6 py-4", "data-testid": "promotion-general-section-header", children: [
|
|
366
|
-
/* @__PURE__ */ jsx4("div", { className: "flex flex-col", children: /* @__PURE__ */ jsx4(Heading3, { "data-testid": "promotion-general-section-code", children: promotion.code }) }),
|
|
389
|
+
/* @__PURE__ */ jsx4("div", { className: "flex flex-col", children: /* @__PURE__ */ jsx4(DisplayField, { model: "promotion", zone: "general", id: "code", data: promotion, children: /* @__PURE__ */ jsx4(Heading3, { "data-testid": "promotion-general-section-code", children: promotion.code }) }) }),
|
|
367
390
|
/* @__PURE__ */ jsxs4("div", { className: "flex items-center gap-x-2", children: [
|
|
368
|
-
/* @__PURE__ */ jsx4(StatusBadge, { color, "data-testid": "promotion-general-section-status", children: text }),
|
|
391
|
+
/* @__PURE__ */ jsx4(DisplayField, { model: "promotion", zone: "general", id: "status", data: promotion, children: /* @__PURE__ */ jsx4(StatusBadge, { color, "data-testid": "promotion-general-section-status", children: text }) }),
|
|
369
392
|
/* @__PURE__ */ jsx4(
|
|
370
393
|
ActionMenu,
|
|
371
394
|
{
|
|
@@ -394,11 +417,11 @@ var PromotionGeneralSection = ({
|
|
|
394
417
|
)
|
|
395
418
|
] })
|
|
396
419
|
] }),
|
|
397
|
-
/* @__PURE__ */ jsxs4("div", { className: "text-ui-fg-subtle grid grid-cols-2 items-start px-6 py-4", "data-testid": "promotion-general-section-method", children: [
|
|
420
|
+
/* @__PURE__ */ jsx4(DisplayField, { model: "promotion", zone: "general", id: "is_automatic", data: promotion, children: /* @__PURE__ */ jsxs4("div", { className: "text-ui-fg-subtle grid grid-cols-2 items-start px-6 py-4", "data-testid": "promotion-general-section-method", children: [
|
|
398
421
|
/* @__PURE__ */ jsx4(Text2, { size: "small", weight: "plus", leading: "compact", "data-testid": "promotion-general-section-method-label", children: t("promotions.fields.method") }),
|
|
399
422
|
/* @__PURE__ */ jsx4(Text2, { size: "small", leading: "compact", className: "text-pretty", "data-testid": "promotion-general-section-method-value", children: promotion.is_automatic ? t("promotions.form.method.automatic.title") : t("promotions.form.method.code.title") })
|
|
400
|
-
] }),
|
|
401
|
-
/* @__PURE__ */ jsxs4("div", { className: "text-ui-fg-subtle grid grid-cols-2 items-center px-6 py-4", "data-testid": "promotion-general-section-code-field", children: [
|
|
423
|
+
] }) }),
|
|
424
|
+
/* @__PURE__ */ jsx4(DisplayField, { model: "promotion", zone: "general", id: "code_badge", data: promotion, children: /* @__PURE__ */ jsxs4("div", { className: "text-ui-fg-subtle grid grid-cols-2 items-center px-6 py-4", "data-testid": "promotion-general-section-code-field", children: [
|
|
402
425
|
/* @__PURE__ */ jsx4(Text2, { size: "small", weight: "plus", leading: "compact", "data-testid": "promotion-general-section-code-label", children: t("fields.code") }),
|
|
403
426
|
/* @__PURE__ */ jsx4(
|
|
404
427
|
Copy,
|
|
@@ -419,26 +442,35 @@ var PromotionGeneralSection = ({
|
|
|
419
442
|
)
|
|
420
443
|
}
|
|
421
444
|
)
|
|
422
|
-
] }),
|
|
423
|
-
/* @__PURE__ */ jsxs4("div", { className: "text-ui-fg-subtle grid grid-cols-2 items-start px-6 py-4", "data-testid": "promotion-general-section-type", children: [
|
|
445
|
+
] }) }),
|
|
446
|
+
/* @__PURE__ */ jsx4(DisplayField, { model: "promotion", zone: "general", id: "type", data: promotion, children: /* @__PURE__ */ jsxs4("div", { className: "text-ui-fg-subtle grid grid-cols-2 items-start px-6 py-4", "data-testid": "promotion-general-section-type", children: [
|
|
424
447
|
/* @__PURE__ */ jsx4(Text2, { size: "small", weight: "plus", leading: "compact", "data-testid": "promotion-general-section-type-label", children: t("promotions.fields.type") }),
|
|
425
448
|
/* @__PURE__ */ jsx4(Text2, { size: "small", leading: "compact", className: "text-pretty capitalize", "data-testid": "promotion-general-section-type-value", children: promotion.type })
|
|
426
|
-
] }),
|
|
427
|
-
/* @__PURE__ */ jsxs4("div", { className: "text-ui-fg-subtle grid grid-cols-2 items-start px-6 py-4", "data-testid": "promotion-general-section-value", children: [
|
|
449
|
+
] }) }),
|
|
450
|
+
/* @__PURE__ */ jsx4(DisplayField, { model: "promotion", zone: "general", id: "value", data: promotion, children: /* @__PURE__ */ jsxs4("div", { className: "text-ui-fg-subtle grid grid-cols-2 items-start px-6 py-4", "data-testid": "promotion-general-section-value", children: [
|
|
428
451
|
/* @__PURE__ */ jsx4(Text2, { size: "small", weight: "plus", leading: "compact", "data-testid": "promotion-general-section-value-label", children: t("promotions.fields.value") }),
|
|
429
452
|
/* @__PURE__ */ jsxs4("div", { className: "flex items-center gap-x-2", "data-testid": "promotion-general-section-value-content", children: [
|
|
430
453
|
/* @__PURE__ */ jsx4(Text2, { className: "inline", size: "small", leading: "compact", "data-testid": "promotion-general-section-value-text", children: displayValue || "-" }),
|
|
431
454
|
promotion?.application_method?.type === "fixed" && /* @__PURE__ */ jsx4(Badge3, { size: "2xsmall", rounded: "full", "data-testid": "promotion-general-section-value-currency", children: promotion?.application_method?.currency_code?.toUpperCase() })
|
|
432
455
|
] })
|
|
433
|
-
] }),
|
|
434
|
-
/* @__PURE__ */ jsxs4("div", { className: "text-ui-fg-subtle grid grid-cols-2 items-start px-6 py-4", "data-testid": "promotion-general-section-allocation", children: [
|
|
456
|
+
] }) }),
|
|
457
|
+
/* @__PURE__ */ jsx4(DisplayField, { model: "promotion", zone: "general", id: "allocation", data: promotion, children: /* @__PURE__ */ jsxs4("div", { className: "text-ui-fg-subtle grid grid-cols-2 items-start px-6 py-4", "data-testid": "promotion-general-section-allocation", children: [
|
|
435
458
|
/* @__PURE__ */ jsx4(Text2, { size: "small", weight: "plus", leading: "compact", "data-testid": "promotion-general-section-allocation-label", children: t("promotions.fields.allocation") }),
|
|
436
459
|
/* @__PURE__ */ jsx4(Text2, { size: "small", leading: "compact", className: "text-pretty capitalize", "data-testid": "promotion-general-section-allocation-value", children: promotion.application_method?.allocation })
|
|
437
|
-
] }),
|
|
438
|
-
promotion.application_method?.type === "fixed" && /* @__PURE__ */ jsxs4("div", { className: "text-ui-fg-subtle grid grid-cols-2 items-start px-6 py-4", "data-testid": "promotion-general-section-tax-inclusive", children: [
|
|
460
|
+
] }) }),
|
|
461
|
+
promotion.application_method?.type === "fixed" && /* @__PURE__ */ jsx4(DisplayField, { model: "promotion", zone: "general", id: "is_tax_inclusive", data: promotion, children: /* @__PURE__ */ jsxs4("div", { className: "text-ui-fg-subtle grid grid-cols-2 items-start px-6 py-4", "data-testid": "promotion-general-section-tax-inclusive", children: [
|
|
439
462
|
/* @__PURE__ */ jsx4(Text2, { size: "small", weight: "plus", leading: "compact", "data-testid": "promotion-general-section-tax-inclusive-label", children: t("promotions.fields.taxInclusive") }),
|
|
440
463
|
/* @__PURE__ */ jsx4("div", { className: "flex items-center gap-x-2", "data-testid": "promotion-general-section-tax-inclusive-value", children: /* @__PURE__ */ jsx4(Text2, { className: "inline", size: "small", leading: "compact", children: promotion.is_tax_inclusive ? t("fields.true") : t("fields.false") }) })
|
|
441
|
-
] })
|
|
464
|
+
] }) }),
|
|
465
|
+
/* @__PURE__ */ jsx4(
|
|
466
|
+
DisplayExtensionZone3,
|
|
467
|
+
{
|
|
468
|
+
model: "promotion",
|
|
469
|
+
zone: "general",
|
|
470
|
+
data: promotion,
|
|
471
|
+
builtInFieldIds: GENERAL_FIELD_IDS
|
|
472
|
+
}
|
|
473
|
+
)
|
|
442
474
|
] });
|
|
443
475
|
};
|
|
444
476
|
|
|
@@ -459,7 +491,7 @@ var Root = ({ children }) => {
|
|
|
459
491
|
return /* @__PURE__ */ jsx5(TwoColumnPageSkeleton, { mainSections: 3, sidebarSections: 1, showJSON: true });
|
|
460
492
|
}
|
|
461
493
|
return Children.count(children) > 0 ? /* @__PURE__ */ jsx5(TwoColumnPage, { data: promotion, hasOutlet: true, showJSON: true, "data-testid": "promotion-detail-page", children }) : /* @__PURE__ */ jsxs5(TwoColumnPage, { data: promotion, hasOutlet: true, showJSON: true, "data-testid": "promotion-detail-page", children: [
|
|
462
|
-
/* @__PURE__ */
|
|
494
|
+
/* @__PURE__ */ jsx5(TwoColumnPage.Main, { children: /* @__PURE__ */ jsxs5(WidgetZone, { id: "promotions.detail.main", data: promotion, children: [
|
|
463
495
|
/* @__PURE__ */ jsx5(PromotionGeneralSection, { promotion }),
|
|
464
496
|
/* @__PURE__ */ jsx5(
|
|
465
497
|
PromotionConditionsSection,
|
|
@@ -484,8 +516,8 @@ var Root = ({ children }) => {
|
|
|
484
516
|
applicationMethodTargetType: "items"
|
|
485
517
|
}
|
|
486
518
|
)
|
|
487
|
-
] }),
|
|
488
|
-
/* @__PURE__ */ jsx5(TwoColumnPage.Sidebar, { children: /* @__PURE__ */ jsx5(CampaignSection, { campaign: promotion.campaign }) })
|
|
519
|
+
] }) }),
|
|
520
|
+
/* @__PURE__ */ jsx5(TwoColumnPage.Sidebar, { children: /* @__PURE__ */ jsx5(WidgetZone, { id: "promotions.detail.side", data: promotion, children: /* @__PURE__ */ jsx5(CampaignSection, { campaign: promotion.campaign }) }) })
|
|
489
521
|
] });
|
|
490
522
|
};
|
|
491
523
|
var PromotionDetailPage = Object.assign(Root, {
|
|
@@ -27,10 +27,12 @@ import {
|
|
|
27
27
|
|
|
28
28
|
// src/pages/reservations/reservation-list/reservation-list.tsx
|
|
29
29
|
import { Children as Children2 } from "react";
|
|
30
|
+
import { WidgetZone } from "@mercurjs/dashboard-shared";
|
|
30
31
|
|
|
31
32
|
// src/pages/reservations/reservation-list/components/reservation-list-table/reservation-list-table.tsx
|
|
32
33
|
import { Button, Container, Heading, Text } from "@medusajs/ui";
|
|
33
|
-
import {
|
|
34
|
+
import { useExtendableTable } from "@mercurjs/dashboard-shared";
|
|
35
|
+
import { Children, useMemo as useMemo2 } from "react";
|
|
34
36
|
import { useTranslation as useTranslation4 } from "react-i18next";
|
|
35
37
|
import { Link } from "react-router-dom";
|
|
36
38
|
|
|
@@ -257,8 +259,12 @@ var ReservationListDataTable = () => {
|
|
|
257
259
|
const { reservations, count, isPending, isError, error } = useReservationItems({
|
|
258
260
|
...searchParams
|
|
259
261
|
});
|
|
260
|
-
const
|
|
261
|
-
const columns =
|
|
262
|
+
const baseFilters = useReservationTableFilters();
|
|
263
|
+
const { columns, filters: extFilters } = useColumns();
|
|
264
|
+
const filters = useMemo2(
|
|
265
|
+
() => [...baseFilters, ...extFilters],
|
|
266
|
+
[baseFilters, extFilters]
|
|
267
|
+
);
|
|
262
268
|
const { table } = useDataTable({
|
|
263
269
|
data: reservations || [],
|
|
264
270
|
columns,
|
|
@@ -286,6 +292,27 @@ var ReservationListDataTable = () => {
|
|
|
286
292
|
}
|
|
287
293
|
);
|
|
288
294
|
};
|
|
295
|
+
var useColumns = () => {
|
|
296
|
+
const base = useReservationTableColumns();
|
|
297
|
+
const actionsColumn = base.filter(
|
|
298
|
+
(c) => c.id === "actions"
|
|
299
|
+
);
|
|
300
|
+
const dataColumns = base.filter(
|
|
301
|
+
(c) => c.id !== "actions"
|
|
302
|
+
);
|
|
303
|
+
const { columns: extended, filters } = useExtendableTable({
|
|
304
|
+
model: "reservation",
|
|
305
|
+
columns: dataColumns
|
|
306
|
+
});
|
|
307
|
+
const columns = useMemo2(
|
|
308
|
+
() => [
|
|
309
|
+
...extended,
|
|
310
|
+
...actionsColumn
|
|
311
|
+
],
|
|
312
|
+
[extended, actionsColumn]
|
|
313
|
+
);
|
|
314
|
+
return { columns, filters };
|
|
315
|
+
};
|
|
289
316
|
var ReservationListTable = ({ children }) => {
|
|
290
317
|
return /* @__PURE__ */ jsx3(Container, { className: "divide-y p-0", children: Children.count(children) > 0 ? children : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
291
318
|
/* @__PURE__ */ jsx3(ReservationListHeader, {}),
|
|
@@ -296,7 +323,7 @@ var ReservationListTable = ({ children }) => {
|
|
|
296
323
|
// src/pages/reservations/reservation-list/reservation-list.tsx
|
|
297
324
|
import { jsx as jsx4 } from "react/jsx-runtime";
|
|
298
325
|
var Root = ({ children }) => {
|
|
299
|
-
return /* @__PURE__ */ jsx4(SingleColumnPage, { children: Children2.count(children) > 0 ? children : /* @__PURE__ */ jsx4(ReservationListTable, {}) });
|
|
326
|
+
return /* @__PURE__ */ jsx4(SingleColumnPage, { children: Children2.count(children) > 0 ? children : /* @__PURE__ */ jsx4(WidgetZone, { id: "reservation.list", children: /* @__PURE__ */ jsx4(ReservationListTable, {}) }) });
|
|
300
327
|
};
|
|
301
328
|
var ReservationListPage = Object.assign(Root, {
|
|
302
329
|
Table: ReservationListTable,
|