Hi,
I have an app that has multiple tables with ref columns. Itโs great for pulling info from other tables and associating records however Iโd like to prevent users from adding records to tables from within a ref column.
How can i ensure that the only way to add a record is from the recordโs original table?
@Asaf_Weis Hi Asaf, right now it is not possible to disable the add button in an inline ref view if the source table of this inline view allows adds. However, thereโs a work around. Instead of hooking the reverse ref column to the original table, you can hook it to a slice of this table instead. If the slice does not allow adds, the inline ref view also not allow add, and the add button will be disabled.
To do this, first create a slice of the table being referenced. Set the permission of the slice to not allow adds.
Next, open the column definition of the reverse ref column. The app formula of the column should look like this:
REF_ROWS(โName of referenced tableโ, โName of this tableโ)
Change this formula to the following:
REF_ROWS(โName of the sliceโ, โName of this tableโ)
Also in the column definition, the first entry in the ElementTypeQualifier of the column should look like this:
โReferencedTableNameโ: โName of referenced tableโ
In this entry, replace the name of the referenced table with the name of the slice as follows:
โReferencedTableNameโ: โName of the sliceโ
Make sure you do not change anything else in the ElementTypeQualifier of the column.
Finally, save your changes.
I have also found myself in a number of scenarios when I didnโt want to allow user to be able to add new row to the referrenced table right from the drop-down list.
I see the Ref column as relationship between 2 entities, so try to avoid using slice instead of table for a Ref column.
I understand that currently it is not possible, but the above workaround seems a little too much of an effort.
I wish there was an option to just remove this New button that by default is always there in the drop-down list.
Thanks,
I also thought i could do it using a vlookup in the table which would automatically fill in the ref field but have the dropdown as the selector.
User | Count |
---|---|
44 | |
34 | |
27 | |
23 | |
15 |