Commit 2b9c1024 authored by Gabriel L. Oliveira's avatar Gabriel L. Oliveira

Improve "Change State" dialog, both layout and behaviour

* Update the checked items before showing the dialog box,
  * Fixing the problem where only the old marked items were presented.
* Apply same layout of UNG Documents listbox table
* Dynamize the dialog 'height'
parent d2c01f1b
......@@ -180,7 +180,7 @@ div.listbox-content table.listbox tbody tr td {\n
padding:2.2px;\n
}\n
\n
div.listbox-content tr {\n
div.listbox-content tr, div#change_state_dialog tr {\n
font-size:13px;\n
empty-cells:show;\n
white-space:nowrap;\n
......@@ -1151,13 +1151,16 @@ span#no-input-file {\n
cursor: pointer;\n
}\n
\n
\n
\n
\n
div#change_state_dialog {\n
display:none;\n
width: 480px !important;\n
width: inherit !important;\n
font-size: 14px;\n
padding-left: .3em;\n
overflow: auto;\n
}\n
\n
div#change_state_dialog table {\n
margin-left: 0;\n
}\n
\n
div.xunda {\n
......
......@@ -238,6 +238,23 @@ function displayDocumentTitle(title){\n
};\n
}\n
\n
// XXX: refactor to upgrade performance of \'updateListboxSelection\' function\n
function updateListboxSelection() {\n
var data_params = $(\'form#main_form\').serializeArray();\n
$(\'input[name="knowledge_pad_module_ung_knowledge_pad_ung_docs_listbox_content_listbox_uid:list"]\')\n
.each(function() {\n
data_params.push({\'name\': \'listbox_uid:list\',\n
\'value\': this.value,}\n
);\n
})\n
$.ajax({\n
async: false,\n
type: \'POST\',\n
url: \'Base_updateListboxSelection\',\n
data: $.param(data_params),\n
});\n
}\n
\n
$().ready(function(){\n
$("p.clear").remove();\n
if ($("a#login").html() != null){\n
......@@ -457,13 +474,8 @@ $().ready(function(){\n
.click(function(event){\n
event.preventDefault();\n
$("div#change_state_dialog").html(\'\');\n
$.ajax({\n
async: false,\n
url: \'WebSection_changeStateHelperUpdatePortalSelections\',\n
data: $("form#main_form").serialize(),\n
success: function(datax){\n
}\n
});\n
// update portal selections\n
updateListboxSelection();\n
$.ajax({\n
async: false,\n
url: \'erp5/Folder_viewWorkflowActionDialog\',\n
......@@ -497,8 +509,8 @@ $().ready(function(){\n
});\n
$("div#change_state_dialog").dialog({\n
autoOpen: false,\n
height: 400,\n
width: 600,\n
height: \'auto\',\n
width: 680,\n
modal:true,\n
buttons: {\n
\'Change State\': function() {\n
......@@ -531,7 +543,6 @@ $().ready(function(){\n
Cancel: function() {\n
$( this ).dialog("close");\n
},\n
\n
}\n
});\n
\n
......
2011-09-21 gabriel.oliveira
* Improve "Change State" dialog, both layout and behaviour
2011-09-21 gabriel.oliveira
* Add separation between current selected language and logged in user
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment