@webiny/api-record-locking 6.2.0-beta.0 → 6.3.0-beta.0
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/features/GetLockRecord/feature.d.ts +4 -1
- package/features/GetLockedEntryLockRecord/feature.d.ts +4 -1
- package/features/IsEntryLocked/feature.d.ts +4 -1
- package/features/KickOutCurrentUser/feature.d.ts +4 -1
- package/features/ListAllLockRecords/feature.d.ts +4 -1
- package/features/ListLockRecords/abstractions.js.map +1 -1
- package/features/ListLockRecords/feature.d.ts +4 -1
- package/features/LockEntry/feature.d.ts +4 -1
- package/features/RecordLockingFeature.d.ts +4 -1
- package/features/RecordLockingFeature.js.map +1 -1
- package/features/UnlockEntry/feature.d.ts +4 -1
- package/features/UnlockEntryRequest/feature.d.ts +4 -1
- package/features/UpdateEntryLock/feature.d.ts +4 -1
- package/package.json +17 -17
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["createAbstraction","ListLockRecordsUseCase","ListLockRecordsRepository"],"sources":["abstractions.ts"],"sourcesContent":["import { createAbstraction, Result } from \"@webiny/feature/api\";\nimport type { ILockRecord } from \"~/domain/LockRecord.js\";\nimport type { LockRecordPersistenceError } from \"~/domain/errors.js\";\nimport type { CmsEntryListParams, CmsEntryMeta } from \"@webiny/api-headless-cms/types\";\nimport type {\n DateStringInterfaceGenerator,\n IdentityInterfaceGenerator,\n IdInterfaceGenerator\n} from \"@webiny/api\";\n\n// Input/Output types\nexport interface IListLockRecordsWhere\n extends
|
|
1
|
+
{"version":3,"names":["createAbstraction","ListLockRecordsUseCase","ListLockRecordsRepository"],"sources":["abstractions.ts"],"sourcesContent":["import { createAbstraction, Result } from \"@webiny/feature/api\";\nimport type { ILockRecord } from \"~/domain/LockRecord.js\";\nimport type { LockRecordPersistenceError } from \"~/domain/errors.js\";\nimport type { CmsEntryListParams, CmsEntryMeta } from \"@webiny/api-headless-cms/types\";\nimport type {\n DateStringInterfaceGenerator,\n IdentityInterfaceGenerator,\n IdInterfaceGenerator\n} from \"@webiny/api\";\n\n// Input/Output types\nexport interface IListLockRecordsWhere\n extends\n IdInterfaceGenerator<\"id\">,\n IdentityInterfaceGenerator<\"lockedBy\">,\n IdentityInterfaceGenerator<\"createdBy\">,\n DateStringInterfaceGenerator<\"lockedOn\">,\n DateStringInterfaceGenerator<\"updatedOn\">,\n DateStringInterfaceGenerator<\"savedOn\">,\n DateStringInterfaceGenerator<\"expiresOn\"> {}\n\nexport interface ListLockRecordsInput extends Pick<CmsEntryListParams, \"limit\" | \"sort\" | \"after\"> {\n where?: IListLockRecordsWhere;\n}\n\nexport interface ListLockRecordsOutput {\n items: ILockRecord[];\n meta: CmsEntryMeta;\n}\n\n/**\n * ListLockRecords Use Case - Lists active lock records (filters out expired, excludes current user)\n */\nexport interface IListLockRecordsUseCase {\n execute(input?: ListLockRecordsInput): Promise<Result<ListLockRecordsOutput, UseCaseError>>;\n}\n\nexport interface IListLockRecordsUseCaseErrors {\n persistence: LockRecordPersistenceError;\n}\n\ntype UseCaseError = IListLockRecordsUseCaseErrors[keyof IListLockRecordsUseCaseErrors];\n\nexport const ListLockRecordsUseCase =\n createAbstraction<IListLockRecordsUseCase>(\"ListLockRecordsUseCase\");\n\nexport namespace ListLockRecordsUseCase {\n export type Interface = IListLockRecordsUseCase;\n export type Error = UseCaseError;\n}\n\n/**\n * ListLockRecordsRepository - Fetches lock records from storage with filtering\n */\nexport interface IListLockRecordsRepository {\n execute(input?: ListLockRecordsInput): Promise<Result<ListLockRecordsOutput, RepositoryError>>;\n}\n\nexport interface IListLockRecordsRepositoryErrors {\n persistence: LockRecordPersistenceError;\n}\n\ntype RepositoryError = IListLockRecordsRepositoryErrors[keyof IListLockRecordsRepositoryErrors];\n\nexport const ListLockRecordsRepository = createAbstraction<IListLockRecordsRepository>(\n \"ListLockRecordsRepository\"\n);\n\nexport namespace ListLockRecordsRepository {\n export type Interface = IListLockRecordsRepository;\n export type Error = RepositoryError;\n}\n"],"mappings":"AAAA,SAASA,iBAAiB,QAAgB,qBAAqB;;AAU/D;;AAoBA;AACA;AACA;;AAWA,OAAO,MAAMC,sBAAsB,GAC/BD,iBAAiB,CAA0B,wBAAwB,CAAC;;AAOxE;AACA;AACA;;AAWA,OAAO,MAAME,yBAAyB,GAAGF,iBAAiB,CACtD,2BACJ,CAAC","ignoreList":[]}
|
|
@@ -9,4 +9,7 @@ export interface RecordLockingParams {
|
|
|
9
9
|
*/
|
|
10
10
|
model: CmsModel;
|
|
11
11
|
}
|
|
12
|
-
export declare const RecordLockingFeature:
|
|
12
|
+
export declare const RecordLockingFeature: {
|
|
13
|
+
name: string;
|
|
14
|
+
register(container: import("@webiny/di").Container, context: RecordLockingParams): void;
|
|
15
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["createFeature","RecordLockingConfig","RecordLockingModel","GetLockRecordFeature","GetLockedEntryLockRecordFeature","KickOutCurrentUserFeature","ListLockRecordsFeature","ListAllLockRecordsFeature","IsEntryLockedFeature","LockEntryFeature","UpdateEntryLockFeature","UnlockEntryFeature","UnlockEntryRequestFeature","RecordLockingFeature","name","register","container","params","registerInstance","timeout","model"],"sources":["RecordLockingFeature.ts"],"sourcesContent":["import { createFeature } from \"@webiny/feature/api\";\nimport type { CmsModel } from \"@webiny/api-headless-cms/types\";\nimport { RecordLockingConfig, RecordLockingModel } from \"~/domain/abstractions.js\";\nimport { GetLockRecordFeature } from \"./GetLockRecord/feature.js\";\nimport { GetLockedEntryLockRecordFeature } from \"./GetLockedEntryLockRecord/feature.js\";\nimport { KickOutCurrentUserFeature } from \"./KickOutCurrentUser/feature.js\";\nimport { ListLockRecordsFeature } from \"./ListLockRecords/feature.js\";\nimport { ListAllLockRecordsFeature } from \"./ListAllLockRecords/feature.js\";\nimport { IsEntryLockedFeature } from \"./IsEntryLocked/feature.js\";\nimport { LockEntryFeature } from \"./LockEntry/feature.js\";\nimport { UpdateEntryLockFeature } from \"./UpdateEntryLock/feature.js\";\nimport { UnlockEntryFeature } from \"./UnlockEntry/feature.js\";\nimport { UnlockEntryRequestFeature } from \"./UnlockEntryRequest/feature.js\";\n\nexport interface RecordLockingParams {\n /**\n * Timeout in milliseconds after which a lock expires\n */\n timeout: number;\n /**\n * The CMS model for storing lock records\n */\n model: CmsModel;\n}\n\nexport const RecordLockingFeature = createFeature({\n name: \"RecordLockingManagement\",\n register(container, params
|
|
1
|
+
{"version":3,"names":["createFeature","RecordLockingConfig","RecordLockingModel","GetLockRecordFeature","GetLockedEntryLockRecordFeature","KickOutCurrentUserFeature","ListLockRecordsFeature","ListAllLockRecordsFeature","IsEntryLockedFeature","LockEntryFeature","UpdateEntryLockFeature","UnlockEntryFeature","UnlockEntryRequestFeature","RecordLockingFeature","name","register","container","params","registerInstance","timeout","model"],"sources":["RecordLockingFeature.ts"],"sourcesContent":["import { createFeature } from \"@webiny/feature/api\";\nimport type { CmsModel } from \"@webiny/api-headless-cms/types\";\nimport { RecordLockingConfig, RecordLockingModel } from \"~/domain/abstractions.js\";\nimport { GetLockRecordFeature } from \"./GetLockRecord/feature.js\";\nimport { GetLockedEntryLockRecordFeature } from \"./GetLockedEntryLockRecord/feature.js\";\nimport { KickOutCurrentUserFeature } from \"./KickOutCurrentUser/feature.js\";\nimport { ListLockRecordsFeature } from \"./ListLockRecords/feature.js\";\nimport { ListAllLockRecordsFeature } from \"./ListAllLockRecords/feature.js\";\nimport { IsEntryLockedFeature } from \"./IsEntryLocked/feature.js\";\nimport { LockEntryFeature } from \"./LockEntry/feature.js\";\nimport { UpdateEntryLockFeature } from \"./UpdateEntryLock/feature.js\";\nimport { UnlockEntryFeature } from \"./UnlockEntry/feature.js\";\nimport { UnlockEntryRequestFeature } from \"./UnlockEntryRequest/feature.js\";\n\nexport interface RecordLockingParams {\n /**\n * Timeout in milliseconds after which a lock expires\n */\n timeout: number;\n /**\n * The CMS model for storing lock records\n */\n model: CmsModel;\n}\n\nexport const RecordLockingFeature = createFeature<RecordLockingParams>({\n name: \"RecordLockingManagement\",\n register(container, params) {\n // Register domain abstractions\n container.registerInstance(RecordLockingConfig, { timeout: params.timeout });\n container.registerInstance(RecordLockingModel, params.model);\n\n // Register all sub-features\n GetLockRecordFeature.register(container);\n GetLockedEntryLockRecordFeature.register(container);\n KickOutCurrentUserFeature.register(container);\n ListLockRecordsFeature.register(container);\n ListAllLockRecordsFeature.register(container);\n IsEntryLockedFeature.register(container);\n LockEntryFeature.register(container);\n UpdateEntryLockFeature.register(container);\n UnlockEntryFeature.register(container);\n UnlockEntryRequestFeature.register(container);\n }\n});\n"],"mappings":"AAAA,SAASA,aAAa,QAAQ,qBAAqB;AAEnD,SAASC,mBAAmB,EAAEC,kBAAkB;AAChD,SAASC,oBAAoB;AAC7B,SAASC,+BAA+B;AACxC,SAASC,yBAAyB;AAClC,SAASC,sBAAsB;AAC/B,SAASC,yBAAyB;AAClC,SAASC,oBAAoB;AAC7B,SAASC,gBAAgB;AACzB,SAASC,sBAAsB;AAC/B,SAASC,kBAAkB;AAC3B,SAASC,yBAAyB;AAalC,OAAO,MAAMC,oBAAoB,GAAGb,aAAa,CAAsB;EACnEc,IAAI,EAAE,yBAAyB;EAC/BC,QAAQA,CAACC,SAAS,EAAEC,MAAM,EAAE;IACxB;IACAD,SAAS,CAACE,gBAAgB,CAACjB,mBAAmB,EAAE;MAAEkB,OAAO,EAAEF,MAAM,CAACE;IAAQ,CAAC,CAAC;IAC5EH,SAAS,CAACE,gBAAgB,CAAChB,kBAAkB,EAAEe,MAAM,CAACG,KAAK,CAAC;;IAE5D;IACAjB,oBAAoB,CAACY,QAAQ,CAACC,SAAS,CAAC;IACxCZ,+BAA+B,CAACW,QAAQ,CAACC,SAAS,CAAC;IACnDX,yBAAyB,CAACU,QAAQ,CAACC,SAAS,CAAC;IAC7CV,sBAAsB,CAACS,QAAQ,CAACC,SAAS,CAAC;IAC1CT,yBAAyB,CAACQ,QAAQ,CAACC,SAAS,CAAC;IAC7CR,oBAAoB,CAACO,QAAQ,CAACC,SAAS,CAAC;IACxCP,gBAAgB,CAACM,QAAQ,CAACC,SAAS,CAAC;IACpCN,sBAAsB,CAACK,QAAQ,CAACC,SAAS,CAAC;IAC1CL,kBAAkB,CAACI,QAAQ,CAACC,SAAS,CAAC;IACtCJ,yBAAyB,CAACG,QAAQ,CAACC,SAAS,CAAC;EACjD;AACJ,CAAC,CAAC","ignoreList":[]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webiny/api-record-locking",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.3.0-beta.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"repository": {
|
|
@@ -13,30 +13,30 @@
|
|
|
13
13
|
],
|
|
14
14
|
"license": "MIT",
|
|
15
15
|
"dependencies": {
|
|
16
|
-
"@webiny/api": "6.
|
|
17
|
-
"@webiny/api-headless-cms": "6.
|
|
18
|
-
"@webiny/api-websockets": "6.
|
|
19
|
-
"@webiny/feature": "6.
|
|
20
|
-
"@webiny/handler": "6.
|
|
21
|
-
"@webiny/handler-aws": "6.
|
|
22
|
-
"@webiny/handler-graphql": "6.
|
|
23
|
-
"@webiny/plugins": "6.
|
|
24
|
-
"@webiny/utils": "6.
|
|
16
|
+
"@webiny/api": "6.3.0-beta.0",
|
|
17
|
+
"@webiny/api-headless-cms": "6.3.0-beta.0",
|
|
18
|
+
"@webiny/api-websockets": "6.3.0-beta.0",
|
|
19
|
+
"@webiny/feature": "6.3.0-beta.0",
|
|
20
|
+
"@webiny/handler": "6.3.0-beta.0",
|
|
21
|
+
"@webiny/handler-aws": "6.3.0-beta.0",
|
|
22
|
+
"@webiny/handler-graphql": "6.3.0-beta.0",
|
|
23
|
+
"@webiny/plugins": "6.3.0-beta.0",
|
|
24
|
+
"@webiny/utils": "6.3.0-beta.0"
|
|
25
25
|
},
|
|
26
26
|
"devDependencies": {
|
|
27
|
-
"@webiny/api-core": "6.
|
|
28
|
-
"@webiny/build-tools": "6.
|
|
29
|
-
"@webiny/project-utils": "6.
|
|
30
|
-
"@webiny/wcp": "6.
|
|
27
|
+
"@webiny/api-core": "6.3.0-beta.0",
|
|
28
|
+
"@webiny/build-tools": "6.3.0-beta.0",
|
|
29
|
+
"@webiny/project-utils": "6.3.0-beta.0",
|
|
30
|
+
"@webiny/wcp": "6.3.0-beta.0",
|
|
31
31
|
"graphql": "16.13.2",
|
|
32
32
|
"rimraf": "6.1.3",
|
|
33
|
-
"type-fest": "5.
|
|
34
|
-
"typescript": "
|
|
33
|
+
"type-fest": "5.6.0",
|
|
34
|
+
"typescript": "6.0.3",
|
|
35
35
|
"vitest": "4.1.4"
|
|
36
36
|
},
|
|
37
37
|
"publishConfig": {
|
|
38
38
|
"access": "public",
|
|
39
39
|
"directory": "dist"
|
|
40
40
|
},
|
|
41
|
-
"gitHead": "
|
|
41
|
+
"gitHead": "94c21e58aebc9855bf1ae972423281faa0f5c135"
|
|
42
42
|
}
|