I am trying to create a POST redirect Mass Action button for a list. When I select records in my Skuid page and click the redirect mass action I created I get an error message “You must select at least one ‘In Progress’ document”. I have double checked and the records I am choosing are ‘In Progress’.
Maybe I am missing something that I need to update in the URL. Has anyone had success in creating a POST mass action list button?
This is the URL:https://ffbext.cs10.visual.force.com/apex/codabecashentrybulkposting?retURL=%2Fa1q%3Ffcf%3D00BU0000003AnRA%26rolodexIndex%3D-1%26page%3D1&wrapMassAction=1&scontrolCaching=1
Thank you!
Tami, see these posts. Visualforce interprets URL Parameters as POST data so all you need to do is send the right URL Parameters. If you are trying to pass in a list of Ids then you need to add a separate “ids” parameter for each Id, e.g. “/apex/codacashentrybulkposting?ids=0010000000111&ids=00100000000222” …
https://community.skuid.com/t/how-to-add-marketo-send-email-mass-action-to-a-skuid-tab…
https://community.skuid.com/t/mass-action-inline-javascript-on-related-list-for-drawlo…
Hi Zach,
Thanks for the quick reply. I followed your instructions and I have a new error.
“java.lang.IllegalArgumentException: id a1qU0000000KHk3IAGretURL=/a1q?fcf=00BU0000003AnRA&rolodexIndex=-1&page=1 must be 15 characters “
Here is what my in-line snippet looks like:
// Get the Ids of the selected items as an Array
var idsArray = skuid.$.map(argumentsu0].list.getSelectedItems(),function(item){
return item.row.Id;
});
// Convert this array to a comma-separated String
var idsString = idsArray.join(‘,’);
// POST to FF
window.top.location = “https://ffbext.cs10.visual.force.com/apex/codabecashentrybulkposting?ids=”+ idsString +”
?retURL=%2Fa1q%3Ffcf%3D00BU0000003AnRA%26rolodexIndex%3D-1%26page%3D1&wrapMassAction=1&scontrolCaching=1”;
I have this working now. The join for the ids couldn’t be ‘,’. I think that is what you were telling me in your original post but I wasn’t quite understanding. I would either get the 15 character error or only the first record would be posted. When I changed ‘,’ to ‘&ids=’ I was able to post all selected records.
Below is the final code.
// Get the Ids of the selected items as an Array
var idsArray = skuid.$.map(argumentsd0].list.getSelectedItems(),function(item){
return item.row.Id;
});
// Convert this array to a comma-separated String
var idsString = idsArray.join(‘&ids=’);
// POST to FF
window.top.location =“https://ffbext.cs10.visual.force.com/apex/codabecashentrybulkposting?ids=”+ idsString +“&retURL=%2Fa1q%3Ffcf%3D00BU0000003AnRA%26rolodexIndex%3D-1%26page%3D1&wrapMassAction=1&scontrolCaching=1”;
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.