Merge branch 'zentaopms273_wyd' into 'master'

* fix bug #30748.

See merge request easycorp/zentaopms!6537
This commit is contained in:
王怡栋
2022-12-13 09:25:16 +00:00
3 changed files with 20 additions and 3 deletions
+2 -2
View File
@@ -1801,7 +1801,7 @@ class bug extends control
}
else
{
return print(js::closeModal('parent.parent'));
return print(js::closeModal('parent.parent', 'this', "typeof(parent.parent.setTitleWidth) == 'function' ? parent.parent.setTitleWidth() : parent.parent.location.reload()"));
}
}
if(defined('RUN_MODE') && RUN_MODE == 'api')
@@ -1988,7 +1988,7 @@ class bug extends control
}
else
{
return print(js::closeModal('parent.parent', 'this', "function(){parent.parent.location.reload();}"));
return print(js::closeModal('parent.parent', 'this', "typeof(parent.parent.setTitleWidth) == 'function' ? parent.parent.setTitleWidth() : parent.parent.location.reload()"));
}
}
if(defined('RUN_MODE') && RUN_MODE == 'api')
+1 -1
View File
@@ -1,6 +1,6 @@
$(function()
{
if($('#bugList thead th.c-title').width() < 150) $('#bugList thead th.c-title').width(150);
setTitleWidth();
/* The display of the adjusting sidebarHeader is synchronized with the sidebar. */
$(".sidebar-toggle").click(function()
+17
View File
@@ -985,3 +985,20 @@ function setBranchRelated(branchID, productID, num)
$.ajaxSettings.async = true;
}
}
/**
* Set title field width.
*
* @access public
* @return void
*/
function setTitleWidth()
{
if(window.config.currentMethod != 'browse') return false;
if($('#bugList thead th.c-title').width() < 150) $('#bugList thead th.c-title').width(150);
setTimeout(function()
{
if($('#bugList thead th.c-title').width() < 150) $('#bugList thead th.c-title').width(150);
}, 400)
}