Is it possible to give the admin or other users special rights so their work on a resource cannot be disturbed by other users leading to the message "Resource Locked by User XY"?
It seems there is a priority in our system concerning the user rights resulting in that some users can lock a resource for themself if another user is on the same site for the same time while other users will always be blocked and cannot block other users.
Does anybody know how to change the priorities for different users?
Letti
-
MODX Staff
- 10,725 Posts
Locks are created on a first-come, first-serve basis. There is no priority.
You can provide permissions for certain users to remove locks however.
Meanwhile I checked it several times. In our installation it doesn´t work on first-come, first-serve basis. Every time the second user blocks the first one. Is there a possibility to change this? Maybe in the settings?
-
☆ A M B ☆
- 24,524 Posts
This is done on the resource itself. If you have a resource open for editing it's locked for anyone else. This is not based on who logs in first. If you save a resource, and don't have the "continue editing" option selected, then if someone else opens the resource at that moment before you open it again it will be locked.
-
MODX Staff
- 10,725 Posts
Also, the locks last for a specific number of seconds, which you can specify via the System Setting lock_ttl (Resource Lock Time To Live). It defaults to 1440 seconds (about 24 minutes). After the ttl has expired and the Resource editor has not selected Cancel (Close in 2.2), the lock is lost and another user can acquire the lock before the editor can save. At that point, they will get a message that the Resource has been locked by another user.
I just tested it. And unfortunately a second user can de facto block a resource to the first user.
Where can I find lock_ttl? I didn´t see it in the settings (revo 2.1.3-pl traditional).
-
MODX Staff
- 10,725 Posts
Correct, I just explained how the second user would gain the lock after the first user's lock expires. If the lock_ttl setting (which is found under the "Back-end Manager" area) does not exist, you can add it.
Ok, this time-setting is missing. Maybe this is the reason for not working in our installation. I will add the parameter.
-
MODX Staff
- 10,725 Posts
FWIW, it defaults to 1440 seconds in the code regardless if the setting exists.
Ok. In this case do you have any other idea why the locking not works in our settings? A second user always directly locks the first user. It is only tested by User A and User B and also for User A and User C. Maybe there is something wrong in the settings for user A?