orchid-orm 1.34.1 → 1.34.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +4 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +4 -2
- package/dist/index.mjs.map +1 -1
- package/dist/migrations.js +7 -4
- package/dist/migrations.js.map +1 -1
- package/dist/migrations.mjs +7 -4
- package/dist/migrations.mjs.map +1 -1
- package/package.json +5 -5
package/dist/index.js
CHANGED
|
@@ -1890,7 +1890,8 @@ const orchidORM = (_a, tables) => {
|
|
|
1890
1890
|
if (key[0] === "$") {
|
|
1891
1891
|
throw new Error(`Table class name must not start with $`);
|
|
1892
1892
|
}
|
|
1893
|
-
const
|
|
1893
|
+
const tableClass = tables[key];
|
|
1894
|
+
const table = tableClass.instance();
|
|
1894
1895
|
tableInstances[key] = table;
|
|
1895
1896
|
const options2 = __spreadProps(__spreadValues$1({}, commonOptions), {
|
|
1896
1897
|
schema: table.schema,
|
|
@@ -1900,7 +1901,8 @@ const orchidORM = (_a, tables) => {
|
|
|
1900
1901
|
snakeCase: table.snakeCase,
|
|
1901
1902
|
comment: table.comment,
|
|
1902
1903
|
noPrimaryKey: table.noPrimaryKey ? "ignore" : void 0,
|
|
1903
|
-
computed: table.computed
|
|
1904
|
+
computed: table.computed,
|
|
1905
|
+
nowSQL: tableClass.nowSQL
|
|
1904
1906
|
});
|
|
1905
1907
|
const dbTable = new pqb.Db(
|
|
1906
1908
|
adapter,
|