Page 1 of 1

Select widget, supress "Other/add New"

PostPosted: Mon Oct 17, 2011 12:35 pm
by jonbfl
In one of our applications, we don't want editors/preparers adding arbitrary codes (lookups) while using the Select Widget.

We have a controlled access app for editing tables.

What's the most straightforward way to disable all 'Other(Add)' functionality in a given app wherever the Select widget lookup is used?

I looked for a preference that might control this, but I must be barking up the wrong tree.

OK may have found it
http://xataface.com/wiki/fields.ini_file
editvalues? Used with select lists to allow users to add values to the select list. E.g. editvalues=1

- well wrongo - it does not seem to matter which value I have, 1 or 0 - I still get the 'other' option and it works...

fields.ini
Code: Select all
[codigo_pais]
widget:type = select
vocabulary = pais
editvalues = 0


I "thought" thi swould suppress the 'Other'

Thanks for any all all suggestions.

Re: Select widget, supress "Other/add New"

PostPosted: Sat Nov 19, 2011 2:06 am
by ctripp
This post may help as you could edit the select.php file (located in the/xataface/Dataface/FormTool folder) to make the change globally.
viewtopic.php?f=4&t=6411

However I think the preferred way to limit this functionality is with permissions.

-Clayton

Re: Select widget, supress "Other/add New"

PostPosted: Tue Nov 22, 2011 12:31 pm
by jonbfl
Thanks for that post -

LOL - I had concluded from Steve's silence this was a permissions issue, I simply have not had time to work it out (annual budgets, plus beta user training and documentation - all in two languages)

I'm going to tackle getting that 'right' after I get the folks working on meta-data table input.

Thanks again - and Happy Thanksgiving

8)

Re: Select widget, supress "Other/add New"

PostPosted: Tue Nov 22, 2011 3:36 pm
by shannah
Yes. Permissions is the best way to limit users from adding records. If you disable the new permission for the table from which the values in the select are retrieved, then you'll prevent them from adding new records.