AkDk7
October 30, 2022, 7:17pm
1
I am using the self-hosted option in version 3.2.6 and Firefox in the newest version.
If I execute a javascript from a button and the row is manually locked (right click > lock row) the script is still able to update a linked record.
base.addLink(...)
rdb
October 30, 2022, 8:27pm
2
This is the desired behavior.
You can add a link to a locked row in the web interface too.
AkDk7
October 31, 2022, 8:02am
3
What is the reason behind this behavior?
The lock is used to prevent users from modify the records from UI.
For example, the admin of the base does not want the users to modify the rows directly, but let the user modify some fields via click a button.
AkDk7
November 1, 2022, 7:47am
5
I understand. But the lock is present if I want to update a non-link row by script. For example a normal text column. This is not possible unless I unlock the row, set the value by script and lock it again.
rdb
November 1, 2022, 8:41am
6
This is only true for JS. The same restriction does not apply for Python scripts.
AkDk7
November 1, 2022, 11:02am
7
Now I am completely confused.
rdb
November 1, 2022, 2:29pm
8
JS scripts are executed in the browser in the user context. Python scripts are executed on the server. Hence the different behavior.
1 Like
AkDk7
November 1, 2022, 2:49pm
9
That makes much more sense. Thank for the clarification!
1 Like
system
Closed
November 3, 2022, 2:50pm
10
This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.