# -- # Copyright (C) 2001-2019 OTRS AG, https://otrs.com/ # -- # This software comes with ABSOLUTELY NO WARRANTY. For details, see # the enclosed file COPYING for license information (GPL). If you # did not receive this file, see https://www.gnu.org/licenses/gpl-3.0.txt. # -- ## nofilter(TidyAll::Plugin::OTRS::TT::Format) [% SET HighlightError = {}; SET HighlightHint = {}; SET DisableButton = {}; %] [% FOR XAxisElement IN Data.UseAsXvalue %] [% IF XAxisElement.Selected %][% SET XAxisConfigured = 1 %][% END %] [% END %] [% IF !Data.UseAsXvalue.size %][% SET XAxisConfigured = 1 %][% END %] [% FOR YAxisElement IN Data.UseAsValueSeries %] [% IF YAxisElement.Selected %][% SET YAxisConfigured = 1 %][% END %] [% END %] [% IF Data.StatsConfigurationErrors.size || !XAxisConfigured %]
[% Translate('There are problems in the configuration of this statistic:') | html %]
[% END %] [% IF Data.StatsConfigurationErrors.GeneralSpecificationFieldErrors.size %] [% PROCESS ErrorText %] [% FOR Error IN Data.StatsConfigurationErrors.GeneralSpecificationFieldErrors.pairs %][% Error.key | html %]: [% Translate(Error.value) | html %]
[% END %] [% ELSIF Data.StatsConfigurationErrors.XAxisGeneralErrors.size || !XAxisConfigured %] [% SET DisableButton.YAxis = 1; SET DisableButton.Restrictions = 1; %] [% IF XAxisConfigured %] [% SET HighlightError.XAxis = 1; %] [% PROCESS ErrorText %] [% FOR Error IN Data.StatsConfigurationErrors.XAxisGeneralErrors %][% Translate(Error) | html %]
[% END %] [% ELSE %] [% SET HighlightHint.XAxis = 1; %][% Translate('You may now configure the X-axis of your statistic.') | html %]
[% END %] [% ELSIF Data.StatsConfigurationErrors.XAxisFieldErrors.size %] [% SET HighlightError.XAxis = 1; SET DisableButton.YAxis = 1; SET DisableButton.Restrictions = 1; %] [% FOR Error IN Data.StatsConfigurationErrors.XAxisFieldErrors.pairs %][% Error.key | html%]: [% Translate(Error.value) | html %]
[% END %] [% ELSIF Data.StatsConfigurationErrors.YAxisGeneralErrors.size %] [% SET DisableButton.Restrictions = 1; %] [% SET HighlightError.YAxis = 1; %] [% PROCESS ErrorText %] [% FOR Error IN Data.StatsConfigurationErrors.YAxisGeneralErrors %][% Translate(Error) | html %]
[% END %] [% ELSIF Data.StatsConfigurationErrors.YAxisFieldErrors.size %] [% SET HighlightError.YAxis = 1; SET DisableButton.Restrictions = 1; %] [% PROCESS ErrorText %] [% FOR Error IN Data.StatsConfigurationErrors.YAxisFieldErrors.pairs %][% Error.key | html%]: [% Translate(Error.value) | html %]
[% END %] [% ELSE %] [% SET HighlightError.Restrictions = 1; %] [% PROCESS ErrorText %] [% FOR Error IN Data.StatsConfigurationErrors.RestrictionsFieldErrors.pairs %][% Error.key | html%]: [% Translate(Error.value) | html %]
[% END %] [% END %][% Translate('This statistic does not provide preview data.') | html %]
[% Translate('This statistic does not provide preview data.') | html %]
[% ELSE %] [% FOREACH Format IN PreviewFormats %] [% IF Format == 'Print' %] [% ELSE %] [% END %] [% END %] [% END %]