mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-19 08:38:45 +02:00
N°6935 - Migrate relative images URLs to absolute ones in order to support pages on different depth levels
This commit is contained in:
@@ -326,6 +326,7 @@ class DataTable
|
||||
$sPagesLinks = implode('', $aPagesToDisplay);
|
||||
$sPagesList = '['.implode(',', array_keys($aPagesToDisplay)).']';
|
||||
|
||||
$sAppRootUrl = utils::GetAbsoluteUrlAppRoot();
|
||||
$sSelectionMode = ($iNbPages == 1) ? '' : 'positive';
|
||||
$sHtml =
|
||||
<<<EOF
|
||||
@@ -333,11 +334,11 @@ class DataTable
|
||||
<div $sPagerStyle>
|
||||
<table id="pager{$this->iListId}" class="pager"><tr>
|
||||
<td>$sPages</td>
|
||||
<td><img src="../images/first.png" class="first"/></td>
|
||||
<td><img src="../images/prev.png" class="prev"/></td>
|
||||
<td><img src="{$sAppRootUrl}images/first.png" class="first"/>AAAA</td>
|
||||
<td><img src="{$sAppRootUrl}images/prev.png" class="prev"/></td>
|
||||
<td><span id="index">$sPagesLinks</span></td>
|
||||
<td><img src="../images/next.png" class="next"/></td>
|
||||
<td><img src="../images/last.png" class="last"/></td>
|
||||
<td><img src="{$sAppRootUrl}images/next.png" class="next"/></td>
|
||||
<td><img src="{$sAppRootUrl}images/last.png" class="last"/></td>
|
||||
<td>$sPageSizeCombo</td>
|
||||
<td><span id="loading"> </span><input type="hidden" name="selectionMode" value="$sSelectionMode"></input>
|
||||
</td>
|
||||
|
||||
@@ -570,7 +570,7 @@ class DisplayBlock
|
||||
} else {
|
||||
// render it as an Ajax (asynchronous) call
|
||||
$oHtml->AddCSSClass("loading");
|
||||
$oHtml->AddHtml("<p><img src=\"../images/indicator_arrows.gif\"> ".Dict::S('UI:Loading').'</p>');
|
||||
$oHtml->AddHtml("<p><img src=\"".utils::GetAbsoluteUrlAppRoot()."images/indicator_arrows.gif\"> ".Dict::S('UI:Loading').'</p>');
|
||||
$oPage->add_script('
|
||||
$.post("ajax.render.php?style='.$this->m_sStyle.'",
|
||||
{ operation: "ajax", filter: "'.$sFilter.'", extra_params: "'.$sExtraParams.'" },
|
||||
|
||||
@@ -232,12 +232,13 @@ class DisplayTemplate
|
||||
static public function UnitTest()
|
||||
{
|
||||
require_once(APPROOT.'/application/startup.inc.php');
|
||||
|
||||
|
||||
$sAppRootUrl = utils::GetAbsoluteUrlAppRoot();
|
||||
$sTemplate = '<div class="page_header">
|
||||
<div class="actions_details"><a href="#"><span>Actions</span></a></div>
|
||||
<h1>$class$: <span class="hilite">$name$</span></h1>
|
||||
</div>
|
||||
<img src="../../images/connect_to_network.png" style="margin-top:-10px; margin-right:10px; float:right">
|
||||
<img src="'.$sAppRootUrl.'images/connect_to_network.png" style="margin-top:-10px; margin-right:10px; float:right">
|
||||
<itoptabs>
|
||||
<itoptab name="Interfaces">
|
||||
<itopblock blockclass="DisplayBlock" type="list" encoding="text/oql">SELECT Interface AS i WHERE i.device_id = $id$</itopblock>
|
||||
@@ -350,7 +351,8 @@ class ObjectDetailsTemplate extends DisplayTemplate
|
||||
if ($iFlags & OPT_ATT_SLAVE)
|
||||
{
|
||||
$iSynchroFlags = $this->m_oObj->GetSynchroReplicaFlags($sAttCode, $aReasons);
|
||||
$sSynchroIcon = " <img id=\"synchro_$iInputId\" src=\"../images/transp-lock.png\" style=\"vertical-align:middle\"/>";
|
||||
$sAppRooturl = utils::GetAbsoluteUrlAppRoot();
|
||||
$sSynchroIcon = " <img id=\"synchro_$iInputId\" src=\"{$sAppRooturl}images/transp-lock.png\" style=\"vertical-align:middle\"/>";
|
||||
$sTip = '';
|
||||
foreach($aReasons as $aRow)
|
||||
{
|
||||
|
||||
@@ -1446,7 +1446,7 @@ EOF
|
||||
<<<EOF
|
||||
function OnTruncatedHistoryToggle(bShowAll)
|
||||
{
|
||||
$('#csv_history_reload').html('<img src="../images/indicator.gif"/>');
|
||||
$('#csv_history_reload').html('<img src="' + GetAbsoluteUrlAppRoot() + 'images/indicator.gif"/>');
|
||||
$.get(GetAbsoluteUrlAppRoot()+'pages/ajax.render.php?{$sAppContext}', {operation: 'displayCSVHistory', showall: bShowAll}, function(data)
|
||||
{
|
||||
$('#$sAjaxDivId').html(data);
|
||||
|
||||
@@ -217,7 +217,7 @@ class ormStopWatch
|
||||
}
|
||||
else
|
||||
{
|
||||
$aProperties['Elapsed'] = 'running <img src="../images/indicator.gif">';
|
||||
$aProperties['Elapsed'] = 'running <img src="' . utils::GetAbsoluteUrlAppRoot() . 'images/indicator.gif">';
|
||||
}
|
||||
|
||||
$aProperties['Started'] = $oAttDef->SecondsToDate($this->iStarted);
|
||||
|
||||
@@ -185,6 +185,7 @@ abstract class AbstractAttachmentsRenderer
|
||||
{
|
||||
$sClass = $this->sObjClass;
|
||||
$sId = $this->iObjKey;
|
||||
$sAppRootUrl = utils::GetAbsoluteUrlAppRoot();
|
||||
$iMaxUploadInBytes = AttachmentPlugIn::GetMaxUploadSize();
|
||||
$sMaxUploadLabel = AttachmentPlugIn::GetMaxUpload();
|
||||
$sFileTooBigLabel = Dict::Format('Attachments:Error:FileTooLarge', $sMaxUploadLabel);
|
||||
@@ -195,7 +196,7 @@ abstract class AbstractAttachmentsRenderer
|
||||
$oAddButton = FileSelectUIBlockFactory::MakeStandard('file', 'file');
|
||||
$oAddButton->SetShowFilename(false);
|
||||
$this->oPage->AddUiBlock($oAddButton);
|
||||
$this->oPage->add('<span style="display:none;" id="attachment_loading"><img src="../images/indicator.gif"></span> '.$sMaxUploadLabel);
|
||||
$this->oPage->add('<span style="display:none;" id="attachment_loading"><img src="' . $sAppRootUrl . 'images/indicator.gif"></span> ' . $sMaxUploadLabel);
|
||||
$this->oPage->add('</div>');
|
||||
$this->oPage->add('<div class="ibo-attachment--upload-file--drop-zone-hint ibo-svg-illustration--container">');
|
||||
$this->oPage->add(file_get_contents(APPROOT.'images/illustrations/undraw_upload.svg'));
|
||||
@@ -342,7 +343,7 @@ abstract class AbstractAttachmentsRenderer
|
||||
$('.attachment a[href="'+sSrc+'"]').parent().addClass('image-in-use').find('img').wrap('<div class="image-in-use-wrapper" style="position:relative;display:inline-block;"></div>');
|
||||
});
|
||||
});
|
||||
$('.image-in-use-wrapper').append('<div style="position:absolute;top:0;left:0;"><img src="../images/transp-lock.png"></div>');
|
||||
$('.image-in-use-wrapper').append('<div style="position:absolute;top:0;left:0;"><img src="' + GetAbsoluteUrlModulesRoot() + 'images/transp-lock.png"></div>');
|
||||
}, 200 );
|
||||
JS
|
||||
);
|
||||
|
||||
@@ -651,7 +651,7 @@ try
|
||||
$oP->SetBreadCrumbEntry($sPageId, $sLabel, $sDescription, '', 'fas fa-search', iTopWebPage::ENUM_BREADCRUMB_ENTRY_ICON_TYPE_CSS_CLASSES);
|
||||
$oP->add("<div style=\"padding: 10px;\">\n");
|
||||
$oP->add("<div class=\"header_message\" id=\"full_text_progress\" style=\"position: fixed; background-color: #cccccc; opacity: 0.7; padding: 1.5em;\">\n");
|
||||
$oP->add('<img id="full_text_indicator" src="../images/indicator.gif"> <span style="padding: 1.5em;">'.Dict::Format('UI:Search:Ongoing', utils::EscapeHtml($sFullText)).'</span>');
|
||||
$oP->add('<img id="full_text_indicator" src="' . utils::GetAbsoluteUrlAppRoot() . 'images/indicator.gif"> <span style="padding: 1.5em;">'.Dict::Format('UI:Search:Ongoing', utils::EscapeHtml($sFullText)).'</span>');
|
||||
$oP->add("</div>\n");
|
||||
$oP->add("<div id=\"full_text_results\">\n");
|
||||
$oP->add("<div id=\"full_text_progress_placeholder\" style=\"padding: 1.5em;\"> </div>\n");
|
||||
@@ -703,7 +703,7 @@ try
|
||||
break;
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
/** @deprecated 3.1.0 Use the "object.new" route instead */
|
||||
// Kept for backward compatibility
|
||||
case 'new': // Form to create a new object
|
||||
|
||||
@@ -1375,7 +1375,7 @@ JS
|
||||
<<<EOF
|
||||
$('.search-class-$sClassName button').prop('disabled', true);
|
||||
|
||||
$('.search-class-$sClassName h2').append(' <img id="indicator" src="../images/indicator.gif">');
|
||||
$('.search-class-$sClassName h2').append(' <img id="indicator" src="' + GetAbsoluteUrlAppRoot() + 'images/indicator.gif">');
|
||||
var oParams = {operation: 'full_text_search_enlarge', class: '$sClassName', text: '$sFullTextJS'};
|
||||
$.post(GetAbsoluteUrlAppRoot()+'pages/ajax.render.php', oParams, function(data) {
|
||||
$('.search-class-$sClassName').html(data);
|
||||
@@ -1532,6 +1532,7 @@ EOF
|
||||
case 'xlsx_export_dialog':
|
||||
DeprecatedCallsLog::NotifyDeprecatedPhpEndpoint('Use "export_*" operations instead of "'.$operation.'"');
|
||||
$sFilter = utils::ReadParam('filter', '', false, 'raw_data');
|
||||
$sAppRootUrl = utils::GetAbsoluteUrlAppRoot();
|
||||
$oPage->SetContentType('text/html');
|
||||
$oPage->add(
|
||||
<<<EOF
|
||||
@@ -1561,11 +1562,11 @@ EOF
|
||||
padding-left: 16px;
|
||||
cursor: pointer;
|
||||
font-size: 10pt;
|
||||
background: url(../images/minus.gif) 0 2px no-repeat;
|
||||
background: url({$sAppRootUrl}images/minus.gif) 0 2px no-repeat;
|
||||
}
|
||||
.statistics > div.closed {
|
||||
padding-left: 16px;
|
||||
background: url(../images/plus.gif) 0 2px no-repeat;
|
||||
background: url({$sAppRootUrl}images/plus.gif) 0 2px no-repeat;
|
||||
}
|
||||
|
||||
.statistics .closed .stats-data {
|
||||
@@ -1594,7 +1595,7 @@ EOF
|
||||
);
|
||||
$sJSLabels = json_encode($aLabels);
|
||||
$sFilter = addslashes($sFilter);
|
||||
$sJSPageUrl = addslashes(utils::GetAbsoluteUrlAppRoot().'pages/ajax.render.php');
|
||||
$sJSPageUrl = addslashes($sAppRootUrl.'pages/ajax.render.php');
|
||||
$oPage->add_ready_script("$('#XlsxExportDlg').xlsxexporter({filter: '$sFilter', labels: $sJSLabels, ajax_page_url: '$sJSPageUrl'});");
|
||||
break;
|
||||
|
||||
@@ -2208,7 +2209,8 @@ EOF
|
||||
$oPage = new NiceWebPage(Dict::S('UI:BrowseInlineImages'));
|
||||
$oPage->add_linked_stylesheet(utils::GetAbsoluteUrlAppRoot().'css/magnific-popup.css');
|
||||
$oPage->add_linked_script(utils::GetAbsoluteUrlAppRoot().'js/jquery.magnific-popup.min.js');
|
||||
$sImgUrl = utils::GetAbsoluteUrlAppRoot().INLINEIMAGE_DOWNLOAD_URL;
|
||||
$sAppRootUrl = utils::GetAbsoluteUrlAppRoot();
|
||||
$sImgUrl = $sAppRootUrl.INLINEIMAGE_DOWNLOAD_URL;
|
||||
|
||||
/** @noinspection SuspiciousAssignmentsInspection cke_upload_and_browse and cke_browse are chained */
|
||||
$sTempId = utils::ReadParam('temp_id', '', false, 'transaction_id');
|
||||
@@ -2236,7 +2238,7 @@ EOF
|
||||
}
|
||||
}
|
||||
|
||||
$sPostUrl = utils::GetAbsoluteUrlAppRoot().'pages/ajax.render.php?CKEditorFuncNum='.$sCKEditorFuncNum;
|
||||
$sPostUrl = $sAppRootUrl.'pages/ajax.render.php?CKEditorFuncNum='.$sCKEditorFuncNum;
|
||||
|
||||
$oPage->add_style(
|
||||
<<<EOF
|
||||
@@ -2304,7 +2306,7 @@ EOF
|
||||
$oPage->add_ready_script(
|
||||
<<<EOF
|
||||
$('#upload_button').on('change', function() {
|
||||
$('#upload_status').html('<img src="../images/indicator.gif">');
|
||||
$('#upload_status').html('<img src="{$sAppRootUrl}images/indicator.gif">');
|
||||
$('#upload_form').submit();
|
||||
$(this).prop('disabled', true);
|
||||
});
|
||||
|
||||
@@ -281,7 +281,7 @@ try
|
||||
$oAllCategoriesDashlet
|
||||
->AddCSSClasses(['ibo-dashlet--is-inline', 'ibo-dashlet-badge'])
|
||||
->AddSubBlock(DashletFactory::MakeForDashletBadge(
|
||||
'../images/icons/icons8-audit.svg',
|
||||
utils::GetAbsoluteUrlAppRoot().'images/icons/icons8-audit.svg',
|
||||
utils::GetAbsoluteUrlAppRoot()."pages/audit.php?operation=audit",
|
||||
$iCategoryCount,
|
||||
Dict::S('UI:Audit:Interactive:Selection:BadgeAll')
|
||||
@@ -304,7 +304,7 @@ try
|
||||
/** @var AuditDomain $oAuditDomain */
|
||||
while($oAuditDomain = $oDomainSet->Fetch()) {
|
||||
$sDomainUrl = utils::GetAbsoluteUrlAppRoot()."pages/audit.php?operation=audit&domain=".$oAuditDomain->GetKey();
|
||||
$sIconUrl = '../images/icons/icons8-puzzle.svg';
|
||||
$sIconUrl = utils::GetAbsoluteUrlAppRoot().'images/icons/icons8-puzzle.svg';
|
||||
/** @var \ormDocument $oImage */
|
||||
$oImage = $oAuditDomain->Get('icon');
|
||||
if (!$oImage->IsEmpty()) {
|
||||
@@ -357,9 +357,9 @@ try
|
||||
$oP->AddUiBlock(TitleUIBlockFactory::MakeForPage($sTitle));
|
||||
$oP->AddUiBlock(new Text($sSubTitle));
|
||||
|
||||
$oTotalBlock = DashletFactory::MakeForDashletBadge('../images/icons/icons8-audit.svg', '#', 0, Dict::S('UI:Audit:Dashboard:ObjectsAudited'));
|
||||
$oErrorBlock = DashletFactory::MakeForDashletBadge('../images/icons/icons8-delete.svg', '#', 0, Dict::S('UI:Audit:Dashboard:ObjectsInError'));
|
||||
$oWorkingBlock = DashletFactory::MakeForDashletBadge('../images/icons/icons8-checkmark.svg', '#', 0, Dict::S('UI:Audit:Dashboard:ObjectsValidated'));
|
||||
$oTotalBlock = DashletFactory::MakeForDashletBadge(utils::GetAbsoluteUrlAppRoot().'images/icons/icons8-audit.svg', '#', 0, Dict::S('UI:Audit:Dashboard:ObjectsAudited'));
|
||||
$oErrorBlock = DashletFactory::MakeForDashletBadge(utils::GetAbsoluteUrlAppRoot().'images/icons/icons8-delete.svg', '#', 0, Dict::S('UI:Audit:Dashboard:ObjectsInError'));
|
||||
$oWorkingBlock = DashletFactory::MakeForDashletBadge(utils::GetAbsoluteUrlAppRoot().'images/icons/icons8-checkmark.svg', '#', 0, Dict::S('UI:Audit:Dashboard:ObjectsValidated'));
|
||||
|
||||
$aCSSClasses = ['ibo-dashlet--is-inline', 'ibo-dashlet-badge'];
|
||||
|
||||
@@ -436,7 +436,7 @@ try
|
||||
foreach ($aErrors as $aErrorRow) {
|
||||
$aObjectsWithErrors[$aErrorRow['id']] = true;
|
||||
}
|
||||
$aRow['nb_errors'] = ($iErrorsCount == 0) ? '0' : "<a href=\"?operation=errors&category=".$oAuditCategory->GetKey()."&rule=".$oAuditRule->GetKey()."&".$oAppContext->GetForLink()."\">$iErrorsCount</a> <a href=\"?operation=csv&category=".$oAuditCategory->GetKey()."&rule=".$oAuditRule->GetKey()."&".$oAppContext->GetForLink()."\"><img src=\"../images/icons/icons8-export-csv.svg\" class=\"ibo-audit--audit-line--csv-download\"></a>";
|
||||
$aRow['nb_errors'] = ($iErrorsCount == 0) ? '0' : "<a href=\"?operation=errors&category=".$oAuditCategory->GetKey()."&rule=".$oAuditRule->GetKey()."&".$oAppContext->GetForLink()."\">$iErrorsCount</a> <a href=\"?operation=csv&category=".$oAuditCategory->GetKey()."&rule=".$oAuditRule->GetKey()."&".$oAppContext->GetForLink()."\"><img src=\"" . utils::GetAbsoluteUrlAppRoot() . "images/icons/icons8-export-csv.svg\" class=\"ibo-audit--audit-line--csv-download\"></a>";
|
||||
$aRow['percent_ok'] = sprintf('%.2f', 100.0 * (($iCount - $iErrorsCount) / $iCount));
|
||||
$aRow['class'] = $oAuditCategory->GetReportColor($iCount, $iErrorsCount);
|
||||
}
|
||||
|
||||
@@ -400,6 +400,7 @@ try {
|
||||
$iUnchanged = 0;
|
||||
|
||||
$aTableData = [];
|
||||
$sAppRootUrl = utils::GetAbsoluteUrlAppRoot();
|
||||
|
||||
foreach ($aRes as $iLine => $aResRow) {
|
||||
$aTableRow = [];
|
||||
@@ -414,7 +415,7 @@ try {
|
||||
$sFinalClass = $aResRow['finalclass'];
|
||||
$oObj = MetaModel::GetObject($sFinalClass, $aResRow['id']->GetPureValue());
|
||||
$sUrl = $oObj->GetHyperlink();
|
||||
$sStatus = '<img src="../images/unchanged.png" title="'.Dict::S('UI:CSVReport-Icon-Unchanged').'">';
|
||||
$sStatus = '<img src="' . $sAppRootUrl . 'images/unchanged.png" title="'.Dict::S('UI:CSVReport-Icon-Unchanged').'">';
|
||||
$sCSSRowClass = 'ibo-csv-import--row-unchanged';
|
||||
break;
|
||||
|
||||
@@ -423,7 +424,7 @@ try {
|
||||
$sFinalClass = $aResRow['finalclass'];
|
||||
$oObj = MetaModel::GetObject($sFinalClass, $aResRow['id']->GetPureValue());
|
||||
$sUrl = $oObj->GetHyperlink();
|
||||
$sStatus = '<img src="../images/modified.png" title="'.Dict::S('UI:CSVReport-Icon-Modified').'">';
|
||||
$sStatus = '<img src="' . $sAppRootUrl . 'images/modified.png" title="'.Dict::S('UI:CSVReport-Icon-Modified').'">';
|
||||
$sCSSRowClass = 'ibo-csv-import--row-modified';
|
||||
break;
|
||||
|
||||
@@ -432,7 +433,7 @@ try {
|
||||
$sFinalClass = $aResRow['finalclass'];
|
||||
$oObj = MetaModel::GetObject($sFinalClass, $aResRow['id']->GetPureValue());
|
||||
$sUrl = $oObj->GetHyperlink();
|
||||
$sStatus = '<img src="../images/delete.png" title="'.Dict::S('UI:CSVReport-Icon-Missing').'">';
|
||||
$sStatus = '<img src="' . $sAppRootUrl . 'images/delete.png" title="'.Dict::S('UI:CSVReport-Icon-Missing').'">';
|
||||
$sCSSRowClass = 'ibo-csv-import--row-modified';
|
||||
if ($bSimulate) {
|
||||
$sMessage = Dict::S('UI:CSVReport-Object-MissingToUpdate');
|
||||
@@ -443,7 +444,7 @@ try {
|
||||
|
||||
case 'RowStatus_NewObj':
|
||||
$iCreated++;
|
||||
$sStatus = '<img src="../images/added.png" title="'.Dict::S('UI:CSVReport-Icon-Created').'">';
|
||||
$sStatus = '<img src="' . $sAppRootUrl . 'images/added.png" title="'.Dict::S('UI:CSVReport-Icon-Created').'">';
|
||||
$sCSSRowClass = 'ibo-csv-import--row-added';
|
||||
if ($bSimulate) {
|
||||
$sMessage = Dict::S('UI:CSVReport-Object-ToCreate');
|
||||
@@ -585,21 +586,21 @@ HTML;
|
||||
$oMulticolumn->AddCSSClass('ml-1');
|
||||
$oForm->AddSubBlock($oMulticolumn);
|
||||
|
||||
$oCheckBoxUnchanged = InputUIBlockFactory::MakeForInputWithLabel('<img src="../images/unchanged.png"> '.sprintf($aDisplayFilters['unchanged'], $iUnchanged), '', "1", "show_unchanged", "checkbox");
|
||||
$oCheckBoxUnchanged = InputUIBlockFactory::MakeForInputWithLabel('<img src="' . $sAppRootUrl . 'images/unchanged.png"> '.sprintf($aDisplayFilters['unchanged'], $iUnchanged), '', "1", "show_unchanged", "checkbox");
|
||||
$oCheckBoxUnchanged->GetInput()->SetIsChecked(true);
|
||||
$oCheckBoxUnchanged->SetBeforeInput(false);
|
||||
$oCheckBoxUnchanged->GetInput()->AddCSSClass('ibo-input-checkbox');
|
||||
$oMulticolumn->AddColumn(ColumnUIBlockFactory::MakeForBlock($oCheckBoxUnchanged));
|
||||
$oPage->add_ready_script("$('#show_unchanged').on('click', function(){ToggleRows('ibo-csv-import--row-unchanged')})");
|
||||
|
||||
$oCheckBoxUnchanged = InputUIBlockFactory::MakeForInputWithLabel('<img src="../images/modified.png"> '.sprintf($aDisplayFilters['modified'], $iModified), '', "1", "show_modified", "checkbox");
|
||||
$oCheckBoxUnchanged = InputUIBlockFactory::MakeForInputWithLabel('<img src="' . $sAppRootUrl . 'images/modified.png"> '.sprintf($aDisplayFilters['modified'], $iModified), '', "1", "show_modified", "checkbox");
|
||||
$oCheckBoxUnchanged->GetInput()->SetIsChecked(true);
|
||||
$oCheckBoxUnchanged->SetBeforeInput(false);
|
||||
$oCheckBoxUnchanged->GetInput()->AddCSSClass('ibo-input-checkbox');
|
||||
$oMulticolumn->AddColumn(ColumnUIBlockFactory::MakeForBlock($oCheckBoxUnchanged));
|
||||
$oPage->add_ready_script("$('#show_modified').on('click', function(){ToggleRows('ibo-csv-import--row-modified')})");
|
||||
|
||||
$oCheckBoxUnchanged = InputUIBlockFactory::MakeForInputWithLabel('<img src="../images/added.png"> '.sprintf($aDisplayFilters['added'], $iCreated), '', "1", "show_created", "checkbox");
|
||||
$oCheckBoxUnchanged = InputUIBlockFactory::MakeForInputWithLabel('<img src="' . $sAppRootUrl . 'images/added.png"> '.sprintf($aDisplayFilters['added'], $iCreated), '', "1", "show_created", "checkbox");
|
||||
$oCheckBoxUnchanged->GetInput()->SetIsChecked(true);
|
||||
$oCheckBoxUnchanged->SetBeforeInput(false);
|
||||
$oCheckBoxUnchanged->GetInput()->AddCSSClass('ibo-input-checkbox');
|
||||
|
||||
@@ -133,7 +133,7 @@ function ValidateOtherSettings()
|
||||
}
|
||||
else
|
||||
{
|
||||
$('#v_default_page_size').html('<img src="../images/validation_error.png"/>');
|
||||
$('#v_default_page_size').html('<img src="' + GetAbsoluteUrlAppRoot() + 'images/validation_error.png"/>');
|
||||
$('#ibo-misc-settings-submit').prop('disabled', true);
|
||||
return false;
|
||||
}
|
||||
@@ -417,7 +417,7 @@ JS
|
||||
|
||||
$oUserPicturePlaceHolderBlock = new Panel(Dict::S('UI:Preferences:ChooseAPlaceholder'), array(), 'grey', 'ibo-user-picture-placeholder');
|
||||
|
||||
$sUserPicturesFolder = '../images/user-pictures/';
|
||||
$sUserPicturesFolder = utils::GetAbsoluteUrlAppRoot() . 'images/user-pictures/';
|
||||
$sUserDefaultPicture = appUserPreferences::GetPref('user_picture_placeholder', 'default-placeholder.png');
|
||||
$sUserPicturePlaceHolderHtml = '';
|
||||
$sUserPicturePlaceHolderHtml .= '<p>'.Dict::S('UI:Preferences:ChooseAPlaceholder+').'</p> <div class="ibo-preferences--user-preferences--picture-placeholder">';
|
||||
|
||||
@@ -55,7 +55,6 @@ class FormHelper
|
||||
*/
|
||||
public static function DisableAttributeBlobInputs(string $sClassName, array &$aExtraParams): void
|
||||
{
|
||||
|
||||
// Initialize extra params array
|
||||
if (!array_key_exists('fieldsFlags', $aExtraParams)) {
|
||||
$aExtraParams['fieldsFlags'] = [];
|
||||
@@ -64,13 +63,13 @@ class FormHelper
|
||||
$aExtraParams['fieldsComments'] = [];
|
||||
}
|
||||
|
||||
// Iterate throw class attributes...
|
||||
// Iterate through class attributes...
|
||||
$sAppRootUrl = utils::GetAbsoluteUrlAppRoot();
|
||||
foreach (MetaModel::ListAttributeDefs($sClassName) as $sAttCode => $oAttDef) {
|
||||
|
||||
// Set attribute blobs in read only
|
||||
if ($oAttDef instanceof AttributeBlob) {
|
||||
$aExtraParams['fieldsFlags'][$sAttCode] = OPT_ATT_READONLY;
|
||||
$aExtraParams['fieldsComments'][$sAttCode] = ' <img src="../images/transp-lock.png" style="vertical-align:middle" title="'.utils::EscapeHtml(Dict::S('UI:UploadNotSupportedInThisMode')).'"/>';
|
||||
$aExtraParams['fieldsComments'][$sAttCode] = ' <img src="' . $sAppRootUrl . 'images/transp-lock.png" style="vertical-align:middle" title="'.utils::EscapeHtml(Dict::S('UI:UploadNotSupportedInThisMode')).'"/>';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -58,7 +58,7 @@ class ErrorPage extends NiceWebPage
|
||||
if(utils::IsEasterEggAllowed())
|
||||
{
|
||||
$this->add('<div class="message message-valid">'.Dict::S('UI:ErrorPage:UnstableVersion').'</div>');
|
||||
$this->add('<img src="../images/alpha-fatal-error.gif">');
|
||||
$this->add('<img src="' . utils::GetAbsoluteUrlAppRoot() . 'images/alpha-fatal-error.gif">');
|
||||
$this->add('<div class="message message-valid">'.nl2br(Dict::S('UI:ErrorPage:KittyDisclaimer')).'</div>');
|
||||
}
|
||||
$this->log_error($sText);
|
||||
|
||||
@@ -54,7 +54,7 @@ class iTopWizardWebPage extends iTopWebPage
|
||||
$sStyle = ($iIndex == $this->m_iCurrentStep) ? 'wizActiveStep' : 'wizStep';
|
||||
$aSteps[] = "<div class=\"$sStyle\"><span>$sStepTitle</span></div>";
|
||||
}
|
||||
$sWizardHeader = "<div class=\"wizHeader\"><h1>".utils::EscapeHtml($this->s_title)."</h1>\n".implode("<div class=\"wizSeparator\"><img align=\"bottom\" src=\"../images/wizArrow.gif\"></div>", $aSteps)."<br style=\"clear:both;\"/></div>\n";
|
||||
$sWizardHeader = "<div class=\"wizHeader\"><h1>".utils::EscapeHtml($this->s_title)."</h1>\n".implode("<div class=\"wizSeparator\"><img align=\"bottom\" src=\"" . utils::GetAbsoluteUrlAppRoot() . "images/wizArrow.gif\"></div>", $aSteps)."<br style=\"clear:both;\"/></div>\n";
|
||||
$this->s_content = "$sWizardHeader<div class=\"wizContainer\">".$this->s_content."</div>";
|
||||
parent::output();
|
||||
}
|
||||
|
||||
@@ -845,7 +845,7 @@ EOF
|
||||
);
|
||||
$sVersionString = Dict::Format('UI:iTopVersion:Short', ITOP_APPLICATION, ITOP_VERSION);
|
||||
$oPage->add('<div id="about_box"><div class="ibo-about-box--top-part">');
|
||||
$oPage->add('<div><a href="http://www.combodo.com" title="www.combodo.com" target="_blank"><img src="../images/logos/logo-combodo-dark.svg?t='.utils::GetCacheBusterTimestamp().'"/></a></div>');
|
||||
$oPage->add('<div><a href="http://www.combodo.com" title="www.combodo.com" target="_blank"><img src="' . utils::GetAbsoluteUrlAppRoot() . 'images/logos/logo-combodo-dark.svg?t='.utils::GetCacheBusterTimestamp().'"/></a></div>');
|
||||
$oPage->add('<div>'.$sVersionString.'</div>');
|
||||
$oPage->add("</div>");
|
||||
self::DisplayAboutLicenses($oPage);
|
||||
@@ -927,7 +927,7 @@ EOF
|
||||
// Display
|
||||
//
|
||||
$oPage->add('<div id="about_box"><div class="ibo-about-box--top-part">');
|
||||
$oPage->add('<div><a href="http://www.combodo.com" title="www.combodo.com" target="_blank"><img src="../images/logos/logo-combodo-dark.svg?t='.utils::GetCacheBusterTimestamp().'"/></a></div>');
|
||||
$oPage->add('<div><a href="http://www.combodo.com" title="www.combodo.com" target="_blank"><img src="' . utils::GetAbsoluteUrlAppRoot() . 'images/logos/logo-combodo-dark.svg?t='.utils::GetCacheBusterTimestamp().'"/></a></div>');
|
||||
$oPage->add('<div>'.$sVersionString.'<br/>'.'MySQL: '.$sMySQLVersion.'<br/>'.'PHP: '.$sPHPVersion.'<br/></div>');
|
||||
$oPage->add("</div>");
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
{% apply spaceless %}
|
||||
<div style="height:250px;width:100%" class="dashboard_chart" id="my_chart_{{ oUIBlock.sChartId }}{{ oUIBlock.iChartCounter }}">
|
||||
<div style="height:200px;line-height:200px;vertical-align:center;text-align:center;width:100%">
|
||||
<img src="../images/indicator.gif">
|
||||
<img src="{{ get_absolute_url_app_root() }}images/indicator.gif">
|
||||
</div>
|
||||
</div>
|
||||
{% endapply %}
|
||||
Reference in New Issue
Block a user