Skip to content

Commit

Permalink
Hide Azure and Google from the admin gui
Browse files Browse the repository at this point in the history
  • Loading branch information
fdurand committed Jun 29, 2021
1 parent 3d1cdf7 commit d6a60d9
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 87 deletions.
40 changes: 0 additions & 40 deletions html/pfappserver/lib/pfappserver/Form/Config/Cloud/Azure.pm
Original file line number Diff line number Diff line change
Expand Up @@ -14,46 +14,6 @@ use HTML::FormHandler::Moose;
extends 'pfappserver::Form::Config::Cloud';
with 'pfappserver::Base::Form::Role::Help';

use pf::config;
use pf::util;
use File::Find qw(find);

has_field 'tenant_id' =>
(
type => 'Text',
label => 'Tenant ID',
required => 1,
messages => { required => 'Please specify the Tenant ID for the Azure Service' },
);

has_field 'client_id' =>
(
type => 'Text',
label => 'Client ID',
required => 1,
messages => { required => 'Please specify the Client ID for the Azure Service' },
);

has_field 'client_secret' =>
(
type => 'ObfuscatedText',
label => 'Client Secret',
required => 1,
messages => { required => 'Please specify the Tenant ID for the Azure Service' },
);


has_field 'type' =>
(
type => 'Hidden',
default => 'Azure',
);

has_block definition =>
(
render_list => [ qw(id tenant_id client_id client_secret) ],
);

=over
=back
Expand Down
40 changes: 0 additions & 40 deletions html/pfappserver/lib/pfappserver/Form/Config/Cloud/Google.pm
Original file line number Diff line number Diff line change
Expand Up @@ -14,46 +14,6 @@ use HTML::FormHandler::Moose;
extends 'pfappserver::Form::Config::Cloud';
with 'pfappserver::Base::Form::Role::Help';

use pf::config;
use pf::util;
use File::Find qw(find);

has_field 'tenant_id' =>
(
type => 'Text',
label => 'Tenant ID',
required => 1,
messages => { required => 'Please specify the Tenant ID for the Google Service' },
);

has_field 'client_id' =>
(
type => 'Text',
label => 'Client ID',
required => 1,
messages => { required => 'Please specify the Client ID for the Google Service' },
);

has_field 'client_secret' =>
(
type => 'ObfuscatedText',
label => 'Client Secret',
required => 1,
messages => { required => 'Please specify the Tenant ID for the Google Service' },
);


has_field 'type' =>
(
type => 'Hidden',
default => 'Google',
);

has_block definition =>
(
render_list => [ qw(id tenant_id client_id client_secret) ],
);

=over
=back
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,9 @@
</template>
<template v-slot:buttonAdd>
<b-dropdown :text="$t('New Cloud')" variant="outline-primary">
<b-dropdown-item :to="{ name: 'newCloud', params: { cloudType: 'Azure' } }">Microsoft Azure</b-dropdown-item>
<!-- <b-dropdown-item :to="{ name: 'newCloud', params: { cloudType: 'Azure' } }">Microsoft Azure</b-dropdown-item>
<b-dropdown-item :to="{ name: 'newCloud', params: { cloudType: 'Google' } }">Google Cloud</b-dropdown-item>
-->
<b-dropdown-item :to="{ name: 'newCloud', params: { cloudType: 'Intune' } }">Microsoft Intune</b-dropdown-item>
</b-dropdown>
</template>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,21 +10,24 @@
:disabled="!isNew && !isClone"
/>

<!--
<form-group-tenant-id namespace="tenant_id"
:column-label="$i18n.t('The tenant ID of the intune service')"
:column-label="$i18n.t('The tenant ID of the Azure service')"
:text="$i18n.t('Define the tenant ID defined in the Azure admin portal.')"
/>
<form-group-client-id namespace="client_id"
:column-label="$i18n.t('The client ID of the intune service')"
:column-label="$i18n.t('The client ID of the Azure service')"
:text="$i18n.t('Define the client ID defined in the Azure admin portal.')"
/>
<form-group-client-secret namespace="client_secret"
:column-label="$i18n.t('The client secret of the intune service')"
:column-label="$i18n.t('The client secret of the Azure service')"
:text="$i18n.t('Define the client secret defined in the Azure admin portal.')"
/>
-->

</base-form>
</template>
<script>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,20 +10,22 @@
:disabled="!isNew && !isClone"
/>

<!--
<form-group-tenant-id namespace="tenant_id"
:column-label="$i18n.t('The tenant ID of the intune service')"
:column-label="$i18n.t('The tenant ID of the Google service')"
:text="$i18n.t('Define the tenant ID defined in the Azure admin portal.')"
/>
<form-group-client-id namespace="client_id"
:column-label="$i18n.t('The client ID of the intune service')"
:column-label="$i18n.t('The client ID of the Google service')"
:text="$i18n.t('Define the client ID defined in the Azure admin portal.')"
/>
<form-group-client-secret namespace="client_secret"
:column-label="$i18n.t('The client secret of the intune service')"
:column-label="$i18n.t('The client secret of the Google service')"
:text="$i18n.t('Define the client secret defined in the Azure admin portal.')"
/>
-->

</base-form>
</template>
Expand Down

0 comments on commit d6a60d9

Please sign in to comment.