Maintenances.tt 3.27 KB
# --
# Kernel/Output/HTML/Standard/Maintenances.tt - template for maintenances module index
#
# Copyright (C) 2014-2018 - SeTIC - UFSC - http://setic.ufsc.br/
# Version 2015-08-01 - Adjustments for OTRS 4
# Version 2018-01-05 - Adjustments for OTRS 6
#
# --
# This software comes with ABSOLUTELY NO WARRANTY. For details, see
# the enclosed file COPYING for license information (AGPL). If you
# did not receive this file, see http://www.gnu.org/licenses/agpl.txt.
# --

<div class="MainBox ARIARoleMain">

	<h1>[% Translate("Maintenances") | html %]</h1>
	
	[% BreadcrumbPath = [
            {
                Name => Translate('Maintenances'),
                Link => Env("Action"),
            },
        ]
    %]    
    
    [% INCLUDE "Breadcrumb.tt" Path = BreadcrumbPath %]
<div class="OverviewBox ARIARoleMain Preview" role="main">
<div class="WidgetSimple QueueOverview">
	<div class="Content">
	<ul class="QueueOverviewList Level_0">
		<li><a [% IF Data.Type == "current" %] class="Active"[% END %] HREF="[% Env("CGIHandle") %]?Action=[% Env("Action") %];Type=current">[% Translate("Current") | html %]</a>
		</li>
		<li><a [% IF Data.Type == "scheduled" %] class="Active"[% END %] HREF="[% Env("CGIHandle") %]?Action=[% Env("Action") %];Type=scheduled">[% Translate("Scheduled") | html %]</a>
		</li>
		<li><a [% IF Data.Type == "current_scheduled" %] class="Active"[% END %] HREF="[% Env("CGIHandle") %]?Action=[% Env("Action") %];Type=current_scheduled">[% Translate("Current and scheduled") | html %]</a>
		</li>
		<li><a [% IF Data.Type == "all" %] class="Active"[% END %] HREF="[% Env("CGIHandle") %]?Action=[% Env("Action") %];Type=all">[% Translate("All") | html %]</a>
		</li>
			
	</ul>
	</div>
</div>
</div>

<table class="DataTable VariableWidth SpacingTop" style="border-collapse: collapse" id="Table">
	<thead>
    	<tr>
        	<th><center>[% Translate("Status/Actions") | html %]</center></th>
            <th width="40%"><center>[% Translate("Description") | html %]</center></th>
            <th><center>[% Translate("Start time") | html %]</center></th>
            <th><center>[% Translate("Scheduled end date") | html %]</center></th>
            <th><center>[% Translate("End date") | html %]</center></th>
        </tr>
	</thead>
	<tbody>
		[% RenderBlockStart("Maintenance") %]
		<tr>
			[% IF Data.Status == 2 %]
				<td>[% Translate("Cancelled") | html %]</td>
			[% ELSIF Data.Status == 1 %]				
				<td>[% Translate("Finished") | html %]</td>
			[% ELSIF Data.Active %]
				<td>[% Translate("Active") | html %] (<A HREF="[% Env("CGIHandle") %]?Action=[% Env("Action") %];Subaction=EndMaintenance;ID=[% Data.ID %]">[% Translate("End") %]</A>)</td>
			[% ELSE %]
				<td>[% Translate("Scheduled ") | html %] (<A HREF="[% Env("CGIHandle") %]?Action=[% Env("Action") %];Subaction=CancelMaintenance;ID=[% Data.ID %]">[% Translate("Cancel") %]</A>)</td>
			[% END %]		
            <td><center>[% Data.Description %]</center></td>
            <td><center><div>[% Data.StartDate | Localize("TimeShort") %]</div></center></td>
            <td><center><div>[% Data.ScheduledEndDate | Localize("TimeShort") %]</div></center></td>
            <td><center><div>[% Data.EndDate | Localize("TimeShort") %]</div></center></td>
		</tr>
		[% RenderBlockEnd("Maintenance") %]                     
	</tbody>
</table>


</div>