Rebuild order flow: settle after pricing, notifications, and invoice expiry.
Hide prices until admin sends the invoice, enforce status transitions, add customer/admin SMS+in-app notifications, schedule cash invoice reminders, and ship updated dist/prisma-client/deploy-bundle for git-pull deploys. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
/** وقتی نه شرکت و نه تنظیمات سیستم مقداری ندارند. */
|
||||
export const FALLBACK_MAX_METERAGE = 5000;
|
||||
|
||||
/**
|
||||
* سقف متراژ موثر هر فاکتور: مقدار شرکت، در نبودش تنظیمات سیستم.
|
||||
*/
|
||||
export function resolveMaxMeterage(
|
||||
companyValue: number | null | undefined,
|
||||
settingsValue: number | null | undefined,
|
||||
): number {
|
||||
if (companyValue != null && companyValue > 0) return companyValue;
|
||||
if (settingsValue != null && settingsValue > 0) return settingsValue;
|
||||
return FALLBACK_MAX_METERAGE;
|
||||
}
|
||||
Reference in New Issue
Block a user