Topic: How do [location autocomplete] and [location name] interact?
I am using General Purpose Data Entry Forms / Sample with occurrences form and want to be able to provide a lits of sites with autocomplete, but also allow the user to enter a site that is not in the list.
If I have the following in the form structure
[location autocomplete]
@searchUpdatesSref=true
@lockable=true
@validation=["required"]
@extraParams={"website_id":113}
[spatial reference]
<button type="button" class="imp-sref-check">Check</button>
[map]
then any non-listed site name is not saved on submission.
If I add a 'location name' field to the form structure
[location autocomplete]
@searchUpdatesSref=true
@lockable=true
@validation=["required"]
@extraParams={"website_id":113}
[location name]
[spatial reference]
<button type="button" class="imp-sref-check">Check</button>
[map]
I get strange behaviour:
1) With an autocomplete site selected and a name provided in the 'location name', the 'location name' appears in the Sample Details location name on the warehouse, but the autocomplete site name shows in the verification 3 form 'Site name'.
2) With non-listed text entered in the autocomplete site field and a name provided in the 'location name', the 'location name' appears in the Sample Details location name on the warehouse and in the verification 3 form 'Site name'.
3) With non-listed text entered in the autocomplete site field and a nothing in the 'location name', nothing appears in the Sample Details location name on the warehouse or in the verification 3 form 'Site name'.
4) With an autocomplete site selected and nothing provided in the 'location name', nothing appears in the Sample Details location name on the warehouse, but the autocomplete site name shows in the verification 3 form 'Site name'.
Is there any way to make it work so that the user can use autocomplete or enter a non-listed place name and in both cases have the verification 3 form show what was entered?
Thanks, Chris
Garganey Consulting