is it possible to make a specific field writeable when empty or if its a amdin
so i want another user(editor) to be able to write if the field is stil empty
i wrote this for writeable if in that specific field:
null or userHasRole ("admin")
but it doesn't seem to work. the problem is that i invited editors and they can't edit the fields when they created a new record. the editor should be able to create a record(this is already good) and then be albe to fill in data only once
3 replies
-
This worked from me on the cloud version ..
DANGER.. for a regular user.. once the TAB off the field. it is locked.... If you want to keep it open until intentionally "saved" .. add a "Save" button and an attribute ..
-
oops.. here is the form.
-
very happy with your help! so this first one is working perfectly
let t := this;
t.Straatnaam = null or if 'Created on' + time(0, 15) < now() then
false
else
true or userHasRole("admin")
endnow i was wondering if i also could combine the timer with the modification_date if it was still null i've tried it like this (see below)but that doesn't seem to work. i just want to avoid the save button because then you would risk forgetting the save button and the field becomes always editeable. (correct me if i'm wrong i am just starting to understand the code writing)
let t := this; t.Straatnaam = if null then _md + time(0, 15) < now() or if 'Created on' + time(0, 15) < now() then
false
else
true or userHasRole("admin")
end
Content aside
- 5 yrs agoLast active
- 3Replies
- 1252Views