app/views/module_projects/edit_module_project_view_config.js.erb
//Resize the modal width
$('.modal').on('show', function () {
$(this).css({
width:'auto',
'min-width':'600px',
'max-width':'100%'
//height:'auto', //probably not needed
//'max-height':'100%'
});
});
$("#notifications").html("");
$(".modal-body-inner").html("<%= j render(:partial => "module_project_view_configurations") %>");
$("#myModalLabel").css('font-size', 'larger');
$("#myModalLabel").html('<%= "#{@module_project} : #{I18n.t(:view_config)}" %>');
$("#edit_component").modal({
keyboard: false,
backdrop: "static",
backdrop: false
});
$("#table_module_view_list").hide();
$("#show_div_for_save_as").hide();
$("#save_as_view_button").attr('disabled', true);
$("#show_table_module_view_list").click(function(){
$("#table_module_view_list").show();
$("#show_div_for_save_as").hide();
$("#save_view_button").attr('disabled', false);
$("#save_as_view_button").attr('disabled', true);
});
$("#save_current_view_as").click(function(){
$("#show_div_for_save_as").show();
$("#table_module_view_list").hide();
//$("#show_table_module_view_list").hide();
$("#save_as_view_button").attr('disabled', false);
$("#save_view_button").attr('disabled', true);
})
$("#notifications").html("<%= j(render "layouts/notifications") %>");