Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 25 additions & 2 deletions Kernel/Modules/AdminCustomerGroup.pm
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,11 @@ sub new {
my $Self = {%Param};
bless( $Self, $Type );

$Self->{AdminSystemConfigurationPermission} = $Kernel::OM->Get('Kernel::Output::HTML::Layout')->Permission(
Action => 'AdminSystemConfiguration',
Type => 'rw',
);

return $Self;
}

Expand All @@ -33,6 +38,8 @@ sub Run {
my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout');
my $ConfigObject = $Kernel::OM->Get('Kernel::Config');

$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

# ------------------------------------------------------------ #
# check if feature is active
# ------------------------------------------------------------ #
Expand Down Expand Up @@ -371,6 +378,8 @@ sub _Change {
my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout');
my $ConfigObject = $Kernel::OM->Get('Kernel::Config');

$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

my %Data = %{ $Param{Data} };
my $Type = $Param{Type} || 'Customer';
my $NeType = $Type eq 'Group' ? 'Customer' : 'Group';
Expand Down Expand Up @@ -430,7 +439,12 @@ sub _Change {
else {

# output config shortcut to CustomerAlwaysGroups
$LayoutObject->Block( Name => 'AlwaysGroupsConfig' );
$LayoutObject->Block(
Name => 'AlwaysGroupsConfig',
Data => {
%Param,
},
);

$LayoutObject->Block( Name => 'Filter' );
}
Expand Down Expand Up @@ -606,6 +620,8 @@ sub _Overview {
my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout');
my $ConfigObject = $Kernel::OM->Get('Kernel::Config');

$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

my $CustomerCount = $Param{CustomerCount};
my @CustomerKeyList = @{ $Param{CustomerKeyList} };
my %CustomerData = %{ $Param{CustomerData} };
Expand All @@ -628,7 +644,12 @@ sub _Overview {
);

# Output config shutcut to CustomerAlwaysGroups
$LayoutObject->Block( Name => 'AlwaysGroupsConfig' );
$LayoutObject->Block(
Name => 'AlwaysGroupsConfig',
Data => {
%Param,
},
);

# output filter and default block
$LayoutObject->Block(
Expand Down Expand Up @@ -744,6 +765,8 @@ sub _Disabled {

my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout');

$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

$LayoutObject->Block(
Name => 'Overview',
Data => {
Expand Down
27 changes: 25 additions & 2 deletions Kernel/Modules/AdminCustomerUserGroup.pm
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,11 @@ sub new {
my $Self = {%Param};
bless( $Self, $Type );

$Self->{AdminSystemConfigurationPermission} = $Kernel::OM->Get('Kernel::Output::HTML::Layout')->Permission(
Action => 'AdminSystemConfiguration',
Type => 'rw',
);

return $Self;
}

Expand All @@ -32,6 +37,8 @@ sub Run {
my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout');
my $ConfigObject = $Kernel::OM->Get('Kernel::Config');

$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

# ------------------------------------------------------------ #
# check if feature is active
# ------------------------------------------------------------ #
Expand Down Expand Up @@ -347,6 +354,8 @@ sub _Change {
my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout');
my $ConfigObject = $Kernel::OM->Get('Kernel::Config');

$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

my %Data = %{ $Param{Data} };
my $Type = $Param{Type} || 'CustomerUser';
my $NeType = $Type eq 'Group' ? 'CustomerUser' : 'Group';
Expand Down Expand Up @@ -404,7 +413,12 @@ sub _Change {
else {

# output config shortcut to CustomerAlwaysGroups
$LayoutObject->Block( Name => 'AlwaysGroupsConfig' );
$LayoutObject->Block(
Name => 'AlwaysGroupsConfig',
Data => {
%Param,
},
);

$LayoutObject->Block( Name => 'Filter' );
}
Expand Down Expand Up @@ -555,6 +569,8 @@ sub _Overview {
my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout');
my $ConfigObject = $Kernel::OM->Get('Kernel::Config');

$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

my $CustomerUserCount = $Param{CustomerUserCount};
my @CustomerUserKeyList = @{ $Param{CustomerUserKeyList} };
my %CustomerUserData = %{ $Param{CustomerUserData} };
Expand All @@ -579,7 +595,12 @@ sub _Overview {
);

# Output config shutcut to CustomerAlwaysGroups
$LayoutObject->Block( Name => 'AlwaysGroupsConfig' );
$LayoutObject->Block(
Name => 'AlwaysGroupsConfig',
Data => {
%Param,
},
);

# output filter and default block
$LayoutObject->Block(
Expand Down Expand Up @@ -695,6 +716,8 @@ sub _Disabled {

my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout');

$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

$LayoutObject->Block(
Name => 'Overview',
Data => {
Expand Down
13 changes: 13 additions & 0 deletions Kernel/Modules/AdminMailAccount.pm
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,11 @@ sub new {
my $Self = {%Param};
bless( $Self, $Type );

$Self->{AdminSystemConfigurationPermission} = $Kernel::OM->Get('Kernel::Output::HTML::Layout')->Permission(
Action => 'AdminSystemConfiguration',
Type => 'rw',
);

return $Self;
}

Expand All @@ -33,6 +38,8 @@ sub Run {
my $ParamObject = $Kernel::OM->Get('Kernel::System::Web::Request');
my $MailAccountObject = $Kernel::OM->Get('Kernel::System::MailAccount');

$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

my %GetParam = ();
my @Params = (
qw(
Expand Down Expand Up @@ -368,6 +375,8 @@ sub _Overview {
my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout');
my $MailAccountObject = $Kernel::OM->Get('Kernel::System::MailAccount');

$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

my %Backend = $MailAccountObject->MailAccountBackendList();

$LayoutObject->Block(
Expand Down Expand Up @@ -425,6 +434,8 @@ sub _MaskUpdateMailAccount {

my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout');

$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

# get valid list
my %ValidList = $Kernel::OM->Get('Kernel::System::Valid')->ValidList();
my %ValidListReverse = reverse %ValidList;
Expand Down Expand Up @@ -504,6 +515,8 @@ sub _MaskAddMailAccount {

my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout');

$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

# get valid list
my %ValidList = $Kernel::OM->Get('Kernel::System::Valid')->ValidList();
my %ValidListReverse = reverse %ValidList;
Expand Down
11 changes: 11 additions & 0 deletions Kernel/Modules/AdminPriority.pm
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,11 @@ sub new {
my $Self = {%Param};
bless( $Self, $Type );

$Self->{AdminSystemConfigurationPermission} = $Kernel::OM->Get('Kernel::Output::HTML::Layout')->Permission(
Action => 'AdminSystemConfiguration',
Type => 'rw',
);

return $Self;
}

Expand All @@ -41,6 +46,8 @@ sub Run {
my $ParamObject = $Kernel::OM->Get('Kernel::System::Web::Request');
my $PriorityObject = $Kernel::OM->Get('Kernel::System::Priority');

$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

# ------------------------------------------------------------ #
# change
# ------------------------------------------------------------ #
Expand Down Expand Up @@ -308,6 +315,8 @@ sub _Edit {

my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout');

$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

$LayoutObject->Block(
Name => 'Overview',
Data => \%Param,
Expand Down Expand Up @@ -404,6 +413,8 @@ sub _Overview {

my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout');

$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

$LayoutObject->Block(
Name => 'Overview',
Data => \%Param,
Expand Down
16 changes: 16 additions & 0 deletions Kernel/Modules/AdminProcessManagement.pm
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,16 @@ sub new {
my $Self = {%Param};
bless( $Self, $Type );

$Self->{AdminACLPermission} = $Kernel::OM->Get('Kernel::Output::HTML::Layout')->Permission(
Action => 'AdminACL',
Type => 'rw',
);

$Self->{AdminSystemConfigurationPermission} = $Kernel::OM->Get('Kernel::Output::HTML::Layout')->Permission(
Action => 'AdminSystemConfiguration',
Type => 'rw',
);

return $Self;
}

Expand Down Expand Up @@ -69,6 +79,9 @@ sub Run {
my $StateObject = $Kernel::OM->Get('Kernel::System::ProcessManagement::DB::Process::State');
my $ConfigObject = $Kernel::OM->Get('Kernel::Config');

$Param{AdminACLPermission} = $Self->{AdminACLPermission};
$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

# ------------------------------------------------------------ #
# ProcessImport
# ------------------------------------------------------------ #
Expand Down Expand Up @@ -1600,6 +1613,9 @@ sub _ShowOverview {

my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout');

$Param{AdminACLPermission} = $Self->{AdminACLPermission};
$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

my $Output = $LayoutObject->Header();
$Output .= $LayoutObject->NavigationBar();

Expand Down
19 changes: 19 additions & 0 deletions Kernel/Modules/AdminQueue.pm
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,16 @@ sub new {
my $Self = {%Param};
bless( $Self, $Type );

$Self->{AdminMailAccountPermission} = $Kernel::OM->Get('Kernel::Output::HTML::Layout')->Permission(
Action => 'AdminMailAccount',
Type => 'rw',
);

$Self->{AdminSystemConfigurationPermission} = $Kernel::OM->Get('Kernel::Output::HTML::Layout')->Permission(
Action => 'AdminSystemConfiguration',
Type => 'rw',
);

return $Self;
}

Expand Down Expand Up @@ -111,6 +121,9 @@ sub Run {
my $MainObject = $Kernel::OM->Get('Kernel::System::Main');
my $Notification = $ParamObject->GetParam( Param => 'Notification' ) || '';

$Param{AdminMailAccountPermission} = $Self->{AdminMailAccountPermission};
$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

# ------------------------------------------------------------ #
# change
# ------------------------------------------------------------ #
Expand Down Expand Up @@ -577,6 +590,9 @@ sub _Edit {

my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout');

$Param{AdminMailAccountPermission} = $Self->{AdminMailAccountPermission};
$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

$LayoutObject->Block(
Name => 'Overview',
Data => \%Param,
Expand Down Expand Up @@ -949,6 +965,9 @@ sub _Overview {

my $LayoutObject = $Kernel::OM->Get('Kernel::Output::HTML::Layout');

$Param{AdminMailAccountPermission} = $Self->{AdminMailAccountPermission};
$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

$LayoutObject->Block(
Name => 'Overview',
Data => \%Param,
Expand Down
11 changes: 9 additions & 2 deletions Kernel/Modules/AdminSLA.pm
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,11 @@ sub new {

$Self->{IsITSMInstalled} = $Kernel::OM->Get('Kernel::System::Util')->IsITSMInstalled();

$Self->{AdminSystemConfigurationPermission} = $Kernel::OM->Get('Kernel::Output::HTML::Layout')->Permission(
Action => 'AdminSystemConfiguration',
Type => 'rw',
);

return $Self;
}

Expand All @@ -35,7 +40,8 @@ sub Run {
my $SLAObject = $Kernel::OM->Get('Kernel::System::SLA');
my %Error = ();

$Param{IsITSMInstalled} = $Self->{IsITSMInstalled};
$Param{IsITSMInstalled} = $Self->{IsITSMInstalled};
$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

# ------------------------------------------------------------ #
# sla edit
Expand Down Expand Up @@ -338,7 +344,8 @@ sub _MaskNew {

my $ParamObject = $Kernel::OM->Get('Kernel::System::Web::Request');

$Param{IsITSMInstalled} = $Self->{IsITSMInstalled};
$Param{IsITSMInstalled} = $Self->{IsITSMInstalled};
$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

# get params
my %SLAData;
Expand Down
11 changes: 9 additions & 2 deletions Kernel/Modules/AdminService.pm
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,11 @@ sub new {

$Self->{IsITSMInstalled} = $Kernel::OM->Get('Kernel::System::Util')->IsITSMInstalled();

$Self->{AdminSystemConfigurationPermission} = $Kernel::OM->Get('Kernel::Output::HTML::Layout')->Permission(
Action => 'AdminSystemConfiguration',
Type => 'rw',
);

return $Self;
}

Expand All @@ -35,7 +40,8 @@ sub Run {
my $ConfigObject = $Kernel::OM->Get('Kernel::Config');
my $ServiceObject = $Kernel::OM->Get('Kernel::System::Service');

$Param{IsITSMInstalled} = $Self->{IsITSMInstalled};
$Param{IsITSMInstalled} = $Self->{IsITSMInstalled};
$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

if ( $Self->{IsITSMInstalled} ) {
my $DynamicFieldObject = $Kernel::OM->Get('Kernel::System::DynamicField');
Expand Down Expand Up @@ -335,7 +341,8 @@ sub _MaskNew {
my $ServiceObject = $Kernel::OM->Get('Kernel::System::Service');
my %ServiceData;

$Param{IsITSMInstalled} = $Self->{IsITSMInstalled};
$Param{IsITSMInstalled} = $Self->{IsITSMInstalled};
$Param{AdminSystemConfigurationPermission} = $Self->{AdminSystemConfigurationPermission};

# get params
$ServiceData{ServiceID} = $Kernel::OM->Get('Kernel::System::Web::Request')->GetParam( Param => "ServiceID" );
Expand Down
Loading
Loading