Add lock NullValueBehavior ALLOW_WRITE_ONLY... fixes a case where audit couldn't be inserted

This commit is contained in:
2023-03-29 18:11:02 -05:00
parent b0d0c0ce6c
commit 037d67dd38
2 changed files with 5 additions and 1 deletions

View File

@ -326,7 +326,10 @@ public class InsertAction extends AbstractQActionFunction<InsertInput, InsertOut
{
for(QRecord inputRecord : inputRecords)
{
inputRecord.addError("You do not have permission to insert this record - the referenced " + leftMostJoinTable.getLabel() + " was not found.");
if(RecordSecurityLock.NullValueBehavior.DENY.equals(recordSecurityLock.getNullValueBehavior()))
{
inputRecord.addError("You do not have permission to insert this record - the referenced " + leftMostJoinTable.getLabel() + " was not found.");
}
}
}
}

View File

@ -60,6 +60,7 @@ public class RecordSecurityLock
public enum NullValueBehavior
{
ALLOW,
ALLOW_WRITE_ONLY, // not common - but see Audit, where you can do a thing that inserts them into a generic table, even though you can't later read them yourself...
DENY
}