Open-source manufacturing ERP, MES and QMS. Quoting, MRP, inventory, shop floor, quality and lot/serial traceability on one Postgres schema, with a REST API and MCP server. Self-host or use Carbon Cloud.
TypeScript ai-agentsbill-of-materialserpinventory-managementleanmanufacturingmanufacturing-execution-systemmcp-servermesmrpopen-source-erppostgresqlproduction-planningqmsquality-management-systemreact-routerself-hostedsupabasetraceabilitytypescript
Fixed Assets (#770)
Brad Barbin34878f41be55
diff --git a/apps/academy/app/components/Hero.tsx b/apps/academy/app/components/Hero.tsxindex bb9a3a274a..5a36cc1605 100644--- a/apps/academy/app/components/Hero.tsx+++ b/apps/academy/app/components/Hero.tsx@@ -1,6 +1,6 @@export function Hero({ children }: { children: React.ReactNode }) {return (- <div className="w-full bg-[linear-gradient(to_bottom_right,#f7f5ff_35.67%,#c9fff8_88.95%)] dark:bg-[linear-gradient(to_bottom_right,#0e0338_35.67%,#1b433e_88.95%)]">+ <div className="w-full bg-[linear-gradient(to_bottom_right,#ffffff_35.67%,#9ebeed_88.95%)] dark:bg-[linear-gradient(to_bottom_right,#0e0338_35.67%,#1b433e_88.95%)]"><div className="flex flex-col gap-6 w-full px-4 max-w-5xl mx-auto my-20 mb-28">{children}</div>diff --git a/apps/academy/app/root.tsx b/apps/academy/app/root.tsxindex d956073f27..32ac44fe60 100644--- a/apps/academy/app/root.tsx+++ b/apps/academy/app/root.tsx@@ -33,6 +33,7 @@ import type React from "react";import { LuChevronDown, LuFingerprint, LuMoon, LuSun } from "react-icons/lu";import type {ActionFunctionArgs,+ LinksFunction,LoaderFunctionArgs,MetaFunction} from "react-router";@@ -53,7 +54,6 @@ import { modules } from "~/config";import { getMode, setMode } from "~/services/mode.server";import NProgress from "~/styles/nprogress.css?url";import Tailwind from "~/styles/tailwind.css?url";-import type { Route } from "./+types/root";import AvatarMenu from "./components/AvatarMenu";import { useOptionalUser } from "./hooks/useUser";import { path } from "./utils/path";@@ -61,7 +61,7 @@ import { path } from "./utils/path";export const middleware = [flashMiddleware];export const clientMiddleware = [flashClientMiddleware];-export const links: Route.LinksFunction = () => [+export const links: LinksFunction = () => [{ rel: "stylesheet", href: Tailwind },{ rel: "stylesheet", href: NProgress }];@@ -443,9 +443,14 @@ export function ErrorBoundary({ error }: { error: unknown }) {<div className="light"><div className="flex flex-col w-full h-screen items-center justify-center space-y-4 "><img- src="/carbon-logo-mark.svg"+ src="/carbon-mark-light.svg"alt="Carbon Logo"- className="block max-w-[60px]"+ className="block max-w-[60px] dark:hidden"+ />+ <img+ src="/carbon-mark-dark.svg"+ alt="Carbon Logo"+ className="max-w-[60px] hidden dark:block"/><Heading size="h1">Something went wrong</Heading><p className="text-muted-foreground max-w-2xl">{message}</p>diff --git a/apps/academy/app/routes/_auth+/callback.tsx b/apps/academy/app/routes/_auth+/callback.tsxindex cdff15be70..6118eca0ac 100644--- a/apps/academy/app/routes/_auth+/callback.tsx+++ b/apps/academy/app/routes/_auth+/callback.tsx@@ -141,8 +141,17 @@ export default function AuthCallback() {return (<div className="flex flex-col items-center justify-center">- <div className="flex justify-center mb-4">- <img src="/carbon-logo-mark.svg" alt="Carbon Logo" className="w-36" />+ <div className="flex justify-center mb-8">+ <img+ src="/carbon-mark-light.svg"+ alt="Carbon Logo"+ className="w-24 dark:hidden"+ />+ <img+ src="/carbon-mark-dark.svg"+ alt="Carbon Logo"+ className="w-24 hidden dark:block"+ /></div>{error ? (<div className="rounded-lg md:bg-card md:border md:border-border md:shadow-lg p-8 mt-8 w-[380px]">@@ -166,12 +175,26 @@ export default function AuthCallback() {</VStack></div>) : (- <div className="hexagon-loader-container">- <div className="hexagon-loader">- <div className="hexagon" />- <div className="hexagon" />- <div className="hexagon" />- </div>+ <div className="flex items-end justify-center gap-1.5 h-8">+ {[0, 1, 2, 3, 4].map((i) => (+ <div+ key={i}+ className="w-1.5 rounded-sm bg-primary"+ style={{+ animationName: "loading-bars",+ animationDuration: "1.2s",+ animationTimingFunction: "ease-in-out",+ animationIterationCount: "infinite",+ animationDelay: `${i * 0.1}s`+ }}+ />+ ))}+ <style>+ {`@keyframes loading-bars {+ 0%, 100% { height: 8px; opacity: 0.3; }+ 50% { height: 32px; opacity: 1; }+ }`}+ </style></div>)}</div>diff --git a/apps/academy/app/routes/_auth+/login.tsx b/apps/academy/app/routes/_auth+/login.tsxindex 72294f8adf..0aa69a5281 100644--- a/apps/academy/app/routes/_auth+/login.tsx+++ b/apps/academy/app/routes/_auth+/login.tsx@@ -143,8 +143,17 @@ export default function LoginRoute() {return (<>- <div className="flex justify-center mb-4">- <img src="/carbon-logo-mark.svg" alt="Carbon Logo" className="w-36" />+ <div className="flex justify-center mb-8">+ <img+ src="/carbon-mark-light.svg"+ alt="Carbon Logo"+ className="w-24 dark:hidden"+ />+ <img+ src="/carbon-mark-dark.svg"+ alt="Carbon Logo"+ className="w-24 hidden dark:block"+ /></div><div className="rounded-lg md:bg-card md:border md:border-border md:shadow-lg p-8 w-[380px]">{fetcher.data?.success === true ? (diff --git a/apps/academy/app/routes/_auth+/request-access.tsx b/apps/academy/app/routes/_auth+/request-access.tsxindex 539861b2a4..d81f0918c7 100644--- a/apps/academy/app/routes/_auth+/request-access.tsx+++ b/apps/academy/app/routes/_auth+/request-access.tsx@@ -16,9 +16,14 @@ export default function RequestAccessRoute() {<><div className="flex flex-col items-center justify-center"><img- src="/carbon-logo-mark.svg"+ src="/carbon-mark-light.svg"alt="Carbon Logo"- className="w-36 mb-3"+ className="w-24 mb-3 dark:hidden"+ />+ <img+ src="/carbon-mark-dark.svg"+ alt="Carbon Logo"+ className="w-24 mb-3"/><h3 className="font-mono font-bold leading-loose uppercase text-xl">diff --git a/apps/academy/app/routes/about.tsx b/apps/academy/app/routes/about.tsxindex 338e96281c..48e8f247d2 100644--- a/apps/academy/app/routes/about.tsx+++ b/apps/academy/app/routes/about.tsx@@ -13,7 +13,7 @@ export default function AboutRoute() {<Hero><Headingsize="display"- className="font-display text-[#212578] dark:text-white max-w-2xl"+ className="font-display text-[#121212] dark:text-white max-w-2xl">Carbon Academy</Heading>@@ -58,7 +58,7 @@ export default function AboutRoute() {</h3><Headingsize="h1"- className="font-display text-[#212578] dark:text-white max-w-2xl"+ className="font-display text-[#121212] dark:text-white max-w-2xl">Register and Track Your Progress</Heading>@@ -80,7 +80,7 @@ export default function AboutRoute() {</h3><Headingsize="h1"- className="font-display text-[#212578] dark:text-white max-w-2xl"+ className="font-display text-[#121212] dark:text-white max-w-2xl">Take Challenges</Heading>diff --git a/apps/academy/app/routes/course+/_layout.tsx b/apps/academy/app/routes/course+/_layout.tsxindex 0384d9b5dc..c160f1c271 100644--- a/apps/academy/app/routes/course+/_layout.tsx+++ b/apps/academy/app/routes/course+/_layout.tsx@@ -14,7 +14,7 @@ export default function CourseLayout() {<Hero><Headingsize="h1"- className="font-display text-[#212578] dark:text-white max-w-xl"+ className="font-display text-[#121212] dark:text-white max-w-xl">Your Journey Starts Here</Heading>diff --git a/apps/academy/app/styles/tailwind.css b/apps/academy/app/styles/tailwind.cssindex ec58dcdc72..511c14c6da 100644--- a/apps/academy/app/styles/tailwind.css+++ b/apps/academy/app/styles/tailwind.css@@ -1,4 +1,4 @@-@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@700&display=swap");+@import url("https://fonts.googleapis.com/css2?family=DM+Sans:wght@700&display=swap");@import "tailwindcss";@import "non.geist";@import "non.geist/mono";@@ -14,10 +14,10 @@--popover-foreground: 240 10% 3.9%;--active: 240 5.9% 10%;--active-foreground: 0 0% 98%;- --primary: 239 57% 30%;+ --primary: 210 42% 9%;--primary-foreground: 0 0% 98%;- --secondary: 248 100% 63%;- --secondary-foreground: 248 5.9% 100%;+ --secondary: 219 93% 56%;+ --secondary-foreground: 219 88% 98%;--muted: 240 4.8% 95.9%;--muted-foreground: 240 3.8% 37.1%;--accent: 240 4.8% 95.9%;@@ -27,7 +27,7 @@--border: 240 5.9% 90%;--input: 240 5.9% 90%;--ring: 240 10% 3.9%;- --radius: 0.675rem;+ --radius: 0.5rem;--sidebar-background: 0 0% 98%;--sidebar-foreground: 240 5.3% 26.1%;--sidebar-primary: 240 5.9% 10%;@@ -68,8 +68,8 @@--primary-foreground: 220 5.9% 10%;--active: 0 0% 98%;--active-foreground: 220 5.9% 10%;- --secondary: 163 100% 69%;- --secondary-foreground: 163 88% 13%;+ --secondary: 163 93% 56%;+ --secondary-foreground: 163 88% 11%;--muted: 0 0% 13.6%;--muted-foreground: 0 0% 65%;--accent: 0 0% 7.6%;@@ -128,92 +128,9 @@}.font-display {- font-family: "Poppins", sans-serif;+ font-family: "DM Sans", sans-serif;}a.active {font-weight: 600;}--.hexagon-loader-container {- @apply relative w-full py-4;-}--.hexagon-loader {- position: relative;- display: flex;- justify-content: center;- align-items: center;- width: 100%;- height: 40px;-}--/* Three hexagon loading animation */-.hexagon {- display: inline-block;- position: relative;- width: 18px;- height: 10px;- background-color: #5fe4d3;- animation: hexloader 1.4s infinite ease-in-out;-}--.hexagon:before,-.hexagon:after {- content: "";- position: absolute;- width: 0;- border-left: 9px solid transparent;- border-right: 9px solid transparent;-}--.hexagon:before {- bottom: 100%;- border-bottom: 5px solid #5fe4d3;-}--.hexagon:after {- top: 100%;- border-top: 5px solid #5fe4d3;-}--.hexagon + .hexagon {- margin-left: 8px;- animation: hexloader 1.4s 0.2s infinite ease-in-out;- background-color: #4faade;-}--.hexagon + .hexagon:before {- border-bottom-color: #4faade;-}--.hexagon + .hexagon:after {- border-top-color: #4faade;-}--.hexagon + .hexagon + .hexagon {- margin-left: 8px;- animation: hexloader 1.4s 0.4s infinite ease-in-out;- background-color: #6041d0;-}--.hexagon + .hexagon + .hexagon:before {- border-bottom-color: #6041d0;-}--.hexagon + .hexagon + .hexagon:after {- border-top-color: #6041d0;-}--@keyframes hexloader {- 0%,- 80%,- 100% {- transform: scale(0.5);- opacity: 0;- }- 40% {- transform: scale(1);- opacity: 1;- }-}diff --git a/apps/academy/package.json b/apps/academy/package.jsonindex 81aa73c6e4..0850c07b7a 100644--- a/apps/academy/package.json+++ b/apps/academy/package.json@@ -56,7 +56,7 @@"scripts": {"build": "react-router build","clean": "rimraf .cache .turbo node_modules dist build",- "dev": "react-router dev",+ "dev": "NODE_EXTRA_CA_CERTS=$HOME/.portless/ca.pem react-router dev","lint": "biome lint --write","start": "react-router-serve ./build/server/index.js","typecheck": "tsgo --noEmit",diff --git a/apps/academy/public/android-chrome-192x192.png b/apps/academy/public/android-chrome-192x192.pngnew file mode 100644index 0000000000..bc936a17b0Binary files /dev/null and b/apps/academy/public/android-chrome-192x192.png differdiff --git a/apps/academy/public/android-chrome-512x512.png b/apps/academy/public/android-chrome-512x512.pngnew file mode 100644index 0000000000..841366bbf7Binary files /dev/null and b/apps/academy/public/android-chrome-512x512.png differdiff --git a/apps/academy/public/apple-touch-icon.png b/apps/academy/public/apple-touch-icon.pngindex 7d10fd7748..aadf41c525 100644Binary files a/apps/academy/public/apple-touch-icon.png and b/apps/academy/public/apple-touch-icon.png differdiff --git a/apps/academy/public/carbon-logo-mark.svg b/apps/academy/public/carbon-logo-mark.svgdeleted file mode 100644index 048049e1e5..0000000000--- a/apps/academy/public/carbon-logo-mark.svg+++ /dev/null@@ -1,20 +0,0 @@-<svg width="362" height="349" viewBox="0 0 362 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M181.165 139.643V69.8213L241.346 35.0564L241.054 104.878L181.165 139.643Z" fill="#60FFD2"/>-<path d="M181.165 69.8213V139.643L120.4 104.878V35.0564L181.165 69.8213Z" fill="#36B5B4"/>-<path d="M120.4 35.0565L181.165 69.8214L241.347 35.0565L181.165 -0.000610352L120.4 35.0565Z" fill="#5FE4D2"/>-<path d="M240.818 244.172V174.35L300.999 139.585L300.707 209.407L240.818 244.172Z" fill="#71DEFF"/>-<path d="M240.818 174.35V244.172L180.052 209.407V139.585L240.818 174.35Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.35L300.999 139.586L240.818 104.528L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.172V174.35L181.693 139.585L181.401 209.407L121.512 244.172Z" fill="#71DEFF"/>-<path d="M121.512 174.35V244.172L60.7466 209.407V139.585L121.512 174.35Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.35L181.694 139.586L121.512 104.528L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.701V278.879L241.346 244.114L241.054 313.936L181.165 348.701Z" fill="#7D7FE5"/>-<path d="M181.165 278.879V348.701L120.4 313.936V244.114L181.165 278.879Z" fill="#2F31AE"/>-<path d="M120.4 244.114L181.165 278.879L241.347 244.114L181.165 209.057L120.4 244.114Z" fill="#6041D0"/>-<path d="M60.7651 348.701V278.879L120.946 244.114L120.654 313.936L60.7651 348.701Z" fill="#7D7FE5"/>-<path d="M60.7656 278.879V348.701L0 313.936V244.114L60.7656 278.879Z" fill="#2F31AE"/>-<path d="M0 244.114L60.7656 278.879L120.947 244.114L60.7656 209.057L0 244.114Z" fill="#6041D0"/>-<path d="M301.017 348.701V278.879L361.198 244.114L360.906 313.936L301.017 348.701Z" fill="#7D7FE5"/>-<path d="M301.018 278.879V348.701L240.252 313.936V244.114L301.018 278.879Z" fill="#2F31AE"/>-<path d="M240.252 244.114L301.018 278.879L361.199 244.114L301.018 209.057L240.252 244.114Z" fill="#6041D0"/>-</svg>diff --git a/apps/academy/public/carbon-mark-dark.svg b/apps/academy/public/carbon-mark-dark.svgnew file mode 100644index 0000000000..047b926154--- /dev/null+++ b/apps/academy/public/carbon-mark-dark.svg@@ -0,0 +1,3 @@+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#E6E6E6"/>+</svg>diff --git a/apps/academy/public/carbon-mark-light.svg b/apps/academy/public/carbon-mark-light.svgnew file mode 100644index 0000000000..db0480c53c--- /dev/null+++ b/apps/academy/public/carbon-mark-light.svg@@ -0,0 +1,3 @@+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#101A24"/>+</svg>diff --git a/apps/academy/public/carbon-word-dark.svg b/apps/academy/public/carbon-word-dark.svgindex 45c24bd04c..c4463b4061 100644--- a/apps/academy/public/carbon-word-dark.svg+++ b/apps/academy/public/carbon-word-dark.svg@@ -1,26 +1,9 @@-<svg width="1583" height="349" viewBox="0 0 1583 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M415.286 183.266C415.286 163.658 419.276 146.558 427.256 131.966C435.236 117.146 446.294 105.746 460.43 97.766C474.566 89.558 490.754 85.454 508.994 85.454C532.478 85.454 551.858 91.382 567.134 103.238C582.638 114.866 593.012 131.282 598.256 152.486H546.614C543.878 144.278 539.204 137.894 532.592 133.334C526.208 128.546 518.228 126.152 508.652 126.152C494.972 126.152 484.142 131.168 476.162 141.2C468.182 151.004 464.192 165.026 464.192 183.266C464.192 201.278 468.182 215.3 476.162 225.332C484.142 235.136 494.972 240.038 508.652 240.038C528.032 240.038 540.686 231.374 546.614 214.046H598.256C593.012 234.566 582.638 250.868 567.134 262.952C551.63 275.036 532.25 281.078 508.994 281.078C490.754 281.078 474.566 277.088 460.43 269.108C446.294 260.9 435.236 249.5 427.256 234.908C419.276 220.088 415.286 202.874 415.286 183.266Z" fill="white"/>-<path d="M610.76 182.582C610.76 163.43 614.522 146.444 622.046 131.624C629.798 116.804 640.172 105.404 653.168 97.424C666.392 89.444 681.098 85.454 697.286 85.454C711.422 85.454 723.734 88.304 734.222 94.004C744.938 99.704 753.488 106.886 759.872 115.55V88.532H808.094V278H759.872V250.298C753.716 259.19 745.166 266.6 734.222 272.528C723.506 278.228 711.08 281.078 696.944 281.078C680.984 281.078 666.392 276.974 653.168 268.766C640.172 260.558 629.798 249.044 622.046 234.224C614.522 219.176 610.76 201.962 610.76 182.582ZM759.872 183.266C759.872 171.638 757.592 161.72 753.032 153.512C748.472 145.076 742.316 138.692 734.564 134.36C726.812 129.8 718.49 127.52 709.598 127.52C700.706 127.52 692.498 129.686 684.974 134.018C677.45 138.35 671.294 144.734 666.506 153.17C661.946 161.378 659.666 171.182 659.666 182.582C659.666 193.982 661.946 204.014 666.506 212.678C671.294 221.114 677.45 227.612 684.974 232.172C692.726 236.732 700.934 239.012 709.598 239.012C718.49 239.012 726.812 236.846 734.564 232.514C742.316 227.954 748.472 221.57 753.032 213.362C757.592 204.926 759.872 194.894 759.872 183.266Z" fill="white"/>-<path d="M892.478 117.944C898.634 107.912 906.614 100.046 916.418 94.346C926.45 88.646 937.85 85.796 950.618 85.796V136.07H937.964C922.916 136.07 911.516 139.604 903.764 146.672C896.24 153.74 892.478 166.052 892.478 183.608V278H844.598V88.532H892.478V117.944Z" fill="white"/>-<path d="M1020.49 116.234C1026.64 107.114 1035.08 99.704 1045.8 94.004C1056.74 88.304 1069.17 85.454 1083.07 85.454C1099.26 85.454 1113.85 89.444 1126.85 97.424C1140.07 105.404 1150.45 116.804 1157.97 131.624C1165.72 146.216 1169.6 163.202 1169.6 182.582C1169.6 201.962 1165.72 219.176 1157.97 234.224C1150.45 249.044 1140.07 260.558 1126.85 268.766C1113.85 276.974 1099.26 281.078 1083.07 281.078C1068.94 281.078 1056.51 278.342 1045.8 272.87C1035.31 267.17 1026.87 259.874 1020.49 250.982V278H972.607V24.92H1020.49V116.234ZM1120.69 182.582C1120.69 171.182 1118.3 161.378 1113.51 153.17C1108.95 144.734 1102.8 138.35 1095.04 134.018C1087.52 129.686 1079.31 127.52 1070.42 127.52C1061.76 127.52 1053.55 129.8 1045.8 134.36C1038.27 138.692 1032.12 145.076 1027.33 153.512C1022.77 161.948 1020.49 171.866 1020.49 183.266C1020.49 194.666 1022.77 204.584 1027.33 213.02C1032.12 221.456 1038.27 227.954 1045.8 232.514C1053.55 236.846 1061.76 239.012 1070.42 239.012C1079.31 239.012 1087.52 236.732 1095.04 232.172C1102.8 227.612 1108.95 221.114 1113.51 212.678C1118.3 204.242 1120.69 194.21 1120.69 182.582Z" fill="white"/>-<path d="M1278.26 281.078C1260.02 281.078 1243.61 277.088 1229.02 269.108C1214.42 260.9 1202.91 249.386 1194.47 234.566C1186.27 219.746 1182.16 202.646 1182.16 183.266C1182.16 163.886 1186.38 146.786 1194.82 131.966C1203.48 117.146 1215.22 105.746 1230.04 97.766C1244.86 89.558 1261.39 85.454 1279.63 85.454C1297.87 85.454 1314.4 89.558 1329.22 97.766C1344.04 105.746 1355.67 117.146 1364.11 131.966C1372.77 146.786 1377.1 163.886 1377.1 183.266C1377.1 202.646 1372.66 219.746 1363.76 234.566C1355.1 249.386 1343.24 260.9 1328.2 269.108C1313.38 277.088 1296.73 281.078 1278.26 281.078ZM1278.26 239.354C1286.93 239.354 1295.02 237.302 1302.55 233.198C1310.3 228.866 1316.45 222.482 1321.01 214.046C1325.57 205.61 1327.85 195.35 1327.85 183.266C1327.85 165.254 1323.07 151.46 1313.49 141.884C1304.14 132.08 1292.63 127.178 1278.95 127.178C1265.27 127.178 1253.75 132.08 1244.41 141.884C1235.29 151.46 1230.73 165.254 1230.73 183.266C1230.73 201.278 1235.17 215.186 1244.06 224.99C1253.18 234.566 1264.58 239.354 1278.26 239.354Z" fill="white"/>-<path d="M1506.96 85.796C1529.53 85.796 1547.77 92.978 1561.68 107.342C1575.59 121.478 1582.54 141.314 1582.54 166.85V278H1534.66V173.348C1534.66 158.3 1530.9 146.786 1523.37 138.806C1515.85 130.598 1505.59 126.494 1492.59 126.494C1479.37 126.494 1468.88 130.598 1461.13 138.806C1453.61 146.786 1449.84 158.3 1449.84 173.348V278H1401.96V88.532H1449.84V112.13C1456.23 103.922 1464.32 97.538 1474.13 92.978C1484.16 88.19 1495.1 85.796 1506.96 85.796Z" fill="white"/>-<path d="M181.165 139.644V69.822L241.346 35.0571L241.054 104.879L181.165 139.644Z" fill="#60FFD2"/>-<path d="M181.165 69.822V139.644L120.4 104.879V35.0571L181.165 69.822Z" fill="#36B5B4"/>-<path d="M120.4 35.0571L181.165 69.822L241.346 35.0571L181.165 0L120.4 35.0571Z" fill="#5FE4D2"/>-<path d="M240.818 244.173V174.351L300.999 139.586L300.707 209.408L240.818 244.173Z" fill="#71DEFF"/>-<path d="M240.818 174.351V244.173L180.052 209.408V139.586L240.818 174.351Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.351L300.999 139.586L240.818 104.529L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.173V174.351L181.693 139.586L181.401 209.408L121.512 244.173Z" fill="#71DEFF"/>-<path d="M121.512 174.351V244.173L60.7466 209.408V139.586L121.512 174.351Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.351L181.693 139.586L121.512 104.529L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.702V278.88L241.346 244.115L241.054 313.937L181.165 348.702Z" fill="#7D7FE5"/>-<path d="M181.165 278.88V348.702L120.4 313.937V244.115L181.165 278.88Z" fill="#2F31AE"/>-<path d="M120.4 244.115L181.165 278.88L241.346 244.115L181.165 209.057L120.4 244.115Z" fill="#6041D0"/>-<path d="M60.7652 348.702V278.88L120.947 244.115L120.654 313.937L60.7652 348.702Z" fill="#7D7FE5"/>-<path d="M60.7652 278.88V348.702L0 313.937V244.115L60.7652 278.88Z" fill="#2F31AE"/>-<path d="M0 244.115L60.7652 278.88L120.947 244.115L60.7656 209.057L0 244.115Z" fill="#6041D0"/>-<path d="M301.017 348.702V278.88L361.198 244.115L360.906 313.937L301.017 348.702Z" fill="#7D7FE5"/>-<path d="M301.017 278.88V348.702L240.252 313.937V244.115L301.017 278.88Z" fill="#2F31AE"/>-<path d="M240.252 244.115L301.017 278.88L361.198 244.115L301.018 209.057L240.252 244.115Z" fill="#6041D0"/>+<svg width="720" height="175" viewBox="0 0 720 175" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M64.2993 3.57443C72.343 -1.19144 82.3494 -1.19151 90.3931 3.57443L142.163 34.2484C149.93 38.8505 154.692 47.2038 154.692 56.2254V118.775C154.692 127.796 149.93 136.149 142.163 140.752L90.3931 171.426C82.3494 176.192 72.343 176.191 64.2993 171.426L12.5296 140.752C4.76242 136.149 0 127.796 0 118.775V56.2254C0 47.2037 4.76242 38.8505 12.5296 34.2484L64.2993 3.57443ZM81.004 40.286C78.8708 39.0012 76.2016 38.9983 74.0657 40.2786L42.6851 59.0884C38.3192 61.7055 38.3303 68.0312 42.7057 70.6326L74.173 89.3408C74.3089 89.4216 74.3921 89.5681 74.3921 89.726V126.818C74.3922 132.04 80.0912 135.269 84.5774 132.589L115.594 114.057C117.626 112.843 118.87 110.652 118.87 108.287V66.8923C118.87 64.5357 117.635 62.3509 115.615 61.134L81.004 40.286Z" fill="#E6E6E6"/>+<path d="M236.385 133.457C229.22 133.457 222.857 132.223 217.298 129.754C211.862 127.163 207.291 123.645 203.584 119.202C200.002 114.635 197.284 109.513 195.431 103.836C193.577 98.1581 192.651 92.2338 192.651 86.0626C192.651 79.8914 193.577 73.9671 195.431 68.2897C197.284 62.6122 200.002 57.5518 203.584 53.1086C207.291 48.6654 211.862 45.2095 217.298 42.741C222.857 40.1492 229.22 38.8532 236.385 38.8532C245.404 38.8532 253.249 41.0131 259.921 45.3329C266.716 49.6528 271.719 56.3176 274.931 65.3275L256.77 72.3626C255.288 67.6725 252.879 63.9081 249.543 61.0694C246.207 58.1072 241.821 56.6262 236.385 56.6262C230.95 56.6262 226.502 58.0455 223.043 60.8843C219.707 63.723 217.236 67.364 215.63 71.8072C214.024 76.2505 213.221 81.0023 213.221 86.0626C213.221 91.123 214.024 95.9365 215.63 100.503C217.236 104.946 219.707 108.587 223.043 111.426C226.502 114.141 230.95 115.499 236.385 115.499C241.821 115.499 246.207 114.08 249.543 111.241C252.879 108.402 255.288 104.638 256.77 99.9477L274.931 106.983C271.719 115.869 266.716 122.534 259.921 126.977C253.249 131.297 245.404 133.457 236.385 133.457Z" fill="#E6E6E6"/>+<path d="M343.217 131.791L341.735 116.425V74.214C341.735 68.2897 339.943 63.8464 336.361 60.8843C332.778 57.7987 327.774 56.2559 321.35 56.2559C316.408 56.2559 311.528 57.2433 306.71 59.218C302.015 61.0694 297.691 63.9698 293.738 67.9194L282.248 54.4045C288.178 48.8505 294.479 44.901 301.151 42.5559C307.822 40.0874 315.111 38.8532 323.018 38.8532C335.372 38.8532 344.947 42.0005 351.742 48.2951C358.66 54.4663 362.12 63.1059 362.12 74.214V131.791H343.217ZM314.864 133.457C308.069 133.457 302.015 132.223 296.703 129.754C291.514 127.286 287.437 123.83 284.472 119.387C281.631 114.944 280.21 109.76 280.21 103.836C280.21 98.7752 281.26 94.3937 283.36 90.691C285.584 86.9883 288.426 84.0878 291.885 81.9896C294.85 80.1383 298.309 78.8423 302.262 78.1018C306.216 77.2378 310.355 76.8059 314.679 76.8059H343.403V92.1721H317.644C315.42 92.1721 313.196 92.4189 310.972 92.9126C308.749 93.2829 306.772 94.0234 305.042 95.1342C303.807 96.1216 302.757 97.3558 301.892 98.8369C301.151 100.318 300.78 102.046 300.78 104.021C300.78 107.97 302.262 111.118 305.228 113.463C308.316 115.684 312.393 116.795 317.458 116.795C321.906 116.795 325.921 115.808 329.504 113.833C333.21 111.858 336.175 109.143 338.399 105.687C340.623 102.231 341.735 98.3432 341.735 94.0234L348.036 104.206C346.553 110.624 344.206 116.054 340.994 120.498C337.781 124.818 333.952 128.088 329.504 130.31C325.056 132.408 320.176 133.457 314.864 133.457Z" fill="#E6E6E6"/>+<path d="M375.823 131.791V40.5194H396.578V65.1424L392.687 65.6978C393.304 60.3906 395.096 55.7622 398.061 51.8127C401.026 47.7397 404.609 44.5924 408.809 42.3708C413.133 40.0257 417.395 38.8532 421.596 38.8532C424.561 38.8532 427.403 39.2235 430.121 39.964C432.839 40.7046 435.68 41.9388 438.645 43.6667L428.638 62.1802C427.279 61.3162 425.488 60.6374 423.264 60.1437C421.164 59.5266 419.125 59.218 417.148 59.218C414.554 59.218 411.96 59.7117 409.365 60.6991C406.894 61.6865 404.67 63.2293 402.694 65.3275C400.717 67.3023 399.234 69.8942 398.246 73.1032C397.628 74.8311 397.134 77.1144 396.764 79.9532C396.517 82.6685 396.393 86.4946 396.393 91.4315V131.791H375.823Z" fill="#E6E6E6"/>+<path d="M492.002 133.457C487.06 133.457 482.365 132.47 477.918 130.495C473.594 128.52 469.825 125.496 466.613 121.423C463.401 117.227 460.992 111.796 459.386 105.132L464.76 106.427V131.791H444.375V2.75192H464.76V66.068H460.127C461.363 60.2672 463.463 55.3919 466.428 51.4424C469.517 47.3694 473.223 44.2838 477.547 42.1856C481.995 39.964 486.813 38.8532 492.002 38.8532C499.414 38.8532 506.086 40.7663 512.016 44.5924C518.069 48.2951 522.888 53.664 526.47 60.6991C530.053 67.7343 531.845 76.1887 531.845 86.0626C531.845 95.0725 530.177 103.157 526.841 110.315C523.629 117.474 519.058 123.151 513.128 127.348C507.198 131.421 500.156 133.457 492.002 133.457ZM486.998 114.573C491.816 114.573 496.017 113.401 499.6 111.056C503.306 108.711 506.147 105.378 508.124 101.059C510.101 96.7387 511.089 91.7401 511.089 86.0626C511.089 80.3851 510.101 75.3865 508.124 71.0667C506.147 66.7469 503.306 63.4144 499.6 61.0694C496.017 58.7244 491.816 57.5518 486.998 57.5518C482.18 57.5518 477.918 58.7861 474.211 61.2545C470.629 63.5996 467.849 66.932 465.872 71.2518C463.895 75.4482 462.907 80.3851 462.907 86.0626C462.907 91.7401 463.895 96.7387 465.872 101.059C467.849 105.378 470.629 108.711 474.211 111.056C477.918 113.401 482.18 114.573 486.998 114.573Z" fill="#E6E6E6"/>+<path d="M583.567 133.457C574.919 133.457 567.135 131.421 560.217 127.348C553.298 123.275 547.862 117.659 543.909 110.5C540.079 103.342 538.164 95.1959 538.164 86.0626C538.164 76.9293 540.079 68.7834 543.909 61.6248C547.862 54.4663 553.237 48.9122 560.032 44.9627C566.95 40.8897 574.795 38.8532 583.567 38.8532C592.462 38.8532 600.245 40.8897 606.917 44.9627C613.711 48.9122 619.086 54.4663 623.039 61.6248C626.992 68.7834 628.969 76.9293 628.969 86.0626C628.969 95.1959 626.992 103.342 623.039 110.5C619.209 117.659 613.835 123.275 606.917 127.348C600.122 131.421 592.338 133.457 583.567 133.457ZM583.752 115.314C588.817 115.314 593.203 114.141 596.909 111.796C600.616 109.451 603.457 106.057 605.434 101.614C607.411 97.1707 608.399 91.9869 608.399 86.0626C608.399 80.0149 607.411 74.8311 605.434 70.5113C603.457 66.068 600.616 62.6739 596.909 60.3289C593.203 57.9838 588.817 56.8113 583.752 56.8113C578.44 56.8113 573.93 58.0455 570.224 60.514C566.518 62.859 563.676 66.1915 561.699 70.5113C559.723 74.8311 558.734 80.0149 558.734 86.0626C558.734 91.9869 559.723 97.1707 561.699 101.614C563.676 106.057 566.518 109.451 570.224 111.796C573.93 114.141 578.44 115.314 583.752 115.314Z" fill="#E6E6E6"/>+<path d="M639.573 131.791V40.5194H660.143V60.6991L656.437 61.6248C658.043 56.3176 660.39 51.9978 663.479 48.6654C666.567 45.3329 670.15 42.8645 674.227 41.26C678.427 39.6555 682.813 38.8532 687.384 38.8532C697.639 38.8532 705.607 41.8154 711.29 47.7397C717.097 53.5406 720 61.8716 720 72.7329V131.791H699.43V80.3234C699.43 72.1775 697.947 66.1915 694.982 62.3653C692.017 58.5392 687.446 56.6262 681.269 56.6262C676.698 56.6262 672.806 57.737 669.594 59.9586C666.505 62.0568 664.158 65.3892 662.552 69.9559C660.946 74.5225 660.143 80.3234 660.143 87.3585V131.791H639.573Z" fill="#E6E6E6"/></svg>diff --git a/apps/academy/public/carbon-word-light.svg b/apps/academy/public/carbon-word-light.svgindex 0aba9da4d8..3fd85675c9 100644--- a/apps/academy/public/carbon-word-light.svg+++ b/apps/academy/public/carbon-word-light.svg@@ -1,26 +1,9 @@-<svg width="1583" height="349" viewBox="0 0 1583 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M415.286 183.266C415.286 163.658 419.276 146.558 427.256 131.966C435.236 117.146 446.294 105.746 460.43 97.766C474.566 89.558 490.754 85.454 508.994 85.454C532.478 85.454 551.858 91.382 567.134 103.238C582.638 114.866 593.012 131.282 598.256 152.486H546.614C543.878 144.278 539.204 137.894 532.592 133.334C526.208 128.546 518.228 126.152 508.652 126.152C494.972 126.152 484.142 131.168 476.162 141.2C468.182 151.004 464.192 165.026 464.192 183.266C464.192 201.278 468.182 215.3 476.162 225.332C484.142 235.136 494.972 240.038 508.652 240.038C528.032 240.038 540.686 231.374 546.614 214.046H598.256C593.012 234.566 582.638 250.868 567.134 262.952C551.63 275.036 532.25 281.078 508.994 281.078C490.754 281.078 474.566 277.088 460.43 269.108C446.294 260.9 435.236 249.5 427.256 234.908C419.276 220.088 415.286 202.874 415.286 183.266Z" fill="#212278"/>-<path d="M610.76 182.582C610.76 163.43 614.522 146.444 622.046 131.624C629.798 116.804 640.172 105.404 653.168 97.424C666.392 89.444 681.098 85.454 697.286 85.454C711.422 85.454 723.734 88.304 734.222 94.004C744.938 99.704 753.488 106.886 759.872 115.55V88.532H808.094V278H759.872V250.298C753.716 259.19 745.166 266.6 734.222 272.528C723.506 278.228 711.08 281.078 696.944 281.078C680.984 281.078 666.392 276.974 653.168 268.766C640.172 260.558 629.798 249.044 622.046 234.224C614.522 219.176 610.76 201.962 610.76 182.582ZM759.872 183.266C759.872 171.638 757.592 161.72 753.032 153.512C748.472 145.076 742.316 138.692 734.564 134.36C726.812 129.8 718.49 127.52 709.598 127.52C700.706 127.52 692.498 129.686 684.974 134.018C677.45 138.35 671.294 144.734 666.506 153.17C661.946 161.378 659.666 171.182 659.666 182.582C659.666 193.982 661.946 204.014 666.506 212.678C671.294 221.114 677.45 227.612 684.974 232.172C692.726 236.732 700.934 239.012 709.598 239.012C718.49 239.012 726.812 236.846 734.564 232.514C742.316 227.954 748.472 221.57 753.032 213.362C757.592 204.926 759.872 194.894 759.872 183.266Z" fill="#212278"/>-<path d="M892.478 117.944C898.634 107.912 906.614 100.046 916.418 94.346C926.45 88.646 937.85 85.796 950.618 85.796V136.07H937.964C922.916 136.07 911.516 139.604 903.764 146.672C896.24 153.74 892.478 166.052 892.478 183.608V278H844.598V88.532H892.478V117.944Z" fill="#212278"/>-<path d="M1020.49 116.234C1026.64 107.114 1035.08 99.704 1045.8 94.004C1056.74 88.304 1069.17 85.454 1083.07 85.454C1099.26 85.454 1113.85 89.444 1126.85 97.424C1140.07 105.404 1150.45 116.804 1157.97 131.624C1165.72 146.216 1169.6 163.202 1169.6 182.582C1169.6 201.962 1165.72 219.176 1157.97 234.224C1150.45 249.044 1140.07 260.558 1126.85 268.766C1113.85 276.974 1099.26 281.078 1083.07 281.078C1068.94 281.078 1056.51 278.342 1045.8 272.87C1035.31 267.17 1026.87 259.874 1020.49 250.982V278H972.607V24.92H1020.49V116.234ZM1120.69 182.582C1120.69 171.182 1118.3 161.378 1113.51 153.17C1108.95 144.734 1102.8 138.35 1095.04 134.018C1087.52 129.686 1079.31 127.52 1070.42 127.52C1061.76 127.52 1053.55 129.8 1045.8 134.36C1038.27 138.692 1032.12 145.076 1027.33 153.512C1022.77 161.948 1020.49 171.866 1020.49 183.266C1020.49 194.666 1022.77 204.584 1027.33 213.02C1032.12 221.456 1038.27 227.954 1045.8 232.514C1053.55 236.846 1061.76 239.012 1070.42 239.012C1079.31 239.012 1087.52 236.732 1095.04 232.172C1102.8 227.612 1108.95 221.114 1113.51 212.678C1118.3 204.242 1120.69 194.21 1120.69 182.582Z" fill="#212278"/>-<path d="M1278.26 281.078C1260.02 281.078 1243.61 277.088 1229.02 269.108C1214.42 260.9 1202.91 249.386 1194.47 234.566C1186.27 219.746 1182.16 202.646 1182.16 183.266C1182.16 163.886 1186.38 146.786 1194.82 131.966C1203.48 117.146 1215.22 105.746 1230.04 97.766C1244.86 89.558 1261.39 85.454 1279.63 85.454C1297.87 85.454 1314.4 89.558 1329.22 97.766C1344.04 105.746 1355.67 117.146 1364.11 131.966C1372.77 146.786 1377.1 163.886 1377.1 183.266C1377.1 202.646 1372.66 219.746 1363.76 234.566C1355.1 249.386 1343.24 260.9 1328.2 269.108C1313.38 277.088 1296.73 281.078 1278.26 281.078ZM1278.26 239.354C1286.93 239.354 1295.02 237.302 1302.55 233.198C1310.3 228.866 1316.45 222.482 1321.01 214.046C1325.57 205.61 1327.85 195.35 1327.85 183.266C1327.85 165.254 1323.07 151.46 1313.49 141.884C1304.14 132.08 1292.63 127.178 1278.95 127.178C1265.27 127.178 1253.75 132.08 1244.41 141.884C1235.29 151.46 1230.73 165.254 1230.73 183.266C1230.73 201.278 1235.17 215.186 1244.06 224.99C1253.18 234.566 1264.58 239.354 1278.26 239.354Z" fill="#212278"/>-<path d="M1506.96 85.796C1529.53 85.796 1547.77 92.978 1561.68 107.342C1575.59 121.478 1582.54 141.314 1582.54 166.85V278H1534.66V173.348C1534.66 158.3 1530.9 146.786 1523.37 138.806C1515.85 130.598 1505.59 126.494 1492.59 126.494C1479.37 126.494 1468.88 130.598 1461.13 138.806C1453.61 146.786 1449.84 158.3 1449.84 173.348V278H1401.96V88.532H1449.84V112.13C1456.23 103.922 1464.32 97.538 1474.13 92.978C1484.16 88.19 1495.1 85.796 1506.96 85.796Z" fill="#212278"/>-<path d="M181.165 139.644V69.822L241.346 35.0571L241.054 104.879L181.165 139.644Z" fill="#60FFD2"/>-<path d="M181.165 69.822V139.644L120.4 104.879V35.0571L181.165 69.822Z" fill="#36B5B4"/>-<path d="M120.4 35.0571L181.165 69.822L241.346 35.0571L181.165 0L120.4 35.0571Z" fill="#5FE4D2"/>-<path d="M240.818 244.173V174.351L300.999 139.586L300.707 209.408L240.818 244.173Z" fill="#71DEFF"/>-<path d="M240.818 174.351V244.173L180.052 209.408V139.586L240.818 174.351Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.351L300.999 139.586L240.818 104.529L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.173V174.351L181.693 139.586L181.401 209.408L121.512 244.173Z" fill="#71DEFF"/>-<path d="M121.512 174.351V244.173L60.7466 209.408V139.586L121.512 174.351Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.351L181.693 139.586L121.512 104.529L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.702V278.88L241.346 244.115L241.054 313.937L181.165 348.702Z" fill="#7D7FE5"/>-<path d="M181.165 278.88V348.702L120.4 313.937V244.115L181.165 278.88Z" fill="#2F31AE"/>-<path d="M120.4 244.115L181.165 278.88L241.346 244.115L181.165 209.057L120.4 244.115Z" fill="#6041D0"/>-<path d="M60.7652 348.702V278.88L120.947 244.115L120.654 313.937L60.7652 348.702Z" fill="#7D7FE5"/>-<path d="M60.7652 278.88V348.702L0 313.937V244.115L60.7652 278.88Z" fill="#2F31AE"/>-<path d="M0 244.115L60.7652 278.88L120.947 244.115L60.7656 209.057L0 244.115Z" fill="#6041D0"/>-<path d="M301.017 348.702V278.88L361.198 244.115L360.906 313.937L301.017 348.702Z" fill="#7D7FE5"/>-<path d="M301.017 278.88V348.702L240.252 313.937V244.115L301.017 278.88Z" fill="#2F31AE"/>-<path d="M240.252 244.115L301.017 278.88L361.198 244.115L301.018 209.057L240.252 244.115Z" fill="#6041D0"/>+<svg width="720" height="175" viewBox="0 0 720 175" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M64.2993 3.57443C72.343 -1.19144 82.3494 -1.19151 90.3931 3.57443L142.163 34.2484C149.93 38.8505 154.692 47.2038 154.692 56.2254V118.775C154.692 127.796 149.93 136.149 142.163 140.752L90.3931 171.426C82.3494 176.192 72.343 176.191 64.2993 171.426L12.5296 140.752C4.76242 136.149 0 127.796 0 118.775V56.2254C0 47.2037 4.76242 38.8505 12.5296 34.2484L64.2993 3.57443ZM81.004 40.286C78.8708 39.0012 76.2016 38.9983 74.0657 40.2786L42.6851 59.0884C38.3192 61.7055 38.3303 68.0312 42.7057 70.6326L74.173 89.3408C74.3089 89.4216 74.3921 89.5681 74.3921 89.726V126.818C74.3922 132.04 80.0912 135.269 84.5774 132.589L115.594 114.057C117.626 112.843 118.87 110.652 118.87 108.287V66.8923C118.87 64.5357 117.635 62.3509 115.615 61.134L81.004 40.286Z" fill="#101A24"/>+<path d="M236.385 133.457C229.22 133.457 222.857 132.223 217.298 129.754C211.862 127.163 207.291 123.645 203.584 119.202C200.002 114.635 197.284 109.513 195.431 103.836C193.577 98.1581 192.651 92.2338 192.651 86.0626C192.651 79.8914 193.577 73.9671 195.431 68.2897C197.284 62.6122 200.002 57.5518 203.584 53.1086C207.291 48.6654 211.862 45.2095 217.298 42.741C222.857 40.1492 229.22 38.8532 236.385 38.8532C245.404 38.8532 253.249 41.0131 259.921 45.3329C266.716 49.6528 271.719 56.3176 274.931 65.3275L256.77 72.3626C255.288 67.6725 252.879 63.9081 249.543 61.0694C246.207 58.1072 241.821 56.6262 236.385 56.6262C230.95 56.6262 226.502 58.0455 223.043 60.8843C219.707 63.723 217.236 67.364 215.63 71.8072C214.024 76.2505 213.221 81.0023 213.221 86.0626C213.221 91.123 214.024 95.9365 215.63 100.503C217.236 104.946 219.707 108.587 223.043 111.426C226.502 114.141 230.95 115.499 236.385 115.499C241.821 115.499 246.207 114.08 249.543 111.241C252.879 108.402 255.288 104.638 256.77 99.9477L274.931 106.983C271.719 115.869 266.716 122.534 259.921 126.977C253.249 131.297 245.404 133.457 236.385 133.457Z" fill="#101A24"/>+<path d="M343.217 131.791L341.735 116.425V74.214C341.735 68.2897 339.943 63.8464 336.361 60.8843C332.778 57.7987 327.774 56.2559 321.35 56.2559C316.408 56.2559 311.528 57.2433 306.71 59.218C302.015 61.0694 297.691 63.9698 293.738 67.9194L282.248 54.4045C288.178 48.8505 294.479 44.901 301.151 42.5559C307.822 40.0874 315.111 38.8532 323.018 38.8532C335.372 38.8532 344.947 42.0005 351.742 48.2951C358.66 54.4663 362.12 63.1059 362.12 74.214V131.791H343.217ZM314.864 133.457C308.069 133.457 302.015 132.223 296.703 129.754C291.514 127.286 287.437 123.83 284.472 119.387C281.631 114.944 280.21 109.76 280.21 103.836C280.21 98.7752 281.26 94.3937 283.36 90.691C285.584 86.9883 288.426 84.0878 291.885 81.9896C294.85 80.1383 298.309 78.8423 302.262 78.1018C306.216 77.2378 310.355 76.8059 314.679 76.8059H343.403V92.1721H317.644C315.42 92.1721 313.196 92.4189 310.972 92.9126C308.749 93.2829 306.772 94.0234 305.042 95.1342C303.807 96.1216 302.757 97.3558 301.892 98.8369C301.151 100.318 300.78 102.046 300.78 104.021C300.78 107.97 302.262 111.118 305.228 113.463C308.316 115.684 312.393 116.795 317.458 116.795C321.906 116.795 325.921 115.808 329.504 113.833C333.21 111.858 336.175 109.143 338.399 105.687C340.623 102.231 341.735 98.3432 341.735 94.0234L348.036 104.206C346.553 110.624 344.206 116.054 340.994 120.498C337.781 124.818 333.952 128.088 329.504 130.31C325.056 132.408 320.176 133.457 314.864 133.457Z" fill="#101A24"/>+<path d="M375.823 131.791V40.5194H396.578V65.1424L392.687 65.6978C393.304 60.3906 395.096 55.7622 398.061 51.8127C401.026 47.7397 404.609 44.5924 408.809 42.3708C413.133 40.0257 417.395 38.8532 421.596 38.8532C424.561 38.8532 427.403 39.2235 430.121 39.964C432.839 40.7046 435.68 41.9388 438.645 43.6667L428.638 62.1802C427.279 61.3162 425.488 60.6374 423.264 60.1437C421.164 59.5266 419.125 59.218 417.148 59.218C414.554 59.218 411.96 59.7117 409.365 60.6991C406.894 61.6865 404.67 63.2293 402.694 65.3275C400.717 67.3023 399.234 69.8942 398.246 73.1032C397.628 74.8311 397.134 77.1144 396.764 79.9532C396.517 82.6685 396.393 86.4946 396.393 91.4315V131.791H375.823Z" fill="#101A24"/>+<path d="M492.002 133.457C487.06 133.457 482.365 132.47 477.918 130.495C473.594 128.52 469.825 125.496 466.613 121.423C463.401 117.227 460.992 111.796 459.386 105.132L464.76 106.427V131.791H444.375V2.75192H464.76V66.068H460.127C461.363 60.2672 463.463 55.3919 466.428 51.4424C469.517 47.3694 473.223 44.2838 477.547 42.1856C481.995 39.964 486.813 38.8532 492.002 38.8532C499.414 38.8532 506.086 40.7663 512.016 44.5924C518.069 48.2951 522.888 53.664 526.47 60.6991C530.053 67.7343 531.845 76.1887 531.845 86.0626C531.845 95.0725 530.177 103.157 526.841 110.315C523.629 117.474 519.058 123.151 513.128 127.348C507.198 131.421 500.156 133.457 492.002 133.457ZM486.998 114.573C491.816 114.573 496.017 113.401 499.6 111.056C503.306 108.711 506.147 105.378 508.124 101.059C510.101 96.7387 511.089 91.7401 511.089 86.0626C511.089 80.3851 510.101 75.3865 508.124 71.0667C506.147 66.7469 503.306 63.4144 499.6 61.0694C496.017 58.7244 491.816 57.5518 486.998 57.5518C482.18 57.5518 477.918 58.7861 474.211 61.2545C470.629 63.5996 467.849 66.932 465.872 71.2518C463.895 75.4482 462.907 80.3851 462.907 86.0626C462.907 91.7401 463.895 96.7387 465.872 101.059C467.849 105.378 470.629 108.711 474.211 111.056C477.918 113.401 482.18 114.573 486.998 114.573Z" fill="#101A24"/>+<path d="M583.567 133.457C574.919 133.457 567.135 131.421 560.217 127.348C553.298 123.275 547.862 117.659 543.909 110.5C540.079 103.342 538.164 95.1959 538.164 86.0626C538.164 76.9293 540.079 68.7834 543.909 61.6248C547.862 54.4663 553.237 48.9122 560.032 44.9627C566.95 40.8897 574.795 38.8532 583.567 38.8532C592.462 38.8532 600.245 40.8897 606.917 44.9627C613.711 48.9122 619.086 54.4663 623.039 61.6248C626.992 68.7834 628.969 76.9293 628.969 86.0626C628.969 95.1959 626.992 103.342 623.039 110.5C619.209 117.659 613.835 123.275 606.917 127.348C600.122 131.421 592.338 133.457 583.567 133.457ZM583.752 115.314C588.817 115.314 593.203 114.141 596.909 111.796C600.616 109.451 603.457 106.057 605.434 101.614C607.411 97.1707 608.399 91.9869 608.399 86.0626C608.399 80.0149 607.411 74.8311 605.434 70.5113C603.457 66.068 600.616 62.6739 596.909 60.3289C593.203 57.9838 588.817 56.8113 583.752 56.8113C578.44 56.8113 573.93 58.0455 570.224 60.514C566.518 62.859 563.676 66.1915 561.699 70.5113C559.723 74.8311 558.734 80.0149 558.734 86.0626C558.734 91.9869 559.723 97.1707 561.699 101.614C563.676 106.057 566.518 109.451 570.224 111.796C573.93 114.141 578.44 115.314 583.752 115.314Z" fill="#101A24"/>+<path d="M639.573 131.791V40.5194H660.143V60.6991L656.437 61.6248C658.043 56.3176 660.39 51.9978 663.479 48.6654C666.567 45.3329 670.15 42.8645 674.227 41.26C678.427 39.6555 682.813 38.8532 687.384 38.8532C697.639 38.8532 705.607 41.8154 711.29 47.7397C717.097 53.5406 720 61.8716 720 72.7329V131.791H699.43V80.3234C699.43 72.1775 697.947 66.1915 694.982 62.3653C692.017 58.5392 687.446 56.6262 681.269 56.6262C676.698 56.6262 672.806 57.737 669.594 59.9586C666.505 62.0568 664.158 65.3892 662.552 69.9559C660.946 74.5225 660.143 80.3234 660.143 87.3585V131.791H639.573Z" fill="#101A24"/></svg>diff --git a/apps/academy/public/favicon-16x16.png b/apps/academy/public/favicon-16x16.pngindex eb216e453f..7f08a7eae3 100644Binary files a/apps/academy/public/favicon-16x16.png and b/apps/academy/public/favicon-16x16.png differdiff --git a/apps/academy/public/favicon-32x32.png b/apps/academy/public/favicon-32x32.pngindex a7064d2122..348b196709 100644Binary files a/apps/academy/public/favicon-32x32.png and b/apps/academy/public/favicon-32x32.png differdiff --git a/apps/academy/public/favicon-96x96.png b/apps/academy/public/favicon-96x96.pngdeleted file mode 100644index c36c27be04..0000000000Binary files a/apps/academy/public/favicon-96x96.png and /dev/null differdiff --git a/apps/academy/public/favicon.ico b/apps/academy/public/favicon.icoindex a87e92b575..644a0d8ed5 100644Binary files a/apps/academy/public/favicon.ico and b/apps/academy/public/favicon.ico differdiff --git a/apps/academy/public/favicon.svg b/apps/academy/public/favicon.svgindex 1f953c23a1..047b926154 100644--- a/apps/academy/public/favicon.svg+++ b/apps/academy/public/favicon.svg@@ -1,22 +1,3 @@-<svg xmlns="http://www.w3.org/2000/svg" version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" width="362" height="349"><svg width="362" height="349" viewBox="0 0 362 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M181.165 139.643V69.8213L241.346 35.0564L241.054 104.878L181.165 139.643Z" fill="#60FFD2"></path>-<path d="M181.165 69.8213V139.643L120.4 104.878V35.0564L181.165 69.8213Z" fill="#36B5B4"></path>-<path d="M120.4 35.0565L181.165 69.8214L241.347 35.0565L181.165 -0.000610352L120.4 35.0565Z" fill="#5FE4D2"></path>-<path d="M240.818 244.172V174.35L300.999 139.585L300.707 209.407L240.818 244.172Z" fill="#71DEFF"></path>-<path d="M240.818 174.35V244.172L180.052 209.407V139.585L240.818 174.35Z" fill="#3877C5"></path>-<path d="M180.052 139.586L240.818 174.35L300.999 139.586L240.818 104.528L180.052 139.586Z" fill="#4EAADE"></path>-<path d="M121.512 244.172V174.35L181.693 139.585L181.401 209.407L121.512 244.172Z" fill="#71DEFF"></path>-<path d="M121.512 174.35V244.172L60.7466 209.407V139.585L121.512 174.35Z" fill="#3877C5"></path>-<path d="M60.7466 139.586L121.512 174.35L181.694 139.586L121.512 104.528L60.7466 139.586Z" fill="#4EAADE"></path>-<path d="M181.165 348.701V278.879L241.346 244.114L241.054 313.936L181.165 348.701Z" fill="#7D7FE5"></path>-<path d="M181.165 278.879V348.701L120.4 313.936V244.114L181.165 278.879Z" fill="#2F31AE"></path>-<path d="M120.4 244.114L181.165 278.879L241.347 244.114L181.165 209.057L120.4 244.114Z" fill="#6041D0"></path>-<path d="M60.7651 348.701V278.879L120.946 244.114L120.654 313.936L60.7651 348.701Z" fill="#7D7FE5"></path>-<path d="M60.7656 278.879V348.701L0 313.936V244.114L60.7656 278.879Z" fill="#2F31AE"></path>-<path d="M0 244.114L60.7656 278.879L120.947 244.114L60.7656 209.057L0 244.114Z" fill="#6041D0"></path>-<path d="M301.017 348.701V278.879L361.198 244.114L360.906 313.936L301.017 348.701Z" fill="#7D7FE5"></path>-<path d="M301.018 278.879V348.701L240.252 313.936V244.114L301.018 278.879Z" fill="#2F31AE"></path>-<path d="M240.252 244.114L301.018 278.879L361.199 244.114L301.018 209.057L240.252 244.114Z" fill="#6041D0"></path>-</svg><style>@media (prefers-color-scheme: light) { :root { filter: none; } }-@media (prefers-color-scheme: dark) { :root { filter: none; } }-</style></svg>\ No newline at end of file+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#E6E6E6"/>+</svg>diff --git a/apps/academy/public/site.webmanifest b/apps/academy/public/site.webmanifestindex 344837476f..45dc8a2065 100644--- a/apps/academy/public/site.webmanifest+++ b/apps/academy/public/site.webmanifest@@ -1,21 +1 @@-{- "name": "Carbon",- "short_name": "Carbon",- "icons": [- {- "src": "/web-app-manifest-192x192.png",- "sizes": "192x192",- "type": "image/png",- "purpose": "maskable"- },- {- "src": "/web-app-manifest-512x512.png",- "sizes": "512x512",- "type": "image/png",- "purpose": "maskable"- }- ],- "theme_color": "#000000",- "background_color": "#000000",- "display": "standalone"-}\ No newline at end of file+{"name":"","short_name":"","icons":[{"src":"/android-chrome-192x192.png","sizes":"192x192","type":"image/png"},{"src":"/android-chrome-512x512.png","sizes":"512x512","type":"image/png"}],"theme_color":"#ffffff","background_color":"#ffffff","display":"standalone"}\ No newline at end of filediff --git a/apps/academy/public/web-app-manifest-192x192.png b/apps/academy/public/web-app-manifest-192x192.pngdeleted file mode 100644index cda38d5ed4..0000000000Binary files a/apps/academy/public/web-app-manifest-192x192.png and /dev/null differdiff --git a/apps/academy/public/web-app-manifest-512x512.png b/apps/academy/public/web-app-manifest-512x512.pngdeleted file mode 100644index 88c30a090e..0000000000Binary files a/apps/academy/public/web-app-manifest-512x512.png and /dev/null differdiff --git a/apps/erp/app/components/DocumentHeader.tsx b/apps/erp/app/components/DocumentHeader.tsxnew file mode 100644index 0000000000..f605f0d251--- /dev/null+++ b/apps/erp/app/components/DocumentHeader.tsx@@ -0,0 +1,61 @@+import {+ CardHeader,+ Copy,+ DropdownMenu,+ DropdownMenuContent,+ DropdownMenuTrigger,+ Heading,+ HStack,+ IconButton+} from "@carbon/react";+import type { ReactNode } from "react";+import { LuEllipsisVertical } from "react-icons/lu";++type DocumentHeaderProps = {+ title: string;+ subtitle?: string;+ status?: ReactNode;+ menuItems?: ReactNode;+ actions?: ReactNode;+};++const DocumentHeader = ({+ title,+ subtitle,+ status,+ menuItems,+ actions+}: DocumentHeaderProps) => {+ return (+ <CardHeader className="flex-row items-center justify-between">+ <div>+ <HStack>+ <Heading as="h1" size="h3">+ {title}+ </Heading>+ <Copy text={title} />+ {menuItems && (+ <DropdownMenu>+ <DropdownMenuTrigger asChild>+ <IconButton+ aria-label="More options"+ icon={<LuEllipsisVertical />}+ variant="secondary"+ size="sm"+ />+ </DropdownMenuTrigger>+ <DropdownMenuContent>{menuItems}</DropdownMenuContent>+ </DropdownMenu>+ )}+ {status}+ </HStack>+ {subtitle && (+ <p className="text-sm text-muted-foreground">{subtitle}</p>+ )}+ </div>+ {actions && <HStack>{actions}</HStack>}+ </CardHeader>+ );+};++export default DocumentHeader;diff --git a/apps/erp/app/components/Form/Account.tsx b/apps/erp/app/components/Form/Account.tsxindex 0e58bf2364..1f570aa1f7 100644--- a/apps/erp/app/components/Form/Account.tsx+++ b/apps/erp/app/components/Form/Account.tsx@@ -69,11 +69,12 @@ function useAccountOptions(classes?: AccountClass[]) {value: c.id,label: (<div className="flex items-center justify-between w-full gap-2">- <span className="truncate">{c.name}</span>+ <span className="truncate">+ <span className="text-muted-foreground">{c.number}</span> {c.name}+ </span>{c.class && <Badge variant={badgeColors[c.class]}>{c.class}</Badge>}</div>- ),- helper: c.number+ )})),[accounts]);diff --git a/apps/erp/app/components/Form/AssetClass.tsx b/apps/erp/app/components/Form/AssetClass.tsxnew file mode 100644index 0000000000..bda16bfe2a--- /dev/null+++ b/apps/erp/app/components/Form/AssetClass.tsx@@ -0,0 +1,114 @@+import type { CreatableComboboxProps } from "@carbon/form";+import { CreatableCombobox } from "@carbon/form";+import { useDisclosure, useMount } from "@carbon/react";+import { useMemo, useRef, useState } from "react";+import { useFetcher } from "react-router";+import type { getFixedAssetClassesList } from "~/modules/accounting";+import AssetClassForm from "~/modules/accounting/ui/FixedAssets/AssetClassForm";+import type { loader as newAssetClassLoader } from "~/routes/x+/accounting+/asset-classes.new";+import { path } from "~/utils/path";+import { Enumerable } from "../Enumerable";++type AssetClassSelectProps = Omit<+ CreatableComboboxProps,+ "options" | "inline"+> & {+ inline?: boolean;+};++const AssetClassPreview = (+ value: string,+ options: { value: string; label: string | JSX.Element }[]+) => {+ const assetClass = options.find((o) => o.value === value);+ // @ts-expect-error TS2322 - TODO: fix type+ return <Enumerable value={assetClass?.label ?? null} />;+};++const AssetClass = ({ inline = false, ...props }: AssetClassSelectProps) => {+ const newAssetClassModal = useDisclosure();+ const [created, setCreated] = useState<string>("");+ const triggerRef = useRef<HTMLButtonElement>(null);+ const defaultsFetcher = useFetcher<typeof newAssetClassLoader>();++ const { options } = useAssetClasses();++ const defaults = defaultsFetcher.data?.defaults;+ const taxDepreciationEnabled =+ defaultsFetcher.data?.taxDepreciationEnabled ?? false;++ return (+ <>+ <CreatableCombobox+ ref={triggerRef}+ options={options.map((o) => ({+ value: o.value,+ label: <Enumerable value={o.label} />+ }))}+ {...props}+ label={props?.label ?? "Asset Class"}+ inline={inline ? AssetClassPreview : undefined}+ onCreateOption={(option) => {+ defaultsFetcher.load(path.to.newAssetClass);+ newAssetClassModal.onOpen();+ setCreated(option);+ }}+ />+ {newAssetClassModal.isOpen && (+ <AssetClassForm+ type="modal"+ onClose={() => {+ setCreated("");+ newAssetClassModal.onClose();+ triggerRef.current?.click();+ }}+ taxDepreciationEnabled={taxDepreciationEnabled}+ initialValues={{+ name: created,+ description: "",+ depreciationMethod: "Straight Line" as const,+ usefulLifeMonths: 60,+ residualValuePercent: 0,+ assetAccountId: defaults?.assetAquisitionCostAccount ?? "",+ accumulatedDepreciationAccountId:+ defaults?.accumulatedDepreciationAccount ?? "",+ depreciationExpenseAccountId:+ defaults?.assetDepreciationExpenseAccount ?? "",+ writeOffAccountId: defaults?.assetGainsAndLossesAccount ?? "",+ writeDownAccountId: defaults?.assetGainsAndLossesAccount ?? "",+ disposalAccountId: defaults?.assetGainsAndLossesAccount ?? ""+ }}+ />+ )}+ </>+ );+};++AssetClass.displayName = "AssetClass";++export default AssetClass;++export const useAssetClasses = () => {+ const assetClassFetcher =+ useFetcher<Awaited<ReturnType<typeof getFixedAssetClassesList>>>();++ useMount(() => {+ assetClassFetcher.load(path.to.api.assetClasses);+ });++ const assetClasses = useMemo(+ () => assetClassFetcher.data?.data ?? [],+ [assetClassFetcher.data]+ );++ const options = useMemo(+ () =>+ assetClasses.map((c) => ({+ value: c.id,+ label: c.name+ })),+ [assetClasses]+ );++ return { options, assetClasses };+};diff --git a/apps/erp/app/components/Form/Location.tsx b/apps/erp/app/components/Form/Location.tsxindex 8658aec521..30ee52bd12 100644--- a/apps/erp/app/components/Form/Location.tsx+++ b/apps/erp/app/components/Form/Location.tsx@@ -22,8 +22,8 @@ const LocationPreview = (options: { value: string; label: string | JSX.Element }[]) => {const location = options.find((o) => o.value === value);- // @ts-expect-error TS2322 - TODO: fix type- return <Enumerable value={location?.label ?? null} />;+ if (!location) return null;+ return location?.label ?? null;};const Location = ({ inline = false, ...props }: LocationSelectProps) => {@@ -39,7 +39,10 @@ const Location = ({ inline = false, ...props }: LocationSelectProps) => {<><CreatableComboboxref={triggerRef}- options={options}+ options={options.map((o) => ({+ value: o.value,+ label: <Enumerable value={o.label} />+ }))}{...props}label={props?.label ?? "Location"}inline={inline ? LocationPreview : undefined}diff --git a/apps/erp/app/components/Form/index.ts b/apps/erp/app/components/Form/index.tsindex f9ebd453e1..e12364eb3c 100644--- a/apps/erp/app/components/Form/index.ts+++ b/apps/erp/app/components/Form/index.ts@@ -29,6 +29,7 @@ import Abilities from "./Abilities";import Ability from "./Ability";import Account, { AccountControlled } from "./Account";import AddressAutocomplete from "./AddressAutocomplete";+import AssetClass, { useAssetClasses } from "./AssetClass";import Color from "./Color";import ConversionFactor from "./ConversionFactor";import CostCenter from "./CostCenter";@@ -90,6 +91,8 @@ export {Ability,Account,AccountControlled,+ AssetClass,+ useAssetClasses,AddressAutocomplete,Array,ArrayNumeric,diff --git a/apps/erp/app/components/Icons.tsx b/apps/erp/app/components/Icons.tsxindex d7017e3b37..4cbbc1a8de 100644--- a/apps/erp/app/components/Icons.tsx+++ b/apps/erp/app/components/Icons.tsx@@ -21,31 +21,34 @@ import {LuBookOpen,LuBox,LuBuilding,+ LuBuilding2,LuCircle,LuCircleCheck,LuCircleDashed,LuCircleDollarSign,+ LuCirclePlay,LuCircleX,LuClipboardCheck,LuClock,LuClock3,+ LuCog,LuContainer,+ LuCreditCard,LuExternalLink,LuEye,- LuFactory,- LuFileText,LuFlaskConical,LuGroup,LuHammer,+ LuHandCoins,LuHardHat,LuHeadphones,LuImage,+ LuLandmark,LuList,LuMapPin,LuPackage,LuPizza,LuQrCode,- LuReceipt,LuRotateCcw,LuShoppingCart,LuSquare,@@ -55,7 +58,8 @@ import {LuToggleLeft,LuTruck,LuUser,- LuUsers+ LuUsers,+ LuWrench} from "react-icons/lu";import { RxCodesandboxLogo } from "react-icons/rx";import { TbTargetOff } from "react-icons/tb";@@ -563,13 +567,13 @@ export const JournalEntrySourceTypeIcon = ({case "Manual":return <LuBookOpen className={className} />;case "Purchase Receipt":- return <LuReceipt className={className} />;+ return <LuHandCoins className={className} />;case "Purchase Invoice":- return <LuFileText className={className} />;+ return <LuCreditCard className={className} />;case "Purchase Return":return <LuRotateCcw className={className} />;case "Sales Invoice":- return <LuFileText className={className} />;+ return <LuCreditCard className={className} />;case "Sales Shipment":return <LuTruck className={className} />;case "Sales Return":@@ -579,7 +583,7 @@ export const JournalEntrySourceTypeIcon = ({case "Inventory Adjustment":return <LuPackage className={className} />;case "Production Order":- return <LuFactory className={className} />;+ return <LuCirclePlay className={className} />;case "Job Consumption":return <LuHammer className={className} />;case "Job Receipt":@@ -588,6 +592,10 @@ export const JournalEntrySourceTypeIcon = ({return <LuHardHat className={className} />;case "Job Close":return <LuCircleCheck className={className} />;+ case "Asset Depreciation":+ return <LuClock className={className} />;+ case "Asset Disposal":+ return <LuBuilding2 className={className} />;}return <LuSquare className={cn("text-muted-foreground", className)} />;@@ -615,8 +623,14 @@ export const DimensionEntityTypeIcon = ({return <LuBuilding className={className} />;case "Employee":return <LuUser className={className} />;+ case "FixedAssetClass":+ return <LuLandmark className={className} />;case "CostCenter":return <LuCircleDollarSign className={className} />;+ case "WorkCenter":+ return <LuWrench className={className} />;+ case "Process":+ return <LuCog className={className} />;}};diff --git a/apps/erp/app/components/Layout/Navigation/PrimaryNavigation.tsx b/apps/erp/app/components/Layout/Navigation/PrimaryNavigation.tsxindex 7a9d1d433a..3bcd4179f1 100644--- a/apps/erp/app/components/Layout/Navigation/PrimaryNavigation.tsx+++ b/apps/erp/app/components/Layout/Navigation/PrimaryNavigation.tsx@@ -15,7 +15,7 @@ import type { AnchorHTMLAttributes } from "react";import { forwardRef, memo, useEffect } from "react";import { LuSettings2 } from "react-icons/lu";import { Link, useMatches } from "react-router";-import { useModules, useOptimisticLocation } from "~/hooks";+import { useModules, useOptimisticLocation, useSettingsModule } from "~/hooks";import type { Authenticated, NavItem } from "~/types";import { HiddenModulesPopover } from "./HiddenModulesPopover";import { NavigationEditBar } from "./NavigationEditBar";@@ -27,6 +27,7 @@ const PrimaryNavigation = () => {const location = useOptimisticLocation();const currentModule = getModule(location.pathname);const links = useModules();+ const settingsModule = useSettingsModule();const matchedModules = useMatches().reduce((acc, match) => {const handle = match.handle as { module?: string } | undefined;@@ -118,44 +119,62 @@ const PrimaryNavigation = () => {)}</VStack>- {editMode.isEditing ? (- <NavigationEditBar- isSaving={editMode.isSaving}- isDirty={editMode.isDirty}- onSave={editMode.save}- onCancel={editMode.cancelEditMode}- />- ) : (- <button- type="button"- onClick={editMode.enterEditMode}- className={cn(- "relative",- "h-10 w-10 group-data-[state=expanded]:w-full",- "flex items-center rounded-md",- "group-data-[state=collapsed]:justify-center",- "group-data-[state=expanded]:-space-x-2",- "font-medium shrink-0 inline-flex select-none",- "text-muted-foreground",- "hover:bg-accent hover:text-accent-foreground",- "transition-[background-color,color,width] duration-100 ease-out",- "focus:!outline-none focus:!ring-0 active:!outline-none active:!ring-0",- "after:pointer-events-none after:absolute after:-inset-[3px] after:rounded-lg after:border after:border-blue-500 after:opacity-0 after:ring-2 after:ring-blue-500/20 after:transition-opacity focus-visible:after:opacity-100 active:after:opacity-0",- "group/item"- )}- >- <LuSettings2 className="absolute left-3 top-3 flex items-center justify-center" />- <span+ <VStack spacing={1}>+ {settingsModule &&+ !editMode.isEditing &&+ (() => {+ const m = getModule(settingsModule.to);+ const moduleMatches = matchedModules.has(m);+ const isActive = currentModule === m || moduleMatches;+ return (+ <NavigationIconLink+ link={settingsModule}+ isActive={isActive}+ isOpen={isOpen}+ onClick={navigationPanel.onClose}+ />+ );+ })()}++ {editMode.isEditing ? (+ <NavigationEditBar+ isSaving={editMode.isSaving}+ isDirty={editMode.isDirty}+ onSave={editMode.save}+ onCancel={editMode.cancelEditMode}+ />+ ) : (+ <button+ type="button"+ onClick={editMode.enterEditMode}className={cn(- "min-w-[128px] text-sm text-left",- "absolute left-7 group-data-[state=expanded]:left-12",- "opacity-0 group-data-[state=expanded]:opacity-100"+ "relative",+ "h-10 w-10 group-data-[state=expanded]:w-full",+ "flex items-center rounded-md",+ "group-data-[state=collapsed]:justify-center",+ "group-data-[state=expanded]:-space-x-2",+ "font-medium shrink-0 inline-flex select-none",+ "text-muted-foreground",+ "hover:bg-accent hover:text-accent-foreground",+ "transition-[background-color,color,width] duration-100 ease-out",+ "focus:!outline-none focus:!ring-0 active:!outline-none active:!ring-0",+ "after:pointer-events-none after:absolute after:-inset-[3px] after:rounded-lg after:border after:border-blue-500 after:opacity-0 after:ring-2 after:ring-blue-500/20 after:transition-opacity focus-visible:after:opacity-100 active:after:opacity-0",+ "group/item")}>- Customize- </span>- </button>- )}+ <LuSettings2 className="absolute left-3 top-3 flex items-center justify-center" />+ <span+ className={cn(+ "min-w-[128px] text-sm text-left",+ "absolute left-7 group-data-[state=expanded]:left-12",+ "opacity-0 group-data-[state=expanded]:opacity-100"+ )}+ >+ Customize+ </span>+ </button>+ )}+ </VStack></VStack></nav></div>diff --git a/apps/erp/app/components/index.ts b/apps/erp/app/components/index.tsindex 6fa9212f5e..5b7378e60a 100644--- a/apps/erp/app/components/index.ts+++ b/apps/erp/app/components/index.ts@@ -8,6 +8,7 @@ import CustomerAvatar from "./CustomerAvatar";import { DateSelect } from "./DateSelect";import { DeferredFiles } from "./DeferredFiles";import { DirectionAwareTabs } from "./DirectionAwareTabs";+import DocumentHeader from "./DocumentHeader";import DocumentPreview from "./DocumentPreview";import Documents from "./Documents";import EmployeeAvatar from "./EmployeeAvatar";@@ -48,6 +49,7 @@ export {DateSelect,DeferredFiles,DirectionAwareTabs,+ DocumentHeader,DocumentPreview,Documents,EmployeeAvatar,diff --git a/apps/erp/app/hooks/index.ts b/apps/erp/app/hooks/index.tsindex 97cbccc74b..8f5fb6d5e8 100644--- a/apps/erp/app/hooks/index.ts+++ b/apps/erp/app/hooks/index.ts@@ -9,7 +9,7 @@ import { useCurrencyFormatter } from "./useCurrencyFormatter";import { useDateFormatter } from "./useDateFormatter";import { useFlags } from "./useFlags";import { useGooglePlaces } from "./useGooglePlaces";-import { useAllModules, useModules } from "./useModules";+import { useAllModules, useModules, useSettingsModule } from "./useModules";import { useMovingCellRef } from "./useMovingCellRef";import { useNextItemId } from "./useNextItemId";import { useNotifications } from "./useNotifications";@@ -31,6 +31,7 @@ export {useGooglePlaces,useAllModules,useModules,+ useSettingsModule,useMovingCellRef,useNanoStore,useNextItemId,diff --git a/apps/erp/app/hooks/useModules.tsx b/apps/erp/app/hooks/useModules.tsxindex f8310c9169..b9435e7bf3 100644--- a/apps/erp/app/hooks/useModules.tsx+++ b/apps/erp/app/hooks/useModules.tsx@@ -139,6 +139,8 @@ function useModuleDefinitions(): ModuleDefinition[] {];}+const PINNED_MODULES = new Set(["settings"]);+export function useModules() {const permissions = usePermissions();const modules = useModuleDefinitions();@@ -148,7 +150,9 @@ export function useModules() {}>(path.to.authenticatedRoot);const modulePreferences = routeData?.modulePreferences ?? [];- const permitted = filterByPermissions(modules, permissions);+ const permitted = filterByPermissions(modules, permissions).filter(+ (m) => !PINNED_MODULES.has(m.key)+ );const alphabetical = permitted.sort((a, b) => a.name.localeCompare(b.name));@@ -170,6 +174,17 @@ export function useModules() {});}+export function useSettingsModule() {+ const permissions = usePermissions();+ const modules = useModuleDefinitions();+ const settings = modules.find((m) => m.key === "settings");+ if (!settings) return null;+ if (settings.permission && !permissions.can("view", settings.permission)) {+ return null;+ }+ return settings;+}+export function useAllModules() {const permissions = usePermissions();const modules = useModuleDefinitions();@@ -179,9 +194,9 @@ export function useAllModules() {}>(path.to.authenticatedRoot);const modulePreferences = routeData?.modulePreferences ?? [];- const permitted = filterByPermissions(modules, permissions).sort((a, b) =>- a.name.localeCompare(b.name)- );+ const permitted = filterByPermissions(modules, permissions)+ .filter((m) => !PINNED_MODULES.has(m.key))+ .sort((a, b) => a.name.localeCompare(b.name));const prefMap = new Map(modulePreferences.map((p) => [p.module, p]));diff --git a/apps/erp/app/modules/accounting/accounting.models.ts b/apps/erp/app/modules/accounting/accounting.models.tsindex 42d1110468..20892f2aff 100644--- a/apps/erp/app/modules/accounting/accounting.models.ts+++ b/apps/erp/app/modules/accounting/accounting.models.ts@@ -5,6 +5,9 @@ import {itemLedgerDocumentTypes,itemLedgerTypes} from "../inventory/inventory.models";+import { macrsConventions, macrsPropertyClasses } from "./accounting.utils";++export { macrsConventions, macrsPropertyClasses };export const accountTypes = ["Bank",@@ -271,6 +274,9 @@ export const defaultBalanceSheetAccountValidator = z.object({}),currencyTranslationAccount: z.string().min(1, {message: "Currency translation account is required"+ }),+ deferredTaxLiabilityAccountId: z.string().min(1, {+ message: "Deferred tax liability account is required"})});@@ -332,6 +338,9 @@ export const defaultIncomeAcountValidator = z.object({}),roundingAccount: z.string().min(1, {message: "Rounding account is required"+ }),+ deferredTaxExpenseAccountId: z.string().min(1, {+ message: "Deferred tax expense account is required"})});@@ -450,7 +459,9 @@ export const journalEntrySourceTypes = ["Job Consumption","Job Receipt","Production Event",- "Job Close"+ "Job Close",+ "Asset Depreciation",+ "Asset Disposal"] as const;export const journalEntryStatuses = ["Draft", "Posted", "Reversed"] as const;@@ -485,9 +496,12 @@ export const dimensionEntityTypes = ["CustomerType","Department","Employee",+ "FixedAssetClass","ItemPostingGroup","Location",- "SupplierType"+ "Process",+ "SupplierType",+ "WorkCenter"] as const;export const dimensionValidator = z.object({@@ -500,3 +514,150 @@ export const dimensionValidator = z.object({required: zfd.checkbox(),dimensionValues: z.string().min(1).array().optional()});++// -- Fixed Asset Models --++export const fixedAssetStatuses = [+ "Draft",+ "Active",+ "Fully Depreciated",+ "Disposed"+] as const;++export const depreciationMethods = [+ "Straight Line",+ "Declining Balance",+ "Units of Production"+] as const;++export const taxDepreciationMethods = [+ "Straight Line",+ "Declining Balance",+ "MACRS"+] as const;++export const disposalMethods = ["Sale", "Scrapping"] as const;++export const fixedAssetClassValidator = z.object({+ id: zfd.text(z.string().optional()),+ name: z.string().min(1, { message: "Name is required" }),+ description: z.string().optional(),+ depreciationMethod: z.enum(depreciationMethods, {+ errorMap: () => ({ message: "Depreciation method is required" })+ }),+ usefulLifeMonths: zfd.numeric(+ z.number().int().positive({ message: "Useful life must be positive" })+ ),+ residualValuePercent: zfd.numeric(+ z+ .number()+ .min(0, { message: "Residual value must be >= 0" })+ .max(100, { message: "Residual value must be <= 100" })+ ),+ assetAccountId: z.string().min(1, { message: "Asset account is required" }),+ accumulatedDepreciationAccountId: z+ .string()+ .min(1, { message: "Accumulated depreciation account is required" }),+ depreciationExpenseAccountId: z+ .string()+ .min(1, { message: "Depreciation expense account is required" }),+ writeOffAccountId: z+ .string()+ .min(1, { message: "Write-off account is required" }),+ writeDownAccountId: z+ .string()+ .min(1, { message: "Write-down account is required" }),+ disposalAccountId: z+ .string()+ .min(1, { message: "Disposal account is required" }),+ taxDepreciationMethod: z.preprocess(+ (val) => (val === "" ? null : val),+ z.enum(taxDepreciationMethods).nullable().optional()+ ),+ taxUsefulLifeMonths: zfd.numeric(+ z.number().int().positive().nullable().optional()+ ),+ taxResidualValuePercent: zfd.numeric(+ z.number().min(0).max(100).nullable().optional()+ ),+ macrsPropertyClass: z.enum(macrsPropertyClasses).nullable().optional(),+ macrsConvention: z.enum(macrsConventions).nullable().optional(),+ bonusDepreciationPercent: zfd.numeric(+ z.number().min(0).max(100).nullable().optional()+ )+});++export const fixedAssetValidator = z.object({+ id: zfd.text(z.string().optional()),+ fixedAssetClassId: z.string().min(1, { message: "Asset class is required" }),+ name: z.string().min(1, { message: "Name is required" }),+ description: z.string().optional(),+ serialNumber: z.string().optional(),+ depreciationMethod: z.enum(depreciationMethods, {+ errorMap: () => ({ message: "Depreciation method is required" })+ }),+ usefulLifeMonths: zfd.numeric(+ z.number().int().positive({ message: "Useful life must be positive" })+ ),+ residualValuePercent: zfd.numeric(+ z+ .number()+ .min(0, { message: "Residual value must be >= 0" })+ .max(100, { message: "Residual value must be <= 100" })+ ),+ assetLifetimeUsage: zfd.numeric(z.number().positive().optional()),+ locationId: zfd.text(z.string().optional()),+ taxDepreciationMethod: z.preprocess(+ (val) => (val === "" ? null : val),+ z.enum(taxDepreciationMethods).nullable().optional()+ ),+ taxUsefulLifeMonths: zfd.numeric(+ z.number().int().positive().nullable().optional()+ ),+ taxResidualValuePercent: zfd.numeric(+ z.number().min(0).max(100).nullable().optional()+ ),+ macrsPropertyClass: z.preprocess(+ (val) => (val === "" ? null : val),+ z.enum(macrsPropertyClasses).nullable().optional()+ ),+ macrsConvention: z.preprocess(+ (val) => (val === "" ? null : val),+ z.enum(macrsConventions).nullable().optional()+ ),+ bonusDepreciationPercent: zfd.numeric(+ z.number().min(0).max(100).nullable().optional()+ )+});++export const fixedAssetRegisterValidator = z.object({+ acquisitionCost: zfd.numeric(+ z.number().positive({ message: "Acquisition cost must be positive" })+ ),+ acquisitionDate: z+ .string()+ .min(1, { message: "Acquisition date is required" }),+ accumulatedDepreciation: zfd.numeric(+ z.number().min(0, { message: "Accumulated depreciation must be >= 0" })+ ),+ depreciationStartDate: z+ .string()+ .min(1, { message: "Depreciation start date is required" })+});++export const depreciationRunValidator = z.object({+ periodEnd: z.string().min(1, { message: "Period end date is required" })+});++export const fixedAssetUsageLogValidator = z.object({+ fixedAssetId: z.string().min(1, { message: "Asset is required" }),+ periodStart: z.string().min(1, { message: "Period start is required" }),+ periodEnd: z.string().min(1, { message: "Period end is required" }),+ unitsProduced: zfd.numeric(+ z.number().positive({ message: "Units must be positive" })+ )+});++export const fixedAssetDisposalValidator = z.object({+ disposalDate: z.string().min(1, { message: "Disposal date is required" })+});diff --git a/apps/erp/app/modules/accounting/accounting.server.ts b/apps/erp/app/modules/accounting/accounting.server.tsnew file mode 100644index 0000000000..9a30863bae--- /dev/null+++ b/apps/erp/app/modules/accounting/accounting.server.ts@@ -0,0 +1,545 @@+import type { Kysely, KyselyDatabase, KyselyTx } from "@carbon/database/client";+import { toStoredAmount } from "@carbon/utils";+import { interpolateSequenceDate } from "~/utils/string";++async function getNextSequence(+ trx: KyselyTx,+ tableName: string,+ companyId: string+) {+ const sequence = await trx+ .selectFrom("sequence")+ .selectAll()+ .where("table", "=", tableName)+ .where("companyId", "=", companyId)+ .executeTakeFirstOrThrow();++ const { prefix, suffix, next, size, step } = sequence;+ if (!Number.isInteger(next)) throw new Error("Next is not an integer");+ if (!Number.isInteger(step)) throw new Error("Step is not an integer");+ if (!Number.isInteger(size)) throw new Error("Size is not an integer");++ const nextValue = next! + step!;+ const nextSequence = nextValue.toString().padStart(size!, "0");+ const derivedPrefix = interpolateSequenceDate(prefix);+ const derivedSuffix = interpolateSequenceDate(suffix);++ await trx+ .updateTable("sequence")+ .set({ next: nextValue, updatedBy: "system" })+ .where("table", "=", tableName)+ .where("companyId", "=", companyId)+ .execute();++ return `${derivedPrefix}${nextSequence}${derivedSuffix}`;+}++export async function postDisposal(+ db: Kysely<KyselyDatabase>,+ args: {+ fixedAssetId: string;+ fixedAssetReadableId: string;+ disposalDate: string;+ disposalMethod: "Sale" | "Scrapping";+ acquisitionCost: number;+ accumulatedDepreciation: number;+ locationId: string | null;+ fixedAssetClassId: string;+ assetAccountId: string;+ accumulatedDepreciationAccountId: string;+ writeOffAccountId: string;+ accountingPeriodId: string;+ locationDimensionId: string | undefined;+ assetClassDimensionId: string | undefined;+ companyId: string;+ userId: string;+ }+) {+ const {+ fixedAssetId,+ fixedAssetReadableId,+ disposalDate,+ disposalMethod,+ acquisitionCost,+ accumulatedDepreciation,+ locationId,+ fixedAssetClassId,+ assetAccountId,+ accumulatedDepreciationAccountId,+ writeOffAccountId,+ accountingPeriodId,+ locationDimensionId,+ assetClassDimensionId,+ companyId,+ userId+ } = args;++ const nbv = acquisitionCost - accumulatedDepreciation;+ const now = new Date().toISOString();++ return db.transaction().execute(async (trx) => {+ const journalEntryId = await getNextSequence(+ trx,+ "journalEntry",+ companyId+ );++ const journal = await trx+ .insertInto("journal")+ .values({+ journalEntryId,+ accountingPeriodId,+ companyId,+ description: `Asset Disposal: ${fixedAssetReadableId} (${disposalMethod})`,+ postingDate: disposalDate,+ sourceType: "Asset Disposal",+ status: "Posted",+ postedAt: now,+ postedBy: userId,+ createdBy: userId+ })+ .returning(["id"])+ .executeTakeFirstOrThrow();++ const journalLines: Array<{+ journalId: string;+ accountId: string;+ description: string;+ amount: number;+ journalLineReference: string;+ companyId: string;+ }> = [];++ if (accumulatedDepreciation > 0) {+ journalLines.push({+ journalId: journal.id,+ accountId: accumulatedDepreciationAccountId,+ description: "Clear accumulated depreciation",+ amount: toStoredAmount(accumulatedDepreciation, 0, "Asset"),+ journalLineReference: crypto.randomUUID(),+ companyId+ });+ }++ if (nbv > 0) {+ journalLines.push({+ journalId: journal.id,+ accountId: writeOffAccountId,+ description: "Write-off remaining book value",+ amount: toStoredAmount(nbv, 0, "Expense"),+ journalLineReference: crypto.randomUUID(),+ companyId+ });+ }++ journalLines.push({+ journalId: journal.id,+ accountId: assetAccountId,+ description: "Remove asset at cost",+ amount: toStoredAmount(0, acquisitionCost, "Asset"),+ journalLineReference: crypto.randomUUID(),+ companyId+ });++ const journalLineResults = await trx+ .insertInto("journalLine")+ .values(journalLines)+ .returning(["id"])+ .execute();++ if (locationDimensionId && locationId) {+ await trx+ .insertInto("journalLineDimension")+ .values(+ journalLineResults.map((jl) => ({+ journalLineId: jl.id,+ dimensionId: locationDimensionId,+ valueId: locationId,+ companyId+ }))+ )+ .execute();+ }++ if (assetClassDimensionId && fixedAssetClassId) {+ await trx+ .insertInto("journalLineDimension")+ .values(+ journalLineResults.map((jl) => ({+ journalLineId: jl.id,+ dimensionId: assetClassDimensionId,+ valueId: fixedAssetClassId,+ companyId+ }))+ )+ .execute();+ }++ await trx+ .insertInto("fixedAssetDisposal")+ .values({+ fixedAssetId,+ disposalMethod,+ disposalDate,+ saleProceeds: 0,+ netBookValueAtDisposal: nbv,+ gainLoss: -nbv,+ journalId: journal.id,+ companyId,+ createdBy: userId+ })+ .execute();++ await trx+ .updateTable("fixedAsset")+ .set({+ status: "Disposed",+ disposalDate,+ disposalMethod,+ saleProceeds: 0,+ updatedBy: userId+ })+ .where("id", "=", fixedAssetId)+ .execute();+ });+}++type DepreciationRunLine = {+ id: string;+ fixedAssetId: string;+ amount: number;+ taxAmount: number;+ asset: {+ fixedAssetId: string;+ locationId: string | null;+ fixedAssetClassId: string;+ acquisitionCost: number;+ accumulatedDepreciation: number;+ accumulatedTaxDepreciation: number;+ residualValuePercent: number;+ depreciationExpenseAccountId: string;+ accumulatedDepreciationAccountId: string;+ };+};++export async function postDepreciationRun(+ db: Kysely<KyselyDatabase>,+ args: {+ depreciationRunId: string;+ depreciationRunReadableId: string;+ postingDate: string;+ accountingPeriodId: string;+ lines: DepreciationRunLine[];+ locationDimensionId: string | undefined;+ assetClassDimensionId: string | undefined;+ taxEnabled: boolean;+ taxRate: number | null;+ dtlAccountId: string | null;+ dtExpenseAccountId: string | null;+ companyId: string;+ userId: string;+ }+) {+ const {+ depreciationRunId,+ depreciationRunReadableId,+ postingDate,+ accountingPeriodId,+ lines,+ locationDimensionId,+ assetClassDimensionId,+ taxEnabled,+ taxRate,+ dtlAccountId,+ dtExpenseAccountId,+ companyId,+ userId+ } = args;++ const now = new Date().toISOString();++ return db.transaction().execute(async (trx) => {+ for (const line of lines) {+ const { asset } = line;+ const amount = Number(line.amount);++ const journalEntryId = await getNextSequence(+ trx,+ "journalEntry",+ companyId+ );++ const journal = await trx+ .insertInto("journal")+ .values({+ journalEntryId,+ accountingPeriodId,+ companyId,+ description: `Depreciation: ${asset.fixedAssetId}`,+ postingDate,+ sourceType: "Asset Depreciation",+ status: "Posted",+ postedAt: now,+ postedBy: userId,+ createdBy: userId+ })+ .returning(["id"])+ .executeTakeFirstOrThrow();++ const journalLineResults = await trx+ .insertInto("journalLine")+ .values([+ {+ journalId: journal.id,+ accountId: asset.depreciationExpenseAccountId,+ description: "Depreciation Expense",+ amount: toStoredAmount(amount, 0, "Expense"),+ journalLineReference: crypto.randomUUID(),+ companyId+ },+ {+ journalId: journal.id,+ accountId: asset.accumulatedDepreciationAccountId,+ description: "Accumulated Depreciation",+ amount: toStoredAmount(0, amount, "Asset"),+ journalLineReference: crypto.randomUUID(),+ companyId+ }+ ])+ .returning(["id"])+ .execute();++ if (locationDimensionId && asset.locationId) {+ await trx+ .insertInto("journalLineDimension")+ .values(+ journalLineResults.map((jl) => ({+ journalLineId: jl.id,+ dimensionId: locationDimensionId,+ valueId: asset.locationId!,+ companyId+ }))+ )+ .execute();+ }++ if (assetClassDimensionId && asset.fixedAssetClassId) {+ await trx+ .insertInto("journalLineDimension")+ .values(+ journalLineResults.map((jl) => ({+ journalLineId: jl.id,+ dimensionId: assetClassDimensionId,+ valueId: asset.fixedAssetClassId,+ companyId+ }))+ )+ .execute();+ }++ await trx+ .updateTable("depreciationRunLine")+ .set({ journalId: journal.id })+ .where("id", "=", line.id)+ .execute();++ const newAccumulated = Number(asset.accumulatedDepreciation) + amount;+ const cost = Number(asset.acquisitionCost);+ const residualValue = cost * (Number(asset.residualValuePercent) / 100);+ const nbv = cost - newAccumulated;++ const assetUpdate: Record<string, any> = {+ accumulatedDepreciation: newAccumulated,+ updatedBy: userId+ };++ if (nbv <= residualValue + 0.01) {+ assetUpdate.status = "Fully Depreciated";+ }++ if (taxEnabled) {+ const taxAmount = Number(line.taxAmount ?? 0);+ if (taxAmount > 0) {+ const currentTax = Number(asset.accumulatedTaxDepreciation ?? 0);+ assetUpdate.accumulatedTaxDepreciation = currentTax + taxAmount;+ }+ }++ await trx+ .updateTable("fixedAsset")+ .set(assetUpdate)+ .where("id", "=", line.fixedAssetId)+ .execute();+ }++ // Deferred tax liability journal entry+ if (taxEnabled && taxRate && dtlAccountId && dtExpenseAccountId) {+ const diffByGroup = new Map<+ string,+ { locationId: string | null; fixedAssetClassId: string; diff: number }+ >();++ for (const line of lines) {+ const bookAmount = Number(line.amount);+ const taxAmt = Number(line.taxAmount ?? bookAmount);+ const diff = taxAmt - bookAmount;+ const locId = line.asset.locationId ?? null;+ const classId = line.asset.fixedAssetClassId;+ const key = `${locId ?? ""}|${classId}`;+ const existing = diffByGroup.get(key);+ if (existing) {+ existing.diff += diff;+ } else {+ diffByGroup.set(key, {+ locationId: locId,+ fixedAssetClassId: classId,+ diff+ });+ }+ }++ const totalTemporaryDifference = [...diffByGroup.values()].reduce(+ (sum, g) => sum + g.diff,+ 0+ );+ const dtlAmount = Math.abs(totalTemporaryDifference * (taxRate / 100));++ if (dtlAmount > 0.01) {+ const dtlEntryId = await getNextSequence(+ trx,+ "journalEntry",+ companyId+ );++ const dtlJournal = await trx+ .insertInto("journal")+ .values({+ journalEntryId: dtlEntryId,+ accountingPeriodId,+ companyId,+ description: `Deferred Tax: Depreciation ${depreciationRunReadableId}`,+ postingDate,+ sourceType: "Asset Depreciation",+ status: "Posted",+ postedAt: now,+ postedBy: userId,+ createdBy: userId+ })+ .returning(["id"])+ .executeTakeFirstOrThrow();++ const isLiability = totalTemporaryDifference > 0;++ const significantEntries = [...diffByGroup.values()].filter(+ (g) => Math.abs(g.diff * (taxRate / 100)) > 0.01+ );++ const dtlLineValues = significantEntries.flatMap((g) => {+ const locAmount = Math.abs(g.diff * (taxRate / 100));+ return [+ {+ journalId: dtlJournal.id,+ accountId: isLiability ? dtExpenseAccountId : dtlAccountId,+ description: isLiability+ ? "Deferred Tax Expense"+ : "Deferred Tax Liability",+ amount: toStoredAmount(+ locAmount,+ 0,+ isLiability ? "Expense" : "Liability"+ ),+ journalLineReference: crypto.randomUUID(),+ companyId+ },+ {+ journalId: dtlJournal.id,+ accountId: isLiability ? dtlAccountId : dtExpenseAccountId,+ description: isLiability+ ? "Deferred Tax Liability"+ : "Deferred Tax Benefit",+ amount: toStoredAmount(+ 0,+ locAmount,+ isLiability ? "Liability" : "Expense"+ ),+ journalLineReference: crypto.randomUUID(),+ companyId+ }+ ];+ });++ if (dtlLineValues.length > 0) {+ const dtlLineResults = await trx+ .insertInto("journalLine")+ .values(dtlLineValues)+ .returning(["id"])+ .execute();++ const dimensionValues: Array<{+ journalLineId: string;+ dimensionId: string;+ valueId: string;+ companyId: string;+ }> = [];++ for (let i = 0; i < significantEntries.length; i++) {+ const g = significantEntries[i];+ const debitLineId = dtlLineResults[i * 2].id;+ const creditLineId = dtlLineResults[i * 2 + 1].id;++ if (locationDimensionId && g.locationId) {+ dimensionValues.push(+ {+ journalLineId: debitLineId,+ dimensionId: locationDimensionId,+ valueId: g.locationId,+ companyId+ },+ {+ journalLineId: creditLineId,+ dimensionId: locationDimensionId,+ valueId: g.locationId,+ companyId+ }+ );+ }++ if (assetClassDimensionId && g.fixedAssetClassId) {+ dimensionValues.push(+ {+ journalLineId: debitLineId,+ dimensionId: assetClassDimensionId,+ valueId: g.fixedAssetClassId,+ companyId+ },+ {+ journalLineId: creditLineId,+ dimensionId: assetClassDimensionId,+ valueId: g.fixedAssetClassId,+ companyId+ }+ );+ }+ }++ if (dimensionValues.length > 0) {+ await trx+ .insertInto("journalLineDimension")+ .values(dimensionValues)+ .execute();+ }+ }+ }+ }++ await trx+ .updateTable("depreciationRun")+ .set({+ status: "Posted",+ postedAt: now,+ postedBy: userId+ })+ .where("id", "=", depreciationRunId)+ .execute();+ });+}diff --git a/apps/erp/app/modules/accounting/accounting.service.ts b/apps/erp/app/modules/accounting/accounting.service.tsindex 49ee86e481..5414e98905 100644--- a/apps/erp/app/modules/accounting/accounting.service.ts+++ b/apps/erp/app/modules/accounting/accounting.service.ts@@ -443,6 +443,73 @@ export async function getCurrentAccountingPeriod(.single();}+export async function getOrCreateAccountingPeriod(+ client: SupabaseClient<Database>,+ companyId: string,+ date: string+): Promise<{ data: string | null; error: { message: string } | null }> {+ const existing = await getCurrentAccountingPeriod(client, companyId, date);++ if (existing.data) {+ if (existing.data.closedAt) {+ return {+ data: null,+ error: {+ message: "Accounting period is closed. Reopen it before posting."+ }+ };+ }++ if (existing.data.status === "Inactive") {+ await client+ .from("accountingPeriod")+ .update({ status: "Inactive" as const })+ .eq("companyId", companyId)+ .eq("status", "Active");++ await client+ .from("accountingPeriod")+ .update({ status: "Active" as const })+ .eq("id", existing.data.id);+ }+ return { data: existing.data.id, error: null };+ }++ // Create a new period for the month of the given date+ const d = new Date(date);+ const year = d.getFullYear();+ const month = d.getMonth(); // 0-indexed+ const startDate = new Date(year, month, 1).toISOString().split("T")[0];+ const endDate = new Date(year, month + 1, 0).toISOString().split("T")[0];++ await client+ .from("accountingPeriod")+ .update({ status: "Inactive" as const })+ .eq("companyId", companyId)+ .eq("status", "Active");++ const result = await client+ .from("accountingPeriod")+ .insert({+ startDate,+ endDate,+ companyId,+ status: "Active" as const,+ createdBy: "system"+ })+ .select("id")+ .single();++ if (result.error) {+ return {+ data: null,+ error: { message: "Failed to create accounting period" }+ };+ }++ return { data: result.data.id, error: null };+}+export async function getDefaultAccounts(client: SupabaseClient<Database>,companyId: string@@ -953,6 +1020,12 @@ function getEntityDimensionValues(.select("id, name").eq("companyId", companyId).order("name");+ case "FixedAssetClass":+ return client+ .from("fixedAssetClass")+ .select("id, name")+ .eq("companyId", companyId)+ .order("name");case "ItemPostingGroup":return client.from("itemPostingGroup")@@ -1083,6 +1156,8 @@ function getEntityValuesByIds(return client.from("itemPostingGroup").select("id, name").in("id", ids);case "CostCenter":return client.from("costCenter").select("id, name").in("id", ids);+ case "FixedAssetClass":+ return client.from("fixedAssetClass").select("id, name").in("id", ids);default:return Promise.resolve({data: [] as { id: string; name: string }[],@@ -1851,3 +1926,287 @@ export async function reverseJournalEntry(return reversed;}++// -- Asset Classes --++export async function getFixedAssetClasses(+ client: SupabaseClient<Database>,+ companyId: string,+ args: GenericQueryFilters & { search: string | null }+) {+ let query = client+ .from("fixedAssetClass")+ .select(+ "id, name, description, depreciationMethod, usefulLifeMonths, residualValuePercent, taxDepreciationMethod, taxUsefulLifeMonths, macrsPropertyClass",+ { count: "exact" }+ )+ .eq("companyId", companyId);++ if (args.search) {+ query = query.ilike("name", `%${args.search}%`);+ }++ query = setGenericQueryFilters(query, args, [+ { column: "name", ascending: true }+ ]);+ return query;+}++export async function getFixedAssetClass(+ client: SupabaseClient<Database>,+ id: string+) {+ return client.from("fixedAssetClass").select("*").eq("id", id).single();+}++export async function getFixedAssetClassesList(+ client: SupabaseClient<Database>,+ companyId: string+) {+ return client+ .from("fixedAssetClass")+ .select(+ "id, name, depreciationMethod, usefulLifeMonths, residualValuePercent, taxDepreciationMethod, taxUsefulLifeMonths, taxResidualValuePercent, macrsPropertyClass, macrsConvention, bonusDepreciationPercent"+ )+ .eq("companyId", companyId)+ .order("name");+}++export async function upsertFixedAssetClass(+ client: SupabaseClient<Database>,+ data:+ | (Record<string, any> & { companyId: string; createdBy: string })+ | (Record<string, any> & { id: string; updatedBy: string })+) {+ if ("createdBy" in data) {+ return client+ .from("fixedAssetClass")+ .insert([data as any])+ .select("id")+ .single();+ }+ const { id, ...rest } = data;+ return client+ .from("fixedAssetClass")+ .update(sanitize(rest))+ .eq("id", id)+ .select("id")+ .single();+}++export async function deleteFixedAssetClass(+ client: SupabaseClient<Database>,+ id: string+) {+ return client.from("fixedAssetClass").delete().eq("id", id);+}++// -- Fixed Assets --++export async function getFixedAssets(+ client: SupabaseClient<Database>,+ companyId: string,+ args: GenericQueryFilters & {+ search: string | null;+ status: Database["public"]["Enums"]["fixedAssetStatus"] | null;+ }+) {+ let query = client+ .from("fixedAsset")+ .select(+ "id, fixedAssetId, fixedAssetClassId, name, serialNumber, status, depreciationMethod, acquisitionCost, accumulatedDepreciation, fixedAssetClass:fixedAssetClassId(id, name), location:locationId(id, name)",+ { count: "exact" }+ )+ .eq("companyId", companyId);++ if (args.search) {+ query = query.or(+ `name.ilike.%${args.search}%,fixedAssetId.ilike.%${args.search}%,serialNumber.ilike.%${args.search}%`+ );+ }++ if (args.status) {+ query = query.eq("status", args.status);+ }++ query = setGenericQueryFilters(query, args, [+ { column: "fixedAssetId", ascending: true }+ ]);+ return query;+}++export async function getFixedAsset(+ client: SupabaseClient<Database>,+ id: string+) {+ return client+ .from("fixedAsset")+ .select(+ "*, fixedAssetClass:fixedAssetClassId(*), location:locationId(id, name)"+ )+ .eq("id", id)+ .single();+}++export async function getFixedAssetsList(+ client: SupabaseClient<Database>,+ companyId: string+) {+ return client+ .from("fixedAsset")+ .select("id, fixedAssetId, name")+ .eq("companyId", companyId)+ .eq("status", "Draft")+ .order("fixedAssetId");+}++export async function getFixedAssetsListForSale(+ client: SupabaseClient<Database>,+ companyId: string+) {+ return client+ .from("fixedAsset")+ .select("id, fixedAssetId, name")+ .eq("companyId", companyId)+ .in("status", ["Active", "Fully Depreciated"])+ .order("fixedAssetId");+}++export async function upsertFixedAsset(+ client: SupabaseClient<Database>,+ data:+ | (Record<string, any> & {+ fixedAssetId: string;+ companyId: string;+ createdBy: string;+ })+ | (Record<string, any> & { id: string; updatedBy: string })+) {+ if ("createdBy" in data) {+ return client+ .from("fixedAsset")+ .insert([data as any])+ .select("id")+ .single();+ }+ const { id, ...rest } = data;+ return client+ .from("fixedAsset")+ .update(sanitize(rest))+ .eq("id", id)+ .select("id")+ .single();+}++export async function deleteFixedAsset(+ client: SupabaseClient<Database>,+ id: string+) {+ return client.from("fixedAsset").delete().eq("id", id).eq("status", "Draft");+}++export async function deleteDepreciationRun(+ client: SupabaseClient<Database>,+ id: string+) {+ return client+ .from("depreciationRun")+ .delete()+ .eq("id", id)+ .eq("status", "Draft");+}++// -- Depreciation --++export async function getDepreciationRuns(+ client: SupabaseClient<Database>,+ companyId: string,+ args: GenericQueryFilters & { search: string | null }+) {+ let query = client+ .from("depreciationRun")+ .select("id, depreciationRunId, periodEnd, status, postedAt", {+ count: "exact"+ })+ .eq("companyId", companyId);++ if (args.search) {+ query = query.ilike("depreciationRunId", `%${args.search}%`);+ }++ query = setGenericQueryFilters(query, args, [+ { column: "createdAt", ascending: false }+ ]);+ return query;+}++export async function getDepreciationRun(+ client: SupabaseClient<Database>,+ id: string+) {+ return client.from("depreciationRun").select("*").eq("id", id).single();+}++export async function getDepreciationRunLines(+ client: SupabaseClient<Database>,+ depreciationRunId: string+) {+ return client+ .from("depreciationRunLine")+ .select(+ "id, amount, taxAmount, journalId, fixedAsset:fixedAssetId(id, fixedAssetId, name, acquisitionCost, accumulatedDepreciation, accumulatedTaxDepreciation, residualValuePercent)"+ )+ .eq("depreciationRunId", depreciationRunId);+}++// -- Depreciation History for a single asset --++export async function getAssetDepreciationHistory(+ client: SupabaseClient<Database>,+ fixedAssetId: string+) {+ return client+ .from("depreciationRunLine")+ .select(+ "id, amount, taxAmount, journalId, depreciationRun:depreciationRunId(id, depreciationRunId, periodEnd, status)"+ )+ .eq("fixedAssetId", fixedAssetId)+ .order("depreciationRun(periodEnd)", { ascending: false });+}++// -- Disposals --++export async function getFixedAssetDisposal(+ client: SupabaseClient<Database>,+ fixedAssetId: string+) {+ return client+ .from("fixedAssetDisposal")+ .select("*")+ .eq("fixedAssetId", fixedAssetId)+ .maybeSingle();+}++// -- Usage Logs --++export async function getFixedAssetUsageLogs(+ client: SupabaseClient<Database>,+ fixedAssetId: string+) {+ return client+ .from("fixedAssetUsageLog")+ .select("*")+ .eq("fixedAssetId", fixedAssetId)+ .order("periodEnd", { ascending: false });+}++export async function upsertFixedAssetUsageLog(+ client: SupabaseClient<Database>,+ data: Record<string, any> & { companyId: string; createdBy: string }+) {+ return client+ .from("fixedAssetUsageLog")+ .insert([data as any])+ .select("id")+ .single();+}diff --git a/apps/erp/app/modules/accounting/accounting.utils.test.ts b/apps/erp/app/modules/accounting/accounting.utils.test.tsnew file mode 100644index 0000000000..746db3778f--- /dev/null+++ b/apps/erp/app/modules/accounting/accounting.utils.test.ts@@ -0,0 +1,612 @@+import { describe, expect, it } from "vitest";+import {+ addOneMonth,+ buildDepreciationLines,+ calculateDepreciation,+ calculateMacrsDepreciation,+ calculateTaxDepreciation,+ getLastDayOfMonth,+ getMacrsPercentage,+ getMonthsBetween,+ getMonthsElapsed,+ getNextPeriodEnd+} from "./accounting.utils";++// ---------------------------------------------------------------------------+// Date helpers+// ---------------------------------------------------------------------------++describe("getMonthsBetween", () => {+ it("returns 1 for same month when end day >= start day", () => {+ expect(+ getMonthsBetween(new Date("2025-01-15"), new Date("2025-01-20"))+ ).toBe(1);+ });++ it("returns 0 when end day < start day in same month", () => {+ expect(+ getMonthsBetween(new Date("2025-01-20"), new Date("2025-01-15"))+ ).toBe(0);+ });++ it("counts months across years", () => {+ expect(+ getMonthsBetween(new Date("2024-11-01"), new Date("2025-02-01"))+ ).toBe(4);+ });++ it("returns 0 for start after end", () => {+ expect(+ getMonthsBetween(new Date("2025-06-01"), new Date("2025-01-01"))+ ).toBe(0);+ });+});++describe("getMonthsElapsed", () => {+ it("returns 0 for same month", () => {+ expect(+ getMonthsElapsed(new Date("2025-01-15"), new Date("2025-01-20"))+ ).toBe(0);+ });++ it("counts elapsed months", () => {+ expect(+ getMonthsElapsed(new Date("2025-01-01"), new Date("2025-04-01"))+ ).toBe(3);+ });++ it("returns 0 when start after end", () => {+ expect(+ getMonthsElapsed(new Date("2025-06-01"), new Date("2025-01-01"))+ ).toBe(0);+ });+});++describe("addOneMonth", () => {+ it("advances to first of next month", () => {+ const result = addOneMonth("2025-01-15");+ expect(result.getFullYear()).toBe(2025);+ expect(result.getMonth()).toBe(1);+ expect(result.getDate()).toBe(1);+ });++ it("rolls over year boundary", () => {+ const result = addOneMonth("2025-12-15");+ expect(result.getFullYear()).toBe(2026);+ expect(result.getMonth()).toBe(0);+ });+});++describe("getLastDayOfMonth", () => {+ it("returns 28 for Feb 2025", () => {+ expect(getLastDayOfMonth(2025, 1)).toBe("2025-02-28");+ });++ it("returns 29 for Feb 2024 (leap year)", () => {+ expect(getLastDayOfMonth(2024, 1)).toBe("2024-02-29");+ });++ it("returns 31 for January", () => {+ expect(getLastDayOfMonth(2025, 0)).toBe("2025-01-31");+ });+});++describe("getNextPeriodEnd", () => {+ it("returns next month's last day when given a previous period", () => {+ const result = getNextPeriodEnd("2025-01-31");+ expect(result).toBe("2025-02-28");+ });++ it("handles year rollover", () => {+ const result = getNextPeriodEnd("2025-12-31");+ expect(result).toBe("2026-01-31");+ });+});++// ---------------------------------------------------------------------------+// MACRS table lookups+// ---------------------------------------------------------------------------++describe("getMacrsPercentage", () => {+ it("returns null for 27.5-year property", () => {+ expect(getMacrsPercentage("27.5", 1, "Half-Year")).toBeNull();+ });++ it("returns null for 39-year property", () => {+ expect(getMacrsPercentage("39", 1, "Half-Year")).toBeNull();+ });++ it("returns correct half-year 5-year year-1 percentage", () => {+ expect(getMacrsPercentage("5", 1, "Half-Year")).toBe(20.0);+ });++ it("returns correct half-year 7-year year-1 percentage", () => {+ expect(getMacrsPercentage("7", 1, "Half-Year")).toBe(14.29);+ });++ it("returns 0 when year exceeds table length", () => {+ expect(getMacrsPercentage("3", 10, "Half-Year")).toBe(0);+ });++ it("returns correct mid-quarter Q1 5-year year-1 percentage", () => {+ expect(getMacrsPercentage("5", 1, "Mid-Quarter", 1)).toBe(35.0);+ });++ it("returns correct mid-quarter Q4 7-year year-1 percentage", () => {+ expect(getMacrsPercentage("7", 1, "Mid-Quarter", 4)).toBe(3.57);+ });++ it("half-year 5-year table sums to ~100%", () => {+ let total = 0;+ for (let y = 1; y <= 6; y++) {+ total += getMacrsPercentage("5", y, "Half-Year") ?? 0;+ }+ expect(total).toBeCloseTo(100, 0);+ });+});++// ---------------------------------------------------------------------------+// calculateMacrsDepreciation+// ---------------------------------------------------------------------------++describe("calculateMacrsDepreciation", () => {+ it("returns 0 for zero basis", () => {+ expect(+ calculateMacrsDepreciation({+ adjustedBasis: 0,+ propertyClass: "5",+ convention: "Half-Year",+ depreciationStartDate: "2025-01-15",+ periodEnd: "2025-12-31",+ lastPostedPeriodEnd: null,+ accumulatedTaxDepreciation: 0,+ bonusAmount: 0+ })+ ).toBe(0);+ });++ it("calculates year-1 half-year 5-year depreciation on $100,000 asset", () => {+ const result = calculateMacrsDepreciation({+ adjustedBasis: 100000,+ propertyClass: "5",+ convention: "Half-Year",+ depreciationStartDate: "2025-01-15",+ periodEnd: "2025-12-31",+ lastPostedPeriodEnd: null,+ accumulatedTaxDepreciation: 0,+ bonusAmount: 0+ });+ // Year 1 at 20% of $100k = $20,000+ expect(result).toBe(20000);+ });++ it("calculates 39-year property monthly depreciation", () => {+ const result = calculateMacrsDepreciation({+ adjustedBasis: 468000,+ propertyClass: "39",+ convention: "Half-Year",+ depreciationStartDate: "2025-01-15",+ periodEnd: "2025-12-31",+ lastPostedPeriodEnd: null,+ accumulatedTaxDepreciation: 0,+ bonusAmount: 0+ });+ // $468,000 / (39*12) = $1,000/month; 11.5 months for first period+ expect(result).toBeCloseTo(11500, -1);+ });++ it("caps at remaining depreciable amount", () => {+ const result = calculateMacrsDepreciation({+ adjustedBasis: 10000,+ propertyClass: "5",+ convention: "Half-Year",+ depreciationStartDate: "2025-01-15",+ periodEnd: "2025-12-31",+ lastPostedPeriodEnd: null,+ accumulatedTaxDepreciation: 9500,+ bonusAmount: 0+ });+ expect(result).toBeLessThanOrEqual(500);+ });+});++// ---------------------------------------------------------------------------+// calculateDepreciation (book)+// ---------------------------------------------------------------------------++describe("calculateDepreciation", () => {+ const baseAsset = {+ acquisitionCost: 120000,+ accumulatedDepreciation: 0,+ residualValuePercent: 10,+ depreciationMethod: "Straight Line",+ usefulLifeMonths: 60,+ depreciationStartDate: "2025-01-01",+ acquisitionDate: "2025-01-01",+ assetLifetimeUsage: null+ };++ describe("Straight Line", () => {+ it("calculates monthly depreciation correctly", () => {+ // Cost 120k, residual 10% = 12k, depreciable = 108k, monthly = 1800+ // Jan 1 to Jan 31 = 1 month+ const result = calculateDepreciation(baseAsset, "2025-01-31", null);+ expect(result).toBe(1800);+ });++ it("calculates multi-month period", () => {+ // 6 months: 1800 * 6 = 10800+ const result = calculateDepreciation(baseAsset, "2025-06-30", null);+ expect(result).toBeCloseTo(10800, 0);+ });++ it("returns 0 when fully depreciated", () => {+ const fullyDepr = { ...baseAsset, accumulatedDepreciation: 108000 };+ expect(calculateDepreciation(fullyDepr, "2025-06-30", null)).toBe(0);+ });++ it("returns 0 when start date is after period end", () => {+ const futureStart = { ...baseAsset, depreciationStartDate: "2026-01-01" };+ expect(calculateDepreciation(futureStart, "2025-06-30", null)).toBe(0);+ });++ it("caps at remaining depreciable amount", () => {+ const nearlyDone = { ...baseAsset, accumulatedDepreciation: 107500 };+ const result = calculateDepreciation(nearlyDone, "2025-06-30", null);+ expect(result).toBe(500);+ });++ it("uses lastPostedPeriodEnd to narrow the window", () => {+ // addOneMonth("2025-01-31") overflows Feb→Mar 1; Mar 1 to Mar 31 = 1 month+ const result = calculateDepreciation(+ baseAsset,+ "2025-03-31",+ "2025-01-31"+ );+ expect(result).toBeCloseTo(1800, 0);+ });+ });++ describe("Declining Balance", () => {+ const dbAsset = { ...baseAsset, depreciationMethod: "Declining Balance" };++ it("first month produces higher amount than straight line", () => {+ const slResult = calculateDepreciation(baseAsset, "2025-01-31", null);+ const dbResult = calculateDepreciation(dbAsset, "2025-01-31", null);+ expect(dbResult).toBeGreaterThanOrEqual(slResult);+ });++ it("returns 0 when fully depreciated", () => {+ const fullyDepr = { ...dbAsset, accumulatedDepreciation: 108000 };+ expect(calculateDepreciation(fullyDepr, "2025-06-30", null)).toBe(0);+ });+ });++ describe("Units of Production", () => {+ const uopAsset = {+ ...baseAsset,+ depreciationMethod: "Units of Production",+ assetLifetimeUsage: 10000+ };++ it("calculates based on units produced", () => {+ // depreciable 108k / 10k units = $10.80/unit, 100 units = $1080+ const result = calculateDepreciation(uopAsset, "2025-06-30", null, {+ unitsProduced: 100+ });+ expect(result).toBe(1080);+ });++ it("returns 0 without usage log", () => {+ expect(calculateDepreciation(uopAsset, "2025-06-30", null)).toBe(0);+ });++ it("returns 0 with zero lifetime usage", () => {+ const zeroLifetime = { ...uopAsset, assetLifetimeUsage: 0 };+ expect(+ calculateDepreciation(zeroLifetime, "2025-06-30", null, {+ unitsProduced: 100+ })+ ).toBe(0);+ });+ });++ it("returns 0 for unknown method", () => {+ const unknown = { ...baseAsset, depreciationMethod: "SomethingElse" };+ expect(calculateDepreciation(unknown, "2025-06-30", null)).toBe(0);+ });+});++// ---------------------------------------------------------------------------+// calculateTaxDepreciation+// ---------------------------------------------------------------------------++describe("calculateTaxDepreciation", () => {+ it("returns null when no tax method configured", () => {+ const result = calculateTaxDepreciation(+ {+ acquisitionCost: 100000,+ accumulatedTaxDepreciation: 0,+ depreciationStartDate: "2025-01-01",+ acquisitionDate: "2025-01-01",+ taxDepreciationMethod: null,+ taxUsefulLifeMonths: null,+ taxResidualValuePercent: null,+ macrsPropertyClass: null,+ macrsConvention: null,+ bonusDepreciationPercent: null+ },+ "2025-12-31",+ null+ );+ expect(result).toBeNull();+ });++ describe("MACRS", () => {+ const macrsAsset = {+ acquisitionCost: 100000,+ accumulatedTaxDepreciation: 0,+ depreciationStartDate: "2025-01-15",+ acquisitionDate: "2025-01-15",+ taxDepreciationMethod: "MACRS",+ taxUsefulLifeMonths: null,+ taxResidualValuePercent: null,+ macrsPropertyClass: "5",+ macrsConvention: "Half-Year",+ bonusDepreciationPercent: 0+ };++ it("calculates year-1 MACRS without bonus", () => {+ const result = calculateTaxDepreciation(macrsAsset, "2025-12-31", null);+ // 5-year half-year year 1: 20% of $100k = $20,000+ expect(result).toBe(20000);+ });++ it("calculates MACRS for a single-month period (how depreciation runs work)", () => {+ const result = calculateTaxDepreciation(macrsAsset, "2025-05-31", null);+ expect(result).not.toBeNull();+ expect(result!).toBeGreaterThan(0);+ });++ it("calculates MACRS for second monthly period with lastPostedPeriodEnd", () => {+ // Asset placed 2026-05-24, first run posted with periodEnd 2026-05-31+ // Second run for periodEnd 2026-06-30+ const result = calculateTaxDepreciation(+ {+ ...macrsAsset,+ depreciationStartDate: "2026-05-24",+ acquisitionDate: "2026-05-24"+ },+ "2026-06-30",+ "2026-05-31"+ );+ expect(result).not.toBeNull();+ expect(result!).toBeGreaterThan(0);+ });++ it("handles null bonusDepreciationPercent (DB default)", () => {+ const nullBonus = {+ ...macrsAsset,+ bonusDepreciationPercent: null+ };+ const result = calculateTaxDepreciation(nullBonus, "2025-12-31", null);+ expect(result).toBe(20000);+ });++ it("applies bonus depreciation in first period", () => {+ const withBonus = {+ ...macrsAsset,+ bonusDepreciationPercent: 60+ };+ const result = calculateTaxDepreciation(withBonus, "2025-12-31", null);+ // Bonus: 100k * 60% = 60k+ // Adjusted basis: 40k, MACRS year 1: 40k * 20% = 8k+ // Total: 60k + 8k = 68k+ expect(result).toBe(68000);+ });++ it("does not re-apply bonus after first period", () => {+ const withBonus = {+ ...macrsAsset,+ accumulatedTaxDepreciation: 68000,+ bonusDepreciationPercent: 60+ };+ const result = calculateTaxDepreciation(+ withBonus,+ "2026-12-31",+ "2025-12-31"+ );+ // Bonus should NOT be applied again (accumulatedTax > 0)+ // Only MACRS on the $40k adjusted basis+ expect(result).not.toBeNull();+ expect(result!).toBeGreaterThan(0);+ expect(result!).toBeLessThan(60000);+ });++ it("handles 100% bonus depreciation", () => {+ const fullBonus = {+ ...macrsAsset,+ bonusDepreciationPercent: 100+ };+ const result = calculateTaxDepreciation(fullBonus, "2025-12-31", null);+ // Bonus = 100k, adjusted basis = 0, MACRS on 0 = 0+ // Total = 100k+ expect(result).toBe(100000);+ });++ it("handles 7-year property class", () => {+ const sevenYear = {+ ...macrsAsset,+ macrsPropertyClass: "7"+ };+ const result = calculateTaxDepreciation(sevenYear, "2025-12-31", null);+ // 7-year half-year year 1: 14.29% of $100k = $14,290+ expect(result).toBe(14290);+ });+ });++ describe("Straight Line (tax)", () => {+ const slTaxAsset = {+ acquisitionCost: 120000,+ accumulatedTaxDepreciation: 0,+ depreciationStartDate: "2025-01-01",+ acquisitionDate: "2025-01-01",+ taxDepreciationMethod: "Straight Line",+ taxUsefulLifeMonths: 120,+ taxResidualValuePercent: 0,+ macrsPropertyClass: null,+ macrsConvention: null,+ bonusDepreciationPercent: null+ };++ it("calculates tax straight-line depreciation", () => {+ // $120k / 120 months = $1k/month; Jan to Dec = 12 months = $12k+ const result = calculateTaxDepreciation(slTaxAsset, "2025-12-31", null);+ expect(result).toBeCloseTo(12000, 0);+ });++ it("returns 0 when fully depreciated", () => {+ const fullyDepr = { ...slTaxAsset, accumulatedTaxDepreciation: 120000 };+ const result = calculateTaxDepreciation(fullyDepr, "2025-12-31", null);+ expect(result).toBe(0);+ });+ });++ describe("Declining Balance (tax)", () => {+ const dbTaxAsset = {+ acquisitionCost: 100000,+ accumulatedTaxDepreciation: 0,+ depreciationStartDate: "2025-01-01",+ acquisitionDate: "2025-01-01",+ taxDepreciationMethod: "Declining Balance",+ taxUsefulLifeMonths: 60,+ taxResidualValuePercent: 10,+ macrsPropertyClass: null,+ macrsConvention: null,+ bonusDepreciationPercent: null+ };++ it("produces a positive result", () => {+ const result = calculateTaxDepreciation(dbTaxAsset, "2025-12-31", null);+ expect(result).not.toBeNull();+ expect(result!).toBeGreaterThan(0);+ });++ it("returns 0 when fully depreciated", () => {+ const fullyDepr = { ...dbTaxAsset, accumulatedTaxDepreciation: 90000 };+ const result = calculateTaxDepreciation(fullyDepr, "2025-12-31", null);+ expect(result).toBe(0);+ });+ });+});++// ---------------------------------------------------------------------------+// buildDepreciationLines+// ---------------------------------------------------------------------------++describe("buildDepreciationLines", () => {+ const baseAsset = {+ id: "asset-1",+ acquisitionCost: 120000,+ accumulatedDepreciation: 0,+ residualValuePercent: 10,+ depreciationMethod: "Straight Line",+ usefulLifeMonths: 60,+ depreciationStartDate: "2025-01-01",+ acquisitionDate: "2025-01-01",+ assetLifetimeUsage: null,+ accumulatedTaxDepreciation: 0,+ taxDepreciationMethod: "MACRS",+ taxUsefulLifeMonths: null,+ taxResidualValuePercent: null,+ macrsPropertyClass: "5",+ macrsConvention: "Half-Year",+ bonusDepreciationPercent: 0+ };++ it("returns book and tax amounts when tax is enabled", () => {+ const lines = buildDepreciationLines(+ [baseAsset],+ "2025-12-31",+ null,+ true,+ new Map()+ );+ expect(lines).toHaveLength(1);+ expect(lines[0].amount).toBeGreaterThan(0);+ expect(lines[0].taxAmount).not.toBeNull();+ expect(lines[0].taxAmount!).toBeGreaterThan(0);+ });++ it("returns null taxAmount when tax is disabled", () => {+ const lines = buildDepreciationLines(+ [baseAsset],+ "2025-12-31",+ null,+ false,+ new Map()+ );+ expect(lines).toHaveLength(1);+ expect(lines[0].amount).toBeGreaterThan(0);+ expect(lines[0].taxAmount).toBeNull();+ });++ it("skips assets with zero depreciation", () => {+ const fullyDepr = {+ ...baseAsset,+ accumulatedDepreciation: 108000,+ accumulatedTaxDepreciation: 120000+ };+ const lines = buildDepreciationLines(+ [fullyDepr],+ "2025-12-31",+ null,+ true,+ new Map()+ );+ expect(lines).toHaveLength(0);+ });++ it("includes line when only tax amount is positive", () => {+ const bookDone = {+ ...baseAsset,+ accumulatedDepreciation: 108000,+ accumulatedTaxDepreciation: 0+ };+ const lines = buildDepreciationLines(+ [bookDone],+ "2025-12-31",+ null,+ true,+ new Map()+ );+ expect(lines).toHaveLength(1);+ expect(lines[0].amount).toBe(0);+ expect(lines[0].taxAmount!).toBeGreaterThan(0);+ });++ it("handles multiple assets", () => {+ const asset2 = { ...baseAsset, id: "asset-2" };+ const lines = buildDepreciationLines(+ [baseAsset, asset2],+ "2025-12-31",+ null,+ true,+ new Map()+ );+ expect(lines).toHaveLength(2);+ });++ it("book vs tax difference: MACRS produces more year-1 depreciation than SL", () => {+ const lines = buildDepreciationLines(+ [baseAsset],+ "2025-12-31",+ null,+ true,+ new Map()+ );+ // Book SL: 108k/60mo * 12mo = $21,600+ // Tax MACRS 5-yr HY: 120k * 20% = $24,000+ expect(lines[0].taxAmount!).toBeGreaterThan(lines[0].amount);+ });+});diff --git a/apps/erp/app/modules/accounting/accounting.utils.ts b/apps/erp/app/modules/accounting/accounting.utils.tsnew file mode 100644index 0000000000..436b7dafdb--- /dev/null+++ b/apps/erp/app/modules/accounting/accounting.utils.ts@@ -0,0 +1,524 @@+export const macrsPropertyClasses = [+ "3",+ "5",+ "7",+ "10",+ "15",+ "20",+ "27.5",+ "39"+] as const;++export const macrsConventions = ["Half-Year", "Mid-Quarter"] as const;++export type MacrsPropertyClass = (typeof macrsPropertyClasses)[number];+export type MacrsConvention = (typeof macrsConventions)[number];++// IRS Revenue Procedure 87-57, Table 1 (GDS, Half-Year Convention)+const MACRS_HALF_YEAR: Record<string, number[]> = {+ "3": [33.33, 44.45, 14.81, 7.41],+ "5": [20.0, 32.0, 19.2, 11.52, 11.52, 5.76],+ "7": [14.29, 24.49, 17.49, 12.49, 8.93, 8.92, 8.93, 4.46],+ "10": [10.0, 18.0, 14.4, 11.52, 9.22, 7.37, 6.55, 6.55, 6.56, 6.55, 3.28],+ "15": [+ 5.0, 9.5, 8.55, 7.7, 6.93, 6.23, 5.9, 5.9, 5.91, 5.9, 5.91, 5.9, 5.91, 5.9,+ 5.91, 2.95+ ],+ "20": [+ 3.75, 7.219, 6.677, 6.177, 5.713, 5.285, 4.888, 4.522, 4.462, 4.461, 4.462,+ 4.461, 4.462, 4.461, 4.462, 4.461, 4.462, 4.461, 4.462, 4.461, 2.231+ ]+};++// IRS Tables 2-5 (GDS, Mid-Quarter Convention)+const MACRS_MID_QUARTER: Record<string, Record<number, number[]>> = {+ "3": {+ 1: [58.33, 27.78, 12.35, 1.54],+ 2: [41.67, 38.89, 14.14, 5.3],+ 3: [25.0, 50.0, 16.67, 8.33],+ 4: [8.33, 61.11, 20.37, 10.19]+ },+ "5": {+ 1: [35.0, 26.0, 15.6, 11.01, 11.01, 1.38],+ 2: [25.0, 30.0, 18.0, 11.37, 11.37, 4.26],+ 3: [15.0, 34.0, 20.4, 12.24, 11.3, 7.06],+ 4: [5.0, 38.0, 22.8, 13.68, 10.94, 9.58]+ },+ "7": {+ 1: [25.0, 21.43, 15.31, 10.93, 8.75, 8.74, 8.75, 1.09],+ 2: [17.85, 23.47, 16.76, 11.97, 8.87, 8.87, 8.87, 3.34],+ 3: [10.71, 25.51, 18.22, 13.02, 9.3, 8.85, 8.86, 5.53],+ 4: [3.57, 27.55, 19.68, 14.06, 10.04, 8.73, 8.73, 7.64]+ },+ "10": {+ 1: [17.5, 16.5, 13.2, 10.56, 8.45, 6.76, 6.55, 6.55, 6.56, 6.55, 0.82],+ 2: [12.5, 17.5, 14.0, 11.2, 8.96, 7.17, 6.55, 6.55, 6.56, 6.55, 2.46],+ 3: [7.5, 18.5, 14.8, 11.84, 9.47, 7.58, 6.55, 6.55, 6.56, 6.55, 4.1],+ 4: [2.5, 19.5, 15.6, 12.48, 9.98, 7.99, 6.55, 6.55, 6.56, 6.55, 5.74]+ },+ "15": {+ 1: [+ 8.75, 9.13, 8.21, 7.39, 6.65, 5.99, 5.9, 5.9, 5.91, 5.9, 5.91, 5.9, 5.91,+ 5.9, 5.91, 0.74+ ],+ 2: [+ 6.25, 9.38, 8.44, 7.59, 6.83, 6.15, 5.9, 5.9, 5.91, 5.9, 5.91, 5.9, 5.91,+ 5.9, 5.91, 2.21+ ],+ 3: [+ 3.75, 9.63, 8.66, 7.8, 7.02, 6.31, 5.9, 5.9, 5.91, 5.9, 5.91, 5.9, 5.91,+ 5.9, 5.91, 3.69+ ],+ 4: [+ 1.25, 9.88, 8.89, 8.0, 7.2, 6.48, 5.9, 5.9, 5.91, 5.9, 5.91, 5.9, 5.91,+ 5.9, 5.91, 5.17+ ]+ },+ "20": {+ 1: [+ 6.563, 7.0, 6.482, 5.996, 5.546, 5.13, 4.746, 4.459, 4.459, 4.459, 4.459,+ 4.46, 4.459, 4.46, 4.459, 4.46, 4.459, 4.46, 4.459, 4.46, 0.557+ ],+ 2: [+ 4.688, 7.148, 6.612, 6.116, 5.658, 5.233, 4.841, 4.478, 4.463, 4.463,+ 4.463, 4.463, 4.463, 4.463, 4.463, 4.462, 4.463, 4.462, 4.463, 4.462,+ 1.673+ ],+ 3: [+ 2.813, 7.289, 6.742, 6.237, 5.769, 5.336, 4.936, 4.566, 4.46, 4.46, 4.46,+ 4.461, 4.46, 4.461, 4.46, 4.461, 4.46, 4.461, 4.46, 4.461, 2.788+ ],+ 4: [+ 0.938, 7.43, 6.872, 6.357, 5.88, 5.439, 5.031, 4.654, 4.458, 4.458, 4.458,+ 4.458, 4.458, 4.458, 4.458, 4.458, 4.458, 4.458, 4.459, 4.458, 3.901+ ]+ }+};++export function getMacrsPercentage(+ propertyClass: MacrsPropertyClass,+ yearInService: number,+ convention: MacrsConvention,+ quarterPlacedInService?: number+): number | null {+ if (propertyClass === "27.5" || propertyClass === "39") {+ return null;+ }++ const yearIndex = yearInService - 1;++ if (convention === "Half-Year") {+ const table = MACRS_HALF_YEAR[propertyClass];+ if (!table || yearIndex >= table.length) return 0;+ return table[yearIndex];+ }++ const quarter = quarterPlacedInService ?? 1;+ const classTable = MACRS_MID_QUARTER[propertyClass];+ if (!classTable) return 0;+ const table = classTable[quarter];+ if (!table || yearIndex >= table.length) return 0;+ return table[yearIndex];+}++export function calculateMacrsDepreciation(args: {+ adjustedBasis: number;+ propertyClass: MacrsPropertyClass;+ convention: MacrsConvention;+ depreciationStartDate: string;+ periodEnd: string;+ lastPostedPeriodEnd: string | null;+ accumulatedTaxDepreciation: number;+ bonusAmount: number;+}): number {+ const {+ adjustedBasis,+ propertyClass,+ convention,+ depreciationStartDate,+ periodEnd,+ lastPostedPeriodEnd,+ accumulatedTaxDepreciation,+ bonusAmount+ } = args;++ if (adjustedBasis <= 0) return 0;++ const startDate = new Date(depreciationStartDate);+ const periodEndDate = new Date(periodEnd);+ const fromDate = lastPostedPeriodEnd+ ? new Date(lastPostedPeriodEnd)+ : startDate;++ // 27.5 and 39-year property: straight-line with mid-month convention+ if (propertyClass === "27.5" || propertyClass === "39") {+ const lifeMonths = propertyClass === "27.5" ? 27.5 * 12 : 39 * 12;+ const monthlyAmount = adjustedBasis / lifeMonths;+ const monthsElapsed =+ (periodEndDate.getFullYear() - fromDate.getFullYear()) * 12 ++ (periodEndDate.getMonth() - fromDate.getMonth());+ const months = lastPostedPeriodEnd ? monthsElapsed : monthsElapsed + 0.5;+ const amount = monthlyAmount * Math.max(0, months);+ const remaining =+ adjustedBasis - (accumulatedTaxDepreciation - bonusAmount);+ return Math.min(Math.round(amount * 100) / 100, Math.max(0, remaining));+ }++ // Table-based MACRS: compute cumulative depreciation through periodEnd,+ // then subtract what has already been taken (accumulatedTaxDepreciation - bonusAmount).+ // MACRS years are calendar years. The IRS percentages already incorporate the+ // convention (half-year or mid-quarter), so year 1 = the full first calendar year amount.+ // Year 1 is spread across months from placed-in-service through Dec 31.+ // Subsequent years are spread evenly across 12 calendar months.+ const quarterPlaced = Math.ceil((startDate.getMonth() + 1) / 3);+ const startYear = startDate.getFullYear();+ const periodEndYear = periodEndDate.getFullYear();+ const lastYearToCalc = periodEndYear - startYear + 1;+ const startMonth = startDate.getMonth(); // 0-based++ let cumulativeThrough = 0;++ for (let year = 1; year <= lastYearToCalc; year++) {+ const pct = getMacrsPercentage(+ propertyClass,+ year,+ convention,+ quarterPlaced+ );+ if (pct === null || pct === 0) continue;++ const annualAmount = adjustedBasis * (pct / 100);+ const totalMonthsInYear = year === 1 ? 12 - startMonth : 12;+ const monthlyAmount = annualAmount / totalMonthsInYear;++ if (year < lastYearToCalc) {+ cumulativeThrough += annualAmount;+ } else {+ // Count months from the start of this MACRS year through periodEnd+ const yearStartMonth = year === 1 ? startMonth : 0;+ const calendarYear = startYear + year - 1;+ const periodEndMonth =+ periodEndDate.getFullYear() === calendarYear+ ? periodEndDate.getMonth()+ : 11;++ const monthsElapsed = periodEndMonth - yearStartMonth + 1;+ cumulativeThrough +=+ monthlyAmount * Math.min(monthsElapsed, totalMonthsInYear);+ }+ }++ const alreadyTaken = accumulatedTaxDepreciation - bonusAmount;+ const periodAmount = cumulativeThrough - Math.max(0, alreadyTaken);+ const remaining = adjustedBasis - Math.max(0, alreadyTaken);+ return Math.min(+ Math.round(Math.max(0, periodAmount) * 100) / 100,+ Math.max(0, remaining)+ );+}++export type DepreciationLine = {+ fixedAssetId: string;+ amount: number;+ taxAmount: number | null;+};++export function getMonthsBetween(start: Date, end: Date): number {+ const years = end.getFullYear() - start.getFullYear();+ const months = end.getMonth() - start.getMonth();+ let total = years * 12 + months;+ if (end.getDate() >= start.getDate()) total += 1;+ return Math.max(0, total);+}++export function getMonthsElapsed(start: Date, end: Date): number {+ const years = end.getFullYear() - start.getFullYear();+ const months = end.getMonth() - start.getMonth();+ return Math.max(0, years * 12 + months);+}++export function addOneMonth(dateStr: string): Date {+ const d = new Date(dateStr);+ d.setMonth(d.getMonth() + 1);+ d.setDate(1);+ return d;+}++export function getLastDayOfMonth(year: number, month: number): string {+ const d = new Date(year, month + 1, 0);+ return d.toISOString().split("T")[0];+}++export function getNextPeriodEnd(lastPeriodEnd: string | null): string {+ if (lastPeriodEnd) {+ const last = new Date(lastPeriodEnd);+ const nextMonth = last.getMonth() + 1;+ const nextYear = last.getFullYear() + (nextMonth > 11 ? 1 : 0);+ return getLastDayOfMonth(nextYear, nextMonth % 12);+ }+ const now = new Date();+ return getLastDayOfMonth(now.getFullYear(), now.getMonth());+}++export function calculateDepreciation(+ asset: {+ acquisitionCost: number;+ accumulatedDepreciation: number;+ residualValuePercent: number;+ depreciationMethod: string;+ usefulLifeMonths: number;+ depreciationStartDate: string | null;+ acquisitionDate: string | null;+ assetLifetimeUsage: number | null;+ },+ periodEnd: string,+ lastPostedPeriodEnd: string | null,+ usageLog?: { unitsProduced: number }+): number {+ const cost = Number(asset.acquisitionCost);+ const residualValue = cost * (Number(asset.residualValuePercent) / 100);+ const depreciableBase = cost - residualValue;+ const accumulated = Number(asset.accumulatedDepreciation);+ const remainingDepreciable = depreciableBase - accumulated;++ if (remainingDepreciable <= 0) return 0;++ const periodEndDate = new Date(periodEnd);+ const startDate = new Date(+ asset.depreciationStartDate ?? asset.acquisitionDate!+ );++ if (startDate > periodEndDate) return 0;++ switch (asset.depreciationMethod) {+ case "Straight Line": {+ const monthlyAmount = depreciableBase / asset.usefulLifeMonths;+ const from = lastPostedPeriodEnd+ ? addOneMonth(lastPostedPeriodEnd)+ : startDate;+ const monthsToDepreciate = getMonthsBetween(from, periodEndDate);+ const amount = monthlyAmount * monthsToDepreciate;+ return Math.min(Math.round(amount * 100) / 100, remainingDepreciable);+ }+ case "Declining Balance": {+ const annualRate = (1 / (asset.usefulLifeMonths / 12)) * 2;+ const monthlyRate = annualRate / 12;+ const from = lastPostedPeriodEnd+ ? addOneMonth(lastPostedPeriodEnd)+ : startDate;+ const monthsToDepreciate = getMonthsBetween(from, periodEndDate);+ let totalDepr = 0;+ let nbv = cost - accumulated;+ for (let i = 0; i < monthsToDepreciate; i++) {+ const dbAmount = nbv * monthlyRate;+ const remainingMonths = Math.max(+ 1,+ asset.usefulLifeMonths -+ getMonthsElapsed(startDate, periodEndDate) ++ monthsToDepreciate -+ i+ );+ const slAmount = (nbv - residualValue) / remainingMonths;+ const amount = Math.max(dbAmount, slAmount);+ const capped = Math.min(amount, nbv - residualValue);+ if (capped <= 0) break;+ totalDepr += capped;+ nbv -= capped;+ }+ return Math.min(Math.round(totalDepr * 100) / 100, remainingDepreciable);+ }+ case "Units of Production": {+ if (+ !usageLog ||+ !asset.assetLifetimeUsage ||+ Number(asset.assetLifetimeUsage) <= 0+ )+ return 0;+ const ratePerUnit = depreciableBase / Number(asset.assetLifetimeUsage);+ const amount = ratePerUnit * usageLog.unitsProduced;+ return Math.min(Math.round(amount * 100) / 100, remainingDepreciable);+ }+ default:+ return 0;+ }+}++export function calculateTaxDepreciation(+ asset: {+ acquisitionCost: number;+ accumulatedTaxDepreciation: number;+ depreciationStartDate: string | null;+ acquisitionDate: string | null;+ taxDepreciationMethod: string | null;+ taxUsefulLifeMonths: number | null;+ taxResidualValuePercent: number | null;+ macrsPropertyClass: string | null;+ macrsConvention: string | null;+ bonusDepreciationPercent: number | null;+ },+ periodEnd: string,+ lastPostedPeriodEnd: string | null+): number | null {+ const taxMethod = asset.taxDepreciationMethod;+ if (!taxMethod) return null;++ const cost = Number(asset.acquisitionCost);+ const accumulatedTax = Number(asset.accumulatedTaxDepreciation);+ const startDate = asset.depreciationStartDate ?? asset.acquisitionDate!;++ if (taxMethod === "MACRS") {+ const propertyClass = asset.macrsPropertyClass! as MacrsPropertyClass;+ const convention = (asset.macrsConvention ??+ "Half-Year") as MacrsConvention;+ const bonusPct = Number(asset.bonusDepreciationPercent ?? 0);+ const bonusAmount = cost * (bonusPct / 100);+ const adjustedBasis = cost - bonusAmount;++ let bonus = 0;+ if (accumulatedTax === 0 && bonusAmount > 0) {+ bonus = bonusAmount;+ }++ const macrsAmount = calculateMacrsDepreciation({+ adjustedBasis,+ propertyClass,+ convention,+ depreciationStartDate: startDate,+ periodEnd,+ lastPostedPeriodEnd,+ accumulatedTaxDepreciation: accumulatedTax,+ bonusAmount+ });++ return Math.round((bonus + macrsAmount) * 100) / 100;+ }++ const taxLife = asset.taxUsefulLifeMonths!;+ const taxResidualPct = Number(asset.taxResidualValuePercent ?? 0);+ const residualValue = cost * (taxResidualPct / 100);+ const depreciableBase = cost - residualValue;+ const remainingDepreciable = depreciableBase - accumulatedTax;++ if (remainingDepreciable <= 0) return 0;++ const periodEndDate = new Date(periodEnd);+ const depStartDate = new Date(startDate);++ if (depStartDate > periodEndDate) return 0;++ const from = lastPostedPeriodEnd+ ? addOneMonth(lastPostedPeriodEnd)+ : depStartDate;+ const monthsToDepreciate = getMonthsBetween(from, periodEndDate);++ if (taxMethod === "Straight Line") {+ const monthlyAmount = depreciableBase / taxLife;+ const amount = monthlyAmount * monthsToDepreciate;+ return Math.min(Math.round(amount * 100) / 100, remainingDepreciable);+ }++ if (taxMethod === "Declining Balance") {+ const annualRate = (1 / (taxLife / 12)) * 2;+ const monthlyRate = annualRate / 12;+ let totalDepr = 0;+ let nbv = cost - accumulatedTax;+ for (let i = 0; i < monthsToDepreciate; i++) {+ const dbAmount = nbv * monthlyRate;+ const remainingMonths = Math.max(+ 1,+ taxLife -+ getMonthsElapsed(depStartDate, periodEndDate) ++ monthsToDepreciate -+ i+ );+ const slAmount = (nbv - residualValue) / remainingMonths;+ const amount = Math.max(dbAmount, slAmount);+ const capped = Math.min(amount, nbv - residualValue);+ if (capped <= 0) break;+ totalDepr += capped;+ nbv -= capped;+ }+ return Math.min(Math.round(totalDepr * 100) / 100, remainingDepreciable);+ }++ return null;+}++export function buildDepreciationLines(+ assets: Array<{+ id: string;+ acquisitionCost: number;+ accumulatedDepreciation: number;+ residualValuePercent: number;+ depreciationMethod: string;+ usefulLifeMonths: number;+ depreciationStartDate: string | null;+ acquisitionDate: string | null;+ assetLifetimeUsage: number | null;+ accumulatedTaxDepreciation?: number;+ taxDepreciationMethod: string | null;+ taxUsefulLifeMonths: number | null;+ taxResidualValuePercent: number | null;+ macrsPropertyClass: string | null;+ macrsConvention: string | null;+ bonusDepreciationPercent: number | null;+ }>,+ periodEnd: string,+ lastPostedPeriodEnd: string | null,+ taxEnabled: boolean,+ usageMap: Map<string, { unitsProduced: number }>+): DepreciationLine[] {+ const lines: DepreciationLine[] = [];++ for (const asset of assets) {+ const usageLog = usageMap.get(asset.id);+ const amount = calculateDepreciation(+ {+ acquisitionCost: Number(asset.acquisitionCost),+ accumulatedDepreciation: Number(asset.accumulatedDepreciation),+ residualValuePercent: Number(asset.residualValuePercent),+ depreciationMethod: asset.depreciationMethod,+ usefulLifeMonths: asset.usefulLifeMonths,+ depreciationStartDate: asset.depreciationStartDate,+ acquisitionDate: asset.acquisitionDate,+ assetLifetimeUsage: asset.assetLifetimeUsage+ ? Number(asset.assetLifetimeUsage)+ : null+ },+ periodEnd,+ lastPostedPeriodEnd,+ usageLog+ );++ let taxAmount: number | null = null;+ if (taxEnabled) {+ taxAmount = calculateTaxDepreciation(+ {+ acquisitionCost: Number(asset.acquisitionCost),+ accumulatedTaxDepreciation: Number(+ asset.accumulatedTaxDepreciation ?? 0+ ),+ depreciationStartDate: asset.depreciationStartDate,+ acquisitionDate: asset.acquisitionDate,+ taxDepreciationMethod: asset.taxDepreciationMethod,+ taxUsefulLifeMonths: asset.taxUsefulLifeMonths,+ taxResidualValuePercent: asset.taxResidualValuePercent,+ macrsPropertyClass: asset.macrsPropertyClass,+ macrsConvention: asset.macrsConvention,+ bonusDepreciationPercent: asset.bonusDepreciationPercent+ },+ periodEnd,+ lastPostedPeriodEnd+ );+ if (taxAmount === null) {+ taxAmount = amount;+ }+ }++ if (amount > 0 || (taxAmount !== null && taxAmount > 0)) {+ lines.push({ fixedAssetId: asset.id, amount, taxAmount });+ }+ }++ return lines;+}diff --git a/apps/erp/app/modules/accounting/types.ts b/apps/erp/app/modules/accounting/types.tsindex 9445086a21..54dad17d8a 100644--- a/apps/erp/app/modules/accounting/types.ts+++ b/apps/erp/app/modules/accounting/types.ts@@ -398,3 +398,53 @@ export type JournalEntryListItem = NonNullable<>[number];export type JournalEntryLine = JournalEntry["journalLine"][number];++// -- Fixed Asset types --++import type {+ getAssetDepreciationHistory,+ getDepreciationRun,+ getDepreciationRunLines,+ getDepreciationRuns,+ getFixedAsset,+ getFixedAssetClass,+ getFixedAssetClasses,+ getFixedAssetDisposal,+ getFixedAssets+} from "./accounting.service";++export type FixedAssetClass = NonNullable<+ Awaited<ReturnType<typeof getFixedAssetClass>>["data"]+>;++export type FixedAssetClassListItem = NonNullable<+ NonNullable<Awaited<ReturnType<typeof getFixedAssetClasses>>>["data"]+>[number];++export type FixedAsset = NonNullable<+ Awaited<ReturnType<typeof getFixedAsset>>["data"]+>;++export type FixedAssetListItem = NonNullable<+ NonNullable<Awaited<ReturnType<typeof getFixedAssets>>>["data"]+>[number];++export type DepreciationRun = NonNullable<+ Awaited<ReturnType<typeof getDepreciationRun>>["data"]+>;++export type DepreciationRunListItem = NonNullable<+ NonNullable<Awaited<ReturnType<typeof getDepreciationRuns>>>["data"]+>[number];++export type DepreciationRunLineItem = NonNullable<+ NonNullable<Awaited<ReturnType<typeof getDepreciationRunLines>>>["data"]+>[number];++export type AssetDepreciationHistoryItem = NonNullable<+ NonNullable<Awaited<ReturnType<typeof getAssetDepreciationHistory>>>["data"]+>[number];++export type FixedAssetDisposal = NonNullable<+ Awaited<ReturnType<typeof getFixedAssetDisposal>>["data"]+>;diff --git a/apps/erp/app/modules/accounting/ui/AccountDefaults/AccountDefaultsForm.tsx b/apps/erp/app/modules/accounting/ui/AccountDefaults/AccountDefaultsForm.tsxindex 9c9334d142..587290557b 100644--- a/apps/erp/app/modules/accounting/ui/AccountDefaults/AccountDefaultsForm.tsx+++ b/apps/erp/app/modules/accounting/ui/AccountDefaults/AccountDefaultsForm.tsx@@ -205,6 +205,14 @@ const categoryGroups: CategoryGroup[] = [description: "Tax liability for reverse-charge transactions",accountType: "balance",badgeType: "Liability"+ },+ {+ name: "deferredTaxLiabilityAccountId",+ label: "Deferred Tax Liability",+ description:+ "Liability account for deferred taxes from accelerated depreciation",+ accountType: "balance",+ badgeType: "Liability"}]},@@ -397,6 +405,14 @@ const categoryGroups: CategoryGroup[] = [description: "Account for small rounding differences in transactions",accountType: "income",badgeType: "Expense"+ },+ {+ name: "deferredTaxExpenseAccountId",+ label: "Deferred Tax Expense",+ description:+ "Expense account for deferred tax adjustments on depreciation",+ accountType: "income",+ badgeType: "Expense"}]}diff --git a/apps/erp/app/modules/accounting/ui/ChartOfAccounts/ChartOfAccountsTableFilters.tsx b/apps/erp/app/modules/accounting/ui/ChartOfAccounts/ChartOfAccountsTableFilters.tsxindex 91955de3c7..9d67666a2a 100644--- a/apps/erp/app/modules/accounting/ui/ChartOfAccounts/ChartOfAccountsTableFilters.tsx+++ b/apps/erp/app/modules/accounting/ui/ChartOfAccounts/ChartOfAccountsTableFilters.tsx@@ -2,21 +2,29 @@ import {Button,DatePicker,HStack,+ Input,+ InputGroup,+ InputLeftElement,Popover,PopoverContent,PopoverHeader,- PopoverTrigger,- ToggleGroup,- ToggleGroupItem+ PopoverTrigger} from "@carbon/react";import { parseDate } from "@internationalized/date";import { Trans, useLingui } from "@lingui/react/macro";-import { LuCalendarDays, LuX } from "react-icons/lu";+import { LuCalendarDays, LuSearch, LuX } from "react-icons/lu";import { New } from "~/components";import { usePermissions, useUrlParams } from "~/hooks";-import { incomeBalanceTypes } from "../../accounting.models";-const ChartOfAccountsTableFilters = () => {+type ChartOfAccountsTableFiltersProps = {+ search: string;+ onSearchChange: (value: string) => void;+};++const ChartOfAccountsTableFilters = ({+ search,+ onSearchChange+}: ChartOfAccountsTableFiltersProps) => {const { t } = useLingui();const [params, setParams] = useUrlParams();const permissions = usePermissions();@@ -27,23 +35,16 @@ const ChartOfAccountsTableFilters = () => {return (<div className="flex px-4 py-3 items-center space-x-4 justify-between bg-card border-b border-border w-full"><HStack>- <ToggleGroup- type="single"- size="sm"- variant="outline"- value={params.get("incomeBalance") ?? ""}- onValueChange={(value) =>- setParams({ incomeBalance: value || undefined })- }- >- {incomeBalanceTypes.map((type) => (- <ToggleGroupItem key={type} value={type}>- {type === "Balance Sheet"- ? t`Balance Sheet`- : t`Income Statement`}- </ToggleGroupItem>- ))}- </ToggleGroup>+ <InputGroup size="sm" className="w-64">+ <InputLeftElement>+ <LuSearch className="h-4 w-4 text-muted-foreground" />+ </InputLeftElement>+ <Input+ placeholder={t`Search accounts...`}+ value={search}+ onChange={(e) => onSearchChange(e.target.value)}+ />+ </InputGroup><Popover><PopoverTrigger asChild><Button variant="secondary" leftIcon={<LuCalendarDays />}>@@ -88,7 +89,6 @@ const ChartOfAccountsTableFilters = () => {rightIcon={<LuX />}onClick={() =>setParams({- incomeBalance: undefined,startDate: undefined,endDate: undefined})diff --git a/apps/erp/app/modules/accounting/ui/ChartOfAccounts/ChartOfAccountsTree.tsx b/apps/erp/app/modules/accounting/ui/ChartOfAccounts/ChartOfAccountsTree.tsxindex 156f0c42d5..db86d85a8f 100644--- a/apps/erp/app/modules/accounting/ui/ChartOfAccounts/ChartOfAccountsTree.tsx+++ b/apps/erp/app/modules/accounting/ui/ChartOfAccounts/ChartOfAccountsTree.tsx@@ -26,6 +26,7 @@ import type { Chart } from "../../types";type ChartOfAccountsTreeProps = {data: Chart[];+ search: string;};function accountsToFlatTree(accounts: Chart[]): FlatTree<Chart> {@@ -66,6 +67,30 @@ function accountsToFlatTree(accounts: Chart[]): FlatTree<Chart> {return result;}+function filterAccounts(accounts: Chart[], search: string): Chart[] {+ if (!search.trim()) return accounts;+ const lower = search.toLowerCase();++ const byId = new Map(accounts.map((a) => [a.id, a]));+ const matched = new Set<string>();++ for (const a of accounts) {+ const nameMatch = a.name?.toLowerCase().includes(lower);+ const numberMatch = a.number?.toLowerCase().includes(lower);+ if (nameMatch || numberMatch) {+ matched.add(a.id as string);+ let parentId = a.parentId;+ while (parentId) {+ matched.add(parentId);+ const parent = byId.get(parentId);+ parentId = parent?.parentId ?? null;+ }+ }+ }++ return accounts.filter((a) => matched.has(a.id as string));+}+function formatCurrency(value: number): string {return value.toLocaleString(undefined, {minimumFractionDigits: 2,@@ -73,160 +98,182 @@ function formatCurrency(value: number): string {});}-const ChartOfAccountsTree = memo(({ data }: ChartOfAccountsTreeProps) => {- useRealtime("journal");- const settings = useSettings();- const accountingEnabled = (settings as any).accountingEnabled ?? false;- const parentRef = useRef<HTMLDivElement>(null);- const navigate = useNavigate();-- const tree = useMemo(() => accountsToFlatTree(data), [data]);+const ChartOfAccountsTree = memo(+ ({ data, search }: ChartOfAccountsTreeProps) => {+ useRealtime("journal");+ const settings = useSettings();+ const accountingEnabled = (settings as any).accountingEnabled ?? false;+ const parentRef = useRef<HTMLDivElement>(null);+ const navigate = useNavigate();- const {- nodes,- getTreeProps,- getNodeProps,- selectNode,- toggleExpandNode,- virtualizer- } = useTree<Chart, undefined>({- tree,- parentRef,- estimatedRowHeight: () => 36,- isEager: true- });+ const filtered = useMemo(+ () => filterAccounts(data, search),+ [data, search]+ );+ const tree = useMemo(() => accountsToFlatTree(filtered), [filtered]);- return (- <ScrollArea className="h-[calc(100dvh-var(--header-height)-61px)] w-full">- <div className="sticky top-0 z-10 flex h-11 items-center pr-4 text-sm font-medium text-foreground/80 border-b border-border bg-card">- <div className="flex-1 px-4">Account</div>- {accountingEnabled && (- <span className="w-32 text-right px-4">Balance</span>- )}- </div>- <TreeView<Chart>- tree={tree}- nodes={nodes}- getTreeProps={getTreeProps}- getNodeProps={getNodeProps}- virtualizer={virtualizer}- parentRef={parentRef}- parentClassName="h-full"- renderNode={({ node, state }) => {- const account = node.data;- const isGroup = account.isGroup;- const isExpanded = state.expanded;+ const {+ nodes,+ getTreeProps,+ getNodeProps,+ selectNode,+ toggleExpandNode,+ virtualizer+ } = useTree<Chart, undefined>({+ tree,+ parentRef,+ estimatedRowHeight: () => 36,+ isEager: true+ });- return (- <div- className={cn(- "flex h-8 cursor-pointer items-center overflow-hidden pr-4 text-sm group/row",- state.selected- ? "bg-muted hover:bg-accent"- : "bg-transparent hover:bg-accent",- isGroup && "font-semibold"- )}- onClick={() => {- selectNode(node.id, false);- if (isGroup) {- toggleExpandNode(node.id);- } else {- navigate(account.id as string);- }- }}- >- {/* Indentation lines */}- <div className="flex h-9 items-center">- {Array.from({ length: node.level }).map((_, index) => (- <LevelLine key={index} isSelected={state.selected} />- ))}+ return (+ <ScrollArea className="h-[calc(100dvh-var(--header-height)-61px)] w-full">+ <div className="sticky top-0 z-10 flex h-11 items-center pr-4 text-sm font-medium text-foreground/80 border-b border-border bg-card">+ <div className="flex-1 px-4">Account</div>+ {accountingEnabled && (+ <span className="w-32 text-right px-4">Balance</span>+ )}+ </div>+ <TreeView<Chart>+ tree={tree}+ nodes={nodes}+ getTreeProps={getTreeProps}+ getNodeProps={getNodeProps}+ virtualizer={virtualizer}+ parentRef={parentRef}+ parentClassName="h-full"+ renderNode={({ node, state }) => {+ const account = node.data;+ const isGroup = account.isGroup;+ const isExpanded = state.expanded;- {/* Expand/collapse chevron */}- <div- className={cn(- "flex h-9 w-5 items-center justify-center",- node.hasChildren && "hover:bg-accent"- )}- onClick={(e) => {- e.stopPropagation();+ return (+ <div+ className={cn(+ "flex h-8 cursor-pointer items-center overflow-hidden pr-4 text-sm group/row",+ state.selected+ ? "bg-muted hover:bg-accent"+ : "bg-transparent hover:bg-accent",+ isGroup && "font-semibold"+ )}+ onClick={() => {+ selectNode(node.id, false);+ if (isGroup) {toggleExpandNode(node.id);- }}- >- {node.hasChildren ? (- isExpanded ? (- <LuChevronDown className="h-4 w-4 text-muted-foreground flex-shrink-0" />+ } else {+ navigate(account.id as string);+ }+ }}+ >+ {/* Indentation lines */}+ <div className="flex h-9 items-center">+ {Array.from({ length: node.level }).map((_, index) => (+ <LevelLine key={index} isSelected={state.selected} />+ ))}++ {/* Expand/collapse chevron */}+ <div+ className={cn(+ "flex h-9 w-5 items-center justify-center",+ node.hasChildren && "hover:bg-accent"+ )}+ onClick={(e) => {+ e.stopPropagation();+ toggleExpandNode(node.id);+ }}+ >+ {node.hasChildren ? (+ isExpanded ? (+ <LuChevronDown className="h-4 w-4 text-muted-foreground flex-shrink-0" />+ ) : (+ <LuChevronRight className="h-4 w-4 text-muted-foreground flex-shrink-0" />+ )) : (- <LuChevronRight className="h-4 w-4 text-muted-foreground flex-shrink-0" />- )- ) : (- <div className="h-9 w-5" />- )}+ <div className="h-9 w-5" />+ )}+ </div></div>- </div>- {/* Folder/dot icon */}- <div className="w-5 h-5 flex items-center justify-center mr-2 shrink-0">- {isGroup &&- (isExpanded ? (- <LuFolderOpen className="h-4 w-4 text-muted-foreground" />- ) : (- <LuFolder className="h-4 w-4 text-muted-foreground" />- ))}- </div>+ {/* Folder/dot icon */}+ <div className="w-5 h-5 flex items-center justify-center mr-2 shrink-0">+ {isGroup &&+ (isExpanded ? (+ <LuFolderOpen className="h-4 w-4 text-muted-foreground" />+ ) : (+ <LuFolder className="h-4 w-4 text-muted-foreground" />+ ))}+ </div>++ {/* Account number + name */}+ <div className="flex flex-1 items-center gap-2 overflow-hidden">+ {!isGroup && account.number && (+ <span className="text-muted-foreground shrink-0">+ {account.number}+ </span>+ )}+ <span className="truncate">{account.name}</span>+ </div>- {/* Account number + name */}- <div className="flex flex-1 items-center gap-2 overflow-hidden">- {!isGroup && account.number && (- <span className="text-muted-foreground shrink-0">- {account.number}+ {/* Balance */}+ {accountingEnabled && (+ <span className="w-32 text-right tabular-nums shrink-0 text-muted-foreground">+ {formatCurrency(account.balance ?? 0)}</span>)}- <span className="truncate">{account.name}</span>- </div>-- {/* Balance */}- {accountingEnabled && (- <span className="w-32 text-right tabular-nums shrink-0 text-muted-foreground">- {formatCurrency(account.balance ?? 0)}- </span>- )}- {/* Actions menu */}- <DropdownMenu>- <DropdownMenuTrigger asChild>- <button- className="ml-1 shrink-0 rounded-md p-1 opacity-0 transition-opacity hover:bg-accent group-hover/row:opacity-100"- onClick={(e) => e.stopPropagation()}- >- <LuEllipsisVertical className="h-3.5 w-3.5 text-muted-foreground" />- </button>- </DropdownMenuTrigger>- <DropdownMenuContent align="end">- {isGroup ? (- <>- {!account.isSystem && (+ {/* Actions menu */}+ <DropdownMenu>+ <DropdownMenuTrigger asChild>+ <button+ className="ml-1 shrink-0 rounded-md p-1 opacity-0 transition-opacity hover:bg-accent group-hover/row:opacity-100"+ onClick={(e) => e.stopPropagation()}+ >+ <LuEllipsisVertical className="h-3.5 w-3.5 text-muted-foreground" />+ </button>+ </DropdownMenuTrigger>+ <DropdownMenuContent align="end">+ {isGroup ? (+ <>+ {!account.isSystem && (+ <DropdownMenuItem+ onClick={() => navigate(account.id as string)}+ >+ <LuPencil className="mr-2 h-4 w-4" />+ Edit Group+ </DropdownMenuItem>+ )}+ <DropdownMenuItem+ onClick={() =>+ navigate(`new-group?parentId=${account.id}`)+ }+ >+ <LuFolderPlus className="mr-2 h-4 w-4" />+ Add Group+ </DropdownMenuItem>+ <DropdownMenuItem+ onClick={() => navigate(`new?parentId=${account.id}`)}+ >+ <LuFilePlus className="mr-2 h-4 w-4" />+ Add Account+ </DropdownMenuItem>+ {!account.isSystem && (+ <DropdownMenuItem+ className="text-destructive"+ onClick={() => navigate(`delete/${account.id}`)}+ >+ <LuTrash2 className="mr-2 h-4 w-4" />+ Delete+ </DropdownMenuItem>+ )}+ </>+ ) : (+ <><DropdownMenuItemonClick={() => navigate(account.id as string)}><LuPencil className="mr-2 h-4 w-4" />- Edit Group+ Edit</DropdownMenuItem>- )}- <DropdownMenuItem- onClick={() =>- navigate(`new-group?parentId=${account.id}`)- }- >- <LuFolderPlus className="mr-2 h-4 w-4" />- Add Group- </DropdownMenuItem>- <DropdownMenuItem- onClick={() => navigate(`new?parentId=${account.id}`)}- >- <LuFilePlus className="mr-2 h-4 w-4" />- Add Account- </DropdownMenuItem>- {!account.isSystem && (<DropdownMenuItemclassName="text-destructive"onClick={() => navigate(`delete/${account.id}`)}@@ -234,34 +281,18 @@ const ChartOfAccountsTree = memo(({ data }: ChartOfAccountsTreeProps) => {<LuTrash2 className="mr-2 h-4 w-4" />Delete</DropdownMenuItem>- )}- </>- ) : (- <>- <DropdownMenuItem- onClick={() => navigate(account.id as string)}- >- <LuPencil className="mr-2 h-4 w-4" />- Edit- </DropdownMenuItem>- <DropdownMenuItem- className="text-destructive"- onClick={() => navigate(`delete/${account.id}`)}- >- <LuTrash2 className="mr-2 h-4 w-4" />- Delete- </DropdownMenuItem>- </>- )}- </DropdownMenuContent>- </DropdownMenu>- </div>- );- }}- />- </ScrollArea>- );-});+ </>+ )}+ </DropdownMenuContent>+ </DropdownMenu>+ </div>+ );+ }}+ />+ </ScrollArea>+ );+ }+);ChartOfAccountsTree.displayName = "ChartOfAccountsTree";export default ChartOfAccountsTree;diff --git a/apps/erp/app/modules/accounting/ui/Dimensions/DimensionForm.tsx b/apps/erp/app/modules/accounting/ui/Dimensions/DimensionForm.tsxindex 3983cb8136..573bb49522 100644--- a/apps/erp/app/modules/accounting/ui/Dimensions/DimensionForm.tsx+++ b/apps/erp/app/modules/accounting/ui/Dimensions/DimensionForm.tsx@@ -33,6 +33,7 @@ const entityTypeLabels: Record<string, string> = {CustomerType: "Customer Type",Department: "Department",Employee: "Employee",+ FixedAssetClass: "Asset Class",CostCenter: "Cost Center"};diff --git a/apps/erp/app/modules/accounting/ui/FixedAssets/AssetClassForm.tsx b/apps/erp/app/modules/accounting/ui/FixedAssets/AssetClassForm.tsxnew file mode 100644index 0000000000..53ce5b5ad6--- /dev/null+++ b/apps/erp/app/modules/accounting/ui/FixedAssets/AssetClassForm.tsx@@ -0,0 +1,237 @@+import { ValidatedForm } from "@carbon/form";+import {+ Button,+ HStack,+ ModalDrawer,+ ModalDrawerBody,+ ModalDrawerContent,+ ModalDrawerFooter,+ ModalDrawerHeader,+ ModalDrawerProvider,+ ModalDrawerTitle,+ toast,+ VStack+} from "@carbon/react";+import type { PostgrestResponse } from "@supabase/supabase-js";+import { useEffect, useState } from "react";+import { useFetcher } from "react-router";+import type { z } from "zod";+import {+ Account,+ Hidden,+ Input,+ Number,+ Select,+ Submit+} from "~/components/Form";+import { usePermissions } from "~/hooks";+import { path } from "~/utils/path";+import {+ depreciationMethods,+ fixedAssetClassValidator,+ taxDepreciationMethods+} from "../../accounting.models";+import { macrsConventions, macrsPropertyClasses } from "../../accounting.utils";++type AssetClassFormProps = {+ initialValues: z.infer<typeof fixedAssetClassValidator>;+ taxDepreciationEnabled: boolean;+ type?: "modal" | "drawer";+ onClose: () => void;+};++const AssetClassForm = ({+ initialValues,+ taxDepreciationEnabled,+ type = "drawer",+ onClose+}: AssetClassFormProps) => {+ const permissions = usePermissions();+ const fetcher = useFetcher<PostgrestResponse<{ id: string }>>();++ useEffect(() => {+ if (type !== "modal") return;++ if (fetcher.state === "loading" && fetcher.data?.data) {+ onClose?.();+ toast.success("Created asset class");+ } else if (fetcher.state === "idle" && fetcher.data?.error) {+ toast.error(+ `Failed to create asset class: ${fetcher.data.error.message}`+ );+ }+ }, [fetcher.data, fetcher.state, onClose, type]);++ const isEditing = initialValues.id !== undefined;+ const isDisabled = isEditing+ ? !permissions.can("update", "accounting")+ : !permissions.can("create", "accounting");++ const [taxMethod, setTaxMethod] = useState<string>(+ initialValues.taxDepreciationMethod ?? ""+ );++ return (+ <ModalDrawerProvider type={type}>+ <ModalDrawer+ open+ onOpenChange={(open) => {+ if (!open) onClose?.();+ }}+ >+ <ModalDrawerContent>+ <ValidatedForm+ validator={fixedAssetClassValidator}+ method="post"+ action={+ isEditing+ ? path.to.assetClass(initialValues.id!)+ : path.to.newAssetClass+ }+ defaultValues={initialValues}+ fetcher={fetcher}+ className="flex flex-col h-full"+ >+ <ModalDrawerHeader>+ <ModalDrawerTitle>+ {isEditing ? "Edit" : "New"} Asset Class+ </ModalDrawerTitle>+ </ModalDrawerHeader>+ <ModalDrawerBody>+ <Hidden name="id" />+ <Hidden name="type" value={type} />+ <VStack spacing={4}>+ <Input name="name" label="Name" />+ <Input name="description" label="Description" />+ <Select+ name="depreciationMethod"+ label="Depreciation Method"+ options={depreciationMethods.map((m) => ({+ label: m,+ value: m+ }))}+ />+ <Number+ name="usefulLifeMonths"+ label="Useful Life (Months)"+ minValue={1}+ />+ <Number+ name="residualValuePercent"+ label="Residual Value %"+ minValue={0}+ maxValue={100}+ />+ <Account+ name="assetAccountId"+ label="Asset Account"+ classes={["Asset"]}+ />+ <Account+ name="accumulatedDepreciationAccountId"+ label="Accumulated Depreciation Account"+ classes={["Asset"]}+ />+ <Account+ name="depreciationExpenseAccountId"+ label="Depreciation Expense Account"+ classes={["Expense"]}+ />+ <Account+ name="writeOffAccountId"+ label="Write-Off Account"+ classes={["Expense"]}+ />+ <Account+ name="writeDownAccountId"+ label="Write-Down Account"+ classes={["Expense"]}+ />+ <Account+ name="disposalAccountId"+ label="Disposal Account"+ classes={["Revenue", "Expense"]}+ />++ {taxDepreciationEnabled && (+ <>+ <div className="border-t pt-4 mt-2 w-full">+ <h4 className="text-sm font-medium mb-4">+ Tax Depreciation+ </h4>+ </div>+ <Select+ name="taxDepreciationMethod"+ label="Tax Method"+ placeholder="Same as Book"+ isOptional+ options={taxDepreciationMethods.map((m) => ({+ label: m,+ value: m+ }))}+ onChange={(value) => setTaxMethod(value?.value ?? "")}+ />++ {taxMethod === "MACRS" && (+ <>+ <Select+ name="macrsPropertyClass"+ label="Recovery Period"+ options={macrsPropertyClasses.map((c) => ({+ label: `${c}-Year Property`,+ value: c+ }))}+ />+ <Select+ name="macrsConvention"+ label="Convention"+ options={macrsConventions.map((c) => ({+ label: c,+ value: c+ }))}+ />+ <Number+ name="bonusDepreciationPercent"+ label="Bonus Depreciation %"+ minValue={0}+ maxValue={100}+ />+ </>+ )}++ {(taxMethod === "Straight Line" ||+ taxMethod === "Declining Balance") && (+ <>+ <Number+ name="taxUsefulLifeMonths"+ label="Tax Useful Life (Months)"+ minValue={1}+ />+ <Number+ name="taxResidualValuePercent"+ label="Tax Residual Value %"+ minValue={0}+ maxValue={100}+ />+ </>+ )}+ </>+ )}+ </VStack>+ </ModalDrawerBody>+ <ModalDrawerFooter>+ <HStack>+ <Submit isDisabled={isDisabled}>Save</Submit>+ <Button size="md" variant="solid" onClick={() => onClose?.()}>+ Cancel+ </Button>+ </HStack>+ </ModalDrawerFooter>+ </ValidatedForm>+ </ModalDrawerContent>+ </ModalDrawer>+ </ModalDrawerProvider>+ );+};++export default AssetClassForm;diff --git a/apps/erp/app/modules/accounting/ui/FixedAssets/AssetClassesTable.tsx b/apps/erp/app/modules/accounting/ui/FixedAssets/AssetClassesTable.tsxnew file mode 100644index 0000000000..383013e7ff--- /dev/null+++ b/apps/erp/app/modules/accounting/ui/FixedAssets/AssetClassesTable.tsx@@ -0,0 +1,167 @@+import { MenuIcon, MenuItem, useDisclosure } from "@carbon/react";+import type { ColumnDef } from "@tanstack/react-table";+import type { ReactNode } from "react";+import { memo, useCallback, useMemo, useState } from "react";+import {+ LuBookMarked,+ LuCalendar,+ LuPencil,+ LuPercent,+ LuTrash+} from "react-icons/lu";+import { useNavigate } from "react-router";+import { Hyperlink, Table } from "~/components";+import { Enumerable } from "~/components/Enumerable";+import { ConfirmDelete } from "~/components/Modals";+import { usePermissions } from "~/hooks";+import { path } from "~/utils/path";+import type { FixedAssetClassListItem } from "../../types";++type AssetClassesTableProps = {+ data: FixedAssetClassListItem[];+ count: number;+ taxDepreciationEnabled: boolean;+ primaryAction?: ReactNode;+};++function formatBookDepreciation(row: FixedAssetClassListItem): string {+ const method = row.depreciationMethod;+ const life = row.usefulLifeMonths;+ const residual = row.residualValuePercent;++ const years = life ? Math.round((life / 12) * 10) / 10 : null;+ const lifeStr = years ? `${years}yr` : "";+ const residualStr =+ residual && Number(residual) > 0 ? `, ${residual}% residual` : "";++ return `${method}, ${lifeStr}${residualStr}`;+}++function formatTaxDepreciation(row: FixedAssetClassListItem): string {+ const method = (row as any).taxDepreciationMethod;+ if (!method) return "Same as Book";++ if (method === "MACRS") {+ const cls = (row as any).macrsPropertyClass;+ return cls ? `MACRS ${cls}-Year` : "MACRS";+ }++ const life = (row as any).taxUsefulLifeMonths;+ const years = life ? Math.round((life / 12) * 10) / 10 : null;+ const lifeStr = years ? `, ${years}yr` : "";+ return `${method}${lifeStr}`;+}++const AssetClassesTable = memo(+ ({+ data,+ count,+ taxDepreciationEnabled,+ primaryAction+ }: AssetClassesTableProps) => {+ const navigate = useNavigate();+ const permissions = usePermissions();+ const [selectedClass, setSelectedClass] =+ useState<FixedAssetClassListItem | null>(null);+ const deleteModal = useDisclosure();++ const columns = useMemo<ColumnDef<FixedAssetClassListItem>[]>(() => {+ const cols: ColumnDef<FixedAssetClassListItem>[] = [+ {+ accessorKey: "name",+ header: "Name",+ cell: ({ row }) => (+ <Hyperlink to={path.to.assetClass(row.original.id)}>+ <Enumerable+ value={row.original.name}+ className="cursor-pointer"+ />+ </Hyperlink>+ ),+ meta: {+ icon: <LuBookMarked />+ }+ },+ {+ id: "bookDepreciation",+ header: "Book Depreciation",+ cell: ({ row }) => formatBookDepreciation(row.original),+ meta: {+ icon: <LuCalendar />+ }+ }+ ];++ if (taxDepreciationEnabled) {+ cols.push({+ id: "taxDepreciation",+ header: "Tax Depreciation",+ cell: ({ row }) => formatTaxDepreciation(row.original),+ meta: {+ icon: <LuPercent />+ }+ });+ }++ return cols;+ }, [taxDepreciationEnabled]);++ const renderContextMenu = useCallback(+ (row: FixedAssetClassListItem) => (+ <>+ <MenuItem+ disabled={!permissions.can("update", "accounting")}+ onClick={() => navigate(path.to.assetClass(row.id))}+ >+ <MenuIcon icon={<LuPencil />} />+ Edit Asset Class+ </MenuItem>+ <MenuItem+ disabled={!permissions.can("delete", "accounting")}+ destructive+ onClick={() => {+ setSelectedClass(row);+ deleteModal.onOpen();+ }}+ >+ <MenuIcon icon={<LuTrash />} />+ Delete Asset Class+ </MenuItem>+ </>+ ),+ [deleteModal, navigate, permissions]+ );++ return (+ <>+ <Table<FixedAssetClassListItem>+ data={data}+ columns={columns}+ count={count}+ primaryAction={primaryAction}+ renderContextMenu={renderContextMenu}+ title="Asset Classes"+ />+ {selectedClass && (+ <ConfirmDelete+ action={path.to.deleteAssetClass(selectedClass.id)}+ isOpen={deleteModal.isOpen}+ name={selectedClass.name}+ text={`Are you sure you want to delete the asset class: ${selectedClass.name}? This cannot be undone.`}+ onCancel={() => {+ deleteModal.onClose();+ setSelectedClass(null);+ }}+ onSubmit={() => {+ deleteModal.onClose();+ setSelectedClass(null);+ }}+ />+ )}+ </>+ );+ }+);++AssetClassesTable.displayName = "AssetClassesTable";+export default AssetClassesTable;diff --git a/apps/erp/app/modules/accounting/ui/FixedAssets/DepreciationRunStatus.tsx b/apps/erp/app/modules/accounting/ui/FixedAssets/DepreciationRunStatus.tsxnew file mode 100644index 0000000000..32d28bd100--- /dev/null+++ b/apps/erp/app/modules/accounting/ui/FixedAssets/DepreciationRunStatus.tsx@@ -0,0 +1,18 @@+import { Status } from "@carbon/react";++type DepreciationRunStatusProps = {+ status?: string | null;+};++const DepreciationRunStatus = ({ status }: DepreciationRunStatusProps) => {+ switch (status) {+ case "Draft":+ return <Status color="gray">{status}</Status>;+ case "Posted":+ return <Status color="green">{status}</Status>;+ default:+ return null;+ }+};++export default DepreciationRunStatus;diff --git a/apps/erp/app/modules/accounting/ui/FixedAssets/DepreciationRunTable.tsx b/apps/erp/app/modules/accounting/ui/FixedAssets/DepreciationRunTable.tsxnew file mode 100644index 0000000000..3489785448--- /dev/null+++ b/apps/erp/app/modules/accounting/ui/FixedAssets/DepreciationRunTable.tsx@@ -0,0 +1,134 @@+import { MenuIcon, MenuItem, useDisclosure } from "@carbon/react";+import { formatDate } from "@carbon/utils";+import type { ColumnDef } from "@tanstack/react-table";+import type { ReactNode } from "react";+import { memo, useCallback, useMemo, useState } from "react";+import { LuCalendar, LuEye, LuHash, LuStar, LuTrash } from "react-icons/lu";+import { useNavigate } from "react-router";+import { Hyperlink, Table } from "~/components";+import { ConfirmDelete } from "~/components/Modals";+import { usePermissions } from "~/hooks";+import { path } from "~/utils/path";+import type { DepreciationRunListItem } from "../../types";+import DepreciationRunStatus from "./DepreciationRunStatus";++type DepreciationRunTableProps = {+ data: DepreciationRunListItem[];+ count: number;+ primaryAction?: ReactNode;+};++const DepreciationRunTable = memo(+ ({ data, count, primaryAction }: DepreciationRunTableProps) => {+ const navigate = useNavigate();+ const permissions = usePermissions();+ const [selectedRun, setSelectedRun] =+ useState<DepreciationRunListItem | null>(null);+ const deleteModal = useDisclosure();++ const columns = useMemo<ColumnDef<DepreciationRunListItem>[]>(+ () => [+ {+ accessorKey: "depreciationRunId",+ header: "Run ID",+ cell: ({ row }) => (+ <Hyperlink to={path.to.depreciationRun(row.original.id)}>+ {row.original.depreciationRunId}+ </Hyperlink>+ ),+ meta: {+ icon: <LuHash />+ }+ },+ {+ accessorKey: "periodEnd",+ header: "Period End",+ cell: ({ row }) => formatDate(row.original.periodEnd),+ meta: {+ icon: <LuCalendar />+ }+ },+ {+ accessorKey: "status",+ header: "Status",+ cell: ({ row }) => (+ <DepreciationRunStatus status={row.original.status} />+ ),+ meta: {+ icon: <LuStar />+ }+ },+ {+ accessorKey: "postedAt",+ header: "Posted At",+ cell: ({ row }) =>+ row.original.postedAt ? formatDate(row.original.postedAt) : "—",+ meta: {+ icon: <LuCalendar />+ }+ }+ ],+ []+ );++ const renderContextMenu = useCallback(+ (row: DepreciationRunListItem) => (+ <>+ <MenuItem+ disabled={!permissions.can("view", "accounting")}+ onClick={() => navigate(path.to.depreciationRun(row.id))}+ >+ <MenuIcon icon={<LuEye />} />+ View Run+ </MenuItem>+ {row.status === "Draft" && (+ <MenuItem+ disabled={!permissions.can("delete", "accounting")}+ destructive+ onClick={() => {+ setSelectedRun(row);+ deleteModal.onOpen();+ }}+ >+ <MenuIcon icon={<LuTrash />} />+ Delete+ </MenuItem>+ )}+ </>+ ),+ [deleteModal, navigate, permissions]+ );++ return (+ <>+ <Table<DepreciationRunListItem>+ data={data}+ columns={columns}+ count={count}+ primaryAction={primaryAction}+ renderContextMenu={renderContextMenu}+ title="Depreciation"+ />+ {selectedRun && (+ <ConfirmDelete+ action={path.to.deleteDepreciationRun(selectedRun.id)}+ isOpen={deleteModal.isOpen}+ name={selectedRun.depreciationRunId}+ text={`Are you sure you want to delete ${selectedRun.depreciationRunId}? This cannot be undone.`}+ onCancel={() => {+ deleteModal.onClose();+ setSelectedRun(null);+ }}+ onSubmit={() => {+ deleteModal.onClose();+ setSelectedRun(null);+ }}+ />+ )}+ </>+ );+ }+);++DepreciationRunTable.displayName = "DepreciationRunTable";+export default DepreciationRunTable;diff --git a/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetDisposalForm.tsx b/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetDisposalForm.tsxnew file mode 100644index 0000000000..2bbbd333dd--- /dev/null+++ b/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetDisposalForm.tsx@@ -0,0 +1,88 @@+import { ValidatedForm } from "@carbon/form";+import {+ Button,+ HStack,+ ModalDrawer,+ ModalDrawerBody,+ ModalDrawerContent,+ ModalDrawerFooter,+ ModalDrawerHeader,+ ModalDrawerProvider,+ ModalDrawerTitle,+ VStack+} from "@carbon/react";+import { useFetcher } from "react-router";+import { DatePicker, Submit } from "~/components/Form";+import { usePermissions, useUser } from "~/hooks";+import { useCurrencyFormatter } from "~/hooks/useCurrencyFormatter";+import { fixedAssetDisposalValidator } from "../../accounting.models";++type FixedAssetDisposalFormProps = {+ currentNBV: number;+ onClose: () => void;+};++const FixedAssetDisposalForm = ({+ currentNBV,+ onClose+}: FixedAssetDisposalFormProps) => {+ const permissions = usePermissions();+ const fetcher = useFetcher();+ const { company } = useUser();+ const currencyFormatter = useCurrencyFormatter({+ currency: company.baseCurrencyCode+ });++ return (+ <ModalDrawerProvider type="modal">+ <ModalDrawer+ open+ onOpenChange={(open) => {+ if (!open) onClose?.();+ }}+ >+ <ModalDrawerContent>+ <ValidatedForm+ validator={fixedAssetDisposalValidator}+ method="post"+ fetcher={fetcher}+ className="flex flex-col h-full"+ defaultValues={{+ disposalDate: ""+ }}+ >+ <ModalDrawerHeader>+ <ModalDrawerTitle>Dispose Asset</ModalDrawerTitle>+ </ModalDrawerHeader>+ <ModalDrawerBody>+ <VStack spacing={4}>+ <div className="text-sm text-muted-foreground">+ Current Net Book Value:{" "}+ <span className="font-medium text-foreground">+ {currencyFormatter.format(currentNBV)}+ </span>+ </div>+ <p className="text-sm text-muted-foreground">+ This will write off the remaining book value of the asset.+ </p>+ <DatePicker name="disposalDate" label="Disposal Date" />+ </VStack>+ </ModalDrawerBody>+ <ModalDrawerFooter>+ <HStack>+ <Submit isDisabled={!permissions.can("update", "accounting")}>+ Dispose+ </Submit>+ <Button size="md" variant="solid" onClick={() => onClose?.()}>+ Cancel+ </Button>+ </HStack>+ </ModalDrawerFooter>+ </ValidatedForm>+ </ModalDrawerContent>+ </ModalDrawer>+ </ModalDrawerProvider>+ );+};++export default FixedAssetDisposalForm;diff --git a/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetForm.tsx b/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetForm.tsxnew file mode 100644index 0000000000..ed9a2a132a--- /dev/null+++ b/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetForm.tsx@@ -0,0 +1,315 @@+import { ValidatedForm } from "@carbon/form";+import {+ Button,+ HStack,+ ModalDrawer,+ ModalDrawerBody,+ ModalDrawerContent,+ ModalDrawerFooter,+ ModalDrawerHeader,+ ModalDrawerProvider,+ ModalDrawerTitle,+ VStack+} from "@carbon/react";+import { useState } from "react";+import { useFetcher } from "react-router";+import type { z } from "zod";+import {+ AssetClass,+ Hidden,+ Input,+ Location,+ NumberControlled,+ SelectControlled,+ Submit,+ useAssetClasses+} from "~/components/Form";+import { usePermissions, useSettings } from "~/hooks";+import { path } from "~/utils/path";+import {+ depreciationMethods,+ fixedAssetValidator,+ macrsConventions,+ macrsPropertyClasses,+ taxDepreciationMethods+} from "../../accounting.models";++type FixedAssetFormProps = {+ initialValues: z.infer<typeof fixedAssetValidator>;+ onClose: () => void;+};++const FixedAssetForm = ({ initialValues, onClose }: FixedAssetFormProps) => {+ const permissions = usePermissions();+ const settings = useSettings();+ const taxDepreciationEnabled =+ (settings as any).assetTaxDepreciationEnabled ?? false;+ const fetcher = useFetcher();++ const isEditing = initialValues.id !== undefined;+ const isDisabled = isEditing+ ? !permissions.can("update", "accounting")+ : !permissions.can("create", "accounting");++ const { assetClasses } = useAssetClasses();++ const [assetData, setAssetData] = useState<{+ fixedAssetClassId: string;+ depreciationMethod: string;+ usefulLifeMonths: number;+ residualValuePercent: number;+ assetLifetimeUsage: number;+ taxDepreciationMethod: string;+ taxUsefulLifeMonths: number;+ taxResidualValuePercent: number;+ macrsPropertyClass: string;+ macrsConvention: string;+ bonusDepreciationPercent: number;+ }>({+ fixedAssetClassId: initialValues.fixedAssetClassId ?? "",+ depreciationMethod: initialValues.depreciationMethod ?? "",+ usefulLifeMonths: initialValues.usefulLifeMonths ?? 60,+ residualValuePercent: initialValues.residualValuePercent ?? 0,+ assetLifetimeUsage: initialValues.assetLifetimeUsage ?? 0,+ taxDepreciationMethod: initialValues.taxDepreciationMethod ?? "",+ taxUsefulLifeMonths: initialValues.taxUsefulLifeMonths ?? 60,+ taxResidualValuePercent: initialValues.taxResidualValuePercent ?? 0,+ macrsPropertyClass: initialValues.macrsPropertyClass ?? "",+ macrsConvention: initialValues.macrsConvention ?? "Half-Year",+ bonusDepreciationPercent: initialValues.bonusDepreciationPercent ?? 0+ });++ const onAssetClassChange = (+ selected: { value: string; label: string | JSX.Element } | null+ ) => {+ if (!selected) return;+ const assetClass = assetClasses.find((c) => c.id === selected.value);+ if (!assetClass) return;++ setAssetData({+ fixedAssetClassId: assetClass.id,+ depreciationMethod: assetClass.depreciationMethod,+ usefulLifeMonths: assetClass.usefulLifeMonths,+ residualValuePercent: assetClass.residualValuePercent,+ assetLifetimeUsage: 0,+ taxDepreciationMethod: assetClass.taxDepreciationMethod ?? "",+ taxUsefulLifeMonths: assetClass.taxUsefulLifeMonths ?? 60,+ taxResidualValuePercent: assetClass.taxResidualValuePercent ?? 0,+ macrsPropertyClass: assetClass.macrsPropertyClass ?? "",+ macrsConvention: assetClass.macrsConvention ?? "Half-Year",+ bonusDepreciationPercent: assetClass.bonusDepreciationPercent ?? 0+ });+ };++ return (+ <ModalDrawerProvider type="drawer">+ <ModalDrawer+ open+ onOpenChange={(open) => {+ if (!open) onClose?.();+ }}+ >+ <ModalDrawerContent>+ <ValidatedForm+ validator={fixedAssetValidator}+ method="post"+ action={+ isEditing+ ? path.to.fixedAssetDetails(initialValues.id!)+ : path.to.newFixedAsset+ }+ defaultValues={initialValues}+ fetcher={fetcher}+ className="flex flex-col h-full"+ >+ <ModalDrawerHeader>+ <ModalDrawerTitle>+ {isEditing ? "Edit" : "New"} Fixed Asset+ </ModalDrawerTitle>+ </ModalDrawerHeader>+ <ModalDrawerBody>+ <Hidden name="id" />+ <VStack spacing={4}>+ <Input name="name" label="Name" />+ <AssetClass+ name="fixedAssetClassId"+ label="Asset Class"+ value={assetData.fixedAssetClassId}+ onChange={onAssetClassChange}+ />+ <Input name="description" label="Description" />+ <Input name="serialNumber" label="Serial Number" />+ <SelectControlled+ name="depreciationMethod"+ label="Depreciation Method"+ options={depreciationMethods.map((m) => ({+ label: m,+ value: m+ }))}+ value={assetData.depreciationMethod}+ onChange={(v) => {+ if (v)+ setAssetData((d) => ({+ ...d,+ depreciationMethod: v.value+ }));+ }}+ />+ <NumberControlled+ name="usefulLifeMonths"+ label="Useful Life (Months)"+ minValue={1}+ value={assetData.usefulLifeMonths}+ onChange={(value) =>+ setAssetData((d) => ({ ...d, usefulLifeMonths: value }))+ }+ />+ <NumberControlled+ name="residualValuePercent"+ label="Residual Value %"+ minValue={0}+ maxValue={100}+ value={assetData.residualValuePercent}+ onChange={(value) =>+ setAssetData((d) => ({ ...d, residualValuePercent: value }))+ }+ />+ {assetData.depreciationMethod === "Units of Production" && (+ <NumberControlled+ name="assetLifetimeUsage"+ label="Lifetime Usage (Units)"+ minValue={0}+ value={assetData.assetLifetimeUsage}+ onChange={(value) =>+ setAssetData((d) => ({ ...d, assetLifetimeUsage: value }))+ }+ />+ )}+ <Location name="locationId" label="Location" />+ {taxDepreciationEnabled && (+ <>+ <SelectControlled+ name="taxDepreciationMethod"+ label="Tax Depreciation Method"+ placeholder="None"+ options={taxDepreciationMethods.map((m) => ({+ label: m,+ value: m+ }))}+ value={assetData.taxDepreciationMethod}+ onChange={(v) => {+ setAssetData((d) => ({+ ...d,+ taxDepreciationMethod: v?.value ?? ""+ }));+ }}+ />+ <div+ className={+ assetData.taxDepreciationMethod === "MACRS"+ ? "flex flex-col gap-4 w-full"+ : "hidden"+ }+ >+ <SelectControlled+ name="macrsPropertyClass"+ label="MACRS Property Class"+ isOptional={false}+ options={macrsPropertyClasses.map((c) => ({+ label: `${c}-Year`,+ value: c+ }))}+ value={assetData.macrsPropertyClass}+ onChange={(v) => {+ if (v)+ setAssetData((d) => ({+ ...d,+ macrsPropertyClass: v.value+ }));+ }}+ />+ <SelectControlled+ name="macrsConvention"+ label="MACRS Convention"+ isOptional={false}+ options={macrsConventions.map((c) => ({+ label: c,+ value: c+ }))}+ value={assetData.macrsConvention}+ onChange={(v) => {+ if (v)+ setAssetData((d) => ({+ ...d,+ macrsConvention: v.value+ }));+ }}+ />+ <NumberControlled+ name="bonusDepreciationPercent"+ label="Bonus Depreciation %"+ minValue={0}+ maxValue={100}+ value={assetData.bonusDepreciationPercent}+ onChange={(value) =>+ setAssetData((d) => ({+ ...d,+ bonusDepreciationPercent: value+ }))+ }+ />+ </div>+ <div+ className={+ assetData.taxDepreciationMethod === "Straight Line" ||+ assetData.taxDepreciationMethod === "Declining Balance"+ ? "flex flex-col gap-4 w-full"+ : "hidden"+ }+ >+ <NumberControlled+ name="taxUsefulLifeMonths"+ label="Tax Useful Life (Months)"+ minValue={1}+ value={assetData.taxUsefulLifeMonths}+ onChange={(value) =>+ setAssetData((d) => ({+ ...d,+ taxUsefulLifeMonths: value+ }))+ }+ />+ <NumberControlled+ name="taxResidualValuePercent"+ label="Tax Residual Value %"+ minValue={0}+ maxValue={100}+ value={assetData.taxResidualValuePercent}+ onChange={(value) =>+ setAssetData((d) => ({+ ...d,+ taxResidualValuePercent: value+ }))+ }+ />+ </div>+ </>+ )}+ </VStack>+ </ModalDrawerBody>+ <ModalDrawerFooter>+ <HStack>+ <Submit isDisabled={isDisabled}>Save</Submit>+ <Button size="md" variant="solid" onClick={() => onClose?.()}>+ Cancel+ </Button>+ </HStack>+ </ModalDrawerFooter>+ </ValidatedForm>+ </ModalDrawerContent>+ </ModalDrawer>+ </ModalDrawerProvider>+ );+};++export default FixedAssetForm;diff --git a/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetNotes.tsx b/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetNotes.tsxnew file mode 100644index 0000000000..6c53ce5aad--- /dev/null+++ b/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetNotes.tsx@@ -0,0 +1,99 @@+import { useCarbon } from "@carbon/auth";+import type { JSONContent } from "@carbon/react";+import {+ Card,+ CardContent,+ CardHeader,+ CardTitle,+ generateHTML,+ toast,+ useDebounce+} from "@carbon/react";+import { Editor } from "@carbon/react/Editor";+import { getLocalTimeZone, today } from "@internationalized/date";+import { useLingui } from "@lingui/react/macro";+import { nanoid } from "nanoid";+import { useState } from "react";+import { usePermissions, useUser } from "~/hooks";+import { getPrivateUrl } from "~/utils/path";++const FixedAssetNotes = ({+ id,+ notes: initialNotes+}: {+ id: string | null;+ notes?: JSONContent;+}) => {+ const {+ id: userId,+ company: { id: companyId }+ } = useUser();+ const { carbon } = useCarbon();+ const { t } = useLingui();+ const permissions = usePermissions();+ const [notes, setNotes] = useState(initialNotes ?? {});++ const onUploadImage = async (file: File) => {+ const fileType = file.name.split(".").pop();+ const fileName = `${companyId}/accounting/${id}/${nanoid()}.${fileType}`;++ const result = await carbon?.storage.from("private").upload(fileName, file);++ if (result?.error) {+ toast.error(t`Failed to upload image`);+ throw new Error(result.error.message);+ }++ if (!result?.data) {+ throw new Error("Failed to upload image");+ }++ return getPrivateUrl(result.data.path);+ };++ const onUpdateNotes = useDebounce(+ async (content: JSONContent) => {+ await carbon+ ?.from("fixedAsset")+ .update({+ notes: content,+ updatedAt: today(getLocalTimeZone()).toString(),+ updatedBy: userId+ })+ .eq("id", id!);+ },+ 2500,+ true+ );++ if (!id) return null;++ return (+ <Card className="w-full">+ <CardHeader>+ <CardTitle>Notes</CardTitle>+ </CardHeader>+ <CardContent>+ {permissions.can("update", "accounting") ? (+ <Editor+ initialValue={(notes ?? {}) as JSONContent}+ onUpload={onUploadImage}+ onChange={(value) => {+ setNotes(value);+ onUpdateNotes(value);+ }}+ />+ ) : (+ <div+ className="prose dark:prose-invert"+ dangerouslySetInnerHTML={{+ __html: generateHTML(notes as JSONContent)+ }}+ />+ )}+ </CardContent>+ </Card>+ );+};++export default FixedAssetNotes;diff --git a/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetRegisterForm.tsx b/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetRegisterForm.tsxnew file mode 100644index 0000000000..35a0eb0c3b--- /dev/null+++ b/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetRegisterForm.tsx@@ -0,0 +1,96 @@+import { ValidatedForm } from "@carbon/form";+import {+ Button,+ HStack,+ ModalDrawer,+ ModalDrawerBody,+ ModalDrawerContent,+ ModalDrawerFooter,+ ModalDrawerHeader,+ ModalDrawerProvider,+ ModalDrawerTitle,+ VStack+} from "@carbon/react";+import { useFetcher } from "react-router";+import { DatePicker, Number, Submit } from "~/components/Form";+import { usePermissions, useUser } from "~/hooks";+import { fixedAssetRegisterValidator } from "../../accounting.models";++type FixedAssetRegisterFormProps = {+ onClose: () => void;+};++const FixedAssetRegisterForm = ({ onClose }: FixedAssetRegisterFormProps) => {+ const permissions = usePermissions();+ const { company } = useUser();+ const fetcher = useFetcher();++ return (+ <ModalDrawerProvider type="drawer">+ <ModalDrawer+ open+ onOpenChange={(open) => {+ if (!open) onClose?.();+ }}+ >+ <ModalDrawerContent>+ <ValidatedForm+ validator={fixedAssetRegisterValidator}+ method="post"+ fetcher={fetcher}+ className="flex flex-col h-full"+ defaultValues={{+ acquisitionCost: 0,+ acquisitionDate: "",+ accumulatedDepreciation: 0,+ depreciationStartDate: ""+ }}+ >+ <ModalDrawerHeader>+ <ModalDrawerTitle>Register Existing Asset</ModalDrawerTitle>+ </ModalDrawerHeader>+ <ModalDrawerBody>+ <VStack spacing={4}>+ <Number+ name="acquisitionCost"+ label="Acquisition Cost"+ minValue={0}+ formatOptions={{+ style: "currency",+ currency: company?.baseCurrencyCode ?? "USD"+ }}+ />+ <DatePicker name="acquisitionDate" label="Acquisition Date" />+ <Number+ name="accumulatedDepreciation"+ label="Accumulated Depreciation"+ minValue={0}+ formatOptions={{+ style: "currency",+ currency: company?.baseCurrencyCode ?? "USD"+ }}+ />+ <DatePicker+ name="depreciationStartDate"+ label="Depreciation Start Date"+ />+ </VStack>+ </ModalDrawerBody>+ <ModalDrawerFooter>+ <HStack>+ <Submit isDisabled={!permissions.can("update", "accounting")}>+ Register+ </Submit>+ <Button size="md" variant="solid" onClick={() => onClose?.()}>+ Cancel+ </Button>+ </HStack>+ </ModalDrawerFooter>+ </ValidatedForm>+ </ModalDrawerContent>+ </ModalDrawer>+ </ModalDrawerProvider>+ );+};++export default FixedAssetRegisterForm;diff --git a/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetStatus.tsx b/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetStatus.tsxnew file mode 100644index 0000000000..343fb5622e--- /dev/null+++ b/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetStatus.tsx@@ -0,0 +1,23 @@+import { Status } from "@carbon/react";+import type { fixedAssetStatuses } from "../../accounting.models";++type FixedAssetStatusProps = {+ status?: (typeof fixedAssetStatuses)[number] | null;+};++const FixedAssetStatus = ({ status }: FixedAssetStatusProps) => {+ switch (status) {+ case "Draft":+ return <Status color="gray">{status}</Status>;+ case "Active":+ return <Status color="green">{status}</Status>;+ case "Fully Depreciated":+ return <Status color="yellow">{status}</Status>;+ case "Disposed":+ return <Status color="red">{status}</Status>;+ default:+ return null;+ }+};++export default FixedAssetStatus;diff --git a/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetsTable.tsx b/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetsTable.tsxnew file mode 100644index 0000000000..e9d3ad509b--- /dev/null+++ b/apps/erp/app/modules/accounting/ui/FixedAssets/FixedAssetsTable.tsx@@ -0,0 +1,228 @@+import { MenuIcon, MenuItem, useDisclosure } from "@carbon/react";+import type { ColumnDef } from "@tanstack/react-table";+import type { ReactNode } from "react";+import { memo, useCallback, useMemo, useState } from "react";+import {+ LuBookMarked,+ LuBuilding2,+ LuCircleDollarSign,+ LuHash,+ LuLayers,+ LuMapPin,+ LuPencil,+ LuStar,+ LuTrash+} from "react-icons/lu";+import { useNavigate } from "react-router";+import { Hyperlink, Table } from "~/components";+import { Enumerable } from "~/components/Enumerable";+import { useLocations } from "~/components/Form/Location";+import { ConfirmDelete } from "~/components/Modals";+import { usePermissions, useUser } from "~/hooks";+import { useCurrencyFormatter } from "~/hooks/useCurrencyFormatter";+import { path } from "~/utils/path";+import { fixedAssetStatuses } from "../../accounting.models";+import type { FixedAssetListItem } from "../../types";+import FixedAssetStatus from "./FixedAssetStatus";++type FixedAssetsTableProps = {+ data: FixedAssetListItem[];+ count: number;+ assetClasses: { id: string; name: string }[];+ primaryAction?: ReactNode;+};++const FixedAssetsTable = memo(+ ({ data, count, assetClasses, primaryAction }: FixedAssetsTableProps) => {+ const navigate = useNavigate();+ const permissions = usePermissions();+ const { company } = useUser();+ const currencyFormatter = useCurrencyFormatter({+ currency: company.baseCurrencyCode+ });+ const locations = useLocations();+ const [selectedAsset, setSelectedAsset] =+ useState<FixedAssetListItem | null>(null);+ const deleteModal = useDisclosure();++ const columns = useMemo<ColumnDef<FixedAssetListItem>[]>(+ () => [+ {+ accessorKey: "fixedAssetId",+ header: "Asset ID",+ cell: ({ row }) => (+ <Hyperlink to={path.to.fixedAsset(row.original.id)}>+ {row.original.fixedAssetId}+ </Hyperlink>+ ),+ meta: {+ icon: <LuBookMarked />+ }+ },+ {+ accessorKey: "name",+ header: "Name",+ meta: {+ icon: <LuBuilding2 />+ }+ },+ {+ accessorKey: "serialNumber",+ header: "Serial Number",+ meta: {+ icon: <LuHash />+ }+ },+ {+ accessorKey: "status",+ header: "Status",+ cell: ({ row }) => (+ <FixedAssetStatus+ status={+ row.original.status as (typeof fixedAssetStatuses)[number]+ }+ />+ ),+ meta: {+ filter: {+ type: "static",+ options: fixedAssetStatuses.map((v) => ({+ label: <FixedAssetStatus status={v} />,+ value: v+ }))+ },+ icon: <LuStar />+ }+ },+ {+ accessorKey: "fixedAssetClassId",+ header: "Asset Class",+ cell: ({ row }) => {+ const cls = row.original.fixedAssetClass as {+ id: string;+ name: string;+ } | null;+ return <Enumerable value={cls?.name ?? null} />;+ },+ meta: {+ filter: {+ type: "static",+ options: assetClasses.map((c) => ({+ label: <Enumerable value={c.name} />,+ value: c.id+ }))+ },+ icon: <LuLayers />+ }+ },+ {+ accessorKey: "location.name",+ header: "Location",+ cell: ({ row }) => {+ const loc = (row.original as any).location as {+ id: string;+ name: string;+ } | null;+ return <Enumerable value={loc?.name ?? null} />;+ },+ meta: {+ filter: {+ type: "static",+ options: locations.map((l) => ({+ label: <Enumerable value={l.label} />,+ value: l.label+ }))+ },+ icon: <LuMapPin />+ }+ },+ {+ accessorKey: "acquisitionCost",+ header: "Acquisition Cost",+ cell: ({ row }) =>+ currencyFormatter.format(Number(row.original.acquisitionCost)),+ meta: {+ icon: <LuCircleDollarSign />+ }+ },+ {+ id: "netBookValue",+ header: "Net Book Value",+ cell: ({ row }) => {+ const nbv =+ Number(row.original.acquisitionCost) -+ Number(row.original.accumulatedDepreciation);+ return currencyFormatter.format(nbv);+ },+ meta: {+ icon: <LuCircleDollarSign />+ }+ }+ ],+ [assetClasses, currencyFormatter, locations]+ );++ const renderContextMenu = useCallback(+ (row: FixedAssetListItem) => {+ const isDraft = row.status === "Draft";+ return (+ <>+ <MenuItem+ disabled={!permissions.can("view", "accounting")}+ onClick={() => navigate(path.to.fixedAsset(row.id))}+ >+ <MenuIcon icon={<LuPencil />} />+ {isDraft ? "Edit Asset" : "View Asset"}+ </MenuItem>+ {isDraft && (+ <MenuItem+ disabled={!permissions.can("delete", "accounting")}+ destructive+ onClick={() => {+ setSelectedAsset(row);+ deleteModal.onOpen();+ }}+ >+ <MenuIcon icon={<LuTrash />} />+ Delete Asset+ </MenuItem>+ )}+ </>+ );+ },+ [deleteModal, navigate, permissions]+ );++ return (+ <>+ <Table<FixedAssetListItem>+ data={data}+ columns={columns}+ count={count}+ primaryAction={primaryAction}+ renderContextMenu={renderContextMenu}+ title="Fixed Assets"+ />+ {selectedAsset && (+ <ConfirmDelete+ action={path.to.deleteFixedAsset(selectedAsset.id)}+ isOpen={deleteModal.isOpen}+ name={selectedAsset.fixedAssetId}+ text={`Are you sure you want to delete ${selectedAsset.fixedAssetId}? This cannot be undone.`}+ onCancel={() => {+ deleteModal.onClose();+ setSelectedAsset(null);+ }}+ onSubmit={() => {+ deleteModal.onClose();+ setSelectedAsset(null);+ }}+ />+ )}+ </>+ );+ }+);++FixedAssetsTable.displayName = "FixedAssetsTable";+export default FixedAssetsTable;diff --git a/apps/erp/app/modules/accounting/ui/FixedAssets/index.ts b/apps/erp/app/modules/accounting/ui/FixedAssets/index.tsnew file mode 100644index 0000000000..51f5c54151--- /dev/null+++ b/apps/erp/app/modules/accounting/ui/FixedAssets/index.ts@@ -0,0 +1,23 @@+import AssetClassesTable from "./AssetClassesTable";+import AssetClassForm from "./AssetClassForm";+import DepreciationRunStatus from "./DepreciationRunStatus";+import DepreciationRunTable from "./DepreciationRunTable";+import FixedAssetDisposalForm from "./FixedAssetDisposalForm";+import FixedAssetForm from "./FixedAssetForm";+import FixedAssetNotes from "./FixedAssetNotes";+import FixedAssetRegisterForm from "./FixedAssetRegisterForm";+import FixedAssetStatus from "./FixedAssetStatus";+import FixedAssetsTable from "./FixedAssetsTable";++export {+ AssetClassForm,+ AssetClassesTable,+ DepreciationRunStatus,+ DepreciationRunTable,+ FixedAssetDisposalForm,+ FixedAssetForm,+ FixedAssetNotes,+ FixedAssetRegisterForm,+ FixedAssetStatus,+ FixedAssetsTable+};diff --git a/apps/erp/app/modules/accounting/ui/JournalEntries/DimensionSelector.tsx b/apps/erp/app/modules/accounting/ui/JournalEntries/DimensionSelector.tsxindex 82b508a44c..2cc01b198e 100644--- a/apps/erp/app/modules/accounting/ui/JournalEntries/DimensionSelector.tsx+++ b/apps/erp/app/modules/accounting/ui/JournalEntries/DimensionSelector.tsx@@ -45,6 +45,10 @@ const entityTypeColors: Record<string, string> = {"bg-orange-100 text-orange-800 dark:bg-orange-500/15 dark:text-orange-400 border-orange-500/20",ItemPostingGroup:"bg-violet-100 text-violet-800 dark:bg-violet-500/15 dark:text-violet-400 border-violet-500/20",+ WorkCenter:+ "bg-teal-100 text-teal-800 dark:bg-teal-500/15 dark:text-teal-400 border-teal-500/20",+ Process:+ "bg-cyan-100 text-cyan-800 dark:bg-cyan-500/15 dark:text-cyan-400 border-cyan-500/20",Custom: ""};diff --git a/apps/erp/app/modules/accounting/ui/Reports/FinancialStatementTree.tsx b/apps/erp/app/modules/accounting/ui/Reports/FinancialStatementTree.tsxindex 38710ebffe..3a5e6e41a4 100644--- a/apps/erp/app/modules/accounting/ui/Reports/FinancialStatementTree.tsx+++ b/apps/erp/app/modules/accounting/ui/Reports/FinancialStatementTree.tsx@@ -20,6 +20,7 @@ type FinancialStatementTreeProps = {data: TranslatedChart[];showTranslated?: boolean;parentCurrency?: string | null;+ search: string;};function accountsToFlatTree(@@ -62,6 +63,33 @@ function accountsToFlatTree(return result;}+function filterAccounts(+ accounts: TranslatedChart[],+ search: string+): TranslatedChart[] {+ if (!search.trim()) return accounts;+ const lower = search.toLowerCase();++ const byId = new Map(accounts.map((a) => [a.id, a]));+ const matched = new Set<string>();++ for (const a of accounts) {+ const nameMatch = a.name?.toLowerCase().includes(lower);+ const numberMatch = a.number?.toLowerCase().includes(lower);+ if (nameMatch || numberMatch) {+ matched.add(a.id as string);+ let parentId = a.parentId;+ while (parentId) {+ matched.add(parentId);+ const parent = byId.get(parentId);+ parentId = parent?.parentId ?? null;+ }+ }+ }++ return accounts.filter((a) => matched.has(a.id as string));+}+function formatCurrency(value: number): string {return value.toLocaleString(undefined, {minimumFractionDigits: 2,@@ -73,12 +101,17 @@ const FinancialStatementTree = memo(({data,showTranslated = false,- parentCurrency+ parentCurrency,+ search}: FinancialStatementTreeProps) => {useRealtime("journal");const parentRef = useRef<HTMLDivElement>(null);- const tree = useMemo(() => accountsToFlatTree(data), [data]);+ const filtered = useMemo(+ () => filterAccounts(data, search),+ [data, search]+ );+ const tree = useMemo(() => accountsToFlatTree(filtered), [filtered]);const {nodes,diff --git a/apps/erp/app/modules/accounting/ui/Reports/ReportFilters.tsx b/apps/erp/app/modules/accounting/ui/Reports/ReportFilters.tsxindex 59ef8820cd..39dbf69e55 100644--- a/apps/erp/app/modules/accounting/ui/Reports/ReportFilters.tsx+++ b/apps/erp/app/modules/accounting/ui/Reports/ReportFilters.tsx@@ -2,13 +2,16 @@ import {Button,DatePicker,HStack,+ Input,+ InputGroup,+ InputLeftElement,Popover,PopoverContent,PopoverHeader,PopoverTrigger} from "@carbon/react";import { parseDate } from "@internationalized/date";-import { LuCalendarDays, LuLanguages, LuX } from "react-icons/lu";+import { LuCalendarDays, LuLanguages, LuSearch, LuX } from "react-icons/lu";import { useUrlParams } from "~/hooks";import CompanySelector from "./CompanySelector";@@ -23,6 +26,8 @@ type ReportFiltersProps = {isMultiCompany: boolean;isForeignCurrency?: boolean;parentCurrency?: string | null;+ search: string;+ onSearchChange: (value: string) => void;};const ReportFilters = ({@@ -30,7 +35,9 @@ const ReportFilters = ({selectedCompanyIds,isMultiCompany,isForeignCurrency = false,- parentCurrency+ parentCurrency,+ search,+ onSearchChange}: ReportFiltersProps) => {const [params, setParams] = useUrlParams();@@ -41,6 +48,16 @@ const ReportFilters = ({return (<div className="flex px-4 py-3 items-center space-x-4 justify-between bg-card border-b border-border w-full"><HStack>+ <InputGroup size="sm" className="w-64">+ <InputLeftElement>+ <LuSearch className="h-4 w-4 text-muted-foreground" />+ </InputLeftElement>+ <Input+ placeholder="Search accounts..."+ value={search}+ onChange={(e) => onSearchChange(e.target.value)}+ />+ </InputGroup><CompanySelectorcompanies={companies}selectedCompanyIds={selectedCompanyIds}diff --git a/apps/erp/app/modules/accounting/ui/Reports/TrialBalanceTree.tsx b/apps/erp/app/modules/accounting/ui/Reports/TrialBalanceTree.tsxindex 756824331d..a5c0f64051 100644--- a/apps/erp/app/modules/accounting/ui/Reports/TrialBalanceTree.tsx+++ b/apps/erp/app/modules/accounting/ui/Reports/TrialBalanceTree.tsx@@ -20,6 +20,7 @@ type TrialBalanceTreeProps = {data: TrialBalanceChart[];showTranslated?: boolean;parentCurrency?: string | null;+ search: string;};function accountsToFlatTree(@@ -62,6 +63,33 @@ function accountsToFlatTree(return result;}+function filterAccounts(+ accounts: TrialBalanceChart[],+ search: string+): TrialBalanceChart[] {+ if (!search.trim()) return accounts;+ const lower = search.toLowerCase();++ const byId = new Map(accounts.map((a) => [a.id, a]));+ const matched = new Set<string>();++ for (const a of accounts) {+ const nameMatch = a.name?.toLowerCase().includes(lower);+ const numberMatch = a.number?.toLowerCase().includes(lower);+ if (nameMatch || numberMatch) {+ matched.add(a.id as string);+ let parentId = a.parentId;+ while (parentId) {+ matched.add(parentId);+ const parent = byId.get(parentId);+ parentId = parent?.parentId ?? null;+ }+ }+ }++ return accounts.filter((a) => matched.has(a.id as string));+}+function formatCurrency(value: number): string {if (value === 0) return "-";return value.toLocaleString(undefined, {@@ -103,11 +131,20 @@ function getDebitCredit(}const TrialBalanceTree = memo(- ({ data, showTranslated = false, parentCurrency }: TrialBalanceTreeProps) => {+ ({+ data,+ showTranslated = false,+ parentCurrency,+ search+ }: TrialBalanceTreeProps) => {useRealtime("journal");const parentRef = useRef<HTMLDivElement>(null);- const tree = useMemo(() => accountsToFlatTree(data), [data]);+ const filtered = useMemo(+ () => filterAccounts(data, search),+ [data, search]+ );+ const tree = useMemo(() => accountsToFlatTree(filtered), [filtered]);// Build a lookup of balanceAtDate by account id for ratio calculationconst balanceById = useMemo(() => {diff --git a/apps/erp/app/modules/accounting/ui/useAccountingSubmodules.tsx b/apps/erp/app/modules/accounting/ui/useAccountingSubmodules.tsxindex 6ab6f36144..564bbcfbc6 100644--- a/apps/erp/app/modules/accounting/ui/useAccountingSubmodules.tsx+++ b/apps/erp/app/modules/accounting/ui/useAccountingSubmodules.tsx@@ -5,11 +5,14 @@ import {LuAxis3D,LuBetweenHorizontalStart,LuBookOpen,+ LuBuilding2,LuCalendar1,+ LuClock,LuCoins,LuEuro,LuFileSpreadsheet,LuHandCoins,+ LuLayers,LuScale,LuSheet,LuTrendingUp@@ -24,7 +27,9 @@ const accountingOnlyRoutes = new Set<string>([path.to.incomeStatement,path.to.trialBalance,path.to.intercompany,- path.to.accountingJournals+ path.to.accountingJournals,+ path.to.fixedAssets,+ path.to.depreciationRuns]);export default function useAccountingSubmodules() {@@ -55,7 +60,7 @@ export default function useAccountingSubmodules() {]},{- name: t`Manage`,+ name: t`General Ledger`,routes: [{name: t`Intercompany`,@@ -72,9 +77,32 @@ export default function useAccountingSubmodules() {]},+ {+ name: t`Fixed Assets`,+ routes: [+ {+ name: t`Assets`,+ to: path.to.fixedAssets,+ role: "employee",+ icon: <LuBuilding2 />+ },+ {+ name: t`Depreciation`,+ to: path.to.depreciationRuns,+ role: "employee",+ icon: <LuClock />+ }+ ]+ },{name: t`Configure`,routes: [+ {+ name: t`Asset Classes`,+ to: path.to.assetClasses,+ role: "employee",+ icon: <LuLayers />+ },{name: t`Chart of Accounts`,to: path.to.chartOfAccounts,diff --git a/apps/erp/app/modules/documents/ui/Documents/DocumentView.tsx b/apps/erp/app/modules/documents/ui/Documents/DocumentView.tsxindex 0a83f82be1..1b2cbc2dc9 100644--- a/apps/erp/app/modules/documents/ui/Documents/DocumentView.tsx+++ b/apps/erp/app/modules/documents/ui/Documents/DocumentView.tsx@@ -57,7 +57,7 @@ const DocumentPreview = ({ bucket, document }: DocumentPreviewProps) => {default:return (<div className="flex flex-1 border-t border-border flex-col items-center justify-start w-full h-full pt-24">- <DocumentIcon className="w-36 h-36 mb-2" type={document.type!} />+ <DocumentIcon className="w-24 h-36 mb-2" type={document.type!} /><p className="text-xl mb-1">{document.name}</p><p className="text-muted-foreground mb-4">{convertKbToString(document.size ?? 0)}diff --git a/apps/erp/app/modules/inventory/ui/Receipts/ReceiptForm/ReceiptForm.tsx b/apps/erp/app/modules/inventory/ui/Receipts/ReceiptForm/ReceiptForm.tsxindex c5e50a8563..d7124fe1f6 100644--- a/apps/erp/app/modules/inventory/ui/Receipts/ReceiptForm/ReceiptForm.tsx+++ b/apps/erp/app/modules/inventory/ui/Receipts/ReceiptForm/ReceiptForm.tsx@@ -4,17 +4,9 @@ import {Card,CardContent,CardFooter,- CardHeader,- Copy,- DropdownMenu,- DropdownMenuContent,DropdownMenuIcon,DropdownMenuItem,DropdownMenuSeparator,- DropdownMenuTrigger,- Heading,- HStack,- IconButton,SplitButton,useDisclosure,VStack@@ -24,7 +16,6 @@ import { Trans, useLingui } from "@lingui/react/macro";import {LuCheckCheck,LuCreditCard,- LuEllipsisVertical,LuQrCode,LuShoppingCart,LuTicketX,@@ -33,6 +24,7 @@ import {} from "react-icons/lu";import { Link, useParams } from "react-router";import type { z } from "zod";+import { DocumentHeader } from "~/components";import { useAuditLog } from "~/components/AuditLog";import {Combobox,@@ -80,6 +72,7 @@ const ReceiptForm = ({const routeData = useRouteData<{receipt: Receipt;receiptLineTracking: ItemTracking[];+ fixedAssetLines: { id: string; received: boolean }[];}>(path.to.receipt(receiptId));const { company } = useUser();@@ -108,9 +101,13 @@ const ReceiptForm = ({const isInvoiced = routeData?.receipt?.invoiced === true;const isEditing = initialValues.id !== undefined;+ const hasReceivableFaLines = (routeData?.fixedAssetLines ?? []).some(+ (line) => line.received+ );const canPost =- receiptLines.length > 0 &&- receiptLines.some((line) => (line.receivedQuantity ?? 0) !== 0);+ (receiptLines.length > 0 &&+ receiptLines.some((line) => (line.receivedQuantity ?? 0) !== 0)) ||+ hasReceivableFaLines;const receiptLineTracking = routeData?.receiptLineTracking ?? [];@@ -149,80 +146,70 @@ const ReceiptForm = ({defaultValues={initialValues}style={{ width: "100%" }}>- <CardHeader className="flex-row items-center justify-between">- <HStack>- <Heading as="h1" size="h3">- {routeData?.receipt?.receiptId}- </Heading>- <Copy text={routeData?.receipt?.receiptId ?? ""} />- <DropdownMenu>- <DropdownMenuTrigger asChild>- <IconButton- aria-label="More options"- icon={<LuEllipsisVertical />}- variant="secondary"- size="sm"- />- </DropdownMenuTrigger>- <DropdownMenuContent>- {auditLogTrigger}- {isPosted && (- <>- <DropdownMenuSeparator />- <DropdownMenuItem- disabled={- isVoided ||- isInvoiced ||- !permissions.can("update", "inventory")- }- destructive- onClick={voidModal.onOpen}- >- <DropdownMenuIcon icon={<LuTicketX />} />- <Trans>Void</Trans>- </DropdownMenuItem>- </>- )}- <DropdownMenuSeparator />- <DropdownMenuItem- disabled={- !permissions.can("delete", "inventory") ||- !permissions.is("employee")- }- destructive- onClick={deleteDisclosure.onOpen}- >- <DropdownMenuIcon icon={<LuTrash />} />- <Trans>Delete</Trans>- </DropdownMenuItem>- </DropdownMenuContent>- </DropdownMenu>- <ReceiptStatus status={status} />- </HStack>- <HStack>- {receiptLineTracking.length > 0 && (- <SplitButton- leftIcon={<LuQrCode />}- dropdownItems={labelSizes.map((size) => ({- label: size.name,- onClick: () => navigateToTrackingLabels(!!size.zpl, size.id)- }))}- onClick={() => navigateToTrackingLabels(false)}- variant={isPosted ? "primary" : "secondary"}+ <DocumentHeader+ title={routeData?.receipt?.receiptId ?? ""}+ status={<ReceiptStatus status={status} />}+ menuItems={+ <>+ {auditLogTrigger}+ {isPosted && (+ <>+ <DropdownMenuSeparator />+ <DropdownMenuItem+ disabled={+ isVoided ||+ isInvoiced ||+ !permissions.can("update", "inventory")+ }+ destructive+ onClick={voidModal.onOpen}+ >+ <DropdownMenuIcon icon={<LuTicketX />} />+ <Trans>Void</Trans>+ </DropdownMenuItem>+ </>+ )}+ <DropdownMenuSeparator />+ <DropdownMenuItem+ disabled={+ !permissions.can("delete", "inventory") ||+ !permissions.is("employee")+ }+ destructive+ onClick={deleteDisclosure.onOpen}>- <Trans>Tracking Labels</Trans>- </SplitButton>- )}- <SourceDocumentLink- sourceDocument={routeData?.receipt?.sourceDocument ?? undefined}- sourceDocumentId={- routeData?.receipt?.sourceDocumentId ?? undefined- }- sourceDocumentReadableId={- routeData?.receipt?.sourceDocumentReadableId ?? undefined- }- />- {+ <DropdownMenuIcon icon={<LuTrash />} />+ <Trans>Delete</Trans>+ </DropdownMenuItem>+ </>+ }+ actions={+ <>+ {receiptLineTracking.length > 0 && (+ <SplitButton+ leftIcon={<LuQrCode />}+ dropdownItems={labelSizes.map((size) => ({+ label: size.name,+ onClick: () =>+ navigateToTrackingLabels(!!size.zpl, size.id)+ }))}+ onClick={() => navigateToTrackingLabels(false)}+ variant={isPosted ? "primary" : "secondary"}+ >+ <Trans>Tracking Labels</Trans>+ </SplitButton>+ )}+ <SourceDocumentLink+ sourceDocument={+ routeData?.receipt?.sourceDocument ?? undefined+ }+ sourceDocumentId={+ routeData?.receipt?.sourceDocumentId ?? undefined+ }+ sourceDocumentReadableId={+ routeData?.receipt?.sourceDocumentReadableId ?? undefined+ }+ /><Buttonvariant={canInvoice ? "primary" : "secondary"}isDisabled={!canInvoice}@@ -235,17 +222,19 @@ const ReceiptForm = ({<Trans>Invoice</Trans></Link></Button>- }- <Button- variant={canPost && !isPosted ? "primary" : "secondary"}- onClick={postModal.onOpen}- isDisabled={!canPost || isPosted || !permissions.is("employee")}- leftIcon={<LuCheckCheck />}- >- <Trans>Post</Trans>- </Button>- </HStack>- </CardHeader>+ <Button+ variant={canPost && !isPosted ? "primary" : "secondary"}+ onClick={postModal.onOpen}+ isDisabled={+ !canPost || isPosted || !permissions.is("employee")+ }+ leftIcon={<LuCheckCheck />}+ >+ <Trans>Post</Trans>+ </Button>+ </>+ }+ /><CardContent><Hidden name="id" />diff --git a/apps/erp/app/modules/inventory/ui/Receipts/ReceiptLines.tsx b/apps/erp/app/modules/inventory/ui/Receipts/ReceiptLines.tsxindex 173191c0b6..0e1b5c2f9d 100644--- a/apps/erp/app/modules/inventory/ui/Receipts/ReceiptLines.tsx+++ b/apps/erp/app/modules/inventory/ui/Receipts/ReceiptLines.tsx@@ -6,6 +6,7 @@ import {CardContent,CardHeader,CardTitle,+ Checkbox,cn,DatePicker,DropdownMenu,@@ -92,6 +93,16 @@ const ReceiptLines = () => {const routeData = useRouteData<{receipt: Receipt;receiptLines: ReceiptLine[];+ fixedAssetLines: {+ id: string;+ purchaseOrderLineId: string;+ assetId: string;+ assetName: string | null;+ assetReadableId: string | null;+ description: string | null;+ received: boolean;+ serialNumber: string | null;+ }[];receiptFiles: PostgrestResponse<StorageItem>;receiptLineTracking: ItemTracking[];batchProperties: PostgrestResponse<BatchProperty>;@@ -278,11 +289,103 @@ const ReceiptLines = () => {</div></CardContent></Card>+ {routeData?.fixedAssetLines && routeData.fixedAssetLines.length > 0 && (+ <Card>+ <CardHeader>+ <CardTitle>+ <Trans>Fixed Assets</Trans>+ </CardTitle>+ </CardHeader>+ <CardContent>+ <div className="border rounded-lg">+ {routeData.fixedAssetLines.map((line, index) => (+ <ReceiptFixedAssetLineItem+ key={line.id}+ line={line}+ isReadOnly={isPosted}+ className={+ index < routeData.fixedAssetLines.length - 1+ ? "border-b"+ : ""+ }+ />+ ))}+ </div>+ </CardContent>+ </Card>+ )}<Outlet /></>);};+function ReceiptFixedAssetLineItem({+ line,+ isReadOnly,+ className+}: {+ line: {+ id: string;+ purchaseOrderLineId: string;+ assetId: string;+ assetName: string | null;+ assetReadableId: string | null;+ description: string | null;+ received: boolean;+ serialNumber: string | null;+ };+ isReadOnly: boolean;+ className?: string;+}) {+ const fetcher = useFetcher();+ const [serialNumber, setSerialNumber] = useState(line.serialNumber ?? "");++ const updateField = (field: string, value: string) => {+ const formData = new FormData();+ formData.append("id", line.id);+ formData.append("field", field);+ formData.append("value", value);+ fetcher.submit(formData, {+ method: "post",+ action: path.to.receiptFixedAssetLineUpdate+ });+ };++ return (+ <div className={cn("flex items-center gap-4 p-6", className)}>+ <Checkbox+ isChecked={line.received}+ disabled={isReadOnly}+ onCheckedChange={(checked) =>+ updateField("received", String(checked === true))+ }+ />+ <VStack spacing={0} className="flex-1 min-w-0">+ <span className="text-sm font-medium">+ {line.assetName ?? line.description ?? "Fixed Asset"}+ </span>+ {line.assetReadableId && (+ <span className="text-xs text-muted-foreground">+ {line.assetReadableId}+ </span>+ )}+ </VStack>+ <Input+ placeholder="Serial Number"+ value={serialNumber}+ isDisabled={isReadOnly}+ className="w-48"+ onChange={(e) => setSerialNumber(e.target.value)}+ onBlur={() => {+ if (serialNumber !== (line.serialNumber ?? "")) {+ updateField("serialNumber", serialNumber);+ }+ }}+ />+ </div>+ );+}+function ReceiptLineItem({line,receipt,diff --git a/apps/erp/app/modules/inventory/ui/Receipts/ReceiptPostModal.tsx b/apps/erp/app/modules/inventory/ui/Receipts/ReceiptPostModal.tsxindex c0f7632930..b8da27bc31 100644--- a/apps/erp/app/modules/inventory/ui/Receipts/ReceiptPostModal.tsx+++ b/apps/erp/app/modules/inventory/ui/Receipts/ReceiptPostModal.tsx@@ -9,7 +9,6 @@ import {Modal,ModalBody,ModalContent,- ModalDescription,ModalFooter,ModalHeader,ModalOverlay,@@ -38,6 +37,10 @@ const ReceiptPostModal = ({ onClose }: { onClose: () => void }) => {const [items] = useItems();const routeData = useRouteData<{receiptLines: ReceiptLine[];+ fixedAssetLines: {+ id: string;+ received: boolean;+ }[];}>(path.to.receipt(receiptId));const navigation = useNavigation();@@ -74,10 +77,14 @@ const ReceiptPostModal = ({ onClose }: { onClose: () => void }) => {companyId);- if (- routeData?.receiptLines.length === 0 ||- routeData?.receiptLines.every((line) => line.receivedQuantity === 0)- ) {+ const hasReceiptLines = routeData?.receiptLines.some(+ (line) => (line.receivedQuantity ?? 0) > 0+ );+ const hasFaLines = (routeData?.fixedAssetLines ?? []).some(+ (line) => line.received+ );++ if (!hasReceiptLines && !hasFaLines) {setValidationErrors([{itemReadableId: null,@@ -95,9 +102,6 @@ const ReceiptPostModal = ({ onClose }: { onClose: () => void }) => {return attributes["Receipt Line"] === line.id;});- const _attributes = trackedEntity?.attributes as- | TrackedEntityAttributes- | undefined;if (!trackedEntity?.readableId) {errors.push({itemReadableId: getItemReadableId(items, line.itemId) ?? null,@@ -115,9 +119,7 @@ const ReceiptPostModal = ({ onClose }: { onClose: () => void }) => {});const quantityWithSerial = trackedEntities?.reduce((acc, tracking) => {- const _attributes = tracking.attributes as TrackedEntityAttributes;const serialNumber = tracking.readableId;-return acc + (serialNumber ? 1 : 0);}, 0);@@ -145,11 +147,6 @@ const ReceiptPostModal = ({ onClose }: { onClose: () => void }) => {});const { fetcher } = ruleViolations;- const handleSubmit = (e: React.FormEvent<HTMLFormElement>) => {- e.preventDefault();- ruleViolations.submit(new FormData());- };-return (<Modalopen={true}@@ -163,12 +160,9 @@ const ReceiptPostModal = ({ onClose }: { onClose: () => void }) => {<ModalTitle><Trans>Post Receipt</Trans></ModalTitle>- <ModalDescription>- <Trans>Are you sure you want to post this receipt?</Trans>- </ModalDescription></ModalHeader><ModalBody>- {validationErrors.length > 0 && (+ {validationErrors.length > 0 ? (<Alert variant="destructive"><LuTriangleAlert className="h-4 w-4" /><AlertTitle>@@ -190,6 +184,10 @@ const ReceiptPostModal = ({ onClose }: { onClose: () => void }) => {</ul></AlertDescription></Alert>+ ) : (+ <p className="text-sm text-muted-foreground">+ <Trans>Are you sure you want to post this receipt?</Trans>+ </p>)}</ModalBody><ModalFooter>@@ -197,7 +195,12 @@ const ReceiptPostModal = ({ onClose }: { onClose: () => void }) => {<Button variant="solid" onClick={onClose}><Trans>Cancel</Trans></Button>- <form onSubmit={handleSubmit}>+ <form+ onSubmit={(e) => {+ e.preventDefault();+ ruleViolations.submit(new FormData());+ }}+ ><ButtonisLoading={fetcher.state !== "idle"}isDisabled={diff --git a/apps/erp/app/modules/inventory/ui/Shipments/ShipmentForm/ShipmentForm.tsx b/apps/erp/app/modules/inventory/ui/Shipments/ShipmentForm/ShipmentForm.tsxindex 331eae1e48..86097671dc 100644--- a/apps/erp/app/modules/inventory/ui/Shipments/ShipmentForm/ShipmentForm.tsx+++ b/apps/erp/app/modules/inventory/ui/Shipments/ShipmentForm/ShipmentForm.tsx@@ -4,17 +4,13 @@ import {Card,CardContent,CardFooter,- CardHeader,- Copy,DropdownMenu,DropdownMenuContent,DropdownMenuIcon,DropdownMenuItem,DropdownMenuSeparator,DropdownMenuTrigger,- Heading,HStack,- IconButton,SplitButton,useDisclosure,VStack@@ -29,7 +25,6 @@ import {LuChevronDown,LuCirclePlus,LuCreditCard,- LuEllipsisVertical,LuQrCode,LuShoppingCart,LuTicketX,@@ -39,6 +34,7 @@ import {import { RiProgress8Line } from "react-icons/ri";import { Await, Link, useNavigate, useParams } from "react-router";import type { z } from "zod";+import { DocumentHeader } from "~/components";import { useAuditLog } from "~/components/AuditLog";import {Combobox,@@ -90,6 +86,7 @@ const ShipmentForm = ({const routeData = useRouteData<{shipment: Shipment;shipmentLineTracking: ItemTracking[];+ fixedAssetLines: { id: string; shipped: boolean }[];relatedItems?: Promise<{ invoices: SalesInvoice[] }>;}>(path.to.shipment(shipmentId));@@ -119,9 +116,13 @@ const ShipmentForm = ({const isVoided = status === "Voided";const isEditing = initialValues.id !== undefined;+ const hasShippableFaLines = (routeData?.fixedAssetLines ?? []).some(+ (line) => line.shipped+ );const canPost =- shipmentLines.length > 0 &&- shipmentLines.some((line) => (line.shippedQuantity ?? 0) !== 0);+ (shipmentLines.length > 0 &&+ shipmentLines.some((line) => (line.shippedQuantity ?? 0) !== 0)) ||+ hasShippableFaLines;const shipmentLineTracking = routeData?.shipmentLineTracking ?? [];const hasTrackingLabels = shipmentLineTracking.some(@@ -163,118 +164,106 @@ const ShipmentForm = ({defaultValues={initialValues}style={{ width: "100%" }}>- <CardHeader className="flex-row items-center justify-between">- <HStack>- <Heading as="h1" size="h3">- {routeData?.shipment?.shipmentId}- </Heading>- <Copy text={routeData?.shipment?.shipmentId ?? ""} />- <DropdownMenu>- <DropdownMenuTrigger asChild>- <IconButton- aria-label={t`More options`}- icon={<LuEllipsisVertical />}- variant="secondary"- size="sm"- />- </DropdownMenuTrigger>- <DropdownMenuContent>- {auditLogTrigger}- {(isPosted || isVoided) && (- <>- <DropdownMenuSeparator />- <DropdownMenuItem- disabled={isVoided || !permissions.is("employee")}- destructive- onClick={voidModal.onOpen}- >- <DropdownMenuIcon icon={<LuTicketX />} />- <Trans>Void</Trans>- </DropdownMenuItem>- </>- )}- <DropdownMenuSeparator />- <DropdownMenuItem- disabled={- !permissions.can("delete", "inventory") ||- !permissions.is("employee")- }- destructive- onClick={deleteDisclosure.onOpen}- >- <DropdownMenuIcon icon={<LuTrash />} />- <Trans>Delete Shipment</Trans>- </DropdownMenuItem>- </DropdownMenuContent>- </DropdownMenu>+ <DocumentHeader+ title={routeData?.shipment?.shipmentId ?? ""}+ status={<ShipmentStatusstatus={status}invoiced={routeData?.shipment?.invoiced}/>- </HStack>- <HStack>- {hasTrackingLabels && (- <SplitButton- leftIcon={<LuQrCode />}- dropdownItems={labelSizes.map((size) => ({- label: size.name,- onClick: () => navigateToTrackingLabels(!!size.zpl, size.id)- }))}- onClick={() => navigateToTrackingLabels(false)}- variant="primary"- >- <Trans>Tracking Labels</Trans>- </SplitButton>- )}-- <Button variant="secondary" leftIcon={<LuBarcode />} asChild>- <a- target="_blank"- href={path.to.file.shipment(shipmentId)}- rel="noreferrer"+ }+ menuItems={+ <>+ {auditLogTrigger}+ {(isPosted || isVoided) && (+ <>+ <DropdownMenuSeparator />+ <DropdownMenuItem+ disabled={isVoided || !permissions.is("employee")}+ destructive+ onClick={voidModal.onOpen}+ >+ <DropdownMenuIcon icon={<LuTicketX />} />+ <Trans>Void</Trans>+ </DropdownMenuItem>+ </>+ )}+ <DropdownMenuSeparator />+ <DropdownMenuItem+ disabled={+ !permissions.can("delete", "inventory") ||+ !permissions.is("employee")+ }+ destructive+ onClick={deleteDisclosure.onOpen}>- <Trans>Packing Slip</Trans>- </a>- </Button>-- <SourceDocumentLink- sourceDocument={- routeData?.shipment?.sourceDocument ?? undefined- }- sourceDocumentId={- routeData?.shipment?.sourceDocumentId ?? undefined- }- sourceDocumentReadableId={- routeData?.shipment?.sourceDocumentReadableId ?? undefined- }- />-- {permissions.can("view", "invoicing") && (- <InvoiceButtons- shipment={routeData?.shipment}- relatedItems={routeData?.relatedItems}- shipmentId={shipmentId}- isPosted={isPosted}- isVoided={isVoided}- onCreateInvoice={createInvoice}+ <DropdownMenuIcon icon={<LuTrash />} />+ <Trans>Delete Shipment</Trans>+ </DropdownMenuItem>+ </>+ }+ actions={+ <>+ {hasTrackingLabels && (+ <SplitButton+ leftIcon={<LuQrCode />}+ dropdownItems={labelSizes.map((size) => ({+ label: size.name,+ onClick: () =>+ navigateToTrackingLabels(!!size.zpl, size.id)+ }))}+ onClick={() => navigateToTrackingLabels(false)}+ variant="primary"+ >+ <Trans>Tracking Labels</Trans>+ </SplitButton>+ )}+ <Button variant="secondary" leftIcon={<LuBarcode />} asChild>+ <a+ target="_blank"+ href={path.to.file.shipment(shipmentId)}+ rel="noreferrer"+ >+ <Trans>Packing Slip</Trans>+ </a>+ </Button>+ <SourceDocumentLink+ sourceDocument={+ routeData?.shipment?.sourceDocument ?? undefined+ }+ sourceDocumentId={+ routeData?.shipment?.sourceDocumentId ?? undefined+ }+ sourceDocumentReadableId={+ routeData?.shipment?.sourceDocumentReadableId ?? undefined+ }/>- )}-- <Button- variant={!isPosted && !isVoided ? "primary" : "secondary"}- onClick={postModal.onOpen}- isDisabled={- !canPost ||- isPosted ||- isVoided ||- !permissions.is("employee")- }- leftIcon={<LuCheckCheck />}- >- <Trans>Post</Trans>- </Button>- </HStack>- </CardHeader>+ {permissions.can("view", "invoicing") && (+ <InvoiceButtons+ shipment={routeData?.shipment}+ relatedItems={routeData?.relatedItems}+ shipmentId={shipmentId}+ isPosted={isPosted}+ isVoided={isVoided}+ onCreateInvoice={createInvoice}+ />+ )}+ <Button+ variant={!isPosted && !isVoided ? "primary" : "secondary"}+ onClick={postModal.onOpen}+ isDisabled={+ !canPost ||+ isPosted ||+ isVoided ||+ !permissions.is("employee")+ }+ leftIcon={<LuCheckCheck />}+ >+ <Trans>Post</Trans>+ </Button>+ </>+ }+ /><CardContent><Hidden name="id" />diff --git a/apps/erp/app/modules/inventory/ui/Shipments/ShipmentLines.tsx b/apps/erp/app/modules/inventory/ui/Shipments/ShipmentLines.tsxindex 70b9282674..c4a91134b2 100644--- a/apps/erp/app/modules/inventory/ui/Shipments/ShipmentLines.tsx+++ b/apps/erp/app/modules/inventory/ui/Shipments/ShipmentLines.tsx@@ -6,6 +6,7 @@ import {CardContent,CardHeader,CardTitle,+ Checkbox,Combobox,cn,DropdownMenu,@@ -86,6 +87,16 @@ const ShipmentLines = () => {shipment: Shipment;shipmentLines: ShipmentLine[];shipmentLineTracking: ShipmentLineTracking[];+ fixedAssetLines: {+ id: string;+ salesOrderLineId: string;+ assetId: string;+ assetName: string | null;+ assetReadableId: string | null;+ description: string | null;+ shipped: boolean;+ serialNumber: string | null;+ }[];}>(path.to.shipment(shipmentId));const shipmentsById = new Map<string, ShipmentLine>(@@ -284,11 +295,103 @@ const ShipmentLines = () => {</div></CardContent></Card>+ {routeData?.fixedAssetLines && routeData.fixedAssetLines.length > 0 && (+ <Card>+ <CardHeader>+ <CardTitle>+ <Trans>Fixed Assets</Trans>+ </CardTitle>+ </CardHeader>+ <CardContent>+ <div className="border rounded-lg">+ {routeData.fixedAssetLines.map((line, index) => (+ <ShipmentFixedAssetLineItem+ key={line.id}+ line={line}+ isReadOnly={isReadOnly}+ className={+ index < routeData.fixedAssetLines.length - 1+ ? "border-b"+ : ""+ }+ />+ ))}+ </div>+ </CardContent>+ </Card>+ )}<Outlet /></>);};+function ShipmentFixedAssetLineItem({+ line,+ isReadOnly,+ className+}: {+ line: {+ id: string;+ salesOrderLineId: string;+ assetId: string;+ assetName: string | null;+ assetReadableId: string | null;+ description: string | null;+ shipped: boolean;+ serialNumber: string | null;+ };+ isReadOnly: boolean;+ className?: string;+}) {+ const fetcher = useFetcher();+ const [serialNumber, setSerialNumber] = useState(line.serialNumber ?? "");++ const updateField = (field: string, value: string) => {+ const formData = new FormData();+ formData.append("id", line.id);+ formData.append("field", field);+ formData.append("value", value);+ fetcher.submit(formData, {+ method: "post",+ action: path.to.shipmentFixedAssetLineUpdate+ });+ };++ return (+ <div className={cn("flex items-center gap-4 p-6", className)}>+ <Checkbox+ isChecked={line.shipped}+ disabled={isReadOnly}+ onCheckedChange={(checked) =>+ updateField("shipped", String(checked === true))+ }+ />+ <VStack spacing={0} className="flex-1 min-w-0">+ <span className="text-sm font-medium">+ {line.assetName ?? line.description ?? "Fixed Asset"}+ </span>+ {line.assetReadableId && (+ <span className="text-xs text-muted-foreground">+ {line.assetReadableId}+ </span>+ )}+ </VStack>+ <Input+ placeholder="Serial Number"+ value={serialNumber}+ isDisabled={isReadOnly}+ className="w-48"+ onChange={(e) => setSerialNumber(e.target.value)}+ onBlur={() => {+ if (serialNumber !== (line.serialNumber ?? "")) {+ updateField("serialNumber", serialNumber);+ }+ }}+ />+ </div>+ );+}+function ShipmentLineItem({line,shipment,diff --git a/apps/erp/app/modules/inventory/ui/Shipments/ShipmentPostModal.tsx b/apps/erp/app/modules/inventory/ui/Shipments/ShipmentPostModal.tsxindex 7834a1fafb..8832da13ca 100644--- a/apps/erp/app/modules/inventory/ui/Shipments/ShipmentPostModal.tsx+++ b/apps/erp/app/modules/inventory/ui/Shipments/ShipmentPostModal.tsx@@ -41,6 +41,10 @@ const ShipmentPostModal = ({ onClose }: { onClose: () => void }) => {const [items] = useItems();const routeData = useRouteData<{shipmentLines: ShipmentLine[];+ fixedAssetLines: {+ id: string;+ shipped: boolean;+ }[];}>(path.to.shipment(shipmentId));const navigation = useNavigation();@@ -99,10 +103,14 @@ const ShipmentPostModal = ({ onClose }: { onClose: () => void }) => {companyId);- if (- routeData?.shipmentLines.length === 0 ||- routeData?.shipmentLines.every((line) => line.shippedQuantity === 0)- ) {+ const hasShipmentLines = routeData?.shipmentLines.some(+ (line) => (line.shippedQuantity ?? 0) > 0+ );+ const hasFaLines = (routeData?.fixedAssetLines ?? []).some(+ (line) => line.shipped+ );++ if (!hasShipmentLines && !hasFaLines) {setValidationErrors([{itemReadableId: null,@@ -225,11 +233,6 @@ const ShipmentPostModal = ({ onClose }: { onClose: () => void }) => {});const { fetcher } = ruleViolations;- const handleSubmit = (e: React.FormEvent<HTMLFormElement>) => {- e.preventDefault();- ruleViolations.submit(new FormData());- };-return (<Modalopen={true}@@ -326,7 +329,12 @@ const ShipmentPostModal = ({ onClose }: { onClose: () => void }) => {<Button variant="solid" onClick={onClose}><Trans>Cancel</Trans></Button>- <form onSubmit={handleSubmit}>+ <form+ onSubmit={(e) => {+ e.preventDefault();+ ruleViolations.submit(new FormData());+ }}+ ><ButtonisLoading={fetcher.state !== "idle"}isDisabled={diff --git a/apps/erp/app/modules/inventory/ui/WarehouseTransfers/WarehouseTransferForm.tsx b/apps/erp/app/modules/inventory/ui/WarehouseTransfers/WarehouseTransferForm.tsxindex 90cad0fdc6..dc5da277a2 100644--- a/apps/erp/app/modules/inventory/ui/WarehouseTransfers/WarehouseTransferForm.tsx+++ b/apps/erp/app/modules/inventory/ui/WarehouseTransfers/WarehouseTransferForm.tsx@@ -7,7 +7,6 @@ import {CardContent,CardFooter,CardHeader,- Copy,DropdownMenu,DropdownMenuContent,DropdownMenuIcon,@@ -16,7 +15,6 @@ import {DropdownMenuTrigger,Heading,HStack,- IconButton,toast,useDisclosure,VStack@@ -28,7 +26,6 @@ import {LuChevronDown,LuCirclePlus,LuCircleStop,- LuEllipsisVertical,LuHandCoins,LuLoaderCircle,LuTrash,@@ -36,6 +33,7 @@ import {} from "react-icons/lu";import { Link, useSubmit } from "react-router";import type { z } from "zod";+import { DocumentHeader } from "~/components";import { useAuditLog } from "~/components/AuditLog";import {DatePicker,@@ -109,237 +107,228 @@ const WarehouseTransferForm = ({><Card className="w-full">{isEditing && warehouseTransfer ? (- <CardHeader className="flex-row items-center justify-between">- <HStack>- <Heading as="h1" size="h3">- {warehouseTransfer.transferId}- </Heading>- <Copy text={warehouseTransfer.transferId ?? ""} />- <DropdownMenu>- <DropdownMenuTrigger asChild>- <IconButton- aria-label={t`More options`}- icon={<LuEllipsisVertical />}- variant="secondary"- size="sm"- />- </DropdownMenuTrigger>- <DropdownMenuContent>- {auditLogTrigger}- <DropdownMenuSeparator />- <DropdownMenuItem- disabled={- ["Draft"].includes(warehouseTransfer.status ?? "") ||- statusFetcher.state !== "idle" ||- !permissions.can("update", "inventory")- }- onClick={() => {- statusFetcher.submit(- { status: "Draft" },- {- method: "post",- action: path.to.warehouseTransferStatus(- warehouseTransfer.id- )- }- );- }}- >- <DropdownMenuIcon icon={<LuLoaderCircle />} />- <Trans>Reopen</Trans>- </DropdownMenuItem>- <DropdownMenuSeparator />- <DropdownMenuItem- disabled={- isLocked ||- !permissions.can("delete", "inventory") ||- !permissions.is("employee")- }- destructive- onClick={deleteModal.onOpen}- >- <DropdownMenuIcon icon={<LuTrash />} />- <Trans>Delete Warehouse Transfer</Trans>- </DropdownMenuItem>- </DropdownMenuContent>- </DropdownMenu>+ <DocumentHeader+ title={warehouseTransfer.transferId ?? ""}+ status={<WarehouseTransferStatus status={warehouseTransfer.status} />- </HStack>- <HStack>- <Button- type="button"- leftIcon={<LuCheckCheck />}- variant={- warehouseTransfer.status === "Draft"- ? "primary"- : "secondary"- }- isDisabled={- !["Draft"].includes(warehouseTransfer.status) ||- statusFetcher.state !== "idle" ||- !permissions.can("update", "inventory")- }- isLoading={- statusFetcher.state !== "idle" &&- statusFetcher.formData?.get("status") ===- "To Ship and Receive"- }- onClick={() => {- const fd = new FormData();- fd.set("status", "To Ship and Receive");- statusRules.submit(fd);- }}- >- <Trans>Confirm</Trans>- </Button>-- <Button- type="button"- variant="secondary"- leftIcon={<LuCircleStop />}- isDisabled={- ["Cancelled", "Completed"].includes(- warehouseTransfer.status- ) ||- statusFetcher.state !== "idle" ||- !permissions.can("update", "inventory")- }- isLoading={- statusFetcher.state !== "idle" &&- statusFetcher.formData?.get("status") === "Cancelled"- }- onClick={() => {- const fd = new FormData();- fd.set("status", "Cancelled");- statusRules.submit(fd);- }}- >- <Trans>Cancel</Trans>- </Button>-- {shipments.length > 0 ? (- <DropdownMenu>- <DropdownMenuTrigger asChild>- <Button- leftIcon={<LuTruck />}- variant="secondary"- rightIcon={<LuChevronDown />}- >- <Trans>Shipments</Trans>- </Button>- </DropdownMenuTrigger>- <DropdownMenuContent>- <DropdownMenuItem- disabled={- !["To Ship", "To Ship and Receive"].includes(- warehouseTransfer.status ?? ""+ }+ menuItems={+ <>+ {auditLogTrigger}+ <DropdownMenuSeparator />+ <DropdownMenuItem+ disabled={+ ["Draft"].includes(warehouseTransfer.status ?? "") ||+ statusFetcher.state !== "idle" ||+ !permissions.can("update", "inventory")+ }+ onClick={() => {+ statusFetcher.submit(+ { status: "Draft" },+ {+ method: "post",+ action: path.to.warehouseTransferStatus(+ warehouseTransfer.id)}- onClick={() => ship(warehouseTransfer)}- >- <DropdownMenuIcon icon={<LuCirclePlus />} />- <Trans>New Shipment</Trans>- </DropdownMenuItem>- <DropdownMenuSeparator />- {shipments.map((shipment) => (- <DropdownMenuItem key={shipment.id} asChild>- <Link to={path.to.shipment(shipment.id)}>- <DropdownMenuIcon icon={<LuTruck />} />- <HStack spacing={8}>- <span>{shipment.shipmentId}</span>- <ShipmentStatus status={shipment.status} />- </HStack>- </Link>- </DropdownMenuItem>- ))}- </DropdownMenuContent>- </DropdownMenu>- ) : (- <Button- leftIcon={<LuTruck />}- isDisabled={- !["To Ship", "To Ship and Receive"].includes(- warehouseTransfer.status ?? ""- )+ );+ }}+ >+ <DropdownMenuIcon icon={<LuLoaderCircle />} />+ <Trans>Reopen</Trans>+ </DropdownMenuItem>+ <DropdownMenuSeparator />+ <DropdownMenuItem+ disabled={+ isLocked ||+ !permissions.can("delete", "inventory") ||+ !permissions.is("employee")}+ destructive+ onClick={deleteModal.onOpen}+ >+ <DropdownMenuIcon icon={<LuTrash />} />+ <Trans>Delete Warehouse Transfer</Trans>+ </DropdownMenuItem>+ </>+ }+ actions={+ <>+ <Button+ type="button"+ leftIcon={<LuCheckCheck />}variant={- ["To Ship", "To Ship and Receive"].includes(- warehouseTransfer.status ?? ""- )+ warehouseTransfer.status === "Draft"? "primary": "secondary"}- onClick={() => ship(warehouseTransfer)}+ isDisabled={+ !["Draft"].includes(warehouseTransfer.status) ||+ statusFetcher.state !== "idle" ||+ !permissions.can("update", "inventory")+ }+ isLoading={+ statusFetcher.state !== "idle" &&+ statusFetcher.formData?.get("status") ===+ "To Ship and Receive"+ }+ onClick={() => {+ const fd = new FormData();+ fd.set("status", "To Ship and Receive");+ statusRules.submit(fd);+ }}>- <Trans>Ship</Trans>+ <Trans>Confirm</Trans></Button>- )}- {receipts.length > 0 ? (- <DropdownMenu>- <DropdownMenuTrigger asChild>- <Button- leftIcon={<LuHandCoins />}- variant={- ["To Receive", "To Ship and Receive"].includes(- warehouseTransfer.status ?? ""- )- ? "primary"- : "secondary"- }- rightIcon={<LuChevronDown />}- >- <Trans>Receipts</Trans>- </Button>- </DropdownMenuTrigger>- <DropdownMenuContent>- <DropdownMenuItem- disabled={- !["To Receive", "To Ship and Receive"].includes(- warehouseTransfer.status ?? ""- ) || !hasShippedItems- }- onClick={() => receive(warehouseTransfer)}- >- <DropdownMenuIcon icon={<LuCirclePlus />} />- <Trans>New Receipt</Trans>- </DropdownMenuItem>- <DropdownMenuSeparator />- {receipts.map((receipt) => (- <DropdownMenuItem key={receipt.id} asChild>- <Link to={path.to.receipt(receipt.id)}>- <DropdownMenuIcon icon={<LuHandCoins />} />- <HStack spacing={8}>- <span>{receipt.receiptId}</span>- <ReceiptStatus status={receipt.status} />- </HStack>- </Link>- </DropdownMenuItem>- ))}- </DropdownMenuContent>- </DropdownMenu>- ) : (<Button- leftIcon={<LuHandCoins />}+ type="button"+ variant="secondary"+ leftIcon={<LuCircleStop />}isDisabled={- !["To Receive", "To Ship and Receive"].includes(- warehouseTransfer.status ?? ""- ) || !hasShippedItems+ ["Cancelled", "Completed"].includes(+ warehouseTransfer.status+ ) ||+ statusFetcher.state !== "idle" ||+ !permissions.can("update", "inventory")}- variant={- ["To Receive", "To Ship and Receive"].includes(- warehouseTransfer.status ?? ""- ) && hasShippedItems- ? "primary"- : "secondary"+ isLoading={+ statusFetcher.state !== "idle" &&+ statusFetcher.formData?.get("status") === "Cancelled"}- onClick={() => receive(warehouseTransfer)}+ onClick={() => {+ const fd = new FormData();+ fd.set("status", "Cancelled");+ statusRules.submit(fd);+ }}>- <Trans>Receive</Trans>+ <Trans>Cancel</Trans></Button>- )}- </HStack>- </CardHeader>++ {shipments.length > 0 ? (+ <DropdownMenu>+ <DropdownMenuTrigger asChild>+ <Button+ leftIcon={<LuTruck />}+ variant="secondary"+ rightIcon={<LuChevronDown />}+ >+ <Trans>Shipments</Trans>+ </Button>+ </DropdownMenuTrigger>+ <DropdownMenuContent>+ <DropdownMenuItem+ disabled={+ !["To Ship", "To Ship and Receive"].includes(+ warehouseTransfer.status ?? ""+ )+ }+ onClick={() => ship(warehouseTransfer)}+ >+ <DropdownMenuIcon icon={<LuCirclePlus />} />+ <Trans>New Shipment</Trans>+ </DropdownMenuItem>+ <DropdownMenuSeparator />+ {shipments.map((shipment) => (+ <DropdownMenuItem key={shipment.id} asChild>+ <Link to={path.to.shipment(shipment.id)}>+ <DropdownMenuIcon icon={<LuTruck />} />+ <HStack spacing={8}>+ <span>{shipment.shipmentId}</span>+ <ShipmentStatus status={shipment.status} />+ </HStack>+ </Link>+ </DropdownMenuItem>+ ))}+ </DropdownMenuContent>+ </DropdownMenu>+ ) : (+ <Button+ leftIcon={<LuTruck />}+ isDisabled={+ !["To Ship", "To Ship and Receive"].includes(+ warehouseTransfer.status ?? ""+ )+ }+ variant={+ ["To Ship", "To Ship and Receive"].includes(+ warehouseTransfer.status ?? ""+ )+ ? "primary"+ : "secondary"+ }+ onClick={() => ship(warehouseTransfer)}+ >+ <Trans>Ship</Trans>+ </Button>+ )}++ {receipts.length > 0 ? (+ <DropdownMenu>+ <DropdownMenuTrigger asChild>+ <Button+ leftIcon={<LuHandCoins />}+ variant={+ ["To Receive", "To Ship and Receive"].includes(+ warehouseTransfer.status ?? ""+ )+ ? "primary"+ : "secondary"+ }+ rightIcon={<LuChevronDown />}+ >+ <Trans>Receipts</Trans>+ </Button>+ </DropdownMenuTrigger>+ <DropdownMenuContent>+ <DropdownMenuItem+ disabled={+ !["To Receive", "To Ship and Receive"].includes(+ warehouseTransfer.status ?? ""+ ) || !hasShippedItems+ }+ onClick={() => receive(warehouseTransfer)}+ >+ <DropdownMenuIcon icon={<LuCirclePlus />} />+ <Trans>New Receipt</Trans>+ </DropdownMenuItem>+ <DropdownMenuSeparator />+ {receipts.map((receipt) => (+ <DropdownMenuItem key={receipt.id} asChild>+ <Link to={path.to.receipt(receipt.id)}>+ <DropdownMenuIcon icon={<LuHandCoins />} />+ <HStack spacing={8}>+ <span>{receipt.receiptId}</span>+ <ReceiptStatus status={receipt.status} />+ </HStack>+ </Link>+ </DropdownMenuItem>+ ))}+ </DropdownMenuContent>+ </DropdownMenu>+ ) : (+ <Button+ leftIcon={<LuHandCoins />}+ isDisabled={+ !["To Receive", "To Ship and Receive"].includes(+ warehouseTransfer.status ?? ""+ ) || !hasShippedItems+ }+ variant={+ ["To Receive", "To Ship and Receive"].includes(+ warehouseTransfer.status ?? ""+ ) && hasShippedItems+ ? "primary"+ : "secondary"+ }+ onClick={() => receive(warehouseTransfer)}+ >+ <Trans>Receive</Trans>+ </Button>+ )}+ </>+ }+ />) : (<CardHeader><Heading as="h1" size="h3">diff --git a/apps/erp/app/modules/invoicing/invoicing.models.ts b/apps/erp/app/modules/invoicing/invoicing.models.tsindex 5dd2f647f9..74215e4ea8 100644--- a/apps/erp/app/modules/invoicing/invoicing.models.ts+++ b/apps/erp/app/modules/invoicing/invoicing.models.ts@@ -42,7 +42,7 @@ export const salesInvoiceLineType = ["Material","Tool","Consumable",- // "Fixed Asset",+ "Fixed Asset",// "G/L Account","Comment"] as const;@@ -102,7 +102,7 @@ export const purchaseInvoiceLineValidator = z.object({id: zfd.text(z.string().optional()),invoiceId: z.string().min(1, { message: "Invoice is required" }),- invoiceLineType: z.enum([...methodItemType, "G/L Account"], {+ invoiceLineType: z.enum([...methodItemType, "G/L Account", "Fixed Asset"], {errorMap: (issue, ctx) => ({message: "Type is required"})@@ -162,6 +162,16 @@ export const purchaseInvoiceLineValidator = zmessage: "Description is required",path: ["description"]}+ )+ .refine(+ (data) =>+ data.invoiceLineType === "Fixed Asset"+ ? (data.quantity ?? 1) === 1+ : true,+ {+ message: "Fixed Asset quantity must be 1",+ path: ["quantity"]+ });export const salesInvoiceValidator = z.object({@@ -211,16 +221,18 @@ export const salesInvoiceLineValidator = z.object({id: zfd.text(z.string().optional()),invoiceId: z.string().min(1, { message: "Invoice is required" }),- invoiceLineType: z.enum(methodItemType, {+ invoiceLineType: z.enum([...methodItemType, "Fixed Asset"], {errorMap: (issue, ctx) => ({message: "Type is required"})}),- methodType: z.enum(methodType, {- errorMap: (issue, ctx) => ({- message: "Method is required"+ methodType: z+ .enum(methodType, {+ errorMap: (issue, ctx) => ({+ message: "Method is required"+ })})- }),+ .optional(),purchaseOrderId: zfd.text(z.string().optional()),purchaseOrderLineId: zfd.text(z.string().optional()),itemId: zfd.text(z.string().optional()),@@ -230,9 +242,7 @@ export const salesInvoiceLineValidator = znonTaxableAddOnCost: zfd.numeric(z.number().optional().default(0)),description: zfd.text(z.string().optional()),quantity: zfd.numeric(z.number().optional()),- unitOfMeasureCode: z- .string()- .min(1, { message: "Unit of measure is required" }),+ unitOfMeasureCode: zfd.text(z.string().default("EA")),unitPrice: zfd.numeric(z.number().optional()),shippingCost: zfd.numeric(z.number().optional().default(0)),taxPercent: zfd.numeric(z.number().optional().default(0)),@@ -249,7 +259,7 @@ export const salesInvoiceLineValidator = z: true,{message: "Item is required",- path: ["itemId"] // path of error+ path: ["itemId"]}).refine(@@ -259,6 +269,26 @@ export const salesInvoiceLineValidator = z: true,{message: "Location is required",- path: ["locationId"] // path of error+ path: ["locationId"]+ }+ )+ .refine(+ (data) => {+ if (data.invoiceLineType === "Fixed Asset") return true;+ return !!data.methodType;+ },+ {+ message: "Method is required",+ path: ["methodType"]+ }+ )+ .refine(+ (data) =>+ data.invoiceLineType === "Fixed Asset"+ ? (data.quantity ?? 1) === 1+ : true,+ {+ message: "Fixed Asset quantity must be 1",+ path: ["quantity"]});diff --git a/apps/erp/app/modules/invoicing/ui/PurchaseInvoice/PurchaseInvoiceExplorer.tsx b/apps/erp/app/modules/invoicing/ui/PurchaseInvoice/PurchaseInvoiceExplorer.tsxindex 30e62a9148..c7a530a826 100644--- a/apps/erp/app/modules/invoicing/ui/PurchaseInvoice/PurchaseInvoiceExplorer.tsx+++ b/apps/erp/app/modules/invoicing/ui/PurchaseInvoice/PurchaseInvoiceExplorer.tsx@@ -295,13 +295,17 @@ function PurchaseInvoiceLineItem({<VStack spacing={0} className="min-w-0"><span className="font-semibold line-clamp-1">{line.invoiceLineType === "G/L Account"- ? line.description || "Indirect Expense"- : getItemReadableId(items, line.itemId)}+ ? line.description || "G/L Account"+ : line.invoiceLineType === "Fixed Asset"+ ? (line as any).assetReadableId || "Fixed Asset"+ : getItemReadableId(items, line.itemId)}</span><span className="text-muted-foreground text-xs truncate line-clamp-1">{line.invoiceLineType === "G/L Account"? "G/L Account"- : line.description}+ : line.invoiceLineType === "Fixed Asset"+ ? line.assetName || line.description+ : line.description}</span></VStack></HStack>diff --git a/apps/erp/app/modules/invoicing/ui/PurchaseInvoice/PurchaseInvoiceLineForm.tsx b/apps/erp/app/modules/invoicing/ui/PurchaseInvoice/PurchaseInvoiceLineForm.tsxindex 2f25c5bde5..db86f278be 100644--- a/apps/erp/app/modules/invoicing/ui/PurchaseInvoice/PurchaseInvoiceLineForm.tsx+++ b/apps/erp/app/modules/invoicing/ui/PurchaseInvoice/PurchaseInvoiceLineForm.tsx@@ -1,12 +1,20 @@import { useCarbon } from "@carbon/auth";-import { DatePicker, InputControlled, ValidatedForm } from "@carbon/form";+import {+ Combobox,+ DatePicker,+ InputControlled,+ ValidatedForm+} from "@carbon/form";import {Badge,+ Button,cn,FormControl,FormLabel,HStack,+ IconButton,Input,+ Label,ModalCard,ModalCardBody,ModalCardContent,@@ -19,13 +27,14 @@ import {TabsContent,TabsList,TabsTrigger,+ useDisclosure,useMount,VStack} from "@carbon/react";import { getItemReadableId } from "@carbon/utils";import { Trans, useLingui } from "@lingui/react/macro";import { useEffect, useState } from "react";-import { LuBox, LuReceipt } from "react-icons/lu";+import { LuBox, LuChevronRight, LuLandmark, LuReceipt } from "react-icons/lu";import { useParams } from "react-router";import type { z } from "zod";import {@@ -58,6 +67,8 @@ import { path } from "~/utils/path";type PurchaseInvoiceLineFormProps = {initialValues: z.infer<typeof purchaseInvoiceLineValidator> & {taxPercent?: number;+ assetReadableId?: string;+ assetName?: string;};type?: "card" | "modal";onClose?: () => void;@@ -142,12 +153,55 @@ const PurchaseInvoiceLineForm = ({const isEditing = initialValues.id !== undefined;const isGLAccount = initialValues.invoiceLineType === "G/L Account";- const [activeTab, setActiveTab] = useState<"direct" | "indirect">(- isGLAccount ? "indirect" : "direct"+ const isFixedAsset = initialValues.invoiceLineType === "Fixed Asset";+ const [activeTab, setActiveTab] = useState<"item" | "gl-account" | "asset">(+ isFixedAsset ? "asset" : isGLAccount ? "gl-account" : "item");+ const [assetOptions, setAssetOptions] = useState<+ { value: string; label: string; locationId: string | null }[]+ >([]);++ useMount(() => {+ (async () => {+ const assets = await carbon+ .from("fixedAsset")+ .select("id, fixedAssetId, name, locationId")+ .eq("companyId", company.id)+ .eq("status", "Draft")+ .order("fixedAssetId");+ const options = (assets.data ?? []).map((a) => ({+ value: a.id,+ label: `${a.fixedAssetId} — ${a.name}`,+ locationId: a.locationId+ }));+ if (+ initialValues.assetId &&+ !options.some((o) => o.value === initialValues.assetId)+ ) {+ const current = await carbon+ .from("fixedAsset")+ .select("id, fixedAssetId, name, locationId")+ .eq("id", initialValues.assetId)+ .single();+ if (current.data) {+ options.unshift({+ value: current.data.id,+ label: `${current.data.fixedAssetId} — ${current.data.name}`,+ locationId: current.data.locationId+ });+ }+ }+ setAssetOptions(options);+ })();+ });++ const costsDisclosure = useDisclosure();+ const indirectCostsDisclosure = useDisclosure();+const [indirectData, setIndirectData] = useState<{accountId: string;+ assetId: string;costCenterId: string;description: string;quantity: number;@@ -158,6 +212,7 @@ const PurchaseInvoiceLineForm = ({taxPercent: number;}>({accountId: initialValues.accountId ?? "",+ assetId: initialValues.assetId ?? "",costCenterId: initialValues.costCenterId ?? "",description: initialValues.description ?? "",quantity: initialValues.quantity ?? 1,@@ -349,7 +404,7 @@ const PurchaseInvoiceLineForm = ({return (<Tabsvalue={activeTab}- onValueChange={(v) => setActiveTab(v as "direct" | "indirect")}+ onValueChange={(v) => setActiveTab(v as "item" | "gl-account" | "asset")}className="w-full"><ModalCardProvider type={type}>@@ -385,20 +440,31 @@ const PurchaseInvoiceLineForm = ({className={cn(isEditing &&!isGLAccount &&+ !isFixedAsset &&!itemData?.itemId &&"text-muted-foreground")}>{isEditing- ? isGLAccount- ? indirectData.description || "G/L Account"- : (getItemReadableId(items, itemData?.itemId) ?? "...")+ ? isFixedAsset+ ? initialValues.assetReadableId || "Fixed Asset"+ : isGLAccount+ ? indirectData.description || "G/L Account"+ : (getItemReadableId(items, itemData?.itemId) ??+ "..."): "New Purchase Invoice Line"}</ModalCardTitle><ModalCardDescription>{isEditing ? (<div className="flex flex-col items-start gap-1">- <span>{itemData?.description}</span>+ <span>+ {isFixedAsset+ ? initialValues.assetName ||+ indirectData.description+ : isGLAccount+ ? "G/L Account"+ : itemData?.description}+ </span><div className="flex items-center gap-2"><Badge variant="outline">{initialValues?.quantity}@@ -428,13 +494,17 @@ const PurchaseInvoiceLineForm = ({<div className="flex-shrink-0">{!isEditing && (<TabsList>- <TabsTrigger value="direct">+ <TabsTrigger value="item"><LuBox className="mr-1" />- <Trans>Direct</Trans>+ <Trans>Item</Trans></TabsTrigger>- <TabsTrigger value="indirect">+ <TabsTrigger value="gl-account"><LuReceipt className="mr-1" />- <Trans>Indirect</Trans>+ <Trans>GL Account</Trans>+ </TabsTrigger>+ <TabsTrigger value="asset">+ <LuLandmark className="mr-1" />+ <Trans>Asset</Trans></TabsTrigger></TabsList>)}@@ -448,9 +518,11 @@ const PurchaseInvoiceLineForm = ({value={routeData?.purchaseInvoice?.exchangeRate ?? 1}/>- <TabsContent value="direct">+ <TabsContent value="item"><Hidden name="invoiceLineType" value={itemType} />- <Hidden name="description" value={itemData.description} />+ {activeTab === "item" && (+ <Hidden name="description" value={itemData.description} />+ )}<Hiddenname="inventoryUnitOfMeasureCode"value={itemData?.inventoryUom}@@ -557,11 +629,314 @@ const PurchaseInvoiceLineForm = ({}))}/>++ <Location+ name="locationId"+ label={t`Delivery Location`}+ value={locationId}+ onChange={onLocationChange}+ />+ <StorageUnit+ name="storageUnitId"+ label={t`Storage Unit`}+ locationId={locationId}+ value={itemData.storageUnitId ?? undefined}+ onChange={(newValue) => {+ if (newValue) {+ setItemData((d) => ({+ ...d,+ storageUnitId: newValue?.id+ }));+ }+ }}+ />+ </>+ )}+ <CustomFormFields table="purchaseInvoiceLine" />+ </div>++ <div className="w-full border border-border rounded-md shadow-sm p-4 flex flex-col gap-4 mt-4">+ <HStack+ className="w-full justify-between cursor-pointer"+ onClick={costsDisclosure.onToggle}+ >+ <Label>+ <Trans>Tax & Shipping</Trans>+ </Label>+ <HStack>+ {itemData.taxPercent > 0 && (+ <Badge variant="red">+ {percentFormatter.format(itemData.taxPercent)}{" "}+ <Trans>Tax</Trans>+ </Badge>+ )}+ {itemData.supplierShippingCost > 0 && (+ <Badge variant="secondary">+ {currencyFormatter.format(+ itemData.supplierShippingCost+ )}+ </Badge>+ )}+ <IconButton+ icon={<LuChevronRight />}+ aria-label={+ costsDisclosure.isOpen+ ? t`Collapse Costs`+ : t`Expand Costs`+ }+ variant="ghost"+ size="md"+ onClick={(e) => {+ e.stopPropagation();+ costsDisclosure.onToggle();+ }}+ className={`transition-transform ${costsDisclosure.isOpen ? "rotate-90" : ""}`}+ />+ </HStack>+ </HStack>+ <div+ className={`grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3 pb-4 ${+ costsDisclosure.isOpen ? "" : "hidden"+ }`}+ >+ <NumberControlled+ name="supplierShippingCost"+ label={t`Shipping`}+ value={itemData.supplierShippingCost}+ minValue={0}+ formatOptions={{+ style: "currency",+ currency:+ routeData?.purchaseInvoice?.currencyCode ??+ company.baseCurrencyCode+ }}+ onChange={(value) =>+ setItemData((d) => ({+ ...d,+ supplierShippingCost: value+ }))+ }+ />+ <NumberControlled+ name="supplierTaxAmount"+ label={t`Tax Amount`}+ value={itemData.taxAmount}+ formatOptions={{+ style: "currency",+ currency:+ routeData?.purchaseInvoice?.currencyCode ??+ company.baseCurrencyCode+ }}+ onChange={(value) => {+ const subtotal =+ itemData.supplierUnitPrice * itemData.quantity ++ itemData.supplierShippingCost;+ setItemData((d) => ({+ ...d,+ taxAmount: value,+ taxPercent: subtotal > 0 ? value / subtotal : 0+ }));+ }}+ />+ <NumberControlled+ name="taxPercent"+ label={t`Tax Percent`}+ value={itemData.taxPercent}+ minValue={0}+ maxValue={1}+ step={0.0001}+ formatOptions={{+ style: "percent",+ minimumFractionDigits: 0,+ maximumFractionDigits: 2+ }}+ onChange={(value) => {+ const subtotal =+ itemData.supplierUnitPrice * itemData.quantity ++ itemData.supplierShippingCost;+ setItemData((d) => ({+ ...d,+ taxPercent: value,+ taxAmount: subtotal * value+ }));+ }}+ />+ </div>+ </div>+ </VStack>+ </TabsContent>++ {(activeTab === "gl-account" || activeTab === "asset") && (+ <>+ <Hidden+ name="invoiceLineType"+ value={+ activeTab === "asset" ? "Fixed Asset" : "G/L Account"+ }+ />++ <VStack>+ <div className="grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3">+ {activeTab === "gl-account" ? (+ <>+ <Account+ name="accountId"+ label={t`GL Account`}+ classes={["Expense"]}+ isOptional={false}+ />+ <CostCenter+ name="costCenterId"+ label={t`Cost Center`}+ isOptional+ />+ </>+ ) : (+ <>+ <Combobox+ name="assetId"+ label={t`Fixed Asset`}+ isOptional={false}+ options={assetOptions}+ value={indirectData.assetId}+ onChange={(selected) => {+ setIndirectData((d) => ({+ ...d,+ assetId: (selected?.value as string) ?? ""+ }));+ const asset = assetOptions.find(+ (o) => o.value === selected?.value+ );+ if (asset?.locationId && !locationId) {+ setLocationId(asset.locationId);+ }+ }}+ />+ <Location+ name="locationId"+ label={t`Location`}+ value={locationId}+ onChange={(newLocation) => {+ setLocationId(newLocation?.value ?? "");+ }}+ />+ </>+ )}+ <InputControlled+ className={+ activeTab === "asset" ? "col-span-1" : "col-span-3"+ }+ label={t`Description`}+ name="description"+ value={indirectData.description}+ isOptional={false}+ onChange={(newValue) =>+ setIndirectData((d) => ({+ ...d,+ description: newValue+ }))+ }+ />+ <DatePicker+ name="requiredDate"+ label={t`Required Date`}+ value={indirectData.requiredDate ?? undefined}+ onChange={(date) => {+ setIndirectData((d) => ({+ ...d,+ requiredDate: date+ }));+ }}+ />+ <NumberControlled+ name="quantity"+ label={t`Quantity`}+ isOptional={false}+ isDisabled={activeTab === "asset"}+ value={+ activeTab === "asset" ? 1 : indirectData.quantity+ }+ onChange={(value) =>+ setIndirectData((d) => ({+ ...d,+ quantity: value+ }))+ }+ />+ <NumberControlled+ name="supplierUnitPrice"+ label={t`Unit Price`}+ isOptional={false}+ value={indirectData.supplierUnitPrice}+ formatOptions={{+ style: "currency",+ currency:+ routeData?.purchaseInvoice?.currencyCode ??+ company.baseCurrencyCode+ }}+ onChange={(value) =>+ setIndirectData((d) => ({+ ...d,+ supplierUnitPrice: value+ }))+ }+ />+ <CustomFormFields table="purchaseInvoiceLine" />+ </div>++ <div className="h-4" />++ <div className="w-full border border-border rounded-md shadow-sm p-4 flex flex-col gap-4">+ <HStack+ className="w-full justify-between cursor-pointer"+ onClick={indirectCostsDisclosure.onToggle}+ >+ <Label>+ <Trans>Tax & Shipping</Trans>+ </Label>+ <HStack>+ {indirectData.taxPercent > 0 && (+ <Badge variant="red">+ {percentFormatter.format(+ indirectData.taxPercent+ )}{" "}+ <Trans>Tax</Trans>+ </Badge>+ )}+ {indirectData.supplierShippingCost > 0 && (+ <Badge variant="secondary">+ {currencyFormatter.format(+ indirectData.supplierShippingCost+ )}+ </Badge>+ )}+ <IconButton+ icon={<LuChevronRight />}+ aria-label={+ indirectCostsDisclosure.isOpen+ ? t`Collapse Costs`+ : t`Expand Costs`+ }+ variant="ghost"+ size="md"+ onClick={(e) => {+ e.stopPropagation();+ indirectCostsDisclosure.onToggle();+ }}+ className={`transition-transform ${indirectCostsDisclosure.isOpen ? "rotate-90" : ""}`}+ />+ </HStack>+ </HStack>+ <div+ className={`grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3 pb-4 ${+ indirectCostsDisclosure.isOpen ? "" : "hidden"+ }`}+ ><NumberControlledname="supplierShippingCost"label={t`Shipping`}- value={itemData.supplierShippingCost}minValue={0}+ value={indirectData.supplierShippingCost}formatOptions={{style: "currency",currency:@@ -569,17 +944,16 @@ const PurchaseInvoiceLineForm = ({company.baseCurrencyCode}}onChange={(value) =>- setItemData((d) => ({+ setIndirectData((d) => ({...d,supplierShippingCost: value}))}/>-<NumberControlledname="supplierTaxAmount"- label={t`Tax`}- value={itemData.taxAmount}+ label={t`Tax Amount`}+ value={indirectData.taxAmount}formatOptions={{style: "currency",currency:@@ -588,205 +962,57 @@ const PurchaseInvoiceLineForm = ({}}onChange={(value) => {const subtotal =- itemData.supplierUnitPrice * itemData.quantity +- itemData.supplierShippingCost;- setItemData((d) => ({+ indirectData.supplierUnitPrice *+ indirectData.quantity ++ indirectData.supplierShippingCost;+ setIndirectData((d) => ({...d,taxAmount: value,taxPercent: subtotal > 0 ? value / subtotal : 0}));}}/>-- <Location- name="locationId"- label={t`Delivery Location`}- value={locationId}- onChange={onLocationChange}- />- <StorageUnit- name="storageUnitId"- label={t`Storage Unit`}- locationId={locationId}- value={itemData.storageUnitId ?? undefined}- onChange={(newValue) => {- if (newValue) {- setItemData((d) => ({- ...d,- storageUnitId: newValue?.id- }));- }+ <NumberControlled+ name="taxPercent"+ label={t`Tax Percent`}+ value={indirectData.taxPercent}+ minValue={0}+ maxValue={1}+ step={0.0001}+ formatOptions={{+ style: "percent",+ minimumFractionDigits: 0,+ maximumFractionDigits: 2+ }}+ onChange={(value) => {+ const subtotal =+ indirectData.supplierUnitPrice *+ indirectData.quantity ++ indirectData.supplierShippingCost;+ setIndirectData((d) => ({+ ...d,+ taxPercent: value,+ taxAmount: subtotal * value+ }));}}/>- </>- )}- <NumberControlled- name="taxPercent"- label={t`Tax Percent`}- value={itemData.taxPercent}- minValue={0}- maxValue={1}- step={0.0001}- formatOptions={{- style: "percent",- minimumFractionDigits: 0,- maximumFractionDigits: 2- }}- onChange={(value) => {- const subtotal =- itemData.supplierUnitPrice * itemData.quantity +- itemData.supplierShippingCost;- setItemData((d) => ({- ...d,- taxPercent: value,- taxAmount: subtotal * value- }));- }}- />- <CustomFormFields table="purchaseInvoiceLine" />- </div>- </VStack>- </TabsContent>-- <TabsContent value="indirect">- <Hidden name="invoiceLineType" value="G/L Account" />- <Hidden name="description" value={indirectData.description} />- <VStack>- <div className="grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3">- <Account- name="accountId"- label={t`GL Account`}- classes={["Asset", "Expense"]}- />- <InputControlled- label={t`Description`}- name="description"- value={indirectData.description}- isOptional={false}- onChange={(newValue) =>- setIndirectData((d) => ({- ...d,- description: newValue- }))- }- />- <CostCenter- name="costCenterId"- label={t`Cost Center`}- isOptional- />- <DatePicker- name="requiredDate"- label={t`Required Date`}- value={indirectData.requiredDate ?? undefined}- onChange={(date) => {- setIndirectData((d) => ({- ...d,- requiredDate: date- }));- }}- />- <NumberControlled- name="quantity"- label={t`Quantity`}- value={indirectData.quantity}- onChange={(value) =>- setIndirectData((d) => ({- ...d,- quantity: value- }))- }- />- <NumberControlled- name="supplierUnitPrice"- label={t`Unit Price`}- value={indirectData.supplierUnitPrice}- formatOptions={{- style: "currency",- currency:- routeData?.purchaseInvoice?.currencyCode ??- company.baseCurrencyCode- }}- onChange={(value) =>- setIndirectData((d) => ({- ...d,- supplierUnitPrice: value- }))- }- />- <NumberControlled- name="supplierShippingCost"- label={t`Shipping`}- minValue={0}- value={indirectData.supplierShippingCost}- formatOptions={{- style: "currency",- currency:- routeData?.purchaseInvoice?.currencyCode ??- company.baseCurrencyCode- }}- onChange={(value) =>- setIndirectData((d) => ({- ...d,- supplierShippingCost: value- }))- }- />- <NumberControlled- name="supplierTaxAmount"- label={t`Tax`}- value={indirectData.taxAmount}- formatOptions={{- style: "currency",- currency:- routeData?.purchaseInvoice?.currencyCode ??- company.baseCurrencyCode- }}- onChange={(value) => {- const subtotal =- indirectData.supplierUnitPrice *- indirectData.quantity +- indirectData.supplierShippingCost;- setIndirectData((d) => ({- ...d,- taxAmount: value,- taxPercent: subtotal > 0 ? value / subtotal : 0- }));- }}- />- <NumberControlled- name="taxPercent"- label={t`Tax Percent`}- value={indirectData.taxPercent}- minValue={0}- maxValue={1}- step={0.0001}- formatOptions={{- style: "percent",- minimumFractionDigits: 0,- maximumFractionDigits: 2- }}- onChange={(value) => {- const subtotal =- indirectData.supplierUnitPrice *- indirectData.quantity +- indirectData.supplierShippingCost;- setIndirectData((d) => ({- ...d,- taxPercent: value,- taxAmount: subtotal * value- }));- }}- />- <CustomFormFields table="purchaseInvoiceLine" />- </div>- </VStack>- </TabsContent>+ </div>+ </div>+ </VStack>+ </>+ )}</ModalCardBody><ModalCardFooter>- <Submit isDisabled={isDisabled} withBlocker={false}>- <Trans>Save</Trans>- </Submit>+ <HStack className="justify-end gap-2">+ {onClose && (+ <Button variant="ghost" onClick={onClose}>+ <Trans>Cancel</Trans>+ </Button>+ )}+ <Submit isDisabled={isDisabled} withBlocker={false}>+ <Trans>Save</Trans>+ </Submit>+ </HStack></ModalCardFooter></ValidatedForm></ModalCardContent>diff --git a/apps/erp/app/modules/invoicing/ui/PurchaseInvoice/PurchaseInvoiceSummary.tsx b/apps/erp/app/modules/invoicing/ui/PurchaseInvoice/PurchaseInvoiceSummary.tsxindex 1187839b1a..dee8201653 100644--- a/apps/erp/app/modules/invoicing/ui/PurchaseInvoice/PurchaseInvoiceSummary.tsx+++ b/apps/erp/app/modules/invoicing/ui/PurchaseInvoice/PurchaseInvoiceSummary.tsx@@ -76,9 +76,13 @@ const LineItems = ({if (!line.id) return null;const isGlAccount = line.invoiceLineType === "G/L Account";+ const isFixedAsset = line.invoiceLineType === "Fixed Asset";+ const isIndirect = isGlAccount || isFixedAsset;const itemReadableId = isGlAccount? line.description || "Indirect Expense"- : getItemReadableId(items, line.itemId);+ : isFixedAsset+ ? line.assetReadableId || "Fixed Asset"+ : getItemReadableId(items, line.itemId);const lineTotal = (line.unitPrice ?? 0) * (line.quantity ?? 0);const supplierLineTotal =(line.supplierUnitPrice ?? 0) * (line.quantity ?? 0);@@ -145,7 +149,9 @@ const LineItems = ({{isGlAccount? (accounts.find((a) => a.id === line.accountId)?.name ?? "Indirect Expense")- : line.description}+ : isFixedAsset+ ? line.description || "Fixed Asset"+ : line.description}</span></VStack><VStack@@ -175,7 +181,7 @@ const LineItems = ({</motion.div></HStack><div className="flex items-center gap-2">- {!isGlAccount && (+ {!isIndirect && (<Badgevariant="outline"className="flex items-center gap-2"diff --git a/apps/erp/app/modules/invoicing/ui/SalesInvoice/SalesInvoiceExplorer.tsx b/apps/erp/app/modules/invoicing/ui/SalesInvoice/SalesInvoiceExplorer.tsxindex a39f6552e9..5a34ea95ba 100644--- a/apps/erp/app/modules/invoicing/ui/SalesInvoice/SalesInvoiceExplorer.tsx+++ b/apps/erp/app/modules/invoicing/ui/SalesInvoice/SalesInvoiceExplorer.tsx@@ -289,10 +289,14 @@ function SalesInvoiceLineItem({<ItemThumbnail thumbnailPath={line.thumbnailPath} type="Part" /><VStack spacing={0} className="min-w-0"><span className="font-semibold line-clamp-1">- {getItemReadableId(items, line.itemId) ?? ""}+ {line.invoiceLineType === "Fixed Asset"+ ? (line as any).assetReadableId || "Fixed Asset"+ : (getItemReadableId(items, line.itemId) ?? "")}</span><span className="text-muted-foreground text-xs truncate line-clamp-1">- {line.description}+ {line.invoiceLineType === "Fixed Asset"+ ? (line as any).assetName || line.description+ : line.description}</span></VStack></HStack>diff --git a/apps/erp/app/modules/invoicing/ui/SalesInvoice/SalesInvoiceLineForm.tsx b/apps/erp/app/modules/invoicing/ui/SalesInvoice/SalesInvoiceLineForm.tsxindex 23cc619b69..1b96cc8114 100644--- a/apps/erp/app/modules/invoicing/ui/SalesInvoice/SalesInvoiceLineForm.tsx+++ b/apps/erp/app/modules/invoicing/ui/SalesInvoice/SalesInvoiceLineForm.tsx@@ -1,5 +1,5 @@import { useCarbon } from "@carbon/auth";-import { ValidatedForm } from "@carbon/form";+import { Combobox, ValidatedForm } from "@carbon/form";import {Alert,AlertTitle,@@ -19,14 +19,26 @@ import {ModalCardHeader,ModalCardProvider,ModalCardTitle,+ Tabs,+ TabsContent,+ TabsList,+ TabsTrigger,toast,useDisclosure,+ useMount,VStack} from "@carbon/react";import { getItemReadableId } from "@carbon/utils";import { Trans, useLingui } from "@lingui/react/macro";import { useEffect, useState } from "react";-import { LuChevronRight, LuCircleAlert, LuPlus, LuTruck } from "react-icons/lu";+import {+ LuBox,+ LuChevronRight,+ LuCircleAlert,+ LuLandmark,+ LuPlus,+ LuTruck+} from "react-icons/lu";import { useParams } from "react-router";import type { z } from "zod";import { MethodIcon } from "~/components";@@ -59,6 +71,8 @@ import { isSalesInvoiceLocked } from "../../invoicing.models";type SalesInvoiceLineFormProps = {initialValues: z.infer<typeof salesInvoiceLineValidator> & {taxPercent?: number;+ assetReadableId?: string;+ assetName?: string;};isSalesOrderLine?: boolean;type?: "card" | "modal";@@ -136,7 +150,71 @@ const SalesInvoiceLineForm = ({itemData.taxPercent]);+ const isFixedAsset = initialValues.invoiceLineType === "Fixed Asset";+ const [activeTab, setActiveTab] = useState<"item" | "asset">(+ isFixedAsset ? "asset" : "item"+ );++ const [assetOptions, setAssetOptions] = useState<+ { value: string; label: string }[]+ >([]);+ const [assetData, setAssetData] = useState<{+ assetId: string;+ description: string;+ quantity: number;+ unitPrice: number;+ taxPercent: number;+ taxAmount: number;+ shippingCost: number;+ addOnCost: number;+ nonTaxableAddOnCost: number;+ }>({+ assetId: initialValues.assetId ?? "",+ description: initialValues.description ?? "",+ quantity: initialValues.quantity ?? 1,+ unitPrice: initialValues.unitPrice ?? 0,+ taxPercent: initialValues.taxPercent ?? 0,+ taxAmount: 0,+ shippingCost: initialValues.shippingCost ?? 0,+ addOnCost: initialValues.addOnCost ?? 0,+ nonTaxableAddOnCost: initialValues.nonTaxableAddOnCost ?? 0+ });++ useMount(() => {+ if (!carbon || !company.id) return;+ (async () => {+ const assets = await carbon+ .from("fixedAsset")+ .select("id, fixedAssetId, name")+ .eq("companyId", company.id)+ .in("status", ["Active", "Fully Depreciated"])+ .order("fixedAssetId");+ const options = (assets.data ?? []).map((a) => ({+ value: a.id,+ label: `${a.fixedAssetId} — ${a.name}`+ }));+ if (+ initialValues.assetId &&+ !options.some((o) => o.value === initialValues.assetId)+ ) {+ const current = await carbon+ .from("fixedAsset")+ .select("id, fixedAssetId, name")+ .eq("id", initialValues.assetId)+ .single();+ if (current.data) {+ options.unshift({+ value: current.data.id,+ label: `${current.data.fixedAssetId} — ${current.data.name}`+ });+ }+ }+ setAssetOptions(options);+ })();+ });+const costsDisclosure = useDisclosure();+ const assetCostsDisclosure = useDisclosure();const isEditing = initialValues.id !== undefined;const hasInvalidMethodType =itemData.methodType === "Make to Order" && !isSalesOrderLine;@@ -268,382 +346,604 @@ const SalesInvoiceLineForm = ({const currencyFormatter = useCurrencyFormatter();const percentFormatter = usePercentFormatter();+ const invoiceCurrency =+ routeData?.salesInvoice?.currencyCode ?? company.baseCurrencyCode;+return (- <ModalCardProvider type={type}>- <ModalCard- onClose={onClose}- isCollapsible={isEditing}- defaultCollapsed={false}- >- <ModalCardContent size="xxlarge">- <ValidatedForm- defaultValues={initialValues}- validator={salesInvoiceLineValidator}- method="post"- action={- isEditing- ? path.to.salesInvoiceLine(invoiceId, initialValues.id!)- : path.to.newSalesInvoiceLine(invoiceId)- }- className="w-full"- isDisabled={isEditing && isLocked}- onSubmit={() => {- if (type === "modal") onClose?.();- }}- >- <ModalCardHeader>- <ModalCardTitle+ <Tabs+ value={activeTab}+ onValueChange={(v) => setActiveTab(v as "item" | "asset")}+ className="w-full"+ >+ <ModalCardProvider type={type}>+ <ModalCard+ onClose={onClose}+ isCollapsible={isEditing}+ defaultCollapsed={false}+ >+ <ModalCardContent size="xxlarge">+ <ValidatedForm+ defaultValues={initialValues}+ validator={salesInvoiceLineValidator}+ method="post"+ action={+ isEditing+ ? path.to.salesInvoiceLine(invoiceId, initialValues.id!)+ : path.to.newSalesInvoiceLine(invoiceId)+ }+ className="w-full"+ isDisabled={isEditing && isLocked}+ onSubmit={() => {+ if (type === "modal") onClose?.();+ }}+ >+ <HStackclassName={cn(- isEditing && !itemData?.itemId && "text-muted-foreground"+ "w-full justify-between items-start",+ type === "modal" && "pr-16")}>- {isEditing ? (- (getItemReadableId(items, itemData?.itemId) ?? "...")- ) : (- <Trans>New Sales Invoice Line</Trans>- )}- </ModalCardTitle>- <ModalCardDescription>- {isEditing ? (- <div className="flex flex-col items-start gap-1">- <span>{itemData?.description}</span>- <div className="flex items-center gap-2">- <Badge- variant="outline"- className="flex items-center gap-2"- >- {initialValues?.quantity}{" "}- <MethodIcon type={itemData.methodType} />- </Badge>- <Badge variant="green">- {currencyFormatter.format(- initialValues?.unitPrice ?? 0- )}{" "}- {initialValues?.unitOfMeasureCode}- </Badge>- {initialValues?.taxPercent > 0 ? (- <Badge variant="red">- {percentFormatter.format(initialValues?.taxPercent)}{" "}- {t`Tax`}- </Badge>- ) : null}- </div>- </div>- ) : (- t`A sales invoice line contains invoice details for a particular item`- )}- </ModalCardDescription>- </ModalCardHeader>- <ModalCardBody>- <Hidden name="id" />- <Hidden name="invoiceId" />- <Hidden name="invoiceLineType" value={itemType} />- <Hidden name="description" value={itemData.description} />- <Hidden- name="exchangeRate"- value={routeData?.salesInvoice?.exchangeRate ?? 1}- />- <Hidden- name="unitOfMeasureCode"- value={itemData?.unitOfMeasureCode}- />-- <VStack>- {hasInvalidMethodType && (- <Alert variant="destructive" className="mb-4">- <LuCircleAlert className="w-4 h-4" />- <AlertTitle>- <Trans>- Make items cannot be invoiced directly. Change method to- Pick to continue.- </Trans>- </AlertTitle>- </Alert>- )}- <div className="grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3">- <Item- name="itemId"- label={itemType}- // @ts-ignore- type={itemType}- locationId={locationId}- onChange={(value) => {- onItemChange(value?.value as string);- }}- onTypeChange={onTypeChange}- />-- <FormControl className="col-span-2">- <FormLabel isOptional>- <Trans>Description</Trans>- </FormLabel>- <Input- value={itemData.description}- onChange={(e) =>- setItemData((d) => ({- ...d,- description: e.target.value- }))- }- />- </FormControl>-- {["Item", "Part", "Material", "Tool", "Consumable"].includes(- itemType- ) && (- <>- <div className="space-y-2">- <SelectControlled- name="methodType"- label={t`Method`}- options={- methodType.map((m) => ({- label: (- <span className="flex items-center gap-2">- <MethodIcon type={m} />- {m}- </span>- ),- value: m- })) ?? []- }- value={itemData.methodType}- onChange={(newValue) => {- if (newValue)- setItemData((d) => ({- ...d,- methodType: newValue?.value- }));- }}- />+ <ModalCardHeader className="flex flex-1">+ <ModalCardTitle+ className={cn(+ isEditing &&+ !isFixedAsset &&+ !itemData?.itemId &&+ "text-muted-foreground"+ )}+ >+ {isEditing ? (+ isFixedAsset ? (+ initialValues.assetReadableId || "Fixed Asset"+ ) : (+ (getItemReadableId(items, itemData?.itemId) ?? "...")+ )+ ) : (+ <Trans>New Sales Invoice Line</Trans>+ )}+ </ModalCardTitle>+ <ModalCardDescription>+ {isEditing ? (+ <div className="flex flex-col items-start gap-1">+ <span>+ {isFixedAsset+ ? initialValues.assetName || assetData.description+ : itemData?.description}+ </span>+ <div className="flex items-center gap-2">+ <Badge+ variant="outline"+ className="flex items-center gap-2"+ >+ {initialValues?.quantity}{" "}+ {!isFixedAsset && (+ <MethodIcon type={itemData.methodType} />+ )}+ </Badge>+ <Badge variant="green">+ {currencyFormatter.format(+ initialValues?.unitPrice ?? 0+ )}{" "}+ {initialValues?.unitOfMeasureCode}+ </Badge>+ {(initialValues?.taxPercent ?? 0) > 0 ? (+ <Badge variant="red">+ {percentFormatter.format(+ initialValues?.taxPercent ?? 0+ )}{" "}+ {t`Tax`}+ </Badge>+ ) : null}+ </div></div>+ ) : (+ t`A sales invoice line contains invoice details for a particular item`+ )}+ </ModalCardDescription>+ </ModalCardHeader>+ <div className="flex-shrink-0">+ {!isEditing && (+ <TabsList>+ <TabsTrigger value="item">+ <LuBox className="mr-1" />+ <Trans>Item</Trans>+ </TabsTrigger>+ <TabsTrigger value="asset">+ <LuLandmark className="mr-1" />+ <Trans>Asset</Trans>+ </TabsTrigger>+ </TabsList>+ )}+ </div>+ </HStack>+ <ModalCardBody>+ <Hidden name="id" />+ <Hidden name="invoiceId" />+ <Hidden+ name="exchangeRate"+ value={routeData?.salesInvoice?.exchangeRate ?? 1}+ />++ <TabsContent value="item">+ <Hidden name="invoiceLineType" value={itemType} />+ <Hidden name="description" value={itemData.description} />+ <Hidden+ name="unitOfMeasureCode"+ value={itemData?.unitOfMeasureCode}+ />- <NumberControlled- name="quantity"- label={t`Quantity`}- value={itemData.quantity}+ <VStack>+ {hasInvalidMethodType && (+ <Alert variant="destructive" className="mb-4">+ <LuCircleAlert className="w-4 h-4" />+ <AlertTitle>+ <Trans>+ Make items cannot be invoiced directly. Change+ method to Pick to continue.+ </Trans>+ </AlertTitle>+ </Alert>+ )}+ <div className="grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3">+ <Item+ name="itemId"+ label={itemType}+ // @ts-ignore+ type={itemType}+ locationId={locationId}onChange={(value) => {- setItemData((d) => ({- ...d,- quantity: value- }));+ onItemChange(value?.value as string);}}+ onTypeChange={onTypeChange}/>- <NumberControlled- name="unitPrice"- label={t`Unit Price`}- value={itemData.unitPrice}- formatOptions={{- style: "currency",- currency:- routeData?.salesInvoice?.currencyCode ??- company.baseCurrencyCode- }}- onChange={(value) =>- setItemData((d) => ({- ...d,- unitPrice: value- }))- }- />- <Location- name="locationId"- label={t`Shipping Location`}- value={locationId}- onChange={onLocationChange}- />- <StorageUnit- name="storageUnitId"- label={t`Storage Unit`}- locationId={locationId}- value={itemData.storageUnitId ?? undefined}- onChange={(newValue) => {- if (newValue) {+ <FormControl className="col-span-2">+ <FormLabel isOptional>+ <Trans>Description</Trans>+ </FormLabel>+ <Input+ value={itemData.description}+ onChange={(e) =>setItemData((d) => ({...d,- storageUnitId: newValue?.id- }));+ description: e.target.value+ }))}- }}- />- </>- )}- <CustomFormFields table="salesInvoiceLine" />- </div>+ />+ </FormControl>- {["Item", "Part", "Material", "Tool", "Consumable"].includes(- itemType- ) && (- <div className="w-full">- <div className="w-full border border-border rounded-md shadow-sm p-4 flex flex-col gap-4 mt-4">- <HStack- className="w-full justify-between cursor-pointer"- onClick={costsDisclosure.onToggle}- >- <Label>- <Trans>Tax & Additional Costs</Trans>- </Label>- <HStack>- {(itemData.taxPercent ?? 0) > 0 && (- <Badge variant="red">- {percentFormatter.format(- itemData.taxPercent ?? 0- )}{" "}- <Trans>Tax</Trans>- </Badge>- )}- {(itemData.shippingCost ?? 0) > 0 && (- <Badge- variant="secondary"- className="flex items-center gap-1"- >- <LuTruck />- <span>- {currencyFormatter.format(- itemData.shippingCost ?? 0- )}- </span>- </Badge>- )}- {(initialValues?.addOnCost ?? 0) > 0 ||- ((initialValues?.nonTaxableAddOnCost ?? 0) > 0 && (- <Badge- variant="secondary"- className="flex items-center gap-1"- >- <LuPlus />- <span>- {currencyFormatter.format(- (initialValues?.addOnCost ?? 0) +- (initialValues?.nonTaxableAddOnCost ?? 0)- )}{" "}- <Trans>Add-On</Trans>- </span>- </Badge>- ))}-- <IconButton- icon={<LuChevronRight />}- aria-label={- costsDisclosure.isOpen- ? t`Collapse Costs`- : t`Expand Costs`+ {[+ "Item",+ "Part",+ "Material",+ "Tool",+ "Consumable"+ ].includes(itemType) && (+ <>+ <div className="space-y-2">+ <SelectControlled+ name="methodType"+ label={t`Method`}+ options={+ methodType.map((m) => ({+ label: (+ <span className="flex items-center gap-2">+ <MethodIcon type={m} />+ {m}+ </span>+ ),+ value: m+ })) ?? []+ }+ value={itemData.methodType}+ onChange={(newValue) => {+ if (newValue)+ setItemData((d) => ({+ ...d,+ methodType: newValue?.value+ }));+ }}+ />+ </div>++ <NumberControlled+ name="quantity"+ label={t`Quantity`}+ value={itemData.quantity}+ onChange={(value) => {+ setItemData((d) => ({+ ...d,+ quantity: value+ }));+ }}+ />++ <NumberControlled+ name="unitPrice"+ label={t`Unit Price`}+ value={itemData.unitPrice}+ formatOptions={{+ style: "currency",+ currency: invoiceCurrency+ }}+ onChange={(value) =>+ setItemData((d) => ({+ ...d,+ unitPrice: value+ }))}- variant="ghost"- size="md"- onClick={(e) => {- e.stopPropagation();- costsDisclosure.onToggle();+ />+ <Location+ name="locationId"+ label={t`Shipping Location`}+ value={locationId}+ onChange={onLocationChange}+ />+ <StorageUnit+ name="storageUnitId"+ label={t`Storage Unit`}+ locationId={locationId}+ value={itemData.storageUnitId ?? undefined}+ onChange={(newValue) => {+ if (newValue) {+ setItemData((d) => ({+ ...d,+ storageUnitId: newValue?.id+ }));+ }}}- className={`transition-transform ${- costsDisclosure.isOpen ? "rotate-90" : ""- }`}/>- </HStack>- </HStack>- <div- className={`grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3 pb-4 ${- costsDisclosure.isOpen ? "" : "hidden"- }`}- >- <NumberControlled- name="taxPercent"- label={t`Tax Percent`}- value={itemData.taxPercent}- minValue={0}- maxValue={1}- step={0.0001}- formatOptions={{- style: "percent",- minimumFractionDigits: 0,- maximumFractionDigits: 2- }}- onChange={(value) => {- const subtotal =- itemData.unitPrice * itemData.quantity +- itemData.shippingCost;- setItemData((d) => ({+ </>+ )}+ <CustomFormFields table="salesInvoiceLine" />+ </div>++ {[+ "Item",+ "Part",+ "Material",+ "Tool",+ "Consumable"+ ].includes(itemType) && (+ <div className="w-full">+ <div className="w-full border border-border rounded-md shadow-sm p-4 flex flex-col gap-4 mt-4">+ <HStack+ className="w-full justify-between cursor-pointer"+ onClick={costsDisclosure.onToggle}+ >+ <Label>+ <Trans>Tax & Additional Costs</Trans>+ </Label>+ <HStack>+ {(itemData.taxPercent ?? 0) > 0 && (+ <Badge variant="red">+ {percentFormatter.format(+ itemData.taxPercent ?? 0+ )}{" "}+ <Trans>Tax</Trans>+ </Badge>+ )}+ {(itemData.shippingCost ?? 0) > 0 && (+ <Badge+ variant="secondary"+ className="flex items-center gap-1"+ >+ <LuTruck />+ <span>+ {currencyFormatter.format(+ itemData.shippingCost ?? 0+ )}+ </span>+ </Badge>+ )}+ {(initialValues?.addOnCost ?? 0) > 0 ||+ ((initialValues?.nonTaxableAddOnCost ?? 0) >+ 0 && (+ <Badge+ variant="secondary"+ className="flex items-center gap-1"+ >+ <LuPlus />+ <span>+ {currencyFormatter.format(+ (initialValues?.addOnCost ?? 0) ++ (initialValues?.nonTaxableAddOnCost ??+ 0)+ )}{" "}+ <Trans>Add-On</Trans>+ </span>+ </Badge>+ ))}++ <IconButton+ icon={<LuChevronRight />}+ aria-label={+ costsDisclosure.isOpen+ ? t`Collapse Costs`+ : t`Expand Costs`+ }+ variant="ghost"+ size="md"+ onClick={(e) => {+ e.stopPropagation();+ costsDisclosure.onToggle();+ }}+ className={`transition-transform ${+ costsDisclosure.isOpen ? "rotate-90" : ""+ }`}+ />+ </HStack>+ </HStack>+ <div+ className={`grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3 pb-4 ${+ costsDisclosure.isOpen ? "" : "hidden"+ }`}+ >+ <NumberControlled+ name="taxPercent"+ label={t`Tax Percent`}+ value={itemData.taxPercent}+ minValue={0}+ maxValue={1}+ step={0.0001}+ formatOptions={{+ style: "percent",+ minimumFractionDigits: 0,+ maximumFractionDigits: 2+ }}+ onChange={(value) => {+ const subtotal =+ itemData.unitPrice * itemData.quantity ++ itemData.shippingCost;+ setItemData((d) => ({+ ...d,+ taxPercent: value,+ taxAmount: subtotal * value+ }));+ }}+ />+ <NumberControlled+ name="taxAmount"+ label={t`Tax Amount`}+ value={itemData.taxAmount}+ formatOptions={{+ style: "currency",+ currency: invoiceCurrency+ }}+ onChange={(value) => {+ const subtotal =+ itemData.unitPrice * itemData.quantity ++ itemData.shippingCost;+ setItemData((d) => ({+ ...d,+ taxAmount: value,+ taxPercent:+ subtotal > 0 ? value / subtotal : 0+ }));+ }}+ />+ <NumberControlled+ name="shippingCost"+ label={t`Shipping Cost`}+ value={itemData.shippingCost}+ minValue={0}+ formatOptions={{+ style: "currency",+ currency: invoiceCurrency+ }}+ onChange={(value) =>+ setItemData((d) => ({+ ...d,+ shippingCost: value+ }))+ }+ />+ <Number+ name="addOnCost"+ label={t`Add-On Cost`}+ formatOptions={{+ style: "currency",+ currency: invoiceCurrency+ }}+ />+ <Number+ name="nonTaxableAddOnCost"+ label={t`Non-Taxable Add-On Cost`}+ formatOptions={{+ style: "currency",+ currency: invoiceCurrency+ }}+ />+ </div>+ </div>+ </div>+ )}+ </VStack>+ </TabsContent>++ {activeTab === "asset" && (+ <>+ <Hidden name="invoiceLineType" value="Fixed Asset" />+ <Hidden name="description" value={assetData.description} />+ <VStack>+ <div className="grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3">+ <Combobox+ name="assetId"+ label={t`Fixed Asset`}+ isOptional={false}+ options={assetOptions}+ value={assetData.assetId}+ onChange={(selected) => {+ setAssetData((d) => ({...d,- taxPercent: value,- taxAmount: subtotal * value+ assetId: (selected?.value as string) ?? ""}));}}/>+ <Location+ name="locationId"+ label={t`Shipping Location`}+ value={locationId}+ onChange={onLocationChange}+ />+ <FormControl>+ <FormLabel>+ <Trans>Description</Trans>+ </FormLabel>+ <Input+ value={assetData.description}+ onChange={(e) =>+ setAssetData((d) => ({+ ...d,+ description: e.target.value+ }))+ }+ />+ </FormControl><NumberControlled- name="taxAmount"- label={t`Tax Amount`}- value={itemData.taxAmount}- formatOptions={{- style: "currency",- currency:- routeData?.salesInvoice?.currencyCode ??- company.baseCurrencyCode- }}- onChange={(value) => {- const subtotal =- itemData.unitPrice * itemData.quantity +- itemData.shippingCost;- setItemData((d) => ({- ...d,- taxAmount: value,- taxPercent: subtotal > 0 ? value / subtotal : 0- }));- }}+ name="quantity"+ label={t`Quantity`}+ isOptional={false}+ isDisabled+ value={1}+ onChange={() => undefined}/><NumberControlled- name="shippingCost"- label={t`Shipping Cost`}- value={itemData.shippingCost}- minValue={0}+ name="unitPrice"+ label={t`Unit Price`}+ isOptional={false}+ value={assetData.unitPrice}formatOptions={{style: "currency",- currency:- routeData?.salesInvoice?.currencyCode ??- company.baseCurrencyCode+ currency: invoiceCurrency}}onChange={(value) =>- setItemData((d) => ({- ...d,- shippingCost: value- }))+ setAssetData((d) => ({ ...d, unitPrice: value }))}/>- <Number- name="addOnCost"- label={t`Add-On Cost`}- formatOptions={{- style: "currency",- currency:- routeData?.salesInvoice?.currencyCode ??- company.baseCurrencyCode- }}- />- <Number- name="nonTaxableAddOnCost"- label={t`Non-Taxable Add-On Cost`}- formatOptions={{- style: "currency",- currency:- routeData?.salesInvoice?.currencyCode ??- company.baseCurrencyCode- }}- />+ <CustomFormFields table="salesInvoiceLine" /></div>- </div>- </div>++ <div className="h-4" />++ <div className="w-full border border-border rounded-md shadow-sm p-4 flex flex-col gap-4">+ <HStack+ className="w-full justify-between cursor-pointer"+ onClick={assetCostsDisclosure.onToggle}+ >+ <Label>+ <Trans>Tax & Additional Costs</Trans>+ </Label>+ <HStack>+ {assetData.taxPercent > 0 && (+ <Badge variant="red">+ {percentFormatter.format(assetData.taxPercent)}{" "}+ <Trans>Tax</Trans>+ </Badge>+ )}+ <IconButton+ icon={<LuChevronRight />}+ aria-label={+ assetCostsDisclosure.isOpen+ ? t`Collapse Costs`+ : t`Expand Costs`+ }+ variant="ghost"+ size="md"+ onClick={(e) => {+ e.stopPropagation();+ assetCostsDisclosure.onToggle();+ }}+ className={`transition-transform ${assetCostsDisclosure.isOpen ? "rotate-90" : ""}`}+ />+ </HStack>+ </HStack>+ <div+ className={`grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3 pb-4 ${+ assetCostsDisclosure.isOpen ? "" : "hidden"+ }`}+ >+ <NumberControlled+ name="taxPercent"+ label={t`Tax Percent`}+ value={assetData.taxPercent}+ minValue={0}+ maxValue={1}+ step={0.0001}+ formatOptions={{+ style: "percent",+ minimumFractionDigits: 0,+ maximumFractionDigits: 2+ }}+ onChange={(value) =>+ setAssetData((d) => ({+ ...d,+ taxPercent: value+ }))+ }+ />+ <NumberControlled+ name="shippingCost"+ label={t`Shipping Cost`}+ value={assetData.shippingCost}+ minValue={0}+ formatOptions={{+ style: "currency",+ currency: invoiceCurrency+ }}+ onChange={(value) =>+ setAssetData((d) => ({+ ...d,+ shippingCost: value+ }))+ }+ />+ <NumberControlled+ name="addOnCost"+ label={t`Add-On Cost`}+ value={assetData.addOnCost}+ formatOptions={{+ style: "currency",+ currency: invoiceCurrency+ }}+ onChange={(value) =>+ setAssetData((d) => ({+ ...d,+ addOnCost: value+ }))+ }+ />+ <NumberControlled+ name="nonTaxableAddOnCost"+ label={t`Non-Taxable Add-On Cost`}+ value={assetData.nonTaxableAddOnCost}+ formatOptions={{+ style: "currency",+ currency: invoiceCurrency+ }}+ onChange={(value) =>+ setAssetData((d) => ({+ ...d,+ nonTaxableAddOnCost: value+ }))+ }+ />+ </div>+ </div>+ </VStack>+ </>)}- </VStack>- </ModalCardBody>- <ModalCardFooter>- <Submit isDisabled={isDisabled} withBlocker={false}>- <Trans>Save</Trans>- </Submit>- </ModalCardFooter>- </ValidatedForm>- </ModalCardContent>- </ModalCard>- </ModalCardProvider>+ </ModalCardBody>+ <ModalCardFooter>+ <Submit isDisabled={isDisabled} withBlocker={false}>+ <Trans>Save</Trans>+ </Submit>+ </ModalCardFooter>+ </ValidatedForm>+ </ModalCardContent>+ </ModalCard>+ </ModalCardProvider>+ </Tabs>);};diff --git a/apps/erp/app/modules/invoicing/ui/SalesInvoice/SalesInvoiceSummary.tsx b/apps/erp/app/modules/invoicing/ui/SalesInvoice/SalesInvoiceSummary.tsxindex 5038fdcfb8..2f586ec725 100644--- a/apps/erp/app/modules/invoicing/ui/SalesInvoice/SalesInvoiceSummary.tsx+++ b/apps/erp/app/modules/invoicing/ui/SalesInvoice/SalesInvoiceSummary.tsx@@ -73,7 +73,10 @@ const LineItems = ({{salesInvoiceLines.map((line) => {if (!line.id) return null;- const itemReadableId = getItemReadableId(items, line.itemId);+ const itemReadableId =+ line.invoiceLineType === "Fixed Asset"+ ? (line as any).assetReadableId || "Fixed Asset"+ : getItemReadableId(items, line.itemId);const lineSubtotal = (line.unitPrice ?? 0) * (line.quantity ?? 0);const customerSubtotal =(line.convertedUnitPrice ?? 0) * (line.quantity ?? 0);@@ -183,9 +186,11 @@ const LineItems = ({className="flex items-center gap-2">{line.quantity}- <MethodIcon- type={line.methodType ?? "Pull from Inventory"}- />+ {line.invoiceLineType !== "Fixed Asset" && (+ <MethodIcon+ type={line.methodType ?? "Pull from Inventory"}+ />+ )}</Badge><Badge variant="green">{formatter.format(line.unitPrice ?? 0)}{" "}diff --git a/apps/erp/app/modules/items/ui/useItemsSubmodules.tsx b/apps/erp/app/modules/items/ui/useItemsSubmodules.tsxindex b2882635e1..9d0beed466 100644--- a/apps/erp/app/modules/items/ui/useItemsSubmodules.tsx+++ b/apps/erp/app/modules/items/ui/useItemsSubmodules.tsx@@ -53,7 +53,7 @@ export default function useItemsSubmodules() {]},{- name: t`Configure Materials`,+ name: t`Material Properties`,routes: [{name: t`Dimensions`,diff --git a/apps/erp/app/modules/purchasing/purchasing.models.ts b/apps/erp/app/modules/purchasing/purchasing.models.tsindex e594311251..9151d16d38 100644--- a/apps/erp/app/modules/purchasing/purchasing.models.ts+++ b/apps/erp/app/modules/purchasing/purchasing.models.ts@@ -190,11 +190,14 @@ export const purchaseOrderLineValidator = z.object({id: zfd.text(z.string().optional()),purchaseOrderId: z.string().min(1, { message: "Order is required" }),- purchaseOrderLineType: z.enum([...methodItemType, "G/L Account"], {- errorMap: (issue, ctx) => ({- message: "Type is required"- })- }),+ purchaseOrderLineType: z.enum(+ [...methodItemType, "G/L Account", "Fixed Asset"],+ {+ errorMap: (issue, ctx) => ({+ message: "Type is required"+ })+ }+ ),itemId: zfd.text(z.string().optional()),accountId: zfd.text(z.string().optional()),costCenterId: zfd.text(z.string().optional()),@@ -242,6 +245,16 @@ export const purchaseOrderLineValidator = zmessage: "Description is required",path: ["description"]}+ )+ .refine(+ (data) =>+ data.purchaseOrderLineType === "Fixed Asset"+ ? (data.purchaseQuantity ?? 1) === 1+ : true,+ {+ message: "Fixed Asset quantity must be 1",+ path: ["purchaseQuantity"]+ });export const purchaseOrderPaymentValidator = z.object({diff --git a/apps/erp/app/modules/purchasing/ui/PurchaseOrder/PurchaseOrderExplorer.tsx b/apps/erp/app/modules/purchasing/ui/PurchaseOrder/PurchaseOrderExplorer.tsxindex 71a7e4185d..2f75fa3cdd 100644--- a/apps/erp/app/modules/purchasing/ui/PurchaseOrder/PurchaseOrderExplorer.tsx+++ b/apps/erp/app/modules/purchasing/ui/PurchaseOrder/PurchaseOrderExplorer.tsx@@ -243,12 +243,16 @@ function PurchaseOrderLineBody({<span className="font-semibold line-clamp-1">{line.purchaseOrderLineType === "G/L Account"? line.description || "Indirect Expense"- : getItemReadableId(items, line.itemId)}+ : line.purchaseOrderLineType === "Fixed Asset"+ ? (line as any).assetReadableId || "Fixed Asset"+ : getItemReadableId(items, line.itemId)}</span><span className="text-muted-foreground text-xs truncate line-clamp-1">{line.purchaseOrderLineType === "G/L Account"? "G/L Account"- : line.description}+ : line.purchaseOrderLineType === "Fixed Asset"+ ? (line as any).assetName || line.description+ : line.description}</span></VStack></HStack>@@ -306,13 +310,17 @@ function PurchaseOrderLineItem({<VStack spacing={0} className="min-w-0"><span className="font-semibold line-clamp-1">{line.purchaseOrderLineType === "G/L Account"- ? line.description || "Indirect Expense"- : getItemReadableId(items, line.itemId)}+ ? line.description || "G/L Account"+ : line.purchaseOrderLineType === "Fixed Asset"+ ? (line as any).assetReadableId || "Fixed Asset"+ : getItemReadableId(items, line.itemId)}</span><span className="text-muted-foreground text-xs truncate line-clamp-1">{line.purchaseOrderLineType === "G/L Account"? "G/L Account"- : line.description}+ : line.purchaseOrderLineType === "Fixed Asset"+ ? line.assetName || line.description+ : line.description}</span></VStack></HStack>diff --git a/apps/erp/app/modules/purchasing/ui/PurchaseOrder/PurchaseOrderLineForm.tsx b/apps/erp/app/modules/purchasing/ui/PurchaseOrder/PurchaseOrderLineForm.tsxindex 1f71c63a39..905ac74779 100644--- a/apps/erp/app/modules/purchasing/ui/PurchaseOrder/PurchaseOrderLineForm.tsx+++ b/apps/erp/app/modules/purchasing/ui/PurchaseOrder/PurchaseOrderLineForm.tsx@@ -7,11 +7,14 @@ import {} from "@carbon/form";import {Badge,+ Button,cn,FormControl,FormLabel,HStack,+ IconButton,Input,+ Label,ModalCard,ModalCardBody,ModalCardContent,@@ -33,7 +36,7 @@ import { getLocalTimeZone, today } from "@internationalized/date";import { Trans, useLingui } from "@lingui/react/macro";import type { PostgrestResponse } from "@supabase/supabase-js";import { useEffect, useMemo, useState } from "react";-import { LuBox, LuReceipt } from "react-icons/lu";+import { LuBox, LuChevronRight, LuLandmark, LuReceipt } from "react-icons/lu";import { useFetcher, useParams } from "react-router";import type { z } from "zod";import {@@ -69,7 +72,10 @@ import { path } from "~/utils/path";import DeletePurchaseOrderLine from "./DeletePurchaseOrderLine";type PurchaseOrderLineFormProps = {- initialValues: z.infer<typeof purchaseOrderLineValidator>;+ initialValues: z.infer<typeof purchaseOrderLineValidator> & {+ assetReadableId?: string;+ assetName?: string;+ };type?: "card" | "modal";onClose?: () => void;};@@ -164,12 +170,14 @@ const PurchaseOrderLineForm = ({const isEditing = initialValues.id !== undefined;const isGLAccount = initialValues.purchaseOrderLineType === "G/L Account";- const [activeTab, setActiveTab] = useState<"direct" | "indirect">(- isGLAccount ? "indirect" : "direct"+ const isFixedAsset = initialValues.purchaseOrderLineType === "Fixed Asset";+ const [activeTab, setActiveTab] = useState<"item" | "gl-account" | "asset">(+ isFixedAsset ? "asset" : isGLAccount ? "gl-account" : "item");const [indirectData, setIndirectData] = useState<{accountId: string;+ assetId: string;costCenterId: string;description: string;purchaseQuantity: number;@@ -180,6 +188,7 @@ const PurchaseOrderLineForm = ({taxPercent: number;}>({accountId: initialValues.accountId ?? "",+ assetId: initialValues.assetId ?? "",costCenterId: initialValues.costCenterId ?? "",description: initialValues.description ?? "",purchaseQuantity: initialValues.purchaseQuantity ?? 1,@@ -216,6 +225,47 @@ const PurchaseOrderLineForm = ({indirectData.taxPercent]);+ const costsDisclosure = useDisclosure();+ const indirectCostsDisclosure = useDisclosure();++ const [assetOptions, setAssetOptions] = useState<+ { value: string; label: string; locationId: string | null }[]+ >([]);++ useMount(() => {+ (async () => {+ const assets = await carbon+ .from("fixedAsset")+ .select("id, fixedAssetId, name, locationId")+ .eq("companyId", company.id)+ .eq("status", "Draft")+ .order("fixedAssetId");+ const options = (assets.data ?? []).map((a) => ({+ value: a.id,+ label: `${a.fixedAssetId} — ${a.name}`,+ locationId: a.locationId+ }));+ if (+ initialValues.assetId &&+ !options.some((o) => o.value === initialValues.assetId)+ ) {+ const current = await carbon+ .from("fixedAsset")+ .select("id, fixedAssetId, name, locationId")+ .eq("id", initialValues.assetId)+ .single();+ if (current.data) {+ options.unshift({+ value: current.data.id,+ label: `${current.data.fixedAssetId} — ${current.data.name}`,+ locationId: current.data.locationId+ });+ }+ }+ setAssetOptions(options);+ })();+ });+// Load price breaks on mount when editing so quantity changes resolve correctlyuseMount(() => {if (!isEditing || !initialValues.itemId) return;@@ -388,7 +438,9 @@ const PurchaseOrderLineForm = ({<><Tabsvalue={activeTab}- onValueChange={(v) => setActiveTab(v as "direct" | "indirect")}+ onValueChange={(v) =>+ setActiveTab(v as "item" | "gl-account" | "asset")+ }className="w-full"><ModalCardProvider type={type}>@@ -425,14 +477,18 @@ const PurchaseOrderLineForm = ({className={cn(isEditing &&!isGLAccount &&+ !isFixedAsset &&!itemData?.itemId &&"text-muted-foreground")}>{isEditing- ? isGLAccount- ? indirectData.description || "G/L Account"- : getItemReadableId(items, itemData?.itemId) || "..."+ ? isFixedAsset+ ? initialValues.assetReadableId || "Fixed Asset"+ : isGLAccount+ ? indirectData.description || "G/L Account"+ : getItemReadableId(items, itemData?.itemId) ||+ "...": "New Purchase Order Line"}</ModalCardTitle><ModalCardDescription>@@ -440,7 +496,14 @@ const PurchaseOrderLineForm = ({<Badge variant="default">Outside Processing</Badge>) : isEditing ? (<div className="flex flex-col items-start gap-1">- <span>{itemData?.description}</span>+ <span>+ {isFixedAsset+ ? initialValues.assetName ||+ indirectData.description+ : isGLAccount+ ? "G/L Account"+ : itemData?.description}+ </span><div className="flex items-center gap-2"><Badge variant="outline">{initialValues?.purchaseQuantity}@@ -472,13 +535,17 @@ const PurchaseOrderLineForm = ({<div className="flex-shrink-0">{!isEditing && (<TabsList>- <TabsTrigger value="direct">+ <TabsTrigger value="item"><LuBox className="mr-1" />- <Trans>Direct</Trans>+ <Trans>Item</Trans></TabsTrigger>- <TabsTrigger value="indirect">+ <TabsTrigger value="gl-account"><LuReceipt className="mr-1" />- <Trans>Indirect</Trans>+ <Trans>GL Account</Trans>+ </TabsTrigger>+ <TabsTrigger value="asset">+ <LuLandmark className="mr-1" />+ <Trans>Asset</Trans></TabsTrigger></TabsList>)}@@ -492,7 +559,7 @@ const PurchaseOrderLineForm = ({value={routeData?.purchaseOrder?.exchangeRate ?? 1}/>- <TabsContent value="direct">+ <TabsContent value="item"><Hidden name="purchaseOrderLineType" value={itemType} /><Hiddenname="inventoryUnitOfMeasureCode"@@ -610,54 +677,13 @@ const PurchaseOrderLineForm = ({}))}/>- <NumberControlled- name="supplierShippingCost"- label={t`Shipping`}- minValue={0}- value={itemData.supplierShippingCost}- formatOptions={{- style: "currency",- currency:- routeData?.purchaseOrder?.currencyCode ??- company.baseCurrencyCode- }}- onChange={(value) =>- setItemData((d) => ({- ...d,- supplierShippingCost: value- }))- }- />- <NumberControlled- name="supplierTaxAmount"- label={t`Tax`}- value={itemData.supplierTaxAmount}- formatOptions={{- style: "currency",- currency:- routeData?.purchaseOrder?.currencyCode ??- company.baseCurrencyCode- }}- onChange={(value) => {- const subtotal =- itemData.supplierUnitPrice *- itemData.purchaseQuantity +- itemData.supplierShippingCost;- setItemData((d) => ({- ...d,- supplierTaxAmount: value,- taxPercent: subtotal > 0 ? value / subtotal : 0- }));- }}- />{["Item","Part","Service","Material","Tool",- "Consumable",- "Fixed Asset"+ "Consumable"].includes(itemType) &&!isOutsideProcessing && (<Location@@ -673,8 +699,7 @@ const PurchaseOrderLineForm = ({"Service","Material","Tool",- "Consumable",- "Fixed Asset"+ "Consumable"].includes(itemType) &&!isOutsideProcessing && (<StorageUnit@@ -692,180 +717,381 @@ const PurchaseOrderLineForm = ({}}/>)}- <NumberControlled- name="taxPercent"- label={t`Tax Percent`}- value={itemData.taxPercent}- minValue={0}- maxValue={1}- step={0.0001}- formatOptions={{- style: "percent",- minimumFractionDigits: 0,- maximumFractionDigits: 2- }}- onChange={(value) => {- const subtotal =- itemData.supplierUnitPrice *- itemData.purchaseQuantity +- itemData.supplierShippingCost;- setItemData((d) => ({- ...d,- taxPercent: value,- supplierTaxAmount: subtotal * value- }));- }}- /><CustomFormFields table="purchaseOrderLine" /></div>- </VStack>- </TabsContent>- <TabsContent value="indirect">- <Hidden name="purchaseOrderLineType" value="G/L Account" />- <Hidden- name="description"- value={indirectData.description}- />- <VStack>- <div className="grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3">- <Account- name="accountId"- label={t`GL Account`}- classes={["Asset", "Expense"]}- />- <FormControl>- <FormLabel>- <Trans>Description</Trans>- </FormLabel>- <Input- value={indirectData.description}- onChange={(e) =>- setIndirectData((d) => ({+ <div className="w-full border border-border rounded-md shadow-sm p-4 flex flex-col gap-4 mt-4">+ <HStack+ className="w-full justify-between cursor-pointer"+ onClick={costsDisclosure.onToggle}+ >+ <Label>+ <Trans>Tax & Shipping</Trans>+ </Label>+ <HStack>+ {itemData.taxPercent > 0 && (+ <Badge variant="red">+ {percentFormatter.format(itemData.taxPercent)}{" "}+ <Trans>Tax</Trans>+ </Badge>+ )}+ {itemData.supplierShippingCost > 0 && (+ <Badge variant="secondary">+ {currencyFormatter.format(+ itemData.supplierShippingCost+ )}+ </Badge>+ )}+ <IconButton+ icon={<LuChevronRight />}+ aria-label={+ costsDisclosure.isOpen+ ? t`Collapse Costs`+ : t`Expand Costs`+ }+ variant="ghost"+ size="md"+ onClick={(e) => {+ e.stopPropagation();+ costsDisclosure.onToggle();+ }}+ className={`transition-transform ${costsDisclosure.isOpen ? "rotate-90" : ""}`}+ />+ </HStack>+ </HStack>+ <div+ className={`grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3 pb-4 ${+ costsDisclosure.isOpen ? "" : "hidden"+ }`}+ >+ <NumberControlled+ name="supplierShippingCost"+ label={t`Shipping`}+ minValue={0}+ value={itemData.supplierShippingCost}+ formatOptions={{+ style: "currency",+ currency:+ routeData?.purchaseOrder?.currencyCode ??+ company.baseCurrencyCode+ }}+ onChange={(value) =>+ setItemData((d) => ({...d,- description: e.target.value+ supplierShippingCost: value}))}/>- </FormControl>- <CostCenter- name="costCenterId"- label={t`Cost Center`}- isOptional- />- <DatePicker- name="requiredDate"- label={t`Required Date`}- value={indirectData.requiredDate ?? undefined}- onChange={(date) => {- setIndirectData((d) => ({- ...d,- requiredDate: date- }));- }}- />- <NumberControlled- name="purchaseQuantity"- label={t`Quantity`}- value={indirectData.purchaseQuantity}- onChange={(value) =>- setIndirectData((d) => ({- ...d,- purchaseQuantity: value- }))- }- />- <NumberControlled- name="supplierUnitPrice"- label={t`Unit Price`}- value={indirectData.supplierUnitPrice}- formatOptions={{- style: "currency",- currency:- routeData?.purchaseOrder?.currencyCode ??- company.baseCurrencyCode- }}- onChange={(value) =>- setIndirectData((d) => ({- ...d,- supplierUnitPrice: value- }))- }- />- <NumberControlled- name="supplierShippingCost"- label={t`Shipping`}- minValue={0}- value={indirectData.supplierShippingCost}- formatOptions={{- style: "currency",- currency:- routeData?.purchaseOrder?.currencyCode ??- company.baseCurrencyCode- }}- onChange={(value) =>- setIndirectData((d) => ({- ...d,- supplierShippingCost: value- }))- }- />- <NumberControlled- name="supplierTaxAmount"- label={t`Tax`}- value={indirectData.supplierTaxAmount}- formatOptions={{- style: "currency",- currency:- routeData?.purchaseOrder?.currencyCode ??- company.baseCurrencyCode- }}- onChange={(value) => {- const subtotal =- indirectData.supplierUnitPrice *- indirectData.purchaseQuantity +- indirectData.supplierShippingCost;- setIndirectData((d) => ({- ...d,- supplierTaxAmount: value,- taxPercent: subtotal > 0 ? value / subtotal : 0- }));- }}- />- <NumberControlled- name="taxPercent"- label={t`Tax Percent`}- value={indirectData.taxPercent}- minValue={0}- maxValue={1}- step={0.0001}- formatOptions={{- style: "percent",- minimumFractionDigits: 0,- maximumFractionDigits: 2- }}- onChange={(value) => {- const subtotal =- indirectData.supplierUnitPrice *- indirectData.purchaseQuantity +- indirectData.supplierShippingCost;- setIndirectData((d) => ({- ...d,- taxPercent: value,- supplierTaxAmount: subtotal * value- }));- }}- />- <CustomFormFields table="purchaseOrderLine" />+ <NumberControlled+ name="supplierTaxAmount"+ label={t`Tax Amount`}+ value={itemData.supplierTaxAmount}+ formatOptions={{+ style: "currency",+ currency:+ routeData?.purchaseOrder?.currencyCode ??+ company.baseCurrencyCode+ }}+ onChange={(value) => {+ const subtotal =+ itemData.supplierUnitPrice *+ itemData.purchaseQuantity ++ itemData.supplierShippingCost;+ setItemData((d) => ({+ ...d,+ supplierTaxAmount: value,+ taxPercent: subtotal > 0 ? value / subtotal : 0+ }));+ }}+ />+ <NumberControlled+ name="taxPercent"+ label={t`Tax Percent`}+ value={itemData.taxPercent}+ minValue={0}+ maxValue={1}+ step={0.0001}+ formatOptions={{+ style: "percent",+ minimumFractionDigits: 0,+ maximumFractionDigits: 2+ }}+ onChange={(value) => {+ const subtotal =+ itemData.supplierUnitPrice *+ itemData.purchaseQuantity ++ itemData.supplierShippingCost;+ setItemData((d) => ({+ ...d,+ taxPercent: value,+ supplierTaxAmount: subtotal * value+ }));+ }}+ />+ </div></div></VStack></TabsContent>++ {(activeTab === "gl-account" || activeTab === "asset") && (+ <>+ <Hidden+ name="purchaseOrderLineType"+ value={+ activeTab === "asset" ? "Fixed Asset" : "G/L Account"+ }+ />+ <Hidden+ name="description"+ value={indirectData.description}+ />+ <VStack>+ <div className="grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3">+ {activeTab === "gl-account" ? (+ <>+ <Account+ name="accountId"+ label={t`GL Account`}+ classes={["Expense"]}+ isOptional={false}+ />+ <CostCenter+ name="costCenterId"+ label={t`Cost Center`}+ isOptional+ />+ </>+ ) : (+ <>+ <Combobox+ name="assetId"+ label={t`Fixed Asset`}+ isOptional={false}+ options={assetOptions}+ value={indirectData.assetId}+ onChange={(selected) => {+ setIndirectData((d) => ({+ ...d,+ assetId: (selected?.value as string) ?? ""+ }));+ const asset = assetOptions.find(+ (o) => o.value === selected?.value+ );+ if (asset?.locationId && !locationId) {+ setLocationId(asset.locationId);+ }+ }}+ />+ <Location+ name="locationId"+ label={t`Location`}+ value={locationId}+ onChange={(newLocation) => {+ setLocationId(newLocation?.value ?? "");+ }}+ />+ </>+ )}+ <FormControl+ className={+ activeTab === "asset"+ ? "col-span-1"+ : "col-span-3"+ }+ >+ <FormLabel>+ <Trans>Description</Trans>+ </FormLabel>+ <Input+ value={indirectData.description}+ onChange={(e) =>+ setIndirectData((d) => ({+ ...d,+ description: e.target.value+ }))+ }+ />+ </FormControl>+ <DatePicker+ name="requiredDate"+ label={t`Required Date`}+ value={indirectData.requiredDate ?? undefined}+ onChange={(date) => {+ setIndirectData((d) => ({+ ...d,+ requiredDate: date+ }));+ }}+ />+ <NumberControlled+ name="purchaseQuantity"+ label={t`Quantity`}+ isOptional={false}+ isDisabled={activeTab === "asset"}+ value={+ activeTab === "asset"+ ? 1+ : indirectData.purchaseQuantity+ }+ onChange={(value) =>+ setIndirectData((d) => ({+ ...d,+ purchaseQuantity: value+ }))+ }+ />+ <NumberControlled+ name="supplierUnitPrice"+ label={t`Unit Price`}+ isOptional={false}+ value={indirectData.supplierUnitPrice}+ formatOptions={{+ style: "currency",+ currency:+ routeData?.purchaseOrder?.currencyCode ??+ company.baseCurrencyCode+ }}+ onChange={(value) =>+ setIndirectData((d) => ({+ ...d,+ supplierUnitPrice: value+ }))+ }+ />+ <CustomFormFields table="purchaseOrderLine" />+ </div>++ <div className="h-4" />++ <div className="w-full border border-border rounded-md shadow-sm p-4 flex flex-col gap-4">+ <HStack+ className="w-full justify-between cursor-pointer"+ onClick={indirectCostsDisclosure.onToggle}+ >+ <Label>+ <Trans>Tax & Shipping</Trans>+ </Label>+ <HStack>+ {indirectData.taxPercent > 0 && (+ <Badge variant="red">+ {percentFormatter.format(+ indirectData.taxPercent+ )}{" "}+ <Trans>Tax</Trans>+ </Badge>+ )}+ {indirectData.supplierShippingCost > 0 && (+ <Badge variant="secondary">+ {currencyFormatter.format(+ indirectData.supplierShippingCost+ )}+ </Badge>+ )}+ <IconButton+ icon={<LuChevronRight />}+ aria-label={+ indirectCostsDisclosure.isOpen+ ? t`Collapse Costs`+ : t`Expand Costs`+ }+ variant="ghost"+ size="md"+ onClick={(e) => {+ e.stopPropagation();+ indirectCostsDisclosure.onToggle();+ }}+ className={`transition-transform ${indirectCostsDisclosure.isOpen ? "rotate-90" : ""}`}+ />+ </HStack>+ </HStack>+ <div+ className={`grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3 pb-4 ${+ indirectCostsDisclosure.isOpen ? "" : "hidden"+ }`}+ >+ <NumberControlled+ name="supplierShippingCost"+ label={t`Shipping`}+ minValue={0}+ value={indirectData.supplierShippingCost}+ formatOptions={{+ style: "currency",+ currency:+ routeData?.purchaseOrder?.currencyCode ??+ company.baseCurrencyCode+ }}+ onChange={(value) =>+ setIndirectData((d) => ({+ ...d,+ supplierShippingCost: value+ }))+ }+ />+ <NumberControlled+ name="supplierTaxAmount"+ label={t`Tax Amount`}+ value={indirectData.supplierTaxAmount}+ formatOptions={{+ style: "currency",+ currency:+ routeData?.purchaseOrder?.currencyCode ??+ company.baseCurrencyCode+ }}+ onChange={(value) => {+ const subtotal =+ indirectData.supplierUnitPrice *+ indirectData.purchaseQuantity ++ indirectData.supplierShippingCost;+ setIndirectData((d) => ({+ ...d,+ supplierTaxAmount: value,+ taxPercent:+ subtotal > 0 ? value / subtotal : 0+ }));+ }}+ />+ <NumberControlled+ name="taxPercent"+ label={t`Tax Percent`}+ value={indirectData.taxPercent}+ minValue={0}+ maxValue={1}+ step={0.0001}+ formatOptions={{+ style: "percent",+ minimumFractionDigits: 0,+ maximumFractionDigits: 2+ }}+ onChange={(value) => {+ const subtotal =+ indirectData.supplierUnitPrice *+ indirectData.purchaseQuantity ++ indirectData.supplierShippingCost;+ setIndirectData((d) => ({+ ...d,+ taxPercent: value,+ supplierTaxAmount: subtotal * value+ }));+ }}+ />+ </div>+ </div>+ </VStack>+ </>+ )}</ModalCardBody><ModalCardFooter>- <Submit isDisabled={isDisabled} withBlocker={false}>- <Trans>Save</Trans>- </Submit>+ <HStack className="justify-end gap-2">+ {onClose && (+ <Button variant="ghost" onClick={onClose}>+ <Trans>Cancel</Trans>+ </Button>+ )}+ <Submit isDisabled={isDisabled} withBlocker={false}>+ <Trans>Save</Trans>+ </Submit>+ </HStack></ModalCardFooter></ValidatedForm></ModalCardContent>diff --git a/apps/erp/app/modules/purchasing/ui/PurchaseOrder/PurchaseOrderSummary.tsx b/apps/erp/app/modules/purchasing/ui/PurchaseOrder/PurchaseOrderSummary.tsxindex b8fac91441..26e3e6798e 100644--- a/apps/erp/app/modules/purchasing/ui/PurchaseOrder/PurchaseOrderSummary.tsx+++ b/apps/erp/app/modules/purchasing/ui/PurchaseOrder/PurchaseOrderSummary.tsx@@ -77,9 +77,13 @@ const LineItems = ({if (!line.id) return null;const isGlAccount = line.purchaseOrderLineType === "G/L Account";+ const isFixedAsset = line.purchaseOrderLineType === "Fixed Asset";+ const isIndirect = isGlAccount || isFixedAsset;const itemReadableId = isGlAccount? line.description || "Indirect Expense"- : getItemReadableId(items, line.itemId);+ : isFixedAsset+ ? line.assetReadableId || "Fixed Asset"+ : getItemReadableId(items, line.itemId);const lineTotal = (line.unitPrice ?? 0) * (line.purchaseQuantity ?? 0);const supplierLineTotal =(line.supplierUnitPrice ?? 0) * (line.purchaseQuantity ?? 0);@@ -143,7 +147,9 @@ const LineItems = ({{isGlAccount? (accounts.find((a) => a.id === line.accountId)?.name ?? "Indirect Expense")- : line.description}+ : isFixedAsset+ ? line.description || "Fixed Asset"+ : line.description}</span></VStack><VStack@@ -173,7 +179,7 @@ const LineItems = ({</motion.div></HStack><div className="flex items-center gap-2">- {!isGlAccount && (+ {!isIndirect && (<Badgevariant="outline"className="flex items-center gap-2"diff --git a/apps/erp/app/modules/resources/resources.models.ts b/apps/erp/app/modules/resources/resources.models.tsindex 1c15a54eb8..c9d1c66a25 100644--- a/apps/erp/app/modules/resources/resources.models.ts+++ b/apps/erp/app/modules/resources/resources.models.ts@@ -485,6 +485,7 @@ export const workCenterValidator = z.object({defaultStandardFactor: z.enum(standardFactorType, {errorMap: () => ({ message: "Standard factor is required" })}),+ departmentId: zfd.text(z.string().optional()),laborRate: zfd.numeric(z.number().min(0)),locationId: z.string().min(1, { message: "Location is required" }),machineRate: zfd.numeric(z.number().min(0)),diff --git a/apps/erp/app/modules/resources/ui/WorkCenters/WorkCenterForm.tsx b/apps/erp/app/modules/resources/ui/WorkCenters/WorkCenterForm.tsxindex df7a2aed94..d959247470 100644--- a/apps/erp/app/modules/resources/ui/WorkCenters/WorkCenterForm.tsx+++ b/apps/erp/app/modules/resources/ui/WorkCenters/WorkCenterForm.tsx@@ -20,6 +20,7 @@ import type { z } from "zod";import {// Ability,CustomFormFields,+ Department,Hidden,Input,Location,@@ -113,6 +114,7 @@ const WorkCenterForm = ({)}<TextArea name="description" label={t`Description`} /><Location name="locationId" label={t`Location`} />+ <Department name="departmentId" label={t`Department`} /><Numbername="laborRate"diff --git a/apps/erp/app/modules/resources/ui/WorkCenters/WorkCentersTable.tsx b/apps/erp/app/modules/resources/ui/WorkCenters/WorkCentersTable.tsxindex 3b3efe715f..e65fb0fc97 100644--- a/apps/erp/app/modules/resources/ui/WorkCenters/WorkCentersTable.tsx+++ b/apps/erp/app/modules/resources/ui/WorkCenters/WorkCentersTable.tsx@@ -54,6 +54,7 @@ import { path } from "~/utils/path";type WorkCentersTableProps = {data: WorkCenter[];count: number;+ departments: ListItem[];locations: ListItem[];};@@ -66,7 +67,7 @@ const defaultColumnVisibility = {};const WorkCentersTable = memo(- ({ data, count, locations }: WorkCentersTableProps) => {+ ({ data, count, departments, locations }: WorkCentersTableProps) => {const { t } = useLingui();const navigate = useNavigate();const [params] = useUrlParams();@@ -172,6 +173,21 @@ const WorkCentersTable = memo(}}},+ {+ accessorKey: "departmentName",+ header: t`Department`,+ cell: (item) => <Enumerable value={item.getValue<string>()} />,+ meta: {+ icon: <LuBuilding2 />,+ filter: {+ type: "static",+ options: departments.map(({ name }) => ({+ value: name,+ label: <Enumerable value={name} />+ }))+ }+ }+ },{accessorKey: "active",header: t`Active`,diff --git a/apps/erp/app/modules/sales/sales.models.ts b/apps/erp/app/modules/sales/sales.models.tsindex 6b7538b53a..3e881dbd91 100644--- a/apps/erp/app/modules/sales/sales.models.ts+++ b/apps/erp/app/modules/sales/sales.models.ts@@ -821,8 +821,11 @@ export const salesOrderLineValidator = z).refine((data) => {- // If sales order line type is not "Comment", we require a method type- if (data.salesOrderLineType !== "Comment" && !data.methodType) {+ if (+ data.salesOrderLineType !== "Comment" &&+ data.salesOrderLineType !== "Fixed Asset" &&+ !data.methodType+ ) {return false;}return true;@@ -831,6 +834,16 @@ export const salesOrderLineValidator = zmessage: "Method type is required",path: ["methodType"]}+ )+ .refine(+ (data) =>+ data.salesOrderLineType === "Fixed Asset"+ ? (data.saleQuantity ?? 1) === 1+ : true,+ {+ message: "Fixed Asset quantity must be 1",+ path: ["saleQuantity"]+ });export const salesOrderPaymentValidator = z.object({diff --git a/apps/erp/app/modules/sales/ui/SalesOrder/SalesOrderExplorer.tsx b/apps/erp/app/modules/sales/ui/SalesOrder/SalesOrderExplorer.tsxindex 5cfeacfe6a..a185a8639e 100644--- a/apps/erp/app/modules/sales/ui/SalesOrder/SalesOrderExplorer.tsx+++ b/apps/erp/app/modules/sales/ui/SalesOrder/SalesOrderExplorer.tsx@@ -380,10 +380,14 @@ function SalesOrderLineItem({<VStack spacing={0} className="min-w-0"><span className="font-semibold line-clamp-1">- {getItemReadableId(items, line.itemId)}+ {line.salesOrderLineType === "Fixed Asset"+ ? (line as any).assetReadableId || "Fixed Asset"+ : getItemReadableId(items, line.itemId)}</span><span className="text-muted-foreground text-xs truncate line-clamp-1">- {line.description}+ {line.salesOrderLineType === "Fixed Asset"+ ? (line as any).assetName || line.description+ : line.description}</span></VStack></HStack>diff --git a/apps/erp/app/modules/sales/ui/SalesOrder/SalesOrderLineForm.tsx b/apps/erp/app/modules/sales/ui/SalesOrder/SalesOrderLineForm.tsxindex 548b311d10..3f3ebbf518 100644--- a/apps/erp/app/modules/sales/ui/SalesOrder/SalesOrderLineForm.tsx+++ b/apps/erp/app/modules/sales/ui/SalesOrder/SalesOrderLineForm.tsx@@ -1,6 +1,6 @@import { useCarbon } from "@carbon/auth";-import { ValidatedForm } from "@carbon/form";+import { Combobox, ValidatedForm } from "@carbon/form";import {Badge,CardAction,@@ -10,8 +10,11 @@ import {DropdownMenuIcon,DropdownMenuItem,DropdownMenuTrigger,+ FormControl,+ FormLabel,HStack,IconButton,+ Input,Label,ModalCard,ModalCardBody,@@ -21,15 +24,27 @@ import {ModalCardHeader,ModalCardProvider,ModalCardTitle,+ Tabs,+ TabsContent,+ TabsList,+ TabsTrigger,useDebounce,useDisclosure,+ useMount,VStack} from "@carbon/react";import { getItemReadableId } from "@carbon/utils";import { Trans, useLingui } from "@lingui/react/macro";import { useCallback, useEffect, useState } from "react";import { BsThreeDotsVertical } from "react-icons/bs";-import { LuChevronRight, LuPlus, LuTrash, LuTruck } from "react-icons/lu";+import {+ LuBox,+ LuChevronRight,+ LuLandmark,+ LuPlus,+ LuTrash,+ LuTruck+} from "react-icons/lu";import { useParams } from "react-router";import type { z } from "zod";import { MethodIcon } from "~/components";@@ -71,7 +86,10 @@ import { PriceTracePopover } from "../Pricing/PriceTracePopover";import DeleteSalesOrderLine from "./DeleteSalesOrderLine";type SalesOrderLineFormProps = {- initialValues: z.infer<typeof salesOrderLineValidator>;+ initialValues: z.infer<typeof salesOrderLineValidator> & {+ assetReadableId?: string;+ assetName?: string;+ };type?: "card" | "modal";onClose?: () => void;};@@ -132,6 +150,66 @@ const SalesOrderLineForm = ({});const isEditing = initialValues.id !== undefined;+ const isFixedAsset = initialValues.salesOrderLineType === "Fixed Asset";+ const [activeTab, setActiveTab] = useState<"item" | "asset">(+ isFixedAsset ? "asset" : "item"+ );++ const [assetOptions, setAssetOptions] = useState<+ { value: string; label: string }[]+ >([]);+ const [assetData, setAssetData] = useState<{+ assetId: string;+ description: string;+ saleQuantity: number;+ unitPrice: number;+ taxPercent: number;+ shippingCost: number;+ addOnCost: number;+ nonTaxableAddOnCost: number;+ }>({+ assetId: initialValues.assetId ?? "",+ description: initialValues.description ?? "",+ saleQuantity: initialValues.saleQuantity ?? 1,+ unitPrice: initialValues.unitPrice ?? 0,+ taxPercent: initialValues.taxPercent ?? 0,+ shippingCost: initialValues.shippingCost ?? 0,+ addOnCost: initialValues.addOnCost ?? 0,+ nonTaxableAddOnCost: initialValues.nonTaxableAddOnCost ?? 0+ });++ useMount(() => {+ if (!carbon || !company.id) return;+ (async () => {+ const assets = await carbon+ .from("fixedAsset")+ .select("id, fixedAssetId, name")+ .eq("companyId", company.id)+ .in("status", ["Active", "Fully Depreciated"])+ .order("fixedAssetId");+ const options = (assets.data ?? []).map((a) => ({+ value: a.id,+ label: `${a.fixedAssetId} — ${a.name}`+ }));+ if (+ initialValues.assetId &&+ !options.some((o) => o.value === initialValues.assetId)+ ) {+ const current = await carbon+ .from("fixedAsset")+ .select("id, fixedAssetId, name")+ .eq("id", initialValues.assetId)+ .single();+ if (current.data) {+ options.unshift({+ value: current.data.id,+ label: `${current.data.fixedAssetId} — ${current.data.name}`+ });+ }+ }+ setAssetOptions(options);+ })();+ });const pricingRuleId = (initialValues as { priceListId?: string | null }).priceListId;@@ -300,397 +378,633 @@ const SalesOrderLineForm = ({};const costsDisclosure = useDisclosure();+ const assetCostsDisclosure = useDisclosure();const deleteDisclosure = useDisclosure();const [items] = useItems();return (<>- <ModalCardProvider type={type}>- <ModalCard- onClose={onClose}- isCollapsible={isEditing}- defaultCollapsed={false}- >- <ModalCardContent size="xxlarge">- <ValidatedForm- defaultValues={initialValues}- validator={salesOrderLineValidator}- method="post"- action={- isEditing- ? path.to.salesOrderLine(orderId, initialValues.id!)- : path.to.newSalesOrderLine(orderId)- }- className="w-full"- isDisabled={isEditing && isLocked}- onSubmit={() => {- if (type === "modal") onClose?.();- }}- >- <HStack className="w-full justify-between items-start">- <ModalCardHeader>- <ModalCardTitle- className={cn(- isEditing && !itemData?.itemId && "text-muted-foreground"- )}- >- {isEditing- ? getItemReadableId(items, itemData?.itemId) || "..."- : t`New Sales Order Line`}- </ModalCardTitle>- <ModalCardDescription>- {isEditing ? (- <div className="flex flex-col items-start gap-1">- <span>{itemData?.description}</span>- <div className="flex items-center gap-2">- <Badge- variant="outline"- className="flex items-center gap-2"- >- {initialValues?.saleQuantity}- <MethodIcon type={itemData.methodType} />- </Badge>- <Badge variant="green">- {currencyFormatter.format(- initialValues?.unitPrice ?? 0- )}{" "}- {initialValues?.unitOfMeasureCode}- </Badge>- {initialValues?.taxPercent > 0 ? (- <Badge variant="red">- {percentFormatter.format(- initialValues?.taxPercent+ <Tabs+ value={activeTab}+ onValueChange={(v) => setActiveTab(v as "item" | "asset")}+ className="w-full"+ >+ <ModalCardProvider type={type}>+ <ModalCard+ onClose={onClose}+ isCollapsible={isEditing}+ defaultCollapsed={false}+ >+ <ModalCardContent size="xxlarge">+ <ValidatedForm+ defaultValues={initialValues}+ validator={salesOrderLineValidator}+ method="post"+ action={+ isEditing+ ? path.to.salesOrderLine(orderId, initialValues.id!)+ : path.to.newSalesOrderLine(orderId)+ }+ className="w-full"+ isDisabled={isEditing && isLocked}+ onSubmit={() => {+ if (type === "modal") onClose?.();+ }}+ >+ <HStack+ className={cn(+ "w-full justify-between items-start",+ type === "modal" && "pr-16"+ )}+ >+ <ModalCardHeader className="flex flex-1">+ <ModalCardTitle+ className={cn(+ isEditing &&+ !isFixedAsset &&+ !itemData?.itemId &&+ "text-muted-foreground"+ )}+ >+ {isEditing+ ? isFixedAsset+ ? initialValues.assetReadableId || "Fixed Asset"+ : getItemReadableId(items, itemData?.itemId) || "..."+ : t`New Sales Order Line`}+ </ModalCardTitle>+ <ModalCardDescription>+ {isEditing ? (+ <div className="flex flex-col items-start gap-1">+ <span>+ {isFixedAsset+ ? initialValues.assetName || assetData.description+ : itemData?.description}+ </span>+ <div className="flex items-center gap-2">+ <Badge+ variant="outline"+ className="flex items-center gap-2"+ >+ {initialValues?.saleQuantity}+ {!isFixedAsset && (+ <MethodIcon type={itemData.methodType} />+ )}+ </Badge>+ <Badge variant="green">+ {currencyFormatter.format(+ initialValues?.unitPrice ?? 0)}{" "}- <Trans>Tax</Trans>+ {initialValues?.unitOfMeasureCode}</Badge>- ) : null}+ {initialValues?.taxPercent > 0 ? (+ <Badge variant="red">+ {percentFormatter.format(+ initialValues?.taxPercent+ )}{" "}+ <Trans>Tax</Trans>+ </Badge>+ ) : null}+ </div></div>- </div>- ) : (- <Trans>- A sales order line contains order details for a- particular item- </Trans>+ ) : (+ <Trans>+ A sales order line contains order details for a+ particular item+ </Trans>+ )}+ </ModalCardDescription>+ </ModalCardHeader>+ <div className="flex-shrink-0 flex items-center gap-2">+ {!isEditing && (+ <TabsList>+ <TabsTrigger value="item">+ <LuBox className="mr-1" />+ <Trans>Item</Trans>+ </TabsTrigger>+ <TabsTrigger value="asset">+ <LuLandmark className="mr-1" />+ <Trans>Asset</Trans>+ </TabsTrigger>+ </TabsList>)}- </ModalCardDescription>- </ModalCardHeader>- {isEditing &&- permissions.can("update", "sales") &&- !isLocked && (- <CardAction className="pr-12">- <DropdownMenu>- <DropdownMenuTrigger asChild>- <IconButton- icon={<BsThreeDotsVertical />}- aria-label={t`More`}- variant="ghost"- />- </DropdownMenuTrigger>- <DropdownMenuContent align="end">- <DropdownMenuItem- destructive- onClick={deleteDisclosure.onOpen}- >- <DropdownMenuIcon icon={<LuTrash />} />- <Trans>Delete Line</Trans>- </DropdownMenuItem>- </DropdownMenuContent>- </DropdownMenu>- </CardAction>- )}- </HStack>- <ModalCardBody>- <Hidden name="id" />- <Hidden name="salesOrderId" />-- {!isEditing && (- <Hidden- name="description"- value={itemData?.description ?? ""}- />- )}- <Hidden- name="modelUploadId"- value={itemData?.modelUploadId ?? undefined}- />- <Hidden- name="priceListId"- value={itemData?.priceListId ?? undefined}- />- <Hidden- name="priceTrace"- value={- itemData?.priceTrace- ? JSON.stringify(itemData.priceTrace)- : undefined- }- />- <Hidden name="unitOfMeasureCode" value={itemData.uom} />- <VStack>- <div className="grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3">- <Item- name="itemId"- label={lineType}- type={lineType as "Part"}- typeFieldName="salesOrderLineType"- value={itemData.itemId}- locationId={locationId}- onChange={(value) => {- onChange(value?.value as string);- }}- onTypeChange={onTypeChange}- />-- {isEditing && (- <InputControlled+ {isEditing &&+ permissions.can("update", "sales") &&+ !isLocked && (+ <CardAction>+ <DropdownMenu>+ <DropdownMenuTrigger asChild>+ <IconButton+ icon={<BsThreeDotsVertical />}+ aria-label={t`More`}+ variant="ghost"+ />+ </DropdownMenuTrigger>+ <DropdownMenuContent align="end">+ <DropdownMenuItem+ destructive+ onClick={deleteDisclosure.onOpen}+ >+ <DropdownMenuIcon icon={<LuTrash />} />+ <Trans>Delete Line</Trans>+ </DropdownMenuItem>+ </DropdownMenuContent>+ </DropdownMenu>+ </CardAction>+ )}+ </div>+ </HStack>+ <ModalCardBody>+ <Hidden name="id" />+ <Hidden name="salesOrderId" />++ <TabsContent value="item">+ {!isEditing && (+ <Hiddenname="description"- label={t`Short Description`}- onChange={(value) => {- setItemData((d) => ({- ...d,- description: value- }));- }}- value={itemData.description}+ value={itemData?.description ?? ""}/>)}+ <Hidden+ name="modelUploadId"+ value={itemData?.modelUploadId ?? undefined}+ />+ <Hidden+ name="priceListId"+ value={itemData?.priceListId ?? undefined}+ />+ <Hidden+ name="priceTrace"+ value={+ itemData?.priceTrace+ ? JSON.stringify(itemData.priceTrace)+ : undefined+ }+ />+ <Hidden name="unitOfMeasureCode" value={itemData.uom} />+ <VStack>+ <div className="grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3">+ <Item+ name="itemId"+ label={lineType}+ type={lineType as "Part"}+ typeFieldName="salesOrderLineType"+ value={itemData.itemId}+ locationId={locationId}+ onChange={(value) => {+ onChange(value?.value as string);+ }}+ onTypeChange={onTypeChange}+ />- {lineType !== "Comment" && (- <>- <SelectControlled- name="methodType"- label={t`Method`}- options={- methodType.map((m) => ({- label: (- <span className="flex items-center gap-2">- <MethodIcon type={m} />- {m}- </span>- ),- value: m- })) ?? []- }- value={itemData.methodType}- onChange={(newValue) => {- if (newValue)+ {isEditing && (+ <InputControlled+ name="description"+ label={t`Short Description`}+ onChange={(value) => {setItemData((d) => ({...d,- methodType: newValue?.value+ description: value}));- }}- />- <NumberControlled- name="saleQuantity"- label={t`Quantity`}- value={saleQuantity}- onChange={onQuantityChange}- />- <div className="flex flex-col gap-y-2 w-full">- <div className="flex items-center justify-between min-h-[16px]">- <span className="text-xs font-medium text-muted-foreground">- Unit Price- </span>- <PriceTracePopover- trace={itemData.priceTrace}- currencyCode={baseCurrency}+ }}+ value={itemData.description}+ />+ )}++ {lineType !== "Comment" && (+ <>+ <SelectControlled+ name="methodType"+ label={t`Method`}+ options={+ methodType.map((m) => ({+ label: (+ <span className="flex items-center gap-2">+ <MethodIcon type={m} />+ {m}+ </span>+ ),+ value: m+ })) ?? []+ }+ value={itemData.methodType}+ onChange={(newValue) => {+ if (newValue)+ setItemData((d) => ({+ ...d,+ methodType: newValue?.value+ }));+ }}/>+ <NumberControlled+ name="saleQuantity"+ label={t`Quantity`}+ value={saleQuantity}+ onChange={onQuantityChange}+ />+ <div className="flex flex-col gap-y-2 w-full">+ <div className="flex items-center justify-between min-h-[16px]">+ <span className="text-xs font-medium text-muted-foreground">+ Unit Price+ </span>+ <PriceTracePopover+ trace={itemData.priceTrace}+ currencyCode={baseCurrency}+ />+ </div>+ <NumberControlled+ name="unitPrice"+ value={itemData.unitPrice}+ formatOptions={{+ style: "currency",+ currency: baseCurrency+ }}+ onChange={(value) =>+ setItemData((d) => ({+ ...d,+ unitPrice: value+ }))+ }+ />+ </div>+ <DatePicker+ name="promisedDate"+ label={t`Promised Date`}+ />+ {[+ "Part",+ "Material",+ "Service",+ "Tool",+ "Consumable"+ ].includes(lineType) && (+ <Location+ name="locationId"+ label={t`Shipping Location`}+ onChange={onLocationChange}+ />+ )}+ {[+ "Part",+ "Material",+ "Tool",+ "Fixture",+ "Consumable"+ ].includes(lineType) && (+ <StorageUnit+ name="storageUnitId"+ label={t`Storage Unit`}+ locationId={locationId}+ itemId={itemData.itemId}+ value={itemData.storageUnitId ?? undefined}+ onChange={(newValue) => {+ if (newValue) {+ setItemData((d) => ({+ ...d,+ storageUnitId: newValue?.id+ }));+ }+ }}+ />+ )}+ </>+ )}+ <CustomFormFields table="salesOrderLine" />+ </div>++ {lineType !== "Comment" && (+ <div className="w-full">+ <div className="w-full border border-border rounded-md shadow-sm p-4 flex flex-col gap-4 mt-4">+ <HStack+ className="w-full justify-between cursor-pointer"+ onClick={costsDisclosure.onToggle}+ >+ <Label>+ <Trans>Tax & Additional Costs</Trans>+ </Label>+ <HStack>+ {(initialValues?.taxPercent ?? 0) > 0 && (+ <Badge variant="red">+ {percentFormatter.format(+ initialValues?.taxPercent ?? 0+ )}{" "}+ <Trans>Tax</Trans>+ </Badge>+ )}+ {(initialValues?.shippingCost ?? 0) > 0 && (+ <Badge+ variant="secondary"+ className="flex items-center gap-1"+ >+ <LuTruck />+ <span>+ {currencyFormatter.format(+ initialValues?.shippingCost ?? 0+ )}+ </span>+ </Badge>+ )}+ {(initialValues?.addOnCost ?? 0) > 0 ||+ ((initialValues?.nonTaxableAddOnCost ?? 0) >+ 0 && (+ <Badge+ variant="secondary"+ className="flex items-center gap-1"+ >+ <LuPlus />+ <span>+ {currencyFormatter.format(+ (initialValues?.addOnCost ?? 0) ++ (initialValues?.nonTaxableAddOnCost ??+ 0)+ )}{" "}+ <Trans>Add-On</Trans>+ </span>+ </Badge>+ ))}++ <IconButton+ icon={<LuChevronRight />}+ aria-label={+ costsDisclosure.isOpen+ ? t`Collapse Costs`+ : t`Expand Costs`+ }+ variant="ghost"+ size="md"+ onClick={(e) => {+ e.stopPropagation();+ costsDisclosure.onToggle();+ }}+ className={`transition-transform ${+ costsDisclosure.isOpen ? "rotate-90" : ""+ }`}+ />+ </HStack>+ </HStack>+ <div+ className={`grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3 pb-4 ${+ costsDisclosure.isOpen ? "" : "hidden"+ }`}+ >+ <Number+ name="taxPercent"+ label={t`Tax Percent`}+ minValue={0}+ maxValue={1}+ step={0.0001}+ formatOptions={{+ style: "percent",+ minimumFractionDigits: 0,+ maximumFractionDigits: 2+ }}+ />+ <Number+ name="shippingCost"+ label={t`Shipping Cost`}+ minValue={0}+ formatOptions={{+ style: "currency",+ currency: baseCurrency+ }}+ />+ <Number+ name="addOnCost"+ label={t`Add-On Cost`}+ formatOptions={{+ style: "currency",+ currency: baseCurrency+ }}+ />+ <Number+ name="nonTaxableAddOnCost"+ label={t`Non-Taxable Add-On Cost`}+ formatOptions={{+ style: "currency",+ currency: baseCurrency+ }}+ />+ </div></div>+ </div>+ )}+ </VStack>+ </TabsContent>++ {activeTab === "asset" && (+ <>+ <Hidden name="salesOrderLineType" value="Fixed Asset" />+ <Hidden+ name="description"+ value={assetData.description}+ />+ <VStack>+ <div className="grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3">+ <Combobox+ name="assetId"+ label={t`Fixed Asset`}+ isOptional={false}+ options={assetOptions}+ value={assetData.assetId}+ onChange={(selected) => {+ setAssetData((d) => ({+ ...d,+ assetId: (selected?.value as string) ?? ""+ }));+ }}+ />+ <Location+ name="locationId"+ label={t`Shipping Location`}+ onChange={onLocationChange}+ />+ <FormControl>+ <FormLabel>+ <Trans>Description</Trans>+ </FormLabel>+ <Input+ value={assetData.description}+ onChange={(e) =>+ setAssetData((d) => ({+ ...d,+ description: e.target.value+ }))+ }+ />+ </FormControl>+ <DatePicker+ name="promisedDate"+ label={t`Promised Date`}+ />+ <NumberControlled+ name="saleQuantity"+ label={t`Quantity`}+ isOptional={false}+ isDisabled+ value={1}+ onChange={() => undefined}+ /><NumberControlledname="unitPrice"- value={itemData.unitPrice}+ label={t`Unit Price`}+ isOptional={false}+ value={assetData.unitPrice}formatOptions={{style: "currency",currency: baseCurrency}}onChange={(value) =>- setItemData((d) => ({+ setAssetData((d) => ({...d,unitPrice: value}))}/>+ <CustomFormFields table="salesOrderLine" /></div>- <DatePicker- name="promisedDate"- label={t`Promised Date`}- />- {[- "Part",- "Material",- "Service",- "Tool",- "Consumable"- ].includes(lineType) && (- <Location- name="locationId"- label={t`Shipping Location`}- onChange={onLocationChange}- />- )}- {[- "Part",- "Material",- "Tool",- "Fixture",- "Consumable"- ].includes(lineType) && (- <StorageUnit- name="storageUnitId"- label={t`Storage Unit`}- locationId={locationId}- itemId={itemData.itemId}- value={itemData.storageUnitId ?? undefined}- onChange={(newValue) => {- if (newValue) {- setItemData((d) => ({- ...d,- storageUnitId: newValue?.id- }));- }- }}- />- )}- </>- )}- <CustomFormFields table="salesOrderLine" />- </div>- {lineType !== "Comment" && (- <div className="w-full">- <div className="w-full border border-border rounded-md shadow-sm p-4 flex flex-col gap-4 mt-4">- <HStack- className="w-full justify-between cursor-pointer"- onClick={costsDisclosure.onToggle}- >- <Label>- <Trans>Tax & Additional Costs</Trans>- </Label>- <HStack>- {(initialValues?.taxPercent ?? 0) > 0 && (- <Badge variant="red">- {percentFormatter.format(- initialValues?.taxPercent ?? 0- )}{" "}- <Trans>Tax</Trans>- </Badge>- )}- {(initialValues?.shippingCost ?? 0) > 0 && (- <Badge- variant="secondary"- className="flex items-center gap-1"- >- <LuTruck />- <span>- {currencyFormatter.format(- initialValues?.shippingCost ?? 0- )}- </span>- </Badge>- )}- {(initialValues?.addOnCost ?? 0) > 0 ||- ((initialValues?.nonTaxableAddOnCost ?? 0) >- 0 && (+ <div className="h-4" />++ <div className="w-full border border-border rounded-md shadow-sm p-4 flex flex-col gap-4">+ <HStack+ className="w-full justify-between cursor-pointer"+ onClick={assetCostsDisclosure.onToggle}+ >+ <Label>+ <Trans>Tax & Additional Costs</Trans>+ </Label>+ <HStack>+ {assetData.taxPercent > 0 && (+ <Badge variant="red">+ {percentFormatter.format(+ assetData.taxPercent+ )}{" "}+ <Trans>Tax</Trans>+ </Badge>+ )}+ {assetData.shippingCost > 0 && (<Badgevariant="secondary"className="flex items-center gap-1">- <LuPlus />+ <LuTruck /><span>{currencyFormatter.format(- (initialValues?.addOnCost ?? 0) +- (initialValues?.nonTaxableAddOnCost ??- 0)- )}{" "}- <Trans>Add-On</Trans>+ assetData.shippingCost+ )}</span></Badge>- ))}-- <IconButton- icon={<LuChevronRight />}- aria-label={- costsDisclosure.isOpen- ? t`Collapse Costs`- : t`Expand Costs`+ )}+ <IconButton+ icon={<LuChevronRight />}+ aria-label={+ assetCostsDisclosure.isOpen+ ? t`Collapse Costs`+ : t`Expand Costs`+ }+ variant="ghost"+ size="md"+ onClick={(e) => {+ e.stopPropagation();+ assetCostsDisclosure.onToggle();+ }}+ className={`transition-transform ${assetCostsDisclosure.isOpen ? "rotate-90" : ""}`}+ />+ </HStack>+ </HStack>+ <div+ className={`grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3 pb-4 ${+ assetCostsDisclosure.isOpen ? "" : "hidden"+ }`}+ >+ <NumberControlled+ name="taxPercent"+ label={t`Tax Percent`}+ value={assetData.taxPercent}+ minValue={0}+ maxValue={1}+ step={0.0001}+ formatOptions={{+ style: "percent",+ minimumFractionDigits: 0,+ maximumFractionDigits: 2+ }}+ onChange={(value) =>+ setAssetData((d) => ({+ ...d,+ taxPercent: value+ }))}- variant="ghost"- size="md"- onClick={(e) => {- e.stopPropagation();- costsDisclosure.onToggle();+ />+ <NumberControlled+ name="shippingCost"+ label={t`Shipping Cost`}+ value={assetData.shippingCost}+ minValue={0}+ formatOptions={{+ style: "currency",+ currency: baseCurrency}}- className={`transition-transform ${- costsDisclosure.isOpen ? "rotate-90" : ""- }`}+ onChange={(value) =>+ setAssetData((d) => ({+ ...d,+ shippingCost: value+ }))+ }/>- </HStack>- </HStack>- <div- className={`grid w-full gap-x-8 gap-y-4 grid-cols-1 lg:grid-cols-3 pb-4 ${- costsDisclosure.isOpen ? "" : "hidden"- }`}- >- <Number- name="taxPercent"- label={t`Tax Percent`}- minValue={0}- maxValue={1}- step={0.0001}- formatOptions={{- style: "percent",- minimumFractionDigits: 0,- maximumFractionDigits: 2- }}- />- <Number- name="shippingCost"- label={t`Shipping Cost`}- minValue={0}- formatOptions={{- style: "currency",- currency: baseCurrency- }}- />- <Number- name="addOnCost"- label={t`Add-On Cost`}- formatOptions={{- style: "currency",- currency: baseCurrency- }}- />- <Number- name="nonTaxableAddOnCost"- label={t`Non-Taxable Add-On Cost`}- formatOptions={{- style: "currency",- currency: baseCurrency- }}- />+ <NumberControlled+ name="addOnCost"+ label={t`Add-On Cost`}+ value={assetData.addOnCost}+ formatOptions={{+ style: "currency",+ currency: baseCurrency+ }}+ onChange={(value) =>+ setAssetData((d) => ({+ ...d,+ addOnCost: value+ }))+ }+ />+ <NumberControlled+ name="nonTaxableAddOnCost"+ label={t`Non-Taxable Add-On Cost`}+ value={assetData.nonTaxableAddOnCost}+ formatOptions={{+ style: "currency",+ currency: baseCurrency+ }}+ onChange={(value) =>+ setAssetData((d) => ({+ ...d,+ nonTaxableAddOnCost: value+ }))+ }+ />+ </div></div>- </div>- </div>+ </VStack>+ </>)}- </VStack>- </ModalCardBody>- <ModalCardFooter>- <Submit- isDisabled={- isPriceResolving ||- !isEditable ||- (isEditing- ? !permissions.can("update", "sales")- : !permissions.can("create", "sales"))- }- >- <Trans>Save</Trans>- </Submit>- </ModalCardFooter>- </ValidatedForm>- </ModalCardContent>- </ModalCard>- </ModalCardProvider>+ </ModalCardBody>+ <ModalCardFooter>+ <Submit+ isDisabled={+ isPriceResolving ||+ !isEditable ||+ (isEditing+ ? !permissions.can("update", "sales")+ : !permissions.can("create", "sales"))+ }+ >+ <Trans>Save</Trans>+ </Submit>+ </ModalCardFooter>+ </ValidatedForm>+ </ModalCardContent>+ </ModalCard>+ </ModalCardProvider>+ </Tabs>{isEditing && deleteDisclosure.isOpen && (<DeleteSalesOrderLineline={initialValues as SalesOrderLine}diff --git a/apps/erp/app/modules/sales/ui/SalesOrder/SalesOrderSummary.tsx b/apps/erp/app/modules/sales/ui/SalesOrder/SalesOrderSummary.tsxindex 46d0f50a89..6c0011f64e 100644--- a/apps/erp/app/modules/sales/ui/SalesOrder/SalesOrderSummary.tsx+++ b/apps/erp/app/modules/sales/ui/SalesOrder/SalesOrderSummary.tsx@@ -409,7 +409,9 @@ function LineItems({className="flex min-w-0 flex-shrink-0"><Heading className="truncate">- {line.itemReadableId}+ {line.salesOrderLineType === "Fixed Asset"+ ? (line as any).assetReadableId || "Fixed Asset"+ : line.itemReadableId}</Heading><ButtonasChild@@ -462,9 +464,11 @@ function LineItems({className="flex items-center gap-2">{line.saleQuantity}- <MethodIcon- type={line.methodType ?? "Pull from Inventory"}- />+ {line.salesOrderLineType !== "Fixed Asset" && (+ <MethodIcon+ type={line.methodType ?? "Pull from Inventory"}+ />+ )}</Badge><Badge variant="green">{formatter.format(line.unitPrice ?? 0)}{" "}diff --git a/apps/erp/app/modules/settings/settings.service.ts b/apps/erp/app/modules/settings/settings.service.tsindex 7b5cf2f7df..e7fcf5ceeb 100644--- a/apps/erp/app/modules/settings/settings.service.ts+++ b/apps/erp/app/modules/settings/settings.service.ts@@ -627,6 +627,20 @@ export async function updateAccountingEnabledSetting(.eq("id", companyId);}+export async function updateAssetTaxDepreciationSettings(+ client: SupabaseClient<Database>,+ companyId: string,+ settings: {+ assetTaxDepreciationEnabled: boolean;+ assetTaxRate: number | null;+ }+) {+ return client+ .from("companySettings")+ .update(sanitize(settings))+ .eq("id", companyId);+}+export async function updateTimeCardSetting(client: SupabaseClient<Database>,companyId: string,diff --git a/apps/erp/app/modules/shared/imports.models.ts b/apps/erp/app/modules/shared/imports.models.tsindex 8fa979011b..7f26df4722 100644--- a/apps/erp/app/modules/shared/imports.models.ts+++ b/apps/erp/app/modules/shared/imports.models.ts@@ -938,6 +938,63 @@ export const fieldMappings = {default: "false"}}+ },+ fixedAsset: {+ name: {+ label: "Name",+ required: true,+ type: "string"+ },+ fixedAssetClassId: {+ label: "Asset Class ID",+ required: true,+ type: "string"+ },+ serialNumber: {+ label: "Serial Number",+ required: false,+ type: "string"+ },+ acquisitionCost: {+ label: "Acquisition Cost",+ required: true,+ type: "string"+ },+ acquisitionDate: {+ label: "Acquisition Date",+ required: true,+ type: "string"+ },+ accumulatedDepreciation: {+ label: "Accumulated Depreciation",+ required: false,+ type: "string"+ },+ depreciationMethod: {+ label: "Depreciation Method",+ required: false,+ type: "enum",+ enumData: {+ description: "The depreciation method for this asset",+ options: ["Straight Line", "Declining Balance", "Units of Production"],+ default: "Straight Line"+ }+ },+ usefulLifeMonths: {+ label: "Useful Life (Months)",+ required: false,+ type: "string"+ },+ residualValuePercent: {+ label: "Residual Value %",+ required: false,+ type: "string"+ },+ locationId: {+ label: "Location ID",+ required: false,+ type: "string"+ }}} as const;@@ -953,7 +1010,8 @@ export const importPermissions: Record<keyof typeof fieldMappings, string> = {fixture: "parts",consumable: "parts",workCenter: "production",- process: "production"+ process: "production",+ fixedAsset: "accounting"};export const importSchemas: Record<@@ -1379,5 +1437,49 @@ export const importSchemas: Record<.describe("Whether scanning a barcode should complete all operations for this process")+ }),+ fixedAsset: z.object({+ name: z+ .string()+ .min(1, { message: "Name is required" })+ .describe("The name of the fixed asset"),+ fixedAssetClassId: z+ .string()+ .min(1, { message: "Asset Class is required" })+ .describe("The ID of the fixed asset class"),+ serialNumber: z+ .string()+ .optional()+ .describe("The serial number of the asset"),+ acquisitionCost: z+ .string()+ .optional()+ .describe("The acquisition cost of the asset"),+ acquisitionDate: z+ .string()+ .optional()+ .describe("The date the asset was acquired (YYYY-MM-DD)"),+ accumulatedDepreciation: z+ .string()+ .optional()+ .describe("The accumulated depreciation to date"),+ depreciationMethod: z+ .string()+ .optional()+ .describe(+ "The depreciation method: Straight Line, Declining Balance, or Units of Production"+ ),+ usefulLifeMonths: z+ .string()+ .optional()+ .describe("The useful life of the asset in months"),+ residualValuePercent: z+ .string()+ .optional()+ .describe("The residual value as a percentage of acquisition cost"),+ locationId: z+ .string()+ .optional()+ .describe("The location ID where the asset is located")})} as const;diff --git a/apps/erp/app/root.tsx b/apps/erp/app/root.tsxindex f665309230..b4c5e65fa6 100644--- a/apps/erp/app/root.tsx+++ b/apps/erp/app/root.tsx@@ -285,9 +285,14 @@ export function ErrorBoundary({ error }: Route.ErrorBoundaryProps) {<div className="light"><div className="flex flex-col w-full h-screen items-center justify-center space-y-4 "><img- src="/carbon-logo-mark.svg"+ src="/carbon-mark-light.svg"alt="Carbon Logo"- className="block max-w-[60px]"+ className="block max-w-[60px] dark:hidden"+ />+ <img+ src="/carbon-mark-dark.svg"+ alt="Carbon Logo"+ className="max-w-[60px] hidden dark:block"/><Heading size="h1">Something went wrong</Heading><p className="text-muted-foreground max-w-2xl">{message}</p>diff --git a/apps/erp/app/routes/_public+/_layout.tsx b/apps/erp/app/routes/_public+/_layout.tsxindex 5c10598ae2..132acf3e51 100644--- a/apps/erp/app/routes/_public+/_layout.tsx+++ b/apps/erp/app/routes/_public+/_layout.tsx@@ -12,7 +12,7 @@ export default function PublicRoute() {src="/carbon-word-light.svg"alt="Carbon Logo"className={cn(- "max-w-[240px] mb-3 dark:hidden z-50",+ "max-w-[200px] mb-3 dark:hidden z-50",CONTROLLED_ENVIRONMENT && "grayscale")}/>@@ -20,7 +20,7 @@ export default function PublicRoute() {src="/carbon-word-dark.svg"alt="Carbon Logo"className={cn(- "max-w-[240px] mb-3 dark:block hidden z-50",+ "max-w-[200px] mb-3 dark:block hidden z-50",CONTROLLED_ENVIRONMENT && "grayscale")}/>diff --git a/apps/erp/app/routes/_public+/callback.tsx b/apps/erp/app/routes/_public+/callback.tsxindex 2bf81540ae..c7bdc37d1e 100644--- a/apps/erp/app/routes/_public+/callback.tsx+++ b/apps/erp/app/routes/_public+/callback.tsx@@ -1,6 +1,5 @@import {assertIsPost,- CONTROLLED_ENVIRONMENT,callbackValidator,carbonClient,error,@@ -17,7 +16,7 @@ import {} from "@carbon/auth/session.server";import { getUserByEmail } from "@carbon/auth/users.server";import { validator } from "@carbon/form";-import { Alert, AlertDescription, AlertTitle, cn, VStack } from "@carbon/react";+import { Alert, AlertDescription, AlertTitle, VStack } from "@carbon/react";import { Trans } from "@lingui/react/macro";import { useEffect, useRef, useState } from "react";import { LuTriangleAlert } from "react-icons/lu";@@ -170,17 +169,26 @@ export default function AuthCallback() {</VStack></div>) : (- <div- className={cn(- "hexagon-loader-container",- CONTROLLED_ENVIRONMENT && "grayscale"- )}- >- <div className="hexagon-loader">- <div className="hexagon" />- <div className="hexagon" />- <div className="hexagon" />- </div>+ <div className="flex items-end justify-center gap-1.5 h-8">+ {[0, 1, 2, 3, 4].map((i) => (+ <div+ key={i}+ className="w-1.5 rounded-sm bg-primary"+ style={{+ animationName: "loading-bars",+ animationDuration: "1.2s",+ animationTimingFunction: "ease-in-out",+ animationIterationCount: "infinite",+ animationDelay: `${i * 0.1}s`+ }}+ />+ ))}+ <style>+ {`@keyframes loading-bars {+ 0%, 100% { height: 8px; opacity: 0.3; }+ 50% { height: 32px; opacity: 1; }+ }`}+ </style></div>)}</div>diff --git a/apps/erp/app/routes/_public+/invite.$code.tsx b/apps/erp/app/routes/_public+/invite.$code.tsxindex fa27791082..57fc6e97c5 100644--- a/apps/erp/app/routes/_public+/invite.$code.tsx+++ b/apps/erp/app/routes/_public+/invite.$code.tsx@@ -112,17 +112,21 @@ const Heading = motion.create(_Heading);const Button = motion.create(_Button);export default function Invite() {- const { t } = useLingui();const { success, company } = useLoaderData<typeof loader>();-+ const { t } = useLingui();if (!success) {return (<VStack spacing={4} className="max-w-lg items-center text-center">- <div className="flex justify-center mb-4">+ <div className="flex justify-center mb-8"><img- src="/carbon-logo-mark.svg"+ src="/carbon-mark-light.svg"alt={t`Carbon Logo`}- className="w-36"+ className="w-24 dark:hidden"+ />+ <img+ src="/carbon-mark-dark.svg"+ alt={t`Carbon Logo`}+ className="w-24 hidden dark:block"/></div><VStack spacing={2} className="text-center w-full">@@ -152,9 +156,14 @@ export default function Invite() {initial={{ opacity: 0, scale: 0.4 }}animate={{ opacity: 1, scale: 1 }}transition={{ duration: 2, ease: "easeInOut" }}- src="/carbon-logo-mark.svg"- alt={t`Carbon Logo`}- className="w-24 mb-3"+ src="/carbon-mark-light.svg"+ alt="Carbon Logo"+ className="w-24 dark:hidden"+ />+ <img+ src="/carbon-mark-dark.svg"+ alt="Carbon Logo"+ className="w-24 hidden dark:block"/><Headingdiff --git a/apps/erp/app/routes/_public+/login.tsx b/apps/erp/app/routes/_public+/login.tsxindex db2e60fe46..744a4cf457 100644--- a/apps/erp/app/routes/_public+/login.tsx+++ b/apps/erp/app/routes/_public+/login.tsx@@ -362,11 +362,16 @@ export default function LoginRoute() {return (<>- <div className="flex justify-center mb-4">+ <div className="flex justify-center mb-8"><img- src={CONTROLLED_ENVIRONMENT ? "/flag.png" : "/carbon-logo-mark.svg"}- alt={t`Carbon Logo`}- className="w-36"+ src={CONTROLLED_ENVIRONMENT ? "/flag.png" : "/carbon-mark-light.svg"}+ alt="Carbon Logo"+ className="w-24 dark:hidden"+ />+ <img+ src={CONTROLLED_ENVIRONMENT ? "/flag.png" : "/carbon-mark-dark.svg"}+ alt="Carbon Logo"+ className="w-24 hidden dark:block"/></div><div className="rounded-lg md:bg-card md:border md:border-border md:shadow-lg p-8 w-[380px]">@@ -456,12 +461,6 @@ export default function LoginRoute() {</Button>)}- {(hasGoogleAuth || hasOutlookAuth) && (- <div className="py-3 w-full">- <Separator />- </div>- )}-{hasPasskeyAuth && passkeySupported && (<Buttontype="button"@@ -473,10 +472,16 @@ export default function LoginRoute() {variant="secondary"leftIcon={<LuFingerprint className="size-4" />}>- Sign in with Passkey+ <Trans>Sign in with Passkey</Trans></Button>)}+ {(hasGoogleAuth || hasOutlookAuth || hasPasskeyAuth) && (+ <div className="py-3 w-full">+ <Separator />+ </div>+ )}+<Inputname="email"label=""diff --git a/apps/erp/app/routes/_public+/magic-link.tsx b/apps/erp/app/routes/_public+/magic-link.tsxindex 50a9e66428..0854e6cf5e 100644--- a/apps/erp/app/routes/_public+/magic-link.tsx+++ b/apps/erp/app/routes/_public+/magic-link.tsx@@ -20,11 +20,16 @@ export default function ConfirmMagicLink() {return (<>- <div className="flex justify-center mb-4">+ <div className="flex justify-center mb-8"><img- src={CONTROLLED_ENVIRONMENT ? "/flag.png" : "/carbon-logo-mark.svg"}+ src={CONTROLLED_ENVIRONMENT ? "/flag.png" : "/carbon-mark-light.svg"}+ className="w-24 dark:hidden"+ alt={t`Carbon Logo`}+ />+ <img+ src={CONTROLLED_ENVIRONMENT ? "/flag.png" : "/carbon-mark-dark.svg"}+ className="w-24 hidden dark:block"alt={t`Carbon Logo`}- className="w-36"/></div><div className="rounded-lg md:bg-card md:border md:border-border md:shadow-lg p-8 w-[380px]">diff --git a/apps/erp/app/routes/_public+/verify.tsx b/apps/erp/app/routes/_public+/verify.tsxindex 1b754d362a..b310bd7883 100644--- a/apps/erp/app/routes/_public+/verify.tsx+++ b/apps/erp/app/routes/_public+/verify.tsx@@ -141,11 +141,16 @@ export default function VerifyRoute() {return (<>- <div className="flex justify-center mb-4">+ <div className="flex justify-center mb-8"><img- src="/carbon-logo-mark.svg"+ src="/carbon-mark-light.svg"alt={t`Carbon Logo`}- className="w-36"+ className="w-24 dark:hidden"+ />+ <img+ src="/carbon-mark-dark.svg"+ alt={t`Carbon Logo`}+ className="w-24 hidden dark:block"/></div><div className="rounded-lg md:bg-card md:border md:border-border md:shadow-lg p-8 w-[380px]">diff --git a/apps/erp/app/routes/api+/accounting.asset-classes.ts b/apps/erp/app/routes/api+/accounting.asset-classes.tsnew file mode 100644index 0000000000..5ecf22f760--- /dev/null+++ b/apps/erp/app/routes/api+/accounting.asset-classes.ts@@ -0,0 +1,9 @@+import { requirePermissions } from "@carbon/auth/auth.server";+import type { LoaderFunctionArgs } from "react-router";+import { getFixedAssetClassesList } from "~/modules/accounting";++export async function loader({ request }: LoaderFunctionArgs) {+ const { client, companyId } = await requirePermissions(request, {});++ return await getFixedAssetClassesList(client, companyId);+}diff --git a/apps/erp/app/routes/api+/mcp+/lib/tool-metadata.json b/apps/erp/app/routes/api+/mcp+/lib/tool-metadata.jsonindex 98079b1da7..871e99da81 100644--- a/apps/erp/app/routes/api+/mcp+/lib/tool-metadata.json+++ b/apps/erp/app/routes/api+/mcp+/lib/tool-metadata.json@@ -1,5 +1,5 @@{- "generated": "2026-05-25T09:55:08.744Z",+ "generated": "2026-05-25T15:51:44.351Z","totalTools": 1075,"modules": 15,"tools": [diff --git a/apps/erp/app/routes/x+/accounting+/asset-class.$assetClassId.delete.tsx b/apps/erp/app/routes/x+/accounting+/asset-class.$assetClassId.delete.tsxnew file mode 100644index 0000000000..3cbed7c176--- /dev/null+++ b/apps/erp/app/routes/x+/accounting+/asset-class.$assetClassId.delete.tsx@@ -0,0 +1,81 @@+import { error, notFound, success } from "@carbon/auth";+import { requirePermissions } from "@carbon/auth/auth.server";+import { flash } from "@carbon/auth/session.server";+import type { ActionFunctionArgs, LoaderFunctionArgs } from "react-router";+import { redirect, useLoaderData, useNavigate, useParams } from "react-router";+import { ConfirmDelete } from "~/components/Modals";+import {+ deleteFixedAssetClass,+ getFixedAssetClass+} from "~/modules/accounting";+import { path } from "~/utils/path";++export async function loader({ request, params }: LoaderFunctionArgs) {+ const { client } = await requirePermissions(request, {+ view: "accounting",+ role: "employee"+ });++ const { assetClassId } = params;+ if (!assetClassId) throw notFound("assetClassId not found");++ const assetClass = await getFixedAssetClass(client, assetClassId);+ if (assetClass.error) {+ throw redirect(+ path.to.assetClasses,+ await flash(request, error(assetClass.error, "Failed to get asset class"))+ );+ }++ return { assetClass: assetClass.data };+}++export async function action({ request, params }: ActionFunctionArgs) {+ const { client } = await requirePermissions(request, {+ delete: "accounting"+ });++ const { assetClassId } = params;+ if (!assetClassId) {+ throw redirect(+ path.to.assetClasses,+ await flash(request, error(params, "Failed to get asset class id"))+ );+ }++ const { error: deleteError } = await deleteFixedAssetClass(+ client,+ assetClassId+ );+ if (deleteError) {+ throw redirect(+ path.to.assetClasses,+ await flash(request, error(deleteError, "Failed to delete asset class"))+ );+ }++ throw redirect(+ path.to.assetClasses,+ await flash(request, success("Successfully deleted asset class"))+ );+}++export default function DeleteAssetClassRoute() {+ const { assetClassId } = useParams();+ const { assetClass } = useLoaderData<typeof loader>();+ const navigate = useNavigate();++ if (!assetClass) return null;+ if (!assetClassId) throw new Error("assetClassId is not found");++ const onCancel = () => navigate(path.to.assetClasses);++ return (+ <ConfirmDelete+ action={path.to.deleteAssetClass(assetClassId)}+ name={assetClass.name}+ text={`Are you sure you want to delete the asset class: ${assetClass.name}? This cannot be undone.`}+ onCancel={onCancel}+ />+ );+}diff --git a/apps/erp/app/routes/x+/accounting+/asset-class.$assetClassId.tsx b/apps/erp/app/routes/x+/accounting+/asset-class.$assetClassId.tsxnew file mode 100644index 0000000000..50ce75abc2--- /dev/null+++ b/apps/erp/app/routes/x+/accounting+/asset-class.$assetClassId.tsx@@ -0,0 +1,120 @@+import { assertIsPost, error, notFound, success } from "@carbon/auth";+import { requirePermissions } from "@carbon/auth/auth.server";+import { flash } from "@carbon/auth/session.server";+import { validationError, validator } from "@carbon/form";+import type { ActionFunctionArgs, LoaderFunctionArgs } from "react-router";+import { redirect, useLoaderData, useNavigate } from "react-router";+import {+ fixedAssetClassValidator,+ getFixedAssetClass,+ upsertFixedAssetClass+} from "~/modules/accounting";+import { AssetClassForm } from "~/modules/accounting/ui/FixedAssets";+import { getCompanySettings } from "~/modules/settings";+import { path } from "~/utils/path";++export async function loader({ request, params }: LoaderFunctionArgs) {+ const { client, companyId } = await requirePermissions(request, {+ view: "accounting"+ });++ const { assetClassId } = params;+ if (!assetClassId) throw notFound("Asset Class ID was not found");++ const [assetClass, companySettings] = await Promise.all([+ getFixedAssetClass(client, assetClassId),+ getCompanySettings(client, companyId)+ ]);++ if (assetClass.error) {+ throw redirect(+ path.to.assetClasses,+ await flash(request, error(assetClass.error, "Failed to get asset class"))+ );+ }++ return {+ assetClass: assetClass.data,+ taxDepreciationEnabled:+ (companySettings.data as any)?.assetTaxDepreciationEnabled ?? false+ };+}++export async function action({ request }: ActionFunctionArgs) {+ assertIsPost(request);+ const { client, userId } = await requirePermissions(request, {+ update: "accounting"+ });++ const formData = await request.formData();+ const validation = await validator(fixedAssetClassValidator).validate(+ formData+ );++ if (validation.error) {+ return validationError(validation.error);+ }++ const { id, ...d } = validation.data;+ if (!id) throw notFound("Asset Class ID was not found");++ const result = await upsertFixedAssetClass(client, {+ id,+ ...d,+ updatedBy: userId+ });++ if (result.error) {+ throw redirect(+ path.to.assetClasses,+ await flash(request, error(result.error, "Failed to update asset class"))+ );+ }++ throw redirect(+ path.to.assetClasses,+ await flash(request, success("Asset class updated"))+ );+}++export default function AssetClassRoute() {+ const { assetClass, taxDepreciationEnabled } = useLoaderData<typeof loader>();+ const navigate = useNavigate();++ const initialValues = {+ id: assetClass.id,+ name: assetClass.name,+ description: assetClass.description ?? "",+ depreciationMethod: assetClass.depreciationMethod,+ usefulLifeMonths: assetClass.usefulLifeMonths,+ residualValuePercent: Number(assetClass.residualValuePercent),+ assetAccountId: assetClass.assetAccountId,+ accumulatedDepreciationAccountId:+ assetClass.accumulatedDepreciationAccountId,+ depreciationExpenseAccountId: assetClass.depreciationExpenseAccountId,+ writeOffAccountId: assetClass.writeOffAccountId,+ writeDownAccountId: assetClass.writeDownAccountId,+ disposalAccountId: assetClass.disposalAccountId,+ taxDepreciationMethod: (assetClass as any).taxDepreciationMethod ?? null,+ taxUsefulLifeMonths: (assetClass as any).taxUsefulLifeMonths ?? null,+ taxResidualValuePercent:+ (assetClass as any).taxResidualValuePercent != null+ ? Number((assetClass as any).taxResidualValuePercent)+ : null,+ macrsPropertyClass: (assetClass as any).macrsPropertyClass ?? null,+ macrsConvention: (assetClass as any).macrsConvention ?? null,+ bonusDepreciationPercent:+ (assetClass as any).bonusDepreciationPercent != null+ ? Number((assetClass as any).bonusDepreciationPercent)+ : null+ };++ return (+ <AssetClassForm+ onClose={() => navigate(-1)}+ key={initialValues.id}+ initialValues={initialValues}+ taxDepreciationEnabled={taxDepreciationEnabled}+ />+ );+}diff --git a/apps/erp/app/routes/x+/accounting+/asset-classes.new.tsx b/apps/erp/app/routes/x+/accounting+/asset-classes.new.tsxnew file mode 100644index 0000000000..60dce084fe--- /dev/null+++ b/apps/erp/app/routes/x+/accounting+/asset-classes.new.tsx@@ -0,0 +1,104 @@+import { assertIsPost, error, success } from "@carbon/auth";+import { requirePermissions } from "@carbon/auth/auth.server";+import { flash } from "@carbon/auth/session.server";+import { validationError, validator } from "@carbon/form";+import type { ActionFunctionArgs, LoaderFunctionArgs } from "react-router";+import { redirect, useLoaderData, useNavigate } from "react-router";+import {+ fixedAssetClassValidator,+ getDefaultAccounts,+ upsertFixedAssetClass+} from "~/modules/accounting";+import { AssetClassForm } from "~/modules/accounting/ui/FixedAssets";+import { getCompanySettings } from "~/modules/settings";+import { path } from "~/utils/path";++export async function loader({ request }: LoaderFunctionArgs) {+ const { client, companyId } = await requirePermissions(request, {+ create: "accounting"+ });++ const [defaults, companySettings] = await Promise.all([+ getDefaultAccounts(client, companyId),+ getCompanySettings(client, companyId)+ ]);++ return {+ defaults: defaults.data,+ taxDepreciationEnabled:+ (companySettings.data as any)?.assetTaxDepreciationEnabled ?? false+ };+}++export async function action({ request }: ActionFunctionArgs) {+ assertIsPost(request);+ const { client, companyId, userId } = await requirePermissions(request, {+ create: "accounting"+ });++ const formData = await request.formData();+ const validation = await validator(fixedAssetClassValidator).validate(+ formData+ );++ if (validation.error) {+ return validationError(validation.error);+ }++ const { id: _id, ...d } = validation.data;+ const modal = formData.get("type") === "modal";++ const result = await upsertFixedAssetClass(client, {+ ...d,+ companyId,+ createdBy: userId+ });++ if (result.error) {+ return modal+ ? result+ : redirect(+ path.to.assetClasses,+ await flash(+ request,+ error(result.error, "Failed to create asset class")+ )+ );+ }++ if (modal) return result;++ throw redirect(+ path.to.assetClasses,+ await flash(request, success("Asset class created"))+ );+}++export default function NewAssetClassRoute() {+ const navigate = useNavigate();+ const { defaults, taxDepreciationEnabled } = useLoaderData<typeof loader>();++ const initialValues = {+ name: "",+ description: "",+ depreciationMethod: "Straight Line" as const,+ usefulLifeMonths: 60,+ residualValuePercent: 0,+ assetAccountId: defaults?.assetAquisitionCostAccount ?? "",+ accumulatedDepreciationAccountId:+ defaults?.accumulatedDepreciationAccount ?? "",+ depreciationExpenseAccountId:+ defaults?.assetDepreciationExpenseAccount ?? "",+ writeOffAccountId: defaults?.assetGainsAndLossesAccount ?? "",+ writeDownAccountId: defaults?.assetGainsAndLossesAccount ?? "",+ disposalAccountId: defaults?.assetGainsAndLossesAccount ?? ""+ };++ return (+ <AssetClassForm+ onClose={() => navigate(-1)}+ initialValues={initialValues}+ taxDepreciationEnabled={taxDepreciationEnabled}+ />+ );+}diff --git a/apps/erp/app/routes/x+/accounting+/asset-classes.tsx b/apps/erp/app/routes/x+/accounting+/asset-classes.tsxnew file mode 100644index 0000000000..31f86e69ba--- /dev/null+++ b/apps/erp/app/routes/x+/accounting+/asset-classes.tsx@@ -0,0 +1,77 @@+import { requirePermissions } from "@carbon/auth/auth.server";+import { Button, VStack } from "@carbon/react";+import { LuCirclePlus } from "react-icons/lu";+import type { LoaderFunctionArgs } from "react-router";+import { Outlet, useLoaderData, useNavigate } from "react-router";+import { usePermissions } from "~/hooks";+import { getFixedAssetClasses } from "~/modules/accounting";+import { AssetClassesTable } from "~/modules/accounting/ui/FixedAssets";+import { getCompanySettings } from "~/modules/settings";+import type { Handle } from "~/utils/handle";+import { path } from "~/utils/path";+import { getGenericQueryFilters } from "~/utils/query";++export const handle: Handle = {+ breadcrumb: "Asset Classes",+ to: path.to.assetClasses+};++export async function loader({ request }: LoaderFunctionArgs) {+ const { client, companyId } = await requirePermissions(request, {+ view: "accounting",+ role: "employee"+ });++ const url = new URL(request.url);+ const searchParams = new URLSearchParams(url.search);+ const search = searchParams.get("search");+ const { limit, offset, sorts, filters } =+ getGenericQueryFilters(searchParams);++ const [classes, companySettings] = await Promise.all([+ getFixedAssetClasses(client, companyId, {+ search,+ limit,+ offset,+ sorts,+ filters+ }),+ getCompanySettings(client, companyId)+ ]);++ return {+ data: classes.data ?? [],+ count: classes.count ?? 0,+ taxDepreciationEnabled:+ (companySettings.data as any)?.assetTaxDepreciationEnabled ?? false+ };+}++export default function AssetClassesRoute() {+ const { data, count, taxDepreciationEnabled } =+ useLoaderData<typeof loader>();+ const permissions = usePermissions();+ const navigate = useNavigate();++ return (+ <VStack spacing={0} className="h-full">+ <AssetClassesTable+ data={data}+ count={count}+ taxDepreciationEnabled={taxDepreciationEnabled}+ primaryAction={+ permissions.can("create", "accounting") && (+ <Button+ leftIcon={<LuCirclePlus />}+ variant="primary"+ onClick={() => navigate(path.to.newAssetClass)}+ >+ Add Asset Class+ </Button>+ )+ }+ />+ <Outlet />+ </VStack>+ );+}diff --git a/apps/erp/app/routes/x+/accounting+/balance-sheet.tsx b/apps/erp/app/routes/x+/accounting+/balance-sheet.tsxindex bff4565a21..1b2eae4383 100644--- a/apps/erp/app/routes/x+/accounting+/balance-sheet.tsx+++ b/apps/erp/app/routes/x+/accounting+/balance-sheet.tsx@@ -2,6 +2,7 @@ import { error } from "@carbon/auth";import { requirePermissions } from "@carbon/auth/auth.server";import { flash } from "@carbon/auth/session.server";import { VStack } from "@carbon/react";+import { useState } from "react";import type { LoaderFunctionArgs } from "react-router";import { redirect, useLoaderData } from "react-router";import type { Chart } from "~/modules/accounting";@@ -174,6 +175,7 @@ export default function BalanceSheetRoute() {isForeignCurrency,parentCurrency} = useLoaderData<typeof loader>();+ const [search, setSearch] = useState("");return (<VStack spacing={0} className="h-full">@@ -183,11 +185,14 @@ export default function BalanceSheetRoute() {isMultiCompany={isMultiCompany}isForeignCurrency={isForeignCurrency}parentCurrency={parentCurrency}+ search={search}+ onSearchChange={setSearch}/><FinancialStatementTreedata={balanceSheet}showTranslated={showTranslated}parentCurrency={parentCurrency}+ search={search}/></VStack>);diff --git a/apps/erp/app/routes/x+/accounting+/charts.tsx b/apps/erp/app/routes/x+/accounting+/charts.tsxindex 1e0ad792da..21e20a2563 100644--- a/apps/erp/app/routes/x+/accounting+/charts.tsx+++ b/apps/erp/app/routes/x+/accounting+/charts.tsx@@ -3,6 +3,7 @@ import { requirePermissions } from "@carbon/auth/auth.server";import { flash } from "@carbon/auth/session.server";import { VStack } from "@carbon/react";import { msg } from "@lingui/core/macro";+import { useState } from "react";import type { LoaderFunctionArgs } from "react-router";import { Outlet, redirect, useLoaderData } from "react-router";import type { Chart } from "~/modules/accounting";@@ -26,18 +27,12 @@ export async function loader({ request }: LoaderFunctionArgs) {const url = new URL(request.url);const searchParams = new URLSearchParams(url.search);- const incomeBalanceParam = searchParams.get("incomeBalance");- const incomeBalance =- incomeBalanceParam === "Income Statement" ||- incomeBalanceParam === "Balance Sheet"- ? incomeBalanceParam- : null;const startDate = searchParams.get("startDate") || null;const endDate = searchParams.get("endDate") || null;const chartOfAccounts = await getChartOfAccounts(client, companyGroupId, {- incomeBalance: incomeBalance as "Income Statement" | "Balance Sheet" | null,+ incomeBalance: null,startDate,endDate});@@ -59,11 +54,12 @@ export async function loader({ request }: LoaderFunctionArgs) {export default function ChartOfAccountsRoute() {const { chartOfAccounts } = useLoaderData<typeof loader>();+ const [search, setSearch] = useState("");return (<VStack spacing={0} className="h-full">- <ChartOfAccountsTableFilters />- <ChartOfAccountsTree data={chartOfAccounts} />+ <ChartOfAccountsTableFilters search={search} onSearchChange={setSearch} />+ <ChartOfAccountsTree data={chartOfAccounts} search={search} /><Outlet /></VStack>);diff --git a/apps/erp/app/routes/x+/accounting+/depreciation-runs.new.tsx b/apps/erp/app/routes/x+/accounting+/depreciation-runs.new.tsxnew file mode 100644index 0000000000..5976ac402b--- /dev/null+++ b/apps/erp/app/routes/x+/accounting+/depreciation-runs.new.tsx@@ -0,0 +1,178 @@+import { assertIsPost, error, success } from "@carbon/auth";+import { requirePermissions } from "@carbon/auth/auth.server";+import { flash } from "@carbon/auth/session.server";+import type { ActionFunctionArgs } from "react-router";+import { redirect } from "react-router";+import {+ buildDepreciationLines,+ getNextPeriodEnd+} from "~/modules/accounting/accounting.utils";+import { getNextSequence } from "~/modules/settings";+import { path } from "~/utils/path";++export async function action({ request }: ActionFunctionArgs) {+ assertIsPost(request);+ const { client, companyId, userId } = await requirePermissions(request, {+ create: "accounting"+ });++ // Find the last run (posted or draft) to determine the next period+ const lastRun = await client+ .from("depreciationRun")+ .select("periodEnd, status")+ .eq("companyId", companyId)+ .order("periodEnd", { ascending: false })+ .limit(1);++ const lastPeriodEnd =+ lastRun.data && lastRun.data.length > 0 ? lastRun.data[0].periodEnd : null;++ const periodEnd = getNextPeriodEnd(lastPeriodEnd);++ // Check for existing run at this period+ const existing = await client+ .from("depreciationRun")+ .select("id")+ .eq("periodEnd", periodEnd)+ .eq("companyId", companyId);++ if (existing.data && existing.data.length > 0) {+ throw redirect(+ path.to.depreciationRuns,+ await flash(+ request,+ error(null, "A depreciation run already exists for this period")+ )+ );+ }++ const companySettings = await client+ .from("companySettings")+ .select("assetTaxDepreciationEnabled")+ .eq("id", companyId)+ .single();++ const taxEnabled =+ (companySettings.data as any)?.assetTaxDepreciationEnabled ?? false;++ const assets = await client+ .from("fixedAsset")+ .select("*")+ .eq("companyId", companyId)+ .eq("status", "Active");++ if (assets.error) {+ throw redirect(+ path.to.depreciationRuns,+ await flash(request, error(assets.error, "Failed to fetch assets"))+ );+ }++ // For depreciation calculation, use last *posted* run+ const lastPostedRun = await client+ .from("depreciationRun")+ .select("periodEnd")+ .eq("companyId", companyId)+ .eq("status", "Posted")+ .order("periodEnd", { ascending: false })+ .limit(1);++ const lastPostedPeriodEnd =+ lastPostedRun.data && lastPostedRun.data.length > 0+ ? lastPostedRun.data[0].periodEnd+ : null;++ const usageLogs = await client+ .from("fixedAssetUsageLog")+ .select("fixedAssetId, unitsProduced")+ .eq("periodEnd", periodEnd);++ const usageMap = new Map(+ (usageLogs.data ?? []).map((u) => [u.fixedAssetId, u])+ );++ const lines = buildDepreciationLines(+ (assets.data ?? []).map((a) => ({+ ...a,+ accumulatedTaxDepreciation: Number(+ (a as any).accumulatedTaxDepreciation ?? 0+ ),+ taxDepreciationMethod: (a as any).taxDepreciationMethod ?? null,+ taxUsefulLifeMonths: (a as any).taxUsefulLifeMonths ?? null,+ taxResidualValuePercent: (a as any).taxResidualValuePercent ?? null,+ macrsPropertyClass: (a as any).macrsPropertyClass ?? null,+ macrsConvention: (a as any).macrsConvention ?? null,+ bonusDepreciationPercent: (a as any).bonusDepreciationPercent ?? null+ })),+ periodEnd,+ lastPostedPeriodEnd,+ taxEnabled,+ usageMap+ );++ const nextSequence = await getNextSequence(+ client,+ "depreciationRun",+ companyId+ );+ if (nextSequence.error) {+ throw redirect(+ path.to.depreciationRuns,+ await flash(+ request,+ error(nextSequence.error, "Failed to generate run ID")+ )+ );+ }++ const run = await client+ .from("depreciationRun")+ .insert({+ depreciationRunId: nextSequence.data,+ periodEnd,+ status: "Draft",+ companyId,+ createdBy: userId+ })+ .select("id")+ .single();++ if (run.error) {+ throw redirect(+ path.to.depreciationRuns,+ await flash(+ request,+ error(run.error, "Failed to create depreciation run")+ )+ );+ }++ if (lines.length > 0) {+ const lineInserts = lines.map((line) => ({+ depreciationRunId: run.data.id,+ fixedAssetId: line.fixedAssetId,+ amount: line.amount,+ taxAmount: line.taxAmount,+ companyId+ }));++ const lineResult = await client+ .from("depreciationRunLine")+ .insert(lineInserts);++ if (lineResult.error) {+ throw redirect(+ path.to.depreciationRuns,+ await flash(+ request,+ error(lineResult.error, "Failed to create run lines")+ )+ );+ }+ }++ throw redirect(+ path.to.depreciationRun(run.data.id),+ await flash(request, success("Depreciation run created"))+ );+}diff --git a/apps/erp/app/routes/x+/accounting+/depreciation-runs.tsx b/apps/erp/app/routes/x+/accounting+/depreciation-runs.tsxnew file mode 100644index 0000000000..7b2f1811e9--- /dev/null+++ b/apps/erp/app/routes/x+/accounting+/depreciation-runs.tsx@@ -0,0 +1,126 @@+import { requirePermissions } from "@carbon/auth/auth.server";+import {+ Button,+ Tooltip,+ TooltipContent,+ TooltipProvider,+ TooltipTrigger,+ useDisclosure,+ VStack+} from "@carbon/react";+import { formatDate } from "@carbon/utils";+import { LuCirclePlus } from "react-icons/lu";+import type { LoaderFunctionArgs } from "react-router";+import { useLoaderData, useNavigate } from "react-router";+import { Confirm } from "~/components/Modals";+import { usePermissions } from "~/hooks";+import { getDepreciationRuns } from "~/modules/accounting";+import { getNextPeriodEnd } from "~/modules/accounting/accounting.utils";+import { DepreciationRunTable } from "~/modules/accounting/ui/FixedAssets";+import type { Handle } from "~/utils/handle";+import { path } from "~/utils/path";+import { getGenericQueryFilters } from "~/utils/query";++export const handle: Handle = {+ breadcrumb: "Depreciation",+ to: path.to.depreciationRuns+};++export async function loader({ request }: LoaderFunctionArgs) {+ const { client, companyId } = await requirePermissions(request, {+ view: "accounting",+ role: "employee"+ });++ const url = new URL(request.url);+ const searchParams = new URLSearchParams(url.search);+ const search = searchParams.get("search");+ const { limit, offset, sorts, filters } =+ getGenericQueryFilters(searchParams);++ const [runs, lastRun] = await Promise.all([+ getDepreciationRuns(client, companyId, {+ search,+ limit,+ offset,+ sorts,+ filters+ }),+ client+ .from("depreciationRun")+ .select("periodEnd, status")+ .eq("companyId", companyId)+ .order("periodEnd", { ascending: false })+ .limit(1)+ ]);++ const lastRunData =+ lastRun.data && lastRun.data.length > 0 ? lastRun.data[0] : null;+ const nextPeriodEnd = getNextPeriodEnd(lastRunData?.periodEnd ?? null);+ const hasDraftBlocking = lastRunData?.status === "Draft";++ return {+ data: runs.data ?? [],+ count: runs.count ?? 0,+ nextPeriodEnd,+ hasDraftBlocking+ };+}++export default function DepreciationRunsRoute() {+ const { data, count, nextPeriodEnd, hasDraftBlocking } =+ useLoaderData<typeof loader>();+ const permissions = usePermissions();+ const navigate = useNavigate();+ const confirmModal = useDisclosure();++ const canCreate =+ permissions.can("create", "accounting") && !hasDraftBlocking;++ return (+ <VStack spacing={0} className="h-full">+ <DepreciationRunTable+ data={data}+ count={count}+ primaryAction={+ permissions.can("create", "accounting") && (+ <TooltipProvider>+ <Tooltip>+ <TooltipTrigger asChild>+ <span>+ <Button+ leftIcon={<LuCirclePlus />}+ variant="primary"+ onClick={confirmModal.onOpen}+ isDisabled={!canCreate}+ >+ Run Next Period+ </Button>+ </span>+ </TooltipTrigger>+ {hasDraftBlocking && (+ <TooltipContent>+ A draft run must be posted or deleted first.+ </TooltipContent>+ )}+ </Tooltip>+ </TooltipProvider>+ )+ }+ />++ <Confirm+ action={path.to.newDepreciationRun}+ isOpen={confirmModal.isOpen}+ title="Run Next Period"+ text={`This will create a draft depreciation run for the period ending ${formatDate(nextPeriodEnd)}. All active assets will be calculated automatically.`}+ confirmText="Create Run"+ onCancel={confirmModal.onClose}+ onSubmit={() => {+ confirmModal.onClose();+ navigate(path.to.depreciationRuns);+ }}+ />+ </VStack>+ );+}diff --git a/apps/erp/app/routes/x+/accounting+/fixed-assets.new.tsx b/apps/erp/app/routes/x+/accounting+/fixed-assets.new.tsxnew file mode 100644index 0000000000..d54c363f21--- /dev/null+++ b/apps/erp/app/routes/x+/accounting+/fixed-assets.new.tsx@@ -0,0 +1,80 @@+import { assertIsPost, error, success } from "@carbon/auth";+import { requirePermissions } from "@carbon/auth/auth.server";+import { flash } from "@carbon/auth/session.server";+import { validationError, validator } from "@carbon/form";+import type { ActionFunctionArgs } from "react-router";+import { redirect, useNavigate } from "react-router";+import { fixedAssetValidator, upsertFixedAsset } from "~/modules/accounting";+import { FixedAssetForm } from "~/modules/accounting/ui/FixedAssets";+import { getNextSequence } from "~/modules/settings";+import { path } from "~/utils/path";++export async function action({ request }: ActionFunctionArgs) {+ assertIsPost(request);+ const { client, companyId, userId } = await requirePermissions(request, {+ create: "accounting"+ });++ const formData = await request.formData();+ const validation = await validator(fixedAssetValidator).validate(formData);++ if (validation.error) {+ return validationError(validation.error);+ }++ const { id: _id, ...d } = validation.data;++ const nextSequence = await getNextSequence(client, "fixedAsset", companyId);+ if (nextSequence.error) {+ return redirect(+ path.to.fixedAssets,+ await flash(+ request,+ error(nextSequence.error, "Failed to generate asset ID")+ )+ );+ }++ const status = "Draft";++ const result = await upsertFixedAsset(client, {+ ...d,+ fixedAssetId: nextSequence.data,+ status,+ companyId,+ createdBy: userId+ });++ if (result.error) {+ return redirect(+ path.to.fixedAssets,+ await flash(request, error(result.error, "Failed to create fixed asset"))+ );+ }++ throw redirect(+ path.to.fixedAsset(result.data.id),+ await flash(request, success("Fixed asset created"))+ );+}++export default function NewFixedAssetRoute() {+ const navigate = useNavigate();++ const initialValues = {+ fixedAssetClassId: "",+ name: "",+ description: "",+ serialNumber: "",+ depreciationMethod: "Straight Line" as const,+ usefulLifeMonths: 60,+ residualValuePercent: 0+ };++ return (+ <FixedAssetForm+ onClose={() => navigate(-1)}+ initialValues={initialValues}+ />+ );+}diff --git a/apps/erp/app/routes/x+/accounting+/fixed-assets.tsx b/apps/erp/app/routes/x+/accounting+/fixed-assets.tsxnew file mode 100644index 0000000000..6014ad8f1a--- /dev/null+++ b/apps/erp/app/routes/x+/accounting+/fixed-assets.tsx@@ -0,0 +1,81 @@+import { requirePermissions } from "@carbon/auth/auth.server";+import { Button, VStack } from "@carbon/react";+import { LuCirclePlus } from "react-icons/lu";+import type { LoaderFunctionArgs } from "react-router";+import { Outlet, useLoaderData, useNavigate } from "react-router";+import { usePermissions } from "~/hooks";+import { getFixedAssetClassesList, getFixedAssets } from "~/modules/accounting";+import { FixedAssetsTable } from "~/modules/accounting/ui/FixedAssets";+import type { Handle } from "~/utils/handle";+import { path } from "~/utils/path";+import { getGenericQueryFilters } from "~/utils/query";++export const handle: Handle = {+ breadcrumb: "Fixed Assets",+ to: path.to.fixedAssets+};++export async function loader({ request }: LoaderFunctionArgs) {+ const { client, companyId } = await requirePermissions(request, {+ view: "accounting",+ role: "employee"+ });++ const url = new URL(request.url);+ const searchParams = new URLSearchParams(url.search);+ const search = searchParams.get("search");+ const status = searchParams.get("status") as+ | "Draft"+ | "Active"+ | "Fully Depreciated"+ | "Disposed"+ | null;+ const { limit, offset, sorts, filters } =+ getGenericQueryFilters(searchParams);++ const [assets, assetClasses] = await Promise.all([+ getFixedAssets(client, companyId, {+ search,+ status,+ limit,+ offset,+ sorts,+ filters+ }),+ getFixedAssetClassesList(client, companyId)+ ]);++ return {+ data: assets.data ?? [],+ count: assets.count ?? 0,+ assetClasses: assetClasses.data ?? []+ };+}++export default function FixedAssetsRoute() {+ const { data, count, assetClasses } = useLoaderData<typeof loader>();+ const permissions = usePermissions();+ const navigate = useNavigate();++ return (+ <VStack spacing={0} className="h-full">+ <FixedAssetsTable+ data={data}+ count={count}+ assetClasses={assetClasses}+ primaryAction={+ permissions.can("create", "accounting") && (+ <Button+ leftIcon={<LuCirclePlus />}+ variant="primary"+ onClick={() => navigate(path.to.newFixedAsset)}+ >+ Add Fixed Asset+ </Button>+ )+ }+ />+ <Outlet />+ </VStack>+ );+}diff --git a/apps/erp/app/routes/x+/accounting+/income-statement.tsx b/apps/erp/app/routes/x+/accounting+/income-statement.tsxindex 9b5151d2a4..01d9d5fd51 100644--- a/apps/erp/app/routes/x+/accounting+/income-statement.tsx+++ b/apps/erp/app/routes/x+/accounting+/income-statement.tsx@@ -2,6 +2,7 @@ import { error } from "@carbon/auth";import { requirePermissions } from "@carbon/auth/auth.server";import { flash } from "@carbon/auth/session.server";import { VStack } from "@carbon/react";+import { useState } from "react";import type { LoaderFunctionArgs } from "react-router";import { redirect, useLoaderData } from "react-router";import type { Chart } from "~/modules/accounting";@@ -161,6 +162,7 @@ export default function IncomeStatementRoute() {isForeignCurrency,parentCurrency} = useLoaderData<typeof loader>();+ const [search, setSearch] = useState("");return (<VStack spacing={0} className="h-full">@@ -170,11 +172,14 @@ export default function IncomeStatementRoute() {isMultiCompany={isMultiCompany}isForeignCurrency={isForeignCurrency}parentCurrency={parentCurrency}+ search={search}+ onSearchChange={setSearch}/><FinancialStatementTreedata={incomeStatement}showTranslated={showTranslated}parentCurrency={parentCurrency}+ search={search}/></VStack>);diff --git a/apps/erp/app/routes/x+/accounting+/trial-balance.tsx b/apps/erp/app/routes/x+/accounting+/trial-balance.tsxindex 1f806cf5b2..fc959342ea 100644--- a/apps/erp/app/routes/x+/accounting+/trial-balance.tsx+++ b/apps/erp/app/routes/x+/accounting+/trial-balance.tsx@@ -2,6 +2,7 @@ import { error } from "@carbon/auth";import { requirePermissions } from "@carbon/auth/auth.server";import { flash } from "@carbon/auth/session.server";import { VStack } from "@carbon/react";+import { useState } from "react";import type { LoaderFunctionArgs } from "react-router";import { redirect, useLoaderData } from "react-router";import type { Chart } from "~/modules/accounting";@@ -158,6 +159,7 @@ export default function TrialBalanceRoute() {isForeignCurrency,parentCurrency} = useLoaderData<typeof loader>();+ const [search, setSearch] = useState("");return (<VStack spacing={0} className="h-full">@@ -167,11 +169,14 @@ export default function TrialBalanceRoute() {isMultiCompany={isMultiCompany}isForeignCurrency={isForeignCurrency}parentCurrency={parentCurrency}+ search={search}+ onSearchChange={setSearch}/><TrialBalanceTreedata={trialBalance}showTranslated={showTranslated}parentCurrency={parentCurrency}+ search={search}/></VStack>);diff --git a/apps/erp/app/routes/x+/depreciation-run+/$depreciationRunId.delete.tsx b/apps/erp/app/routes/x+/depreciation-run+/$depreciationRunId.delete.tsxnew file mode 100644index 0000000000..d8ea5c1feb--- /dev/null+++ b/apps/erp/app/routes/x+/depreciation-run+/$depreciationRunId.delete.tsx@@ -0,0 +1,84 @@+import { error, notFound, success } from "@carbon/auth";+import { requirePermissions } from "@carbon/auth/auth.server";+import { flash } from "@carbon/auth/session.server";+import type { ActionFunctionArgs, LoaderFunctionArgs } from "react-router";+import { redirect, useLoaderData, useNavigate, useParams } from "react-router";+import { ConfirmDelete } from "~/components/Modals";+import {+ deleteDepreciationRun,+ getDepreciationRun+} from "~/modules/accounting";+import { path } from "~/utils/path";++export async function loader({ request, params }: LoaderFunctionArgs) {+ const { client } = await requirePermissions(request, {+ view: "accounting",+ role: "employee"+ });++ const { depreciationRunId } = params;+ if (!depreciationRunId) throw notFound("depreciationRunId not found");++ const run = await getDepreciationRun(client, depreciationRunId);+ if (run.error) {+ throw redirect(+ path.to.depreciationRuns,+ await flash(request, error(run.error, "Failed to get depreciation run"))+ );+ }++ return { run: run.data };+}++export async function action({ request, params }: ActionFunctionArgs) {+ const { client } = await requirePermissions(request, {+ delete: "accounting"+ });++ const { depreciationRunId } = params;+ if (!depreciationRunId) {+ throw redirect(+ path.to.depreciationRuns,+ await flash(request, error(params, "Failed to get depreciation run id"))+ );+ }++ const { error: deleteError } = await deleteDepreciationRun(+ client,+ depreciationRunId+ );+ if (deleteError) {+ throw redirect(+ path.to.depreciationRuns,+ await flash(+ request,+ error(deleteError, "Failed to delete depreciation run")+ )+ );+ }++ throw redirect(+ path.to.depreciationRuns,+ await flash(request, success("Successfully deleted depreciation run"))+ );+}++export default function DeleteDepreciationRunRoute() {+ const { depreciationRunId } = useParams();+ const { run } = useLoaderData<typeof loader>();+ const navigate = useNavigate();++ if (!run) return null;+ if (!depreciationRunId) throw new Error("depreciationRunId is not found");++ const onCancel = () => navigate(path.to.depreciationRun(depreciationRunId));++ return (+ <ConfirmDelete+ action={path.to.deleteDepreciationRun(depreciationRunId)}+ name={run.depreciationRunId}+ text={`Are you sure you want to delete ${run.depreciationRunId}? This cannot be undone.`}+ onCancel={onCancel}+ />+ );+}diff --git a/apps/erp/app/routes/x+/depreciation-run+/$depreciationRunId.post.tsx b/apps/erp/app/routes/x+/depreciation-run+/$depreciationRunId.post.tsxnew file mode 100644index 0000000000..3942c59bf5--- /dev/null+++ b/apps/erp/app/routes/x+/depreciation-run+/$depreciationRunId.post.tsx@@ -0,0 +1,186 @@+import { assertIsPost, error, success } from "@carbon/auth";+import { requirePermissions } from "@carbon/auth/auth.server";+import { flash } from "@carbon/auth/session.server";+import type { ActionFunctionArgs } from "react-router";+import { redirect } from "react-router";+import { getOrCreateAccountingPeriod } from "~/modules/accounting";+import { postDepreciationRun } from "~/modules/accounting/accounting.server";+import { getDatabaseClient } from "~/services/database.server";+import { path } from "~/utils/path";++export async function action({ request, params }: ActionFunctionArgs) {+ assertIsPost(request);+ const { client, companyId, companyGroupId, userId } =+ await requirePermissions(request, {+ update: "accounting"+ });++ const { depreciationRunId } = params;+ if (!depreciationRunId) {+ throw redirect(+ path.to.depreciationRuns,+ await flash(request, error(null, "Missing depreciation run ID"))+ );+ }++ const run = await client+ .from("depreciationRun")+ .select("*")+ .eq("id", depreciationRunId)+ .eq("companyId", companyId)+ .single();++ if (run.error || run.data.status !== "Draft") {+ throw redirect(+ path.to.depreciationRun(depreciationRunId),+ await flash(request, error(run.error, "Run is not in Draft status"))+ );+ }++ const [companySettingsResult, accountDefaultsResult] = await Promise.all([+ client+ .from("companySettings")+ .select("assetTaxDepreciationEnabled, assetTaxRate")+ .eq("id", companyId)+ .single(),+ client+ .from("accountDefault")+ .select("deferredTaxLiabilityAccountId, deferredTaxExpenseAccountId")+ .eq("companyId", companyId)+ .single()+ ]);++ const taxEnabled =+ (companySettingsResult.data as any)?.assetTaxDepreciationEnabled ?? false;+ const taxRate = (companySettingsResult.data as any)?.assetTaxRate+ ? Number((companySettingsResult.data as any).assetTaxRate)+ : null;+ const dtlAccountId = (accountDefaultsResult.data as any)+ ?.deferredTaxLiabilityAccountId;+ const dtExpenseAccountId = (accountDefaultsResult.data as any)+ ?.deferredTaxExpenseAccountId;++ const [linesResult, dimensionsResult] = await Promise.all([+ client+ .from("depreciationRunLine")+ .select(+ "id, fixedAssetId, amount, taxAmount, fixedAsset:fixedAssetId(id, fixedAssetId, locationId, fixedAssetClassId, acquisitionCost, accumulatedDepreciation, accumulatedTaxDepreciation, residualValuePercent, usefulLifeMonths, fixedAssetClass:fixedAssetClassId(depreciationExpenseAccountId, accumulatedDepreciationAccountId))"+ )+ .eq("depreciationRunId", depreciationRunId),+ client+ .from("dimension")+ .select("id, entityType")+ .eq("companyGroupId", companyGroupId)+ .eq("active", true)+ ]);++ if (linesResult.error) {+ throw redirect(+ path.to.depreciationRun(depreciationRunId),+ await flash(+ request,+ error(linesResult.error, "Failed to fetch run lines")+ )+ );+ }++ const locationDimensionId = (dimensionsResult.data ?? []).find(+ (d) => d.entityType === "Location"+ )?.id;++ const assetClassDimensionId = (dimensionsResult.data ?? []).find(+ (d) => d.entityType === "FixedAssetClass"+ )?.id;++ const postingDate = run.data.periodEnd;++ const accountingPeriod = await getOrCreateAccountingPeriod(+ client,+ companyId,+ postingDate+ );+ if (accountingPeriod.error) {+ throw redirect(+ path.to.depreciationRun(depreciationRunId),+ await flash(+ request,+ error(accountingPeriod.error, "Failed to get accounting period")+ )+ );+ }++ // Validate all lines have required account configuration+ for (const line of linesResult.data) {+ const asset = line.fixedAsset as any;+ const assetClass = asset?.fixedAssetClass;+ if (+ !assetClass?.depreciationExpenseAccountId ||+ !assetClass?.accumulatedDepreciationAccountId+ ) {+ throw redirect(+ path.to.depreciationRun(depreciationRunId),+ await flash(+ request,+ error(+ null,+ `Asset ${asset?.fixedAssetId ?? line.fixedAssetId} is missing depreciation account configuration`+ )+ )+ );+ }+ }++ const lines = linesResult.data.map((line) => {+ const asset = line.fixedAsset as any;+ const assetClass = asset.fixedAssetClass;+ return {+ id: line.id,+ fixedAssetId: line.fixedAssetId,+ amount: Number(line.amount),+ taxAmount: Number((line as any).taxAmount ?? 0),+ asset: {+ fixedAssetId: asset.fixedAssetId as string,+ locationId: asset.locationId as string | null,+ fixedAssetClassId: asset.fixedAssetClassId as string,+ acquisitionCost: Number(asset.acquisitionCost),+ accumulatedDepreciation: Number(asset.accumulatedDepreciation),+ accumulatedTaxDepreciation: Number(+ asset.accumulatedTaxDepreciation ?? 0+ ),+ residualValuePercent: Number(asset.residualValuePercent),+ depreciationExpenseAccountId:+ assetClass.depreciationExpenseAccountId as string,+ accumulatedDepreciationAccountId:+ assetClass.accumulatedDepreciationAccountId as string+ }+ };+ });++ try {+ await postDepreciationRun(getDatabaseClient(), {+ depreciationRunId,+ depreciationRunReadableId: run.data.depreciationRunId,+ postingDate,+ accountingPeriodId: accountingPeriod.data!,+ lines,+ locationDimensionId,+ assetClassDimensionId,+ taxEnabled,+ taxRate,+ dtlAccountId,+ dtExpenseAccountId,+ companyId,+ userId+ });+ } catch (err) {+ throw redirect(+ path.to.depreciationRun(depreciationRunId),+ await flash(request, error(err, "Failed to post depreciation run"))+ );+ }++ throw redirect(+ path.to.depreciationRun(depreciationRunId),+ await flash(request, success("Depreciation run posted"))+ );+}diff --git a/apps/erp/app/routes/x+/depreciation-run+/$depreciationRunId.repeat.tsx b/apps/erp/app/routes/x+/depreciation-run+/$depreciationRunId.repeat.tsxnew file mode 100644index 0000000000..804c21a5be--- /dev/null+++ b/apps/erp/app/routes/x+/depreciation-run+/$depreciationRunId.repeat.tsx@@ -0,0 +1,222 @@+import { assertIsPost, error, success } from "@carbon/auth";+import { requirePermissions } from "@carbon/auth/auth.server";+import { flash } from "@carbon/auth/session.server";+import type { ActionFunctionArgs } from "react-router";+import { redirect } from "react-router";+import { buildDepreciationLines } from "~/modules/accounting/accounting.utils";+import { getNextSequence } from "~/modules/settings";+import { path } from "~/utils/path";++export async function action({ request, params }: ActionFunctionArgs) {+ assertIsPost(request);+ const { client, companyId, userId } = await requirePermissions(request, {+ create: "accounting"+ });++ const { depreciationRunId } = params;+ if (!depreciationRunId) {+ throw redirect(+ path.to.depreciationRuns,+ await flash(request, error(null, "Missing depreciation run ID"))+ );+ }++ // Get the source run to find its period+ const sourceRun = await client+ .from("depreciationRun")+ .select("periodEnd, status")+ .eq("id", depreciationRunId)+ .single();++ if (sourceRun.error) {+ throw redirect(+ path.to.depreciationRun(depreciationRunId),+ await flash(request, error(sourceRun.error, "Failed to load source run"))+ );+ }++ if (sourceRun.data.status !== "Posted") {+ throw redirect(+ path.to.depreciationRun(depreciationRunId),+ await flash(request, error(null, "Only posted runs can be repeated"))+ );+ }++ const periodEnd = sourceRun.data.periodEnd;++ // Find all assets already covered by runs for this period+ const runsForPeriod = await client+ .from("depreciationRun")+ .select("id")+ .eq("companyId", companyId)+ .eq("periodEnd", periodEnd);++ const runIdsForPeriod = (runsForPeriod.data ?? []).map((r) => r.id);++ let coveredAssetIds = new Set<string>();+ if (runIdsForPeriod.length > 0) {+ const existingLines = await client+ .from("depreciationRunLine")+ .select("fixedAssetId")+ .in("depreciationRunId", runIdsForPeriod);++ coveredAssetIds = new Set(+ (existingLines.data ?? []).map((l) => l.fixedAssetId)+ );+ }++ const companySettings = await client+ .from("companySettings")+ .select("assetTaxDepreciationEnabled")+ .eq("id", companyId)+ .single();++ const taxEnabled =+ (companySettings.data as any)?.assetTaxDepreciationEnabled ?? false;++ // Get all active assets+ const assets = await client+ .from("fixedAsset")+ .select("*")+ .eq("companyId", companyId)+ .eq("status", "Active");++ if (assets.error) {+ throw redirect(+ path.to.depreciationRuns,+ await flash(request, error(assets.error, "Failed to fetch assets"))+ );+ }++ // Filter to only uncovered assets+ const uncoveredAssets = (assets.data ?? []).filter(+ (a) => !coveredAssetIds.has(a.id)+ );++ if (uncoveredAssets.length === 0) {+ throw redirect(+ path.to.depreciationRun(depreciationRunId),+ await flash(+ request,+ error(null, "All active assets are already covered for this period")+ )+ );+ }++ // Use last posted run before this period for calculation baseline+ const lastPostedRun = await client+ .from("depreciationRun")+ .select("periodEnd")+ .eq("companyId", companyId)+ .eq("status", "Posted")+ .lt("periodEnd", periodEnd)+ .order("periodEnd", { ascending: false })+ .limit(1);++ const lastPostedPeriodEnd =+ lastPostedRun.data && lastPostedRun.data.length > 0+ ? lastPostedRun.data[0].periodEnd+ : null;++ const usageLogs = await client+ .from("fixedAssetUsageLog")+ .select("fixedAssetId, unitsProduced")+ .eq("periodEnd", periodEnd);++ const usageMap = new Map(+ (usageLogs.data ?? []).map((u) => [u.fixedAssetId, u])+ );++ const lines = buildDepreciationLines(+ uncoveredAssets.map((a) => ({+ ...a,+ accumulatedTaxDepreciation: Number(+ (a as any).accumulatedTaxDepreciation ?? 0+ ),+ taxDepreciationMethod: (a as any).taxDepreciationMethod ?? null,+ taxUsefulLifeMonths: (a as any).taxUsefulLifeMonths ?? null,+ taxResidualValuePercent: (a as any).taxResidualValuePercent ?? null,+ macrsPropertyClass: (a as any).macrsPropertyClass ?? null,+ macrsConvention: (a as any).macrsConvention ?? null,+ bonusDepreciationPercent: (a as any).bonusDepreciationPercent ?? null+ })),+ periodEnd,+ lastPostedPeriodEnd,+ taxEnabled,+ usageMap+ );++ if (lines.length === 0) {+ throw redirect(+ path.to.depreciationRun(depreciationRunId),+ await flash(+ request,+ error(null, "No depreciation to calculate for uncovered assets")+ )+ );+ }++ const nextSequence = await getNextSequence(+ client,+ "depreciationRun",+ companyId+ );+ if (nextSequence.error) {+ throw redirect(+ path.to.depreciationRuns,+ await flash(+ request,+ error(nextSequence.error, "Failed to generate run ID")+ )+ );+ }++ const run = await client+ .from("depreciationRun")+ .insert({+ depreciationRunId: nextSequence.data,+ periodEnd,+ status: "Draft",+ companyId,+ createdBy: userId+ })+ .select("id")+ .single();++ if (run.error) {+ throw redirect(+ path.to.depreciationRuns,+ await flash(+ request,+ error(run.error, "Failed to create repeat depreciation run")+ )+ );+ }++ const lineInserts = lines.map((line) => ({+ depreciationRunId: run.data.id,+ fixedAssetId: line.fixedAssetId,+ amount: line.amount,+ taxAmount: line.taxAmount,+ companyId+ }));++ const lineResult = await client+ .from("depreciationRunLine")+ .insert(lineInserts);++ if (lineResult.error) {+ throw redirect(+ path.to.depreciationRuns,+ await flash(+ request,+ error(lineResult.error, "Failed to create run lines")+ )+ );+ }++ throw redirect(+ path.to.depreciationRun(run.data.id),+ await flash(request, success("Repeat depreciation run created"))+ );+}diff --git a/apps/erp/app/routes/x+/depreciation-run+/$depreciationRunId.tsx b/apps/erp/app/routes/x+/depreciation-run+/$depreciationRunId.tsxnew file mode 100644index 0000000000..4316604adb--- /dev/null+++ b/apps/erp/app/routes/x+/depreciation-run+/$depreciationRunId.tsx@@ -0,0 +1,308 @@+import { error } from "@carbon/auth";+import { requirePermissions } from "@carbon/auth/auth.server";+import { flash } from "@carbon/auth/session.server";+import {+ Button,+ Card,+ CardContent,+ CardHeader,+ Copy,+ DropdownMenu,+ DropdownMenuContent,+ DropdownMenuIcon,+ DropdownMenuItem,+ DropdownMenuTrigger,+ Heading,+ HStack,+ IconButton,+ useDisclosure+} from "@carbon/react";+import { formatDate } from "@carbon/utils";+import { LuEllipsisVertical, LuRepeat, LuTrash } from "react-icons/lu";+import type { LoaderFunctionArgs } from "react-router";+import {+ Link,+ Outlet,+ redirect,+ useFetcher,+ useLoaderData,+ useNavigate,+ useParams+} from "react-router";+import { Confirm, ConfirmDelete } from "~/components/Modals";+import { usePermissions, useSettings, useUser } from "~/hooks";+import { useCurrencyFormatter } from "~/hooks/useCurrencyFormatter";+import {+ getDepreciationRun,+ getDepreciationRunLines+} from "~/modules/accounting";+import { DepreciationRunStatus } from "~/modules/accounting/ui/FixedAssets";+import type { Handle } from "~/utils/handle";+import { path } from "~/utils/path";++export const handle: Handle = {+ breadcrumb: "Depreciation",+ to: path.to.depreciationRuns+};++export async function loader({ request, params }: LoaderFunctionArgs) {+ const { client } = await requirePermissions(request, {+ view: "accounting"+ });++ const { depreciationRunId } = params;+ if (!depreciationRunId) throw new Error("Could not find depreciationRunId");++ const [run, lines] = await Promise.all([+ getDepreciationRun(client, depreciationRunId),+ getDepreciationRunLines(client, depreciationRunId)+ ]);++ if (run.error) {+ throw redirect(+ path.to.depreciationRuns,+ await flash(request, error(run.error, "Failed to load depreciation run"))+ );+ }++ return {+ run: run.data,+ lines: lines.data ?? []+ };+}++export default function DepreciationRunDetailRoute() {+ const { depreciationRunId } = useParams();+ const { run, lines } = useLoaderData<typeof loader>();+ const settings = useSettings();+ const taxDepreciationEnabled =+ (settings as any).assetTaxDepreciationEnabled ?? false;+ const permissions = usePermissions();+ const navigate = useNavigate();+ const fetcher = useFetcher();+ const { company } = useUser();+ const currencyFormatter = useCurrencyFormatter({+ currency: company.baseCurrencyCode+ });+ const deleteModal = useDisclosure();+ const repeatModal = useDisclosure();++ if (!depreciationRunId) throw new Error("Could not find depreciationRunId");++ const isDraft = run.status === "Draft";+ const isPosted = run.status === "Posted";+ const totalAmount = lines.reduce((sum, line) => sum + Number(line.amount), 0);+ const totalTaxAmount = taxDepreciationEnabled+ ? lines.reduce((sum, line) => sum + Number((line as any).taxAmount ?? 0), 0)+ : 0;++ const gridCols = taxDepreciationEnabled+ ? "grid-cols-[auto_1fr_1fr_120px_120px_120px_120px_120px]"+ : "grid-cols-[auto_1fr_1fr_120px_120px_120px_120px]";++ return (+ <div className="flex h-[calc(100dvh-49px)] overflow-y-auto scrollbar-hide w-full">+ <div className="h-full p-4 pb-16 w-full max-w-5xl mx-auto">+ <Card>+ <CardHeader className="flex-row items-center justify-between">+ <HStack>+ <Heading as="h1" size="h3">+ {run.depreciationRunId}+ </Heading>+ <Copy text={run.depreciationRunId} />+ {(isDraft || isPosted) && (+ <DropdownMenu>+ <DropdownMenuTrigger asChild>+ <IconButton+ aria-label="More options"+ icon={<LuEllipsisVertical />}+ variant="secondary"+ size="sm"+ />+ </DropdownMenuTrigger>+ <DropdownMenuContent>+ {isPosted && (+ <DropdownMenuItem+ disabled={!permissions.can("create", "accounting")}+ onClick={repeatModal.onOpen}+ >+ <DropdownMenuIcon icon={<LuRepeat />} />+ Repeat Run+ </DropdownMenuItem>+ )}+ {isDraft && (+ <DropdownMenuItem+ disabled={!permissions.can("delete", "accounting")}+ destructive+ onClick={deleteModal.onOpen}+ >+ <DropdownMenuIcon icon={<LuTrash />} />+ Delete+ </DropdownMenuItem>+ )}+ </DropdownMenuContent>+ </DropdownMenu>+ )}+ <DepreciationRunStatus status={run.status} />+ </HStack>+ <HStack>+ {isDraft && permissions.can("update", "accounting") && (+ <fetcher.Form method="post" action="post">+ <Button+ variant="primary"+ type="submit"+ isLoading={fetcher.state !== "idle"}+ >+ Post Run+ </Button>+ </fetcher.Form>+ )}+ </HStack>+ </CardHeader>++ <CardContent>+ <div className="grid gap-4 grid-cols-1 md:grid-cols-3 w-full mb-6">+ <div>+ <p className="text-sm text-muted-foreground">Period End</p>+ <p className="text-sm">{formatDate(run.periodEnd)}</p>+ </div>+ {run.postedAt && (+ <div>+ <p className="text-sm text-muted-foreground">Posted At</p>+ <p className="text-sm">{formatDate(run.postedAt)}</p>+ </div>+ )}+ </div>++ {/* Depreciation Lines */}+ <div className="rounded-lg border border-border overflow-hidden w-full">+ {/* Column Headers */}+ <div+ className={`grid ${gridCols} items-center gap-3 px-4 py-2.5 text-sm text-muted-foreground font-medium bg-muted/50 border-b border-border`}+ >+ <div className="w-6" />+ <div>Asset</div>+ <div>Name</div>+ <div className="text-right">Cost</div>+ <div className="text-right">Accum. Depr.</div>+ <div className="text-right">Amount</div>+ {taxDepreciationEnabled && (+ <div className="text-right">Tax Amount</div>+ )}+ <div className="text-right">NBV After</div>+ </div>++ {/* Lines */}+ <div className="divide-y divide-border">+ {lines.length === 0 ? (+ <div className="px-4 py-6 text-sm text-muted-foreground text-center">+ No assets to depreciate for this period.+ </div>+ ) : (+ lines.map((line, index) => {+ const asset = line.fixedAsset as any;+ const cost = Number(asset?.acquisitionCost ?? 0);+ const accDepr = Number(asset?.accumulatedDepreciation ?? 0);+ const nbvAfter = cost - accDepr - Number(line.amount);+ return (+ <div+ key={line.id}+ className={`grid ${gridCols} items-center gap-3 px-4 py-2.5 text-sm hover:bg-muted/30 transition-colors`}+ >+ <div className="w-6 text-muted-foreground tabular-nums">+ {index + 1}+ </div>+ <div>+ {asset?.id ? (+ <Link+ to={path.to.fixedAsset(asset.id)}+ className="text-foreground hover:underline"+ >+ {asset.fixedAssetId ?? "—"}+ </Link>+ ) : (+ "—"+ )}+ </div>+ <div className="text-muted-foreground">+ {asset?.name ?? "—"}+ </div>+ <div className="text-right tabular-nums">+ {currencyFormatter.format(cost)}+ </div>+ <div className="text-right tabular-nums">+ {currencyFormatter.format(accDepr)}+ </div>+ <div className="text-right tabular-nums font-medium">+ {currencyFormatter.format(Number(line.amount))}+ </div>+ {taxDepreciationEnabled && (+ <div className="text-right tabular-nums font-medium">+ {currencyFormatter.format(+ Number((line as any).taxAmount ?? 0)+ )}+ </div>+ )}+ <div className="text-right tabular-nums">+ {currencyFormatter.format(nbvAfter)}+ </div>+ </div>+ );+ })+ )}+ </div>++ {/* Totals */}+ {lines.length > 0 && (+ <div+ className={`grid ${gridCols} items-center gap-3 px-4 py-3 bg-muted/50 border-t border-border`}+ >+ <div className="w-6" />+ <div className="text-sm font-medium">+ {lines.length} {lines.length === 1 ? "Asset" : "Assets"}+ </div>+ <div />+ <div />+ <div />+ <div className="text-right font-mono text-sm tabular-nums font-medium">+ {currencyFormatter.format(totalAmount)}+ </div>+ {taxDepreciationEnabled && (+ <div className="text-right font-mono text-sm tabular-nums font-medium">+ {currencyFormatter.format(totalTaxAmount)}+ </div>+ )}+ <div />+ </div>+ )}+ </div>+ </CardContent>+ </Card>++ <Outlet />++ <ConfirmDelete+ action={path.to.deleteDepreciationRun(depreciationRunId)}+ isOpen={deleteModal.isOpen}+ name={run.depreciationRunId}+ text={`Are you sure you want to delete ${run.depreciationRunId}? This cannot be undone.`}+ onCancel={deleteModal.onClose}+ onSubmit={() => {+ deleteModal.onClose();+ navigate(path.to.depreciationRuns);+ }}+ />++ <Confirm+ action={path.to.repeatDepreciationRun(depreciationRunId)}+ isOpen={repeatModal.isOpen}+ title="Repeat Run"+ text={`This will create a new draft depreciation run for the same period (${formatDate(run.periodEnd)}), including only active assets not already covered by an existing run.`}+ confirmText="Create Repeat Run"+ onCancel={repeatModal.onClose}+ onSubmit={repeatModal.onClose}+ />+ </div>+ </div>+ );+}diff --git a/apps/erp/app/routes/x+/depreciation-run+/_layout.tsx b/apps/erp/app/routes/x+/depreciation-run+/_layout.tsxnew file mode 100644index 0000000000..6ab429d8f8--- /dev/null+++ b/apps/erp/app/routes/x+/depreciation-run+/_layout.tsx@@ -0,0 +1,18 @@+import type { MetaFunction } from "react-router";+import { Outlet } from "react-router";+import type { Handle } from "~/utils/handle";+import { path } from "~/utils/path";++export const meta: MetaFunction = () => {+ return [{ title: "Carbon | Depreciation Run" }];+};++export const handle: Handle = {+ breadcrumb: "Accounting",+ to: path.to.depreciationRuns,+ module: "accounting"+};++export default function DepreciationRunLayout() {+ return <Outlet />;+}diff --git a/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.delete.tsx b/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.delete.tsxnew file mode 100644index 0000000000..09029f818c--- /dev/null+++ b/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.delete.tsx@@ -0,0 +1,75 @@+import { error, notFound, success } from "@carbon/auth";+import { requirePermissions } from "@carbon/auth/auth.server";+import { flash } from "@carbon/auth/session.server";+import type { ActionFunctionArgs, LoaderFunctionArgs } from "react-router";+import { redirect, useLoaderData, useNavigate, useParams } from "react-router";+import { ConfirmDelete } from "~/components/Modals";+import { deleteFixedAsset, getFixedAsset } from "~/modules/accounting";+import { path } from "~/utils/path";++export async function loader({ request, params }: LoaderFunctionArgs) {+ const { client } = await requirePermissions(request, {+ view: "accounting",+ role: "employee"+ });++ const { fixedAssetId } = params;+ if (!fixedAssetId) throw notFound("fixedAssetId not found");++ const asset = await getFixedAsset(client, fixedAssetId);+ if (asset.error) {+ throw redirect(+ path.to.fixedAssets,+ await flash(request, error(asset.error, "Failed to get fixed asset"))+ );+ }++ return { asset: asset.data };+}++export async function action({ request, params }: ActionFunctionArgs) {+ const { client } = await requirePermissions(request, {+ delete: "accounting"+ });++ const { fixedAssetId } = params;+ if (!fixedAssetId) {+ throw redirect(+ path.to.fixedAssets,+ await flash(request, error(params, "Failed to get fixed asset id"))+ );+ }++ const { error: deleteError } = await deleteFixedAsset(client, fixedAssetId);+ if (deleteError) {+ throw redirect(+ path.to.fixedAssets,+ await flash(request, error(deleteError, "Failed to delete fixed asset"))+ );+ }++ throw redirect(+ path.to.fixedAssets,+ await flash(request, success("Successfully deleted fixed asset"))+ );+}++export default function DeleteFixedAssetRoute() {+ const { fixedAssetId } = useParams();+ const { asset } = useLoaderData<typeof loader>();+ const navigate = useNavigate();++ if (!asset) return null;+ if (!fixedAssetId) throw new Error("fixedAssetId is not found");++ const onCancel = () => navigate(path.to.fixedAsset(fixedAssetId));++ return (+ <ConfirmDelete+ action={path.to.deleteFixedAsset(fixedAssetId)}+ name={asset.fixedAssetId}+ text={`Are you sure you want to delete ${asset.fixedAssetId}? This cannot be undone.`}+ onCancel={onCancel}+ />+ );+}diff --git a/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.details.tsx b/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.details.tsxnew file mode 100644index 0000000000..0fffbd3833--- /dev/null+++ b/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.details.tsx@@ -0,0 +1,111 @@+import { assertIsPost, error, notFound, success } from "@carbon/auth";+import { requirePermissions } from "@carbon/auth/auth.server";+import { flash } from "@carbon/auth/session.server";+import { validationError, validator } from "@carbon/form";+import type { ActionFunctionArgs, LoaderFunctionArgs } from "react-router";+import { redirect, useLoaderData, useNavigate } from "react-router";+import {+ fixedAssetValidator,+ getFixedAsset,+ upsertFixedAsset+} from "~/modules/accounting";+import { FixedAssetForm } from "~/modules/accounting/ui/FixedAssets";+import { path } from "~/utils/path";++export async function loader({ request, params }: LoaderFunctionArgs) {+ const { client } = await requirePermissions(request, {+ view: "accounting"+ });++ const { fixedAssetId } = params;+ if (!fixedAssetId) throw notFound("fixedAssetId not found");++ const asset = await getFixedAsset(client, fixedAssetId);++ if (asset.error) {+ throw redirect(+ path.to.fixedAssets,+ await flash(request, error(asset.error, "Failed to get fixed asset"))+ );+ }++ return {+ asset: asset.data+ };+}++export async function action({ request, params }: ActionFunctionArgs) {+ assertIsPost(request);+ const { client, userId } = await requirePermissions(request, {+ update: "accounting"+ });++ const formData = await request.formData();+ const validation = await validator(fixedAssetValidator).validate(formData);++ if (validation.error) {+ return validationError(validation.error);+ }++ const { id, ...d } = validation.data;+ if (!id) throw notFound("Fixed Asset ID was not found");++ const result = await upsertFixedAsset(client, {+ id,+ ...d,+ updatedBy: userId+ });++ if (result.error) {+ throw redirect(+ path.to.fixedAssets,+ await flash(request, error(result.error, "Failed to update fixed asset"))+ );+ }++ const { fixedAssetId } = params;+ throw redirect(+ path.to.fixedAsset(fixedAssetId!),+ await flash(request, success("Fixed asset updated"))+ );+}++export default function FixedAssetDetailsRoute() {+ const { asset } = useLoaderData<typeof loader>();+ const navigate = useNavigate();++ const initialValues = {+ id: asset.id,+ fixedAssetClassId: asset.fixedAssetClassId,+ name: asset.name,+ description: asset.description ?? "",+ serialNumber: asset.serialNumber ?? "",+ depreciationMethod: asset.depreciationMethod,+ usefulLifeMonths: asset.usefulLifeMonths,+ residualValuePercent: Number(asset.residualValuePercent),+ assetLifetimeUsage: asset.assetLifetimeUsage+ ? Number(asset.assetLifetimeUsage)+ : undefined,+ locationId: asset.locationId ?? undefined,+ taxDepreciationMethod: (asset as any).taxDepreciationMethod ?? undefined,+ taxUsefulLifeMonths: (asset as any).taxUsefulLifeMonths ?? undefined,+ taxResidualValuePercent:+ (asset as any).taxResidualValuePercent != null+ ? Number((asset as any).taxResidualValuePercent)+ : undefined,+ macrsPropertyClass: (asset as any).macrsPropertyClass ?? undefined,+ macrsConvention: (asset as any).macrsConvention ?? undefined,+ bonusDepreciationPercent:+ (asset as any).bonusDepreciationPercent != null+ ? Number((asset as any).bonusDepreciationPercent)+ : undefined+ };++ return (+ <FixedAssetForm+ onClose={() => navigate(-1)}+ key={initialValues.id}+ initialValues={initialValues}+ />+ );+}diff --git a/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.dispose.tsx b/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.dispose.tsxnew file mode 100644index 0000000000..1e146aba52--- /dev/null+++ b/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.dispose.tsx@@ -0,0 +1,165 @@+import { assertIsPost, error, notFound, success } from "@carbon/auth";+import { requirePermissions } from "@carbon/auth/auth.server";+import { flash } from "@carbon/auth/session.server";+import { validationError, validator } from "@carbon/form";+import type { ActionFunctionArgs, LoaderFunctionArgs } from "react-router";+import { redirect, useLoaderData, useNavigate } from "react-router";+import {+ fixedAssetDisposalValidator,+ getFixedAsset,+ getOrCreateAccountingPeriod+} from "~/modules/accounting";+import { postDisposal } from "~/modules/accounting/accounting.server";+import { FixedAssetDisposalForm } from "~/modules/accounting/ui/FixedAssets";+import { getDatabaseClient } from "~/services/database.server";+import { path } from "~/utils/path";++export async function loader({ request, params }: LoaderFunctionArgs) {+ const { client } = await requirePermissions(request, {+ view: "accounting"+ });++ const { fixedAssetId } = params;+ if (!fixedAssetId) throw notFound("fixedAssetId not found");++ const asset = await getFixedAsset(client, fixedAssetId);+ if (asset.error) {+ throw redirect(+ path.to.fixedAssets,+ await flash(request, error(asset.error, "Failed to get fixed asset"))+ );+ }++ if (+ asset.data.status !== "Active" &&+ asset.data.status !== "Fully Depreciated"+ ) {+ throw redirect(+ path.to.fixedAsset(fixedAssetId),+ await flash(+ request,+ error(null, "Only Active or Fully Depreciated assets can be disposed")+ )+ );+ }++ const nbv =+ Number(asset.data.acquisitionCost) -+ Number(asset.data.accumulatedDepreciation);++ return { asset: asset.data, currentNBV: nbv };+}++export async function action({ request, params }: ActionFunctionArgs) {+ assertIsPost(request);+ const { client, companyId, companyGroupId, userId } =+ await requirePermissions(request, {+ update: "accounting"+ });++ const { fixedAssetId } = params;+ if (!fixedAssetId) throw notFound("fixedAssetId not found");++ const formData = await request.formData();+ const validation = await validator(fixedAssetDisposalValidator).validate(+ formData+ );++ if (validation.error) {+ return validationError(validation.error);+ }++ const { disposalDate } = validation.data;+ const disposalMethod = "Scrapping";++ const [asset, dimensionsResult] = await Promise.all([+ client+ .from("fixedAsset")+ .select("*, fixedAssetClass:fixedAssetClassId(*)")+ .eq("id", fixedAssetId)+ .single(),+ client+ .from("dimension")+ .select("id, entityType")+ .eq("companyGroupId", companyGroupId)+ .eq("active", true)+ ]);++ if (asset.error) {+ throw redirect(+ path.to.fixedAsset(fixedAssetId),+ await flash(request, error(asset.error, "Failed to get asset"))+ );+ }++ const assetClass = asset.data.fixedAssetClass as any;+ const acquisitionCost = Number(asset.data.acquisitionCost);+ const accumulatedDepreciation = Number(asset.data.accumulatedDepreciation);++ const accountingPeriod = await getOrCreateAccountingPeriod(+ client,+ companyId,+ disposalDate+ );+ if (accountingPeriod.error) {+ throw redirect(+ path.to.fixedAsset(fixedAssetId),+ await flash(+ request,+ error(accountingPeriod.error, "Failed to get accounting period")+ )+ );+ }++ const locationDimensionId = (dimensionsResult.data ?? []).find(+ (d) => d.entityType === "Location"+ )?.id;++ const assetClassDimensionId = (dimensionsResult.data ?? []).find(+ (d) => d.entityType === "FixedAssetClass"+ )?.id;++ try {+ await postDisposal(getDatabaseClient(), {+ fixedAssetId,+ fixedAssetReadableId: asset.data.fixedAssetId,+ disposalDate,+ disposalMethod,+ acquisitionCost,+ accumulatedDepreciation,+ locationId: asset.data.locationId,+ fixedAssetClassId: asset.data.fixedAssetClassId,+ assetAccountId: assetClass.assetAccountId,+ accumulatedDepreciationAccountId:+ assetClass.accumulatedDepreciationAccountId,+ writeOffAccountId: assetClass.writeOffAccountId,+ accountingPeriodId: accountingPeriod.data!,+ locationDimensionId,+ assetClassDimensionId,+ companyId,+ userId+ });+ } catch (err) {+ throw redirect(+ path.to.fixedAsset(fixedAssetId),+ await flash(request, error(err, "Failed to post asset disposal"))+ );+ }++ throw redirect(+ path.to.fixedAsset(fixedAssetId),+ await flash(request, success("Asset disposed successfully"))+ );+}++export default function DisposeFixedAssetRoute() {+ const { currentNBV } = useLoaderData<typeof loader>();+ const navigate = useNavigate();++ return (+ <FixedAssetDisposalForm+ currentNBV={currentNBV}+ onClose={() => navigate(-1)}+ />+ );+}diff --git a/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.purchase.tsx b/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.purchase.tsxnew file mode 100644index 0000000000..e0572b329c--- /dev/null+++ b/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.purchase.tsx@@ -0,0 +1,190 @@+import { assertIsPost, error, notFound, success } from "@carbon/auth";+import { requirePermissions } from "@carbon/auth/auth.server";+import { flash } from "@carbon/auth/session.server";+import { ValidatedForm, validationError, validator } from "@carbon/form";+import {+ Button,+ HStack,+ Modal,+ ModalBody,+ ModalContent,+ ModalFooter,+ ModalHeader,+ ModalTitle,+ VStack+} from "@carbon/react";+import type { ActionFunctionArgs, LoaderFunctionArgs } from "react-router";+import { redirect, useNavigate } from "react-router";+import { z } from "zod";+import { Submit, Supplier } from "~/components/Form";+import { usePermissions } from "~/hooks";+import { getFixedAsset } from "~/modules/accounting";+import {+ upsertPurchaseOrder,+ upsertPurchaseOrderLine+} from "~/modules/purchasing";+import { getNextSequence } from "~/modules/settings";+import { getUserDefaults } from "~/modules/users/users.server";+import { path } from "~/utils/path";++const purchaseAssetValidator = z.object({+ supplierId: z.string().min(1, { message: "Supplier is required" })+});++export async function loader({ request, params }: LoaderFunctionArgs) {+ const { client } = await requirePermissions(request, {+ view: "accounting"+ });++ const { fixedAssetId } = params;+ if (!fixedAssetId) throw notFound("fixedAssetId not found");++ const asset = await getFixedAsset(client, fixedAssetId);+ if (asset.error) {+ throw redirect(+ path.to.fixedAssets,+ await flash(request, error(asset.error, "Failed to get fixed asset"))+ );+ }++ if (asset.data.status !== "Draft") {+ throw redirect(+ path.to.fixedAsset(fixedAssetId),+ await flash(request, error(null, "Only Draft assets can be purchased"))+ );+ }++ return null;+}++export async function action({ request, params }: ActionFunctionArgs) {+ assertIsPost(request);+ const { client, companyId, companyGroupId, userId } =+ await requirePermissions(request, {+ create: "purchasing"+ });++ const { fixedAssetId } = params;+ if (!fixedAssetId) throw notFound("fixedAssetId not found");++ const formData = await request.formData();+ const validation = await validator(purchaseAssetValidator).validate(formData);++ if (validation.error) {+ return validationError(validation.error);+ }++ const { supplierId } = validation.data;++ const [asset, defaults] = await Promise.all([+ getFixedAsset(client, fixedAssetId),+ getUserDefaults(client, userId, companyId)+ ]);++ if (asset.error || !asset.data) {+ throw redirect(+ path.to.fixedAssets,+ await flash(request, error(asset.error, "Failed to get fixed asset"))+ );+ }++ const locationId = asset.data.locationId ?? defaults.data?.locationId ?? "";++ const nextSequence = await getNextSequence(+ client,+ "purchaseOrder",+ companyId+ );+ if (nextSequence.error) {+ throw redirect(+ path.to.fixedAsset(fixedAssetId),+ await flash(+ request,+ error(nextSequence.error, "Failed to get next sequence")+ )+ );+ }++ const newPO = await upsertPurchaseOrder(client, {+ purchaseOrderId: nextSequence.data!,+ supplierId,+ locationId,+ status: "Draft",+ purchaseOrderType: "Purchase",+ companyId,+ companyGroupId,+ createdBy: userId+ });++ if (newPO.error || !newPO.data?.[0]) {+ throw redirect(+ path.to.fixedAsset(fixedAssetId),+ await flash(+ request,+ error(newPO.error, "Failed to create purchase order")+ )+ );+ }++ const purchaseOrderId = newPO.data[0].id;++ await upsertPurchaseOrderLine(client, {+ purchaseOrderId,+ purchaseOrderLineType: "Fixed Asset",+ assetId: fixedAssetId,+ description: asset.data.name,+ locationId,+ purchaseQuantity: 1,+ supplierUnitPrice: 0,+ supplierShippingCost: 0,+ supplierTaxAmount: 0,+ exchangeRate: 1,+ purchaseUnitOfMeasureCode: "EA",+ inventoryUnitOfMeasureCode: "EA",+ conversionFactor: 1,+ companyId,+ createdBy: userId+ });++ throw redirect(+ path.to.purchaseOrder(purchaseOrderId),+ await flash(request, success("Purchase order created"))+ );+}++export default function PurchaseFixedAssetRoute() {+ const navigate = useNavigate();+ const permissions = usePermissions();++ return (+ <Modal+ open+ onOpenChange={(open) => {+ if (!open) navigate(-1);+ }}+ >+ <ModalContent>+ <ValidatedForm validator={purchaseAssetValidator} method="post">+ <ModalHeader>+ <ModalTitle>Purchase Asset</ModalTitle>+ </ModalHeader>+ <ModalBody>+ <VStack spacing={4}>+ <Supplier name="supplierId" label="Supplier" />+ </VStack>+ </ModalBody>+ <ModalFooter>+ <HStack>+ <Submit isDisabled={!permissions.can("create", "purchasing")}>+ Create Purchase Order+ </Submit>+ <Button size="md" variant="solid" onClick={() => navigate(-1)}>+ Cancel+ </Button>+ </HStack>+ </ModalFooter>+ </ValidatedForm>+ </ModalContent>+ </Modal>+ );+}diff --git a/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.register.tsx b/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.register.tsxnew file mode 100644index 0000000000..491163ea07--- /dev/null+++ b/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.register.tsx@@ -0,0 +1,85 @@+import { assertIsPost, error, notFound, success } from "@carbon/auth";+import { requirePermissions } from "@carbon/auth/auth.server";+import { flash } from "@carbon/auth/session.server";+import { validationError, validator } from "@carbon/form";+import type { ActionFunctionArgs, LoaderFunctionArgs } from "react-router";+import { redirect, useNavigate } from "react-router";+import {+ fixedAssetRegisterValidator,+ getFixedAsset+} from "~/modules/accounting";+import { FixedAssetRegisterForm } from "~/modules/accounting/ui/FixedAssets";+import { path } from "~/utils/path";++export async function loader({ request, params }: LoaderFunctionArgs) {+ const { client } = await requirePermissions(request, {+ view: "accounting"+ });++ const { fixedAssetId } = params;+ if (!fixedAssetId) throw notFound("fixedAssetId not found");++ const asset = await getFixedAsset(client, fixedAssetId);+ if (asset.error) {+ throw redirect(+ path.to.fixedAssets,+ await flash(request, error(asset.error, "Failed to get fixed asset"))+ );+ }++ if (asset.data.status !== "Draft") {+ throw redirect(+ path.to.fixedAsset(fixedAssetId),+ await flash(request, error(null, "Only Draft assets can be registered"))+ );+ }++ return null;+}++export async function action({ request, params }: ActionFunctionArgs) {+ assertIsPost(request);+ const { client, userId } = await requirePermissions(request, {+ update: "accounting"+ });++ const { fixedAssetId } = params;+ if (!fixedAssetId) throw notFound("fixedAssetId not found");++ const formData = await request.formData();+ const validation = await validator(fixedAssetRegisterValidator).validate(+ formData+ );++ if (validation.error) {+ return validationError(validation.error);+ }++ const result = await client+ .from("fixedAsset")+ .update({+ ...validation.data,+ status: "Active",+ updatedBy: userId+ })+ .eq("id", fixedAssetId)+ .eq("status", "Draft");++ if (result.error) {+ throw redirect(+ path.to.fixedAsset(fixedAssetId),+ await flash(request, error(result.error, "Failed to register asset"))+ );+ }++ throw redirect(+ path.to.fixedAsset(fixedAssetId),+ await flash(request, success("Asset registered successfully"))+ );+}++export default function RegisterFixedAssetRoute() {+ const navigate = useNavigate();++ return <FixedAssetRegisterForm onClose={() => navigate(-1)} />;+}diff --git a/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.sell.tsx b/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.sell.tsxnew file mode 100644index 0000000000..c79b9a4d22--- /dev/null+++ b/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.sell.tsx@@ -0,0 +1,186 @@+import { assertIsPost, error, notFound, success } from "@carbon/auth";+import { requirePermissions } from "@carbon/auth/auth.server";+import { flash } from "@carbon/auth/session.server";+import { ValidatedForm, validationError, validator } from "@carbon/form";+import {+ Button,+ HStack,+ Modal,+ ModalBody,+ ModalContent,+ ModalFooter,+ ModalHeader,+ ModalTitle,+ VStack+} from "@carbon/react";+import type { ActionFunctionArgs, LoaderFunctionArgs } from "react-router";+import { redirect, useNavigate } from "react-router";+import { z } from "zod";+import { Customer, Submit } from "~/components/Form";+import { usePermissions } from "~/hooks";+import { getFixedAsset } from "~/modules/accounting";+import { upsertSalesOrder } from "~/modules/sales";+import { getNextSequence } from "~/modules/settings";+import { getUserDefaults } from "~/modules/users/users.server";+import { path } from "~/utils/path";++const sellAssetValidator = z.object({+ customerId: z.string().min(1, { message: "Customer is required" })+});++export async function loader({ request, params }: LoaderFunctionArgs) {+ const { client } = await requirePermissions(request, {+ view: "accounting"+ });++ const { fixedAssetId } = params;+ if (!fixedAssetId) throw notFound("fixedAssetId not found");++ const asset = await getFixedAsset(client, fixedAssetId);+ if (asset.error) {+ throw redirect(+ path.to.fixedAssets,+ await flash(request, error(asset.error, "Failed to get fixed asset"))+ );+ }++ if (!["Active", "Fully Depreciated"].includes(asset.data.status)) {+ throw redirect(+ path.to.fixedAsset(fixedAssetId),+ await flash(request, error(null, "Only active assets can be sold"))+ );+ }++ return null;+}++export async function action({ request, params }: ActionFunctionArgs) {+ assertIsPost(request);+ const { client, companyId, companyGroupId, userId } =+ await requirePermissions(request, {+ create: "sales"+ });++ const { fixedAssetId } = params;+ if (!fixedAssetId) throw notFound("fixedAssetId not found");++ const formData = await request.formData();+ const validation = await validator(sellAssetValidator).validate(formData);++ if (validation.error) {+ return validationError(validation.error);+ }++ const { customerId } = validation.data;++ const [asset, defaults] = await Promise.all([+ getFixedAsset(client, fixedAssetId),+ getUserDefaults(client, userId, companyId)+ ]);++ if (asset.error || !asset.data) {+ throw redirect(+ path.to.fixedAssets,+ await flash(request, error(asset.error, "Failed to get fixed asset"))+ );+ }++ const nextSequence = await getNextSequence(client, "salesOrder", companyId);+ if (nextSequence.error) {+ throw redirect(+ path.to.fixedAsset(fixedAssetId),+ await flash(+ request,+ error(nextSequence.error, "Failed to get next sequence")+ )+ );+ }++ const locationId = asset.data.locationId ?? defaults.data?.locationId ?? "";++ const company = await client+ .from("company")+ .select("baseCurrencyCode")+ .eq("id", companyId)+ .single();++ const newSO = await upsertSalesOrder(client, {+ salesOrderId: nextSequence.data!,+ customerId,+ currencyCode: company.data?.baseCurrencyCode ?? "USD",+ locationId: locationId ?? "",+ status: "Draft",+ companyId,+ companyGroupId,+ createdBy: userId+ });++ if (newSO.error || !newSO.data?.[0]) {+ throw redirect(+ path.to.fixedAsset(fixedAssetId),+ await flash(request, error(newSO.error, "Failed to create sales order"))+ );+ }++ const salesOrderId = newSO.data[0].id;++ const nbv =+ Number(asset.data.acquisitionCost) -+ Number(asset.data.accumulatedDepreciation);++ await client.from("salesOrderLine").insert({+ salesOrderId,+ salesOrderLineType: "Fixed Asset",+ assetId: fixedAssetId,+ description: asset.data.name,+ saleQuantity: 1,+ unitPrice: nbv,+ locationId: asset.data.locationId ?? "",+ taxPercent: 0,+ exchangeRate: 1,+ companyId,+ createdBy: userId+ });++ throw redirect(+ path.to.salesOrder(salesOrderId),+ await flash(request, success("Sales order created"))+ );+}++export default function SellFixedAssetRoute() {+ const navigate = useNavigate();+ const permissions = usePermissions();++ return (+ <Modal+ open+ onOpenChange={(open) => {+ if (!open) navigate(-1);+ }}+ >+ <ModalContent>+ <ValidatedForm validator={sellAssetValidator} method="post">+ <ModalHeader>+ <ModalTitle>Sell Asset</ModalTitle>+ </ModalHeader>+ <ModalBody>+ <VStack spacing={4}>+ <Customer name="customerId" label="Customer" />+ </VStack>+ </ModalBody>+ <ModalFooter>+ <HStack>+ <Submit isDisabled={!permissions.can("create", "sales")}>+ Create Sales Order+ </Submit>+ <Button size="md" variant="solid" onClick={() => navigate(-1)}>+ Cancel+ </Button>+ </HStack>+ </ModalFooter>+ </ValidatedForm>+ </ModalContent>+ </Modal>+ );+}diff --git a/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.tsx b/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.tsxnew file mode 100644index 0000000000..42197663ab--- /dev/null+++ b/apps/erp/app/routes/x+/fixed-asset+/$fixedAssetId.tsx@@ -0,0 +1,515 @@+import { error } from "@carbon/auth";+import { requirePermissions } from "@carbon/auth/auth.server";+import { flash } from "@carbon/auth/session.server";+import type { JSONContent } from "@carbon/react";+import {+ Badge,+ BarProgress,+ Button,+ Card,+ CardContent,+ CardHeader,+ CardTitle,+ DropdownMenu,+ DropdownMenuContent,+ DropdownMenuIcon,+ DropdownMenuItem,+ DropdownMenuSeparator,+ DropdownMenuTrigger,+ useDisclosure+} from "@carbon/react";+import { formatDate } from "@carbon/utils";+import {+ LuChevronDown,+ LuCircleX,+ LuClipboardCheck,+ LuHistory,+ LuPencil,+ LuShoppingCart,+ LuStore,+ LuTrash+} from "react-icons/lu";+import type { LoaderFunctionArgs } from "react-router";+import {+ Link,+ Outlet,+ redirect,+ useLoaderData,+ useNavigate,+ useParams+} from "react-router";+import { DocumentHeader } from "~/components";+import { AuditLogDrawer } from "~/components/AuditLog";+import { Enumerable } from "~/components/Enumerable";+import { ConfirmDelete } from "~/components/Modals";+import { usePermissions, useSettings, useUser } from "~/hooks";+import { useCurrencyFormatter } from "~/hooks/useCurrencyFormatter";+import {+ getAssetDepreciationHistory,+ getFixedAsset,+ getFixedAssetDisposal+} from "~/modules/accounting";+import {+ DepreciationRunStatus,+ FixedAssetNotes,+ FixedAssetStatus+} from "~/modules/accounting/ui/FixedAssets";+import type { Handle } from "~/utils/handle";+import { path } from "~/utils/path";++export const handle: Handle = {+ breadcrumb: "Fixed Assets",+ to: path.to.fixedAssets+};++export async function loader({ request, params }: LoaderFunctionArgs) {+ const { client } = await requirePermissions(request, {+ view: "accounting"+ });++ const { fixedAssetId } = params;+ if (!fixedAssetId) throw new Error("Could not find fixedAssetId");++ const [asset, depreciationHistory, disposal] = await Promise.all([+ getFixedAsset(client, fixedAssetId),+ getAssetDepreciationHistory(client, fixedAssetId),+ getFixedAssetDisposal(client, fixedAssetId)+ ]);++ if (asset.error) {+ throw redirect(+ path.to.fixedAssets,+ await flash(request, error(asset.error, "Failed to load fixed asset"))+ );+ }++ return {+ asset: asset.data,+ depreciationHistory: depreciationHistory.data ?? [],+ disposal: disposal.data+ };+}++export default function FixedAssetDetailRoute() {+ const { fixedAssetId } = useParams();+ const { asset, depreciationHistory, disposal } =+ useLoaderData<typeof loader>();+ const settings = useSettings();+ const taxDepreciationEnabled =+ (settings as any).assetTaxDepreciationEnabled ?? false;+ const permissions = usePermissions();+ const navigate = useNavigate();+ const { company } = useUser();+ const currencyFormatter = useCurrencyFormatter({+ currency: company.baseCurrencyCode+ });+ const deleteModal = useDisclosure();+ const auditDrawer = useDisclosure();++ if (!fixedAssetId) throw new Error("Could not find fixedAssetId");++ const acquisitionCost = Number(asset.acquisitionCost);+ const accumulatedDepreciation = Number(asset.accumulatedDepreciation);+ const nbv = acquisitionCost - accumulatedDepreciation;+ const depreciationPercent =+ acquisitionCost > 0+ ? Math.min(100, (accumulatedDepreciation / acquisitionCost) * 100)+ : 0;++ const accumulatedTaxDepreciation = Number(+ (asset as any).accumulatedTaxDepreciation ?? 0+ );+ const taxNbv = acquisitionCost - accumulatedTaxDepreciation;+ const taxDepreciationPercent =+ acquisitionCost > 0+ ? Math.min(100, (accumulatedTaxDepreciation / acquisitionCost) * 100)+ : 0;++ const isDraft = asset.status === "Draft";+ const isActive =+ asset.status === "Active" || asset.status === "Fully Depreciated";+ const canUpdate = permissions.can("update", "accounting");++ return (+ <div className="flex h-[calc(100dvh-49px)] overflow-y-auto scrollbar-hide w-full">+ <div className="h-full p-4 pb-16 w-full max-w-5xl mx-auto space-y-4">+ {/* Main Details */}+ <Card>+ <DocumentHeader+ title={asset.fixedAssetId ?? ""}+ status={<FixedAssetStatus status={asset.status as any} />}+ menuItems={+ <>+ <DropdownMenuItem onClick={auditDrawer.onOpen}>+ <DropdownMenuIcon icon={<LuHistory />} />+ History+ </DropdownMenuItem>+ {isDraft && (+ <>+ <DropdownMenuSeparator />+ <DropdownMenuItem+ disabled={!permissions.can("delete", "accounting")}+ destructive+ onClick={deleteModal.onOpen}+ >+ <DropdownMenuIcon icon={<LuTrash />} />+ Delete+ </DropdownMenuItem>+ </>+ )}+ </>+ }+ actions={+ <DropdownMenu>+ <DropdownMenuTrigger asChild>+ <Button+ variant="primary"+ size="md"+ rightIcon={<LuChevronDown />}+ >+ Actions+ </Button>+ </DropdownMenuTrigger>+ <DropdownMenuContent align="end">+ <DropdownMenuItem disabled={!canUpdate} asChild>+ <Link to={path.to.fixedAssetDetails(fixedAssetId)}>+ <DropdownMenuIcon icon={<LuPencil />} />+ Edit+ </Link>+ </DropdownMenuItem>+ {isDraft && (+ <>+ <DropdownMenuItem disabled={!canUpdate} asChild>+ <Link to={path.to.fixedAssetRegister(fixedAssetId)}>+ <DropdownMenuIcon icon={<LuClipboardCheck />} />+ Register+ </Link>+ </DropdownMenuItem>+ <DropdownMenuItem asChild>+ <Link to={path.to.fixedAssetPurchase(fixedAssetId)}>+ <DropdownMenuIcon icon={<LuShoppingCart />} />+ Purchase+ </Link>+ </DropdownMenuItem>+ </>+ )}+ {isActive && (+ <>+ <DropdownMenuItem asChild>+ <Link to={path.to.fixedAssetSell(fixedAssetId)}>+ <DropdownMenuIcon icon={<LuStore />} />+ Sell+ </Link>+ </DropdownMenuItem>+ <DropdownMenuSeparator />+ <DropdownMenuItem disabled={!canUpdate} asChild>+ <Link to={path.to.fixedAssetDispose(fixedAssetId)}>+ <DropdownMenuIcon icon={<LuCircleX />} />+ Dispose+ </Link>+ </DropdownMenuItem>+ </>+ )}+ </DropdownMenuContent>+ </DropdownMenu>+ }+ />+ <CardContent className="space-y-0">+ <div+ className={`grid grid-cols-1 gap-3 sm:gap-0 pb-4 ${taxDepreciationEnabled ? "sm:grid-cols-5" : "sm:grid-cols-3"}`}+ >+ <div className="sm:pr-6">+ <p className="text-base text-muted-foreground truncate sm:text-sm">+ Acquisition Cost+ </p>+ <p className="mt-1 text-2xl font-semibold tabular-nums tracking-tight">+ {currencyFormatter.format(acquisitionCost)}+ </p>+ </div>+ <div className="sm:border-l sm:border-border sm:px-6">+ <p className="text-base text-muted-foreground truncate sm:text-sm">+ Accum. Depreciation+ </p>+ <p className="mt-1 text-2xl font-semibold tabular-nums tracking-tight">+ {currencyFormatter.format(accumulatedDepreciation)}+ </p>+ </div>+ <div+ className={`sm:border-l sm:border-border ${taxDepreciationEnabled ? "sm:px-6" : "sm:pl-6"}`}+ >+ <p className="text-base text-muted-foreground truncate sm:text-sm">+ Net Book Value+ </p>+ <p className="mt-1 text-2xl font-semibold tabular-nums tracking-tight">+ {currencyFormatter.format(nbv)}+ </p>+ </div>+ {taxDepreciationEnabled && (+ <>+ <div className="sm:border-l sm:border-border sm:px-6">+ <p className="text-base text-muted-foreground truncate sm:text-sm">+ Accum. Tax Depr.+ </p>+ <p className="mt-1 text-2xl font-semibold tabular-nums tracking-tight">+ {currencyFormatter.format(accumulatedTaxDepreciation)}+ </p>+ </div>+ <div className="sm:border-l sm:border-border sm:pl-6">+ <p className="text-base text-muted-foreground truncate sm:text-sm">+ Tax Book Value+ </p>+ <p className="mt-1 text-2xl font-semibold tabular-nums tracking-tight">+ {currencyFormatter.format(taxNbv)}+ </p>+ </div>+ </>+ )}+ </div>+ <div className="divide-y divide-border border-t border-border">+ <DetailRow label="Name">{asset.name}</DetailRow>+ <DetailRow label="Asset Class">+ <Enumerable+ value={(asset.fixedAssetClass as any)?.name ?? null}+ />+ </DetailRow>+ <DetailRow label="Serial Number">+ {asset.serialNumber || "—"}+ </DetailRow>+ <DetailRow label="Location">+ <Enumerable value={(asset as any).location?.name ?? null} />+ </DetailRow>+ <DetailRow label="Depreciation Method">+ {asset.depreciationMethod}+ </DetailRow>+ <DetailRow label="Useful Life">+ {asset.usefulLifeMonths} months+ </DetailRow>+ <DetailRow label="Residual Value">+ {Number(asset.residualValuePercent)}%+ </DetailRow>+ {taxDepreciationEnabled && (+ <>+ <DetailRow label="Tax Depreciation Method">+ {(asset as any).taxDepreciationMethod || "—"}+ </DetailRow>+ {(asset as any).taxDepreciationMethod === "MACRS" ? (+ <>+ <DetailRow label="MACRS Property Class">+ {(asset as any).macrsPropertyClass+ ? `${(asset as any).macrsPropertyClass}-Year`+ : "—"}+ </DetailRow>+ <DetailRow label="MACRS Convention">+ {(asset as any).macrsConvention || "—"}+ </DetailRow>+ <DetailRow label="Bonus Depreciation">+ {(asset as any).bonusDepreciationPercent != null+ ? `${Number((asset as any).bonusDepreciationPercent)}%`+ : "—"}+ </DetailRow>+ </>+ ) : (+ <>+ <DetailRow label="Tax Useful Life">+ {(asset as any).taxUsefulLifeMonths+ ? `${(asset as any).taxUsefulLifeMonths} months`+ : "—"}+ </DetailRow>+ <DetailRow label="Tax Residual Value">+ {(asset as any).taxResidualValuePercent != null+ ? `${Number((asset as any).taxResidualValuePercent)}%`+ : "—"}+ </DetailRow>+ </>+ )}+ </>+ )}+ <DetailRow label="Acquisition Date">+ {asset.acquisitionDate+ ? formatDate(asset.acquisitionDate)+ : "—"}+ </DetailRow>+ <DetailRow label="Depreciation Start">+ {asset.depreciationStartDate+ ? formatDate(asset.depreciationStartDate)+ : "—"}+ </DetailRow>+ </div>+ </CardContent>+ </Card>++ {/* Depreciation History */}+ {(depreciationHistory.length > 0 || acquisitionCost > 0) && (+ <Card>+ <CardHeader>+ <CardTitle>Depreciation</CardTitle>+ </CardHeader>+ <CardContent className="space-y-6">+ {acquisitionCost > 0 && (+ <div className="space-y-4">+ <BarProgress+ progress={depreciationPercent}+ label="Book Depreciation"+ value={`${depreciationPercent.toFixed(1)}%`}+ gradient+ />+ {taxDepreciationEnabled && (+ <BarProgress+ progress={taxDepreciationPercent}+ label="Tax Depreciation"+ value={`${taxDepreciationPercent.toFixed(1)}%`}+ gradient+ />+ )}+ </div>+ )}+ {depreciationHistory.length > 0 && (+ <div className="overflow-x-auto -mx-6 px-6">+ <table className="w-full text-base sm:text-sm">+ <thead>+ <tr className="border-b border-border">+ <th className="text-left py-2.5 sm:py-2 font-medium text-muted-foreground">+ Run+ </th>+ <th className="text-left py-2.5 sm:py-2 font-medium text-muted-foreground">+ Period End+ </th>+ <th className="text-left py-2.5 sm:py-2 font-medium text-muted-foreground">+ Status+ </th>+ <th className="text-right py-2.5 sm:py-2 font-medium text-muted-foreground">+ Amount+ </th>+ {taxDepreciationEnabled && (+ <th className="text-right py-2.5 sm:py-2 font-medium text-muted-foreground">+ Tax Amount+ </th>+ )}+ </tr>+ </thead>+ <tbody>+ {depreciationHistory.map((item) => {+ const run = item.depreciationRun as any;+ return (+ <tr+ key={item.id}+ className="border-b border-border last:border-0"+ >+ <td className="py-3 sm:py-2.5 tabular-nums">+ <Link+ to={path.to.depreciationRun(run?.id ?? item.id)}+ className="text-foreground hover:underline"+ >+ {run?.depreciationRunId ?? "—"}+ </Link>+ </td>+ <td className="py-3 sm:py-2.5">+ {run?.periodEnd ? formatDate(run.periodEnd) : "—"}+ </td>+ <td className="py-3 sm:py-2.5">+ <DepreciationRunStatus+ status={run?.status ?? null}+ />+ </td>+ <td className="py-3 sm:py-2.5 text-right tabular-nums">+ {currencyFormatter.format(Number(item.amount))}+ </td>+ {taxDepreciationEnabled && (+ <td className="py-3 sm:py-2.5 text-right tabular-nums">+ {currencyFormatter.format(+ Number((item as any).taxAmount ?? 0)+ )}+ </td>+ )}+ </tr>+ );+ })}+ </tbody>+ </table>+ </div>+ )}+ </CardContent>+ </Card>+ )}++ {/* Notes */}+ <FixedAssetNotes+ key={`notes-${fixedAssetId}`}+ id={fixedAssetId}+ notes={asset.notes as JSONContent}+ />++ {/* Disposal */}+ {disposal && (+ <Card>+ <CardContent className="pt-6">+ <div className="divide-y divide-border">+ <DetailRow label="Disposal Method">+ {disposal.disposalMethod}+ </DetailRow>+ <DetailRow label="Disposal Date">+ {formatDate(disposal.disposalDate)}+ </DetailRow>+ <DetailRow label="NBV at Disposal">+ <span className="tabular-nums">+ {currencyFormatter.format(+ Number(disposal.netBookValueAtDisposal)+ )}+ </span>+ </DetailRow>+ <DetailRow label="Sale Proceeds">+ <span className="tabular-nums">+ {currencyFormatter.format(Number(disposal.saleProceeds))}+ </span>+ </DetailRow>+ <DetailRow label="Gain/Loss">+ <Badge+ variant={Number(disposal.gainLoss) >= 0 ? "green" : "red"}+ >+ {currencyFormatter.format(Number(disposal.gainLoss))}+ </Badge>+ </DetailRow>+ </div>+ </CardContent>+ </Card>+ )}++ <Outlet />++ <ConfirmDelete+ action={path.to.deleteFixedAsset(fixedAssetId)}+ isOpen={deleteModal.isOpen}+ name={asset.fixedAssetId}+ text={`Are you sure you want to delete ${asset.fixedAssetId}? This cannot be undone.`}+ onCancel={deleteModal.onClose}+ onSubmit={() => {+ deleteModal.onClose();+ navigate(path.to.fixedAssets);+ }}+ />+ </div>+ <AuditLogDrawer+ isOpen={auditDrawer.isOpen}+ onClose={auditDrawer.onClose}+ entityType="fixedAsset"+ entityId={fixedAssetId}+ companyId={company.id}+ />+ </div>+ );+}++function DetailRow({+ label,+ children+}: {+ label: string;+ children: React.ReactNode;+}) {+ return (+ <div className="flex items-center justify-between py-3 text-base sm:text-sm">+ <span className="text-muted-foreground">{label}</span>+ <span className="font-medium">{children}</span>+ </div>+ );+}diff --git a/apps/erp/app/routes/x+/fixed-asset+/_layout.tsx b/apps/erp/app/routes/x+/fixed-asset+/_layout.tsxnew file mode 100644index 0000000000..55cc8e395e--- /dev/null+++ b/apps/erp/app/routes/x+/fixed-asset+/_layout.tsx@@ -0,0 +1,18 @@+import type { MetaFunction } from "react-router";+import { Outlet } from "react-router";+import type { Handle } from "~/utils/handle";+import { path } from "~/utils/path";++export const meta: MetaFunction = () => {+ return [{ title: "Carbon | Fixed Asset" }];+};++export const handle: Handle = {+ breadcrumb: "Accounting",+ to: path.to.fixedAssets,+ module: "accounting"+};++export default function FixedAssetLayout() {+ return <Outlet />;+}diff --git a/apps/erp/app/routes/x+/purchase-invoice+/$invoiceId.$lineId.details.tsx b/apps/erp/app/routes/x+/purchase-invoice+/$invoiceId.$lineId.details.tsxindex 6933a931ef..799a9cc2f0 100644--- a/apps/erp/app/routes/x+/purchase-invoice+/$invoiceId.$lineId.details.tsx+++ b/apps/erp/app/routes/x+/purchase-invoice+/$invoiceId.$lineId.details.tsx@@ -163,6 +163,8 @@ export default function EditPurchaseInvoiceLineRoute() {storageUnitId: purchaseInvoiceLine?.storageUnitId ?? "",costCenterId: purchaseInvoiceLine?.costCenterId ?? "",taxPercent: purchaseInvoiceLine?.taxPercent ?? 0,+ assetReadableId: (purchaseInvoiceLine as any)?.assetReadableId ?? "",+ assetName: (purchaseInvoiceLine as any)?.assetName ?? "",...getCustomFields(purchaseInvoiceLine?.customFields)};@@ -176,7 +178,15 @@ export default function EditPurchaseInvoiceLineRoute() {id={purchaseInvoiceLine?.id ?? ""}table="purchaseInvoiceLine"title={t`Notes`}- subTitle={getItemReadableId(items, purchaseInvoiceLine?.itemId) ?? ""}+ subTitle={+ purchaseInvoiceLine?.invoiceLineType === "Fixed Asset"+ ? ((purchaseInvoiceLine as any)?.assetName ??+ purchaseInvoiceLine?.description ??+ "")+ : purchaseInvoiceLine?.invoiceLineType === "G/L Account"+ ? (purchaseInvoiceLine?.description ?? "")+ : (getItemReadableId(items, purchaseInvoiceLine?.itemId) ?? "")+ }internalNotes={purchaseInvoiceLine?.internalNotes as JSONContent}/>diff --git a/apps/erp/app/routes/x+/purchase-order+/$orderId.$lineId.details.tsx b/apps/erp/app/routes/x+/purchase-order+/$orderId.$lineId.details.tsxindex a07c4a09c2..29d6412c50 100644--- a/apps/erp/app/routes/x+/purchase-order+/$orderId.$lineId.details.tsx+++ b/apps/erp/app/routes/x+/purchase-order+/$orderId.$lineId.details.tsx@@ -170,6 +170,8 @@ export default function EditPurchaseOrderLineRoute() {supplierUnitPrice: line?.supplierUnitPrice ?? 0,costCenterId: line?.costCenterId ?? "",taxPercent: line?.taxPercent ?? 0,+ assetReadableId: (line as any)?.assetReadableId ?? "",+ assetName: (line as any)?.assetName ?? "",...getCustomFields(line?.customFields)};@@ -183,7 +185,13 @@ export default function EditPurchaseOrderLineRoute() {id={line?.id ?? ""}table="purchaseOrderLine"title="Notes"- subTitle={line.itemReadableId ?? ""}+ subTitle={+ line.purchaseOrderLineType === "Fixed Asset"+ ? (line.assetName ?? line.description ?? "")+ : line.purchaseOrderLineType === "G/L Account"+ ? (line.description ?? "")+ : (line.itemReadableId ?? "")+ }internalNotes={line.internalNotes as JSONContent}externalNotes={line.externalNotes as JSONContent}/>diff --git a/apps/erp/app/routes/x+/receipt+/$receiptId.tsx b/apps/erp/app/routes/x+/receipt+/$receiptId.tsxindex fa1eb120d3..2bfa6bca53 100644--- a/apps/erp/app/routes/x+/receipt+/$receiptId.tsx+++ b/apps/erp/app/routes/x+/receipt+/$receiptId.tsx@@ -69,9 +69,49 @@ export async function loader({ request, params }: LoaderFunctionArgs) {.filter((itemId) => itemId !== null) as string[];}+ let fixedAssetLines: {+ id: string;+ purchaseOrderLineId: string;+ assetId: string;+ assetName: string | null;+ assetReadableId: string | null;+ description: string | null;+ received: boolean;+ serialNumber: string | null;+ }[] = [];++ if (receipt.data.sourceDocument === "Purchase Order") {+ const faLineRecords = await serviceRole+ .from("receiptFixedAssetLine")+ .select(+ "id, purchaseOrderLineId, received, serialNumber, purchaseOrderLine:purchaseOrderLineId(assetId, description, fixedAsset:assetId(name, fixedAssetId, serialNumber))"+ )+ .eq("receiptId", receiptId);++ fixedAssetLines = (faLineRecords.data ?? [])+ .filter((row) => {+ const pol = row.purchaseOrderLine as any;+ return pol?.assetId;+ })+ .map((row) => {+ const pol = row.purchaseOrderLine as any;+ return {+ id: row.id,+ purchaseOrderLineId: row.purchaseOrderLineId,+ assetId: pol.assetId,+ assetName: pol.fixedAsset?.name ?? null,+ assetReadableId: pol.fixedAsset?.fixedAssetId ?? null,+ description: pol.description,+ received: row.received,+ serialNumber: row.serialNumber ?? pol.fixedAsset?.serialNumber ?? null+ };+ });+ }+return {receipt: receipt.data,receiptLines: receiptLines.data ?? [],+ fixedAssetLines,receiptFiles: getReceiptFiles(serviceRole, companyId, receiptLineIds) ?? [],receiptLineTracking: receiptLineTracking.data ?? [],batchProperties:diff --git a/apps/erp/app/routes/x+/receipt+/fixed-asset-lines.update.tsx b/apps/erp/app/routes/x+/receipt+/fixed-asset-lines.update.tsxnew file mode 100644index 0000000000..31ce1665f9--- /dev/null+++ b/apps/erp/app/routes/x+/receipt+/fixed-asset-lines.update.tsx@@ -0,0 +1,39 @@+import { requirePermissions } from "@carbon/auth/auth.server";+import { getCarbonServiceRole } from "@carbon/auth/client.server";+import type { ActionFunctionArgs } from "react-router";++export async function action({ request }: ActionFunctionArgs) {+ const { companyId } = await requirePermissions(request, {+ update: "inventory"+ });++ const formData = await request.formData();+ const id = formData.get("id") as string;+ const field = formData.get("field") as string;+ const value = formData.get("value") as string | null;++ if (!id || !field) {+ return { error: { message: "Invalid form data" }, data: null };+ }++ if (field !== "received" && field !== "serialNumber") {+ return { error: { message: `Invalid field: ${field}` }, data: null };+ }++ const serviceRole = getCarbonServiceRole();++ const updateData: Record<string, unknown> = {};+ if (field === "received") {+ updateData.received = value === "true";+ } else if (field === "serialNumber") {+ updateData.serialNumber = value || null;+ }++ const update = await serviceRole+ .from("receiptFixedAssetLine")+ .update(updateData)+ .eq("id", id)+ .eq("companyId", companyId);++ return update;+}diff --git a/apps/erp/app/routes/x+/resources+/work-centers.$id.tsx b/apps/erp/app/routes/x+/resources+/work-centers.$id.tsxindex 59f03cec81..53b18b6b1e 100644--- a/apps/erp/app/routes/x+/resources+/work-centers.$id.tsx+++ b/apps/erp/app/routes/x+/resources+/work-centers.$id.tsx@@ -96,6 +96,7 @@ export default function WorkCenterRoute() {const initialValues = {id: workCenter?.id ?? undefined,defaultStandardFactor: workCenter?.defaultStandardFactor ?? "Minutes/Piece",+ departmentId: workCenter?.departmentId ?? undefined,description: workCenter?.description ?? "",laborRate: workCenter?.laborRate ?? 0,locationId: workCenter?.locationId ?? "",diff --git a/apps/erp/app/routes/x+/resources+/work-centers.new.tsx b/apps/erp/app/routes/x+/resources+/work-centers.new.tsxindex 1d5a2c7190..19c027a96f 100644--- a/apps/erp/app/routes/x+/resources+/work-centers.new.tsx+++ b/apps/erp/app/routes/x+/resources+/work-centers.new.tsx@@ -71,6 +71,7 @@ export default function NewWorkCenterRoute() {const initialValues = {defaultStandardFactor: "Minutes/Piece" as "Minutes/Piece",+ departmentId: undefined as string | undefined,description: "",laborRate: 0,locationId: defaults?.locationId ?? "",diff --git a/apps/erp/app/routes/x+/resources+/work-centers.tsx b/apps/erp/app/routes/x+/resources+/work-centers.tsxindex ec9c233b7c..aabee1d108 100644--- a/apps/erp/app/routes/x+/resources+/work-centers.tsx+++ b/apps/erp/app/routes/x+/resources+/work-centers.tsx@@ -5,6 +5,7 @@ import { VStack } from "@carbon/react";import { msg } from "@lingui/core/macro";import type { LoaderFunctionArgs } from "react-router";import { Outlet, redirect, useLoaderData } from "react-router";+import { getDepartmentsList } from "~/modules/people";import {getLocationsList,getWorkCenters,@@ -32,7 +33,7 @@ export async function loader({ request }: LoaderFunctionArgs) {const { limit, offset, sorts, filters } =getGenericQueryFilters(searchParams);- const [workCenters, locations] = await Promise.all([+ const [workCenters, departments, locations] = await Promise.all([getWorkCenters(client, companyId, {search,limit,@@ -40,6 +41,7 @@ export async function loader({ request }: LoaderFunctionArgs) {sorts,filters}),+ getDepartmentsList(client, companyId),getLocationsList(client, companyId)]);@@ -55,19 +57,22 @@ export async function loader({ request }: LoaderFunctionArgs) {return {count: workCenters.count ?? 0,+ departments: departments.data ?? [],workCenters: workCenters.data ?? [],locations: locations.data ?? []};}export default function WorkCentersRoute() {- const { count, locations, workCenters } = useLoaderData<typeof loader>();+ const { count, departments, locations, workCenters } =+ useLoaderData<typeof loader>();return (<VStack spacing={0} className="h-full"><WorkCentersTabledata={workCenters}count={count}+ departments={departments}locations={locations}/><Outlet />diff --git a/apps/erp/app/routes/x+/sales-invoice+/$invoiceId.$lineId.details.tsx b/apps/erp/app/routes/x+/sales-invoice+/$invoiceId.$lineId.details.tsxindex 462512e50e..80d218d220 100644--- a/apps/erp/app/routes/x+/sales-invoice+/$invoiceId.$lineId.details.tsx+++ b/apps/erp/app/routes/x+/sales-invoice+/$invoiceId.$lineId.details.tsx@@ -89,21 +89,13 @@ export async function action({ request, params }: ActionFunctionArgs) {// biome-ignore lint/correctness/noUnusedVariables: suppressed due to migrationconst { id, ...d } = validation.data;- // if (d.invoiceLineType === "G/L Account") {- // d.assetId = undefined;- // d.itemId = undefined;- // } else if (d.invoiceLineType === "Fixed Asset") {- // d.accountId = undefined;- // d.itemId = undefined;- // } else- // if (d.invoiceLineType === "Comment") {- // d.accountId = undefined;- // d.assetId = undefined;- // d.itemId = undefined;- // } else {- // d.accountId = undefined;- // d.assetId = undefined;- // }+ if (d.invoiceLineType === "Fixed Asset") {+ d.accountId = undefined;+ d.itemId = undefined;+ } else {+ d.accountId = undefined;+ d.assetId = undefined;+ }const updateSalesInvoiceLine = await upsertSalesInvoiceLine(client, {id: lineId,@@ -155,6 +147,8 @@ export default function EditSalesInvoiceLineRoute() {exchangeRate: salesInvoiceLine?.exchangeRate ?? 1,unitOfMeasureCode: salesInvoiceLine?.unitOfMeasureCode ?? "",storageUnitId: salesInvoiceLine?.storageUnitId ?? "",+ assetReadableId: (salesInvoiceLine as any)?.assetReadableId ?? undefined,+ assetName: (salesInvoiceLine as any)?.assetName ?? undefined,...getCustomFields(salesInvoiceLine?.customFields)};diff --git a/apps/erp/app/routes/x+/sales-invoice+/$invoiceId.new.tsx b/apps/erp/app/routes/x+/sales-invoice+/$invoiceId.new.tsxindex 502ac1c59e..f203b4f29f 100644--- a/apps/erp/app/routes/x+/sales-invoice+/$invoiceId.new.tsx+++ b/apps/erp/app/routes/x+/sales-invoice+/$invoiceId.new.tsx@@ -61,6 +61,14 @@ export async function action({ request, params }: ActionFunctionArgs) {// biome-ignore lint/correctness/noUnusedVariables: suppressed due to migrationconst { id, ...d } = validation.data;+ if (d.invoiceLineType === "Fixed Asset") {+ d.accountId = undefined;+ d.itemId = undefined;+ } else {+ d.accountId = undefined;+ d.assetId = undefined;+ }+const createSalesInvoiceLine = await upsertSalesInvoiceLine(client, {...d,companyId,@@ -109,6 +117,5 @@ export default function NewSalesInvoiceLineRoute() {exchangeRate: salesInvoiceData?.salesInvoice?.exchangeRate ?? 1};- // @ts-expect-error TS2322 - TODO: fix typereturn <SalesInvoiceLineForm initialValues={initialValues} />;}diff --git a/apps/erp/app/routes/x+/sales-order+/$orderId.$lineId.details.tsx b/apps/erp/app/routes/x+/sales-order+/$orderId.$lineId.details.tsxindex a7d3aaffee..662ffa79e9 100644--- a/apps/erp/app/routes/x+/sales-order+/$orderId.$lineId.details.tsx+++ b/apps/erp/app/routes/x+/sales-order+/$orderId.$lineId.details.tsx@@ -191,6 +191,8 @@ export default function EditSalesOrderLineRoute() {unitPrice: line?.unitPrice ?? 0,taxPercent: line?.taxPercent ?? 0,shippingCost: line?.shippingCost ?? 0,+ assetReadableId: (line as any)?.assetReadableId ?? undefined,+ assetName: (line as any)?.assetName ?? undefined,...getCustomFields(line?.customFields)};diff --git a/apps/erp/app/routes/x+/sales-order+/$orderId.new.tsx b/apps/erp/app/routes/x+/sales-order+/$orderId.new.tsxindex 6fd2f5784e..53cafd98fb 100644--- a/apps/erp/app/routes/x+/sales-order+/$orderId.new.tsx+++ b/apps/erp/app/routes/x+/sales-order+/$orderId.new.tsx@@ -50,6 +50,18 @@ export async function action({ request, params }: ActionFunctionArgs) {// biome-ignore lint/correctness/noUnusedVariables: suppressed due to migrationconst { id, ...d } = validation.data;+ if (d.salesOrderLineType === "Comment") {+ d.accountId = undefined;+ d.assetId = undefined;+ d.itemId = undefined;+ } else if (d.salesOrderLineType === "Fixed Asset") {+ d.accountId = undefined;+ d.itemId = undefined;+ } else {+ d.accountId = undefined;+ d.assetId = undefined;+ }+const createSalesOrderLine = await upsertSalesOrderLine(client, {...d,companyId,diff --git a/apps/erp/app/routes/x+/settings+/accounting.tsx b/apps/erp/app/routes/x+/settings+/accounting.tsxindex 733b9a382d..83c75e67b8 100644--- a/apps/erp/app/routes/x+/settings+/accounting.tsx+++ b/apps/erp/app/routes/x+/settings+/accounting.tsx@@ -1,11 +1,13 @@import { error } from "@carbon/auth";import { requirePermissions } from "@carbon/auth/auth.server";import { flash } from "@carbon/auth/session.server";+import { ValidatedForm, validationError, validator } from "@carbon/form";import {Badge,Card,CardContent,CardDescription,+ CardFooter,CardHeader,CardTitle,Heading,@@ -18,17 +20,37 @@ import {import { msg } from "@lingui/core/macro";import { Trans } from "@lingui/react/macro";import { useCallback, useEffect } from "react";-import type { ActionFunctionArgs, LoaderFunctionArgs } from "react-router";import { redirect, useFetcher, useLoaderData } from "react-router";+import { z } from "zod";+import { zfd } from "zod-form-data";+import {+ Account,+ Hidden,+ Number as NumberInput,+ Submit+} from "~/components/Form";import { useFlags } from "~/hooks";+import { getDefaultAccounts } from "~/modules/accounting";import {getCompanySettings,- updateAccountingEnabledSetting+ updateAccountingEnabledSetting,+ updateAssetTaxDepreciationSettings} from "~/modules/settings";import type { Handle } from "~/utils/handle";import { path } from "~/utils/path";+const taxDepreciationSettingsValidator = z.object({+ intent: z.literal("assetTaxDepreciation"),+ assetTaxRate: zfd.numeric(z.number().min(0).max(100)),+ deferredTaxLiabilityAccountId: z.string().min(1, {+ message: "Deferred tax liability account is required"+ }),+ deferredTaxExpenseAccountId: z.string().min(1, {+ message: "Deferred tax expense account is required"+ })+});+export const handle: Handle = {breadcrumb: msg`Accounting`,to: path.to.accountingSettings@@ -39,7 +61,10 @@ export async function loader({ request }: LoaderFunctionArgs) {view: "settings"});- const companySettings = await getCompanySettings(client, companyId);+ const [companySettings, accountDefaults] = await Promise.all([+ getCompanySettings(client, companyId),+ getDefaultAccounts(client, companyId)+ ]);if (!companySettings.data)throw redirect(@@ -49,19 +74,23 @@ export async function loader({ request }: LoaderFunctionArgs) {error(companySettings.error, "Failed to get company settings")));- return { companySettings: companySettings.data };++ return {+ companySettings: companySettings.data,+ accountDefaults: accountDefaults.data+ };}export async function action({ request }: ActionFunctionArgs) {- const { client, companyId } = await requirePermissions(request, {+ const { client, companyId, userId } = await requirePermissions(request, {update: "settings"});const formData = await request.formData();const intent = formData.get("intent");- const enabled = formData.get("enabled") === "true";if (intent === "accountingEnabled") {+ const enabled = formData.get("enabled") === "true";const update = await updateAccountingEnabledSetting(client,companyId,@@ -71,25 +100,88 @@ export async function action({ request }: ActionFunctionArgs) {return { success: true, message: "Accounting settings updated" };}+ if (intent === "assetTaxDepreciationEnabled") {+ const enabled = formData.get("enabled") === "true";+ const update = await updateAssetTaxDepreciationSettings(client, companyId, {+ assetTaxDepreciationEnabled: enabled,+ assetTaxRate: null+ });+ if (update.error) return { success: false, message: update.error.message };+ return { success: true, message: "Fixed asset settings updated" };+ }++ if (intent === "assetTaxDepreciation") {+ const validation = await validator(+ taxDepreciationSettingsValidator+ ).validate(formData);++ if (validation.error) {+ return validationError(validation.error);+ }++ const {+ assetTaxRate,+ deferredTaxLiabilityAccountId,+ deferredTaxExpenseAccountId+ } = validation.data;++ const settingsUpdate = await updateAssetTaxDepreciationSettings(+ client,+ companyId,+ { assetTaxDepreciationEnabled: true, assetTaxRate }+ );++ if (settingsUpdate.error)+ return { success: false, message: settingsUpdate.error.message };++ const accountUpdate = await client+ .from("accountDefault")+ .update({+ deferredTaxLiabilityAccountId,+ deferredTaxExpenseAccountId,+ updatedBy: userId+ } as any)+ .eq("companyId", companyId);++ if (accountUpdate.error)+ return { success: false, message: accountUpdate.error.message };++ return { success: true, message: "Fixed asset settings updated" };+ }+return { success: false, message: "Unknown intent" };}export default function AccountingSettingsRoute() {- const { companySettings } = useLoaderData<typeof loader>();+ const { companySettings, accountDefaults } = useLoaderData<typeof loader>();const fetcher = useFetcher<typeof action>();+ const taxFetcher = useFetcher<typeof action>();const { isInternal } = useFlags();- // const isToggling = fetcher.state !== "idle";+ const taxEnabled =+ (companySettings as any).assetTaxDepreciationEnabled ?? false;useEffect(() => {- if (fetcher.data?.success === true && fetcher.data?.message) {- toast.success(fetcher.data.message);+ if (fetcher.data && "success" in fetcher.data) {+ if (fetcher.data.success === true && fetcher.data.message) {+ toast.success(fetcher.data.message);+ }+ if (fetcher.data.success === false && fetcher.data.message) {+ toast.error(fetcher.data.message);+ }}+ }, [fetcher.data]);- if (fetcher.data?.success === false && fetcher.data?.message) {- toast.error(fetcher.data.message);+ useEffect(() => {+ if (taxFetcher.data && "success" in taxFetcher.data) {+ if (taxFetcher.data.success === true && taxFetcher.data.message) {+ toast.success(taxFetcher.data.message);+ }+ if (taxFetcher.data.success === false && taxFetcher.data.message) {+ toast.error(taxFetcher.data.message);+ }}- }, [fetcher.data]);+ }, [taxFetcher.data]);const handleAccountingToggle = useCallback((checked: boolean) => {@@ -101,6 +193,16 @@ export default function AccountingSettingsRoute() {[fetcher]);+ const handleTaxDepreciationToggle = useCallback(+ (checked: boolean) => {+ fetcher.submit(+ { intent: "assetTaxDepreciationEnabled", enabled: String(checked) },+ { method: "POST" }+ );+ },+ [fetcher]+ );+return (<ScrollArea className="w-full h-[calc(100dvh-49px)]"><VStack@@ -156,11 +258,90 @@ export default function AccountingSettingsRoute() {checked={(companySettings as any).accountingEnabled ?? false}onCheckedChange={handleAccountingToggle}disabled={!isInternal}- // disabled={isToggling}/></HStack></CardContent></Card>++ <ValidatedForm+ className="w-full"+ validator={taxDepreciationSettingsValidator}+ method="post"+ fetcher={taxFetcher}+ defaultValues={{+ intent: "assetTaxDepreciation",+ assetTaxRate: parseFloat(+ (companySettings as any).assetTaxRate ?? "0"+ ),+ deferredTaxLiabilityAccountId:+ (accountDefaults as any)?.deferredTaxLiabilityAccountId ?? "",+ deferredTaxExpenseAccountId:+ (accountDefaults as any)?.deferredTaxExpenseAccountId ?? ""+ }}+ >+ <Card>+ <CardHeader>+ <CardTitle>+ <Trans>Fixed Assets</Trans>+ </CardTitle>+ <CardDescription>+ <Trans>+ Track tax depreciation separately from book depreciation and+ automatically post deferred tax liability entries.+ </Trans>+ </CardDescription>+ </CardHeader>+ <CardContent>+ <VStack spacing={4}>+ <HStack className="w-full justify-between items-center">+ <VStack className="items-start" spacing={1}>+ <span className="font-medium">+ <Trans>Track tax depreciation separately</Trans>+ </span>+ <span className="text-sm text-muted-foreground">+ <Trans>+ Enable to configure tax-specific depreciation methods on+ asset classes (e.g., MACRS, accelerated).+ </Trans>+ </span>+ </VStack>+ <Switch+ checked={taxEnabled}+ onCheckedChange={handleTaxDepreciationToggle}+ />+ </HStack>+ {taxEnabled && (+ <VStack spacing={4} className="pt-4 border-t">+ <Hidden name="intent" value="assetTaxDepreciation" />+ <NumberInput+ name="assetTaxRate"+ label="Tax Rate (%)"+ minValue={0}+ maxValue={100}+ />+ <Account+ name="deferredTaxLiabilityAccountId"+ label="Deferred Tax Liability Account"+ classes={["Liability"]}+ />+ <Account+ name="deferredTaxExpenseAccountId"+ label="Deferred Tax Expense Account"+ classes={["Expense"]}+ />+ </VStack>+ )}+ </VStack>+ </CardContent>+ {taxEnabled && (+ <CardFooter>+ <Submit isDisabled={taxFetcher.state !== "idle"}>+ <Trans>Save</Trans>+ </Submit>+ </CardFooter>+ )}+ </Card>+ </ValidatedForm></VStack></ScrollArea>);diff --git a/apps/erp/app/routes/x+/shipment+/$shipmentId.tsx b/apps/erp/app/routes/x+/shipment+/$shipmentId.tsxindex aef779eaa2..093ede2f14 100644--- a/apps/erp/app/routes/x+/shipment+/$shipmentId.tsx+++ b/apps/erp/app/routes/x+/shipment+/$shipmentId.tsx@@ -1,5 +1,6 @@import { error } from "@carbon/auth";import { requirePermissions } from "@carbon/auth/auth.server";+import { getCarbonServiceRole } from "@carbon/auth/client.server";import { flash } from "@carbon/auth/session.server";import { msg } from "@lingui/core/macro";import type { LoaderFunctionArgs } from "react-router";@@ -43,9 +44,50 @@ export async function loader({ request, params }: LoaderFunctionArgs) {throw redirect(path.to.shipments);}+ let fixedAssetLines: {+ id: string;+ salesOrderLineId: string;+ assetId: string;+ assetName: string | null;+ assetReadableId: string | null;+ description: string | null;+ shipped: boolean;+ serialNumber: string | null;+ }[] = [];++ if (shipment.data.sourceDocument === "Sales Order") {+ const serviceRole = getCarbonServiceRole();+ const faLineRecords = await serviceRole+ .from("shipmentFixedAssetLine")+ .select(+ "id, salesOrderLineId, shipped, serialNumber, salesOrderLine:salesOrderLineId(assetId, description, fixedAsset:assetId(name, fixedAssetId, serialNumber))"+ )+ .eq("shipmentId", shipmentId);++ fixedAssetLines = (faLineRecords.data ?? [])+ .filter((row) => {+ const sol = row.salesOrderLine as any;+ return sol?.assetId;+ })+ .map((row) => {+ const sol = row.salesOrderLine as any;+ return {+ id: row.id,+ salesOrderLineId: row.salesOrderLineId,+ assetId: sol.assetId,+ assetName: sol.fixedAsset?.name ?? null,+ assetReadableId: sol.fixedAsset?.fixedAssetId ?? null,+ description: sol.description,+ shipped: row.shipped,+ serialNumber: row.serialNumber ?? sol.fixedAsset?.serialNumber ?? null+ };+ });+ }+return {shipment: shipment.data,shipmentLines: shipmentLines.data ?? [],+ fixedAssetLines,shipmentLineTracking: shipmentLineTracking.data ?? [],relatedItems: getShipmentRelatedItems(client,diff --git a/apps/erp/app/routes/x+/shipment+/fixed-asset-lines.update.tsx b/apps/erp/app/routes/x+/shipment+/fixed-asset-lines.update.tsxnew file mode 100644index 0000000000..8647bb3e97--- /dev/null+++ b/apps/erp/app/routes/x+/shipment+/fixed-asset-lines.update.tsx@@ -0,0 +1,39 @@+import { requirePermissions } from "@carbon/auth/auth.server";+import { getCarbonServiceRole } from "@carbon/auth/client.server";+import type { ActionFunctionArgs } from "react-router";++export async function action({ request }: ActionFunctionArgs) {+ const { companyId } = await requirePermissions(request, {+ update: "inventory"+ });++ const formData = await request.formData();+ const id = formData.get("id") as string;+ const field = formData.get("field") as string;+ const value = formData.get("value") as string | null;++ if (!id || !field) {+ return { error: { message: "Invalid form data" }, data: null };+ }++ if (field !== "shipped" && field !== "serialNumber") {+ return { error: { message: `Invalid field: ${field}` }, data: null };+ }++ const serviceRole = getCarbonServiceRole();++ const updateData: Record<string, unknown> = {};+ if (field === "shipped") {+ updateData.shipped = value === "true";+ } else if (field === "serialNumber") {+ updateData.serialNumber = value || null;+ }++ const update = await serviceRole+ .from("shipmentFixedAssetLine")+ .update(updateData)+ .eq("id", id)+ .eq("companyId", companyId);++ return update;+}diff --git a/apps/erp/app/styles/tailwind.css b/apps/erp/app/styles/tailwind.cssindex 574628a7c0..a863189da9 100644--- a/apps/erp/app/styles/tailwind.css+++ b/apps/erp/app/styles/tailwind.css@@ -197,87 +197,3 @@ p.is-editor-empty:first-child:before {.loading-dot:nth-child(3) {animation-delay: 0.4s;}--.hexagon-loader-container {- @apply relative w-full py-4;-}--.hexagon-loader {- position: relative;- display: flex;- justify-content: center;- align-items: center;- width: 100%;- height: 40px;-}--/* Three hexagon loading animation */-.hexagon {- display: inline-block;- position: relative;- width: 18px;- height: 10px;- background-color: #5fe4d3;- animation: hexloader 1.4s infinite ease-in-out;-}--.hexagon:before,-.hexagon:after {- content: "";- position: absolute;- width: 0;- border-left: 9px solid transparent;- border-right: 9px solid transparent;-}--.hexagon:before {- bottom: 100%;- border-bottom: 5px solid #5fe4d3;-}--.hexagon:after {- top: 100%;- border-top: 5px solid #5fe4d3;-}--.hexagon + .hexagon {- margin-left: 8px;- animation: hexloader 1.4s 0.2s infinite ease-in-out;- background-color: #4faade;-}--.hexagon + .hexagon:before {- border-bottom-color: #4faade;-}--.hexagon + .hexagon:after {- border-top-color: #4faade;-}--.hexagon + .hexagon + .hexagon {- margin-left: 8px;- animation: hexloader 1.4s 0.4s infinite ease-in-out;- background-color: #6041d0;-}--.hexagon + .hexagon + .hexagon:before {- border-bottom-color: #6041d0;-}--.hexagon + .hexagon + .hexagon:after {- border-top-color: #6041d0;-}---@keyframes hexloader {- 0%,- 80%,- 100% {- transform: scale(0.5);- opacity: 0;- }- 40% {- transform: scale(1);- opacity: 1;- }-}diff --git a/apps/erp/app/utils/path.ts b/apps/erp/app/utils/path.tsindex c8d5003901..bde9f4c1fe 100644--- a/apps/erp/app/utils/path.ts+++ b/apps/erp/app/utils/path.ts@@ -14,6 +14,7 @@ export const path = {api: {abilities: `${api}/resources/abilities`,accounts: `${api}/accounting/accounts`,+ assetClasses: `${api}/accounting/asset-classes`,assign: `${api}/assign`,batchNumbers: (itemId: string) =>generatePath(`${api}/inventory/batch-numbers?itemId=${itemId}`),@@ -418,6 +419,35 @@ export const path = {accountingGroupsPurchasing: `${x}/accounting/groups/purchasing`,accountingGroupsSales: `${x}/accounting/groups/sales`,accountingRoot: `${x}/accounting`,+ fixedAssets: `${x}/accounting/fixed-assets`,+ fixedAsset: (id: string) => generatePath(`${x}/fixed-asset/${id}`),+ fixedAssetDetails: (id: string) =>+ generatePath(`${x}/fixed-asset/${id}/details`),+ fixedAssetDispose: (id: string) =>+ generatePath(`${x}/fixed-asset/${id}/dispose`),+ fixedAssetRegister: (id: string) =>+ generatePath(`${x}/fixed-asset/${id}/register`),+ fixedAssetPurchase: (id: string) =>+ generatePath(`${x}/fixed-asset/${id}/purchase`),+ fixedAssetSell: (id: string) => generatePath(`${x}/fixed-asset/${id}/sell`),+ newFixedAsset: `${x}/accounting/fixed-assets/new`,+ deleteFixedAsset: (id: string) =>+ generatePath(`${x}/fixed-asset/${id}/delete`),+ assetClasses: `${x}/accounting/asset-classes`,+ assetClass: (id: string) =>+ generatePath(`${x}/accounting/asset-class/${id}`),+ newAssetClass: `${x}/accounting/asset-classes/new`,+ deleteAssetClass: (id: string) =>+ generatePath(`${x}/accounting/asset-class/${id}/delete`),+ depreciationRuns: `${x}/accounting/depreciation-runs`,+ depreciationRun: (id: string) =>+ generatePath(`${x}/depreciation-run/${id}`),+ newDepreciationRun: `${x}/accounting/depreciation-runs/new`,+ deleteDepreciationRun: (id: string) =>+ generatePath(`${x}/depreciation-run/${id}/delete`),+ repeatDepreciationRun: (id: string) =>+ generatePath(`${x}/depreciation-run/${id}/repeat`),+ fixedAssetImport: `${x}/accounting/fixed-asset-import`,intercompany: `${x}/accounting/intercompany`,newIntercompanyTransaction: `${x}/accounting/intercompany/new`,activeMethodVersion: (id: string) =>@@ -1442,6 +1472,7 @@ export const path = {receiptDetails: (id: string) => generatePath(`${x}/receipt/${id}/details`),receiptLineDelete: (id: string) =>generatePath(`${x}/receipt/lines/${id}/delete`),+ receiptFixedAssetLineUpdate: `${x}/receipt/fixed-asset-lines/update`,receiptLineSplit: `${x}/receipt/lines/split`,receiptLines: (id: string) => generatePath(`${x}/receipt/${id}/lines`),receiptLinesTracking: (id: string) =>@@ -1610,6 +1641,7 @@ export const path = {shipment: (id: string) => generatePath(`${x}/shipment/${id}`),shipmentDetails: (id: string) =>generatePath(`${x}/shipment/${id}/details`),+ shipmentFixedAssetLineUpdate: `${x}/shipment/fixed-asset-lines/update`,shipmentLineDelete: (id: string) =>generatePath(`${x}/shipment/lines/${id}/delete`),shipmentLineSplit: `${x}/shipment/lines/split`,diff --git a/apps/erp/public/android-chrome-192x192.png b/apps/erp/public/android-chrome-192x192.pngnew file mode 100644index 0000000000..bc936a17b0Binary files /dev/null and b/apps/erp/public/android-chrome-192x192.png differdiff --git a/apps/erp/public/android-chrome-512x512.png b/apps/erp/public/android-chrome-512x512.pngnew file mode 100644index 0000000000..841366bbf7Binary files /dev/null and b/apps/erp/public/android-chrome-512x512.png differdiff --git a/apps/erp/public/apple-touch-icon.png b/apps/erp/public/apple-touch-icon.pngindex 7d10fd7748..aadf41c525 100644Binary files a/apps/erp/public/apple-touch-icon.png and b/apps/erp/public/apple-touch-icon.png differdiff --git a/apps/erp/public/ascii-logo.txt b/apps/erp/public/ascii-logo.txtdeleted file mode 100644index a32ea0d3dc..0000000000--- a/apps/erp/public/ascii-logo.txt+++ /dev/null@@ -1,30 +0,0 @@- .--.- :=#@@@@#=:- -*%@@@@@@@@@@%*-- .=*@@@@@@@@@@@@@@@@@@*=.- +@@@@@@@@@@@@@@@@@@@@@@@@+- %@@@@@@@@@@@@@@@@@@@@@@@@%- #@@@@@@@@@@@@@@@@@@@@@@@@%- %@@@@@@@@@@@@@@@@@@@@@@@@%- %@@@@@@@@@@@@@@@@@@@@@@@@%- #@@@@@@@@@@@@@@@@@@@@@@@@%- %@@@@@@@@@@@@@@@@@@@@@@@@%- *@@@@@@@@@@@@@@@@@@@@@@@@*- :+%@@@@@@@@@@@@@@@@@@%+-- :=#@@@@@@@@@@@@#=:- :=+- .-*@@@@@@*=. -+=:- .-*%@@@@@#=. :++- .=#@@@@@@*-.- .=#@@@@@@@@@@@@%+: :+%@@@@@@@@@@@@#=.- :+%@@@@@@@@@@@@@@@@@@%*- -*%@@@@@@@@@@@@@@@@@@%+:- +@@@@@@@@@@@@@@@@@@@@@@@@# #@@@@@@@@@@@@@@@@@@@@@@@@+- #@@@@@@@@@@@@@@@@@@@@@@@@@ @@@@@@@@@@@@@@@@@@@@@@@@@#- *@@@@@@@@@@@@@@@@@@@@@@@@% %@@@@@@@@@@@@@@@@@@@@@@@@*- *@@@@@@@@@@@@@@@@@@@@@@@@% %@@@@@@@@@@@@@@@@@@@@@@@@*- *@@@@@@@@@@@@@@@@@@@@@@@@% %@@@@@@@@@@@@@@@@@@@@@@@@*- *@@@@@@@@@@@@@@@@@@@@@@@@% %@@@@@@@@@@@@@@@@@@@@@@@@*- #@@@@@@@@@@@@@@@@@@@@@@@@@ @@@@@@@@@@@@@@@@@@@@@@@@@#- =@@@@@@@@@@@@@@@@@@@@@@@@* *@@@@@@@@@@@@@@@@@@@@@@@@=- .-*@@@@@@@@@@@@@@@@@@#=. .=#@@@@@@@@@@@@@@@@@%*-.- :+%@@@@@@@@@@%*-. -*%@@@@@@@@@@%+:- .=#@@@@#+: :+#@@@@#=.- .--. .--.\ No newline at end of filediff --git a/apps/erp/public/carbon-logo-mark.svg b/apps/erp/public/carbon-logo-mark.svgdeleted file mode 100644index 048049e1e5..0000000000--- a/apps/erp/public/carbon-logo-mark.svg+++ /dev/null@@ -1,20 +0,0 @@-<svg width="362" height="349" viewBox="0 0 362 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M181.165 139.643V69.8213L241.346 35.0564L241.054 104.878L181.165 139.643Z" fill="#60FFD2"/>-<path d="M181.165 69.8213V139.643L120.4 104.878V35.0564L181.165 69.8213Z" fill="#36B5B4"/>-<path d="M120.4 35.0565L181.165 69.8214L241.347 35.0565L181.165 -0.000610352L120.4 35.0565Z" fill="#5FE4D2"/>-<path d="M240.818 244.172V174.35L300.999 139.585L300.707 209.407L240.818 244.172Z" fill="#71DEFF"/>-<path d="M240.818 174.35V244.172L180.052 209.407V139.585L240.818 174.35Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.35L300.999 139.586L240.818 104.528L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.172V174.35L181.693 139.585L181.401 209.407L121.512 244.172Z" fill="#71DEFF"/>-<path d="M121.512 174.35V244.172L60.7466 209.407V139.585L121.512 174.35Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.35L181.694 139.586L121.512 104.528L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.701V278.879L241.346 244.114L241.054 313.936L181.165 348.701Z" fill="#7D7FE5"/>-<path d="M181.165 278.879V348.701L120.4 313.936V244.114L181.165 278.879Z" fill="#2F31AE"/>-<path d="M120.4 244.114L181.165 278.879L241.347 244.114L181.165 209.057L120.4 244.114Z" fill="#6041D0"/>-<path d="M60.7651 348.701V278.879L120.946 244.114L120.654 313.936L60.7651 348.701Z" fill="#7D7FE5"/>-<path d="M60.7656 278.879V348.701L0 313.936V244.114L60.7656 278.879Z" fill="#2F31AE"/>-<path d="M0 244.114L60.7656 278.879L120.947 244.114L60.7656 209.057L0 244.114Z" fill="#6041D0"/>-<path d="M301.017 348.701V278.879L361.198 244.114L360.906 313.936L301.017 348.701Z" fill="#7D7FE5"/>-<path d="M301.018 278.879V348.701L240.252 313.936V244.114L301.018 278.879Z" fill="#2F31AE"/>-<path d="M240.252 244.114L301.018 278.879L361.199 244.114L301.018 209.057L240.252 244.114Z" fill="#6041D0"/>-</svg>diff --git a/apps/erp/public/carbon-mark-dark.svg b/apps/erp/public/carbon-mark-dark.svgnew file mode 100644index 0000000000..047b926154--- /dev/null+++ b/apps/erp/public/carbon-mark-dark.svg@@ -0,0 +1,3 @@+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#E6E6E6"/>+</svg>diff --git a/apps/erp/public/carbon-mark-light.svg b/apps/erp/public/carbon-mark-light.svgnew file mode 100644index 0000000000..db0480c53c--- /dev/null+++ b/apps/erp/public/carbon-mark-light.svg@@ -0,0 +1,3 @@+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#101A24"/>+</svg>diff --git a/apps/erp/public/carbon-word-dark.png b/apps/erp/public/carbon-word-dark.pngdeleted file mode 100644index 3606059a75..0000000000Binary files a/apps/erp/public/carbon-word-dark.png and /dev/null differdiff --git a/apps/erp/public/carbon-word-dark.svg b/apps/erp/public/carbon-word-dark.svgindex b555c4b360..c4463b4061 100644--- a/apps/erp/public/carbon-word-dark.svg+++ b/apps/erp/public/carbon-word-dark.svg@@ -1,26 +1,9 @@-<svg width="1307" height="349" viewBox="0 0 1307 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M412.646 193.426C412.646 178.405 415.703 165.305 421.816 154.126C427.929 142.773 436.401 134.039 447.23 127.926C458.059 121.638 470.461 118.494 484.434 118.494C502.425 118.494 517.271 123.035 528.974 132.118C540.851 141.026 548.799 153.602 552.816 169.846H513.254C511.158 163.558 507.577 158.667 502.512 155.174C497.621 151.506 491.508 149.672 484.172 149.672C473.692 149.672 465.395 153.515 459.282 161.2C453.169 168.711 450.112 179.453 450.112 193.426C450.112 207.225 453.169 217.967 459.282 225.652C465.395 233.163 473.692 236.918 484.172 236.918C499.019 236.918 508.713 230.281 513.254 217.006H552.816C548.799 232.726 540.851 245.215 528.974 254.472C517.097 263.729 502.25 268.358 484.434 268.358C470.461 268.358 458.059 265.301 447.23 259.188C436.401 252.9 427.929 244.167 421.816 232.988C415.703 221.635 412.646 208.447 412.646 193.426Z" fill="white"/>-<path d="M562.395 192.902C562.395 178.23 565.277 165.217 571.041 153.864C576.98 142.511 584.927 133.777 594.883 127.664C605.014 121.551 616.28 118.494 628.681 118.494C639.511 118.494 648.943 120.677 656.977 125.044C665.187 129.411 671.737 134.913 676.627 141.55V120.852H713.569V266H676.627V244.778C671.911 251.59 665.361 257.267 656.977 261.808C648.768 266.175 639.249 268.358 628.419 268.358C616.193 268.358 605.014 265.214 594.883 258.926C584.927 252.638 576.98 243.817 571.041 232.464C565.277 220.936 562.395 207.749 562.395 192.902ZM676.627 193.426C676.627 184.518 674.881 176.92 671.387 170.632C667.894 164.169 663.178 159.279 657.239 155.96C651.301 152.467 644.925 150.72 638.113 150.72C631.301 150.72 625.013 152.379 619.249 155.698C613.485 159.017 608.769 163.907 605.101 170.37C601.608 176.658 599.861 184.169 599.861 192.902C599.861 201.635 601.608 209.321 605.101 215.958C608.769 222.421 613.485 227.399 619.249 230.892C625.188 234.385 631.476 236.132 638.113 236.132C644.925 236.132 651.301 234.473 657.239 231.154C663.178 227.661 667.894 222.77 671.387 216.482C674.881 210.019 676.627 202.334 676.627 193.426Z" fill="white"/>-<path d="M778.214 143.384C782.93 135.699 789.043 129.673 796.554 125.306C804.239 120.939 812.972 118.756 822.754 118.756V157.27H813.06C801.532 157.27 792.798 159.977 786.86 165.392C781.096 170.807 778.214 180.239 778.214 193.688V266H741.534V120.852H778.214V143.384Z" fill="white"/>-<path d="M876.28 142.074C880.996 135.087 887.458 129.411 895.668 125.044C904.052 120.677 913.571 118.494 924.226 118.494C936.627 118.494 947.806 121.551 957.762 127.664C967.892 133.777 975.84 142.511 981.604 153.864C987.542 165.043 990.512 178.055 990.512 192.902C990.512 207.749 987.542 220.936 981.604 232.464C975.84 243.817 967.892 252.638 957.762 258.926C947.806 265.214 936.627 268.358 924.226 268.358C913.396 268.358 903.877 266.262 895.668 262.07C887.633 257.703 881.17 252.114 876.28 245.302V266H839.6V72.12H876.28V142.074ZM953.046 192.902C953.046 184.169 951.212 176.658 947.544 170.37C944.05 163.907 939.334 159.017 933.396 155.698C927.632 152.379 921.344 150.72 914.532 150.72C907.894 150.72 901.606 152.467 895.668 155.96C889.904 159.279 885.188 164.169 881.52 170.632C878.026 177.095 876.28 184.693 876.28 193.426C876.28 202.159 878.026 209.757 881.52 216.22C885.188 222.683 889.904 227.661 895.668 231.154C901.606 234.473 907.894 236.132 914.532 236.132C921.344 236.132 927.632 234.385 933.396 230.892C939.334 227.399 944.05 222.421 947.544 215.958C951.212 209.495 953.046 201.81 953.046 192.902Z" fill="white"/>-<path d="M1073.76 268.358C1059.78 268.358 1047.21 265.301 1036.03 259.188C1024.85 252.9 1016.03 244.079 1009.57 232.726C1003.28 221.373 1000.14 208.273 1000.14 193.426C1000.14 178.579 1003.37 165.479 1009.83 154.126C1016.47 142.773 1025.46 134.039 1036.82 127.926C1048.17 121.638 1060.83 118.494 1074.81 118.494C1088.78 118.494 1101.44 121.638 1112.8 127.926C1124.15 134.039 1133.06 142.773 1139.52 154.126C1146.16 165.479 1149.48 178.579 1149.48 193.426C1149.48 208.273 1146.07 221.373 1139.26 232.726C1132.62 244.079 1123.54 252.9 1112.01 259.188C1100.66 265.301 1087.91 268.358 1073.76 268.358ZM1073.76 236.394C1080.4 236.394 1086.6 234.822 1092.36 231.678C1098.3 228.359 1103.01 223.469 1106.51 217.006C1110 210.543 1111.75 202.683 1111.75 193.426C1111.75 179.627 1108.08 169.06 1100.74 161.724C1093.58 154.213 1084.76 150.458 1074.28 150.458C1063.8 150.458 1054.98 154.213 1047.82 161.724C1040.83 169.06 1037.34 179.627 1037.34 193.426C1037.34 207.225 1040.75 217.879 1047.56 225.39C1054.54 232.726 1063.28 236.394 1073.76 236.394Z" fill="white"/>-<path d="M1248.96 118.756C1266.25 118.756 1280.22 124.258 1290.88 135.262C1301.53 146.091 1306.86 161.287 1306.86 180.85V266H1270.18V185.828C1270.18 174.3 1267.3 165.479 1261.53 159.366C1255.77 153.078 1247.91 149.934 1237.95 149.934C1227.82 149.934 1219.79 153.078 1213.85 159.366C1208.08 165.479 1205.2 174.3 1205.2 185.828V266H1168.52V120.852H1205.2V138.93C1210.09 132.642 1216.29 127.751 1223.8 124.258C1231.49 120.59 1239.87 118.756 1248.96 118.756Z" fill="white"/>-<path d="M181.165 139.644V69.822L241.346 35.0571L241.054 104.879L181.165 139.644Z" fill="#60FFD2"/>-<path d="M181.165 69.822V139.644L120.4 104.879V35.0571L181.165 69.822Z" fill="#36B5B4"/>-<path d="M120.4 35.0571L181.165 69.822L241.346 35.0571L181.165 0L120.4 35.0571Z" fill="#5FE4D2"/>-<path d="M240.818 244.173V174.351L300.999 139.586L300.707 209.408L240.818 244.173Z" fill="#71DEFF"/>-<path d="M240.818 174.351V244.173L180.052 209.408V139.586L240.818 174.351Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.351L300.999 139.586L240.818 104.529L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.173V174.351L181.693 139.586L181.401 209.408L121.512 244.173Z" fill="#71DEFF"/>-<path d="M121.512 174.351V244.173L60.7466 209.408V139.586L121.512 174.351Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.351L181.693 139.586L121.512 104.529L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.702V278.88L241.346 244.115L241.054 313.937L181.165 348.702Z" fill="#7D7FE5"/>-<path d="M181.165 278.88V348.702L120.4 313.937V244.115L181.165 278.88Z" fill="#2F31AE"/>-<path d="M120.4 244.115L181.165 278.88L241.346 244.115L181.165 209.057L120.4 244.115Z" fill="#6041D0"/>-<path d="M60.7652 348.702V278.88L120.947 244.115L120.654 313.937L60.7652 348.702Z" fill="#7D7FE5"/>-<path d="M60.7652 278.88V348.702L0 313.937V244.115L60.7652 278.88Z" fill="#2F31AE"/>-<path d="M0 244.115L60.7652 278.88L120.947 244.115L60.7656 209.057L0 244.115Z" fill="#6041D0"/>-<path d="M301.017 348.702V278.88L361.198 244.115L360.906 313.937L301.017 348.702Z" fill="#7D7FE5"/>-<path d="M301.017 278.88V348.702L240.252 313.937V244.115L301.017 278.88Z" fill="#2F31AE"/>-<path d="M240.252 244.115L301.017 278.88L361.198 244.115L301.018 209.057L240.252 244.115Z" fill="#6041D0"/>+<svg width="720" height="175" viewBox="0 0 720 175" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M64.2993 3.57443C72.343 -1.19144 82.3494 -1.19151 90.3931 3.57443L142.163 34.2484C149.93 38.8505 154.692 47.2038 154.692 56.2254V118.775C154.692 127.796 149.93 136.149 142.163 140.752L90.3931 171.426C82.3494 176.192 72.343 176.191 64.2993 171.426L12.5296 140.752C4.76242 136.149 0 127.796 0 118.775V56.2254C0 47.2037 4.76242 38.8505 12.5296 34.2484L64.2993 3.57443ZM81.004 40.286C78.8708 39.0012 76.2016 38.9983 74.0657 40.2786L42.6851 59.0884C38.3192 61.7055 38.3303 68.0312 42.7057 70.6326L74.173 89.3408C74.3089 89.4216 74.3921 89.5681 74.3921 89.726V126.818C74.3922 132.04 80.0912 135.269 84.5774 132.589L115.594 114.057C117.626 112.843 118.87 110.652 118.87 108.287V66.8923C118.87 64.5357 117.635 62.3509 115.615 61.134L81.004 40.286Z" fill="#E6E6E6"/>+<path d="M236.385 133.457C229.22 133.457 222.857 132.223 217.298 129.754C211.862 127.163 207.291 123.645 203.584 119.202C200.002 114.635 197.284 109.513 195.431 103.836C193.577 98.1581 192.651 92.2338 192.651 86.0626C192.651 79.8914 193.577 73.9671 195.431 68.2897C197.284 62.6122 200.002 57.5518 203.584 53.1086C207.291 48.6654 211.862 45.2095 217.298 42.741C222.857 40.1492 229.22 38.8532 236.385 38.8532C245.404 38.8532 253.249 41.0131 259.921 45.3329C266.716 49.6528 271.719 56.3176 274.931 65.3275L256.77 72.3626C255.288 67.6725 252.879 63.9081 249.543 61.0694C246.207 58.1072 241.821 56.6262 236.385 56.6262C230.95 56.6262 226.502 58.0455 223.043 60.8843C219.707 63.723 217.236 67.364 215.63 71.8072C214.024 76.2505 213.221 81.0023 213.221 86.0626C213.221 91.123 214.024 95.9365 215.63 100.503C217.236 104.946 219.707 108.587 223.043 111.426C226.502 114.141 230.95 115.499 236.385 115.499C241.821 115.499 246.207 114.08 249.543 111.241C252.879 108.402 255.288 104.638 256.77 99.9477L274.931 106.983C271.719 115.869 266.716 122.534 259.921 126.977C253.249 131.297 245.404 133.457 236.385 133.457Z" fill="#E6E6E6"/>+<path d="M343.217 131.791L341.735 116.425V74.214C341.735 68.2897 339.943 63.8464 336.361 60.8843C332.778 57.7987 327.774 56.2559 321.35 56.2559C316.408 56.2559 311.528 57.2433 306.71 59.218C302.015 61.0694 297.691 63.9698 293.738 67.9194L282.248 54.4045C288.178 48.8505 294.479 44.901 301.151 42.5559C307.822 40.0874 315.111 38.8532 323.018 38.8532C335.372 38.8532 344.947 42.0005 351.742 48.2951C358.66 54.4663 362.12 63.1059 362.12 74.214V131.791H343.217ZM314.864 133.457C308.069 133.457 302.015 132.223 296.703 129.754C291.514 127.286 287.437 123.83 284.472 119.387C281.631 114.944 280.21 109.76 280.21 103.836C280.21 98.7752 281.26 94.3937 283.36 90.691C285.584 86.9883 288.426 84.0878 291.885 81.9896C294.85 80.1383 298.309 78.8423 302.262 78.1018C306.216 77.2378 310.355 76.8059 314.679 76.8059H343.403V92.1721H317.644C315.42 92.1721 313.196 92.4189 310.972 92.9126C308.749 93.2829 306.772 94.0234 305.042 95.1342C303.807 96.1216 302.757 97.3558 301.892 98.8369C301.151 100.318 300.78 102.046 300.78 104.021C300.78 107.97 302.262 111.118 305.228 113.463C308.316 115.684 312.393 116.795 317.458 116.795C321.906 116.795 325.921 115.808 329.504 113.833C333.21 111.858 336.175 109.143 338.399 105.687C340.623 102.231 341.735 98.3432 341.735 94.0234L348.036 104.206C346.553 110.624 344.206 116.054 340.994 120.498C337.781 124.818 333.952 128.088 329.504 130.31C325.056 132.408 320.176 133.457 314.864 133.457Z" fill="#E6E6E6"/>+<path d="M375.823 131.791V40.5194H396.578V65.1424L392.687 65.6978C393.304 60.3906 395.096 55.7622 398.061 51.8127C401.026 47.7397 404.609 44.5924 408.809 42.3708C413.133 40.0257 417.395 38.8532 421.596 38.8532C424.561 38.8532 427.403 39.2235 430.121 39.964C432.839 40.7046 435.68 41.9388 438.645 43.6667L428.638 62.1802C427.279 61.3162 425.488 60.6374 423.264 60.1437C421.164 59.5266 419.125 59.218 417.148 59.218C414.554 59.218 411.96 59.7117 409.365 60.6991C406.894 61.6865 404.67 63.2293 402.694 65.3275C400.717 67.3023 399.234 69.8942 398.246 73.1032C397.628 74.8311 397.134 77.1144 396.764 79.9532C396.517 82.6685 396.393 86.4946 396.393 91.4315V131.791H375.823Z" fill="#E6E6E6"/>+<path d="M492.002 133.457C487.06 133.457 482.365 132.47 477.918 130.495C473.594 128.52 469.825 125.496 466.613 121.423C463.401 117.227 460.992 111.796 459.386 105.132L464.76 106.427V131.791H444.375V2.75192H464.76V66.068H460.127C461.363 60.2672 463.463 55.3919 466.428 51.4424C469.517 47.3694 473.223 44.2838 477.547 42.1856C481.995 39.964 486.813 38.8532 492.002 38.8532C499.414 38.8532 506.086 40.7663 512.016 44.5924C518.069 48.2951 522.888 53.664 526.47 60.6991C530.053 67.7343 531.845 76.1887 531.845 86.0626C531.845 95.0725 530.177 103.157 526.841 110.315C523.629 117.474 519.058 123.151 513.128 127.348C507.198 131.421 500.156 133.457 492.002 133.457ZM486.998 114.573C491.816 114.573 496.017 113.401 499.6 111.056C503.306 108.711 506.147 105.378 508.124 101.059C510.101 96.7387 511.089 91.7401 511.089 86.0626C511.089 80.3851 510.101 75.3865 508.124 71.0667C506.147 66.7469 503.306 63.4144 499.6 61.0694C496.017 58.7244 491.816 57.5518 486.998 57.5518C482.18 57.5518 477.918 58.7861 474.211 61.2545C470.629 63.5996 467.849 66.932 465.872 71.2518C463.895 75.4482 462.907 80.3851 462.907 86.0626C462.907 91.7401 463.895 96.7387 465.872 101.059C467.849 105.378 470.629 108.711 474.211 111.056C477.918 113.401 482.18 114.573 486.998 114.573Z" fill="#E6E6E6"/>+<path d="M583.567 133.457C574.919 133.457 567.135 131.421 560.217 127.348C553.298 123.275 547.862 117.659 543.909 110.5C540.079 103.342 538.164 95.1959 538.164 86.0626C538.164 76.9293 540.079 68.7834 543.909 61.6248C547.862 54.4663 553.237 48.9122 560.032 44.9627C566.95 40.8897 574.795 38.8532 583.567 38.8532C592.462 38.8532 600.245 40.8897 606.917 44.9627C613.711 48.9122 619.086 54.4663 623.039 61.6248C626.992 68.7834 628.969 76.9293 628.969 86.0626C628.969 95.1959 626.992 103.342 623.039 110.5C619.209 117.659 613.835 123.275 606.917 127.348C600.122 131.421 592.338 133.457 583.567 133.457ZM583.752 115.314C588.817 115.314 593.203 114.141 596.909 111.796C600.616 109.451 603.457 106.057 605.434 101.614C607.411 97.1707 608.399 91.9869 608.399 86.0626C608.399 80.0149 607.411 74.8311 605.434 70.5113C603.457 66.068 600.616 62.6739 596.909 60.3289C593.203 57.9838 588.817 56.8113 583.752 56.8113C578.44 56.8113 573.93 58.0455 570.224 60.514C566.518 62.859 563.676 66.1915 561.699 70.5113C559.723 74.8311 558.734 80.0149 558.734 86.0626C558.734 91.9869 559.723 97.1707 561.699 101.614C563.676 106.057 566.518 109.451 570.224 111.796C573.93 114.141 578.44 115.314 583.752 115.314Z" fill="#E6E6E6"/>+<path d="M639.573 131.791V40.5194H660.143V60.6991L656.437 61.6248C658.043 56.3176 660.39 51.9978 663.479 48.6654C666.567 45.3329 670.15 42.8645 674.227 41.26C678.427 39.6555 682.813 38.8532 687.384 38.8532C697.639 38.8532 705.607 41.8154 711.29 47.7397C717.097 53.5406 720 61.8716 720 72.7329V131.791H699.43V80.3234C699.43 72.1775 697.947 66.1915 694.982 62.3653C692.017 58.5392 687.446 56.6262 681.269 56.6262C676.698 56.6262 672.806 57.737 669.594 59.9586C666.505 62.0568 664.158 65.3892 662.552 69.9559C660.946 74.5225 660.143 80.3234 660.143 87.3585V131.791H639.573Z" fill="#E6E6E6"/></svg>diff --git a/apps/erp/public/carbon-word-light.png b/apps/erp/public/carbon-word-light.pngdeleted file mode 100644index becd8f13bb..0000000000Binary files a/apps/erp/public/carbon-word-light.png and /dev/null differdiff --git a/apps/erp/public/carbon-word-light.svg b/apps/erp/public/carbon-word-light.svgindex 3e899a2d1b..3fd85675c9 100644--- a/apps/erp/public/carbon-word-light.svg+++ b/apps/erp/public/carbon-word-light.svg@@ -1,26 +1,9 @@-<svg width="1307" height="349" viewBox="0 0 1307 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M412.646 193.426C412.646 178.405 415.703 165.305 421.816 154.126C427.929 142.773 436.401 134.039 447.23 127.926C458.059 121.638 470.461 118.494 484.434 118.494C502.425 118.494 517.271 123.035 528.974 132.118C540.851 141.026 548.799 153.602 552.816 169.846H513.254C511.158 163.558 507.577 158.667 502.512 155.174C497.621 151.506 491.508 149.672 484.172 149.672C473.692 149.672 465.395 153.515 459.282 161.2C453.169 168.711 450.112 179.453 450.112 193.426C450.112 207.225 453.169 217.967 459.282 225.652C465.395 233.163 473.692 236.918 484.172 236.918C499.019 236.918 508.713 230.281 513.254 217.006H552.816C548.799 232.726 540.851 245.215 528.974 254.472C517.097 263.729 502.25 268.358 484.434 268.358C470.461 268.358 458.059 265.301 447.23 259.188C436.401 252.9 427.929 244.167 421.816 232.988C415.703 221.635 412.646 208.447 412.646 193.426Z" fill="#212278"/>-<path d="M562.395 192.902C562.395 178.23 565.277 165.217 571.041 153.864C576.98 142.511 584.927 133.777 594.883 127.664C605.014 121.551 616.28 118.494 628.681 118.494C639.511 118.494 648.943 120.677 656.977 125.044C665.187 129.411 671.737 134.913 676.627 141.55V120.852H713.569V266H676.627V244.778C671.911 251.59 665.361 257.267 656.977 261.808C648.768 266.175 639.249 268.358 628.419 268.358C616.193 268.358 605.014 265.214 594.883 258.926C584.927 252.638 576.98 243.817 571.041 232.464C565.277 220.936 562.395 207.749 562.395 192.902ZM676.627 193.426C676.627 184.518 674.881 176.92 671.387 170.632C667.894 164.169 663.178 159.279 657.239 155.96C651.301 152.467 644.925 150.72 638.113 150.72C631.301 150.72 625.013 152.379 619.249 155.698C613.485 159.017 608.769 163.907 605.101 170.37C601.608 176.658 599.861 184.169 599.861 192.902C599.861 201.635 601.608 209.321 605.101 215.958C608.769 222.421 613.485 227.399 619.249 230.892C625.188 234.385 631.476 236.132 638.113 236.132C644.925 236.132 651.301 234.473 657.239 231.154C663.178 227.661 667.894 222.77 671.387 216.482C674.881 210.019 676.627 202.334 676.627 193.426Z" fill="#212278"/>-<path d="M778.214 143.384C782.93 135.699 789.043 129.673 796.554 125.306C804.239 120.939 812.972 118.756 822.754 118.756V157.27H813.06C801.532 157.27 792.798 159.977 786.86 165.392C781.096 170.807 778.214 180.239 778.214 193.688V266H741.534V120.852H778.214V143.384Z" fill="#212278"/>-<path d="M876.28 142.074C880.996 135.087 887.458 129.411 895.668 125.044C904.052 120.677 913.571 118.494 924.226 118.494C936.627 118.494 947.806 121.551 957.762 127.664C967.892 133.777 975.84 142.511 981.604 153.864C987.542 165.043 990.512 178.055 990.512 192.902C990.512 207.749 987.542 220.936 981.604 232.464C975.84 243.817 967.892 252.638 957.762 258.926C947.806 265.214 936.627 268.358 924.226 268.358C913.396 268.358 903.877 266.262 895.668 262.07C887.633 257.703 881.17 252.114 876.28 245.302V266H839.6V72.12H876.28V142.074ZM953.046 192.902C953.046 184.169 951.212 176.658 947.544 170.37C944.05 163.907 939.334 159.017 933.396 155.698C927.632 152.379 921.344 150.72 914.532 150.72C907.894 150.72 901.606 152.467 895.668 155.96C889.904 159.279 885.188 164.169 881.52 170.632C878.026 177.095 876.28 184.693 876.28 193.426C876.28 202.159 878.026 209.757 881.52 216.22C885.188 222.683 889.904 227.661 895.668 231.154C901.606 234.473 907.894 236.132 914.532 236.132C921.344 236.132 927.632 234.385 933.396 230.892C939.334 227.399 944.05 222.421 947.544 215.958C951.212 209.495 953.046 201.81 953.046 192.902Z" fill="#212278"/>-<path d="M1073.76 268.358C1059.78 268.358 1047.21 265.301 1036.03 259.188C1024.85 252.9 1016.03 244.079 1009.57 232.726C1003.28 221.373 1000.14 208.273 1000.14 193.426C1000.14 178.579 1003.37 165.479 1009.83 154.126C1016.47 142.773 1025.46 134.039 1036.82 127.926C1048.17 121.638 1060.83 118.494 1074.81 118.494C1088.78 118.494 1101.44 121.638 1112.8 127.926C1124.15 134.039 1133.06 142.773 1139.52 154.126C1146.16 165.479 1149.48 178.579 1149.48 193.426C1149.48 208.273 1146.07 221.373 1139.26 232.726C1132.62 244.079 1123.54 252.9 1112.01 259.188C1100.66 265.301 1087.91 268.358 1073.76 268.358ZM1073.76 236.394C1080.4 236.394 1086.6 234.822 1092.36 231.678C1098.3 228.359 1103.01 223.469 1106.51 217.006C1110 210.543 1111.75 202.683 1111.75 193.426C1111.75 179.627 1108.08 169.06 1100.74 161.724C1093.58 154.213 1084.76 150.458 1074.28 150.458C1063.8 150.458 1054.98 154.213 1047.82 161.724C1040.83 169.06 1037.34 179.627 1037.34 193.426C1037.34 207.225 1040.75 217.879 1047.56 225.39C1054.54 232.726 1063.28 236.394 1073.76 236.394Z" fill="#212278"/>-<path d="M1248.96 118.756C1266.25 118.756 1280.22 124.258 1290.88 135.262C1301.53 146.091 1306.86 161.287 1306.86 180.85V266H1270.18V185.828C1270.18 174.3 1267.3 165.479 1261.53 159.366C1255.77 153.078 1247.91 149.934 1237.95 149.934C1227.82 149.934 1219.79 153.078 1213.85 159.366C1208.08 165.479 1205.2 174.3 1205.2 185.828V266H1168.52V120.852H1205.2V138.93C1210.09 132.642 1216.29 127.751 1223.8 124.258C1231.49 120.59 1239.87 118.756 1248.96 118.756Z" fill="#212278"/>-<path d="M181.165 139.644V69.822L241.346 35.0571L241.054 104.879L181.165 139.644Z" fill="#60FFD2"/>-<path d="M181.165 69.822V139.644L120.4 104.879V35.0571L181.165 69.822Z" fill="#36B5B4"/>-<path d="M120.4 35.0571L181.165 69.822L241.346 35.0571L181.165 0L120.4 35.0571Z" fill="#5FE4D2"/>-<path d="M240.818 244.173V174.351L300.999 139.586L300.707 209.408L240.818 244.173Z" fill="#71DEFF"/>-<path d="M240.818 174.351V244.173L180.052 209.408V139.586L240.818 174.351Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.351L300.999 139.586L240.818 104.529L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.173V174.351L181.693 139.586L181.401 209.408L121.512 244.173Z" fill="#71DEFF"/>-<path d="M121.512 174.351V244.173L60.7466 209.408V139.586L121.512 174.351Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.351L181.693 139.586L121.512 104.529L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.702V278.88L241.346 244.115L241.054 313.937L181.165 348.702Z" fill="#7D7FE5"/>-<path d="M181.165 278.88V348.702L120.4 313.937V244.115L181.165 278.88Z" fill="#2F31AE"/>-<path d="M120.4 244.115L181.165 278.88L241.346 244.115L181.165 209.057L120.4 244.115Z" fill="#6041D0"/>-<path d="M60.7652 348.702V278.88L120.947 244.115L120.654 313.937L60.7652 348.702Z" fill="#7D7FE5"/>-<path d="M60.7652 278.88V348.702L-1.52588e-05 313.937V244.115L60.7652 278.88Z" fill="#2F31AE"/>-<path d="M-1.52588e-05 244.115L60.7652 278.88L120.947 244.115L60.7656 209.057L-1.52588e-05 244.115Z" fill="#6041D0"/>-<path d="M301.017 348.702V278.88L361.198 244.115L360.906 313.937L301.017 348.702Z" fill="#7D7FE5"/>-<path d="M301.017 278.88V348.702L240.252 313.937V244.115L301.017 278.88Z" fill="#2F31AE"/>-<path d="M240.252 244.115L301.017 278.88L361.198 244.115L301.018 209.057L240.252 244.115Z" fill="#6041D0"/>+<svg width="720" height="175" viewBox="0 0 720 175" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M64.2993 3.57443C72.343 -1.19144 82.3494 -1.19151 90.3931 3.57443L142.163 34.2484C149.93 38.8505 154.692 47.2038 154.692 56.2254V118.775C154.692 127.796 149.93 136.149 142.163 140.752L90.3931 171.426C82.3494 176.192 72.343 176.191 64.2993 171.426L12.5296 140.752C4.76242 136.149 0 127.796 0 118.775V56.2254C0 47.2037 4.76242 38.8505 12.5296 34.2484L64.2993 3.57443ZM81.004 40.286C78.8708 39.0012 76.2016 38.9983 74.0657 40.2786L42.6851 59.0884C38.3192 61.7055 38.3303 68.0312 42.7057 70.6326L74.173 89.3408C74.3089 89.4216 74.3921 89.5681 74.3921 89.726V126.818C74.3922 132.04 80.0912 135.269 84.5774 132.589L115.594 114.057C117.626 112.843 118.87 110.652 118.87 108.287V66.8923C118.87 64.5357 117.635 62.3509 115.615 61.134L81.004 40.286Z" fill="#101A24"/>+<path d="M236.385 133.457C229.22 133.457 222.857 132.223 217.298 129.754C211.862 127.163 207.291 123.645 203.584 119.202C200.002 114.635 197.284 109.513 195.431 103.836C193.577 98.1581 192.651 92.2338 192.651 86.0626C192.651 79.8914 193.577 73.9671 195.431 68.2897C197.284 62.6122 200.002 57.5518 203.584 53.1086C207.291 48.6654 211.862 45.2095 217.298 42.741C222.857 40.1492 229.22 38.8532 236.385 38.8532C245.404 38.8532 253.249 41.0131 259.921 45.3329C266.716 49.6528 271.719 56.3176 274.931 65.3275L256.77 72.3626C255.288 67.6725 252.879 63.9081 249.543 61.0694C246.207 58.1072 241.821 56.6262 236.385 56.6262C230.95 56.6262 226.502 58.0455 223.043 60.8843C219.707 63.723 217.236 67.364 215.63 71.8072C214.024 76.2505 213.221 81.0023 213.221 86.0626C213.221 91.123 214.024 95.9365 215.63 100.503C217.236 104.946 219.707 108.587 223.043 111.426C226.502 114.141 230.95 115.499 236.385 115.499C241.821 115.499 246.207 114.08 249.543 111.241C252.879 108.402 255.288 104.638 256.77 99.9477L274.931 106.983C271.719 115.869 266.716 122.534 259.921 126.977C253.249 131.297 245.404 133.457 236.385 133.457Z" fill="#101A24"/>+<path d="M343.217 131.791L341.735 116.425V74.214C341.735 68.2897 339.943 63.8464 336.361 60.8843C332.778 57.7987 327.774 56.2559 321.35 56.2559C316.408 56.2559 311.528 57.2433 306.71 59.218C302.015 61.0694 297.691 63.9698 293.738 67.9194L282.248 54.4045C288.178 48.8505 294.479 44.901 301.151 42.5559C307.822 40.0874 315.111 38.8532 323.018 38.8532C335.372 38.8532 344.947 42.0005 351.742 48.2951C358.66 54.4663 362.12 63.1059 362.12 74.214V131.791H343.217ZM314.864 133.457C308.069 133.457 302.015 132.223 296.703 129.754C291.514 127.286 287.437 123.83 284.472 119.387C281.631 114.944 280.21 109.76 280.21 103.836C280.21 98.7752 281.26 94.3937 283.36 90.691C285.584 86.9883 288.426 84.0878 291.885 81.9896C294.85 80.1383 298.309 78.8423 302.262 78.1018C306.216 77.2378 310.355 76.8059 314.679 76.8059H343.403V92.1721H317.644C315.42 92.1721 313.196 92.4189 310.972 92.9126C308.749 93.2829 306.772 94.0234 305.042 95.1342C303.807 96.1216 302.757 97.3558 301.892 98.8369C301.151 100.318 300.78 102.046 300.78 104.021C300.78 107.97 302.262 111.118 305.228 113.463C308.316 115.684 312.393 116.795 317.458 116.795C321.906 116.795 325.921 115.808 329.504 113.833C333.21 111.858 336.175 109.143 338.399 105.687C340.623 102.231 341.735 98.3432 341.735 94.0234L348.036 104.206C346.553 110.624 344.206 116.054 340.994 120.498C337.781 124.818 333.952 128.088 329.504 130.31C325.056 132.408 320.176 133.457 314.864 133.457Z" fill="#101A24"/>+<path d="M375.823 131.791V40.5194H396.578V65.1424L392.687 65.6978C393.304 60.3906 395.096 55.7622 398.061 51.8127C401.026 47.7397 404.609 44.5924 408.809 42.3708C413.133 40.0257 417.395 38.8532 421.596 38.8532C424.561 38.8532 427.403 39.2235 430.121 39.964C432.839 40.7046 435.68 41.9388 438.645 43.6667L428.638 62.1802C427.279 61.3162 425.488 60.6374 423.264 60.1437C421.164 59.5266 419.125 59.218 417.148 59.218C414.554 59.218 411.96 59.7117 409.365 60.6991C406.894 61.6865 404.67 63.2293 402.694 65.3275C400.717 67.3023 399.234 69.8942 398.246 73.1032C397.628 74.8311 397.134 77.1144 396.764 79.9532C396.517 82.6685 396.393 86.4946 396.393 91.4315V131.791H375.823Z" fill="#101A24"/>+<path d="M492.002 133.457C487.06 133.457 482.365 132.47 477.918 130.495C473.594 128.52 469.825 125.496 466.613 121.423C463.401 117.227 460.992 111.796 459.386 105.132L464.76 106.427V131.791H444.375V2.75192H464.76V66.068H460.127C461.363 60.2672 463.463 55.3919 466.428 51.4424C469.517 47.3694 473.223 44.2838 477.547 42.1856C481.995 39.964 486.813 38.8532 492.002 38.8532C499.414 38.8532 506.086 40.7663 512.016 44.5924C518.069 48.2951 522.888 53.664 526.47 60.6991C530.053 67.7343 531.845 76.1887 531.845 86.0626C531.845 95.0725 530.177 103.157 526.841 110.315C523.629 117.474 519.058 123.151 513.128 127.348C507.198 131.421 500.156 133.457 492.002 133.457ZM486.998 114.573C491.816 114.573 496.017 113.401 499.6 111.056C503.306 108.711 506.147 105.378 508.124 101.059C510.101 96.7387 511.089 91.7401 511.089 86.0626C511.089 80.3851 510.101 75.3865 508.124 71.0667C506.147 66.7469 503.306 63.4144 499.6 61.0694C496.017 58.7244 491.816 57.5518 486.998 57.5518C482.18 57.5518 477.918 58.7861 474.211 61.2545C470.629 63.5996 467.849 66.932 465.872 71.2518C463.895 75.4482 462.907 80.3851 462.907 86.0626C462.907 91.7401 463.895 96.7387 465.872 101.059C467.849 105.378 470.629 108.711 474.211 111.056C477.918 113.401 482.18 114.573 486.998 114.573Z" fill="#101A24"/>+<path d="M583.567 133.457C574.919 133.457 567.135 131.421 560.217 127.348C553.298 123.275 547.862 117.659 543.909 110.5C540.079 103.342 538.164 95.1959 538.164 86.0626C538.164 76.9293 540.079 68.7834 543.909 61.6248C547.862 54.4663 553.237 48.9122 560.032 44.9627C566.95 40.8897 574.795 38.8532 583.567 38.8532C592.462 38.8532 600.245 40.8897 606.917 44.9627C613.711 48.9122 619.086 54.4663 623.039 61.6248C626.992 68.7834 628.969 76.9293 628.969 86.0626C628.969 95.1959 626.992 103.342 623.039 110.5C619.209 117.659 613.835 123.275 606.917 127.348C600.122 131.421 592.338 133.457 583.567 133.457ZM583.752 115.314C588.817 115.314 593.203 114.141 596.909 111.796C600.616 109.451 603.457 106.057 605.434 101.614C607.411 97.1707 608.399 91.9869 608.399 86.0626C608.399 80.0149 607.411 74.8311 605.434 70.5113C603.457 66.068 600.616 62.6739 596.909 60.3289C593.203 57.9838 588.817 56.8113 583.752 56.8113C578.44 56.8113 573.93 58.0455 570.224 60.514C566.518 62.859 563.676 66.1915 561.699 70.5113C559.723 74.8311 558.734 80.0149 558.734 86.0626C558.734 91.9869 559.723 97.1707 561.699 101.614C563.676 106.057 566.518 109.451 570.224 111.796C573.93 114.141 578.44 115.314 583.752 115.314Z" fill="#101A24"/>+<path d="M639.573 131.791V40.5194H660.143V60.6991L656.437 61.6248C658.043 56.3176 660.39 51.9978 663.479 48.6654C666.567 45.3329 670.15 42.8645 674.227 41.26C678.427 39.6555 682.813 38.8532 687.384 38.8532C697.639 38.8532 705.607 41.8154 711.29 47.7397C717.097 53.5406 720 61.8716 720 72.7329V131.791H699.43V80.3234C699.43 72.1775 697.947 66.1915 694.982 62.3653C692.017 58.5392 687.446 56.6262 681.269 56.6262C676.698 56.6262 672.806 57.737 669.594 59.9586C666.505 62.0568 664.158 65.3892 662.552 69.9559C660.946 74.5225 660.143 80.3234 660.143 87.3585V131.791H639.573Z" fill="#101A24"/></svg>diff --git a/apps/erp/public/carbon-word-only-dark.svg b/apps/erp/public/carbon-word-only-dark.svgdeleted file mode 100644index eaab7b0993..0000000000--- a/apps/erp/public/carbon-word-only-dark.svg+++ /dev/null@@ -1,8 +0,0 @@-<svg width="944" height="208" viewBox="0 0 944 208" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M0.517578 128.877C0.517578 113.031 3.74102 99.213 10.1879 87.4213C16.6348 75.4453 25.5683 66.2331 36.9885 59.7845C48.4086 53.1516 61.4866 49.8352 76.2223 49.8352C95.1945 49.8352 110.851 54.6256 123.192 64.2063C135.718 73.6029 144.099 86.8686 148.335 104.003H106.615C104.404 97.3706 100.628 92.2117 95.2866 88.5268C90.1291 84.6576 83.6823 82.723 75.946 82.723C64.8942 82.723 56.1449 86.7764 49.698 94.8832C43.2511 102.806 40.0277 114.137 40.0277 128.877C40.0277 143.432 43.2511 154.763 49.698 162.87C56.1449 170.792 64.8942 174.754 75.946 174.754C91.6027 174.754 101.826 167.752 106.615 153.75H148.335C144.099 170.332 135.718 183.505 123.192 193.27C110.667 203.035 95.0103 207.918 76.2223 207.918C61.4866 207.918 48.4086 204.694 36.9885 198.245C25.5683 191.612 16.6348 182.4 10.1879 170.608C3.74102 158.632 0.517578 144.722 0.517578 128.877Z" fill="#E0E0E0"/>-<path d="M158.437 128.324C158.437 112.847 161.476 99.1209 167.555 87.1449C173.818 75.169 182.199 65.9567 192.698 59.5081C203.381 53.0595 215.262 49.8352 228.34 49.8352C239.76 49.8352 249.707 52.1383 258.18 56.7444C266.837 61.3505 273.744 67.1543 278.902 74.1556V52.3225H317.859V205.431H278.902V183.045C273.928 190.23 267.021 196.218 258.18 201.009C249.522 205.615 239.484 207.918 228.063 207.918C215.17 207.918 203.381 204.602 192.698 197.969C182.199 191.336 173.818 182.031 167.555 170.055C161.476 157.895 158.437 143.985 158.437 128.324ZM278.902 128.877C278.902 119.48 277.06 111.465 273.376 104.833C269.692 98.0154 264.719 92.8565 258.456 89.3559C252.193 85.671 245.47 83.8285 238.286 83.8285C231.103 83.8285 224.472 85.5788 218.393 89.0795C212.315 92.5802 207.341 97.7391 203.473 104.556C199.789 111.189 197.947 119.112 197.947 128.324C197.947 137.536 199.789 145.643 203.473 152.644C207.341 159.461 212.315 164.712 218.393 168.397C224.656 172.082 231.287 173.925 238.286 173.925C245.47 173.925 252.193 172.174 258.456 168.674C264.719 164.989 269.692 159.83 273.376 153.197C277.06 146.38 278.902 138.273 278.902 128.877Z" fill="#E0E0E0"/>-<path d="M386.031 76.0902C391.004 67.9834 397.451 61.6269 405.371 57.0208C413.476 52.4146 422.686 50.1116 433.001 50.1116V90.7377H422.778C410.621 90.7377 401.411 93.5935 395.148 99.3051C389.07 105.017 386.031 114.966 386.031 129.153V205.431H347.349V52.3225H386.031V76.0902Z" fill="#E0E0E0"/>-<path d="M489.447 74.7083C494.42 67.3385 501.235 61.3505 509.893 56.7444C518.734 52.1383 528.773 49.8352 540.009 49.8352C553.087 49.8352 564.875 53.0595 575.374 59.5081C586.058 65.9567 594.439 75.169 600.517 87.1449C606.78 98.9367 609.911 112.663 609.911 128.324C609.911 143.985 606.78 157.895 600.517 170.055C594.439 182.031 586.058 191.336 575.374 197.969C564.875 204.602 553.087 207.918 540.009 207.918C528.589 207.918 518.55 205.707 509.893 201.285C501.42 196.679 494.604 190.783 489.447 183.598V205.431H450.766V0.917969H489.447V74.7083ZM570.401 128.324C570.401 119.112 568.467 111.189 564.599 104.556C560.915 97.7391 555.942 92.5802 549.679 89.0795C543.601 85.5788 536.969 83.8285 529.786 83.8285C522.786 83.8285 516.155 85.671 509.893 89.3559C503.814 92.8565 498.841 98.0154 494.973 104.833C491.289 111.65 489.447 119.664 489.447 128.877C489.447 138.089 491.289 146.104 494.973 152.921C498.841 159.738 503.814 164.989 509.893 168.674C516.155 172.174 522.786 173.925 529.786 173.925C536.969 173.925 543.601 172.082 549.679 168.397C555.942 164.712 560.915 159.461 564.599 152.644C568.467 145.827 570.401 137.72 570.401 128.324Z" fill="#E0E0E0"/>-<path d="M697.7 207.918C682.964 207.918 669.702 204.694 657.913 198.245C646.125 191.612 636.823 182.308 630.007 170.332C623.376 158.356 620.061 144.537 620.061 128.877C620.061 113.216 623.468 99.3973 630.284 87.4213C637.283 75.4453 646.769 66.2331 658.742 59.7845C670.715 53.1516 684.069 49.8352 698.805 49.8352C713.54 49.8352 726.895 53.1516 738.867 59.7845C750.84 66.2331 760.234 75.4453 767.049 87.4213C774.049 99.3973 777.549 113.216 777.549 128.877C777.549 144.537 773.957 158.356 766.773 170.332C759.774 182.308 750.196 191.612 738.039 198.245C726.066 204.694 712.619 207.918 697.7 207.918ZM697.7 174.201C704.699 174.201 711.238 172.543 717.316 169.226C723.579 165.726 728.552 160.567 732.236 153.75C735.92 146.933 737.762 138.642 737.762 128.877C737.762 114.321 733.894 103.174 726.158 95.436C718.606 87.5134 709.304 83.5521 698.252 83.5521C687.2 83.5521 677.898 87.5134 670.346 95.436C662.979 103.174 659.295 114.321 659.295 128.877C659.295 143.432 662.886 154.671 670.07 162.594C677.438 170.332 686.648 174.201 697.7 174.201Z" fill="#E0E0E0"/>-<path d="M882.456 50.1116C900.692 50.1116 915.428 55.9153 926.664 67.5228C937.9 78.946 943.518 94.9754 943.518 115.611V205.431H904.836V120.862C904.836 108.702 901.797 99.3973 895.719 92.9487C889.64 86.3158 881.351 82.9994 870.852 82.9994C860.169 82.9994 851.696 86.3158 845.433 92.9487C839.355 99.3973 836.315 108.702 836.315 120.862V205.431H797.634V52.3225H836.315V71.3919C841.473 64.7591 848.012 59.6002 855.932 55.9153C864.037 52.0461 872.878 50.1116 882.456 50.1116Z" fill="#E0E0E0"/>-</svg>diff --git a/apps/erp/public/carbon-word-only-light.svg b/apps/erp/public/carbon-word-only-light.svgdeleted file mode 100644index b9bb1c59c8..0000000000--- a/apps/erp/public/carbon-word-only-light.svg+++ /dev/null@@ -1,8 +0,0 @@-<svg width="944" height="208" viewBox="0 0 944 208" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M0.517578 128.877C0.517578 113.031 3.74102 99.213 10.1879 87.4213C16.6348 75.4453 25.5683 66.2331 36.9885 59.7845C48.4086 53.1516 61.4866 49.8352 76.2223 49.8352C95.1945 49.8352 110.851 54.6256 123.192 64.2063C135.718 73.6029 144.099 86.8686 148.335 104.003H106.615C104.404 97.3706 100.628 92.2117 95.2866 88.5268C90.1291 84.6576 83.6823 82.723 75.946 82.723C64.8942 82.723 56.1449 86.7764 49.698 94.8832C43.2511 102.806 40.0277 114.137 40.0277 128.877C40.0277 143.432 43.2511 154.763 49.698 162.87C56.1449 170.792 64.8942 174.754 75.946 174.754C91.6027 174.754 101.826 167.752 106.615 153.75H148.335C144.099 170.332 135.718 183.505 123.192 193.27C110.667 203.035 95.0103 207.918 76.2223 207.918C61.4866 207.918 48.4086 204.694 36.9885 198.245C25.5683 191.612 16.6348 182.4 10.1879 170.608C3.74102 158.632 0.517578 144.722 0.517578 128.877Z" fill="#383838"/>-<path d="M158.437 128.324C158.437 112.847 161.476 99.1209 167.555 87.1449C173.818 75.169 182.199 65.9567 192.698 59.5081C203.381 53.0595 215.262 49.8352 228.34 49.8352C239.76 49.8352 249.707 52.1383 258.18 56.7444C266.837 61.3505 273.744 67.1543 278.902 74.1556V52.3225H317.859V205.431H278.902V183.045C273.928 190.23 267.021 196.218 258.18 201.009C249.522 205.615 239.484 207.918 228.063 207.918C215.17 207.918 203.381 204.602 192.698 197.969C182.199 191.336 173.818 182.031 167.555 170.055C161.476 157.895 158.437 143.985 158.437 128.324ZM278.902 128.877C278.902 119.48 277.06 111.465 273.376 104.833C269.692 98.0154 264.719 92.8565 258.456 89.3559C252.193 85.671 245.47 83.8285 238.286 83.8285C231.103 83.8285 224.472 85.5788 218.393 89.0795C212.315 92.5802 207.341 97.7391 203.473 104.556C199.789 111.189 197.947 119.112 197.947 128.324C197.947 137.536 199.789 145.643 203.473 152.644C207.341 159.461 212.315 164.712 218.393 168.397C224.656 172.082 231.287 173.925 238.286 173.925C245.47 173.925 252.193 172.174 258.456 168.674C264.719 164.989 269.692 159.83 273.376 153.197C277.06 146.38 278.902 138.273 278.902 128.877Z" fill="#383838"/>-<path d="M386.031 76.0902C391.004 67.9834 397.451 61.6269 405.371 57.0208C413.476 52.4146 422.686 50.1116 433.001 50.1116V90.7377H422.778C410.621 90.7377 401.411 93.5935 395.148 99.3051C389.07 105.017 386.031 114.966 386.031 129.153V205.431H347.349V52.3225H386.031V76.0902Z" fill="#383838"/>-<path d="M489.447 74.7083C494.42 67.3385 501.235 61.3505 509.893 56.7444C518.734 52.1383 528.773 49.8352 540.009 49.8352C553.087 49.8352 564.875 53.0595 575.374 59.5081C586.058 65.9567 594.439 75.169 600.517 87.1449C606.78 98.9367 609.911 112.663 609.911 128.324C609.911 143.985 606.78 157.895 600.517 170.055C594.439 182.031 586.058 191.336 575.374 197.969C564.875 204.602 553.087 207.918 540.009 207.918C528.589 207.918 518.55 205.707 509.893 201.285C501.42 196.679 494.604 190.783 489.447 183.598V205.431H450.766V0.917969H489.447V74.7083ZM570.401 128.324C570.401 119.112 568.467 111.189 564.599 104.556C560.915 97.7391 555.942 92.5802 549.679 89.0795C543.601 85.5788 536.969 83.8285 529.786 83.8285C522.786 83.8285 516.155 85.671 509.893 89.3559C503.814 92.8565 498.841 98.0154 494.973 104.833C491.289 111.65 489.447 119.664 489.447 128.877C489.447 138.089 491.289 146.104 494.973 152.921C498.841 159.738 503.814 164.989 509.893 168.674C516.155 172.174 522.786 173.925 529.786 173.925C536.969 173.925 543.601 172.082 549.679 168.397C555.942 164.712 560.915 159.461 564.599 152.644C568.467 145.827 570.401 137.72 570.401 128.324Z" fill="#383838"/>-<path d="M697.7 207.918C682.964 207.918 669.702 204.694 657.913 198.245C646.125 191.612 636.823 182.308 630.007 170.332C623.376 158.356 620.061 144.537 620.061 128.877C620.061 113.216 623.468 99.3973 630.284 87.4213C637.283 75.4453 646.769 66.2331 658.742 59.7845C670.715 53.1516 684.069 49.8352 698.805 49.8352C713.54 49.8352 726.895 53.1516 738.867 59.7845C750.84 66.2331 760.234 75.4453 767.049 87.4213C774.049 99.3973 777.549 113.216 777.549 128.877C777.549 144.537 773.957 158.356 766.773 170.332C759.774 182.308 750.196 191.612 738.039 198.245C726.066 204.694 712.619 207.918 697.7 207.918ZM697.7 174.201C704.699 174.201 711.238 172.543 717.316 169.226C723.579 165.726 728.552 160.567 732.236 153.75C735.92 146.933 737.762 138.642 737.762 128.877C737.762 114.321 733.894 103.174 726.158 95.436C718.606 87.5134 709.304 83.5521 698.252 83.5521C687.2 83.5521 677.898 87.5134 670.346 95.436C662.979 103.174 659.295 114.321 659.295 128.877C659.295 143.432 662.886 154.671 670.07 162.594C677.438 170.332 686.648 174.201 697.7 174.201Z" fill="#383838"/>-<path d="M882.456 50.1116C900.692 50.1116 915.428 55.9153 926.664 67.5228C937.9 78.946 943.518 94.9754 943.518 115.611V205.431H904.836V120.862C904.836 108.702 901.797 99.3973 895.719 92.9487C889.64 86.3158 881.351 82.9994 870.852 82.9994C860.169 82.9994 851.696 86.3158 845.433 92.9487C839.355 99.3973 836.315 108.702 836.315 120.862V205.431H797.634V52.3225H836.315V71.3919C841.473 64.7591 848.012 59.6002 855.932 55.9153C864.037 52.0461 872.878 50.1116 882.456 50.1116Z" fill="#383838"/>-</svg>diff --git a/apps/erp/public/favicon-16x16.png b/apps/erp/public/favicon-16x16.pngnew file mode 100644index 0000000000..7f08a7eae3Binary files /dev/null and b/apps/erp/public/favicon-16x16.png differdiff --git a/apps/erp/public/favicon-32x32.png b/apps/erp/public/favicon-32x32.pngnew file mode 100644index 0000000000..348b196709Binary files /dev/null and b/apps/erp/public/favicon-32x32.png differdiff --git a/apps/erp/public/favicon-96x96.png b/apps/erp/public/favicon-96x96.pngdeleted file mode 100644index c36c27be04..0000000000Binary files a/apps/erp/public/favicon-96x96.png and /dev/null differdiff --git a/apps/erp/public/favicon.ico b/apps/erp/public/favicon.icoindex a87e92b575..644a0d8ed5 100644Binary files a/apps/erp/public/favicon.ico and b/apps/erp/public/favicon.ico differdiff --git a/apps/erp/public/favicon.svg b/apps/erp/public/favicon.svgindex 1f953c23a1..047b926154 100644--- a/apps/erp/public/favicon.svg+++ b/apps/erp/public/favicon.svg@@ -1,22 +1,3 @@-<svg xmlns="http://www.w3.org/2000/svg" version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" width="362" height="349"><svg width="362" height="349" viewBox="0 0 362 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M181.165 139.643V69.8213L241.346 35.0564L241.054 104.878L181.165 139.643Z" fill="#60FFD2"></path>-<path d="M181.165 69.8213V139.643L120.4 104.878V35.0564L181.165 69.8213Z" fill="#36B5B4"></path>-<path d="M120.4 35.0565L181.165 69.8214L241.347 35.0565L181.165 -0.000610352L120.4 35.0565Z" fill="#5FE4D2"></path>-<path d="M240.818 244.172V174.35L300.999 139.585L300.707 209.407L240.818 244.172Z" fill="#71DEFF"></path>-<path d="M240.818 174.35V244.172L180.052 209.407V139.585L240.818 174.35Z" fill="#3877C5"></path>-<path d="M180.052 139.586L240.818 174.35L300.999 139.586L240.818 104.528L180.052 139.586Z" fill="#4EAADE"></path>-<path d="M121.512 244.172V174.35L181.693 139.585L181.401 209.407L121.512 244.172Z" fill="#71DEFF"></path>-<path d="M121.512 174.35V244.172L60.7466 209.407V139.585L121.512 174.35Z" fill="#3877C5"></path>-<path d="M60.7466 139.586L121.512 174.35L181.694 139.586L121.512 104.528L60.7466 139.586Z" fill="#4EAADE"></path>-<path d="M181.165 348.701V278.879L241.346 244.114L241.054 313.936L181.165 348.701Z" fill="#7D7FE5"></path>-<path d="M181.165 278.879V348.701L120.4 313.936V244.114L181.165 278.879Z" fill="#2F31AE"></path>-<path d="M120.4 244.114L181.165 278.879L241.347 244.114L181.165 209.057L120.4 244.114Z" fill="#6041D0"></path>-<path d="M60.7651 348.701V278.879L120.946 244.114L120.654 313.936L60.7651 348.701Z" fill="#7D7FE5"></path>-<path d="M60.7656 278.879V348.701L0 313.936V244.114L60.7656 278.879Z" fill="#2F31AE"></path>-<path d="M0 244.114L60.7656 278.879L120.947 244.114L60.7656 209.057L0 244.114Z" fill="#6041D0"></path>-<path d="M301.017 348.701V278.879L361.198 244.114L360.906 313.936L301.017 348.701Z" fill="#7D7FE5"></path>-<path d="M301.018 278.879V348.701L240.252 313.936V244.114L301.018 278.879Z" fill="#2F31AE"></path>-<path d="M240.252 244.114L301.018 278.879L361.199 244.114L301.018 209.057L240.252 244.114Z" fill="#6041D0"></path>-</svg><style>@media (prefers-color-scheme: light) { :root { filter: none; } }-@media (prefers-color-scheme: dark) { :root { filter: none; } }-</style></svg>\ No newline at end of file+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#E6E6E6"/>+</svg>diff --git a/apps/erp/public/site.webmanifest b/apps/erp/public/site.webmanifestindex 344837476f..9929734043 100644--- a/apps/erp/public/site.webmanifest+++ b/apps/erp/public/site.webmanifest@@ -1,21 +1 @@-{- "name": "Carbon",- "short_name": "Carbon",- "icons": [- {- "src": "/web-app-manifest-192x192.png",- "sizes": "192x192",- "type": "image/png",- "purpose": "maskable"- },- {- "src": "/web-app-manifest-512x512.png",- "sizes": "512x512",- "type": "image/png",- "purpose": "maskable"- }- ],- "theme_color": "#000000",- "background_color": "#000000",- "display": "standalone"-}\ No newline at end of file+{"name":"Carbon ERP","short_name":"ERP","icons":[{"src":"/android-chrome-192x192.png","sizes":"192x192","type":"image/png"},{"src":"/android-chrome-512x512.png","sizes":"512x512","type":"image/png"}],"theme_color":"#ffffff","background_color":"#ffffff","display":"standalone"}\ No newline at end of filediff --git a/apps/erp/public/web-app-manifest-192x192.png b/apps/erp/public/web-app-manifest-192x192.pngdeleted file mode 100644index cda38d5ed4..0000000000Binary files a/apps/erp/public/web-app-manifest-192x192.png and /dev/null differdiff --git a/apps/erp/public/web-app-manifest-512x512.png b/apps/erp/public/web-app-manifest-512x512.pngdeleted file mode 100644index 88c30a090e..0000000000Binary files a/apps/erp/public/web-app-manifest-512x512.png and /dev/null differdiff --git a/apps/mes/app/root.tsx b/apps/mes/app/root.tsxindex 3ddc3c2b8b..e917693368 100644--- a/apps/mes/app/root.tsx+++ b/apps/mes/app/root.tsx@@ -250,9 +250,14 @@ export function ErrorBoundary({ error }: Route.ErrorBoundaryProps) {<div className="light"><div className="flex flex-col w-full h-screen items-center justify-center space-y-4 "><img- src="/carbon-logo-mark.svg"+ src="/carbon-mark-light.svg"alt="Carbon Logo"- className="block max-w-[60px]"+ className="block max-w-[60px] dark:hidden"+ />+ <img+ src="/carbon-mark-dark.svg"+ alt="Carbon Logo"+ className="max-w-[60px] hidden dark:block"/><Heading size="h1">Something went wrong</Heading><p className="text-muted-foreground max-w-2xl">{message}</p>diff --git a/apps/mes/app/routes/_public+/_layout.tsx b/apps/mes/app/routes/_public+/_layout.tsxindex b2864fd322..b6107f6ac9 100644--- a/apps/mes/app/routes/_public+/_layout.tsx+++ b/apps/mes/app/routes/_public+/_layout.tsx@@ -12,7 +12,7 @@ export default function PublicRoute() {src="/carbon-word-light.svg"alt="Carbon Logo"className={cn(- "max-w-[240px] mb-3 dark:hidden z-50",+ "max-w-[200px] mb-3 dark:hidden z-50",CONTROLLED_ENVIRONMENT && "grayscale")}/>@@ -20,7 +20,7 @@ export default function PublicRoute() {src="/carbon-word-dark.svg"alt="Carbon Logo"className={cn(- "max-w-[240px] mb-3 dark:block hidden z-50",+ "max-w-[200px] mb-3 dark:block hidden z-50",CONTROLLED_ENVIRONMENT && "grayscale")}/>diff --git a/apps/mes/app/routes/_public+/callback.tsx b/apps/mes/app/routes/_public+/callback.tsxindex b4ffb55b09..af60e12ad3 100644--- a/apps/mes/app/routes/_public+/callback.tsx+++ b/apps/mes/app/routes/_public+/callback.tsx@@ -1,6 +1,5 @@import {assertIsPost,- CONTROLLED_ENVIRONMENT,callbackValidator,carbonClient,error@@ -21,7 +20,6 @@ import {AlertDescription,AlertTitle,Button,- cn,VStack} from "@carbon/react";import { Trans } from "@lingui/react/macro";@@ -172,17 +170,26 @@ export default function AuthCallback() {</VStack></div>) : (- <div- className={cn(- "hexagon-loader-container",- CONTROLLED_ENVIRONMENT && "grayscale"- )}- >- <div className="hexagon-loader">- <div className="hexagon" />- <div className="hexagon" />- <div className="hexagon" />- </div>+ <div className="flex items-end justify-center gap-1.5 h-8">+ {[0, 1, 2, 3, 4].map((i) => (+ <div+ key={i}+ className="w-1.5 rounded-sm bg-primary"+ style={{+ animationName: "loading-bars",+ animationDuration: "1.2s",+ animationTimingFunction: "ease-in-out",+ animationIterationCount: "infinite",+ animationDelay: `${i * 0.1}s`+ }}+ />+ ))}+ <style>+ {`@keyframes loading-bars {+ 0%, 100% { height: 8px; opacity: 0.3; }+ 50% { height: 32px; opacity: 1; }+ }`}+ </style></div>)}</div>diff --git a/apps/mes/app/routes/_public+/login.tsx b/apps/mes/app/routes/_public+/login.tsxindex 1b778a078e..a3878ec6ad 100644--- a/apps/mes/app/routes/_public+/login.tsx+++ b/apps/mes/app/routes/_public+/login.tsx@@ -271,11 +271,16 @@ export default function LoginRoute() {return (<>- <div className="flex justify-center mb-4">+ <div className="flex justify-center mb-8"><img- src={CONTROLLED_ENVIRONMENT ? "/flag.png" : "/carbon-logo-mark.svg"}+ src={CONTROLLED_ENVIRONMENT ? "/flag.png" : "/carbon-mark-light.svg"}alt={t`Carbon Logo`}- className="w-36"+ className="w-24 dark:hidden"+ />+ <img+ src={CONTROLLED_ENVIRONMENT ? "/flag.png" : "/carbon-mark-dark.svg"}+ alt={t`Carbon Logo`}+ className="w-24 hidden dark:block"/></div><div className="rounded-lg md:bg-card md:border md:border-border md:shadow-lg p-8 w-[380px]">@@ -338,11 +343,6 @@ export default function LoginRoute() {</Button>)}- {(hasGoogleAuth || hasOutlookAuth) && (- <div className="py-3 w-full">- <Separator />- </div>- )}{hasPasskeyAuth && passkeySupported && (<Buttontype="button"@@ -354,9 +354,16 @@ export default function LoginRoute() {variant="secondary"leftIcon={<LuFingerprint className="size-4" />}>- Sign in with Passkey+ <Trans>Sign in with Passkey</Trans></Button>)}++ {(hasGoogleAuth || hasOutlookAuth || hasPasskeyAuth) && (+ <div className="py-3 w-full">+ <Separator />+ </div>+ )}+<Inputname="email"label=""diff --git a/apps/mes/app/styles/tailwind.css b/apps/mes/app/styles/tailwind.cssindex b9b161a23b..c31ecad3bc 100644--- a/apps/mes/app/styles/tailwind.css+++ b/apps/mes/app/styles/tailwind.css@@ -137,86 +137,3 @@ p.is-editor-empty:first-child:before {.mention {@apply inline-flex items-center px-2 py-0.5 rounded-full text-xs font-medium bg-blue-100 text-blue-800 dark:bg-blue-900/50 dark:text-blue-400;}--.hexagon-loader-container {- @apply relative w-full py-4;-}--.hexagon-loader {- position: relative;- display: flex;- justify-content: center;- align-items: center;- width: 100%;- height: 40px;-}--/* Three hexagon loading animation */-.hexagon {- display: inline-block;- position: relative;- width: 18px;- height: 10px;- background-color: #5fe4d3;- animation: hexloader 1.4s infinite ease-in-out;-}--.hexagon:before,-.hexagon:after {- content: "";- position: absolute;- width: 0;- border-left: 9px solid transparent;- border-right: 9px solid transparent;-}--.hexagon:before {- bottom: 100%;- border-bottom: 5px solid #5fe4d3;-}--.hexagon:after {- top: 100%;- border-top: 5px solid #5fe4d3;-}--.hexagon + .hexagon {- margin-left: 8px;- animation: hexloader 1.4s 0.2s infinite ease-in-out;- background-color: #4faade;-}--.hexagon + .hexagon:before {- border-bottom-color: #4faade;-}--.hexagon + .hexagon:after {- border-top-color: #4faade;-}--.hexagon + .hexagon + .hexagon {- margin-left: 8px;- animation: hexloader 1.4s 0.4s infinite ease-in-out;- background-color: #6041d0;-}--.hexagon + .hexagon + .hexagon:before {- border-bottom-color: #6041d0;-}--.hexagon + .hexagon + .hexagon:after {- border-top-color: #6041d0;-}--@keyframes hexloader {- 0%,- 80%,- 100% {- transform: scale(0.5);- opacity: 0;- }- 40% {- transform: scale(1);- opacity: 1;- }-}diff --git a/apps/mes/public/android-chrome-192x192.png b/apps/mes/public/android-chrome-192x192.pngnew file mode 100644index 0000000000..bc936a17b0Binary files /dev/null and b/apps/mes/public/android-chrome-192x192.png differdiff --git a/apps/mes/public/android-chrome-512x512.png b/apps/mes/public/android-chrome-512x512.pngnew file mode 100644index 0000000000..841366bbf7Binary files /dev/null and b/apps/mes/public/android-chrome-512x512.png differdiff --git a/apps/mes/public/apple-touch-icon.png b/apps/mes/public/apple-touch-icon.pngindex 7d10fd7748..aadf41c525 100644Binary files a/apps/mes/public/apple-touch-icon.png and b/apps/mes/public/apple-touch-icon.png differdiff --git a/apps/mes/public/carbon-logo-mark.svg b/apps/mes/public/carbon-logo-mark.svgdeleted file mode 100644index 048049e1e5..0000000000--- a/apps/mes/public/carbon-logo-mark.svg+++ /dev/null@@ -1,20 +0,0 @@-<svg width="362" height="349" viewBox="0 0 362 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M181.165 139.643V69.8213L241.346 35.0564L241.054 104.878L181.165 139.643Z" fill="#60FFD2"/>-<path d="M181.165 69.8213V139.643L120.4 104.878V35.0564L181.165 69.8213Z" fill="#36B5B4"/>-<path d="M120.4 35.0565L181.165 69.8214L241.347 35.0565L181.165 -0.000610352L120.4 35.0565Z" fill="#5FE4D2"/>-<path d="M240.818 244.172V174.35L300.999 139.585L300.707 209.407L240.818 244.172Z" fill="#71DEFF"/>-<path d="M240.818 174.35V244.172L180.052 209.407V139.585L240.818 174.35Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.35L300.999 139.586L240.818 104.528L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.172V174.35L181.693 139.585L181.401 209.407L121.512 244.172Z" fill="#71DEFF"/>-<path d="M121.512 174.35V244.172L60.7466 209.407V139.585L121.512 174.35Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.35L181.694 139.586L121.512 104.528L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.701V278.879L241.346 244.114L241.054 313.936L181.165 348.701Z" fill="#7D7FE5"/>-<path d="M181.165 278.879V348.701L120.4 313.936V244.114L181.165 278.879Z" fill="#2F31AE"/>-<path d="M120.4 244.114L181.165 278.879L241.347 244.114L181.165 209.057L120.4 244.114Z" fill="#6041D0"/>-<path d="M60.7651 348.701V278.879L120.946 244.114L120.654 313.936L60.7651 348.701Z" fill="#7D7FE5"/>-<path d="M60.7656 278.879V348.701L0 313.936V244.114L60.7656 278.879Z" fill="#2F31AE"/>-<path d="M0 244.114L60.7656 278.879L120.947 244.114L60.7656 209.057L0 244.114Z" fill="#6041D0"/>-<path d="M301.017 348.701V278.879L361.198 244.114L360.906 313.936L301.017 348.701Z" fill="#7D7FE5"/>-<path d="M301.018 278.879V348.701L240.252 313.936V244.114L301.018 278.879Z" fill="#2F31AE"/>-<path d="M240.252 244.114L301.018 278.879L361.199 244.114L301.018 209.057L240.252 244.114Z" fill="#6041D0"/>-</svg>diff --git a/apps/mes/public/carbon-mark-dark.svg b/apps/mes/public/carbon-mark-dark.svgnew file mode 100644index 0000000000..047b926154--- /dev/null+++ b/apps/mes/public/carbon-mark-dark.svg@@ -0,0 +1,3 @@+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#E6E6E6"/>+</svg>diff --git a/apps/mes/public/carbon-mark-light.svg b/apps/mes/public/carbon-mark-light.svgnew file mode 100644index 0000000000..db0480c53c--- /dev/null+++ b/apps/mes/public/carbon-mark-light.svg@@ -0,0 +1,3 @@+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#101A24"/>+</svg>diff --git a/apps/mes/public/carbon-word-dark.png b/apps/mes/public/carbon-word-dark.pngdeleted file mode 100644index 3606059a75..0000000000Binary files a/apps/mes/public/carbon-word-dark.png and /dev/null differdiff --git a/apps/mes/public/carbon-word-dark.svg b/apps/mes/public/carbon-word-dark.svgindex b555c4b360..c4463b4061 100644--- a/apps/mes/public/carbon-word-dark.svg+++ b/apps/mes/public/carbon-word-dark.svg@@ -1,26 +1,9 @@-<svg width="1307" height="349" viewBox="0 0 1307 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M412.646 193.426C412.646 178.405 415.703 165.305 421.816 154.126C427.929 142.773 436.401 134.039 447.23 127.926C458.059 121.638 470.461 118.494 484.434 118.494C502.425 118.494 517.271 123.035 528.974 132.118C540.851 141.026 548.799 153.602 552.816 169.846H513.254C511.158 163.558 507.577 158.667 502.512 155.174C497.621 151.506 491.508 149.672 484.172 149.672C473.692 149.672 465.395 153.515 459.282 161.2C453.169 168.711 450.112 179.453 450.112 193.426C450.112 207.225 453.169 217.967 459.282 225.652C465.395 233.163 473.692 236.918 484.172 236.918C499.019 236.918 508.713 230.281 513.254 217.006H552.816C548.799 232.726 540.851 245.215 528.974 254.472C517.097 263.729 502.25 268.358 484.434 268.358C470.461 268.358 458.059 265.301 447.23 259.188C436.401 252.9 427.929 244.167 421.816 232.988C415.703 221.635 412.646 208.447 412.646 193.426Z" fill="white"/>-<path d="M562.395 192.902C562.395 178.23 565.277 165.217 571.041 153.864C576.98 142.511 584.927 133.777 594.883 127.664C605.014 121.551 616.28 118.494 628.681 118.494C639.511 118.494 648.943 120.677 656.977 125.044C665.187 129.411 671.737 134.913 676.627 141.55V120.852H713.569V266H676.627V244.778C671.911 251.59 665.361 257.267 656.977 261.808C648.768 266.175 639.249 268.358 628.419 268.358C616.193 268.358 605.014 265.214 594.883 258.926C584.927 252.638 576.98 243.817 571.041 232.464C565.277 220.936 562.395 207.749 562.395 192.902ZM676.627 193.426C676.627 184.518 674.881 176.92 671.387 170.632C667.894 164.169 663.178 159.279 657.239 155.96C651.301 152.467 644.925 150.72 638.113 150.72C631.301 150.72 625.013 152.379 619.249 155.698C613.485 159.017 608.769 163.907 605.101 170.37C601.608 176.658 599.861 184.169 599.861 192.902C599.861 201.635 601.608 209.321 605.101 215.958C608.769 222.421 613.485 227.399 619.249 230.892C625.188 234.385 631.476 236.132 638.113 236.132C644.925 236.132 651.301 234.473 657.239 231.154C663.178 227.661 667.894 222.77 671.387 216.482C674.881 210.019 676.627 202.334 676.627 193.426Z" fill="white"/>-<path d="M778.214 143.384C782.93 135.699 789.043 129.673 796.554 125.306C804.239 120.939 812.972 118.756 822.754 118.756V157.27H813.06C801.532 157.27 792.798 159.977 786.86 165.392C781.096 170.807 778.214 180.239 778.214 193.688V266H741.534V120.852H778.214V143.384Z" fill="white"/>-<path d="M876.28 142.074C880.996 135.087 887.458 129.411 895.668 125.044C904.052 120.677 913.571 118.494 924.226 118.494C936.627 118.494 947.806 121.551 957.762 127.664C967.892 133.777 975.84 142.511 981.604 153.864C987.542 165.043 990.512 178.055 990.512 192.902C990.512 207.749 987.542 220.936 981.604 232.464C975.84 243.817 967.892 252.638 957.762 258.926C947.806 265.214 936.627 268.358 924.226 268.358C913.396 268.358 903.877 266.262 895.668 262.07C887.633 257.703 881.17 252.114 876.28 245.302V266H839.6V72.12H876.28V142.074ZM953.046 192.902C953.046 184.169 951.212 176.658 947.544 170.37C944.05 163.907 939.334 159.017 933.396 155.698C927.632 152.379 921.344 150.72 914.532 150.72C907.894 150.72 901.606 152.467 895.668 155.96C889.904 159.279 885.188 164.169 881.52 170.632C878.026 177.095 876.28 184.693 876.28 193.426C876.28 202.159 878.026 209.757 881.52 216.22C885.188 222.683 889.904 227.661 895.668 231.154C901.606 234.473 907.894 236.132 914.532 236.132C921.344 236.132 927.632 234.385 933.396 230.892C939.334 227.399 944.05 222.421 947.544 215.958C951.212 209.495 953.046 201.81 953.046 192.902Z" fill="white"/>-<path d="M1073.76 268.358C1059.78 268.358 1047.21 265.301 1036.03 259.188C1024.85 252.9 1016.03 244.079 1009.57 232.726C1003.28 221.373 1000.14 208.273 1000.14 193.426C1000.14 178.579 1003.37 165.479 1009.83 154.126C1016.47 142.773 1025.46 134.039 1036.82 127.926C1048.17 121.638 1060.83 118.494 1074.81 118.494C1088.78 118.494 1101.44 121.638 1112.8 127.926C1124.15 134.039 1133.06 142.773 1139.52 154.126C1146.16 165.479 1149.48 178.579 1149.48 193.426C1149.48 208.273 1146.07 221.373 1139.26 232.726C1132.62 244.079 1123.54 252.9 1112.01 259.188C1100.66 265.301 1087.91 268.358 1073.76 268.358ZM1073.76 236.394C1080.4 236.394 1086.6 234.822 1092.36 231.678C1098.3 228.359 1103.01 223.469 1106.51 217.006C1110 210.543 1111.75 202.683 1111.75 193.426C1111.75 179.627 1108.08 169.06 1100.74 161.724C1093.58 154.213 1084.76 150.458 1074.28 150.458C1063.8 150.458 1054.98 154.213 1047.82 161.724C1040.83 169.06 1037.34 179.627 1037.34 193.426C1037.34 207.225 1040.75 217.879 1047.56 225.39C1054.54 232.726 1063.28 236.394 1073.76 236.394Z" fill="white"/>-<path d="M1248.96 118.756C1266.25 118.756 1280.22 124.258 1290.88 135.262C1301.53 146.091 1306.86 161.287 1306.86 180.85V266H1270.18V185.828C1270.18 174.3 1267.3 165.479 1261.53 159.366C1255.77 153.078 1247.91 149.934 1237.95 149.934C1227.82 149.934 1219.79 153.078 1213.85 159.366C1208.08 165.479 1205.2 174.3 1205.2 185.828V266H1168.52V120.852H1205.2V138.93C1210.09 132.642 1216.29 127.751 1223.8 124.258C1231.49 120.59 1239.87 118.756 1248.96 118.756Z" fill="white"/>-<path d="M181.165 139.644V69.822L241.346 35.0571L241.054 104.879L181.165 139.644Z" fill="#60FFD2"/>-<path d="M181.165 69.822V139.644L120.4 104.879V35.0571L181.165 69.822Z" fill="#36B5B4"/>-<path d="M120.4 35.0571L181.165 69.822L241.346 35.0571L181.165 0L120.4 35.0571Z" fill="#5FE4D2"/>-<path d="M240.818 244.173V174.351L300.999 139.586L300.707 209.408L240.818 244.173Z" fill="#71DEFF"/>-<path d="M240.818 174.351V244.173L180.052 209.408V139.586L240.818 174.351Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.351L300.999 139.586L240.818 104.529L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.173V174.351L181.693 139.586L181.401 209.408L121.512 244.173Z" fill="#71DEFF"/>-<path d="M121.512 174.351V244.173L60.7466 209.408V139.586L121.512 174.351Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.351L181.693 139.586L121.512 104.529L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.702V278.88L241.346 244.115L241.054 313.937L181.165 348.702Z" fill="#7D7FE5"/>-<path d="M181.165 278.88V348.702L120.4 313.937V244.115L181.165 278.88Z" fill="#2F31AE"/>-<path d="M120.4 244.115L181.165 278.88L241.346 244.115L181.165 209.057L120.4 244.115Z" fill="#6041D0"/>-<path d="M60.7652 348.702V278.88L120.947 244.115L120.654 313.937L60.7652 348.702Z" fill="#7D7FE5"/>-<path d="M60.7652 278.88V348.702L0 313.937V244.115L60.7652 278.88Z" fill="#2F31AE"/>-<path d="M0 244.115L60.7652 278.88L120.947 244.115L60.7656 209.057L0 244.115Z" fill="#6041D0"/>-<path d="M301.017 348.702V278.88L361.198 244.115L360.906 313.937L301.017 348.702Z" fill="#7D7FE5"/>-<path d="M301.017 278.88V348.702L240.252 313.937V244.115L301.017 278.88Z" fill="#2F31AE"/>-<path d="M240.252 244.115L301.017 278.88L361.198 244.115L301.018 209.057L240.252 244.115Z" fill="#6041D0"/>+<svg width="720" height="175" viewBox="0 0 720 175" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M64.2993 3.57443C72.343 -1.19144 82.3494 -1.19151 90.3931 3.57443L142.163 34.2484C149.93 38.8505 154.692 47.2038 154.692 56.2254V118.775C154.692 127.796 149.93 136.149 142.163 140.752L90.3931 171.426C82.3494 176.192 72.343 176.191 64.2993 171.426L12.5296 140.752C4.76242 136.149 0 127.796 0 118.775V56.2254C0 47.2037 4.76242 38.8505 12.5296 34.2484L64.2993 3.57443ZM81.004 40.286C78.8708 39.0012 76.2016 38.9983 74.0657 40.2786L42.6851 59.0884C38.3192 61.7055 38.3303 68.0312 42.7057 70.6326L74.173 89.3408C74.3089 89.4216 74.3921 89.5681 74.3921 89.726V126.818C74.3922 132.04 80.0912 135.269 84.5774 132.589L115.594 114.057C117.626 112.843 118.87 110.652 118.87 108.287V66.8923C118.87 64.5357 117.635 62.3509 115.615 61.134L81.004 40.286Z" fill="#E6E6E6"/>+<path d="M236.385 133.457C229.22 133.457 222.857 132.223 217.298 129.754C211.862 127.163 207.291 123.645 203.584 119.202C200.002 114.635 197.284 109.513 195.431 103.836C193.577 98.1581 192.651 92.2338 192.651 86.0626C192.651 79.8914 193.577 73.9671 195.431 68.2897C197.284 62.6122 200.002 57.5518 203.584 53.1086C207.291 48.6654 211.862 45.2095 217.298 42.741C222.857 40.1492 229.22 38.8532 236.385 38.8532C245.404 38.8532 253.249 41.0131 259.921 45.3329C266.716 49.6528 271.719 56.3176 274.931 65.3275L256.77 72.3626C255.288 67.6725 252.879 63.9081 249.543 61.0694C246.207 58.1072 241.821 56.6262 236.385 56.6262C230.95 56.6262 226.502 58.0455 223.043 60.8843C219.707 63.723 217.236 67.364 215.63 71.8072C214.024 76.2505 213.221 81.0023 213.221 86.0626C213.221 91.123 214.024 95.9365 215.63 100.503C217.236 104.946 219.707 108.587 223.043 111.426C226.502 114.141 230.95 115.499 236.385 115.499C241.821 115.499 246.207 114.08 249.543 111.241C252.879 108.402 255.288 104.638 256.77 99.9477L274.931 106.983C271.719 115.869 266.716 122.534 259.921 126.977C253.249 131.297 245.404 133.457 236.385 133.457Z" fill="#E6E6E6"/>+<path d="M343.217 131.791L341.735 116.425V74.214C341.735 68.2897 339.943 63.8464 336.361 60.8843C332.778 57.7987 327.774 56.2559 321.35 56.2559C316.408 56.2559 311.528 57.2433 306.71 59.218C302.015 61.0694 297.691 63.9698 293.738 67.9194L282.248 54.4045C288.178 48.8505 294.479 44.901 301.151 42.5559C307.822 40.0874 315.111 38.8532 323.018 38.8532C335.372 38.8532 344.947 42.0005 351.742 48.2951C358.66 54.4663 362.12 63.1059 362.12 74.214V131.791H343.217ZM314.864 133.457C308.069 133.457 302.015 132.223 296.703 129.754C291.514 127.286 287.437 123.83 284.472 119.387C281.631 114.944 280.21 109.76 280.21 103.836C280.21 98.7752 281.26 94.3937 283.36 90.691C285.584 86.9883 288.426 84.0878 291.885 81.9896C294.85 80.1383 298.309 78.8423 302.262 78.1018C306.216 77.2378 310.355 76.8059 314.679 76.8059H343.403V92.1721H317.644C315.42 92.1721 313.196 92.4189 310.972 92.9126C308.749 93.2829 306.772 94.0234 305.042 95.1342C303.807 96.1216 302.757 97.3558 301.892 98.8369C301.151 100.318 300.78 102.046 300.78 104.021C300.78 107.97 302.262 111.118 305.228 113.463C308.316 115.684 312.393 116.795 317.458 116.795C321.906 116.795 325.921 115.808 329.504 113.833C333.21 111.858 336.175 109.143 338.399 105.687C340.623 102.231 341.735 98.3432 341.735 94.0234L348.036 104.206C346.553 110.624 344.206 116.054 340.994 120.498C337.781 124.818 333.952 128.088 329.504 130.31C325.056 132.408 320.176 133.457 314.864 133.457Z" fill="#E6E6E6"/>+<path d="M375.823 131.791V40.5194H396.578V65.1424L392.687 65.6978C393.304 60.3906 395.096 55.7622 398.061 51.8127C401.026 47.7397 404.609 44.5924 408.809 42.3708C413.133 40.0257 417.395 38.8532 421.596 38.8532C424.561 38.8532 427.403 39.2235 430.121 39.964C432.839 40.7046 435.68 41.9388 438.645 43.6667L428.638 62.1802C427.279 61.3162 425.488 60.6374 423.264 60.1437C421.164 59.5266 419.125 59.218 417.148 59.218C414.554 59.218 411.96 59.7117 409.365 60.6991C406.894 61.6865 404.67 63.2293 402.694 65.3275C400.717 67.3023 399.234 69.8942 398.246 73.1032C397.628 74.8311 397.134 77.1144 396.764 79.9532C396.517 82.6685 396.393 86.4946 396.393 91.4315V131.791H375.823Z" fill="#E6E6E6"/>+<path d="M492.002 133.457C487.06 133.457 482.365 132.47 477.918 130.495C473.594 128.52 469.825 125.496 466.613 121.423C463.401 117.227 460.992 111.796 459.386 105.132L464.76 106.427V131.791H444.375V2.75192H464.76V66.068H460.127C461.363 60.2672 463.463 55.3919 466.428 51.4424C469.517 47.3694 473.223 44.2838 477.547 42.1856C481.995 39.964 486.813 38.8532 492.002 38.8532C499.414 38.8532 506.086 40.7663 512.016 44.5924C518.069 48.2951 522.888 53.664 526.47 60.6991C530.053 67.7343 531.845 76.1887 531.845 86.0626C531.845 95.0725 530.177 103.157 526.841 110.315C523.629 117.474 519.058 123.151 513.128 127.348C507.198 131.421 500.156 133.457 492.002 133.457ZM486.998 114.573C491.816 114.573 496.017 113.401 499.6 111.056C503.306 108.711 506.147 105.378 508.124 101.059C510.101 96.7387 511.089 91.7401 511.089 86.0626C511.089 80.3851 510.101 75.3865 508.124 71.0667C506.147 66.7469 503.306 63.4144 499.6 61.0694C496.017 58.7244 491.816 57.5518 486.998 57.5518C482.18 57.5518 477.918 58.7861 474.211 61.2545C470.629 63.5996 467.849 66.932 465.872 71.2518C463.895 75.4482 462.907 80.3851 462.907 86.0626C462.907 91.7401 463.895 96.7387 465.872 101.059C467.849 105.378 470.629 108.711 474.211 111.056C477.918 113.401 482.18 114.573 486.998 114.573Z" fill="#E6E6E6"/>+<path d="M583.567 133.457C574.919 133.457 567.135 131.421 560.217 127.348C553.298 123.275 547.862 117.659 543.909 110.5C540.079 103.342 538.164 95.1959 538.164 86.0626C538.164 76.9293 540.079 68.7834 543.909 61.6248C547.862 54.4663 553.237 48.9122 560.032 44.9627C566.95 40.8897 574.795 38.8532 583.567 38.8532C592.462 38.8532 600.245 40.8897 606.917 44.9627C613.711 48.9122 619.086 54.4663 623.039 61.6248C626.992 68.7834 628.969 76.9293 628.969 86.0626C628.969 95.1959 626.992 103.342 623.039 110.5C619.209 117.659 613.835 123.275 606.917 127.348C600.122 131.421 592.338 133.457 583.567 133.457ZM583.752 115.314C588.817 115.314 593.203 114.141 596.909 111.796C600.616 109.451 603.457 106.057 605.434 101.614C607.411 97.1707 608.399 91.9869 608.399 86.0626C608.399 80.0149 607.411 74.8311 605.434 70.5113C603.457 66.068 600.616 62.6739 596.909 60.3289C593.203 57.9838 588.817 56.8113 583.752 56.8113C578.44 56.8113 573.93 58.0455 570.224 60.514C566.518 62.859 563.676 66.1915 561.699 70.5113C559.723 74.8311 558.734 80.0149 558.734 86.0626C558.734 91.9869 559.723 97.1707 561.699 101.614C563.676 106.057 566.518 109.451 570.224 111.796C573.93 114.141 578.44 115.314 583.752 115.314Z" fill="#E6E6E6"/>+<path d="M639.573 131.791V40.5194H660.143V60.6991L656.437 61.6248C658.043 56.3176 660.39 51.9978 663.479 48.6654C666.567 45.3329 670.15 42.8645 674.227 41.26C678.427 39.6555 682.813 38.8532 687.384 38.8532C697.639 38.8532 705.607 41.8154 711.29 47.7397C717.097 53.5406 720 61.8716 720 72.7329V131.791H699.43V80.3234C699.43 72.1775 697.947 66.1915 694.982 62.3653C692.017 58.5392 687.446 56.6262 681.269 56.6262C676.698 56.6262 672.806 57.737 669.594 59.9586C666.505 62.0568 664.158 65.3892 662.552 69.9559C660.946 74.5225 660.143 80.3234 660.143 87.3585V131.791H639.573Z" fill="#E6E6E6"/></svg>diff --git a/apps/mes/public/carbon-word-light.png b/apps/mes/public/carbon-word-light.pngdeleted file mode 100644index becd8f13bb..0000000000Binary files a/apps/mes/public/carbon-word-light.png and /dev/null differdiff --git a/apps/mes/public/carbon-word-light.svg b/apps/mes/public/carbon-word-light.svgindex 3e899a2d1b..3fd85675c9 100644--- a/apps/mes/public/carbon-word-light.svg+++ b/apps/mes/public/carbon-word-light.svg@@ -1,26 +1,9 @@-<svg width="1307" height="349" viewBox="0 0 1307 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M412.646 193.426C412.646 178.405 415.703 165.305 421.816 154.126C427.929 142.773 436.401 134.039 447.23 127.926C458.059 121.638 470.461 118.494 484.434 118.494C502.425 118.494 517.271 123.035 528.974 132.118C540.851 141.026 548.799 153.602 552.816 169.846H513.254C511.158 163.558 507.577 158.667 502.512 155.174C497.621 151.506 491.508 149.672 484.172 149.672C473.692 149.672 465.395 153.515 459.282 161.2C453.169 168.711 450.112 179.453 450.112 193.426C450.112 207.225 453.169 217.967 459.282 225.652C465.395 233.163 473.692 236.918 484.172 236.918C499.019 236.918 508.713 230.281 513.254 217.006H552.816C548.799 232.726 540.851 245.215 528.974 254.472C517.097 263.729 502.25 268.358 484.434 268.358C470.461 268.358 458.059 265.301 447.23 259.188C436.401 252.9 427.929 244.167 421.816 232.988C415.703 221.635 412.646 208.447 412.646 193.426Z" fill="#212278"/>-<path d="M562.395 192.902C562.395 178.23 565.277 165.217 571.041 153.864C576.98 142.511 584.927 133.777 594.883 127.664C605.014 121.551 616.28 118.494 628.681 118.494C639.511 118.494 648.943 120.677 656.977 125.044C665.187 129.411 671.737 134.913 676.627 141.55V120.852H713.569V266H676.627V244.778C671.911 251.59 665.361 257.267 656.977 261.808C648.768 266.175 639.249 268.358 628.419 268.358C616.193 268.358 605.014 265.214 594.883 258.926C584.927 252.638 576.98 243.817 571.041 232.464C565.277 220.936 562.395 207.749 562.395 192.902ZM676.627 193.426C676.627 184.518 674.881 176.92 671.387 170.632C667.894 164.169 663.178 159.279 657.239 155.96C651.301 152.467 644.925 150.72 638.113 150.72C631.301 150.72 625.013 152.379 619.249 155.698C613.485 159.017 608.769 163.907 605.101 170.37C601.608 176.658 599.861 184.169 599.861 192.902C599.861 201.635 601.608 209.321 605.101 215.958C608.769 222.421 613.485 227.399 619.249 230.892C625.188 234.385 631.476 236.132 638.113 236.132C644.925 236.132 651.301 234.473 657.239 231.154C663.178 227.661 667.894 222.77 671.387 216.482C674.881 210.019 676.627 202.334 676.627 193.426Z" fill="#212278"/>-<path d="M778.214 143.384C782.93 135.699 789.043 129.673 796.554 125.306C804.239 120.939 812.972 118.756 822.754 118.756V157.27H813.06C801.532 157.27 792.798 159.977 786.86 165.392C781.096 170.807 778.214 180.239 778.214 193.688V266H741.534V120.852H778.214V143.384Z" fill="#212278"/>-<path d="M876.28 142.074C880.996 135.087 887.458 129.411 895.668 125.044C904.052 120.677 913.571 118.494 924.226 118.494C936.627 118.494 947.806 121.551 957.762 127.664C967.892 133.777 975.84 142.511 981.604 153.864C987.542 165.043 990.512 178.055 990.512 192.902C990.512 207.749 987.542 220.936 981.604 232.464C975.84 243.817 967.892 252.638 957.762 258.926C947.806 265.214 936.627 268.358 924.226 268.358C913.396 268.358 903.877 266.262 895.668 262.07C887.633 257.703 881.17 252.114 876.28 245.302V266H839.6V72.12H876.28V142.074ZM953.046 192.902C953.046 184.169 951.212 176.658 947.544 170.37C944.05 163.907 939.334 159.017 933.396 155.698C927.632 152.379 921.344 150.72 914.532 150.72C907.894 150.72 901.606 152.467 895.668 155.96C889.904 159.279 885.188 164.169 881.52 170.632C878.026 177.095 876.28 184.693 876.28 193.426C876.28 202.159 878.026 209.757 881.52 216.22C885.188 222.683 889.904 227.661 895.668 231.154C901.606 234.473 907.894 236.132 914.532 236.132C921.344 236.132 927.632 234.385 933.396 230.892C939.334 227.399 944.05 222.421 947.544 215.958C951.212 209.495 953.046 201.81 953.046 192.902Z" fill="#212278"/>-<path d="M1073.76 268.358C1059.78 268.358 1047.21 265.301 1036.03 259.188C1024.85 252.9 1016.03 244.079 1009.57 232.726C1003.28 221.373 1000.14 208.273 1000.14 193.426C1000.14 178.579 1003.37 165.479 1009.83 154.126C1016.47 142.773 1025.46 134.039 1036.82 127.926C1048.17 121.638 1060.83 118.494 1074.81 118.494C1088.78 118.494 1101.44 121.638 1112.8 127.926C1124.15 134.039 1133.06 142.773 1139.52 154.126C1146.16 165.479 1149.48 178.579 1149.48 193.426C1149.48 208.273 1146.07 221.373 1139.26 232.726C1132.62 244.079 1123.54 252.9 1112.01 259.188C1100.66 265.301 1087.91 268.358 1073.76 268.358ZM1073.76 236.394C1080.4 236.394 1086.6 234.822 1092.36 231.678C1098.3 228.359 1103.01 223.469 1106.51 217.006C1110 210.543 1111.75 202.683 1111.75 193.426C1111.75 179.627 1108.08 169.06 1100.74 161.724C1093.58 154.213 1084.76 150.458 1074.28 150.458C1063.8 150.458 1054.98 154.213 1047.82 161.724C1040.83 169.06 1037.34 179.627 1037.34 193.426C1037.34 207.225 1040.75 217.879 1047.56 225.39C1054.54 232.726 1063.28 236.394 1073.76 236.394Z" fill="#212278"/>-<path d="M1248.96 118.756C1266.25 118.756 1280.22 124.258 1290.88 135.262C1301.53 146.091 1306.86 161.287 1306.86 180.85V266H1270.18V185.828C1270.18 174.3 1267.3 165.479 1261.53 159.366C1255.77 153.078 1247.91 149.934 1237.95 149.934C1227.82 149.934 1219.79 153.078 1213.85 159.366C1208.08 165.479 1205.2 174.3 1205.2 185.828V266H1168.52V120.852H1205.2V138.93C1210.09 132.642 1216.29 127.751 1223.8 124.258C1231.49 120.59 1239.87 118.756 1248.96 118.756Z" fill="#212278"/>-<path d="M181.165 139.644V69.822L241.346 35.0571L241.054 104.879L181.165 139.644Z" fill="#60FFD2"/>-<path d="M181.165 69.822V139.644L120.4 104.879V35.0571L181.165 69.822Z" fill="#36B5B4"/>-<path d="M120.4 35.0571L181.165 69.822L241.346 35.0571L181.165 0L120.4 35.0571Z" fill="#5FE4D2"/>-<path d="M240.818 244.173V174.351L300.999 139.586L300.707 209.408L240.818 244.173Z" fill="#71DEFF"/>-<path d="M240.818 174.351V244.173L180.052 209.408V139.586L240.818 174.351Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.351L300.999 139.586L240.818 104.529L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.173V174.351L181.693 139.586L181.401 209.408L121.512 244.173Z" fill="#71DEFF"/>-<path d="M121.512 174.351V244.173L60.7466 209.408V139.586L121.512 174.351Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.351L181.693 139.586L121.512 104.529L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.702V278.88L241.346 244.115L241.054 313.937L181.165 348.702Z" fill="#7D7FE5"/>-<path d="M181.165 278.88V348.702L120.4 313.937V244.115L181.165 278.88Z" fill="#2F31AE"/>-<path d="M120.4 244.115L181.165 278.88L241.346 244.115L181.165 209.057L120.4 244.115Z" fill="#6041D0"/>-<path d="M60.7652 348.702V278.88L120.947 244.115L120.654 313.937L60.7652 348.702Z" fill="#7D7FE5"/>-<path d="M60.7652 278.88V348.702L-1.52588e-05 313.937V244.115L60.7652 278.88Z" fill="#2F31AE"/>-<path d="M-1.52588e-05 244.115L60.7652 278.88L120.947 244.115L60.7656 209.057L-1.52588e-05 244.115Z" fill="#6041D0"/>-<path d="M301.017 348.702V278.88L361.198 244.115L360.906 313.937L301.017 348.702Z" fill="#7D7FE5"/>-<path d="M301.017 278.88V348.702L240.252 313.937V244.115L301.017 278.88Z" fill="#2F31AE"/>-<path d="M240.252 244.115L301.017 278.88L361.198 244.115L301.018 209.057L240.252 244.115Z" fill="#6041D0"/>+<svg width="720" height="175" viewBox="0 0 720 175" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M64.2993 3.57443C72.343 -1.19144 82.3494 -1.19151 90.3931 3.57443L142.163 34.2484C149.93 38.8505 154.692 47.2038 154.692 56.2254V118.775C154.692 127.796 149.93 136.149 142.163 140.752L90.3931 171.426C82.3494 176.192 72.343 176.191 64.2993 171.426L12.5296 140.752C4.76242 136.149 0 127.796 0 118.775V56.2254C0 47.2037 4.76242 38.8505 12.5296 34.2484L64.2993 3.57443ZM81.004 40.286C78.8708 39.0012 76.2016 38.9983 74.0657 40.2786L42.6851 59.0884C38.3192 61.7055 38.3303 68.0312 42.7057 70.6326L74.173 89.3408C74.3089 89.4216 74.3921 89.5681 74.3921 89.726V126.818C74.3922 132.04 80.0912 135.269 84.5774 132.589L115.594 114.057C117.626 112.843 118.87 110.652 118.87 108.287V66.8923C118.87 64.5357 117.635 62.3509 115.615 61.134L81.004 40.286Z" fill="#101A24"/>+<path d="M236.385 133.457C229.22 133.457 222.857 132.223 217.298 129.754C211.862 127.163 207.291 123.645 203.584 119.202C200.002 114.635 197.284 109.513 195.431 103.836C193.577 98.1581 192.651 92.2338 192.651 86.0626C192.651 79.8914 193.577 73.9671 195.431 68.2897C197.284 62.6122 200.002 57.5518 203.584 53.1086C207.291 48.6654 211.862 45.2095 217.298 42.741C222.857 40.1492 229.22 38.8532 236.385 38.8532C245.404 38.8532 253.249 41.0131 259.921 45.3329C266.716 49.6528 271.719 56.3176 274.931 65.3275L256.77 72.3626C255.288 67.6725 252.879 63.9081 249.543 61.0694C246.207 58.1072 241.821 56.6262 236.385 56.6262C230.95 56.6262 226.502 58.0455 223.043 60.8843C219.707 63.723 217.236 67.364 215.63 71.8072C214.024 76.2505 213.221 81.0023 213.221 86.0626C213.221 91.123 214.024 95.9365 215.63 100.503C217.236 104.946 219.707 108.587 223.043 111.426C226.502 114.141 230.95 115.499 236.385 115.499C241.821 115.499 246.207 114.08 249.543 111.241C252.879 108.402 255.288 104.638 256.77 99.9477L274.931 106.983C271.719 115.869 266.716 122.534 259.921 126.977C253.249 131.297 245.404 133.457 236.385 133.457Z" fill="#101A24"/>+<path d="M343.217 131.791L341.735 116.425V74.214C341.735 68.2897 339.943 63.8464 336.361 60.8843C332.778 57.7987 327.774 56.2559 321.35 56.2559C316.408 56.2559 311.528 57.2433 306.71 59.218C302.015 61.0694 297.691 63.9698 293.738 67.9194L282.248 54.4045C288.178 48.8505 294.479 44.901 301.151 42.5559C307.822 40.0874 315.111 38.8532 323.018 38.8532C335.372 38.8532 344.947 42.0005 351.742 48.2951C358.66 54.4663 362.12 63.1059 362.12 74.214V131.791H343.217ZM314.864 133.457C308.069 133.457 302.015 132.223 296.703 129.754C291.514 127.286 287.437 123.83 284.472 119.387C281.631 114.944 280.21 109.76 280.21 103.836C280.21 98.7752 281.26 94.3937 283.36 90.691C285.584 86.9883 288.426 84.0878 291.885 81.9896C294.85 80.1383 298.309 78.8423 302.262 78.1018C306.216 77.2378 310.355 76.8059 314.679 76.8059H343.403V92.1721H317.644C315.42 92.1721 313.196 92.4189 310.972 92.9126C308.749 93.2829 306.772 94.0234 305.042 95.1342C303.807 96.1216 302.757 97.3558 301.892 98.8369C301.151 100.318 300.78 102.046 300.78 104.021C300.78 107.97 302.262 111.118 305.228 113.463C308.316 115.684 312.393 116.795 317.458 116.795C321.906 116.795 325.921 115.808 329.504 113.833C333.21 111.858 336.175 109.143 338.399 105.687C340.623 102.231 341.735 98.3432 341.735 94.0234L348.036 104.206C346.553 110.624 344.206 116.054 340.994 120.498C337.781 124.818 333.952 128.088 329.504 130.31C325.056 132.408 320.176 133.457 314.864 133.457Z" fill="#101A24"/>+<path d="M375.823 131.791V40.5194H396.578V65.1424L392.687 65.6978C393.304 60.3906 395.096 55.7622 398.061 51.8127C401.026 47.7397 404.609 44.5924 408.809 42.3708C413.133 40.0257 417.395 38.8532 421.596 38.8532C424.561 38.8532 427.403 39.2235 430.121 39.964C432.839 40.7046 435.68 41.9388 438.645 43.6667L428.638 62.1802C427.279 61.3162 425.488 60.6374 423.264 60.1437C421.164 59.5266 419.125 59.218 417.148 59.218C414.554 59.218 411.96 59.7117 409.365 60.6991C406.894 61.6865 404.67 63.2293 402.694 65.3275C400.717 67.3023 399.234 69.8942 398.246 73.1032C397.628 74.8311 397.134 77.1144 396.764 79.9532C396.517 82.6685 396.393 86.4946 396.393 91.4315V131.791H375.823Z" fill="#101A24"/>+<path d="M492.002 133.457C487.06 133.457 482.365 132.47 477.918 130.495C473.594 128.52 469.825 125.496 466.613 121.423C463.401 117.227 460.992 111.796 459.386 105.132L464.76 106.427V131.791H444.375V2.75192H464.76V66.068H460.127C461.363 60.2672 463.463 55.3919 466.428 51.4424C469.517 47.3694 473.223 44.2838 477.547 42.1856C481.995 39.964 486.813 38.8532 492.002 38.8532C499.414 38.8532 506.086 40.7663 512.016 44.5924C518.069 48.2951 522.888 53.664 526.47 60.6991C530.053 67.7343 531.845 76.1887 531.845 86.0626C531.845 95.0725 530.177 103.157 526.841 110.315C523.629 117.474 519.058 123.151 513.128 127.348C507.198 131.421 500.156 133.457 492.002 133.457ZM486.998 114.573C491.816 114.573 496.017 113.401 499.6 111.056C503.306 108.711 506.147 105.378 508.124 101.059C510.101 96.7387 511.089 91.7401 511.089 86.0626C511.089 80.3851 510.101 75.3865 508.124 71.0667C506.147 66.7469 503.306 63.4144 499.6 61.0694C496.017 58.7244 491.816 57.5518 486.998 57.5518C482.18 57.5518 477.918 58.7861 474.211 61.2545C470.629 63.5996 467.849 66.932 465.872 71.2518C463.895 75.4482 462.907 80.3851 462.907 86.0626C462.907 91.7401 463.895 96.7387 465.872 101.059C467.849 105.378 470.629 108.711 474.211 111.056C477.918 113.401 482.18 114.573 486.998 114.573Z" fill="#101A24"/>+<path d="M583.567 133.457C574.919 133.457 567.135 131.421 560.217 127.348C553.298 123.275 547.862 117.659 543.909 110.5C540.079 103.342 538.164 95.1959 538.164 86.0626C538.164 76.9293 540.079 68.7834 543.909 61.6248C547.862 54.4663 553.237 48.9122 560.032 44.9627C566.95 40.8897 574.795 38.8532 583.567 38.8532C592.462 38.8532 600.245 40.8897 606.917 44.9627C613.711 48.9122 619.086 54.4663 623.039 61.6248C626.992 68.7834 628.969 76.9293 628.969 86.0626C628.969 95.1959 626.992 103.342 623.039 110.5C619.209 117.659 613.835 123.275 606.917 127.348C600.122 131.421 592.338 133.457 583.567 133.457ZM583.752 115.314C588.817 115.314 593.203 114.141 596.909 111.796C600.616 109.451 603.457 106.057 605.434 101.614C607.411 97.1707 608.399 91.9869 608.399 86.0626C608.399 80.0149 607.411 74.8311 605.434 70.5113C603.457 66.068 600.616 62.6739 596.909 60.3289C593.203 57.9838 588.817 56.8113 583.752 56.8113C578.44 56.8113 573.93 58.0455 570.224 60.514C566.518 62.859 563.676 66.1915 561.699 70.5113C559.723 74.8311 558.734 80.0149 558.734 86.0626C558.734 91.9869 559.723 97.1707 561.699 101.614C563.676 106.057 566.518 109.451 570.224 111.796C573.93 114.141 578.44 115.314 583.752 115.314Z" fill="#101A24"/>+<path d="M639.573 131.791V40.5194H660.143V60.6991L656.437 61.6248C658.043 56.3176 660.39 51.9978 663.479 48.6654C666.567 45.3329 670.15 42.8645 674.227 41.26C678.427 39.6555 682.813 38.8532 687.384 38.8532C697.639 38.8532 705.607 41.8154 711.29 47.7397C717.097 53.5406 720 61.8716 720 72.7329V131.791H699.43V80.3234C699.43 72.1775 697.947 66.1915 694.982 62.3653C692.017 58.5392 687.446 56.6262 681.269 56.6262C676.698 56.6262 672.806 57.737 669.594 59.9586C666.505 62.0568 664.158 65.3892 662.552 69.9559C660.946 74.5225 660.143 80.3234 660.143 87.3585V131.791H639.573Z" fill="#101A24"/></svg>diff --git a/apps/mes/public/favicon-16x16.png b/apps/mes/public/favicon-16x16.pngnew file mode 100644index 0000000000..7f08a7eae3Binary files /dev/null and b/apps/mes/public/favicon-16x16.png differdiff --git a/apps/mes/public/favicon-32x32.png b/apps/mes/public/favicon-32x32.pngnew file mode 100644index 0000000000..348b196709Binary files /dev/null and b/apps/mes/public/favicon-32x32.png differdiff --git a/apps/mes/public/favicon-96x96.png b/apps/mes/public/favicon-96x96.pngdeleted file mode 100644index c36c27be04..0000000000Binary files a/apps/mes/public/favicon-96x96.png and /dev/null differdiff --git a/apps/mes/public/favicon.ico b/apps/mes/public/favicon.icoindex a87e92b575..644a0d8ed5 100644Binary files a/apps/mes/public/favicon.ico and b/apps/mes/public/favicon.ico differdiff --git a/apps/mes/public/favicon.svg b/apps/mes/public/favicon.svgindex 1f953c23a1..047b926154 100644--- a/apps/mes/public/favicon.svg+++ b/apps/mes/public/favicon.svg@@ -1,22 +1,3 @@-<svg xmlns="http://www.w3.org/2000/svg" version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" width="362" height="349"><svg width="362" height="349" viewBox="0 0 362 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M181.165 139.643V69.8213L241.346 35.0564L241.054 104.878L181.165 139.643Z" fill="#60FFD2"></path>-<path d="M181.165 69.8213V139.643L120.4 104.878V35.0564L181.165 69.8213Z" fill="#36B5B4"></path>-<path d="M120.4 35.0565L181.165 69.8214L241.347 35.0565L181.165 -0.000610352L120.4 35.0565Z" fill="#5FE4D2"></path>-<path d="M240.818 244.172V174.35L300.999 139.585L300.707 209.407L240.818 244.172Z" fill="#71DEFF"></path>-<path d="M240.818 174.35V244.172L180.052 209.407V139.585L240.818 174.35Z" fill="#3877C5"></path>-<path d="M180.052 139.586L240.818 174.35L300.999 139.586L240.818 104.528L180.052 139.586Z" fill="#4EAADE"></path>-<path d="M121.512 244.172V174.35L181.693 139.585L181.401 209.407L121.512 244.172Z" fill="#71DEFF"></path>-<path d="M121.512 174.35V244.172L60.7466 209.407V139.585L121.512 174.35Z" fill="#3877C5"></path>-<path d="M60.7466 139.586L121.512 174.35L181.694 139.586L121.512 104.528L60.7466 139.586Z" fill="#4EAADE"></path>-<path d="M181.165 348.701V278.879L241.346 244.114L241.054 313.936L181.165 348.701Z" fill="#7D7FE5"></path>-<path d="M181.165 278.879V348.701L120.4 313.936V244.114L181.165 278.879Z" fill="#2F31AE"></path>-<path d="M120.4 244.114L181.165 278.879L241.347 244.114L181.165 209.057L120.4 244.114Z" fill="#6041D0"></path>-<path d="M60.7651 348.701V278.879L120.946 244.114L120.654 313.936L60.7651 348.701Z" fill="#7D7FE5"></path>-<path d="M60.7656 278.879V348.701L0 313.936V244.114L60.7656 278.879Z" fill="#2F31AE"></path>-<path d="M0 244.114L60.7656 278.879L120.947 244.114L60.7656 209.057L0 244.114Z" fill="#6041D0"></path>-<path d="M301.017 348.701V278.879L361.198 244.114L360.906 313.936L301.017 348.701Z" fill="#7D7FE5"></path>-<path d="M301.018 278.879V348.701L240.252 313.936V244.114L301.018 278.879Z" fill="#2F31AE"></path>-<path d="M240.252 244.114L301.018 278.879L361.199 244.114L301.018 209.057L240.252 244.114Z" fill="#6041D0"></path>-</svg><style>@media (prefers-color-scheme: light) { :root { filter: none; } }-@media (prefers-color-scheme: dark) { :root { filter: none; } }-</style></svg>\ No newline at end of file+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#E6E6E6"/>+</svg>diff --git a/apps/mes/public/site.webmanifest b/apps/mes/public/site.webmanifestindex 344837476f..5e955fc30a 100644--- a/apps/mes/public/site.webmanifest+++ b/apps/mes/public/site.webmanifest@@ -1,21 +1 @@-{- "name": "Carbon",- "short_name": "Carbon",- "icons": [- {- "src": "/web-app-manifest-192x192.png",- "sizes": "192x192",- "type": "image/png",- "purpose": "maskable"- },- {- "src": "/web-app-manifest-512x512.png",- "sizes": "512x512",- "type": "image/png",- "purpose": "maskable"- }- ],- "theme_color": "#000000",- "background_color": "#000000",- "display": "standalone"-}\ No newline at end of file+{"name":"Carbon MES","short_name":"MES","icons":[{"src":"/android-chrome-192x192.png","sizes":"192x192","type":"image/png"},{"src":"/android-chrome-512x512.png","sizes":"512x512","type":"image/png"}],"theme_color":"#ffffff","background_color":"#ffffff","display":"standalone"}\ No newline at end of filediff --git a/apps/mes/public/web-app-manifest-192x192.png b/apps/mes/public/web-app-manifest-192x192.pngdeleted file mode 100644index cda38d5ed4..0000000000Binary files a/apps/mes/public/web-app-manifest-192x192.png and /dev/null differdiff --git a/apps/mes/public/web-app-manifest-512x512.png b/apps/mes/public/web-app-manifest-512x512.pngdeleted file mode 100644index 88c30a090e..0000000000Binary files a/apps/mes/public/web-app-manifest-512x512.png and /dev/null differdiff --git a/apps/starter/app/root.tsx b/apps/starter/app/root.tsxindex be616766b8..52fc4c5640 100644--- a/apps/starter/app/root.tsx+++ b/apps/starter/app/root.tsx@@ -13,6 +13,7 @@ import { Analytics } from "@vercel/analytics/react";import type React from "react";import type {ActionFunctionArgs,+ LinksFunction,LoaderFunctionArgs,MetaFunction} from "react-router";@@ -30,13 +31,12 @@ import { getMode, setMode } from "~/services/mode.server";import Background from "~/styles/background.css?url";import NProgress from "~/styles/nprogress.css?url";import Tailwind from "~/styles/tailwind.css?url";-import type { Route } from "./+types/root";import { getTheme } from "./services/theme.server";export const middleware = [flashMiddleware];export const clientMiddleware = [flashClientMiddleware];-export const links: Route.LinksFunction = () => [+export const links: LinksFunction = () => [{ rel: "stylesheet", href: Tailwind },{ rel: "stylesheet", href: Background },{ rel: "stylesheet", href: NProgress }@@ -200,9 +200,14 @@ export function ErrorBoundary({ error }: { error: unknown }) {<div className="light"><div className="flex flex-col w-full h-screen items-center justify-center space-y-4 "><img- src="/carbon-logo-mark.svg"+ src="/carbon-mark-light.svg"alt="Carbon Logo"- className="block max-w-[60px]"+ className="block max-w-[60px] dark:hidden"+ />+ <img+ src="/carbon-mark-dark.svg"+ alt="Carbon Logo"+ className="max-w-[60px] hidden dark:block"/><Heading size="h1">Something went wrong</Heading><p className="text-muted-foreground max-w-2xl">{message}</p>diff --git a/apps/starter/app/routes/_public+/callback.tsx b/apps/starter/app/routes/_public+/callback.tsxindex 2eb23cae63..fa6d428da3 100644--- a/apps/starter/app/routes/_public+/callback.tsx+++ b/apps/starter/app/routes/_public+/callback.tsx@@ -141,8 +141,22 @@ export default function AuthCallback() {return (<div className="flex flex-col items-center justify-center">- <div className="flex justify-center mb-4">- <img src="/carbon-logo-mark.svg" alt="Carbon Logo" className="w-36" />+ <div className="flex justify-center mb-8">+ <img+ src="/carbon-mark-light.svg"+ alt="Carbon Logo"+ className="w-24 dark:hidden"+ />+ <img+ src="/carbon-mark-dark.svg"+ alt="Carbon Logo"+ className="w-24 hidden dark:block"+ />+ <img+ src="/carbon-mark-dark.svg"+ alt="Carbon Logo"+ className="w-24 hidden dark:block"+ /></div>{error ? (<div className="rounded-lg md:bg-card md:border md:border-border md:shadow-lg p-8 mt-8 w-[380px]">@@ -166,12 +180,26 @@ export default function AuthCallback() {</VStack></div>) : (- <div className="hexagon-loader-container">- <div className="hexagon-loader">- <div className="hexagon" />- <div className="hexagon" />- <div className="hexagon" />- </div>+ <div className="flex items-end justify-center gap-1.5 h-8">+ {[0, 1, 2, 3, 4].map((i) => (+ <div+ key={i}+ className="w-1.5 rounded-sm bg-primary"+ style={{+ animationName: "loading-bars",+ animationDuration: "1.2s",+ animationTimingFunction: "ease-in-out",+ animationIterationCount: "infinite",+ animationDelay: `${i * 0.1}s`+ }}+ />+ ))}+ <style>+ {`@keyframes loading-bars {+ 0%, 100% { height: 8px; opacity: 0.3; }+ 50% { height: 32px; opacity: 1; }+ }`}+ </style></div>)}</div>diff --git a/apps/starter/app/routes/_public+/login.tsx b/apps/starter/app/routes/_public+/login.tsxindex 5ef713af4f..710d9c4c03 100644--- a/apps/starter/app/routes/_public+/login.tsx+++ b/apps/starter/app/routes/_public+/login.tsx@@ -143,8 +143,17 @@ export default function LoginRoute() {return (<>- <div className="flex justify-center mb-4">- <img src="/carbon-logo-mark.svg" alt="Carbon Logo" className="w-36" />+ <div className="flex justify-center mb-8">+ <img+ src="/carbon-mark-light.svg"+ alt="Carbon Logo"+ className="w-24 dark:hidden"+ />+ <img+ src="/carbon-mark-dark.svg"+ alt="Carbon Logo"+ className="w-24 hidden dark:block"+ /></div><div className="rounded-lg md:bg-card md:border md:border-border md:shadow-lg p-8 w-[380px]">{fetcher.data?.success === true ? (diff --git a/apps/starter/app/routes/_public+/request-access.tsx b/apps/starter/app/routes/_public+/request-access.tsxindex 539861b2a4..df0de6fa52 100644--- a/apps/starter/app/routes/_public+/request-access.tsx+++ b/apps/starter/app/routes/_public+/request-access.tsx@@ -16,9 +16,14 @@ export default function RequestAccessRoute() {<><div className="flex flex-col items-center justify-center"><img- src="/carbon-logo-mark.svg"+ src="/carbon-mark-light.svg"alt="Carbon Logo"- className="w-36 mb-3"+ className="w-24 mb-3"+ />+ <img+ src="/carbon-mark-dark.svg"+ alt="Carbon Logo"+ className="w-24 mb-3 hidden dark:block"/><h3 className="font-mono font-bold leading-loose uppercase text-xl">diff --git a/apps/starter/app/styles/tailwind.css b/apps/starter/app/styles/tailwind.cssindex 6b35913895..3b70c89f30 100644--- a/apps/starter/app/styles/tailwind.css+++ b/apps/starter/app/styles/tailwind.css@@ -146,86 +146,3 @@ p.is-editor-empty:first-child:before {.tiptap.ProseMirror-selectedNode div[data-video-embed] {@apply ring-2 ring-primary cursor-move p-2 rounded-lg;}--.hexagon-loader-container {- @apply relative w-full py-4;-}--.hexagon-loader {- position: relative;- display: flex;- justify-content: center;- align-items: center;- width: 100%;- height: 40px;-}--/* Three hexagon loading animation */-.hexagon {- display: inline-block;- position: relative;- width: 18px;- height: 10px;- background-color: #5fe4d3;- animation: hexloader 1.4s infinite ease-in-out;-}--.hexagon:before,-.hexagon:after {- content: "";- position: absolute;- width: 0;- border-left: 9px solid transparent;- border-right: 9px solid transparent;-}--.hexagon:before {- bottom: 100%;- border-bottom: 5px solid #5fe4d3;-}--.hexagon:after {- top: 100%;- border-top: 5px solid #5fe4d3;-}--.hexagon + .hexagon {- margin-left: 8px;- animation: hexloader 1.4s 0.2s infinite ease-in-out;- background-color: #4faade;-}--.hexagon + .hexagon:before {- border-bottom-color: #4faade;-}--.hexagon + .hexagon:after {- border-top-color: #4faade;-}--.hexagon + .hexagon + .hexagon {- margin-left: 8px;- animation: hexloader 1.4s 0.4s infinite ease-in-out;- background-color: #6041d0;-}--.hexagon + .hexagon + .hexagon:before {- border-bottom-color: #6041d0;-}--.hexagon + .hexagon + .hexagon:after {- border-top-color: #6041d0;-}--@keyframes hexloader {- 0%,- 80%,- 100% {- transform: scale(0.5);- opacity: 0;- }- 40% {- transform: scale(1);- opacity: 1;- }-}diff --git a/apps/starter/public/android-chrome-192x192.png b/apps/starter/public/android-chrome-192x192.pngnew file mode 100644index 0000000000..bc936a17b0Binary files /dev/null and b/apps/starter/public/android-chrome-192x192.png differdiff --git a/apps/starter/public/android-chrome-512x512.png b/apps/starter/public/android-chrome-512x512.pngnew file mode 100644index 0000000000..841366bbf7Binary files /dev/null and b/apps/starter/public/android-chrome-512x512.png differdiff --git a/apps/starter/public/apple-touch-icon.png b/apps/starter/public/apple-touch-icon.pngindex 7d10fd7748..aadf41c525 100644Binary files a/apps/starter/public/apple-touch-icon.png and b/apps/starter/public/apple-touch-icon.png differdiff --git a/apps/starter/public/carbon-logo-mark.svg b/apps/starter/public/carbon-logo-mark.svgdeleted file mode 100644index 048049e1e5..0000000000--- a/apps/starter/public/carbon-logo-mark.svg+++ /dev/null@@ -1,20 +0,0 @@-<svg width="362" height="349" viewBox="0 0 362 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M181.165 139.643V69.8213L241.346 35.0564L241.054 104.878L181.165 139.643Z" fill="#60FFD2"/>-<path d="M181.165 69.8213V139.643L120.4 104.878V35.0564L181.165 69.8213Z" fill="#36B5B4"/>-<path d="M120.4 35.0565L181.165 69.8214L241.347 35.0565L181.165 -0.000610352L120.4 35.0565Z" fill="#5FE4D2"/>-<path d="M240.818 244.172V174.35L300.999 139.585L300.707 209.407L240.818 244.172Z" fill="#71DEFF"/>-<path d="M240.818 174.35V244.172L180.052 209.407V139.585L240.818 174.35Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.35L300.999 139.586L240.818 104.528L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.172V174.35L181.693 139.585L181.401 209.407L121.512 244.172Z" fill="#71DEFF"/>-<path d="M121.512 174.35V244.172L60.7466 209.407V139.585L121.512 174.35Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.35L181.694 139.586L121.512 104.528L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.701V278.879L241.346 244.114L241.054 313.936L181.165 348.701Z" fill="#7D7FE5"/>-<path d="M181.165 278.879V348.701L120.4 313.936V244.114L181.165 278.879Z" fill="#2F31AE"/>-<path d="M120.4 244.114L181.165 278.879L241.347 244.114L181.165 209.057L120.4 244.114Z" fill="#6041D0"/>-<path d="M60.7651 348.701V278.879L120.946 244.114L120.654 313.936L60.7651 348.701Z" fill="#7D7FE5"/>-<path d="M60.7656 278.879V348.701L0 313.936V244.114L60.7656 278.879Z" fill="#2F31AE"/>-<path d="M0 244.114L60.7656 278.879L120.947 244.114L60.7656 209.057L0 244.114Z" fill="#6041D0"/>-<path d="M301.017 348.701V278.879L361.198 244.114L360.906 313.936L301.017 348.701Z" fill="#7D7FE5"/>-<path d="M301.018 278.879V348.701L240.252 313.936V244.114L301.018 278.879Z" fill="#2F31AE"/>-<path d="M240.252 244.114L301.018 278.879L361.199 244.114L301.018 209.057L240.252 244.114Z" fill="#6041D0"/>-</svg>diff --git a/apps/starter/public/carbon-mark-dark.svg b/apps/starter/public/carbon-mark-dark.svgnew file mode 100644index 0000000000..047b926154--- /dev/null+++ b/apps/starter/public/carbon-mark-dark.svg@@ -0,0 +1,3 @@+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#E6E6E6"/>+</svg>diff --git a/apps/starter/public/carbon-mark-light.svg b/apps/starter/public/carbon-mark-light.svgnew file mode 100644index 0000000000..db0480c53c--- /dev/null+++ b/apps/starter/public/carbon-mark-light.svg@@ -0,0 +1,3 @@+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#101A24"/>+</svg>diff --git a/apps/starter/public/carbon-word-dark.png b/apps/starter/public/carbon-word-dark.pngdeleted file mode 100644index 3606059a75..0000000000Binary files a/apps/starter/public/carbon-word-dark.png and /dev/null differdiff --git a/apps/starter/public/carbon-word-dark.svg b/apps/starter/public/carbon-word-dark.svgindex b555c4b360..c4463b4061 100644--- a/apps/starter/public/carbon-word-dark.svg+++ b/apps/starter/public/carbon-word-dark.svg@@ -1,26 +1,9 @@-<svg width="1307" height="349" viewBox="0 0 1307 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M412.646 193.426C412.646 178.405 415.703 165.305 421.816 154.126C427.929 142.773 436.401 134.039 447.23 127.926C458.059 121.638 470.461 118.494 484.434 118.494C502.425 118.494 517.271 123.035 528.974 132.118C540.851 141.026 548.799 153.602 552.816 169.846H513.254C511.158 163.558 507.577 158.667 502.512 155.174C497.621 151.506 491.508 149.672 484.172 149.672C473.692 149.672 465.395 153.515 459.282 161.2C453.169 168.711 450.112 179.453 450.112 193.426C450.112 207.225 453.169 217.967 459.282 225.652C465.395 233.163 473.692 236.918 484.172 236.918C499.019 236.918 508.713 230.281 513.254 217.006H552.816C548.799 232.726 540.851 245.215 528.974 254.472C517.097 263.729 502.25 268.358 484.434 268.358C470.461 268.358 458.059 265.301 447.23 259.188C436.401 252.9 427.929 244.167 421.816 232.988C415.703 221.635 412.646 208.447 412.646 193.426Z" fill="white"/>-<path d="M562.395 192.902C562.395 178.23 565.277 165.217 571.041 153.864C576.98 142.511 584.927 133.777 594.883 127.664C605.014 121.551 616.28 118.494 628.681 118.494C639.511 118.494 648.943 120.677 656.977 125.044C665.187 129.411 671.737 134.913 676.627 141.55V120.852H713.569V266H676.627V244.778C671.911 251.59 665.361 257.267 656.977 261.808C648.768 266.175 639.249 268.358 628.419 268.358C616.193 268.358 605.014 265.214 594.883 258.926C584.927 252.638 576.98 243.817 571.041 232.464C565.277 220.936 562.395 207.749 562.395 192.902ZM676.627 193.426C676.627 184.518 674.881 176.92 671.387 170.632C667.894 164.169 663.178 159.279 657.239 155.96C651.301 152.467 644.925 150.72 638.113 150.72C631.301 150.72 625.013 152.379 619.249 155.698C613.485 159.017 608.769 163.907 605.101 170.37C601.608 176.658 599.861 184.169 599.861 192.902C599.861 201.635 601.608 209.321 605.101 215.958C608.769 222.421 613.485 227.399 619.249 230.892C625.188 234.385 631.476 236.132 638.113 236.132C644.925 236.132 651.301 234.473 657.239 231.154C663.178 227.661 667.894 222.77 671.387 216.482C674.881 210.019 676.627 202.334 676.627 193.426Z" fill="white"/>-<path d="M778.214 143.384C782.93 135.699 789.043 129.673 796.554 125.306C804.239 120.939 812.972 118.756 822.754 118.756V157.27H813.06C801.532 157.27 792.798 159.977 786.86 165.392C781.096 170.807 778.214 180.239 778.214 193.688V266H741.534V120.852H778.214V143.384Z" fill="white"/>-<path d="M876.28 142.074C880.996 135.087 887.458 129.411 895.668 125.044C904.052 120.677 913.571 118.494 924.226 118.494C936.627 118.494 947.806 121.551 957.762 127.664C967.892 133.777 975.84 142.511 981.604 153.864C987.542 165.043 990.512 178.055 990.512 192.902C990.512 207.749 987.542 220.936 981.604 232.464C975.84 243.817 967.892 252.638 957.762 258.926C947.806 265.214 936.627 268.358 924.226 268.358C913.396 268.358 903.877 266.262 895.668 262.07C887.633 257.703 881.17 252.114 876.28 245.302V266H839.6V72.12H876.28V142.074ZM953.046 192.902C953.046 184.169 951.212 176.658 947.544 170.37C944.05 163.907 939.334 159.017 933.396 155.698C927.632 152.379 921.344 150.72 914.532 150.72C907.894 150.72 901.606 152.467 895.668 155.96C889.904 159.279 885.188 164.169 881.52 170.632C878.026 177.095 876.28 184.693 876.28 193.426C876.28 202.159 878.026 209.757 881.52 216.22C885.188 222.683 889.904 227.661 895.668 231.154C901.606 234.473 907.894 236.132 914.532 236.132C921.344 236.132 927.632 234.385 933.396 230.892C939.334 227.399 944.05 222.421 947.544 215.958C951.212 209.495 953.046 201.81 953.046 192.902Z" fill="white"/>-<path d="M1073.76 268.358C1059.78 268.358 1047.21 265.301 1036.03 259.188C1024.85 252.9 1016.03 244.079 1009.57 232.726C1003.28 221.373 1000.14 208.273 1000.14 193.426C1000.14 178.579 1003.37 165.479 1009.83 154.126C1016.47 142.773 1025.46 134.039 1036.82 127.926C1048.17 121.638 1060.83 118.494 1074.81 118.494C1088.78 118.494 1101.44 121.638 1112.8 127.926C1124.15 134.039 1133.06 142.773 1139.52 154.126C1146.16 165.479 1149.48 178.579 1149.48 193.426C1149.48 208.273 1146.07 221.373 1139.26 232.726C1132.62 244.079 1123.54 252.9 1112.01 259.188C1100.66 265.301 1087.91 268.358 1073.76 268.358ZM1073.76 236.394C1080.4 236.394 1086.6 234.822 1092.36 231.678C1098.3 228.359 1103.01 223.469 1106.51 217.006C1110 210.543 1111.75 202.683 1111.75 193.426C1111.75 179.627 1108.08 169.06 1100.74 161.724C1093.58 154.213 1084.76 150.458 1074.28 150.458C1063.8 150.458 1054.98 154.213 1047.82 161.724C1040.83 169.06 1037.34 179.627 1037.34 193.426C1037.34 207.225 1040.75 217.879 1047.56 225.39C1054.54 232.726 1063.28 236.394 1073.76 236.394Z" fill="white"/>-<path d="M1248.96 118.756C1266.25 118.756 1280.22 124.258 1290.88 135.262C1301.53 146.091 1306.86 161.287 1306.86 180.85V266H1270.18V185.828C1270.18 174.3 1267.3 165.479 1261.53 159.366C1255.77 153.078 1247.91 149.934 1237.95 149.934C1227.82 149.934 1219.79 153.078 1213.85 159.366C1208.08 165.479 1205.2 174.3 1205.2 185.828V266H1168.52V120.852H1205.2V138.93C1210.09 132.642 1216.29 127.751 1223.8 124.258C1231.49 120.59 1239.87 118.756 1248.96 118.756Z" fill="white"/>-<path d="M181.165 139.644V69.822L241.346 35.0571L241.054 104.879L181.165 139.644Z" fill="#60FFD2"/>-<path d="M181.165 69.822V139.644L120.4 104.879V35.0571L181.165 69.822Z" fill="#36B5B4"/>-<path d="M120.4 35.0571L181.165 69.822L241.346 35.0571L181.165 0L120.4 35.0571Z" fill="#5FE4D2"/>-<path d="M240.818 244.173V174.351L300.999 139.586L300.707 209.408L240.818 244.173Z" fill="#71DEFF"/>-<path d="M240.818 174.351V244.173L180.052 209.408V139.586L240.818 174.351Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.351L300.999 139.586L240.818 104.529L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.173V174.351L181.693 139.586L181.401 209.408L121.512 244.173Z" fill="#71DEFF"/>-<path d="M121.512 174.351V244.173L60.7466 209.408V139.586L121.512 174.351Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.351L181.693 139.586L121.512 104.529L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.702V278.88L241.346 244.115L241.054 313.937L181.165 348.702Z" fill="#7D7FE5"/>-<path d="M181.165 278.88V348.702L120.4 313.937V244.115L181.165 278.88Z" fill="#2F31AE"/>-<path d="M120.4 244.115L181.165 278.88L241.346 244.115L181.165 209.057L120.4 244.115Z" fill="#6041D0"/>-<path d="M60.7652 348.702V278.88L120.947 244.115L120.654 313.937L60.7652 348.702Z" fill="#7D7FE5"/>-<path d="M60.7652 278.88V348.702L0 313.937V244.115L60.7652 278.88Z" fill="#2F31AE"/>-<path d="M0 244.115L60.7652 278.88L120.947 244.115L60.7656 209.057L0 244.115Z" fill="#6041D0"/>-<path d="M301.017 348.702V278.88L361.198 244.115L360.906 313.937L301.017 348.702Z" fill="#7D7FE5"/>-<path d="M301.017 278.88V348.702L240.252 313.937V244.115L301.017 278.88Z" fill="#2F31AE"/>-<path d="M240.252 244.115L301.017 278.88L361.198 244.115L301.018 209.057L240.252 244.115Z" fill="#6041D0"/>+<svg width="720" height="175" viewBox="0 0 720 175" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M64.2993 3.57443C72.343 -1.19144 82.3494 -1.19151 90.3931 3.57443L142.163 34.2484C149.93 38.8505 154.692 47.2038 154.692 56.2254V118.775C154.692 127.796 149.93 136.149 142.163 140.752L90.3931 171.426C82.3494 176.192 72.343 176.191 64.2993 171.426L12.5296 140.752C4.76242 136.149 0 127.796 0 118.775V56.2254C0 47.2037 4.76242 38.8505 12.5296 34.2484L64.2993 3.57443ZM81.004 40.286C78.8708 39.0012 76.2016 38.9983 74.0657 40.2786L42.6851 59.0884C38.3192 61.7055 38.3303 68.0312 42.7057 70.6326L74.173 89.3408C74.3089 89.4216 74.3921 89.5681 74.3921 89.726V126.818C74.3922 132.04 80.0912 135.269 84.5774 132.589L115.594 114.057C117.626 112.843 118.87 110.652 118.87 108.287V66.8923C118.87 64.5357 117.635 62.3509 115.615 61.134L81.004 40.286Z" fill="#E6E6E6"/>+<path d="M236.385 133.457C229.22 133.457 222.857 132.223 217.298 129.754C211.862 127.163 207.291 123.645 203.584 119.202C200.002 114.635 197.284 109.513 195.431 103.836C193.577 98.1581 192.651 92.2338 192.651 86.0626C192.651 79.8914 193.577 73.9671 195.431 68.2897C197.284 62.6122 200.002 57.5518 203.584 53.1086C207.291 48.6654 211.862 45.2095 217.298 42.741C222.857 40.1492 229.22 38.8532 236.385 38.8532C245.404 38.8532 253.249 41.0131 259.921 45.3329C266.716 49.6528 271.719 56.3176 274.931 65.3275L256.77 72.3626C255.288 67.6725 252.879 63.9081 249.543 61.0694C246.207 58.1072 241.821 56.6262 236.385 56.6262C230.95 56.6262 226.502 58.0455 223.043 60.8843C219.707 63.723 217.236 67.364 215.63 71.8072C214.024 76.2505 213.221 81.0023 213.221 86.0626C213.221 91.123 214.024 95.9365 215.63 100.503C217.236 104.946 219.707 108.587 223.043 111.426C226.502 114.141 230.95 115.499 236.385 115.499C241.821 115.499 246.207 114.08 249.543 111.241C252.879 108.402 255.288 104.638 256.77 99.9477L274.931 106.983C271.719 115.869 266.716 122.534 259.921 126.977C253.249 131.297 245.404 133.457 236.385 133.457Z" fill="#E6E6E6"/>+<path d="M343.217 131.791L341.735 116.425V74.214C341.735 68.2897 339.943 63.8464 336.361 60.8843C332.778 57.7987 327.774 56.2559 321.35 56.2559C316.408 56.2559 311.528 57.2433 306.71 59.218C302.015 61.0694 297.691 63.9698 293.738 67.9194L282.248 54.4045C288.178 48.8505 294.479 44.901 301.151 42.5559C307.822 40.0874 315.111 38.8532 323.018 38.8532C335.372 38.8532 344.947 42.0005 351.742 48.2951C358.66 54.4663 362.12 63.1059 362.12 74.214V131.791H343.217ZM314.864 133.457C308.069 133.457 302.015 132.223 296.703 129.754C291.514 127.286 287.437 123.83 284.472 119.387C281.631 114.944 280.21 109.76 280.21 103.836C280.21 98.7752 281.26 94.3937 283.36 90.691C285.584 86.9883 288.426 84.0878 291.885 81.9896C294.85 80.1383 298.309 78.8423 302.262 78.1018C306.216 77.2378 310.355 76.8059 314.679 76.8059H343.403V92.1721H317.644C315.42 92.1721 313.196 92.4189 310.972 92.9126C308.749 93.2829 306.772 94.0234 305.042 95.1342C303.807 96.1216 302.757 97.3558 301.892 98.8369C301.151 100.318 300.78 102.046 300.78 104.021C300.78 107.97 302.262 111.118 305.228 113.463C308.316 115.684 312.393 116.795 317.458 116.795C321.906 116.795 325.921 115.808 329.504 113.833C333.21 111.858 336.175 109.143 338.399 105.687C340.623 102.231 341.735 98.3432 341.735 94.0234L348.036 104.206C346.553 110.624 344.206 116.054 340.994 120.498C337.781 124.818 333.952 128.088 329.504 130.31C325.056 132.408 320.176 133.457 314.864 133.457Z" fill="#E6E6E6"/>+<path d="M375.823 131.791V40.5194H396.578V65.1424L392.687 65.6978C393.304 60.3906 395.096 55.7622 398.061 51.8127C401.026 47.7397 404.609 44.5924 408.809 42.3708C413.133 40.0257 417.395 38.8532 421.596 38.8532C424.561 38.8532 427.403 39.2235 430.121 39.964C432.839 40.7046 435.68 41.9388 438.645 43.6667L428.638 62.1802C427.279 61.3162 425.488 60.6374 423.264 60.1437C421.164 59.5266 419.125 59.218 417.148 59.218C414.554 59.218 411.96 59.7117 409.365 60.6991C406.894 61.6865 404.67 63.2293 402.694 65.3275C400.717 67.3023 399.234 69.8942 398.246 73.1032C397.628 74.8311 397.134 77.1144 396.764 79.9532C396.517 82.6685 396.393 86.4946 396.393 91.4315V131.791H375.823Z" fill="#E6E6E6"/>+<path d="M492.002 133.457C487.06 133.457 482.365 132.47 477.918 130.495C473.594 128.52 469.825 125.496 466.613 121.423C463.401 117.227 460.992 111.796 459.386 105.132L464.76 106.427V131.791H444.375V2.75192H464.76V66.068H460.127C461.363 60.2672 463.463 55.3919 466.428 51.4424C469.517 47.3694 473.223 44.2838 477.547 42.1856C481.995 39.964 486.813 38.8532 492.002 38.8532C499.414 38.8532 506.086 40.7663 512.016 44.5924C518.069 48.2951 522.888 53.664 526.47 60.6991C530.053 67.7343 531.845 76.1887 531.845 86.0626C531.845 95.0725 530.177 103.157 526.841 110.315C523.629 117.474 519.058 123.151 513.128 127.348C507.198 131.421 500.156 133.457 492.002 133.457ZM486.998 114.573C491.816 114.573 496.017 113.401 499.6 111.056C503.306 108.711 506.147 105.378 508.124 101.059C510.101 96.7387 511.089 91.7401 511.089 86.0626C511.089 80.3851 510.101 75.3865 508.124 71.0667C506.147 66.7469 503.306 63.4144 499.6 61.0694C496.017 58.7244 491.816 57.5518 486.998 57.5518C482.18 57.5518 477.918 58.7861 474.211 61.2545C470.629 63.5996 467.849 66.932 465.872 71.2518C463.895 75.4482 462.907 80.3851 462.907 86.0626C462.907 91.7401 463.895 96.7387 465.872 101.059C467.849 105.378 470.629 108.711 474.211 111.056C477.918 113.401 482.18 114.573 486.998 114.573Z" fill="#E6E6E6"/>+<path d="M583.567 133.457C574.919 133.457 567.135 131.421 560.217 127.348C553.298 123.275 547.862 117.659 543.909 110.5C540.079 103.342 538.164 95.1959 538.164 86.0626C538.164 76.9293 540.079 68.7834 543.909 61.6248C547.862 54.4663 553.237 48.9122 560.032 44.9627C566.95 40.8897 574.795 38.8532 583.567 38.8532C592.462 38.8532 600.245 40.8897 606.917 44.9627C613.711 48.9122 619.086 54.4663 623.039 61.6248C626.992 68.7834 628.969 76.9293 628.969 86.0626C628.969 95.1959 626.992 103.342 623.039 110.5C619.209 117.659 613.835 123.275 606.917 127.348C600.122 131.421 592.338 133.457 583.567 133.457ZM583.752 115.314C588.817 115.314 593.203 114.141 596.909 111.796C600.616 109.451 603.457 106.057 605.434 101.614C607.411 97.1707 608.399 91.9869 608.399 86.0626C608.399 80.0149 607.411 74.8311 605.434 70.5113C603.457 66.068 600.616 62.6739 596.909 60.3289C593.203 57.9838 588.817 56.8113 583.752 56.8113C578.44 56.8113 573.93 58.0455 570.224 60.514C566.518 62.859 563.676 66.1915 561.699 70.5113C559.723 74.8311 558.734 80.0149 558.734 86.0626C558.734 91.9869 559.723 97.1707 561.699 101.614C563.676 106.057 566.518 109.451 570.224 111.796C573.93 114.141 578.44 115.314 583.752 115.314Z" fill="#E6E6E6"/>+<path d="M639.573 131.791V40.5194H660.143V60.6991L656.437 61.6248C658.043 56.3176 660.39 51.9978 663.479 48.6654C666.567 45.3329 670.15 42.8645 674.227 41.26C678.427 39.6555 682.813 38.8532 687.384 38.8532C697.639 38.8532 705.607 41.8154 711.29 47.7397C717.097 53.5406 720 61.8716 720 72.7329V131.791H699.43V80.3234C699.43 72.1775 697.947 66.1915 694.982 62.3653C692.017 58.5392 687.446 56.6262 681.269 56.6262C676.698 56.6262 672.806 57.737 669.594 59.9586C666.505 62.0568 664.158 65.3892 662.552 69.9559C660.946 74.5225 660.143 80.3234 660.143 87.3585V131.791H639.573Z" fill="#E6E6E6"/></svg>diff --git a/apps/starter/public/carbon-word-light.png b/apps/starter/public/carbon-word-light.pngdeleted file mode 100644index becd8f13bb..0000000000Binary files a/apps/starter/public/carbon-word-light.png and /dev/null differdiff --git a/apps/starter/public/carbon-word-light.svg b/apps/starter/public/carbon-word-light.svgindex 3e899a2d1b..3fd85675c9 100644--- a/apps/starter/public/carbon-word-light.svg+++ b/apps/starter/public/carbon-word-light.svg@@ -1,26 +1,9 @@-<svg width="1307" height="349" viewBox="0 0 1307 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M412.646 193.426C412.646 178.405 415.703 165.305 421.816 154.126C427.929 142.773 436.401 134.039 447.23 127.926C458.059 121.638 470.461 118.494 484.434 118.494C502.425 118.494 517.271 123.035 528.974 132.118C540.851 141.026 548.799 153.602 552.816 169.846H513.254C511.158 163.558 507.577 158.667 502.512 155.174C497.621 151.506 491.508 149.672 484.172 149.672C473.692 149.672 465.395 153.515 459.282 161.2C453.169 168.711 450.112 179.453 450.112 193.426C450.112 207.225 453.169 217.967 459.282 225.652C465.395 233.163 473.692 236.918 484.172 236.918C499.019 236.918 508.713 230.281 513.254 217.006H552.816C548.799 232.726 540.851 245.215 528.974 254.472C517.097 263.729 502.25 268.358 484.434 268.358C470.461 268.358 458.059 265.301 447.23 259.188C436.401 252.9 427.929 244.167 421.816 232.988C415.703 221.635 412.646 208.447 412.646 193.426Z" fill="#212278"/>-<path d="M562.395 192.902C562.395 178.23 565.277 165.217 571.041 153.864C576.98 142.511 584.927 133.777 594.883 127.664C605.014 121.551 616.28 118.494 628.681 118.494C639.511 118.494 648.943 120.677 656.977 125.044C665.187 129.411 671.737 134.913 676.627 141.55V120.852H713.569V266H676.627V244.778C671.911 251.59 665.361 257.267 656.977 261.808C648.768 266.175 639.249 268.358 628.419 268.358C616.193 268.358 605.014 265.214 594.883 258.926C584.927 252.638 576.98 243.817 571.041 232.464C565.277 220.936 562.395 207.749 562.395 192.902ZM676.627 193.426C676.627 184.518 674.881 176.92 671.387 170.632C667.894 164.169 663.178 159.279 657.239 155.96C651.301 152.467 644.925 150.72 638.113 150.72C631.301 150.72 625.013 152.379 619.249 155.698C613.485 159.017 608.769 163.907 605.101 170.37C601.608 176.658 599.861 184.169 599.861 192.902C599.861 201.635 601.608 209.321 605.101 215.958C608.769 222.421 613.485 227.399 619.249 230.892C625.188 234.385 631.476 236.132 638.113 236.132C644.925 236.132 651.301 234.473 657.239 231.154C663.178 227.661 667.894 222.77 671.387 216.482C674.881 210.019 676.627 202.334 676.627 193.426Z" fill="#212278"/>-<path d="M778.214 143.384C782.93 135.699 789.043 129.673 796.554 125.306C804.239 120.939 812.972 118.756 822.754 118.756V157.27H813.06C801.532 157.27 792.798 159.977 786.86 165.392C781.096 170.807 778.214 180.239 778.214 193.688V266H741.534V120.852H778.214V143.384Z" fill="#212278"/>-<path d="M876.28 142.074C880.996 135.087 887.458 129.411 895.668 125.044C904.052 120.677 913.571 118.494 924.226 118.494C936.627 118.494 947.806 121.551 957.762 127.664C967.892 133.777 975.84 142.511 981.604 153.864C987.542 165.043 990.512 178.055 990.512 192.902C990.512 207.749 987.542 220.936 981.604 232.464C975.84 243.817 967.892 252.638 957.762 258.926C947.806 265.214 936.627 268.358 924.226 268.358C913.396 268.358 903.877 266.262 895.668 262.07C887.633 257.703 881.17 252.114 876.28 245.302V266H839.6V72.12H876.28V142.074ZM953.046 192.902C953.046 184.169 951.212 176.658 947.544 170.37C944.05 163.907 939.334 159.017 933.396 155.698C927.632 152.379 921.344 150.72 914.532 150.72C907.894 150.72 901.606 152.467 895.668 155.96C889.904 159.279 885.188 164.169 881.52 170.632C878.026 177.095 876.28 184.693 876.28 193.426C876.28 202.159 878.026 209.757 881.52 216.22C885.188 222.683 889.904 227.661 895.668 231.154C901.606 234.473 907.894 236.132 914.532 236.132C921.344 236.132 927.632 234.385 933.396 230.892C939.334 227.399 944.05 222.421 947.544 215.958C951.212 209.495 953.046 201.81 953.046 192.902Z" fill="#212278"/>-<path d="M1073.76 268.358C1059.78 268.358 1047.21 265.301 1036.03 259.188C1024.85 252.9 1016.03 244.079 1009.57 232.726C1003.28 221.373 1000.14 208.273 1000.14 193.426C1000.14 178.579 1003.37 165.479 1009.83 154.126C1016.47 142.773 1025.46 134.039 1036.82 127.926C1048.17 121.638 1060.83 118.494 1074.81 118.494C1088.78 118.494 1101.44 121.638 1112.8 127.926C1124.15 134.039 1133.06 142.773 1139.52 154.126C1146.16 165.479 1149.48 178.579 1149.48 193.426C1149.48 208.273 1146.07 221.373 1139.26 232.726C1132.62 244.079 1123.54 252.9 1112.01 259.188C1100.66 265.301 1087.91 268.358 1073.76 268.358ZM1073.76 236.394C1080.4 236.394 1086.6 234.822 1092.36 231.678C1098.3 228.359 1103.01 223.469 1106.51 217.006C1110 210.543 1111.75 202.683 1111.75 193.426C1111.75 179.627 1108.08 169.06 1100.74 161.724C1093.58 154.213 1084.76 150.458 1074.28 150.458C1063.8 150.458 1054.98 154.213 1047.82 161.724C1040.83 169.06 1037.34 179.627 1037.34 193.426C1037.34 207.225 1040.75 217.879 1047.56 225.39C1054.54 232.726 1063.28 236.394 1073.76 236.394Z" fill="#212278"/>-<path d="M1248.96 118.756C1266.25 118.756 1280.22 124.258 1290.88 135.262C1301.53 146.091 1306.86 161.287 1306.86 180.85V266H1270.18V185.828C1270.18 174.3 1267.3 165.479 1261.53 159.366C1255.77 153.078 1247.91 149.934 1237.95 149.934C1227.82 149.934 1219.79 153.078 1213.85 159.366C1208.08 165.479 1205.2 174.3 1205.2 185.828V266H1168.52V120.852H1205.2V138.93C1210.09 132.642 1216.29 127.751 1223.8 124.258C1231.49 120.59 1239.87 118.756 1248.96 118.756Z" fill="#212278"/>-<path d="M181.165 139.644V69.822L241.346 35.0571L241.054 104.879L181.165 139.644Z" fill="#60FFD2"/>-<path d="M181.165 69.822V139.644L120.4 104.879V35.0571L181.165 69.822Z" fill="#36B5B4"/>-<path d="M120.4 35.0571L181.165 69.822L241.346 35.0571L181.165 0L120.4 35.0571Z" fill="#5FE4D2"/>-<path d="M240.818 244.173V174.351L300.999 139.586L300.707 209.408L240.818 244.173Z" fill="#71DEFF"/>-<path d="M240.818 174.351V244.173L180.052 209.408V139.586L240.818 174.351Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.351L300.999 139.586L240.818 104.529L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.173V174.351L181.693 139.586L181.401 209.408L121.512 244.173Z" fill="#71DEFF"/>-<path d="M121.512 174.351V244.173L60.7466 209.408V139.586L121.512 174.351Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.351L181.693 139.586L121.512 104.529L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.702V278.88L241.346 244.115L241.054 313.937L181.165 348.702Z" fill="#7D7FE5"/>-<path d="M181.165 278.88V348.702L120.4 313.937V244.115L181.165 278.88Z" fill="#2F31AE"/>-<path d="M120.4 244.115L181.165 278.88L241.346 244.115L181.165 209.057L120.4 244.115Z" fill="#6041D0"/>-<path d="M60.7652 348.702V278.88L120.947 244.115L120.654 313.937L60.7652 348.702Z" fill="#7D7FE5"/>-<path d="M60.7652 278.88V348.702L-1.52588e-05 313.937V244.115L60.7652 278.88Z" fill="#2F31AE"/>-<path d="M-1.52588e-05 244.115L60.7652 278.88L120.947 244.115L60.7656 209.057L-1.52588e-05 244.115Z" fill="#6041D0"/>-<path d="M301.017 348.702V278.88L361.198 244.115L360.906 313.937L301.017 348.702Z" fill="#7D7FE5"/>-<path d="M301.017 278.88V348.702L240.252 313.937V244.115L301.017 278.88Z" fill="#2F31AE"/>-<path d="M240.252 244.115L301.017 278.88L361.198 244.115L301.018 209.057L240.252 244.115Z" fill="#6041D0"/>+<svg width="720" height="175" viewBox="0 0 720 175" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M64.2993 3.57443C72.343 -1.19144 82.3494 -1.19151 90.3931 3.57443L142.163 34.2484C149.93 38.8505 154.692 47.2038 154.692 56.2254V118.775C154.692 127.796 149.93 136.149 142.163 140.752L90.3931 171.426C82.3494 176.192 72.343 176.191 64.2993 171.426L12.5296 140.752C4.76242 136.149 0 127.796 0 118.775V56.2254C0 47.2037 4.76242 38.8505 12.5296 34.2484L64.2993 3.57443ZM81.004 40.286C78.8708 39.0012 76.2016 38.9983 74.0657 40.2786L42.6851 59.0884C38.3192 61.7055 38.3303 68.0312 42.7057 70.6326L74.173 89.3408C74.3089 89.4216 74.3921 89.5681 74.3921 89.726V126.818C74.3922 132.04 80.0912 135.269 84.5774 132.589L115.594 114.057C117.626 112.843 118.87 110.652 118.87 108.287V66.8923C118.87 64.5357 117.635 62.3509 115.615 61.134L81.004 40.286Z" fill="#101A24"/>+<path d="M236.385 133.457C229.22 133.457 222.857 132.223 217.298 129.754C211.862 127.163 207.291 123.645 203.584 119.202C200.002 114.635 197.284 109.513 195.431 103.836C193.577 98.1581 192.651 92.2338 192.651 86.0626C192.651 79.8914 193.577 73.9671 195.431 68.2897C197.284 62.6122 200.002 57.5518 203.584 53.1086C207.291 48.6654 211.862 45.2095 217.298 42.741C222.857 40.1492 229.22 38.8532 236.385 38.8532C245.404 38.8532 253.249 41.0131 259.921 45.3329C266.716 49.6528 271.719 56.3176 274.931 65.3275L256.77 72.3626C255.288 67.6725 252.879 63.9081 249.543 61.0694C246.207 58.1072 241.821 56.6262 236.385 56.6262C230.95 56.6262 226.502 58.0455 223.043 60.8843C219.707 63.723 217.236 67.364 215.63 71.8072C214.024 76.2505 213.221 81.0023 213.221 86.0626C213.221 91.123 214.024 95.9365 215.63 100.503C217.236 104.946 219.707 108.587 223.043 111.426C226.502 114.141 230.95 115.499 236.385 115.499C241.821 115.499 246.207 114.08 249.543 111.241C252.879 108.402 255.288 104.638 256.77 99.9477L274.931 106.983C271.719 115.869 266.716 122.534 259.921 126.977C253.249 131.297 245.404 133.457 236.385 133.457Z" fill="#101A24"/>+<path d="M343.217 131.791L341.735 116.425V74.214C341.735 68.2897 339.943 63.8464 336.361 60.8843C332.778 57.7987 327.774 56.2559 321.35 56.2559C316.408 56.2559 311.528 57.2433 306.71 59.218C302.015 61.0694 297.691 63.9698 293.738 67.9194L282.248 54.4045C288.178 48.8505 294.479 44.901 301.151 42.5559C307.822 40.0874 315.111 38.8532 323.018 38.8532C335.372 38.8532 344.947 42.0005 351.742 48.2951C358.66 54.4663 362.12 63.1059 362.12 74.214V131.791H343.217ZM314.864 133.457C308.069 133.457 302.015 132.223 296.703 129.754C291.514 127.286 287.437 123.83 284.472 119.387C281.631 114.944 280.21 109.76 280.21 103.836C280.21 98.7752 281.26 94.3937 283.36 90.691C285.584 86.9883 288.426 84.0878 291.885 81.9896C294.85 80.1383 298.309 78.8423 302.262 78.1018C306.216 77.2378 310.355 76.8059 314.679 76.8059H343.403V92.1721H317.644C315.42 92.1721 313.196 92.4189 310.972 92.9126C308.749 93.2829 306.772 94.0234 305.042 95.1342C303.807 96.1216 302.757 97.3558 301.892 98.8369C301.151 100.318 300.78 102.046 300.78 104.021C300.78 107.97 302.262 111.118 305.228 113.463C308.316 115.684 312.393 116.795 317.458 116.795C321.906 116.795 325.921 115.808 329.504 113.833C333.21 111.858 336.175 109.143 338.399 105.687C340.623 102.231 341.735 98.3432 341.735 94.0234L348.036 104.206C346.553 110.624 344.206 116.054 340.994 120.498C337.781 124.818 333.952 128.088 329.504 130.31C325.056 132.408 320.176 133.457 314.864 133.457Z" fill="#101A24"/>+<path d="M375.823 131.791V40.5194H396.578V65.1424L392.687 65.6978C393.304 60.3906 395.096 55.7622 398.061 51.8127C401.026 47.7397 404.609 44.5924 408.809 42.3708C413.133 40.0257 417.395 38.8532 421.596 38.8532C424.561 38.8532 427.403 39.2235 430.121 39.964C432.839 40.7046 435.68 41.9388 438.645 43.6667L428.638 62.1802C427.279 61.3162 425.488 60.6374 423.264 60.1437C421.164 59.5266 419.125 59.218 417.148 59.218C414.554 59.218 411.96 59.7117 409.365 60.6991C406.894 61.6865 404.67 63.2293 402.694 65.3275C400.717 67.3023 399.234 69.8942 398.246 73.1032C397.628 74.8311 397.134 77.1144 396.764 79.9532C396.517 82.6685 396.393 86.4946 396.393 91.4315V131.791H375.823Z" fill="#101A24"/>+<path d="M492.002 133.457C487.06 133.457 482.365 132.47 477.918 130.495C473.594 128.52 469.825 125.496 466.613 121.423C463.401 117.227 460.992 111.796 459.386 105.132L464.76 106.427V131.791H444.375V2.75192H464.76V66.068H460.127C461.363 60.2672 463.463 55.3919 466.428 51.4424C469.517 47.3694 473.223 44.2838 477.547 42.1856C481.995 39.964 486.813 38.8532 492.002 38.8532C499.414 38.8532 506.086 40.7663 512.016 44.5924C518.069 48.2951 522.888 53.664 526.47 60.6991C530.053 67.7343 531.845 76.1887 531.845 86.0626C531.845 95.0725 530.177 103.157 526.841 110.315C523.629 117.474 519.058 123.151 513.128 127.348C507.198 131.421 500.156 133.457 492.002 133.457ZM486.998 114.573C491.816 114.573 496.017 113.401 499.6 111.056C503.306 108.711 506.147 105.378 508.124 101.059C510.101 96.7387 511.089 91.7401 511.089 86.0626C511.089 80.3851 510.101 75.3865 508.124 71.0667C506.147 66.7469 503.306 63.4144 499.6 61.0694C496.017 58.7244 491.816 57.5518 486.998 57.5518C482.18 57.5518 477.918 58.7861 474.211 61.2545C470.629 63.5996 467.849 66.932 465.872 71.2518C463.895 75.4482 462.907 80.3851 462.907 86.0626C462.907 91.7401 463.895 96.7387 465.872 101.059C467.849 105.378 470.629 108.711 474.211 111.056C477.918 113.401 482.18 114.573 486.998 114.573Z" fill="#101A24"/>+<path d="M583.567 133.457C574.919 133.457 567.135 131.421 560.217 127.348C553.298 123.275 547.862 117.659 543.909 110.5C540.079 103.342 538.164 95.1959 538.164 86.0626C538.164 76.9293 540.079 68.7834 543.909 61.6248C547.862 54.4663 553.237 48.9122 560.032 44.9627C566.95 40.8897 574.795 38.8532 583.567 38.8532C592.462 38.8532 600.245 40.8897 606.917 44.9627C613.711 48.9122 619.086 54.4663 623.039 61.6248C626.992 68.7834 628.969 76.9293 628.969 86.0626C628.969 95.1959 626.992 103.342 623.039 110.5C619.209 117.659 613.835 123.275 606.917 127.348C600.122 131.421 592.338 133.457 583.567 133.457ZM583.752 115.314C588.817 115.314 593.203 114.141 596.909 111.796C600.616 109.451 603.457 106.057 605.434 101.614C607.411 97.1707 608.399 91.9869 608.399 86.0626C608.399 80.0149 607.411 74.8311 605.434 70.5113C603.457 66.068 600.616 62.6739 596.909 60.3289C593.203 57.9838 588.817 56.8113 583.752 56.8113C578.44 56.8113 573.93 58.0455 570.224 60.514C566.518 62.859 563.676 66.1915 561.699 70.5113C559.723 74.8311 558.734 80.0149 558.734 86.0626C558.734 91.9869 559.723 97.1707 561.699 101.614C563.676 106.057 566.518 109.451 570.224 111.796C573.93 114.141 578.44 115.314 583.752 115.314Z" fill="#101A24"/>+<path d="M639.573 131.791V40.5194H660.143V60.6991L656.437 61.6248C658.043 56.3176 660.39 51.9978 663.479 48.6654C666.567 45.3329 670.15 42.8645 674.227 41.26C678.427 39.6555 682.813 38.8532 687.384 38.8532C697.639 38.8532 705.607 41.8154 711.29 47.7397C717.097 53.5406 720 61.8716 720 72.7329V131.791H699.43V80.3234C699.43 72.1775 697.947 66.1915 694.982 62.3653C692.017 58.5392 687.446 56.6262 681.269 56.6262C676.698 56.6262 672.806 57.737 669.594 59.9586C666.505 62.0568 664.158 65.3892 662.552 69.9559C660.946 74.5225 660.143 80.3234 660.143 87.3585V131.791H639.573Z" fill="#101A24"/></svg>diff --git a/apps/starter/public/favicon-16x16.png b/apps/starter/public/favicon-16x16.pngindex eb216e453f..7f08a7eae3 100644Binary files a/apps/starter/public/favicon-16x16.png and b/apps/starter/public/favicon-16x16.png differdiff --git a/apps/starter/public/favicon-32x32.png b/apps/starter/public/favicon-32x32.pngindex a7064d2122..348b196709 100644Binary files a/apps/starter/public/favicon-32x32.png and b/apps/starter/public/favicon-32x32.png differdiff --git a/apps/starter/public/favicon-96x96.png b/apps/starter/public/favicon-96x96.pngdeleted file mode 100644index c36c27be04..0000000000Binary files a/apps/starter/public/favicon-96x96.png and /dev/null differdiff --git a/apps/starter/public/favicon.ico b/apps/starter/public/favicon.icoindex a87e92b575..644a0d8ed5 100644Binary files a/apps/starter/public/favicon.ico and b/apps/starter/public/favicon.ico differdiff --git a/apps/starter/public/favicon.svg b/apps/starter/public/favicon.svgindex 1f953c23a1..047b926154 100644--- a/apps/starter/public/favicon.svg+++ b/apps/starter/public/favicon.svg@@ -1,22 +1,3 @@-<svg xmlns="http://www.w3.org/2000/svg" version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" width="362" height="349"><svg width="362" height="349" viewBox="0 0 362 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M181.165 139.643V69.8213L241.346 35.0564L241.054 104.878L181.165 139.643Z" fill="#60FFD2"></path>-<path d="M181.165 69.8213V139.643L120.4 104.878V35.0564L181.165 69.8213Z" fill="#36B5B4"></path>-<path d="M120.4 35.0565L181.165 69.8214L241.347 35.0565L181.165 -0.000610352L120.4 35.0565Z" fill="#5FE4D2"></path>-<path d="M240.818 244.172V174.35L300.999 139.585L300.707 209.407L240.818 244.172Z" fill="#71DEFF"></path>-<path d="M240.818 174.35V244.172L180.052 209.407V139.585L240.818 174.35Z" fill="#3877C5"></path>-<path d="M180.052 139.586L240.818 174.35L300.999 139.586L240.818 104.528L180.052 139.586Z" fill="#4EAADE"></path>-<path d="M121.512 244.172V174.35L181.693 139.585L181.401 209.407L121.512 244.172Z" fill="#71DEFF"></path>-<path d="M121.512 174.35V244.172L60.7466 209.407V139.585L121.512 174.35Z" fill="#3877C5"></path>-<path d="M60.7466 139.586L121.512 174.35L181.694 139.586L121.512 104.528L60.7466 139.586Z" fill="#4EAADE"></path>-<path d="M181.165 348.701V278.879L241.346 244.114L241.054 313.936L181.165 348.701Z" fill="#7D7FE5"></path>-<path d="M181.165 278.879V348.701L120.4 313.936V244.114L181.165 278.879Z" fill="#2F31AE"></path>-<path d="M120.4 244.114L181.165 278.879L241.347 244.114L181.165 209.057L120.4 244.114Z" fill="#6041D0"></path>-<path d="M60.7651 348.701V278.879L120.946 244.114L120.654 313.936L60.7651 348.701Z" fill="#7D7FE5"></path>-<path d="M60.7656 278.879V348.701L0 313.936V244.114L60.7656 278.879Z" fill="#2F31AE"></path>-<path d="M0 244.114L60.7656 278.879L120.947 244.114L60.7656 209.057L0 244.114Z" fill="#6041D0"></path>-<path d="M301.017 348.701V278.879L361.198 244.114L360.906 313.936L301.017 348.701Z" fill="#7D7FE5"></path>-<path d="M301.018 278.879V348.701L240.252 313.936V244.114L301.018 278.879Z" fill="#2F31AE"></path>-<path d="M240.252 244.114L301.018 278.879L361.199 244.114L301.018 209.057L240.252 244.114Z" fill="#6041D0"></path>-</svg><style>@media (prefers-color-scheme: light) { :root { filter: none; } }-@media (prefers-color-scheme: dark) { :root { filter: none; } }-</style></svg>\ No newline at end of file+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#E6E6E6"/>+</svg>diff --git a/apps/starter/public/site.webmanifest b/apps/starter/public/site.webmanifestindex 344837476f..4c0ea372e1 100644--- a/apps/starter/public/site.webmanifest+++ b/apps/starter/public/site.webmanifest@@ -1,21 +1 @@-{- "name": "Carbon",- "short_name": "Carbon",- "icons": [- {- "src": "/web-app-manifest-192x192.png",- "sizes": "192x192",- "type": "image/png",- "purpose": "maskable"- },- {- "src": "/web-app-manifest-512x512.png",- "sizes": "512x512",- "type": "image/png",- "purpose": "maskable"- }- ],- "theme_color": "#000000",- "background_color": "#000000",- "display": "standalone"-}\ No newline at end of file+{"name":"Carbon","short_name":"Carbon","icons":[{"src":"/android-chrome-192x192.png","sizes":"192x192","type":"image/png"},{"src":"/android-chrome-512x512.png","sizes":"512x512","type":"image/png"}],"theme_color":"#ffffff","background_color":"#ffffff","display":"standalone"}\ No newline at end of filediff --git a/apps/starter/public/web-app-manifest-192x192.png b/apps/starter/public/web-app-manifest-192x192.pngdeleted file mode 100644index cda38d5ed4..0000000000Binary files a/apps/starter/public/web-app-manifest-192x192.png and /dev/null differdiff --git a/apps/starter/public/web-app-manifest-512x512.png b/apps/starter/public/web-app-manifest-512x512.pngdeleted file mode 100644index 88c30a090e..0000000000Binary files a/apps/starter/public/web-app-manifest-512x512.png and /dev/null differdiff --git a/carbon-mark-dark.svg b/carbon-mark-dark.svgnew file mode 100644index 0000000000..047b926154--- /dev/null+++ b/carbon-mark-dark.svg@@ -0,0 +1,3 @@+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#E6E6E6"/>+</svg>diff --git a/carbon-mark-light.svg b/carbon-mark-light.svgnew file mode 100644index 0000000000..db0480c53c--- /dev/null+++ b/carbon-mark-light.svg@@ -0,0 +1,3 @@+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#101A24"/>+</svg>diff --git a/carbon-word-dark.svg b/carbon-word-dark.svgnew file mode 100644index 0000000000..c4463b4061--- /dev/null+++ b/carbon-word-dark.svg@@ -0,0 +1,9 @@+<svg width="720" height="175" viewBox="0 0 720 175" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M64.2993 3.57443C72.343 -1.19144 82.3494 -1.19151 90.3931 3.57443L142.163 34.2484C149.93 38.8505 154.692 47.2038 154.692 56.2254V118.775C154.692 127.796 149.93 136.149 142.163 140.752L90.3931 171.426C82.3494 176.192 72.343 176.191 64.2993 171.426L12.5296 140.752C4.76242 136.149 0 127.796 0 118.775V56.2254C0 47.2037 4.76242 38.8505 12.5296 34.2484L64.2993 3.57443ZM81.004 40.286C78.8708 39.0012 76.2016 38.9983 74.0657 40.2786L42.6851 59.0884C38.3192 61.7055 38.3303 68.0312 42.7057 70.6326L74.173 89.3408C74.3089 89.4216 74.3921 89.5681 74.3921 89.726V126.818C74.3922 132.04 80.0912 135.269 84.5774 132.589L115.594 114.057C117.626 112.843 118.87 110.652 118.87 108.287V66.8923C118.87 64.5357 117.635 62.3509 115.615 61.134L81.004 40.286Z" fill="#E6E6E6"/>+<path d="M236.385 133.457C229.22 133.457 222.857 132.223 217.298 129.754C211.862 127.163 207.291 123.645 203.584 119.202C200.002 114.635 197.284 109.513 195.431 103.836C193.577 98.1581 192.651 92.2338 192.651 86.0626C192.651 79.8914 193.577 73.9671 195.431 68.2897C197.284 62.6122 200.002 57.5518 203.584 53.1086C207.291 48.6654 211.862 45.2095 217.298 42.741C222.857 40.1492 229.22 38.8532 236.385 38.8532C245.404 38.8532 253.249 41.0131 259.921 45.3329C266.716 49.6528 271.719 56.3176 274.931 65.3275L256.77 72.3626C255.288 67.6725 252.879 63.9081 249.543 61.0694C246.207 58.1072 241.821 56.6262 236.385 56.6262C230.95 56.6262 226.502 58.0455 223.043 60.8843C219.707 63.723 217.236 67.364 215.63 71.8072C214.024 76.2505 213.221 81.0023 213.221 86.0626C213.221 91.123 214.024 95.9365 215.63 100.503C217.236 104.946 219.707 108.587 223.043 111.426C226.502 114.141 230.95 115.499 236.385 115.499C241.821 115.499 246.207 114.08 249.543 111.241C252.879 108.402 255.288 104.638 256.77 99.9477L274.931 106.983C271.719 115.869 266.716 122.534 259.921 126.977C253.249 131.297 245.404 133.457 236.385 133.457Z" fill="#E6E6E6"/>+<path d="M343.217 131.791L341.735 116.425V74.214C341.735 68.2897 339.943 63.8464 336.361 60.8843C332.778 57.7987 327.774 56.2559 321.35 56.2559C316.408 56.2559 311.528 57.2433 306.71 59.218C302.015 61.0694 297.691 63.9698 293.738 67.9194L282.248 54.4045C288.178 48.8505 294.479 44.901 301.151 42.5559C307.822 40.0874 315.111 38.8532 323.018 38.8532C335.372 38.8532 344.947 42.0005 351.742 48.2951C358.66 54.4663 362.12 63.1059 362.12 74.214V131.791H343.217ZM314.864 133.457C308.069 133.457 302.015 132.223 296.703 129.754C291.514 127.286 287.437 123.83 284.472 119.387C281.631 114.944 280.21 109.76 280.21 103.836C280.21 98.7752 281.26 94.3937 283.36 90.691C285.584 86.9883 288.426 84.0878 291.885 81.9896C294.85 80.1383 298.309 78.8423 302.262 78.1018C306.216 77.2378 310.355 76.8059 314.679 76.8059H343.403V92.1721H317.644C315.42 92.1721 313.196 92.4189 310.972 92.9126C308.749 93.2829 306.772 94.0234 305.042 95.1342C303.807 96.1216 302.757 97.3558 301.892 98.8369C301.151 100.318 300.78 102.046 300.78 104.021C300.78 107.97 302.262 111.118 305.228 113.463C308.316 115.684 312.393 116.795 317.458 116.795C321.906 116.795 325.921 115.808 329.504 113.833C333.21 111.858 336.175 109.143 338.399 105.687C340.623 102.231 341.735 98.3432 341.735 94.0234L348.036 104.206C346.553 110.624 344.206 116.054 340.994 120.498C337.781 124.818 333.952 128.088 329.504 130.31C325.056 132.408 320.176 133.457 314.864 133.457Z" fill="#E6E6E6"/>+<path d="M375.823 131.791V40.5194H396.578V65.1424L392.687 65.6978C393.304 60.3906 395.096 55.7622 398.061 51.8127C401.026 47.7397 404.609 44.5924 408.809 42.3708C413.133 40.0257 417.395 38.8532 421.596 38.8532C424.561 38.8532 427.403 39.2235 430.121 39.964C432.839 40.7046 435.68 41.9388 438.645 43.6667L428.638 62.1802C427.279 61.3162 425.488 60.6374 423.264 60.1437C421.164 59.5266 419.125 59.218 417.148 59.218C414.554 59.218 411.96 59.7117 409.365 60.6991C406.894 61.6865 404.67 63.2293 402.694 65.3275C400.717 67.3023 399.234 69.8942 398.246 73.1032C397.628 74.8311 397.134 77.1144 396.764 79.9532C396.517 82.6685 396.393 86.4946 396.393 91.4315V131.791H375.823Z" fill="#E6E6E6"/>+<path d="M492.002 133.457C487.06 133.457 482.365 132.47 477.918 130.495C473.594 128.52 469.825 125.496 466.613 121.423C463.401 117.227 460.992 111.796 459.386 105.132L464.76 106.427V131.791H444.375V2.75192H464.76V66.068H460.127C461.363 60.2672 463.463 55.3919 466.428 51.4424C469.517 47.3694 473.223 44.2838 477.547 42.1856C481.995 39.964 486.813 38.8532 492.002 38.8532C499.414 38.8532 506.086 40.7663 512.016 44.5924C518.069 48.2951 522.888 53.664 526.47 60.6991C530.053 67.7343 531.845 76.1887 531.845 86.0626C531.845 95.0725 530.177 103.157 526.841 110.315C523.629 117.474 519.058 123.151 513.128 127.348C507.198 131.421 500.156 133.457 492.002 133.457ZM486.998 114.573C491.816 114.573 496.017 113.401 499.6 111.056C503.306 108.711 506.147 105.378 508.124 101.059C510.101 96.7387 511.089 91.7401 511.089 86.0626C511.089 80.3851 510.101 75.3865 508.124 71.0667C506.147 66.7469 503.306 63.4144 499.6 61.0694C496.017 58.7244 491.816 57.5518 486.998 57.5518C482.18 57.5518 477.918 58.7861 474.211 61.2545C470.629 63.5996 467.849 66.932 465.872 71.2518C463.895 75.4482 462.907 80.3851 462.907 86.0626C462.907 91.7401 463.895 96.7387 465.872 101.059C467.849 105.378 470.629 108.711 474.211 111.056C477.918 113.401 482.18 114.573 486.998 114.573Z" fill="#E6E6E6"/>+<path d="M583.567 133.457C574.919 133.457 567.135 131.421 560.217 127.348C553.298 123.275 547.862 117.659 543.909 110.5C540.079 103.342 538.164 95.1959 538.164 86.0626C538.164 76.9293 540.079 68.7834 543.909 61.6248C547.862 54.4663 553.237 48.9122 560.032 44.9627C566.95 40.8897 574.795 38.8532 583.567 38.8532C592.462 38.8532 600.245 40.8897 606.917 44.9627C613.711 48.9122 619.086 54.4663 623.039 61.6248C626.992 68.7834 628.969 76.9293 628.969 86.0626C628.969 95.1959 626.992 103.342 623.039 110.5C619.209 117.659 613.835 123.275 606.917 127.348C600.122 131.421 592.338 133.457 583.567 133.457ZM583.752 115.314C588.817 115.314 593.203 114.141 596.909 111.796C600.616 109.451 603.457 106.057 605.434 101.614C607.411 97.1707 608.399 91.9869 608.399 86.0626C608.399 80.0149 607.411 74.8311 605.434 70.5113C603.457 66.068 600.616 62.6739 596.909 60.3289C593.203 57.9838 588.817 56.8113 583.752 56.8113C578.44 56.8113 573.93 58.0455 570.224 60.514C566.518 62.859 563.676 66.1915 561.699 70.5113C559.723 74.8311 558.734 80.0149 558.734 86.0626C558.734 91.9869 559.723 97.1707 561.699 101.614C563.676 106.057 566.518 109.451 570.224 111.796C573.93 114.141 578.44 115.314 583.752 115.314Z" fill="#E6E6E6"/>+<path d="M639.573 131.791V40.5194H660.143V60.6991L656.437 61.6248C658.043 56.3176 660.39 51.9978 663.479 48.6654C666.567 45.3329 670.15 42.8645 674.227 41.26C678.427 39.6555 682.813 38.8532 687.384 38.8532C697.639 38.8532 705.607 41.8154 711.29 47.7397C717.097 53.5406 720 61.8716 720 72.7329V131.791H699.43V80.3234C699.43 72.1775 697.947 66.1915 694.982 62.3653C692.017 58.5392 687.446 56.6262 681.269 56.6262C676.698 56.6262 672.806 57.737 669.594 59.9586C666.505 62.0568 664.158 65.3892 662.552 69.9559C660.946 74.5225 660.143 80.3234 660.143 87.3585V131.791H639.573Z" fill="#E6E6E6"/>+</svg>diff --git a/carbon-word-light.svg b/carbon-word-light.svgnew file mode 100644index 0000000000..3fd85675c9--- /dev/null+++ b/carbon-word-light.svg@@ -0,0 +1,9 @@+<svg width="720" height="175" viewBox="0 0 720 175" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M64.2993 3.57443C72.343 -1.19144 82.3494 -1.19151 90.3931 3.57443L142.163 34.2484C149.93 38.8505 154.692 47.2038 154.692 56.2254V118.775C154.692 127.796 149.93 136.149 142.163 140.752L90.3931 171.426C82.3494 176.192 72.343 176.191 64.2993 171.426L12.5296 140.752C4.76242 136.149 0 127.796 0 118.775V56.2254C0 47.2037 4.76242 38.8505 12.5296 34.2484L64.2993 3.57443ZM81.004 40.286C78.8708 39.0012 76.2016 38.9983 74.0657 40.2786L42.6851 59.0884C38.3192 61.7055 38.3303 68.0312 42.7057 70.6326L74.173 89.3408C74.3089 89.4216 74.3921 89.5681 74.3921 89.726V126.818C74.3922 132.04 80.0912 135.269 84.5774 132.589L115.594 114.057C117.626 112.843 118.87 110.652 118.87 108.287V66.8923C118.87 64.5357 117.635 62.3509 115.615 61.134L81.004 40.286Z" fill="#101A24"/>+<path d="M236.385 133.457C229.22 133.457 222.857 132.223 217.298 129.754C211.862 127.163 207.291 123.645 203.584 119.202C200.002 114.635 197.284 109.513 195.431 103.836C193.577 98.1581 192.651 92.2338 192.651 86.0626C192.651 79.8914 193.577 73.9671 195.431 68.2897C197.284 62.6122 200.002 57.5518 203.584 53.1086C207.291 48.6654 211.862 45.2095 217.298 42.741C222.857 40.1492 229.22 38.8532 236.385 38.8532C245.404 38.8532 253.249 41.0131 259.921 45.3329C266.716 49.6528 271.719 56.3176 274.931 65.3275L256.77 72.3626C255.288 67.6725 252.879 63.9081 249.543 61.0694C246.207 58.1072 241.821 56.6262 236.385 56.6262C230.95 56.6262 226.502 58.0455 223.043 60.8843C219.707 63.723 217.236 67.364 215.63 71.8072C214.024 76.2505 213.221 81.0023 213.221 86.0626C213.221 91.123 214.024 95.9365 215.63 100.503C217.236 104.946 219.707 108.587 223.043 111.426C226.502 114.141 230.95 115.499 236.385 115.499C241.821 115.499 246.207 114.08 249.543 111.241C252.879 108.402 255.288 104.638 256.77 99.9477L274.931 106.983C271.719 115.869 266.716 122.534 259.921 126.977C253.249 131.297 245.404 133.457 236.385 133.457Z" fill="#101A24"/>+<path d="M343.217 131.791L341.735 116.425V74.214C341.735 68.2897 339.943 63.8464 336.361 60.8843C332.778 57.7987 327.774 56.2559 321.35 56.2559C316.408 56.2559 311.528 57.2433 306.71 59.218C302.015 61.0694 297.691 63.9698 293.738 67.9194L282.248 54.4045C288.178 48.8505 294.479 44.901 301.151 42.5559C307.822 40.0874 315.111 38.8532 323.018 38.8532C335.372 38.8532 344.947 42.0005 351.742 48.2951C358.66 54.4663 362.12 63.1059 362.12 74.214V131.791H343.217ZM314.864 133.457C308.069 133.457 302.015 132.223 296.703 129.754C291.514 127.286 287.437 123.83 284.472 119.387C281.631 114.944 280.21 109.76 280.21 103.836C280.21 98.7752 281.26 94.3937 283.36 90.691C285.584 86.9883 288.426 84.0878 291.885 81.9896C294.85 80.1383 298.309 78.8423 302.262 78.1018C306.216 77.2378 310.355 76.8059 314.679 76.8059H343.403V92.1721H317.644C315.42 92.1721 313.196 92.4189 310.972 92.9126C308.749 93.2829 306.772 94.0234 305.042 95.1342C303.807 96.1216 302.757 97.3558 301.892 98.8369C301.151 100.318 300.78 102.046 300.78 104.021C300.78 107.97 302.262 111.118 305.228 113.463C308.316 115.684 312.393 116.795 317.458 116.795C321.906 116.795 325.921 115.808 329.504 113.833C333.21 111.858 336.175 109.143 338.399 105.687C340.623 102.231 341.735 98.3432 341.735 94.0234L348.036 104.206C346.553 110.624 344.206 116.054 340.994 120.498C337.781 124.818 333.952 128.088 329.504 130.31C325.056 132.408 320.176 133.457 314.864 133.457Z" fill="#101A24"/>+<path d="M375.823 131.791V40.5194H396.578V65.1424L392.687 65.6978C393.304 60.3906 395.096 55.7622 398.061 51.8127C401.026 47.7397 404.609 44.5924 408.809 42.3708C413.133 40.0257 417.395 38.8532 421.596 38.8532C424.561 38.8532 427.403 39.2235 430.121 39.964C432.839 40.7046 435.68 41.9388 438.645 43.6667L428.638 62.1802C427.279 61.3162 425.488 60.6374 423.264 60.1437C421.164 59.5266 419.125 59.218 417.148 59.218C414.554 59.218 411.96 59.7117 409.365 60.6991C406.894 61.6865 404.67 63.2293 402.694 65.3275C400.717 67.3023 399.234 69.8942 398.246 73.1032C397.628 74.8311 397.134 77.1144 396.764 79.9532C396.517 82.6685 396.393 86.4946 396.393 91.4315V131.791H375.823Z" fill="#101A24"/>+<path d="M492.002 133.457C487.06 133.457 482.365 132.47 477.918 130.495C473.594 128.52 469.825 125.496 466.613 121.423C463.401 117.227 460.992 111.796 459.386 105.132L464.76 106.427V131.791H444.375V2.75192H464.76V66.068H460.127C461.363 60.2672 463.463 55.3919 466.428 51.4424C469.517 47.3694 473.223 44.2838 477.547 42.1856C481.995 39.964 486.813 38.8532 492.002 38.8532C499.414 38.8532 506.086 40.7663 512.016 44.5924C518.069 48.2951 522.888 53.664 526.47 60.6991C530.053 67.7343 531.845 76.1887 531.845 86.0626C531.845 95.0725 530.177 103.157 526.841 110.315C523.629 117.474 519.058 123.151 513.128 127.348C507.198 131.421 500.156 133.457 492.002 133.457ZM486.998 114.573C491.816 114.573 496.017 113.401 499.6 111.056C503.306 108.711 506.147 105.378 508.124 101.059C510.101 96.7387 511.089 91.7401 511.089 86.0626C511.089 80.3851 510.101 75.3865 508.124 71.0667C506.147 66.7469 503.306 63.4144 499.6 61.0694C496.017 58.7244 491.816 57.5518 486.998 57.5518C482.18 57.5518 477.918 58.7861 474.211 61.2545C470.629 63.5996 467.849 66.932 465.872 71.2518C463.895 75.4482 462.907 80.3851 462.907 86.0626C462.907 91.7401 463.895 96.7387 465.872 101.059C467.849 105.378 470.629 108.711 474.211 111.056C477.918 113.401 482.18 114.573 486.998 114.573Z" fill="#101A24"/>+<path d="M583.567 133.457C574.919 133.457 567.135 131.421 560.217 127.348C553.298 123.275 547.862 117.659 543.909 110.5C540.079 103.342 538.164 95.1959 538.164 86.0626C538.164 76.9293 540.079 68.7834 543.909 61.6248C547.862 54.4663 553.237 48.9122 560.032 44.9627C566.95 40.8897 574.795 38.8532 583.567 38.8532C592.462 38.8532 600.245 40.8897 606.917 44.9627C613.711 48.9122 619.086 54.4663 623.039 61.6248C626.992 68.7834 628.969 76.9293 628.969 86.0626C628.969 95.1959 626.992 103.342 623.039 110.5C619.209 117.659 613.835 123.275 606.917 127.348C600.122 131.421 592.338 133.457 583.567 133.457ZM583.752 115.314C588.817 115.314 593.203 114.141 596.909 111.796C600.616 109.451 603.457 106.057 605.434 101.614C607.411 97.1707 608.399 91.9869 608.399 86.0626C608.399 80.0149 607.411 74.8311 605.434 70.5113C603.457 66.068 600.616 62.6739 596.909 60.3289C593.203 57.9838 588.817 56.8113 583.752 56.8113C578.44 56.8113 573.93 58.0455 570.224 60.514C566.518 62.859 563.676 66.1915 561.699 70.5113C559.723 74.8311 558.734 80.0149 558.734 86.0626C558.734 91.9869 559.723 97.1707 561.699 101.614C563.676 106.057 566.518 109.451 570.224 111.796C573.93 114.141 578.44 115.314 583.752 115.314Z" fill="#101A24"/>+<path d="M639.573 131.791V40.5194H660.143V60.6991L656.437 61.6248C658.043 56.3176 660.39 51.9978 663.479 48.6654C666.567 45.3329 670.15 42.8645 674.227 41.26C678.427 39.6555 682.813 38.8532 687.384 38.8532C697.639 38.8532 705.607 41.8154 711.29 47.7397C717.097 53.5406 720 61.8716 720 72.7329V131.791H699.43V80.3234C699.43 72.1775 697.947 66.1915 694.982 62.3653C692.017 58.5392 687.446 56.6262 681.269 56.6262C676.698 56.6262 672.806 57.737 669.594 59.9586C666.505 62.0568 664.158 65.3892 662.552 69.9559C660.946 74.5225 660.143 80.3234 660.143 87.3585V131.791H639.573Z" fill="#101A24"/>+</svg>diff --git a/examples/quote-configurator/app/root.tsx b/examples/quote-configurator/app/root.tsxindex 52199b19ee..9e138d2a7d 100644--- a/examples/quote-configurator/app/root.tsx+++ b/examples/quote-configurator/app/root.tsx@@ -82,10 +82,15 @@ export function ErrorBoundary() {<div className="light"><div className="flex flex-col w-full h-screen items-center justify-center space-y-4 "><img- src="/carbon-logo-mark.svg"+ src="/carbon-mark-light.svg"alt="Carbon Logo"className="block max-w-[60px]"/>+ <img+ src="/carbon-mark-dark.svg"+ alt="Carbon Logo"+ className="max-w-[60px] hidden dark:block"+ /><h1 className="text-2xl font-bold">Something went wrong</h1><p className="text-muted-foreground max-w-2xl">{message}</p></div>diff --git a/examples/quote-configurator/public/android-chrome-192x192.png b/examples/quote-configurator/public/android-chrome-192x192.pngnew file mode 100644index 0000000000..bc936a17b0Binary files /dev/null and b/examples/quote-configurator/public/android-chrome-192x192.png differdiff --git a/examples/quote-configurator/public/android-chrome-512x512.png b/examples/quote-configurator/public/android-chrome-512x512.pngnew file mode 100644index 0000000000..841366bbf7Binary files /dev/null and b/examples/quote-configurator/public/android-chrome-512x512.png differdiff --git a/examples/quote-configurator/public/apple-touch-icon.png b/examples/quote-configurator/public/apple-touch-icon.pngindex 7d10fd7748..aadf41c525 100644Binary files a/examples/quote-configurator/public/apple-touch-icon.png and b/examples/quote-configurator/public/apple-touch-icon.png differdiff --git a/examples/quote-configurator/public/carbon-logo-mark.svg b/examples/quote-configurator/public/carbon-logo-mark.svgdeleted file mode 100644index 048049e1e5..0000000000--- a/examples/quote-configurator/public/carbon-logo-mark.svg+++ /dev/null@@ -1,20 +0,0 @@-<svg width="362" height="349" viewBox="0 0 362 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M181.165 139.643V69.8213L241.346 35.0564L241.054 104.878L181.165 139.643Z" fill="#60FFD2"/>-<path d="M181.165 69.8213V139.643L120.4 104.878V35.0564L181.165 69.8213Z" fill="#36B5B4"/>-<path d="M120.4 35.0565L181.165 69.8214L241.347 35.0565L181.165 -0.000610352L120.4 35.0565Z" fill="#5FE4D2"/>-<path d="M240.818 244.172V174.35L300.999 139.585L300.707 209.407L240.818 244.172Z" fill="#71DEFF"/>-<path d="M240.818 174.35V244.172L180.052 209.407V139.585L240.818 174.35Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.35L300.999 139.586L240.818 104.528L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.172V174.35L181.693 139.585L181.401 209.407L121.512 244.172Z" fill="#71DEFF"/>-<path d="M121.512 174.35V244.172L60.7466 209.407V139.585L121.512 174.35Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.35L181.694 139.586L121.512 104.528L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.701V278.879L241.346 244.114L241.054 313.936L181.165 348.701Z" fill="#7D7FE5"/>-<path d="M181.165 278.879V348.701L120.4 313.936V244.114L181.165 278.879Z" fill="#2F31AE"/>-<path d="M120.4 244.114L181.165 278.879L241.347 244.114L181.165 209.057L120.4 244.114Z" fill="#6041D0"/>-<path d="M60.7651 348.701V278.879L120.946 244.114L120.654 313.936L60.7651 348.701Z" fill="#7D7FE5"/>-<path d="M60.7656 278.879V348.701L0 313.936V244.114L60.7656 278.879Z" fill="#2F31AE"/>-<path d="M0 244.114L60.7656 278.879L120.947 244.114L60.7656 209.057L0 244.114Z" fill="#6041D0"/>-<path d="M301.017 348.701V278.879L361.198 244.114L360.906 313.936L301.017 348.701Z" fill="#7D7FE5"/>-<path d="M301.018 278.879V348.701L240.252 313.936V244.114L301.018 278.879Z" fill="#2F31AE"/>-<path d="M240.252 244.114L301.018 278.879L361.199 244.114L301.018 209.057L240.252 244.114Z" fill="#6041D0"/>-</svg>diff --git a/examples/quote-configurator/public/carbon-mark-dark.svg b/examples/quote-configurator/public/carbon-mark-dark.svgnew file mode 100644index 0000000000..047b926154--- /dev/null+++ b/examples/quote-configurator/public/carbon-mark-dark.svg@@ -0,0 +1,3 @@+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#E6E6E6"/>+</svg>diff --git a/examples/quote-configurator/public/carbon-mark-light.svg b/examples/quote-configurator/public/carbon-mark-light.svgnew file mode 100644index 0000000000..db0480c53c--- /dev/null+++ b/examples/quote-configurator/public/carbon-mark-light.svg@@ -0,0 +1,3 @@+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#101A24"/>+</svg>diff --git a/examples/quote-configurator/public/carbon-word-dark.png b/examples/quote-configurator/public/carbon-word-dark.pngdeleted file mode 100644index 3606059a75..0000000000Binary files a/examples/quote-configurator/public/carbon-word-dark.png and /dev/null differdiff --git a/examples/quote-configurator/public/carbon-word-dark.svg b/examples/quote-configurator/public/carbon-word-dark.svgindex b555c4b360..c4463b4061 100644--- a/examples/quote-configurator/public/carbon-word-dark.svg+++ b/examples/quote-configurator/public/carbon-word-dark.svg@@ -1,26 +1,9 @@-<svg width="1307" height="349" viewBox="0 0 1307 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M412.646 193.426C412.646 178.405 415.703 165.305 421.816 154.126C427.929 142.773 436.401 134.039 447.23 127.926C458.059 121.638 470.461 118.494 484.434 118.494C502.425 118.494 517.271 123.035 528.974 132.118C540.851 141.026 548.799 153.602 552.816 169.846H513.254C511.158 163.558 507.577 158.667 502.512 155.174C497.621 151.506 491.508 149.672 484.172 149.672C473.692 149.672 465.395 153.515 459.282 161.2C453.169 168.711 450.112 179.453 450.112 193.426C450.112 207.225 453.169 217.967 459.282 225.652C465.395 233.163 473.692 236.918 484.172 236.918C499.019 236.918 508.713 230.281 513.254 217.006H552.816C548.799 232.726 540.851 245.215 528.974 254.472C517.097 263.729 502.25 268.358 484.434 268.358C470.461 268.358 458.059 265.301 447.23 259.188C436.401 252.9 427.929 244.167 421.816 232.988C415.703 221.635 412.646 208.447 412.646 193.426Z" fill="white"/>-<path d="M562.395 192.902C562.395 178.23 565.277 165.217 571.041 153.864C576.98 142.511 584.927 133.777 594.883 127.664C605.014 121.551 616.28 118.494 628.681 118.494C639.511 118.494 648.943 120.677 656.977 125.044C665.187 129.411 671.737 134.913 676.627 141.55V120.852H713.569V266H676.627V244.778C671.911 251.59 665.361 257.267 656.977 261.808C648.768 266.175 639.249 268.358 628.419 268.358C616.193 268.358 605.014 265.214 594.883 258.926C584.927 252.638 576.98 243.817 571.041 232.464C565.277 220.936 562.395 207.749 562.395 192.902ZM676.627 193.426C676.627 184.518 674.881 176.92 671.387 170.632C667.894 164.169 663.178 159.279 657.239 155.96C651.301 152.467 644.925 150.72 638.113 150.72C631.301 150.72 625.013 152.379 619.249 155.698C613.485 159.017 608.769 163.907 605.101 170.37C601.608 176.658 599.861 184.169 599.861 192.902C599.861 201.635 601.608 209.321 605.101 215.958C608.769 222.421 613.485 227.399 619.249 230.892C625.188 234.385 631.476 236.132 638.113 236.132C644.925 236.132 651.301 234.473 657.239 231.154C663.178 227.661 667.894 222.77 671.387 216.482C674.881 210.019 676.627 202.334 676.627 193.426Z" fill="white"/>-<path d="M778.214 143.384C782.93 135.699 789.043 129.673 796.554 125.306C804.239 120.939 812.972 118.756 822.754 118.756V157.27H813.06C801.532 157.27 792.798 159.977 786.86 165.392C781.096 170.807 778.214 180.239 778.214 193.688V266H741.534V120.852H778.214V143.384Z" fill="white"/>-<path d="M876.28 142.074C880.996 135.087 887.458 129.411 895.668 125.044C904.052 120.677 913.571 118.494 924.226 118.494C936.627 118.494 947.806 121.551 957.762 127.664C967.892 133.777 975.84 142.511 981.604 153.864C987.542 165.043 990.512 178.055 990.512 192.902C990.512 207.749 987.542 220.936 981.604 232.464C975.84 243.817 967.892 252.638 957.762 258.926C947.806 265.214 936.627 268.358 924.226 268.358C913.396 268.358 903.877 266.262 895.668 262.07C887.633 257.703 881.17 252.114 876.28 245.302V266H839.6V72.12H876.28V142.074ZM953.046 192.902C953.046 184.169 951.212 176.658 947.544 170.37C944.05 163.907 939.334 159.017 933.396 155.698C927.632 152.379 921.344 150.72 914.532 150.72C907.894 150.72 901.606 152.467 895.668 155.96C889.904 159.279 885.188 164.169 881.52 170.632C878.026 177.095 876.28 184.693 876.28 193.426C876.28 202.159 878.026 209.757 881.52 216.22C885.188 222.683 889.904 227.661 895.668 231.154C901.606 234.473 907.894 236.132 914.532 236.132C921.344 236.132 927.632 234.385 933.396 230.892C939.334 227.399 944.05 222.421 947.544 215.958C951.212 209.495 953.046 201.81 953.046 192.902Z" fill="white"/>-<path d="M1073.76 268.358C1059.78 268.358 1047.21 265.301 1036.03 259.188C1024.85 252.9 1016.03 244.079 1009.57 232.726C1003.28 221.373 1000.14 208.273 1000.14 193.426C1000.14 178.579 1003.37 165.479 1009.83 154.126C1016.47 142.773 1025.46 134.039 1036.82 127.926C1048.17 121.638 1060.83 118.494 1074.81 118.494C1088.78 118.494 1101.44 121.638 1112.8 127.926C1124.15 134.039 1133.06 142.773 1139.52 154.126C1146.16 165.479 1149.48 178.579 1149.48 193.426C1149.48 208.273 1146.07 221.373 1139.26 232.726C1132.62 244.079 1123.54 252.9 1112.01 259.188C1100.66 265.301 1087.91 268.358 1073.76 268.358ZM1073.76 236.394C1080.4 236.394 1086.6 234.822 1092.36 231.678C1098.3 228.359 1103.01 223.469 1106.51 217.006C1110 210.543 1111.75 202.683 1111.75 193.426C1111.75 179.627 1108.08 169.06 1100.74 161.724C1093.58 154.213 1084.76 150.458 1074.28 150.458C1063.8 150.458 1054.98 154.213 1047.82 161.724C1040.83 169.06 1037.34 179.627 1037.34 193.426C1037.34 207.225 1040.75 217.879 1047.56 225.39C1054.54 232.726 1063.28 236.394 1073.76 236.394Z" fill="white"/>-<path d="M1248.96 118.756C1266.25 118.756 1280.22 124.258 1290.88 135.262C1301.53 146.091 1306.86 161.287 1306.86 180.85V266H1270.18V185.828C1270.18 174.3 1267.3 165.479 1261.53 159.366C1255.77 153.078 1247.91 149.934 1237.95 149.934C1227.82 149.934 1219.79 153.078 1213.85 159.366C1208.08 165.479 1205.2 174.3 1205.2 185.828V266H1168.52V120.852H1205.2V138.93C1210.09 132.642 1216.29 127.751 1223.8 124.258C1231.49 120.59 1239.87 118.756 1248.96 118.756Z" fill="white"/>-<path d="M181.165 139.644V69.822L241.346 35.0571L241.054 104.879L181.165 139.644Z" fill="#60FFD2"/>-<path d="M181.165 69.822V139.644L120.4 104.879V35.0571L181.165 69.822Z" fill="#36B5B4"/>-<path d="M120.4 35.0571L181.165 69.822L241.346 35.0571L181.165 0L120.4 35.0571Z" fill="#5FE4D2"/>-<path d="M240.818 244.173V174.351L300.999 139.586L300.707 209.408L240.818 244.173Z" fill="#71DEFF"/>-<path d="M240.818 174.351V244.173L180.052 209.408V139.586L240.818 174.351Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.351L300.999 139.586L240.818 104.529L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.173V174.351L181.693 139.586L181.401 209.408L121.512 244.173Z" fill="#71DEFF"/>-<path d="M121.512 174.351V244.173L60.7466 209.408V139.586L121.512 174.351Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.351L181.693 139.586L121.512 104.529L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.702V278.88L241.346 244.115L241.054 313.937L181.165 348.702Z" fill="#7D7FE5"/>-<path d="M181.165 278.88V348.702L120.4 313.937V244.115L181.165 278.88Z" fill="#2F31AE"/>-<path d="M120.4 244.115L181.165 278.88L241.346 244.115L181.165 209.057L120.4 244.115Z" fill="#6041D0"/>-<path d="M60.7652 348.702V278.88L120.947 244.115L120.654 313.937L60.7652 348.702Z" fill="#7D7FE5"/>-<path d="M60.7652 278.88V348.702L0 313.937V244.115L60.7652 278.88Z" fill="#2F31AE"/>-<path d="M0 244.115L60.7652 278.88L120.947 244.115L60.7656 209.057L0 244.115Z" fill="#6041D0"/>-<path d="M301.017 348.702V278.88L361.198 244.115L360.906 313.937L301.017 348.702Z" fill="#7D7FE5"/>-<path d="M301.017 278.88V348.702L240.252 313.937V244.115L301.017 278.88Z" fill="#2F31AE"/>-<path d="M240.252 244.115L301.017 278.88L361.198 244.115L301.018 209.057L240.252 244.115Z" fill="#6041D0"/>+<svg width="720" height="175" viewBox="0 0 720 175" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M64.2993 3.57443C72.343 -1.19144 82.3494 -1.19151 90.3931 3.57443L142.163 34.2484C149.93 38.8505 154.692 47.2038 154.692 56.2254V118.775C154.692 127.796 149.93 136.149 142.163 140.752L90.3931 171.426C82.3494 176.192 72.343 176.191 64.2993 171.426L12.5296 140.752C4.76242 136.149 0 127.796 0 118.775V56.2254C0 47.2037 4.76242 38.8505 12.5296 34.2484L64.2993 3.57443ZM81.004 40.286C78.8708 39.0012 76.2016 38.9983 74.0657 40.2786L42.6851 59.0884C38.3192 61.7055 38.3303 68.0312 42.7057 70.6326L74.173 89.3408C74.3089 89.4216 74.3921 89.5681 74.3921 89.726V126.818C74.3922 132.04 80.0912 135.269 84.5774 132.589L115.594 114.057C117.626 112.843 118.87 110.652 118.87 108.287V66.8923C118.87 64.5357 117.635 62.3509 115.615 61.134L81.004 40.286Z" fill="#E6E6E6"/>+<path d="M236.385 133.457C229.22 133.457 222.857 132.223 217.298 129.754C211.862 127.163 207.291 123.645 203.584 119.202C200.002 114.635 197.284 109.513 195.431 103.836C193.577 98.1581 192.651 92.2338 192.651 86.0626C192.651 79.8914 193.577 73.9671 195.431 68.2897C197.284 62.6122 200.002 57.5518 203.584 53.1086C207.291 48.6654 211.862 45.2095 217.298 42.741C222.857 40.1492 229.22 38.8532 236.385 38.8532C245.404 38.8532 253.249 41.0131 259.921 45.3329C266.716 49.6528 271.719 56.3176 274.931 65.3275L256.77 72.3626C255.288 67.6725 252.879 63.9081 249.543 61.0694C246.207 58.1072 241.821 56.6262 236.385 56.6262C230.95 56.6262 226.502 58.0455 223.043 60.8843C219.707 63.723 217.236 67.364 215.63 71.8072C214.024 76.2505 213.221 81.0023 213.221 86.0626C213.221 91.123 214.024 95.9365 215.63 100.503C217.236 104.946 219.707 108.587 223.043 111.426C226.502 114.141 230.95 115.499 236.385 115.499C241.821 115.499 246.207 114.08 249.543 111.241C252.879 108.402 255.288 104.638 256.77 99.9477L274.931 106.983C271.719 115.869 266.716 122.534 259.921 126.977C253.249 131.297 245.404 133.457 236.385 133.457Z" fill="#E6E6E6"/>+<path d="M343.217 131.791L341.735 116.425V74.214C341.735 68.2897 339.943 63.8464 336.361 60.8843C332.778 57.7987 327.774 56.2559 321.35 56.2559C316.408 56.2559 311.528 57.2433 306.71 59.218C302.015 61.0694 297.691 63.9698 293.738 67.9194L282.248 54.4045C288.178 48.8505 294.479 44.901 301.151 42.5559C307.822 40.0874 315.111 38.8532 323.018 38.8532C335.372 38.8532 344.947 42.0005 351.742 48.2951C358.66 54.4663 362.12 63.1059 362.12 74.214V131.791H343.217ZM314.864 133.457C308.069 133.457 302.015 132.223 296.703 129.754C291.514 127.286 287.437 123.83 284.472 119.387C281.631 114.944 280.21 109.76 280.21 103.836C280.21 98.7752 281.26 94.3937 283.36 90.691C285.584 86.9883 288.426 84.0878 291.885 81.9896C294.85 80.1383 298.309 78.8423 302.262 78.1018C306.216 77.2378 310.355 76.8059 314.679 76.8059H343.403V92.1721H317.644C315.42 92.1721 313.196 92.4189 310.972 92.9126C308.749 93.2829 306.772 94.0234 305.042 95.1342C303.807 96.1216 302.757 97.3558 301.892 98.8369C301.151 100.318 300.78 102.046 300.78 104.021C300.78 107.97 302.262 111.118 305.228 113.463C308.316 115.684 312.393 116.795 317.458 116.795C321.906 116.795 325.921 115.808 329.504 113.833C333.21 111.858 336.175 109.143 338.399 105.687C340.623 102.231 341.735 98.3432 341.735 94.0234L348.036 104.206C346.553 110.624 344.206 116.054 340.994 120.498C337.781 124.818 333.952 128.088 329.504 130.31C325.056 132.408 320.176 133.457 314.864 133.457Z" fill="#E6E6E6"/>+<path d="M375.823 131.791V40.5194H396.578V65.1424L392.687 65.6978C393.304 60.3906 395.096 55.7622 398.061 51.8127C401.026 47.7397 404.609 44.5924 408.809 42.3708C413.133 40.0257 417.395 38.8532 421.596 38.8532C424.561 38.8532 427.403 39.2235 430.121 39.964C432.839 40.7046 435.68 41.9388 438.645 43.6667L428.638 62.1802C427.279 61.3162 425.488 60.6374 423.264 60.1437C421.164 59.5266 419.125 59.218 417.148 59.218C414.554 59.218 411.96 59.7117 409.365 60.6991C406.894 61.6865 404.67 63.2293 402.694 65.3275C400.717 67.3023 399.234 69.8942 398.246 73.1032C397.628 74.8311 397.134 77.1144 396.764 79.9532C396.517 82.6685 396.393 86.4946 396.393 91.4315V131.791H375.823Z" fill="#E6E6E6"/>+<path d="M492.002 133.457C487.06 133.457 482.365 132.47 477.918 130.495C473.594 128.52 469.825 125.496 466.613 121.423C463.401 117.227 460.992 111.796 459.386 105.132L464.76 106.427V131.791H444.375V2.75192H464.76V66.068H460.127C461.363 60.2672 463.463 55.3919 466.428 51.4424C469.517 47.3694 473.223 44.2838 477.547 42.1856C481.995 39.964 486.813 38.8532 492.002 38.8532C499.414 38.8532 506.086 40.7663 512.016 44.5924C518.069 48.2951 522.888 53.664 526.47 60.6991C530.053 67.7343 531.845 76.1887 531.845 86.0626C531.845 95.0725 530.177 103.157 526.841 110.315C523.629 117.474 519.058 123.151 513.128 127.348C507.198 131.421 500.156 133.457 492.002 133.457ZM486.998 114.573C491.816 114.573 496.017 113.401 499.6 111.056C503.306 108.711 506.147 105.378 508.124 101.059C510.101 96.7387 511.089 91.7401 511.089 86.0626C511.089 80.3851 510.101 75.3865 508.124 71.0667C506.147 66.7469 503.306 63.4144 499.6 61.0694C496.017 58.7244 491.816 57.5518 486.998 57.5518C482.18 57.5518 477.918 58.7861 474.211 61.2545C470.629 63.5996 467.849 66.932 465.872 71.2518C463.895 75.4482 462.907 80.3851 462.907 86.0626C462.907 91.7401 463.895 96.7387 465.872 101.059C467.849 105.378 470.629 108.711 474.211 111.056C477.918 113.401 482.18 114.573 486.998 114.573Z" fill="#E6E6E6"/>+<path d="M583.567 133.457C574.919 133.457 567.135 131.421 560.217 127.348C553.298 123.275 547.862 117.659 543.909 110.5C540.079 103.342 538.164 95.1959 538.164 86.0626C538.164 76.9293 540.079 68.7834 543.909 61.6248C547.862 54.4663 553.237 48.9122 560.032 44.9627C566.95 40.8897 574.795 38.8532 583.567 38.8532C592.462 38.8532 600.245 40.8897 606.917 44.9627C613.711 48.9122 619.086 54.4663 623.039 61.6248C626.992 68.7834 628.969 76.9293 628.969 86.0626C628.969 95.1959 626.992 103.342 623.039 110.5C619.209 117.659 613.835 123.275 606.917 127.348C600.122 131.421 592.338 133.457 583.567 133.457ZM583.752 115.314C588.817 115.314 593.203 114.141 596.909 111.796C600.616 109.451 603.457 106.057 605.434 101.614C607.411 97.1707 608.399 91.9869 608.399 86.0626C608.399 80.0149 607.411 74.8311 605.434 70.5113C603.457 66.068 600.616 62.6739 596.909 60.3289C593.203 57.9838 588.817 56.8113 583.752 56.8113C578.44 56.8113 573.93 58.0455 570.224 60.514C566.518 62.859 563.676 66.1915 561.699 70.5113C559.723 74.8311 558.734 80.0149 558.734 86.0626C558.734 91.9869 559.723 97.1707 561.699 101.614C563.676 106.057 566.518 109.451 570.224 111.796C573.93 114.141 578.44 115.314 583.752 115.314Z" fill="#E6E6E6"/>+<path d="M639.573 131.791V40.5194H660.143V60.6991L656.437 61.6248C658.043 56.3176 660.39 51.9978 663.479 48.6654C666.567 45.3329 670.15 42.8645 674.227 41.26C678.427 39.6555 682.813 38.8532 687.384 38.8532C697.639 38.8532 705.607 41.8154 711.29 47.7397C717.097 53.5406 720 61.8716 720 72.7329V131.791H699.43V80.3234C699.43 72.1775 697.947 66.1915 694.982 62.3653C692.017 58.5392 687.446 56.6262 681.269 56.6262C676.698 56.6262 672.806 57.737 669.594 59.9586C666.505 62.0568 664.158 65.3892 662.552 69.9559C660.946 74.5225 660.143 80.3234 660.143 87.3585V131.791H639.573Z" fill="#E6E6E6"/></svg>diff --git a/examples/quote-configurator/public/carbon-word-light.png b/examples/quote-configurator/public/carbon-word-light.pngdeleted file mode 100644index becd8f13bb..0000000000Binary files a/examples/quote-configurator/public/carbon-word-light.png and /dev/null differdiff --git a/examples/quote-configurator/public/carbon-word-light.svg b/examples/quote-configurator/public/carbon-word-light.svgindex 3e899a2d1b..3fd85675c9 100644--- a/examples/quote-configurator/public/carbon-word-light.svg+++ b/examples/quote-configurator/public/carbon-word-light.svg@@ -1,26 +1,9 @@-<svg width="1307" height="349" viewBox="0 0 1307 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M412.646 193.426C412.646 178.405 415.703 165.305 421.816 154.126C427.929 142.773 436.401 134.039 447.23 127.926C458.059 121.638 470.461 118.494 484.434 118.494C502.425 118.494 517.271 123.035 528.974 132.118C540.851 141.026 548.799 153.602 552.816 169.846H513.254C511.158 163.558 507.577 158.667 502.512 155.174C497.621 151.506 491.508 149.672 484.172 149.672C473.692 149.672 465.395 153.515 459.282 161.2C453.169 168.711 450.112 179.453 450.112 193.426C450.112 207.225 453.169 217.967 459.282 225.652C465.395 233.163 473.692 236.918 484.172 236.918C499.019 236.918 508.713 230.281 513.254 217.006H552.816C548.799 232.726 540.851 245.215 528.974 254.472C517.097 263.729 502.25 268.358 484.434 268.358C470.461 268.358 458.059 265.301 447.23 259.188C436.401 252.9 427.929 244.167 421.816 232.988C415.703 221.635 412.646 208.447 412.646 193.426Z" fill="#212278"/>-<path d="M562.395 192.902C562.395 178.23 565.277 165.217 571.041 153.864C576.98 142.511 584.927 133.777 594.883 127.664C605.014 121.551 616.28 118.494 628.681 118.494C639.511 118.494 648.943 120.677 656.977 125.044C665.187 129.411 671.737 134.913 676.627 141.55V120.852H713.569V266H676.627V244.778C671.911 251.59 665.361 257.267 656.977 261.808C648.768 266.175 639.249 268.358 628.419 268.358C616.193 268.358 605.014 265.214 594.883 258.926C584.927 252.638 576.98 243.817 571.041 232.464C565.277 220.936 562.395 207.749 562.395 192.902ZM676.627 193.426C676.627 184.518 674.881 176.92 671.387 170.632C667.894 164.169 663.178 159.279 657.239 155.96C651.301 152.467 644.925 150.72 638.113 150.72C631.301 150.72 625.013 152.379 619.249 155.698C613.485 159.017 608.769 163.907 605.101 170.37C601.608 176.658 599.861 184.169 599.861 192.902C599.861 201.635 601.608 209.321 605.101 215.958C608.769 222.421 613.485 227.399 619.249 230.892C625.188 234.385 631.476 236.132 638.113 236.132C644.925 236.132 651.301 234.473 657.239 231.154C663.178 227.661 667.894 222.77 671.387 216.482C674.881 210.019 676.627 202.334 676.627 193.426Z" fill="#212278"/>-<path d="M778.214 143.384C782.93 135.699 789.043 129.673 796.554 125.306C804.239 120.939 812.972 118.756 822.754 118.756V157.27H813.06C801.532 157.27 792.798 159.977 786.86 165.392C781.096 170.807 778.214 180.239 778.214 193.688V266H741.534V120.852H778.214V143.384Z" fill="#212278"/>-<path d="M876.28 142.074C880.996 135.087 887.458 129.411 895.668 125.044C904.052 120.677 913.571 118.494 924.226 118.494C936.627 118.494 947.806 121.551 957.762 127.664C967.892 133.777 975.84 142.511 981.604 153.864C987.542 165.043 990.512 178.055 990.512 192.902C990.512 207.749 987.542 220.936 981.604 232.464C975.84 243.817 967.892 252.638 957.762 258.926C947.806 265.214 936.627 268.358 924.226 268.358C913.396 268.358 903.877 266.262 895.668 262.07C887.633 257.703 881.17 252.114 876.28 245.302V266H839.6V72.12H876.28V142.074ZM953.046 192.902C953.046 184.169 951.212 176.658 947.544 170.37C944.05 163.907 939.334 159.017 933.396 155.698C927.632 152.379 921.344 150.72 914.532 150.72C907.894 150.72 901.606 152.467 895.668 155.96C889.904 159.279 885.188 164.169 881.52 170.632C878.026 177.095 876.28 184.693 876.28 193.426C876.28 202.159 878.026 209.757 881.52 216.22C885.188 222.683 889.904 227.661 895.668 231.154C901.606 234.473 907.894 236.132 914.532 236.132C921.344 236.132 927.632 234.385 933.396 230.892C939.334 227.399 944.05 222.421 947.544 215.958C951.212 209.495 953.046 201.81 953.046 192.902Z" fill="#212278"/>-<path d="M1073.76 268.358C1059.78 268.358 1047.21 265.301 1036.03 259.188C1024.85 252.9 1016.03 244.079 1009.57 232.726C1003.28 221.373 1000.14 208.273 1000.14 193.426C1000.14 178.579 1003.37 165.479 1009.83 154.126C1016.47 142.773 1025.46 134.039 1036.82 127.926C1048.17 121.638 1060.83 118.494 1074.81 118.494C1088.78 118.494 1101.44 121.638 1112.8 127.926C1124.15 134.039 1133.06 142.773 1139.52 154.126C1146.16 165.479 1149.48 178.579 1149.48 193.426C1149.48 208.273 1146.07 221.373 1139.26 232.726C1132.62 244.079 1123.54 252.9 1112.01 259.188C1100.66 265.301 1087.91 268.358 1073.76 268.358ZM1073.76 236.394C1080.4 236.394 1086.6 234.822 1092.36 231.678C1098.3 228.359 1103.01 223.469 1106.51 217.006C1110 210.543 1111.75 202.683 1111.75 193.426C1111.75 179.627 1108.08 169.06 1100.74 161.724C1093.58 154.213 1084.76 150.458 1074.28 150.458C1063.8 150.458 1054.98 154.213 1047.82 161.724C1040.83 169.06 1037.34 179.627 1037.34 193.426C1037.34 207.225 1040.75 217.879 1047.56 225.39C1054.54 232.726 1063.28 236.394 1073.76 236.394Z" fill="#212278"/>-<path d="M1248.96 118.756C1266.25 118.756 1280.22 124.258 1290.88 135.262C1301.53 146.091 1306.86 161.287 1306.86 180.85V266H1270.18V185.828C1270.18 174.3 1267.3 165.479 1261.53 159.366C1255.77 153.078 1247.91 149.934 1237.95 149.934C1227.82 149.934 1219.79 153.078 1213.85 159.366C1208.08 165.479 1205.2 174.3 1205.2 185.828V266H1168.52V120.852H1205.2V138.93C1210.09 132.642 1216.29 127.751 1223.8 124.258C1231.49 120.59 1239.87 118.756 1248.96 118.756Z" fill="#212278"/>-<path d="M181.165 139.644V69.822L241.346 35.0571L241.054 104.879L181.165 139.644Z" fill="#60FFD2"/>-<path d="M181.165 69.822V139.644L120.4 104.879V35.0571L181.165 69.822Z" fill="#36B5B4"/>-<path d="M120.4 35.0571L181.165 69.822L241.346 35.0571L181.165 0L120.4 35.0571Z" fill="#5FE4D2"/>-<path d="M240.818 244.173V174.351L300.999 139.586L300.707 209.408L240.818 244.173Z" fill="#71DEFF"/>-<path d="M240.818 174.351V244.173L180.052 209.408V139.586L240.818 174.351Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.351L300.999 139.586L240.818 104.529L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.173V174.351L181.693 139.586L181.401 209.408L121.512 244.173Z" fill="#71DEFF"/>-<path d="M121.512 174.351V244.173L60.7466 209.408V139.586L121.512 174.351Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.351L181.693 139.586L121.512 104.529L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.702V278.88L241.346 244.115L241.054 313.937L181.165 348.702Z" fill="#7D7FE5"/>-<path d="M181.165 278.88V348.702L120.4 313.937V244.115L181.165 278.88Z" fill="#2F31AE"/>-<path d="M120.4 244.115L181.165 278.88L241.346 244.115L181.165 209.057L120.4 244.115Z" fill="#6041D0"/>-<path d="M60.7652 348.702V278.88L120.947 244.115L120.654 313.937L60.7652 348.702Z" fill="#7D7FE5"/>-<path d="M60.7652 278.88V348.702L-1.52588e-05 313.937V244.115L60.7652 278.88Z" fill="#2F31AE"/>-<path d="M-1.52588e-05 244.115L60.7652 278.88L120.947 244.115L60.7656 209.057L-1.52588e-05 244.115Z" fill="#6041D0"/>-<path d="M301.017 348.702V278.88L361.198 244.115L360.906 313.937L301.017 348.702Z" fill="#7D7FE5"/>-<path d="M301.017 278.88V348.702L240.252 313.937V244.115L301.017 278.88Z" fill="#2F31AE"/>-<path d="M240.252 244.115L301.017 278.88L361.198 244.115L301.018 209.057L240.252 244.115Z" fill="#6041D0"/>+<svg width="720" height="175" viewBox="0 0 720 175" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M64.2993 3.57443C72.343 -1.19144 82.3494 -1.19151 90.3931 3.57443L142.163 34.2484C149.93 38.8505 154.692 47.2038 154.692 56.2254V118.775C154.692 127.796 149.93 136.149 142.163 140.752L90.3931 171.426C82.3494 176.192 72.343 176.191 64.2993 171.426L12.5296 140.752C4.76242 136.149 0 127.796 0 118.775V56.2254C0 47.2037 4.76242 38.8505 12.5296 34.2484L64.2993 3.57443ZM81.004 40.286C78.8708 39.0012 76.2016 38.9983 74.0657 40.2786L42.6851 59.0884C38.3192 61.7055 38.3303 68.0312 42.7057 70.6326L74.173 89.3408C74.3089 89.4216 74.3921 89.5681 74.3921 89.726V126.818C74.3922 132.04 80.0912 135.269 84.5774 132.589L115.594 114.057C117.626 112.843 118.87 110.652 118.87 108.287V66.8923C118.87 64.5357 117.635 62.3509 115.615 61.134L81.004 40.286Z" fill="#101A24"/>+<path d="M236.385 133.457C229.22 133.457 222.857 132.223 217.298 129.754C211.862 127.163 207.291 123.645 203.584 119.202C200.002 114.635 197.284 109.513 195.431 103.836C193.577 98.1581 192.651 92.2338 192.651 86.0626C192.651 79.8914 193.577 73.9671 195.431 68.2897C197.284 62.6122 200.002 57.5518 203.584 53.1086C207.291 48.6654 211.862 45.2095 217.298 42.741C222.857 40.1492 229.22 38.8532 236.385 38.8532C245.404 38.8532 253.249 41.0131 259.921 45.3329C266.716 49.6528 271.719 56.3176 274.931 65.3275L256.77 72.3626C255.288 67.6725 252.879 63.9081 249.543 61.0694C246.207 58.1072 241.821 56.6262 236.385 56.6262C230.95 56.6262 226.502 58.0455 223.043 60.8843C219.707 63.723 217.236 67.364 215.63 71.8072C214.024 76.2505 213.221 81.0023 213.221 86.0626C213.221 91.123 214.024 95.9365 215.63 100.503C217.236 104.946 219.707 108.587 223.043 111.426C226.502 114.141 230.95 115.499 236.385 115.499C241.821 115.499 246.207 114.08 249.543 111.241C252.879 108.402 255.288 104.638 256.77 99.9477L274.931 106.983C271.719 115.869 266.716 122.534 259.921 126.977C253.249 131.297 245.404 133.457 236.385 133.457Z" fill="#101A24"/>+<path d="M343.217 131.791L341.735 116.425V74.214C341.735 68.2897 339.943 63.8464 336.361 60.8843C332.778 57.7987 327.774 56.2559 321.35 56.2559C316.408 56.2559 311.528 57.2433 306.71 59.218C302.015 61.0694 297.691 63.9698 293.738 67.9194L282.248 54.4045C288.178 48.8505 294.479 44.901 301.151 42.5559C307.822 40.0874 315.111 38.8532 323.018 38.8532C335.372 38.8532 344.947 42.0005 351.742 48.2951C358.66 54.4663 362.12 63.1059 362.12 74.214V131.791H343.217ZM314.864 133.457C308.069 133.457 302.015 132.223 296.703 129.754C291.514 127.286 287.437 123.83 284.472 119.387C281.631 114.944 280.21 109.76 280.21 103.836C280.21 98.7752 281.26 94.3937 283.36 90.691C285.584 86.9883 288.426 84.0878 291.885 81.9896C294.85 80.1383 298.309 78.8423 302.262 78.1018C306.216 77.2378 310.355 76.8059 314.679 76.8059H343.403V92.1721H317.644C315.42 92.1721 313.196 92.4189 310.972 92.9126C308.749 93.2829 306.772 94.0234 305.042 95.1342C303.807 96.1216 302.757 97.3558 301.892 98.8369C301.151 100.318 300.78 102.046 300.78 104.021C300.78 107.97 302.262 111.118 305.228 113.463C308.316 115.684 312.393 116.795 317.458 116.795C321.906 116.795 325.921 115.808 329.504 113.833C333.21 111.858 336.175 109.143 338.399 105.687C340.623 102.231 341.735 98.3432 341.735 94.0234L348.036 104.206C346.553 110.624 344.206 116.054 340.994 120.498C337.781 124.818 333.952 128.088 329.504 130.31C325.056 132.408 320.176 133.457 314.864 133.457Z" fill="#101A24"/>+<path d="M375.823 131.791V40.5194H396.578V65.1424L392.687 65.6978C393.304 60.3906 395.096 55.7622 398.061 51.8127C401.026 47.7397 404.609 44.5924 408.809 42.3708C413.133 40.0257 417.395 38.8532 421.596 38.8532C424.561 38.8532 427.403 39.2235 430.121 39.964C432.839 40.7046 435.68 41.9388 438.645 43.6667L428.638 62.1802C427.279 61.3162 425.488 60.6374 423.264 60.1437C421.164 59.5266 419.125 59.218 417.148 59.218C414.554 59.218 411.96 59.7117 409.365 60.6991C406.894 61.6865 404.67 63.2293 402.694 65.3275C400.717 67.3023 399.234 69.8942 398.246 73.1032C397.628 74.8311 397.134 77.1144 396.764 79.9532C396.517 82.6685 396.393 86.4946 396.393 91.4315V131.791H375.823Z" fill="#101A24"/>+<path d="M492.002 133.457C487.06 133.457 482.365 132.47 477.918 130.495C473.594 128.52 469.825 125.496 466.613 121.423C463.401 117.227 460.992 111.796 459.386 105.132L464.76 106.427V131.791H444.375V2.75192H464.76V66.068H460.127C461.363 60.2672 463.463 55.3919 466.428 51.4424C469.517 47.3694 473.223 44.2838 477.547 42.1856C481.995 39.964 486.813 38.8532 492.002 38.8532C499.414 38.8532 506.086 40.7663 512.016 44.5924C518.069 48.2951 522.888 53.664 526.47 60.6991C530.053 67.7343 531.845 76.1887 531.845 86.0626C531.845 95.0725 530.177 103.157 526.841 110.315C523.629 117.474 519.058 123.151 513.128 127.348C507.198 131.421 500.156 133.457 492.002 133.457ZM486.998 114.573C491.816 114.573 496.017 113.401 499.6 111.056C503.306 108.711 506.147 105.378 508.124 101.059C510.101 96.7387 511.089 91.7401 511.089 86.0626C511.089 80.3851 510.101 75.3865 508.124 71.0667C506.147 66.7469 503.306 63.4144 499.6 61.0694C496.017 58.7244 491.816 57.5518 486.998 57.5518C482.18 57.5518 477.918 58.7861 474.211 61.2545C470.629 63.5996 467.849 66.932 465.872 71.2518C463.895 75.4482 462.907 80.3851 462.907 86.0626C462.907 91.7401 463.895 96.7387 465.872 101.059C467.849 105.378 470.629 108.711 474.211 111.056C477.918 113.401 482.18 114.573 486.998 114.573Z" fill="#101A24"/>+<path d="M583.567 133.457C574.919 133.457 567.135 131.421 560.217 127.348C553.298 123.275 547.862 117.659 543.909 110.5C540.079 103.342 538.164 95.1959 538.164 86.0626C538.164 76.9293 540.079 68.7834 543.909 61.6248C547.862 54.4663 553.237 48.9122 560.032 44.9627C566.95 40.8897 574.795 38.8532 583.567 38.8532C592.462 38.8532 600.245 40.8897 606.917 44.9627C613.711 48.9122 619.086 54.4663 623.039 61.6248C626.992 68.7834 628.969 76.9293 628.969 86.0626C628.969 95.1959 626.992 103.342 623.039 110.5C619.209 117.659 613.835 123.275 606.917 127.348C600.122 131.421 592.338 133.457 583.567 133.457ZM583.752 115.314C588.817 115.314 593.203 114.141 596.909 111.796C600.616 109.451 603.457 106.057 605.434 101.614C607.411 97.1707 608.399 91.9869 608.399 86.0626C608.399 80.0149 607.411 74.8311 605.434 70.5113C603.457 66.068 600.616 62.6739 596.909 60.3289C593.203 57.9838 588.817 56.8113 583.752 56.8113C578.44 56.8113 573.93 58.0455 570.224 60.514C566.518 62.859 563.676 66.1915 561.699 70.5113C559.723 74.8311 558.734 80.0149 558.734 86.0626C558.734 91.9869 559.723 97.1707 561.699 101.614C563.676 106.057 566.518 109.451 570.224 111.796C573.93 114.141 578.44 115.314 583.752 115.314Z" fill="#101A24"/>+<path d="M639.573 131.791V40.5194H660.143V60.6991L656.437 61.6248C658.043 56.3176 660.39 51.9978 663.479 48.6654C666.567 45.3329 670.15 42.8645 674.227 41.26C678.427 39.6555 682.813 38.8532 687.384 38.8532C697.639 38.8532 705.607 41.8154 711.29 47.7397C717.097 53.5406 720 61.8716 720 72.7329V131.791H699.43V80.3234C699.43 72.1775 697.947 66.1915 694.982 62.3653C692.017 58.5392 687.446 56.6262 681.269 56.6262C676.698 56.6262 672.806 57.737 669.594 59.9586C666.505 62.0568 664.158 65.3892 662.552 69.9559C660.946 74.5225 660.143 80.3234 660.143 87.3585V131.791H639.573Z" fill="#101A24"/></svg>diff --git a/examples/quote-configurator/public/favicon-16x16.png b/examples/quote-configurator/public/favicon-16x16.pngindex eb216e453f..7f08a7eae3 100644Binary files a/examples/quote-configurator/public/favicon-16x16.png and b/examples/quote-configurator/public/favicon-16x16.png differdiff --git a/examples/quote-configurator/public/favicon-32x32.png b/examples/quote-configurator/public/favicon-32x32.pngindex a7064d2122..348b196709 100644Binary files a/examples/quote-configurator/public/favicon-32x32.png and b/examples/quote-configurator/public/favicon-32x32.png differdiff --git a/examples/quote-configurator/public/favicon-96x96.png b/examples/quote-configurator/public/favicon-96x96.pngdeleted file mode 100644index c36c27be04..0000000000Binary files a/examples/quote-configurator/public/favicon-96x96.png and /dev/null differdiff --git a/examples/quote-configurator/public/favicon.ico b/examples/quote-configurator/public/favicon.icoindex a87e92b575..644a0d8ed5 100644Binary files a/examples/quote-configurator/public/favicon.ico and b/examples/quote-configurator/public/favicon.ico differdiff --git a/examples/quote-configurator/public/favicon.svg b/examples/quote-configurator/public/favicon.svgindex 1f953c23a1..047b926154 100644--- a/examples/quote-configurator/public/favicon.svg+++ b/examples/quote-configurator/public/favicon.svg@@ -1,22 +1,3 @@-<svg xmlns="http://www.w3.org/2000/svg" version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" width="362" height="349"><svg width="362" height="349" viewBox="0 0 362 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M181.165 139.643V69.8213L241.346 35.0564L241.054 104.878L181.165 139.643Z" fill="#60FFD2"></path>-<path d="M181.165 69.8213V139.643L120.4 104.878V35.0564L181.165 69.8213Z" fill="#36B5B4"></path>-<path d="M120.4 35.0565L181.165 69.8214L241.347 35.0565L181.165 -0.000610352L120.4 35.0565Z" fill="#5FE4D2"></path>-<path d="M240.818 244.172V174.35L300.999 139.585L300.707 209.407L240.818 244.172Z" fill="#71DEFF"></path>-<path d="M240.818 174.35V244.172L180.052 209.407V139.585L240.818 174.35Z" fill="#3877C5"></path>-<path d="M180.052 139.586L240.818 174.35L300.999 139.586L240.818 104.528L180.052 139.586Z" fill="#4EAADE"></path>-<path d="M121.512 244.172V174.35L181.693 139.585L181.401 209.407L121.512 244.172Z" fill="#71DEFF"></path>-<path d="M121.512 174.35V244.172L60.7466 209.407V139.585L121.512 174.35Z" fill="#3877C5"></path>-<path d="M60.7466 139.586L121.512 174.35L181.694 139.586L121.512 104.528L60.7466 139.586Z" fill="#4EAADE"></path>-<path d="M181.165 348.701V278.879L241.346 244.114L241.054 313.936L181.165 348.701Z" fill="#7D7FE5"></path>-<path d="M181.165 278.879V348.701L120.4 313.936V244.114L181.165 278.879Z" fill="#2F31AE"></path>-<path d="M120.4 244.114L181.165 278.879L241.347 244.114L181.165 209.057L120.4 244.114Z" fill="#6041D0"></path>-<path d="M60.7651 348.701V278.879L120.946 244.114L120.654 313.936L60.7651 348.701Z" fill="#7D7FE5"></path>-<path d="M60.7656 278.879V348.701L0 313.936V244.114L60.7656 278.879Z" fill="#2F31AE"></path>-<path d="M0 244.114L60.7656 278.879L120.947 244.114L60.7656 209.057L0 244.114Z" fill="#6041D0"></path>-<path d="M301.017 348.701V278.879L361.198 244.114L360.906 313.936L301.017 348.701Z" fill="#7D7FE5"></path>-<path d="M301.018 278.879V348.701L240.252 313.936V244.114L301.018 278.879Z" fill="#2F31AE"></path>-<path d="M240.252 244.114L301.018 278.879L361.199 244.114L301.018 209.057L240.252 244.114Z" fill="#6041D0"></path>-</svg><style>@media (prefers-color-scheme: light) { :root { filter: none; } }-@media (prefers-color-scheme: dark) { :root { filter: none; } }-</style></svg>\ No newline at end of file+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#E6E6E6"/>+</svg>diff --git a/examples/quote-configurator/public/site.webmanifest b/examples/quote-configurator/public/site.webmanifestindex aa6777552f..4e209ea8a1 100644--- a/examples/quote-configurator/public/site.webmanifest+++ b/examples/quote-configurator/public/site.webmanifest@@ -3,19 +3,17 @@"short_name": "Carbon","icons": [{- "src": "/web-app-manifest-192x192.png",+ "src": "/android-chrome-192x192.png","sizes": "192x192",- "type": "image/png",- "purpose": "maskable"+ "type": "image/png"},{- "src": "/web-app-manifest-512x512.png",+ "src": "/android-chrome-512x512.png","sizes": "512x512",- "type": "image/png",- "purpose": "maskable"+ "type": "image/png"}],- "theme_color": "#000000",- "background_color": "#000000",+ "theme_color": "#ffffff",+ "background_color": "#ffffff","display": "standalone"}diff --git a/examples/quote-configurator/public/web-app-manifest-192x192.png b/examples/quote-configurator/public/web-app-manifest-192x192.pngdeleted file mode 100644index cda38d5ed4..0000000000Binary files a/examples/quote-configurator/public/web-app-manifest-192x192.png and /dev/null differdiff --git a/examples/quote-configurator/public/web-app-manifest-512x512.png b/examples/quote-configurator/public/web-app-manifest-512x512.pngdeleted file mode 100644index 88c30a090e..0000000000Binary files a/examples/quote-configurator/public/web-app-manifest-512x512.png and /dev/null differdiff --git a/examples/upload-3d-model/app/root.tsx b/examples/upload-3d-model/app/root.tsxindex 1b311ef32d..0960155155 100644--- a/examples/upload-3d-model/app/root.tsx+++ b/examples/upload-3d-model/app/root.tsx@@ -82,10 +82,15 @@ export function ErrorBoundary() {<div className="light"><div className="flex flex-col w-full h-screen items-center justify-center space-y-4 "><img- src="/carbon-logo-mark.svg"+ src="/carbon-mark-light.svg"alt="Carbon Logo"className="block max-w-[60px]"/>+ <img+ src="/carbon-mark-dark.svg"+ alt="Carbon Logo"+ className="max-w-[60px] hidden dark:block"+ /><h1 className="text-2xl font-bold">Something went wrong</h1><p className="text-muted-foreground max-w-2xl">{message}</p></div>diff --git a/examples/upload-3d-model/public/android-chrome-192x192.png b/examples/upload-3d-model/public/android-chrome-192x192.pngnew file mode 100644index 0000000000..bc936a17b0Binary files /dev/null and b/examples/upload-3d-model/public/android-chrome-192x192.png differdiff --git a/examples/upload-3d-model/public/android-chrome-512x512.png b/examples/upload-3d-model/public/android-chrome-512x512.pngnew file mode 100644index 0000000000..841366bbf7Binary files /dev/null and b/examples/upload-3d-model/public/android-chrome-512x512.png differdiff --git a/examples/upload-3d-model/public/apple-touch-icon.png b/examples/upload-3d-model/public/apple-touch-icon.pngindex 7d10fd7748..aadf41c525 100644Binary files a/examples/upload-3d-model/public/apple-touch-icon.png and b/examples/upload-3d-model/public/apple-touch-icon.png differdiff --git a/examples/upload-3d-model/public/carbon-logo-mark.svg b/examples/upload-3d-model/public/carbon-logo-mark.svgdeleted file mode 100644index 048049e1e5..0000000000--- a/examples/upload-3d-model/public/carbon-logo-mark.svg+++ /dev/null@@ -1,20 +0,0 @@-<svg width="362" height="349" viewBox="0 0 362 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M181.165 139.643V69.8213L241.346 35.0564L241.054 104.878L181.165 139.643Z" fill="#60FFD2"/>-<path d="M181.165 69.8213V139.643L120.4 104.878V35.0564L181.165 69.8213Z" fill="#36B5B4"/>-<path d="M120.4 35.0565L181.165 69.8214L241.347 35.0565L181.165 -0.000610352L120.4 35.0565Z" fill="#5FE4D2"/>-<path d="M240.818 244.172V174.35L300.999 139.585L300.707 209.407L240.818 244.172Z" fill="#71DEFF"/>-<path d="M240.818 174.35V244.172L180.052 209.407V139.585L240.818 174.35Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.35L300.999 139.586L240.818 104.528L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.172V174.35L181.693 139.585L181.401 209.407L121.512 244.172Z" fill="#71DEFF"/>-<path d="M121.512 174.35V244.172L60.7466 209.407V139.585L121.512 174.35Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.35L181.694 139.586L121.512 104.528L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.701V278.879L241.346 244.114L241.054 313.936L181.165 348.701Z" fill="#7D7FE5"/>-<path d="M181.165 278.879V348.701L120.4 313.936V244.114L181.165 278.879Z" fill="#2F31AE"/>-<path d="M120.4 244.114L181.165 278.879L241.347 244.114L181.165 209.057L120.4 244.114Z" fill="#6041D0"/>-<path d="M60.7651 348.701V278.879L120.946 244.114L120.654 313.936L60.7651 348.701Z" fill="#7D7FE5"/>-<path d="M60.7656 278.879V348.701L0 313.936V244.114L60.7656 278.879Z" fill="#2F31AE"/>-<path d="M0 244.114L60.7656 278.879L120.947 244.114L60.7656 209.057L0 244.114Z" fill="#6041D0"/>-<path d="M301.017 348.701V278.879L361.198 244.114L360.906 313.936L301.017 348.701Z" fill="#7D7FE5"/>-<path d="M301.018 278.879V348.701L240.252 313.936V244.114L301.018 278.879Z" fill="#2F31AE"/>-<path d="M240.252 244.114L301.018 278.879L361.199 244.114L301.018 209.057L240.252 244.114Z" fill="#6041D0"/>-</svg>diff --git a/examples/upload-3d-model/public/carbon-mark-dark.svg b/examples/upload-3d-model/public/carbon-mark-dark.svgnew file mode 100644index 0000000000..047b926154--- /dev/null+++ b/examples/upload-3d-model/public/carbon-mark-dark.svg@@ -0,0 +1,3 @@+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#E6E6E6"/>+</svg>diff --git a/examples/upload-3d-model/public/carbon-mark-light.svg b/examples/upload-3d-model/public/carbon-mark-light.svgnew file mode 100644index 0000000000..db0480c53c--- /dev/null+++ b/examples/upload-3d-model/public/carbon-mark-light.svg@@ -0,0 +1,3 @@+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#101A24"/>+</svg>diff --git a/examples/upload-3d-model/public/carbon-word-dark.png b/examples/upload-3d-model/public/carbon-word-dark.pngdeleted file mode 100644index 3606059a75..0000000000Binary files a/examples/upload-3d-model/public/carbon-word-dark.png and /dev/null differdiff --git a/examples/upload-3d-model/public/carbon-word-dark.svg b/examples/upload-3d-model/public/carbon-word-dark.svgindex b555c4b360..c4463b4061 100644--- a/examples/upload-3d-model/public/carbon-word-dark.svg+++ b/examples/upload-3d-model/public/carbon-word-dark.svg@@ -1,26 +1,9 @@-<svg width="1307" height="349" viewBox="0 0 1307 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M412.646 193.426C412.646 178.405 415.703 165.305 421.816 154.126C427.929 142.773 436.401 134.039 447.23 127.926C458.059 121.638 470.461 118.494 484.434 118.494C502.425 118.494 517.271 123.035 528.974 132.118C540.851 141.026 548.799 153.602 552.816 169.846H513.254C511.158 163.558 507.577 158.667 502.512 155.174C497.621 151.506 491.508 149.672 484.172 149.672C473.692 149.672 465.395 153.515 459.282 161.2C453.169 168.711 450.112 179.453 450.112 193.426C450.112 207.225 453.169 217.967 459.282 225.652C465.395 233.163 473.692 236.918 484.172 236.918C499.019 236.918 508.713 230.281 513.254 217.006H552.816C548.799 232.726 540.851 245.215 528.974 254.472C517.097 263.729 502.25 268.358 484.434 268.358C470.461 268.358 458.059 265.301 447.23 259.188C436.401 252.9 427.929 244.167 421.816 232.988C415.703 221.635 412.646 208.447 412.646 193.426Z" fill="white"/>-<path d="M562.395 192.902C562.395 178.23 565.277 165.217 571.041 153.864C576.98 142.511 584.927 133.777 594.883 127.664C605.014 121.551 616.28 118.494 628.681 118.494C639.511 118.494 648.943 120.677 656.977 125.044C665.187 129.411 671.737 134.913 676.627 141.55V120.852H713.569V266H676.627V244.778C671.911 251.59 665.361 257.267 656.977 261.808C648.768 266.175 639.249 268.358 628.419 268.358C616.193 268.358 605.014 265.214 594.883 258.926C584.927 252.638 576.98 243.817 571.041 232.464C565.277 220.936 562.395 207.749 562.395 192.902ZM676.627 193.426C676.627 184.518 674.881 176.92 671.387 170.632C667.894 164.169 663.178 159.279 657.239 155.96C651.301 152.467 644.925 150.72 638.113 150.72C631.301 150.72 625.013 152.379 619.249 155.698C613.485 159.017 608.769 163.907 605.101 170.37C601.608 176.658 599.861 184.169 599.861 192.902C599.861 201.635 601.608 209.321 605.101 215.958C608.769 222.421 613.485 227.399 619.249 230.892C625.188 234.385 631.476 236.132 638.113 236.132C644.925 236.132 651.301 234.473 657.239 231.154C663.178 227.661 667.894 222.77 671.387 216.482C674.881 210.019 676.627 202.334 676.627 193.426Z" fill="white"/>-<path d="M778.214 143.384C782.93 135.699 789.043 129.673 796.554 125.306C804.239 120.939 812.972 118.756 822.754 118.756V157.27H813.06C801.532 157.27 792.798 159.977 786.86 165.392C781.096 170.807 778.214 180.239 778.214 193.688V266H741.534V120.852H778.214V143.384Z" fill="white"/>-<path d="M876.28 142.074C880.996 135.087 887.458 129.411 895.668 125.044C904.052 120.677 913.571 118.494 924.226 118.494C936.627 118.494 947.806 121.551 957.762 127.664C967.892 133.777 975.84 142.511 981.604 153.864C987.542 165.043 990.512 178.055 990.512 192.902C990.512 207.749 987.542 220.936 981.604 232.464C975.84 243.817 967.892 252.638 957.762 258.926C947.806 265.214 936.627 268.358 924.226 268.358C913.396 268.358 903.877 266.262 895.668 262.07C887.633 257.703 881.17 252.114 876.28 245.302V266H839.6V72.12H876.28V142.074ZM953.046 192.902C953.046 184.169 951.212 176.658 947.544 170.37C944.05 163.907 939.334 159.017 933.396 155.698C927.632 152.379 921.344 150.72 914.532 150.72C907.894 150.72 901.606 152.467 895.668 155.96C889.904 159.279 885.188 164.169 881.52 170.632C878.026 177.095 876.28 184.693 876.28 193.426C876.28 202.159 878.026 209.757 881.52 216.22C885.188 222.683 889.904 227.661 895.668 231.154C901.606 234.473 907.894 236.132 914.532 236.132C921.344 236.132 927.632 234.385 933.396 230.892C939.334 227.399 944.05 222.421 947.544 215.958C951.212 209.495 953.046 201.81 953.046 192.902Z" fill="white"/>-<path d="M1073.76 268.358C1059.78 268.358 1047.21 265.301 1036.03 259.188C1024.85 252.9 1016.03 244.079 1009.57 232.726C1003.28 221.373 1000.14 208.273 1000.14 193.426C1000.14 178.579 1003.37 165.479 1009.83 154.126C1016.47 142.773 1025.46 134.039 1036.82 127.926C1048.17 121.638 1060.83 118.494 1074.81 118.494C1088.78 118.494 1101.44 121.638 1112.8 127.926C1124.15 134.039 1133.06 142.773 1139.52 154.126C1146.16 165.479 1149.48 178.579 1149.48 193.426C1149.48 208.273 1146.07 221.373 1139.26 232.726C1132.62 244.079 1123.54 252.9 1112.01 259.188C1100.66 265.301 1087.91 268.358 1073.76 268.358ZM1073.76 236.394C1080.4 236.394 1086.6 234.822 1092.36 231.678C1098.3 228.359 1103.01 223.469 1106.51 217.006C1110 210.543 1111.75 202.683 1111.75 193.426C1111.75 179.627 1108.08 169.06 1100.74 161.724C1093.58 154.213 1084.76 150.458 1074.28 150.458C1063.8 150.458 1054.98 154.213 1047.82 161.724C1040.83 169.06 1037.34 179.627 1037.34 193.426C1037.34 207.225 1040.75 217.879 1047.56 225.39C1054.54 232.726 1063.28 236.394 1073.76 236.394Z" fill="white"/>-<path d="M1248.96 118.756C1266.25 118.756 1280.22 124.258 1290.88 135.262C1301.53 146.091 1306.86 161.287 1306.86 180.85V266H1270.18V185.828C1270.18 174.3 1267.3 165.479 1261.53 159.366C1255.77 153.078 1247.91 149.934 1237.95 149.934C1227.82 149.934 1219.79 153.078 1213.85 159.366C1208.08 165.479 1205.2 174.3 1205.2 185.828V266H1168.52V120.852H1205.2V138.93C1210.09 132.642 1216.29 127.751 1223.8 124.258C1231.49 120.59 1239.87 118.756 1248.96 118.756Z" fill="white"/>-<path d="M181.165 139.644V69.822L241.346 35.0571L241.054 104.879L181.165 139.644Z" fill="#60FFD2"/>-<path d="M181.165 69.822V139.644L120.4 104.879V35.0571L181.165 69.822Z" fill="#36B5B4"/>-<path d="M120.4 35.0571L181.165 69.822L241.346 35.0571L181.165 0L120.4 35.0571Z" fill="#5FE4D2"/>-<path d="M240.818 244.173V174.351L300.999 139.586L300.707 209.408L240.818 244.173Z" fill="#71DEFF"/>-<path d="M240.818 174.351V244.173L180.052 209.408V139.586L240.818 174.351Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.351L300.999 139.586L240.818 104.529L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.173V174.351L181.693 139.586L181.401 209.408L121.512 244.173Z" fill="#71DEFF"/>-<path d="M121.512 174.351V244.173L60.7466 209.408V139.586L121.512 174.351Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.351L181.693 139.586L121.512 104.529L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.702V278.88L241.346 244.115L241.054 313.937L181.165 348.702Z" fill="#7D7FE5"/>-<path d="M181.165 278.88V348.702L120.4 313.937V244.115L181.165 278.88Z" fill="#2F31AE"/>-<path d="M120.4 244.115L181.165 278.88L241.346 244.115L181.165 209.057L120.4 244.115Z" fill="#6041D0"/>-<path d="M60.7652 348.702V278.88L120.947 244.115L120.654 313.937L60.7652 348.702Z" fill="#7D7FE5"/>-<path d="M60.7652 278.88V348.702L0 313.937V244.115L60.7652 278.88Z" fill="#2F31AE"/>-<path d="M0 244.115L60.7652 278.88L120.947 244.115L60.7656 209.057L0 244.115Z" fill="#6041D0"/>-<path d="M301.017 348.702V278.88L361.198 244.115L360.906 313.937L301.017 348.702Z" fill="#7D7FE5"/>-<path d="M301.017 278.88V348.702L240.252 313.937V244.115L301.017 278.88Z" fill="#2F31AE"/>-<path d="M240.252 244.115L301.017 278.88L361.198 244.115L301.018 209.057L240.252 244.115Z" fill="#6041D0"/>+<svg width="720" height="175" viewBox="0 0 720 175" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M64.2993 3.57443C72.343 -1.19144 82.3494 -1.19151 90.3931 3.57443L142.163 34.2484C149.93 38.8505 154.692 47.2038 154.692 56.2254V118.775C154.692 127.796 149.93 136.149 142.163 140.752L90.3931 171.426C82.3494 176.192 72.343 176.191 64.2993 171.426L12.5296 140.752C4.76242 136.149 0 127.796 0 118.775V56.2254C0 47.2037 4.76242 38.8505 12.5296 34.2484L64.2993 3.57443ZM81.004 40.286C78.8708 39.0012 76.2016 38.9983 74.0657 40.2786L42.6851 59.0884C38.3192 61.7055 38.3303 68.0312 42.7057 70.6326L74.173 89.3408C74.3089 89.4216 74.3921 89.5681 74.3921 89.726V126.818C74.3922 132.04 80.0912 135.269 84.5774 132.589L115.594 114.057C117.626 112.843 118.87 110.652 118.87 108.287V66.8923C118.87 64.5357 117.635 62.3509 115.615 61.134L81.004 40.286Z" fill="#E6E6E6"/>+<path d="M236.385 133.457C229.22 133.457 222.857 132.223 217.298 129.754C211.862 127.163 207.291 123.645 203.584 119.202C200.002 114.635 197.284 109.513 195.431 103.836C193.577 98.1581 192.651 92.2338 192.651 86.0626C192.651 79.8914 193.577 73.9671 195.431 68.2897C197.284 62.6122 200.002 57.5518 203.584 53.1086C207.291 48.6654 211.862 45.2095 217.298 42.741C222.857 40.1492 229.22 38.8532 236.385 38.8532C245.404 38.8532 253.249 41.0131 259.921 45.3329C266.716 49.6528 271.719 56.3176 274.931 65.3275L256.77 72.3626C255.288 67.6725 252.879 63.9081 249.543 61.0694C246.207 58.1072 241.821 56.6262 236.385 56.6262C230.95 56.6262 226.502 58.0455 223.043 60.8843C219.707 63.723 217.236 67.364 215.63 71.8072C214.024 76.2505 213.221 81.0023 213.221 86.0626C213.221 91.123 214.024 95.9365 215.63 100.503C217.236 104.946 219.707 108.587 223.043 111.426C226.502 114.141 230.95 115.499 236.385 115.499C241.821 115.499 246.207 114.08 249.543 111.241C252.879 108.402 255.288 104.638 256.77 99.9477L274.931 106.983C271.719 115.869 266.716 122.534 259.921 126.977C253.249 131.297 245.404 133.457 236.385 133.457Z" fill="#E6E6E6"/>+<path d="M343.217 131.791L341.735 116.425V74.214C341.735 68.2897 339.943 63.8464 336.361 60.8843C332.778 57.7987 327.774 56.2559 321.35 56.2559C316.408 56.2559 311.528 57.2433 306.71 59.218C302.015 61.0694 297.691 63.9698 293.738 67.9194L282.248 54.4045C288.178 48.8505 294.479 44.901 301.151 42.5559C307.822 40.0874 315.111 38.8532 323.018 38.8532C335.372 38.8532 344.947 42.0005 351.742 48.2951C358.66 54.4663 362.12 63.1059 362.12 74.214V131.791H343.217ZM314.864 133.457C308.069 133.457 302.015 132.223 296.703 129.754C291.514 127.286 287.437 123.83 284.472 119.387C281.631 114.944 280.21 109.76 280.21 103.836C280.21 98.7752 281.26 94.3937 283.36 90.691C285.584 86.9883 288.426 84.0878 291.885 81.9896C294.85 80.1383 298.309 78.8423 302.262 78.1018C306.216 77.2378 310.355 76.8059 314.679 76.8059H343.403V92.1721H317.644C315.42 92.1721 313.196 92.4189 310.972 92.9126C308.749 93.2829 306.772 94.0234 305.042 95.1342C303.807 96.1216 302.757 97.3558 301.892 98.8369C301.151 100.318 300.78 102.046 300.78 104.021C300.78 107.97 302.262 111.118 305.228 113.463C308.316 115.684 312.393 116.795 317.458 116.795C321.906 116.795 325.921 115.808 329.504 113.833C333.21 111.858 336.175 109.143 338.399 105.687C340.623 102.231 341.735 98.3432 341.735 94.0234L348.036 104.206C346.553 110.624 344.206 116.054 340.994 120.498C337.781 124.818 333.952 128.088 329.504 130.31C325.056 132.408 320.176 133.457 314.864 133.457Z" fill="#E6E6E6"/>+<path d="M375.823 131.791V40.5194H396.578V65.1424L392.687 65.6978C393.304 60.3906 395.096 55.7622 398.061 51.8127C401.026 47.7397 404.609 44.5924 408.809 42.3708C413.133 40.0257 417.395 38.8532 421.596 38.8532C424.561 38.8532 427.403 39.2235 430.121 39.964C432.839 40.7046 435.68 41.9388 438.645 43.6667L428.638 62.1802C427.279 61.3162 425.488 60.6374 423.264 60.1437C421.164 59.5266 419.125 59.218 417.148 59.218C414.554 59.218 411.96 59.7117 409.365 60.6991C406.894 61.6865 404.67 63.2293 402.694 65.3275C400.717 67.3023 399.234 69.8942 398.246 73.1032C397.628 74.8311 397.134 77.1144 396.764 79.9532C396.517 82.6685 396.393 86.4946 396.393 91.4315V131.791H375.823Z" fill="#E6E6E6"/>+<path d="M492.002 133.457C487.06 133.457 482.365 132.47 477.918 130.495C473.594 128.52 469.825 125.496 466.613 121.423C463.401 117.227 460.992 111.796 459.386 105.132L464.76 106.427V131.791H444.375V2.75192H464.76V66.068H460.127C461.363 60.2672 463.463 55.3919 466.428 51.4424C469.517 47.3694 473.223 44.2838 477.547 42.1856C481.995 39.964 486.813 38.8532 492.002 38.8532C499.414 38.8532 506.086 40.7663 512.016 44.5924C518.069 48.2951 522.888 53.664 526.47 60.6991C530.053 67.7343 531.845 76.1887 531.845 86.0626C531.845 95.0725 530.177 103.157 526.841 110.315C523.629 117.474 519.058 123.151 513.128 127.348C507.198 131.421 500.156 133.457 492.002 133.457ZM486.998 114.573C491.816 114.573 496.017 113.401 499.6 111.056C503.306 108.711 506.147 105.378 508.124 101.059C510.101 96.7387 511.089 91.7401 511.089 86.0626C511.089 80.3851 510.101 75.3865 508.124 71.0667C506.147 66.7469 503.306 63.4144 499.6 61.0694C496.017 58.7244 491.816 57.5518 486.998 57.5518C482.18 57.5518 477.918 58.7861 474.211 61.2545C470.629 63.5996 467.849 66.932 465.872 71.2518C463.895 75.4482 462.907 80.3851 462.907 86.0626C462.907 91.7401 463.895 96.7387 465.872 101.059C467.849 105.378 470.629 108.711 474.211 111.056C477.918 113.401 482.18 114.573 486.998 114.573Z" fill="#E6E6E6"/>+<path d="M583.567 133.457C574.919 133.457 567.135 131.421 560.217 127.348C553.298 123.275 547.862 117.659 543.909 110.5C540.079 103.342 538.164 95.1959 538.164 86.0626C538.164 76.9293 540.079 68.7834 543.909 61.6248C547.862 54.4663 553.237 48.9122 560.032 44.9627C566.95 40.8897 574.795 38.8532 583.567 38.8532C592.462 38.8532 600.245 40.8897 606.917 44.9627C613.711 48.9122 619.086 54.4663 623.039 61.6248C626.992 68.7834 628.969 76.9293 628.969 86.0626C628.969 95.1959 626.992 103.342 623.039 110.5C619.209 117.659 613.835 123.275 606.917 127.348C600.122 131.421 592.338 133.457 583.567 133.457ZM583.752 115.314C588.817 115.314 593.203 114.141 596.909 111.796C600.616 109.451 603.457 106.057 605.434 101.614C607.411 97.1707 608.399 91.9869 608.399 86.0626C608.399 80.0149 607.411 74.8311 605.434 70.5113C603.457 66.068 600.616 62.6739 596.909 60.3289C593.203 57.9838 588.817 56.8113 583.752 56.8113C578.44 56.8113 573.93 58.0455 570.224 60.514C566.518 62.859 563.676 66.1915 561.699 70.5113C559.723 74.8311 558.734 80.0149 558.734 86.0626C558.734 91.9869 559.723 97.1707 561.699 101.614C563.676 106.057 566.518 109.451 570.224 111.796C573.93 114.141 578.44 115.314 583.752 115.314Z" fill="#E6E6E6"/>+<path d="M639.573 131.791V40.5194H660.143V60.6991L656.437 61.6248C658.043 56.3176 660.39 51.9978 663.479 48.6654C666.567 45.3329 670.15 42.8645 674.227 41.26C678.427 39.6555 682.813 38.8532 687.384 38.8532C697.639 38.8532 705.607 41.8154 711.29 47.7397C717.097 53.5406 720 61.8716 720 72.7329V131.791H699.43V80.3234C699.43 72.1775 697.947 66.1915 694.982 62.3653C692.017 58.5392 687.446 56.6262 681.269 56.6262C676.698 56.6262 672.806 57.737 669.594 59.9586C666.505 62.0568 664.158 65.3892 662.552 69.9559C660.946 74.5225 660.143 80.3234 660.143 87.3585V131.791H639.573Z" fill="#E6E6E6"/></svg>diff --git a/examples/upload-3d-model/public/carbon-word-light.png b/examples/upload-3d-model/public/carbon-word-light.pngdeleted file mode 100644index becd8f13bb..0000000000Binary files a/examples/upload-3d-model/public/carbon-word-light.png and /dev/null differdiff --git a/examples/upload-3d-model/public/carbon-word-light.svg b/examples/upload-3d-model/public/carbon-word-light.svgindex 3e899a2d1b..3fd85675c9 100644--- a/examples/upload-3d-model/public/carbon-word-light.svg+++ b/examples/upload-3d-model/public/carbon-word-light.svg@@ -1,26 +1,9 @@-<svg width="1307" height="349" viewBox="0 0 1307 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M412.646 193.426C412.646 178.405 415.703 165.305 421.816 154.126C427.929 142.773 436.401 134.039 447.23 127.926C458.059 121.638 470.461 118.494 484.434 118.494C502.425 118.494 517.271 123.035 528.974 132.118C540.851 141.026 548.799 153.602 552.816 169.846H513.254C511.158 163.558 507.577 158.667 502.512 155.174C497.621 151.506 491.508 149.672 484.172 149.672C473.692 149.672 465.395 153.515 459.282 161.2C453.169 168.711 450.112 179.453 450.112 193.426C450.112 207.225 453.169 217.967 459.282 225.652C465.395 233.163 473.692 236.918 484.172 236.918C499.019 236.918 508.713 230.281 513.254 217.006H552.816C548.799 232.726 540.851 245.215 528.974 254.472C517.097 263.729 502.25 268.358 484.434 268.358C470.461 268.358 458.059 265.301 447.23 259.188C436.401 252.9 427.929 244.167 421.816 232.988C415.703 221.635 412.646 208.447 412.646 193.426Z" fill="#212278"/>-<path d="M562.395 192.902C562.395 178.23 565.277 165.217 571.041 153.864C576.98 142.511 584.927 133.777 594.883 127.664C605.014 121.551 616.28 118.494 628.681 118.494C639.511 118.494 648.943 120.677 656.977 125.044C665.187 129.411 671.737 134.913 676.627 141.55V120.852H713.569V266H676.627V244.778C671.911 251.59 665.361 257.267 656.977 261.808C648.768 266.175 639.249 268.358 628.419 268.358C616.193 268.358 605.014 265.214 594.883 258.926C584.927 252.638 576.98 243.817 571.041 232.464C565.277 220.936 562.395 207.749 562.395 192.902ZM676.627 193.426C676.627 184.518 674.881 176.92 671.387 170.632C667.894 164.169 663.178 159.279 657.239 155.96C651.301 152.467 644.925 150.72 638.113 150.72C631.301 150.72 625.013 152.379 619.249 155.698C613.485 159.017 608.769 163.907 605.101 170.37C601.608 176.658 599.861 184.169 599.861 192.902C599.861 201.635 601.608 209.321 605.101 215.958C608.769 222.421 613.485 227.399 619.249 230.892C625.188 234.385 631.476 236.132 638.113 236.132C644.925 236.132 651.301 234.473 657.239 231.154C663.178 227.661 667.894 222.77 671.387 216.482C674.881 210.019 676.627 202.334 676.627 193.426Z" fill="#212278"/>-<path d="M778.214 143.384C782.93 135.699 789.043 129.673 796.554 125.306C804.239 120.939 812.972 118.756 822.754 118.756V157.27H813.06C801.532 157.27 792.798 159.977 786.86 165.392C781.096 170.807 778.214 180.239 778.214 193.688V266H741.534V120.852H778.214V143.384Z" fill="#212278"/>-<path d="M876.28 142.074C880.996 135.087 887.458 129.411 895.668 125.044C904.052 120.677 913.571 118.494 924.226 118.494C936.627 118.494 947.806 121.551 957.762 127.664C967.892 133.777 975.84 142.511 981.604 153.864C987.542 165.043 990.512 178.055 990.512 192.902C990.512 207.749 987.542 220.936 981.604 232.464C975.84 243.817 967.892 252.638 957.762 258.926C947.806 265.214 936.627 268.358 924.226 268.358C913.396 268.358 903.877 266.262 895.668 262.07C887.633 257.703 881.17 252.114 876.28 245.302V266H839.6V72.12H876.28V142.074ZM953.046 192.902C953.046 184.169 951.212 176.658 947.544 170.37C944.05 163.907 939.334 159.017 933.396 155.698C927.632 152.379 921.344 150.72 914.532 150.72C907.894 150.72 901.606 152.467 895.668 155.96C889.904 159.279 885.188 164.169 881.52 170.632C878.026 177.095 876.28 184.693 876.28 193.426C876.28 202.159 878.026 209.757 881.52 216.22C885.188 222.683 889.904 227.661 895.668 231.154C901.606 234.473 907.894 236.132 914.532 236.132C921.344 236.132 927.632 234.385 933.396 230.892C939.334 227.399 944.05 222.421 947.544 215.958C951.212 209.495 953.046 201.81 953.046 192.902Z" fill="#212278"/>-<path d="M1073.76 268.358C1059.78 268.358 1047.21 265.301 1036.03 259.188C1024.85 252.9 1016.03 244.079 1009.57 232.726C1003.28 221.373 1000.14 208.273 1000.14 193.426C1000.14 178.579 1003.37 165.479 1009.83 154.126C1016.47 142.773 1025.46 134.039 1036.82 127.926C1048.17 121.638 1060.83 118.494 1074.81 118.494C1088.78 118.494 1101.44 121.638 1112.8 127.926C1124.15 134.039 1133.06 142.773 1139.52 154.126C1146.16 165.479 1149.48 178.579 1149.48 193.426C1149.48 208.273 1146.07 221.373 1139.26 232.726C1132.62 244.079 1123.54 252.9 1112.01 259.188C1100.66 265.301 1087.91 268.358 1073.76 268.358ZM1073.76 236.394C1080.4 236.394 1086.6 234.822 1092.36 231.678C1098.3 228.359 1103.01 223.469 1106.51 217.006C1110 210.543 1111.75 202.683 1111.75 193.426C1111.75 179.627 1108.08 169.06 1100.74 161.724C1093.58 154.213 1084.76 150.458 1074.28 150.458C1063.8 150.458 1054.98 154.213 1047.82 161.724C1040.83 169.06 1037.34 179.627 1037.34 193.426C1037.34 207.225 1040.75 217.879 1047.56 225.39C1054.54 232.726 1063.28 236.394 1073.76 236.394Z" fill="#212278"/>-<path d="M1248.96 118.756C1266.25 118.756 1280.22 124.258 1290.88 135.262C1301.53 146.091 1306.86 161.287 1306.86 180.85V266H1270.18V185.828C1270.18 174.3 1267.3 165.479 1261.53 159.366C1255.77 153.078 1247.91 149.934 1237.95 149.934C1227.82 149.934 1219.79 153.078 1213.85 159.366C1208.08 165.479 1205.2 174.3 1205.2 185.828V266H1168.52V120.852H1205.2V138.93C1210.09 132.642 1216.29 127.751 1223.8 124.258C1231.49 120.59 1239.87 118.756 1248.96 118.756Z" fill="#212278"/>-<path d="M181.165 139.644V69.822L241.346 35.0571L241.054 104.879L181.165 139.644Z" fill="#60FFD2"/>-<path d="M181.165 69.822V139.644L120.4 104.879V35.0571L181.165 69.822Z" fill="#36B5B4"/>-<path d="M120.4 35.0571L181.165 69.822L241.346 35.0571L181.165 0L120.4 35.0571Z" fill="#5FE4D2"/>-<path d="M240.818 244.173V174.351L300.999 139.586L300.707 209.408L240.818 244.173Z" fill="#71DEFF"/>-<path d="M240.818 174.351V244.173L180.052 209.408V139.586L240.818 174.351Z" fill="#3877C5"/>-<path d="M180.052 139.586L240.818 174.351L300.999 139.586L240.818 104.529L180.052 139.586Z" fill="#4EAADE"/>-<path d="M121.512 244.173V174.351L181.693 139.586L181.401 209.408L121.512 244.173Z" fill="#71DEFF"/>-<path d="M121.512 174.351V244.173L60.7466 209.408V139.586L121.512 174.351Z" fill="#3877C5"/>-<path d="M60.7466 139.586L121.512 174.351L181.693 139.586L121.512 104.529L60.7466 139.586Z" fill="#4EAADE"/>-<path d="M181.165 348.702V278.88L241.346 244.115L241.054 313.937L181.165 348.702Z" fill="#7D7FE5"/>-<path d="M181.165 278.88V348.702L120.4 313.937V244.115L181.165 278.88Z" fill="#2F31AE"/>-<path d="M120.4 244.115L181.165 278.88L241.346 244.115L181.165 209.057L120.4 244.115Z" fill="#6041D0"/>-<path d="M60.7652 348.702V278.88L120.947 244.115L120.654 313.937L60.7652 348.702Z" fill="#7D7FE5"/>-<path d="M60.7652 278.88V348.702L-1.52588e-05 313.937V244.115L60.7652 278.88Z" fill="#2F31AE"/>-<path d="M-1.52588e-05 244.115L60.7652 278.88L120.947 244.115L60.7656 209.057L-1.52588e-05 244.115Z" fill="#6041D0"/>-<path d="M301.017 348.702V278.88L361.198 244.115L360.906 313.937L301.017 348.702Z" fill="#7D7FE5"/>-<path d="M301.017 278.88V348.702L240.252 313.937V244.115L301.017 278.88Z" fill="#2F31AE"/>-<path d="M240.252 244.115L301.017 278.88L361.198 244.115L301.018 209.057L240.252 244.115Z" fill="#6041D0"/>+<svg width="720" height="175" viewBox="0 0 720 175" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M64.2993 3.57443C72.343 -1.19144 82.3494 -1.19151 90.3931 3.57443L142.163 34.2484C149.93 38.8505 154.692 47.2038 154.692 56.2254V118.775C154.692 127.796 149.93 136.149 142.163 140.752L90.3931 171.426C82.3494 176.192 72.343 176.191 64.2993 171.426L12.5296 140.752C4.76242 136.149 0 127.796 0 118.775V56.2254C0 47.2037 4.76242 38.8505 12.5296 34.2484L64.2993 3.57443ZM81.004 40.286C78.8708 39.0012 76.2016 38.9983 74.0657 40.2786L42.6851 59.0884C38.3192 61.7055 38.3303 68.0312 42.7057 70.6326L74.173 89.3408C74.3089 89.4216 74.3921 89.5681 74.3921 89.726V126.818C74.3922 132.04 80.0912 135.269 84.5774 132.589L115.594 114.057C117.626 112.843 118.87 110.652 118.87 108.287V66.8923C118.87 64.5357 117.635 62.3509 115.615 61.134L81.004 40.286Z" fill="#101A24"/>+<path d="M236.385 133.457C229.22 133.457 222.857 132.223 217.298 129.754C211.862 127.163 207.291 123.645 203.584 119.202C200.002 114.635 197.284 109.513 195.431 103.836C193.577 98.1581 192.651 92.2338 192.651 86.0626C192.651 79.8914 193.577 73.9671 195.431 68.2897C197.284 62.6122 200.002 57.5518 203.584 53.1086C207.291 48.6654 211.862 45.2095 217.298 42.741C222.857 40.1492 229.22 38.8532 236.385 38.8532C245.404 38.8532 253.249 41.0131 259.921 45.3329C266.716 49.6528 271.719 56.3176 274.931 65.3275L256.77 72.3626C255.288 67.6725 252.879 63.9081 249.543 61.0694C246.207 58.1072 241.821 56.6262 236.385 56.6262C230.95 56.6262 226.502 58.0455 223.043 60.8843C219.707 63.723 217.236 67.364 215.63 71.8072C214.024 76.2505 213.221 81.0023 213.221 86.0626C213.221 91.123 214.024 95.9365 215.63 100.503C217.236 104.946 219.707 108.587 223.043 111.426C226.502 114.141 230.95 115.499 236.385 115.499C241.821 115.499 246.207 114.08 249.543 111.241C252.879 108.402 255.288 104.638 256.77 99.9477L274.931 106.983C271.719 115.869 266.716 122.534 259.921 126.977C253.249 131.297 245.404 133.457 236.385 133.457Z" fill="#101A24"/>+<path d="M343.217 131.791L341.735 116.425V74.214C341.735 68.2897 339.943 63.8464 336.361 60.8843C332.778 57.7987 327.774 56.2559 321.35 56.2559C316.408 56.2559 311.528 57.2433 306.71 59.218C302.015 61.0694 297.691 63.9698 293.738 67.9194L282.248 54.4045C288.178 48.8505 294.479 44.901 301.151 42.5559C307.822 40.0874 315.111 38.8532 323.018 38.8532C335.372 38.8532 344.947 42.0005 351.742 48.2951C358.66 54.4663 362.12 63.1059 362.12 74.214V131.791H343.217ZM314.864 133.457C308.069 133.457 302.015 132.223 296.703 129.754C291.514 127.286 287.437 123.83 284.472 119.387C281.631 114.944 280.21 109.76 280.21 103.836C280.21 98.7752 281.26 94.3937 283.36 90.691C285.584 86.9883 288.426 84.0878 291.885 81.9896C294.85 80.1383 298.309 78.8423 302.262 78.1018C306.216 77.2378 310.355 76.8059 314.679 76.8059H343.403V92.1721H317.644C315.42 92.1721 313.196 92.4189 310.972 92.9126C308.749 93.2829 306.772 94.0234 305.042 95.1342C303.807 96.1216 302.757 97.3558 301.892 98.8369C301.151 100.318 300.78 102.046 300.78 104.021C300.78 107.97 302.262 111.118 305.228 113.463C308.316 115.684 312.393 116.795 317.458 116.795C321.906 116.795 325.921 115.808 329.504 113.833C333.21 111.858 336.175 109.143 338.399 105.687C340.623 102.231 341.735 98.3432 341.735 94.0234L348.036 104.206C346.553 110.624 344.206 116.054 340.994 120.498C337.781 124.818 333.952 128.088 329.504 130.31C325.056 132.408 320.176 133.457 314.864 133.457Z" fill="#101A24"/>+<path d="M375.823 131.791V40.5194H396.578V65.1424L392.687 65.6978C393.304 60.3906 395.096 55.7622 398.061 51.8127C401.026 47.7397 404.609 44.5924 408.809 42.3708C413.133 40.0257 417.395 38.8532 421.596 38.8532C424.561 38.8532 427.403 39.2235 430.121 39.964C432.839 40.7046 435.68 41.9388 438.645 43.6667L428.638 62.1802C427.279 61.3162 425.488 60.6374 423.264 60.1437C421.164 59.5266 419.125 59.218 417.148 59.218C414.554 59.218 411.96 59.7117 409.365 60.6991C406.894 61.6865 404.67 63.2293 402.694 65.3275C400.717 67.3023 399.234 69.8942 398.246 73.1032C397.628 74.8311 397.134 77.1144 396.764 79.9532C396.517 82.6685 396.393 86.4946 396.393 91.4315V131.791H375.823Z" fill="#101A24"/>+<path d="M492.002 133.457C487.06 133.457 482.365 132.47 477.918 130.495C473.594 128.52 469.825 125.496 466.613 121.423C463.401 117.227 460.992 111.796 459.386 105.132L464.76 106.427V131.791H444.375V2.75192H464.76V66.068H460.127C461.363 60.2672 463.463 55.3919 466.428 51.4424C469.517 47.3694 473.223 44.2838 477.547 42.1856C481.995 39.964 486.813 38.8532 492.002 38.8532C499.414 38.8532 506.086 40.7663 512.016 44.5924C518.069 48.2951 522.888 53.664 526.47 60.6991C530.053 67.7343 531.845 76.1887 531.845 86.0626C531.845 95.0725 530.177 103.157 526.841 110.315C523.629 117.474 519.058 123.151 513.128 127.348C507.198 131.421 500.156 133.457 492.002 133.457ZM486.998 114.573C491.816 114.573 496.017 113.401 499.6 111.056C503.306 108.711 506.147 105.378 508.124 101.059C510.101 96.7387 511.089 91.7401 511.089 86.0626C511.089 80.3851 510.101 75.3865 508.124 71.0667C506.147 66.7469 503.306 63.4144 499.6 61.0694C496.017 58.7244 491.816 57.5518 486.998 57.5518C482.18 57.5518 477.918 58.7861 474.211 61.2545C470.629 63.5996 467.849 66.932 465.872 71.2518C463.895 75.4482 462.907 80.3851 462.907 86.0626C462.907 91.7401 463.895 96.7387 465.872 101.059C467.849 105.378 470.629 108.711 474.211 111.056C477.918 113.401 482.18 114.573 486.998 114.573Z" fill="#101A24"/>+<path d="M583.567 133.457C574.919 133.457 567.135 131.421 560.217 127.348C553.298 123.275 547.862 117.659 543.909 110.5C540.079 103.342 538.164 95.1959 538.164 86.0626C538.164 76.9293 540.079 68.7834 543.909 61.6248C547.862 54.4663 553.237 48.9122 560.032 44.9627C566.95 40.8897 574.795 38.8532 583.567 38.8532C592.462 38.8532 600.245 40.8897 606.917 44.9627C613.711 48.9122 619.086 54.4663 623.039 61.6248C626.992 68.7834 628.969 76.9293 628.969 86.0626C628.969 95.1959 626.992 103.342 623.039 110.5C619.209 117.659 613.835 123.275 606.917 127.348C600.122 131.421 592.338 133.457 583.567 133.457ZM583.752 115.314C588.817 115.314 593.203 114.141 596.909 111.796C600.616 109.451 603.457 106.057 605.434 101.614C607.411 97.1707 608.399 91.9869 608.399 86.0626C608.399 80.0149 607.411 74.8311 605.434 70.5113C603.457 66.068 600.616 62.6739 596.909 60.3289C593.203 57.9838 588.817 56.8113 583.752 56.8113C578.44 56.8113 573.93 58.0455 570.224 60.514C566.518 62.859 563.676 66.1915 561.699 70.5113C559.723 74.8311 558.734 80.0149 558.734 86.0626C558.734 91.9869 559.723 97.1707 561.699 101.614C563.676 106.057 566.518 109.451 570.224 111.796C573.93 114.141 578.44 115.314 583.752 115.314Z" fill="#101A24"/>+<path d="M639.573 131.791V40.5194H660.143V60.6991L656.437 61.6248C658.043 56.3176 660.39 51.9978 663.479 48.6654C666.567 45.3329 670.15 42.8645 674.227 41.26C678.427 39.6555 682.813 38.8532 687.384 38.8532C697.639 38.8532 705.607 41.8154 711.29 47.7397C717.097 53.5406 720 61.8716 720 72.7329V131.791H699.43V80.3234C699.43 72.1775 697.947 66.1915 694.982 62.3653C692.017 58.5392 687.446 56.6262 681.269 56.6262C676.698 56.6262 672.806 57.737 669.594 59.9586C666.505 62.0568 664.158 65.3892 662.552 69.9559C660.946 74.5225 660.143 80.3234 660.143 87.3585V131.791H639.573Z" fill="#101A24"/></svg>diff --git a/examples/upload-3d-model/public/favicon-16x16.png b/examples/upload-3d-model/public/favicon-16x16.pngindex eb216e453f..7f08a7eae3 100644Binary files a/examples/upload-3d-model/public/favicon-16x16.png and b/examples/upload-3d-model/public/favicon-16x16.png differdiff --git a/examples/upload-3d-model/public/favicon-32x32.png b/examples/upload-3d-model/public/favicon-32x32.pngindex a7064d2122..348b196709 100644Binary files a/examples/upload-3d-model/public/favicon-32x32.png and b/examples/upload-3d-model/public/favicon-32x32.png differdiff --git a/examples/upload-3d-model/public/favicon-96x96.png b/examples/upload-3d-model/public/favicon-96x96.pngdeleted file mode 100644index c36c27be04..0000000000Binary files a/examples/upload-3d-model/public/favicon-96x96.png and /dev/null differdiff --git a/examples/upload-3d-model/public/favicon.ico b/examples/upload-3d-model/public/favicon.icoindex a87e92b575..644a0d8ed5 100644Binary files a/examples/upload-3d-model/public/favicon.ico and b/examples/upload-3d-model/public/favicon.ico differdiff --git a/examples/upload-3d-model/public/favicon.svg b/examples/upload-3d-model/public/favicon.svgindex 1f953c23a1..047b926154 100644--- a/examples/upload-3d-model/public/favicon.svg+++ b/examples/upload-3d-model/public/favicon.svg@@ -1,22 +1,3 @@-<svg xmlns="http://www.w3.org/2000/svg" version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink" width="362" height="349"><svg width="362" height="349" viewBox="0 0 362 349" fill="none" xmlns="http://www.w3.org/2000/svg">-<path d="M181.165 139.643V69.8213L241.346 35.0564L241.054 104.878L181.165 139.643Z" fill="#60FFD2"></path>-<path d="M181.165 69.8213V139.643L120.4 104.878V35.0564L181.165 69.8213Z" fill="#36B5B4"></path>-<path d="M120.4 35.0565L181.165 69.8214L241.347 35.0565L181.165 -0.000610352L120.4 35.0565Z" fill="#5FE4D2"></path>-<path d="M240.818 244.172V174.35L300.999 139.585L300.707 209.407L240.818 244.172Z" fill="#71DEFF"></path>-<path d="M240.818 174.35V244.172L180.052 209.407V139.585L240.818 174.35Z" fill="#3877C5"></path>-<path d="M180.052 139.586L240.818 174.35L300.999 139.586L240.818 104.528L180.052 139.586Z" fill="#4EAADE"></path>-<path d="M121.512 244.172V174.35L181.693 139.585L181.401 209.407L121.512 244.172Z" fill="#71DEFF"></path>-<path d="M121.512 174.35V244.172L60.7466 209.407V139.585L121.512 174.35Z" fill="#3877C5"></path>-<path d="M60.7466 139.586L121.512 174.35L181.694 139.586L121.512 104.528L60.7466 139.586Z" fill="#4EAADE"></path>-<path d="M181.165 348.701V278.879L241.346 244.114L241.054 313.936L181.165 348.701Z" fill="#7D7FE5"></path>-<path d="M181.165 278.879V348.701L120.4 313.936V244.114L181.165 278.879Z" fill="#2F31AE"></path>-<path d="M120.4 244.114L181.165 278.879L241.347 244.114L181.165 209.057L120.4 244.114Z" fill="#6041D0"></path>-<path d="M60.7651 348.701V278.879L120.946 244.114L120.654 313.936L60.7651 348.701Z" fill="#7D7FE5"></path>-<path d="M60.7656 278.879V348.701L0 313.936V244.114L60.7656 278.879Z" fill="#2F31AE"></path>-<path d="M0 244.114L60.7656 278.879L120.947 244.114L60.7656 209.057L0 244.114Z" fill="#6041D0"></path>-<path d="M301.017 348.701V278.879L361.198 244.114L360.906 313.936L301.017 348.701Z" fill="#7D7FE5"></path>-<path d="M301.018 278.879V348.701L240.252 313.936V244.114L301.018 278.879Z" fill="#2F31AE"></path>-<path d="M240.252 244.114L301.018 278.879L361.199 244.114L301.018 209.057L240.252 244.114Z" fill="#6041D0"></path>-</svg><style>@media (prefers-color-scheme: light) { :root { filter: none; } }-@media (prefers-color-scheme: dark) { :root { filter: none; } }-</style></svg>\ No newline at end of file+<svg width="424" height="480" viewBox="0 0 424 480" fill="none" xmlns="http://www.w3.org/2000/svg">+<path fill-rule="evenodd" clip-rule="evenodd" d="M176.24 9.80407C198.287 -3.26801 225.714 -3.26803 247.761 9.80407L389.658 93.9389C410.947 106.562 424 129.472 424 154.217V325.783C424 350.528 410.947 373.439 389.658 386.062L247.761 470.196C225.714 483.268 198.287 483.268 176.24 470.196L34.3432 386.062C13.0539 373.439 0.000129963 350.528 0 325.783V154.217C0.000219136 129.472 13.054 106.562 34.3432 93.9389L176.24 9.80407ZM224.561 112.025C217.155 107.562 207.886 107.551 200.471 111.999L124.056 157.836C108.898 166.929 108.938 188.904 124.128 197.943L200.899 243.618C202.762 244.727 203.903 246.734 203.903 248.901V339.17C203.903 357.314 223.69 368.532 239.265 359.22L314.442 314.275C321.496 310.057 325.815 302.443 325.815 294.225V186.253C325.815 178.065 321.527 170.474 314.514 166.246L224.561 112.025Z" fill="#E6E6E6"/>+</svg>diff --git a/examples/upload-3d-model/public/site copy.webmanifest b/examples/upload-3d-model/public/site copy.webmanifestnew file mode 100644index 0000000000..4e209ea8a1--- /dev/null+++ b/examples/upload-3d-model/public/site copy.webmanifest@@ -0,0 +1,19 @@+{+ "name": "Carbon",+ "short_name": "Carbon",+ "icons": [+ {+ "src": "/android-chrome-192x192.png",+ "sizes": "192x192",+ "type": "image/png"+ },+ {+ "src": "/android-chrome-512x512.png",+ "sizes": "512x512",+ "type": "image/png"+ }+ ],+ "theme_color": "#ffffff",+ "background_color": "#ffffff",+ "display": "standalone"+}diff --git a/examples/upload-3d-model/public/site.webmanifest b/examples/upload-3d-model/public/site.webmanifestindex aa6777552f..4ec775aaef 100644--- a/examples/upload-3d-model/public/site.webmanifest+++ b/examples/upload-3d-model/public/site.webmanifest@@ -1,21 +1,19 @@{- "name": "Carbon",- "short_name": "Carbon",+ "name": "Carbon ERP",+ "short_name": "ERP","icons": [{- "src": "/web-app-manifest-192x192.png",+ "src": "/android-chrome-192x192.png","sizes": "192x192",- "type": "image/png",- "purpose": "maskable"+ "type": "image/png"},{- "src": "/web-app-manifest-512x512.png",+ "src": "/android-chrome-512x512.png","sizes": "512x512",- "type": "image/png",- "purpose": "maskable"+ "type": "image/png"}],- "theme_color": "#000000",- "background_color": "#000000",+ "theme_color": "#ffffff",+ "background_color": "#ffffff","display": "standalone"}diff --git a/examples/upload-3d-model/public/web-app-manifest-192x192.png b/examples/upload-3d-model/public/web-app-manifest-192x192.pngdeleted file mode 100644index cda38d5ed4..0000000000Binary files a/examples/upload-3d-model/public/web-app-manifest-192x192.png and /dev/null differdiff --git a/examples/upload-3d-model/public/web-app-manifest-512x512.png b/examples/upload-3d-model/public/web-app-manifest-512x512.pngdeleted file mode 100644index 88c30a090e..0000000000Binary files a/examples/upload-3d-model/public/web-app-manifest-512x512.png and /dev/null differdiff --git a/llm/cache/fixed-asset-lifecycle.md b/llm/cache/fixed-asset-lifecycle.mdnew file mode 100644index 0000000000..bd7d5fd47d--- /dev/null+++ b/llm/cache/fixed-asset-lifecycle.md@@ -0,0 +1,47 @@+# Fixed Asset Lifecycle System++## Overview++Fixed assets can be acquired, tracked, depreciated, and disposed through the ERP system. They integrate with purchasing (acquisition), sales (disposal), and accounting (GL entries).++## Database Tables++- `fixedAsset` — Master record: status (Draft/Active/Fully Depreciated/Disposed), acquisitionCost, accumulatedDepreciation, disposalDate, disposalMethod (Sale/Scrapping), saleProceeds+- `fixedAssetClass` — Classification with GL accounts: assetAccountId, accumulatedDepreciationAccountId, depreciationExpenseAccountId, writeOffAccountId, writeDownAccountId, disposalAccountId+- `fixedAssetDisposal` — Disposal record: netBookValueAtDisposal, gainLoss, saleProceeds, journalId++## Line Type Integration++SO lines (`salesOrderLineType`), SI lines (`invoiceLineType`), PO lines (`purchaseOrderLineType`), PI lines (`invoiceLineType`) all support "Fixed Asset" as a line type with an `assetId` foreign key.++### Views++The `salesOrderLines`, `salesInvoiceLines`, `purchaseOrderLines`, `purchaseInvoiceLines` views join to fixedAsset to expose `assetReadableId` and `assetName`. Since TS types may not be regenerated, access via `(line as any).assetReadableId`.++## Acquisition Path (Draft → Active)++1. **Via Receipt Posting** (`post-receipt` edge function): When a PO receipt with a Fixed Asset line is posted, the asset's acquisitionCost is incremented, acquisitionDate and depreciationStartDate are set (if not already), and status changes from Draft to Active.++2. **Via Purchase Invoice Posting** (`post-purchase-invoice` edge function): Same activation logic for the no-PO path. GL: Debit asset class's assetAccountId, Credit payablesAccount.++## Disposal Path (Active/Fully Depreciated → Disposed)++1. **Manual Disposal** (`$fixedAssetId.dispose.tsx`): Creates journal entries to clear accumulated depreciation, write off NBV, and remove asset at cost. Creates fixedAssetDisposal record.++2. **Via Shipment Posting** (`post-shipment` edge function): When a shipment with a Fixed Asset SO line is posted, the asset is disposed. GL entries mirror manual disposal. Skips item ledger and COGS entries.++3. **Via Sales Invoice Posting** (`post-sales-invoice` edge function): For the no-SO path. Disposes asset AND creates AR/revenue entries for sale proceeds. Records saleProceeds and gainLoss on fixedAssetDisposal.++## Form Pattern++SO and SI line forms use a Tabs pattern (Item/Asset tabs) mirroring the PO line form. The asset tab shows a Combobox to select assets with status Active or Fully Depreciated. Hidden fields carry `salesOrderLineType="Fixed Asset"` and description across tab switches.++## Key Files++- Forms: `SalesOrderLineForm.tsx`, `SalesInvoiceLineForm.tsx`, `PurchaseOrderLineForm.tsx`+- Validators: `sales.models.ts` (salesOrderLineValidator), `invoicing.models.ts` (salesInvoiceLineValidator)+- Edge functions: `post-receipt/index.ts`, `post-purchase-invoice/index.ts`, `post-shipment/index.ts`, `post-sales-invoice/index.ts`+- PDF utils: `packages/documents/src/utils/sales-order.ts`, `sales-invoice.ts`+- Explorers: `SalesOrderExplorer.tsx`, `SalesInvoiceExplorer.tsx`+- Summaries: `SalesOrderSummary.tsx`, `SalesInvoiceSummary.tsx`+- Detail page: `$fixedAssetId.tsx` (Actions dropdown with state-aware Purchase/Sell/Dispose links)diff --git a/packages/database/src/audit.config.ts b/packages/database/src/audit.config.tsindex 869c9014b9..c6630a31f0 100644--- a/packages/database/src/audit.config.ts+++ b/packages/database/src/audit.config.ts@@ -394,6 +394,13 @@ export const auditConfig = {createFields: ["quantity", "overridePrice", "active"]}}+ },++ fixedAsset: {+ label: "Fixed Asset",+ tables: {+ fixedAsset: { role: "root" }+ }}} satisfies Record<string, EntityConfig>,@@ -467,7 +474,8 @@ export const auditConfig = {maintenanceDispatchComment: "Dispatch Comment",pricingRule: "Pricing Rule",customerItemPriceOverride: "Price Override",- customerItemPriceOverrideBreak: "Quantity Break"+ customerItemPriceOverrideBreak: "Quantity Break",+ fixedAsset: "Fixed Asset"} satisfies Partial<Record<TableName, string>>,/** Fields to skip in diff computation */diff --git a/packages/database/src/seed-dev.ts b/packages/database/src/seed-dev.tsindex ce6c3099f0..1059311ed4 100644--- a/packages/database/src/seed-dev.ts+++ b/packages/database/src/seed-dev.ts@@ -21,6 +21,7 @@ import {dimensions,failureModes,fiscalYearSettings,+ fixedAssetClasses,gaugeTypes,getGroupId,groups,@@ -481,6 +482,32 @@ async function seedDev() {]);+ // Seed fixed asset classes+ for (const fac of fixedAssetClasses) {+ await client.query(+ `INSERT INTO "fixedAssetClass" (+ "name", "depreciationMethod", "usefulLifeMonths", "residualValuePercent",+ "assetAccountId", "accumulatedDepreciationAccountId",+ "depreciationExpenseAccountId", "writeOffAccountId",+ "writeDownAccountId", "disposalAccountId",+ "companyId", "createdBy"+ ) VALUES ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11, 'system')`,+ [+ fac.name,+ fac.depreciationMethod,+ fac.usefulLifeMonths,+ fac.residualValuePercent,+ accountIdByKey[fac.assetAccount],+ accountIdByKey[fac.accumulatedDepreciationAccount],+ accountIdByKey[fac.depreciationExpenseAccount],+ accountIdByKey[fac.writeOffAccount],+ accountIdByKey[fac.writeDownAccount],+ accountIdByKey[fac.disposalAccount],+ companyId+ ]+ );+ }+// Seed default location (required for inventory, jobs, etc.)// Must be after accountDefaults since location trigger copies from accountDefaultsconst locationResult = await client.query(diff --git a/packages/database/src/types.ts b/packages/database/src/types.tsindex e42609ed29..311514d124 100644--- a/packages/database/src/types.ts+++ b/packages/database/src/types.ts@@ -342,6 +342,8 @@ export type Database = {costOfGoodsSoldAccount: stringcurrencyTranslationAccount: stringcustomerPaymentDiscountAccount: string+ deferredTaxExpenseAccountId: string | null+ deferredTaxLiabilityAccountId: string | nullgoodsReceivedNotInvoicedAccount: stringindirectCostAccount: stringinterestAccount: string@@ -385,6 +387,8 @@ export type Database = {costOfGoodsSoldAccount: stringcurrencyTranslationAccount: stringcustomerPaymentDiscountAccount: string+ deferredTaxExpenseAccountId?: string | null+ deferredTaxLiabilityAccountId?: string | nullgoodsReceivedNotInvoicedAccount: stringindirectCostAccount: stringinterestAccount: string@@ -428,6 +432,8 @@ export type Database = {costOfGoodsSoldAccount?: stringcurrencyTranslationAccount?: stringcustomerPaymentDiscountAccount?: string+ deferredTaxExpenseAccountId?: string | null+ deferredTaxLiabilityAccountId?: string | nullgoodsReceivedNotInvoicedAccount?: stringindirectCostAccount?: stringinterestAccount?: string@@ -626,6 +632,34 @@ export type Database = {referencedRelation: "accounts"referencedColumns: ["id"]},+ {+ foreignKeyName: "accountDefault_deferredTaxExpenseAccountId_fkey"+ columns: ["deferredTaxExpenseAccountId"]+ isOneToOne: false+ referencedRelation: "account"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "accountDefault_deferredTaxExpenseAccountId_fkey"+ columns: ["deferredTaxExpenseAccountId"]+ isOneToOne: false+ referencedRelation: "accounts"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "accountDefault_deferredTaxLiabilityAccountId_fkey"+ columns: ["deferredTaxLiabilityAccountId"]+ isOneToOne: false+ referencedRelation: "account"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "accountDefault_deferredTaxLiabilityAccountId_fkey"+ columns: ["deferredTaxLiabilityAccountId"]+ isOneToOne: false+ referencedRelation: "accounts"+ referencedColumns: ["id"]+ },{foreignKeyName: "accountDefault_fkey"columns: ["companyId"]@@ -2832,6 +2866,8 @@ export type Database = {accountsPayableEmail: string | nullaccountsReceivableAddress: boolean | nullaccountsReceivableEmail: string | null+ assetTaxDepreciationEnabled: boolean+ assetTaxRate: number | nullconsoleEnabled: booleandefaultCustomerCc: string[] | nulldefaultSupplierCc: string[] | null@@ -2873,6 +2909,8 @@ export type Database = {accountsPayableEmail?: string | nullaccountsReceivableAddress?: boolean | nullaccountsReceivableEmail?: string | null+ assetTaxDepreciationEnabled?: boolean+ assetTaxRate?: number | nullconsoleEnabled?: booleandefaultCustomerCc?: string[] | nulldefaultSupplierCc?: string[] | null@@ -2914,6 +2952,8 @@ export type Database = {accountsPayableEmail?: string | nullaccountsReceivableAddress?: boolean | nullaccountsReceivableEmail?: string | null+ assetTaxDepreciationEnabled?: boolean+ assetTaxRate?: number | nullconsoleEnabled?: booleandefaultCustomerCc?: string[] | nulldefaultSupplierCc?: string[] | null@@ -7582,6 +7622,228 @@ export type Database = {},]}+ depreciationRun: {+ Row: {+ companyId: string+ createdAt: string+ createdBy: string+ depreciationRunId: string+ id: string+ periodEnd: string+ postedAt: string | null+ postedBy: string | null+ status: string+ }+ Insert: {+ companyId: string+ createdAt?: string+ createdBy: string+ depreciationRunId: string+ id?: string+ periodEnd: string+ postedAt?: string | null+ postedBy?: string | null+ status?: string+ }+ Update: {+ companyId?: string+ createdAt?: string+ createdBy?: string+ depreciationRunId?: string+ id?: string+ periodEnd?: string+ postedAt?: string | null+ postedBy?: string | null+ status?: string+ }+ Relationships: [+ {+ foreignKeyName: "depreciationRun_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "companies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "company"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "customFieldTables"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "depreciationRun_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "integrations"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "depreciationRun_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ {+ foreignKeyName: "depreciationRun_postedBy_fkey"+ columns: ["postedBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_postedBy_fkey"+ columns: ["postedBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_postedBy_fkey"+ columns: ["postedBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_postedBy_fkey"+ columns: ["postedBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_postedBy_fkey"+ columns: ["postedBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ ]+ }+ depreciationRunLine: {+ Row: {+ amount: number+ companyId: string+ depreciationRunId: string+ fixedAssetId: string+ id: string+ journalId: string | null+ taxAmount: number | null+ }+ Insert: {+ amount: number+ companyId: string+ depreciationRunId: string+ fixedAssetId: string+ id?: string+ journalId?: string | null+ taxAmount?: number | null+ }+ Update: {+ amount?: number+ companyId?: string+ depreciationRunId?: string+ fixedAssetId?: string+ id?: string+ journalId?: string | null+ taxAmount?: number | null+ }+ Relationships: [+ {+ foreignKeyName: "depreciationRunLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "companies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRunLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "company"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRunLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "customFieldTables"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "depreciationRunLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "integrations"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "depreciationRunLine_depreciationRunId_fkey"+ columns: ["depreciationRunId"]+ isOneToOne: false+ referencedRelation: "depreciationRun"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRunLine_fixedAssetId_fkey"+ columns: ["fixedAssetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRunLine_journalId_fkey"+ columns: ["journalId"]+ isOneToOne: false+ referencedRelation: "journal"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRunLine_journalId_fkey"+ columns: ["journalId"]+ isOneToOne: false+ referencedRelation: "journalEntries"+ referencedColumns: ["id"]+ },+ ]+ }dimension: {Row: {active: boolean@@ -9207,6 +9469,754 @@ export type Database = {},]}+ fixedAsset: {+ Row: {+ accumulatedDepreciation: number+ accumulatedTaxDepreciation: number+ acquisitionCost: number+ acquisitionDate: string | null+ assetLifetimeUsage: number | null+ bonusDepreciationPercent: number | null+ companyId: string+ createdAt: string+ createdBy: string+ customFields: Json | null+ depreciationMethod: Database["public"]["Enums"]["depreciationMethod"]+ depreciationStartDate: string | null+ description: string | null+ disposalDate: string | null+ disposalMethod: Database["public"]["Enums"]["disposalMethod"] | null+ fixedAssetClassId: string+ fixedAssetId: string+ id: string+ locationId: string | null+ macrsConvention: Database["public"]["Enums"]["macrsConvention"] | null+ macrsPropertyClass:+ | Database["public"]["Enums"]["macrsPropertyClass"]+ | null+ name: string+ notes: Json | null+ residualValuePercent: number+ saleProceeds: number | null+ serialNumber: string | null+ status: Database["public"]["Enums"]["fixedAssetStatus"]+ taxDepreciationMethod:+ | Database["public"]["Enums"]["taxDepreciationMethod"]+ | null+ taxResidualValuePercent: number | null+ taxUsefulLifeMonths: number | null+ updatedAt: string | null+ updatedBy: string | null+ usefulLifeMonths: number+ }+ Insert: {+ accumulatedDepreciation?: number+ accumulatedTaxDepreciation?: number+ acquisitionCost?: number+ acquisitionDate?: string | null+ assetLifetimeUsage?: number | null+ bonusDepreciationPercent?: number | null+ companyId: string+ createdAt?: string+ createdBy: string+ customFields?: Json | null+ depreciationMethod?: Database["public"]["Enums"]["depreciationMethod"]+ depreciationStartDate?: string | null+ description?: string | null+ disposalDate?: string | null+ disposalMethod?: Database["public"]["Enums"]["disposalMethod"] | null+ fixedAssetClassId: string+ fixedAssetId: string+ id?: string+ locationId?: string | null+ macrsConvention?:+ | Database["public"]["Enums"]["macrsConvention"]+ | null+ macrsPropertyClass?:+ | Database["public"]["Enums"]["macrsPropertyClass"]+ | null+ name: string+ notes?: Json | null+ residualValuePercent?: number+ saleProceeds?: number | null+ serialNumber?: string | null+ status?: Database["public"]["Enums"]["fixedAssetStatus"]+ taxDepreciationMethod?:+ | Database["public"]["Enums"]["taxDepreciationMethod"]+ | null+ taxResidualValuePercent?: number | null+ taxUsefulLifeMonths?: number | null+ updatedAt?: string | null+ updatedBy?: string | null+ usefulLifeMonths?: number+ }+ Update: {+ accumulatedDepreciation?: number+ accumulatedTaxDepreciation?: number+ acquisitionCost?: number+ acquisitionDate?: string | null+ assetLifetimeUsage?: number | null+ bonusDepreciationPercent?: number | null+ companyId?: string+ createdAt?: string+ createdBy?: string+ customFields?: Json | null+ depreciationMethod?: Database["public"]["Enums"]["depreciationMethod"]+ depreciationStartDate?: string | null+ description?: string | null+ disposalDate?: string | null+ disposalMethod?: Database["public"]["Enums"]["disposalMethod"] | null+ fixedAssetClassId?: string+ fixedAssetId?: string+ id?: string+ locationId?: string | null+ macrsConvention?:+ | Database["public"]["Enums"]["macrsConvention"]+ | null+ macrsPropertyClass?:+ | Database["public"]["Enums"]["macrsPropertyClass"]+ | null+ name?: string+ notes?: Json | null+ residualValuePercent?: number+ saleProceeds?: number | null+ serialNumber?: string | null+ status?: Database["public"]["Enums"]["fixedAssetStatus"]+ taxDepreciationMethod?:+ | Database["public"]["Enums"]["taxDepreciationMethod"]+ | null+ taxResidualValuePercent?: number | null+ taxUsefulLifeMonths?: number | null+ updatedAt?: string | null+ updatedBy?: string | null+ usefulLifeMonths?: number+ }+ Relationships: [+ {+ foreignKeyName: "fixedAsset_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "companies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "company"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "customFieldTables"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "fixedAsset_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "integrations"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "fixedAsset_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ {+ foreignKeyName: "fixedAsset_fixedAssetClassId_fkey"+ columns: ["fixedAssetClassId"]+ isOneToOne: false+ referencedRelation: "fixedAssetClass"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_locationId_fkey"+ columns: ["locationId"]+ isOneToOne: false+ referencedRelation: "location"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ ]+ }+ fixedAssetClass: {+ Row: {+ accumulatedDepreciationAccountId: string+ assetAccountId: string+ bonusDepreciationPercent: number | null+ companyId: string+ createdAt: string+ createdBy: string+ customFields: Json | null+ depreciationExpenseAccountId: string+ depreciationMethod: Database["public"]["Enums"]["depreciationMethod"]+ description: string | null+ disposalAccountId: string+ id: string+ macrsConvention: Database["public"]["Enums"]["macrsConvention"] | null+ macrsPropertyClass:+ | Database["public"]["Enums"]["macrsPropertyClass"]+ | null+ name: string+ residualValuePercent: number+ taxDepreciationMethod:+ | Database["public"]["Enums"]["taxDepreciationMethod"]+ | null+ taxResidualValuePercent: number | null+ taxUsefulLifeMonths: number | null+ updatedAt: string | null+ updatedBy: string | null+ usefulLifeMonths: number+ writeDownAccountId: string+ writeOffAccountId: string+ }+ Insert: {+ accumulatedDepreciationAccountId: string+ assetAccountId: string+ bonusDepreciationPercent?: number | null+ companyId: string+ createdAt?: string+ createdBy: string+ customFields?: Json | null+ depreciationExpenseAccountId: string+ depreciationMethod?: Database["public"]["Enums"]["depreciationMethod"]+ description?: string | null+ disposalAccountId: string+ id?: string+ macrsConvention?:+ | Database["public"]["Enums"]["macrsConvention"]+ | null+ macrsPropertyClass?:+ | Database["public"]["Enums"]["macrsPropertyClass"]+ | null+ name: string+ residualValuePercent?: number+ taxDepreciationMethod?:+ | Database["public"]["Enums"]["taxDepreciationMethod"]+ | null+ taxResidualValuePercent?: number | null+ taxUsefulLifeMonths?: number | null+ updatedAt?: string | null+ updatedBy?: string | null+ usefulLifeMonths?: number+ writeDownAccountId: string+ writeOffAccountId: string+ }+ Update: {+ accumulatedDepreciationAccountId?: string+ assetAccountId?: string+ bonusDepreciationPercent?: number | null+ companyId?: string+ createdAt?: string+ createdBy?: string+ customFields?: Json | null+ depreciationExpenseAccountId?: string+ depreciationMethod?: Database["public"]["Enums"]["depreciationMethod"]+ description?: string | null+ disposalAccountId?: string+ id?: string+ macrsConvention?:+ | Database["public"]["Enums"]["macrsConvention"]+ | null+ macrsPropertyClass?:+ | Database["public"]["Enums"]["macrsPropertyClass"]+ | null+ name?: string+ residualValuePercent?: number+ taxDepreciationMethod?:+ | Database["public"]["Enums"]["taxDepreciationMethod"]+ | null+ taxResidualValuePercent?: number | null+ taxUsefulLifeMonths?: number | null+ updatedAt?: string | null+ updatedBy?: string | null+ usefulLifeMonths?: number+ writeDownAccountId?: string+ writeOffAccountId?: string+ }+ Relationships: [+ {+ foreignKeyName: "fixedAssetClass_accumulatedDepreciationAccountId_fkey"+ columns: ["accumulatedDepreciationAccountId"]+ isOneToOne: false+ referencedRelation: "account"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_accumulatedDepreciationAccountId_fkey"+ columns: ["accumulatedDepreciationAccountId"]+ isOneToOne: false+ referencedRelation: "accounts"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_assetAccountId_fkey"+ columns: ["assetAccountId"]+ isOneToOne: false+ referencedRelation: "account"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_assetAccountId_fkey"+ columns: ["assetAccountId"]+ isOneToOne: false+ referencedRelation: "accounts"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "companies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "company"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "customFieldTables"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "fixedAssetClass_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "integrations"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "fixedAssetClass_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ {+ foreignKeyName: "fixedAssetClass_depreciationExpenseAccountId_fkey"+ columns: ["depreciationExpenseAccountId"]+ isOneToOne: false+ referencedRelation: "account"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_depreciationExpenseAccountId_fkey"+ columns: ["depreciationExpenseAccountId"]+ isOneToOne: false+ referencedRelation: "accounts"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_disposalAccountId_fkey"+ columns: ["disposalAccountId"]+ isOneToOne: false+ referencedRelation: "account"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_disposalAccountId_fkey"+ columns: ["disposalAccountId"]+ isOneToOne: false+ referencedRelation: "accounts"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ {+ foreignKeyName: "fixedAssetClass_writeDownAccountId_fkey"+ columns: ["writeDownAccountId"]+ isOneToOne: false+ referencedRelation: "account"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_writeDownAccountId_fkey"+ columns: ["writeDownAccountId"]+ isOneToOne: false+ referencedRelation: "accounts"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_writeOffAccountId_fkey"+ columns: ["writeOffAccountId"]+ isOneToOne: false+ referencedRelation: "account"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_writeOffAccountId_fkey"+ columns: ["writeOffAccountId"]+ isOneToOne: false+ referencedRelation: "accounts"+ referencedColumns: ["id"]+ },+ ]+ }+ fixedAssetDisposal: {+ Row: {+ companyId: string+ createdAt: string+ createdBy: string+ disposalDate: string+ disposalMethod: Database["public"]["Enums"]["disposalMethod"]+ fixedAssetId: string+ gainLoss: number+ id: string+ journalId: string | null+ netBookValueAtDisposal: number+ saleProceeds: number+ }+ Insert: {+ companyId: string+ createdAt?: string+ createdBy: string+ disposalDate: string+ disposalMethod: Database["public"]["Enums"]["disposalMethod"]+ fixedAssetId: string+ gainLoss: number+ id?: string+ journalId?: string | null+ netBookValueAtDisposal: number+ saleProceeds?: number+ }+ Update: {+ companyId?: string+ createdAt?: string+ createdBy?: string+ disposalDate?: string+ disposalMethod?: Database["public"]["Enums"]["disposalMethod"]+ fixedAssetId?: string+ gainLoss?: number+ id?: string+ journalId?: string | null+ netBookValueAtDisposal?: number+ saleProceeds?: number+ }+ Relationships: [+ {+ foreignKeyName: "fixedAssetDisposal_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "companies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "company"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "customFieldTables"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "integrations"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_fixedAssetId_fkey"+ columns: ["fixedAssetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_journalId_fkey"+ columns: ["journalId"]+ isOneToOne: false+ referencedRelation: "journal"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_journalId_fkey"+ columns: ["journalId"]+ isOneToOne: false+ referencedRelation: "journalEntries"+ referencedColumns: ["id"]+ },+ ]+ }+ fixedAssetUsageLog: {+ Row: {+ companyId: string+ createdAt: string+ createdBy: string+ fixedAssetId: string+ id: string+ periodEnd: string+ periodStart: string+ unitsProduced: number+ }+ Insert: {+ companyId: string+ createdAt?: string+ createdBy: string+ fixedAssetId: string+ id?: string+ periodEnd: string+ periodStart: string+ unitsProduced: number+ }+ Update: {+ companyId?: string+ createdAt?: string+ createdBy?: string+ fixedAssetId?: string+ id?: string+ periodEnd?: string+ periodStart?: string+ unitsProduced?: number+ }+ Relationships: [+ {+ foreignKeyName: "fixedAssetUsageLog_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "companies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "company"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "customFieldTables"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "integrations"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_fixedAssetId_fkey"+ columns: ["fixedAssetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },+ ]+ }fixture: {Row: {approved: boolean@@ -24088,131 +25098,6 @@ export type Database = {},]}- notification: {- Row: {- companyId: string- createdAt: string- description: string | null- digestedInto: string | null- documentId: string | null- documentType: string | null- event: string- from: string | null- id: string- payload: Json- readAt: string | null- seenAt: string | null- title: string- topic: string- userId: string- }- Insert: {- companyId: string- createdAt?: string- description?: string | null- digestedInto?: string | null- documentId?: string | null- documentType?: string | null- event: string- from?: string | null- id?: string- payload?: Json- readAt?: string | null- seenAt?: string | null- title: string- topic: string- userId: string- }- Update: {- companyId?: string- createdAt?: string- description?: string | null- digestedInto?: string | null- documentId?: string | null- documentType?: string | null- event?: string- from?: string | null- id?: string- payload?: Json- readAt?: string | null- seenAt?: string | null- title?: string- topic?: string- userId?: string- }- Relationships: [- {- foreignKeyName: "notification_companyId_fkey"- columns: ["companyId"]- isOneToOne: false- referencedRelation: "companies"- referencedColumns: ["id"]- },- {- foreignKeyName: "notification_companyId_fkey"- columns: ["companyId"]- isOneToOne: false- referencedRelation: "company"- referencedColumns: ["id"]- },- {- foreignKeyName: "notification_companyId_fkey"- columns: ["companyId"]- isOneToOne: false- referencedRelation: "customFieldTables"- referencedColumns: ["companyId"]- },- {- foreignKeyName: "notification_companyId_fkey"- columns: ["companyId"]- isOneToOne: false- referencedRelation: "integrations"- referencedColumns: ["companyId"]- },- {- foreignKeyName: "notification_digestedInto_fkey"- columns: ["digestedInto"]- isOneToOne: false- referencedRelation: "notification"- referencedColumns: ["id"]- },- {- foreignKeyName: "notification_userId_fkey"- columns: ["userId"]- isOneToOne: false- referencedRelation: "employees"- referencedColumns: ["id"]- },- {- foreignKeyName: "notification_userId_fkey"- columns: ["userId"]- isOneToOne: false- referencedRelation: "employeesAcrossCompanies"- referencedColumns: ["id"]- },- {- foreignKeyName: "notification_userId_fkey"- columns: ["userId"]- isOneToOne: false- referencedRelation: "employeeSummary"- referencedColumns: ["id"]- },- {- foreignKeyName: "notification_userId_fkey"- columns: ["userId"]- isOneToOne: false- referencedRelation: "user"- referencedColumns: ["id"]- },- {- foreignKeyName: "notification_userId_fkey"- columns: ["userId"]- isOneToOne: false- referencedRelation: "userDefaults"- referencedColumns: ["userId"]- },- ]- }oauthClient: {Row: {clientId: string@@ -28423,6 +29308,13 @@ export type Database = {referencedRelation: "accounts"referencedColumns: ["id"]},+ {+ foreignKeyName: "purchaseOrderLine_assetId_fkey"+ columns: ["assetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },{foreignKeyName: "purchaseOrderLine_costCenterId_fkey"columns: ["costCenterId"]@@ -33237,6 +34129,144 @@ export type Database = {},]}+ receiptFixedAssetLine: {+ Row: {+ companyId: string+ createdAt: string+ createdBy: string+ id: string+ purchaseOrderLineId: string+ receiptId: string+ received: boolean+ serialNumber: string | null+ updatedAt: string | null+ updatedBy: string | null+ }+ Insert: {+ companyId: string+ createdAt?: string+ createdBy: string+ id?: string+ purchaseOrderLineId: string+ receiptId: string+ received?: boolean+ serialNumber?: string | null+ updatedAt?: string | null+ updatedBy?: string | null+ }+ Update: {+ companyId?: string+ createdAt?: string+ createdBy?: string+ id?: string+ purchaseOrderLineId?: string+ receiptId?: string+ received?: boolean+ serialNumber?: string | null+ updatedAt?: string | null+ updatedBy?: string | null+ }+ Relationships: [+ {+ foreignKeyName: "receiptFixedAssetLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "companies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "company"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "customFieldTables"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "integrations"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_purchaseOrderLineId_fkey"+ columns: ["purchaseOrderLineId"]+ isOneToOne: false+ referencedRelation: "openPurchaseOrderLines"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_purchaseOrderLineId_fkey"+ columns: ["purchaseOrderLineId"]+ isOneToOne: false+ referencedRelation: "purchaseOrderLine"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_purchaseOrderLineId_fkey"+ columns: ["purchaseOrderLineId"]+ isOneToOne: false+ referencedRelation: "purchaseOrderLines"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_receiptId_fkey"+ columns: ["receiptId"]+ isOneToOne: false+ referencedRelation: "receipt"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_receiptId_fkey"+ columns: ["receiptId"]+ isOneToOne: false+ referencedRelation: "receipts"+ referencedColumns: ["id"]+ },+ ]+ }receiptLine: {Row: {companyId: string@@ -34114,6 +35144,13 @@ export type Database = {referencedRelation: "accounts"referencedColumns: ["id"]},+ {+ foreignKeyName: "salesInvoiceLine_assetId_fkey"+ columns: ["assetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },{foreignKeyName: "salesInvoiceLine_companyId_fkey"columns: ["companyId"]@@ -35086,6 +36123,13 @@ export type Database = {referencedRelation: "accounts"referencedColumns: ["id"]},+ {+ foreignKeyName: "salesOrderLine_assetId_fkey"+ columns: ["assetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },{foreignKeyName: "salesOrderLine_createdBy_fkey"columns: ["createdBy"]@@ -36547,7 +37591,7 @@ export type Database = {},]}- searchIndex_PjY5r4hY5NXa8db3oSSoQs: {+ searchIndex_SvN8PSwVgcgrU2W6cCNWXE: {Row: {createdAt: stringdescription: string | null@@ -37493,6 +38537,137 @@ export type Database = {},]}+ shipmentFixedAssetLine: {+ Row: {+ companyId: string+ createdAt: string+ createdBy: string+ id: string+ salesOrderLineId: string+ serialNumber: string | null+ shipmentId: string+ shipped: boolean+ updatedAt: string | null+ updatedBy: string | null+ }+ Insert: {+ companyId: string+ createdAt?: string+ createdBy: string+ id?: string+ salesOrderLineId: string+ serialNumber?: string | null+ shipmentId: string+ shipped?: boolean+ updatedAt?: string | null+ updatedBy?: string | null+ }+ Update: {+ companyId?: string+ createdAt?: string+ createdBy?: string+ id?: string+ salesOrderLineId?: string+ serialNumber?: string | null+ shipmentId?: string+ shipped?: boolean+ updatedAt?: string | null+ updatedBy?: string | null+ }+ Relationships: [+ {+ foreignKeyName: "shipmentFixedAssetLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "companies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "company"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "customFieldTables"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "integrations"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_salesOrderLineId_fkey"+ columns: ["salesOrderLineId"]+ isOneToOne: false+ referencedRelation: "openSalesOrderLines"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_salesOrderLineId_fkey"+ columns: ["salesOrderLineId"]+ isOneToOne: false+ referencedRelation: "salesOrderLine"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_salesOrderLineId_fkey"+ columns: ["salesOrderLineId"]+ isOneToOne: false+ referencedRelation: "salesOrderLines"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_shipmentId_fkey"+ columns: ["shipmentId"]+ isOneToOne: false+ referencedRelation: "shipment"+ referencedColumns: ["id"]+ },+ ]+ }shipmentLine: {Row: {companyId: string@@ -45744,6 +46919,7 @@ export type Database = {createdBy: stringcustomFields: Json | nulldefaultStandardFactor: Database["public"]["Enums"]["factor"]+ departmentId: string | nulldescription: string | nullid: stringlaborRate: number@@ -45763,6 +46939,7 @@ export type Database = {createdBy: stringcustomFields?: Json | nulldefaultStandardFactor?: Database["public"]["Enums"]["factor"]+ departmentId?: string | nulldescription?: string | nullid?: stringlaborRate?: number@@ -45782,6 +46959,7 @@ export type Database = {createdBy?: stringcustomFields?: Json | nulldefaultStandardFactor?: Database["public"]["Enums"]["factor"]+ departmentId?: string | nulldescription?: string | nullid?: stringlaborRate?: number@@ -45858,6 +47036,13 @@ export type Database = {referencedRelation: "userDefaults"referencedColumns: ["userId"]},+ {+ foreignKeyName: "workCenter_departmentId_fkey"+ columns: ["departmentId"]+ isOneToOne: false+ referencedRelation: "department"+ referencedColumns: ["id"]+ },{foreignKeyName: "workCenter_locationId_fkey"columns: ["locationId"]@@ -51822,14 +53007,14 @@ export type Database = {},{foreignKeyName: "partner_id_fkey"- columns: ["supplierLocationId"]+ columns: ["id"]isOneToOne: falsereferencedRelation: "supplierLocation"referencedColumns: ["id"]},{foreignKeyName: "partner_id_fkey"- columns: ["id"]+ columns: ["supplierLocationId"]isOneToOne: falsereferencedRelation: "supplierLocation"referencedColumns: ["id"]@@ -52273,6 +53458,8 @@ export type Database = {accountId: string | nullaccountName: string | nullassetId: string | null+ assetName: string | null+ assetReadableId: string | nullcompanyId: string | nullconversionFactor: number | nullcostCenterId: string | null@@ -52935,6 +54122,8 @@ export type Database = {accountId: string | nullaccountName: string | nullassetId: string | null+ assetName: string | null+ assetReadableId: string | nullautodeskUrn: string | nullcompanyId: string | nullconversionFactor: number | null@@ -53013,6 +54202,13 @@ export type Database = {referencedRelation: "accounts"referencedColumns: ["id"]},+ {+ foreignKeyName: "purchaseOrderLine_assetId_fkey"+ columns: ["assetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },{foreignKeyName: "purchaseOrderLine_costCenterId_fkey"columns: ["costCenterId"]@@ -53313,14 +54509,14 @@ export type Database = {Relationships: [{foreignKeyName: "address_countryCode_fkey"- columns: ["supplierCountryCode"]+ columns: ["customerCountryCode"]isOneToOne: falsereferencedRelation: "country"referencedColumns: ["alpha2"]},{foreignKeyName: "address_countryCode_fkey"- columns: ["customerCountryCode"]+ columns: ["supplierCountryCode"]isOneToOne: falsereferencedRelation: "country"referencedColumns: ["alpha2"]@@ -56392,6 +57588,8 @@ export type Database = {accountId: string | nulladdOnCost: number | nullassetId: string | null+ assetName: string | null+ assetReadableId: string | nullcompanyId: string | nullconvertedAddOnCost: number | nullconvertedNonTaxableAddOnCost: number | null@@ -56450,6 +57648,13 @@ export type Database = {referencedRelation: "accounts"referencedColumns: ["id"]},+ {+ foreignKeyName: "salesInvoiceLine_assetId_fkey"+ columns: ["assetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },{foreignKeyName: "salesInvoiceLine_companyId_fkey"columns: ["companyId"]@@ -56731,7 +57936,7 @@ export type Database = {Relationships: [{foreignKeyName: "address_countryCode_fkey"- columns: ["invoiceCountryCode"]+ columns: ["shipmentCountryCode"]isOneToOne: falsereferencedRelation: "country"referencedColumns: ["alpha2"]@@ -56745,7 +57950,7 @@ export type Database = {},{foreignKeyName: "address_countryCode_fkey"- columns: ["shipmentCountryCode"]+ columns: ["invoiceCountryCode"]isOneToOne: falsereferencedRelation: "country"referencedColumns: ["alpha2"]@@ -57027,6 +58232,8 @@ export type Database = {accountId: string | nulladdOnCost: number | nullassetId: string | null+ assetName: string | null+ assetReadableId: string | nullautodeskUrn: string | nullcompanyId: string | nullconvertedAddOnCost: number | null@@ -57121,6 +58328,13 @@ export type Database = {referencedRelation: "accounts"referencedColumns: ["id"]},+ {+ foreignKeyName: "salesOrderLine_assetId_fkey"+ columns: ["assetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },{foreignKeyName: "salesOrderLine_createdBy_fkey"columns: ["createdBy"]@@ -57303,14 +58517,14 @@ export type Database = {Relationships: [{foreignKeyName: "address_countryCode_fkey"- columns: ["paymentCountryCode"]+ columns: ["customerCountryCode"]isOneToOne: falsereferencedRelation: "country"referencedColumns: ["alpha2"]},{foreignKeyName: "address_countryCode_fkey"- columns: ["customerCountryCode"]+ columns: ["paymentCountryCode"]isOneToOne: falsereferencedRelation: "country"referencedColumns: ["alpha2"]@@ -60312,6 +61526,8 @@ export type Database = {createdBy: string | nullcustomFields: Json | nulldefaultStandardFactor: Database["public"]["Enums"]["factor"] | null+ departmentId: string | null+ departmentName: string | nulldescription: string | nullid: string | nulllaborRate: number | null@@ -60390,6 +61606,13 @@ export type Database = {referencedRelation: "userDefaults"referencedColumns: ["userId"]},+ {+ foreignKeyName: "workCenter_departmentId_fkey"+ columns: ["departmentId"]+ isOneToOne: false+ referencedRelation: "department"+ referencedColumns: ["id"]+ },{foreignKeyName: "workCenter_locationId_fkey"columns: ["locationId"]@@ -60451,6 +61674,7 @@ export type Database = {createdBy: string | nullcustomFields: Json | nulldefaultStandardFactor: Database["public"]["Enums"]["factor"] | null+ departmentId: string | nulldescription: string | nullid: string | nullisBlocked: boolean | null@@ -60529,6 +61753,13 @@ export type Database = {referencedRelation: "userDefaults"referencedColumns: ["userId"]},+ {+ foreignKeyName: "workCenter_departmentId_fkey"+ columns: ["departmentId"]+ isOneToOne: false+ referencedRelation: "department"+ referencedColumns: ["id"]+ },{foreignKeyName: "workCenter_locationId_fkey"columns: ["locationId"]@@ -62778,6 +64009,10 @@ export type Database = {customRuleTargetType: "item" | "storageUnit" | "workCenter"deadlineType: "No Deadline" | "ASAP" | "Soft Deadline" | "Hard Deadline"demandSourceType: "Sales Order" | "Job Material"+ depreciationMethod:+ | "Straight Line"+ | "Declining Balance"+ | "Units of Production"dimensionEntityType:| "Custom"| "Location"@@ -62787,6 +64022,10 @@ export type Database = {| "Department"| "Employee"| "CostCenter"+ | "WorkCenter"+ | "Process"+ | "FixedAssetClass"+ disposalMethod: "Sale" | "Scrapping"disposition:| "Conditional Acceptance"| "Deviation Accepted"@@ -62867,6 +64106,7 @@ export type Database = {| "Seconds/Piece"| "Total Hours"| "Total Minutes"+ fixedAssetStatus: "Draft" | "Active" | "Fully Depreciated" | "Disposed"fulfillmentType: "Inventory" | "Job"gaugeCalibrationStatus:| "Pending"@@ -62987,6 +64227,8 @@ export type Database = {| "Job Receipt"| "Production Event"| "Job Close"+ | "Asset Depreciation"+ | "Asset Disposal"journalEntryStatus: "Draft" | "Posted" | "Reversed"journalLineDocumentType:| "Receipt"@@ -63005,6 +64247,8 @@ export type Database = {| "Production Event"| "Job Close"kanbanOutput: "label" | "qrcode" | "url"+ macrsConvention: "Half-Year" | "Mid-Quarter"+ macrsPropertyClass: "3" | "5" | "7" | "10" | "15" | "20" | "27.5" | "39"maintenanceDispatchPriority: "Low" | "Medium" | "High" | "Critical"maintenanceDispatchStatus:| "Open"@@ -63266,6 +64510,7 @@ export type Database = {supplierStatusType: "Active" | "Inactive" | "Pending" | "Rejected"supplySourceType: "Purchase Order" | "Production Order"tableViewType: "Public" | "Private"+ taxDepreciationMethod: "Straight Line" | "Declining Balance" | "MACRS"taxExemptionReason:| "Resale"| "Government"@@ -64032,6 +65277,11 @@ export const Constants = {customRuleTargetType: ["item", "storageUnit", "workCenter"],deadlineType: ["No Deadline", "ASAP", "Soft Deadline", "Hard Deadline"],demandSourceType: ["Sales Order", "Job Material"],+ depreciationMethod: [+ "Straight Line",+ "Declining Balance",+ "Units of Production",+ ],dimensionEntityType: ["Custom","Location",@@ -64041,7 +65291,11 @@ export const Constants = {"Department","Employee","CostCenter",+ "WorkCenter",+ "Process",+ "FixedAssetClass",],+ disposalMethod: ["Sale", "Scrapping"],disposition: ["Conditional Acceptance","Deviation Accepted",@@ -64129,6 +65383,7 @@ export const Constants = {"Total Hours","Total Minutes",],+ fixedAssetStatus: ["Draft", "Active", "Fully Depreciated", "Disposed"],fulfillmentType: ["Inventory", "Job"],gaugeCalibrationStatus: ["Pending",@@ -64259,6 +65514,8 @@ export const Constants = {"Job Receipt","Production Event","Job Close",+ "Asset Depreciation",+ "Asset Disposal",],journalEntryStatus: ["Draft", "Posted", "Reversed"],journalLineDocumentType: [@@ -64279,6 +65536,8 @@ export const Constants = {"Job Close",],kanbanOutput: ["label", "qrcode", "url"],+ macrsConvention: ["Half-Year", "Mid-Quarter"],+ macrsPropertyClass: ["3", "5", "7", "10", "15", "20", "27.5", "39"],maintenanceDispatchPriority: ["Low", "Medium", "High", "Critical"],maintenanceDispatchStatus: ["Open",@@ -64566,6 +65825,7 @@ export const Constants = {supplierStatusType: ["Active", "Inactive", "Pending", "Rejected"],supplySourceType: ["Purchase Order", "Production Order"],tableViewType: ["Public", "Private"],+ taxDepreciationMethod: ["Straight Line", "Declining Balance", "MACRS"],taxExemptionReason: ["Resale","Government",diff --git a/packages/database/supabase/functions/convert/index.ts b/packages/database/supabase/functions/convert/index.tsindex 57795ad8a3..676a93fd1e 100644--- a/packages/database/supabase/functions/convert/index.ts+++ b/packages/database/supabase/functions/convert/index.ts@@ -1176,12 +1176,20 @@ serve(async (req: Request) => {}case "shipmentToSalesInvoice": {const shipmentId = id;- const [shipment, shipmentLines] = await Promise.all([- client.from("shipment").select("*").eq("id", shipmentId).single(),- client.from("shipmentLine").select("*").eq("shipmentId", shipmentId),- ]);+ const [shipment, shipmentLines, shipmentFixedAssetLines] =+ await Promise.all([+ client.from("shipment").select("*").eq("id", shipmentId).single(),+ client.from("shipmentLine").select("*").eq("shipmentId", shipmentId),+ client+ .from("shipmentFixedAssetLine")+ .select("*")+ .eq("shipmentId", shipmentId)+ .eq("shipped", true),+ ]);if (shipmentLines.error) throw shipmentLines.error;+ if (shipmentFixedAssetLines.error)+ throw shipmentFixedAssetLines.error;// Accumulate quantities for each sales order lineconst quantitiesByLine = shipmentLines.data.reduce<@@ -1192,6 +1200,12 @@ serve(async (req: Request) => {return acc;}, {});+ // Each shipped fixed asset line counts as quantity 1+ for (const line of shipmentFixedAssetLines.data) {+ const lineId = line.salesOrderLineId;+ quantitiesByLine[lineId] = (quantitiesByLine[lineId] || 0) + 1;+ }+const salesOrderLineIds = Object.keys(quantitiesByLine);if (diff --git a/packages/database/supabase/functions/create/index.ts b/packages/database/supabase/functions/create/index.tsindex 83f01aae93..9ce8901092 100644--- a/packages/database/supabase/functions/create/index.ts+++ b/packages/database/supabase/functions/create/index.ts@@ -778,7 +778,7 @@ serve(async (req: Request) => {companyId);- const [purchaseOrder, purchaseOrderLines, receipt] = await Promise.all([+ const [purchaseOrder, purchaseOrderLines, fixedAssetPoLines, receipt] = await Promise.all([client.from("purchaseOrders").select("*")@@ -795,7 +795,11 @@ serve(async (req: Request) => {"Fixture","Consumable",]),-+ client+ .from("purchaseOrderLine")+ .select("id, purchaseOrderLineType, assetId, purchaseQuantity, quantityReceived, receivedComplete")+ .eq("purchaseOrderId", purchaseOrderId)+ .eq("purchaseOrderLineType", "Fixed Asset"),client.from("receipt").select("*")@@ -923,7 +927,10 @@ serve(async (req: Request) => {return acc;}, []);- if (receiptLineItems.length === 0) {+ const hasUnreceivedFaLines = (fixedAssetPoLines.data ?? []).some(+ (d) => d.assetId && d.purchaseQuantity && !d.receivedComplete+ );+ if (receiptLineItems.length === 0 && !hasUnreceivedFaLines) {throw new Error("No valid receipt line items found");}@@ -988,6 +995,28 @@ serve(async (req: Request) => {).execute();}++ const unreceivedFaLines = (fixedAssetPoLines.data ?? []).filter(+ (d) => d.assetId && d.purchaseQuantity && !d.receivedComplete+ );+ if (unreceivedFaLines.length > 0) {+ await trx+ .deleteFrom("receiptFixedAssetLine")+ .where("receiptId", "=", receiptId)+ .execute();+ await trx+ .insertInto("receiptFixedAssetLine")+ .values(+ unreceivedFaLines.map((line) => ({+ receiptId: receiptId,+ purchaseOrderLineId: line.id,+ received: true,+ companyId,+ createdBy: userId,+ }))+ )+ .execute();+ }});return new Response(@@ -1972,6 +2001,7 @@ serve(async (req: Request) => {const [salesOrder,salesOrderLines,+ fixedAssetSoLines,salesOrderShipment,shipment,jobs,@@ -1989,6 +2019,11 @@ serve(async (req: Request) => {"Consumable",]).eq("locationId", locationId),+ client+ .from("salesOrderLine")+ .select("id, salesOrderLineType, assetId, saleQuantity, quantitySent, sentComplete")+ .eq("salesOrderId", salesOrderId)+ .eq("salesOrderLineType", "Fixed Asset"),client.from("salesOrderShipment").select("*")@@ -2263,6 +2298,28 @@ serve(async (req: Request) => {).execute();}++ const unshippedFaLines = (fixedAssetSoLines.data ?? []).filter(+ (d) => d.assetId && d.saleQuantity && !d.sentComplete+ );+ if (unshippedFaLines.length > 0) {+ await trx+ .deleteFrom("shipmentFixedAssetLine")+ .where("shipmentId", "=", shipmentId)+ .execute();+ await trx+ .insertInto("shipmentFixedAssetLine")+ .values(+ unshippedFaLines.map((line) => ({+ shipmentId: shipmentId,+ salesOrderLineId: line.id,+ shipped: true,+ companyId,+ createdBy: userId,+ }))+ )+ .execute();+ }});return new Response(diff --git a/packages/database/supabase/functions/lib/seed.data.ts b/packages/database/supabase/functions/lib/seed.data.tsindex 50478e397c..fb4d94ba5d 100644--- a/packages/database/supabase/functions/lib/seed.data.ts+++ b/packages/database/supabase/functions/lib/seed.data.ts@@ -13,6 +13,9 @@ export const dimensions = [{ name: "Item Posting Group", entityType: "ItemPostingGroup" },{ name: "Customer Type", entityType: "CustomerType" },{ name: "Supplier Type", entityType: "SupplierType" },+ { name: "Work Center", entityType: "WorkCenter" },+ { name: "Process", entityType: "Process" },+ { name: "Asset Class", entityType: "FixedAssetClass" },] as const;export const supplierStatuses = [@@ -345,6 +348,24 @@ export const sequences = [next: 0,size: 6,step: 1+ },+ {+ table: "fixedAsset",+ name: "Fixed Asset",+ prefix: "FA",+ suffix: null,+ next: 1,+ size: 6,+ step: 1+ },+ {+ table: "depreciationRun",+ name: "Depreciation Run",+ prefix: "DR",+ suffix: null,+ next: 1,+ size: 6,+ step: 1}] as const;@@ -620,6 +641,7 @@ export const accounts = [{ key: "7060", number: "7060", name: "Foreign Exchange Losses", isGroup: false, parentKey: "other-expenses", accountType: "Other Expense", incomeBalance: "Income Statement", class: "Expense", consolidatedRate: "Average", createdBy: "system" },{ key: "7070", number: "7070", name: "Income Tax Expense", isGroup: false, parentKey: "other-expenses", accountType: "Other Expense", incomeBalance: "Income Statement", class: "Expense", consolidatedRate: "Average", createdBy: "system" },{ key: "7080", number: "7080", name: "R&D Expenses", isGroup: false, parentKey: "other-expenses", accountType: "Other Expense", incomeBalance: "Income Statement", class: "Expense", consolidatedRate: "Average", createdBy: "system" },+ { key: "7090", number: "7090", name: "Deferred Tax Expense", isGroup: false, parentKey: "other-expenses", accountType: "Other Expense", incomeBalance: "Income Statement", class: "Expense", consolidatedRate: "Average", createdBy: "system" },] as const;export const accountDefaults = {@@ -662,8 +684,49 @@ export const accountDefaults = {reverseChargeSalesTaxPayableAccount: "2230",retainedEarningsAccount: "3100",currencyTranslationAccount: "3200",+ deferredTaxLiabilityAccountId: "2420",+ deferredTaxExpenseAccountId: "7090",} as const;+export const fixedAssetClasses = [+ {+ name: "Buildings",+ depreciationMethod: "Straight Line" as const,+ usefulLifeMonths: 468,+ residualValuePercent: 0,+ assetAccount: "1360",+ accumulatedDepreciationAccount: "1330",+ depreciationExpenseAccount: "6310",+ writeOffAccount: "6320",+ writeDownAccount: "6320",+ disposalAccount: "6320",+ },+ {+ name: "Machinery & Equipment",+ depreciationMethod: "Straight Line" as const,+ usefulLifeMonths: 120,+ residualValuePercent: 0,+ assetAccount: "1350",+ accumulatedDepreciationAccount: "1330",+ depreciationExpenseAccount: "6310",+ writeOffAccount: "6320",+ writeDownAccount: "6320",+ disposalAccount: "6320",+ },+ {+ name: "Vehicles",+ depreciationMethod: "Straight Line" as const,+ usefulLifeMonths: 60,+ residualValuePercent: 0,+ assetAccount: "1310",+ accumulatedDepreciationAccount: "1330",+ depreciationExpenseAccount: "6310",+ writeOffAccount: "6320",+ writeDownAccount: "6320",+ disposalAccount: "6320",+ },+];+export const fiscalYearSettings = {startMonth: "January",taxStartMonth: "January",diff --git a/packages/database/supabase/functions/lib/seed.ts b/packages/database/supabase/functions/lib/seed.tsindex 11fd0ccd5a..5646957831 100644--- a/packages/database/supabase/functions/lib/seed.ts+++ b/packages/database/supabase/functions/lib/seed.ts@@ -11,6 +11,7 @@ export {dimensions,failureModes,fiscalYearSettings,+ fixedAssetClasses,gaugeTypes,nonConformanceRequiredActions,nonConformanceTypes,diff --git a/packages/database/supabase/functions/lib/types.ts b/packages/database/supabase/functions/lib/types.tsindex e42609ed29..311514d124 100644--- a/packages/database/supabase/functions/lib/types.ts+++ b/packages/database/supabase/functions/lib/types.ts@@ -342,6 +342,8 @@ export type Database = {costOfGoodsSoldAccount: stringcurrencyTranslationAccount: stringcustomerPaymentDiscountAccount: string+ deferredTaxExpenseAccountId: string | null+ deferredTaxLiabilityAccountId: string | nullgoodsReceivedNotInvoicedAccount: stringindirectCostAccount: stringinterestAccount: string@@ -385,6 +387,8 @@ export type Database = {costOfGoodsSoldAccount: stringcurrencyTranslationAccount: stringcustomerPaymentDiscountAccount: string+ deferredTaxExpenseAccountId?: string | null+ deferredTaxLiabilityAccountId?: string | nullgoodsReceivedNotInvoicedAccount: stringindirectCostAccount: stringinterestAccount: string@@ -428,6 +432,8 @@ export type Database = {costOfGoodsSoldAccount?: stringcurrencyTranslationAccount?: stringcustomerPaymentDiscountAccount?: string+ deferredTaxExpenseAccountId?: string | null+ deferredTaxLiabilityAccountId?: string | nullgoodsReceivedNotInvoicedAccount?: stringindirectCostAccount?: stringinterestAccount?: string@@ -626,6 +632,34 @@ export type Database = {referencedRelation: "accounts"referencedColumns: ["id"]},+ {+ foreignKeyName: "accountDefault_deferredTaxExpenseAccountId_fkey"+ columns: ["deferredTaxExpenseAccountId"]+ isOneToOne: false+ referencedRelation: "account"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "accountDefault_deferredTaxExpenseAccountId_fkey"+ columns: ["deferredTaxExpenseAccountId"]+ isOneToOne: false+ referencedRelation: "accounts"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "accountDefault_deferredTaxLiabilityAccountId_fkey"+ columns: ["deferredTaxLiabilityAccountId"]+ isOneToOne: false+ referencedRelation: "account"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "accountDefault_deferredTaxLiabilityAccountId_fkey"+ columns: ["deferredTaxLiabilityAccountId"]+ isOneToOne: false+ referencedRelation: "accounts"+ referencedColumns: ["id"]+ },{foreignKeyName: "accountDefault_fkey"columns: ["companyId"]@@ -2832,6 +2866,8 @@ export type Database = {accountsPayableEmail: string | nullaccountsReceivableAddress: boolean | nullaccountsReceivableEmail: string | null+ assetTaxDepreciationEnabled: boolean+ assetTaxRate: number | nullconsoleEnabled: booleandefaultCustomerCc: string[] | nulldefaultSupplierCc: string[] | null@@ -2873,6 +2909,8 @@ export type Database = {accountsPayableEmail?: string | nullaccountsReceivableAddress?: boolean | nullaccountsReceivableEmail?: string | null+ assetTaxDepreciationEnabled?: boolean+ assetTaxRate?: number | nullconsoleEnabled?: booleandefaultCustomerCc?: string[] | nulldefaultSupplierCc?: string[] | null@@ -2914,6 +2952,8 @@ export type Database = {accountsPayableEmail?: string | nullaccountsReceivableAddress?: boolean | nullaccountsReceivableEmail?: string | null+ assetTaxDepreciationEnabled?: boolean+ assetTaxRate?: number | nullconsoleEnabled?: booleandefaultCustomerCc?: string[] | nulldefaultSupplierCc?: string[] | null@@ -7582,6 +7622,228 @@ export type Database = {},]}+ depreciationRun: {+ Row: {+ companyId: string+ createdAt: string+ createdBy: string+ depreciationRunId: string+ id: string+ periodEnd: string+ postedAt: string | null+ postedBy: string | null+ status: string+ }+ Insert: {+ companyId: string+ createdAt?: string+ createdBy: string+ depreciationRunId: string+ id?: string+ periodEnd: string+ postedAt?: string | null+ postedBy?: string | null+ status?: string+ }+ Update: {+ companyId?: string+ createdAt?: string+ createdBy?: string+ depreciationRunId?: string+ id?: string+ periodEnd?: string+ postedAt?: string | null+ postedBy?: string | null+ status?: string+ }+ Relationships: [+ {+ foreignKeyName: "depreciationRun_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "companies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "company"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "customFieldTables"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "depreciationRun_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "integrations"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "depreciationRun_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ {+ foreignKeyName: "depreciationRun_postedBy_fkey"+ columns: ["postedBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_postedBy_fkey"+ columns: ["postedBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_postedBy_fkey"+ columns: ["postedBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_postedBy_fkey"+ columns: ["postedBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRun_postedBy_fkey"+ columns: ["postedBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ ]+ }+ depreciationRunLine: {+ Row: {+ amount: number+ companyId: string+ depreciationRunId: string+ fixedAssetId: string+ id: string+ journalId: string | null+ taxAmount: number | null+ }+ Insert: {+ amount: number+ companyId: string+ depreciationRunId: string+ fixedAssetId: string+ id?: string+ journalId?: string | null+ taxAmount?: number | null+ }+ Update: {+ amount?: number+ companyId?: string+ depreciationRunId?: string+ fixedAssetId?: string+ id?: string+ journalId?: string | null+ taxAmount?: number | null+ }+ Relationships: [+ {+ foreignKeyName: "depreciationRunLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "companies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRunLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "company"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRunLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "customFieldTables"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "depreciationRunLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "integrations"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "depreciationRunLine_depreciationRunId_fkey"+ columns: ["depreciationRunId"]+ isOneToOne: false+ referencedRelation: "depreciationRun"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRunLine_fixedAssetId_fkey"+ columns: ["fixedAssetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRunLine_journalId_fkey"+ columns: ["journalId"]+ isOneToOne: false+ referencedRelation: "journal"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "depreciationRunLine_journalId_fkey"+ columns: ["journalId"]+ isOneToOne: false+ referencedRelation: "journalEntries"+ referencedColumns: ["id"]+ },+ ]+ }dimension: {Row: {active: boolean@@ -9207,6 +9469,754 @@ export type Database = {},]}+ fixedAsset: {+ Row: {+ accumulatedDepreciation: number+ accumulatedTaxDepreciation: number+ acquisitionCost: number+ acquisitionDate: string | null+ assetLifetimeUsage: number | null+ bonusDepreciationPercent: number | null+ companyId: string+ createdAt: string+ createdBy: string+ customFields: Json | null+ depreciationMethod: Database["public"]["Enums"]["depreciationMethod"]+ depreciationStartDate: string | null+ description: string | null+ disposalDate: string | null+ disposalMethod: Database["public"]["Enums"]["disposalMethod"] | null+ fixedAssetClassId: string+ fixedAssetId: string+ id: string+ locationId: string | null+ macrsConvention: Database["public"]["Enums"]["macrsConvention"] | null+ macrsPropertyClass:+ | Database["public"]["Enums"]["macrsPropertyClass"]+ | null+ name: string+ notes: Json | null+ residualValuePercent: number+ saleProceeds: number | null+ serialNumber: string | null+ status: Database["public"]["Enums"]["fixedAssetStatus"]+ taxDepreciationMethod:+ | Database["public"]["Enums"]["taxDepreciationMethod"]+ | null+ taxResidualValuePercent: number | null+ taxUsefulLifeMonths: number | null+ updatedAt: string | null+ updatedBy: string | null+ usefulLifeMonths: number+ }+ Insert: {+ accumulatedDepreciation?: number+ accumulatedTaxDepreciation?: number+ acquisitionCost?: number+ acquisitionDate?: string | null+ assetLifetimeUsage?: number | null+ bonusDepreciationPercent?: number | null+ companyId: string+ createdAt?: string+ createdBy: string+ customFields?: Json | null+ depreciationMethod?: Database["public"]["Enums"]["depreciationMethod"]+ depreciationStartDate?: string | null+ description?: string | null+ disposalDate?: string | null+ disposalMethod?: Database["public"]["Enums"]["disposalMethod"] | null+ fixedAssetClassId: string+ fixedAssetId: string+ id?: string+ locationId?: string | null+ macrsConvention?:+ | Database["public"]["Enums"]["macrsConvention"]+ | null+ macrsPropertyClass?:+ | Database["public"]["Enums"]["macrsPropertyClass"]+ | null+ name: string+ notes?: Json | null+ residualValuePercent?: number+ saleProceeds?: number | null+ serialNumber?: string | null+ status?: Database["public"]["Enums"]["fixedAssetStatus"]+ taxDepreciationMethod?:+ | Database["public"]["Enums"]["taxDepreciationMethod"]+ | null+ taxResidualValuePercent?: number | null+ taxUsefulLifeMonths?: number | null+ updatedAt?: string | null+ updatedBy?: string | null+ usefulLifeMonths?: number+ }+ Update: {+ accumulatedDepreciation?: number+ accumulatedTaxDepreciation?: number+ acquisitionCost?: number+ acquisitionDate?: string | null+ assetLifetimeUsage?: number | null+ bonusDepreciationPercent?: number | null+ companyId?: string+ createdAt?: string+ createdBy?: string+ customFields?: Json | null+ depreciationMethod?: Database["public"]["Enums"]["depreciationMethod"]+ depreciationStartDate?: string | null+ description?: string | null+ disposalDate?: string | null+ disposalMethod?: Database["public"]["Enums"]["disposalMethod"] | null+ fixedAssetClassId?: string+ fixedAssetId?: string+ id?: string+ locationId?: string | null+ macrsConvention?:+ | Database["public"]["Enums"]["macrsConvention"]+ | null+ macrsPropertyClass?:+ | Database["public"]["Enums"]["macrsPropertyClass"]+ | null+ name?: string+ notes?: Json | null+ residualValuePercent?: number+ saleProceeds?: number | null+ serialNumber?: string | null+ status?: Database["public"]["Enums"]["fixedAssetStatus"]+ taxDepreciationMethod?:+ | Database["public"]["Enums"]["taxDepreciationMethod"]+ | null+ taxResidualValuePercent?: number | null+ taxUsefulLifeMonths?: number | null+ updatedAt?: string | null+ updatedBy?: string | null+ usefulLifeMonths?: number+ }+ Relationships: [+ {+ foreignKeyName: "fixedAsset_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "companies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "company"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "customFieldTables"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "fixedAsset_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "integrations"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "fixedAsset_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ {+ foreignKeyName: "fixedAsset_fixedAssetClassId_fkey"+ columns: ["fixedAssetClassId"]+ isOneToOne: false+ referencedRelation: "fixedAssetClass"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_locationId_fkey"+ columns: ["locationId"]+ isOneToOne: false+ referencedRelation: "location"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAsset_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ ]+ }+ fixedAssetClass: {+ Row: {+ accumulatedDepreciationAccountId: string+ assetAccountId: string+ bonusDepreciationPercent: number | null+ companyId: string+ createdAt: string+ createdBy: string+ customFields: Json | null+ depreciationExpenseAccountId: string+ depreciationMethod: Database["public"]["Enums"]["depreciationMethod"]+ description: string | null+ disposalAccountId: string+ id: string+ macrsConvention: Database["public"]["Enums"]["macrsConvention"] | null+ macrsPropertyClass:+ | Database["public"]["Enums"]["macrsPropertyClass"]+ | null+ name: string+ residualValuePercent: number+ taxDepreciationMethod:+ | Database["public"]["Enums"]["taxDepreciationMethod"]+ | null+ taxResidualValuePercent: number | null+ taxUsefulLifeMonths: number | null+ updatedAt: string | null+ updatedBy: string | null+ usefulLifeMonths: number+ writeDownAccountId: string+ writeOffAccountId: string+ }+ Insert: {+ accumulatedDepreciationAccountId: string+ assetAccountId: string+ bonusDepreciationPercent?: number | null+ companyId: string+ createdAt?: string+ createdBy: string+ customFields?: Json | null+ depreciationExpenseAccountId: string+ depreciationMethod?: Database["public"]["Enums"]["depreciationMethod"]+ description?: string | null+ disposalAccountId: string+ id?: string+ macrsConvention?:+ | Database["public"]["Enums"]["macrsConvention"]+ | null+ macrsPropertyClass?:+ | Database["public"]["Enums"]["macrsPropertyClass"]+ | null+ name: string+ residualValuePercent?: number+ taxDepreciationMethod?:+ | Database["public"]["Enums"]["taxDepreciationMethod"]+ | null+ taxResidualValuePercent?: number | null+ taxUsefulLifeMonths?: number | null+ updatedAt?: string | null+ updatedBy?: string | null+ usefulLifeMonths?: number+ writeDownAccountId: string+ writeOffAccountId: string+ }+ Update: {+ accumulatedDepreciationAccountId?: string+ assetAccountId?: string+ bonusDepreciationPercent?: number | null+ companyId?: string+ createdAt?: string+ createdBy?: string+ customFields?: Json | null+ depreciationExpenseAccountId?: string+ depreciationMethod?: Database["public"]["Enums"]["depreciationMethod"]+ description?: string | null+ disposalAccountId?: string+ id?: string+ macrsConvention?:+ | Database["public"]["Enums"]["macrsConvention"]+ | null+ macrsPropertyClass?:+ | Database["public"]["Enums"]["macrsPropertyClass"]+ | null+ name?: string+ residualValuePercent?: number+ taxDepreciationMethod?:+ | Database["public"]["Enums"]["taxDepreciationMethod"]+ | null+ taxResidualValuePercent?: number | null+ taxUsefulLifeMonths?: number | null+ updatedAt?: string | null+ updatedBy?: string | null+ usefulLifeMonths?: number+ writeDownAccountId?: string+ writeOffAccountId?: string+ }+ Relationships: [+ {+ foreignKeyName: "fixedAssetClass_accumulatedDepreciationAccountId_fkey"+ columns: ["accumulatedDepreciationAccountId"]+ isOneToOne: false+ referencedRelation: "account"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_accumulatedDepreciationAccountId_fkey"+ columns: ["accumulatedDepreciationAccountId"]+ isOneToOne: false+ referencedRelation: "accounts"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_assetAccountId_fkey"+ columns: ["assetAccountId"]+ isOneToOne: false+ referencedRelation: "account"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_assetAccountId_fkey"+ columns: ["assetAccountId"]+ isOneToOne: false+ referencedRelation: "accounts"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "companies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "company"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "customFieldTables"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "fixedAssetClass_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "integrations"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "fixedAssetClass_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ {+ foreignKeyName: "fixedAssetClass_depreciationExpenseAccountId_fkey"+ columns: ["depreciationExpenseAccountId"]+ isOneToOne: false+ referencedRelation: "account"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_depreciationExpenseAccountId_fkey"+ columns: ["depreciationExpenseAccountId"]+ isOneToOne: false+ referencedRelation: "accounts"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_disposalAccountId_fkey"+ columns: ["disposalAccountId"]+ isOneToOne: false+ referencedRelation: "account"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_disposalAccountId_fkey"+ columns: ["disposalAccountId"]+ isOneToOne: false+ referencedRelation: "accounts"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_updatedBy_fkey"+ columns: ["updatedBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ {+ foreignKeyName: "fixedAssetClass_writeDownAccountId_fkey"+ columns: ["writeDownAccountId"]+ isOneToOne: false+ referencedRelation: "account"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_writeDownAccountId_fkey"+ columns: ["writeDownAccountId"]+ isOneToOne: false+ referencedRelation: "accounts"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_writeOffAccountId_fkey"+ columns: ["writeOffAccountId"]+ isOneToOne: false+ referencedRelation: "account"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetClass_writeOffAccountId_fkey"+ columns: ["writeOffAccountId"]+ isOneToOne: false+ referencedRelation: "accounts"+ referencedColumns: ["id"]+ },+ ]+ }+ fixedAssetDisposal: {+ Row: {+ companyId: string+ createdAt: string+ createdBy: string+ disposalDate: string+ disposalMethod: Database["public"]["Enums"]["disposalMethod"]+ fixedAssetId: string+ gainLoss: number+ id: string+ journalId: string | null+ netBookValueAtDisposal: number+ saleProceeds: number+ }+ Insert: {+ companyId: string+ createdAt?: string+ createdBy: string+ disposalDate: string+ disposalMethod: Database["public"]["Enums"]["disposalMethod"]+ fixedAssetId: string+ gainLoss: number+ id?: string+ journalId?: string | null+ netBookValueAtDisposal: number+ saleProceeds?: number+ }+ Update: {+ companyId?: string+ createdAt?: string+ createdBy?: string+ disposalDate?: string+ disposalMethod?: Database["public"]["Enums"]["disposalMethod"]+ fixedAssetId?: string+ gainLoss?: number+ id?: string+ journalId?: string | null+ netBookValueAtDisposal?: number+ saleProceeds?: number+ }+ Relationships: [+ {+ foreignKeyName: "fixedAssetDisposal_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "companies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "company"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "customFieldTables"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "integrations"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_fixedAssetId_fkey"+ columns: ["fixedAssetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_journalId_fkey"+ columns: ["journalId"]+ isOneToOne: false+ referencedRelation: "journal"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetDisposal_journalId_fkey"+ columns: ["journalId"]+ isOneToOne: false+ referencedRelation: "journalEntries"+ referencedColumns: ["id"]+ },+ ]+ }+ fixedAssetUsageLog: {+ Row: {+ companyId: string+ createdAt: string+ createdBy: string+ fixedAssetId: string+ id: string+ periodEnd: string+ periodStart: string+ unitsProduced: number+ }+ Insert: {+ companyId: string+ createdAt?: string+ createdBy: string+ fixedAssetId: string+ id?: string+ periodEnd: string+ periodStart: string+ unitsProduced: number+ }+ Update: {+ companyId?: string+ createdAt?: string+ createdBy?: string+ fixedAssetId?: string+ id?: string+ periodEnd?: string+ periodStart?: string+ unitsProduced?: number+ }+ Relationships: [+ {+ foreignKeyName: "fixedAssetUsageLog_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "companies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "company"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "customFieldTables"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "integrations"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ {+ foreignKeyName: "fixedAssetUsageLog_fixedAssetId_fkey"+ columns: ["fixedAssetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },+ ]+ }fixture: {Row: {approved: boolean@@ -24088,131 +25098,6 @@ export type Database = {},]}- notification: {- Row: {- companyId: string- createdAt: string- description: string | null- digestedInto: string | null- documentId: string | null- documentType: string | null- event: string- from: string | null- id: string- payload: Json- readAt: string | null- seenAt: string | null- title: string- topic: string- userId: string- }- Insert: {- companyId: string- createdAt?: string- description?: string | null- digestedInto?: string | null- documentId?: string | null- documentType?: string | null- event: string- from?: string | null- id?: string- payload?: Json- readAt?: string | null- seenAt?: string | null- title: string- topic: string- userId: string- }- Update: {- companyId?: string- createdAt?: string- description?: string | null- digestedInto?: string | null- documentId?: string | null- documentType?: string | null- event?: string- from?: string | null- id?: string- payload?: Json- readAt?: string | null- seenAt?: string | null- title?: string- topic?: string- userId?: string- }- Relationships: [- {- foreignKeyName: "notification_companyId_fkey"- columns: ["companyId"]- isOneToOne: false- referencedRelation: "companies"- referencedColumns: ["id"]- },- {- foreignKeyName: "notification_companyId_fkey"- columns: ["companyId"]- isOneToOne: false- referencedRelation: "company"- referencedColumns: ["id"]- },- {- foreignKeyName: "notification_companyId_fkey"- columns: ["companyId"]- isOneToOne: false- referencedRelation: "customFieldTables"- referencedColumns: ["companyId"]- },- {- foreignKeyName: "notification_companyId_fkey"- columns: ["companyId"]- isOneToOne: false- referencedRelation: "integrations"- referencedColumns: ["companyId"]- },- {- foreignKeyName: "notification_digestedInto_fkey"- columns: ["digestedInto"]- isOneToOne: false- referencedRelation: "notification"- referencedColumns: ["id"]- },- {- foreignKeyName: "notification_userId_fkey"- columns: ["userId"]- isOneToOne: false- referencedRelation: "employees"- referencedColumns: ["id"]- },- {- foreignKeyName: "notification_userId_fkey"- columns: ["userId"]- isOneToOne: false- referencedRelation: "employeesAcrossCompanies"- referencedColumns: ["id"]- },- {- foreignKeyName: "notification_userId_fkey"- columns: ["userId"]- isOneToOne: false- referencedRelation: "employeeSummary"- referencedColumns: ["id"]- },- {- foreignKeyName: "notification_userId_fkey"- columns: ["userId"]- isOneToOne: false- referencedRelation: "user"- referencedColumns: ["id"]- },- {- foreignKeyName: "notification_userId_fkey"- columns: ["userId"]- isOneToOne: false- referencedRelation: "userDefaults"- referencedColumns: ["userId"]- },- ]- }oauthClient: {Row: {clientId: string@@ -28423,6 +29308,13 @@ export type Database = {referencedRelation: "accounts"referencedColumns: ["id"]},+ {+ foreignKeyName: "purchaseOrderLine_assetId_fkey"+ columns: ["assetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },{foreignKeyName: "purchaseOrderLine_costCenterId_fkey"columns: ["costCenterId"]@@ -33237,6 +34129,144 @@ export type Database = {},]}+ receiptFixedAssetLine: {+ Row: {+ companyId: string+ createdAt: string+ createdBy: string+ id: string+ purchaseOrderLineId: string+ receiptId: string+ received: boolean+ serialNumber: string | null+ updatedAt: string | null+ updatedBy: string | null+ }+ Insert: {+ companyId: string+ createdAt?: string+ createdBy: string+ id?: string+ purchaseOrderLineId: string+ receiptId: string+ received?: boolean+ serialNumber?: string | null+ updatedAt?: string | null+ updatedBy?: string | null+ }+ Update: {+ companyId?: string+ createdAt?: string+ createdBy?: string+ id?: string+ purchaseOrderLineId?: string+ receiptId?: string+ received?: boolean+ serialNumber?: string | null+ updatedAt?: string | null+ updatedBy?: string | null+ }+ Relationships: [+ {+ foreignKeyName: "receiptFixedAssetLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "companies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "company"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "customFieldTables"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "integrations"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_purchaseOrderLineId_fkey"+ columns: ["purchaseOrderLineId"]+ isOneToOne: false+ referencedRelation: "openPurchaseOrderLines"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_purchaseOrderLineId_fkey"+ columns: ["purchaseOrderLineId"]+ isOneToOne: false+ referencedRelation: "purchaseOrderLine"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_purchaseOrderLineId_fkey"+ columns: ["purchaseOrderLineId"]+ isOneToOne: false+ referencedRelation: "purchaseOrderLines"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_receiptId_fkey"+ columns: ["receiptId"]+ isOneToOne: false+ referencedRelation: "receipt"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "receiptFixedAssetLine_receiptId_fkey"+ columns: ["receiptId"]+ isOneToOne: false+ referencedRelation: "receipts"+ referencedColumns: ["id"]+ },+ ]+ }receiptLine: {Row: {companyId: string@@ -34114,6 +35144,13 @@ export type Database = {referencedRelation: "accounts"referencedColumns: ["id"]},+ {+ foreignKeyName: "salesInvoiceLine_assetId_fkey"+ columns: ["assetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },{foreignKeyName: "salesInvoiceLine_companyId_fkey"columns: ["companyId"]@@ -35086,6 +36123,13 @@ export type Database = {referencedRelation: "accounts"referencedColumns: ["id"]},+ {+ foreignKeyName: "salesOrderLine_assetId_fkey"+ columns: ["assetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },{foreignKeyName: "salesOrderLine_createdBy_fkey"columns: ["createdBy"]@@ -36547,7 +37591,7 @@ export type Database = {},]}- searchIndex_PjY5r4hY5NXa8db3oSSoQs: {+ searchIndex_SvN8PSwVgcgrU2W6cCNWXE: {Row: {createdAt: stringdescription: string | null@@ -37493,6 +38537,137 @@ export type Database = {},]}+ shipmentFixedAssetLine: {+ Row: {+ companyId: string+ createdAt: string+ createdBy: string+ id: string+ salesOrderLineId: string+ serialNumber: string | null+ shipmentId: string+ shipped: boolean+ updatedAt: string | null+ updatedBy: string | null+ }+ Insert: {+ companyId: string+ createdAt?: string+ createdBy: string+ id?: string+ salesOrderLineId: string+ serialNumber?: string | null+ shipmentId: string+ shipped?: boolean+ updatedAt?: string | null+ updatedBy?: string | null+ }+ Update: {+ companyId?: string+ createdAt?: string+ createdBy?: string+ id?: string+ salesOrderLineId?: string+ serialNumber?: string | null+ shipmentId?: string+ shipped?: boolean+ updatedAt?: string | null+ updatedBy?: string | null+ }+ Relationships: [+ {+ foreignKeyName: "shipmentFixedAssetLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "companies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "company"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "customFieldTables"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_companyId_fkey"+ columns: ["companyId"]+ isOneToOne: false+ referencedRelation: "integrations"+ referencedColumns: ["companyId"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employees"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeesAcrossCompanies"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "employeeSummary"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "user"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_createdBy_fkey"+ columns: ["createdBy"]+ isOneToOne: false+ referencedRelation: "userDefaults"+ referencedColumns: ["userId"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_salesOrderLineId_fkey"+ columns: ["salesOrderLineId"]+ isOneToOne: false+ referencedRelation: "openSalesOrderLines"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_salesOrderLineId_fkey"+ columns: ["salesOrderLineId"]+ isOneToOne: false+ referencedRelation: "salesOrderLine"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_salesOrderLineId_fkey"+ columns: ["salesOrderLineId"]+ isOneToOne: false+ referencedRelation: "salesOrderLines"+ referencedColumns: ["id"]+ },+ {+ foreignKeyName: "shipmentFixedAssetLine_shipmentId_fkey"+ columns: ["shipmentId"]+ isOneToOne: false+ referencedRelation: "shipment"+ referencedColumns: ["id"]+ },+ ]+ }shipmentLine: {Row: {companyId: string@@ -45744,6 +46919,7 @@ export type Database = {createdBy: stringcustomFields: Json | nulldefaultStandardFactor: Database["public"]["Enums"]["factor"]+ departmentId: string | nulldescription: string | nullid: stringlaborRate: number@@ -45763,6 +46939,7 @@ export type Database = {createdBy: stringcustomFields?: Json | nulldefaultStandardFactor?: Database["public"]["Enums"]["factor"]+ departmentId?: string | nulldescription?: string | nullid?: stringlaborRate?: number@@ -45782,6 +46959,7 @@ export type Database = {createdBy?: stringcustomFields?: Json | nulldefaultStandardFactor?: Database["public"]["Enums"]["factor"]+ departmentId?: string | nulldescription?: string | nullid?: stringlaborRate?: number@@ -45858,6 +47036,13 @@ export type Database = {referencedRelation: "userDefaults"referencedColumns: ["userId"]},+ {+ foreignKeyName: "workCenter_departmentId_fkey"+ columns: ["departmentId"]+ isOneToOne: false+ referencedRelation: "department"+ referencedColumns: ["id"]+ },{foreignKeyName: "workCenter_locationId_fkey"columns: ["locationId"]@@ -51822,14 +53007,14 @@ export type Database = {},{foreignKeyName: "partner_id_fkey"- columns: ["supplierLocationId"]+ columns: ["id"]isOneToOne: falsereferencedRelation: "supplierLocation"referencedColumns: ["id"]},{foreignKeyName: "partner_id_fkey"- columns: ["id"]+ columns: ["supplierLocationId"]isOneToOne: falsereferencedRelation: "supplierLocation"referencedColumns: ["id"]@@ -52273,6 +53458,8 @@ export type Database = {accountId: string | nullaccountName: string | nullassetId: string | null+ assetName: string | null+ assetReadableId: string | nullcompanyId: string | nullconversionFactor: number | nullcostCenterId: string | null@@ -52935,6 +54122,8 @@ export type Database = {accountId: string | nullaccountName: string | nullassetId: string | null+ assetName: string | null+ assetReadableId: string | nullautodeskUrn: string | nullcompanyId: string | nullconversionFactor: number | null@@ -53013,6 +54202,13 @@ export type Database = {referencedRelation: "accounts"referencedColumns: ["id"]},+ {+ foreignKeyName: "purchaseOrderLine_assetId_fkey"+ columns: ["assetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },{foreignKeyName: "purchaseOrderLine_costCenterId_fkey"columns: ["costCenterId"]@@ -53313,14 +54509,14 @@ export type Database = {Relationships: [{foreignKeyName: "address_countryCode_fkey"- columns: ["supplierCountryCode"]+ columns: ["customerCountryCode"]isOneToOne: falsereferencedRelation: "country"referencedColumns: ["alpha2"]},{foreignKeyName: "address_countryCode_fkey"- columns: ["customerCountryCode"]+ columns: ["supplierCountryCode"]isOneToOne: falsereferencedRelation: "country"referencedColumns: ["alpha2"]@@ -56392,6 +57588,8 @@ export type Database = {accountId: string | nulladdOnCost: number | nullassetId: string | null+ assetName: string | null+ assetReadableId: string | nullcompanyId: string | nullconvertedAddOnCost: number | nullconvertedNonTaxableAddOnCost: number | null@@ -56450,6 +57648,13 @@ export type Database = {referencedRelation: "accounts"referencedColumns: ["id"]},+ {+ foreignKeyName: "salesInvoiceLine_assetId_fkey"+ columns: ["assetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },{foreignKeyName: "salesInvoiceLine_companyId_fkey"columns: ["companyId"]@@ -56731,7 +57936,7 @@ export type Database = {Relationships: [{foreignKeyName: "address_countryCode_fkey"- columns: ["invoiceCountryCode"]+ columns: ["shipmentCountryCode"]isOneToOne: falsereferencedRelation: "country"referencedColumns: ["alpha2"]@@ -56745,7 +57950,7 @@ export type Database = {},{foreignKeyName: "address_countryCode_fkey"- columns: ["shipmentCountryCode"]+ columns: ["invoiceCountryCode"]isOneToOne: falsereferencedRelation: "country"referencedColumns: ["alpha2"]@@ -57027,6 +58232,8 @@ export type Database = {accountId: string | nulladdOnCost: number | nullassetId: string | null+ assetName: string | null+ assetReadableId: string | nullautodeskUrn: string | nullcompanyId: string | nullconvertedAddOnCost: number | null@@ -57121,6 +58328,13 @@ export type Database = {referencedRelation: "accounts"referencedColumns: ["id"]},+ {+ foreignKeyName: "salesOrderLine_assetId_fkey"+ columns: ["assetId"]+ isOneToOne: false+ referencedRelation: "fixedAsset"+ referencedColumns: ["id"]+ },{foreignKeyName: "salesOrderLine_createdBy_fkey"columns: ["createdBy"]@@ -57303,14 +58517,14 @@ export type Database = {Relationships: [{foreignKeyName: "address_countryCode_fkey"- columns: ["paymentCountryCode"]+ columns: ["customerCountryCode"]isOneToOne: falsereferencedRelation: "country"referencedColumns: ["alpha2"]},{foreignKeyName: "address_countryCode_fkey"- columns: ["customerCountryCode"]+ columns: ["paymentCountryCode"]isOneToOne: falsereferencedRelation: "country"referencedColumns: ["alpha2"]@@ -60312,6 +61526,8 @@ export type Database = {createdBy: string | nullcustomFields: Json | nulldefaultStandardFactor: Database["public"]["Enums"]["factor"] | null+ departmentId: string | null+ departmentName: string | nulldescription: string | nullid: string | nulllaborRate: number | null@@ -60390,6 +61606,13 @@ export type Database = {referencedRelation: "userDefaults"referencedColumns: ["userId"]},+ {+ foreignKeyName: "workCenter_departmentId_fkey"+ columns: ["departmentId"]+ isOneToOne: false+ referencedRelation: "department"+ referencedColumns: ["id"]+ },{foreignKeyName: "workCenter_locationId_fkey"columns: ["locationId"]@@ -60451,6 +61674,7 @@ export type Database = {createdBy: string | nullcustomFields: Json | nulldefaultStandardFactor: Database["public"]["Enums"]["factor"] | null+ departmentId: string | nulldescription: string | nullid: string | nullisBlocked: boolean | null@@ -60529,6 +61753,13 @@ export type Database = {referencedRelation: "userDefaults"referencedColumns: ["userId"]},+ {+ foreignKeyName: "workCenter_departmentId_fkey"+ columns: ["departmentId"]+ isOneToOne: false+ referencedRelation: "department"+ referencedColumns: ["id"]+ },{foreignKeyName: "workCenter_locationId_fkey"columns: ["locationId"]@@ -62778,6 +64009,10 @@ export type Database = {customRuleTargetType: "item" | "storageUnit" | "workCenter"deadlineType: "No Deadline" | "ASAP" | "Soft Deadline" | "Hard Deadline"demandSourceType: "Sales Order" | "Job Material"+ depreciationMethod:+ | "Straight Line"+ | "Declining Balance"+ | "Units of Production"dimensionEntityType:| "Custom"| "Location"@@ -62787,6 +64022,10 @@ export type Database = {| "Department"| "Employee"| "CostCenter"+ | "WorkCenter"+ | "Process"+ | "FixedAssetClass"+ disposalMethod: "Sale" | "Scrapping"disposition:| "Conditional Acceptance"| "Deviation Accepted"@@ -62867,6 +64106,7 @@ export type Database = {| "Seconds/Piece"| "Total Hours"| "Total Minutes"+ fixedAssetStatus: "Draft" | "Active" | "Fully Depreciated" | "Disposed"fulfillmentType: "Inventory" | "Job"gaugeCalibrationStatus:| "Pending"@@ -62987,6 +64227,8 @@ export type Database = {| "Job Receipt"| "Production Event"| "Job Close"+ | "Asset Depreciation"+ | "Asset Disposal"journalEntryStatus: "Draft" | "Posted" | "Reversed"journalLineDocumentType:| "Receipt"@@ -63005,6 +64247,8 @@ export type Database = {| "Production Event"| "Job Close"kanbanOutput: "label" | "qrcode" | "url"+ macrsConvention: "Half-Year" | "Mid-Quarter"+ macrsPropertyClass: "3" | "5" | "7" | "10" | "15" | "20" | "27.5" | "39"maintenanceDispatchPriority: "Low" | "Medium" | "High" | "Critical"maintenanceDispatchStatus:| "Open"@@ -63266,6 +64510,7 @@ export type Database = {supplierStatusType: "Active" | "Inactive" | "Pending" | "Rejected"supplySourceType: "Purchase Order" | "Production Order"tableViewType: "Public" | "Private"+ taxDepreciationMethod: "Straight Line" | "Declining Balance" | "MACRS"taxExemptionReason:| "Resale"| "Government"@@ -64032,6 +65277,11 @@ export const Constants = {customRuleTargetType: ["item", "storageUnit", "workCenter"],deadlineType: ["No Deadline", "ASAP", "Soft Deadline", "Hard Deadline"],demandSourceType: ["Sales Order", "Job Material"],+ depreciationMethod: [+ "Straight Line",+ "Declining Balance",+ "Units of Production",+ ],dimensionEntityType: ["Custom","Location",@@ -64041,7 +65291,11 @@ export const Constants = {"Department","Employee","CostCenter",+ "WorkCenter",+ "Process",+ "FixedAssetClass",],+ disposalMethod: ["Sale", "Scrapping"],disposition: ["Conditional Acceptance","Deviation Accepted",@@ -64129,6 +65383,7 @@ export const Constants = {"Total Hours","Total Minutes",],+ fixedAssetStatus: ["Draft", "Active", "Fully Depreciated", "Disposed"],fulfillmentType: ["Inventory", "Job"],gaugeCalibrationStatus: ["Pending",@@ -64259,6 +65514,8 @@ export const Constants = {"Job Receipt","Production Event","Job Close",+ "Asset Depreciation",+ "Asset Disposal",],journalEntryStatus: ["Draft", "Posted", "Reversed"],journalLineDocumentType: [@@ -64279,6 +65536,8 @@ export const Constants = {"Job Close",],kanbanOutput: ["label", "qrcode", "url"],+ macrsConvention: ["Half-Year", "Mid-Quarter"],+ macrsPropertyClass: ["3", "5", "7", "10", "15", "20", "27.5", "39"],maintenanceDispatchPriority: ["Low", "Medium", "High", "Critical"],maintenanceDispatchStatus: ["Open",@@ -64566,6 +65825,7 @@ export const Constants = {supplierStatusType: ["Active", "Inactive", "Pending", "Rejected"],supplySourceType: ["Purchase Order", "Production Order"],tableViewType: ["Public", "Private"],+ taxDepreciationMethod: ["Straight Line", "Declining Balance", "MACRS"],taxExemptionReason: ["Resale","Government",diff --git a/packages/database/supabase/functions/post-production-event/index.ts b/packages/database/supabase/functions/post-production-event/index.tsindex 791b7d7625..7abcb6dfd6 100644--- a/packages/database/supabase/functions/post-production-event/index.ts+++ b/packages/database/supabase/functions/post-production-event/index.ts@@ -64,7 +64,7 @@ serve(async (req: Request) => {const [productionEvent, accountDefaults, dimensions] = await Promise.all([client.from("productionEvent")- .select("*, jobOperation!inner(jobId)")+ .select("*, jobOperation!inner(jobId, processId)").eq("id", productionEventId).single(),getDefaultPostingGroup(client, companyId),@@ -73,7 +73,7 @@ serve(async (req: Request) => {.select("id, entityType").eq("companyGroupId", companyRecord.data.companyGroupId).eq("active", true)- .in("entityType", ["ItemPostingGroup", "Location", "Employee"]),+ .in("entityType", ["ItemPostingGroup", "Location", "Employee", "WorkCenter", "Process"]),]);if (productionEvent.error) throw new Error("Failed to fetch production event");@@ -251,6 +251,23 @@ serve(async (req: Request) => {companyId,});}+ if (event.workCenterId && dimensionMap.has("WorkCenter")) {+ dimensionInserts.push({+ journalLineId: jl.id,+ dimensionId: dimensionMap.get("WorkCenter")!,+ valueId: event.workCenterId,+ companyId,+ });+ }+ const processId = (event.jobOperation as any)?.processId as string | null;+ if (processId && dimensionMap.has("Process")) {+ dimensionInserts.push({+ journalLineId: jl.id,+ dimensionId: dimensionMap.get("Process")!,+ valueId: processId,+ companyId,+ });+ }});if (dimensionInserts.length > 0) {diff --git a/packages/database/supabase/functions/post-purchase-invoice/index.ts b/packages/database/supabase/functions/post-purchase-invoice/index.tsindex bfa91fde7c..64fb1f3d93 100644--- a/packages/database/supabase/functions/post-purchase-invoice/index.ts+++ b/packages/database/supabase/functions/post-purchase-invoice/index.ts@@ -424,6 +424,8 @@ serve(async (req: Request) => {"ItemPostingGroup","Location","CostCenter",+ "Process",+ "FixedAssetClass",]),]);@@ -538,8 +540,26 @@ serve(async (req: Request) => {itemPostingGroupId: string | null;locationId: string | null;costCenterId: string | null;+ processId: string | null;+ fixedAssetClassId: string | null;}[] = [];+ const processIdByJobOperationId = new Map<string, string>();+ {+ const jobOpIds = purchaseOrderLines.data+ .map((pol) => pol.jobOperationId)+ .filter((id): id is string => !!id);+ if (jobOpIds.length > 0) {+ const jobOps = await client+ .from("jobOperation")+ .select("id, processId")+ .in("id", jobOpIds);+ for (const op of jobOps.data ?? []) {+ if (op.processId) processIdByJobOperationId.set(op.id, op.processId);+ }+ }+ }+const receiptLineInserts: Omit<Database["public"]["Tables"]["receiptLine"]["Insert"],"receiptId"@@ -796,6 +816,8 @@ serve(async (req: Request) => {itemPostingGroupId: lineItemPostingGroupId,locationId: invoiceLine.locationId ?? null,costCenterId: null,+ processId: null,+ fixedAssetClassId: null,};journalLineDimensionsMeta.push(itemDimMeta, itemDimMeta);}@@ -976,11 +998,16 @@ serve(async (req: Request) => {itemCosts.data.find((cost) => cost.itemId === invoiceLine.itemId)?.itemPostingGroupId ?? null;+ const lineProcessId = purchaseOrderLine?.jobOperationId+ ? processIdByJobOperationId.get(purchaseOrderLine.jobOperationId) ?? null+ : null;const reverseDimMeta = {supplierTypeId: supplier.data.supplierTypeId ?? null,itemPostingGroupId: reverseLineItemPostingGroupId,locationId: invoiceLine.locationId ?? null,costCenterId: null,+ processId: lineProcessId,+ fixedAssetClassId: null,};const reverseJlCount =journalLineInserts.length - jlStartIdxReverse;@@ -1040,11 +1067,16 @@ serve(async (req: Request) => {itemCosts.data.find((cost) => cost.itemId === invoiceLine.itemId)?.itemPostingGroupId ?? null;+ const accrualProcessId = purchaseOrderLine?.jobOperationId+ ? processIdByJobOperationId.get(purchaseOrderLine.jobOperationId) ?? null+ : null;const accrualDimMeta = {supplierTypeId: supplier.data.supplierTypeId ?? null,itemPostingGroupId: accrualLineItemPostingGroupId,locationId: invoiceLine.locationId ?? null,costCenterId: null,+ processId: accrualProcessId,+ fixedAssetClassId: null,};journalLineDimensionsMeta.push(accrualDimMeta, accrualDimMeta);}@@ -1052,9 +1084,221 @@ serve(async (req: Request) => {}break;- case "Fixed Asset":- // TODO: fixed assets+ case "Fixed Asset": {+ if (accountingEnabled && accountDefaults?.data && invoiceLine.assetId) {+ const purchaseOrderLine = purchaseOrderLines.data.find(+ (line) => line.id === invoiceLine.purchaseOrderLineId+ );++ const wasReceived =+ purchaseOrderLine &&+ (purchaseOrderLine.quantityReceived ?? 0) > 0;++ const faRecord = await client+ .from("fixedAsset")+ .select("locationId, fixedAssetClassId")+ .eq("id", invoiceLine.assetId)+ .single();+ const faLocationId = faRecord.data?.locationId ?? null;+ const faClassId = faRecord.data?.fixedAssetClassId ?? null;++ const jlStartIdxFa = journalLineInserts.length;+ let faFixedAssetClassId: string | null = null;++ if (wasReceived && invoiceLine.purchaseOrderLineId) {+ // Receipt was already posted — reverse the GR/IR accrual+ const existingJournalLines =+ journalLinesByPurchaseOrderLine[+ invoiceLine.purchaseOrderLineId+ ] ?? [];++ let receiptCost = 0;+ for (const entry of existingJournalLines) {+ if (+ (entry.amount ?? 0) > 0 &&+ entry.description === "Fixed Asset Acquisition"+ ) {+ receiptCost += Math.abs(entry.amount ?? 0);+ }+ }+ if (receiptCost === 0) {+ for (const entry of existingJournalLines) {+ if (+ (entry.amount ?? 0) < 0 &&+ entry.description === "Goods Received Not Invoiced"+ ) {+ receiptCost += Math.abs(entry.amount ?? 0);+ }+ }+ }++ const invoiceCost = totalLineCostWithWeightedShipping;+ const variance = invoiceCost - receiptCost;++ journalLineReference = nanoid();++ // DR GR/IR at receipt cost (clear the accrual)+ journalLineInserts.push({+ accountId:+ accountDefaults.data.goodsReceivedNotInvoicedAccount,+ description: "GR/IR Clearing",+ amount: debit("liability", receiptCost),+ quantity: invoiceLineQuantityInInventoryUnit,+ documentType: "Invoice",+ documentId: purchaseInvoice.data?.id,+ externalDocumentId: purchaseInvoice.data?.supplierReference,+ documentLineReference: journalReference.to.purchaseInvoice(+ invoiceLine.purchaseOrderLineId+ ),+ journalLineReference,+ companyId,+ });++ if (Math.abs(variance) > 0.005) {+ journalLineInserts.push({+ accountId: accountDefaults.data.purchaseVarianceAccount,+ description: "Purchase Price Variance",+ amount: debit("expense", variance),+ quantity: invoiceLineQuantityInInventoryUnit,+ documentType: "Invoice",+ documentId: purchaseInvoice.data?.id,+ externalDocumentId: purchaseInvoice.data?.supplierReference,+ documentLineReference: journalReference.to.purchaseInvoice(+ invoiceLine.purchaseOrderLineId+ ),+ journalLineReference,+ companyId,+ });+ }++ // CR Payables at invoice cost+ journalLineInserts.push({+ accountId: accountDefaults.data.payablesAccount,+ description: "Accounts Payable",+ amount: credit("liability", invoiceCost),+ quantity: invoiceLineQuantityInInventoryUnit,+ documentType: "Invoice",+ documentId: purchaseInvoice.data?.id,+ externalDocumentId: purchaseInvoice.data?.supplierReference,+ documentLineReference: journalReference.to.purchaseInvoice(+ invoiceLine.purchaseOrderLineId+ ),+ journalLineReference,+ companyId,+ });++ // Update FA acquisition cost if variance exists+ if (Math.abs(variance) > 0.005) {+ const assetRecord = await client+ .from("fixedAsset")+ .select("id, acquisitionCost")+ .eq("id", invoiceLine.assetId)+ .single();+ if (!assetRecord.error) {+ await client+ .from("fixedAsset")+ .update({+ acquisitionCost:+ Number(assetRecord.data.acquisitionCost) + variance,+ updatedBy: userId,+ })+ .eq("id", invoiceLine.assetId);+ }+ }+ faFixedAssetClassId = faClassId;+ } else {+ // Direct invoice (no prior receipt) — full acquisition+ const assetRecord = await client+ .from("fixedAsset")+ .select(+ "id, status, acquisitionDate, depreciationStartDate, acquisitionCost, fixedAssetClassId, fixedAssetClass:fixedAssetClassId(assetAccountId)"+ )+ .eq("id", invoiceLine.assetId)+ .single();++ if (assetRecord.error)+ throw new Error("Failed to fetch fixed asset");++ faFixedAssetClassId = assetRecord.data.fixedAssetClassId ?? null;++ journalLineReference = nanoid();++ journalLineInserts.push({+ accountId: (assetRecord.data.fixedAssetClass as any)+ .assetAccountId,+ description: "Fixed Asset Acquisition",+ amount: debit("asset", totalLineCostWithWeightedShipping),+ quantity: invoiceLineQuantityInInventoryUnit,+ documentType: "Invoice",+ documentId: purchaseInvoice.data?.id,+ externalDocumentId: purchaseInvoice.data?.supplierReference,+ documentLineReference: invoiceLine.purchaseOrderLineId+ ? journalReference.to.purchaseInvoice(+ invoiceLine.purchaseOrderLineId+ )+ : null,+ journalLineReference,+ companyId,+ });++ journalLineInserts.push({+ accountId: accountDefaults.data.payablesAccount,+ description: "Accounts Payable",+ amount: credit("liability", totalLineCostWithWeightedShipping),+ quantity: invoiceLineQuantityInInventoryUnit,+ documentType: "Invoice",+ documentId: purchaseInvoice.data?.id,+ externalDocumentId: purchaseInvoice.data?.supplierReference,+ documentLineReference: invoiceLine.purchaseOrderLineId+ ? journalReference.to.purchaseInvoice(+ invoiceLine.purchaseOrderLineId+ )+ : null,+ journalLineReference,+ companyId,+ });++ const updateData: Record<string, any> = {+ acquisitionCost:+ (Number(assetRecord.data.acquisitionCost) ?? 0) ++ totalLineCostWithWeightedShipping,+ updatedBy: userId,+ };+ if (!assetRecord.data.acquisitionDate) {+ updateData.acquisitionDate = today;+ }+ if (!assetRecord.data.depreciationStartDate) {+ updateData.depreciationStartDate = today;+ }+ if (assetRecord.data.status === "Draft") {+ updateData.status = "Active";+ }++ if (invoiceLine.locationId) {+ updateData.locationId = invoiceLine.locationId;+ }++ await client+ .from("fixedAsset")+ .update(updateData)+ .eq("id", invoiceLine.assetId);+ }++ const faJlCount = journalLineInserts.length - jlStartIdxFa;+ const assetDimMeta = {+ supplierTypeId: supplier.data.supplierTypeId ?? null,+ itemPostingGroupId: null,+ locationId: invoiceLine.locationId ?? purchaseOrderLine?.locationId ?? faLocationId,+ costCenterId: null,+ processId: null,+ fixedAssetClassId: faFixedAssetClassId,+ };+ for (let i = 0; i < faJlCount; i++) {+ journalLineDimensionsMeta.push(assetDimMeta);+ }+ }break;+ }case "Comment":break;case "G/L Account": {@@ -1111,6 +1355,8 @@ serve(async (req: Request) => {itemPostingGroupId: null,locationId: invoiceLine.locationId ?? null,costCenterId: invoiceLine.costCenterId ?? null,+ processId: null,+ fixedAssetClassId: null,};journalLineDimensionsMeta.push(glDimMeta, glDimMeta);}@@ -1339,6 +1585,22 @@ serve(async (req: Request) => {companyId,});}+ if (meta.processId && dimensionMap.has("Process")) {+ journalLineDimensionInserts.push({+ journalLineId: jl.id,+ dimensionId: dimensionMap.get("Process")!,+ valueId: meta.processId,+ companyId,+ });+ }+ if (meta.fixedAssetClassId && dimensionMap.has("FixedAssetClass")) {+ journalLineDimensionInserts.push({+ journalLineId: jl.id,+ dimensionId: dimensionMap.get("FixedAssetClass")!,+ valueId: meta.fixedAssetClassId,+ companyId,+ });+ }});if (journalLineDimensionInserts.length > 0) {diff --git a/packages/database/supabase/functions/post-receipt/index.ts b/packages/database/supabase/functions/post-receipt/index.tsindex 1f6e803bf2..083b45eece 100644--- a/packages/database/supabase/functions/post-receipt/index.ts+++ b/packages/database/supabase/functions/post-receipt/index.ts@@ -85,7 +85,7 @@ serve(async (req: Request) => {.select("id, entityType").eq("companyGroupId", companyGroupId).eq("active", true)- .in("entityType", ["SupplierType", "ItemPostingGroup", "Location"]),+ .in("entityType", ["SupplierType", "ItemPostingGroup", "Location", "Process", "FixedAssetClass"]),]);if (receipt.error) throw new Error("Failed to fetch receipt");@@ -283,6 +283,67 @@ serve(async (req: Request) => {return acc;}, {});+ // Reverse FA PO line received status on void+ const faPoLinesForVoid = purchaseOrderLinesVoid.data.filter(+ (pol) =>+ pol.purchaseOrderLineType === "Fixed Asset" &&+ pol.assetId &&+ pol.receivedComplete+ );++ for (const faPoLine of faPoLinesForVoid) {+ const hasReceiptEntries = originalJournalLines.data.some(+ (jl) =>+ jl.documentLineReference ===+ journalReference.to.receipt(faPoLine.id)+ );++ if (hasReceiptEntries) {+ purchaseOrderLineUpdatesVoid[faPoLine.id] = {+ quantityReceived: 0,+ receivedComplete: false,+ };++ const receiptCost = originalJournalLines.data+ .filter(+ (jl) =>+ jl.documentLineReference ===+ journalReference.to.receipt(faPoLine.id) &&+ (jl.amount ?? 0) > 0+ )+ .reduce((sum, jl) => sum + Math.abs(jl.amount ?? 0), 0);++ const assetRecord = await client+ .from("fixedAsset")+ .select("id, acquisitionCost, status")+ .eq("id", faPoLine.assetId!)+ .single();++ if (!assetRecord.error && assetRecord.data) {+ const newAcquisitionCost = Math.max(+ 0,+ Number(assetRecord.data.acquisitionCost) - receiptCost+ );+ const faUpdate: Record<string, any> = {+ acquisitionCost: newAcquisitionCost,+ updatedBy: userId,+ };+ if (+ newAcquisitionCost === 0 &&+ assetRecord.data.status === "Active"+ ) {+ faUpdate.status = "Draft";+ faUpdate.acquisitionDate = null;+ faUpdate.depreciationStartDate = null;+ }+ await client+ .from("fixedAsset")+ .update(faUpdate)+ .eq("id", faPoLine.assetId!);+ }+ }+ }+const projectedPurchaseOrderLines = purchaseOrderLinesVoid.data.map((line) => {const update = purchaseOrderLineUpdatesVoid[line.id];@@ -535,11 +596,29 @@ serve(async (req: Request) => {supplierTypeId: string | null;itemPostingGroupId: string | null;locationId: string | null;+ processId: string | null;+ fixedAssetClassId: string | null;}[] = [];const isOutsideProcessing =purchaseOrder.data.purchaseOrderType === "Outside Processing";+ const processIdByJobOperationId = new Map<string, string>();+ if (isOutsideProcessing) {+ const jobOpIds = purchaseOrderLines.data+ .map((pol) => pol.jobOperationId)+ .filter((id): id is string => !!id);+ if (jobOpIds.length > 0) {+ const jobOps = await client+ .from("jobOperation")+ .select("id, processId")+ .in("id", jobOpIds);+ for (const op of jobOps.data ?? []) {+ if (op.processId) processIdByJobOperationId.set(op.id, op.processId);+ }+ }+ }+const receiptLinesByPurchaseOrderLineId = receiptLines.data.reduce<Record<string, Database["public"]["Tables"]["receiptLine"]["Row"][]>>((acc, receiptLine) => {@@ -841,6 +920,11 @@ serve(async (req: Request) => {const journalLineReference = nanoid();+ // Find the PO line for this receipt line+ const poLine = purchaseOrderLines.data.find(+ (pol) => pol.id === receiptLine.lineId+ );+// Determine the debit account based on item typelet debitAccount: string;let debitDescription: string;@@ -1083,14 +1167,141 @@ serve(async (req: Request) => {itemCosts.data.find((cost) => cost.itemId === receiptLine.itemId)?.itemPostingGroupId ?? null;+ const poLine = purchaseOrderLines.data.find(+ (pol) => pol.id === receiptLine.lineId+ );+ const lineProcessId = poLine?.jobOperationId+ ? processIdByJobOperationId.get(poLine.jobOperationId) ?? null+ : null;for (let i = 0; i < jlCount; i++) {journalLineDimensionsMeta.push({supplierTypeId: supplier.data.supplierTypeId ?? null,itemPostingGroupId: lineItemPostingGroupId,locationId: receiptLine.locationId ?? null,+ processId: lineProcessId,+ fixedAssetClassId: null,+ });+ }+ }+ }++ // Process Fixed Asset PO lines (no receipt lines — handled directly from PO)+ const { data: receiptFaLines } = await client+ .from("receiptFixedAssetLine")+ .select("purchaseOrderLineId, serialNumber")+ .eq("receiptId", receiptId)+ .eq("received", true);+ const receivedFaPoLineIds = new Set(+ (receiptFaLines ?? []).map((r) => r.purchaseOrderLineId)+ );+ const faSerialNumbers = new Map(+ (receiptFaLines ?? []).map((r) => [r.purchaseOrderLineId, r.serialNumber])+ );++ const faPurchaseOrderLines = purchaseOrderLines.data.filter(+ (pol) =>+ pol.purchaseOrderLineType === "Fixed Asset" &&+ pol.assetId &&+ !pol.receivedComplete &&+ pol.purchaseQuantity &&+ pol.purchaseQuantity > 0 &&+ receivedFaPoLineIds.has(pol.id)+ );++ for (const faPoLine of faPurchaseOrderLines) {+ if (accountingEnabled && accountDefaults?.data) {+ const quantity = faPoLine.purchaseQuantity ?? 1;+ const unitPrice = faPoLine.unitPrice ?? 0;+ const cost = quantity * unitPrice;++ const assetRecord = await client+ .from("fixedAsset")+ .select(+ "id, status, acquisitionDate, depreciationStartDate, acquisitionCost, locationId, fixedAssetClassId, fixedAssetClass:fixedAssetClassId(assetAccountId)"+ )+ .eq("id", faPoLine.assetId!)+ .single();++ if (assetRecord.error)+ throw new Error("Failed to fetch fixed asset");++ const journalLineRef = nanoid();++ journalLineInserts.push({+ accountId: (assetRecord.data.fixedAssetClass as any)+ .assetAccountId,+ description: "Fixed Asset Acquisition",+ amount: debit("asset", cost),+ quantity,+ documentType: "Receipt",+ documentId: receipt.data?.id ?? undefined,+ externalDocumentId:+ purchaseOrder.data?.supplierReference ?? undefined,+ documentLineReference: journalReference.to.receipt(faPoLine.id!),+ journalLineReference: journalLineRef,+ companyId,+ });++ journalLineInserts.push({+ accountId: accountDefaults.data.goodsReceivedNotInvoicedAccount,+ description: "Goods Received Not Invoiced",+ amount: credit("liability", cost),+ quantity,+ documentType: "Receipt",+ documentId: receipt.data?.id ?? undefined,+ externalDocumentId:+ purchaseOrder.data?.supplierReference ?? undefined,+ documentLineReference: journalReference.to.receipt(faPoLine.id!),+ journalLineReference: journalLineRef,+ companyId,+ });++ for (let i = 0; i < 2; i++) {+ journalLineDimensionsMeta.push({+ supplierTypeId: supplier.data.supplierTypeId ?? null,+ itemPostingGroupId: null,+ locationId: faPoLine.locationId ?? receipt.data.locationId ?? assetRecord.data.locationId ?? null,+ processId: null,+ fixedAssetClassId: assetRecord.data.fixedAssetClassId ?? null,});}++ const updateData: Record<string, any> = {+ acquisitionCost:+ (Number(assetRecord.data.acquisitionCost) ?? 0) + cost,+ updatedBy: userId,+ };+ if (!assetRecord.data.acquisitionDate) {+ updateData.acquisitionDate = today;+ }+ if (!assetRecord.data.depreciationStartDate) {+ updateData.depreciationStartDate = today;+ }+ if (assetRecord.data.status === "Draft") {+ updateData.status = "Active";+ }++ const serialNumber = faSerialNumbers.get(faPoLine.id!);+ if (serialNumber) {+ updateData.serialNumber = serialNumber;+ }++ const faLineLocationId = faPoLine.locationId ?? receipt.data.locationId;+ if (faLineLocationId) {+ updateData.locationId = faLineLocationId;+ }++ await client+ .from("fixedAsset")+ .update(updateData)+ .eq("id", faPoLine.assetId!);}++ purchaseOrderLineUpdates[faPoLine.id!] = {+ quantityReceived: faPoLine.purchaseQuantity,+ receivedComplete: true,+ receivedDate: today,+ };}const accountingPeriodId = accountingEnabled@@ -1246,6 +1457,22 @@ serve(async (req: Request) => {companyId,});}+ if (meta.processId && dimensionMap.has("Process")) {+ journalLineDimensionInserts.push({+ journalLineId: jl.id,+ dimensionId: dimensionMap.get("Process")!,+ valueId: meta.processId,+ companyId,+ });+ }+ if (meta.fixedAssetClassId && dimensionMap.has("FixedAssetClass")) {+ journalLineDimensionInserts.push({+ journalLineId: jl.id,+ dimensionId: dimensionMap.get("FixedAssetClass")!,+ valueId: meta.fixedAssetClassId,+ companyId,+ });+ }});if (journalLineDimensionInserts.length > 0) {@@ -1381,6 +1608,7 @@ serve(async (req: Request) => {const journalLineDimensionsMeta: {itemPostingGroupId: string | null;locationId: string | null;+ fixedAssetClassId: string | null;}[] = [];const warehouseTransferLineUpdates: Record<string,@@ -1480,6 +1708,7 @@ serve(async (req: Request) => {journalLineDimensionsMeta.push({itemPostingGroupId: itemCost?.itemPostingGroupId ?? null,locationId: receiptLine.locationId ?? null,+ fixedAssetClassId: null,});}}@@ -1609,6 +1838,14 @@ serve(async (req: Request) => {companyId,});}+ if (meta.fixedAssetClassId && dimensionMap.has("FixedAssetClass")) {+ journalLineDimensionInserts.push({+ journalLineId: jl.id,+ dimensionId: dimensionMap.get("FixedAssetClass")!,+ valueId: meta.fixedAssetClassId,+ companyId,+ });+ }});if (journalLineDimensionInserts.length > 0) {diff --git a/packages/database/supabase/functions/post-sales-invoice/index.ts b/packages/database/supabase/functions/post-sales-invoice/index.tsindex 9c4f9fca11..4a0dce1cc7 100644--- a/packages/database/supabase/functions/post-sales-invoice/index.ts+++ b/packages/database/supabase/functions/post-sales-invoice/index.ts@@ -255,6 +255,7 @@ serve(async (req: Request) => {"ItemPostingGroup","Location","CostCenter",+ "FixedAssetClass",]): null;@@ -270,6 +271,7 @@ serve(async (req: Request) => {itemPostingGroupId: string | null;locationId: string | null;costCenterId: string | null;+ fixedAssetClassId: string | null;}[] = [];// For IC transactions, use IC Receivables (1130) instead of regular AR@@ -414,6 +416,7 @@ serve(async (req: Request) => {itemPostingGroupId: lineItemPostingGroupId,locationId: invoiceLine.locationId ?? null,costCenterId: null,+ fixedAssetClassId: null,});}@@ -450,6 +453,7 @@ serve(async (req: Request) => {itemPostingGroupId: lineItemPostingGroupId,locationId: invoiceLine.locationId ?? null,costCenterId: null,+ fixedAssetClassId: null,});}}@@ -513,6 +517,7 @@ serve(async (req: Request) => {itemPostingGroupId,locationId: invoiceLine.locationId ?? null,costCenterId: null,+ fixedAssetClassId: null,});}}@@ -520,9 +525,291 @@ serve(async (req: Request) => {}break;- case "Fixed Asset":- // TODO: fixed assets+ case "Fixed Asset": {+ if (accountingEnabled && accountDefaults?.data && invoiceLine.assetId) {+ const salesOrderLine = salesOrderLines?.find(+ (sol) => sol.id === invoiceLine.salesOrderLineId+ );+ const wasShipped = salesOrderLine?.sentComplete === true;+ const saleProceeds = totalLineCostWithWeightedShipping;++ if (wasShipped && invoiceLine.salesOrderLineId) {+ // Shipment already handled disposal — just post AR/proceeds+ const assetRecord = await client+ .from("fixedAsset")+ .select(+ "locationId, fixedAssetClassId, fixedAssetClass:fixedAssetClassId(writeOffAccountId)"+ )+ .eq("id", invoiceLine.assetId)+ .single();++ if (assetRecord.error)+ throw new Error("Failed to fetch fixed asset");++ const writeOffAccountId = (+ assetRecord.data.fixedAssetClass as any+ ).writeOffAccountId;++ const arJournalLineReference = nanoid();++ journalLineInserts.push({+ accountId: receivablesAccountId,+ description: "Accounts Receivable",+ amount: debit("asset", saleProceeds),+ quantity: invoiceLineQuantityInInventoryUnit,+ documentType: "Invoice",+ documentId: salesInvoice.data?.id ?? undefined,+ externalDocumentId:+ salesInvoice.data?.customerReference ?? undefined,+ documentLineReference: journalReference.to.salesInvoice(+ invoiceLine.salesOrderLineId+ ),+ journalLineReference: arJournalLineReference,+ intercompanyPartnerId,+ companyId,+ });++ journalLineInserts.push({+ accountId: writeOffAccountId,+ description: "Disposal proceeds",+ amount: credit("expense", saleProceeds),+ quantity: invoiceLineQuantityInInventoryUnit,+ documentType: "Invoice",+ documentId: salesInvoice.data?.id ?? undefined,+ externalDocumentId:+ salesInvoice.data?.customerReference ?? undefined,+ documentLineReference: journalReference.to.salesInvoice(+ invoiceLine.salesOrderLineId+ ),+ journalLineReference: arJournalLineReference,+ intercompanyPartnerId,+ companyId,+ });++ for (let i = 0; i < 2; i++) {+ journalLineDimensionsMeta.push({+ customerTypeId: customer.data.customerTypeId ?? null,+ itemPostingGroupId: null,+ locationId: invoiceLine.locationId ?? salesOrderLine?.locationId ?? assetRecord.data.locationId ?? null,+ costCenterId: null,+ fixedAssetClassId: (assetRecord.data.fixedAssetClass as any)?.id ?? null,+ });+ }++ // Update fixedAssetDisposal with sale proceeds+ const disposal = await client+ .from("fixedAssetDisposal")+ .select("id, netBookValueAtDisposal")+ .eq("fixedAssetId", invoiceLine.assetId)+ .order("createdAt", { ascending: false })+ .limit(1)+ .single();++ if (!disposal.error && disposal.data) {+ const nbv = Number(disposal.data.netBookValueAtDisposal);+ await client+ .from("fixedAssetDisposal")+ .update({+ saleProceeds,+ gainLoss: saleProceeds - nbv,+ })+ .eq("id", disposal.data.id);+ }++ await client+ .from("fixedAsset")+ .update({+ saleProceeds,+ updatedBy: userId,+ })+ .eq("id", invoiceLine.assetId);+ } else {+ // Direct invoice (no prior shipment) — full disposal + AR+ const assetRecord = await client+ .from("fixedAsset")+ .select(+ "id, status, acquisitionCost, accumulatedDepreciation, locationId, fixedAssetClass:fixedAssetClassId(id, assetAccountId, accumulatedDepreciationAccountId, writeOffAccountId)"+ )+ .eq("id", invoiceLine.assetId)+ .single();++ if (assetRecord.error)+ throw new Error(+ "Failed to fetch fixed asset for disposal"+ );++ const assetClass =+ assetRecord.data.fixedAssetClass as any;+ const acquisitionCost =+ Number(assetRecord.data.acquisitionCost) ?? 0;+ const accumulatedDepreciation =+ Number(assetRecord.data.accumulatedDepreciation) ?? 0;+ const nbv = acquisitionCost - accumulatedDepreciation;++ if (accumulatedDepreciation > 0) {+ journalLineReference = nanoid();+ journalLineInserts.push({+ accountId:+ assetClass.accumulatedDepreciationAccountId,+ description: "Clear accumulated depreciation",+ amount: debit("asset", accumulatedDepreciation),+ quantity: 1,+ documentType: "Invoice",+ documentId: salesInvoice.data?.id ?? undefined,+ externalDocumentId:+ salesInvoice.data?.customerReference ?? undefined,+ documentLineReference: invoiceLine.salesOrderLineId+ ? journalReference.to.salesInvoice(+ invoiceLine.salesOrderLineId+ )+ : null,+ journalLineReference,+ companyId,+ });++ journalLineDimensionsMeta.push({+ customerTypeId:+ customer.data.customerTypeId ?? null,+ itemPostingGroupId: null,+ locationId: invoiceLine.locationId ?? salesOrderLine?.locationId ?? assetRecord.data.locationId ?? null,+ costCenterId: null,+ fixedAssetClassId: (assetRecord.data.fixedAssetClass as any)?.id ?? null,+ });+ }++ if (nbv > 0) {+ const nbvJournalLineReference = nanoid();+ journalLineInserts.push({+ accountId: assetClass.writeOffAccountId,+ description: "Write-off remaining book value",+ amount: debit("expense", nbv),+ quantity: 1,+ documentType: "Invoice",+ documentId: salesInvoice.data?.id ?? undefined,+ externalDocumentId:+ salesInvoice.data?.customerReference ?? undefined,+ documentLineReference: invoiceLine.salesOrderLineId+ ? journalReference.to.salesInvoice(+ invoiceLine.salesOrderLineId+ )+ : null,+ journalLineReference: nbvJournalLineReference,+ companyId,+ });++ journalLineDimensionsMeta.push({+ customerTypeId:+ customer.data.customerTypeId ?? null,+ itemPostingGroupId: null,+ locationId: invoiceLine.locationId ?? salesOrderLine?.locationId ?? assetRecord.data.locationId ?? null,+ costCenterId: null,+ fixedAssetClassId: (assetRecord.data.fixedAssetClass as any)?.id ?? null,+ });+ }++ const removeJournalLineReference = nanoid();+ journalLineInserts.push({+ accountId: assetClass.assetAccountId,+ description: "Remove asset at cost",+ amount: credit("asset", acquisitionCost),+ quantity: 1,+ documentType: "Invoice",+ documentId: salesInvoice.data?.id ?? undefined,+ externalDocumentId:+ salesInvoice.data?.customerReference ?? undefined,+ documentLineReference: invoiceLine.salesOrderLineId+ ? journalReference.to.salesInvoice(+ invoiceLine.salesOrderLineId+ )+ : null,+ journalLineReference: removeJournalLineReference,+ companyId,+ });++ journalLineDimensionsMeta.push({+ customerTypeId:+ customer.data.customerTypeId ?? null,+ itemPostingGroupId: null,+ locationId: invoiceLine.locationId ?? salesOrderLine?.locationId ?? null,+ costCenterId: null,+ fixedAssetClassId: (assetRecord.data.fixedAssetClass as any)?.id ?? null,+ });++ const arJournalLineReference = nanoid();+ journalLineInserts.push({+ accountId: receivablesAccountId,+ description: "Accounts Receivable",+ amount: debit("asset", saleProceeds),+ quantity: invoiceLineQuantityInInventoryUnit,+ documentType: "Invoice",+ documentId: salesInvoice.data?.id ?? undefined,+ externalDocumentId:+ salesInvoice.data?.customerReference ?? undefined,+ documentLineReference: invoiceLine.salesOrderLineId+ ? journalReference.to.salesInvoice(+ invoiceLine.salesOrderLineId+ )+ : null,+ journalLineReference: arJournalLineReference,+ intercompanyPartnerId,+ companyId,+ });++ journalLineInserts.push({+ accountId: assetClass.writeOffAccountId,+ description: "Disposal proceeds",+ amount: credit("expense", saleProceeds),+ quantity: invoiceLineQuantityInInventoryUnit,+ documentType: "Invoice",+ documentId: salesInvoice.data?.id ?? undefined,+ externalDocumentId:+ salesInvoice.data?.customerReference ?? undefined,+ documentLineReference: invoiceLine.salesOrderLineId+ ? journalReference.to.salesInvoice(+ invoiceLine.salesOrderLineId+ )+ : null,+ journalLineReference: arJournalLineReference,+ intercompanyPartnerId,+ companyId,+ });++ for (let i = 0; i < 2; i++) {+ journalLineDimensionsMeta.push({+ customerTypeId:+ customer.data.customerTypeId ?? null,+ itemPostingGroupId: null,+ locationId: invoiceLine.locationId ?? salesOrderLine?.locationId ?? assetRecord.data.locationId ?? null,+ costCenterId: null,+ fixedAssetClassId: (assetRecord.data.fixedAssetClass as any)?.id ?? null,+ });+ }++ await client+ .from("fixedAsset")+ .update({+ status: "Disposed",+ disposalDate: today,+ disposalMethod: "Sale",+ saleProceeds,+ updatedBy: userId,+ })+ .eq("id", invoiceLine.assetId);++ await client.from("fixedAssetDisposal").insert({+ fixedAssetId: invoiceLine.assetId,+ disposalMethod: "Sale",+ disposalDate: today,+ saleProceeds,+ netBookValueAtDisposal: nbv,+ gainLoss: saleProceeds - nbv,+ companyId,+ createdBy: userId,+ });+ }+ }break;+ }case "Comment":break;@@ -798,6 +1085,14 @@ serve(async (req: Request) => {companyId,});}+ if (meta.fixedAssetClassId && dimensionMap.has("FixedAssetClass")) {+ journalLineDimensionInserts.push({+ journalLineId: jl.id,+ dimensionId: dimensionMap.get("FixedAssetClass")!,+ valueId: meta.fixedAssetClassId,+ companyId,+ });+ }});if (journalLineDimensionInserts.length > 0) {diff --git a/packages/database/supabase/functions/post-shipment/index.ts b/packages/database/supabase/functions/post-shipment/index.tsindex 0ebb23b3cf..7177c67ca5 100644--- a/packages/database/supabase/functions/post-shipment/index.ts+++ b/packages/database/supabase/functions/post-shipment/index.ts@@ -178,6 +178,7 @@ serve(async (req: Request) => {"ItemPostingGroup","Location","CostCenter",+ "FixedAssetClass",]): null;@@ -201,6 +202,7 @@ serve(async (req: Request) => {itemPostingGroupId: string | null;locationId: string | null;costCenterId: string | null;+ fixedAssetClassId: string | null;}[] = [];const jobUpdates: Record<@@ -212,6 +214,10 @@ serve(async (req: Request) => {const locationId = shipment.data.locationId;for await (const shipmentLine of shipmentLines.data) {+ const salesOrderLine = salesOrderLines.data.find(+ (sol) => sol.id === shipmentLine.lineId+ );+if (shipmentLine.fulfillment?.type === "Job" &&shipmentLine.fulfillment?.jobId@@ -453,6 +459,7 @@ serve(async (req: Request) => {itemPostingGroupId,locationId: shipmentLine.locationId ?? locationId ?? null,costCenterId: salesOrderLine?.costCenterId ?? null,+ fixedAssetClassId: null,});}}@@ -527,6 +534,154 @@ serve(async (req: Request) => {return acc;}, {});+ // Process Fixed Asset SO lines (no shipment lines — handled directly from SO)+ const { data: shipmentFaLines } = await client+ .from("shipmentFixedAssetLine")+ .select("salesOrderLineId, serialNumber")+ .eq("shipmentId", shipmentId)+ .eq("shipped", true);+ const shippedFaSoLineIds = new Set(+ (shipmentFaLines ?? []).map((r) => r.salesOrderLineId)+ );++ const faSalesOrderLines = salesOrderLines.data.filter(+ (sol) =>+ sol.salesOrderLineType === "Fixed Asset" &&+ sol.assetId &&+ !sol.sentComplete &&+ sol.saleQuantity &&+ sol.saleQuantity > 0 &&+ shippedFaSoLineIds.has(sol.id)+ );++ for (const faSoLine of faSalesOrderLines) {+ if (accountingEnabled && accountDefaults?.data) {+ const assetRecord = await client+ .from("fixedAsset")+ .select(+ "id, status, acquisitionCost, accumulatedDepreciation, locationId, fixedAssetClassId, fixedAssetClass:fixedAssetClassId(assetAccountId, accumulatedDepreciationAccountId, writeOffAccountId)"+ )+ .eq("id", faSoLine.assetId!)+ .single();++ if (assetRecord.error)+ throw new Error("Failed to fetch fixed asset for disposal");++ const assetClass = assetRecord.data.fixedAssetClass as any;+ const acquisitionCost =+ Number(assetRecord.data.acquisitionCost) ?? 0;+ const accumulatedDepreciation =+ Number(assetRecord.data.accumulatedDepreciation) ?? 0;+ const nbv = acquisitionCost - accumulatedDepreciation;++ if (accumulatedDepreciation > 0) {+ const jlRef = nanoid();+ journalLineInserts.push({+ accountId: assetClass.accumulatedDepreciationAccountId,+ description: "Clear accumulated depreciation",+ amount: debit("asset", accumulatedDepreciation),+ quantity: 1,+ documentType: "Sales Shipment",+ documentId: shipment.data?.id,+ externalDocumentId:+ salesOrder.data?.customerReference ?? undefined,+ documentLineReference: journalReference.to.shipment(+ faSoLine.id+ ),+ journalLineReference: jlRef,+ companyId,+ });++ journalLineDimensionsMeta.push({+ customerTypeId: customer.data.customerTypeId ?? null,+ itemPostingGroupId: null,+ locationId: locationId ?? assetRecord.data.locationId ?? null,+ costCenterId: faSoLine.costCenterId ?? null,+ fixedAssetClassId: assetRecord.data.fixedAssetClassId ?? null,+ });+ }++ if (nbv > 0) {+ const nbvJlRef = nanoid();+ journalLineInserts.push({+ accountId: assetClass.writeOffAccountId,+ description: "Write-off remaining book value",+ amount: debit("expense", nbv),+ quantity: 1,+ documentType: "Sales Shipment",+ documentId: shipment.data?.id,+ externalDocumentId:+ salesOrder.data?.customerReference ?? undefined,+ documentLineReference: journalReference.to.shipment(+ faSoLine.id+ ),+ journalLineReference: nbvJlRef,+ companyId,+ });++ journalLineDimensionsMeta.push({+ customerTypeId: customer.data.customerTypeId ?? null,+ itemPostingGroupId: null,+ locationId: locationId ?? assetRecord.data.locationId ?? null,+ costCenterId: faSoLine.costCenterId ?? null,+ fixedAssetClassId: assetRecord.data.fixedAssetClassId ?? null,+ });+ }++ const removeJlRef = nanoid();+ journalLineInserts.push({+ accountId: assetClass.assetAccountId,+ description: "Remove asset at cost",+ amount: credit("asset", acquisitionCost),+ quantity: 1,+ documentType: "Sales Shipment",+ documentId: shipment.data?.id,+ externalDocumentId:+ salesOrder.data?.customerReference ?? undefined,+ documentLineReference: journalReference.to.shipment(+ faSoLine.id+ ),+ journalLineReference: removeJlRef,+ companyId,+ });++ journalLineDimensionsMeta.push({+ customerTypeId: customer.data.customerTypeId ?? null,+ itemPostingGroupId: null,+ locationId: locationId ?? assetRecord.data.locationId ?? null,+ costCenterId: faSoLine.costCenterId ?? null,+ fixedAssetClassId: assetRecord.data.fixedAssetClassId ?? null,+ });++ await client+ .from("fixedAsset")+ .update({+ status: "Disposed",+ disposalDate: today,+ disposalMethod: "Sale",+ updatedBy: userId,+ })+ .eq("id", faSoLine.assetId!);++ await client.from("fixedAssetDisposal").insert({+ fixedAssetId: faSoLine.assetId!,+ disposalMethod: "Sale",+ disposalDate: today,+ saleProceeds: 0,+ netBookValueAtDisposal: nbv,+ gainLoss: -nbv,+ companyId,+ createdBy: userId,+ });+ }++ salesOrderLineUpdates[faSoLine.id] = {+ quantitySent: faSoLine.saleQuantity,+ sentComplete: true,+ sentDate: today,+ };+ }+const trackedEntitySplits: Record<string,{@@ -1081,6 +1236,14 @@ serve(async (req: Request) => {companyId,});}+ if (meta.fixedAssetClassId && dimensionMap.has("FixedAssetClass")) {+ journalLineDimensionInserts.push({+ journalLineId: jl.id,+ dimensionId: dimensionMap.get("FixedAssetClass")!,+ valueId: meta.fixedAssetClassId,+ companyId,+ });+ }});if (journalLineDimensionInserts.length > 0) {@@ -1648,7 +1811,12 @@ serve(async (req: Request) => {if (!shipment.data.sourceDocumentId)throw new Error("Shipment has no sourceDocumentId");- const [salesOrder, salesOrderLines] = await Promise.all([+ const [+ salesOrder,+ salesOrderLines,+ originalJournalLines,+ accountingSettings,+ ] = await Promise.all([client.from("salesOrder").select("*")@@ -1658,11 +1826,46 @@ serve(async (req: Request) => {.from("salesOrderLine").select("*").eq("salesOrderId", shipment.data.sourceDocumentId),+ client+ .from("journalLine")+ .select("*")+ .eq("documentId", shipmentId)+ .eq("documentType", "Sales Shipment")+ .eq("companyId", companyId),+ client+ .from("companySettings")+ .select("accountingEnabled")+ .eq("id", companyId)+ .single(),]);if (salesOrder.error)throw new Error("Failed to fetch sales order");if (salesOrderLines.error)throw new Error("Failed to fetch sales order lines");+ if (originalJournalLines.error)+ throw new Error("Failed to fetch journal lines");++ const accountingEnabled =+ accountingSettings.data?.accountingEnabled ?? false;++ const reversingJournalLines: Omit<+ Database["public"]["Tables"]["journalLine"]["Insert"],+ "journalId"+ >[] = accountingEnabled+ ? originalJournalLines.data.map((entry) => ({+ accountId: entry.accountId,+ accrual: entry.accrual,+ description: `VOID: ${entry.description}`,+ amount: -entry.amount,+ quantity: -entry.quantity,+ documentType: entry.documentType,+ documentId: entry.documentId,+ externalDocumentId: entry.externalDocumentId,+ documentLineReference: entry.documentLineReference,+ journalLineReference: entry.journalLineReference,+ companyId,+ }))+ : [];const customer = await client.from("customer")@@ -1902,6 +2105,46 @@ serve(async (req: Request) => {return acc;}, {});+ // Reverse FA SO line disposals on void+ const faSoLinesForVoid = salesOrderLines.data.filter(+ (sol) =>+ sol.salesOrderLineType === "Fixed Asset" &&+ sol.assetId &&+ sol.sentComplete+ );++ for (const faSoLine of faSoLinesForVoid) {+ const hasShipmentEntries = originalJournalLines.data.some(+ (jl) =>+ jl.documentLineReference ===+ journalReference.to.shipment(faSoLine.id)+ );++ if (hasShipmentEntries) {+ salesOrderLineUpdates[faSoLine.id] = {+ quantitySent: 0,+ sentComplete: false,+ sentDate: null,+ };++ await client+ .from("fixedAsset")+ .update({+ status: "Active",+ disposalDate: null,+ disposalMethod: null,+ updatedBy: userId,+ })+ .eq("id", faSoLine.assetId!);++ await client+ .from("fixedAssetDisposal")+ .delete()+ .eq("fixedAssetId", faSoLine.assetId!)+ .eq("companyId", companyId);+ }+ }+// Restore tracked entities to available statusconst trackedEntityUpdates =shipmentLineTracking.data?.reduce<@@ -1927,6 +2170,11 @@ serve(async (req: Request) => {return acc;}, {}) ?? {};+ const accountingPeriodId =+ accountingEnabled && reversingJournalLines.length > 0+ ? await getCurrentAccountingPeriod(client, companyId, db)+ : null;+await db.transaction().execute(async (trx) => {// Update sales order lines to reverse shipped quantitiesfor await (const [salesOrderLineId, update] of Object.entries(@@ -2063,6 +2311,46 @@ serve(async (req: Request) => {.execute();}}++ // Create reversing journal entries+ if (+ accountingEnabled &&+ reversingJournalLines.length > 0 &&+ accountingPeriodId+ ) {+ const voidJournalEntryId = await getNextSequence(+ trx,+ "journalEntry",+ companyId+ );++ const voidJournalResult = await trx+ .insertInto("journal")+ .values({+ journalEntryId: voidJournalEntryId,+ accountingPeriodId,+ description: `VOID: Sales Shipment ${shipment.data.shipmentId}`,+ postingDate: today,+ companyId,+ sourceType: "Sales Shipment",+ status: "Posted",+ postedAt: new Date().toISOString(),+ postedBy: userId,+ createdBy: userId,+ })+ .returning(["id"])+ .executeTakeFirstOrThrow();++ await trx+ .insertInto("journalLine")+ .values(+ reversingJournalLines.map((line) => ({+ ...line,+ journalId: voidJournalResult.id,+ }))+ )+ .execute();+ }});break;}diff --git a/packages/database/supabase/functions/seed-company/index.ts b/packages/database/supabase/functions/seed-company/index.tsindex ce40456711..90a957e74f 100644--- a/packages/database/supabase/functions/seed-company/index.ts+++ b/packages/database/supabase/functions/seed-company/index.ts@@ -10,6 +10,7 @@ import {dimensions,failureModes,fiscalYearSettings,+ fixedAssetClasses,gaugeTypes,groupCompanyTemplate,groups,@@ -334,6 +335,28 @@ serve(async (req: Request) => {.values([{ ...fiscalYearSettings, companyId }]).execute();+ await trx+ .insertInto("fixedAssetClass")+ .values(+ fixedAssetClasses.map((fac) => ({+ name: fac.name,+ depreciationMethod: fac.depreciationMethod,+ usefulLifeMonths: fac.usefulLifeMonths,+ residualValuePercent: fac.residualValuePercent,+ assetAccountId: accountIdByKey[fac.assetAccount]!,+ accumulatedDepreciationAccountId:+ accountIdByKey[fac.accumulatedDepreciationAccount]!,+ depreciationExpenseAccountId:+ accountIdByKey[fac.depreciationExpenseAccount]!,+ writeOffAccountId: accountIdByKey[fac.writeOffAccount]!,+ writeDownAccountId: accountIdByKey[fac.writeDownAccount]!,+ disposalAccountId: accountIdByKey[fac.disposalAccount]!,+ companyId,+ createdBy: userId,+ }))+ )+ .execute();+const user = await client.from("userPermission").select("permissions")diff --git a/packages/database/supabase/functions/shared/get-accounting-period.ts b/packages/database/supabase/functions/shared/get-accounting-period.tsindex a8eba71688..6aad606096 100644--- a/packages/database/supabase/functions/shared/get-accounting-period.ts+++ b/packages/database/supabase/functions/shared/get-accounting-period.ts@@ -77,18 +77,18 @@ export async function getCurrentAccountingPeriod<T>(return currentAccountingPeriod.data.id;}- await db.transaction().execute(async (trx) => {- const year = new Date().getFullYear();- const month = new Date().getMonth() + 1;- const startDate = `${year}-${month.toString().padStart(2, "0")}-01`;- let endDate = `${year}-${month.toString().padStart(2, "0")}-${- daysInMonths[month]- }`;-- if (month === 2 && isLeapYear(year)) {- endDate = `${year}-${month.toString().padStart(2, "0")}-29`;- }+ const year = new Date().getFullYear();+ const month = new Date().getMonth() + 1;+ const startDate = `${year}-${month.toString().padStart(2, "0")}-01`;+ let endDate = `${year}-${month.toString().padStart(2, "0")}-${+ daysInMonths[month]+ }`;++ if (month === 2 && isLeapYear(year)) {+ endDate = `${year}-${month.toString().padStart(2, "0")}-29`;+ }+ const newPeriod = await db.transaction().execute(async (trx) => {await trx.updateTable("accountingPeriod").set({ status: "Inactive" })@@ -96,7 +96,7 @@ export async function getCurrentAccountingPeriod<T>(.where("companyId", "=", companyId).execute();- await trx+ const result = await trx.insertInto("accountingPeriod").values({startDate,@@ -105,23 +105,11 @@ export async function getCurrentAccountingPeriod<T>(status: "Active",createdBy: "system",})- .execute();- });-- // get the current accounting period now that we've inserted them- currentAccountingPeriod = await client- .from("accountingPeriod")- .select("*")- // .gte("startDate", d.toString())- // .lte("endDate", d.toString())- .gte("endDate", d)- .lte("startDate", d)- .eq("companyId", companyId)- .single();+ .returning("id")+ .executeTakeFirstOrThrow();- if (currentAccountingPeriod.error || !currentAccountingPeriod.data) {- throw new Error("Current accounting period not found");- }+ return result;+ });- return currentAccountingPeriod.data.id;+ return newPeriod.id;}diff --git a/packages/database/supabase/migrations/20260524143826_fixed-asset-enums.sql b/packages/database/supabase/migrations/20260524143826_fixed-asset-enums.sqlnew file mode 100644index 0000000000..e9c08b1755--- /dev/null+++ b/packages/database/supabase/migrations/20260524143826_fixed-asset-enums.sql@@ -0,0 +1,5 @@+-- Enum additions that must be committed before use in the next migration+ALTER TYPE "journalEntrySourceType" ADD VALUE IF NOT EXISTS 'Asset Depreciation';+ALTER TYPE "journalEntrySourceType" ADD VALUE IF NOT EXISTS 'Asset Disposal';+ALTER TYPE "dimensionEntityType" ADD VALUE IF NOT EXISTS 'WorkCenter';+ALTER TYPE "dimensionEntityType" ADD VALUE IF NOT EXISTS 'Process';diff --git a/packages/database/supabase/migrations/20260524143827_fixed-assets.sql b/packages/database/supabase/migrations/20260524143827_fixed-assets.sqlnew file mode 100644index 0000000000..fa38586f02--- /dev/null+++ b/packages/database/supabase/migrations/20260524143827_fixed-assets.sql@@ -0,0 +1,766 @@+-- Fixed Assets Module+-- Adds fixed asset tracking with book and tax depreciation,+-- purchase/sales order integration, and receipt/shipment lines.+-- NOTE: enum ADD VALUE statements are in 20260524143826_fixed-asset-enums.sql++-- New enums (CREATE TYPE is fine within a transaction)+CREATE TYPE "fixedAssetStatus" AS ENUM (+ 'Draft',+ 'Active',+ 'Fully Depreciated',+ 'Disposed'+);++CREATE TYPE "depreciationMethod" AS ENUM (+ 'Straight Line',+ 'Declining Balance',+ 'Units of Production'+);++CREATE TYPE "disposalMethod" AS ENUM (+ 'Sale',+ 'Scrapping'+);++CREATE TYPE "taxDepreciationMethod" AS ENUM (+ 'Straight Line',+ 'Declining Balance',+ 'MACRS'+);++CREATE TYPE "macrsPropertyClass" AS ENUM (+ '3',+ '5',+ '7',+ '10',+ '15',+ '20',+ '27.5',+ '39'+);++CREATE TYPE "macrsConvention" AS ENUM (+ 'Half-Year',+ 'Mid-Quarter'+);++-- Company settings: tax depreciation toggle and rate+ALTER TABLE "companySettings"+ ADD COLUMN "assetTaxDepreciationEnabled" BOOLEAN NOT NULL DEFAULT FALSE,+ ADD COLUMN "assetTaxRate" NUMERIC(5,2) NULL;++-- Account defaults: deferred tax accounts+ALTER TABLE "accountDefault"+ ADD COLUMN "deferredTaxLiabilityAccountId" TEXT NULL REFERENCES "account"("id"),+ ADD COLUMN "deferredTaxExpenseAccountId" TEXT NULL REFERENCES "account"("id");++-- Seed Deferred Tax Expense account and set defaults+DO $$+DECLARE+ cg RECORD;+ parent_id TEXT;+ dtl_id TEXT;+ dte_id TEXT;+BEGIN+ FOR cg IN SELECT id FROM "companyGroup" LOOP+ SELECT a.id INTO parent_id+ FROM "account" a+ WHERE a."companyGroupId" = cg.id+ AND a.number = '7000'+ AND a."isGroup" = true+ LIMIT 1;++ INSERT INTO "account" (+ number, name, "isGroup", "accountType", "incomeBalance",+ class, "parentId", "companyGroupId", "createdBy"+ ) VALUES (+ '7090', 'Deferred Tax Expense', false, 'Other Expense', 'Income Statement',+ 'Expense', parent_id, cg.id, 'system'+ ) RETURNING id INTO dte_id;++ SELECT a.id INTO dtl_id+ FROM "account" a+ WHERE a."companyGroupId" = cg.id+ AND a.number = '2420'+ AND a."isGroup" = false+ LIMIT 1;++ UPDATE "accountDefault" ad+ SET "deferredTaxLiabilityAccountId" = dtl_id,+ "deferredTaxExpenseAccountId" = dte_id+ FROM "company" c+ WHERE c.id = ad."companyId"+ AND c."companyGroupId" = cg.id;+ END LOOP;+END $$;++-- Asset Class table+CREATE TABLE "fixedAssetClass" (+ "id" TEXT NOT NULL DEFAULT xid(),+ "name" TEXT NOT NULL,+ "description" TEXT,+ "depreciationMethod" "depreciationMethod" NOT NULL DEFAULT 'Straight Line',+ "usefulLifeMonths" INTEGER NOT NULL DEFAULT 60,+ "residualValuePercent" NUMERIC NOT NULL DEFAULT 0,+ "assetAccountId" TEXT NOT NULL,+ "accumulatedDepreciationAccountId" TEXT NOT NULL,+ "depreciationExpenseAccountId" TEXT NOT NULL,+ "writeOffAccountId" TEXT NOT NULL,+ "writeDownAccountId" TEXT NOT NULL,+ "disposalAccountId" TEXT NOT NULL,+ "taxDepreciationMethod" "taxDepreciationMethod" NULL,+ "taxUsefulLifeMonths" INTEGER NULL,+ "taxResidualValuePercent" NUMERIC(5,2) NULL,+ "macrsPropertyClass" "macrsPropertyClass" NULL,+ "macrsConvention" "macrsConvention" NULL DEFAULT 'Half-Year',+ "bonusDepreciationPercent" NUMERIC(5,2) NULL DEFAULT 0,+ "companyId" TEXT NOT NULL,+ "createdAt" TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW(),+ "createdBy" TEXT NOT NULL,+ "updatedAt" TIMESTAMP WITH TIME ZONE,+ "updatedBy" TEXT,+ "customFields" JSONB,++ CONSTRAINT "fixedAssetClass_pkey" PRIMARY KEY ("id"),+ CONSTRAINT "fixedAssetClass_name_companyId_key" UNIQUE ("name", "companyId"),+ CONSTRAINT "fixedAssetClass_assetAccountId_fkey" FOREIGN KEY ("assetAccountId") REFERENCES "account" ("id") ON DELETE RESTRICT ON UPDATE CASCADE,+ CONSTRAINT "fixedAssetClass_accumulatedDepreciationAccountId_fkey" FOREIGN KEY ("accumulatedDepreciationAccountId") REFERENCES "account" ("id") ON DELETE RESTRICT ON UPDATE CASCADE,+ CONSTRAINT "fixedAssetClass_depreciationExpenseAccountId_fkey" FOREIGN KEY ("depreciationExpenseAccountId") REFERENCES "account" ("id") ON DELETE RESTRICT ON UPDATE CASCADE,+ CONSTRAINT "fixedAssetClass_writeOffAccountId_fkey" FOREIGN KEY ("writeOffAccountId") REFERENCES "account" ("id") ON DELETE RESTRICT ON UPDATE CASCADE,+ CONSTRAINT "fixedAssetClass_writeDownAccountId_fkey" FOREIGN KEY ("writeDownAccountId") REFERENCES "account" ("id") ON DELETE RESTRICT ON UPDATE CASCADE,+ CONSTRAINT "fixedAssetClass_disposalAccountId_fkey" FOREIGN KEY ("disposalAccountId") REFERENCES "account" ("id") ON DELETE RESTRICT ON UPDATE CASCADE,+ CONSTRAINT "fixedAssetClass_companyId_fkey" FOREIGN KEY ("companyId") REFERENCES "company" ("id") ON DELETE CASCADE ON UPDATE CASCADE,+ CONSTRAINT "fixedAssetClass_createdBy_fkey" FOREIGN KEY ("createdBy") REFERENCES "user" ("id") ON DELETE RESTRICT,+ CONSTRAINT "fixedAssetClass_updatedBy_fkey" FOREIGN KEY ("updatedBy") REFERENCES "user" ("id") ON DELETE RESTRICT+);++CREATE INDEX "fixedAssetClass_companyId_idx" ON "fixedAssetClass" ("companyId");++ALTER TABLE "fixedAssetClass" ENABLE ROW LEVEL SECURITY;++CREATE POLICY "SELECT" ON "public"."fixedAssetClass"+ FOR SELECT USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_view'))::text[]+ )+ );++CREATE POLICY "INSERT" ON "public"."fixedAssetClass"+ FOR INSERT WITH CHECK (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_create'))::text[]+ )+ );++CREATE POLICY "UPDATE" ON "public"."fixedAssetClass"+ FOR UPDATE USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_update'))::text[]+ )+ );++CREATE POLICY "DELETE" ON "public"."fixedAssetClass"+ FOR DELETE USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_delete'))::text[]+ )+ );++-- Fixed Asset table+CREATE TABLE "fixedAsset" (+ "id" TEXT NOT NULL DEFAULT xid(),+ "fixedAssetId" TEXT NOT NULL,+ "fixedAssetClassId" TEXT NOT NULL,+ "name" TEXT NOT NULL,+ "description" TEXT,+ "serialNumber" TEXT,+ "status" "fixedAssetStatus" NOT NULL DEFAULT 'Draft',+ "depreciationMethod" "depreciationMethod" NOT NULL DEFAULT 'Straight Line',+ "usefulLifeMonths" INTEGER NOT NULL DEFAULT 60,+ "residualValuePercent" NUMERIC NOT NULL DEFAULT 0,+ "taxDepreciationMethod" "taxDepreciationMethod",+ "taxUsefulLifeMonths" INTEGER,+ "taxResidualValuePercent" NUMERIC(5,2),+ "macrsPropertyClass" "macrsPropertyClass",+ "macrsConvention" "macrsConvention" DEFAULT 'Half-Year',+ "bonusDepreciationPercent" NUMERIC(5,2) DEFAULT 0,+ "acquisitionCost" NUMERIC NOT NULL DEFAULT 0,+ "acquisitionDate" DATE,+ "depreciationStartDate" DATE,+ "accumulatedDepreciation" NUMERIC NOT NULL DEFAULT 0,+ "accumulatedTaxDepreciation" NUMERIC NOT NULL DEFAULT 0,+ "assetLifetimeUsage" NUMERIC,+ "locationId" TEXT,+ "disposalDate" DATE,+ "disposalMethod" "disposalMethod",+ "saleProceeds" NUMERIC,+ "companyId" TEXT NOT NULL,+ "createdAt" TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW(),+ "createdBy" TEXT NOT NULL,+ "updatedAt" TIMESTAMP WITH TIME ZONE,+ "updatedBy" TEXT,+ "notes" JSONB,+ "customFields" JSONB,++ CONSTRAINT "fixedAsset_pkey" PRIMARY KEY ("id"),+ CONSTRAINT "fixedAsset_fixedAssetId_companyId_key" UNIQUE ("fixedAssetId", "companyId"),+ CONSTRAINT "fixedAsset_fixedAssetClassId_fkey" FOREIGN KEY ("fixedAssetClassId") REFERENCES "fixedAssetClass" ("id") ON DELETE RESTRICT ON UPDATE CASCADE,+ CONSTRAINT "fixedAsset_locationId_fkey" FOREIGN KEY ("locationId") REFERENCES "location" ("id") ON DELETE SET NULL ON UPDATE CASCADE,+ CONSTRAINT "fixedAsset_companyId_fkey" FOREIGN KEY ("companyId") REFERENCES "company" ("id") ON DELETE CASCADE ON UPDATE CASCADE,+ CONSTRAINT "fixedAsset_createdBy_fkey" FOREIGN KEY ("createdBy") REFERENCES "user" ("id") ON DELETE RESTRICT,+ CONSTRAINT "fixedAsset_updatedBy_fkey" FOREIGN KEY ("updatedBy") REFERENCES "user" ("id") ON DELETE RESTRICT+);++CREATE INDEX "fixedAsset_companyId_idx" ON "fixedAsset" ("companyId");+CREATE INDEX "fixedAsset_fixedAssetClassId_idx" ON "fixedAsset" ("fixedAssetClassId");+CREATE INDEX "fixedAsset_status_idx" ON "fixedAsset" ("companyId", "status");++ALTER TABLE "fixedAsset" ENABLE ROW LEVEL SECURITY;++CREATE POLICY "SELECT" ON "public"."fixedAsset"+ FOR SELECT USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_view'))::text[]+ )+ );++CREATE POLICY "INSERT" ON "public"."fixedAsset"+ FOR INSERT WITH CHECK (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_create'))::text[]+ )+ );++CREATE POLICY "UPDATE" ON "public"."fixedAsset"+ FOR UPDATE USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_update'))::text[]+ )+ );++CREATE POLICY "DELETE" ON "public"."fixedAsset"+ FOR DELETE USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_delete'))::text[]+ )+ );++-- FK from order/invoice lines to fixedAsset+ALTER TABLE "purchaseOrderLine" ADD CONSTRAINT "purchaseOrderLine_assetId_fkey"+ FOREIGN KEY ("assetId") REFERENCES "fixedAsset" ("id") ON DELETE SET NULL ON UPDATE CASCADE;++ALTER TABLE "salesOrderLine" ADD CONSTRAINT "salesOrderLine_assetId_fkey"+ FOREIGN KEY ("assetId") REFERENCES "fixedAsset"("id") ON DELETE SET NULL ON UPDATE CASCADE;++ALTER TABLE "salesInvoiceLine" ADD CONSTRAINT "salesInvoiceLine_assetId_fkey"+ FOREIGN KEY ("assetId") REFERENCES "fixedAsset"("id") ON DELETE SET NULL ON UPDATE CASCADE;++-- Depreciation Run table+CREATE TABLE "depreciationRun" (+ "id" TEXT NOT NULL DEFAULT xid(),+ "depreciationRunId" TEXT NOT NULL,+ "periodEnd" DATE NOT NULL,+ "status" TEXT NOT NULL DEFAULT 'Draft',+ "postedAt" TIMESTAMP WITH TIME ZONE,+ "postedBy" TEXT,+ "companyId" TEXT NOT NULL,+ "createdAt" TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW(),+ "createdBy" TEXT NOT NULL,++ CONSTRAINT "depreciationRun_pkey" PRIMARY KEY ("id"),+ CONSTRAINT "depreciationRun_depreciationRunId_companyId_key" UNIQUE ("depreciationRunId", "companyId"),+ CONSTRAINT "depreciationRun_postedBy_fkey" FOREIGN KEY ("postedBy") REFERENCES "user" ("id") ON DELETE RESTRICT,+ CONSTRAINT "depreciationRun_companyId_fkey" FOREIGN KEY ("companyId") REFERENCES "company" ("id") ON DELETE CASCADE ON UPDATE CASCADE,+ CONSTRAINT "depreciationRun_createdBy_fkey" FOREIGN KEY ("createdBy") REFERENCES "user" ("id") ON DELETE RESTRICT,+ CONSTRAINT "depreciationRun_status_check" CHECK ("status" IN ('Draft', 'Posted'))+);++CREATE INDEX "depreciationRun_companyId_idx" ON "depreciationRun" ("companyId");++ALTER TABLE "depreciationRun" ENABLE ROW LEVEL SECURITY;++CREATE POLICY "SELECT" ON "public"."depreciationRun"+ FOR SELECT USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_view'))::text[]+ )+ );++CREATE POLICY "INSERT" ON "public"."depreciationRun"+ FOR INSERT WITH CHECK (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_create'))::text[]+ )+ );++CREATE POLICY "UPDATE" ON "public"."depreciationRun"+ FOR UPDATE USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_update'))::text[]+ )+ );++CREATE POLICY "DELETE" ON "public"."depreciationRun"+ FOR DELETE USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_delete'))::text[]+ )+ );++-- Depreciation Run Line table+CREATE TABLE "depreciationRunLine" (+ "id" TEXT NOT NULL DEFAULT xid(),+ "depreciationRunId" TEXT NOT NULL,+ "fixedAssetId" TEXT NOT NULL,+ "amount" NUMERIC NOT NULL,+ "taxAmount" NUMERIC NULL,+ "journalId" TEXT,+ "companyId" TEXT NOT NULL,++ CONSTRAINT "depreciationRunLine_pkey" PRIMARY KEY ("id"),+ CONSTRAINT "depreciationRunLine_depreciationRunId_fkey" FOREIGN KEY ("depreciationRunId") REFERENCES "depreciationRun" ("id") ON DELETE CASCADE ON UPDATE CASCADE,+ CONSTRAINT "depreciationRunLine_fixedAssetId_fkey" FOREIGN KEY ("fixedAssetId") REFERENCES "fixedAsset" ("id") ON DELETE RESTRICT ON UPDATE CASCADE,+ CONSTRAINT "depreciationRunLine_journalId_fkey" FOREIGN KEY ("journalId") REFERENCES "journal" ("id") ON DELETE SET NULL ON UPDATE CASCADE,+ CONSTRAINT "depreciationRunLine_companyId_fkey" FOREIGN KEY ("companyId") REFERENCES "company" ("id") ON DELETE CASCADE ON UPDATE CASCADE+);++CREATE INDEX "depreciationRunLine_depreciationRunId_idx" ON "depreciationRunLine" ("depreciationRunId");+CREATE INDEX "depreciationRunLine_fixedAssetId_idx" ON "depreciationRunLine" ("fixedAssetId");++ALTER TABLE "depreciationRunLine" ENABLE ROW LEVEL SECURITY;++CREATE POLICY "SELECT" ON "public"."depreciationRunLine"+ FOR SELECT USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_view'))::text[]+ )+ );++CREATE POLICY "INSERT" ON "public"."depreciationRunLine"+ FOR INSERT WITH CHECK (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_create'))::text[]+ )+ );++CREATE POLICY "UPDATE" ON "public"."depreciationRunLine"+ FOR UPDATE USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_update'))::text[]+ )+ );++CREATE POLICY "DELETE" ON "public"."depreciationRunLine"+ FOR DELETE USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_delete'))::text[]+ )+ );++-- Fixed Asset Disposal table+CREATE TABLE "fixedAssetDisposal" (+ "id" TEXT NOT NULL DEFAULT xid(),+ "fixedAssetId" TEXT NOT NULL,+ "disposalMethod" "disposalMethod" NOT NULL,+ "disposalDate" DATE NOT NULL,+ "saleProceeds" NUMERIC NOT NULL DEFAULT 0,+ "netBookValueAtDisposal" NUMERIC NOT NULL,+ "gainLoss" NUMERIC NOT NULL,+ "journalId" TEXT,+ "companyId" TEXT NOT NULL,+ "createdAt" TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW(),+ "createdBy" TEXT NOT NULL,++ CONSTRAINT "fixedAssetDisposal_pkey" PRIMARY KEY ("id"),+ CONSTRAINT "fixedAssetDisposal_fixedAssetId_fkey" FOREIGN KEY ("fixedAssetId") REFERENCES "fixedAsset" ("id") ON DELETE RESTRICT ON UPDATE CASCADE,+ CONSTRAINT "fixedAssetDisposal_journalId_fkey" FOREIGN KEY ("journalId") REFERENCES "journal" ("id") ON DELETE SET NULL ON UPDATE CASCADE,+ CONSTRAINT "fixedAssetDisposal_companyId_fkey" FOREIGN KEY ("companyId") REFERENCES "company" ("id") ON DELETE CASCADE ON UPDATE CASCADE,+ CONSTRAINT "fixedAssetDisposal_createdBy_fkey" FOREIGN KEY ("createdBy") REFERENCES "user" ("id") ON DELETE RESTRICT+);++CREATE INDEX "fixedAssetDisposal_fixedAssetId_idx" ON "fixedAssetDisposal" ("fixedAssetId");++ALTER TABLE "fixedAssetDisposal" ENABLE ROW LEVEL SECURITY;++CREATE POLICY "SELECT" ON "public"."fixedAssetDisposal"+ FOR SELECT USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_view'))::text[]+ )+ );++CREATE POLICY "INSERT" ON "public"."fixedAssetDisposal"+ FOR INSERT WITH CHECK (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_create'))::text[]+ )+ );++-- Fixed Asset Usage Log table (for Units of Production)+CREATE TABLE "fixedAssetUsageLog" (+ "id" TEXT NOT NULL DEFAULT xid(),+ "fixedAssetId" TEXT NOT NULL,+ "periodStart" DATE NOT NULL,+ "periodEnd" DATE NOT NULL,+ "unitsProduced" NUMERIC NOT NULL,+ "companyId" TEXT NOT NULL,+ "createdAt" TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW(),+ "createdBy" TEXT NOT NULL,++ CONSTRAINT "fixedAssetUsageLog_pkey" PRIMARY KEY ("id"),+ CONSTRAINT "fixedAssetUsageLog_fixedAssetId_periodEnd_key" UNIQUE ("fixedAssetId", "periodEnd"),+ CONSTRAINT "fixedAssetUsageLog_fixedAssetId_fkey" FOREIGN KEY ("fixedAssetId") REFERENCES "fixedAsset" ("id") ON DELETE CASCADE ON UPDATE CASCADE,+ CONSTRAINT "fixedAssetUsageLog_companyId_fkey" FOREIGN KEY ("companyId") REFERENCES "company" ("id") ON DELETE CASCADE ON UPDATE CASCADE,+ CONSTRAINT "fixedAssetUsageLog_createdBy_fkey" FOREIGN KEY ("createdBy") REFERENCES "user" ("id") ON DELETE RESTRICT+);++CREATE INDEX "fixedAssetUsageLog_fixedAssetId_idx" ON "fixedAssetUsageLog" ("fixedAssetId");++ALTER TABLE "fixedAssetUsageLog" ENABLE ROW LEVEL SECURITY;++CREATE POLICY "SELECT" ON "public"."fixedAssetUsageLog"+ FOR SELECT USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_view'))::text[]+ )+ );++CREATE POLICY "INSERT" ON "public"."fixedAssetUsageLog"+ FOR INSERT WITH CHECK (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_create'))::text[]+ )+ );++CREATE POLICY "UPDATE" ON "public"."fixedAssetUsageLog"+ FOR UPDATE USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_update'))::text[]+ )+ );++CREATE POLICY "DELETE" ON "public"."fixedAssetUsageLog"+ FOR DELETE USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('accounting_delete'))::text[]+ )+ );++-- Receipt/Shipment lines for fixed assets+CREATE TABLE "receiptFixedAssetLine" (+ "id" TEXT NOT NULL DEFAULT id(),+ "receiptId" TEXT NOT NULL,+ "purchaseOrderLineId" TEXT NOT NULL,+ "received" BOOLEAN NOT NULL DEFAULT true,+ "serialNumber" TEXT,+ "companyId" TEXT NOT NULL,+ "createdBy" TEXT NOT NULL,+ "createdAt" TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW(),+ "updatedAt" TIMESTAMP WITH TIME ZONE,+ "updatedBy" TEXT,+ CONSTRAINT "receiptFixedAssetLine_pkey" PRIMARY KEY ("id"),+ CONSTRAINT "receiptFixedAssetLine_receiptId_fkey" FOREIGN KEY ("receiptId") REFERENCES "receipt"("id") ON DELETE CASCADE ON UPDATE CASCADE,+ CONSTRAINT "receiptFixedAssetLine_purchaseOrderLineId_fkey" FOREIGN KEY ("purchaseOrderLineId") REFERENCES "purchaseOrderLine"("id") ON DELETE CASCADE ON UPDATE CASCADE,+ CONSTRAINT "receiptFixedAssetLine_companyId_fkey" FOREIGN KEY ("companyId") REFERENCES "company"("id") ON DELETE CASCADE ON UPDATE CASCADE,+ CONSTRAINT "receiptFixedAssetLine_createdBy_fkey" FOREIGN KEY ("createdBy") REFERENCES "user"("id") ON DELETE CASCADE ON UPDATE CASCADE+);++CREATE INDEX "receiptFixedAssetLine_receiptId_idx" ON "receiptFixedAssetLine" ("receiptId");++ALTER TABLE "receiptFixedAssetLine" ENABLE ROW LEVEL SECURITY;++CREATE POLICY "SELECT" ON "public"."receiptFixedAssetLine"+FOR SELECT USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('inventory_view'))::text[]+ )+);++CREATE POLICY "INSERT" ON "public"."receiptFixedAssetLine"+FOR INSERT WITH CHECK (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('inventory_create'))::text[]+ )+);++CREATE POLICY "UPDATE" ON "public"."receiptFixedAssetLine"+FOR UPDATE USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('inventory_update'))::text[]+ )+);++CREATE POLICY "DELETE" ON "public"."receiptFixedAssetLine"+FOR DELETE USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('inventory_delete'))::text[]+ )+);++CREATE TABLE "shipmentFixedAssetLine" (+ "id" TEXT NOT NULL DEFAULT id(),+ "shipmentId" TEXT NOT NULL,+ "salesOrderLineId" TEXT NOT NULL,+ "shipped" BOOLEAN NOT NULL DEFAULT true,+ "serialNumber" TEXT,+ "companyId" TEXT NOT NULL,+ "createdBy" TEXT NOT NULL,+ "createdAt" TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW(),+ "updatedAt" TIMESTAMP WITH TIME ZONE,+ "updatedBy" TEXT,+ CONSTRAINT "shipmentFixedAssetLine_pkey" PRIMARY KEY ("id"),+ CONSTRAINT "shipmentFixedAssetLine_shipmentId_fkey" FOREIGN KEY ("shipmentId") REFERENCES "shipment"("id") ON DELETE CASCADE ON UPDATE CASCADE,+ CONSTRAINT "shipmentFixedAssetLine_salesOrderLineId_fkey" FOREIGN KEY ("salesOrderLineId") REFERENCES "salesOrderLine"("id") ON DELETE CASCADE ON UPDATE CASCADE,+ CONSTRAINT "shipmentFixedAssetLine_companyId_fkey" FOREIGN KEY ("companyId") REFERENCES "company"("id") ON DELETE CASCADE ON UPDATE CASCADE,+ CONSTRAINT "shipmentFixedAssetLine_createdBy_fkey" FOREIGN KEY ("createdBy") REFERENCES "user"("id") ON DELETE CASCADE ON UPDATE CASCADE+);++CREATE INDEX "shipmentFixedAssetLine_shipmentId_idx" ON "shipmentFixedAssetLine" ("shipmentId");++ALTER TABLE "shipmentFixedAssetLine" ENABLE ROW LEVEL SECURITY;++CREATE POLICY "SELECT" ON "public"."shipmentFixedAssetLine"+FOR SELECT USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('inventory_view'))::text[]+ )+);++CREATE POLICY "INSERT" ON "public"."shipmentFixedAssetLine"+FOR INSERT WITH CHECK (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('inventory_create'))::text[]+ )+);++CREATE POLICY "UPDATE" ON "public"."shipmentFixedAssetLine"+FOR UPDATE USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('inventory_update'))::text[]+ )+);++CREATE POLICY "DELETE" ON "public"."shipmentFixedAssetLine"+FOR DELETE USING (+ "companyId" = ANY (+ (SELECT get_companies_with_employee_permission('inventory_delete'))::text[]+ )+);++-- Audit event trigger+SELECT attach_event_trigger('fixedAsset', ARRAY[]::TEXT[], ARRAY[]::TEXT[]);++-- Sequences+INSERT INTO "sequence" ("table", "name", "prefix", "suffix", "next", "size", "step", "companyId")+SELECT 'fixedAsset', 'Fixed Asset', 'FA', NULL, 1, 6, 1, "id" FROM "company"+ON CONFLICT DO NOTHING;++INSERT INTO "sequence" ("table", "name", "prefix", "suffix", "next", "size", "step", "companyId")+SELECT 'depreciationRun', 'Depreciation Run', 'DR', NULL, 1, 6, 1, "id" FROM "company"+ON CONFLICT DO NOTHING;++-- Dimension unique constraint: only enforce among active dimensions+ALTER TABLE "dimension" DROP CONSTRAINT IF EXISTS "dimension_name_companyGroupId_key";++CREATE UNIQUE INDEX "dimension_name_companyGroupId_active_idx"+ ON "dimension"("name", "companyGroupId")+ WHERE "active" = true;++-- Work Center: add departmentId+ALTER TABLE "workCenter"+ ADD COLUMN "departmentId" TEXT,+ ADD CONSTRAINT "workCenter_departmentId_fkey"+ FOREIGN KEY ("departmentId") REFERENCES "department" ("id") ON DELETE SET NULL;++-- Backfill dimensions+INSERT INTO "dimension" ("name", "entityType", "companyGroupId", "createdBy")+SELECT 'Work Center', 'WorkCenter'::"dimensionEntityType", cg."id", 'system'+FROM "companyGroup" cg+ON CONFLICT ("name", "companyGroupId") WHERE "active" = true DO NOTHING;++INSERT INTO "dimension" ("name", "entityType", "companyGroupId", "createdBy")+SELECT 'Process', 'Process'::"dimensionEntityType", cg."id", 'system'+FROM "companyGroup" cg+ON CONFLICT ("name", "companyGroupId") WHERE "active" = true DO NOTHING;++-- Recreate views with fixed asset joins++DROP VIEW IF EXISTS "purchaseOrderLines";+CREATE OR REPLACE VIEW "purchaseOrderLines" WITH(SECURITY_INVOKER=true) AS (+ SELECT DISTINCT ON (pl.id)+ pl.*,+ CASE+ WHEN i."thumbnailPath" IS NULL AND mu."thumbnailPath" IS NOT NULL THEN mu."thumbnailPath"+ WHEN i."thumbnailPath" IS NULL AND imu."thumbnailPath" IS NOT NULL THEN imu."thumbnailPath"+ ELSE i."thumbnailPath"+ END as "thumbnailPath",+ i.name as "itemName",+ i."readableIdWithRevision" as "itemReadableId",+ i.description as "itemDescription",+ COALESCE(mu.id, imu.id) as "modelId",+ COALESCE(mu."autodeskUrn", imu."autodeskUrn") as "autodeskUrn",+ COALESCE(mu."modelPath", imu."modelPath") as "modelPath",+ COALESCE(mu."name", imu."name") as "modelName",+ COALESCE(mu."size", imu."size") as "modelSize",+ ic."unitCost" as "unitCost",+ sp."supplierPartId",+ jo."description" as "jobOperationDescription",+ a."name" as "accountName",+ fa."fixedAssetId" as "assetReadableId",+ fa."name" as "assetName"+ FROM "purchaseOrderLine" pl+ INNER JOIN "purchaseOrder" so ON so.id = pl."purchaseOrderId"+ LEFT JOIN "modelUpload" mu ON pl."modelUploadId" = mu."id"+ LEFT JOIN "item" i ON i.id = pl."itemId"+ LEFT JOIN "itemCost" ic ON ic."itemId" = i.id+ LEFT JOIN "modelUpload" imu ON imu.id = i."modelUploadId"+ LEFT JOIN "supplierPart" sp ON sp."supplierId" = so."supplierId" AND sp."itemId" = i.id+ LEFT JOIN "jobOperation" jo ON jo."id" = pl."jobOperationId"+ LEFT JOIN "account" a ON a.id = pl."accountId"+ LEFT JOIN "fixedAsset" fa ON fa.id = pl."assetId"+);++DROP VIEW IF EXISTS "purchaseInvoiceLines";+CREATE OR REPLACE VIEW "purchaseInvoiceLines" WITH(SECURITY_INVOKER=true) AS (+ SELECT+ pl.*,+ CASE+ WHEN i."thumbnailPath" IS NULL AND mu."thumbnailPath" IS NOT NULL THEN mu."thumbnailPath"+ WHEN i."thumbnailPath" IS NULL AND imu."thumbnailPath" IS NOT NULL THEN imu."thumbnailPath"+ ELSE i."thumbnailPath"+ END as "thumbnailPath",+ i."readableIdWithRevision" as "itemReadableId",+ i.name as "itemName",+ i.description as "itemDescription",+ ic."unitCost" as "unitCost",+ sp."supplierPartId",+ a."name" as "accountName",+ fa."fixedAssetId" as "assetReadableId",+ fa."name" as "assetName"+ FROM "purchaseInvoiceLine" pl+ INNER JOIN "purchaseInvoice" pi ON pi.id = pl."invoiceId"+ LEFT JOIN "modelUpload" mu ON pl."modelUploadId" = mu."id"+ LEFT JOIN "item" i ON i.id = pl."itemId"+ LEFT JOIN "itemCost" ic ON ic."itemId" = i.id+ LEFT JOIN "modelUpload" imu ON imu.id = i."modelUploadId"+ LEFT JOIN "supplierPart" sp ON sp."supplierId" = pi."supplierId" AND sp."itemId" = i.id+ LEFT JOIN "account" a ON a.id = pl."accountId"+ LEFT JOIN "fixedAsset" fa ON fa.id = pl."assetId"+);++DROP VIEW IF EXISTS "salesOrderLines";+CREATE OR REPLACE VIEW "salesOrderLines" WITH(SECURITY_INVOKER=true) AS (+ SELECT+ sl.*,+ i."readableIdWithRevision" as "itemReadableId",+ CASE+ WHEN i."thumbnailPath" IS NULL AND mu."thumbnailPath" IS NOT NULL THEN mu."thumbnailPath"+ WHEN i."thumbnailPath" IS NULL AND imu."thumbnailPath" IS NOT NULL THEN imu."thumbnailPath"+ ELSE i."thumbnailPath"+ END as "thumbnailPath",+ COALESCE(mu.id, imu.id) as "modelId",+ COALESCE(mu."autodeskUrn", imu."autodeskUrn") as "autodeskUrn",+ COALESCE(mu."modelPath", imu."modelPath") as "modelPath",+ COALESCE(mu."name", imu."name") as "modelName",+ COALESCE(mu."size", imu."size") as "modelSize",+ ic."unitCost" as "unitCost",+ cp."customerPartId",+ cp."customerPartRevision",+ so."orderDate",+ so."customerId",+ so."salesOrderId" as "salesOrderReadableId",+ fa."fixedAssetId" as "assetReadableId",+ fa."name" as "assetName"+ FROM "salesOrderLine" sl+ INNER JOIN "salesOrder" so ON so.id = sl."salesOrderId"+ LEFT JOIN "modelUpload" mu ON sl."modelUploadId" = mu."id"+ LEFT JOIN "item" i ON i.id = sl."itemId"+ LEFT JOIN "itemCost" ic ON ic."itemId" = i.id+ LEFT JOIN "modelUpload" imu ON imu.id = i."modelUploadId"+ LEFT JOIN "customerPartToItem" cp ON cp."customerId" = so."customerId" AND cp."itemId" = i.id+ LEFT JOIN "fixedAsset" fa ON fa.id = sl."assetId"+);++DROP VIEW IF EXISTS "salesInvoiceLines";+CREATE OR REPLACE VIEW "salesInvoiceLines" WITH(SECURITY_INVOKER=true) AS (+ SELECT+ sl.*,+ i."readableIdWithRevision" as "itemReadableId",+ CASE+ WHEN i."thumbnailPath" IS NULL AND mu."thumbnailPath" IS NOT NULL THEN mu."thumbnailPath"+ WHEN i."thumbnailPath" IS NULL AND imu."thumbnailPath" IS NOT NULL THEN imu."thumbnailPath"+ ELSE i."thumbnailPath"+ END as "thumbnailPath",+ i.name as "itemName",+ i.description as "itemDescription",+ ic."unitCost" as "unitCost",+ (SELECT cp."customerPartId"+ FROM "customerPartToItem" cp+ WHERE cp."customerId" = si."customerId" AND cp."itemId" = i.id+ LIMIT 1) as "customerPartId",+ fa."fixedAssetId" as "assetReadableId",+ fa."name" as "assetName"+ FROM "salesInvoiceLine" sl+ INNER JOIN "salesInvoice" si ON si.id = sl."invoiceId"+ LEFT JOIN "modelUpload" mu ON sl."modelUploadId" = mu."id"+ LEFT JOIN "item" i ON i.id = sl."itemId"+ LEFT JOIN "itemCost" ic ON ic."itemId" = i.id+ LEFT JOIN "modelUpload" imu ON imu.id = i."modelUploadId"+ LEFT JOIN "fixedAsset" fa ON fa.id = sl."assetId"+);++-- Recreate workCenters view with departmentName+DROP VIEW IF EXISTS "workCenters";+CREATE OR REPLACE VIEW "workCenters" WITH(SECURITY_INVOKER=true) AS+ SELECT+ wc.*,+ l.name as "locationName",+ d.name as "departmentName",+ wcp.processes+ FROM "workCenter" wc+ LEFT JOIN "location" l+ ON wc."locationId" = l.id+ LEFT JOIN "department" d+ ON wc."departmentId" = d.id+ LEFT JOIN (+ SELECT+ "workCenterId",+ array_agg("processId"::text) as processes+ FROM "workCenterProcess" wcp+ INNER JOIN "process" p ON wcp."processId" = p.id+ GROUP BY "workCenterId"+ ) wcp ON wc.id = wcp."workCenterId";++DROP VIEW IF EXISTS "workCentersWithBlockingStatus";+CREATE OR REPLACE VIEW "workCentersWithBlockingStatus" WITH (security_invoker = true) AS+SELECT+ wc.*,+ l.name AS "locationName",+ COALESCE(+ (SELECT COUNT(*) > 0+ FROM "maintenanceDispatch" md+ WHERE md."workCenterId" = wc.id+ AND md.status = 'In Progress'+ AND md."oeeImpact" IN ('Down', 'Planned')+ ), false+ ) AS "isBlocked",+ (+ SELECT md.id+ FROM "maintenanceDispatch" md+ WHERE md."workCenterId" = wc.id+ AND md.status = 'In Progress'+ AND md."oeeImpact" IN ('Down', 'Planned')+ ORDER BY md."createdAt" DESC+ LIMIT 1+ ) AS "blockingDispatchId",+ (+ SELECT md."maintenanceDispatchId"+ FROM "maintenanceDispatch" md+ WHERE md."workCenterId" = wc.id+ AND md.status = 'In Progress'+ AND md."oeeImpact" IN ('Down', 'Planned')+ ORDER BY md."createdAt" DESC+ LIMIT 1+ ) AS "blockingDispatchReadableId"+FROM "workCenter" wc+LEFT JOIN "location" l ON wc."locationId" = l.id;diff --git a/packages/database/supabase/migrations/20260524163042_asset-class-dimension.sql b/packages/database/supabase/migrations/20260524163042_asset-class-dimension.sqlnew file mode 100644index 0000000000..2f934896f5--- /dev/null+++ b/packages/database/supabase/migrations/20260524163042_asset-class-dimension.sql@@ -0,0 +1,2 @@+-- Add FixedAssetClass to dimensionEntityType enum+ALTER TYPE "dimensionEntityType" ADD VALUE 'FixedAssetClass';diff --git a/packages/database/supabase/migrations/20260524163043_asset-class-dimension-backfill.sql b/packages/database/supabase/migrations/20260524163043_asset-class-dimension-backfill.sqlnew file mode 100644index 0000000000..b1ebd5952c--- /dev/null+++ b/packages/database/supabase/migrations/20260524163043_asset-class-dimension-backfill.sql@@ -0,0 +1,5 @@+-- Backfill: create Asset Class dimension for every company group+INSERT INTO "dimension" ("name", "entityType", "companyGroupId", "createdBy")+SELECT 'Asset Class', 'FixedAssetClass'::"dimensionEntityType", cg."id", 'system'+FROM "companyGroup" cg+ON CONFLICT ("name", "companyGroupId") WHERE "active" = true DO NOTHING;diff --git a/packages/database/supabase/migrations/20260525084319_seed-fixed-asset-classes.sql b/packages/database/supabase/migrations/20260525084319_seed-fixed-asset-classes.sqlnew file mode 100644index 0000000000..1d64e3b5fc--- /dev/null+++ b/packages/database/supabase/migrations/20260525084319_seed-fixed-asset-classes.sql@@ -0,0 +1,41 @@+INSERT INTO "fixedAssetClass" (+ "name", "depreciationMethod", "usefulLifeMonths", "residualValuePercent",+ "assetAccountId", "accumulatedDepreciationAccountId",+ "depreciationExpenseAccountId", "writeOffAccountId",+ "writeDownAccountId", "disposalAccountId",+ "companyId", "createdBy"+)+SELECT+ cls.name,+ 'Straight Line'::"depreciationMethod",+ cls.useful_life_months,+ 0,+ a_asset.id,+ a1330.id,+ a6310.id,+ a6320.id,+ a6320.id,+ a6320.id,+ c.id,+ 'system'+FROM "company" c+CROSS JOIN (+ VALUES+ ('Buildings', 468, '1360'),+ ('Machinery & Equipment', 120, '1350'),+ ('Vehicles', 60, '1310')+) AS cls(name, useful_life_months, asset_account_number)+JOIN "account" a_asset+ ON a_asset."companyGroupId" = c."companyGroupId"+ AND a_asset."number" = cls.asset_account_number+JOIN "account" a1330+ ON a1330."companyGroupId" = c."companyGroupId"+ AND a1330."number" = '1330'+JOIN "account" a6310+ ON a6310."companyGroupId" = c."companyGroupId"+ AND a6310."number" = '6310'+JOIN "account" a6320+ ON a6320."companyGroupId" = c."companyGroupId"+ AND a6320."number" = '6320'+WHERE c."isEliminationEntity" IS NOT TRUE+ON CONFLICT ("name", "companyId") DO NOTHING;diff --git a/packages/documents/src/utils/purchase-order.ts b/packages/documents/src/utils/purchase-order.tsindex d49a4941c6..3848ebfe18 100644--- a/packages/documents/src/utils/purchase-order.ts+++ b/packages/documents/src/utils/purchase-order.ts@@ -5,7 +5,7 @@ export function getLineDescription() {switch (line?.purchaseOrderLineType) {case "Fixed Asset":- return line?.assetId;+ return line?.assetName ?? "Fixed Asset";case "G/L Account":return line?.description;case "Comment":diff --git a/packages/documents/src/utils/sales-invoice.ts b/packages/documents/src/utils/sales-invoice.tsindex f62f7749d0..957e9aa388 100644--- a/packages/documents/src/utils/sales-invoice.ts+++ b/packages/documents/src/utils/sales-invoice.ts@@ -5,7 +5,11 @@ export function getLineDescription() {switch (line?.invoiceLineType) {case "Fixed Asset":- return line?.assetId;+ return (+ (line as any)?.assetReadableId ??+ (line as any)?.assetName ??+ "Fixed Asset"+ );case "Comment":return line?.description;default:diff --git a/packages/documents/src/utils/sales-order.ts b/packages/documents/src/utils/sales-order.tsindex b01472279a..df5cea09c3 100644--- a/packages/documents/src/utils/sales-order.ts+++ b/packages/documents/src/utils/sales-order.ts@@ -5,7 +5,11 @@ export function getLineDescription() {switch (line?.salesOrderLineType) {case "Fixed Asset":- return line?.assetId;+ return (+ (line as any)?.assetReadableId ??+ (line as any)?.assetName ??+ "Fixed Asset"+ );case "Comment":return line?.description;default:diff --git a/packages/form/src/components/Submit.tsx b/packages/form/src/components/Submit.tsxindex dae182f6d3..51def1a5a2 100644--- a/packages/form/src/components/Submit.tsx+++ b/packages/form/src/components/Submit.tsx@@ -3,8 +3,8 @@ import type { ButtonProps } from "@carbon/react";import {Button,Modal,- ModalBody,ModalContent,+ ModalDescription,ModalFooter,ModalHeader,ModalTitle@@ -83,10 +83,10 @@ export const Submit = forwardRef<HTMLButtonElement, SubmitProps>(<ModalContent><ModalHeader><ModalTitle>Unsaved changes</ModalTitle>+ <ModalDescription>+ Are you sure you want to leave this page?+ </ModalDescription></ModalHeader>- <ModalBody>- <p>Are you sure you want to leave this page?</p>- </ModalBody><ModalFooter><Button variant="secondary" onClick={() => blocker.reset()}>Stay on this pagediff --git a/packages/locale/locales/de/erp.po b/packages/locale/locales/de/erp.poindex f1d4d543b6..3aaa860bce 100644--- a/packages/locale/locales/de/erp.po+++ b/packages/locale/locales/de/erp.po@@ -889,6 +889,15 @@ msgstr ""msgid "Assembly:"msgstr ""+msgid "Asset"+msgstr ""++msgid "Asset Classes"+msgstr ""++msgid "Assets"+msgstr ""+msgid "Assign To"msgstr ""@@ -1422,9 +1431,6 @@ msgstr ""msgid "Configure Item"msgstr ""-msgid "Configure Materials"-msgstr ""-msgid "Configure notifications for when gauges go out of calibration."msgstr ""@@ -2412,6 +2418,9 @@ msgstr ""msgid "Departments"msgstr ""+msgid "Depreciation"+msgstr ""+msgid "Description"msgstr ""@@ -2881,6 +2890,9 @@ msgstr ""msgid "Enable to automatically post transactions to the general ledger."msgstr ""+msgid "Enable to configure tax-specific depreciation methods on asset classes (e.g., MACRS, accelerated)."+msgstr ""+msgid "Enable to generate IDs and descriptions for raw materials."msgstr ""@@ -3512,6 +3524,12 @@ msgstr ""msgid "Fixed"msgstr ""+msgid "Fixed Asset"+msgstr ""++msgid "Fixed Assets"+msgstr ""+msgid "Fixed Reorder"msgstr ""@@ -4426,6 +4444,9 @@ msgstr ""msgid "Material IDs"msgstr ""+msgid "Material Properties"+msgstr ""+msgid "Material Shape"msgstr ""@@ -6506,6 +6527,9 @@ msgstr ""msgid "Search"msgstr ""+msgid "Search accounts..."+msgstr ""+msgid "Search across your workspace..."msgstr ""@@ -6930,6 +6954,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -7381,6 +7408,9 @@ msgstr ""msgid "Tax & Additional Costs"msgstr ""+msgid "Tax & Shipping"+msgstr ""+msgid "Tax Amount"msgstr ""@@ -7681,6 +7711,12 @@ msgstr ""msgid "Track every change to your orders, invoices, customers, suppliers, and more."msgstr ""+msgid "Track tax depreciation separately"+msgstr ""++msgid "Track tax depreciation separately from book depreciation and automatically post deferred tax liability entries."+msgstr ""+msgid "Track when batches or serials of this item expire."msgstr ""diff --git a/packages/locale/locales/de/mes.po b/packages/locale/locales/de/mes.poindex 02cb40b608..3ce98f4b5b 100644--- a/packages/locale/locales/de/mes.po+++ b/packages/locale/locales/de/mes.po@@ -403,7 +403,7 @@ msgid "Job Traveler"msgstr ""msgid "Jobs"-msgstr ""+msgstr "Aufträge"msgid "Kit"msgstr ""@@ -536,7 +536,7 @@ msgid "No materials"msgstr ""msgid "No open jobs"-msgstr ""+msgstr "Keine offenen Aufträge"msgid "No operators"msgstr ""@@ -597,7 +597,7 @@ msgid "Open"msgstr ""msgid "Open Jobs"-msgstr ""+msgstr "Offene Aufträge"msgid "Operations"msgstr ""@@ -718,7 +718,7 @@ msgid "Search"msgstr ""msgid "Search by job or item ID"-msgstr ""+msgstr "Nach Job oder Artikel-ID suchen"msgid "Search operators..."msgstr ""@@ -799,6 +799,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -891,7 +894,7 @@ msgid "Total: {0}"msgstr ""msgid "Tracking"-msgstr ""+msgstr "Verfolgung"msgid "Tracking Labels"msgstr ""diff --git a/packages/locale/locales/en/erp.po b/packages/locale/locales/en/erp.poindex 6dd7d40f9f..99f7434d62 100644--- a/packages/locale/locales/en/erp.po+++ b/packages/locale/locales/en/erp.po@@ -889,6 +889,15 @@ msgstr "Ask anything"msgid "Assembly:"msgstr "Assembly:"+msgid "Asset"+msgstr "Asset"++msgid "Asset Classes"+msgstr "Asset Classes"++msgid "Assets"+msgstr "Assets"+msgid "Assign To"msgstr "Assign To"@@ -1422,9 +1431,6 @@ msgstr "Configure how preventative maintenance dispatches are automatically genemsgid "Configure Item"msgstr "Configure Item"-msgid "Configure Materials"-msgstr "Configure Materials"-msgid "Configure notifications for when gauges go out of calibration."msgstr "Configure notifications for when gauges go out of calibration."@@ -2412,6 +2418,9 @@ msgstr "Department Name"msgid "Departments"msgstr "Departments"+msgid "Depreciation"+msgstr "Depreciation"+msgid "Description"msgstr "Description"@@ -2881,6 +2890,9 @@ msgstr "Enable to allow shared workstation mode."msgid "Enable to automatically post transactions to the general ledger."msgstr "Enable to automatically post transactions to the general ledger."+msgid "Enable to configure tax-specific depreciation methods on asset classes (e.g., MACRS, accelerated)."+msgstr "Enable to configure tax-specific depreciation methods on asset classes (e.g., MACRS, accelerated)."+msgid "Enable to generate IDs and descriptions for raw materials."msgstr "Enable to generate IDs and descriptions for raw materials."@@ -3512,6 +3524,12 @@ msgstr "Fiscal Years"msgid "Fixed"msgstr "Fixed"+msgid "Fixed Asset"+msgstr "Fixed Asset"++msgid "Fixed Assets"+msgstr "Fixed Assets"+msgid "Fixed Reorder"msgstr "Fixed Reorder"@@ -4426,6 +4444,9 @@ msgstr "Material ID"msgid "Material IDs"msgstr "Material IDs"+msgid "Material Properties"+msgstr "Material Properties"+msgid "Material Shape"msgstr "Material Shape"@@ -6506,6 +6527,9 @@ msgstr "Scrap Reasons"msgid "Search"msgstr "Search"+msgid "Search accounts..."+msgstr "Search accounts..."+msgid "Search across your workspace..."msgstr "Search across your workspace..."@@ -6930,6 +6954,9 @@ msgstr "Sign in with Google"msgid "Sign in with Outlook"msgstr "Sign in with Outlook"+msgid "Sign in with Passkey"+msgstr "Sign in with Passkey"+msgid "Sign Out"msgstr "Sign Out"@@ -7381,6 +7408,9 @@ msgstr "Tax"msgid "Tax & Additional Costs"msgstr "Tax & Additional Costs"+msgid "Tax & Shipping"+msgstr "Tax & Shipping"+msgid "Tax Amount"msgstr "Tax Amount"@@ -7681,6 +7711,12 @@ msgstr "Track every change to your orders, invoices, customers, and more."msgid "Track every change to your orders, invoices, customers, suppliers, and more."msgstr "Track every change to your orders, invoices, customers, suppliers, and more."+msgid "Track tax depreciation separately"+msgstr "Track tax depreciation separately"++msgid "Track tax depreciation separately from book depreciation and automatically post deferred tax liability entries."+msgstr "Track tax depreciation separately from book depreciation and automatically post deferred tax liability entries."+msgid "Track when batches or serials of this item expire."msgstr "Track when batches or serials of this item expire."diff --git a/packages/locale/locales/en/mes.po b/packages/locale/locales/en/mes.poindex ff1b0a7b2e..2c3d76da98 100644--- a/packages/locale/locales/en/mes.po+++ b/packages/locale/locales/en/mes.po@@ -799,6 +799,9 @@ msgstr "Sign in with Google"msgid "Sign in with Outlook"msgstr "Sign in with Outlook"+msgid "Sign in with Passkey"+msgstr "Sign in with Passkey"+msgid "Sign Out"msgstr "Sign Out"diff --git a/packages/locale/locales/es/erp.po b/packages/locale/locales/es/erp.poindex f2137bed71..afe2eb21a9 100644--- a/packages/locale/locales/es/erp.po+++ b/packages/locale/locales/es/erp.po@@ -889,6 +889,15 @@ msgstr ""msgid "Assembly:"msgstr ""+msgid "Asset"+msgstr ""++msgid "Asset Classes"+msgstr ""++msgid "Assets"+msgstr ""+msgid "Assign To"msgstr ""@@ -1422,9 +1431,6 @@ msgstr ""msgid "Configure Item"msgstr ""-msgid "Configure Materials"-msgstr ""-msgid "Configure notifications for when gauges go out of calibration."msgstr ""@@ -2412,6 +2418,9 @@ msgstr ""msgid "Departments"msgstr ""+msgid "Depreciation"+msgstr ""+msgid "Description"msgstr ""@@ -2881,6 +2890,9 @@ msgstr ""msgid "Enable to automatically post transactions to the general ledger."msgstr ""+msgid "Enable to configure tax-specific depreciation methods on asset classes (e.g., MACRS, accelerated)."+msgstr ""+msgid "Enable to generate IDs and descriptions for raw materials."msgstr ""@@ -3512,6 +3524,12 @@ msgstr ""msgid "Fixed"msgstr ""+msgid "Fixed Asset"+msgstr ""++msgid "Fixed Assets"+msgstr ""+msgid "Fixed Reorder"msgstr ""@@ -4426,6 +4444,9 @@ msgstr ""msgid "Material IDs"msgstr ""+msgid "Material Properties"+msgstr ""+msgid "Material Shape"msgstr ""@@ -6506,6 +6527,9 @@ msgstr ""msgid "Search"msgstr ""+msgid "Search accounts..."+msgstr ""+msgid "Search across your workspace..."msgstr ""@@ -6930,6 +6954,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -7381,6 +7408,9 @@ msgstr ""msgid "Tax & Additional Costs"msgstr ""+msgid "Tax & Shipping"+msgstr ""+msgid "Tax Amount"msgstr ""@@ -7681,6 +7711,12 @@ msgstr ""msgid "Track every change to your orders, invoices, customers, suppliers, and more."msgstr ""+msgid "Track tax depreciation separately"+msgstr ""++msgid "Track tax depreciation separately from book depreciation and automatically post deferred tax liability entries."+msgstr ""+msgid "Track when batches or serials of this item expire."msgstr ""diff --git a/packages/locale/locales/es/mes.po b/packages/locale/locales/es/mes.poindex 963468f855..206e35bab9 100644--- a/packages/locale/locales/es/mes.po+++ b/packages/locale/locales/es/mes.po@@ -403,7 +403,7 @@ msgid "Job Traveler"msgstr ""msgid "Jobs"-msgstr ""+msgstr "Trabajos"msgid "Kit"msgstr ""@@ -536,7 +536,7 @@ msgid "No materials"msgstr ""msgid "No open jobs"-msgstr ""+msgstr "Sin trabajos abiertos"msgid "No operators"msgstr ""@@ -597,7 +597,7 @@ msgid "Open"msgstr ""msgid "Open Jobs"-msgstr ""+msgstr "Trabajos Abiertos"msgid "Operations"msgstr ""@@ -718,7 +718,7 @@ msgid "Search"msgstr ""msgid "Search by job or item ID"-msgstr ""+msgstr "Buscar por ID de trabajo o artículo"msgid "Search operators..."msgstr ""@@ -799,6 +799,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -891,7 +894,7 @@ msgid "Total: {0}"msgstr ""msgid "Tracking"-msgstr ""+msgstr "Seguimiento"msgid "Tracking Labels"msgstr ""diff --git a/packages/locale/locales/fr/erp.po b/packages/locale/locales/fr/erp.poindex ba8cd9bafc..2b327bd3fc 100644--- a/packages/locale/locales/fr/erp.po+++ b/packages/locale/locales/fr/erp.po@@ -889,6 +889,15 @@ msgstr ""msgid "Assembly:"msgstr ""+msgid "Asset"+msgstr ""++msgid "Asset Classes"+msgstr ""++msgid "Assets"+msgstr ""+msgid "Assign To"msgstr ""@@ -1422,9 +1431,6 @@ msgstr ""msgid "Configure Item"msgstr ""-msgid "Configure Materials"-msgstr ""-msgid "Configure notifications for when gauges go out of calibration."msgstr ""@@ -2412,6 +2418,9 @@ msgstr ""msgid "Departments"msgstr ""+msgid "Depreciation"+msgstr ""+msgid "Description"msgstr ""@@ -2881,6 +2890,9 @@ msgstr ""msgid "Enable to automatically post transactions to the general ledger."msgstr ""+msgid "Enable to configure tax-specific depreciation methods on asset classes (e.g., MACRS, accelerated)."+msgstr ""+msgid "Enable to generate IDs and descriptions for raw materials."msgstr ""@@ -3512,6 +3524,12 @@ msgstr ""msgid "Fixed"msgstr ""+msgid "Fixed Asset"+msgstr ""++msgid "Fixed Assets"+msgstr ""+msgid "Fixed Reorder"msgstr ""@@ -4426,6 +4444,9 @@ msgstr ""msgid "Material IDs"msgstr ""+msgid "Material Properties"+msgstr ""+msgid "Material Shape"msgstr ""@@ -6506,6 +6527,9 @@ msgstr ""msgid "Search"msgstr ""+msgid "Search accounts..."+msgstr ""+msgid "Search across your workspace..."msgstr ""@@ -6930,6 +6954,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -7381,6 +7408,9 @@ msgstr ""msgid "Tax & Additional Costs"msgstr ""+msgid "Tax & Shipping"+msgstr ""+msgid "Tax Amount"msgstr ""@@ -7681,6 +7711,12 @@ msgstr ""msgid "Track every change to your orders, invoices, customers, suppliers, and more."msgstr ""+msgid "Track tax depreciation separately"+msgstr ""++msgid "Track tax depreciation separately from book depreciation and automatically post deferred tax liability entries."+msgstr ""+msgid "Track when batches or serials of this item expire."msgstr ""diff --git a/packages/locale/locales/fr/mes.po b/packages/locale/locales/fr/mes.poindex 95e0d00217..0ccb0f92a6 100644--- a/packages/locale/locales/fr/mes.po+++ b/packages/locale/locales/fr/mes.po@@ -403,7 +403,7 @@ msgid "Job Traveler"msgstr ""msgid "Jobs"-msgstr ""+msgstr "Emplois"msgid "Kit"msgstr ""@@ -536,7 +536,7 @@ msgid "No materials"msgstr ""msgid "No open jobs"-msgstr ""+msgstr "Aucun travail ouvert"msgid "No operators"msgstr ""@@ -597,7 +597,7 @@ msgid "Open"msgstr ""msgid "Open Jobs"-msgstr ""+msgstr "Emplois ouverts"msgid "Operations"msgstr ""@@ -718,7 +718,7 @@ msgid "Search"msgstr ""msgid "Search by job or item ID"-msgstr ""+msgstr "Rechercher par numéro de travail ou d'article"msgid "Search operators..."msgstr ""@@ -799,6 +799,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -891,7 +894,7 @@ msgid "Total: {0}"msgstr ""msgid "Tracking"-msgstr ""+msgstr "Suivi"msgid "Tracking Labels"msgstr ""diff --git a/packages/locale/locales/hi/erp.po b/packages/locale/locales/hi/erp.poindex d5cc536d16..3a7d0c2af2 100644--- a/packages/locale/locales/hi/erp.po+++ b/packages/locale/locales/hi/erp.po@@ -889,6 +889,15 @@ msgstr ""msgid "Assembly:"msgstr ""+msgid "Asset"+msgstr ""++msgid "Asset Classes"+msgstr ""++msgid "Assets"+msgstr ""+msgid "Assign To"msgstr ""@@ -1422,9 +1431,6 @@ msgstr ""msgid "Configure Item"msgstr ""-msgid "Configure Materials"-msgstr ""-msgid "Configure notifications for when gauges go out of calibration."msgstr ""@@ -2412,6 +2418,9 @@ msgstr ""msgid "Departments"msgstr ""+msgid "Depreciation"+msgstr ""+msgid "Description"msgstr ""@@ -2881,6 +2890,9 @@ msgstr ""msgid "Enable to automatically post transactions to the general ledger."msgstr ""+msgid "Enable to configure tax-specific depreciation methods on asset classes (e.g., MACRS, accelerated)."+msgstr ""+msgid "Enable to generate IDs and descriptions for raw materials."msgstr ""@@ -3512,6 +3524,12 @@ msgstr ""msgid "Fixed"msgstr ""+msgid "Fixed Asset"+msgstr ""++msgid "Fixed Assets"+msgstr ""+msgid "Fixed Reorder"msgstr ""@@ -4426,6 +4444,9 @@ msgstr ""msgid "Material IDs"msgstr ""+msgid "Material Properties"+msgstr ""+msgid "Material Shape"msgstr ""@@ -6506,6 +6527,9 @@ msgstr ""msgid "Search"msgstr ""+msgid "Search accounts..."+msgstr ""+msgid "Search across your workspace..."msgstr ""@@ -6930,6 +6954,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -7381,6 +7408,9 @@ msgstr ""msgid "Tax & Additional Costs"msgstr ""+msgid "Tax & Shipping"+msgstr ""+msgid "Tax Amount"msgstr ""@@ -7681,6 +7711,12 @@ msgstr ""msgid "Track every change to your orders, invoices, customers, suppliers, and more."msgstr ""+msgid "Track tax depreciation separately"+msgstr ""++msgid "Track tax depreciation separately from book depreciation and automatically post deferred tax liability entries."+msgstr ""+msgid "Track when batches or serials of this item expire."msgstr ""diff --git a/packages/locale/locales/hi/mes.po b/packages/locale/locales/hi/mes.poindex 592fbec193..fc03a3e771 100644--- a/packages/locale/locales/hi/mes.po+++ b/packages/locale/locales/hi/mes.po@@ -403,7 +403,7 @@ msgid "Job Traveler"msgstr ""msgid "Jobs"-msgstr ""+msgstr "नौकरियां"msgid "Kit"msgstr ""@@ -536,7 +536,7 @@ msgid "No materials"msgstr ""msgid "No open jobs"-msgstr ""+msgstr "कोई खुली नौकरी नहीं"msgid "No operators"msgstr ""@@ -597,7 +597,7 @@ msgid "Open"msgstr ""msgid "Open Jobs"-msgstr ""+msgstr "खुली नौकरियां"msgid "Operations"msgstr ""@@ -718,7 +718,7 @@ msgid "Search"msgstr ""msgid "Search by job or item ID"-msgstr ""+msgstr "जॉब या आइटम आईडी से खोजें"msgid "Search operators..."msgstr ""@@ -799,6 +799,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -891,7 +894,7 @@ msgid "Total: {0}"msgstr ""msgid "Tracking"-msgstr ""+msgstr "ट्रैकिंग"msgid "Tracking Labels"msgstr ""diff --git a/packages/locale/locales/it/erp.po b/packages/locale/locales/it/erp.poindex 90902f7568..35ed16778d 100644--- a/packages/locale/locales/it/erp.po+++ b/packages/locale/locales/it/erp.po@@ -889,6 +889,15 @@ msgstr ""msgid "Assembly:"msgstr ""+msgid "Asset"+msgstr ""++msgid "Asset Classes"+msgstr ""++msgid "Assets"+msgstr ""+msgid "Assign To"msgstr ""@@ -1422,9 +1431,6 @@ msgstr ""msgid "Configure Item"msgstr ""-msgid "Configure Materials"-msgstr ""-msgid "Configure notifications for when gauges go out of calibration."msgstr ""@@ -2412,6 +2418,9 @@ msgstr ""msgid "Departments"msgstr ""+msgid "Depreciation"+msgstr ""+msgid "Description"msgstr ""@@ -2881,6 +2890,9 @@ msgstr ""msgid "Enable to automatically post transactions to the general ledger."msgstr ""+msgid "Enable to configure tax-specific depreciation methods on asset classes (e.g., MACRS, accelerated)."+msgstr ""+msgid "Enable to generate IDs and descriptions for raw materials."msgstr ""@@ -3512,6 +3524,12 @@ msgstr ""msgid "Fixed"msgstr ""+msgid "Fixed Asset"+msgstr ""++msgid "Fixed Assets"+msgstr ""+msgid "Fixed Reorder"msgstr ""@@ -4426,6 +4444,9 @@ msgstr ""msgid "Material IDs"msgstr ""+msgid "Material Properties"+msgstr ""+msgid "Material Shape"msgstr ""@@ -6506,6 +6527,9 @@ msgstr ""msgid "Search"msgstr ""+msgid "Search accounts..."+msgstr ""+msgid "Search across your workspace..."msgstr ""@@ -6930,6 +6954,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -7381,6 +7408,9 @@ msgstr ""msgid "Tax & Additional Costs"msgstr ""+msgid "Tax & Shipping"+msgstr ""+msgid "Tax Amount"msgstr ""@@ -7681,6 +7711,12 @@ msgstr ""msgid "Track every change to your orders, invoices, customers, suppliers, and more."msgstr ""+msgid "Track tax depreciation separately"+msgstr ""++msgid "Track tax depreciation separately from book depreciation and automatically post deferred tax liability entries."+msgstr ""+msgid "Track when batches or serials of this item expire."msgstr ""diff --git a/packages/locale/locales/it/mes.po b/packages/locale/locales/it/mes.poindex 423ef80eec..e200ea41a2 100644--- a/packages/locale/locales/it/mes.po+++ b/packages/locale/locales/it/mes.po@@ -403,7 +403,7 @@ msgid "Job Traveler"msgstr ""msgid "Jobs"-msgstr ""+msgstr "Lavori"msgid "Kit"msgstr ""@@ -536,7 +536,7 @@ msgid "No materials"msgstr ""msgid "No open jobs"-msgstr ""+msgstr "Nessun lavoro aperto"msgid "No operators"msgstr ""@@ -597,7 +597,7 @@ msgid "Open"msgstr ""msgid "Open Jobs"-msgstr ""+msgstr "Lavori Aperti"msgid "Operations"msgstr ""@@ -718,7 +718,7 @@ msgid "Search"msgstr ""msgid "Search by job or item ID"-msgstr ""+msgstr "Cerca per ID lavoro o articolo"msgid "Search operators..."msgstr ""@@ -799,6 +799,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -891,7 +894,7 @@ msgid "Total: {0}"msgstr ""msgid "Tracking"-msgstr ""+msgstr "Tracciamento"msgid "Tracking Labels"msgstr ""diff --git a/packages/locale/locales/ja/erp.po b/packages/locale/locales/ja/erp.poindex f5b474ec9a..3e4965a5ea 100644--- a/packages/locale/locales/ja/erp.po+++ b/packages/locale/locales/ja/erp.po@@ -889,6 +889,15 @@ msgstr ""msgid "Assembly:"msgstr ""+msgid "Asset"+msgstr ""++msgid "Asset Classes"+msgstr ""++msgid "Assets"+msgstr ""+msgid "Assign To"msgstr ""@@ -1422,9 +1431,6 @@ msgstr ""msgid "Configure Item"msgstr ""-msgid "Configure Materials"-msgstr ""-msgid "Configure notifications for when gauges go out of calibration."msgstr ""@@ -2412,6 +2418,9 @@ msgstr ""msgid "Departments"msgstr ""+msgid "Depreciation"+msgstr ""+msgid "Description"msgstr ""@@ -2881,6 +2890,9 @@ msgstr ""msgid "Enable to automatically post transactions to the general ledger."msgstr ""+msgid "Enable to configure tax-specific depreciation methods on asset classes (e.g., MACRS, accelerated)."+msgstr ""+msgid "Enable to generate IDs and descriptions for raw materials."msgstr ""@@ -3512,6 +3524,12 @@ msgstr ""msgid "Fixed"msgstr ""+msgid "Fixed Asset"+msgstr ""++msgid "Fixed Assets"+msgstr ""+msgid "Fixed Reorder"msgstr ""@@ -4426,6 +4444,9 @@ msgstr ""msgid "Material IDs"msgstr ""+msgid "Material Properties"+msgstr ""+msgid "Material Shape"msgstr ""@@ -6506,6 +6527,9 @@ msgstr ""msgid "Search"msgstr ""+msgid "Search accounts..."+msgstr ""+msgid "Search across your workspace..."msgstr ""@@ -6930,6 +6954,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -7381,6 +7408,9 @@ msgstr ""msgid "Tax & Additional Costs"msgstr ""+msgid "Tax & Shipping"+msgstr ""+msgid "Tax Amount"msgstr ""@@ -7681,6 +7711,12 @@ msgstr ""msgid "Track every change to your orders, invoices, customers, suppliers, and more."msgstr ""+msgid "Track tax depreciation separately"+msgstr ""++msgid "Track tax depreciation separately from book depreciation and automatically post deferred tax liability entries."+msgstr ""+msgid "Track when batches or serials of this item expire."msgstr ""diff --git a/packages/locale/locales/ja/mes.po b/packages/locale/locales/ja/mes.poindex 64034cce2f..726f635b8a 100644--- a/packages/locale/locales/ja/mes.po+++ b/packages/locale/locales/ja/mes.po@@ -403,7 +403,7 @@ msgid "Job Traveler"msgstr ""msgid "Jobs"-msgstr ""+msgstr "ジョブ"msgid "Kit"msgstr ""@@ -536,7 +536,7 @@ msgid "No materials"msgstr ""msgid "No open jobs"-msgstr ""+msgstr "オープンなジョブはありません"msgid "No operators"msgstr ""@@ -597,7 +597,7 @@ msgid "Open"msgstr ""msgid "Open Jobs"-msgstr ""+msgstr "オープンジョブ"msgid "Operations"msgstr ""@@ -718,7 +718,7 @@ msgid "Search"msgstr ""msgid "Search by job or item ID"-msgstr ""+msgstr "ジョブまたはアイテムIDで検索"msgid "Search operators..."msgstr ""@@ -799,6 +799,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -891,7 +894,7 @@ msgid "Total: {0}"msgstr ""msgid "Tracking"-msgstr ""+msgstr "追跡"msgid "Tracking Labels"msgstr ""diff --git a/packages/locale/locales/nl/erp.po b/packages/locale/locales/nl/erp.ponew file mode 100644index 0000000000..85b3949bcf--- /dev/null+++ b/packages/locale/locales/nl/erp.po@@ -0,0 +1,8361 @@+msgid ""+msgstr ""+"MIME-Version: 1.0\n"+"Content-Type: text/plain; charset=utf-8\n"+"Content-Transfer-Encoding: 8bit\n"+"X-Generator: @lingui/cli\n"+"Language: nl\n"+"Project-Id-Version: \n"+"Report-Msgid-Bugs-To: \n"+"PO-Revision-Date: \n"+"Last-Translator: \n"+"Language-Team: \n"+"Plural-Forms: \n"++msgid " A supplier is a business or person who sells you parts or services."+msgstr ""++msgid "\"{storageUnitName}\" has {childCount} direct nested storage units. Deleting it will also delete them and anything underneath them. This cannot be undone."+msgstr ""++msgid "\"{storageUnitName}\" has 1 direct nested storage unit. Deleting it will also delete that unit and anything underneath it. This cannot be undone."+msgstr ""++#. placeholder {0}: rule.escalationDays+msgid "{0} days"+msgstr ""++#. placeholder {0}: attachment.name+#. placeholder {0}: file.name+msgid "{0} deleted successfully"+msgstr ""++#. placeholder {0}: history.length+msgid "{0} orders"+msgstr ""++#. placeholder {0}: selectedProcesses.length+msgid "{0} Processes"+msgstr ""++#. placeholder {0}: lotEntities.length - inspected+msgid "{0} un-sampled entities will be released to Available. Sampled passes stay Available and sampled failures stay Rejected."+msgstr ""++#. placeholder {0}: file.name+msgid "{0} uploaded successfully"+msgstr ""++msgid "{maxSizeMB}MB limit"+msgstr ""++msgid "{scopeCount} permissions"+msgstr ""++msgid "/month/user"+msgstr ""++#. placeholder {0}: allItems.length - 3+msgid "+{0} more"+msgstr ""++msgid "<0>delete</0> lets you delete rows. <1>delete</1> will match all rows by default, so remember to specify your filters!"+msgstr ""++msgid "<0>insert</0> lets you insert into your tables. You can also insert in bulk and do UPSERT."+msgstr ""++msgid "<0>insert</0> will also return the replaced values for UPSERT."+msgstr ""++msgid "<0>update</0> lets you update rows. <1>update</1> will match all rows by default. You can update specific rows using horizontal filters, e.g. <2>eq</2>, <3>lt</3>, and <4>is</4>."+msgstr ""++msgid "<0>update</0> will also return the replaced values for UPDATE."+msgstr ""++msgid "1 day"+msgstr ""++msgid "3D Model"+msgstr ""++msgid "5 User Minimum"+msgstr ""++msgid "5MB file limit"+msgstr ""++msgid "A consumable is a physical item used to make a part that can be used across multiple jobs"+msgstr ""++msgid "A contractor is a supplier contact with particular abilities and available hours"+msgstr ""++msgid "A customer is a business or person who buys your parts or services."+msgstr ""++msgid "A issue record tracks quality issues and their resolution process."+msgstr ""++msgid "A material is a physical item used to make a part that can be used across multiple jobs"+msgstr ""++msgid "A name is required to save a view"+msgstr ""++msgid "A new purchase order will be created for each supplier. Alternatively, you can choose an existing draft purchase order for the supplier to add the outside operations to."+msgstr ""++msgid "A new revision will be created using a copy of the current revision"+msgstr ""++msgid "A new size will be created using a copy of the current size"+msgstr ""++msgid "A part contains the information about a specific item that can be purchased or manufactured."+msgstr ""++msgid "A purchase invoice is a document that specifies the products or services purchased by a customer and the corresponding cost."+msgstr ""++msgid "A quote is a set of prices for specific parts and quantities."+msgstr ""++msgid "A quote line contains pricing and lead times for a particular part"+msgstr ""++msgid "A sales invoice is a document that specifies the products or services sold to a customer and the corresponding cost."+msgstr ""++msgid "A sales invoice line contains invoice details for a particular item"+msgstr ""++msgid "A sales order contains information about the agreement between the company and a specific customer for parts and services."+msgstr ""++msgid "A sales order line contains order details for a particular item"+msgstr ""++msgid "A sales request for quote (RFQ) is a customer inquiry for pricing on a set of parts and quantities. It may result in a quote."+msgstr ""++msgid "A tool is a physical item used to make a part that can be used across multiple jobs"+msgstr ""++msgid "A user records the expiry date on each batch or serial when the goods are received. Use when suppliers ship lots with different expiry dates."+msgstr ""++msgid "Abilities"+msgstr ""++msgid "About"+msgstr ""++msgid "Accept Lot"+msgstr ""++msgid "Accept lot?"+msgstr ""++msgid "Accept Quote"+msgstr ""++msgid "Account"+msgstr ""++msgid "Account Manager"+msgstr ""++msgid "Account Number"+msgstr ""++msgid "Account Settings"+msgstr ""++msgid "Account Type"+msgstr ""++msgid "Accounting"+msgstr ""++msgid "Accounting is disabled"+msgstr ""++msgid "Accounting is enabled"+msgstr ""++msgid "Accounts"+msgstr ""++msgid "Accounts Payable Billing Address"+msgstr ""++msgid "Accounts Receivable Billing Address"+msgstr ""++msgid "Accumulation Period (Weeks)"+msgstr ""++msgid "Accumulation Period:"+msgstr ""++msgid "Acknowledge & continue"+msgstr ""++msgid "Action Items"+msgstr ""++msgid "Action Status"+msgstr ""++msgid "Action Type"+msgstr ""++msgid "Action Types"+msgstr ""++msgid "Actions"+msgstr ""++msgid "Activate"+msgstr ""++msgid "Activate {name}"+msgstr ""++msgid "Activate Process"+msgstr ""++msgid "Activate Work Center"+msgstr ""++msgid "Active"+msgstr ""++msgid "Active Jobs"+msgstr ""++msgid "Active Statuses"+msgstr ""++msgid "Active Supplier Quotes"+msgstr ""++msgid "Activity"+msgstr ""++msgid "Actual"+msgstr ""++msgid "Actual Cost"+msgstr ""++msgid "Actual End"+msgstr ""++msgid "Actual Failure Mode"+msgstr ""++msgid "Actual Start"+msgstr ""++msgid "Add"+msgstr ""++msgid "Add & Issue"+msgstr ""++msgid "Add a column below to sort the view"+msgstr ""++msgid "Add a comment..."+msgstr ""++msgid "Add Actions"+msgstr ""++msgid "Add any notes about your decision..."+msgstr ""++msgid "Add Approval Requirement"+msgstr ""++msgid "Add attachments"+msgstr ""++msgid "Add Calibration Record"+msgstr ""++msgid "Add Child Storage Unit"+msgstr ""++msgid "Add Company"+msgstr ""++msgid "Add condition"+msgstr ""++msgid "Add Contractor"+msgstr ""++msgid "Add Entry"+msgstr ""++msgid "Add from library…"+msgstr ""++msgid "Add Group"+msgstr ""++msgid "Add Item"+msgstr ""++msgid "Add Line"+msgstr ""++msgid "Add Line Item"+msgstr ""++msgid "Add Note"+msgstr ""++msgid "Add notes and documentation for this maintenance dispatch"+msgstr ""++msgid "Add Operation"+msgstr ""++msgid "Add options above first"+msgstr ""++msgid "Add Pair"+msgstr ""++msgid "Add Parameter"+msgstr ""++msgid "Add Partner"+msgstr ""++msgid "Add Permissions"+msgstr ""++msgid "Add Property"+msgstr ""++msgid "Add Question"+msgstr ""++msgid "Add Receipt"+msgstr ""++msgid "Add Required Actions"+msgstr ""++msgid "Add Requirement"+msgstr ""++msgid "Add Risk"+msgstr ""++msgid "Add rule"+msgstr ""++msgid "Add Shipment"+msgstr ""++msgid "Add Shipping"+msgstr ""++msgid "Add Spare Part"+msgstr ""++msgid "Add Step"+msgstr ""++msgid "Add Supplier"+msgstr ""++msgid "Add Timecard"+msgstr ""++msgid "Add to stock for future use"+msgstr ""++msgid "Add-On"+msgstr ""++msgid "Add-On Cost"+msgstr ""++msgid "Adding..."+msgstr ""++msgid "Address"+msgstr ""++msgid "Address Line 1"+msgstr ""++msgid "Address Line 2"+msgstr ""++msgid "Adjustment Type"+msgstr ""++msgid "Advanced"+msgstr ""++msgid "After"+msgstr ""++msgid "AI Tokens"+msgstr ""++msgid "All"+msgstr ""++msgid "All Audit Logs"+msgstr ""++msgid "All changes to auditable entities are being recorded."+msgstr ""++msgid "All Customers"+msgstr ""++msgid "All Documents"+msgstr ""++msgid "All Items"+msgstr ""++msgid "All jobs completed"+msgstr ""++msgid "All members of selected groups and selected individuals will be able to approve requests"+msgstr ""++msgid "All Suppliers"+msgstr ""++msgid "All Types"+msgstr ""++msgid "All Work Centers"+msgstr ""++msgid "Allows acknowledge & continue"+msgstr ""++msgid "Alpha"+msgstr ""++msgid "Always"+msgstr ""++msgid "Amount"+msgstr ""++msgid "Amount Type"+msgstr ""++msgid "An item cannot be added to itself."+msgstr ""++msgid "and {remaining} more"+msgstr ""++msgid "API and Webhooks"+msgstr ""++msgid "API Docs"+msgstr ""++msgid "API Documentation"+msgstr ""++msgid "API Key"+msgstr ""++msgid "API Keys"+msgstr ""++msgid "Applies to"+msgstr ""++msgid "Apply pricing rules"+msgstr ""++msgid "Apply To"+msgstr ""++msgid "Approval Date"+msgstr ""++msgid "Approval Requirements"+msgstr ""++msgid "Approval Rules"+msgstr ""++msgid "Approve"+msgstr ""++msgid "Approved By"+msgstr ""++msgid "AQL"+msgstr ""++msgid "Archive"+msgstr ""++msgid "Archive all"+msgstr ""++msgid "Archived"+msgstr ""++msgid "Archived Logs"+msgstr ""++#. placeholder {0}: quote.quoteId+#. placeholder {1}: formatter.format(total)+msgid "Are you sure you want to accept quote {0} for {1}?"+msgstr ""++msgid "Are you sure you want to activate the process: {name}? It will appear in dropdowns again."+msgstr ""++msgid "Are you sure you want to activate this gauge?."+msgstr ""++#. placeholder {0}: routeData?.rfqSummary ?.rfqId!+msgid "Are you sure you want to cancel {0}? This will also cancel all related supplier quotes."+msgstr ""++msgid "Are you sure you want to cancel this job? It will no longer be available on the shop floor."+msgstr ""++msgid "Are you sure you want to change the {propertyName} property? Since you use generated material IDs this will change the part ID of this part, and all related revisions."+msgstr ""++msgid "Are you sure you want to complete this stock transfer?"+msgstr ""++msgid "Are you sure you want to confirm this sales order? Confirming the order will affect on order quantities used to calculate supply and demand."+msgstr ""++msgid "Are you sure you want to convert the RFQ to a quote?"+msgstr ""++msgid "Are you sure you want to create jobs for this sales order? This will create jobs for all lines that don't already have jobs."+msgstr ""++#. placeholder {0}: routeData?.supplier?.name+msgid "Are you sure you want to deactivate {0}?"+msgstr ""++#. placeholder {0}: selectedCategory?.name+msgid "Are you sure you want to deactivate the {0} attribute category?"+msgstr ""++#. placeholder {0}: selectedAttribute?.name+msgid "Are you sure you want to deactivate the {0} attribute?"+msgstr ""++msgid "Are you sure you want to deactivate the {label} configuration rule?"+msgstr ""++msgid "Are you sure you want to deactivate the process: {name}? It will no longer appear in dropdowns."+msgstr ""++msgid "Are you sure you want to deactivate these users?"+msgstr ""++msgid "Are you sure you want to deactivate this gauge?."+msgstr ""++msgid "Are you sure you want to deactivate this user?"+msgstr ""++#. placeholder {0}: tool.readableIdWithRevision+msgid "Are you sure you want to delete {0} from this operation? This cannot be undone."+msgstr ""++#. placeholder {0}: selectedGroup.name+msgid "Are you sure you want to delete {0}?"+msgstr ""++#. placeholder {0}: routeData?.consumableSummary?.readableIdWithRevision+#. placeholder {0}: routeData?.customer?.name!+#. placeholder {0}: routeData?.document?.name+msgid "Are you sure you want to delete {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: selectedCustomField?.name+msgid "Are you sure you want to delete the {0} field?"+msgstr ""++#. placeholder {0}: parameter.label+msgid "Are you sure you want to delete the {0} parameter? This will not update any formulas that are using this parameter."+msgstr ""++msgid "Are you sure you want to delete the {key} parameter from this operation? This cannot be undone."+msgstr ""++msgid "Are you sure you want to delete the {name} attribute from this operation? This cannot be undone."+msgstr ""++#. placeholder {0}: account.name+#. placeholder {1}: account.number ? ` (${account.number})` : ""+msgid "Are you sure you want to delete the account: {0}{1}? This cannot be undone."+msgstr ""++#. placeholder {0}: apiKey.name+msgid "Are you sure you want to delete the API key: {0}? This cannot be undone."+msgstr ""++msgid "Are you sure you want to delete the contractor: {name}? This cannot be undone."+msgstr ""++#. placeholder {0}: customerPart?.customer?.name ?? ""+msgid "Are you sure you want to delete the customer part for {0}? This cannot be undone."+msgstr ""++msgid "Are you sure you want to delete the customer portal for: {customerName}? This cannot be undone."+msgstr ""++#. placeholder {0}: customerStatus.name+msgid "Are you sure you want to delete the customer status: {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: customerType.name+msgid "Are you sure you want to delete the customer type: {0}? This cannot be undone."+msgstr ""++msgid "Are you sure you want to delete the department: {name}? This cannot be undone."+msgstr ""++#. placeholder {0}: employeeType.name+msgid "Are you sure you want to delete the employee type: {0}? This cannot be undone."+msgstr ""++msgid "Are you sure you want to delete the failure mode: {name}? This cannot be undone."+msgstr ""++#. placeholder {0}: gaugeType.name+msgid "Are you sure you want to delete the gauge type: {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: group.name+msgid "Are you sure you want to delete the group: {0}? This cannot be undone."+msgstr ""++msgid "Are you sure you want to delete the holiday: {name}? This cannot be undone."+msgstr ""++#. placeholder {0}: nonConformanceType.name+msgid "Are you sure you want to delete the issue type: {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: itemPostingGroup.name+msgid "Are you sure you want to delete the item group: {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: line.customerPartId+#. placeholder {0}: line.description+#. placeholder {0}: line.itemReadableId+msgid "Are you sure you want to delete the line: {0}? This cannot be undone."+msgstr ""++msgid "Are you sure you want to delete the line: {itemReadableId}? This cannot be undone."+msgstr ""++msgid "Are you sure you want to delete the location: {name}? This cannot be undone."+msgstr ""++msgid "Are you sure you want to delete the maintenance schedule: {name}? This cannot be undone."+msgstr ""++#. placeholder {0}: materialDimension.name+msgid "Are you sure you want to delete the material dimension: {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: materialFinish.name+msgid "Are you sure you want to delete the material finish: {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: materialForm.name+msgid "Are you sure you want to delete the material form: {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: materialGrade.name+msgid "Are you sure you want to delete the material grade: {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: materialSubstance.name+msgid "Are you sure you want to delete the material substance: {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: materialType.name+msgid "Are you sure you want to delete the material type: {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: noQuoteReason.name+msgid "Are you sure you want to delete the no quote reason: {0}? This cannot be undone."+msgstr ""++msgid "Are you sure you want to delete the partner: {name}? This cannot be undone."+msgstr ""++#. placeholder {0}: paymentTerm.name+msgid "Are you sure you want to delete the payment term: {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: pricingRule.name+msgid "Are you sure you want to delete the pricing rule: {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: purchaseInvoiceLine.quantity ?? 0+#. placeholder {1}: purchaseInvoiceLine.description ?? ""+msgid "Are you sure you want to delete the purchase invoice line for {0} {1}? This cannot be undone."+msgstr ""++#. placeholder {0}: salesInvoiceLine.quantity ?? 0+#. placeholder {1}: salesInvoiceLine.description ?? ""+msgid "Are you sure you want to delete the sales invoice line for {0} {1}? This cannot be undone."+msgstr ""++#. placeholder {0}: salesOrderLine.saleQuantity ?? 0+#. placeholder {1}: salesOrderLine.description ?? ""+msgid "Are you sure you want to delete the sales order line for {0} {1}? This cannot be undone."+msgstr ""++#. placeholder {0}: scrapReason.name+msgid "Are you sure you want to delete the scrap reason: {0}? This cannot be undone."+msgstr ""++msgid "Are you sure you want to delete the shift: {name} from {locationName}? This cannot be undone."+msgstr ""++#. placeholder {0}: shippingMethod.name+msgid "Are you sure you want to delete the shipping method: {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: storageType.name+msgid "Are you sure you want to delete the storage type: {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: storageUnit.name+msgid "Are you sure you want to delete the storage unit: {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: supplierType.name+msgid "Are you sure you want to delete the supplier type: {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: unitOfMeasure.name+msgid "Are you sure you want to delete the unit of measure: {0}? This cannot be undone."+msgstr ""++#. placeholder {0}: selectedView.name+msgid "Are you sure you want to delete the view \"{0}\"?"+msgstr ""++#. placeholder {0}: webhook.name+msgid "Are you sure you want to delete the webhook: {0}? This cannot be undone."+msgstr ""++msgid "Are you sure you want to delete this approval rule? This cannot be undone."+msgstr ""++msgid "Are you sure you want to delete this gauge?"+msgstr ""++msgid "Are you sure you want to delete this issue workflow?"+msgstr ""++msgid "Are you sure you want to delete this issue?"+msgstr ""++msgid "Are you sure you want to delete this kanban card? This cannot be undone."+msgstr ""++msgid "Are you sure you want to delete this maintenance dispatch? This cannot be undone."+msgstr ""++msgid "Are you sure you want to delete this quality document?"+msgstr ""++msgid "Are you sure you want to delete this record?"+msgstr ""++msgid "Are you sure you want to delete this required action?"+msgstr ""++msgid "Are you sure you want to delete this risk?"+msgstr ""++msgid "Are you sure you want to delete this risk? This cannot be undone."+msgstr ""++msgid "Are you sure you want to delete this suggestion? This action cannot be undone."+msgstr ""++msgid "Are you sure you want to delete this timecard? This cannot be undone."+msgstr ""++msgid "Are you sure you want to finalize the quote?"+msgstr ""++msgid "Are you sure you want to finalize the supplier quote?"+msgstr ""++#. placeholder {0}: selectedPurchaseInvoice.invoiceId!+#. placeholder {0}: selectedSalesInvoice.invoiceId!+msgid "Are you sure you want to permanently delete {0}?"+msgstr ""++msgid "Are you sure you want to permanently delete the supplier process?"+msgstr ""++msgid "Are you sure you want to post this receipt?"+msgstr ""++msgid "Are you sure you want to post this shipment?"+msgstr ""++msgid "Are you sure you want to reject this quote?"+msgstr ""++msgid "Are you sure you want to release this job? It will become available to the shop floor, and drive purchasing and production."+msgstr ""++msgid "Are you sure you want to remove this item from the price list? This cannot be undone."+msgstr ""++msgid "Are you sure you want to revoke the invitation for this user?"+msgstr ""++msgid "Are you sure you want to revoke the invitations for these users?"+msgstr ""++msgid "Are you sure you want to send an invite to these users?"+msgstr ""++msgid "Are you sure you want to send an invite to this user?"+msgstr ""++msgid "Are you sure you want to void this purchase invoice? This action will reverse all financial transactions and cannot be undone."+msgstr ""++msgid "Are you sure you want to void this receipt? This action will reverse all inventory transactions and cannot be undone."+msgstr ""++msgid "Are you sure you want to void this sales invoice? This action will reverse all financial transactions and cannot be undone."+msgstr ""++msgid "Are you sure you want to void this shipment? This action will reverse all inventory transactions and cannot be undone."+msgstr ""++msgid "Are you sure?"+msgstr ""++msgid "As the company owner, you can transfer ownership to another employee. This will give them full access to billing and administrative settings."+msgstr ""++msgid "Ascending"+msgstr ""++#. js-lingui-explicit-id+msgid "Ask anything"+msgstr ""++msgid "Assembly:"+msgstr ""++msgid "Assign To"+msgstr ""++msgid "Assign to Groups"+msgstr ""++msgid "Assigned"+msgstr ""++msgid "Assigned to Me"+msgstr ""++msgid "Assignee"+msgstr ""++msgid "Assignment"+msgstr ""++msgid "Assignments"+msgstr ""++msgid "At least one condition must match"+msgstr ""++msgid "Attach File"+msgstr ""++msgid "Attachment"+msgstr ""++msgid "Attribute"+msgstr ""++msgid "Attribute sampling standard used to compute lot sample sizes and accept/reject numbers on inbound inspections."+msgstr ""++msgid "Attributes"+msgstr ""++msgid "Attributes are inherited from the procedure."+msgstr ""++msgid "Audit Log"+msgstr ""++msgid "Audit Logging"+msgstr ""++msgid "Audit logging is disabled"+msgstr ""++msgid "Audit logging is enabled"+msgstr ""++msgid "Audit logging is not enabled"+msgstr ""++msgid "Audit Logs"+msgstr ""++msgid "Authentication Error"+msgstr ""++msgid "Auto Release"+msgstr ""++msgid "Auto release must be enabled to start a job automatically"+msgstr ""++msgid "Auto Start Job"+msgstr ""++msgid "Auto-generated QR Code"+msgstr ""++msgid "Automatically release the job when the kanban is scanned"+msgstr ""++msgid "Automatically start the job when the kanban is scanned"+msgstr ""++msgid "Available"+msgstr ""++msgid "Avg Days to Close"+msgstr ""++msgid "Back"+msgstr ""++msgid "Back to home"+msgstr ""++msgid "Back to traceability"+msgstr ""++msgid "Backflush"+msgstr ""++msgid "Balance Sheet"+msgstr ""++msgid "Base Currency"+msgstr ""++msgid "Base Price"+msgstr ""++msgid "Basic Information"+msgstr ""++msgid "Batch"+msgstr ""++msgid "Batch items require a sales order"+msgstr ""++msgid "Batch number"+msgstr ""++msgid "Batch Number"+msgstr ""++msgid "Batch Properties"+msgstr ""++msgid "Batch Size"+msgstr ""++msgid "Batch Tracking"+msgstr ""++msgid "Beta"+msgstr ""++msgid "Bill of Material"+msgstr ""++msgid "Bill of Materials"+msgstr ""++msgid "Bill of Process"+msgstr ""++msgid "Bill To"+msgstr ""++msgid "Billing"+msgstr ""++msgid "Billing Address"+msgstr ""++msgid "Block with an error"+msgstr ""++msgid "Block, allow override"+msgstr ""++#. placeholder {0}: workCenter.blockingDispatchReadableId+msgid "Blocked by {0}"+msgstr ""++msgid "Blocks save until resolved"+msgstr ""++msgid "BoM"+msgstr ""++msgid "BoM + BoP"+msgstr ""++msgid "BOM synced successfully"+msgstr ""++msgid "Breadcrumb"+msgstr ""++msgid "Browse library"+msgstr ""++msgid "Bucket"+msgstr ""++msgid "Bulk Import"+msgstr ""++msgid "Bulk Jobs"+msgstr ""++msgid "Buy"+msgstr ""++msgid "Buy and Make"+msgstr ""++msgid "Buyer"+msgstr ""++msgid "by {byUser}"+msgstr ""++msgid "By accepting the invite, you agree to the <0>Terms of Service</0> and <1>Privacy Policy</1>."+msgstr ""++msgid "By signing in, you agree to the <0>Terms of Service</0> and <1>Privacy Policy.</1>"+msgstr ""++msgid "CAD Model"+msgstr ""++msgid "Calculate from BOM"+msgstr ""++msgid "Calculated finished-good expiry"+msgstr ""++msgid "Calculation Method"+msgstr ""++msgid "Calibration Expiration Notifications"+msgstr ""++msgid "Calibration Interval (Months)"+msgstr ""++msgid "Calibration Records"+msgstr ""++msgid "Calibration Status"+msgstr ""++msgid "Calibration Supplier"+msgstr ""++msgid "Calibrations"+msgstr ""++msgid "Can't disable the only active break. Add another break or toggle the override's Active instead."+msgstr ""++msgid "Cancel"+msgstr ""++msgid "Cancel Job"+msgstr ""++msgid "Canceled"+msgstr ""++msgid "Cancelled"+msgstr ""++msgid "Cannot add parameters to unsaved operation"+msgstr ""++msgid "Cannot add steps to unsaved operation"+msgstr ""++msgid "Cannot add tools to unsaved operation"+msgstr ""++msgid "Cannot convert RFQ to quote"+msgstr ""++msgid "Cannot move to parts bucket without item ID"+msgstr ""++msgid "Cannot place order - no supplier associated with this item"+msgstr ""++msgid "Cannot post — shipment contains expired tracked entities."+msgstr ""++msgid "Cannot send RFQ"+msgstr ""++msgid "Cannot upload to parts bucket without item ID"+msgstr ""++msgid "Carbon client is not available"+msgstr ""++msgid "Carbon client not available"+msgstr ""++msgid "Carbon client not found"+msgstr ""++msgid "Carbon column"+msgstr ""++msgid "Carbon Logo"+msgstr ""++msgid "Carbon Value"+msgstr ""++msgid "Carrier"+msgstr ""++msgid "Carrier Account"+msgstr ""++msgid "Category"+msgstr ""++msgid "Category Name"+msgstr ""++msgid "CC"+msgstr ""++msgid "Change"+msgstr ""++msgid "Change status"+msgstr ""++msgid "Change the item type (e.g. Part, Material, Tool, etc.)"+msgstr ""++msgid "Change Type"+msgstr ""++msgid "Changed By"+msgstr ""++msgid "Changes"+msgstr ""++msgid "Changing this will overwrite the existing method"+msgstr ""++msgid "Changing this will update the part ID"+msgstr ""++msgid "Chart of Accounts"+msgstr ""++msgid "Chat"+msgstr ""++msgid "Check your email"+msgstr ""++msgid "Choose another file"+msgstr ""++msgid "Choose your preferred language for the interface."+msgstr ""++msgid "Choose your style"+msgstr ""++msgid "City"+msgstr ""++msgid "Class"+msgstr ""++msgid "Clear"+msgstr ""++msgid "Clear All"+msgstr ""++msgid "Clear due date"+msgstr ""++msgid "Clear Filters"+msgstr ""++msgid "Clear search"+msgstr ""++msgid "Clear search query"+msgstr ""++msgid "Clock In"+msgstr ""++msgid "Clock Out"+msgstr ""++#. placeholder {0}: formatTime(openEntry.clockIn, locale)+msgid "Clocked in since {0}"+msgstr ""++msgid "Close"+msgstr ""++msgid "Close Date"+msgstr ""++msgid "Closed Date"+msgstr ""++msgid "Closure blocked"+msgstr ""++msgid "Cloud-Hosted"+msgstr ""++msgid "Code"+msgstr ""++msgid "Collapse all"+msgstr ""++msgid "Collapse Costs"+msgstr ""++msgid "Collapse Labor"+msgstr ""++msgid "Collapse Machine"+msgstr ""++msgid "Collapse Setup"+msgstr ""++msgid "Collapse subtree"+msgstr ""++msgid "Column"+msgstr ""++msgid "Column visibility and order"+msgstr ""++msgid "Columns"+msgstr ""++msgid "Coming soon"+msgstr ""++msgid "comma-separated values"+msgstr ""++msgid "Comment"+msgstr ""++msgid "Comments"+msgstr ""++msgid "Companies"+msgstr ""++msgid "Company"+msgstr ""++msgid "Company Name"+msgstr ""++msgid "Company policy asks for a different person to inspect inbound items than the one who received them."+msgstr ""++msgid "Compare and Order"+msgstr ""++msgid "Compare at quantity:"+msgstr ""++msgid "Compare Quotes"+msgstr ""++msgid "Compare Supplier Quotes"+msgstr ""++msgid "Complete"+msgstr ""++msgid "Complete All"+msgstr ""++msgid "Complete all quantities on barcode scan"+msgstr ""++msgid "Complete Job"+msgstr ""++msgid "Complete Stock Transfer"+msgstr ""++msgid "Completed"+msgstr ""++msgid "Completed At"+msgstr ""++msgid "Completed Date"+msgstr ""++msgid "Completed Job Notifications"+msgstr ""++msgid "Completed Qty"+msgstr ""++msgid "Completion Barcode"+msgstr ""++msgid "Completion Time"+msgstr ""++msgid "Conditions"+msgstr ""++msgid "Configuration Parameters"+msgstr ""++msgid "Configurator"+msgstr ""++msgid "Configure"+msgstr ""++msgid "Configure {label}"+msgstr ""++msgid "Configure defaults for the quality dashboard."+msgstr ""++msgid "Configure how preventative maintenance dispatches are automatically generated from maintenance schedules."+msgstr ""++msgid "Configure Item"+msgstr ""++msgid "Configure Materials"+msgstr ""++msgid "Configure notifications for when gauges go out of calibration."+msgstr ""++msgid "Configure notifications for when jobs are completed."+msgstr ""++msgid "Configure notifications for when maintenance dispatches are created from the shop floor. Notifications are routed based on the failure mode type."+msgstr ""++msgid "Configure notifications for when new suggestions are submitted."+msgstr ""++msgid "Configure the content displayed on job traveler PDFs."+msgstr ""++msgid "Configure the default accounts used for various transaction types across your system"+msgstr ""++msgid "Configure the start months for your fiscal and tax years"+msgstr ""++msgid "Configure when purchased item prices should be updated from supplier transactions."+msgstr ""++msgid "Configure who should receive notifications when a supplier submits a quote."+msgstr ""++msgid "Configured"+msgstr ""++msgid "Confirm"+msgstr ""++#. placeholder {0}: salesOrder?.salesOrderId+msgid "Confirm {0}"+msgstr ""++msgid "Confirm ID Change"+msgstr ""++msgid "Confirm Import"+msgstr ""++msgid "Confirm Password"+msgstr ""++msgid "Connect Carbon to your accounting, project, and CAD tools and much more."+msgstr ""++msgid "Connect Jira issue"+msgstr ""++msgid "Connect Linear issue"+msgstr ""++msgid "Connected to"+msgstr ""++msgid "Console Mode"+msgstr ""++msgid "Console mode has been enabled. Use this PIN to identify yourself at MES terminals."+msgstr ""++msgid "Console mode is disabled"+msgstr ""++msgid "Console mode is enabled"+msgstr ""++msgid "Console Operator"+msgstr ""++msgid "Consumable"+msgstr ""++msgid "Consumable Details"+msgstr ""++msgid "Consumable ID"+msgstr ""++msgid "Consumables"+msgstr ""++msgid "Consumed"+msgstr ""++msgid "Contact"+msgstr ""++msgid "Contact (optional)"+msgstr ""++msgid "Contacts"+msgstr ""++msgid "Contained"+msgstr ""++msgid "Containment"+msgstr ""++msgid "Contractor"+msgstr ""++msgid "Contractors"+msgstr ""++msgid "Conversion"+msgstr ""++msgid "Conversion Factor"+msgstr ""++msgid "Conversion:"+msgstr ""++msgid "Convert"+msgstr ""++msgid "Convert Line to Job"+msgstr ""++msgid "Convert Lines to Jobs"+msgstr ""++msgid "Convert to Quote"+msgstr ""++msgid "Copied link to clipboard"+msgstr ""++msgid "Copied!"+msgstr ""++msgid "Copy"+msgstr ""++msgid "Copy all items and pricing to another customer or type."+msgstr ""++msgid "Copy API Key"+msgstr ""++msgid "Copy consumable number"+msgstr ""++msgid "Copy dispatch ID"+msgstr ""++msgid "Copy dispatch number"+msgstr ""++msgid "Copy document name"+msgstr ""++msgid "Copy document unique identifier"+msgstr ""++msgid "Copy ID"+msgstr ""++msgid "Copy issue number"+msgstr ""++msgid "Copy issue unique identifier"+msgstr ""++msgid "Copy Job number"+msgstr ""++msgid "Copy link"+msgstr ""++msgid "Copy link to consumable"+msgstr ""++msgid "Copy link to dispatch"+msgstr ""++msgid "Copy link to document"+msgstr ""++msgid "Copy link to issue"+msgstr ""++msgid "Copy link to Job"+msgstr ""++msgid "Copy link to material"+msgstr ""++msgid "Copy link to part"+msgstr ""++msgid "Copy link to procedure"+msgstr ""++msgid "Copy link to tool"+msgstr ""++msgid "Copy link to training"+msgstr ""++msgid "Copy material number"+msgstr ""++msgid "Copy material unique identifier"+msgstr ""++msgid "Copy MCP Command"+msgstr ""++msgid "Copy part number"+msgstr ""++msgid "Copy part unique identifier"+msgstr ""++msgid "Copy PIN"+msgstr ""++msgid "Copy pricing to a single customer"+msgstr ""++msgid "Copy pricing to all customers of a type"+msgstr ""++msgid "Copy procedure name"+msgstr ""++msgid "Copy procedure unique identifier"+msgstr ""++msgid "Copy Quote"+msgstr ""++msgid "Copy Quote number"+msgstr ""++msgid "Copy response"+msgstr ""++msgid "Copy this item's pricing to another scope."+msgstr ""++msgid "Copy this link to share the quote with a customer"+msgstr ""++msgid "Copy this link to share the quote with a supplier"+msgstr ""++msgid "Copy tool number"+msgstr ""++msgid "Copy tool unique identifier"+msgstr ""++msgid "Copy training name"+msgstr ""++msgid "Copy training unique identifier"+msgstr ""++msgid "Correct Answer"+msgstr ""++msgid "Correct Answers"+msgstr ""++msgid "Cost Center"+msgstr ""++msgid "Cost Centers"+msgstr ""++msgid "Cost History"+msgstr ""++msgid "Costing"+msgstr ""++msgid "Costing & Posting"+msgstr ""++msgid "Costing Method"+msgstr ""++msgid "Couldn't load documents"+msgstr ""++msgid "Country"+msgstr ""++msgid "Create"+msgstr ""++#. placeholder {0}: search.trim() === "" ? (createLabel ?? label) : search+#. placeholder {0}: search.trim() === "" ? label : search+msgid "Create {0}"+msgstr ""++msgid "Create a new kanban card for scan-based replenishment."+msgstr ""++msgid "Create a new maintenance dispatch to track equipment repairs and maintenance activities"+msgstr ""++msgid "Create a new production job to fulfill the sales order"+msgstr ""++msgid "Create a quote with a new quote ID"+msgstr ""++msgid "Create Account"+msgstr ""++msgid "Create an account"+msgstr ""++msgid "Create audit trail entries"+msgstr ""++msgid "Create Issue"+msgstr ""++msgid "Create Issue from Inspection"+msgstr ""++msgid "Create Jobs"+msgstr ""++msgid "Create Kanban"+msgstr ""++msgid "Create new rule"+msgstr ""++msgid "Create Quote Revision"+msgstr ""++msgid "Create Revision"+msgstr ""++msgid "Create Rule"+msgstr ""++msgid "Create User"+msgstr ""++msgid "Create Version"+msgstr ""++msgid "Create Work Center"+msgstr ""++msgid "Created"+msgstr ""++msgid "Created account"+msgstr ""++msgid "Created At"+msgstr ""++msgid "Created By"+msgstr ""++msgid "Created consumable"+msgstr ""++msgid "Created customer portal"+msgstr ""++msgid "Created customer status"+msgstr ""++msgid "Created customer type"+msgstr ""++#. placeholder {0}: createdCustomer?.name ?? t`Customer`+msgid "Created customer: {0}"+msgstr ""++msgid "Created department"+msgstr ""++msgid "Created failure mode"+msgstr ""++msgid "Created gauge type"+msgstr ""++msgid "Created item group"+msgstr ""++msgid "Created location"+msgstr ""++msgid "Created maintenance schedule"+msgstr ""++msgid "Created material"+msgstr ""++msgid "Created material dimension"+msgstr ""++msgid "Created material finish"+msgstr ""++msgid "Created material form"+msgstr ""++msgid "Created material grade"+msgstr ""++msgid "Created material substance"+msgstr ""++msgid "Created material type"+msgstr ""++msgid "Created no quote reason"+msgstr ""++msgid "Created non conformance type"+msgstr ""++msgid "Created part"+msgstr ""++msgid "Created payment term"+msgstr ""++msgid "Created process"+msgstr ""++msgid "Created required action"+msgstr ""++msgid "Created scrap reason"+msgstr ""++msgid "Created shipping method"+msgstr ""++msgid "Created stock transfer line"+msgstr ""++msgid "Created storage type"+msgstr ""++#. placeholder {0}: fetcher.data.data.name+msgid "Created supplier: {0}"+msgstr ""++msgid "Created tool"+msgstr ""++msgid "Created unit of measure"+msgstr ""++msgid "Created webhook"+msgstr ""++msgid "Created work center"+msgstr ""++msgid "Creating part..."+msgstr ""++msgid "CSV column"+msgstr ""++msgid "CSV file must have at least 2 rows."+msgstr ""++msgid "Currency"+msgstr ""++msgid "Current"+msgstr ""++msgid "Current Password"+msgstr ""++msgid "Current quantity"+msgstr ""++msgid "Currently training for"+msgstr ""++msgid "Custom"+msgstr ""++msgid "Custom {label}"+msgstr ""++msgid "Custom Field"+msgstr ""++msgid "Custom Fields"+msgstr ""++msgid "Customer"+msgstr ""++msgid "Customer Accounts"+msgstr ""++msgid "Customer Contact"+msgstr ""++msgid "Customer Details"+msgstr ""++msgid "Customer ID"+msgstr ""++msgid "Customer Invoice Number"+msgstr ""++msgid "Customer Location"+msgstr ""++msgid "Customer Overview"+msgstr ""++msgid "Customer Part"+msgstr ""++msgid "Customer Part ID"+msgstr ""++msgid "Customer Part Number"+msgstr ""++msgid "Customer Part Revision"+msgstr ""++msgid "Customer Parts"+msgstr ""++msgid "Customer PO"+msgstr ""++msgid "Customer PO Number"+msgstr ""++msgid "Customer Portal"+msgstr ""++msgid "Customer Portals"+msgstr ""++msgid "Customer Revision"+msgstr ""++msgid "Customer RFQ"+msgstr ""++msgid "Customer Scope"+msgstr ""++msgid "Customer Status"+msgstr ""++msgid "Customer Statuses"+msgstr ""++msgid "Customer Type"+msgstr ""++msgid "Customer Types"+msgstr ""++msgid "Customers"+msgstr ""++msgid "Daily Usage"+msgstr ""++msgid "Dark"+msgstr ""++msgid "Dark Mode"+msgstr ""++msgid "Dashboard"+msgstr ""++msgid "Data Type"+msgstr ""++msgid "Data type cannot be changed"+msgstr ""++msgid "Date"+msgstr ""++msgid "Date Acquired"+msgstr ""++msgid "Date Calibrated"+msgstr ""++msgid "Date Due"+msgstr ""++msgid "Date Issued"+msgstr ""++msgid "Date Paid"+msgstr ""++msgid "Date Range"+msgstr ""++msgid "Dates"+msgstr ""++msgid "Days"+msgstr ""++msgid "Days Discount"+msgstr ""++msgid "Days Due"+msgstr ""++msgid "Days in advance to generate dispatches"+msgstr ""++msgid "Days Off"+msgstr ""++msgid "Days Remaining"+msgstr ""++msgid "Deactivate"+msgstr ""++#. placeholder {0}: workCenter.name+msgid "Deactivate {0}"+msgstr ""++msgid "Deactivate {name}"+msgstr ""++msgid "Deactivate Account"+msgstr ""++msgid "Deactivate Employee"+msgstr ""++msgid "Deactivate Employees"+msgstr ""++msgid "Deactivate Process"+msgstr ""++msgid "Deactivate Supplier"+msgstr ""++msgid "Deactivate Users"+msgstr ""++msgid "Deactivate Work Center"+msgstr ""++msgid "Deadline Type"+msgstr ""++msgid "Decide what an operator sees if they try to issue a batch or serial that's already expired."+msgstr ""++msgid "Default Accounts"+msgstr ""++msgid "Default Approver"+msgstr ""++msgid "Default CC Recipients"+msgstr ""++msgid "Default Method"+msgstr ""++msgid "Default Method Type"+msgstr ""++msgid "Default Permissions"+msgstr ""++msgid "Default Priority"+msgstr ""++msgid "Default shelf-life duration (days)"+msgstr ""++msgid "Default Source"+msgstr ""++msgid "Default Storage Unit"+msgstr ""++msgid "Default Unit"+msgstr ""++msgid "Defaults"+msgstr ""++msgid "Define the default size of the product label. Used for tracking items in inventory."+msgstr ""++msgid "Define the terms and conditions for purchase orders"+msgstr ""++msgid "Define the terms and conditions for quotes and sales orders"+msgstr ""++msgid "Defines how many tracked entities are inspected per lot, and how many failures are tolerated before the lot is rejected."+msgstr ""++msgid "Delete"+msgstr ""++msgid "Delete {name}"+msgstr ""++msgid "Delete {storageUnitName}"+msgstr ""++msgid "Delete API Key"+msgstr ""++msgid "Delete Assignment"+msgstr ""++msgid "Delete Association"+msgstr ""++msgid "Delete Attribute"+msgstr ""++msgid "Delete Category"+msgstr ""++msgid "Delete chat"+msgstr ""++msgid "Delete Consumable"+msgstr ""++msgid "Delete Contact"+msgstr ""++msgid "Delete Contractor"+msgstr ""++msgid "Delete Custom Field"+msgstr ""++msgid "Delete Customer"+msgstr ""++msgid "Delete Customer Status"+msgstr ""++msgid "Delete Customer Type"+msgstr ""++msgid "Delete Department"+msgstr ""++msgid "Delete Dispatch"+msgstr ""++msgid "Delete Document"+msgstr ""++msgid "Delete Employee Type"+msgstr ""++msgid "Delete Failure Mode"+msgstr ""++msgid "Delete file"+msgstr ""++msgid "Delete Group"+msgstr ""++msgid "Delete Holiday"+msgstr ""++msgid "Delete Issue"+msgstr ""++msgid "Delete Line"+msgstr ""++msgid "Delete Location"+msgstr ""++msgid "Delete Material"+msgstr ""++msgid "Delete Material Dimension"+msgstr ""++msgid "Delete Material Finish"+msgstr ""++msgid "Delete Material Grade"+msgstr ""++msgid "Delete Material Shape"+msgstr ""++msgid "Delete Material Type"+msgstr ""++msgid "Delete Part"+msgstr ""++msgid "Delete Partner"+msgstr ""++msgid "Delete Payment Term"+msgstr ""++msgid "Delete Portal"+msgstr ""++msgid "Delete Price Break"+msgstr ""++msgid "Delete Pricing Rule"+msgstr ""++msgid "Delete Procedure"+msgstr ""++msgid "Delete Process"+msgstr ""++msgid "Delete Purchase Invoice"+msgstr ""++msgid "Delete Purchase Order"+msgstr ""++msgid "Delete Purchase Orders"+msgstr ""++msgid "Delete Question"+msgstr ""++msgid "Delete Quote"+msgstr ""++msgid "Delete Reason"+msgstr ""++msgid "Delete Receipt"+msgstr ""++msgid "Delete receipt line"+msgstr ""++msgid "Delete RFQ"+msgstr ""++msgid "Delete Risk"+msgstr ""++msgid "Delete rows"+msgstr ""++msgid "Delete Rule"+msgstr ""++msgid "Delete Sales Invoice"+msgstr ""++msgid "Delete Sales Order"+msgstr ""++msgid "Delete Schedule"+msgstr ""++msgid "Delete Shift"+msgstr ""++msgid "Delete Shipment"+msgstr ""++msgid "Delete shipment line"+msgstr ""++msgid "Delete Shipping Method"+msgstr ""++msgid "Delete Step"+msgstr ""++msgid "Delete Stock Transfer"+msgstr ""++msgid "Delete Storage Type"+msgstr ""++msgid "Delete Storage Unit"+msgstr ""++msgid "Delete Substance"+msgstr ""++msgid "Delete Suggestion"+msgstr ""++msgid "Delete Supplier"+msgstr ""++msgid "Delete Supplier Quote"+msgstr ""++msgid "Delete Supplier Type"+msgstr ""++msgid "Delete Timecard"+msgstr ""++msgid "Delete Tool"+msgstr ""++msgid "Delete Training"+msgstr ""++msgid "Delete Transfer"+msgstr ""++msgid "Delete Transfer Line"+msgstr ""++msgid "Delete View"+msgstr ""++msgid "Delete Warehouse Transfer"+msgstr ""++msgid "Delete Webhook"+msgstr ""++msgid "Delivery Date"+msgstr ""++msgid "Delivery Location"+msgstr ""++msgid "Demand"+msgstr ""++msgid "Demand Forecast"+msgstr ""++msgid "Demand Projections"+msgstr ""++msgid "Demand-Based"+msgstr ""++msgid "Department"+msgstr ""++msgid "Department Name"+msgstr ""++msgid "Departments"+msgstr ""++msgid "Description"+msgstr ""++msgid "Description (optional)"+msgstr ""++msgid "Description of Issue"+msgstr ""++msgid "Detail"+msgstr ""++msgid "Details"+msgstr ""++msgid "Digital Quote"+msgstr ""++msgid "Digital Quotes"+msgstr ""++msgid "Dimension"+msgstr ""++msgid "Dimensions"+msgstr ""++msgid "Direct"+msgstr ""++msgid "Disabled"+msgstr ""++msgid "Discard"+msgstr ""++msgid "Discount"+msgstr ""++msgid "Discount Days after {selectedCalculationMethod}"+msgstr ""++msgid "Discount Percent"+msgstr ""++msgid "Discount Percentage"+msgstr ""++msgid "Dismiss"+msgstr ""++msgid "Dispatch"+msgstr ""++msgid "Dispatch ID"+msgstr ""++msgid "Dispatches"+msgstr ""++msgid "Display Settings"+msgstr ""++msgid "Disposition"+msgstr ""++msgid "Dispositions"+msgstr ""++msgid "Do you want to overwrite the user's current permissions with the default permissions for this employee type?"+msgstr ""++msgid "Document"+msgstr ""++msgid "Document Control"+msgstr ""++msgid "Document:"+msgstr ""++msgid "Documents"+msgstr ""++msgid "Don't Cancel"+msgstr ""++msgid "Done"+msgstr ""++msgid "Download"+msgstr ""++msgid "Download CSV"+msgstr ""++msgid "Draft"+msgstr ""++msgid "Drag and drop a Purchase Order PDF here, or click to select a file"+msgstr ""++msgid "Drag handle"+msgstr ""++msgid "Drop Shipment"+msgstr ""++msgid "Drop Shipment Statuses"+msgstr ""++msgid "Drop your file here, or click to browse."+msgstr ""++#. placeholder {0}: formatRelativeTime( convertDateStringToIsoString(dueDate) )+msgid "Due {0}"+msgstr ""++msgid "Due Date"+msgstr ""++msgid "Due Date of First Job"+msgstr ""++msgid "Due Date of Last Job"+msgstr ""++msgid "Due Days after {selectedCalculationMethod}"+msgstr ""++msgid "Duplicate"+msgstr ""++msgid "Duplicate Item"+msgstr ""++msgid "Duplicate Price List"+msgstr ""++msgid "Duplicate Pricing Rule"+msgstr ""++msgid "Duplicate To"+msgstr ""++msgid "Duplicate to..."+msgstr ""++msgid "Duration"+msgstr ""++msgid "Edit"+msgstr ""++msgid "Edit Account"+msgstr ""++msgid "Edit API Key"+msgstr ""++msgid "Edit Approval Rule"+msgstr ""++msgid "Edit Assignment"+msgstr ""++msgid "Edit Attribute"+msgstr ""++msgid "Edit Attribute Category"+msgstr ""++msgid "Edit Category"+msgstr ""++msgid "Edit column visibility"+msgstr ""++msgid "Edit Contact"+msgstr ""++msgid "Edit Contractor"+msgstr ""++msgid "Edit Currency"+msgstr ""++msgid "Edit Custom Field"+msgstr ""++msgid "Edit Customer Part"+msgstr ""++msgid "Edit Customer Status"+msgstr ""++msgid "Edit Customer Type"+msgstr ""++msgid "Edit date range"+msgstr ""++msgid "Edit Department"+msgstr ""++msgid "Edit Dispatch"+msgstr ""++msgid "Edit Employee"+msgstr ""++msgid "Edit Employee Type"+msgstr ""++msgid "Edit expiration date"+msgstr ""++msgid "Edit Expiry"+msgstr ""++msgid "Edit Failure Mode"+msgstr ""++msgid "Edit Gauge Calibration Record"+msgstr ""++msgid "Edit Gauge Type"+msgstr ""++msgid "Edit Group"+msgstr ""++msgid "Edit Holiday"+msgstr ""++msgid "Edit Item Group"+msgstr ""++msgid "Edit Kanban"+msgstr ""++msgid "Edit Line"+msgstr ""++msgid "Edit Location"+msgstr ""++msgid "Edit Maintenance Dispatch"+msgstr ""++msgid "Edit Material"+msgstr ""++msgid "Edit Material Dimension"+msgstr ""++msgid "Edit Material Finish"+msgstr ""++msgid "Edit Material Grade"+msgstr ""++msgid "Edit Material Shape"+msgstr ""++msgid "Edit Material Substance"+msgstr ""++msgid "Edit Material Type"+msgstr ""++msgid "Edit Non Conformance Type"+msgstr ""++msgid "Edit Part"+msgstr ""++msgid "Edit Partner"+msgstr ""++msgid "Edit Payment Term"+msgstr ""++msgid "Edit Permissions"+msgstr ""++msgid "Edit Portal"+msgstr ""++msgid "Edit Price Override"+msgstr ""++msgid "Edit Pricing"+msgstr ""++msgid "Edit Pricing Rule"+msgstr ""++msgid "Edit Process"+msgstr ""++msgid "Edit purchase order line type"+msgstr ""++msgid "Edit Question"+msgstr ""++msgid "Edit Reason"+msgstr ""++msgid "Edit Receipt"+msgstr ""++msgid "Edit Revision"+msgstr ""++msgid "Edit rule"+msgstr ""++msgid "Edit Rule"+msgstr ""++msgid "Edit Schedule"+msgstr ""++msgid "Edit Scheduled Maintenance"+msgstr ""++msgid "Edit Sequence"+msgstr ""++msgid "Edit Shift"+msgstr ""++msgid "Edit Shipment"+msgstr ""++msgid "Edit Shipping"+msgstr ""++msgid "Edit Shipping Method"+msgstr ""++msgid "Edit Size"+msgstr ""++msgid "Edit Step"+msgstr ""++msgid "Edit Stock Transfer"+msgstr ""++msgid "Edit Storage Type"+msgstr ""++msgid "Edit Storage Unit"+msgstr ""++msgid "Edit Substance"+msgstr ""++msgid "Edit Supplier"+msgstr ""++msgid "Edit Supplier Part"+msgstr ""++msgid "Edit supplier process"+msgstr ""++msgid "Edit Supplier Type"+msgstr ""++msgid "Edit Timecard"+msgstr ""++msgid "Edit Tool"+msgstr ""++msgid "Edit Training"+msgstr ""++msgid "Edit Transfer"+msgstr ""++msgid "Edit Transfer Line"+msgstr ""++msgid "Edit Unit of Measure"+msgstr ""++msgid "Edit View"+msgstr ""++msgid "Edit Webhook"+msgstr ""++msgid "Edit Work Center"+msgstr ""++msgid "Email"+msgstr ""++msgid "Email Address"+msgstr ""++msgid "Email notifications not configured"+msgstr ""++msgid "Emails"+msgstr ""++msgid "Emoji"+msgstr ""++msgid "Employee"+msgstr ""++msgid "Employee Accounts"+msgstr ""++msgid "Employee Type"+msgstr ""++msgid "Employee Types"+msgstr ""++msgid "Employees"+msgstr ""++msgid "Enable audit logging in settings to start tracking changes to your data."+msgstr ""++msgid "Enable digital quotes for your company. This will allow you to send digital quotes to your customers, and allow them to accept them online."+msgstr ""++msgid "Enable full accrual accounting with journal entries, financial reports, and general ledger posting."+msgstr ""++msgid "Enable in Settings"+msgstr ""++msgid "Enable notifications when an RFQ is marked as ready for quote."+msgstr ""++msgid "Enable shared workstation mode for MES terminals. Operators identify themselves via PIN before performing work."+msgstr ""++msgid "Enable this rule to automatically require approval for matching documents"+msgstr ""++msgid "Enable timecard tracking for work shifts."+msgstr ""++msgid "Enable to allow shared workstation mode."+msgstr ""++msgid "Enable to automatically post transactions to the general ledger."+msgstr ""++msgid "Enable to generate IDs and descriptions for raw materials."+msgstr ""++msgid "Enable to include work instructions on job traveler PDFs."+msgstr ""++msgid "Enable to show part thumbnails on purchase order PDFs."+msgstr ""++msgid "Enable to show part thumbnails on sales PDFs."+msgstr ""++msgid "Enable to start tracking changes to your data."+msgstr ""++msgid "Enable to start tracking work shifts."+msgstr ""++msgid "Enable to use metric units for material dimensions."+msgstr ""++msgid "Enabled"+msgstr ""++msgid "End Date"+msgstr ""++msgid "End Time"+msgstr ""++msgid "Enforce constraints on receipts, shipments, transfers and job operations for this item."+msgstr ""++msgid "Enforce per-item validation across receipts, shipments, transfers and adjustments."+msgstr ""++msgid "Enforce per-item validation and guidelines across receipts, shipments, transfers, and adjustments."+msgstr ""++msgid "Engineering Contact"+msgstr ""++msgid "Enter a batch number before setting the expiration date"+msgstr ""++msgid "Enter or scan serial number"+msgstr ""++msgid "Enter PO number"+msgstr ""++msgid "Entered At Receipt"+msgstr ""++msgid "Entities"+msgstr ""++msgid "Entities to move"+msgstr ""++msgid "Entities to split off"+msgstr ""++msgid "Entity"+msgstr ""++msgid "Entity is {status}"+msgstr ""++msgid "EORI"+msgstr ""++msgid "ERP, MES, QMS"+msgstr ""++msgid "Error"+msgstr ""++msgid "Error deleting file"+msgstr ""++msgid "Error downloading file"+msgstr ""++msgid "Error fetching customer data"+msgstr ""++msgid "Error fetching supplier data"+msgstr ""++msgid "Error loading assigned dispatches"+msgstr ""++msgid "Error loading assigned documents"+msgstr ""++msgid "Error loading assigned issues"+msgstr ""++msgid "Error loading job tree."+msgstr ""++msgid "Error loading make method"+msgstr ""++msgid "Error moving file"+msgstr ""++msgid "Error removing model from {sourceDocument}"+msgstr ""++msgid "Error removing model from item"+msgstr ""++msgid "Error removing model from job"+msgstr ""++msgid "Error removing model from quote line"+msgstr ""++msgid "Error removing model from RFQ line"+msgstr ""++msgid "Error removing model from sales invoice line"+msgstr ""++msgid "Error removing model from sales order line"+msgstr ""++msgid "Error validating serial number"+msgstr ""++msgid "Errors"+msgstr ""++msgid "Escalation"+msgstr ""++msgid "Est. Duration"+msgstr ""++msgid "Estimated Duration"+msgstr ""++msgid "Estimated Duration (minutes)"+msgstr ""++msgid "Estimated Scrap Quantity"+msgstr ""++msgid "Estimates vs Actual"+msgstr ""++msgid "Estimates vs Actuals"+msgstr ""++msgid "Estimator"+msgstr ""++msgid "Event Type"+msgstr ""++msgid "Events"+msgstr ""++msgid "Every condition must match"+msgstr ""++msgid "Everything from Starter"+msgstr ""++msgid "Exchange Rate"+msgstr ""++msgid "Exchange Rates"+msgstr ""++msgid "Expand"+msgstr ""++#. placeholder {0}: item.label+msgid "Expand {0}"+msgstr ""++msgid "Expand all"+msgstr ""++msgid "Expand Costs"+msgstr ""++msgid "Expand Labor"+msgstr ""++msgid "Expand Machine"+msgstr ""++msgid "Expand Setup"+msgstr ""++msgid "Expand subtree"+msgstr ""++msgid "Expected Receipt"+msgstr ""++msgid "Expected Receipt Date"+msgstr ""++msgid "Expiration Date"+msgstr ""++msgid "Expiration Date (applies to all serials on this line)"+msgstr ""++msgid "Expired"+msgstr ""++msgid "Expired batch"+msgstr ""++msgid "Expired Batches"+msgstr ""++msgid "Expires"+msgstr ""++msgid "Expires At (optional)"+msgstr ""++msgid "Expiry"+msgstr ""++msgid "Expiry begins when the selected process completes."+msgstr ""++msgid "Expiry begins when the selected process starts."+msgstr ""++msgid "Expiry trace"+msgstr ""++msgid "Export"+msgstr ""++msgid "Export CSV"+msgstr ""++msgid "Export Lines to CSV"+msgstr ""++msgid "Extended Price"+msgstr ""++msgid "External"+msgstr ""++msgid "External Notes"+msgstr ""++msgid "External Ref."+msgstr ""++msgid "External Reference"+msgstr ""++msgid "Fail"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create consumable: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create customer portal: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create customer status: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create customer type: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create customer: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create department: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create failure mode: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create gauge type: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create item group: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create location: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create maintenance schedule: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create material dimension: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create material finish: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create material form: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create material grade: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create material substance: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create material type: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create material: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create no quote reason: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create part: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create payment term: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create process: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create shipping method: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create stock transfer line: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create storage type: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create supplier: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create tool: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create webhook: {0}"+msgstr ""++#. placeholder {0}: fetcher.data.error.message+msgid "Failed to create work center: {0}"+msgstr ""++msgid "Failed to delete file from old location"+msgstr ""++msgid "Failed to download file for moving"+msgstr ""++msgid "Failed to fetch item costs"+msgstr ""++msgid "Failed to fetch place details"+msgstr ""++msgid "Failed to fetch risks"+msgstr ""++msgid "Failed to fetch suggestions"+msgstr ""++msgid "Failed to initialize Carbon client"+msgstr ""++msgid "Failed to insert quote line"+msgstr ""++msgid "Failed to insert supplier quote line"+msgstr ""++msgid "Failed to load configuration parameters"+msgstr ""++msgid "Failed to load customer part details"+msgstr ""++msgid "Failed to load data"+msgstr ""++msgid "Failed to load inbound inspections"+msgstr ""++msgid "Failed to load item data"+msgstr ""++msgid "Failed to load item details"+msgstr ""++msgid "Failed to load job operations"+msgstr ""++msgid "Failed to load jobs"+msgstr ""++msgid "Failed to load purchase order lines"+msgstr ""++msgid "Failed to load purchase orders"+msgstr ""++msgid "Failed to load receipt lines"+msgstr ""++msgid "Failed to load receipts"+msgstr ""++msgid "Failed to load sales order lines"+msgstr ""++msgid "Failed to load sales orders"+msgstr ""++msgid "Failed to load shipment lines"+msgstr ""++msgid "Failed to load shipments"+msgstr ""++msgid "Failed to load supplier part details"+msgstr ""++msgid "Failed to load tracked entities"+msgstr ""++msgid "Failed to remove image: {errorMessage}"+msgstr ""++msgid "Failed to remove model thumbnail"+msgstr ""++msgid "Failed to remove purchase order"+msgstr ""++msgid "Failed to remove thumbnail"+msgstr ""++msgid "Failed to resize image"+msgstr ""++msgid "Failed to resize image: {errorMessage}"+msgstr ""++msgid "Failed to retrieve CSV column data."+msgstr ""++msgid "Failed to save configuration rule"+msgstr ""++msgid "Failed to update batch property"+msgstr ""++msgid "Failed to update category markups"+msgstr ""++msgid "Failed to update configuration parameter"+msgstr ""++msgid "Failed to update item cost"+msgstr ""++msgid "Failed to update opportunity with purchase order"+msgstr ""++msgid "Failed to update quote line"+msgstr ""++msgid "Failed to update supplier quote line"+msgstr ""++msgid "Failed to update thumbnail path"+msgstr ""++msgid "Failed to upload CSV file."+msgstr ""++msgid "Failed to upload file"+msgstr ""++msgid "Failed to upload file to new location"+msgstr ""++#. placeholder {0}: file.name+#. placeholder {0}: fileUpload.name+msgid "Failed to upload file: {0}"+msgstr ""++msgid "Failed to upload image"+msgstr ""++msgid "Failed to upload logo: {errorMessage}"+msgstr ""++msgid "Failed to upload model"+msgstr ""++msgid "Failed to upload thumbnail"+msgstr ""++msgid "Failure Mode"+msgstr ""++msgid "Failure Modes"+msgstr ""++msgid "Favorite"+msgstr ""++msgid "Fax"+msgstr ""++msgid "Fax Number"+msgstr ""++msgid "Feedback"+msgstr ""++msgid "Fees"+msgstr ""++msgid "Fetch"+msgstr ""++msgid "Field"+msgstr ""++msgid "Field Mapping"+msgstr ""++msgid "Fields"+msgstr ""++msgid "File deleted successfully"+msgstr ""++msgid "File Extension"+msgstr ""++msgid "File is already in the selected bucket"+msgstr ""++#. placeholder {0}: ( logo.size / 1024 / 1024 ).toFixed(2)+msgid "File size exceeds {maxSizeMB}MB limit. Current size: {0}MB"+msgstr ""++msgid "File size exceeds 10MB limit"+msgstr ""++#. placeholder {0}: SIZE_LIMIT.format()+msgid "File size too big (max. {0})"+msgstr ""++msgid "File type not supported"+msgstr ""++msgid "File type not supported. Please use JPG, PNG, WebP, or GIF."+msgstr ""++msgid "Files"+msgstr ""++msgid "Filter"+msgstr ""++msgid "Filtering"+msgstr ""++msgid "Finalize"+msgstr ""++msgid "Finish"+msgstr ""++msgid "Finish To"+msgstr ""++msgid "Finishes"+msgstr ""++msgid "First Name"+msgstr ""++msgid "First Operation"+msgstr ""++msgid "Fiscal Year"+msgstr ""++msgid "Fiscal Year Settings"+msgstr ""++msgid "Fiscal Years"+msgstr ""++msgid "Fixed"+msgstr ""++msgid "Fixed Reorder"+msgstr ""++msgid "Fixed Shelf Life"+msgstr ""++msgid "For growing businesses that need support"+msgstr ""++msgid "For US companies handling ITAR data"+msgstr ""++msgid "Forgot to Clock Out?"+msgstr ""++msgid "Format"+msgstr ""++msgid "Frequencies"+msgstr ""++msgid "Frequency"+msgstr ""++msgid "Friday"+msgstr ""++msgid "From Location"+msgstr ""++msgid "From Storage Unit"+msgstr ""++msgid "Fully trained for"+msgstr ""++msgid "Gauge"+msgstr ""++msgid "Gauge Calibration Notifications"+msgstr ""++msgid "Gauge ID"+msgstr ""++msgid "Gauge not found"+msgstr ""++msgid "Gauge Type"+msgstr ""++msgid "Gauge Types"+msgstr ""++msgid "Gauges"+msgstr ""++msgid "General Ledger"+msgstr ""++msgid "Generate a new 4-digit PIN. Share it with the operator so they can pin in at MES terminals."+msgstr ""++msgid "Generate material IDs and descriptions based on the properties of the material."+msgstr ""++msgid "Generate new PIN"+msgstr ""++msgid "Generated IDs are disabled"+msgstr ""++msgid "Generated IDs are enabled"+msgstr ""++msgid "Get Method"+msgstr ""++msgid "GL Account"+msgstr ""++#. placeholder {0}: user.firstName+msgid "Good afternoon, {0}"+msgstr ""++#. placeholder {0}: user.firstName+msgid "Good evening, {0}"+msgstr ""++#. placeholder {0}: user.firstName+msgid "Good morning, {0}"+msgstr ""++msgid "Google Places API key not configured"+msgstr ""++msgid "Grade"+msgstr ""++msgid "Grades"+msgstr ""++msgid "Group"+msgstr ""++msgid "Group Members"+msgstr ""++msgid "Group Name"+msgstr ""++msgid "Groups"+msgstr ""++msgid "Help"+msgstr ""++msgid "Hide, pin and reorder columns"+msgstr ""++msgid "Higher priority wins ties and applies first for markups"+msgstr ""++msgid "History"+msgstr ""++msgid "Holiday"+msgstr ""++msgid "Holiday Name"+msgstr ""++msgid "Holidays"+msgstr ""++msgid "Home Phone"+msgstr ""++msgid "Hours per Week"+msgstr ""++msgid "Hours/100 Pieces"+msgstr ""++msgid "Hours/1000 Pieces"+msgstr ""++msgid "Hours/Piece"+msgstr ""++msgid "How the resolved price was calculated."+msgstr ""++msgid "Humidity"+msgstr ""++msgid "I'm Still Working"+msgstr ""++msgid "ID"+msgstr ""++msgid "Ideas, suggestions or problems with this page?"+msgstr ""++msgid "Ideas, suggestions or problems?"+msgstr ""++msgid "IDs and descriptions are generated for raw materials."+msgstr ""++msgid "If items already exist"+msgstr ""++msgid "If you wish to change the part numbers, please click Cancel and manually assign the parts for each line item before converting."+msgstr ""++msgid "Implementation Support"+msgstr ""++msgid "Import {label} CSV"+msgstr ""++msgid "In order to convert this RFQ to a quote, all lines must have an internal part number."+msgstr ""++msgid "In order to convert this RFQ to a quote, it must be associated with a customer."+msgstr ""++msgid "In order to convert this RFQ to a quote, it must have a customer."+msgstr ""++msgid "In order to send this RFQ to suppliers, you must first add suppliers to the RFQ."+msgstr ""++msgid "In Process Only"+msgstr ""++msgid "In Progress"+msgstr ""++msgid "in selected period"+msgstr ""++msgid "Inactive"+msgstr ""++msgid "Inactive actions will not appear in selection lists"+msgstr ""++msgid "Inbound Inspection"+msgstr ""++msgid "Inbound Inspections"+msgstr ""++msgid "Inbound Inspections: Require Different Inspector"+msgstr ""++msgid "Inbox"+msgstr ""++msgid "Include extra parts in shipment"+msgstr ""++msgid "Include Inactive"+msgstr ""++msgid "Includes tax and shipping costs"+msgstr ""++msgid "Income Statement"+msgstr ""++msgid "Income/Balance"+msgstr ""++msgid "Incoming"+msgstr ""++msgid "Incoterm"+msgstr ""++msgid "Incoterm Location"+msgstr ""++msgid "Indirect"+msgstr ""++msgid "Infrastructure"+msgstr ""++msgid "Inherit From Materials"+msgstr ""++msgid "Insert rows"+msgstr ""++msgid "Insert token"+msgstr ""++msgid "Inspect"+msgstr ""++msgid "Inspect Item"+msgstr ""++msgid "Inspect Next Item"+msgstr ""++msgid "Inspection"+msgstr ""++msgid "Inspection Level"+msgstr ""++msgid "Inspection Status"+msgstr ""++msgid "Inspections"+msgstr ""++msgid "Inspector"+msgstr ""++msgid "Install"+msgstr ""++msgid "Installed"+msgstr ""++msgid "Instructions"+msgstr ""++msgid "Instructions are inherited from the procedure."+msgstr ""++msgid "Integration not found"+msgstr ""++msgid "Integrations"+msgstr ""++msgid "Intercompany"+msgstr ""++msgid "Internal"+msgstr ""++msgid "Internal Notes"+msgstr ""++msgid "Invalid Invite"+msgstr ""++msgid "Inventory"+msgstr ""++msgid "Inventory Adjustment"+msgstr ""++msgid "Inventory Job Notifications"+msgstr ""++msgid "Inventory Qty"+msgstr ""++msgid "Inventory Tracking"+msgstr ""++msgid "Inventory Unit of Measure"+msgstr ""++msgid "Invite"+msgstr ""++msgid "Invoice"+msgstr ""++msgid "Invoice Contact"+msgstr ""++msgid "Invoice Customer"+msgstr ""++msgid "Invoice Customer Contact"+msgstr ""++msgid "Invoice Customer Location"+msgstr ""++msgid "Invoice ID"+msgstr ""++msgid "Invoice Location"+msgstr ""++msgid "Invoice Number"+msgstr ""++msgid "Invoice Supplier"+msgstr ""++msgid "Invoice Supplier Contact"+msgstr ""++msgid "Invoice Supplier Location"+msgstr ""++msgid "Invoice Total"+msgstr ""++msgid "Invoiced"+msgstr ""++msgid "Invoiced Amount:"+msgstr ""++msgid "Invoiced Statuses"+msgstr ""++msgid "Invoices"+msgstr ""++msgid "is"+msgstr ""++msgid "is any of"+msgstr ""++msgid "Issue"+msgstr ""++msgid "Issue description"+msgstr ""++msgid "Issue not found"+msgstr ""++msgid "Issue scoped API keys for programmatic access to your Carbon data."+msgstr ""++msgid "Issue Status"+msgstr ""++msgid "Issue Target"+msgstr ""++msgid "Issue title"+msgstr ""++msgid "Issue Trend"+msgstr ""++msgid "Issue Type"+msgstr ""++msgid "Issue Types"+msgstr ""++msgid "Issue Workflow"+msgstr ""++msgid "Issue Workflows"+msgstr ""++msgid "Issued Date"+msgstr ""++msgid "Issues"+msgstr ""++msgid "item"+msgstr ""++msgid "Item"+msgstr ""++msgid "Item {scannedItem} is not the same as the item {expectedItem}"+msgstr ""++msgid "Item Group"+msgstr ""++msgid "Item Groups"+msgstr ""++msgid "Item ID"+msgstr ""++msgid "Item Master"+msgstr ""++msgid "Item Rules"+msgstr ""++msgid "Item Scope"+msgstr ""++msgid "Item Type"+msgstr ""++msgid "items"+msgstr ""++msgid "Items"+msgstr ""++msgid "Items inside this window get a yellow badge."+msgstr ""++msgid "Job"+msgstr ""++msgid "Job ID"+msgstr ""++msgid "Job Location"+msgstr ""++msgid "Job Materials"+msgstr ""++msgid "Job Operation"+msgstr ""++msgid "Job Operations"+msgstr ""++msgid "Job Traveler"+msgstr ""++msgid "Job traveler PDFs include work instructions."+msgstr ""++msgid "Jobs"+msgstr ""++msgid "Jobs Assigned to Me"+msgstr ""++msgid "Jobs in progress"+msgstr ""++msgid "Jobs Required"+msgstr ""++#. placeholder {0}: company?.name ?? "Company"+msgid "Join {0}"+msgstr ""++msgid "Journal Entries"+msgstr ""++msgid "Kanban"+msgstr ""++msgid "Kanban for {kanbanName}"+msgstr ""++msgid "Kanban Output"+msgstr ""++msgid "Kanbans"+msgstr ""++msgid "Keep Current"+msgstr ""++msgid "Keep existing pricing, only add new items"+msgstr ""++msgid "Key"+msgstr ""++msgid "Kit"+msgstr ""++msgid "Label"+msgstr ""++msgid "Label to complete the current operation for this kanban"+msgstr ""++#. placeholder {0}: row.original.replenishmentSystem === "Make" ? "Job" : "Order"+msgid "Label to create a {0} for this kanban"+msgstr ""++msgid "Label to start the next operation for this kanban"+msgstr ""++msgid "Labels"+msgstr ""++msgid "Labor"+msgstr ""++msgid "Labor Rate"+msgstr ""++msgid "Labor Rate (Hourly)"+msgstr ""++msgid "Labor Time"+msgstr ""++msgid "Labor Unit"+msgstr ""++msgid "Language"+msgstr ""++msgid "Last Calibration"+msgstr ""++msgid "Last Calibration Date"+msgstr ""++msgid "Last Name"+msgstr ""++#. placeholder {0}: formatDateTime(lastSyncedAt)+msgid "Last synced: {0}"+msgstr ""++msgid "Last updated: {formattedDate}"+msgstr ""++msgid "Lead Time"+msgstr ""++msgid "Lead Time (Days)"+msgstr ""++msgid "Lead Time Updates"+msgstr ""++msgid "Lead Time:"+msgstr ""++msgid "Learn more"+msgstr ""++msgid "Leave any related receipts untouched"+msgstr ""++msgid "Leave empty for exact match"+msgstr ""++msgid "Left item"+msgstr ""++msgid "Leftover Parts Detected"+msgstr ""++msgid "Let's build something"+msgstr ""++msgid "Let's set up your new company"+msgstr ""++msgid "Let's setup your account"+msgstr ""++msgid "Letter"+msgstr ""++msgid "Light"+msgstr ""++msgid "Light Mode"+msgstr ""++msgid "Likelihood"+msgstr ""++msgid "Line Item Comparison"+msgstr ""++msgid "Line options"+msgstr ""++msgid "Line Status"+msgstr ""++msgid "Linear Team"+msgstr ""++msgid "Lines need internal part numbers"+msgstr ""++msgid "Lines need prices or lead times"+msgstr ""++msgid "Link"+msgstr ""++msgid "Link Jira Issue"+msgstr ""++msgid "Link Linear Issue"+msgstr ""++#. placeholder {0}: r.linkedSum+#. placeholder {1}: r.quantity+msgid "Linked entity quantity ({0}) does not match row quantity ({1})."+msgstr ""++msgid "List Options"+msgstr ""++msgid "List Parameters"+msgstr ""++msgid "Live reloading"+msgstr ""++msgid "Load Templates"+msgstr ""++msgid "Loader"+msgstr ""++msgid "Loading item details..."+msgstr ""++msgid "Loading..."+msgstr ""++msgid "Location"+msgstr ""++msgid "Location Name"+msgstr ""++msgid "Locations"+msgstr ""++msgid "Lock"+msgstr ""++msgid "Log In"+msgstr ""++msgid "Login or create a new account"+msgstr ""++msgid "Logo removed successfully"+msgstr ""++msgid "Logo uploaded successfully"+msgstr ""++msgid "Logos"+msgstr ""++#. placeholder {0}: auditConfig.retentionDays+msgid "Logs older than {0} days are automatically archived."+msgstr ""++msgid "Long Description"+msgstr ""++msgid "Looks empty here"+msgstr ""++msgid "Lost"+msgstr ""++msgid "Lot"+msgstr ""++msgid "Lot Size"+msgstr ""++msgid "Lot Size:"+msgstr ""++msgid "Machine"+msgstr ""++msgid "Machine Rate"+msgstr ""++msgid "Machine Rate (Hourly)"+msgstr ""++msgid "Machine Time"+msgstr ""++msgid "Machine Unit"+msgstr ""++msgid "Maintenance"+msgstr ""++msgid "Maintenance Dispatch Notifications"+msgstr ""++msgid "Maintenance Dispatches"+msgstr ""++msgid "Maintenance Scheduling"+msgstr ""++msgid "Maintenance Type"+msgstr ""++msgid "Make"+msgstr ""++msgid "Make Active"+msgstr ""++msgid "Make Default"+msgstr ""++msgid "Make Inactive"+msgstr ""++msgid "Make items cannot be invoiced directly. Change method to Pick to continue."+msgstr ""++msgid "Make Method Version"+msgstr ""++#. placeholder {0}: selectedRevision.revision+msgid "Make revision {0} default?"+msgstr ""++#. placeholder {0}: selectedRevision.revision+msgid "Make size {0} default?"+msgstr ""++msgid "Make to Order"+msgstr ""++msgid "Make tracked entities available again"+msgstr ""++msgid "Makes this document active again."+msgstr ""++msgid "Makes this document active and visible."+msgstr ""++msgid "Manage"+msgstr ""++msgid "Manage how shelf life is tracked, computed, and enforced across inventory."+msgstr ""++msgid "Manage Ownership"+msgstr ""++msgid "Manage Subscription"+msgstr ""++msgid "Manage your subscription and billing information"+msgstr ""++msgid "Manager"+msgstr ""++msgid "Manual"+msgstr ""++msgid "Manufacturer"+msgstr ""++msgid "Manufacturing"+msgstr ""++msgid "Mark as Planned"+msgstr ""++msgid "Mark as read"+msgstr ""++msgid "Mark Complete"+msgstr ""++msgid "Mark Dark Mode"+msgstr ""++msgid "Mark Light Mode"+msgstr ""++msgid "Mark lot as partial?"+msgstr ""++msgid "Mark Partial"+msgstr ""++msgid "Mark to delete"+msgstr ""++msgid "Match"+msgstr ""++msgid "Match all"+msgstr ""++msgid "Match any"+msgstr ""++msgid "Match none"+msgstr ""++msgid "matches"+msgstr ""++msgid "Matching Pairs"+msgstr ""++msgid "Material"+msgstr ""++msgid "Material Dimension"+msgstr ""++msgid "Material Dimensions"+msgstr ""++msgid "Material dimensions use metric units."+msgstr ""++msgid "Material Finish"+msgstr ""++msgid "Material Finishes"+msgstr ""++msgid "Material Form"+msgstr ""++msgid "Material Grade"+msgstr ""++msgid "Material Grades"+msgstr ""++msgid "Material ID"+msgstr ""++msgid "Material IDs"+msgstr ""++msgid "Material Shape"+msgstr ""++msgid "Material Shapes"+msgstr ""++msgid "Material Substance"+msgstr ""++msgid "Material Substances"+msgstr ""++msgid "Material Type"+msgstr ""++msgid "Material Types"+msgstr ""++msgid "Materials"+msgstr ""++msgid "Max Qty"+msgstr ""++msgid "Max Quantity"+msgstr ""++msgid "Maximum"+msgstr ""++msgid "Maximum Inventory Quantity"+msgstr ""++msgid "Maximum Inventory:"+msgstr ""++msgid "Maximum Order Quantity"+msgstr ""++msgid "Maximum Order:"+msgstr ""++msgid "MCP Command"+msgstr ""++msgid "Mean Time Between Failures"+msgstr ""++msgid "Mean Time To Repair"+msgstr ""++msgid "Measurement Standard"+msgstr ""++msgid "Members"+msgstr ""++msgid "Message"+msgstr ""++msgid "Method"+msgstr ""++msgid "Method Id"+msgstr ""++msgid "Method Materials"+msgstr ""++msgid "Method Operations"+msgstr ""++msgid "Method Type"+msgstr ""++msgid "Methods"+msgstr ""++msgid "Metric"+msgstr ""++msgid "Metric units are disabled"+msgstr ""++msgid "Metric units are enabled"+msgstr ""++msgid "Min Qty"+msgstr ""++msgid "Minimize"+msgstr ""++msgid "Minimum"+msgstr ""++msgid "Minimum Amount"+msgstr ""++msgid "Minimum Cost"+msgstr ""++msgid "Minimum Order Quantity"+msgstr ""++msgid "Minimum Order:"+msgstr ""++msgid "Minutes/100 Pieces"+msgstr ""++msgid "Minutes/1000 Pieces"+msgstr ""++msgid "Minutes/Piece"+msgstr ""++msgid "Missing Information"+msgstr ""++msgid "Missing Operations"+msgstr ""++msgid "Missing Shipping Costs"+msgstr ""++msgid "Missing Suppliers"+msgstr ""++msgid "Mobile Phone"+msgstr ""++msgid "Model data is missing"+msgstr ""++msgid "Model Number"+msgstr ""++msgid "Model Number:"+msgstr ""++msgid "Model removed from {sourceDocument}"+msgstr ""++msgid "Model removed from item"+msgstr ""++msgid "Model removed from job"+msgstr ""++msgid "Model removed from line"+msgstr ""++msgid "Module"+msgstr ""++msgid "Modules"+msgstr ""++msgid "Monday"+msgstr ""++msgid "More"+msgstr ""++msgid "More actions"+msgstr ""++msgid "More options"+msgstr ""++msgid "Move"+msgstr ""++msgid "Move entities"+msgstr ""++msgid "Move entities…"+msgstr ""++msgid "Move item"+msgstr ""++msgid "Move some of the quantity into a new disposition row so MRB can decide each portion separately (e.g. scrap some, rework some)."+msgstr ""++msgid "Move to"+msgstr ""++msgid "Move to Trash"+msgstr ""++#. placeholder {0}: file.name+#. placeholder {1}: targetBucket === "parts" ? "Parts" : "Opportunity"+msgid "Moved {0} to {1} bucket"+msgstr ""++msgid "MRP runs automatically every 3 hours, but you can run it manually here."+msgstr ""++msgid "Must be in the same location"+msgstr ""++msgid "My Documents"+msgstr ""++msgid "My Saved View"+msgstr ""++msgid "Name"+msgstr ""++msgid "Navigate"+msgstr ""++msgid "NCRs by Type"+msgstr ""++msgid "Negative Adjustment"+msgstr ""++msgid "Negative feedback"+msgstr ""++msgid "Never"+msgstr ""++msgid "New"+msgstr ""++msgid "New Account"+msgstr ""++msgid "New API Key"+msgstr ""++msgid "New Approval Rule"+msgstr ""++msgid "New Assignment"+msgstr ""++msgid "New Attribute"+msgstr ""++msgid "New Attribute Category"+msgstr ""++msgid "New chat"+msgstr ""++msgid "New Consumable"+msgstr ""++msgid "New Contractor"+msgstr ""++msgid "New Custom Field"+msgstr ""++msgid "New Customer"+msgstr ""++msgid "New Customer Part"+msgstr ""++msgid "New Department"+msgstr ""++msgid "New Employee Type"+msgstr ""++msgid "New expiration date"+msgstr ""++msgid "New Failure Mode"+msgstr ""++msgid "New Field"+msgstr ""++msgid "New Gauge Calibration Record"+msgstr ""++msgid "New Gauge Type"+msgstr ""++msgid "New Group"+msgstr ""++msgid "New Holiday"+msgstr ""++msgid "New Invoice"+msgstr ""++msgid "New Item Group"+msgstr ""++msgid "New Kanban"+msgstr ""++msgid "New Line"+msgstr ""++msgid "New Line Item"+msgstr ""++msgid "New Location"+msgstr ""++msgid "New Maintenance Dispatch"+msgstr ""++msgid "New Material"+msgstr ""++msgid "New Material Dimension"+msgstr ""++msgid "New Material Finish"+msgstr ""++msgid "New Material Grade"+msgstr ""++msgid "New Material Shape"+msgstr ""++msgid "New Material Substance"+msgstr ""++msgid "New Material Type"+msgstr ""++msgid "New Non Conformance Type"+msgstr ""++msgid "New Owner"+msgstr ""++msgid "New Part"+msgstr ""++msgid "New Password"+msgstr ""++msgid "New Payment Term"+msgstr ""++msgid "New PIN"+msgstr ""++msgid "New PO"+msgstr ""++msgid "New Price Override"+msgstr ""++msgid "New Pricing Rule"+msgstr ""++msgid "New Process"+msgstr ""++msgid "New Quote"+msgstr ""++msgid "New Quote Line"+msgstr ""++msgid "New Receipt"+msgstr ""++msgid "New record created"+msgstr ""++msgid "New Revision"+msgstr ""++msgid "New RFQ"+msgstr ""++msgid "New rule"+msgstr ""++msgid "New Rule"+msgstr ""++msgid "New Sales Invoice"+msgstr ""++msgid "New Sales Invoice Line"+msgstr ""++msgid "New Sales Order"+msgstr ""++msgid "New Sales Order Line"+msgstr ""++msgid "New Scheduled Maintenance"+msgstr ""++msgid "New Shift"+msgstr ""++msgid "New Shipment"+msgstr ""++msgid "New Shipping Method"+msgstr ""++msgid "New Size"+msgstr ""++msgid "New Storage Type"+msgstr ""++msgid "New Storage Unit"+msgstr ""++msgid "New Supplier"+msgstr ""++msgid "New Supplier Part"+msgstr ""++msgid "New Timecard"+msgstr ""++msgid "New Tool"+msgstr ""++msgid "New Training"+msgstr ""++msgid "New Transfer"+msgstr ""++msgid "New Transfer Line"+msgstr ""++msgid "New Unit of Measure"+msgstr ""++msgid "New Version"+msgstr ""++msgid "New Warehouse Transfer"+msgstr ""++msgid "New Webhook"+msgstr ""++msgid "New Work Center"+msgstr ""++msgid "Next"+msgstr ""++msgid "Next Calibration"+msgstr ""++msgid "Next Calibration Date"+msgstr ""++msgid "Next Date"+msgstr ""++msgid "Next Due"+msgstr ""++msgid "Next Sequence"+msgstr ""++msgid "No"+msgstr ""++#. placeholder {0}: node.name.toLowerCase()+msgid "No {0} found"+msgstr ""++msgid "No abilities added"+msgstr ""++msgid "No Access"+msgstr ""++msgid "No action needed"+msgstr ""++msgid "No active plan"+msgstr ""++msgid "No Active Quotes"+msgstr ""++msgid "No addresses found"+msgstr ""++#. placeholder {0}: auditConfig.retentionDays+msgid "No archived logs yet. Logs older than {0} days will be automatically archived and available for download here."+msgstr ""++msgid "No available filters"+msgstr ""++msgid "No BOM input has a shelf-life policy"+msgstr ""++msgid "No calibration records found"+msgstr ""++msgid "No changes recorded"+msgstr ""++msgid "No chat history"+msgstr ""++msgid "No chats found"+msgstr ""++msgid "No comments yet. Be the first to add a comment."+msgstr ""++msgid "No completed jobs within range"+msgstr ""++msgid "No condition may match"+msgstr ""++msgid "No conversion is required"+msgstr ""++msgid "No cost history found"+msgstr ""++msgid "No Data"+msgstr ""++msgid "No data exists"+msgstr ""++msgid "No days off scheduled"+msgstr ""++msgid "No draft versions available"+msgstr ""++msgid "No due date"+msgstr ""++msgid "No employees assigned yet. Add groups to see status."+msgstr ""++msgid "No employees found"+msgstr ""++msgid "No fields found."+msgstr ""++msgid "No files"+msgstr ""++msgid "No files uploaded"+msgstr ""++msgid "No Gauge Selected"+msgstr ""++msgid "No groups assigned"+msgstr ""++msgid "No image"+msgstr ""++msgid "No issue types configured"+msgstr ""++msgid "No logo uploaded"+msgstr ""++msgid "No matches"+msgstr ""++msgid "No matches for \"{query}\". Try a different search term."+msgstr ""++msgid "No new notifications"+msgstr ""++msgid "No notes"+msgstr ""++msgid "No operators."+msgstr ""++msgid "No option found."+msgstr ""++msgid "No options found."+msgstr ""++msgid "No other employees found. Add employees to enable ownership transfer."+msgstr ""++msgid "No outstanding trainings"+msgstr ""++msgid "No overtime scheduled"+msgstr ""++msgid "No part ID"+msgstr ""++msgid "No parts added yet"+msgstr ""++msgid "No planning data"+msgstr ""++msgid "No pricing for selected quantity"+msgstr ""++msgid "No pricing options found"+msgstr ""++msgid "No Quote"+msgstr ""++msgid "No Quote Reason"+msgstr ""++msgid "No Quote Reasons"+msgstr ""++msgid "No remaining entities to inspect."+msgstr ""++msgid "No results"+msgstr ""++msgid "No results found"+msgstr ""++msgid "No rules assigned"+msgstr ""++msgid "No samples inspected yet."+msgstr ""++msgid "No sorts applied to this view"+msgstr ""++msgid "No time entries for this week"+msgstr ""++msgid "No value needed"+msgstr ""++msgid "No values available"+msgstr ""++msgid "No work center utilization data within range"+msgstr ""++msgid "No work centers exist"+msgstr ""++msgid "Nominal Cost"+msgstr ""++msgid "Non Conformance Type"+msgstr ""++msgid "Non-Inventory"+msgstr ""++msgid "Non-Inventory Tracking"+msgstr ""++msgid "Non-Taxable Add-On Cost"+msgstr ""++msgid "None"+msgstr ""++msgid "Not enough jobs to cover quantity"+msgstr ""++msgid "Not Required"+msgstr ""++msgid "Not set"+msgstr ""++msgid "Not started training for"+msgstr ""++msgid "Note"+msgstr ""++msgid "Notes"+msgstr ""++msgid "Notes (optional)"+msgstr ""++msgid "Nothing in the archive"+msgstr ""++msgid "Notification"+msgstr ""++msgid "Notifications"+msgstr ""++msgid "Now let's set up your company"+msgstr ""++msgid "Number"+msgstr ""++msgid "Number of inventory units per purchase unit"+msgstr ""++msgid "OEE Impact"+msgstr ""++msgid "of"+msgstr ""++msgid "OK"+msgstr ""++msgid "On Hand"+msgstr ""++msgid "On Hold"+msgstr ""++msgid "On Jobs"+msgstr ""++msgid "On Purchase Order"+msgstr ""++msgid "On Sales Order"+msgstr ""++msgid "On Storage Unit"+msgstr ""++msgid "Onshape Status"+msgstr ""++msgid "Oops! The link you're trying to access has expired or is no longer valid."+msgstr ""++msgid "Oops! The link you're trying to access is not valid."+msgstr ""++msgid "Open"+msgstr ""++msgid "Open Actions"+msgstr ""++msgid "Open chat history"+msgstr ""++msgid "Open Date"+msgstr ""++msgid "Open Dispatches"+msgstr ""++msgid "Open Issues"+msgstr ""++msgid "Open menu"+msgstr ""++msgid "Open Purchase Invoices"+msgstr ""++msgid "Open Purchase Orders"+msgstr ""++msgid "Open Quotes"+msgstr ""++msgid "Open Reactive"+msgstr ""++msgid "Open RFQs"+msgstr ""++msgid "Open Sales Orders"+msgstr ""++msgid "Open Scheduled"+msgstr ""++msgid "Open task details"+msgstr ""++msgid "Operation"+msgstr ""++msgid "Operation Order"+msgstr ""++msgid "Operation Type"+msgstr ""++msgid "Operations"+msgstr ""++msgid "Operations Type"+msgstr ""++msgid "Operator"+msgstr ""++msgid "Operator gets a warning. Stock still goes through."+msgstr ""++msgid "Operator must pick a different batch/serial."+msgstr ""++msgid "Operators"+msgstr ""++msgid "Operators can use shared workstations with PIN authentication."+msgstr ""++msgid "Opportunity"+msgstr ""++msgid "Optional"+msgstr ""++msgid "Optional context for this rule"+msgstr ""++msgid "Options"+msgstr ""++msgid "Order"+msgstr ""++msgid "Order Date"+msgstr ""++msgid "Order Multiple"+msgstr ""++msgid "Order Parts"+msgstr ""++msgid "Order Qty"+msgstr ""++msgid "Order Total"+msgstr ""++msgid "Ordered"+msgstr ""++msgid "Ordering"+msgstr ""++msgid "Orders"+msgstr ""++msgid "Orders submitted"+msgstr ""++msgid "Other Type"+msgstr ""++msgid "Outgoing"+msgstr ""++msgid "Output"+msgstr ""++msgid "Output never outlasts its raw materials. Falls back to the fixed duration when no input has an expiry date."+msgstr ""++msgid "Overdue"+msgstr ""++msgid "Overhead Rate"+msgstr ""++msgid "Overhead Rate (Hourly)"+msgstr ""++msgid "Override needs the inventory:update permission and a reason."+msgstr ""++msgid "Override Price"+msgstr ""++msgid "Override price for a single customer"+msgstr ""++msgid "Override price for all customers of a type"+msgstr ""++msgid "Override the expiration on {label}."+msgstr ""++msgid "Overtime"+msgstr ""++msgid "Overwrite Existing"+msgstr ""++msgid "Overwrite Permissions"+msgstr ""++msgid "Overwrite the quote method with the source method"+msgstr ""++msgid "Overwrite the target manufacturing method with the quote method"+msgstr ""++msgid "Packing Slip"+msgstr ""++msgid "Paid Amount:"+msgstr ""++msgid "Paid Date"+msgstr ""++msgid "Parameters"+msgstr ""++msgid "Parameters are inherited from the procedure."+msgstr ""++msgid "Params"+msgstr ""++msgid "Parent Department"+msgstr ""++msgid "Parent Group"+msgstr ""++msgid "Parent Storage Unit"+msgstr ""++msgid "Pareto by Type"+msgstr ""++msgid "Part"+msgstr ""++msgid "Part Details"+msgstr ""++msgid "Part ID"+msgstr ""++msgid "Part is configured for manufacturing"+msgstr ""++msgid "Part thumbnails are shown on purchase order PDFs."+msgstr ""++msgid "Part thumbnails are shown on sales PDFs."+msgstr ""++msgid "Partial"+msgstr ""++msgid "Partner"+msgstr ""++msgid "Partners"+msgstr ""++msgid "Parts"+msgstr ""++msgid "Pass"+msgstr ""++msgid "Path"+msgstr ""++msgid "Payment"+msgstr ""++msgid "Payment Method"+msgstr ""++msgid "Payment Term"+msgstr ""++msgid "Payment Terms"+msgstr ""++msgid "PDF"+msgstr ""++msgid "PDF Watermark"+msgstr ""++msgid "PDFs"+msgstr ""++msgid "Pending"+msgstr ""++msgid "People"+msgstr ""++msgid "Per Unit"+msgstr ""++msgid "Percentage of Lot"+msgstr ""++msgid "Perfect for low-cost evaluation"+msgstr ""++msgid "Period"+msgstr ""++msgid "Permanently Delete"+msgstr ""++msgid "Permissions"+msgstr ""++msgid "Phone"+msgstr ""++msgid "Phone Number"+msgstr ""++msgid "Photo removed successfully"+msgstr ""++msgid "Photo uploaded successfully"+msgstr ""++msgid "Pick"+msgstr ""++msgid "Pick a column to sort by"+msgstr ""++msgid "Pick a customer or customer type to view their pricing."+msgstr ""++msgid "Pick a date or leave blank to clear it."+msgstr ""++msgid "Pick an existing rule from the library or create a new one to start enforcing constraints on this item."+msgstr ""++msgid "Pick List"+msgstr ""++msgid "Pieces/Hour"+msgstr ""++msgid "Pieces/Minute"+msgstr ""++msgid "Pinned"+msgstr ""++msgid "Plan"+msgstr ""++msgid "Plan Type"+msgstr ""++msgid "Planned End"+msgstr ""++msgid "Planned End Time"+msgstr ""++msgid "Planned Start"+msgstr ""++msgid "Planned Start Time"+msgstr ""++msgid "Planning"+msgstr ""++msgid "Please contact your administrator to enable audit logging."+msgstr ""++msgid "Please enter your email address"+msgstr ""++msgid "Please enter your name"+msgstr ""++msgid "Please fill out all required fields"+msgstr ""++msgid "Please save the operation before adding parameters."+msgstr ""++msgid "Please save the operation before adding steps."+msgstr ""++msgid "Please save the operation before adding tools."+msgstr ""++msgid "Please select an item"+msgstr ""++msgid "Please upload a CSV file of your data"+msgstr ""++msgid "PO"+msgstr ""++msgid "PO Number"+msgstr ""++msgid "Policy & Procedure"+msgstr ""++msgid "Portal Link"+msgstr ""++msgid "Portals"+msgstr ""++msgid "Positive Adjustment"+msgstr ""++msgid "Positive feedback"+msgstr ""++msgid "Post"+msgstr ""++msgid "Post Comment"+msgstr ""++msgid "Post Invoice"+msgstr ""++msgid "Post Receipt"+msgstr ""++msgid "Post Shipment"+msgstr ""++msgid "Postal Code"+msgstr ""++msgid "Posted"+msgstr ""++msgid "Posted By"+msgstr ""++msgid "Posting Date"+msgstr ""++msgid "Posting Groups"+msgstr ""++msgid "Potential Data Loss"+msgstr ""++msgid "Pre-filled for a new item when expiry is Fixed Duration."+msgstr ""++msgid "Preferred Supplier"+msgstr ""++msgid "Prefix"+msgstr ""++msgid "Prev"+msgstr ""++msgid "Preview"+msgstr ""++msgid "Preview Quantity"+msgstr ""++msgid "Previous"+msgstr ""++msgid "Previous Date"+msgstr ""++msgid "Price break actions"+msgstr ""++msgid "Price Break History"+msgstr ""++msgid "Price Breaks"+msgstr ""++msgid "Price List"+msgstr ""++msgid "Price Lists"+msgstr ""++msgid "Prices"+msgstr ""++msgid "Pricing"+msgstr ""++msgid "Pricing Rule"+msgstr ""++msgid "Pricing Rules"+msgstr ""++msgid "Pricing Trace"+msgstr ""++msgid "Print Label"+msgstr ""++msgid "Priorities"+msgstr ""++msgid "Priority"+msgstr ""++msgid "Privacy Policy"+msgstr ""++msgid "Private"+msgstr ""++msgid "Procedure"+msgstr ""++msgid "Procedures"+msgstr ""++msgid "Process"+msgstr ""++msgid "Process Name"+msgstr ""++msgid "Process Type"+msgstr ""++msgid "Processes"+msgstr ""++msgid "Product Label Size"+msgstr ""++msgid "Production"+msgstr ""++msgid "Production Event"+msgstr ""++msgid "Production Events"+msgstr ""++msgid "Production Qty"+msgstr ""++msgid "Production Quantities"+msgstr ""++msgid "Production Quantity"+msgstr ""++msgid "Profile"+msgstr ""++msgid "Progress"+msgstr ""++msgid "Project"+msgstr ""++msgid "Projections"+msgstr ""++msgid "Promised Date"+msgstr ""++msgid "Properties"+msgstr ""++msgid "Public"+msgstr ""++msgid "Publish"+msgstr ""++msgid "Published by Carbon"+msgstr ""++msgid "Pull From"+msgstr ""++msgid "Pull from Inventory"+msgstr ""++msgid "Purchase History"+msgstr ""++msgid "Purchase Invoice"+msgstr ""++msgid "Purchase Invoice Amount"+msgstr ""++msgid "Purchase Invoice Line"+msgstr ""++msgid "Purchase Invoices"+msgstr ""++msgid "Purchase Order"+msgstr ""++msgid "Purchase Order Amount"+msgstr ""++msgid "Purchase Order approval rule"+msgstr ""++msgid "Purchase Order ID"+msgstr ""++msgid "Purchase Order Line"+msgstr ""++msgid "Purchase Order Location"+msgstr ""++msgid "Purchase order removed successfully"+msgstr ""++msgid "Purchase Orders"+msgstr ""++msgid "Purchase orders required"+msgstr ""++msgid "Purchase Price Updates"+msgstr ""++msgid "Purchase Qty"+msgstr ""++msgid "Purchase to Order"+msgstr ""++msgid "Purchase Unit of Measure"+msgstr ""++msgid "Purchase Unit:"+msgstr ""++msgid "Purchased"+msgstr ""++msgid "Purchasing"+msgstr ""++msgid "Purchasing Contact"+msgstr ""++msgid "Purchasing Terms & Conditions"+msgstr ""++msgid "Purchasing Unit of Measure"+msgstr ""++msgid "Push record changes to external systems the moment they happen."+msgstr ""++#. placeholder {0}: row.original.replenishmentSystem === "Make" ? "Job" : "Order"+msgid "QR Code to create a {0} for this kanban"+msgstr ""++msgid "QR Code to start the next operation for this kanban"+msgstr ""++msgid "Qty to Order"+msgstr ""++msgid "Qty. Complete"+msgstr ""++msgid "Qty. per Parent"+msgstr ""++msgid "Qty. Reworked"+msgstr ""++msgid "Qty. Scrapped"+msgstr ""++msgid "Quality"+msgstr ""++msgid "Quality Document approval rule"+msgstr ""++msgid "Quality Documents"+msgstr ""++msgid "Quality Type"+msgstr ""++msgid "Quantities"+msgstr ""++msgid "Quantity"+msgstr ""++msgid "Quantity Completed"+msgstr ""++msgid "Quantity is derived from completed serials/batches in MES and cannot be edited."+msgstr ""++msgid "Quantity must be greater than 0"+msgstr ""++msgid "Quantity on Hand"+msgstr ""++msgid "Quantity on Jobs"+msgstr ""++msgid "Quantity on Purchase Order"+msgstr ""++msgid "Quantity on Sales Order"+msgstr ""++msgid "Quantity Per Job"+msgstr ""++msgid "Quantity per Parent"+msgstr ""++msgid "Quantity Type"+msgstr ""++msgid "Question"+msgstr ""++msgid "Quote"+msgstr ""++msgid "Quote Accepted By"+msgstr ""++msgid "Quote Accepted By Email"+msgstr ""++msgid "Quote expired"+msgstr ""++msgid "Quote ID"+msgstr ""++msgid "Quote Line"+msgstr ""++msgid "Quote Location"+msgstr ""++msgid "Quote Markups"+msgstr ""++msgid "Quote Materials"+msgstr ""++msgid "Quote not found"+msgstr ""++msgid "Quote Number"+msgstr ""++msgid "Quoted Date"+msgstr ""++msgid "Quotes"+msgstr ""++msgid "Rate Limit"+msgstr ""++msgid "Reactivate"+msgstr ""++msgid "Read rows"+msgstr ""++msgid "Ready for Quote"+msgstr ""++msgid "Reason"+msgstr ""++msgid "Reason for declining (Optional)"+msgstr ""++msgid "Reasons"+msgstr ""++msgid "Reassign specific tracked entities from this row to another disposition row."+msgstr ""++msgid "Recalculate"+msgstr ""++msgid "Recalculate Unit Cost"+msgstr ""++msgid "Receipt"+msgstr ""++msgid "Receipt ID"+msgstr ""++msgid "Receipt Line"+msgstr ""++msgid "Receipt Lines"+msgstr ""++msgid "Receipt Promised Date"+msgstr ""++msgid "Receipt Requested Date"+msgstr ""++msgid "Receipts"+msgstr ""++msgid "Receive"+msgstr ""++#. placeholder {0}: job.jobId+msgid "Receive {0} to Inventory"+msgstr ""++msgid "Receive to Inventory"+msgstr ""++msgid "Received At"+msgstr ""++msgid "Received By"+msgstr ""++msgid "Received Qty"+msgstr ""++msgid "Receiving Location"+msgstr ""++msgid "Recent"+msgstr ""++msgid "Recently Created"+msgstr ""++msgid "Record"+msgstr ""++msgid "Record deleted"+msgstr ""++msgid "Records"+msgstr ""++msgid "Redirecting to verification page..."+msgstr ""++msgid "Reference"+msgstr ""++msgid "Refresh"+msgstr ""++msgid "Refresh exchange rate"+msgstr ""++msgid "Reject"+msgstr ""++msgid "Reject Lot"+msgstr ""++msgid "Reject Quote"+msgstr ""++msgid "Rejected"+msgstr ""++msgid "Rejected By"+msgstr ""++msgid "Rejected Date"+msgstr ""++msgid "Release"+msgstr ""++msgid "Release Job"+msgstr ""++msgid "Released"+msgstr ""++msgid "Remaining after split stays on the original row."+msgstr ""++msgid "Remember this PIN. You will need it to exit console mode on MES terminals."+msgstr ""++msgid "Remove"+msgstr ""++#. placeholder {0}: item.label+msgid "Remove {0}"+msgstr ""++msgid "Remove attachment"+msgstr ""++msgid "Remove condition"+msgstr ""++msgid "Remove filter"+msgstr ""++msgid "Remove Filters"+msgstr ""++msgid "Remove from Price List"+msgstr ""++msgid "Remove item"+msgstr ""++msgid "Remove negative feedback"+msgstr ""++msgid "Remove order"+msgstr ""++msgid "Remove Order"+msgstr ""++msgid "Remove pair"+msgstr ""++msgid "Remove positive feedback"+msgstr ""++msgid "Remove sort by column"+msgstr ""++msgid "Remove this storage type from all referencing storage units and delete it. This cannot be undone."+msgstr ""++msgid "Remove Transfer"+msgstr ""++msgid "Reopen"+msgstr ""++msgid "Reorder"+msgstr ""++msgid "Reorder Group"+msgstr ""++msgid "Reorder Point"+msgstr ""++msgid "Reorder Point:"+msgstr ""++msgid "Reorder Policy"+msgstr ""++msgid "Reorder Policy:"+msgstr ""++msgid "Reorder Qty."+msgstr ""++msgid "Reorder Quantity"+msgstr ""++msgid "Reorder Quantity:"+msgstr ""++msgid "Reordering Policy"+msgstr ""++msgid "Replace existing pricing with source values"+msgstr ""++msgid "Replenishment"+msgstr ""++msgid "Replenishment System"+msgstr ""++msgid "Report"+msgstr ""++msgid "Reports"+msgstr ""++msgid "Request Approval"+msgstr ""++msgid "Requested Date"+msgstr ""++msgid "Require approval before suppliers can be set to Active"+msgstr ""++msgid "Require approval for purchase orders based on amount thresholds"+msgstr ""++msgid "Require approval for quality documents in your workflow"+msgstr ""++msgid "Required"+msgstr ""++msgid "Required Action"+msgstr ""++msgid "Required Actions"+msgstr ""++msgid "Required Date"+msgstr ""++msgid "Requires Action"+msgstr ""++msgid "Requires Adjustment"+msgstr ""++msgid "Requires Inspection"+msgstr ""++msgid "Requires Repair"+msgstr ""++msgid "Reserved"+msgstr ""++msgid "Reset"+msgstr ""++msgid "Reset PIN"+msgstr ""++#. placeholder {0}: operator.firstName+#. placeholder {1}: operator.lastName+msgid "Reset PIN for {0} {1}"+msgstr ""++msgid "Resolve these before completing the NCR: every row must have a non-Pending disposition, and its linked entity quantities must match the row quantity."+msgstr ""++msgid "Resolved Price"+msgstr ""++msgid "Resources"+msgstr ""++msgid "Restore from Trash"+msgstr ""++msgid "Restore tracked entities to available"+msgstr ""++msgid "Result"+msgstr ""++msgid "Results"+msgstr ""++msgid "Results per page"+msgstr ""++msgid "Retry"+msgstr ""++msgid "Retry response"+msgstr ""++msgid "Return Home"+msgstr ""++msgid "Rev {revision}"+msgstr ""++msgid "Reverse all inventory adjustments"+msgstr ""++msgid "Reverse all journal and cost ledger entries"+msgstr ""++msgid "Reverse any item ledger entries from this invoice"+msgstr ""++msgid "Reverse the related journal entries"+msgstr ""++msgid "Revision"+msgstr ""++#. placeholder {0}: revision.revision+msgid "Revision {0}"+msgstr ""++msgid "Revoke"+msgstr ""++msgid "Revoke Invite"+msgstr ""++msgid "Revoke Invites"+msgstr ""++msgid "RFQ"+msgstr ""++msgid "RFQ Date"+msgstr ""++msgid "RFQ has no customer"+msgstr ""++msgid "RFQ has no suppliers"+msgstr ""++msgid "RFQ ID"+msgstr ""++msgid "RFQ Location"+msgstr ""++msgid "RFQ Number"+msgstr ""++msgid "RFQs"+msgstr ""++msgid "Right item"+msgstr ""++msgid "Risk"+msgstr ""++msgid "Risks"+msgstr ""++msgid "Role"+msgstr ""++msgid "Role:"+msgstr ""++msgid "rows"+msgstr ""++msgid "Rule"+msgstr ""++msgid "Rule applies to every customer."+msgstr ""++msgid "Rule applies to every item."+msgstr ""++msgid "Rule Type"+msgstr ""++msgid "Rule Violation"+msgstr ""++msgid "Rules"+msgstr ""++msgid "Run Test"+msgstr ""++msgid "Running Total"+msgstr ""++msgid "Safety Stock"+msgstr ""++msgid "Safety Stock:"+msgstr ""++msgid "Sale Price"+msgstr ""++msgid "Sales"+msgstr ""++msgid "Sales Contact"+msgstr ""++msgid "Sales Funnel"+msgstr ""++msgid "Sales Invoice"+msgstr ""++msgid "Sales Invoice Line"+msgstr ""++msgid "Sales Invoices"+msgstr ""++msgid "Sales Job Notifications"+msgstr ""++msgid "Sales Order"+msgstr ""++msgid "Sales Order ID"+msgstr ""++msgid "Sales Order Line"+msgstr ""++msgid "Sales Order Location"+msgstr ""++msgid "Sales Order Number"+msgstr ""++msgid "Sales Orders"+msgstr ""++msgid "Sales Person"+msgstr ""++msgid "Sales Revenue"+msgstr ""++msgid "Sales Terms & Conditions"+msgstr ""++msgid "Sample"+msgstr ""++msgid "Sample Size"+msgstr ""++msgid "Sampling Plan"+msgstr ""++msgid "Sampling Standard"+msgstr ""++msgid "Saturday"+msgstr ""++msgid "Save"+msgstr ""++msgid "Save & Close"+msgstr ""++msgid "Save and Overwrite"+msgstr ""++msgid "Save Method"+msgstr ""++msgid "Save View"+msgstr ""++msgid "Scan"+msgstr ""++msgid "Scan a label or search by ID, serial number, or batch number."+msgstr ""++msgid "Scan or enter tracked entity ID, serial, or batch"+msgstr ""++msgid "Scan or search..."+msgstr ""++msgid "Scan or select a tracked entity from this lot and record the inspection result."+msgstr ""++msgid "Scan the tracking ID for this line"+msgstr ""++msgid "SCAR"+msgstr ""++msgid "Schedule"+msgstr ""++msgid "Schedule Name"+msgstr ""++msgid "Scheduled Maintenance"+msgstr ""++msgid "Scheduled Maintenances"+msgstr ""++msgid "Schedules"+msgstr ""++msgid "Scope"+msgstr ""++msgid "Scopes"+msgstr ""++msgid "Scrap Percent"+msgstr ""++msgid "Scrap Qty"+msgstr ""++msgid "Scrap Quantity"+msgstr ""++msgid "Scrap Quantity Per Job"+msgstr ""++msgid "Scrap Reason"+msgstr ""++msgid "Scrap Reasons"+msgstr ""++msgid "Search"+msgstr ""++msgid "Search across your workspace..."+msgstr ""++msgid "Search by Jira issue title..."+msgstr ""++msgid "Search by linear issue title..."+msgstr ""++msgid "Search customers and types..."+msgstr ""++msgid "Search customers or types..."+msgstr ""++msgid "Search employees..."+msgstr ""++msgid "Search fields..."+msgstr ""++msgid "Search for existing or create a new one"+msgstr ""++msgid "Search history"+msgstr ""++msgid "Search Job"+msgstr ""++msgid "Search operators..."+msgstr ""++msgid "Search processes..."+msgstr ""++msgid "Search related items..."+msgstr ""++msgid "Search suppliers..."+msgstr ""++#. js-lingui-explicit-id+msgid "Search the web"+msgstr ""++msgid "Search..."+msgstr ""++msgid "Seconds/Piece"+msgstr ""++msgid "Select"+msgstr ""++msgid "Select a assignee"+msgstr ""++msgid "Select a default approver"+msgstr ""++msgid "Select a new owner"+msgstr ""++msgid "Select a plan"+msgstr ""++#. placeholder {0}: plans[0].stripeTrialPeriodDays+msgid "Select a plan to get started. You won't be charged for the first {0} days. Switch or cancel anytime."+msgstr ""++msgid "Select a project"+msgstr ""++msgid "Select a quote"+msgstr ""++msgid "Select a quote line"+msgstr ""++msgid "Select a reason for why the quote was not created."+msgstr ""++msgid "Select a team"+msgstr ""++msgid "Select an assignee"+msgstr ""++msgid "Select an issue type"+msgstr ""++msgid "Select an item and specify the quantity to issue"+msgstr ""++msgid "Select an item first"+msgstr ""++msgid "Select an item to configure"+msgstr ""++msgid "Select an option"+msgstr ""++msgid "Select Contact"+msgstr ""++msgid "Select Customer Status"+msgstr ""++msgid "Select Customer Type"+msgstr ""++msgid "Select customer types"+msgstr ""++msgid "Select customers"+msgstr ""++msgid "Select date range to filter net change and balance at date"+msgstr ""++msgid "Select Employee"+msgstr ""++msgid "Select Employee Type"+msgstr ""++msgid "Select field"+msgstr ""++msgid "Select Gauge"+msgstr ""++msgid "Select groups or individuals"+msgstr ""++msgid "Select Item Type"+msgstr ""++msgid "Select items"+msgstr ""++msgid "Select Quantities"+msgstr ""++msgid "Select Row"+msgstr ""++msgid "Select scope"+msgstr ""++msgid "Select Supplier Status"+msgstr ""++msgid "Select Supplier Type"+msgstr ""++msgid "Select surfaces"+msgstr ""++msgid "Select the groups that should complete this training"+msgstr ""++msgid "Select value"+msgstr ""++msgid "Select values"+msgstr ""++msgid "Selected"+msgstr ""++msgid "Selected Operation"+msgstr ""++#. placeholder {0}: target.maxQuantity - selectedSum+msgid "Selected: {selectedSum} / remaining after split: {0}"+msgstr ""++msgid "Self Managed"+msgstr ""++msgid "Self-Onboarding with Carbon Academy"+msgstr ""++msgid "Send"+msgstr ""++msgid "Send Invite"+msgstr ""++msgid "Send Invites"+msgstr ""++msgid "Send RFQ to Suppliers"+msgstr ""++msgid "Send Via"+msgstr ""++msgid "Sends this document for approval before it can go active."+msgstr ""++msgid "Sequences"+msgstr ""++msgid "Serial"+msgstr ""++msgid "Serial / Batch"+msgstr ""++msgid "Serial items require a sales order"+msgstr ""++msgid "Serial Number"+msgstr ""++msgid "Serial number not found"+msgstr ""++msgid "Serial Number:"+msgstr ""++msgid "Serial or Batch Tracking Required"+msgstr ""++msgid "Serial Tracking"+msgstr ""++msgid "Serial/Batch #"+msgstr ""++msgid "Set Clock Out"+msgstr ""++msgid "Set clock-out time"+msgstr ""++msgid "Set Console PIN"+msgstr ""++msgid "Set default markup percentages for each cost category on new quote lines"+msgstr ""++msgid "Set due date"+msgstr ""++msgid "Set Pricing"+msgstr ""++msgid "Set Quantity"+msgstr ""++#. placeholder {0}: selectedVersion.version+msgid "Set Version {0} as Active Version?"+msgstr ""++msgid "Set your default location in profile settings to pick a storage unit."+msgstr ""++msgid "Settings"+msgstr ""++msgid "Setup"+msgstr ""++msgid "Setup instructions"+msgstr ""++msgid "Setup Time"+msgstr ""++msgid "Setup Unit"+msgstr ""++msgid "Severities"+msgstr ""++msgid "Severity"+msgstr ""++msgid "Shape"+msgstr ""++msgid "Shapes"+msgstr ""++msgid "Share"+msgstr ""++msgid "Share Link"+msgstr ""++msgid "Share Quote"+msgstr ""++msgid "Shelf life"+msgstr ""++msgid "Shelf Life (Days)"+msgstr ""++msgid "Shelf Life Start Process"+msgstr ""++msgid "Shelf-Life"+msgstr ""++msgid "Shift"+msgstr ""++msgid "Shift Name"+msgstr ""++msgid "Shifts"+msgstr ""++msgid "Ship"+msgstr ""++msgid "Ship some, stock some"+msgstr ""++msgid "Ship to Customer"+msgstr ""++msgid "Shipment"+msgstr ""++msgid "Shipment Date"+msgstr ""++msgid "Shipment ID"+msgstr ""++msgid "Shipment Line"+msgstr ""++msgid "Shipment Lines"+msgstr ""++msgid "Shipment Location"+msgstr ""++msgid "Shipments"+msgstr ""++msgid "Shipped Qty"+msgstr ""++msgid "Shipping"+msgstr ""++msgid "Shipping Contact"+msgstr ""++msgid "Shipping Cost"+msgstr ""++msgid "Shipping Customer"+msgstr ""++msgid "Shipping Location"+msgstr ""++msgid "Shipping Method"+msgstr ""++msgid "Shipping Methods"+msgstr ""++msgid "Shipping Notes"+msgstr ""++msgid "Shipping Supplier"+msgstr ""++msgid "Shipping:"+msgstr ""++msgid "Shop Floor"+msgstr ""++msgid "Short Description"+msgstr ""++msgid "Shortcuts"+msgstr ""++msgid "Show Durations"+msgstr ""++msgid "Show parent items"+msgstr ""++msgid "Show part thumbnails on purchase orders."+msgstr ""++msgid "Show part thumbnails on quotes, sales orders, sales invoices, and shipments."+msgstr ""++msgid "Show sync options"+msgstr ""++msgid "Shown as a faint background behind every page of generated PDFs"+msgstr ""++msgid "Shown to the user when this rule fails."+msgstr ""++msgid "Sign in with Email"+msgstr ""++msgid "Sign in with Google"+msgstr ""++msgid "Sign in with Outlook"+msgstr ""++msgid "Sign Out"+msgstr ""++msgid "Signed in as {name}"+msgstr ""++msgid "Size"+msgstr ""++msgid "Sizes"+msgstr ""++msgid "Skip Existing"+msgstr ""++msgid "Skip Holidays"+msgstr ""++msgid "Skip raw-material dates set at receipt. Only inputs with their own shelf-life policy count."+msgstr ""++msgid "Skip scheduled maintenance on company holidays"+msgstr ""++msgid "Skipped"+msgstr ""++msgid "Something went wrong. Please try again."+msgstr ""++msgid "Soonest expiry across every material sets the finished good."+msgstr ""++msgid "Sort"+msgstr ""++msgid "Sort Ascending"+msgstr ""++msgid "Sort by"+msgstr ""++msgid "Sort Descending"+msgstr ""++msgid "Source"+msgstr ""++msgid "Source Analysis"+msgstr ""++msgid "Source Document"+msgstr ""++msgid "Source Document ID"+msgstr ""++msgid "Source Item"+msgstr ""++msgid "Source Method"+msgstr ""++msgid "Source Version"+msgstr ""++msgid "Sources"+msgstr ""++msgid "Sourcing Type"+msgstr ""++msgid "Spare Part Consumption"+msgstr ""++msgid "Spare Part Cost"+msgstr ""++msgid "Specific Customer"+msgstr ""++msgid "Specific Customers"+msgstr ""++msgid "Specific Items"+msgstr ""++msgid "Split"+msgstr ""++msgid "Split line"+msgstr ""++msgid "Split off quantity"+msgstr ""++msgid "Split receipt line"+msgstr ""++msgid "Split shipment line"+msgstr ""++msgid "Standard"+msgstr ""++msgid "Standard Lead Time"+msgstr ""++msgid "Start"+msgstr ""++#. placeholder {0}: plan.stripeTrialPeriodDays+msgid "Start {0} Day Free Trial"+msgstr ""++msgid "Start adding parts to your stock transfer"+msgstr ""++msgid "Start Date"+msgstr ""++msgid "Start Expiration"+msgstr ""++msgid "Start expiration on process end"+msgstr ""++msgid "Start expiration on process start"+msgstr ""++msgid "Start Learning"+msgstr ""++msgid "Start Now"+msgstr ""++msgid "Start of Fiscal Year"+msgstr ""++msgid "Start of Tax Year"+msgstr ""++msgid "Start Time"+msgstr ""++msgid "Started"+msgstr ""++msgid "State / Province"+msgstr ""++#. placeholder {0}: lotEntities.length+#. placeholder {1}: Math.max(0, lotEntities.length - inspected)+msgid "Statistical acceptance failed, so the entire lot is considered non-conforming (ISO 9001:2015 §8.7). All {0} entities — {passes} sampled pass(es), {fails} failure(s), and {1} un-inspected — will be marked Rejected. An NCR will be opened automatically for MRB disposition."+msgstr ""++msgid "Status"+msgstr ""++msgid "Status Distribution"+msgstr ""++msgid "Statuses"+msgstr ""++msgid "Step"+msgstr ""++msgid "Step Records"+msgstr ""++msgid "Steps"+msgstr ""++msgid "Stock Transfer ID"+msgstr ""++msgid "Stock Transfer Lines"+msgstr ""++msgid "Stock Transfer Notes"+msgstr ""++msgid "Stock Transfer Wizard"+msgstr ""++msgid "Stock Transfers"+msgstr ""++msgid "Storage Type"+msgstr ""++msgid "Storage Types"+msgstr ""++msgid "Storage Unit"+msgstr ""++msgid "Storage Units"+msgstr ""++msgid "Store a fixed number of days on this item. Expiry start date is set on each batch or serial when it's created (or when the trigger process runs, if set)."+msgstr ""++msgid "Store a fixed number of days on this item. Expiry start date is set on each batch or serial when it's received or created (or when the trigger process runs, if set)."+msgstr ""++msgid "Store a fixed number of days on this item. Expiry start date is set on each batch or serial when it's received."+msgstr ""++msgid "Style of kanban output to show in the Kanban table"+msgstr ""++msgid "Sub-assembly expiries only"+msgstr ""++msgid "Sub-Departments"+msgstr ""++msgid "Subassembly"+msgstr ""++msgid "Submit"+msgstr ""++msgid "Submit anonymously"+msgstr ""++msgid "Submit for approval"+msgstr ""++msgid "Submit Inspection"+msgstr ""++msgid "Submitted By"+msgstr ""++msgid "Subscribe to changes"+msgstr ""++msgid "Substance"+msgstr ""++msgid "Substances"+msgstr ""++msgid "Subtotal"+msgstr ""++msgid "Subtotal:"+msgstr ""++msgid "Success"+msgstr ""++msgid "Successfully copied quote"+msgstr ""++msgid "Successfully created a new revision"+msgstr ""++msgid "Suffix"+msgstr ""++msgid "Suggested Actions"+msgstr ""++msgid "Suggestion"+msgstr ""++msgid "Suggestion Notifications"+msgstr ""++msgid "Suggestions"+msgstr ""++msgid "Sunday"+msgstr ""++msgid "Supabase provides a wide range of filters."+msgstr ""++msgid "Supabase provides realtime functionality and broadcasts database changes to authorized users depending on Row Level Security (RLS) policies."+msgstr ""++msgid "Supplier"+msgstr ""++msgid "Supplier Accounts"+msgstr ""++msgid "Supplier added and selected"+msgstr ""++msgid "Supplier Contact"+msgstr ""++msgid "Supplier ID"+msgstr ""++msgid "Supplier Invoice Number"+msgstr ""++msgid "Supplier Location"+msgstr ""++msgid "Supplier Order Number"+msgstr ""++msgid "Supplier Overview"+msgstr ""++msgid "Supplier Part ID"+msgstr ""++msgid "Supplier Part Number"+msgstr ""++msgid "Supplier Parts"+msgstr ""++msgid "Supplier Processes"+msgstr ""++msgid "Supplier Quality"+msgstr ""++msgid "Supplier Quote"+msgstr ""++msgid "Supplier Quote ID"+msgstr ""++msgid "Supplier Quote Notifications"+msgstr ""++msgid "Supplier Quotes"+msgstr ""++msgid "Supplier Ref."+msgstr ""++msgid "Supplier Ref. Number"+msgstr ""++msgid "Supplier Reference"+msgstr ""++msgid "Supplier Status"+msgstr ""++msgid "Supplier Type"+msgstr ""++msgid "Supplier Types"+msgstr ""++msgid "Supplier Unit Price"+msgstr ""++msgid "Supplier updated"+msgstr ""++msgid "Supplier:"+msgstr ""++msgid "Suppliers"+msgstr ""++msgid "Supply"+msgstr ""++msgid "Supply & Demand"+msgstr ""++#. placeholder {0}: supportedModelTypes.join(", ")+msgid "Supports {0} files"+msgstr ""++msgid "Surfaces"+msgstr ""++msgid "Suspected Failure Mode"+msgstr ""++msgid "Switch"+msgstr ""++msgid "Sync"+msgstr ""++msgid "System"+msgstr ""++msgid "Table"+msgstr ""++msgid "Table actions"+msgstr ""++msgid "Tags"+msgstr ""++msgid "Take the shortest remaining shelf life across the materials consumed to make this item. Use when the product's expiry depends on its ingredients."+msgstr ""++msgid "Talk to Sales"+msgstr ""++msgid "Target"+msgstr ""++msgid "Target an item group."+msgstr ""++msgid "Target customers by type."+msgstr ""++msgid "Target disposition row"+msgstr ""++msgid "Target Item"+msgstr ""++msgid "Target Method"+msgstr ""++msgid "Target number of open issues shown as a reference line on the Issue Trend chart."+msgstr ""++msgid "Target one or more customers."+msgstr ""++msgid "Target one or more items."+msgstr ""++msgid "Target Version"+msgstr ""++msgid "Tasks"+msgstr ""++msgid "Tax"+msgstr ""++msgid "Tax & Additional Costs"+msgstr ""++msgid "Tax Amount"+msgstr ""++msgid "Tax ID"+msgstr ""++msgid "Tax Percent"+msgstr ""++msgid "Tax:"+msgstr ""++msgid "Temperature"+msgstr ""++msgid "Terms and Privacy"+msgstr ""++msgid "Terms of Service"+msgstr ""++msgid "Test Value"+msgstr ""++msgid "The amount of days after the calculation method that the cash discount is available"+msgstr ""++msgid "The amount of days after the calculation method that the payment is due"+msgstr ""++msgid "The billing address used on purchase orders and other purchasing documents."+msgstr ""++msgid "The billing address used on quotes, sales orders, invoices, and other sales documents."+msgstr ""++msgid "The date the customer expects to receive the goods"+msgstr ""++msgid "The endpoint that receives a POST request with the updated data when the table is updated"+msgstr ""++msgid "The following assemblies have no operations. Please assign an operation to each before releasing."+msgstr ""++msgid "The following line items are missing prices or lead times:"+msgstr ""++msgid "The lot will still be rejected, but an NCR cannot be auto-created until at least one Issue Type is configured."+msgstr ""++msgid "The new version number of the method"+msgstr ""++msgid "The number of hours per week the contractor is available to work."+msgstr ""++msgid "The percentage of the cash discount. Use 0 for no discount."+msgstr ""++msgid "The quantity of the item to be reordered on scan-based replenishment."+msgstr ""++msgid "The quote has been created"+msgstr ""++msgid "The quote will be copied with a revision suffix"+msgstr ""++msgid "The revision number of the part"+msgstr ""++msgid "The size of the part"+msgstr ""++msgid "The storage service didn't respond in time. Please try again."+msgstr ""++msgid "The unit price of the item at the time of the purchase"+msgstr ""++msgid "Theme"+msgstr ""++msgid "Theme Color"+msgstr ""++msgid "There are no active supplier quotes to compare for this RFQ."+msgstr ""++msgid "There are outside operations associated with this job that have no suppliers. Please assign a supplier to each outside operation before releasing it."+msgstr ""++msgid "These custom fields will only be available for entities with the same tags"+msgstr ""++msgid "These email addresses will be automatically CC'd on all emails sent to suppliers (quotes, purchase orders, etc.)."+msgstr ""++msgid "These email addresses will be automatically CC'd on all quote emails sent to customers."+msgstr ""++msgid "These jobs have operations assigned to this work center:"+msgstr ""++msgid "This information will be used on document headers"+msgstr ""++msgid "This information will be visible to all users, so be careful what you share."+msgstr ""++msgid "This is a unique identifier for the webhook"+msgstr ""++msgid "This is the month your fiscal year starts."+msgstr ""++msgid "This is the month your tax year starts."+msgstr ""++msgid "This item's bill of materials has no inputs with shelf-life enabled, so no expiry will be calculated from the BOM."+msgstr ""++msgid "This job will be received to inventory. It will no longer be available on the shop floor."+msgstr ""++msgid "This job will no longer be available on the shop floor."+msgstr ""++msgid "This sales order has lines that require jobs to be created"+msgstr ""++#. placeholder {0}: usageCount === 1 ? "" : "s"+msgid "This storage type is currently used by {usageCount} storage unit{0}."+msgstr ""++msgid "This updates the theme for all users of the application"+msgstr ""++msgid "This will make this version read-only and replace any material make methods with this version."+msgstr ""++msgid "This will overwrite the existing job method"+msgstr ""++msgid "This will overwrite the existing manufacturing method and the latest versions of all subassemblies."+msgstr ""++msgid "This will overwrite the existing quote method"+msgstr ""++msgid "This will recalculate the unit cost from the active make method's bill of materials and processes using the batch size. The current cost will be overwritten. Do you want to continue?"+msgstr ""++msgid "This will replace all method materials of other revisions with this revision."+msgstr ""++msgid "This will replace all method materials of other sizes with this size."+msgstr ""++msgid "Thumbnail"+msgstr ""++msgid "Thumbnail removed"+msgstr ""++msgid "Thumbnail uploaded"+msgstr ""++msgid "Thumbnails are included"+msgstr ""++msgid "Thumbnails are not included"+msgstr ""++msgid "Thursday"+msgstr ""++msgid "Timecard"+msgstr ""++msgid "Timecards"+msgstr ""++msgid "Timecards are disabled"+msgstr ""++msgid "Timecards are enabled"+msgstr ""++msgid "Timezone"+msgstr ""++msgid "Title"+msgstr ""++msgid "To Location"+msgstr ""++msgid "To read rows in <0>{resourceId}</0>, use the <1>select</1> method."+msgstr ""++msgid "To Receive"+msgstr ""++msgid "To Ship"+msgstr ""++msgid "To Ship and Receive"+msgstr ""++msgid "To Storage Unit"+msgstr ""++msgid "Today"+msgstr ""++msgid "Toggle"+msgstr ""++msgid "Toggle Assignee"+msgstr ""++msgid "Toggle break active"+msgstr ""++msgid "Toggle column"+msgstr ""++msgid "Toggle dark/light mode"+msgstr ""++msgid "Toggle durations"+msgstr ""++msgid "Toggle Explorer"+msgstr ""++msgid "Toggle level"+msgstr ""++msgid "Toggle Properties"+msgstr ""++msgid "Toggle views"+msgstr ""++msgid "Tolerance (+/-)"+msgstr ""++msgid "Tool"+msgstr ""++msgid "Tool Details"+msgstr ""++msgid "Tool ID"+msgstr ""++msgid "Tools"+msgstr ""++msgid "Total"+msgstr ""++msgid "Total Hours"+msgstr ""++msgid "Total Minutes"+msgstr ""++msgid "Total Price"+msgstr ""++msgid "Total Quantity"+msgstr ""++msgid "Total:"+msgstr ""++msgid "Traceability"+msgstr ""++msgid "Track"+msgstr ""++msgid "Track changes to key business entities including invoices, orders, customers, suppliers, and more."+msgstr ""++msgid "Track every change to your orders, invoices, customers, and more."+msgstr ""++msgid "Track every change to your orders, invoices, customers, suppliers, and more."+msgstr ""++msgid "Track when batches or serials of this item expire."+msgstr ""++msgid "Tracked Entities"+msgstr ""++msgid "Tracked Entity"+msgstr ""++msgid "Tracked entity already picked"+msgstr ""++msgid "Tracked entity ID is required but none was found"+msgstr ""++msgid "Tracking"+msgstr ""++msgid "Tracking ID"+msgstr ""++msgid "Tracking Labels"+msgstr ""++msgid "Tracking Number"+msgstr ""++msgid "Tracking Type"+msgstr ""++msgid "Tracking URL"+msgstr ""++msgid "Training"+msgstr ""++msgid "Training Assignments"+msgstr ""++msgid "Trainings"+msgstr ""++msgid "Transactions will create journal entries and update the general ledger."+msgstr ""++msgid "Transfer"+msgstr ""++msgid "Transfer Date"+msgstr ""++msgid "Transfer From"+msgstr ""++msgid "Transfer ID"+msgstr ""++msgid "Transfer Lines"+msgstr ""++msgid "Transfer Ownership"+msgstr ""++msgid "Transfer ownership of this company to another user"+msgstr ""++msgid "Transfer To"+msgstr ""++msgid "Transfers"+msgstr ""++msgid "Trash"+msgstr ""++msgid "Trial Balance"+msgstr ""++msgid "Tuesday"+msgstr ""++msgid "Type"+msgstr ""++msgid "Type a message..."+msgstr ""++msgid "Type of Permission Update"+msgstr ""++msgid "Type to search across your workspace"+msgstr ""++msgid "Type:"+msgstr ""++msgid "Types"+msgstr ""++msgid "Un-sampled entities will remain On Hold so you can keep inspecting and disposition later. Sampled outcomes are preserved."+msgstr ""++msgid "Unapproved Supplier"+msgstr ""++msgid "Unassign rule"+msgstr ""++msgid "Unassigned"+msgstr ""++msgid "Uninstall"+msgstr ""++msgid "Unique, uppercase, without spaces"+msgstr ""++msgid "Unit"+msgstr ""++msgid "Unit Cost"+msgstr ""++msgid "Unit of Measure"+msgstr ""++msgid "Unit of Measures"+msgstr ""++msgid "Unit Price"+msgstr ""++msgid "Unit Sale Price"+msgstr ""++msgid "Units"+msgstr ""++msgid "Unknown"+msgstr ""++msgid "unknown location"+msgstr ""++msgid "Unlimited Functional Support"+msgstr ""++msgid "Unlink"+msgstr ""++msgid "Unsupported source document type: {sourceDocument}"+msgstr ""++msgid "UoM"+msgstr ""++msgid "Update"+msgstr ""++msgid "Update Inventory"+msgstr ""++msgid "Update Jira issue"+msgstr ""++msgid "Update Kanban"+msgstr ""++msgid "Update Linear issue"+msgstr ""++msgid "Update part lead times from posted purchase receipts."+msgstr ""++msgid "Update Password"+msgstr ""++msgid "Update Permissions"+msgstr ""++msgid "Update prices on"+msgstr ""++msgid "Update Quantity"+msgstr ""++msgid "Update rows"+msgstr ""++msgid "Update Rule"+msgstr ""++msgid "Update source document quantities"+msgstr ""++msgid "Update the kanban information for scan-based replenishment."+msgstr ""++msgid "Update the purchase order quantities"+msgstr ""++msgid "Updated"+msgstr ""++msgid "Updated account"+msgstr ""++msgid "Updated At"+msgstr ""++msgid "Updated By"+msgstr ""++msgid "Updated successfully"+msgstr ""++msgid "Upgrade"+msgstr ""++msgid "Upgrade to Business"+msgstr ""++msgid "Upgrade to unlock audit history"+msgstr ""++msgid "Upgrade to unlock item rules"+msgstr ""++msgid "Upload"+msgstr ""++msgid "Upload completed but no file path returned"+msgstr ""++msgid "Upload CSV"+msgstr ""++msgid "Uploaded model"+msgstr ""++#. placeholder {0}: file.name+#. placeholder {0}: fileUpload.name+msgid "Uploaded: {0}"+msgstr ""++#. placeholder {0}: avatarFile.name+#. placeholder {0}: file.name+#. placeholder {0}: fileUpload.name+msgid "Uploading {0}"+msgstr ""++msgid "Uploading {fileName}"+msgstr ""++msgid "Upon clicking Convert, parts will be created with the following internal part numbers:"+msgstr ""++msgid "Usage/Day (30d)"+msgstr ""++msgid "Usage/Day (90d)"+msgstr ""++msgid "Use ... to get the next consumable ID"+msgstr ""++msgid "Use ... to get the next material ID"+msgstr ""++msgid "Use ... to get the next part ID"+msgstr ""++msgid "Use ... to get the next tool ID"+msgstr ""++msgid "Use a different email"+msgstr ""++msgid "Use metric system for default material dimensions."+msgstr ""++msgid "Used In"+msgstr ""++msgid "Used in the navigation and on documents like sales orders"+msgstr ""++msgid "Used in the navigation in dark mode"+msgstr ""++msgid "Used on the home screen and digital quotes"+msgstr ""++msgid "Used on the home screen in dark mode"+msgstr ""++msgid "Used to categorize items for reporting and analysis"+msgstr ""++msgid "User"+msgstr ""++msgid "Users"+msgstr ""++msgid "Users can update this value for themselves"+msgstr ""++msgid "Users to Update"+msgstr ""++msgid "Valid From"+msgstr ""++msgid "Valid Period"+msgstr ""++msgid "Valid To"+msgstr ""++msgid "Validating job..."+msgstr ""++msgid "Value"+msgstr ""++msgid "VAT Number"+msgstr ""++msgid "Verification Error"+msgstr ""++msgid "Verify your email"+msgstr ""++msgid "Version"+msgstr ""++msgid "Version:"+msgstr ""++msgid "Versions"+msgstr ""++msgid "via Digital Quote"+msgstr ""++msgid "View"+msgstr ""++msgid "View Active Jobs"+msgstr ""++msgid "View Active Quotes"+msgstr ""++msgid "View All"+msgstr ""++msgid "View Assigned Jobs"+msgstr ""++msgid "View Attachment"+msgstr ""++msgid "View Attributes"+msgstr ""++msgid "View Contact"+msgstr ""++msgid "View Custom Fields"+msgstr ""++msgid "View Customers"+msgstr ""++msgid "View Employees"+msgstr ""++msgid "View History"+msgstr ""++msgid "View in Academy"+msgstr ""++msgid "View Issue"+msgstr ""++msgid "View Item Master"+msgstr ""++msgid "View maintenance dispatch"+msgstr ""++msgid "View Open"+msgstr ""++msgid "View Open Invoices"+msgstr ""++msgid "View Open Orders"+msgstr ""++msgid "View Open POs"+msgstr ""++msgid "View Open Quotes"+msgstr ""++msgid "View Open RFQs"+msgstr ""++msgid "View Permissions"+msgstr ""++msgid "View Production Events"+msgstr ""++msgid "View Purchase Invoice"+msgstr ""++msgid "View Reactive"+msgstr ""++msgid "View Receipt"+msgstr ""++msgid "View Scheduled"+msgstr ""++msgid "View Shipment"+msgstr ""++msgid "View Status"+msgstr ""++msgid "View Stock Transfer"+msgstr ""++msgid "View Suggestion"+msgstr ""++msgid "View Suppliers"+msgstr ""++msgid "View Traceability Graph"+msgstr ""++msgid "View Transfer"+msgstr ""++msgid "Visibilities"+msgstr ""++msgid "Visibility"+msgstr ""++msgid "Visible on a user's public profile"+msgstr ""++msgid "Voice"+msgstr ""++msgid "Void"+msgstr ""++msgid "Void Invoice"+msgstr ""++msgid "Void Purchase Invoice"+msgstr ""++msgid "Void Receipt"+msgstr ""++msgid "Void Sales Invoice"+msgstr ""++msgid "Void Shipment"+msgstr ""++msgid "Voided"+msgstr ""++msgid "Voiding this purchase invoice will:"+msgstr ""++msgid "Voiding this receipt will:"+msgstr ""++msgid "Voiding this shipment will:"+msgstr ""++msgid "Warehouse Transfer"+msgstr ""++msgid "Warehouse Transfers"+msgstr ""++msgid "Warn"+msgstr ""++msgid "Warn but allow"+msgstr ""++msgid "Warn this many days before expiry"+msgstr ""++msgid "Warn when the person inspecting an inbound item is the same person who received it."+msgstr ""++msgid "Warning"+msgstr ""++msgid "Warnings"+msgstr ""++msgid "Watch full video"+msgstr ""++msgid "We've mapped each column to what we believe is correct, but please review the data below to confirm it's accurate."+msgstr ""++msgid "We've sent a verification code to {email}"+msgstr ""++msgid "We've sent a verification code to {signupEmail}"+msgstr ""++msgid "We've sent you a magic link to sign in to your account."+msgstr ""++msgid "Web Search"+msgstr ""++msgid "Webhook"+msgstr ""++msgid "Webhook Documentation"+msgstr ""++msgid "Webhook URL"+msgstr ""++msgid "Webhooks"+msgstr ""++msgid "Webhooks Docs"+msgstr ""++msgid "Website"+msgstr ""++msgid "Wednesday"+msgstr ""++msgid "Weeks Open"+msgstr ""++msgid "Weighted Average"+msgstr ""++msgid "Weighted average cost over last year calculated when the invoice is posted"+msgstr ""++msgid "Welcome to Carbon"+msgstr ""++msgid "When"+msgstr ""++msgid "When a finished product's shelf life is set to Calculated, pick which consumed inputs feed the calculation."+msgstr ""++msgid "When expired stock is used"+msgstr ""++msgid "Who Can Approve"+msgstr ""++msgid "Who should receive notifications for maintenance-related dispatches?"+msgstr ""++msgid "Who should receive notifications for operations-related dispatches?"+msgstr ""++msgid "Who should receive notifications for other dispatches?"+msgstr ""++msgid "Who should receive notifications for quality-related dispatches?"+msgstr ""++msgid "Who should receive notifications when a digital quote is accepted or expired?"+msgstr ""++msgid "Who should receive notifications when a gauge goes out of calibration?"+msgstr ""++msgid "Who should receive notifications when a new suggestion is submitted?"+msgstr ""++msgid "Who should receive notifications when a RFQ is marked ready for quote?"+msgstr ""++msgid "Who should receive notifications when a sales job is completed?"+msgstr ""++msgid "Who should receive notifications when a supplier quote is submitted?"+msgstr ""++msgid "Who should receive notifications when an inventory job is completed?"+msgstr ""++msgid "Why is the expiration being changed?"+msgstr ""++msgid "WIP"+msgstr ""++msgid "Won"+msgstr ""++msgid "Wordmark Dark Mode"+msgstr ""++msgid "Wordmark Light Mode"+msgstr ""++msgid "Work Center"+msgstr ""++msgid "Work Center Utilization"+msgstr ""++msgid "Work Centers"+msgstr ""++msgid "Work Instructions"+msgstr ""++msgid "Work instructions are included"+msgstr ""++msgid "Work instructions are not included"+msgstr ""++msgid "Work Phone"+msgstr ""++msgid "Work shift tracking is active."+msgstr ""++msgid "Workflow"+msgstr ""++msgid "Worst Performing Machines"+msgstr ""++msgid "Year"+msgstr ""++msgid "Yes"+msgstr ""++msgid "Yes, Accept"+msgstr ""++msgid "Yes, also delete every nested storage unit."+msgstr ""++msgid "Yes, Reject"+msgstr ""++msgid "Yes, Update IDs"+msgstr ""++msgid "You can change the UI style any time through the theme setting"+msgstr ""++msgid "You can only see this key once. Store it safely."+msgstr ""++#. placeholder {0}: new Date(openClockEntry.clockIn).toLocaleString(locale)+msgid "You clocked in at {0}. You can edit your clock-out time below or acknowledge that you're still working."+msgstr ""++#. placeholder {0}: leftoverQuantity === 1 ? "part" : "parts"+#. placeholder {1}: job.quantity+msgid ""+"You completed {leftoverQuantity} more \n"+" {0} than the\n"+" ordered quantity of {1}. What would you like\n"+" to do with the extra parts?"+msgstr ""++msgid "You haven't created any contacts yet."+msgstr ""++msgid "You received this item"+msgstr ""++msgid "You received this lot"+msgstr ""++msgid "You've been clocked in for {hoursElapsed} hours. Did you forget to clock out?"+msgstr ""++msgid "Your Console PIN"+msgstr ""++msgid "Your Email"+msgstr ""++msgid "Your invitation is invalid or has already been accepted. Please contact support if you believe this is an error."+msgstr ""++msgid "Your Name"+msgstr ""++msgid "yourself"+msgstr ""diff --git a/packages/locale/locales/nl/mes.po b/packages/locale/locales/nl/mes.ponew file mode 100644index 0000000000..bfe1f15aab--- /dev/null+++ b/packages/locale/locales/nl/mes.po@@ -0,0 +1,924 @@+msgid ""+msgstr ""+"MIME-Version: 1.0\n"+"Content-Type: text/plain; charset=utf-8\n"+"Content-Transfer-Encoding: 8bit\n"+"X-Generator: @lingui/cli\n"+"Language: nl\n"+"Project-Id-Version: \n"+"Report-Msgid-Bugs-To: \n"+"PO-Revision-Date: \n"+"Last-Translator: \n"+"Language-Team: \n"+"Plural-Forms: \n"++#. placeholder {0}: attribute.name+#. placeholder {1}: activeStep + 1+msgid "{0} - Set {1}"+msgstr ""++#. placeholder {0}: employeeIds.length+msgid "{0} Active"+msgstr ""++#. placeholder {0}: batch.quantity+msgid "{0} available"+msgstr ""++#. placeholder {0}: operation.quantityComplete+#. placeholder {0}: serialIndex + 1+#. placeholder {1}: operation.operationQuantity+#. placeholder {1}: operation.targetQuantity+msgid "{0} of {1}"+msgstr ""++#. placeholder {0}: attributes.filter((a) => a.jobOperationStepRecord.some( (r) => r.index === activeStep ) ).length+#. placeholder {1}: attributes.length+msgid "{0} of {1} complete"+msgstr ""++#. placeholder {0}: attributes.filter((a) => a.jobOperationStepRecord.some( (r) => r.index === activeStep ) ).length+#. placeholder {1}: attributes.length+msgid "{0} of {1} completed"+msgstr ""++#. placeholder {0}: item.quantityScrapped+msgid "{0} Scrapped"+msgstr ""++msgid "About"+msgstr ""++msgid "Account Settings"+msgstr ""++msgid "Active"+msgstr ""++msgid "Actual"+msgstr ""++msgid "Add"+msgstr ""++msgid "Add & Issue"+msgstr ""++msgid "Add Inventory"+msgstr ""++msgid "Add Spare Part"+msgstr ""++msgid "All"+msgstr ""++msgid "Are you sure you want to close out this operation? This will end all active production events for this operation."+msgstr ""++msgid "Are you sure you want to delete this step?"+msgstr ""++msgid "Are you sure you want to delete this timecard? This cannot be undone."+msgstr ""++msgid "Are you sure you want to end all production events? This will end all active operations without completing or finishing them."+msgstr ""++msgid "Assigned"+msgstr ""++msgid "Assigned to Me"+msgstr ""++msgid "Assignee"+msgstr ""++msgid "Attach File"+msgstr ""++msgid "Authentication Error"+msgstr ""++#. placeholder {0}: batch.readableId+#. placeholder {1}: batch.quantity+msgid "Batch {0} ({1} available)"+msgstr ""++msgid "Batch is not available"+msgstr ""++#. placeholder {0}: index + 1+msgid "Batch Number {0}"+msgstr ""++msgid "Batch number is required"+msgstr ""++#. placeholder {0}: column.blockingDispatchReadableId+msgid "Blocked by {0}"+msgstr ""++msgid "Blocking"+msgstr ""++msgid "But don't worry. You can use the forgot password flow to request a new magic link."+msgstr ""++msgid "By signing in, you agree to the <0>Terms of Service</0> and <1>Privacy Policy.</1>"+msgstr ""++msgid "Cancel"+msgstr ""++msgid "Carbon Logo"+msgstr ""++msgid "Cards"+msgstr ""++msgid "Chat"+msgstr ""++msgid "Check your email"+msgstr ""++msgid "Clear"+msgstr ""++msgid "Clear Filters"+msgstr ""++msgid "Clear Search"+msgstr ""++msgid "Clock In"+msgstr ""++msgid "Clock Out"+msgstr ""++#. placeholder {0}: formatTime(openEntry.clockIn, locale)+msgid "Clocked in since {0}"+msgstr ""++msgid "Close"+msgstr ""++msgid "Close Anyways"+msgstr ""++msgid "Close Out"+msgstr ""++#. placeholder {0}: operation.itemReadableId+msgid "Close out {0}"+msgstr ""++#. placeholder {0}: active.data.current.column.title+#. placeholder {1}: overColumnPosition + 1+#. placeholder {2}: columnOrder.length+msgid "Column {0} was dropped into position {1} of {2}"+msgstr ""++#. placeholder {0}: active.data.current.column.title+#. placeholder {1}: over.data.current.column.title+#. placeholder {2}: overIndex + 1+#. placeholder {3}: columnOrder.length+msgid "Column {0} was moved over {1} at position {2} of {3}"+msgstr ""++#. placeholder {0}: column.title+msgid "Column: {0}"+msgstr ""++msgid "Columns"+msgstr ""++msgid "Company"+msgstr ""++msgid "Complete"+msgstr ""++msgid "Completed"+msgstr ""++msgid "Console"+msgstr ""++msgid "Console Mode"+msgstr ""++msgid "Consumed expired"+msgstr ""++#. placeholder {0}: search.trim() === "" ? (createLabel ?? label) : search+#. placeholder {0}: search.trim() === "" ? label : search+msgid "Create {0}"+msgstr ""++msgid "Customer"+msgstr ""++msgid "Dark Mode"+msgstr ""++msgid "Date"+msgstr ""++msgid "Deadline"+msgstr ""++msgid "Default Storage Unit"+msgstr ""++msgid "Delete"+msgstr ""++msgid "Delete Step"+msgstr ""++#. placeholder {0}: new Date(deletingEntry.clockIn).toLocaleString(locale)+msgid "Delete Timecard ({0})"+msgstr ""++msgid "Description"+msgstr ""++msgid "Details"+msgstr ""++msgid "Dispatch not found"+msgstr ""++msgid "Display"+msgstr ""++msgid "Down"+msgstr ""++msgid "Download"+msgstr ""++msgid "Drag and drop a file here, or click to select a file"+msgstr ""++#. placeholder {0}: active.data.current?.type+msgid "Dragging {0} cancelled."+msgstr ""++#. placeholder {0}: formatRelativeTime( convertDateStringToIsoString( operation.operationDueDate ) )+#. placeholder {0}: formatRelativeTime( convertDateStringToIsoString(operation.jobDueDate) )+#. placeholder {0}: formatRelativeTime( convertDateStringToIsoString(item.dueDate) )+msgid "Due {0}"+msgstr ""++msgid "Due Date"+msgstr ""++msgid "Duplicate batch number"+msgstr ""++msgid "Duplicate serial number"+msgstr ""++msgid "Duration"+msgstr ""++msgid "Edit"+msgstr ""++msgid "Email Address"+msgstr ""++msgid "Empty work centers"+msgstr ""++msgid "End Operations"+msgstr ""++#. placeholder {0}: selectedPerson.name+msgid "Enter PIN for {0}"+msgstr ""++msgid "Error"+msgstr ""++msgid "Estimated"+msgstr ""++msgid "Failed to complete inventory adjustment"+msgstr ""++msgid "Failed to end operations"+msgstr ""++msgid "Failed to fetch active operations"+msgstr ""++msgid "Failed to fetch storageUnits"+msgstr ""++#. placeholder {0}: fileUpload.name+msgid "Failed to upload file: {0}"+msgstr ""++msgid "Failed to upload image"+msgstr ""++msgid "Feedback"+msgstr ""++msgid "File size exceeds 10MB limit"+msgstr ""++msgid "Files"+msgstr ""++msgid "Files related to the job and the opportunity line."+msgstr ""++msgid "Filter"+msgstr ""++msgid "Forgot to Clock Out?"+msgstr ""++msgid "Have a technical issue? Contact <0>Carbon Support.</0>"+msgstr ""++msgid "I understand and want to complete without issuing"+msgstr ""++msgid "I'm Still Working"+msgstr ""++msgid "Ideas, suggestions or problems with this page?"+msgstr ""++msgid "Ideas, suggestions or problems?"+msgstr ""++msgid "Impact"+msgstr ""++msgid "In Progress"+msgstr ""++msgid "Insufficient quantity"+msgstr ""++msgid "Inventory adjustment completed"+msgstr ""++msgid "Inventory Adjustments"+msgstr ""++msgid "is"+msgstr ""++msgid "is any of"+msgstr ""++msgid "Issue"+msgstr ""++msgid "Issue Material"+msgstr ""++msgid "Item"+msgstr ""++msgid "Item Master"+msgstr ""++msgid "Job"+msgstr ""++msgid "Job Details"+msgstr ""++msgid "Job Traveler"+msgstr ""++msgid "Kit"+msgstr ""++msgid "Labor"+msgstr ""++msgid "Let's build something"+msgstr ""++msgid "Loading item details..."+msgstr ""++msgid "Loading..."+msgstr ""++msgid "Location"+msgstr ""++msgid "Log Completed"+msgstr ""++#. placeholder {0}: operation.itemReadableId+msgid "Log completed for {0}"+msgstr ""++msgid "Log Rework"+msgstr ""++#. placeholder {0}: operation.itemReadableId+msgid "Log rework for {0}"+msgstr ""++msgid "Log Scrap"+msgstr ""++#. placeholder {0}: operation.itemReadableId+msgid "Log scrap for {0}"+msgstr ""++msgid "Login"+msgstr ""++msgid "Machine"+msgstr ""++msgid "Maintenance"+msgstr ""++msgid "Maintenance Completed"+msgstr ""++msgid "Manually add items to inventory"+msgstr ""++msgid "Manually remove items from inventory"+msgstr ""++msgid "matches"+msgstr ""++msgid "Materials"+msgstr ""++msgid "Maximum number of records reached"+msgstr ""++msgid "Model"+msgstr ""++msgid "More options"+msgstr ""++#. placeholder {0}: column.title+msgid "Move column: {0}"+msgstr ""++msgid "Must be < {maxValue} {unitOfMeasureCode}"+msgstr ""++msgid "Must be > {minValue} {unitOfMeasureCode}"+msgstr ""++msgid "Must be between {minValue} and {maxValue} {unitOfMeasureCode}"+msgstr ""++msgid "My Hours"+msgstr ""++msgid "Name"+msgstr ""++msgid "New"+msgstr ""++msgid "New Record"+msgstr ""++msgid "Next"+msgstr ""++msgid "No active maintenance dispatches"+msgstr ""++msgid "No active operations"+msgstr ""++msgid "No assigned operations"+msgstr ""++msgid "No available filters"+msgstr ""++msgid "No available serial numbers found"+msgstr ""++msgid "No dispatches assigned to you"+msgstr ""++msgid "No files"+msgstr ""++msgid "No Impact"+msgstr ""++msgid "No maintenance scheduled for today"+msgstr ""++msgid "No materials"+msgstr ""++msgid "No operators"+msgstr ""++msgid "No option found."+msgstr ""++msgid "No options found."+msgstr ""++msgid "No recent operations"+msgstr ""++msgid "No results"+msgstr ""++msgid "No results exist"+msgstr ""++msgid "No results found"+msgstr ""++msgid "No scheduled time"+msgstr ""++msgid "No serial numbers"+msgstr ""++msgid "No spare parts added yet"+msgstr ""++msgid "No time entries for this week"+msgstr ""++msgid "No work centers are blocked"+msgstr ""++msgid "No work centers exist"+msgstr ""++msgid "Notes"+msgstr ""++msgid "OEE Impact"+msgstr ""++msgid "OEM Required"+msgstr ""++#. placeholder {0}: batch.quantity+msgid "Only {0} available"+msgstr ""++msgid "Oops. You shouldn't see this page. Eventually it will be a landing page."+msgstr ""++msgid "Open"+msgstr ""++msgid "Operations"+msgstr ""++msgid "Operations ended"+msgstr ""++msgid "Operator Performed"+msgstr ""++msgid "Optional"+msgstr ""++msgid "Parameters"+msgstr ""++msgid "Part"+msgstr ""++msgid "Passed Inspection"+msgstr ""++msgid "Pause"+msgstr ""++#. placeholder {0}: startColumn?.title+#. placeholder {1}: startIndex + 1+#. placeholder {2}: columnOrder.length+msgid "Picked up Column {0} at position: {1} of {2}"+msgstr ""++msgid "Pin Out"+msgstr ""++msgid "Planned"+msgstr ""++msgid "Please record all steps for this operation before closing."+msgstr ""++msgid "Please select an item"+msgstr ""++msgid "Prev"+msgstr ""++msgid "Preventive"+msgstr ""++msgid "Priority"+msgstr ""++msgid "Procedure"+msgstr ""++msgid "Process"+msgstr ""++msgid "Process Parameters"+msgstr ""++msgid "Processes"+msgstr ""++msgid "Progress"+msgstr ""++msgid "Quantity"+msgstr ""++msgid "Quantity must be greater than 0"+msgstr ""++msgid "Recent"+msgstr ""++msgid "Record"+msgstr ""++#. placeholder {0}: activeStep + 1+msgid "Record {0}"+msgstr ""++msgid "Remove"+msgstr ""++msgid "Remove filter"+msgstr ""++msgid "Remove Inventory"+msgstr ""++msgid "Remove part"+msgstr ""++msgid "Sales Order"+msgstr ""++msgid "Save"+msgstr ""++msgid "Scan"+msgstr ""++msgid "Scan or enter serial number"+msgstr ""++msgid "Schedule"+msgstr ""++msgid "Scrap Reason"+msgstr ""++msgid "Scrapped"+msgstr ""++msgid "Search"+msgstr ""++msgid "Search operators..."+msgstr ""++msgid "Search..."+msgstr ""++msgid "Select"+msgstr ""++msgid "Select a completion quantity"+msgstr ""++msgid "Select a rework quantity"+msgstr ""++msgid "Select a scrap quantity and reason"+msgstr ""++msgid "Select a serial number to continue with this operation"+msgstr ""++msgid "Select an item and specify the quantity to issue"+msgstr ""++msgid "Select an item..."+msgstr ""++#. placeholder {0}: index + 1+msgid "Select Batch {0}"+msgstr ""++#. placeholder {0}: index + 1+msgid "Select Serial {0}"+msgstr ""++msgid "Select Serial Number"+msgstr ""++msgid "Send"+msgstr ""++msgid "Serial"+msgstr ""++#. placeholder {0}: sn.readableId+msgid "Serial {0}"+msgstr ""++#. placeholder {0}: index + 1+msgid "Serial Number {0}"+msgstr ""++msgid "Serial number is not available"+msgstr ""++msgid "Serial number is required"+msgstr ""++msgid "Serial Numbers"+msgstr ""++msgid "Set Clock Out"+msgstr ""++msgid "Set clock-out time"+msgstr ""++msgid "Setup"+msgstr ""++msgid "Sign in with Email"+msgstr ""++msgid "Sign in with Google"+msgstr ""++msgid "Sign in with Outlook"+msgstr ""++msgid "Sign Out"+msgstr ""++msgid "Signed in as {stationName}"+msgstr ""++msgid "Size"+msgstr ""++msgid "Source"+msgstr ""++msgid "Spare Parts"+msgstr ""++msgid "Spare Parts Used"+msgstr ""++msgid "Start"+msgstr ""++msgid "Station User"+msgstr ""++msgid "Station: {stationName}"+msgstr ""++msgid "Status"+msgstr ""++msgid "Statuses"+msgstr ""++msgid "Steps"+msgstr ""++msgid "Steps are missing"+msgstr ""++msgid "Storage Unit"+msgstr ""++msgid "Submit anonymously"+msgstr ""++msgid "Suggestion"+msgstr ""++msgid "Support Required"+msgstr ""++msgid "Switch Operator"+msgstr ""++msgid "Tag"+msgstr ""++#. placeholder {0}: operation.operationQuantity+msgid "The completed quantity for this operation is less than the required quantity of {0}."+msgstr ""++msgid "There are serial or batch tracked materials on the bill of material that have not been fully issued. Completing without issuing may result in incorrect traceability records."+msgstr ""++msgid "Thumbnail"+msgstr ""++msgid "Time Entries"+msgstr ""++#. placeholder {0}: formatDuration(totalDuration)+msgid "Time Worked: {0}"+msgstr ""++msgid "Today"+msgstr ""++msgid "Tools"+msgstr ""++msgid "Total Quantity"+msgstr ""++#. placeholder {0}: formatDuration(totalDuration)+msgid "Total time: {0}"+msgstr ""++#. placeholder {0}: formatTotalHours(entries)+msgid "Total: {0}"+msgstr ""++msgid "Tracking Labels"+msgstr ""++msgid "Type a message..."+msgstr ""++msgid "Unissued serial/batch materials"+msgstr ""++msgid "Unknown"+msgstr ""++msgid "Update"+msgstr ""++msgid "Updated successfully"+msgstr ""++#. placeholder {0}: fileUpload.name+msgid "Uploaded: {0}"+msgstr ""++#. placeholder {0}: fileUpload.name+msgid "Uploading {0}"+msgstr ""++msgid "View maintenance dispatch"+msgstr ""++msgid "We've sent you a magic link to sign in to your account."+msgstr ""++msgid "WIP"+msgstr ""++msgid "Work Center"+msgstr ""++#. placeholder {0}: new Date(openClockEntry.clockIn).toLocaleString(locale)+msgid "You clocked in at {0}. You can edit your clock-out time below or acknowledge that you're still working."+msgstr ""++msgid "You've been clocked in for {hoursElapsed} hours. Did you forget to clock out?"+msgstr ""diff --git a/packages/locale/locales/package.json b/packages/locale/locales/package.jsonnew file mode 100644index 0000000000..3dbc1ca591--- /dev/null+++ b/packages/locale/locales/package.json@@ -0,0 +1,3 @@+{+ "type": "module"+}diff --git a/packages/locale/locales/pl/erp.po b/packages/locale/locales/pl/erp.poindex 0aa053c6e6..3a4fe1fa0d 100644--- a/packages/locale/locales/pl/erp.po+++ b/packages/locale/locales/pl/erp.po@@ -889,6 +889,15 @@ msgstr ""msgid "Assembly:"msgstr ""+msgid "Asset"+msgstr ""++msgid "Asset Classes"+msgstr ""++msgid "Assets"+msgstr ""+msgid "Assign To"msgstr ""@@ -1422,9 +1431,6 @@ msgstr ""msgid "Configure Item"msgstr ""-msgid "Configure Materials"-msgstr ""-msgid "Configure notifications for when gauges go out of calibration."msgstr ""@@ -2412,6 +2418,9 @@ msgstr ""msgid "Departments"msgstr ""+msgid "Depreciation"+msgstr ""+msgid "Description"msgstr ""@@ -2881,6 +2890,9 @@ msgstr ""msgid "Enable to automatically post transactions to the general ledger."msgstr ""+msgid "Enable to configure tax-specific depreciation methods on asset classes (e.g., MACRS, accelerated)."+msgstr ""+msgid "Enable to generate IDs and descriptions for raw materials."msgstr ""@@ -3512,6 +3524,12 @@ msgstr ""msgid "Fixed"msgstr ""+msgid "Fixed Asset"+msgstr ""++msgid "Fixed Assets"+msgstr ""+msgid "Fixed Reorder"msgstr ""@@ -4426,6 +4444,9 @@ msgstr ""msgid "Material IDs"msgstr ""+msgid "Material Properties"+msgstr ""+msgid "Material Shape"msgstr ""@@ -6506,6 +6527,9 @@ msgstr ""msgid "Search"msgstr ""+msgid "Search accounts..."+msgstr ""+msgid "Search across your workspace..."msgstr ""@@ -6930,6 +6954,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -7381,6 +7408,9 @@ msgstr ""msgid "Tax & Additional Costs"msgstr ""+msgid "Tax & Shipping"+msgstr ""+msgid "Tax Amount"msgstr ""@@ -7681,6 +7711,12 @@ msgstr ""msgid "Track every change to your orders, invoices, customers, suppliers, and more."msgstr ""+msgid "Track tax depreciation separately"+msgstr ""++msgid "Track tax depreciation separately from book depreciation and automatically post deferred tax liability entries."+msgstr ""+msgid "Track when batches or serials of this item expire."msgstr ""diff --git a/packages/locale/locales/pl/mes.po b/packages/locale/locales/pl/mes.poindex 1cfef03bfb..b97bf0a411 100644--- a/packages/locale/locales/pl/mes.po+++ b/packages/locale/locales/pl/mes.po@@ -403,7 +403,7 @@ msgid "Job Traveler"msgstr ""msgid "Jobs"-msgstr ""+msgstr "Zadania"msgid "Kit"msgstr ""@@ -536,7 +536,7 @@ msgid "No materials"msgstr ""msgid "No open jobs"-msgstr ""+msgstr "Brak otwartych zadań"msgid "No operators"msgstr ""@@ -597,7 +597,7 @@ msgid "Open"msgstr ""msgid "Open Jobs"-msgstr ""+msgstr "Otwarte Zadania"msgid "Operations"msgstr ""@@ -718,7 +718,7 @@ msgid "Search"msgstr ""msgid "Search by job or item ID"-msgstr ""+msgstr "Szukaj po ID zadania lub przedmiotu"msgid "Search operators..."msgstr ""@@ -799,6 +799,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -891,7 +894,7 @@ msgid "Total: {0}"msgstr ""msgid "Tracking"-msgstr ""+msgstr "Śledzenie"msgid "Tracking Labels"msgstr ""diff --git a/packages/locale/locales/pt/erp.po b/packages/locale/locales/pt/erp.poindex bff35afa09..868af46212 100644--- a/packages/locale/locales/pt/erp.po+++ b/packages/locale/locales/pt/erp.po@@ -889,6 +889,15 @@ msgstr ""msgid "Assembly:"msgstr ""+msgid "Asset"+msgstr ""++msgid "Asset Classes"+msgstr ""++msgid "Assets"+msgstr ""+msgid "Assign To"msgstr ""@@ -1422,9 +1431,6 @@ msgstr ""msgid "Configure Item"msgstr ""-msgid "Configure Materials"-msgstr ""-msgid "Configure notifications for when gauges go out of calibration."msgstr ""@@ -2412,6 +2418,9 @@ msgstr ""msgid "Departments"msgstr ""+msgid "Depreciation"+msgstr ""+msgid "Description"msgstr ""@@ -2881,6 +2890,9 @@ msgstr ""msgid "Enable to automatically post transactions to the general ledger."msgstr ""+msgid "Enable to configure tax-specific depreciation methods on asset classes (e.g., MACRS, accelerated)."+msgstr ""+msgid "Enable to generate IDs and descriptions for raw materials."msgstr ""@@ -3512,6 +3524,12 @@ msgstr ""msgid "Fixed"msgstr ""+msgid "Fixed Asset"+msgstr ""++msgid "Fixed Assets"+msgstr ""+msgid "Fixed Reorder"msgstr ""@@ -4426,6 +4444,9 @@ msgstr ""msgid "Material IDs"msgstr ""+msgid "Material Properties"+msgstr ""+msgid "Material Shape"msgstr ""@@ -6506,6 +6527,9 @@ msgstr ""msgid "Search"msgstr ""+msgid "Search accounts..."+msgstr ""+msgid "Search across your workspace..."msgstr ""@@ -6930,6 +6954,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -7381,6 +7408,9 @@ msgstr ""msgid "Tax & Additional Costs"msgstr ""+msgid "Tax & Shipping"+msgstr ""+msgid "Tax Amount"msgstr ""@@ -7681,6 +7711,12 @@ msgstr ""msgid "Track every change to your orders, invoices, customers, suppliers, and more."msgstr ""+msgid "Track tax depreciation separately"+msgstr ""++msgid "Track tax depreciation separately from book depreciation and automatically post deferred tax liability entries."+msgstr ""+msgid "Track when batches or serials of this item expire."msgstr ""diff --git a/packages/locale/locales/pt/mes.po b/packages/locale/locales/pt/mes.poindex 4106bc7aee..c1b8693dc8 100644--- a/packages/locale/locales/pt/mes.po+++ b/packages/locale/locales/pt/mes.po@@ -403,7 +403,7 @@ msgid "Job Traveler"msgstr ""msgid "Jobs"-msgstr ""+msgstr "Trabalhos"msgid "Kit"msgstr ""@@ -536,7 +536,7 @@ msgid "No materials"msgstr ""msgid "No open jobs"-msgstr ""+msgstr "Nenhum trabalho aberto"msgid "No operators"msgstr ""@@ -597,7 +597,7 @@ msgid "Open"msgstr ""msgid "Open Jobs"-msgstr ""+msgstr "Trabalhos Abertos"msgid "Operations"msgstr ""@@ -718,7 +718,7 @@ msgid "Search"msgstr ""msgid "Search by job or item ID"-msgstr ""+msgstr "Pesquisar por ID de trabalho ou item"msgid "Search operators..."msgstr ""@@ -799,6 +799,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -891,7 +894,7 @@ msgid "Total: {0}"msgstr ""msgid "Tracking"-msgstr ""+msgstr "Rastreamento"msgid "Tracking Labels"msgstr ""diff --git a/packages/locale/locales/ru/erp.po b/packages/locale/locales/ru/erp.poindex a466164f84..7e798b0984 100644--- a/packages/locale/locales/ru/erp.po+++ b/packages/locale/locales/ru/erp.po@@ -889,6 +889,15 @@ msgstr ""msgid "Assembly:"msgstr ""+msgid "Asset"+msgstr ""++msgid "Asset Classes"+msgstr ""++msgid "Assets"+msgstr ""+msgid "Assign To"msgstr ""@@ -1422,9 +1431,6 @@ msgstr ""msgid "Configure Item"msgstr ""-msgid "Configure Materials"-msgstr ""-msgid "Configure notifications for when gauges go out of calibration."msgstr ""@@ -2412,6 +2418,9 @@ msgstr ""msgid "Departments"msgstr ""+msgid "Depreciation"+msgstr ""+msgid "Description"msgstr ""@@ -2881,6 +2890,9 @@ msgstr ""msgid "Enable to automatically post transactions to the general ledger."msgstr ""+msgid "Enable to configure tax-specific depreciation methods on asset classes (e.g., MACRS, accelerated)."+msgstr ""+msgid "Enable to generate IDs and descriptions for raw materials."msgstr ""@@ -3512,6 +3524,12 @@ msgstr ""msgid "Fixed"msgstr ""+msgid "Fixed Asset"+msgstr ""++msgid "Fixed Assets"+msgstr ""+msgid "Fixed Reorder"msgstr ""@@ -4426,6 +4444,9 @@ msgstr ""msgid "Material IDs"msgstr ""+msgid "Material Properties"+msgstr ""+msgid "Material Shape"msgstr ""@@ -6506,6 +6527,9 @@ msgstr ""msgid "Search"msgstr ""+msgid "Search accounts..."+msgstr ""+msgid "Search across your workspace..."msgstr ""@@ -6930,6 +6954,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -7381,6 +7408,9 @@ msgstr ""msgid "Tax & Additional Costs"msgstr ""+msgid "Tax & Shipping"+msgstr ""+msgid "Tax Amount"msgstr ""@@ -7681,6 +7711,12 @@ msgstr ""msgid "Track every change to your orders, invoices, customers, suppliers, and more."msgstr ""+msgid "Track tax depreciation separately"+msgstr ""++msgid "Track tax depreciation separately from book depreciation and automatically post deferred tax liability entries."+msgstr ""+msgid "Track when batches or serials of this item expire."msgstr ""diff --git a/packages/locale/locales/ru/mes.po b/packages/locale/locales/ru/mes.poindex 19bb0b591c..ea5d2f847c 100644--- a/packages/locale/locales/ru/mes.po+++ b/packages/locale/locales/ru/mes.po@@ -403,7 +403,7 @@ msgid "Job Traveler"msgstr ""msgid "Jobs"-msgstr ""+msgstr "Работы"msgid "Kit"msgstr ""@@ -536,7 +536,7 @@ msgid "No materials"msgstr ""msgid "No open jobs"-msgstr ""+msgstr "Нет открытых заданий"msgid "No operators"msgstr ""@@ -597,7 +597,7 @@ msgid "Open"msgstr ""msgid "Open Jobs"-msgstr ""+msgstr "Открытые задания"msgid "Operations"msgstr ""@@ -718,7 +718,7 @@ msgid "Search"msgstr ""msgid "Search by job or item ID"-msgstr ""+msgstr "Поиск по номеру работы или товара"msgid "Search operators..."msgstr ""@@ -799,6 +799,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -891,7 +894,7 @@ msgid "Total: {0}"msgstr ""msgid "Tracking"-msgstr ""+msgstr "Отслеживание"msgid "Tracking Labels"msgstr ""diff --git a/packages/locale/locales/zh/erp.po b/packages/locale/locales/zh/erp.poindex 9d3193ef4a..ee61c65e2f 100644--- a/packages/locale/locales/zh/erp.po+++ b/packages/locale/locales/zh/erp.po@@ -889,6 +889,15 @@ msgstr ""msgid "Assembly:"msgstr ""+msgid "Asset"+msgstr ""++msgid "Asset Classes"+msgstr ""++msgid "Assets"+msgstr ""+msgid "Assign To"msgstr ""@@ -1422,9 +1431,6 @@ msgstr ""msgid "Configure Item"msgstr ""-msgid "Configure Materials"-msgstr ""-msgid "Configure notifications for when gauges go out of calibration."msgstr ""@@ -2412,6 +2418,9 @@ msgstr ""msgid "Departments"msgstr ""+msgid "Depreciation"+msgstr ""+msgid "Description"msgstr ""@@ -2881,6 +2890,9 @@ msgstr ""msgid "Enable to automatically post transactions to the general ledger."msgstr ""+msgid "Enable to configure tax-specific depreciation methods on asset classes (e.g., MACRS, accelerated)."+msgstr ""+msgid "Enable to generate IDs and descriptions for raw materials."msgstr ""@@ -3512,6 +3524,12 @@ msgstr ""msgid "Fixed"msgstr ""+msgid "Fixed Asset"+msgstr ""++msgid "Fixed Assets"+msgstr ""+msgid "Fixed Reorder"msgstr ""@@ -4426,6 +4444,9 @@ msgstr ""msgid "Material IDs"msgstr ""+msgid "Material Properties"+msgstr ""+msgid "Material Shape"msgstr ""@@ -6506,6 +6527,9 @@ msgstr ""msgid "Search"msgstr ""+msgid "Search accounts..."+msgstr ""+msgid "Search across your workspace..."msgstr ""@@ -6930,6 +6954,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -7381,6 +7408,9 @@ msgstr ""msgid "Tax & Additional Costs"msgstr ""+msgid "Tax & Shipping"+msgstr ""+msgid "Tax Amount"msgstr ""@@ -7681,6 +7711,12 @@ msgstr ""msgid "Track every change to your orders, invoices, customers, suppliers, and more."msgstr ""+msgid "Track tax depreciation separately"+msgstr ""++msgid "Track tax depreciation separately from book depreciation and automatically post deferred tax liability entries."+msgstr ""+msgid "Track when batches or serials of this item expire."msgstr ""diff --git a/packages/locale/locales/zh/mes.po b/packages/locale/locales/zh/mes.poindex 4abd89fb12..a3363f994a 100644--- a/packages/locale/locales/zh/mes.po+++ b/packages/locale/locales/zh/mes.po@@ -403,7 +403,7 @@ msgid "Job Traveler"msgstr ""msgid "Jobs"-msgstr ""+msgstr "工作"msgid "Kit"msgstr ""@@ -536,7 +536,7 @@ msgid "No materials"msgstr ""msgid "No open jobs"-msgstr ""+msgstr "没有开放的工作"msgid "No operators"msgstr ""@@ -597,7 +597,7 @@ msgid "Open"msgstr ""msgid "Open Jobs"-msgstr ""+msgstr "开放工作"msgid "Operations"msgstr ""@@ -718,7 +718,7 @@ msgid "Search"msgstr ""msgid "Search by job or item ID"-msgstr ""+msgstr "按工作或项目ID搜索"msgid "Search operators..."msgstr ""@@ -799,6 +799,9 @@ msgstr ""msgid "Sign in with Outlook"msgstr ""+msgid "Sign in with Passkey"+msgstr ""+msgid "Sign Out"msgstr ""@@ -891,7 +894,7 @@ msgid "Total: {0}"msgstr ""msgid "Tracking"-msgstr ""+msgstr "追踪"msgid "Tracking Labels"msgstr ""diff --git a/packages/react/src/Modal.tsx b/packages/react/src/Modal.tsxindex ce47aaa99f..3508bdd55d 100644--- a/packages/react/src/Modal.tsx+++ b/packages/react/src/Modal.tsx@@ -111,7 +111,7 @@ const ModalHeader = ({}: HTMLAttributes<HTMLDivElement>) => (<divclassName={cn(- "flex flex-col space-y-1.5 text-center sm:text-left mb-6 px-6",+ "flex flex-col space-y-1.5 text-center sm:text-left mb-4 px-6",className)}{...props}@@ -120,7 +120,7 @@ const ModalHeader = ({ModalHeader.displayName = "ModalHeader";const ModalBody = ({ className, ...props }: HTMLAttributes<HTMLDivElement>) => (- <div className={cn(" w-full py-0 px-6 mb-6", className)} {...props} />+ <div className={cn(" w-full py-0 px-6 mb-4", className)} {...props} />);ModalBody.displayName = "ModalBody";@@ -159,7 +159,7 @@ const ModalDescription = forwardRef<>(({ className, ...props }, ref) => (<DialogPrimitive.Descriptionref={ref}- className={cn("text-xs text-muted-foreground", className)}+ className={cn("text-sm text-muted-foreground", className)}{...props}/>));