Deploy via committed dist: local Nest build, server runs with .env
Build on the developer machine without Docker, commit dist/, and run on the server with Dockerfile.dist plus compose env_file. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Vendored
+12
@@ -0,0 +1,12 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.generateOrderNumber = generateOrderNumber;
|
||||
function generateOrderNumber(date = new Date()) {
|
||||
const year = new Intl.DateTimeFormat('fa-IR-u-ca-persian', {
|
||||
year: 'numeric',
|
||||
}).format(date);
|
||||
const persianYear = year.replace(/[^\d]/g, '') || '1403';
|
||||
const seq = Math.floor(Math.random() * 9000) + 1000;
|
||||
return `ORD-${persianYear}-${seq}`;
|
||||
}
|
||||
//# sourceMappingURL=order-number.js.map
|
||||
Reference in New Issue
Block a user