orchid-orm 1.9.19 → 1.9.21

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.mjs CHANGED
@@ -11,7 +11,8 @@ import { pluralize } from 'inflection';
11
11
  const createBaseTable = ({
12
12
  columnTypes: columnTypes$1,
13
13
  snakeCase,
14
- filePath
14
+ filePath,
15
+ nowSQL
15
16
  } = { columnTypes: columnTypes }) => {
16
17
  const ct = typeof columnTypes$1 === "function" ? columnTypes$1(columnTypes) : columnTypes$1 || columnTypes;
17
18
  filePath != null ? filePath : filePath = getCallerFilePath();
@@ -23,10 +24,11 @@ const createBaseTable = ({
23
24
  return create(
24
25
  ct,
25
26
  filePath,
26
- snakeCase
27
+ snakeCase,
28
+ nowSQL
27
29
  );
28
30
  };
29
- const create = (columnTypes, filePath, snakeCase) => {
31
+ const create = (columnTypes, filePath, snakeCase, nowSQL) => {
30
32
  var _a;
31
33
  const base = (_a = class {
32
34
  constructor() {
@@ -44,7 +46,7 @@ const create = (columnTypes, filePath, snakeCase) => {
44
46
  this.filePath = filePath2;
45
47
  }
46
48
  columnTypes[snakeCaseKey] = this.snakeCase;
47
- const shape = getColumnTypes(columnTypes, fn);
49
+ const shape = getColumnTypes(columnTypes, fn, nowSQL);
48
50
  if (this.snakeCase) {
49
51
  for (const key in shape) {
50
52
  const column = shape[key];
@@ -93,7 +95,7 @@ const create = (columnTypes, filePath, snakeCase) => {
93
95
  options
94
96
  };
95
97
  }
96
- }, _a.filePath = filePath, _a);
98
+ }, _a.filePath = filePath, _a.nowSQL = nowSQL, _a);
97
99
  base.prototype.columnTypes = columnTypes;
98
100
  return base;
99
101
  };