lakutata
Version:
An IoC-based universal application framework.
42 lines (34 loc) • 1.38 kB
JavaScript
/* Build Date: Mon Jan 05 2026 23:52:23 GMT+0800 (China Standard Time) */
;
const e = require("./Package.internal.51.cjs");
var r = {};
Object.defineProperty(r, "__esModule", {
value: true
});
exports.Index_2 = r.Index = n;
const t = e.requireGlobals();
const s = e.ObjectUtils;
function n(e, r, n) {
const u = typeof e === "string" ? e : undefined;
const a = typeof e === "string" ? r : e;
let i = s.ObjectUtils.isObject(e) && !Array.isArray(e) ? e : n;
if (!i) i = s.ObjectUtils.isObject(r) && !Array.isArray(r) ? r : n;
return function(e, r) {
(0, t.getMetadataArgsStorage)().indices.push({
target: r ? e.constructor : e,
name: u,
columns: r ? [ r ] : a,
synchronize: i && i.synchronize === false ? false : true,
where: i ? i.where : undefined,
unique: i && i.unique ? true : false,
spatial: i && i.spatial ? true : false,
fulltext: i && i.fulltext ? true : false,
nullFiltered: i && i.nullFiltered ? true : false,
parser: i ? i.parser : undefined,
sparse: i && i.sparse ? true : false,
background: i && i.background ? true : false,
concurrent: i && i.concurrent ? true : false,
expireAfterSeconds: i ? i.expireAfterSeconds : undefined
});
};
}