Adds accounting-service PATCH/archive, fiscal helpers, COA templates and setup status, plus SuperApp Accounting UI (DS, scoreboard, masters, vouchers, ledger, ops modules) with session refresh and HTTPS public API URLs. Co-authored-by: Cursor <cursoragent@cursor.com>
14 lines
509 B
TypeScript
14 lines
509 B
TypeScript
import { type ClassValue, clsx } from "clsx";
|
|
import { twMerge } from "tailwind-merge";
|
|
|
|
export function cn(...inputs: ClassValue[]) {
|
|
return twMerge(clsx(inputs));
|
|
}
|
|
|
|
export function formatMoney(value: string | number | null | undefined, locale = "fa-IR") {
|
|
if (value === null || value === undefined || value === "") return "—";
|
|
const n = typeof value === "string" ? Number(value) : value;
|
|
if (Number.isNaN(n)) return String(value);
|
|
return new Intl.NumberFormat(locale).format(n);
|
|
}
|