Queue with Page Include doesn't warn users if unsaved changes?

I think I got it, Rob!  Below is the snippet I have right now, which simply saves the model and then causes the page include to load the correct page.

var params = arguments[0], $ = skuid.$;
// save the model, in case there are changes waiting
skuid.model.getModelsByName().Contact.save();
// locate the Page Include and cause it to load the new contact by Id 
var includeObject = $(‘#Queue_Details’).data(‘object’);
includeObject.pagename = ‘BDR_Contact_Details’;
includeObject.querystring = ‘?id=’ + params.row.Id;
includeObject.load();

(where #Queue_Details is the ID I put on my Page Include object)

The last thing I will play with is detecting if the model is dirty (if model.hasChanged is true), and if so popping up a message asking if the user wants to save it.  If they cancel, I can simply not change the page include and they can continue editing.

Let me know if for any reason you think this is flawed.

Thanks as always…

- Chris