can't mark tasks as complete using the check mark

I am using task tables using pretty much the code found here: Page Not Found — Skuid v15.1.6 Documentation the green check box to mark tasks complete is not working. is there an issue with the code on this sample page?

Well the link in the tutorial to our page repository was old and moldy.  Here is a better link to a sample page that has the task table working correctly. 

https://github.com/skuidify/SamplePages/blob/master/pages/Opportunity%20Detail%20Starter%20Page

Let me know if this still gives you trouble. 


Hi Brandon, I just tested our sample page, and it is working. Try this one and see if it works: skuid.snippet.registerSnippet(‘tasks.markCompleted’,function(params){ // Mark all selected items as closed, // then save our 2 Tasks models var model = params.model, list = params.list, selectedItems = params.item ? [params.item] : list.getSelectedItems(); if (selectedItems.length === 1 && skuid.model.isNewId(selectedItems[0].row.Id)) { alert(‘Please finish creating this Task before marking it as completed.’); return; } $j.each(selectedItems,function(i,item){ model.updateRow(item.row,‘Status’,‘Completed’); }); // Block the list from having updates list.element.block({ css: list.blockUICSS, overlayCSS: list.blockOverlayCSS, message:‘Marking Tasks as Completed…’ }); var saveFinishes = model.save({callback: function(){ var updateFinishes = skuid.model.updateData([model,skuid.model.getModel(‘TaskHistory’)]); $j.when(updateFinishes).then( function(){ list.element.unblock(); }, function(){ list.element.unblock(); } ); } }); });

Hi Joel, I am working with Brandon on this and the code that we are using is exactly the same as you posted. It only works the first time. Could there be a caching issue here? We are using Chrome. Thanks!

Shanna or Brandon, are you guys seeing any javascript errors in the console when you run it the second time?

No. It just doesn’t seem to execute the second time.

Shanna, would you grant Skuid access so I can take a look at this? 

For me, the code posted on http://help.skuidify.com/m/supercharge-your-ui/l/107247-build-an-activities-related-list-tab works, but in Chrome I it hangs (item is marked complete, but page hands with gray overlay and words: “Marking tasks as completed”
In the console I get the error:

Uncaught TypeError: Converting circular structure to JSON skuid__SkuidJS:4

  • lskuid__SkuidJS:4
  • iskuid__SkuidJS:4
  • model.save.callbackUI?page=OpportunitiesTab:120
  • a.RemotingStubs.save.escapeskuid__SkuidJS:4
  • e.cbVFRemote.js:132
  • VFExt3.direct.RemotingProvider.VFExt3.extend.doCallbackVFRemote.js:99
  • VFExt3.direct.RemotingProvider.VFExt3.extend.onDataVFRemote.js:94
  • VFExt3.extend.handleResponseVFRemote.js:75
  • aVFRemote.js:39
  • (anonymous function)VFRemote.js:40

  • Is there anything you would suggest to make the page work?

    I had this issue and it was because I hadn’t linked the snippet to the correct model as referenced in the lower part of the snippet code (I was using a model named ‘Tasks’ rather than ‘TaskHistory’). Yours might be hanging for a different reason though…

    var saveFinishes = model.save({callback: function(){ var updateFinishes = skuid.model.updateData([model,skuid.model.getModel('<b>Tasks</b>')]); $j.when(updateFinishes).then( function(){ list.element.unblock(); }, function(){ list.element.unblock(); } ); } });<br>