@payloadcms/db-postgres 0.7.1 → 0.8.0
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/connect.js +1 -1
- package/dist/create.d.ts.map +1 -1
- package/dist/create.js +7 -9
- package/dist/createGlobal.d.ts +1 -1
- package/dist/createGlobal.d.ts.map +1 -1
- package/dist/createGlobal.js +8 -10
- package/dist/createGlobalVersion.d.ts +1 -1
- package/dist/createGlobalVersion.d.ts.map +1 -1
- package/dist/createGlobalVersion.js +12 -14
- package/dist/createMigration.js +1 -1
- package/dist/createVersion.d.ts.map +1 -1
- package/dist/createVersion.js +22 -19
- package/dist/deleteMany.js +6 -8
- package/dist/deleteOne.d.ts.map +1 -1
- package/dist/deleteOne.js +6 -3
- package/dist/deleteVersions.d.ts.map +1 -1
- package/dist/deleteVersions.js +7 -8
- package/dist/destroy.js +1 -1
- package/dist/find/buildFindManyArgs.js +3 -3
- package/dist/find/chainMethods.js +1 -1
- package/dist/find/findMany.js +2 -2
- package/dist/find/traverseFields.d.ts.map +1 -1
- package/dist/find/traverseFields.js +23 -11
- package/dist/find.d.ts.map +1 -1
- package/dist/find.js +10 -11
- package/dist/findGlobal.d.ts.map +1 -1
- package/dist/findGlobal.js +7 -9
- package/dist/findGlobalVersions.d.ts.map +1 -1
- package/dist/findGlobalVersions.js +7 -8
- package/dist/findOne.d.ts +1 -1
- package/dist/findOne.d.ts.map +1 -1
- package/dist/findOne.js +9 -10
- package/dist/findVersions.d.ts.map +1 -1
- package/dist/findVersions.js +7 -8
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +5 -1
- package/dist/init.d.ts.map +1 -1
- package/dist/init.js +28 -15
- package/dist/migrate.js +1 -1
- package/dist/migrateDown.js +1 -1
- package/dist/migrateFresh.js +1 -1
- package/dist/migrateRefresh.js +1 -1
- package/dist/migrateReset.js +1 -1
- package/dist/migrateStatus.js +1 -1
- package/dist/queries/buildAndOrConditions.js +1 -1
- package/dist/queries/buildQuery.js +1 -1
- package/dist/queries/createJSONQuery/convertPathToJSONTraversal.js +1 -1
- package/dist/queries/createJSONQuery/formatJSONPathSegment.js +1 -1
- package/dist/queries/createJSONQuery/index.js +1 -1
- package/dist/queries/getTableColumnFromPath.d.ts.map +1 -1
- package/dist/queries/getTableColumnFromPath.js +148 -42
- package/dist/queries/operatorMap.js +1 -1
- package/dist/queries/parseParams.js +1 -1
- package/dist/queries/sanitizeQueryValue.d.ts.map +1 -1
- package/dist/queries/sanitizeQueryValue.js +5 -2
- package/dist/queries/selectDistinct.js +1 -1
- package/dist/queryDrafts.d.ts.map +1 -1
- package/dist/queryDrafts.js +7 -8
- package/dist/schema/build.d.ts +2 -1
- package/dist/schema/build.d.ts.map +1 -1
- package/dist/schema/build.js +19 -14
- package/dist/schema/createIndex.js +1 -1
- package/dist/schema/getTableName.d.ts +32 -0
- package/dist/schema/getTableName.d.ts.map +1 -0
- package/dist/schema/getTableName.js +43 -0
- package/dist/schema/idToUUID.js +1 -1
- package/dist/schema/parentIDColumnMap.js +1 -1
- package/dist/schema/setColumnID.js +1 -1
- package/dist/schema/traverseFields.d.ts +2 -1
- package/dist/schema/traverseFields.d.ts.map +1 -1
- package/dist/schema/traverseFields.js +55 -17
- package/dist/schema/validateExistingBlockIsIdentical.d.ts +2 -1
- package/dist/schema/validateExistingBlockIsIdentical.d.ts.map +1 -1
- package/dist/schema/validateExistingBlockIsIdentical.js +12 -6
- package/dist/transactions/beginTransaction.js +1 -1
- package/dist/transactions/commitTransaction.js +1 -1
- package/dist/transactions/rollbackTransaction.js +1 -1
- package/dist/transform/read/hasManyNumber.js +1 -1
- package/dist/transform/read/hasManyText.js +1 -1
- package/dist/transform/read/index.js +1 -1
- package/dist/transform/read/relationship.js +1 -1
- package/dist/transform/read/traverseFields.js +1 -1
- package/dist/transform/write/array.js +1 -1
- package/dist/transform/write/blocks.d.ts +2 -2
- package/dist/transform/write/blocks.d.ts.map +1 -1
- package/dist/transform/write/blocks.js +4 -4
- package/dist/transform/write/index.js +1 -1
- package/dist/transform/write/numbers.js +1 -1
- package/dist/transform/write/relationships.js +1 -1
- package/dist/transform/write/selects.js +1 -1
- package/dist/transform/write/texts.js +1 -1
- package/dist/transform/write/traverseFields.d.ts +2 -2
- package/dist/transform/write/traverseFields.d.ts.map +1 -1
- package/dist/transform/write/traverseFields.js +34 -25
- package/dist/transform/write/types.js +1 -1
- package/dist/types.d.ts +13 -0
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js +1 -1
- package/dist/update.d.ts.map +1 -1
- package/dist/update.js +7 -4
- package/dist/updateGlobal.d.ts +1 -1
- package/dist/updateGlobal.d.ts.map +1 -1
- package/dist/updateGlobal.js +9 -11
- package/dist/updateGlobalVersion.d.ts.map +1 -1
- package/dist/updateGlobalVersion.js +9 -5
- package/dist/updateVersion.d.ts.map +1 -1
- package/dist/updateVersion.js +9 -5
- package/dist/upsertRow/deleteExistingArrayRows.js +1 -1
- package/dist/upsertRow/deleteExistingRowsByPath.js +1 -1
- package/dist/upsertRow/index.d.ts.map +1 -1
- package/dist/upsertRow/index.js +7 -6
- package/dist/upsertRow/insertArrays.d.ts.map +1 -1
- package/dist/upsertRow/insertArrays.js +3 -3
- package/dist/upsertRow/types.d.ts +1 -1
- package/dist/upsertRow/types.d.ts.map +1 -1
- package/dist/upsertRow/types.js +1 -1
- package/dist/utilities/appendPrefixToKeys.js +1 -1
- package/dist/utilities/createBlocksMap.js +1 -1
- package/dist/utilities/createMigrationTable.js +1 -1
- package/dist/utilities/createRelationshipMap.js +1 -1
- package/dist/utilities/hasLocalesTable.js +1 -1
- package/dist/utilities/isArrayOfRows.js +1 -1
- package/dist/utilities/migrationTableExists.js +1 -1
- package/dist/utilities/parseError.js +1 -1
- package/package.json +2 -2
package/dist/find/findMany.js
CHANGED
@@ -107,7 +107,7 @@ const findMany = async function find({ adapter, fields, limit: limitArg, locale,
|
|
107
107
|
findManyArgs.orderBy = orderBy.order(orderBy.column);
|
108
108
|
}
|
109
109
|
const findPromise = db.query[tableName].findMany(findManyArgs);
|
110
|
-
if (pagination !== false && (orderedIDs ? orderedIDs?.length
|
110
|
+
if (pagination !== false && (orderedIDs ? orderedIDs?.length <= limit : true)) {
|
111
111
|
const selectCountMethods = [];
|
112
112
|
joinAliases.forEach(({ condition, table })=>{
|
113
113
|
selectCountMethods.push({
|
@@ -175,4 +175,4 @@ const findMany = async function find({ adapter, fields, limit: limitArg, locale,
|
|
175
175
|
};
|
176
176
|
};
|
177
177
|
|
178
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uL3NyYy9maW5kL2ZpbmRNYW55LnRzIl0sInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB0eXBlIHsgRmluZEFyZ3MgfSBmcm9tICdwYXlsb2FkL2RhdGFiYXNlJ1xuaW1wb3J0IHR5cGUgeyBGaWVsZCwgUGF5bG9hZFJlcXVlc3QsIFR5cGVXaXRoSUQgfSBmcm9tICdwYXlsb2FkL3R5cGVzJ1xuXG5pbXBvcnQgeyBpbkFycmF5LCBzcWwgfSBmcm9tICdkcml6emxlLW9ybSdcblxuaW1wb3J0IHR5cGUgeyBQb3N0Z3Jlc0FkYXB0ZXIgfSBmcm9tICcuLi90eXBlcydcbmltcG9ydCB0eXBlIHsgQ2hhaW5lZE1ldGhvZHMgfSBmcm9tICcuL2NoYWluTWV0aG9kcydcblxuaW1wb3J0IGJ1aWxkUXVlcnkgZnJvbSAnLi4vcXVlcmllcy9idWlsZFF1ZXJ5J1xuaW1wb3J0IHsgc2VsZWN0RGlzdGluY3QgfSBmcm9tICcuLi9xdWVyaWVzL3NlbGVjdERpc3RpbmN0J1xuaW1wb3J0IHsgdHJhbnNmb3JtIH0gZnJvbSAnLi4vdHJhbnNmb3JtL3JlYWQnXG5pbXBvcnQgeyBidWlsZEZpbmRNYW55QXJncyB9IGZyb20gJy4vYnVpbGRGaW5kTWFueUFyZ3MnXG5pbXBvcnQgeyBjaGFpbk1ldGhvZHMgfSBmcm9tICcuL2NoYWluTWV0aG9kcydc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ts","sourceRoot":"","sources":["../../src/find/traverseFields.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;
|
1
|
+
{"version":3,"file":"traverseFields.d.ts","sourceRoot":"","sources":["../../src/find/traverseFields.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAI1C,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,UAAU,CAAA;AAK/C,KAAK,iBAAiB,GAAG;IACvB,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IACjC,OAAO,EAAE,eAAe,CAAA;IACxB,WAAW,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IACpC,gBAAgB,EAAE,MAAM,CAAA;IACxB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,MAAM,EAAE,KAAK,EAAE,CAAA;IACf,IAAI,EAAE,MAAM,CAAA;IACZ,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IACrC,iBAAiB,EAAE,MAAM,CAAA;CAC1B,CAAA;AAED,eAAO,MAAM,cAAc,gHAUxB,iBAAiB,4BAkKnB,CAAA"}
|
@@ -9,12 +9,7 @@ Object.defineProperty(exports, "traverseFields", {
|
|
9
9
|
}
|
10
10
|
});
|
11
11
|
const _types = require("payload/types");
|
12
|
-
const
|
13
|
-
function _interop_require_default(obj) {
|
14
|
-
return obj && obj.__esModule ? obj : {
|
15
|
-
default: obj
|
16
|
-
};
|
17
|
-
}
|
12
|
+
const _getTableName = require("../schema/getTableName");
|
18
13
|
const traverseFields = ({ _locales, adapter, currentArgs, currentTableName, depth, fields, path, topLevelArgs, topLevelTableName })=>{
|
19
14
|
fields.forEach((field)=>{
|
20
15
|
if (field.type === 'collapsible' || field.type === 'row') {
|
@@ -61,8 +56,20 @@ const traverseFields = ({ _locales, adapter, currentArgs, currentTableName, dept
|
|
61
56
|
],
|
62
57
|
with: {}
|
63
58
|
};
|
64
|
-
const arrayTableName =
|
65
|
-
|
59
|
+
const arrayTableName = (0, _getTableName.getTableName)({
|
60
|
+
adapter,
|
61
|
+
config: field,
|
62
|
+
parentTableName: currentTableName,
|
63
|
+
prefix: `${currentTableName}_${path}`
|
64
|
+
});
|
65
|
+
const arrayTableNameWithLocales = (0, _getTableName.getTableName)({
|
66
|
+
adapter,
|
67
|
+
config: field,
|
68
|
+
locales: true,
|
69
|
+
parentTableName: currentTableName,
|
70
|
+
prefix: `${currentTableName}_${path}`
|
71
|
+
});
|
72
|
+
if (adapter.tables[arrayTableNameWithLocales]) withArray.with._locales = _locales;
|
66
73
|
currentArgs.with[`${path}${field.name}`] = withArray;
|
67
74
|
traverseFields({
|
68
75
|
_locales,
|
@@ -107,8 +114,13 @@ const traverseFields = ({ _locales, adapter, currentArgs, currentTableName, dept
|
|
107
114
|
],
|
108
115
|
with: {}
|
109
116
|
};
|
110
|
-
const tableName =
|
111
|
-
|
117
|
+
const tableName = (0, _getTableName.getTableName)({
|
118
|
+
adapter,
|
119
|
+
config: block,
|
120
|
+
parentTableName: topLevelTableName,
|
121
|
+
prefix: `${topLevelTableName}_blocks_`
|
122
|
+
});
|
123
|
+
if (adapter.tables[`${tableName}${adapter.localesSuffix}`]) withBlock.with._locales = _locales;
|
112
124
|
topLevelArgs.with[blockKey] = withBlock;
|
113
125
|
traverseFields({
|
114
126
|
_locales,
|
@@ -147,4 +159,4 @@ const traverseFields = ({ _locales, adapter, currentArgs, currentTableName, dept
|
|
147
159
|
return topLevelArgs;
|
148
160
|
};
|
149
161
|
|
150
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uL3NyYy9maW5kL3RyYXZlcnNlRmllbGRzLnRzIl0sInNvdXJjZXNDb250ZW50IjpbIi8qIGVzbGludC1kaXNhYmxlIG5vLXBhcmFtLXJlYXNzaWduICovXG5pbXBvcnQgdHlwZSB7IE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nKSB7XG4gICAgICB0cmF2ZXJzZUZpZWxkcyh7XG4gICAgICAgIF9sb2NhbGVzLFxuICAgICAgICBhZGFwdGVyLFxuICAgICAgICBjdXJyZW50QXJncyxcbiAgICAgICAgY3VycmVudFRhYmxlTmFtZSxcbiAgICAgICAgZGVwdGgsXG4gICAgICAgIGZpZWxkczogZmllbGQuZmllbGRzLFxuICAgICAgICBwYXRoLFxuICAgICAgICB0b3BMZXZlbEFyZ3MsXG4gICAgICAgIHRvcExldmVsVGFibGVOYW1lLFxuICAgICAgfSlcblxuICAgICAgcmV0dXJuXG4gICAgfVxuXG4gICAgaWYgKGZpZWxkLnR5cGUgPT09ICd0YWJzJykge1xuICAgICAgZmllbGQudGFicy5mb3JFYWNoKCh0YWIpID0+IHtcbiAgICAgICAgY29uc3QgdGFiUGF0aCA9IHRhYkhhc05hbWUodGFiKSA/IGAke3BhdGh9JHt0YWIubmFtZX1fYCA6IHBhdGhcblxuICAgICAgICB0cmF2ZXJzZUZpZWxkcyh7XG4gICAgICAgICAgX2xvY2FsZXMsXG4gICAgICAgICAgYWRhcHRlcixcbiAgICAgICAgICBjdXJyZW50QXJncyxcbiAgICAgICAgICBjdXJyZW50VGFibGVOYW1lLFxuICAgICAgICAgIGRlcHRoLFxuICAgICAgICAgIGZpZWxkczogdGFiLmZpZWxkcyxcbiAgICAgICAgICBwYXRoOiB0YWJQYXRoLFxuICAgICAgICAgIHRvcExldmVsQXJncyxcbiAgICAgICAgICB0b3BMZXZlbFRhYmxlTmFtZSxcbiAgICAgICAgfSlcbiAgICAgIH0pXG5cbiAgICAgIHJldHVyblxuICAgIH1cblxuICAgIGlmIChmaWVsZEFmZmVjdHNEYXRhKGZpZWxkKSkge1xuICAgICAgc3dpdGNoIChmaWVsZC50eXBlKSB7XG4gICAgICAgIGNhc2UgJ2FycmF5Jzoge1xuICAgICAgICAgIGNvbnN0IHdpdGhBcnJheTogUmVzdWx0ID0ge1xuICAgICAgICAgICAgY29sdW1uczoge1xuICAgICAgICAgICAgICBfcGFyZW50SUQ6IGZhbHNlLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIG9yZGVyQnk6ICh7IF9vcmRlciB9LCB7IGFzYyB9KSA9PiBbYXNjKF9vcmRlcildLFxuICAgICAgICAgICAgd2l0aDoge30sXG4gICAgICAgICAgfVxuXG4gICAgICAgICAgY29uc3QgYXJyYXlUYWJsZU5hbWUgPSBgJHtjdXJyZW50VGFibGVOYW1lfV8ke3BhdGh9JHt0b1NuYWtlQ2FzZShmaWVsZC5uYW1lKX1gXG5cbiAgICAgICAgICBpZiAoYWRhcHRlci50YWJsZXNbYCR7YXJyYXlUYWJsZU5hbWV9X2xvY2FsZXNgXSkgd2l0aEFycmF5LndpdGguX2xvY2FsZXMgPSBfbG9jYWxlc1xuICAgICAgICAgIGN1cnJlbnRBcmdzLndpdGhbYCR7cGF0aH0ke2ZpZWxkLm5hbWV9YF0gPSB3aXRoQXJyYXlcblxuICAgICAgICAgIHRyYXZlcnNlRmllbGRzKHtcbiAgICAgICAgICAgIF9sb2NhbGVzLFxuICAgICAgICAgICAgYWRhcHRlcixcbiAgICAgICAgICAgIGN1cnJlbnRBcmdzOiB3aXRoQXJyYXksXG4gICAgICAgICAgICBjdXJyZW50VGFibGVOYW1lOiBhcnJheVRhYmxlTmFtZSxcbiAgICAgICAgICAgIGRlcHRoLFxuICAgICAgICAgICAgZmllbGRzOiBmaWVsZC5maWVsZHMsXG4gICAgICAgICAgICBwYXRoOiAnJyxcbiAgICAgICAgICAgIHRvcExldmVsQXJncyxcbiAgICAgICAgICAgIHRvcExldmVsVGFibGVOYW1lLFxuICAgICAgICAgIH0pXG5cbiAgICAgICAgICBicmVha1xuICAgICAgICB9XG5cbiAgICAgICAgY2FzZSAnc2VsZWN0Jzoge1xuICAgICAgICAgIGlmIChmaWVsZC5oYXNNYW55KSB7XG4gICAgICAgICAgICBjb25zdCB3aXRoU2VsZWN0OiBSZXN1bHQgPSB7XG4gICAgICAgICAgICAgIGNvbHVtbnM6IHtcbiAgICAgICAgICAgICAgICBpZDogZmFsc2UsXG4gICAgICAgICAgICAgICAgb3JkZXI6IGZhbHNlLFxuICAgICAgICAgICAgICAgIHBhcmVudDogZmFsc2UsXG4gICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgIG9yZGVyQnk6ICh7IG9yZGVyIH0sIHsgYXNjIH0pID0+IFthc2Mob3JkZXIpXSxcbiAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgY3VycmVudEFyZ3Mud2l0aFtgJHtwYXRofSR7ZmllbGQubmFtZX1gXSA9IHdpdGhTZWxlY3RcbiAgICAgICAgICB9XG5cbiAgICAgICAgICBicmVha1xuICAgICAgICB9XG5cbiAgICAgICAgY2FzZSAnYmxvY2tzJzpcbiAgICAgICAgICBmaWVsZC5ibG9ja3MuZm9yRWFjaCgoYmxvY2spID0+IHtcbiAgICAgICAgICAgIGNvbnN0IGJsb2NrS2V5ID0gYF9ibG9ja3NfJHtibG9jay5zbHVnfWBcblxuICAgICAgICAgICAgaWYgKCF0b3BMZXZlbEFyZ3NbYmxvY2tLZXldKSB7XG4gICAgICAgICAgICAgIGNvbnN0IHdpdGhCbG9jazogUmVzdWx0ID0ge1xuICAgICAgICAgICAgICAgIGNvbHVtbnM6IHtcbiAgICAgICAgICAgICAgICAgIF9wYXJlbnRJRDogZmFsc2UsXG4gICAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICAgICBvcmRlckJ5OiAoeyBfb3JkZXIgfSwgeyBhc2MgfSkgPT4gW2FzYyhfb3JkZXIpXSxcbiAgICAgICAgICAgICAgICB3aXRoOiB7fSxcbiAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgIGNvbnN0IHRhYmxlTmFtZSA9IGAke3RvcExldmVsVGFibGVOYW1lfV9ibG9ja3NfJHt0b1NuYWtlQ2FzZShibG9jay5zbHVnKX1gXG5cbiAgICAgICAgICAgICAgaWYgKGFkYXB0ZXIudGFibGVzW2Ake3RhYmxlTmFtZX1fbG9jYWxlc2BdKSB3aXRoQmxvY2sud2l0aC5fbG9jYWxlcyA9IF9sb2NhbGVzXG4gICAgICAgICAgICAgIHRvcExldmVsQXJncy53aXRoW2Jsb2NrS2V5XSA9IHdpdGhCbG9ja1xuXG4gICAgICAgICAgICAgIHRyYXZlcnNlRmllbGRzKHtcbiAgICAgICAgICAgICAgICBfbG9jYWxlcyxcbiAgICAgICAgICAgICAgICBhZGFwdGVyLFxuICAgICAgICAgICAgICAgIGN1cnJlbnRBcmdzOiB3aXRoQmxvY2ssXG4gICAgICAgICAgICAgICAgY3VycmVudFRhYmxlTmFtZTogdGFibGVOYW1lLFxuICAgICAgICAgICAgICAgIGRlcHRoLFxuICAgICAgICAgICAgICAgIGZpZWxkczogYmxvY2suZmllbGRzLFxuICAgICAgICAgICAgICAgIHBhdGg6ICcnLFxuICAgICAgICAgICAgICAgIHRvcExldmVsQXJncyxcbiAgICAgICAgICAgICAgICB0b3BMZXZlbFRhYmxlTmFtZSxcbiAgICAgICAgICAgICAgfSlcbiAgICAgICAgICAgIH1cbiAgICAgICAgICB9KVxuXG4gICAgICAgICAgYnJlYWtcblxuICAgICAgICBjYXNlICdncm91cCc6XG4gICAgICAgICAgdHJhdmVyc2VGaWVsZHMoe1xuICAgICAgICAgICAgX2xvY2FsZXMsXG4gICAgICAgICAgICBhZGFwdGVyLFxuICAgICAgICAgICAgY3VycmVudEFyZ3MsXG4gICAgICAgICAgICBjdXJyZW50VGFibGVOYW1lLFxuICAgICAgICAgICAgZGVwdGgsXG4gICAgICAgICAgICBmaWVsZHM6IGZpZWxkLmZpZWxkcyxcbiAgICAgICAgICAgIHBhdGg6IGAke3BhdGh9JHtmaWVsZC5uYW1lfV9gLFxuICAgICAgICAgICAgdG9wTGV2ZWxBcmdzLFxuICAgICAgICAgICAgdG9wTGV2ZWxUYWJsZU5hbWUsXG4gICAgICAgICAgfSlcblxuICAgICAgICAgIGJyZWFrXG5cbiAgICAgICAgZGVmYXVsdDoge1xuICAgICAg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VsZCkpIHtcbiAgICAgIHN3aXRjaCAoZmllbGQudHlwZSkge1xuICAgICAgICBjYXNlICdhcnJheSc6IHtcbiAgICAgICAgICBjb25zdCB3aXRoQXJyYXk6IFJlc3VsdCA9IHtcbiAgICAgICAgICAgIGNvbHVtbnM6IHtcbiAgICAgICAgICAgICAgX3BhcmVudElEOiBmYWxzZSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgICBvcmRlckJ5OiAoeyBfb3JkZXIgfSwgeyBhc2MgfSkgPT4gW2FzYyhfb3JkZXIpXSxcbiAgICAgICAgICAgIHdpdGg6IHt9LFxuICAgICAgICAgIH1cblxuICAgICAgICAgIGNvbnN0IGFycmF5VGFibGVOYW1lID0gZ2V0VGFibGVOYW1lKHtcbiAgICAgICAgICAgIGFkYXB0ZXIsXG4gICAgICAgICAgICBjb25maWc6IGZpZWxkLFxuICAgICAgICAgICAgcGFyZW50VGFibGVOYW1lOiBjdXJyZW50VGFibGVOYW1lLFxuICAgICAgICAgICAgcHJlZml4OiBgJHtjdXJyZW50VGFibGVOYW1lfV8ke3BhdGh9YCxcbiAgICAgICAgICB9KVxuXG4gICAgICAgICAgY29uc3QgYXJyYXlUYWJsZU5hbWVXaXRoTG9jYWxlcyA9IGdldFRhYmxlTmFtZSh7XG4gICAgICAgICAgICBhZGFwdGVyLFxuICAgICAgICAgICAgY29uZmlnOiBmaWVsZCxcbiAgICAgICAgICAgIGxvY2FsZXM6IHRydWUsXG4gICAgICAgICAgICBwYXJlbnRUYWJsZU5hbWU6IGN1cnJlbnRUYWJsZU5hbWUsXG4gICAgICAgICAgICBwcmVmaXg6IGAke2N1cnJlbnRUYWJsZU5hbWV9XyR7cGF0aH1gLFxuICAgICAgICAgIH0pXG5cbiAgICAgICAgICBpZiAoYWRhcHRlci50YWJsZXNbYXJyYXlUYWJsZU5hbWVXaXRoTG9jYWxlc10pIHdpdGhBcnJheS53aXRoLl9sb2NhbGVzID0gX2xvY2FsZXNcbiAgICAgICAgICBjdXJyZW50QXJncy53aXRoW2Ake3BhdGh9JHtmaWVsZC5uYW1lfWBdID0gd2l0aEFycmF5XG5cbiAgICAgICAgICB0cmF2ZXJzZUZpZWxkcyh7XG4gICAgICAgICAgICBfbG9jYWxlcyxcbiAgICAgICAgICAgIGFkYXB0ZXIsXG4gICAgICAgICAgICBjdXJyZW50QXJnczogd2l0aEFycmF5LFxuICAgICAgICAgICAgY3VycmVudFRhYmxlTmFtZTogYXJyYXlUYWJsZU5hbWUsXG4gICAgICAgICAgICBkZXB0aCxcbiAgICAgICAgICAgIGZpZWxkczogZmllbGQuZmllbGRzLFxuICAgICAgICAgICAgcGF0aDogJycsXG4gICAgICAgICAgICB0b3BMZXZlbEFyZ3MsXG4gICAgICAgICAgICB0b3BMZXZlbFRhYmxlTmFtZSxcbiAgICAgICAgICB9KVxuXG4gICAgICAgICAgYnJlYWtcbiAgICAgICAgfVxuXG4gICAgICAgIGNhc2UgJ3NlbGVjdCc6IHtcbiAgICAgICAgICBpZiAoZmllbGQuaGFzTWFueSkge1xuICAgICAgICAgICAgY29uc3Qgd2l0aFNlbGVjdDogUmVzdWx0ID0ge1xuICAgICAgICAgICAgICBjb2x1bW5zOiB7XG4gICAgICAgICAgICAgICAgaWQ6IGZhbHNlLFxuICAgICAgICAgICAgICAgIG9yZGVyOiBmYWxzZSxcbiAgICAgICAgICAgICAgICBwYXJlbnQ6IGZhbHNlLFxuICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgICBvcmRlckJ5OiAoeyBvcmRlciB9LCB7IGFzYyB9KSA9PiBbYXNjKG9yZGVyKV0sXG4gICAgICAgICAgICB9XG5cbiAgICAgICAgICAgIGN1cnJlbnRBcmdzLndpdGhbYCR7cGF0aH0ke2ZpZWxkLm5hbWV9YF0gPSB3aXRoU2VsZWN0XG4gICAgICAgICAgfVxuXG4gICAgICAgICAgYnJlYWtcbiAgICAgICAgfVxuXG4gICAgICAgIGNhc2UgJ2Jsb2Nrcyc6XG4gICAgICAgICAgZmllbGQuYmxvY2tzLmZvckVhY2goKGJsb2NrKSA9PiB7XG4gICAgICAgICAgICBjb25zdCBibG9ja0tleSA9IGBfYmxvY2tzXyR7YmxvY2suc2x1Z31gXG5cbiAgICAgICAgICAgIGlmICghdG9wTGV2ZWxBcmdzW2Jsb2NrS2V5XSkge1xuICAgICAgICAgICAgICBjb25zdCB3aXRoQmxvY2s6IFJlc3VsdCA9IHtcbiAgICAgICAgICAgICAgICBjb2x1bW5zOiB7XG4gICAgICAgICAgICAgICAgICBfcGFyZW50SUQ6IGZhbHNlLFxuICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgb3JkZXJCeTogKHsgX29yZGVyIH0sIHsgYXNjIH0pID0+IFthc2MoX29yZGVyKV0sXG4gICAgICAgICAgICAgICAgd2l0aDoge30sXG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICBjb25zdCB0YWJsZU5hbWUgPSBnZXRUYWJsZU5hbWUoe1xuICAgICAgICAgICAgICAgIGFkYXB0ZXIsXG4gICAgICAgICAgICAgICAgY29uZmlnOiBibG9jayxcbiAgICAgICAgICAgICAgICBwYXJlbnRUYWJsZU5hbWU6IHRvcExldmVsVGFibGVOYW1lLFxuICAgICAgICAgICAgICAgIHByZWZpeDogYCR7dG9wTGV2ZWxUYWJsZU5hbWV9X2Jsb2Nrc19gLFxuICAgICAgICAgICAgICB9KVxuXG4gICAgICAgICAgICAgIGlmIChhZGFwdGVyLnRhYmxlc1tgJHt0YWJsZU5hbWV9JHthZGFwdGVyLmxvY2FsZXNTdWZmaXh9YF0pXG4gICAgICAgICAgICAgICAgd2l0aEJsb2NrLndpdGguX2xvY2FsZXMgPSBfbG9jYWxlc1xuICAgICAgICAgICAgICB0b3BMZXZlbEFyZ3Mud2l0aFtibG9ja0tleV0gPSB3aXRoQmxvY2tcblxuICAgICAgICAgICAgICB0cmF2ZXJzZUZpZWxkcyh7XG4gICAgICAgICAgICAgICAgX2xvY2FsZXMsXG4gICAgICAgICAgICAgICAgYWRhcHRlcixcbiAgICAgICAgICAgICAgICBjdXJyZW50QXJnczogd2l0aEJsb2NrLFxuICAgICAgICAgICAgICAgIGN1cnJlbnRUYWJsZU5hbWU6IHRhYmxlTmFtZSxcbiAgICAgICAgICAgICAgICBkZXB0aCxcbiAgICAgICAgICAgICAgICBmaWVsZHM6IGJsb2NrLmZpZWxkcyxcbiAgICAgICAgICAgICAgICBwYXRoOiAnJyxcbiAgICAgICAgICAgICAgICB0b3BMZXZlbEFyZ3MsXG4gICAgICAgICAgICAgICAgdG9wTGV2ZWxUYWJsZU5hbWUsXG4gICAgICAgICAgICAgIH0pXG4gICAgICAgICAgICB9XG4gICAgICAgICAgfSlcblxuICAgICAgICAgIGJyZWFrXG5cbiAgICAgICAgY2FzZSAnZ3JvdXAnOlxuICAgICAgICAgIHRyYXZlcnNlRmllbGRzKHtcbiAgICAgICAgICAgIF9sb2NhbGVzLFxuICAgICAgICAgICAgYWRhcHRlcixcbiAgICAgICAgICAgIGN1cnJlbnRBcmdzLFxuICAgICAgICAgICAgY3VycmVudFRhYmxlTmFtZSxcbiAgICAgICAgICAgIGRlcHRoLFxuICAgICAgICAgICAgZmllbGRzOiBmaWVsZC5maWVsZHMsXG4gICAgICAgICAgICBwYXRoOiBgJHtwYXRofSR7ZmllbGQubmFtZX1fYCxcbiAgICAgICAgICAgIHRvcExldmVsQXJncyxcbiAgICAgICAgICAgIHRvcExldmVsVGFibGVOYW1lLFxuICAgICAgICAgIH0pXG5cbiAgICAgICAgICBicmVha1xuXG4gICAgICAgIGRlZmF1bHQ6IHtcbiAgICAgICAgICBicmVha1xuICAgICAgICB9XG4gICAgICB9XG4gICAgfVxuICB9KVxuXG4gIHJldHVybiB0b3BMZXZlbEFyZ3Ncbn1cbiJdLCJuYW1lcyI6WyJ0cmF2ZXJzZUZpZWxkcyIsIl9sb2NhbGVzIiwiYWRhcHRlciIsImN1cnJlbnRBcmdzIiwiY3VycmVudFRhYmxlTmFtZSIsImRlcHRoIiwiZmllb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EJ2QztnQ0FDQUMsUUFBUWtDLE1BQU1sQyxNQUFNO2dDQUNwQkMsTUFBTTtnQ0FDTkM7Z0NBQ0FDOzRCQUNGO3dCQUNGO29CQUNGO29CQUVBO2dCQUVGLEtBQUs7b0JBQ0hULGVBQWU7d0JBQ2JDO3dCQUNBQzt3QkFDQUM7d0JBQ0FDO3dCQUNBQzt3QkFDQUMsUUFBUUssTUFBTUwsTUFBTTt3QkFDcEJDLE1BQU0sQ0FBQyxFQUFFQSxLQUFLLEVBQUVJLE1BQU1NLElBQUksQ0FBQyxDQUFDLENBQUM7d0JBQzdCVDt3QkFDQUM7b0JBQ0Y7b0JBRUE7Z0JBRUY7b0JBQVM7d0JBQ1A7b0JBQ0Y7WUFDRjtRQUNGO0lBQ0Y7SUFFQSxPQUFPRDtBQUNUIn0=
|
package/dist/find.d.ts.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"find.d.ts","sourceRoot":"","sources":["../src/find.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAA;
|
1
|
+
{"version":3,"file":"find.d.ts","sourceRoot":"","sources":["../src/find.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAA;AAQ5C,eAAO,MAAM,IAAI,EAAE,IAgClB,CAAA"}
|
package/dist/find.js
CHANGED
@@ -8,28 +8,27 @@ Object.defineProperty(exports, "find", {
|
|
8
8
|
return find;
|
9
9
|
}
|
10
10
|
});
|
11
|
-
const _tosnakecase = /*#__PURE__*/ _interop_require_default(require("to-snake-case"));
|
12
11
|
const _findMany = require("./find/findMany");
|
13
|
-
|
14
|
-
|
15
|
-
default: obj
|
16
|
-
};
|
17
|
-
}
|
18
|
-
const find = async function find({ collection, limit: limitArg, locale, page = 1, pagination, req = {}, sort: sortArg, where: whereArg }) {
|
12
|
+
const _getTableName = require("./schema/getTableName");
|
13
|
+
const find = async function find({ collection, limit, locale, page = 1, pagination, req = {}, sort: sortArg, where }) {
|
19
14
|
const collectionConfig = this.payload.collections[collection].config;
|
20
15
|
const sort = typeof sortArg === 'string' ? sortArg : collectionConfig.defaultSort;
|
16
|
+
const tableName = (0, _getTableName.getTableName)({
|
17
|
+
adapter: this,
|
18
|
+
config: collectionConfig
|
19
|
+
});
|
21
20
|
return (0, _findMany.findMany)({
|
22
21
|
adapter: this,
|
23
22
|
fields: collectionConfig.fields,
|
24
|
-
limit
|
23
|
+
limit,
|
25
24
|
locale,
|
26
25
|
page,
|
27
26
|
pagination,
|
28
27
|
req,
|
29
28
|
sort,
|
30
|
-
tableName
|
31
|
-
where
|
29
|
+
tableName,
|
30
|
+
where
|
32
31
|
});
|
33
32
|
};
|
34
33
|
|
35
|
-
//# sourceMappingURL=data:application/json;base64,
|
34
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9maW5kLnRzIl0sInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB0eXBlIHsgRmluZCB9IGZyb20gJ3BheWxvYWQvZGF0YWJhc2UnXG5pbXBvcnQgdHlwZSB7IFBheWxvYWRSZXF1ZXN0LCBTYW5pdGl6ZWRDb2xsZWN0aW9uQ29uZmlnIH0gZnJvbSAncGF5bG9hZC90eXBlcydcblxuaW1wb3J0IHR5cGUgeyBQb3N0Z3Jlc0FkYXB0ZXIgfSBmcm9tICcuL3R5cGVzJ1xuXG5pbXBvcnQgeyBmaW5kTWFueSB9IGZyb20gJy4vZmluZC9maW5kTWFueSdcbmltcG9ydCB7IGdldFRhYmxlTmFtZSB9IGZyb20gJy4vc2NoZW1hL2dldFRhYmxlTmFtZSdcblxuZXhwb3J0IGNvbnN0IGZpbmQ6IEZpbmQgPSBhc3luYyBmdW5jdGlvbiBmaW5kKFxuICB0aGlzOiBQb3N0Z3Jlc0FkYXB0ZXIsXG4gIHtcbiAgICBjb2xsZWN0aW9uLFxuICAgIGxpbWl0L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JyYW5nZU1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7OyIsIm1hcHBpbmdzIjoiOzs7OytCQVFhQTs7O2VBQUFBOzs7MEJBSFk7OEJBQ0k7QUFFdEIsTUFBTUEsT0FBYSxlQUFlQSxLQUV2QyxFQUNFQyxVQUFVLEVBQ1ZDLEtBQUssRUFDTEMsTUFBTSxFQUNOQyxPQUFPLENBQUMsRUFDUkMsVUFBVSxFQUNWQyxNQUFNLENBQUMsQ0FBbUIsRUFDMUJDLE1BQU1DLE9BQU8sRUFDYkMsS0FBSyxFQUNOO0lBRUQsTUFBTUMsbUJBQThDLElBQUksQ0FBQ0MsT0FBTyxDQUFDQyxXQUFXLENBQUNYLFdBQVcsQ0FBQ1ksTUFBTTtJQUMvRixNQUFNTixPQUFPLE9BQU9DLFlBQVksV0FBV0EsVUFBVUUsaUJBQWlCSSxXQUFXO0lBQ2pGLE1BQU1DLFlBQVlDLElBQUFBLDBCQUFZLEVBQUM7UUFDN0JDLFNBQVMsSUFBSTtRQUNiSixRQUFRSDtJQUNWO0lBRUEsT0FBT1EsSUFBQUEsa0JBQVEsRUFBQztRQUNkRCxTQUFTLElBQUk7UUFDYkUsUUFBUVQsaUJBQWlCUyxNQUFNO1FBQy9CakI7UUFDQUM7UUFDQUM7UUFDQUM7UUFDQUM7UUFDQUM7UUFDQVE7UUFDQU47SUFDRjtBQUNGIn0=
|
package/dist/findGlobal.d.ts.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"findGlobal.d.ts","sourceRoot":"","sources":["../src/findGlobal.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;
|
1
|
+
{"version":3,"file":"findGlobal.d.ts","sourceRoot":"","sources":["../src/findGlobal.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAOlD,eAAO,MAAM,UAAU,EAAE,UA6BxB,CAAA"}
|
package/dist/findGlobal.js
CHANGED
@@ -8,16 +8,14 @@ Object.defineProperty(exports, "findGlobal", {
|
|
8
8
|
return findGlobal;
|
9
9
|
}
|
10
10
|
});
|
11
|
-
const _tosnakecase = /*#__PURE__*/ _interop_require_default(require("to-snake-case"));
|
12
11
|
const _findMany = require("./find/findMany");
|
13
|
-
|
14
|
-
|
15
|
-
default: obj
|
16
|
-
};
|
17
|
-
}
|
18
|
-
const findGlobal = async function findGlobal({ locale, req, slug, where }) {
|
12
|
+
const _getTableName = require("./schema/getTableName");
|
13
|
+
const findGlobal = async function findGlobal({ slug, locale, req, where }) {
|
19
14
|
const globalConfig = this.payload.globals.config.find((config)=>config.slug === slug);
|
20
|
-
const tableName = (0,
|
15
|
+
const tableName = (0, _getTableName.getTableName)({
|
16
|
+
adapter: this,
|
17
|
+
config: globalConfig
|
18
|
+
});
|
21
19
|
const { docs: [doc] } = await (0, _findMany.findMany)({
|
22
20
|
adapter: this,
|
23
21
|
fields: globalConfig.fields,
|
@@ -35,4 +33,4 @@ const findGlobal = async function findGlobal({ locale, req, slug, where }) {
|
|
35
33
|
return {};
|
36
34
|
};
|
37
35
|
|
38
|
-
//# sourceMappingURL=data:application/json;base64,
|
36
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9maW5kR2xvYmFsLnRzIl0sInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB0eXBlIHsgRmluZEdsb2JhbCB9IGZyb20gJ3BheWxvYWQvZGF0YWJhc2UnXG5cbmltcG9ydCB0eXBlIHsgUG9zdGdyZXNBZGFwdGVyIH0gZnJvbSAnLi90eXBlcydcblxuaW1wb3J0IHsgZmluZE1hbnkgfSBmcm9tICcuL2ZpbmQvZmluZE1hbnknXG5pbXBvcnQgeyBnZXRUYWJsZU5hbWUgfSBmcm9tICcuL3NjaGVtYS9nZXRUYWJsZU5hbWUnXG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2VNYXBwaW5ncyI6Ijs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7OyIsIm1hcHBpbmdzIjoiOzs7OytCQU9hQTs7O2VBQUFBOzs7MEJBSFk7OEJBQ0k7QUFFdEIsTUFBTUEsYUFBeUIsZUFBZUEsV0FFbkQsRUFBRUMsSUFBSSxFQUFFQyxNQUFNLEVBQUVDLEdBQUcsRUFBRUMsS0FBSyxFQUFFO0lBRTVCLE1BQU1DLGVBQWUsSUFBSSxDQUFDQyxPQUFPLENBQUNDLE9BQU8sQ0FBQ0MsTUFBTSxDQUFDQyxJQUFJLENBQUMsQ0FBQ0QsU0FBV0EsT0FBT1AsSUFBSSxLQUFLQTtJQUNsRixNQUFNUyxZQUFZQyxJQUFBQSwwQkFBWSxFQUFDO1FBQzdCQyxTQUFTLElBQUk7UUFDYkosUUFBUUg7SUFDVjtJQUVBLE1BQU0sRUFDSlEsTUFBTSxDQUFDQyxJQUFJLEVBQ1osR0FBRyxNQUFNQyxJQUFBQSxrQkFBUSxFQUFDO1FBQ2pCSCxTQUFTLElBQUk7UUFDYkksUUFBUVgsYUFBYVcsTUFBTTtRQUMzQkMsT0FBTztRQUNQZjtRQUNBZ0IsWUFBWTtRQUNaZjtRQUNBTztRQUNBTjtJQUNGO0lBRUEsSUFBSVUsS0FBSztRQUNQQSxJQUFJSyxVQUFVLEdBQUdsQjtRQUNqQixPQUFPYTtJQUNUO0lBRUEsT0FBTyxDQUFDO0FBQ1YifQ==
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"findGlobalVersions.d.ts","sourceRoot":"","sources":["../src/findGlobalVersions.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,kBAAkB,CAAA;AAU1D,eAAO,MAAM,kBAAkB,EAAE,
|
1
|
+
{"version":3,"file":"findGlobalVersions.d.ts","sourceRoot":"","sources":["../src/findGlobalVersions.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,kBAAkB,CAAA;AAU1D,eAAO,MAAM,kBAAkB,EAAE,kBAuChC,CAAA"}
|
@@ -9,17 +9,16 @@ Object.defineProperty(exports, "findGlobalVersions", {
|
|
9
9
|
}
|
10
10
|
});
|
11
11
|
const _versions = require("payload/versions");
|
12
|
-
const _tosnakecase = /*#__PURE__*/ _interop_require_default(require("to-snake-case"));
|
13
12
|
const _findMany = require("./find/findMany");
|
14
|
-
|
15
|
-
return obj && obj.__esModule ? obj : {
|
16
|
-
default: obj
|
17
|
-
};
|
18
|
-
}
|
13
|
+
const _getTableName = require("./schema/getTableName");
|
19
14
|
const findGlobalVersions = async function findGlobalVersions({ global, limit, locale, page, pagination, req = {}, skip, sort: sortArg, where }) {
|
20
15
|
const globalConfig = this.payload.globals.config.find(({ slug })=>slug === global);
|
21
16
|
const sort = typeof sortArg === 'string' ? sortArg : '-createdAt';
|
22
|
-
const tableName =
|
17
|
+
const tableName = (0, _getTableName.getTableName)({
|
18
|
+
adapter: this,
|
19
|
+
config: globalConfig,
|
20
|
+
versions: true
|
21
|
+
});
|
23
22
|
const fields = (0, _versions.buildVersionGlobalFields)(globalConfig);
|
24
23
|
return (0, _findMany.findMany)({
|
25
24
|
adapter: this,
|
@@ -36,4 +35,4 @@ const findGlobalVersions = async function findGlobalVersions({ global, limit, lo
|
|
36
35
|
});
|
37
36
|
};
|
38
37
|
|
39
|
-
//# sourceMappingURL=data:application/json;base64,
|
38
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9maW5kR2xvYmFsVmVyc2lvbnMudHMiXSwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHR5cGUgeyBGaW5kR2xvYmFsVmVyc2lvbnMgfSBmcm9tICdwYXlsb2FkL2RhdGFiYXNlJ1xuaW1wb3J0IHR5cGUgeyBQYXlsb2FkUmVxdWVzdCwgU2FuaXRpemVkR2xvYmFsQ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xJQUFJLENBQUNDLE9BQU8sQ0FBQ0MsT0FBTyxDQUFDQyxNQUFNLENBQUNDLElBQUksQ0FDMUUsQ0FBQyxFQUFFQyxJQUFJLEVBQUUsR0FBS0EsU0FBU2Y7SUFFekIsTUFBTU8sT0FBTyxPQUFPQyxZQUFZLFdBQVdBLFVBQVU7SUFFckQsTUFBTVEsWUFBWUMsSUFBQUEsMEJBQVksRUFBQztRQUM3QkMsU0FBUyxJQUFJO1FBQ2JMLFFBQVFIO1FBQ1JTLFVBQVU7SUFDWjtJQUNBLE1BQU1DLFNBQVNDLElBQUFBLGtDQUF3QixFQUFDWDtJQUV4QyxPQUFPWSxJQUFBQSxrQkFBUSxFQUFDO1FBQ2RKLFNBQVMsSUFBSTtRQUNiRTtRQUNBbkI7UUFDQUM7UUFDQUM7UUFDQUM7UUFDQUM7UUFDQUM7UUFDQUM7UUFDQVM7UUFDQVA7SUFDRjtBQUNGIn0=
|
package/dist/findOne.d.ts
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
import type { FindOneArgs } from 'payload/database';
|
2
2
|
import type { TypeWithID } from 'payload/types';
|
3
3
|
import type { PostgresAdapter } from './types';
|
4
|
-
export declare function findOne<T extends TypeWithID>(this: PostgresAdapter, { collection, locale, req, where
|
4
|
+
export declare function findOne<T extends TypeWithID>(this: PostgresAdapter, { collection, locale, req, where }: FindOneArgs): Promise<T>;
|
5
5
|
//# sourceMappingURL=findOne.d.ts.map
|
package/dist/findOne.d.ts.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"findOne.d.ts","sourceRoot":"","sources":["../src/findOne.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA;AACnD,OAAO,KAAK,EAA6C,UAAU,EAAE,MAAM,eAAe,CAAA;
|
1
|
+
{"version":3,"file":"findOne.d.ts","sourceRoot":"","sources":["../src/findOne.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA;AACnD,OAAO,KAAK,EAA6C,UAAU,EAAE,MAAM,eAAe,CAAA;AAE1F,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,SAAS,CAAA;AAK9C,wBAAsB,OAAO,CAAC,CAAC,SAAS,UAAU,EAChD,IAAI,EAAE,eAAe,EACrB,EAAE,UAAU,EAAE,MAAM,EAAE,GAA0B,EAAE,KAAK,EAAE,EAAE,WAAW,GACrE,OAAO,CAAC,CAAC,CAAC,CAqBZ"}
|
package/dist/findOne.js
CHANGED
@@ -8,15 +8,14 @@ Object.defineProperty(exports, "findOne", {
|
|
8
8
|
return findOne;
|
9
9
|
}
|
10
10
|
});
|
11
|
-
const _tosnakecase = /*#__PURE__*/ _interop_require_default(require("to-snake-case"));
|
12
11
|
const _findMany = require("./find/findMany");
|
13
|
-
|
14
|
-
|
15
|
-
default: obj
|
16
|
-
};
|
17
|
-
}
|
18
|
-
async function findOne({ collection, locale, req = {}, where: incomingWhere }) {
|
12
|
+
const _getTableName = require("./schema/getTableName");
|
13
|
+
async function findOne({ collection, locale, req = {}, where }) {
|
19
14
|
const collectionConfig = this.payload.collections[collection].config;
|
15
|
+
const tableName = (0, _getTableName.getTableName)({
|
16
|
+
adapter: this,
|
17
|
+
config: collectionConfig
|
18
|
+
});
|
20
19
|
const { docs } = await (0, _findMany.findMany)({
|
21
20
|
adapter: this,
|
22
21
|
fields: collectionConfig.fields,
|
@@ -26,10 +25,10 @@ async function findOne({ collection, locale, req = {}, where: incomingWhere }) {
|
|
26
25
|
pagination: false,
|
27
26
|
req,
|
28
27
|
sort: undefined,
|
29
|
-
tableName
|
30
|
-
where
|
28
|
+
tableName,
|
29
|
+
where
|
31
30
|
});
|
32
31
|
return docs?.[0] || null;
|
33
32
|
}
|
34
33
|
|
35
|
-
//# sourceMappingURL=data:application/json;base64,
|
34
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3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ztRQUNQYjtRQUNBYyxNQUFNO1FBQ05DLFlBQVk7UUFDWmQ7UUFDQWUsTUFBTUM7UUFDTlY7UUFDQUw7SUFDRjtJQUVBLE9BQU9RLE1BQU0sQ0FBQyxFQUFFLElBQUk7QUFDdEIifQ==
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"findVersions.d.ts","sourceRoot":"","sources":["../src/findVersions.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAA;AAUpD,eAAO,MAAM,YAAY,EAAE,
|
1
|
+
{"version":3,"file":"findVersions.d.ts","sourceRoot":"","sources":["../src/findVersions.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAA;AAUpD,eAAO,MAAM,YAAY,EAAE,YAqC1B,CAAA"}
|
package/dist/findVersions.js
CHANGED
@@ -9,17 +9,16 @@ Object.defineProperty(exports, "findVersions", {
|
|
9
9
|
}
|
10
10
|
});
|
11
11
|
const _versions = require("payload/versions");
|
12
|
-
const _tosnakecase = /*#__PURE__*/ _interop_require_default(require("to-snake-case"));
|
13
12
|
const _findMany = require("./find/findMany");
|
14
|
-
|
15
|
-
return obj && obj.__esModule ? obj : {
|
16
|
-
default: obj
|
17
|
-
};
|
18
|
-
}
|
13
|
+
const _getTableName = require("./schema/getTableName");
|
19
14
|
const findVersions = async function findVersions({ collection, limit, locale, page, pagination, req = {}, skip, sort: sortArg, where }) {
|
20
15
|
const collectionConfig = this.payload.collections[collection].config;
|
21
16
|
const sort = typeof sortArg === 'string' ? sortArg : collectionConfig.defaultSort;
|
22
|
-
const tableName =
|
17
|
+
const tableName = (0, _getTableName.getTableName)({
|
18
|
+
adapter: this,
|
19
|
+
config: collectionConfig,
|
20
|
+
versions: true
|
21
|
+
});
|
23
22
|
const fields = (0, _versions.buildVersionCollectionFields)(collectionConfig);
|
24
23
|
return (0, _findMany.findMany)({
|
25
24
|
adapter: this,
|
@@ -36,4 +35,4 @@ const findVersions = async function findVersions({ collection, limit, locale, pa
|
|
36
35
|
});
|
37
36
|
};
|
38
37
|
|
39
|
-
//# sourceMappingURL=data:application/json;base64,
|
38
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9maW5kVmVyc2lvbnMudHMiXSwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHR5cGUgeyBGaW5kVmVyc2lvbnMgfSBmcm9tICdwYXlsb2FkL2RhdGFiYXNlJ1xuaW1wb3J0IHR5cGUgeyBQYXlsb2FkUmVxdWVzdCwgU2FuaXRpemVkQ29sbGVjdGlvbkNvbmZpZyB9IGZyb20gJ3BheWxvYWQvdHlwZXMnXG5cbmltcG9ydCB7IGJ1aWxkVmVyc2lvbkNvbGxlY3Rpb25GaWVsZHMgfSBmcm9tICdwYXlsb2FkL3ZlcnNpb25zJ1xuXG5pbXBvcnQgdHlwZSB7IFBvc3RncmVzQWRhcHRlciB9IGZyb20gJy4vdHlwZXMnXG5cbmltcG9ydCB7IGZpbmRNYW55IH0gZnJvbSAnLi9maW5kL2ZpbmRNYW55J1xuaW1wb3J0IHsgZ2V0VGFibGVOYW1lIH0gZnJvbSAnLi9zY2hlbWEvZ2V0VGFibGVOYW1lJ1xuXG5leHBvcnQgY29uc3QgZmluZFZlcnNpb25zOiBGaW5kVmVyc2lvbnMgPSBhc3luYyBmdW5jdGlvbiBmaW5kVmVyc2lvbnMoXG4gIHRoaXM6IFBvc3RncmVzQWRhcHRlcixcbiAge1xuICAgIGNvbGxlY3Rpb24sXG4gICAgbGltaXQsXG4gICAgbG9jYWxlLFxuICAgIHBhZ2UsXG4gICAgcGFnaW5hdGlvbixcbiAgICByZXEgPSB7fSBhcyBQYXlsb2FkUmVxdWVzdCxcbiAgICBza2lwLFxuICAgIHNvcnQ6IHNvcnRBcmcsXG4gICAgd2hlcmUsXG4gIH0sXG4pIHtcbiAgY29uc3QgY29sbGVjdG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SAAS,CAAA;AAE7D,wBAAgB,eAAe,CAAC,IAAI,EAAE,IAAI,GAAG,qBAAqB,
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,IAAI,EAAmB,qBAAqB,EAAE,MAAM,SAAS,CAAA;AAiC3E,YAAY,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,SAAS,CAAA;AAE7D,wBAAgB,eAAe,CAAC,IAAI,EAAE,IAAI,GAAG,qBAAqB,CAoEjE"}
|
package/dist/index.js
CHANGED
@@ -53,20 +53,24 @@ function postgresAdapter(args) {
|
|
53
53
|
return (0, _database.createDatabaseAdapter)({
|
54
54
|
name: 'postgres',
|
55
55
|
// Postgres-specific
|
56
|
+
blockTableNames: {},
|
56
57
|
drizzle: undefined,
|
57
58
|
enums: {},
|
58
59
|
fieldConstraints: {},
|
59
60
|
idType,
|
61
|
+
localesSuffix: args.localesSuffix || '_locales',
|
60
62
|
logger: args.logger,
|
61
63
|
pgSchema: undefined,
|
62
64
|
pool: undefined,
|
63
65
|
poolOptions: args.pool,
|
64
66
|
push: args.push,
|
65
67
|
relations: {},
|
68
|
+
relationshipsSuffix: args.relationshipsSuffix || '_rels',
|
66
69
|
schema: {},
|
67
70
|
schemaName: args.schemaName,
|
68
71
|
sessions: {},
|
69
72
|
tables: {},
|
73
|
+
versionsSuffix: args.versionsSuffix || '_v',
|
70
74
|
// DatabaseAdapter
|
71
75
|
beginTransaction: _beginTransaction.beginTransaction,
|
72
76
|
commitTransaction: _commitTransaction.commitTransaction,
|
@@ -140,4 +144,4 @@ function postgresAdapter(args) {
|
|
140
144
|
return srcDir;
|
141
145
|
}
|
142
146
|
|
143
|
-
//# sourceMappingURL=data:application/json;base64,
|
147
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9pbmRleC50cyJdLCJzb3VyY2VzQ29udGVudCI6Wy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osS0FBSztJQUU3QyxzQkFBc0I7SUFDdEIsSUFBSXRELGNBQWMsT0FBT0E7SUFFekIsK0JBQStCO0lBQy9CLElBQUk2RCxXQUFFLENBQUNDLFVBQVUsQ0FBQ04sU0FBUztRQUN6QixPQUFPQTtJQUNUO0lBRUEsSUFBSUssV0FBRSxDQUFDQyxVQUFVLENBQUNILFVBQVU7UUFDMUIsT0FBT0E7SUFDVDtJQUVBLElBQUlFLFdBQUUsQ0FBQ0MsVUFBVSxDQUFDRixxQkFBcUI7UUFDckMsT0FBT0E7SUFDVDtJQUVBLE9BQU9KO0FBQ1QifQ==
|
package/dist/init.d.ts.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"init.d.ts","sourceRoot":"","sources":["../src/init.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAA;AAW5C,eAAO,MAAM,IAAI,EAAE,
|
1
|
+
{"version":3,"file":"init.d.ts","sourceRoot":"","sources":["../src/init.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAA;AAW5C,eAAO,MAAM,IAAI,EAAE,IA0FlB,CAAA"}
|