Body: <p>I've set up a profile which contains a multi-record field and my users are having a hard time with it.</p>
  <p>If a user edits a regular field, but then adds/edits/deletes an item in the multi-record field before clicking &quot;Save&quot;, any edits in the other fields are not retained.  They have to enter their regular field data again and then click &quot;save&quot;. OR they click &quot;Save&quot; after their multi-record field confirms it has saved, and don't realize all their other edits have not been saved -- especially a problem in longer forms.</p>
  <p>I am running Civicrm 5.40.2 on Joomla 3.9.28, but I have also just reproduced this behavior on the Drupal demo at <a href="https://dmaster.demo.civicrm.org/" rel="nofollow noreferrer">https://dmaster.demo.civicrm.org/</a> (Profile &quot;Multi-Record Edit Test&quot; at <a href="https://dmaster.demo.civicrm.org/civicrm/profile/edit?gid=17&amp;reset=1" rel="nofollow noreferrer">https://dmaster.demo.civicrm.org/civicrm/profile/edit?gid=17&amp;reset=1</a> for as long as it stays up there)</p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2021-11-09T14:41:19.230Z
Comments.Text: Yes, I see what you mean.  The custom fields are saved separately from the rest of the profile fields. Maybe a jQuery check for changed fields to alert before moving away from the page would help?  Meanwhile, I'd add some wording alerting users.
Comments.UserDisplayName: Aidan
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2021-11-09T16:09:46.193Z
Comments.Text: Thanks very much for answering, Aidan, I was afraid of that.  Could you give me a clue as to where I would hook that jQuery check?  The only "moving away from the page" i see in this process is the "Save" action when the button is clicked -- but I guess the page is also reloaded when the custom fields are saved?  Should I put the jQuery in a custom profile template?
Comments.UserDisplayName: minbori
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2021-11-09T17:12:18.403Z
Comments.Text: Hopefully someone more familiar with the UI side of things will chime in...
Comments.UserDisplayName: Aidan
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2021-11-10T11:00:23.770Z
Comments.Text: Hmmm not so far :-)  Can you point me at least to where the appropriate documentation might be?
Comments.UserDisplayName: minbori
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2021-11-11T10:22:48.000Z
Comments.Text: Think I found it....if anyone's looking:  https://docs.civicrm.org/dev/en/latest/framework/ui/
Comments.UserDisplayName: minbori
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2021-11-11T10:30:07.270Z
Comments.Text: Also here: https://docs.civicrm.org/dev/en/latest/standards/javascript/
Comments.UserDisplayName: minbori
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2021-12-07T12:04:35.073Z
Comments.Text: @minbori - i think i have the same problem, did you manage to solve your issue. thanks
Comments.UserDisplayName: UKSGEVENTS
Tags: <profile><joomla><forms>
Title: In the Profile Form "edit" mode, why are edits to other fields lost when a multi-record field is updated?
ThreadText: # In the Profile Form "edit" mode, why are edits to other fields lost when a multi-record field is updated?
  
  (Asked by: username_0 on 2021-11-09)
  
  I've set up a profile which contains a multi-record field and my users are having a hard time with it.
  
  If a user edits a regular field, but then adds/edits/deletes an item in the multi-record field before clicking "Save", any edits in the other fields are not retained. They have to enter their regular field data again and then click "save". OR they click "Save" after their multi-record field confirms it has saved, and don't realize all their other edits have not been saved -- especially a problem in longer forms.
  
  I am running Civicrm 5.40.2 on Joomla 3.9.28, but I have also just reproduced this behavior on the Drupal demo at <https://dmaster.demo.civicrm.org/> (Profile "Multi-Record Edit Test" at <https://dmaster.demo.civicrm.org/civicrm/profile/edit?gid=17&reset=1> for as long as it stays up there)
  
  **Tags:** profile, joomla, forms
  
  > **Comments:**
  > **username_1**: Yes, I see what you mean.  The custom fields are saved separately from the rest of the profile fields. Maybe a jQuery check for changed fields to alert before moving away from the page would help?  Meanwhile, I'd add some wording alerting users.  
  > **username_0**: Thanks very much for answering, username_1, I was afraid of that.  Could you give me a clue as to where I would hook that jQuery check?  The only "moving away from the page" i see in this process is the "Save" action when the button is clicked -- but I guess the page is also reloaded when the custom fields are saved?  Should I put the jQuery in a custom profile template?  
  > **username_1**: Hopefully someone more familiar with the UI side of things will chime in...  
  > **username_0**: Hmmm not so far :-)  Can you point me at least to where the appropriate documentation might be?  
  > **username_0**: Think I found it....if anyone's looking:  https://docs.civicrm.org/dev/en/latest/framework/ui/  
  > **username_0**: Also here: https://docs.civicrm.org/dev/en/latest/standards/javascript/  
  > **username_2**: @username_0 - i think i have the same problem, did you manage to solve your issue. thanks  
  
  ---
  
  ## 0 answers
  
  