mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-23 18:48:51 +02:00
N°4400 - Move inline JS functions to corresponding JS file
This commit is contained in:
@@ -24,6 +24,13 @@ function ShowAboutBox()
|
||||
});
|
||||
return false;
|
||||
}
|
||||
function ShowDebug()
|
||||
{
|
||||
if ($('#rawOutput > div').html() != '')
|
||||
{
|
||||
$('#rawOutput').dialog( {autoOpen: true, modal:false, width: '80%'});
|
||||
}
|
||||
}
|
||||
function ArchiveMode(bEnable)
|
||||
{
|
||||
var sPrevUrl = StripArchiveArgument(window.location.search);
|
||||
@@ -41,6 +48,31 @@ function StripArchiveArgument(sUrl)
|
||||
var res = sUrl.replace(/&with-archive=[01]/g, '');
|
||||
return res;
|
||||
}
|
||||
function goBack()
|
||||
{
|
||||
window.history.back();
|
||||
}
|
||||
function BackToDetails(sClass, id, sDefaultUrl, sOwnershipToken)
|
||||
{
|
||||
window.bInCancel = true;
|
||||
if (id > 0)
|
||||
{
|
||||
sToken = '';
|
||||
if (sOwnershipToken != undefined)
|
||||
{
|
||||
sToken = '&token='+sOwnershipToken;
|
||||
}
|
||||
window.location.href = AddAppContext(GetAbsoluteUrlAppRoot()+'pages/UI.php?operation=release_lock_and_details&class='+sClass+'&id='+id+sToken);
|
||||
}
|
||||
else
|
||||
{
|
||||
window.location.href = sDefaultUrl; // Already contains the context...
|
||||
}
|
||||
}
|
||||
function BackToList(sClass)
|
||||
{
|
||||
window.location.href = AddAppContext(GetAbsoluteUrlAppRoot()+'pages/UI.php?operation=search_oql&oql_class='+sClass+'&oql_clause=WHERE id=0');
|
||||
}
|
||||
|
||||
/**
|
||||
* A toolbox for common JS operations in the backoffice. Meant to be used by Combodo developers and the community.
|
||||
|
||||
Reference in New Issue
Block a user