orchid-orm 1.6.10 → 1.6.12

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.d.ts CHANGED
@@ -251,6 +251,7 @@ declare const createBaseTable: <CT extends ColumnTypesBase>(options?: {
251
251
  }) => Type)): pqb.JSONColumn<Type>;
252
252
  jsonText(this: ColumnTypesBase): pqb.JSONTextColumn;
253
253
  array<Item extends pqb.ColumnType<unknown, orchid_core.BaseOperators, unknown>>(this: ColumnTypesBase, item: Item): pqb.ArrayColumn<Item>;
254
+ domain(this: ColumnTypesBase, dataType: string): pqb.DomainColumn;
254
255
  primaryKey(columns: string[], options?: {
255
256
  name?: string | undefined;
256
257
  } | undefined): {};
@@ -361,6 +362,7 @@ declare const createBaseTable: <CT extends ColumnTypesBase>(options?: {
361
362
  }) => Type)): pqb.JSONColumn<Type>;
362
363
  jsonText(this: ColumnTypesBase): pqb.JSONTextColumn;
363
364
  array<Item extends pqb.ColumnType<unknown, orchid_core.BaseOperators, unknown>>(this: ColumnTypesBase, item: Item): pqb.ArrayColumn<Item>;
365
+ domain(this: ColumnTypesBase, dataType: string): pqb.DomainColumn;
364
366
  primaryKey(columns: string[], options?: {
365
367
  name?: string | undefined;
366
368
  } | undefined): {};
package/dist/index.js CHANGED
@@ -2125,6 +2125,9 @@ const getColumnMethodArgs = (t, to, key) => {
2125
2125
  if (key === "foreignKeys") {
2126
2126
  return pqb.columnForeignKeysToCode(value);
2127
2127
  }
2128
+ if (key === "check") {
2129
+ return [pqb.columnCheckToCode(t, value)];
2130
+ }
2128
2131
  const code = [`.${key}(`];
2129
2132
  if (key === "collate" || key === "compression") {
2130
2133
  orchidCore.addCode(code, orchidCore.singleQuote(value));