qRules repeating data RefreshListItems command - deleting first row does not delete record in SharePoint list - InfoPath Dev
in

InfoPath Dev

qRules repeating data RefreshListItems command - deleting first row does not delete record in SharePoint list

Last post 07-30-2016 11:32 AM by qRules is qool. 8 replies.
Page 1 of 1 (9 items)
Sort Posts: Previous Next
  • 12-28-2014 04:07 PM

    qRules repeating data RefreshListItems command - deleting first row does not delete record in SharePoint list

    Hi guys!

    First post here :) so first thing's first, thank you so much to everyone who worked on this excellent product!! I followed Hillary's (also excellent) guides to set up the SubmitToSharePointList and RefreshSharePointListItems commands. At first glance everything worked great:

     

    1. submit produced a new item in my SharePoint list and populated the ID field indicated in my mapping in the XML -> no problems yet

    2. updating the repeating data in the XML also updated the records in the SharePoint list and vice versa (updating list items updated the XML) -> no problems yet

    3. deleting rows in the repeating table appeared to work at first, but I noticed that if I deleted the first row in the XML, it did NOT delete in the SharePoint list. However any other deleted rows in the repeating table were successfully deleted in the SharePoint list.

     

    This is baffling me. I searched the forums and found only one other person who had the same issue as me:  http://www.infopathdev.com/forums/t/27950.aspx

     

    He/she says in the last post of the topic: "I resolved this by recreating the qrules mappings for all the Sharepoint lists using the InfoPath filler." I tried recreating the mapping several times and am having the same issue.

     

    What's baffling is everything is technically working, even deleting, except when deleting the first row of repeating data. I get no error message in the error field. If anyone wants to take a look at my form, I'd be happy to email it. It's 465KB though so I can't attach here because it exceeds the maximum allowed file size.

     

    Thank you in advance!

    Gene 

  • 01-02-2015 07:58 AM In reply to

    Re: qRules repeating data RefreshListItems command - deleting first row does not delete record in SharePoint list

    Hi - I'd be happy to look at your form (sorry for the slow reply, we've had a lot of people out for holidays). Send your form to Support AT Qdabra DOT com and include a link to this forum post - maybe throw in an "Attention Hilary" or something to make sure I see it. :)

    Hilary Stoupa

  • 03-14-2015 06:40 PM In reply to

    Re: qRules repeating data RefreshListItems command - deleting first row does not delete record in SharePoint list

    Hi!

    Just sent my form & mapping to the email address you provided. My company put my SharePoint project on hold until last week so I wasn't sure I'd be moving forward with it until now. Sorry for the delay.

    Thank you in advance for your help Hillary!  :)

  • 03-25-2015 07:20 AM In reply to

    Re: qRules repeating data RefreshListItems command - deleting first row does not delete record in SharePoint list

    Hi, Eugene -

    Thanks for bringing this to our attention and for your patience while we fixed it. I can confirm this was a bug in qRules 6.1 that has been addressed in the latest 7.1 builds.

    Hilary Stoupa

  • 07-25-2016 10:41 AM In reply to

    Re: qRules repeating data RefreshListItems command - deleting first row does not delete record in SharePoint list

    Hi,

    Can you please take a look at this bug again? I'm not sure if v7.2 changed something in regards to deleting nodes with RefreshSharePointListItems, but I just caught that two of my browser-enabled InfoPath forms are again not consistently deleting repeating nodes in the backend SharePoint list. (One form attached for reference.)Same detail as before when I first wrote this post - the refresh command is working perfectly for updates. If I add a repeating node, save, then update it & resave, I can see the update immediately upon refreshing the SharePoint list page that shows each repeating node as a separate record/item.

    The bug is more pervasive than last time - I believe originally it was only failing to delete when there was one last node to delete. Now it does not delete most of the time, regardless of if I try to delete all items, one item, etc. Sometimes it does go through, particularly if I add an item, save & close (instead of save), re-open the form, and then delete & save or save & close, there seems to be a higher probability of the node successfully deleting. Something about save & close and re-opening the form takes better with deletes. Again, this is totally unnecessary with updates - updates always execute correctly regardless of save or save & close and of how many updates I make in one save.

    Thank you in advance for looking into this.

    Eugene 

  • 07-26-2016 02:34 PM In reply to

    Re: qRules repeating data RefreshListItems command - deleting first row does not delete record in SharePoint list

    I'll take a look at this to see if I can reproduce items not deleting. Just to be very clear - Refresh creates a list of items that are currently in the form that have a SharePoint ID, based on the mapping. Then, when you Submit, if any items have been removed from the form, we delete them from the list. The two commands work together.
    Hilary Stoupa

  • 07-26-2016 02:58 PM In reply to

    Re: qRules repeating data RefreshListItems command - deleting first row does not delete record in SharePoint list

    Thanks for that explanation Hilary. So if my form uses a save button, should I also run the refresh command after submit to ensure that any updates made to the repeating data are captured in the list because when the refresh command was run at form load, those nodes/IDs didn't exist? It's interesting but the refresh command works for me for updates even in cases like this where the nodes were created, saved without closing the form and without rerunning the refresh command. Updates always work, so is the delete functionality in some way different. Also about Submit, does the command resubmit existing nodes, or is that functionality purely for the refresh command? Basically, if I add logic to only Submit new nodes without IDs, does that prevent Submit from functioning correctly? Doesn't seem like it would unless a node needs to be submitted to be refreshed. Thanks for helping me understand the basics of how the programming is set up!
  • 07-27-2016 08:07 AM In reply to

    Re: qRules repeating data RefreshListItems command - deleting first row does not delete record in SharePoint list

    No. Don't run the refresh command after submit. Only run refresh on the "finishedLoading" node in the qRules data source. For submit, the command resubmits nodes with a SharePoint ID as updates, and submits any without as new.
    Hilary Stoupa

  • 07-30-2016 11:32 AM In reply to

    Re: qRules repeating data RefreshListItems command - deleting first row does not delete record in SharePoint list

    Hi Hilary,

    Attached is my latest file that I reference in my email to you. I have a repeating field called Publish which is set to "Yes" based on rules for each repeating field in the node that determine if the repeating node should be submitted or refreshed.

    I then set my repeating group in the mapping to the following:  my:myFields/my:Budget/my:Budget_Section/my:Expense_Section/my:Expense_Fields[my:Publish = "Yes"]

    Right now I'm just testing on one particular mapping (Research-Equity), so my save and save & close buttons at the top are only configured to change the Research-Equity (called "re") mapping. This also requires the Primary Sponsor field near the top of the form to be Research-Equity.

    Lastly, the save button and finishedLoading field in the qRules data source have rules on save and on form load that set the Publish repeating field back to blank for all repeating nodes, so that the form is not resubmitting/refreshing fields that have not been updated each time the form is saved.

    As mentioned in the email, the performance is fantastic since the only repeating nodes that are submitted/refreshed are now the ones have been changed by the user.

    The issue is that previously submitted fields that were not updated by the user are being deleted. For example, add a repeating node, save & close, re-open the form, save or save & close again without making any changes, and the repeating node will disappear/be deleted from the SharePoint list. I believe this is happening because the refresh command thinks those nodes are gone now that they no longer have "Yes" in the Publish field.

    Is there a way I can work around this? This would be a fantastic workaround to lengthy save times/large repeating data structures if the refresh command would be smart enough not to touch nodes that are not updated. 

Page 1 of 1 (9 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.