CoreCommunity ExtensionsIncubatorDistributionsTYPO3 4.5 ProjectsTYPO3 4.7 ProjectsTYPO3 6.0 ProjectsTYPO3 6.1 ProjectsTYPO3 6.2 Projects (+)

Lockadmin WIKI

Version 3 (Typoheads , 2009-04-08 16:13)

1 1
h1. Concept for Page/Record Locking in TYPO3
2 1
3 1
4 1
*Purpose & current situation:*
5 1
6 1
TYPO3 implements a "weak advisory record locking". That means whenever a TCE form edits a record it is marked as locked. But this locking is only shown as a warning to the user (the exclamation mark in the pagetree and the yellow field in the pagerecord with the warningtext). Neither the UI nor the API (TCE main) use this locking.
7 1
8 1
*Goal:*
9 1
10 1
Implement a true locking mechanism where editing of an unlocked record is not possible. The UI has to indicate that a record is locked and the API has to enforce it. Additionally it must be able to unlock a page. Locking a page locks the page record, the alternative language page records and all content records. Depending on the TCA configuration other records than tt_content records may be locked with the page.
11 1
12 1
Intelligent means lock managing must be implemented. An admin/user with the right permissons must be able to "break a lock" and after a certain amount of time the locks must expire (escalation handling). 
13 3 Typoheads
The UI must show the locking state of records in the page tree and the content frame (see Screenshots). A page can only be locked once.
14 1
15 1
*Changes to the API:*
16 1
17 1
* TCEmain must get a new command to lock a record. The locking of a page record automatically locks all dependent records (see above).
18 1
* TCEmain must get a new command to unlock a record.
19 1
* TCEmain must not update or delete a locked record.
20 1
* The lock table must be changed to contain the session id.
21 1
* The session clean up must have an option to clear all session locks on exit.
22 1
23 1
*Changes to the UI:*
24 1
25 1
Two possible modes of operation are possible: *explicit* and *implicit* locking. The former requires a user to explicitely lock a record by eg clicking a lock button/icon. The latter locks a record when the user clicks on a edit icon.
26 1
27 1
*Explicit locking:*
28 1
29 1
* In this mode the user has by default no edit icons for page related table (if they are shown the must be grayed out and inoperable). In the page tree and in web>page there is a "lock page" option.
30 1
* After locking a page, the UI shows the edit icons for all page related contents of the locked page (thus the complete page + tt_content records). Saving and closing the page does not change the locking state. A page is only unlocked after the user chooses the unlock option in the page tree or web>page.
31 1
* Non page related records (eg. tt_news records) are locked implicitely (see below). It may be possible to define other sets of related records where the locking of a "master record" locks related records (eg a shop where a product has a master records and any number of variant records). In this case web>list may either never show edit icons for the master record or use implicit locking.
32 1
* In this mode it is possible to let a user lock a page even when he navigates around in the page tree etc and closes the record.
33 1
34 1
*Implicit locking:*
35 1
36 1
* In this mode the edit icons show up as usual, but by choosing an edit option a record or a page is locked automatically. Choosing "close" unlocks the record again.
37 1
* In this mode not choosing close leads to a stale lock. The UI has no way to unlock a record besides clicking close.
38 1
39 1
*Features:*
40 1
41 1
* Locking-Manager (BE-Module): The admin must be able to list all locks (with user and session info) and to break a lock.
42 1
* Internal messaging system to communicate nearly real-time with other editors (not hidden in taskcenter, directly integrated) =>> this is postponed, move to an extra extension
43 1
44 2 Typoheads
More Info:
45 2 Typoheads
http://screens.typoheads.at/exts/locking/index.htm