Summary:
The simple dropdown version of parent selector in the "Navigation" tab of "Edit Content Page" does not update the field
Detailed Description:
The problem:
If the current user does not have "Manage All Content" or "Modify Any Page"
permissions, the parent selector in the "Navigation" tab of "Edit Content Page"
displays a simple dropdown version of permissible parents. The dropdown
correctly displays only the pages that the user owns or is an additional editor
of. Selecting another page (and applying the changes) has no effect, though.
The analysis and solution:
Function "_build_simple_select" of "jquery.cmsms_hierselector.js" defines the
"change" event handler, which should update the "parent_id" hidden field (as its
"build_smart_select" cousin does), but it does not do that. The fix is simple:
sel.on('change',function(){
var v = $(this).val();
self.data.hidden_e.val(v).change(); /* ADD THIS LINE -- copied from
"_build_smart_select" */
$(this).trigger('cmsms_formchange',{
'elem': $(this),
'value': v
});
});