Date field is cleared from within repeat when record is opened from Inbox for editing

283
2
Jump to solution
02-15-2021 02:37 AM
SaraMiller
New Contributor III

I have created a survey with a date field within a repeat.  I intend for the record to be submitted and subsequently edited from the Inbox to add a new repeat record with a new date, but to prevent previous repeat records from being edited.  However, when I open a record from the Inbox to edit it, the date field in the previous repeat record is cleared, and it also doesn't allow me to re-enter the date because of the allowUpdates=false setting in the parameters.  Because the date field is required, it also does not let me add a new repeat record without the date field being completed.

I have set the parameters as 'query allowAdds=true allowUpdates=false'.

The date field within the repeat defaults to 'today()'.

Options are set to Enable Inbox folder, Allow inbox surveys to be viewed, and Allow inbox surveys to be edited.

Why is the date previously entered clearing from the field within the repeat?

0 Kudos
1 Solution

Accepted Solutions
SaraMiller
New Contributor III

Hi Ismael,

I have resolved this issue. 

I have two date fields - one with the default format that ESRI gives and a hidden one that re-formats the date value from that field to DD/MM/YYYY. 

In tidying up the column headers for the table, I mistakenly nulled the primary date field in the bind::esri::fieldType column in the XLSForm.  By excluding this field from the table in AGOL, it was unable to pull in a date previously entered into the repeat section when I opened the record to add a new repeat record.  

Solution:  I removed 'null' from this field and republished, and the date appears correctly within the repeat of a record opened and edited from the inbox.

Thank you for getting back to me, though!

View solution in original post

0 Kudos
2 Replies
IsmaelChivite
Esri Notable Contributor

Can you please share your XLSForm?

0 Kudos
SaraMiller
New Contributor III

Hi Ismael,

I have resolved this issue. 

I have two date fields - one with the default format that ESRI gives and a hidden one that re-formats the date value from that field to DD/MM/YYYY. 

In tidying up the column headers for the table, I mistakenly nulled the primary date field in the bind::esri::fieldType column in the XLSForm.  By excluding this field from the table in AGOL, it was unable to pull in a date previously entered into the repeat section when I opened the record to add a new repeat record.  

Solution:  I removed 'null' from this field and republished, and the date appears correctly within the repeat of a record opened and edited from the inbox.

Thank you for getting back to me, though!

0 Kudos