Skip to content

Commit

Permalink
feat(web): add guide link for eligibility
Browse files Browse the repository at this point in the history
ref: MANAGER-15875

Signed-off-by: Antony MARION <[email protected]>
  • Loading branch information
Antony MARION authored and antonymarion committed Nov 15, 2024
1 parent 6e069a3 commit d58fa8b
Show file tree
Hide file tree
Showing 4 changed files with 63 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,48 @@ export const INFO_PROPERTIES_ARRAY = [
},
];

export const GUIDE_URLS = {
AU:
'https://help.ovhcloud.com/csm/en-au-account-manage-contacts?id=kb_article_view&sysparm_article=KB0042979',
DE:
'https://help.ovhcloud.com/csm/de-account-manage-contacts?id=kb_article_view&sysparm_article=KB0042983',
GB:
'https://help.ovhcloud.com/csm/en-gb-account-manage-contacts?id=kb_article_view&sysparm_article=KB0042993',
CA:
'https://help.ovhcloud.com/csm/en-ca-account-manage-contacts?id=kb_article_view&sysparm_article=KB0042991',
IE:
'https://help.ovhcloud.com/csm/en-ie-account-manage-contacts?id=kb_article_view&sysparm_article=KB0042992',
SG:
'https://help.ovhcloud.com/csm/en-sg-account-manage-contacts?id=kb_article_view&sysparm_article=KB0042996',
ES:
'https://help.ovhcloud.com/csm/es-es-account-manage-contacts?id=kb_article_view&sysparm_article=KB0043001',
QC:
'https://help.ovhcloud.com/csm/fr-ca-account-manage-contacts?id=kb_article_view&sysparm_article=KB0043000',
FR:
'https://help.ovhcloud.com/csm/fr-account-manage-contacts?id=kb_article_view&sysparm_article=KB0042989',
MA:
'https://help.ovhcloud.com/csm/fr-account-manage-contacts?id=kb_article_view&sysparm_article=KB0042989',
SN:
'https://help.ovhcloud.com/csm/fr-account-manage-contacts?id=kb_article_view&sysparm_article=KB0042989',
TN:
'https://help.ovhcloud.com/csm/fr-account-manage-contacts?id=kb_article_view&sysparm_article=KB0042989',
IT:
'https://help.ovhcloud.com/csm/it-account-manage-contacts?id=kb_article_view&sysparm_article=KB0042994',
PL:
'https://help.ovhcloud.com/csm/pl-account-manage-contacts?id=kb_article_view&sysparm_article=KB0042997',
PT:
'https://help.ovhcloud.com/csm/pt-account-manage-contacts?id=kb_article_view&sysparm_article=KB0043004',
IN:
'https://help.ovhcloud.com/csm/asia-account-manage-contacts?id=kb_article_view&sysparm_article=KB0029947',
DEFAULT:
'https://help.ovhcloud.com/csm/en-account-manage-contacts?id=kb_article_view&sysparm_article=KB0042986',
};

export const LEGAL_FORM_INDIVIDUAL = 'individual';

export default {
INFO_PROPERTIES,
LEGAL_FORM_INDIVIDUAL,
INFO_PROPERTIES_ARRAY,
GUIDE_URL: GUIDE_URLS,
};
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import {
INFO_PROPERTIES,
INFO_PROPERTIES_ARRAY,
LEGAL_FORM_INDIVIDUAL,
GUIDE_URLS,
} from './dashboard.constants';

export default class DomainContactDashboardCtrl {
Expand All @@ -17,6 +18,8 @@ export default class DomainContactDashboardCtrl {
this.INFO_PROPERTIES = INFO_PROPERTIES;
this.LEGAL_FORM_INDIVIDUAL = LEGAL_FORM_INDIVIDUAL;
this.infoProperties = INFO_PROPERTIES_ARRAY;
this.ovhSubsidiary = this.user.ovhSubsidiary;
this.GUIDE_URL = GUIDE_URLS[this.ovhSubsidiary] || GUIDE_URLS.DEFAULT;
}

$onInit() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,26 @@ <h1 data-translate="domain_tab_CONTACT_title"></h1>

<div data-ng-if="!$ctrl.loading">
<div class="row">
<strong
class="mb-2"
data-translate="domain_tab_CONTACT_header"
></strong>
<p data-translate="domain_tab_CONTACT_description"></p>
<div class="col-md-10">
<strong
class="mb-2"
data-translate="domain_tab_CONTACT_header"
></strong>
<p data-translate="domain_tab_CONTACT_description"></p>
</div>
<div class="col-md-2">
<oui-guide-menu
data-text="{{ ::'domain_tab_CONTACT_guide_text' | translate }}"
>
<oui-guide-menu-item
data-href="{{ ::$ctrl.GUIDE_URL }}"
data-external="true"
><span
data-translate="domain_tab_CONTACT_guide_manage_contact_and_services"
></span>
</oui-guide-menu-item>
</oui-guide-menu>
</div>
</div>

<div class="row d-flex align-items-stretch">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,7 @@
"domain_tab_CONTACT_description_technical": "Il gère les aspects techniques d'un service. Il est responsable de la définition des serveurs DNS autoritaires.",
"domain_tab_CONTACT_description_billing": "Il gère uniquement la facturation d'un service dont ses prélèvements.",
"domain_tab_CONTACT_description_error_message": "Une erreur est apparue",
"domain_tab_CONTACT_guide_text": "Guide",
"domain_tab_CONTACT_guide_manage_contact_and_services": "Gérer les contacts de ses services",
"domain_tab_CONTACT_view_more": "Voir plus"
}

0 comments on commit d58fa8b

Please sign in to comment.