@flowselections/floriday-klanten-module 1.0.49 → 1.0.51
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-lib/components/CustomerAvatar.js +1 -1
- package/dist-lib/components/klanten/BewerkKlant.js +1 -1
- package/dist-lib/components/klanten/BewerkKlantRoute.js +1 -1
- package/dist-lib/components/klanten/BulkStickerUploadDialog.js +1 -1
- package/dist-lib/components/klanten/CustomerAnalyticsTab.js +2 -2
- package/dist-lib/components/klanten/CustomerAssortmentTab.js +4 -4
- package/dist-lib/components/klanten/DeliveryLocationsTab.js +6 -6
- package/dist-lib/components/klanten/DiscountsTab.js +3 -3
- package/dist-lib/components/klanten/ExternalCacheBanner.d.ts +1 -1
- package/dist-lib/components/klanten/ExternalCacheBanner.d.ts.map +1 -1
- package/dist-lib/components/klanten/ExternalCacheBanner.js +2 -5
- package/dist-lib/components/klanten/FloridayNetworkStatus.d.ts.map +1 -1
- package/dist-lib/components/klanten/FloridayNetworkStatus.js +5 -3
- package/dist-lib/components/klanten/GroupedKlantDetailRoute.js +1 -1
- package/dist-lib/components/klanten/ImportKlanten.js +1 -1
- package/dist-lib/components/klanten/KlantBewerkenDialog.js +2 -2
- package/dist-lib/components/klanten/KlantDetail.d.ts.map +1 -1
- package/dist-lib/components/klanten/KlantDetail.js +15 -3
- package/dist-lib/components/klanten/KlantDetailLayout.d.ts +1 -1
- package/dist-lib/components/klanten/KlantDetailLayout.d.ts.map +1 -1
- package/dist-lib/components/klanten/KlantDetailLayout.js +7 -5
- package/dist-lib/components/klanten/KlantDetailRoute.js +1 -1
- package/dist-lib/components/klanten/KlantenOverzicht.js +18 -18
- package/dist-lib/components/klanten/LocalDiscountFormDialog.js +1 -1
- package/dist-lib/components/klanten/LocalDiscountsTab.js +2 -2
- package/dist-lib/components/klanten/NetwerkPagina.js +3 -3
- package/dist-lib/components/klanten/NieuweKlant.js +1 -1
- package/dist-lib/components/klanten/OvernemenTwinfieldKlant.js +1 -1
- package/dist-lib/components/klanten/OvernemenTwinfieldKlantRoute.js +1 -1
- package/dist-lib/components/klanten/RouteError.js +1 -1
- package/dist-lib/components/klanten/SyncStatusChip.d.ts.map +1 -1
- package/dist-lib/components/klanten/SyncStatusChip.js +5 -4
- package/dist-lib/components/klanten/pricegroups/CustomerPickerDialog.js +6 -6
- package/dist-lib/components/klanten/pricegroups/CustomerPriceGroupSelect.js +3 -3
- package/dist-lib/components/klanten/pricegroups/PriceGroupEditRoute.js +1 -1
- package/dist-lib/components/klanten/pricegroups/PriceGroupFormPage.js +13 -13
- package/dist-lib/components/klanten/pricegroups/PriceGroupNewRoute.js +1 -1
- package/dist-lib/components/klanten/pricegroups/PriceGroupsPage.js +4 -4
- package/dist-lib/components/klanten/pricegroups/PriceGroupsRoute.js +1 -1
- package/dist-lib/components/klanten/pricegroups/ProductPickerDialog.d.ts +1 -1
- package/dist-lib/components/klanten/pricegroups/UnknownFloridayMembers.d.ts +1 -1
- package/dist-lib/components/klanten/pricegroups/UnknownFloridayMembers.js +4 -4
- package/dist-lib/components/klanten/useCustomerDefaults.d.ts +1 -1
- package/dist-lib/index.d.ts +34 -34
- package/dist-lib/index.js +35 -35
- package/dist-lib/integrations/supabase/auth-attacher.js +1 -1
- package/dist-lib/integrations/supabase/auth-middleware.d.ts +1 -1
- package/dist-lib/integrations/supabase/client.d.ts +1 -1
- package/dist-lib/integrations/supabase/client.server.d.ts +1 -1
- package/dist-lib/integrations/supabase/types.d.ts +450 -0
- package/dist-lib/integrations/supabase/types.d.ts.map +1 -1
- package/dist-lib/lib/accounting/exact/client.server.d.ts +1 -1
- package/dist-lib/lib/accounting/exact/client.server.js +2 -2
- package/dist-lib/lib/accounting/exact/sync.server.d.ts +1 -1
- package/dist-lib/lib/accounting/exact/sync.server.js +3 -3
- package/dist-lib/lib/accounting/floriday/sync.server.d.ts +1 -1
- package/dist-lib/lib/accounting/floriday/sync.server.js +1 -1
- package/dist-lib/lib/accounting/registry.server.d.ts +1 -1
- package/dist-lib/lib/accounting/registry.server.js +2 -2
- package/dist-lib/lib/accounting/twinfield/client.server.js +2 -2
- package/dist-lib/lib/accounting/twinfield/field-coverage.test.js +6 -6
- package/dist-lib/lib/accounting/twinfield/mapping.js +3 -3
- package/dist-lib/lib/accounting/twinfield/rmw-push.server.d.ts +2 -2
- package/dist-lib/lib/accounting/twinfield/rmw-push.server.js +4 -4
- package/dist-lib/lib/accounting/twinfield/rmw.server.d.ts +1 -1
- package/dist-lib/lib/accounting/twinfield/rmw.server.js +2 -2
- package/dist-lib/lib/accounting/twinfield/sandbox-rmw.server.d.ts +6 -6
- package/dist-lib/lib/accounting/twinfield/sandbox-rmw.server.js +12 -12
- package/dist-lib/lib/accounting/twinfield/sandbox.server.js +3 -3
- package/dist-lib/lib/accounting/twinfield/sync.server.js +4 -4
- package/dist-lib/lib/accounting/twinfield/worker.functions.d.ts +7 -7
- package/dist-lib/lib/accounting/twinfield/worker.functions.js +6 -6
- package/dist-lib/lib/accounting/twinfield/worker.server.js +8 -8
- package/dist-lib/lib/accounting.functions.d.ts +4 -4
- package/dist-lib/lib/accounting.functions.js +2 -2
- package/dist-lib/lib/countries.test.js +3 -3
- package/dist-lib/lib/customer-analytics.functions.d.ts +1 -1
- package/dist-lib/lib/customer-analytics.functions.js +1 -1
- package/dist-lib/lib/customer-assortment.functions.d.ts +1 -1
- package/dist-lib/lib/customer-assortment.functions.js +3 -3
- package/dist-lib/lib/customer-defaults.test.js +3 -3
- package/dist-lib/lib/customer-insert.d.ts +1 -1
- package/dist-lib/lib/customer-insert.js +2 -2
- package/dist-lib/lib/customer-notes.functions.d.ts +2 -2
- package/dist-lib/lib/customer-notes.functions.js +1 -1
- package/dist-lib/lib/customer-orders.functions.d.ts +1 -1
- package/dist-lib/lib/customer-orders.functions.js +1 -1
- package/dist-lib/lib/customer-revenue.functions.d.ts +1 -1
- package/dist-lib/lib/customer-revenue.functions.js +2 -2
- package/dist-lib/lib/customer-schemas.js +1 -1
- package/dist-lib/lib/customer-schemas.test.js +1 -1
- package/dist-lib/lib/customer-stickers.functions.d.ts +9 -9
- package/dist-lib/lib/customer-stickers.functions.js +2 -2
- package/dist-lib/lib/customers.functions.d.ts +29 -29
- package/dist-lib/lib/customers.functions.js +11 -11
- package/dist-lib/lib/delivery-locations.functions.d.ts +7 -7
- package/dist-lib/lib/delivery-locations.functions.js +2 -2
- package/dist-lib/lib/external-customers.functions.d.ts +4 -4
- package/dist-lib/lib/external-customers.functions.js +2 -2
- package/dist-lib/lib/floriday-app-url.functions.d.ts +1 -1
- package/dist-lib/lib/floriday-app-url.functions.js +2 -2
- package/dist-lib/lib/floriday-assortment.functions.d.ts +1 -1
- package/dist-lib/lib/floriday-assortment.functions.js +2 -2
- package/dist-lib/lib/floriday-discounts.functions.d.ts +2 -2
- package/dist-lib/lib/floriday-discounts.functions.js +2 -2
- package/dist-lib/lib/floriday-network-status.functions.d.ts +3 -1
- package/dist-lib/lib/floriday-network-status.functions.d.ts.map +1 -1
- package/dist-lib/lib/floriday-network-status.functions.js +39 -18
- package/dist-lib/lib/floriday-price-import.functions.d.ts +2 -2
- package/dist-lib/lib/floriday-price-import.functions.js +2 -2
- package/dist-lib/lib/floriday-sticker-import.functions.d.ts +1 -1
- package/dist-lib/lib/floriday-sticker-import.functions.js +1 -1
- package/dist-lib/lib/floriday-trade-items.functions.d.ts +1 -1
- package/dist-lib/lib/floriday-trade-items.functions.js +1 -1
- package/dist-lib/lib/floriday-trade-settings.functions.d.ts +1 -1
- package/dist-lib/lib/floriday-trade-settings.functions.js +1 -1
- package/dist-lib/lib/friendly-twinfield-error.d.ts +8 -0
- package/dist-lib/lib/friendly-twinfield-error.d.ts.map +1 -0
- package/dist-lib/lib/friendly-twinfield-error.js +16 -0
- package/dist-lib/lib/local-discounts.functions.d.ts +7 -7
- package/dist-lib/lib/local-discounts.functions.js +1 -1
- package/dist-lib/lib/logistics-events.functions.d.ts +1 -1
- package/dist-lib/lib/logistics-events.functions.js +1 -1
- package/dist-lib/lib/logistics-strategy.functions.d.ts +4 -4
- package/dist-lib/lib/logistics-strategy.functions.js +1 -1
- package/dist-lib/lib/overdue-invoices.functions.d.ts +1 -1
- package/dist-lib/lib/overdue-invoices.functions.js +2 -2
- package/dist-lib/lib/price-groups-local.functions.d.ts +15 -15
- package/dist-lib/lib/price-groups-local.functions.js +1 -1
- package/dist-lib/lib/price-groups.functions.d.ts +1 -1
- package/dist-lib/lib/price-groups.functions.js +1 -1
- package/dist-lib/lib/twinfield-adopt.functions.d.ts +5 -5
- package/dist-lib/lib/twinfield-adopt.functions.js +7 -7
- package/dist-lib/lib/twinfield-customer-defaults.functions.d.ts +2 -2
- package/dist-lib/lib/twinfield-customer-defaults.functions.js +2 -2
- package/dist-lib/lib/twinfield-customer-defaults.server.js +1 -1
- package/dist-lib/lib/twinfield-ledger.functions.d.ts +2 -2
- package/dist-lib/lib/twinfield-ledger.functions.js +2 -2
- package/dist-lib/lib/twinfield-ledger.server.js +2 -2
- package/dist-lib/lib/twinfield-required-fields.js +1 -1
- package/package.json +2 -2
|
@@ -4,12 +4,12 @@ import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query";
|
|
|
4
4
|
import { useServerFn } from "@tanstack/react-start";
|
|
5
5
|
import { Dialog, DialogContent, DialogHeader, DialogTitle, DialogFooter, Button, Input, Checkbox, Badge, } from "@flowselections/core";
|
|
6
6
|
import { Search } from "lucide-react";
|
|
7
|
-
import { listExternalCustomers } from "../../../lib/external-customers.functions";
|
|
8
|
-
import { setPriceGroupMembers, getCustomerPriceGroup, listUnknownFloridayMembers, } from "../../../lib/price-groups-local.functions";
|
|
9
|
-
import { decodeDeep } from "../../../lib/decode-html";
|
|
10
|
-
import { countryNameToFlag } from "../../../lib/countries";
|
|
11
|
-
import { formatDateTime } from "../../../lib/format-date";
|
|
12
|
-
import { UnknownFloridayMembers } from "./UnknownFloridayMembers";
|
|
7
|
+
import { listExternalCustomers } from "../../../lib/external-customers.functions.js";
|
|
8
|
+
import { setPriceGroupMembers, getCustomerPriceGroup, listUnknownFloridayMembers, } from "../../../lib/price-groups-local.functions.js";
|
|
9
|
+
import { decodeDeep } from "../../../lib/decode-html.js";
|
|
10
|
+
import { countryNameToFlag } from "../../../lib/countries.js";
|
|
11
|
+
import { formatDateTime } from "../../../lib/format-date.js";
|
|
12
|
+
import { UnknownFloridayMembers } from "./UnknownFloridayMembers.js";
|
|
13
13
|
export function CustomerPickerDialog({ priceGroupId, open, onOpenChange, value, onChange, }) {
|
|
14
14
|
const qc = useQueryClient();
|
|
15
15
|
const listCustomers = useServerFn(listExternalCustomers);
|
|
@@ -3,9 +3,9 @@ import { useMemo, useState } from "react";
|
|
|
3
3
|
import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query";
|
|
4
4
|
import { useServerFn } from "@tanstack/react-start";
|
|
5
5
|
import { toast } from "@flowselections/core";
|
|
6
|
-
import { SearchableSelect } from "../SearchableSelect";
|
|
7
|
-
import { listCustomerPriceGroups, getPriceGroupsForCustomer, setPriceGroupForCustomer, } from "../../../lib/price-groups-local.functions";
|
|
8
|
-
import { friendlyError } from "../../../lib/errors";
|
|
6
|
+
import { SearchableSelect } from "../SearchableSelect.js";
|
|
7
|
+
import { listCustomerPriceGroups, getPriceGroupsForCustomer, setPriceGroupForCustomer, } from "../../../lib/price-groups-local.functions.js";
|
|
8
|
+
import { friendlyError } from "../../../lib/errors.js";
|
|
9
9
|
const NONE = "__none__";
|
|
10
10
|
export function CustomerPriceGroupSelect({ customerKey }) {
|
|
11
11
|
const qc = useQueryClient();
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { useParams } from "@tanstack/react-router";
|
|
3
|
-
import { PriceGroupFormPage } from "./PriceGroupFormPage";
|
|
3
|
+
import { PriceGroupFormPage } from "./PriceGroupFormPage.js";
|
|
4
4
|
export function PriceGroupEditRoute({ id: propId } = {}) {
|
|
5
5
|
const params = useParams({ strict: false });
|
|
6
6
|
const id = propId ?? ("id" in params ? params.id : undefined);
|
|
@@ -5,18 +5,18 @@ import { useServerFn } from "@tanstack/react-start";
|
|
|
5
5
|
import { useNavigate } from "@tanstack/react-router";
|
|
6
6
|
import { Button, Input, Label, Separator, Card, CardContent, Select, SelectContent, SelectItem, SelectTrigger, SelectValue, Checkbox, } from "@flowselections/core";
|
|
7
7
|
import { ArrowRight, Check, ChevronDown, PencilLine, Calculator, Users, Globe2, Circle, CheckCircle2, Info, ChevronLeft, ChevronRight, ImageIcon } from "lucide-react";
|
|
8
|
-
import { BackLink } from "../BackLink";
|
|
9
|
-
import { createCustomerPriceGroup, updateCustomerPriceGroup, getCustomerPriceGroup, setPriceGroupMembers, } from "../../../lib/price-groups-local.functions";
|
|
10
|
-
import { computePrice } from "../../../lib/pricing";
|
|
11
|
-
import { formatEur } from "../../../lib/format-currency";
|
|
12
|
-
import { listTradeItemsForPreview } from "../../../lib/floriday-trade-items.functions";
|
|
13
|
-
import { ProductPickerDialog } from "./ProductPickerDialog";
|
|
14
|
-
import { PriceGroupItemPrices } from "./PriceGroupItemPrices";
|
|
15
|
-
import { CustomerPickerDialog } from "./CustomerPickerDialog";
|
|
8
|
+
import { BackLink } from "../BackLink.js";
|
|
9
|
+
import { createCustomerPriceGroup, updateCustomerPriceGroup, getCustomerPriceGroup, setPriceGroupMembers, } from "../../../lib/price-groups-local.functions.js";
|
|
10
|
+
import { computePrice } from "../../../lib/pricing.js";
|
|
11
|
+
import { formatEur } from "../../../lib/format-currency.js";
|
|
12
|
+
import { listTradeItemsForPreview } from "../../../lib/floriday-trade-items.functions.js";
|
|
13
|
+
import { ProductPickerDialog } from "./ProductPickerDialog.js";
|
|
14
|
+
import { PriceGroupItemPrices } from "./PriceGroupItemPrices.js";
|
|
15
|
+
import { CustomerPickerDialog } from "./CustomerPickerDialog.js";
|
|
16
16
|
import { UserPlus, Users2 } from "lucide-react";
|
|
17
|
-
import { listExternalCustomers } from "../../../lib/external-customers.functions";
|
|
18
|
-
import { decodeDeep } from "../../../lib/decode-html";
|
|
19
|
-
import { countryNameToFlag } from "../../../lib/countries";
|
|
17
|
+
import { listExternalCustomers } from "../../../lib/external-customers.functions.js";
|
|
18
|
+
import { decodeDeep } from "../../../lib/decode-html.js";
|
|
19
|
+
import { countryNameToFlag } from "../../../lib/countries.js";
|
|
20
20
|
import { Badge } from "@flowselections/core";
|
|
21
21
|
import { toast } from "sonner";
|
|
22
22
|
const emptyInput = {
|
|
@@ -257,7 +257,7 @@ export function PriceGroupFormPage({ editingId }) {
|
|
|
257
257
|
"De ingestelde transport- en afleverkosten in de levervoorwaarden worden in rekening gebracht",
|
|
258
258
|
] }))] }), _jsxs("div", { className: "pt-2", children: [_jsx("div", { className: "text-sm text-muted-foreground mb-2", children: "Diensten" }), _jsx(Separator, { className: "mb-3" }), _jsxs("label", { className: "flex items-center gap-2 cursor-pointer select-none", children: [_jsx(Checkbox, { checked: form.include_stickers, onCheckedChange: (v) => patch({ include_stickers: v === true }) }), _jsx("span", { className: "text-sm font-medium", children: "Inclusief stickeren" })] })] }), _jsxs("div", { className: "pt-2", children: [_jsx("div", { className: "text-sm text-muted-foreground mb-2", children: "Afname" }), _jsx(Separator, { className: "mb-3" }), _jsxs("div", { className: "max-w-sm", children: [_jsx(Label, { children: "Afname-eenheid" }), _jsxs(Select, { value: form.unit, onValueChange: (v) => patch({ unit: v }), children: [_jsx(SelectTrigger, { children: _jsx(SelectValue, { placeholder: "- Selecteer een eenheid -" }) }), _jsxs(SelectContent, { children: [_jsx(SelectItem, { value: "per_fust", children: "Per fust" }), _jsx(SelectItem, { value: "per_laag", children: "Per laag" }), _jsx(SelectItem, { value: "per_ladingdrager", children: "Per ladingdrager" })] })] })] }), _jsxs("div", { className: "text-xs text-muted-foreground mt-2 leading-relaxed", children: ["Afname-eenheid per aangeboden artikel.", _jsx("br", {}), "Deze instelling geldt voor alle klanten in deze prijsgroep, per aangeboden artikel, niet per bestelling."] })] }), _jsx("div", { className: "pt-2 flex justify-end", children: _jsxs(Button, { onClick: () => nextStep(1), children: ["Volgende stap ", _jsx(ArrowRight, { className: "h-4 w-4 ml-1" })] }) })] }) }), _jsx(StepSection, { index: 2, title: STEP_TITLES[2], subtitle: summaries[2], open: openStep === 2, completed: form.pricing_mode === "calculated" && maxReached >= 2 && openStep !== 2, disabled: maxReached < 2 || form.pricing_mode !== "calculated", onToggle: () => goToStep(2), children: _jsx("div", { className: "space-y-4", children: form.pricing_mode !== "calculated" ? (_jsx("div", { className: "text-sm text-muted-foreground p-4 border rounded-md bg-muted/30", children: "Deze prijsgroep gebruikt handmatige prijzen. Prijsberekening is niet van toepassing." })) : (_jsxs(_Fragment, { children: [_jsxs("div", { children: [_jsx(Label, { children: "Korting/opslag per stuk" }), _jsxs("div", { className: "grid grid-cols-1 sm:grid-cols-3 gap-3 mt-1.5", children: [_jsxs(Select, { value: form.calc_type ?? "discount", onValueChange: (v) => patch({ calc_type: v }), children: [_jsx(SelectTrigger, { children: _jsx(SelectValue, {}) }), _jsxs(SelectContent, { children: [_jsx(SelectItem, { value: "discount", children: "Korting" }), _jsx(SelectItem, { value: "surcharge", children: "Opslag" })] })] }), _jsxs(Select, { value: form.calc_value_type ?? "fixed", onValueChange: (v) => patch({ calc_value_type: v }), children: [_jsx(SelectTrigger, { children: _jsx(SelectValue, {}) }), _jsxs(SelectContent, { children: [_jsx(SelectItem, { value: "percentage", children: "Percentage" }), _jsx(SelectItem, { value: "fixed", children: "Vast bedrag" })] })] }), _jsxs("div", { className: "relative", children: [form.calc_value_type !== "percentage" && (_jsx("span", { className: "absolute left-3 top-1/2 -translate-y-1/2 text-sm text-muted-foreground pointer-events-none", children: "\u20AC" })), _jsx(Input, { type: "number", step: form.calc_value_type === "percentage" ? "1" : "0.001", value: form.calc_value ?? 0, onChange: (e) => patch({ calc_value: Number(e.target.value) }), className: form.calc_value_type === "percentage" ? "pr-8" : "pl-7" }), form.calc_value_type === "percentage" && (_jsx("span", { className: "absolute right-3 top-1/2 -translate-y-1/2 text-sm text-muted-foreground pointer-events-none", children: "%" }))] })] })] }), _jsxs("div", { className: "grid grid-cols-1 sm:grid-cols-2 gap-4", children: [_jsxs("div", { children: [_jsxs(Label, { className: "flex items-center gap-1.5", children: ["Afhandelingskosten (optioneel)", _jsx(Info, { className: "h-3.5 w-3.5 text-muted-foreground", "aria-label": "Extra kosten die bovenop de prijs komen. Kies hoe deze verdeeld worden." })] }), _jsxs("div", { className: "relative mt-1.5", children: [_jsx("span", { className: "absolute left-3 top-1/2 -translate-y-1/2 text-sm text-muted-foreground pointer-events-none", children: "\u20AC" }), _jsx(Input, { type: "number", step: "0.01", value: form.handling_fee ?? 0, onChange: (e) => patch({ handling_fee: Number(e.target.value) }), className: "pl-7" })] })] }), _jsxs("div", { children: [_jsx(Label, { children: "Verdeeld over het aantal planten of bloemen op een" }), _jsxs(Select, { value: form.distribute_over ?? "ladingdrager", onValueChange: (v) => patch({ distribute_over: v }), children: [_jsx(SelectTrigger, { className: "mt-1.5", children: _jsx(SelectValue, {}) }), _jsxs(SelectContent, { children: [_jsx(SelectItem, { value: "ladingdrager", children: "Ladingdrager" }), _jsx(SelectItem, { value: "laag", children: "Laag" }), _jsx(SelectItem, { value: "fust", children: "Fust" })] })] })] })] }), _jsxs("div", { className: "grid grid-cols-1 sm:grid-cols-2 gap-4", children: [_jsxs("div", { children: [_jsx(Label, { children: "Prijs afronden" }), _jsxs(Select, { value: form.rounding, onValueChange: (v) => patch({ rounding: v }), children: [_jsx(SelectTrigger, { className: "mt-1.5", children: _jsx(SelectValue, {}) }), _jsxs(SelectContent, { children: [_jsx(SelectItem, { value: "none", children: "Niet afronden" }), _jsx(SelectItem, { value: "up", children: "Omhoog" }), _jsx(SelectItem, { value: "down", children: "Omlaag" }), _jsx(SelectItem, { value: "nearest", children: "Dichtstbijzijnde" })] })] })] }), form.rounding !== "none" && (_jsxs("div", { children: [_jsx(Label, { children: "Op" }), _jsxs(Select, { value: String(form.rounding_step ?? 0.05), onValueChange: (v) => patch({ rounding_step: Number(v) }), children: [_jsx(SelectTrigger, { className: "mt-1.5", children: _jsx(SelectValue, {}) }), _jsxs(SelectContent, { children: [_jsx(SelectItem, { value: "0.01", children: "\u20AC 0,01" }), _jsx(SelectItem, { value: "0.05", children: "\u20AC 0,05" }), _jsx(SelectItem, { value: "0.1", children: "\u20AC 0,10" })] })] })] }))] }), _jsx("div", { className: "pt-2 flex justify-end", children: _jsxs(Button, { onClick: () => nextStep(2), children: ["Volgende stap ", _jsx(ArrowRight, { className: "h-4 w-4 ml-1" })] }) })] })) }) }), _jsxs(StepSection, { index: 3, title: STEP_TITLES[3], subtitle: summaries[3], open: openStep === 3, completed: form.group_type === "customer_specific" && maxReached >= 3 && openStep !== 3 && selectedCustomerKeys.length > 0, disabled: maxReached < 3 || form.group_type !== "customer_specific", onToggle: () => goToStep(3), children: [form.group_type !== "customer_specific" ? (_jsx("div", { className: "text-sm text-muted-foreground p-4 border rounded-md bg-muted/30", children: "Algemene prijsgroepen zijn zichtbaar voor alle klanten \u2014 een doelgroep is niet van toepassing." })) : selectedCustomerKeys.length === 0 ? (_jsxs("div", { className: "rounded-lg border bg-muted/20 p-8", children: [_jsxs("div", { className: "flex flex-col items-center text-center gap-3", children: [_jsxs("div", { className: "relative h-16 w-16 rounded-full bg-muted flex items-center justify-center", children: [_jsx(Users2, { className: "h-8 w-8 text-muted-foreground/60" }), _jsx("span", { className: "absolute -top-1 -right-1 h-6 w-6 rounded-full bg-background border flex items-center justify-center", children: _jsx(UserPlus, { className: "h-3.5 w-3.5 text-muted-foreground" }) })] }), _jsx("div", { children: _jsx("div", { className: "font-medium text-sm", children: "Nog geen klanten toegevoegd" }) })] }), _jsx("div", { className: "flex justify-end mt-4", children: _jsxs(Button, { variant: "outline", onClick: () => setCustomerPickerOpen(true), children: [_jsx(UserPlus, { className: "h-4 w-4 mr-1.5" }), " Organisaties wijzigen"] }) })] })) : (_jsxs("div", { className: "space-y-3", children: [_jsxs("div", { className: "flex items-center justify-between", children: [_jsxs("div", { className: "text-sm text-muted-foreground", children: [_jsx("strong", { className: "text-foreground", children: selectedCustomerKeys.length }), " ", "klant", selectedCustomerKeys.length === 1 ? "" : "en", " gekoppeld"] }), _jsxs(Button, { variant: "outline", size: "sm", onClick: () => setCustomerPickerOpen(true), children: [_jsx(UserPlus, { className: "h-4 w-4 mr-1.5" }), " Organisaties wijzigen"] })] }), _jsx("div", { className: "max-h-[320px] overflow-y-auto border rounded-md divide-y", children: selectedCustomerKeys.map((k) => {
|
|
259
259
|
const c = customersByKey.get(k);
|
|
260
|
-
return (_jsxs("div", { className: "flex items-center gap-3 p-2.5", children: [_jsxs("div", { className: "flex-1 min-w-0", children: [_jsx("div", { className: "text-sm font-medium truncate", children: c?.display_name ?? k }), _jsx("div", { className: "text-xs text-muted-foreground truncate", children: c ? (c.city || c.country ? (_jsxs("span", { className: "inline-flex items-center gap-1", children: [c.city && _jsx("span", { children: c.city }), c.city && c.country && _jsx("span", { children: "\u00B7" }), c.country && (_jsxs(_Fragment, { children: [_jsx("span", { className: "text-base", "aria-hidden": "true", children: countryNameToFlag(c.country) ?? "🌐" }), _jsx("span", { children: c.country })] }))] })) : "—") : "
|
|
260
|
+
return (_jsxs("div", { className: "flex items-center gap-3 p-2.5", children: [_jsxs("div", { className: "flex-1 min-w-0", children: [_jsx("div", { className: "text-sm font-medium truncate", children: c?.display_name ?? k }), _jsx("div", { className: "text-xs text-muted-foreground truncate", children: c ? (c.city || c.country ? (_jsxs("span", { className: "inline-flex items-center gap-1", children: [c.city && _jsx("span", { children: c.city }), c.city && c.country && _jsx("span", { children: "\u00B7" }), c.country && (_jsxs(_Fragment, { children: [_jsx("span", { className: "text-base", "aria-hidden": "true", children: countryNameToFlag(c.country) ?? "🌐" }), _jsx("span", { children: c.country })] }))] })) : "—") : "Nog niet opgehaald uit Floriday" })] }), _jsx("div", { className: "flex gap-1", children: (c?.providers ?? []).slice(0, 3).map((p) => (_jsx(Badge, { variant: "secondary", className: "text-[10px]", children: p }, p))) })] }, k));
|
|
261
261
|
}) })] })), _jsx(CustomerPickerDialog, { open: customerPickerOpen, onOpenChange: setCustomerPickerOpen, value: selectedCustomerKeys, onChange: setSelectedCustomerKeys })] }), editingId && (_jsx(PriceGroupItemPrices, { priceGroupId: editingId, currency: form.currency })), error && _jsx("div", { className: "text-sm text-destructive", children: error })] }), form.pricing_mode === "calculated" && (_jsxs("aside", { className: "lg:sticky lg:top-4 space-y-3", children: [_jsx(Card, { children: _jsxs(CardContent, { className: "p-4 space-y-4", children: [_jsxs("div", { className: "flex items-center justify-between", children: [_jsx("div", { className: "text-sm font-medium", children: "Voorbeeld prijscalculatie" }), _jsxs("div", { className: "flex items-center gap-1", children: [_jsx(Button, { variant: "outline", size: "icon", className: "h-7 w-7", onClick: () => cycleItem(-1), disabled: items.length < 2, "aria-label": "Vorige product", children: _jsx(ChevronLeft, { className: "h-4 w-4" }) }), _jsx(Button, { variant: "outline", size: "icon", className: "h-7 w-7", onClick: () => cycleItem(1), disabled: items.length < 2, "aria-label": "Volgend product", children: _jsx(ChevronRight, { className: "h-4 w-4" }) })] })] }), _jsxs("button", { type: "button", onClick: () => setPickerOpen(true), className: "w-full flex items-center gap-3 text-left hover:bg-muted/30 rounded-md p-2 -m-2", children: [_jsx("div", { className: "h-14 w-14 rounded bg-muted flex items-center justify-center overflow-hidden shrink-0", children: selectedItem?.image_url
|
|
262
262
|
? _jsx("img", { src: selectedItem.image_url, alt: "", className: "h-full w-full object-contain" })
|
|
263
263
|
: _jsx(ImageIcon, { className: "h-6 w-6 text-muted-foreground" }) }), _jsxs("div", { className: "min-w-0 flex-1", children: [_jsx("div", { className: "text-sm font-medium truncate", children: selectedItem?.name ?? "Geen product beschikbaar" }), _jsx("div", { className: "text-xs text-muted-foreground truncate", children: selectedItem
|
|
@@ -265,7 +265,7 @@ export function PriceGroupFormPage({ editingId }) {
|
|
|
265
265
|
`${selectedItem.units_per_fust}×${selectedItem.packages_per_layer}×${selectedItem.layers_per_carrier}`,
|
|
266
266
|
selectedItem.carrier_code]
|
|
267
267
|
.filter(Boolean).join(" - ")
|
|
268
|
-
: "
|
|
268
|
+
: "Nog niet opgehaald uit Floriday" })] })] }), _jsxs("div", { children: [_jsx(Label, { className: "text-xs", children: "Basisprijs" }), _jsxs("div", { className: "relative mt-1.5", children: [_jsx("span", { className: "absolute left-3 top-1/2 -translate-y-1/2 text-sm text-muted-foreground pointer-events-none", children: "\u20AC" }), _jsx(Input, { type: "number", step: "0.01", value: basePrice, onChange: (e) => setBasePrice(Number(e.target.value)), className: "pl-7" })] })] }), _jsxs("div", { children: [_jsx("div", { className: "flex justify-end text-xs text-muted-foreground mb-1", children: "Prijzen" }), _jsxs("div", { className: "space-y-1.5 text-sm tabular-nums border-t pt-2", children: [_jsxs("div", { className: "flex justify-between", children: [_jsx("span", { className: "text-muted-foreground", children: "Basisprijs" }), _jsx("span", { children: formatEur(basePrice) })] }), Math.abs(preview.discountAmount) > 0 && (_jsxs("div", { className: "flex justify-between", children: [_jsxs("span", { className: "text-muted-foreground", children: [form.calc_type === "surcharge" ? "Opslag" : "Korting", " ", form.calc_value_type === "percentage"
|
|
269
269
|
? `${(form.calc_value ?? 0).toLocaleString("nl-NL")}%`
|
|
270
270
|
: formatEur(form.calc_value ?? 0, { decimals: 3 })] }), _jsxs("span", { children: [preview.discountAmount < 0 ? "− " : "", formatEur(Math.abs(preview.discountAmount))] })] })), preview.handlingPerUnit > 0 && (_jsxs("div", { className: "flex justify-between items-baseline gap-2", children: [_jsxs("span", { className: "text-muted-foreground truncate", children: ["Afhandelingskosten (optioneel)", " ", _jsxs("span", { className: "italic text-muted-foreground/80", children: [formatEur(form.handling_fee ?? 0), handlingSuffix] })] }), _jsx("span", { children: formatEur(preview.handlingPerUnit, { decimals: 3 }) })] })), _jsxs("div", { className: "flex justify-between border-t pt-1.5", children: [_jsx("span", { className: form.rounding === "none" ? "font-medium" : "text-muted-foreground", children: "Berekende prijs" }), _jsx("span", { className: form.rounding === "none" ? "font-medium" : "", children: formatEur(preview.adjusted, { decimals: 3 }) })] }), form.rounding !== "none" && (_jsxs("div", { className: "flex justify-between font-medium border-t pt-1.5", children: [_jsx("span", { children: "Afgeronde prijs" }), _jsx("span", { children: formatEur(preview.rounded) })] }))] })] })] }) }), _jsx(ProductPickerDialog, { open: pickerOpen, onOpenChange: setPickerOpen, items: items, onSelect: (i) => setSelectedItemId(i.id) })] }))] })] }), _jsx("div", { className: "fixed bottom-0 left-0 right-0 bg-background/95 backdrop-blur border-t z-10", children: _jsxs("div", { className: "max-w-6xl mx-auto px-6 py-3 flex items-center justify-between", children: [_jsx(Button, { variant: "ghost", onClick: goBack, children: "Annuleren" }), _jsx(Button, { onClick: () => saveMut.mutate(), disabled: saveMut.isPending ||
|
|
271
271
|
!form.name.trim() ||
|
|
@@ -10,10 +10,10 @@ import { Plus, Search, MoreVertical, GripVertical, EyeOff, Eye, Pencil, Users, C
|
|
|
10
10
|
import { DndContext, closestCenter, KeyboardSensor, PointerSensor, useSensor, useSensors, } from "@dnd-kit/core";
|
|
11
11
|
import { SortableContext, sortableKeyboardCoordinates, verticalListSortingStrategy, useSortable, arrayMove, } from "@dnd-kit/sortable";
|
|
12
12
|
import { CSS } from "@dnd-kit/utilities";
|
|
13
|
-
import { listCustomerPriceGroups, deleteCustomerPriceGroup, reorderCustomerPriceGroups, updateCustomerPriceGroup, createCustomerPriceGroup, importFloridayPriceGroups, } from "../../../lib/price-groups-local.functions";
|
|
14
|
-
import { CustomerPickerDialog } from "./CustomerPickerDialog";
|
|
15
|
-
import { UnknownFloridayMembers } from "./UnknownFloridayMembers";
|
|
16
|
-
import { friendlyError } from "../../../lib/errors";
|
|
13
|
+
import { listCustomerPriceGroups, deleteCustomerPriceGroup, reorderCustomerPriceGroups, updateCustomerPriceGroup, createCustomerPriceGroup, importFloridayPriceGroups, } from "../../../lib/price-groups-local.functions.js";
|
|
14
|
+
import { CustomerPickerDialog } from "./CustomerPickerDialog.js";
|
|
15
|
+
import { UnknownFloridayMembers } from "./UnknownFloridayMembers.js";
|
|
16
|
+
import { friendlyError } from "../../../lib/errors.js";
|
|
17
17
|
import { toast } from "sonner";
|
|
18
18
|
function unitLabel(u) {
|
|
19
19
|
switch (u) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { Outlet, useRouterState } from "@tanstack/react-router";
|
|
3
|
-
import { PriceGroupsPage } from "./PriceGroupsPage";
|
|
3
|
+
import { PriceGroupsPage } from "./PriceGroupsPage.js";
|
|
4
4
|
export function PriceGroupsRoute() {
|
|
5
5
|
const pathname = useRouterState({
|
|
6
6
|
select: (state) => state.location.pathname.replace(/\/+$/, ""),
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { TradeItemPreview } from "../../../lib/floriday-trade-items.functions";
|
|
1
|
+
import type { TradeItemPreview } from "../../../lib/floriday-trade-items.functions.js";
|
|
2
2
|
export declare function ProductPickerDialog({ open, onOpenChange, items, onSelect, }: {
|
|
3
3
|
open: boolean;
|
|
4
4
|
onOpenChange: (v: boolean) => void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type UnknownFloridayMember } from "../../../lib/price-groups-local.functions";
|
|
1
|
+
import { type UnknownFloridayMember } from "../../../lib/price-groups-local.functions.js";
|
|
2
2
|
/**
|
|
3
3
|
* Floriday-leden van een prijsgroep die nog geen ERP-klant zijn. Er wordt niets vastgelegd
|
|
4
4
|
* tot iemand op "Toevoegen" klikt; dan ontstaat een klant zonder Twinfield-debiteur.
|
|
@@ -4,8 +4,8 @@ import { useMutation, useQueryClient } from "@tanstack/react-query";
|
|
|
4
4
|
import { useServerFn } from "@tanstack/react-start";
|
|
5
5
|
import { Button, Badge } from "@flowselections/core";
|
|
6
6
|
import { toast } from "sonner";
|
|
7
|
-
import { addFloridayMemberToPriceGroup, } from "../../../lib/price-groups-local.functions";
|
|
8
|
-
import { friendlyError } from "../../../lib/errors";
|
|
7
|
+
import { addFloridayMemberToPriceGroup, } from "../../../lib/price-groups-local.functions.js";
|
|
8
|
+
import { friendlyError } from "../../../lib/errors.js";
|
|
9
9
|
/**
|
|
10
10
|
* Floriday-leden van een prijsgroep die nog geen ERP-klant zijn. Er wordt niets vastgelegd
|
|
11
11
|
* tot iemand op "Toevoegen" klikt; dan ontstaat een klant zonder Twinfield-debiteur.
|
|
@@ -29,7 +29,7 @@ export function UnknownFloridayMembers({ members, priceGroupIdFor, }) {
|
|
|
29
29
|
qc.invalidateQueries({ queryKey: ["unknown-floriday-members"] });
|
|
30
30
|
qc.invalidateQueries({ queryKey: ["customer-price-group"] });
|
|
31
31
|
qc.invalidateQueries({ queryKey: ["external-customers-picker"] });
|
|
32
|
-
toast.success(`${m.commercial_name ?? m.name} is toegevoegd als klant
|
|
32
|
+
toast.success(`${m.commercial_name ?? m.name} is toegevoegd als klant en staat in deze prijsgroep.`);
|
|
33
33
|
},
|
|
34
34
|
onError: (e) => toast.error(friendlyError(e)),
|
|
35
35
|
});
|
|
@@ -39,5 +39,5 @@ export function UnknownFloridayMembers({ members, priceGroupIdFor, }) {
|
|
|
39
39
|
const added = done.has(m.organization_id);
|
|
40
40
|
const canAdd = m.groups.some((g) => priceGroupIdFor(g.external_id));
|
|
41
41
|
return (_jsxs("div", { className: "flex flex-wrap items-center justify-between gap-2 px-3 py-2", children: [_jsxs("div", { className: "min-w-0 flex-1", children: [_jsx("div", { className: "text-sm font-medium truncate", children: m.commercial_name ?? m.name }), _jsxs("div", { className: "text-xs text-muted-foreground truncate", children: [m.commercial_name ? `${m.name} · ` : "", m.city ?? "—", " \u00B7 ", m.reason] }), m.groups.length > 0 && (_jsxs("div", { className: "text-xs text-muted-foreground truncate", children: ["In Floriday: ", m.groups.map((g) => g.name).join(", ")] }))] }), added ? (_jsx(Badge, { variant: "secondary", children: "Toegevoegd" })) : (_jsx(Button, { size: "sm", variant: "outline", disabled: !canAdd || addMut.isPending, title: canAdd ? undefined : "Importeer eerst de prijsgroep", onClick: () => addMut.mutate(m), children: "Toevoegen" }))] }, m.organization_id));
|
|
42
|
-
}) }), _jsx("p", { className: "text-xs text-muted-foreground", children: "Toevoegen maakt een klant aan
|
|
42
|
+
}) }), _jsx("p", { className: "text-xs text-muted-foreground", children: "Toevoegen maakt een nieuwe klant aan (nog niet in de boekhouding) en zet die in deze prijsgroep." })] }));
|
|
43
43
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/** Standaardwaarden van de actieve administratie (land, taal, grootboek, betaaltermijn). */
|
|
2
2
|
export declare function useCustomerDefaults(): {
|
|
3
3
|
isLoading: boolean;
|
|
4
|
-
defaults?: import("../../lib/twinfield-customer-defaults.server").CustomerDefaults | undefined;
|
|
4
|
+
defaults?: import("../../lib/twinfield-customer-defaults.server.js").CustomerDefaults | undefined;
|
|
5
5
|
isAdmin?: boolean | undefined;
|
|
6
6
|
};
|
|
7
7
|
export declare const MISSING_DEFAULT_MESSAGE = "Standaardwaarde ontbreekt in de Twinfield-instellingen";
|
package/dist-lib/index.d.ts
CHANGED
|
@@ -1,37 +1,37 @@
|
|
|
1
1
|
import type { FlowModule } from "@flowselections/core";
|
|
2
|
-
export * from "./_core-safelist";
|
|
3
|
-
export { KlantenOverzicht } from "./components/klanten/KlantenOverzicht";
|
|
4
|
-
export { KlantDetail } from "./components/klanten/KlantDetail";
|
|
5
|
-
export { GroupedKlantDetail } from "./components/klanten/GroupedKlantDetail";
|
|
6
|
-
export { NetwerkPagina } from "./components/klanten/NetwerkPagina";
|
|
7
|
-
export { NieuweKlant } from "./components/klanten/NieuweKlant";
|
|
8
|
-
export { KlantFormulier } from "./components/klanten/KlantFormulier";
|
|
9
|
-
export { BewerkKlant } from "./components/klanten/BewerkKlant";
|
|
10
|
-
export { BewerkKlantRoute } from "./components/klanten/BewerkKlantRoute";
|
|
11
|
-
export { KlantBewerkenDialog } from "./components/klanten/KlantBewerkenDialog";
|
|
12
|
-
export { OvernemenTwinfieldKlant } from "./components/klanten/OvernemenTwinfieldKlant";
|
|
13
|
-
export { OvernemenTwinfieldKlantRoute } from "./components/klanten/OvernemenTwinfieldKlantRoute";
|
|
14
|
-
export { ImportKlanten } from "./components/klanten/ImportKlanten";
|
|
15
|
-
export { KlantDetailRoute } from "./components/klanten/KlantDetailRoute";
|
|
16
|
-
export { GroupedKlantDetailRoute } from "./components/klanten/GroupedKlantDetailRoute";
|
|
17
|
-
export { PriceGroupsPage } from "./components/klanten/pricegroups/PriceGroupsPage";
|
|
18
|
-
export { PriceGroupsRoute } from "./components/klanten/pricegroups/PriceGroupsRoute";
|
|
19
|
-
export { PriceGroupFormPage } from "./components/klanten/pricegroups/PriceGroupFormPage";
|
|
20
|
-
export { PriceGroupNewRoute } from "./components/klanten/pricegroups/PriceGroupNewRoute";
|
|
21
|
-
export { PriceGroupEditRoute } from "./components/klanten/pricegroups/PriceGroupEditRoute";
|
|
22
|
-
export { CustomerPriceGroupSelect } from "./components/klanten/pricegroups/CustomerPriceGroupSelect";
|
|
23
|
-
export { CustomerAssortmentTab } from "./components/klanten/CustomerAssortmentTab";
|
|
24
|
-
export { listCustomerAssortment } from "./lib/customer-assortment.functions";
|
|
25
|
-
export { loadFloridayCatalogPrices, type CatalogPrice } from "./lib/floriday-catalog-prices";
|
|
26
|
-
export { FloridayPriceImportDialog } from "./components/klanten/FloridayPriceImportDialog";
|
|
27
|
-
export { CustomerStickerCell } from "./components/klanten/CustomerStickerCell";
|
|
28
|
-
export { CustomerStickerFormatDialog } from "./components/klanten/CustomerStickerFormatDialog";
|
|
29
|
-
export { BulkStickerUploadDialog } from "./components/klanten/BulkStickerUploadDialog";
|
|
30
|
-
export { listCustomerStickers, confirmStickerUpload, deleteCustomerSticker, getCustomerStickerSettings, setCustomerStickerSettings, getStickerForPrint, suggestStickerMatches, commitStickerBatch, discardStickerBatch, ALLOWED_STICKER_MIME, type CustomerSticker, type CustomerStickersResult, type StickerFormat, } from "./lib/customer-stickers.functions";
|
|
31
|
-
export { previewFloridayPriceImport, applyFloridayPriceImport, } from "./lib/floriday-price-import.functions";
|
|
32
|
-
export { getPriceGroupsForCustomer, setPriceGroupForCustomer, resolveCustomerKeyForLocalCustomer, listPriceGroupItemPrices, setPriceGroupItemPrice, } from "./lib/price-groups-local.functions";
|
|
33
|
-
export { PriceGroupItemPrices } from "./components/klanten/pricegroups/PriceGroupItemPrices";
|
|
34
|
-
export { listLogisticsStrategies, getLogisticsStrategyBinding, setLogisticsStrategyBinding, resolveLogisticsStrategy, } from "./lib/logistics-strategy.functions";
|
|
35
|
-
export { emitLogisticsEvent } from "./lib/logistics-events.functions";
|
|
2
|
+
export * from "./_core-safelist.js";
|
|
3
|
+
export { KlantenOverzicht } from "./components/klanten/KlantenOverzicht.js";
|
|
4
|
+
export { KlantDetail } from "./components/klanten/KlantDetail.js";
|
|
5
|
+
export { GroupedKlantDetail } from "./components/klanten/GroupedKlantDetail.js";
|
|
6
|
+
export { NetwerkPagina } from "./components/klanten/NetwerkPagina.js";
|
|
7
|
+
export { NieuweKlant } from "./components/klanten/NieuweKlant.js";
|
|
8
|
+
export { KlantFormulier } from "./components/klanten/KlantFormulier.js";
|
|
9
|
+
export { BewerkKlant } from "./components/klanten/BewerkKlant.js";
|
|
10
|
+
export { BewerkKlantRoute } from "./components/klanten/BewerkKlantRoute.js";
|
|
11
|
+
export { KlantBewerkenDialog } from "./components/klanten/KlantBewerkenDialog.js";
|
|
12
|
+
export { OvernemenTwinfieldKlant } from "./components/klanten/OvernemenTwinfieldKlant.js";
|
|
13
|
+
export { OvernemenTwinfieldKlantRoute } from "./components/klanten/OvernemenTwinfieldKlantRoute.js";
|
|
14
|
+
export { ImportKlanten } from "./components/klanten/ImportKlanten.js";
|
|
15
|
+
export { KlantDetailRoute } from "./components/klanten/KlantDetailRoute.js";
|
|
16
|
+
export { GroupedKlantDetailRoute } from "./components/klanten/GroupedKlantDetailRoute.js";
|
|
17
|
+
export { PriceGroupsPage } from "./components/klanten/pricegroups/PriceGroupsPage.js";
|
|
18
|
+
export { PriceGroupsRoute } from "./components/klanten/pricegroups/PriceGroupsRoute.js";
|
|
19
|
+
export { PriceGroupFormPage } from "./components/klanten/pricegroups/PriceGroupFormPage.js";
|
|
20
|
+
export { PriceGroupNewRoute } from "./components/klanten/pricegroups/PriceGroupNewRoute.js";
|
|
21
|
+
export { PriceGroupEditRoute } from "./components/klanten/pricegroups/PriceGroupEditRoute.js";
|
|
22
|
+
export { CustomerPriceGroupSelect } from "./components/klanten/pricegroups/CustomerPriceGroupSelect.js";
|
|
23
|
+
export { CustomerAssortmentTab } from "./components/klanten/CustomerAssortmentTab.js";
|
|
24
|
+
export { listCustomerAssortment } from "./lib/customer-assortment.functions.js";
|
|
25
|
+
export { loadFloridayCatalogPrices, type CatalogPrice } from "./lib/floriday-catalog-prices.js";
|
|
26
|
+
export { FloridayPriceImportDialog } from "./components/klanten/FloridayPriceImportDialog.js";
|
|
27
|
+
export { CustomerStickerCell } from "./components/klanten/CustomerStickerCell.js";
|
|
28
|
+
export { CustomerStickerFormatDialog } from "./components/klanten/CustomerStickerFormatDialog.js";
|
|
29
|
+
export { BulkStickerUploadDialog } from "./components/klanten/BulkStickerUploadDialog.js";
|
|
30
|
+
export { listCustomerStickers, confirmStickerUpload, deleteCustomerSticker, getCustomerStickerSettings, setCustomerStickerSettings, getStickerForPrint, suggestStickerMatches, commitStickerBatch, discardStickerBatch, ALLOWED_STICKER_MIME, type CustomerSticker, type CustomerStickersResult, type StickerFormat, } from "./lib/customer-stickers.functions.js";
|
|
31
|
+
export { previewFloridayPriceImport, applyFloridayPriceImport, } from "./lib/floriday-price-import.functions.js";
|
|
32
|
+
export { getPriceGroupsForCustomer, setPriceGroupForCustomer, resolveCustomerKeyForLocalCustomer, listPriceGroupItemPrices, setPriceGroupItemPrice, } from "./lib/price-groups-local.functions.js";
|
|
33
|
+
export { PriceGroupItemPrices } from "./components/klanten/pricegroups/PriceGroupItemPrices.js";
|
|
34
|
+
export { listLogisticsStrategies, getLogisticsStrategyBinding, setLogisticsStrategyBinding, resolveLogisticsStrategy, } from "./lib/logistics-strategy.functions.js";
|
|
35
|
+
export { emitLogisticsEvent } from "./lib/logistics-events.functions.js";
|
|
36
36
|
export declare const floridayKlantenModule: FlowModule;
|
|
37
37
|
//# sourceMappingURL=index.d.ts.map
|
package/dist-lib/index.js
CHANGED
|
@@ -14,41 +14,41 @@
|
|
|
14
14
|
// 4. Done! You don't need to touch any other file for registration.
|
|
15
15
|
// ============================================================================
|
|
16
16
|
import { Users, Tag } from "lucide-react";
|
|
17
|
-
import { CustomerFieldsCard } from "./components/settings/CustomerFieldsCard";
|
|
18
|
-
export * from "./_core-safelist";
|
|
19
|
-
export { KlantenOverzicht } from "./components/klanten/KlantenOverzicht";
|
|
20
|
-
export { KlantDetail } from "./components/klanten/KlantDetail";
|
|
21
|
-
export { GroupedKlantDetail } from "./components/klanten/GroupedKlantDetail";
|
|
22
|
-
export { NetwerkPagina } from "./components/klanten/NetwerkPagina";
|
|
23
|
-
export { NieuweKlant } from "./components/klanten/NieuweKlant";
|
|
24
|
-
export { KlantFormulier } from "./components/klanten/KlantFormulier";
|
|
25
|
-
export { BewerkKlant } from "./components/klanten/BewerkKlant";
|
|
26
|
-
export { BewerkKlantRoute } from "./components/klanten/BewerkKlantRoute";
|
|
27
|
-
export { KlantBewerkenDialog } from "./components/klanten/KlantBewerkenDialog";
|
|
28
|
-
export { OvernemenTwinfieldKlant } from "./components/klanten/OvernemenTwinfieldKlant";
|
|
29
|
-
export { OvernemenTwinfieldKlantRoute } from "./components/klanten/OvernemenTwinfieldKlantRoute";
|
|
30
|
-
export { ImportKlanten } from "./components/klanten/ImportKlanten";
|
|
31
|
-
export { KlantDetailRoute } from "./components/klanten/KlantDetailRoute";
|
|
32
|
-
export { GroupedKlantDetailRoute } from "./components/klanten/GroupedKlantDetailRoute";
|
|
33
|
-
export { PriceGroupsPage } from "./components/klanten/pricegroups/PriceGroupsPage";
|
|
34
|
-
export { PriceGroupsRoute } from "./components/klanten/pricegroups/PriceGroupsRoute";
|
|
35
|
-
export { PriceGroupFormPage } from "./components/klanten/pricegroups/PriceGroupFormPage";
|
|
36
|
-
export { PriceGroupNewRoute } from "./components/klanten/pricegroups/PriceGroupNewRoute";
|
|
37
|
-
export { PriceGroupEditRoute } from "./components/klanten/pricegroups/PriceGroupEditRoute";
|
|
38
|
-
export { CustomerPriceGroupSelect } from "./components/klanten/pricegroups/CustomerPriceGroupSelect";
|
|
39
|
-
export { CustomerAssortmentTab } from "./components/klanten/CustomerAssortmentTab";
|
|
40
|
-
export { listCustomerAssortment } from "./lib/customer-assortment.functions";
|
|
41
|
-
export { loadFloridayCatalogPrices } from "./lib/floriday-catalog-prices";
|
|
42
|
-
export { FloridayPriceImportDialog } from "./components/klanten/FloridayPriceImportDialog";
|
|
43
|
-
export { CustomerStickerCell } from "./components/klanten/CustomerStickerCell";
|
|
44
|
-
export { CustomerStickerFormatDialog } from "./components/klanten/CustomerStickerFormatDialog";
|
|
45
|
-
export { BulkStickerUploadDialog } from "./components/klanten/BulkStickerUploadDialog";
|
|
46
|
-
export { listCustomerStickers, confirmStickerUpload, deleteCustomerSticker, getCustomerStickerSettings, setCustomerStickerSettings, getStickerForPrint, suggestStickerMatches, commitStickerBatch, discardStickerBatch, ALLOWED_STICKER_MIME, } from "./lib/customer-stickers.functions";
|
|
47
|
-
export { previewFloridayPriceImport, applyFloridayPriceImport, } from "./lib/floriday-price-import.functions";
|
|
48
|
-
export { getPriceGroupsForCustomer, setPriceGroupForCustomer, resolveCustomerKeyForLocalCustomer, listPriceGroupItemPrices, setPriceGroupItemPrice, } from "./lib/price-groups-local.functions";
|
|
49
|
-
export { PriceGroupItemPrices } from "./components/klanten/pricegroups/PriceGroupItemPrices";
|
|
50
|
-
export { listLogisticsStrategies, getLogisticsStrategyBinding, setLogisticsStrategyBinding, resolveLogisticsStrategy, } from "./lib/logistics-strategy.functions";
|
|
51
|
-
export { emitLogisticsEvent } from "./lib/logistics-events.functions";
|
|
17
|
+
import { CustomerFieldsCard } from "./components/settings/CustomerFieldsCard.js";
|
|
18
|
+
export * from "./_core-safelist.js";
|
|
19
|
+
export { KlantenOverzicht } from "./components/klanten/KlantenOverzicht.js";
|
|
20
|
+
export { KlantDetail } from "./components/klanten/KlantDetail.js";
|
|
21
|
+
export { GroupedKlantDetail } from "./components/klanten/GroupedKlantDetail.js";
|
|
22
|
+
export { NetwerkPagina } from "./components/klanten/NetwerkPagina.js";
|
|
23
|
+
export { NieuweKlant } from "./components/klanten/NieuweKlant.js";
|
|
24
|
+
export { KlantFormulier } from "./components/klanten/KlantFormulier.js";
|
|
25
|
+
export { BewerkKlant } from "./components/klanten/BewerkKlant.js";
|
|
26
|
+
export { BewerkKlantRoute } from "./components/klanten/BewerkKlantRoute.js";
|
|
27
|
+
export { KlantBewerkenDialog } from "./components/klanten/KlantBewerkenDialog.js";
|
|
28
|
+
export { OvernemenTwinfieldKlant } from "./components/klanten/OvernemenTwinfieldKlant.js";
|
|
29
|
+
export { OvernemenTwinfieldKlantRoute } from "./components/klanten/OvernemenTwinfieldKlantRoute.js";
|
|
30
|
+
export { ImportKlanten } from "./components/klanten/ImportKlanten.js";
|
|
31
|
+
export { KlantDetailRoute } from "./components/klanten/KlantDetailRoute.js";
|
|
32
|
+
export { GroupedKlantDetailRoute } from "./components/klanten/GroupedKlantDetailRoute.js";
|
|
33
|
+
export { PriceGroupsPage } from "./components/klanten/pricegroups/PriceGroupsPage.js";
|
|
34
|
+
export { PriceGroupsRoute } from "./components/klanten/pricegroups/PriceGroupsRoute.js";
|
|
35
|
+
export { PriceGroupFormPage } from "./components/klanten/pricegroups/PriceGroupFormPage.js";
|
|
36
|
+
export { PriceGroupNewRoute } from "./components/klanten/pricegroups/PriceGroupNewRoute.js";
|
|
37
|
+
export { PriceGroupEditRoute } from "./components/klanten/pricegroups/PriceGroupEditRoute.js";
|
|
38
|
+
export { CustomerPriceGroupSelect } from "./components/klanten/pricegroups/CustomerPriceGroupSelect.js";
|
|
39
|
+
export { CustomerAssortmentTab } from "./components/klanten/CustomerAssortmentTab.js";
|
|
40
|
+
export { listCustomerAssortment } from "./lib/customer-assortment.functions.js";
|
|
41
|
+
export { loadFloridayCatalogPrices } from "./lib/floriday-catalog-prices.js";
|
|
42
|
+
export { FloridayPriceImportDialog } from "./components/klanten/FloridayPriceImportDialog.js";
|
|
43
|
+
export { CustomerStickerCell } from "./components/klanten/CustomerStickerCell.js";
|
|
44
|
+
export { CustomerStickerFormatDialog } from "./components/klanten/CustomerStickerFormatDialog.js";
|
|
45
|
+
export { BulkStickerUploadDialog } from "./components/klanten/BulkStickerUploadDialog.js";
|
|
46
|
+
export { listCustomerStickers, confirmStickerUpload, deleteCustomerSticker, getCustomerStickerSettings, setCustomerStickerSettings, getStickerForPrint, suggestStickerMatches, commitStickerBatch, discardStickerBatch, ALLOWED_STICKER_MIME, } from "./lib/customer-stickers.functions.js";
|
|
47
|
+
export { previewFloridayPriceImport, applyFloridayPriceImport, } from "./lib/floriday-price-import.functions.js";
|
|
48
|
+
export { getPriceGroupsForCustomer, setPriceGroupForCustomer, resolveCustomerKeyForLocalCustomer, listPriceGroupItemPrices, setPriceGroupItemPrice, } from "./lib/price-groups-local.functions.js";
|
|
49
|
+
export { PriceGroupItemPrices } from "./components/klanten/pricegroups/PriceGroupItemPrices.js";
|
|
50
|
+
export { listLogisticsStrategies, getLogisticsStrategyBinding, setLogisticsStrategyBinding, resolveLogisticsStrategy, } from "./lib/logistics-strategy.functions.js";
|
|
51
|
+
export { emitLogisticsEvent } from "./lib/logistics-events.functions.js";
|
|
52
52
|
export const floridayKlantenModule = {
|
|
53
53
|
id: "customers",
|
|
54
54
|
name: "Klanten",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// This file is automatically generated. Do not edit it directly.
|
|
2
2
|
import { createMiddleware } from '@tanstack/react-start';
|
|
3
|
-
import { supabase } from './client';
|
|
3
|
+
import { supabase } from './client.js';
|
|
4
4
|
// Must be registered as a global `functionMiddleware` in `src/start.ts`; otherwise
|
|
5
5
|
// the browser never attaches the bearer token to serverFn RPCs.
|
|
6
6
|
export const attachSupabaseAuth = createMiddleware({ type: 'function' }).client(async ({ next }) => {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { SupabaseClient } from '@supabase/supabase-js';
|
|
2
|
-
import type { Database } from './types';
|
|
2
|
+
import type { Database } from './types.js';
|
|
3
3
|
export interface AuthedSupabaseClient extends SupabaseClient<Database> {
|
|
4
4
|
}
|
|
5
5
|
export declare const requireSupabaseAuth: import("@tanstack/start-client-core").FunctionMiddlewareAfterServer<{}, unknown, undefined, {
|