UNPKG

lakutata

Version:

An IoC-based universal application framework.

55 lines (47 loc) 1.3 kB
/* Build Date: Mon Jan 05 2026 23:52:23 GMT+0800 (China Standard Time) */ import { a as e, O as t } from "./Package.internal.51.mjs"; var r = {}; Object.defineProperty(r, "__esModule", { value: true }); var i = r.PrimaryGeneratedColumn = s; const a = e(); const n = t; function s(e, t) { const r = {}; let i; if (e) { if (typeof e === "string") i = e; if (n.ObjectUtils.isObject(e)) { i = "increment"; Object.assign(r, e); } } else { i = "increment"; } if (n.ObjectUtils.isObject(t)) Object.assign(r, t); return function(e, t) { if (!r.type) { if (i === "increment" || i === "identity") { r.type = Number; } else if (i === "uuid") { r.type = "uuid"; } else if (i === "rowid") { r.type = "int"; } } r.primary = true; (0, a.getMetadataArgsStorage)().columns.push({ target: e.constructor, propertyName: t, mode: "regular", options: r }); (0, a.getMetadataArgsStorage)().generations.push({ target: e.constructor, propertyName: t, strategy: i }); }; } export { i as P };