From 1cd02f285d4d778dddfe34024da4b31afdc0afcd Mon Sep 17 00:00:00 2001 From: Paul McGoldrick Date: Thu, 28 Sep 2017 10:36:03 -0700 Subject: initial seed code commit VVP-9 Change-Id: I4d48180db7eba7cb7c299ab618f04d2092868085 Signed-off-by: Paul McGoldrick --- .../activation/activate/activateUser.controller.js | 60 ++ .../app/main/activation/activate/activateUser.html | 39 + .../activation/activate/activateUser.module.js | 58 ++ .../addVendorContact.controller.js | 111 +++ .../addVendorContact/addVendorContact.html | 111 +++ .../addVendorContact/addVendorContact.less | 82 ++ .../addVendorContact/addVendorContact.module.js | 67 ++ .../app/main/activation/addVf/addVf.controller.js | 277 +++++++ d2ice.att.io/app/main/activation/addVf/addVf.html | 130 ++++ d2ice.att.io/app/main/activation/addVf/addVf.less | 176 +++++ .../app/main/activation/addVf/addVf.module.js | 67 ++ .../activation/contactUs/contactUs.controller.js | 57 ++ .../app/main/activation/contactUs/contactUs.html | 53 ++ .../app/main/activation/contactUs/contactUs.less | 59 ++ .../main/activation/contactUs/contactUs.module.js | 67 ++ .../inviteMembers/inviteMembers.controller.js | 97 +++ .../activation/inviteMembers/inviteMembers.html | 72 ++ .../activation/inviteMembers/inviteMembers.less | 86 +++ .../inviteMembers/inviteMembers.module.js | 67 ++ .../app/main/activation/login/login.controller.js | 119 +++ d2ice.att.io/app/main/activation/login/login.html | 90 +++ d2ice.att.io/app/main/activation/login/login.less | 109 +++ .../app/main/activation/login/login.module.js | 68 ++ .../activation/register/register.controller.js | 122 +++ .../app/main/activation/register/register.html | 127 ++++ .../app/main/activation/register/register.less | 100 +++ .../main/activation/register/register.module.js | 67 ++ .../resendActivation.controller.js | 79 ++ .../resendActivation/resendActivation.html | 61 ++ .../resendActivation/resendActivation.less | 67 ++ .../resendActivation/resendActivation.module.js | 68 ++ .../resetPassword/resetPassword.controller.js | 95 +++ .../activation/resetPassword/resetPassword.html | 64 ++ .../activation/resetPassword/resetPassword.less | 84 +++ .../resetPassword/resetPassword.module.js | 68 ++ .../app/main/activation/terms/terms.controller.js | 56 ++ d2ice.att.io/app/main/activation/terms/terms.html | 105 +++ d2ice.att.io/app/main/activation/terms/terms.less | 65 ++ .../app/main/activation/terms/terms.module.js | 68 ++ .../updatePassword/updatePassword.controller.js | 95 +++ .../activation/updatePassword/updatePassword.html | 76 ++ .../activation/updatePassword/updatePassword.less | 85 +++ .../updatePassword/updatePassword.module.js | 68 ++ d2ice.att.io/app/main/admin/admin.module.js | 89 +++ .../checklist-template.controller.js | 241 ++++++ .../checklist-template/checklist-template.html | 174 +++++ .../checklist-template/checklist-template.less | 552 ++++++++++++++ .../main/dashboard/account/account.controller.js | 150 ++++ .../app/main/dashboard/account/account.html | 159 ++++ .../app/main/dashboard/account/account.less | 215 ++++++ .../app/main/dashboard/account/account.module.js | 85 +++ .../notifications/notifications.controller.js | 140 ++++ .../account/notifications/notifications.html | 60 ++ .../account/notifications/notifications.less | 348 +++++++++ .../user-profile-settings.controller.js | 98 +++ .../user-profile-settings.html | 66 ++ .../user-profile-settings.less | 45 ++ .../dashboard/checklist/checklist.controller.js | 445 +++++++++++ .../app/main/dashboard/checklist/checklist.html | 117 +++ .../app/main/dashboard/checklist/checklist.less | 826 ++++++++++++++++++++ .../dashboard/dashboard/dashboard.controller.js | 235 ++++++ .../app/main/dashboard/dashboard/dashboard.html | 111 +++ .../app/main/dashboard/dashboard/dashboard.less | 189 +++++ .../detailed-view/detailed-view.controller.js | 245 ++++++ .../dashboard/detailed-view/detailed-view.html | 109 +++ .../dashboard/detailed-view/detailed-view.less | 400 ++++++++++ .../get-started-modal.directive.js | 308 ++++++++ .../get-started-modal/get-started-modal.html | 38 + .../get-started-modal/get-started-modal.less | 47 ++ .../get-started-modal/get-started-modal.module.js | 48 ++ .../get-started-modal/wizard/wizard-container.html | 192 +++++ .../dashboard/get-started-modal/wizard/wizard.less | 255 +++++++ d2ice.att.io/app/main/dashboard/main.module.js | 107 +++ d2ice.att.io/app/main/dashboard/main/main.html | 172 +++++ .../main/dashboard/overview/overview.controller.js | 833 +++++++++++++++++++++ .../app/main/dashboard/overview/overview.html | 212 ++++++ .../app/main/dashboard/overview/overview.less | 575 ++++++++++++++ .../main/documentation/documentation.controller.js | 74 ++ .../app/main/documentation/documentation.html | 47 ++ .../app/main/documentation/documentation.less | 96 +++ .../app/main/documentation/documentation.module.js | 74 ++ .../sidebar/documentation.sidebar.html | 41 + .../sidebar/documentation.sidebar.less | 61 ++ d2ice.att.io/app/main/errors/404.html | 190 +++++ d2ice.att.io/app/main/main.controller.js | 60 ++ .../archive-engagement-modal.controller.js | 66 ++ .../archive-engagement-modal.html | 56 ++ .../archive-engagement-modal.less | 54 ++ .../main/modals/audit-log/audit-log.controller.js | 95 +++ .../app/main/modals/audit-log/audit-log.html | 76 ++ .../app/main/modals/audit-log/audit-log.less | 49 ++ .../modals/change-date/change-date.controller.js | 75 ++ .../app/main/modals/change-date/change-date.html | 62 ++ .../change-progress/change-progress.controller.js | 71 ++ .../modals/change-progress/change-progress.html | 65 ++ .../main/modals/checklist/checklist.controller.js | 238 ++++++ .../app/main/modals/checklist/checklist.html | 107 +++ .../state-approve-or-reject.controller.js | 105 +++ .../state-approve-or-reject.html | 58 ++ .../state-approve-or-reject.less | 173 +++++ .../cms-post-modal/cms-post-modal.controller.js | 92 +++ .../main/modals/cms-post-modal/cms-post-modal.html | 55 ++ .../main/modals/cms-post-modal/cms-post-modal.less | 106 +++ .../detailed-view-dtsites-modal.controller.js | 100 +++ .../dtsite/detailed-view-dtsites-modal.html | 62 ++ .../vfc/detailed-view-vfc-modal.controller.js | 124 +++ .../detailed-view/vfc/detailed-view-vfc-modal.html | 100 +++ .../detailed-view/vfc/detailed-view-vfc-modal.less | 68 ++ .../main/modals/feedback/feedback.controller.js | 82 ++ .../app/main/modals/feedback/feedback.html | 57 ++ .../app/main/modals/feedback/feedback.less | 44 ++ .../general-log-modal.controller.js | 63 ++ .../general-log-modal/general-log-modal.html | 45 ++ .../general-log-modal/general-log-modal.less | 72 ++ .../general-prompt-modal.controller.js | 74 ++ .../general-prompt-modal/general-prompt-modal.html | 52 ++ .../general-prompt-modal/general-prompt-modal.less | 151 ++++ .../modals/next-steps/next-steps.controller.js | 278 +++++++ .../app/main/modals/next-steps/next-steps.html | 138 ++++ .../app/main/modals/next-steps/next-steps.less | 307 ++++++++ .../select-el-modal/select-el-modal.controller.js | 78 ++ .../modals/select-el-modal/select-el-modal.html | 56 ++ .../modals/select-el-modal/select-el-modal.less | 54 ++ .../set-eng-stage-modal.controller.js | 63 ++ .../modals/set-eng-stage/set-eng-stage-modal.html | 49 ++ .../modals/set-eng-stage/set-eng-stage-modal.less | 135 ++++ .../modals/set-eng-stage/set_eng_stage_modal.html | 58 ++ .../app/main/modals/status/status.controller.js | 125 ++++ d2ice.att.io/app/main/modals/status/status.html | 59 ++ d2ice.att.io/app/main/modals/status/status.less | 44 ++ .../change-lab-entry-date.controller.js | 78 ++ .../target-lab-entry/change-lab-entry-date.html | 55 ++ .../target-lab-entry/change-lab-entry-date.less | 49 ++ .../update-engagement-status-modal.controller.js | 73 ++ .../update-engagement-status-modal.html | 97 +++ .../update-engagement-status-modal.less | 61 ++ ...led-view-validation-details-modal.controller.js | 202 +++++ .../detailed-view-validation-details-modal.html | 101 +++ .../detailed-view-validation-details-modal.less | 49 ++ 139 files changed, 17177 insertions(+) create mode 100755 d2ice.att.io/app/main/activation/activate/activateUser.controller.js create mode 100755 d2ice.att.io/app/main/activation/activate/activateUser.html create mode 100755 d2ice.att.io/app/main/activation/activate/activateUser.module.js create mode 100755 d2ice.att.io/app/main/activation/addVendorContact/addVendorContact.controller.js create mode 100755 d2ice.att.io/app/main/activation/addVendorContact/addVendorContact.html create mode 100755 d2ice.att.io/app/main/activation/addVendorContact/addVendorContact.less create mode 100755 d2ice.att.io/app/main/activation/addVendorContact/addVendorContact.module.js create mode 100755 d2ice.att.io/app/main/activation/addVf/addVf.controller.js create mode 100755 d2ice.att.io/app/main/activation/addVf/addVf.html create mode 100755 d2ice.att.io/app/main/activation/addVf/addVf.less create mode 100755 d2ice.att.io/app/main/activation/addVf/addVf.module.js create mode 100755 d2ice.att.io/app/main/activation/contactUs/contactUs.controller.js create mode 100755 d2ice.att.io/app/main/activation/contactUs/contactUs.html create mode 100755 d2ice.att.io/app/main/activation/contactUs/contactUs.less create mode 100755 d2ice.att.io/app/main/activation/contactUs/contactUs.module.js create mode 100755 d2ice.att.io/app/main/activation/inviteMembers/inviteMembers.controller.js create mode 100755 d2ice.att.io/app/main/activation/inviteMembers/inviteMembers.html create mode 100755 d2ice.att.io/app/main/activation/inviteMembers/inviteMembers.less create mode 100755 d2ice.att.io/app/main/activation/inviteMembers/inviteMembers.module.js create mode 100755 d2ice.att.io/app/main/activation/login/login.controller.js create mode 100755 d2ice.att.io/app/main/activation/login/login.html create mode 100755 d2ice.att.io/app/main/activation/login/login.less create mode 100755 d2ice.att.io/app/main/activation/login/login.module.js create mode 100755 d2ice.att.io/app/main/activation/register/register.controller.js create mode 100755 d2ice.att.io/app/main/activation/register/register.html create mode 100755 d2ice.att.io/app/main/activation/register/register.less create mode 100755 d2ice.att.io/app/main/activation/register/register.module.js create mode 100755 d2ice.att.io/app/main/activation/resendActivation/resendActivation.controller.js create mode 100755 d2ice.att.io/app/main/activation/resendActivation/resendActivation.html create mode 100755 d2ice.att.io/app/main/activation/resendActivation/resendActivation.less create mode 100755 d2ice.att.io/app/main/activation/resendActivation/resendActivation.module.js create mode 100755 d2ice.att.io/app/main/activation/resetPassword/resetPassword.controller.js create mode 100755 d2ice.att.io/app/main/activation/resetPassword/resetPassword.html create mode 100755 d2ice.att.io/app/main/activation/resetPassword/resetPassword.less create mode 100755 d2ice.att.io/app/main/activation/resetPassword/resetPassword.module.js create mode 100755 d2ice.att.io/app/main/activation/terms/terms.controller.js create mode 100755 d2ice.att.io/app/main/activation/terms/terms.html create mode 100755 d2ice.att.io/app/main/activation/terms/terms.less create mode 100755 d2ice.att.io/app/main/activation/terms/terms.module.js create mode 100755 d2ice.att.io/app/main/activation/updatePassword/updatePassword.controller.js create mode 100755 d2ice.att.io/app/main/activation/updatePassword/updatePassword.html create mode 100755 d2ice.att.io/app/main/activation/updatePassword/updatePassword.less create mode 100755 d2ice.att.io/app/main/activation/updatePassword/updatePassword.module.js create mode 100755 d2ice.att.io/app/main/admin/admin.module.js create mode 100755 d2ice.att.io/app/main/admin/checklist-template/checklist-template.controller.js create mode 100755 d2ice.att.io/app/main/admin/checklist-template/checklist-template.html create mode 100755 d2ice.att.io/app/main/admin/checklist-template/checklist-template.less create mode 100755 d2ice.att.io/app/main/dashboard/account/account.controller.js create mode 100755 d2ice.att.io/app/main/dashboard/account/account.html create mode 100755 d2ice.att.io/app/main/dashboard/account/account.less create mode 100755 d2ice.att.io/app/main/dashboard/account/account.module.js create mode 100755 d2ice.att.io/app/main/dashboard/account/notifications/notifications.controller.js create mode 100755 d2ice.att.io/app/main/dashboard/account/notifications/notifications.html create mode 100755 d2ice.att.io/app/main/dashboard/account/notifications/notifications.less create mode 100755 d2ice.att.io/app/main/dashboard/account/user-profile-settings/user-profile-settings.controller.js create mode 100755 d2ice.att.io/app/main/dashboard/account/user-profile-settings/user-profile-settings.html create mode 100755 d2ice.att.io/app/main/dashboard/account/user-profile-settings/user-profile-settings.less create mode 100755 d2ice.att.io/app/main/dashboard/checklist/checklist.controller.js create mode 100755 d2ice.att.io/app/main/dashboard/checklist/checklist.html create mode 100755 d2ice.att.io/app/main/dashboard/checklist/checklist.less create mode 100755 d2ice.att.io/app/main/dashboard/dashboard/dashboard.controller.js create mode 100755 d2ice.att.io/app/main/dashboard/dashboard/dashboard.html create mode 100755 d2ice.att.io/app/main/dashboard/dashboard/dashboard.less create mode 100755 d2ice.att.io/app/main/dashboard/detailed-view/detailed-view.controller.js create mode 100755 d2ice.att.io/app/main/dashboard/detailed-view/detailed-view.html create mode 100755 d2ice.att.io/app/main/dashboard/detailed-view/detailed-view.less create mode 100755 d2ice.att.io/app/main/dashboard/get-started-modal/get-started-modal.directive.js create mode 100755 d2ice.att.io/app/main/dashboard/get-started-modal/get-started-modal.html create mode 100755 d2ice.att.io/app/main/dashboard/get-started-modal/get-started-modal.less create mode 100755 d2ice.att.io/app/main/dashboard/get-started-modal/get-started-modal.module.js create mode 100755 d2ice.att.io/app/main/dashboard/get-started-modal/wizard/wizard-container.html create mode 100755 d2ice.att.io/app/main/dashboard/get-started-modal/wizard/wizard.less create mode 100755 d2ice.att.io/app/main/dashboard/main.module.js create mode 100755 d2ice.att.io/app/main/dashboard/main/main.html create mode 100755 d2ice.att.io/app/main/dashboard/overview/overview.controller.js create mode 100755 d2ice.att.io/app/main/dashboard/overview/overview.html create mode 100755 d2ice.att.io/app/main/dashboard/overview/overview.less create mode 100755 d2ice.att.io/app/main/documentation/documentation.controller.js create mode 100755 d2ice.att.io/app/main/documentation/documentation.html create mode 100755 d2ice.att.io/app/main/documentation/documentation.less create mode 100755 d2ice.att.io/app/main/documentation/documentation.module.js create mode 100755 d2ice.att.io/app/main/documentation/sidebar/documentation.sidebar.html create mode 100755 d2ice.att.io/app/main/documentation/sidebar/documentation.sidebar.less create mode 100755 d2ice.att.io/app/main/errors/404.html create mode 100755 d2ice.att.io/app/main/main.controller.js create mode 100755 d2ice.att.io/app/main/modals/archive-engagement-modal/archive-engagement-modal.controller.js create mode 100755 d2ice.att.io/app/main/modals/archive-engagement-modal/archive-engagement-modal.html create mode 100755 d2ice.att.io/app/main/modals/archive-engagement-modal/archive-engagement-modal.less create mode 100755 d2ice.att.io/app/main/modals/audit-log/audit-log.controller.js create mode 100755 d2ice.att.io/app/main/modals/audit-log/audit-log.html create mode 100755 d2ice.att.io/app/main/modals/audit-log/audit-log.less create mode 100755 d2ice.att.io/app/main/modals/change-date/change-date.controller.js create mode 100755 d2ice.att.io/app/main/modals/change-date/change-date.html create mode 100755 d2ice.att.io/app/main/modals/change-progress/change-progress.controller.js create mode 100755 d2ice.att.io/app/main/modals/change-progress/change-progress.html create mode 100755 d2ice.att.io/app/main/modals/checklist/checklist.controller.js create mode 100755 d2ice.att.io/app/main/modals/checklist/checklist.html create mode 100755 d2ice.att.io/app/main/modals/checklist/state-approve-or-reject/state-approve-or-reject.controller.js create mode 100755 d2ice.att.io/app/main/modals/checklist/state-approve-or-reject/state-approve-or-reject.html create mode 100755 d2ice.att.io/app/main/modals/checklist/state-approve-or-reject/state-approve-or-reject.less create mode 100755 d2ice.att.io/app/main/modals/cms-post-modal/cms-post-modal.controller.js create mode 100755 d2ice.att.io/app/main/modals/cms-post-modal/cms-post-modal.html create mode 100755 d2ice.att.io/app/main/modals/cms-post-modal/cms-post-modal.less create mode 100755 d2ice.att.io/app/main/modals/detailed-view/dtsite/detailed-view-dtsites-modal.controller.js create mode 100755 d2ice.att.io/app/main/modals/detailed-view/dtsite/detailed-view-dtsites-modal.html create mode 100755 d2ice.att.io/app/main/modals/detailed-view/vfc/detailed-view-vfc-modal.controller.js create mode 100755 d2ice.att.io/app/main/modals/detailed-view/vfc/detailed-view-vfc-modal.html create mode 100755 d2ice.att.io/app/main/modals/detailed-view/vfc/detailed-view-vfc-modal.less create mode 100755 d2ice.att.io/app/main/modals/feedback/feedback.controller.js create mode 100755 d2ice.att.io/app/main/modals/feedback/feedback.html create mode 100755 d2ice.att.io/app/main/modals/feedback/feedback.less create mode 100755 d2ice.att.io/app/main/modals/general-log-modal/general-log-modal.controller.js create mode 100755 d2ice.att.io/app/main/modals/general-log-modal/general-log-modal.html create mode 100755 d2ice.att.io/app/main/modals/general-log-modal/general-log-modal.less create mode 100755 d2ice.att.io/app/main/modals/general-prompt-modal/general-prompt-modal.controller.js create mode 100755 d2ice.att.io/app/main/modals/general-prompt-modal/general-prompt-modal.html create mode 100755 d2ice.att.io/app/main/modals/general-prompt-modal/general-prompt-modal.less create mode 100755 d2ice.att.io/app/main/modals/next-steps/next-steps.controller.js create mode 100755 d2ice.att.io/app/main/modals/next-steps/next-steps.html create mode 100755 d2ice.att.io/app/main/modals/next-steps/next-steps.less create mode 100755 d2ice.att.io/app/main/modals/select-el-modal/select-el-modal.controller.js create mode 100755 d2ice.att.io/app/main/modals/select-el-modal/select-el-modal.html create mode 100755 d2ice.att.io/app/main/modals/select-el-modal/select-el-modal.less create mode 100755 d2ice.att.io/app/main/modals/set-eng-stage/set-eng-stage-modal.controller.js create mode 100755 d2ice.att.io/app/main/modals/set-eng-stage/set-eng-stage-modal.html create mode 100755 d2ice.att.io/app/main/modals/set-eng-stage/set-eng-stage-modal.less create mode 100755 d2ice.att.io/app/main/modals/set-eng-stage/set_eng_stage_modal.html create mode 100755 d2ice.att.io/app/main/modals/status/status.controller.js create mode 100755 d2ice.att.io/app/main/modals/status/status.html create mode 100755 d2ice.att.io/app/main/modals/status/status.less create mode 100755 d2ice.att.io/app/main/modals/target-lab-entry/change-lab-entry-date.controller.js create mode 100755 d2ice.att.io/app/main/modals/target-lab-entry/change-lab-entry-date.html create mode 100755 d2ice.att.io/app/main/modals/target-lab-entry/change-lab-entry-date.less create mode 100755 d2ice.att.io/app/main/modals/update-engagement-status-modal/update-engagement-status-modal.controller.js create mode 100755 d2ice.att.io/app/main/modals/update-engagement-status-modal/update-engagement-status-modal.html create mode 100755 d2ice.att.io/app/main/modals/update-engagement-status-modal/update-engagement-status-modal.less create mode 100755 d2ice.att.io/app/main/modals/validation-details/detailed-view-validation-details-modal.controller.js create mode 100755 d2ice.att.io/app/main/modals/validation-details/detailed-view-validation-details-modal.html create mode 100755 d2ice.att.io/app/main/modals/validation-details/detailed-view-validation-details-modal.less (limited to 'd2ice.att.io/app/main') diff --git a/d2ice.att.io/app/main/activation/activate/activateUser.controller.js b/d2ice.att.io/app/main/activation/activate/activateUser.controller.js new file mode 100755 index 00000000..39e60123 --- /dev/null +++ b/d2ice.att.io/app/main/activation/activate/activateUser.controller.js @@ -0,0 +1,60 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + angular + .module('ice.activation.activateUser') + .controller('ActivateUserController', ["$state", "usersService", "$log", "$stateParams", LoginController]); + + function LoginController($state, usersService, $log, $stateParams) { + var init = function () { + usersService.activateUser($stateParams.userID, $stateParams.token) + .then(function (response) { + $state.go('app.login', {activation_success: response.data.activation_success, + engagement_uuid: response.data.engagement_uuid}); + }) + .catch(function (error) { + $log.error(error); + $state.go('app.login', {message: error.message.detail}); + }); + }; + + init(); + } +})(); diff --git a/d2ice.att.io/app/main/activation/activate/activateUser.html b/d2ice.att.io/app/main/activation/activate/activateUser.html new file mode 100755 index 00000000..2041a607 --- /dev/null +++ b/d2ice.att.io/app/main/activation/activate/activateUser.html @@ -0,0 +1,39 @@ + +
diff --git a/d2ice.att.io/app/main/activation/activate/activateUser.module.js b/d2ice.att.io/app/main/activation/activate/activateUser.module.js new file mode 100755 index 00000000..b2e1f169 --- /dev/null +++ b/d2ice.att.io/app/main/activation/activate/activateUser.module.js @@ -0,0 +1,58 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + angular + .module('ice.activation.activateUser', []) + .config(config); + + function config($stateProvider) { + $stateProvider + .state('app.activateUser', { + url: '/activate/:userID/:token', + views: { + 'main@': { + templateUrl: 'main/activation/activate/activateUser.html', + controller : 'ActivateUserController as vm' + } + }, + params: {} + }); + } +})(); diff --git a/d2ice.att.io/app/main/activation/addVendorContact/addVendorContact.controller.js b/d2ice.att.io/app/main/activation/addVendorContact/addVendorContact.controller.js new file mode 100755 index 00000000..c8859a7d --- /dev/null +++ b/d2ice.att.io/app/main/activation/addVendorContact/addVendorContact.controller.js @@ -0,0 +1,111 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.activation.addVendorContact') + .controller('AddVendorContactController', ["$state", "vfService", "usersService", "$log", "$rootScope", + AddVendorContactController]); + + function AddVendorContactController($state, vfService, usersService, $log, $rootScope) { + + var vm = this; + vm.data = {}; + + var init = function() { + $rootScope.ice.loader.show = true; + $rootScope.headerTitle = ""; + $rootScope.headerSubTitle = ""; + + vm.choices = [{ VirtualFunction: '', TargetLab: '', TargetAic: '',is_service_provider_internal: '' }]; + + vfService.getCompanies() + .then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 200) { + vm.companies = response.data; + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + + }; + + vm.submitForm = function () { + vm.data.company = vm.data.company.uuid; + + $rootScope.ice.loader.show = true; + usersService.addVendorContact(vm.data) + .then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 200) { + if (response.data.is_active) { + $state.go('app.dashboard.overview'); + } else { + $state.go('app.resend_activation'); + } + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + vm.Msg = response.status + " : " + response.statusText; + vm.bgColor = "#FFEBEB"; // RED #FFEBEB green DFF0D9 + $log.error(error); + }); + }; + + vm.addNewChoice = function (){ + var newItemNo = vm.choices.length + 1; + vm.choices.push({ 'id': newItemNo }); + }; + + vm.removeChoice = function (){ + var lastItem = vm.choices.length - 1; + vm.choices.splice(lastItem); + }; + + init(); + } + +})(); + diff --git a/d2ice.att.io/app/main/activation/addVendorContact/addVendorContact.html b/d2ice.att.io/app/main/activation/addVendorContact/addVendorContact.html new file mode 100755 index 00000000..ff9bd6e6 --- /dev/null +++ b/d2ice.att.io/app/main/activation/addVendorContact/addVendorContact.html @@ -0,0 +1,111 @@ + + + +
+
+
+ +
+ +
+ + +
+ Please select a company +
+
+ +
+ + +
+ Name is a required field. + Full Name is too short. + Full Name is too long. +
+
+ +
+ + +
+ Email is a required field. + Enter a valid email. +
+
+ +
+ + +
+ Phone is a required field. + Phone is too short. + Phone is too long. + Phone must consist of numbers only. +
+
+ +
+  I agree to receive regular email updates. +
+ +
+  I accept the AT&T's {{'program.name' | i18next}} Terms of Service and Privacy Policy. +
+ +
+ +
+
reCAPTCHA is invalid.
+
+ + + + + + +
+ +
+
+ +
diff --git a/d2ice.att.io/app/main/activation/addVendorContact/addVendorContact.less b/d2ice.att.io/app/main/activation/addVendorContact/addVendorContact.less new file mode 100755 index 00000000..166962d9 --- /dev/null +++ b/d2ice.att.io/app/main/activation/addVendorContact/addVendorContact.less @@ -0,0 +1,82 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.addVendorContact { + + .add-button + { + float:left; + .sprite; + .sprite.add; + } + + .remove-button + { + width:100px; + height:40px; + line-height:20px; + vertical-align:middle; + padding-left:10px; + float:left; + } + + .login-form { + margin-top: 20px; + } + + .btn { + width: 100%; + } + + .btn-primary { + border: 1px solid #8799A3; + border-radius: 6px; + background: #1E79B0; /* For browsers that do not support gradients */ + background: -webkit-linear-gradient(#1E79B0, #62ADD5); /* For Safari 5.1 to 6.0 */ + background: -o-linear-gradient(#1E79B0, #62ADD5); /* For Opera 11.1 to 12.0 */ + background: -moz-linear-gradient(#1E79B0, #62ADD5); /* For Firefox 3.6 to 15 */ + background: linear-gradient(#1E79B0, #62ADD5); /* Standard syntax (must be last) */ + } + + a.register { + text-decoration: underline; + float: right; + margin: 10px 0 0 0; + } + +} diff --git a/d2ice.att.io/app/main/activation/addVendorContact/addVendorContact.module.js b/d2ice.att.io/app/main/activation/addVendorContact/addVendorContact.module.js new file mode 100755 index 00000000..c7b7396a --- /dev/null +++ b/d2ice.att.io/app/main/activation/addVendorContact/addVendorContact.module.js @@ -0,0 +1,67 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.activation.addVendorContact', []) + .config(config); + + function config($stateProvider) { + + $stateProvider + .state('app.addVendorContact', { + url : '/addVendorContact', + views : { + 'main@': { + templateUrl: 'core/layouts/full-page-with-header/full-page-with-header.html', + controller : 'MainController as vm' + }, + 'content@app.addVendorContact': { + templateUrl: 'main/activation/addVendorContact/addVendorContact.html', + controller : 'AddVendorContactController as vm' + } + }, + bodyClass: 'addVendorContact' + }); + + } + +})(); diff --git a/d2ice.att.io/app/main/activation/addVf/addVf.controller.js b/d2ice.att.io/app/main/activation/addVf/addVf.controller.js new file mode 100755 index 00000000..5a00c170 --- /dev/null +++ b/d2ice.att.io/app/main/activation/addVf/addVf.controller.js @@ -0,0 +1,277 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.activation.addVf') + .controller('AddVfController', ["$scope", "$state", "vfService", "toastService", "$location", "$rootScope", + "localStorageService", 'usersService', '$log', AddVfController]) + .directive('addVf', function () { + return { + restrict: 'AEC', + templateUrl: 'main/activation/addVf/addVf.html', + link: function(scope, elm, attrs) { + + }, + controller: AddVfController, + controllerAs: 'vm', + scope: { + isModal: '=isModal' + } + } + }); + + function AddVfController($scope, $state, vfService, toastService, $location, $rootScope,localStorageService, + usersService, $log) { + var vm = this; + vm.data = []; + vm.isModal = $scope.isModal; + vm.user = usersService.getUserData(); + if (vm.user == undefined) { + $state.go('app.login'); + } + + $rootScope.headerTitle = "Add Virtual Function"; + $rootScope.headerSubTitle = "
Please use the form below to submit the virtual functions you would " + + "like to engage with ICE.
Please do note that each VF will be tracked separately.
"; + + if (!vm.isModal && $location.search().activation_success) { + toastService.setToast('You have successfully activated your account', 'success', {displayFor: 'modal'}); + } + + var targetLabDate1 = []; + //vm.targetLabDate = iceConstants.targetLabDate; + vm.targetLabDate = monthesPlus12(); + + + $rootScope.ice.loader.show = true; + vfService.getDeployTargets() + .then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 200) { + vm.deployTargets = response.data; + } + }).catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + + vfService.getECOMPReleases() + .then(function (response) { + if (response.status === 200) { + vm.ECOMPReleases = response.data; + } + }).catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + + vm.choices = [{VirtualFunction: '', TargetLab: '', TargetAic: '', is_service_provider_internal: ''}]; + + vm.addNewChoice = function () { + var newItemNo = vm.choices.length + 1; + vm.choices.push({'id': newItemNo}); + }; + + vm.removeChoice = function (index) { + vm.choices.splice(index,1); + }; + + vm.submitForm = function () { + var is_service_provider_internal; + var jsonAddVf = []; + angular.forEach(vm.choices, function (value, key) { + if (value.is_service_provider_internal == true) { + is_service_provider_internal = "True"; + } else { + is_service_provider_internal = "False"; + } + vm.item = []; + var jsonItem = new Object(); + jsonItem.virtual_function = value.VirtualFunction; + var objDate = new Date(Date.parse((value.TargetLab) + moment().format("z"))); + jsonItem.target_lab_entry_date = objDate.getFullYear() + "-" + + addZero(objDate.getMonth()+1) + "-" + addZero(objDate.getDate()); + jsonItem.version = value.VFVersion; + jsonItem.target_aic_uuid = value.TargetAic; + jsonItem.ecomp_release = value.ECOMPRelease; + jsonItem.is_service_provider_internal = (is_service_provider_internal === "True"); + jsonAddVf.push(jsonItem); + }); + + $rootScope.ice.loader.show = true; + vfService.addVfs(JSON.stringify(jsonAddVf))//vm.data)) + .then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 200) { + localStorageService.setJson("vfs", response.data); + + if (!vm.isModal) { + if (response.data.is_active) { + $state.go('app.dashboard.overview'); + } else { + $state.go('app.resend_activation'); + } + } else { + $scope.$emit('onUpdateEngagements',{ + select: { + uuid:response.data[0].engagement.uuid,page_type:'overview', + sub_id:undefined + } + }); + $scope.$emit('moveWizardNextStep', response.data[0]); + } + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + }; + + + vm.skipAddVf = function () { + if (!vm.isModal && $location.search().activation_success) { + $state.go('app.dashboard.overview'); + } else { + $state.go('app.resend_activation'); + } + }; + vm.myDate = new Date(); + vm.minDate = new Date( + vm.myDate.getFullYear(), + vm.myDate.getMonth(), + vm.myDate.getDate()); + vm.maxDate = new Date( + vm.myDate.getFullYear() + 2, + vm.myDate.getMonth(), + vm.myDate.getDate()); + + } + + + var monthesPlus12 = function() + { + var i; + var arrMonthYear=[]; + var startingMonth = (new Date().getMonth()+1); + var startingYear = (new Date().getFullYear()); + for (i = startingMonth ; i<=12;i++) + { + arrMonthYear.push({"val": monthZero(i) + "-" + startingYear, "nam": MonthNumToName(i) + " " + + startingYear}); + } + for (i=1; i < startingMonth ; i++) + { + arrMonthYear.push({"val": monthZero(i) + "-" + (startingYear+1), "nam": MonthNumToName(i) + " " + + (startingYear + 1)}); + } + return(arrMonthYear); + } + + var monthZero = function(m) + { + var ret = m; + if (m<10) + { + ret = "0"+m; + } + return(ret); + } + + var MonthNumToName = function(m) + { + var MonthName; + switch (m) + { + case 1: + MonthName = "January"; + break; + case 2: + MonthName = "February"; + break; + case 3: + MonthName = "March"; + break; + case 4: + MonthName = "April"; + break; + case 5: + MonthName = "May"; + break; + case 6: + MonthName = "June"; + break; + case 7: + MonthName = "July"; + break; + case 8: + MonthName = "August"; + break; + case 9: + MonthName = "September"; + break; + case 10: + MonthName = "October"; + break; + case 11: + MonthName = "November"; + break; + case 12: + MonthName = "December"; + break; + } + return(MonthName); + } + + var addZero = function(x) + { + if (x<10) + { + return("0"+x); + } + else + { + return(x); + } + } +})(); + diff --git a/d2ice.att.io/app/main/activation/addVf/addVf.html b/d2ice.att.io/app/main/activation/addVf/addVf.html new file mode 100755 index 00000000..4dff7b0b --- /dev/null +++ b/d2ice.att.io/app/main/activation/addVf/addVf.html @@ -0,0 +1,130 @@ + + +
+
+
+
+
+
+ +
+
+ +
+ +
+ Use the form below to add your VF.Try to be as accurate as you can around the information to + make sure the validation can accomplished as possible. +
+
+
+ +
+
VF Name
+ +
+ VF Name can be alphanumeric or/and Hyphen +
+
+
+
+

Key Metadata

+
+ +
+ +
+
Target Lab Entry Date
+ + +
+
+
+ + The virtual function is only developed internally inside AT&T. +
+
+
+
+ +
+
+
+
+
diff --git a/d2ice.att.io/app/main/activation/addVf/addVf.less b/d2ice.att.io/app/main/activation/addVf/addVf.less new file mode 100755 index 00000000..dd78bae3 --- /dev/null +++ b/d2ice.att.io/app/main/activation/addVf/addVf.less @@ -0,0 +1,176 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.add-vf { + + .reject_large { + .actions-sprite; + .actions-sprite.reject_large; + cursor: pointer; + } + + .table{ + margin-bottom: 0; + } + + .table-container-flex { + + + .action-row-wrapper, .data-row-wrapper { + padding: 5px 10px; + margin-bottom:5px; + + } + + .data-row-wrapper:nth-child(even) { + background: rgba(158, 158, 158, 0.28); + + + } + + .data-row-wrapper:nth-child(odd) { + border-bottom: 1px solid; + border-top: 1px solid; + border-color: @main_color_q; + } + + .data-row-wrapper:first-child { + border-top: none; + } + + .data-row-wrapper:last-child { + border-bottom:none; + } + .flex-item { + padding-left:0px; + } + .flex-item:nth-child(1) { + padding: 5px 15px 5px 0px; + flex-grow: 25; + } + + .flex-item:nth-child(2) { + flex-grow: 25; + } + + .flex-item:nth-child(3) { + flex-grow: 25; + } + + .flex-item:nth-child(4) { + flex-grow: 25; + } + .flex-item:nth-child(5) { + flex-grow: 25; + } + + } + + .add-vf-confirm-checkbox { + display: block; + clear: both; + } + + .add-button { + display: block; + .add-text { + .a_16_m; + vertical-align: top; + margin-left: 6px; + } + .add-icon { + .sprite; + .sprite.add; + display: inline-block; + } + } + + .remove-button { + width:100px; + height:40px; + line-height:20px; + vertical-align:middle; + padding-left:10px; + float:left; + .a_16_m; + margin-top: 8px; + cursor: pointer; + + .remove-icon { + display: inline-block; + vertical-align: text-top; + margin-right: 6px; + .sprite; + .sprite.delete-circle; + cursor: pointer; + } + } + + .lineColor + { + margin: 2px; + } + + .addVf-form { + margin-top: 20px; + } + + .btn { + width: 100%; + } + + .btn-primary { + border: 1px solid #8799A3; + border-radius: 6px; + background: #1E79B0; /* For browsers that do not support gradients */ + background: -webkit-linear-gradient(#1E79B0, #62ADD5); /* For Safari 5.1 to 6.0 */ + background: -o-linear-gradient(#1E79B0, #62ADD5); /* For Opera 11.1 to 12.0 */ + background: -moz-linear-gradient(#1E79B0, #62ADD5); /* For Firefox 3.6 to 15 */ + background: linear-gradient(#1E79B0, #62ADD5); /* Standard syntax (must be last) */ + } + + #skip-add-vf-singup { + margin-top: 10px; + display: block; + text-decoration: underline; + text-align: left; + .a_16_r; + } + + +} diff --git a/d2ice.att.io/app/main/activation/addVf/addVf.module.js b/d2ice.att.io/app/main/activation/addVf/addVf.module.js new file mode 100755 index 00000000..bac2c90b --- /dev/null +++ b/d2ice.att.io/app/main/activation/addVf/addVf.module.js @@ -0,0 +1,67 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.activation.addVf', []) + .config(config); + + function config($stateProvider) { + + $stateProvider + .state('app.addVf', { + url : '/addVf', + views : { + 'main@': { + templateUrl: 'core/layouts/full-page-with-header/full-page-with-header.html', + controller : 'MainController as vm' + }, + 'content@app.addVf': { + templateUrl: 'main/activation/addVf/addVf.html', + controller : 'AddVfController as vm' + } + }, + bodyClass: 'add-vf' + }); + + } + +})(); diff --git a/d2ice.att.io/app/main/activation/contactUs/contactUs.controller.js b/d2ice.att.io/app/main/activation/contactUs/contactUs.controller.js new file mode 100755 index 00000000..bed33798 --- /dev/null +++ b/d2ice.att.io/app/main/activation/contactUs/contactUs.controller.js @@ -0,0 +1,57 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.contactUs') + .controller('ContactUsController', ["$rootScope", ContactUsController]); + + function ContactUsController($rootScope) { + + var vm = this; + + $rootScope.headerTitle = "Contact Us"; + $rootScope.headerSubTitle = "Please fill in the details below"; + + } + +})(); + diff --git a/d2ice.att.io/app/main/activation/contactUs/contactUs.html b/d2ice.att.io/app/main/activation/contactUs/contactUs.html new file mode 100755 index 00000000..653ebc1d --- /dev/null +++ b/d2ice.att.io/app/main/activation/contactUs/contactUs.html @@ -0,0 +1,53 @@ + +
+ +
+
+ +
+ + + +
+ +
+
+ +
diff --git a/d2ice.att.io/app/main/activation/contactUs/contactUs.less b/d2ice.att.io/app/main/activation/contactUs/contactUs.less new file mode 100755 index 00000000..befbb342 --- /dev/null +++ b/d2ice.att.io/app/main/activation/contactUs/contactUs.less @@ -0,0 +1,59 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.contact-us { + + .contact-us-form { + margin-top: 20px; + } + + .btn { + width: 100%; + } + + .btn-primary { + border: 1px solid #8799A3; + border-radius: 6px; + background: #1E79B0; /* For browsers that do not support gradients */ + background: -webkit-linear-gradient(#1E79B0, #62ADD5); /* For Safari 5.1 to 6.0 */ + background: -o-linear-gradient(#1E79B0, #62ADD5); /* For Opera 11.1 to 12.0 */ + background: -moz-linear-gradient(#1E79B0, #62ADD5); /* For Firefox 3.6 to 15 */ + background: linear-gradient(#1E79B0, #62ADD5); /* Standard syntax (must be last) */ + } + +} diff --git a/d2ice.att.io/app/main/activation/contactUs/contactUs.module.js b/d2ice.att.io/app/main/activation/contactUs/contactUs.module.js new file mode 100755 index 00000000..9259671d --- /dev/null +++ b/d2ice.att.io/app/main/activation/contactUs/contactUs.module.js @@ -0,0 +1,67 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.contactUs', []) + .config(config); + + function config($stateProvider) { + + $stateProvider + .state('app.contactus', { + url : '/contactUs', + views : { + 'main@': { + templateUrl: 'core/layouts/full-page-with-header/full-page-with-header.html', + controller : 'MainController as vm' + }, + 'content@app.contactus': { + templateUrl: 'main/activation/contactUs/contactUs.html', + controller : 'ContactUsController as vm' + } + }, + bodyClass: 'contact-us' + }); + + } + +})(); diff --git a/d2ice.att.io/app/main/activation/inviteMembers/inviteMembers.controller.js b/d2ice.att.io/app/main/activation/inviteMembers/inviteMembers.controller.js new file mode 100755 index 00000000..72ff43c0 --- /dev/null +++ b/d2ice.att.io/app/main/activation/inviteMembers/inviteMembers.controller.js @@ -0,0 +1,97 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + angular + .module('ice.activation.inviteMembers') + .controller('InviteMembersController', ["$state", "vfService", "$rootScope", "$log", InviteMembersController]); + + function InviteMembersController($state, vfService, $rootScope, $log) { + var vm = this; + vm.data = []; + + var init = function() { + $rootScope.headerTitle = "Invite Team Members"; + $rootScope.headerSubTitle = "You can invite as many team members to collaborate around your virtual" + + " function as you would like. Please do remember that anyone invited to collaborate with you around" + + " the virtual function will have equal access."; + vm.choices = [{ Email: '' }]; + }; + + vm.submitForm = function () { + var jsonInviteMembers=[]; + angular.forEach(vm.choices, function(value, key) { + vm.item=[]; + var jsonItem = new Object(); + jsonItem.email = value.email; + jsonInviteMembers.push(jsonItem); + }); + + $rootScope.ice.loader.show = true; + vfService.inviteMembers(JSON.stringify(jsonInviteMembers)) + .then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 200) { + if (response.data.is_active) { + $state.go('app.dashboard.overview'); + } else { + $state.go('app.resend_activation'); + } + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + }; + + vm.addNewChoice = function () { + var newItemNo = vm.choices.length + 1; + vm.choices.push({ 'id': newItemNo }); + }; + + vm.removeChoice = function () { + var lastItem = vm.choices.length - 1; + vm.choices.splice(lastItem); + }; + + init(); + } +})(); + diff --git a/d2ice.att.io/app/main/activation/inviteMembers/inviteMembers.html b/d2ice.att.io/app/main/activation/inviteMembers/inviteMembers.html new file mode 100755 index 00000000..60fa01d5 --- /dev/null +++ b/d2ice.att.io/app/main/activation/inviteMembers/inviteMembers.html @@ -0,0 +1,72 @@ + + + +
+ +
+ +
+ +
+
+
+
+
+
+ +
+ Email is a required field. + Enter a valid email. +
+
+
+
+ Remove +
+
+
+ + Invite another team member + + + +
+
+
diff --git a/d2ice.att.io/app/main/activation/inviteMembers/inviteMembers.less b/d2ice.att.io/app/main/activation/inviteMembers/inviteMembers.less new file mode 100755 index 00000000..9eb02dc3 --- /dev/null +++ b/d2ice.att.io/app/main/activation/inviteMembers/inviteMembers.less @@ -0,0 +1,86 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.inviteMembers { + + .inviteMembers-title { + height: 130px; + display: flex; + flex-direction: column; + align-items: center; + justify-content: flex-start; + h1 {.p_24; margin: 20px 0 10px 0;} + h2 {.p_16_m; margin: 0;} + } + + .add-button { + &:after { + .sprite; + .sprite.add; + display: block; + } + } + + .remove-button { + width:100px; + height:40px; + line-height:20px; + vertical-align:middle; + padding-left:10px; + float:left; + } + + .inviteMembers-form { + margin-top: 20px; + } + + .btn { + width: 100%; + } + + .btn-primary { + border: 1px solid #8799A3; + border-radius: 6px; + background: #1E79B0; /* For browsers that do not support gradients */ + background: -webkit-linear-gradient(#1E79B0, #62ADD5); /* For Safari 5.1 to 6.0 */ + background: -o-linear-gradient(#1E79B0, #62ADD5); /* For Opera 11.1 to 12.0 */ + background: -moz-linear-gradient(#1E79B0, #62ADD5); /* For Firefox 3.6 to 15 */ + background: linear-gradient(#1E79B0, #62ADD5); /* Standard syntax (must be last) */ + } + +} diff --git a/d2ice.att.io/app/main/activation/inviteMembers/inviteMembers.module.js b/d2ice.att.io/app/main/activation/inviteMembers/inviteMembers.module.js new file mode 100755 index 00000000..61d8f1f0 --- /dev/null +++ b/d2ice.att.io/app/main/activation/inviteMembers/inviteMembers.module.js @@ -0,0 +1,67 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.activation.inviteMembers', []) + .config(config); + + function config($stateProvider) { + + $stateProvider + .state('app.inviteMembers', { + url : '/inviteMembers', + views : { + 'main@': { + templateUrl: 'core/layouts/full-page-with-header/full-page-with-header.html', + controller : 'MainController as vm' + }, + 'content@app.inviteMembers': { + templateUrl: 'main/activation/inviteMembers/inviteMembers.html', + controller : 'InviteMembers as vm' + } + }, + bodyClass: 'inviteMembers' + }); + + } + +})(); diff --git a/d2ice.att.io/app/main/activation/login/login.controller.js b/d2ice.att.io/app/main/activation/login/login.controller.js new file mode 100755 index 00000000..9ed5f1be --- /dev/null +++ b/d2ice.att.io/app/main/activation/login/login.controller.js @@ -0,0 +1,119 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.activation.login') + .controller('LoginController', ["$state", "usersService", "$log", "$rootScope", "$location", "toastService", + "$stateParams", LoginController]); + + function LoginController($state, usersService, $log, $rootScope, $location, toastService, $stateParams) { + var vm = this; + vm.data = {}; + $rootScope.headerTitle = "Login"; + $rootScope.headerSubTitle = "Please use the form below to login"; + usersService.resetUserData(); + var t=""; + + if ($state.params.message){ + toastService.setToast($state.params.message, 'danger'); + $log.warn($state.params.message); + } + + if ($location.search().t != undefined){ + t = "token"+$location.search().t + } + + vm.data.invitation = $location.search().invitation; + + vm.submitForm = function () { + $rootScope.ice.loader.show = true; + usersService.login(JSON.stringify(vm.data), t) + .then(function (response) { + if (response.status === 200) { + $rootScope.ice.loader.show = false; + + usersService.setUserActivationSuccess($state.params.activation_success); + + if(response.data.isResetPwdFlow!=undefined && response.data.isResetPwdFlow==true){ + $state.go("app.updatePassword"); + } + else{ + // This is a workaround to remove slash at the beginning. + // The slash is there because the ui-router does not support optional + // params in URL address, and I used regex: + // url: '/login{enggement_uuid: (?:/[^/]+)?}' and the value returned for engagement_uuid + // contains slash at the start. + var engagement_uuid = $state.params.engagement_uuid; + if (response.data.eng_uuid != undefined) + engagement_uuid = response.data.eng_uuid; + + if (engagement_uuid){ + engagement_uuid = engagement_uuid.replace('/',''); + $state.go("app.dashboard.overview", {"engagement_uuid": engagement_uuid}); + } else { + $state.go("app.dashboard.dashboard"); + } + } + } + }) + .catch(function (error) { + if(error && error.message && error.message.detail) { + toastService.setToast(error.message.detail, 'danger'); + } else { + toastService.setToast(error.message, 'danger'); + } + + $rootScope.ice.loader.show = false; + $log.error(error.message); + if(error.status===403){ // The server will return 403 if the user.is_active==false + $log.error('User is not active, redirecting to resend_activation page'); + $state.go("app.resend_activation", {"message": "Please activate your account first"}); + } + if(error.status===302){ // The server will return 302 if the temporary password has expired + $log.error('Temporary password has expired, redirecting to reset_password page'); + $state.go('app.resetPassword', {"message":"Your temporary password has expired, please" + + " generate a new one"}); + } + }); + }; + } +})(); diff --git a/d2ice.att.io/app/main/activation/login/login.html b/d2ice.att.io/app/main/activation/login/login.html new file mode 100755 index 00000000..d095fda1 --- /dev/null +++ b/d2ice.att.io/app/main/activation/login/login.html @@ -0,0 +1,90 @@ + + + +
+ +
+
+ +
+
+ +
diff --git a/d2ice.att.io/app/main/activation/login/login.less b/d2ice.att.io/app/main/activation/login/login.less new file mode 100755 index 00000000..9dd6a9f7 --- /dev/null +++ b/d2ice.att.io/app/main/activation/login/login.less @@ -0,0 +1,109 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.login { + + .login-form { + margin-top: 20px; + } + + .btn { + width: 100%; + } + + .btn-primary { + border: 1px solid #8799A3; + border-radius: 6px; + background: #1E79B0; /* For browsers that do not support gradients */ + background: -webkit-linear-gradient(#1E79B0, #62ADD5); /* For Safari 5.1 to 6.0 */ + background: -o-linear-gradient(#1E79B0, #62ADD5); /* For Opera 11.1 to 12.0 */ + background: -moz-linear-gradient(#1E79B0, #62ADD5); /* For Firefox 3.6 to 15 */ + background: linear-gradient(#1E79B0, #62ADD5); /* Standard syntax (must be last) */ + } + + a.register { + text-decoration: underline; + float: right; + margin: 10px 0 0 0; + } + + + .leftLink + { + padding-top:5px; + width:50%; + text-align:left; + float:left; + + a, + a:hover, + a:active, + a:focus + { + .m_14_r; + cursor: pointer; + } + + a{ + text-decoration:underline; + } + } + + .rightLink + { + font-size:14px; + padding-top:5px; + width:50%; + text-align:right; + float:left; + + a, + a:hover, + a:active, + a:focus + { + .m_14_r; + cursor: pointer; + } + + a{ + text-decoration:underline; + } + } + +} diff --git a/d2ice.att.io/app/main/activation/login/login.module.js b/d2ice.att.io/app/main/activation/login/login.module.js new file mode 100755 index 00000000..9953063b --- /dev/null +++ b/d2ice.att.io/app/main/activation/login/login.module.js @@ -0,0 +1,68 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.activation.login', []) + .config(config); + + function config($stateProvider) { + + $stateProvider + .state('app.login', { + url: '/login{engagement_uuid: (?:/[^/]+)?}', + views: { + 'main@': { + templateUrl: 'core/layouts/full-page-with-header/full-page-with-header.html', + controller: 'MainController as vm' + }, + 'content@app.login': { + templateUrl: 'main/activation/login/login.html', + controller: 'LoginController as vm' + } + }, + params: {message: null, activation_success: undefined}, + bodyClass: 'login' + }); + + } + +})(); diff --git a/d2ice.att.io/app/main/activation/register/register.controller.js b/d2ice.att.io/app/main/activation/register/register.controller.js new file mode 100755 index 00000000..e4e525a7 --- /dev/null +++ b/d2ice.att.io/app/main/activation/register/register.controller.js @@ -0,0 +1,122 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.activation.register') + .controller('RegisterController', ["usersService", "$state", "$location", "vfService", "$rootScope", + "toastService", "$log",'$i18next', RegisterController]); + + function RegisterController(usersService, $state, $location, vfService, $rootScope, toastService, $log,$i18next) { + + var vm = this; + vm.data = {}; + var programName = $i18next.t('program.name'); + var init = function() + { + + $rootScope.headerTitle = "Sign Up"; + $rootScope.headerSubTitle = "Please use the form to Sign Up to " +programName; + + usersService.resetUserData(); + + var companyParam = $location.search().company; + + vm.data.full_name = $location.search().full_name; + vm.data.email = $location.search().email; + vm.data.phone_number = $location.search().phone_number; + + $rootScope.ice.loader.show = true; + vfService.getCompanies() + .then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 200){ + vm.vendors = response.data; + if (companyParam != undefined) { + angular.forEach(vm.vendors, function (value, key) { + if (value.uuid === companyParam) { + vm.data.company = value.name; + }; + }); + } + } + }) + .catch(function (error){ + $rootScope.ice.loader.show = false; + $log.error(error); + }); + }; + + vm.submitForm = function () { + if(grecaptcha.getResponse().length != 0) + { + $rootScope.ice.loader.show = true; + if (vm.data.regular_email_updates != true) { + vm.data.regular_email_updates = false; + } + vm.data.inviter_uuid = $location.search().inviter_uuid; + vm.data.eng_uuid = $location.search().eng_uuid; + vm.data.invitation = $location.search().invitation; + vm.data.is_contact_user = ($location.search().is_contact_user === "true"); + vm.email = $location.search().email; + + usersService.register(vm.data) + .then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 200) { + $state.go('app.resend_activation'); + } + }) + .catch(function (error) { + toastService.setToast(error.message, 'danger'); + $rootScope.ice.loader.show = false; + $log.error(error.message); + }); + $rootScope.PleaseFill = ""; + } else { + toastService.setToast('Please fill CAPTCHA!', 'danger'); + $log.warn("Please fill CAPTCHA!"); + } + }; + + init(); + } +})(); diff --git a/d2ice.att.io/app/main/activation/register/register.html b/d2ice.att.io/app/main/activation/register/register.html new file mode 100755 index 00000000..b6af8ce4 --- /dev/null +++ b/d2ice.att.io/app/main/activation/register/register.html @@ -0,0 +1,127 @@ + + + +
+ +
+
+ +
+
+ + +
+ Please select a company +
+
+ +
+ + +
+ Name is a required field. + Full Name is too short. + Full Name is too long. + Full Name must be alphanumeric +
+
+ +
+ + +
+ Email is a required field. + Enter a valid email. +
+
+ +
+ + +
+ Phone is a required field. + Phone is too short. + Phone is too long. + Phone format invalid +
+
+ +
+ + +
+ Password is a required field. + Password is too short. + Password is too long. +
+
+ +
+  I agree to receive regular email updates from AT&T {{'program.name' | i18next}}. +
+ + + +
+ +
+
+ + {{PleaseFill}} + + + + +
+
+
+ +
diff --git a/d2ice.att.io/app/main/activation/register/register.less b/d2ice.att.io/app/main/activation/register/register.less new file mode 100755 index 00000000..7df0cce9 --- /dev/null +++ b/d2ice.att.io/app/main/activation/register/register.less @@ -0,0 +1,100 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.register { + .phone-place-holder::-webkit-input-placeholder { + opacity: 0.7; + } + .phone-place-holder::-moz-placeholder { + opacity: 0.7; + } + .phone-place-holder:-moz-placeholder { + opacity: 0.7; + } + .phone-place-holder:-ms-input-placeholder { + opacity: 0.7; + } + + .register-form { + margin-top: 20px; + } + + .btn { + width: 100%; + } + + .btn-primary { + border: 1px solid #8799A3; + border-radius: 6px; + background: #1E79B0; /* For browsers that do not support gradients */ + background: -webkit-linear-gradient(#1E79B0, #62ADD5); /* For Safari 5.1 to 6.0 */ + background: -o-linear-gradient(#1E79B0, #62ADD5); /* For Opera 11.1 to 12.0 */ + background: -moz-linear-gradient(#1E79B0, #62ADD5); /* For Firefox 3.6 to 15 */ + background: linear-gradient(#1E79B0, #62ADD5); /* Standard syntax (must be last) */ + } + + a, + a:hover, + a:active, + a:focus + { + .m_14_r; + cursor: pointer; + } + + a.login, a.login:hover{ + .m_14_r; + float: right; + margin: 5px 0 0 0; + } + + a.login{ + text-decoration: underline; + } + + .form-group { + a { + font-size:14px; + text-decoration:underline; + + &:hover { + font-size:14px; + } + } + } +} diff --git a/d2ice.att.io/app/main/activation/register/register.module.js b/d2ice.att.io/app/main/activation/register/register.module.js new file mode 100755 index 00000000..e463ceb1 --- /dev/null +++ b/d2ice.att.io/app/main/activation/register/register.module.js @@ -0,0 +1,67 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.activation.register', []) + .config(config); + + function config($stateProvider) { + + $stateProvider + .state('app.register', { + url : '/signUp', + views : { + 'main@': { + templateUrl: 'core/layouts/full-page-with-header/full-page-with-header.html', + controller : 'MainController as vm' + }, + 'content@app.register': { + templateUrl: 'main/activation/register/register.html', + controller : 'RegisterController as vm' + } + }, + bodyClass: 'register' + }); + + } + +})(); diff --git a/d2ice.att.io/app/main/activation/resendActivation/resendActivation.controller.js b/d2ice.att.io/app/main/activation/resendActivation/resendActivation.controller.js new file mode 100755 index 00000000..374d9005 --- /dev/null +++ b/d2ice.att.io/app/main/activation/resendActivation/resendActivation.controller.js @@ -0,0 +1,79 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + angular + .module('ice.activation.resendActivation') + .controller('resendActivationController', ["usersService", "toastService", "$rootScope", "$state", "$log", + resendActivationController]); + + function resendActivationController(usersService, toastService, $rootScope, $state, $log) { + var vm = this; + vm.data = []; + + var init = function() { + $rootScope.headerTitle = "Activate Your Account"; + $rootScope.headerSubTitle = "Please follow the instructions below to activate your account."; + + if ($state.params.message){ + toastService.setToast($state.params.message, 'danger'); + } + + vm.activated=false; //True false + vm.showHideMsg = false; + vm.showHideWait = false; + }; + + vm.submitForm = function () { + $rootScope.ice.loader.show = true; + usersService.resendActivationMail() + .then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 200) { + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + }; + + init(); + } +})(); diff --git a/d2ice.att.io/app/main/activation/resendActivation/resendActivation.html b/d2ice.att.io/app/main/activation/resendActivation/resendActivation.html new file mode 100755 index 00000000..cc2cc91b --- /dev/null +++ b/d2ice.att.io/app/main/activation/resendActivation/resendActivation.html @@ -0,0 +1,61 @@ + + + +
+ +
+
+
+

+ You have successfully created your account! To begin using this site you will need to activate your account via the email we have just sent to your email address. +

+ Please note that sometimes activation emails end up in users spam/junk folders, so please check there. +

+ If you have not received it, please click the resend the Activation Email button below. +

+ + + +
+
+
+
diff --git a/d2ice.att.io/app/main/activation/resendActivation/resendActivation.less b/d2ice.att.io/app/main/activation/resendActivation/resendActivation.less new file mode 100755 index 00000000..5d2277cb --- /dev/null +++ b/d2ice.att.io/app/main/activation/resendActivation/resendActivation.less @@ -0,0 +1,67 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.resend-activation { + + .active-form { + margin-top: 20px; + } + + .btn { + width: 100%; + } + + .btn-primary { + border: 1px solid #8799A3; + border-radius: 6px; + background: #1E79B0; /* For browsers that do not support gradients */ + background: -webkit-linear-gradient(#1E79B0, #62ADD5); /* For Safari 5.1 to 6.0 */ + background: -o-linear-gradient(#1E79B0, #62ADD5); /* For Opera 11.1 to 12.0 */ + background: -moz-linear-gradient(#1E79B0, #62ADD5); /* For Firefox 3.6 to 15 */ + background: linear-gradient(#1E79B0, #62ADD5); /* Standard syntax (must be last) */ + } + + .leftLink{ + padding-top:5px; + width:50%; + text-align:left; + float:left; + + } + +} diff --git a/d2ice.att.io/app/main/activation/resendActivation/resendActivation.module.js b/d2ice.att.io/app/main/activation/resendActivation/resendActivation.module.js new file mode 100755 index 00000000..90a28339 --- /dev/null +++ b/d2ice.att.io/app/main/activation/resendActivation/resendActivation.module.js @@ -0,0 +1,68 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.activation.resendActivation', []) + .config(config); + + function config($stateProvider) { + + $stateProvider + .state('app.resend_activation', { + url : '/resendActivation', + views : { + 'main@': { + templateUrl: 'core/layouts/full-page-with-header/full-page-with-header.html', + controller : 'MainController as vm' + }, + 'content@app.resend_activation': { + templateUrl: 'main/activation/resendActivation/resendActivation.html', + controller : 'resendActivationController as vm' + } + }, + params: {message: null}, + bodyClass: 'resend-activation' + }); + + } + +})(); diff --git a/d2ice.att.io/app/main/activation/resetPassword/resetPassword.controller.js b/d2ice.att.io/app/main/activation/resetPassword/resetPassword.controller.js new file mode 100755 index 00000000..9702c2e4 --- /dev/null +++ b/d2ice.att.io/app/main/activation/resetPassword/resetPassword.controller.js @@ -0,0 +1,95 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + angular + .module('ice.activation.resetPassword') + .controller('ResetPasswordController', ["$state", "usersService", "toastService", "$rootScope", "$window", + "$log", ResetPasswordController]); + + function ResetPasswordController($state, usersService, toastService, $rootScope, $window,$log) + { + var vm = this; + vm.data = {}; + var ngReq = true; + $rootScope.headerTitle = "Reset Your Password"; + $rootScope.headerSubTitle = "Please follow the instructions below to reset your password"; + + if($state.params.message!=undefined && $state.params.message!=""){ + toastService.setToast($state.params.message, 'danger'); + $rootScope.ice.loader.show = false; + $log.warn($state.params.message); + } + + vm.submitForm = function() + { + $rootScope.ice.loader.show = true; + var jsonEmail = + { + email : vm.data.email + }; + toastService.clearToast() + usersService.sendResetPwdInstructions(jsonEmail) + .then(function (response) { + if (response.status === 200) { + toastService.setToast('An email with detailed instructions on how to reset your password was sent to your Email.', 'success'); + ngReq = false; + vm.data.email = ""; + $rootScope.ice.loader.show = false; + } + else + { + toastService.setToast('Error sending reset password instructions email.', 'danger'); + $rootScope.ice.loader.show = false; + } + }) + .catch(function (error) + { + toastService.setToast(error.message, 'danger'); + $rootScope.ice.loader.show = false; + $log.error(error.message); + }); + }; + + vm.sendMail = function() + { + $window.open("mailto:d2ice@att.com","_self"); + } + } +})(); diff --git a/d2ice.att.io/app/main/activation/resetPassword/resetPassword.html b/d2ice.att.io/app/main/activation/resetPassword/resetPassword.html new file mode 100755 index 00000000..41d90a69 --- /dev/null +++ b/d2ice.att.io/app/main/activation/resetPassword/resetPassword.html @@ -0,0 +1,64 @@ + + + +
+ +
+
+
+
+ + +
+ Email is a required field. + Enter a valid email. +
+
+ + + + +
+
+
+ +
diff --git a/d2ice.att.io/app/main/activation/resetPassword/resetPassword.less b/d2ice.att.io/app/main/activation/resetPassword/resetPassword.less new file mode 100755 index 00000000..18f79364 --- /dev/null +++ b/d2ice.att.io/app/main/activation/resetPassword/resetPassword.less @@ -0,0 +1,84 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.resetPassword { + + .resetPassword-form { + margin-top: 20px; + } + + .btn { + width: 100%; + } + + .btn-primary { + border: 1px solid #8799A3; + border-radius: 6px; + background: #1E79B0; /* For browsers that do not support gradients */ + background: -webkit-linear-gradient(#1E79B0, #62ADD5); /* For Safari 5.1 to 6.0 */ + background: -o-linear-gradient(#1E79B0, #62ADD5); /* For Opera 11.1 to 12.0 */ + background: -moz-linear-gradient(#1E79B0, #62ADD5); /* For Firefox 3.6 to 15 */ + background: linear-gradient(#1E79B0, #62ADD5); /* Standard syntax (must be last) */ + } + + a.register { + text-decoration: underline; + float: right; + margin: 10px 0 0 0; + } + + .leftLink { + width:100%; + padding-top:5px; + text-align:left; + + a, + a:hover, + a:active, + a:focus + { + .m_14_r; + cursor: pointer; + } + + a{ + text-decoration:underline; + } + } + +} diff --git a/d2ice.att.io/app/main/activation/resetPassword/resetPassword.module.js b/d2ice.att.io/app/main/activation/resetPassword/resetPassword.module.js new file mode 100755 index 00000000..792e51dd --- /dev/null +++ b/d2ice.att.io/app/main/activation/resetPassword/resetPassword.module.js @@ -0,0 +1,68 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.activation.resetPassword',[]) + .config(config); + + function config($stateProvider) { + + $stateProvider + .state('app.resetPassword', { + url: '/resetPassword', + views: { + 'main@': { + templateUrl: 'core/layouts/full-page-with-header/full-page-with-header.html', + controller: 'MainController as vm' + }, + 'content@app.resetPassword': { + templateUrl: 'main/activation/resetPassword/resetPassword.html', + controller: 'ResetPasswordController as vm' + } + }, + params: {message: null}, + bodyClass: 'resetPassword' + }); + + } + +})(); diff --git a/d2ice.att.io/app/main/activation/terms/terms.controller.js b/d2ice.att.io/app/main/activation/terms/terms.controller.js new file mode 100755 index 00000000..9eabdc25 --- /dev/null +++ b/d2ice.att.io/app/main/activation/terms/terms.controller.js @@ -0,0 +1,56 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.activation.terms') + .controller('TermsController', ["$rootScope", TermsController]); + + function TermsController($rootScope) + { + var vm = this; + vm.data = {}; + + $rootScope.headerTitle = "Terms of Service"; + $rootScope.headerSubTitle = "Last updated 2016-06-10"; + } + +})(); diff --git a/d2ice.att.io/app/main/activation/terms/terms.html b/d2ice.att.io/app/main/activation/terms/terms.html new file mode 100755 index 00000000..fd39eb99 --- /dev/null +++ b/d2ice.att.io/app/main/activation/terms/terms.html @@ -0,0 +1,105 @@ + +
+ +
+
+ +
+ +

The {{'serviceProvider.name' | i18next}} Domain 2 ICE ({{'program.name' | i18next}}) are maintained by {{'serviceProvider.name' | i18next}} Foundry (“{{'serviceProvider.name' | i18next}}”) for use by any one interested in incubating or validating their Virtual Function (VF) against our Domain 2.0 architecture. When you or any other person, employee or representative authorized by you (collectively referred to as “You” or “Your”) use the {{'serviceProvider.name' | i18next}} Domain 2.0 ICE, You accept the Terms and Conditions stated below (the “Terms and Conditions”).  Do not use the {{'program.name' | i18next}} if You do not agree with these Terms and Conditions.

+ +
    + +
  1. Content Ownership. The {{'serviceProvider.name' | i18next}} Domain 2.0 ICE (“{{'program.name' | i18next}}”) provide You access to technical resources, such as product, service, and network information, and community forums and contain trademarks, service marks, logos, copyrights, other intellectual property, including, without limitation, text, data, graphics, audio, video, and product, service, network, process, and technical descriptions and information (collectively, the "Content") owned by, licensed to, and/or supplied to {{'serviceProvider.name' | i18next}}. As between You, {{'serviceProvider.name' | i18next}} its third party Content licensors and suppliers, {{'serviceProvider.name' | i18next}} or such third party Content licensors and suppliers are the sole owners of all Content on the {{'program.name' | i18next}}, including, without limitation, all copyrights, trademarks, service marks, patent, trade secret, and other intellectual property rights thereto. {{'serviceProvider.name' | i18next}} is the sole owner of the {{'program.name' | i18next}}. The {{'program.name' | i18next}} may contain links and references to third-party websites, which are provided for the convenience.  {{'serviceProvider.name' | i18next}} is not responsible for the content or information contained on such third party websites

  2. + +
  3. Account Registration. In order to use certain features of the {{'program.name' | i18next}}, You will be asked to create a user Account and password (an "Account") and provide certain information ("Registration Data"). You agree: (i) that the Registration Data You provide will be true, accurate, current and complete at the time You provide it; (ii) to maintain and update such Registration Data to keep it true, accurate, current and complete; and (iii) that {{'serviceProvider.name' | i18next}} may contact You and require You to confirm some or all of Your Registration Data before using certain features of the {{'program.name' | i18next}}. You are responsible for maintaining the confidentiality of Your Account credentials and for all activities, charges and/or liabilities that occur from Your Account, whether or not authorized by You. You must immediately notify {{'serviceProvider.name' | i18next}} of any unauthorized use of Your Account credentials or any other breach of security of which You become aware. We will not be liable for any loss or damage arising from Your failure to comply with this section.

  4. + +
  5. Limited License. Subject to Your compliance with these Terms and Conditions, and in consideration of Your promises reflected herein, {{'serviceProvider.name' | i18next}} grants to You a limited, non-exclusive, revocable, non-transferable license to access, view and use the {{'program.name' | i18next}}, including the Content contained therein, subject to any access restrictions or fees {{'serviceProvider.name' | i18next}} may establish from time to time. You may download, view, copy and print the Content solely for Your own use; provided that, without the express prior written permission of {{'serviceProvider.name' | i18next}}, such Content may not be adapted, modified, published, displayed, transmitted, transferred, shared with or disseminated to anyone for any purpose which is inconsistent with the business purpose of these {{'program.name' | i18next}}, facilitates unfair competition with these {{'program.name' | i18next}}, or exploits these {{'program.name' | i18next}} in any way or which is inappropriate under applicable US or international law. You are not permitted to distribute, assign, transfer or sublicense any right to use the {{'program.name' | i18next}}, either in whole or in part, to any third party. 

  6. + +
  7. Use Restrictions. Notwithstanding the foregoing license grant, You may not resell, redistribute, broadcast or transfer the Content or use the Content in a searchable, machine-readable database or file except through the authorized access to these {{'program.name' | i18next}}. Unless separately and specifically authorized in writing by {{'serviceProvider.name' | i18next}}, You may not rent, lease, sublicense, distribute, transfer, copy, reproduce, publicly display, publish, adapt, modify, create derivative works, mine, harvest, collect, store or time-share these {{'program.name' | i18next}}, any part thereof, or any of the Content received or accessed therefrom to or through any person or entity.  Access to any restricted area of the {{'program.name' | i18next}} without the authorization of {{'serviceProvider.name' | i18next}} is prohibited. You agree to use these {{'program.name' | i18next}}, including, without limitation, any restricted area, and the Content contained herein for lawful purposes only. You may not utilize logos, marks, or other distinctive graphics, video, or audio material in Your links, without {{'serviceProvider.name' | i18next}}’s express written permission, which {{'serviceProvider.name' | i18next}} may withhold in its discretion. You may not link in any manner reasonably likely to (i) imply affiliation with or endorsement or sponsorship by {{'serviceProvider.name' | i18next}}, (ii) cause confusion, mistake, or deception, (iii) dilute {{'serviceProvider.name' | i18next}}'s trademarks or service marks, or (iv) otherwise violate state or federal law. In addition, You may only link to the home page of the {{'serviceProvider.name' | i18next}} {{'program.name' | i18next}} unless {{'serviceProvider.name' | i18next}} authorizes You to do otherwise. You may not use spiders, robots, data mining techniques or other automated devices or programs to catalog, download or programs to catalog, download or otherwise reproduce, store or distribute Content available on the {{'serviceProvider.name' | i18next}} {{'program.name' | i18next}}.  You may not use any such automated means to manipulate the {{'serviceProvider.name' | i18next}} {{'program.name' | i18next}} or attempt to exceed the limited authorization and access granted to You under these Terms and Conditions.  You may not resell use of, or access to, the {{'serviceProvider.name' | i18next}} {{'program.name' | i18next}} to any third party. + +

  8. Forums. {{'serviceProvider.name' | i18next}} may make forums available within the {{'serviceProvider.name' | i18next}} {{'program.name' | i18next}} to help developers request and provide development help and share tips.  By submitting comments, posts, content, information, or messages (“Posts”) to such forums, You represent and warrant that: (i) You own and control all rights to the content in Your Posts, that You transmit or otherwise make available, or You have the lawful right to distribute, reproduce, and provide such content; (ii) the Posts are accurate and not misleading; and (iii) providing such Posts does not: (a) violate this Agreement or (b) violate the rights of, or cause any injury to, any person or entity. Further, You grant us a royalty-free, perpetual, irrevocable license to use such Posts.  Also, You understand and agree that {{'serviceProvider.name' | i18next}} retains the right to reformat, excerpt or translate any Posts submitted by You. You understand and agree that {{'serviceProvider.name' | i18next}} will not be liable for any Posts publicly posted or privately transmitted on these Web Sites. You understand and agree that we cannot guarantee the identity, statements or representations of any other users with whom You may interact in the course of using these Web Sites. Additionally, we cannot guarantee that any Posts obtained from our users or otherwise, is accurate, complete, authentic, current or reliable. Your use of the forums, if any, will further be governed by the {{'serviceProvider.name' | i18next}} Community Rules available for review within the forums.  Those rules are incorporated into these Terms and Conditions by this reference.  Users should be aware that forums and discussion groups are public and not private communications. Further, users acknowledge that Postings by other users are not endorsed by {{'serviceProvider.name' | i18next}}, and that such Posts shall not be considered as having been reviewed, screened or approved by {{'serviceProvider.name' | i18next}}.

    + +

    You agree not to submit or transmit any Post that (a) is libelous, defamatory, vulgar or obscene, pornographic, sexually offensive or explicit, harmful or harassing, threatening, hateful, racially, culturally, ethnically or otherwise objectionable or offensive, discriminatory or abusive; (b) violates any law or regulation or the rights of others; (c) infringes any copyright, trademark or other intellectual property right, or any proprietary or personal rights or confidentiality obligations of others; or (d)  is a solicitation for funding, advertising or solicitation for goods or services; or (e) (iv) which is used to unlawfully collude against another person in restraint of trade and competition.  You are solely responsible and liable for any such activity, behavior, use and conduct.  This means that You, and not {{'serviceProvider.name' | i18next}} or its, suppliers, or licensors, are entirely responsible for all Posts You submit or transmit.  {{'serviceProvider.name' | i18next}} reserves the right to filter, edit, or control all Your Posts and does not guarantee the accuracy, integrity or quality of Your Post.  Under no circumstances will {{'serviceProvider.name' | i18next}} or its suppliers, or licensors be liable in any way to You for any Posts, including, but not limited to, any errors or omissions in any content, information, or messages, or any loss or damage of any kind incurred as a result of the use of any such content, information or messages posted, emailed, transmitted.  You shall be solely liable for any damages resulting from any infringement of copyright, trademark or other proprietary right, or any other harm resulting from Your Post to a forum.  {{'serviceProvider.name' | i18next}} does not and cannot review every Post by You on forums and is not responsible for any Post.  {{'serviceProvider.name' | i18next}} reserves the right to delete, move or edit, at its sole discretion, any Post that does not comply with this paragraph. You acknowledge that any Post may be edited, removed, modified, published, transmitted and displayed by {{'serviceProvider.name' | i18next}}.   {{'serviceProvider.name' | i18next}} is under no obligation to use any Post you transmit or submit. You agree that {{'serviceProvider.name' | i18next}} is not under any obligation of confidentiality, express or implied, with respect to Your Post.

    + +

    Any Post, comments, content, information or materials sent to us, including, but not limited to, data,  ideas, answers, questions, comments, suggestions, feedback or the like,  (collectively, "Feedback"), is non-confidential and shall become our sole property. We shall have no obligation to You of any kind, monetary or non-monetary, with respect to such Feedback and shall be free to reproduce, use, disclose, exhibit, display, transform, create derivative works from and distribute the Feedback to others without limitation or obligation.  You acknowledge that {{'serviceProvider.name' | i18next}} has absolutely no liability for alleged infringement or misappropriation in connection with such information/Post. The submission of such information/Post to {{'serviceProvider.name' | i18next}} will in no way prevent, or require, the purchase, manufacture or use of any products, services, plans or ideas by {{'serviceProvider.name' | i18next}} for any purpose whatsoever.

  9. + +
  10. Consent to Monitoring and Disclosure. You acknowledge that {{'serviceProvider.name' | i18next}} reserves the right, and may from time to time, monitor Your access and use of the {{'program.name' | i18next}} and Your Posts. {{'serviceProvider.name' | i18next}}, at its sole discretion and without further notice to You, may (but is not obligated to) review, censor or prohibit the transmission or receipt of any Post which {{'serviceProvider.name' | i18next}} deems inappropriate or that violates these Terms or Conditions or any {{'serviceProvider.name' | i18next}} Policy. During monitoring, Posts may be examined, recorded, copied, and used for authorized purposes. Your use of the {{'program.name' | i18next}}, authorized or unauthorized, constitutes consent to such monitoring.

  11. + +
  12. Copyright Complaints. {{'serviceProvider.name' | i18next}} respects the intellectual property rights of others. If You believe that Your work has been copied and has been posted, stored or transmitted by or through the {{'program.name' | i18next}} in a way that constitutes copyright infringement, please submit a notification pursuant to the Digital Millennium Copyright Act ("DMCA") in accordance with the process detailed at http://www.att.net/general-info/claims.html and directed to:  Designated Agent: Manager of Security & Copyright Infringement, 1800 Perimeter Park Drive, Suite 100, Morrisville, NC 27560, Phone: (919) 319-5737, Fax: (919) 319-8154, E-mail: copyright@att.com.

  13. + +
  14. Privacy. It is the policy of {{'serviceProvider.name' | i18next}} to respect the privacy of its customers and any persons who visit its web sites.  For this reason, {{'serviceProvider.name' | i18next}} has established a Privacy Policy, the terms of which are available for Your review at:  www.att.com/privacy.  Subject to these Terms and Conditions, the relevant provisions of said Privacy Policy are incorporated by this reference.

  15. + +
  16. Subject to Change. {{'serviceProvider.name' | i18next}} reserves the right to modify these Terms and Conditions, the Privacy Statement, and the business policies and practices associated with the use of these {{'program.name' | i18next}}. Such modifications may include, without limitation, implementation of user priorities, implementation of rules for use by You, and discontinuance of functional aspects of the {{'program.name' | i18next}}, and changes in prices. {{'serviceProvider.name' | i18next}} may also add, withdraw or modify any Content contained within these {{'program.name' | i18next}} at any time in its sole discretion.  Your use of these {{'program.name' | i18next}} is Your agreement to be bound by such changes.

  17. + +
  18. Term. The period during which You are entitled to use the {{'serviceProvider.name' | i18next}} {{'program.name' | i18next}} (“Term”) begins on the date upon which You agree to these Terms and Conditions. {{'serviceProvider.name' | i18next}} may revoke or terminate the License granted in its sole discretion at any time. Without limiting the generality of the foregoing, we may revoke or terminate the License if You: (i) breach any obligation in these Terms and Conditions or in any other agreement between You and us, (ii) violate any policy or guideline applicable to the {{'program.name' | i18next}}, Content, or any other {{'serviceProvider.name' | i18next}} service, or (iii) use these {{'program.name' | i18next}} or Content specifically authorized in these Terms and Conditions, without our prior written permission.   Additionally, either You or {{'serviceProvider.name' | i18next}} may terminate this License at any time without cause, but termination of this License will not relieve You of the obligations under these Terms and Conditions that You assumed by using these {{'program.name' | i18next}}.

  19. + +
  20. Termination of {{'serviceProvider.name' | i18next}} Web Site and Service. {{'serviceProvider.name' | i18next}} may discontinue, terminate, suspend or shut down the {{'serviceProvider.name' | i18next}} Web Site, {{'program.name' | i18next}}, particular {{'program.name' | i18next}}, and/or remove Content at any time and for any or no reason. We are not obligated to give notice of such discontinuation, termination, suspension, removal or shut-down.  Your License shall automatically terminate, if {{'serviceProvider.name' | i18next}} discontinues, terminates, suspends or shut downs the {{'serviceProvider.name' | i18next}} Web Site.

  21. + +
  22. Application Agreement(s).  These Terms and Conditions relate solely to Your access to, and use of, the {{'program.name' | i18next}} and Content.  No commitments, obligations, terms or restrictions are imposed upon either party with respect to any Application(s) by virtue of these Terms and Conditions.  Any agreements between You and {{'serviceProvider.name' | i18next}} regarding Applications will be governed by a separate agreement(s).

  23. + +
  24. Trademarks. The {{'serviceProvider.name' | i18next}} name, trade names, trademarks and logo, as well as all related product and service names, design marks and slogans, are the property of {{'serviceProvider.name' | i18next}}, and may not be used by You for any purpose unless specifically authorized in writing, and in advance, by {{'serviceProvider.name' | i18next}}.  All other names, marks and logos are the names, marks and logos of their respective owners.  All right, title and interest, including, without limitation, all copyrights, trademarks and other intellectual property rights, in the {{'program.name' | i18next}} and Content belong to {{'serviceProvider.name' | i18next}}, its licensors, or suppliers.

  25. + +
  26. Connectivity; Delay in Service. You are responsible for all costs and expenses associated with establishing and maintaining Your connection to these {{'program.name' | i18next}}. Neither {{'serviceProvider.name' | i18next}}, nor any of its licensors or suppliers (including its and their officers, directors, managers, employees, affiliates, agents, or representatives) shall be liable for any loss or liability resulting, directly or indirectly, from delays or interruptions due to electric or mechanic equipment failures,  interconnection problems, defects, weather, strikes, walkouts, fire, acts of nature, riots, armed conflicts, acts of war or other like causes. {{'serviceProvider.name' | i18next}} shall have no responsibility to provide You access to these {{'program.name' | i18next}} during any such interruption.

  27. + +
  28. Limitation of Liability. YOU ASSUME FULL RESPONSIBILITY FOR IMPLEMENTING SUFFICIENT PROCEDURES AND CHECKS TO SATISFY YOUR REQUIREMENTS FOR ACCURACY AND SUITABILITY OF THESE {{'program.name' | i18next}} AND THE CONTENT, AND FOR MAINTAINING ANY MEANS WHICH YOU MAY REQUIRE FOR THE RECONSTRUCTION OF LOST DATA OR SUBSEQUENT MANIPULATIONS OR ANALYSES OF THE CONTENT PROVIDED UNDER THIS AGREEMENT. YOU ACKNOWLEDGE AND AGREE THAT {{'serviceProvider.name' | i18next}}, ITS AFFILIATES, LICENSORS, AND SUPPLIERS (INCLUDING ITS OR THEIR OFFICERS, DIRECTORS, MANAGERS, EMPLOYEES, AFFILIATES, AGENTS,  AND REPRESENTATIVES (“LIMITED LIABILITY PARTIES” FOR THE REMAINDER OF THIS PARAGRAPH) WILL NOT BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM AN INABILITY TO ACCESS OR USE THE {{'program.name' | i18next}} AND/OR CONTENT AVAILABLE ON OR ACCESSIBLE THROUGH THE {{'program.name' | i18next}}. THESE LIMITATIONS ON THE LIABILITY OF THE LIMITED LIABILITY PARTIES APPLY WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE, STRICT LIABILITY OR OTHER TORTIOUS ACTION ARISING OUT OF OR IN CONNECTION WITH THE CONTENT AVAILABLE ON OR ACCESSIBLE THROUGH THE {{'program.name' | i18next}} AND THE LIMITATIONS APPLY EVEN IF LIMITED LIABILITY PARTIES HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.  YOU AGREE AND ACKNOWLEDGE THAT THESE LIMITATIONS ON THE LIABILITY OF LIMITED LIABILITY PARTIES REFLECT A REASONABLE ALLOCATION OF RISK AND THAT SUCH ALLOCATION OF RISK IS A SIGNIFICANT INDUCMENT FOR {{'serviceProvider.name' | i18next}} TO ALLOW YOU TO ACCESS AND USE THE {{'program.name' | i18next}}.  IN NO EVENT WILL THE AGGREGATE, TOTAL LIABILITY OF THE LIMITED LIABILITY PARTIES FOR DAMAGES, INJURY, LOSSES AND CAUSES OF ACTION, WHETHER IN CONTRACT, TORT OR OTHERWISE, ARISING FROM OR RELATING TO ACCESS OR USE OF THE {{'program.name' | i18next}} EXCEED TEN DOLLARS ($10.00). BECAUSE SOME JURISDICTIONS DO NOT ALLOW THE LIMITATION OR EXCLUSION OF LIABILITY FOR INCIDENTAL OR CONSEQUENTIAL DAMAGES, SOME OF THE ABOVE LIMITATIONS MAY NOT APPLY IN THOSE JURISDICTIONS. IN SUCH JURISDICTIONS, THE LIMITED LIABILITY PARTIES¿ LIABILITY IS LIMITED TO THE GREATEST EXTENT PERMITTED BY LAW.

  29. + +
  30. Disclaimer of Warranties. BROWSING AND USE OF THE {{'program.name' | i18next}} AND CONTENT IS AT YOUR OWN RISK. YOU ACKNOWLEDGE THAT INACCURACIES MAY OCCUR, AND THAT {{'serviceProvider.name' | i18next}} AND ITS LICENSORS AND SUPPLIERS DO NOT WARRANT THE ACCURACY OR SUITABILITY OF THE {{'program.name' | i18next}} AND CONTENT FOR ANY PURPOSE. FURTHERMORE, THE {{'program.name' | i18next}} AND CONTENT MAY CONTAIN LINKS TO THIRD PARTY WEBSITES NOT UNDER THE CONTROL OR OPERATION OF {{'serviceProvider.name' | i18next}}. {{'serviceProvider.name' | i18next}} PROVIDES ANY SUCH LINKS ONLY AS A CONVENIENCE FOR YOU AND IS NOT RESPONSIBLE FOR ANY SUCH LINKED SITES, THE CONTENT ON ANY SUCH LINKED SITES OR A SITE LINKED TO OR FROM ANY SUCH LINKED SITES. YOU ASSUME ALL RESPONSIBILITY AND RISK FOR USE OF THE {{'program.name' | i18next}}, THE CONTENT AND THE INTERNET GENERALLY. ACCESS TO AND/OR USE OF THE {{'program.name' | i18next}} AND CONTENT PROVIDED ON OR AVAILABLE THROUGH THE {{'program.name' | i18next}} ARE PROVIDED OR MADE AVAILABLE ON AN ¿AS IS¿ AND ¿AS AVAILABLE¿ BASIS WITHOUT WARRANTIES OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, WARRANTIES OF TITLE, NON-INFRINGEMENT OR IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. NO ADVICE OR INFORMATION GIVEN BY {{'serviceProvider.name' | i18next}}, ITS AFFILIATES OR IT LICENSORS, OR SUPPLIERS WILL CREATE ANY WARRANTY. FURTHER, NEITHER {{'serviceProvider.name' | i18next}} NOR ITS AFFILIATES, LICENSORS, OR SUPPLIERS WARRANT THAT CONTENT PROVIDED ON OR AVAILABLE THROUGH THE {{'program.name' | i18next}} WILL BE UN-INTERRUPTABLE, ACCURATE, COMPLETE, USEFUL, FUNCTIONAL OR ERROR FREE, OR THAT CONTENT OR MATERIAL PROVIDED ON OR AVAILABLE THROUGH THE {{'program.name' | i18next}} IS FREE OF VIRUSES OR OTHER HARMFUL COMPONENTS. ANY CONTENT AVAILABLE ON OR ACCESSIBLE THROUGH THE {{'program.name' | i18next}} MAY INCLUDE TECHNICAL INACCURACIES OR TYPOGRAPHICAL ERRORS.

  31. + +
  32. Indemnification. You agree to release, indemnify, defend and hold {{'serviceProvider.name' | i18next}}, its affiliates and/or its licensors, and suppliers and their affiliates, officers, directors, managers, employees, agents and representatives  harmless from losses, damages, claims, demands, suits, liabilities, fines, penalties, and expenses, including reasonable attorneys’ fees, made by any third party due to or arising out of Your access to or use of the {{'serviceProvider.name' | i18next}} {{'program.name' | i18next}} or the Content, the violation by You of these Terms and Conditions, the infringement by You of any intellectual property or other right of any person or entity, and/or any Posts You submit or transmit to any Forums. + +

  33. Severability. If any of these Terms and Conditions are held to be invalid or unenforceable with respect to a party, the remainder of these Terms and Conditions, or the application of such provision to persons other than those to whom it is held invalid or unenforceable shall not be affected and each remaining provision of these Terms and Conditions shall be valid and enforceable to the fullest extent permitted by law.

  34. + +
  35. Publicity. Nothing contained in these Terms and Conditions will be construed as granting to You any right to use or refer to in advertising, publicity, promotion, marketing or other activities, any name, trade name, trade or service mark or any other designation of {{'serviceProvider.name' | i18next}}, its licensors, or suppliers, including any contraction, abbreviation or simulation of any kind of the foregoing, unless specifically authorized in writing, and in advance, by {{'serviceProvider.name' | i18next}}, its licensors, or suppliers.

  36. + +
  37. International Use. {{'serviceProvider.name' | i18next}} controls and operates these {{'program.name' | i18next}} from its offices in the United States of America. {{'serviceProvider.name' | i18next}} does not represent that Content accessible via the {{'program.name' | i18next}} is appropriate or available for use in all geographic locations, especially some locations outside the United States, and accessing such from certain locations may be illegal and prohibited.  If You access or use such Content from such locations, You are acting on Your own initiative, and {{'serviceProvider.name' | i18next}} is not responsible for Your compliance with local laws or other applicable legal or regulatory restrictions.  You agree that You will not access or use the {{'program.name' | i18next}} or Content where prohibited by applicable law, rule or regulation.  You represent and warrant that You are not (a) located in any country that is subject to a U.S. Government embargo, or that has been designated by the U.S. Government as a “terrorist supporting” country, or (b) listed on any U.S. Government list of prohibited or restricted parties including the Treasury Department’s list of Specially Designated Nationals or the U.S. Department of Commerce Denied Persons List or Entity List. You also agree that You will not use the {{'program.name' | i18next}} or Content for any purposes prohibited by United States law.

  38. + +
  39. Governing Law. The laws of the State of Texas, excluding its conflicts-of-law rules, shall govern this Agreement and Your use of these {{'program.name' | i18next}} and Content. You agree that any claim or dispute with {{'serviceProvider.name' | i18next}} relating in any way to Your use of the {{'program.name' | i18next}} or Content shall be commenced and heard in the state or federal courts of the State of Texas, County of Dallas, and You agree and expressly consent to the exercise of personal jurisdiction in the courts of the State of Texas, in connection with any such dispute.  You and {{'serviceProvider.name' | i18next}} agree that any cause of action arising out of or related to or use of the {{'program.name' | i18next}} or Content  must commence within one (1) year after the cause of action arises.  Otherwise, such cause of action is permanently barred.  Because some jurisdictions do not permit such time bars, this limitation may not apply in all situations.

  40. + +
  41. Miscellaneous. {{'serviceProvider.name' | i18next}}’s failure to exercise or enforce any right or provision of these Terms and Conditions will not constitute a waiver of such right or provision unless acknowledged and agreed to by {{'serviceProvider.name' | i18next}} in writing.  Neither the course of conduct between the parties nor trade practice will act to modify any provision of these Terms and Conditions. 

  42. + +
+ +
+ +
+
+ +
diff --git a/d2ice.att.io/app/main/activation/terms/terms.less b/d2ice.att.io/app/main/activation/terms/terms.less new file mode 100755 index 00000000..e809c9d6 --- /dev/null +++ b/d2ice.att.io/app/main/activation/terms/terms.less @@ -0,0 +1,65 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.terms { + + .terms-form { + margin-top: 20px; + } + + .btn { + width: 100%; + } + + .btn-primary { + border: 1px solid #8799A3; + border-radius: 6px; + background: #1E79B0; /* For browsers that do not support gradients */ + background: -webkit-linear-gradient(#1E79B0, #62ADD5); /* For Safari 5.1 to 6.0 */ + background: -o-linear-gradient(#1E79B0, #62ADD5); /* For Opera 11.1 to 12.0 */ + background: -moz-linear-gradient(#1E79B0, #62ADD5); /* For Firefox 3.6 to 15 */ + background: linear-gradient(#1E79B0, #62ADD5); /* Standard syntax (must be last) */ + } + + a.register { + text-decoration: underline; + float: right; + margin: 10px 0 0 0; + } + +} diff --git a/d2ice.att.io/app/main/activation/terms/terms.module.js b/d2ice.att.io/app/main/activation/terms/terms.module.js new file mode 100755 index 00000000..68a429cf --- /dev/null +++ b/d2ice.att.io/app/main/activation/terms/terms.module.js @@ -0,0 +1,68 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.activation.terms', []) + .config(config); + + function config($stateProvider) { + + $stateProvider + .state('app.terms', { + url: '/terms', + views: { + 'main@': { + templateUrl: 'core/layouts/full-page-with-header/full-page-with-header.html', + controller: 'MainController as vm' + }, + 'content@app.terms': { + templateUrl: 'main/activation/terms/terms.html', + controller: 'TermsController as vm' + } + }, + params: {message: null}, + bodyClass: 'terms' + }); + + } + +})(); diff --git a/d2ice.att.io/app/main/activation/updatePassword/updatePassword.controller.js b/d2ice.att.io/app/main/activation/updatePassword/updatePassword.controller.js new file mode 100755 index 00000000..364dcc77 --- /dev/null +++ b/d2ice.att.io/app/main/activation/updatePassword/updatePassword.controller.js @@ -0,0 +1,95 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.activation.updatePassword') + .controller('UpdatePasswordController', ["$state", "usersService", "localStorageService", "$rootScope", "toastService", "$window", UpdatePasswordController]); + + function UpdatePasswordController($state, usersService, localStorageService, $rootScope, toastService, $window) { + + var vm = this; + vm.data = {}; + + var ngReq = true; + + $rootScope.headerTitle = "Update Your Password"; + $rootScope.headerSubTitle = "Please follow the instructions below to update your password"; + + vm.submitForm = function() + { + $rootScope.ice.loader.show = true; + var jsonPasswordConfirm = + { + password : vm.data.password, + confirm_password : vm.data.confirm_password + } + + usersService.updatePassword(usersService.getUserData().uuid, jsonPasswordConfirm) + .then(function (response) { + if (response.status === 200) { + toastService.setToast('Password was updated Successfully!', 'success'); + ngReq = false; + vm.data.password = ""; + vm.data.confirm_password = ""; + $rootScope.ice.loader.show = false; + //$timeout(function() { $state.go("app.dashboard"); }, 2000); + $state.go('app.dashboard.dashboard', {"messagePass": "Password was updated Successfully!"}); + } + else + { + toastService.setToast('Error updating your password.', 'danger'); + $rootScope.ice.loader.show = false; + } + }) + .catch(function (error) { + toastService.setToast(error.message, 'danger'); + $rootScope.ice.loader.show = false; + }); + }; + + vm.sendMail = function() + { + $window.open("mailto:d2ice@att.com","_self"); + } + } + +})(); diff --git a/d2ice.att.io/app/main/activation/updatePassword/updatePassword.html b/d2ice.att.io/app/main/activation/updatePassword/updatePassword.html new file mode 100755 index 00000000..65569cdb --- /dev/null +++ b/d2ice.att.io/app/main/activation/updatePassword/updatePassword.html @@ -0,0 +1,76 @@ + + + +
+ +
+
+
+
+ + +
+ Password is required field. + Password is too short. + Password is too long. +
+
+ +
+ + +
+ Confirm password is required field. + Passwords do not match. +
+
+ + + + + + +
+
+
+ +
diff --git a/d2ice.att.io/app/main/activation/updatePassword/updatePassword.less b/d2ice.att.io/app/main/activation/updatePassword/updatePassword.less new file mode 100755 index 00000000..a6524df5 --- /dev/null +++ b/d2ice.att.io/app/main/activation/updatePassword/updatePassword.less @@ -0,0 +1,85 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.updatePassword { + + .updatePassword-form { + margin-top: 20px; + } + + .btn { + width: 100%; + } + + .btn-primary { + border: 1px solid #8799A3; + border-radius: 6px; + background: #1E79B0; /* For browsers that do not support gradients */ + background: -webkit-linear-gradient(#1E79B0, #62ADD5); /* For Safari 5.1 to 6.0 */ + background: -o-linear-gradient(#1E79B0, #62ADD5); /* For Opera 11.1 to 12.0 */ + background: -moz-linear-gradient(#1E79B0, #62ADD5); /* For Firefox 3.6 to 15 */ + background: linear-gradient(#1E79B0, #62ADD5); /* Standard syntax (must be last) */ + } + + a.register { + text-decoration: underline; + float: right; + margin: 10px 0 0 0; + } + + .leftLink{ + padding-top:5px; + width:50%; + text-align:left; + float:left; + + a, + a:hover, + a:active, + a:focus + { + .m_14_r; + cursor: pointer; + } + + a{ + text-decoration:underline; + } + } + +} diff --git a/d2ice.att.io/app/main/activation/updatePassword/updatePassword.module.js b/d2ice.att.io/app/main/activation/updatePassword/updatePassword.module.js new file mode 100755 index 00000000..b00e619b --- /dev/null +++ b/d2ice.att.io/app/main/activation/updatePassword/updatePassword.module.js @@ -0,0 +1,68 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.activation.updatePassword', []) + .config(config); + + function config($stateProvider) { + + $stateProvider + .state('app.updatePassword', { + url: '/updatePassword{engagement_uuid: (?:/[^/]+)?}', + views: { + 'main@': { + templateUrl: 'core/layouts/full-page-with-header/full-page-with-header.html', + controller: 'MainController as vm' + }, + 'content@app.updatePassword': { + templateUrl: 'main/activation/updatePassword/updatePassword.html', + controller: 'UpdatePasswordController as vm' + } + }, + params: {message: null,messagePass:null}, + bodyClass: 'updatePassword' + }); + + } + +})(); diff --git a/d2ice.att.io/app/main/admin/admin.module.js b/d2ice.att.io/app/main/admin/admin.module.js new file mode 100755 index 00000000..391461d0 --- /dev/null +++ b/d2ice.att.io/app/main/admin/admin.module.js @@ -0,0 +1,89 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.main.admin') + .config(config); + + function config($stateProvider) { + $stateProvider + .state('app.admin', { + url: '/admin', + views: { + 'navigation@app': { + templateUrl: 'core/navigation/layouts/admin-navigation/navigation.html', + controller: 'adminNavigationController as vm' + } + }, + bodyClass: 'nav-admin', + resolve: { authenticate: authenticate } + }) + .state('app.admin.checklisttemplate', { + url: '/admin/checklist-template', + views: { + 'content@app': { + templateUrl: 'main/admin/checklist-template/checklist-template.html', + controller: 'checklistTemplateController as vm' + } + }, + params: {template_uuid: undefined}, + bodyClass: 'checklist-template', + }); + + function authenticate(usersService, $q, $timeout, $state) { + var result = usersService.isAdmin(usersService.getUserData()); + + if(result === true) { + return $q.when(); + } else { + $timeout(function() { + $state.go('app.login'); + }); + } + + return $q.reject(); + } + } + + + +})(); diff --git a/d2ice.att.io/app/main/admin/checklist-template/checklist-template.controller.js b/d2ice.att.io/app/main/admin/checklist-template/checklist-template.controller.js new file mode 100755 index 00000000..e3033544 --- /dev/null +++ b/d2ice.att.io/app/main/admin/checklist-template/checklist-template.controller.js @@ -0,0 +1,241 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + angular + .module('ice.main.admin') + .controller('checklistTemplateController', ["_", "$scope", "checklistService", "$stateParams", "toastService", + "$uibModal", "$log", checklistTemplateController]); + + function checklistTemplateController(_, $scope, checklistService, $stateParams, toastService, $uibModal, $log) { + var vm = this; + var templateToRevert; + + var init = function(){ + if ($stateParams['template_uuid']){ + vm.inlineEditingElements = {}; + vm.wysiwyg_menu = [ + ['bold', 'italic', 'strikethrough', 'underline'], + ['unordered-list', 'ordered-list', 'outdent', 'indent'] + ]; + + checklistService.getChecklistTemplate($stateParams['template_uuid']) + .then(function (response) { + if (response.status === 200) { + vm.template = response.data; + registerWatchers(); + orderTemplateItems(); + templateToRevert = angular.copy(response.data); + initFirstLineItemSelection(); + } + }) + .catch(function (err){ + $log.error("got error with getChecklistTemplate"); + }); + } + }; + + vm.switchElementInlineEditing = function(elementName) { + vm.inlineEditingElements[elementName] = !vm.inlineEditingElements[elementName]; + }; + + vm.save = function() { + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/general-prompt-modal/general-prompt-modal.html', + controller: 'generalPromptModalController', + controllerAs: 'vm', + resolve: { + modalDetails: function () { + return { + "upper_headline": 'Master Checklist Template: ', + "upper_headline_value": vm.template.name, + "headline": 'Are you done editing?', + "is_message":true, + "message": 'Editing a master checklist template will effect all checklists currently ' + + 'created of that type and will also restart the validation for all active engagements', + "approve": 'Yes', + "cancelText": 'No', + "is_close_modal_button":false + }; + } + } + }); + + modalInstance.result.then(function (saveApproved) { + if(saveApproved) { + checklistService.saveChecklistTemplate(vm.template) + .then(function (response) { + if (response.status === 200) { + templateToRevert = angular.copy(vm.template); + toastService.setToast("Template was saved successfully.", 'success'); + } + }) + .catch(function (err){ + toastService.setToast("Problem occurred while saving template.", 'danger'); + $log.error("got error with saveChecklistTemplate"); + }); + } + }); + }; + + vm.cancel = function() { + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/general-prompt-modal/general-prompt-modal.html', + controller: 'generalPromptModalController', + controllerAs: 'vm', + resolve: { + modalDetails: function () { + return { + "upper_headline": 'Master Checklist Template: ', + "upper_headline_value": vm.template.name, + "headline": 'Are you sure you want to revert all changes?', + "is_message":false, + "approve": 'Yes', + "cancelText": 'No', + "is_close_modal_button":false + }; + } + } + }); + + modalInstance.result.then(function (revertApproved) { + if(revertApproved) { + vm.template = angular.copy(templateToRevert); + initFirstLineItemSelection(); + toastService.setToast("All changes discarded.", 'success'); + } + }); + }; + + vm.deleteSection = function(sectionToDelete) { + _.remove(vm.template.sections, function(section) {return sectionToDelete === section;}); + initFirstLineItemSelection(); + }; + + vm.selectLineItem = function(lineItem, section, $event) { + if(vm.selectedLineItem != lineItem) { + vm.selectedSection = section; + vm.selectedLineItem = lineItem; + $scope.$$postDigest(function () { + // Make extended window follow selected decision line + if ($event != undefined) + { + var line_item_bottom_offset = angular.element($event.target).prop('offsetHeight') + angular.element($event.target).prop('offsetTop'); + var extendended_item_height = angular.element("#line-item-extended").prop('offsetHeight'); + var diff_between_elements = line_item_bottom_offset - extendended_item_height; + if (diff_between_elements > 0) { + angular.element("#line-item-extended").css('margin-top',(20+diff_between_elements) +'px'); + } else { + angular.element("#line-item-extended").css('margin-top',''); + } + } + }); + } + }; + + vm.addLineItem = function(section) { + if(section) { + var maxWeight = _.maxBy(section.lineItems, function(lineItem) {return lineItem.weight;}) + 1; + var newLineItem = {"uuid": "newEntity", + "name": "Untitled line item", + "description": "Please add a description", + "weight": maxWeight, + "validation_instructions": "Please add validation instructions for the line item."}; + + section.lineItems.push(newLineItem); + } + }; + + vm.addSection = function() { + if(vm.template) { + var maxWeight = _.maxBy(vm.template.sections, function(section) {return section.weight;}) + 1; + var newSection = {"uuid": "newEntity", + "name": "Untitled section", + "description": "Section added from portal", + "validation_instructions": "valid instructions", + "weight": maxWeight, + "lineItems": []}; + + vm.template.sections.push(newSection); + } + }; + + vm.deleteLineItem = function(lineItemToDelete) { + _.remove(vm.selectedSection.lineItems, function(lineItem) {return lineItemToDelete === lineItem;}); + initFirstLineItemSelection(); + }; + + vm.isSaveInvalid = function() { + var result = false; + if(vm.template) { + result = _.find(vm.template.sections, function(section) { return section.lineItems.length === 0; }) != undefined; + } + + return result; + }; + + var registerWatchers = function() { + $scope.$watch('vm.template.name', function(newVal, OldVal){ + $stateParams.templateName = newVal; + }, true); + }; + + var initFirstLineItemSelection = function () { + vm.selectedSection = vm.template.sections && vm.template.sections.length > 0 + ? vm.template.sections[0] + : undefined; + + vm.selectedLineItem = vm.selectedSection ? vm.selectedSection.lineItems[0] : undefined; + + angular.element("#line-item-extended").css('margin-top',''); + }; + + var orderTemplateItems = function() { + if(vm.template) { + vm.template.sections = _.orderBy(vm.template.sections, 'weight'); + + _.forEach(vm.template.sections, function(section) { + section.lineItems = _.orderBy(section.lineItems, 'weight'); + }); + } + }; + + init(); + } +})(); diff --git a/d2ice.att.io/app/main/admin/checklist-template/checklist-template.html b/d2ice.att.io/app/main/admin/checklist-template/checklist-template.html new file mode 100755 index 00000000..cea7b11b --- /dev/null +++ b/d2ice.att.io/app/main/admin/checklist-template/checklist-template.html @@ -0,0 +1,174 @@ + +
+
+
+

+ + Master Checklist Template: + {{vm.template.name}} + + +
+ Template name is a required field. + Template name is too short. + Template name is too long. +
+
+

+
+ Editing a master checklist template will affect all checklists currently created of that type + and will also restart the validation for all active engagements. +
+
+ +
+
+
+
+
+
+
+
    +
  • +

    + Section {{$index+1}}: {{section.name}} + + + + +
    + Section name is a required field. + Section name is too short. + Section name is too long. +
    +
    +

    +
      +
    • + + + {{$parent.$index+1}}.{{$index+1}} + + {{lineItem.name}} +
       
      + +
    • +
    • + + Add Another line item +
    • +
    +
  • +
+ +
+
+
+ + Add Another Section +
diff --git a/d2ice.att.io/app/main/admin/checklist-template/checklist-template.less b/d2ice.att.io/app/main/admin/checklist-template/checklist-template.less new file mode 100755 index 00000000..7077958e --- /dev/null +++ b/d2ice.att.io/app/main/admin/checklist-template/checklist-template.less @@ -0,0 +1,552 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.cl-add-item-line { + width: 80%; + + .add-button { + .sprite; + .sprite.small-grey-add; + display: inline-block; + cursor: pointer; + position:relative; + top:3px; + } +} + +.cl-action-button{ + width: 30%; + margin-bottom: 2%; + margin-right: 3%; + &:last-child { + margin-right: 0; + } + +} + +.checklist-template-edit-item { + padding: 5px; + &.edit-template-name{ + .a_24_r; + } + + &.edit-section-name{ + .m_24; + } + + &.edit-lineitem-name{ + .m_18; + background-color: white; + line-height: normal; + } + &.edit-lineitem-description{ + .m_18; + width: 100%; + line-height: normal; + } +} + +.glyphicon-cursor-approve-changes { + display: inline-block; + cursor: pointer; + position:relative; + top:3px; + float: right; +} + +.lineitem-changed-icon { + .sprite; + .sprite.grey-check-mark; + display: inline-block; + cursor: pointer; + position:relative; + top:3px; + margin-left: -15px; +} + +.remove-item { + .sprite; + .sprite.red-delete; + display: inline-block; + cursor: pointer; + position:relative; + top:3px; + float: right; + margin-right: 1%; +} + +.template-edit-item { + .sprite; + .sprite.edit-medium; + display: inline-block; + cursor: pointer; + position:relative; + top:3px; + float: right; +} + +.add-another-section { + .sprite; + .sprite.big-grey-add; + display: inline-block; + cursor: pointer; + position:relative; + top:3px; +} + +.another-section { + border-top: 1px dashed ; + padding-top: 0.5%; +} + + +.checklist-template { + height:100%; + + #checklist-main-section { + padding-left: 12px; + } + + .ice-form-error { + text-transform: none; + } + + .section-topic{ + padding-left: 4%; + .m_24_m; + } + + .lineitem-index{ + padding-left: 5%; + } + + .lineitem-icon-and-index{ + padding-left: 0px; + } + + #cl-header { + height:12%; + padding-top:1%; + padding-bottom: 2%; + + .checklist-template-topic{ + border-right: 1px solid; + + #cl-title { + padding-left: 0px; + + .template-name { + .a_24_r; + } + + .template-topic { + .a_24_m; + } + } + + .edit-checklist { + display: inline-block; + margin-right: 5px; + cursor: pointer; + } + } + } + + + + + + #state-actions .btn { + width: 100%; + } + + .action-buttons{ + width: 100%; + margin-bottom: 7px; + } + + + + .add-icon { + .sprite; + .sprite.add; + display: inline-block; + } + + + .add-button { + margin-top: 8px; + .add-text { + .a_16_m; + vertical-align: top; + margin-left: 6px; + } + + } + + + + + #cl-title h1 { + .a_24_r; + margin: 0 0 30px 0; + } + + h3 { + .m_18_m; + } + h2 { + margin: 0 0 10px 0; + .a_24_m; + position: relative; + .add-people, + .add-step { + .sprite; + .sprite.add; + display: inline-block; + margin-left: 8px; + cursor: pointer; + } + } + + .main-section { + margin-top: 30px; + } + } + + + #state-bar { + float:none; + height: 5%; + + } + + + + #cl-header > #cl-title > span.bold { + .a_24_m; + } + + + .cl-action-buttons-frame{ + list-style: none; + display: inline; + padding-top: 20px; + } + + + + #line-item-list { + list-style: none; + padding-right:15px; + } + + + #line-item-list > li { + margin-bottom: 25px; + } + #line-item-list > li > h2 { + text-transform: capitalize; + border-bottom: 1px solid; + border-color: @main_color_q; + width: 100%; + margin-bottom: 0px; + padding-left: 5px; + .m_24; + } + #line-item-list > li > h2 > span.bold { + .m_24_m; + } + + #line-item-list > li > ul { + list-style: none; + } + #line-item-list > li > ul >li.line-item-row { + border-bottom: 1px solid; + border-color: @main_color_q; + line-height: 30px; + padding: 0px; + vertical-align: middle; + height: 30px; + .m_16_r; + cursor: pointer; + } + + #line-item-list > li > ul >li.line-item-row .value-icon { + padding: 0px; + } + + #line-item-list > li > ul >li.line-item-row .value-icon span { + display: inline-block; + position: relative; + top: 3px; + margin-right: 5px; + margin-left: 3px; + width:15px; + height:15px; + } + + #line-item-list > li > ul >li.line-item-row .auto-icon { + text-align:right; + padding: 0px; + } + + #line-item-list > li > ul >li.line-item-row .auto-icon span { + display: inline-block; + position: relative; + top: 3px; + margin-right: 3px; + } + + #line-item-list > li > ul >li.line-item-row.selected-line { + background-color: @bg_color_a; + border-left: 2px solid; + border-top: 2px solid; + border-bottom: 2px solid; + border-color: @main_color_a; + position:relative; + z-index:1; + top: -1px; + left: -2px; + } + + #line-item-list > li > ul >li.line-item-row.selected-line > .selected-line-connector { + position: absolute; + right: -19px; + width: 20px; + height: 30px; + top: -2px; + background-color: @bg_color_a; + border-top: 2px solid; + border-bottom: 2px solid; + border-color: @main_color_a; + } + #line-item-extended { + background-color: @bg_color_a; + border: 2px solid; + border-color: @main_color_a; + padding:15px; + @media (min-width: 992px) { + max-height: 100%; + overflow-y: auto; + } + } + #line-item-extended >header { + padding: 0 30px; + padding-bottom: 0px; + } + #line-item-extended >header > h2 { + text-transform: capitalize; + padding:0px; + margin:0px; + line-height:32px; + .m_18_r; + } + #line-item-extended > header > h2 > span.bold { + .m_18_m; + } + #line-item-extended >header > #decision-actions { + list-style: none; + text-align: right; + margin:0px; + } + #line-item-extended >header > #decision-actions > li { + display: inline-block; + margin-left: 2px; + .sprite; + } + #line-item-extended >header > #decision-actions.active > li { + cursor:pointer; + } + + #line-item-extended >header > #decision-actions > li.not-relevant-btn { + .sprite.not-relevant-btn; + } + + #line-item-extended >header > #decision-actions.active > li.not-relevant-btn:hover { + .sprite.not-relevant-btn-active; + } + #line-item-extended >header > #decision-actions > li.not-relevant-btn.active { + .sprite.not-relevant-btn-active; + } + #line-item-extended >header > #decision-actions > li.denied-cl-btn { + .sprite.denied-cl-btn; + } + #line-item-extended >header > #decision-actions.active > li.denied-cl-btn:hover { + .sprite.denied-cl-btn-active; + } + #line-item-extended >header > #decision-actions > li.denied-cl-btn.active { + .sprite.denied-cl-btn-active; + } + #line-item-extended >header > #decision-actions > li.approved-cl-btn { + .sprite.approved-cl-btn; + } + #line-item-extended >header > #decision-actions.active > li.approved-cl-btn:hover { + .sprite.approved-cl-btn-active; + } + #line-item-extended >header > #decision-actions > li.approved-cl-btn.active { + .sprite.approved-cl-btn-active; + } + + + #line-item-extended > #line-item-description { + margin: 0 15px; + .m_16_r; + } + + #line-item-extended > #line-item-validation-instructions { + .m_14_r; + background-color: #fff; + border: 1px solid; + border-color: @main_color_a; + padding: 15px; + margin-top: 15px; + } + + #line-item-extended > #line-item-validation-instructions h3 { + text-transform: capitalize; + margin: 0px; + .m_18_m; + } + + #line-item-extended > #line-item-validation-instructions p { + margin-top: 5px; + + } + + #line-item-extended > #line-item-validation-instructions p ul { + padding-left: 15px; + } + + #line-item-extended > #line-item-audit-logs { + padding:0 15px; + } + + #line-item-extended > #line-item-audit-logs > h3 { + text-transform: capitalize; + .m_18_m; + + } + #line-item-extended > #line-item-audit-logs > #audit-log-list { + list-style:none; + + } + #line-item-extended > #line-item-audit-logs > #audit-log-list > li { + margin: 0 15px 10px; + border-bottom: 2px solid; + border-color: @main_color_q; + } + #line-item-extended > #line-item-audit-logs > #audit-log-list > li > .audit-creator { + .m_16_m; + margin:0px; + padding:0px; + } + #line-item-extended > #line-item-audit-logs > #audit-log-list > li > .audit-date { + text-align:right; + .m_14_r; + padding:0px; + } + #line-item-extended > #line-item-audit-logs > #audit-log-list > li > .audit-text { + .m_16_r; + margin-bottom:0px; + padding:0px; + } + + #line-item-extended > #line-item-audit-logs > #new-audit-log-from { + margin: 0 0 15px; + } + + #line-item-extended > #line-item-audit-logs > #new-audit-log-from #new-audit-log-text { + border-color: @main_color_q; + margin-bottom:15px; + } + + .btn-gradient-primary { + font-weight: bold; + color: #FFFFFF; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #37B2E5; + *background-color: #37B2E5; + background-image: -moz-linear-gradient(top, #0079AB, #37B2E5); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#0079AB), to(#37B2E5)); + background-image: -webkit-linear-gradient(top, #0079AB, #37B2E5); + background-image: -o-linear-gradient(top, #0079AB, #37B2E5); + background-image: linear-gradient(to bottom, #0079AB, #37B2E5); + background-repeat: repeat-x; + border-color: #37B2E5; + border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#0079AB', endColorstr='#37B2E5', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); + } + + .btn-gradient-success { + font-weight: bold; + color: #FFFFFF; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #41A02C; + *background-color: #41A02C; + background-image: -moz-linear-gradient(top, #A2E652, #41A02C); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#A2E652), to(#41A02C)); + background-image: -webkit-linear-gradient(top, #A2E652, #41A02C); + background-image: -o-linear-gradient(top, #A2E652, #41A02C); + background-image: linear-gradient(to bottom, #A2E652, #41A02C); + background-repeat: repeat-x; + border-color: #41A02C; + border-color: #888; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#A2E652', endColorstr='#41A02C', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); + } + + .btn-gradient-danger { + font-weight: bold; + color: #FFFFFF; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #AE0020; + *background-color: #AE0020; + background-image: -moz-linear-gradient(top, #F74658, #AE0020); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#F74658), to(#AE0020)); + background-image: -webkit-linear-gradient(top, #F74658, #AE0020); + background-image: -o-linear-gradient(top, #F74658, #AE0020); + background-image: linear-gradient(to bottom, #F74658, #AE0020); + background-repeat: repeat-x; + border-color: #AE0020; + border-color: #888; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#F74658', endColorstr='#AE0020', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); + } + diff --git a/d2ice.att.io/app/main/dashboard/account/account.controller.js b/d2ice.att.io/app/main/dashboard/account/account.controller.js new file mode 100755 index 00000000..da648f73 --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/account/account.controller.js @@ -0,0 +1,150 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.dashboard.account') + .controller('DashboardAccountController', ["$state", "usersService", "vfService", "$log", + "$rootScope", "toastService", dashboardAccountController]); + + function dashboardAccountController($state,usersService,vfService, $log, $rootScope, toastService) { + + var vm = this; + vm.data = {}; + + var init = function() + { + + vm.user = usersService.getUserData(); + + if (vm.user == undefined) { + $state.go('app.login'); + return; + } + + var user_uuid = vm.user.uuid; + + $rootScope.ice.loader.show = true; + usersService.getIceUser(user_uuid) + .then + (function (response) + { + if (response.status === 200) + { + vm.data.full_name = response.data.full_name; + vm.data.email = response.data.email; + vm.data.phone_number = response.data.phone_number; + vm.data.password = ''; //user.password; + vm.data.ssh_key = response.data.ssh_public_key; + vm.data.company = response.data.company.name; + vm.data.access_key = response.data.rgwa_access_key; + vm.data.access_secret = "•••••••••••••••"; + $rootScope.ice.loader.show = false; + } + else + { + toastService.setToast('Error getting account', 'danger'); + $log.error("Error getting account: " + uuid); + $rootScope.ice.loader.show = false; + } + } + ).catch(function (error) { + toastService.setToast(error.message, 'danger'); + $log.error(error.message); + }); + + vfService.getCompanies() + .then(function (response) { + if (response.status === 200) + { + vm.companies = response.data; + } + }) + .catch(function (error) + { + $log.error(error.message); + }); + + + + }; + + init(); + + vm.getAccessSecret = function () + { + usersService.getRGWASecret() + .then + (function (response) + { + if (response.status === 200) + { + vm.data.access_secret = response.data.rgwa_secret_key; + } + else + { + toastService.setToast('Error getting user\'s access secret', 'danger'); + $log.error("Error getting access secret: " + uuid); + $rootScope.ice.loader.show = false; + } + } + ).catch(function (error) { + toastService.setToast(error.message, 'danger'); + $log.error(error.message); + }); + } + + vm.submitForm = function () + { + var user = usersService.getUserData(); + usersService.updateAccount(user.uuid, vm.data) + .then(function (response) { + if (response.status === 200) { + toastService.setToast('Account was updated successfully!', 'success'); + } + }) + .catch(function (error) { + toastService.setToast(error.message.detail, 'danger'); + }); + }; + } + +})(); diff --git a/d2ice.att.io/app/main/dashboard/account/account.html b/d2ice.att.io/app/main/dashboard/account/account.html new file mode 100755 index 00000000..de792d3a --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/account/account.html @@ -0,0 +1,159 @@ + + + +

Account

+ +
+ +
+ + +
+ + + +
+ + + +
+ +
+
+
+

Your Storage Credentials

+
+ +
Access Key: +
{{vm.data.access_key}}
+
+ +
Access Secret (Show) +
{{vm.data.access_secret}}
+
+ +
+
+
+ + + diff --git a/d2ice.att.io/app/main/dashboard/account/account.less b/d2ice.att.io/app/main/dashboard/account/account.less new file mode 100755 index 00000000..d32db492 --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/account/account.less @@ -0,0 +1,215 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.account { + + .btn { + width: 100%; + } + + .btn-primary { + border: 1px solid #8799A3; + border-radius: 6px; + background: #1E79B0; /* For browsers that do not support gradients */ + background: -webkit-linear-gradient(#1E79B0, #62ADD5); /* For Safari 5.1 to 6.0 */ + background: -o-linear-gradient(#1E79B0, #62ADD5); /* For Opera 11.1 to 12.0 */ + background: -moz-linear-gradient(#1E79B0, #62ADD5); /* For Firefox 3.6 to 15 */ + background: linear-gradient(#1E79B0, #62ADD5); /* Standard syntax (must be last) */ + } + + .content { + + .steps-progress-wrapper { + margin-top: 10px; + } + + h1 { + .a_36; + margin: 0 0 30px 0; + } + + h2 { + margin: 0 0 10px 0; + .a_24_m; + position: relative; + .add-people, + .add-step { + .sprite; + .sprite.add; + display: inline-block; + margin-left: 8px; + cursor: pointer; + } + } + + h3 { + .a_20_m; + } + + .main-section { + margin-top: 30px; + } + + .steps { + + border-right: dashed 1px @main_color_a; + height: 100%; + padding-right: 20px; + + ul { + li.step { + + &.selected { + background-color: #DEF3FF; + } + + list-style: none; + position: relative; + padding: 10px 10px 10px 4px; + + .description { + + .m_16_r; + border-bottom: dashed 1px @main_color_n; + padding: 10px 0; + + input { + position: absolute; + top: 10px; + left: 0; + margin-right: 20px; + } + + .step-text { + margin-left: 20px; + } + + .step-state { + position: absolute; + top: 24px; + &.todo { + .steps-sprite; + .steps-sprite.todo; + display: inline-block; + } + &.confirmed { + .steps-sprite; + .steps-sprite.confirmed; + display: inline-block; + } + &.completed { + .steps-sprite; + .steps-sprite.completed; + display: inline-block; + } + &.completed-non-el { + .steps-sprite; + .steps-sprite.completed-non-el; + display: inline-block; + } + } + } + .details { + .m_12_r; + margin-bottom: 20px; + .actions { + float: right; + margin-top: 4px; + + .moveto-confirmed { + .sprite; + .sprite.success; + display: inline-block; + cursor: pointer; + } + .moveto-todo { + .sprite; + .sprite.delete-circle; + display: inline-block; + cursor: pointer; + } + .moveto-delete { + .sprite; + .sprite.delete; + display: inline-block; + cursor: pointer; + } + } + } + } + } + } + + .right-panel { + height: 100%; + padding-left: 20px; + padding-bottom: 5px; + + .personImage + { + .profiles-sprite; + .profiles-sprite.profile-large; + display: block; + } + + .line-separator { + border-bottom: solid lightgrey; + margin: 20px 0; + } + + .storage-credentials { + .m_18_r; + } + + .access-key { + margin-bottom: 10px; + .m_16_r; + } + + .access-secret { + margin-bottom: 10px; + .m_16_r; + } + + .show-secret { + .underline; + cursor: pointer; + } + } + } +} diff --git a/d2ice.att.io/app/main/dashboard/account/account.module.js b/d2ice.att.io/app/main/dashboard/account/account.module.js new file mode 100755 index 00000000..052cbbfb --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/account/account.module.js @@ -0,0 +1,85 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.dashboard.account') + .config(config); + + function config($stateProvider) { + $stateProvider + .state('app.account', { + url: '/account', + views: { + 'content@app': { + templateUrl: 'main/dashboard/account/account.html', + controller: 'DashboardAccountController as vm' + }, + 'navigation@app': { + templateUrl: 'core/navigation/layouts/account-navigation/navigation.html', + controller: 'accountNavigationController as vm' + } + }, + params: {engagement_uuid: null}, + bodyClass: 'account' + }) + .state('app.account.notifications', { + url: '/account/notifications', + views: { + 'content@app': { + templateUrl: 'main/dashboard/account/notifications/notifications.html', + controller: 'DashboardNotificationsController as vm' + } + }, + bodyClass: 'notifications' + }) + .state('app.account.userProfile', { + url: '/account/userProfile', + views: { + 'content@app': { + templateUrl: 'main/dashboard/account/user-profile-settings/user-profile-settings.html', + controller: 'accountUserProfileSettingsController as vm' + } + }, + bodyClass: 'account' + }); + } +})(); diff --git a/d2ice.att.io/app/main/dashboard/account/notifications/notifications.controller.js b/d2ice.att.io/app/main/dashboard/account/notifications/notifications.controller.js new file mode 100755 index 00000000..0e9542dd --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/account/notifications/notifications.controller.js @@ -0,0 +1,140 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + angular + .module('ice.dashboard.account') + .controller('DashboardNotificationsController', ["$state","pageService","usersService", "toastService", "$rootScope", "$scope", "$log", dashboardNotificationsController]); + + function dashboardNotificationsController($state,pageService, usersService, toastService, $rootScope, $scope, $log) { + var vm = this; + vm.data = {}; + var init = function() + { + pageService.setPage('notification'); + $rootScope.timeGapLocal = moment().format("z");// timeGap(); + $rootScope.ampm = moment().format('A'); + $rootScope.mom =moment().tz( moment.tz.guess()).format('z'); + + vm.pagination_num_of_objects = 10; + vm.current_starting_offset = "0"; + vm.page_num = 1; + vm.user = usersService.getUserData(); + if (vm.user == undefined) { + $state.go('app.login'); + return; + } + vm.getNotifications(true) + } + + vm.getNotifications = function (reset) { + var user_uuid = vm.user.uuid; + $rootScope.ice.loader.show = true; + vm.current_starting_offset = (vm.page_num-1)*vm.pagination_num_of_objects; + usersService.getNotificationsDescription(vm.user.uuid,vm.current_starting_offset,vm.pagination_num_of_objects) + .then + (function (response) + { + if (response.status === 200) + { + vm.notifications = response.data['serilizedActivitySet']; + vm.num_of_returned_items = response.data['num_of_objects']; + vm.notifications_display_list = vm.notifications; + if (reset){ + usersService.resetNotificationNum(user_uuid) + .then + (function (response) + { + if (response.status === 200) + { + $scope.$emit('eventClearNotifications',0); + } + } + ) + .catch(function (error) { + toastService.setToast(error.message, 'danger'); + $rootScope.ice.loader.show = false; + $log.error(error); + }); + } + $rootScope.ice.loader.show = false; + } + else + { + toastService.setToast(response.error, 'danger'); + $rootScope.ice.loader.show = false; + } + } + ) + .catch(function (error) { + toastService.setToast(error.message, 'danger'); + $rootScope.ice.loader.show = false; + $log.error(error); + } + ); + }; + + vm.delNotification = function(uuid) + { + var itemIndex = 0; + + for(var i=0; i < vm.notifications.length; i++) + { + if (vm.notifications[i].uuid == uuid) + { + itemIndex = i; + break; + } + } + usersService.notificationsDelete(uuid) + .then + (function (response) { + if (response.status != 400){ + vm.notifications.splice(itemIndex , 1); + } + }) + .catch(function (error) { + toastService.setToast(error.message, 'danger'); + $rootScope.ice.loader.show = false; + $log.error(error); + }); + } + init(); + } +})(); \ No newline at end of file diff --git a/d2ice.att.io/app/main/dashboard/account/notifications/notifications.html b/d2ice.att.io/app/main/dashboard/account/notifications/notifications.html new file mode 100755 index 00000000..f92cc41a --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/account/notifications/notifications.html @@ -0,0 +1,60 @@ + + + +
+
+

Notifications

+
+
+
+ +
+
+
+
+
+
+ + + +
+ diff --git a/d2ice.att.io/app/main/dashboard/account/notifications/notifications.less b/d2ice.att.io/app/main/dashboard/account/notifications/notifications.less new file mode 100755 index 00000000..7981be89 --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/account/notifications/notifications.less @@ -0,0 +1,348 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.engagement_link { + text-decoration: underline; + cursor:pointer; +} +.notifications { + + .table{ + margin-bottom: 0; + } + + .table-container-flex { + + .data-row-wrapper { + padding: 10px 20px; + } + + .flex-item:nth-child(1) { + padding-left: 5px; + padding-top: 15px; + flex-grow: 2; + } + + .flex-item:nth-child(2) { + padding-top: 12px; + flex-grow: 93; + } + + .flex-item:nth-child(3) { + padding-top: 12px; + flex-grow: 5; + } + + } + + .pagination > .active > a, .pagination > .active > span, .pagination > .active > a:hover, .pagination > .active > span:hover, .pagination > .active > a:focus, .pagination > .active > span:focus + { + background-color: #DEF3FF; + border-color: #DDDDDD; + color: #000000; + cursor:pointer; + z-index:2; + } + + .btn { + width: 100%; + } + + .lineColor + { + background-color:#F6F3F3; + } + + .electricity + { + .sprite; + .sprite.electricity; + display: block; + margin-top: 10px; + margin-left: 10px; + } + + .delete + { + .sprite; + .sprite.delete-circle; + display: block; + cursor:pointer; + margin-top: 11px; + } + + + .fLeft + { + float:left; + height:50px; + } + + .hoverCyan + { + line-height: 40px; + &:hover { + background-color: #DEF3FF; + } + } + + .boldFont + { + font-weight: bold; + } + + .marginLeft60 + { + margin-left:-60px; + } + + .height510 + { + height:510px; + margin-top:-30px; + } + + .height50 + { + height:50px; + line-height:50px; + width:1100px; + } + + .marginLeft5 + { + margin-left:5px; + } + + .marginTop5 + { + margin-top:5px; + margin-left: 40px; + } + + .personImage + { + .profiles-sprite; + .profiles-sprite.profile-large; + display: block; + } + + .textAlignCenter + { + text-align:center; + width:1100px + } + + .btn-primary { + border: 1px solid #8799A3; + border-radius: 6px; + background: #1E79B0; /* For browsers that do not support gradients */ + background: -webkit-linear-gradient(#1E79B0, #62ADD5); /* For Safari 5.1 to 6.0 */ + background: -o-linear-gradient(#1E79B0, #62ADD5); /* For Opera 11.1 to 12.0 */ + background: -moz-linear-gradient(#1E79B0, #62ADD5); /* For Firefox 3.6 to 15 */ + background: linear-gradient(#1E79B0, #62ADD5); /* Standard syntax (must be last) */ + } + + .pad17 + { + padding-top:17px; + display: block; + } + + .content { + + .steps-progress-wrapper { + margin-top: 10px; + } + + h1 { + .a_36; + margin: 0 0 30px 0; + } + + h2 { + margin: 0 0 10px 0; + .a_24_m; + position: relative; + .add-people, + .add-step { + .sprite; + .sprite.add; + display: inline-block; + margin-left: 8px; + cursor: pointer; + } + } + + .main-section { + margin-top: 30px; + } + + .steps { + + + height: 100%; + padding-right: 20px; + + ul { + li.step { + + &.selected { + background-color: #DEF3FF; + } + + list-style: none; + position: relative; + padding: 10px 10px 10px 4px; + + .description { + + .m_16_r; + + padding: 10px 0; + + input { + position: absolute; + top: 10px; + left: 0; + margin-right: 20px; + } + + .step-text { + margin-left: 20px; + } + + .step-state { + position: absolute; + top: 24px; + &.todo { + .steps-sprite; + .steps-sprite.todo; + display: inline-block; + } + &.confirmed { + .steps-sprite; + .steps-sprite.confirmed; + display: inline-block; + } + &.completed { + .steps-sprite; + .steps-sprite.completed; + display: inline-block; + } + &.completed-non-el { + .steps-sprite; + .steps-sprite.completed-non-el; + display: inline-block; + } + } + } + .details { + .m_12_r; + margin-bottom: 20px; + .actions { + float: right; + margin-top: 4px; + + .moveto-confirmed { + .sprite; + .sprite.success; + display: inline-block; + cursor: pointer; + } + .moveto-todo { + .sprite; + .sprite.delete-circle; + display: inline-block; + cursor: pointer; + } + .moveto-delete { + .sprite; + .sprite.delete; + display: inline-block; + cursor: pointer; + } + } + } + } + } + } + + .team-and-logs { + height: 100%; + padding-left: 20px; + .team { + ul.team-avatars { + + li { + list-style: none; + display: inline-block; + margin-right: 10px; + .profiles-sprite; + .profiles-sprite.profile-medium; + + &.me { + .profiles-sprite; + .profiles-sprite.avatar-blue; + } + } + } + } + + .activity-log { + ul.activity-log-details { + li { + list-style: none; + position: relative; + margin-left: 30px; + + &:before { + content: ''; + display: inline-block; + .sprite; + .sprite.electricity; + position: absolute; + top: 0; + left: -30px; + } + } + } + } + } + } +} diff --git a/d2ice.att.io/app/main/dashboard/account/user-profile-settings/user-profile-settings.controller.js b/d2ice.att.io/app/main/dashboard/account/user-profile-settings/user-profile-settings.controller.js new file mode 100755 index 00000000..6d51a440 --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/account/user-profile-settings/user-profile-settings.controller.js @@ -0,0 +1,98 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + angular + .module('ice.dashboard.account') + .controller('accountUserProfileSettingsController', ['toastService', 'usersService', + accountUserProfileSettingsController]); + + function accountUserProfileSettingsController(toastService, usersService) { + var vm = this; + + var init = function() + { + usersService.getIceUser() + .then + (function (response) { + vm.receiveEmails = response.data.regular_email_updates; + vm.receiveEmailsEveryTime = response.data.email_updates_on_every_notification; + vm.receiveDigestEmails = response.data.email_updates_daily_digest; + + vm.receiveNotifications = vm.receiveEmailsEveryTime || vm.receiveDigestEmails; + } + ).catch(function (error) { + toastService.setToast(error.message, 'danger'); + $log.error(error.message); + }); + }; + + vm.submitForm = function() { + var user = usersService.getUserData(); + var userData = {}; + + userData.regular_email_updates = vm.receiveEmails; + userData.email_updates_on_every_notification = vm.receiveEmailsEveryTime; + userData.email_updates_daily_digest = vm.receiveDigestEmails; + userData.company = user.company.name; + userData.full_name = user.full_name; + userData.email = user.email; + userData.phone_number = user.phone_number; + + usersService.updateAccount(user.uuid, userData) + .then(function (response) { + if (response.status === 200) { + toastService.setToast('User profile settings was updated successfully!', 'success'); + } + }) + .catch(function (error) { + toastService.setToast(error.message.detail, 'danger'); + }); + }; + + vm.changeReceiveNotifications = function() { + if(!vm.receiveNotifications) { + vm.receiveEmailsEveryTime = false; + vm.receiveDigestEmails = false; + } + }; + + init(); + } +})(); diff --git a/d2ice.att.io/app/main/dashboard/account/user-profile-settings/user-profile-settings.html b/d2ice.att.io/app/main/dashboard/account/user-profile-settings/user-profile-settings.html new file mode 100755 index 00000000..521c73ab --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/account/user-profile-settings/user-profile-settings.html @@ -0,0 +1,66 @@ + + +

Settings

+ diff --git a/d2ice.att.io/app/main/dashboard/account/user-profile-settings/user-profile-settings.less b/d2ice.att.io/app/main/dashboard/account/user-profile-settings/user-profile-settings.less new file mode 100755 index 00000000..41ad47ec --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/account/user-profile-settings/user-profile-settings.less @@ -0,0 +1,45 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.user-profile-settings-form { + .receive-email-options { + padding-left: 20px; + } +} + + diff --git a/d2ice.att.io/app/main/dashboard/checklist/checklist.controller.js b/d2ice.att.io/app/main/dashboard/checklist/checklist.controller.js new file mode 100755 index 00000000..293134cd --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/checklist/checklist.controller.js @@ -0,0 +1,445 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + angular + .module('ice.dashboard.checklist',[]) + .controller('DashboardChecklistController', ["$scope", "$stateParams", "$rootScope", "checklistService", + "iceConstants", "usersService", "$uibModal", "toastService", "$log", DashboardChecklistController]); + function DashboardChecklistController($scope, $stateParams, $rootScope, checklistService, iceConstants, + usersService, $uibModal, toastService, $log) { + + var vm = this; + vm.data = {}; + var engagementUuid = $stateParams.engagement_uuid; + vm.checklistUuid = $stateParams.sub_id; + vm.selected_decision = false; + + var init = function() { + if (vm.checklistUuid == null) + return; + + checklistService.getChecklist(vm.checklistUuid) + .then(function (response) { + if (response.status === 200) { + vm.data = response.data; + vm.data.states = iceConstants.checklist_states; + vm.me = usersService.getUserData(); + vm.is_peer_reviewer = usersService.isPeerReviewer(vm.me, response.data.checklist.engagement.peer_reviewer.uuid); + // if state pending dont allow changing data manually + if(vm.data.checklist.associated_files) { + vm.has_files = true; + } + else { + vm.has_files = false; + } + vm.formatDecisions(); + + } + }) + .catch(function (error) { + if (error.status === 410) { + $rootScope.$broadcast('onUpdateEngagements',{ + select:{ + uuid: $stateParams.engagement_uuid, + view_type : 'overview', + sub_id: undefined + } + }); + } + else{ + $log.error(error.message); + return false; + } + }); + }; + + + vm.formatDecisions = function () { + var section_counter = 0; + vm.data.checklistDecisions = _.orderBy(vm.data.checklistDecisions, 'weight'); + angular.forEach(vm.data.checklistDecisions, function(section,section_key) { + section_counter ++; + section.counter = section_counter; + var decision_counter = 0; + section.decisions = _.orderBy(section.decisions, 'weight'); + angular.forEach(section.decisions,function(decision,decision_key) { + decision_counter++; + // add text of section and line number E.g 2.1 + decision.counter = section_counter+'.'+decision_counter; + + // set selected decision default value + if (vm.selected_decision == false) + { + vm.selected_decision = decision; + vm.selectDecision(decision); + } + + // choose which decision value to show + var view_value; + switch(vm.data.checklist.state) + { + case 'peer_review': + view_value = decision.peer_review_value; + break; + case 'review': + case 'approval': + case 'handoff': + case 'closed': + view_value = decision.review_value; + break; + } + + // choose which ucib to show + var view_value_css; + switch(view_value) + { + case 'approved': + view_value_css = 'sprite approved-cl'; + break; + case 'denied': + view_value_css = 'sprite denied-cl'; + break; + case 'not_relevant': + view_value_css = 'sprite not-relevant-cl'; + break; + } + + // choose which line item type icon to show + var auto_icon_css + switch(decision.lineitem.line_type) + { + case 'auto': + auto_icon_css = 'sprite automation-state'; + } + vm.data.checklistDecisions[section_key].decisions[decision_key]['selected-value'] = view_value + vm.data.checklistDecisions[section_key].decisions[decision_key]['view_value'] = view_value; + vm.data.checklistDecisions[section_key].decisions[decision_key]['view_value_css'] = view_value_css; + vm.data.checklistDecisions[section_key].decisions[decision_key]['auto_icon_css'] = auto_icon_css; + }); + }); + // after decision change refresh which state buttons to shows + vm.refreshStateOptions(); + + }; + + // set decision value + vm.setDecision = function(decision,value) { + checklistService.putChecklistDecision(decision.uuid,{value:value}) + .then(function (response) { + if (response.status === 200) { + switch(vm.data.checklist.state) + { + case 'peer_review': + decision.peer_review_value = value; + break; + case 'review': + decision.review_value = value; + break; + } + vm.formatDecisions(); + } + }); + + }; + + // decice which state change buttons to choose + vm.refreshStateOptions = function () { + var force_break = false; + vm.is_able_to_approve = true; + angular.forEach(vm.data.checklistDecisions, function (section,key) { + if (!force_break) + angular.forEach(section.decisions, function (decision,key) { + if (!force_break){ + // if not all decisions have value only only next_step + if ( decision['view_value'] != 'approved' && decision['view_value'] != 'not_relevant' ) { + vm.is_able_to_approve = false; + force_break=true; + } + } + }); + + }); + }; + + // set state + vm.stateAction = function(action) { + switch(action) + { + case 'approve': + var postData = {}; + postData["description"] = ''; + postData["decline"] = "False"; + checklistService.setState(vm.data.checklist.uuid, postData) + .then(function (response) { + if (response.status === 200) { + $rootScope.$broadcast('onUpdateEngagements',{select:{uuid:engagementUuid,page_type:'overview',sub_id:vm.data.checklist.uuid}}); + } + else { + toastService.setToast(response.error, 'danger'); + $rootScope.ice.loader.show = false; + } + }) + .catch(function (error) { + $log.error(error); + toastService.setToast(error.status + ': Error changing progress!', 'danger'); + }); + break; + case 'reject': + vm.openSetState(action,vm.data.checklist); + break; + case 'next_step': + vm.openNextSteps(vm.data.checklist); + break; + } + }; + + vm.formatDate = function (create_time) { + var region = moment().tz( moment.tz.guess()).format('z'); + var dt = ""; + dt = moment(create_time).local().format('YYYY-MM-DD hh:mm:ss A') + " " + region; + return dt; + }; + + // add decision log + vm.submitDecisionAuditLog = function () { + + var jsonPost = {"description":vm.selected_decision.new_audit_log_description}; + checklistService.createAuditlogDecisionChecklist(vm.selected_decision.uuid, jsonPost) + .then(function (response) { + if (response.status === 200) + { + if (vm.data.decisionAuditLogs[vm.selected_decision.uuid] == undefined) + vm.data.decisionAuditLogs[vm.selected_decision.uuid] = [] + vm.data.decisionAuditLogs[vm.selected_decision.uuid].push(response.data); + vm.selected_decision.new_audit_log_description = "" + } + else + { + toastService.setToast(response.error, 'danger'); + $rootScope.ice.loader.show = false; + } + }) + .catch(function (error) { + toastService.setToast(error.message, 'danger'); + $log.error(error.message); + }); + } + + // choose active decision + vm.selectDecision = function(decision,$event) { + if(vm.selected_decision != decision || vm.selected_decision.selected === undefined) { + // remove status from previos decision + vm.selected_decision.selected = false; + + // populate new decision + vm.selected_decision = decision; + vm.selected_decision.selected = true; + + $scope.$$postDigest(function () { + // Make extended window follow selected decision line + if ($event != undefined) + { + var line_item_bottom_offset = angular.element($event.target).prop('offsetHeight') + angular.element($event.target).prop('offsetTop'); + var extendended_item_height = angular.element("#line-item-extended").prop('offsetHeight'); + var diff_between_elements = line_item_bottom_offset - extendended_item_height; + if (diff_between_elements > 0) + { + angular.element("#line-item-extended").css('margin-top',(20+diff_between_elements) +'px') + } else { + angular.element("#line-item-extended").css('margin-top','') + } + } + }); + } + }; + + // next steps modal + vm.openNextSteps = function(checklist) { + var modalInstance = $uibModal.open( + { + templateUrl: 'main/modals/next-steps/next-steps.html', + controller: 'NextStepsModalController', + controllerAs: 'vm', + size: 'lg', + resolve: { + engagement_team: function () { + return checklist.engagement.engagement_team; + }, + title: function () { + return checklist.name; + }, + associated_files: function () { + return checklist.repo_associated_files; + }, + engagement_uuid: function () { + return checklist.engagement.uuid; + }, + checklist: function () { + return checklist; + }, + nextstep: function () { + return undefined; + } + + } + }); + + modalInstance.result.then(function (data) { + if (data === 200) { + $rootScope.$broadcast('onUpdateEngagements',{select:{uuid:engagementUuid,page_type:'overview',sub_id:checklist.uuid}}); + } + }, function () { + }); + }; + + // set state modal + vm.openSetState = function(action,checklist) { + var modalInstance = $uibModal.open( + { + templateUrl: 'main/modals/checklist/state-approve-or-reject/state-approve-or-reject.html', + controller: 'stateDecisionModalController', + controllerAs: 'vm', + resolve: { + checklist: function () {return checklist}, + action: function () {return action} + } + }); + + modalInstance.result.then(function (data) { + if (data) { + $rootScope.$broadcast('onUpdateEngagements',{select:{uuid:engagementUuid,page_type:'overview',sub_id:checklist.uuid}}); + } + }, function () { + }); + + }; + + vm.openJenkinsLogModal = function () { + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/general-log-modal/general-log-modal.html', + controller: 'GeneralLogModalController', + controllerAs: 'vm', + size: 'general-log-modal', + resolve: { + modalDetails: function () { + return { + "headline": 'Jenkins log', + "body": vm.data.checklist.jenkins_log, + }; + } + } + }); + }; + + // audit log modal + vm.auditLog = function() { + + var auditLogData = { + name:vm.data.checklist.name, + uuid:vm.data.checklist.uuid, + checklistAuditLogs: vm.data.checklistAuditLogs + + }; + + var modalInstance = $uibModal.open( + { + templateUrl: 'main/modals/audit-log/audit-log.html', + controller: 'AuditLogModalController', + controllerAs: 'vm', + size: 'lg' + + , + resolve: { + wizardData: function () { + return auditLogData; + } + } + }); + + modalInstance.result.then(function (data) { + if (data) { + vm.data.checklistAuditLogs.push(data); + } + }, function () { + $log.debug('Modal dismissed at: ' + new Date()); + }); + }; + + // edit checklist + vm.editChecklist = function() { + var checklistData = { + uuid:vm.data.checklist.uuid, + name:vm.data.checklist.name, + templates:vm.data.checklist.templates, + selectedTemplateUuid:vm.data.checklist.template.uuid, + selectedTemplateName:vm.data.checklist.template.name, + associatedFiles:vm.data.checklist.associated_files, + state:vm.data.checklist.state + }; + + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/checklist/checklist.html', + controller: 'ChecklistModalController', + controllerAs: 'vm', + size: 'lg' + , + resolve: { + wizardData: function () { + return checklistData; + }, + engagementUuid: function () { + return engagementUuid; + }, + modal_type: function () { + return 'update'; + } + } + }); + modalInstance.result.then(function (data) { + if (data) { + vm.data.checklist.name = data.checklist_name; + vm.data.checklist.associated_files = data.associated_files; + } + }); + }; + + init(); + } +})(); diff --git a/d2ice.att.io/app/main/dashboard/checklist/checklist.html b/d2ice.att.io/app/main/dashboard/checklist/checklist.html new file mode 100755 index 00000000..b8da8836 --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/checklist/checklist.html @@ -0,0 +1,117 @@ + +
+
+ +
+
+

+ + Checklist: + {{vm.data.checklist.name}} +

+
+ +
+ + + +
+
    +
  • Audit Log ({{vm.data.checklistAuditLogs.length}})
  • +
  • Jenkins Log
  • + +
+
+
+ +
+
    +
  • Section {{section.counter}}: {{section.section.name}}

    +
      +
    • + {{decision.counter}} + {{decision.lineitem.name}} + + +
    • +
    +
  • +
+ +
+
diff --git a/d2ice.att.io/app/main/dashboard/checklist/checklist.less b/d2ice.att.io/app/main/dashboard/checklist/checklist.less new file mode 100755 index 00000000..5e0d228e --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/checklist/checklist.less @@ -0,0 +1,826 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.cl-action-button{ + width: 30%; + margin-bottom: 2%; + margin-right: 3%; + &:last-child { + margin-right: 0; + } + +} +#main .popover { + max-width: 330px; +} +// Pop over rules +.popover { + border: 2px solid #15B3E8; + .m_14_r; + z-index:100000; +} + +.popover .popover-title { + background-color: white; + margin-top: 5px; + .a_18_m; + padding: 5px 10px; +} + +.popover .popover-content { + padding: 5px 10px; + .m_16_r; +} +.popover .popover-content ul{ + list-style-type: none;// square; + padding-left:0px; + margin-left:0px; + .m_16_r; + word-wrap: break-word; +} +.cl-action-control { + padding-left:8% +} + +.checkList { + height:100%; + > #checklist-main-section { + height:80% !important; + } + + .blocked-area { + pointer-events: none; + opacity: 0.5; + filter: alpha(opacity=50); + background-color: white; + } + + #modal_header_checklist { + margin-top:0px; + padding: 0 29px; + } + + #modal-header-checklist-15 { + margin-top:0px; + padding: 0 15px; + } + + .rows { + + } + + + .font-deco { + text-decoration-line: underline; + text-decoration-style: dashed; + } + + .lineColor + { + background-color:#F6F3F3; + } + + .font_header + { + .m_18_m; + } + + .font_header_chk_name + { + .m_18_r; + } + + .font_user_name + { + .m_18_m; + } + + .font_date + { + .m_14_r; + } + + .font_line + { + border-bottom: 1px solid grey; + } + + .font_desc + { + .m_16_r; + text-align:left; + } + + .pad0 + { + padding:0px; + } + + .dash + { + border-bottom: dashed 1px; + border-color: @main_color_q; + padding: 0px; + } + + .italic + { + font-style:italic; + } + + + #modal-title { + margin: 0px; + } + + .checkList-form { + max-height: 100%; + //overflow-y: auto; + //overflow-x: hidden; + + #audit-log-lines { + + } + + + #checklist-subject + { + padding:0 15px; + margin-bottom: 0px; + } + + .checklist-modal-multi-select { + margin-top: 1%; + + .btn-group .btn { + .m_14_m; + } + } + + .btn { + width: 100%; + } + + .action-buttons{ + width: 100%; + margin-bottom: 7px; + } + + .col-no-pad + { + padding:0px; + } + + .col-no-top + { + margin:0px 0px 0px 0px; + } + + .text-right + { + text-align:right; + } + + .modal-header { + display: flex; + flex-direction: row; + + h2, h3 { + display: inline-block; + flex-grow: 10; + } + } + + .font_title + { + .a_16_m; + } + + .add-icon { + .sprite; + .sprite.add; + display: inline-block; + } + + + .add-button { + margin-top: 8px; + display: block; + .add-text { + .a_16_m; + vertical-align: top; + margin-left: 6px; + } + + } + + .margin_btm + { + margin-bottom:12px; + } + + .margin_top + { + margin-top:12px; + } + + .margin_btm5 + { + margin-bottom: 5px; + } + + + .personImage + { + .profiles-sprite; + .profiles-sprite.profile-large; + display: block; + } + + .table{ + margin-bottom: 0; + } + + .table-container-flex { + + .data-row-wrapper { + padding: 10px 20px; + } + + .flex-item:nth-child(1) { + padding-left: 0; + flex-grow: 25; + } + + .flex-item:nth-child(2) { + flex-grow: 25; + } + + .flex-item:nth-child(3) { + flex-grow: 25; + } + + .flex-item:nth-child(4) { + flex-grow: 25; + } + + } + + .table-container-flex-a { + + .data-row-wrapper { + padding: 10px 20px; + } + + .flex-item-a:nth-child(1) { + + padding-left: 0; + flex-grow: 40; + width:90%; + float:left; + } + + .flex-item-a:nth-child(2) { + + flex-grow: 25; + width:10%; + float:left; + } + } + //.a_16_m; + + .remove-icon { + cursor: pointer; + vertical-align: text-top; + //.sprite; + //.sprite.delete;//-circle; + .actions-sprite; + .actions-sprite.delete_large; + + display:block; + position:relative; + top:11px; + } + + + + + //.btn-primary-with-margin { + // border: 1px solid #8799A3; + // border-radius: 6px; + // background: #1E79B0; /* For browsers that do not support gradients */ + // background: -webkit-linear-gradient(#1E79B0, #62ADD5); /* For Safari 5.1 to 6.0 */ + // background: -o-linear-gradient(#1E79B0, #62ADD5); /* For Opera 11.1 to 12.0 */ + // background: -moz-linear-gradient(#1E79B0, #62ADD5); /* For Firefox 3.6 to 15 */ + // background: linear-gradient(#1E79B0, #62ADD5); /* Standard syntax (must be last) */ + // margin-bottom:7px; + //} + // + //.btn-primary { + // border: 1px solid #8799A3; + // border-radius: 6px; + // background: #1E79B0; /* For browsers that do not support gradients */ + // background: -webkit-linear-gradient(#1E79B0, #62ADD5); /* For Safari 5.1 to 6.0 */ + // background: -o-linear-gradient(#1E79B0, #62ADD5); /* For Opera 11.1 to 12.0 */ + // background: -moz-linear-gradient(#1E79B0, #62ADD5); /* For Firefox 3.6 to 15 */ + // background: linear-gradient(#1E79B0, #62ADD5); /* Standard syntax (must be last) */ + //} + + + .flex-item-a:nth-child(0) { + padding-left: 0; + flex-grow: 40; + width:80% + } + + .flex-item-a:nth-child(1) { + flex-grow: 25; + width:20%; + } + + //.content { + + .steps-progress-wrapper { + margin-top: 10px; + } + + .fnt + { + font-size:20px; + } + + h1 { + .a_36; + margin: 0 0 30px 0; + } + + h3 { + .m_18_m; + } + h2 { + margin: 0 0 10px 0; + .a_24_m; + position: relative; + .add-people, + .add-step { + .sprite; + .sprite.add; + display: inline-block; + margin-left: 8px; + cursor: pointer; + } + } + + .main-section { + margin-top: 30px; + } + } + + // dashboard css + padding:0 20px; + + #state-bar { + float:none; + height: 5%; + + } + #state-bar > ul { + border-bottom: dashed 1px; + border-color: @main_color_q; + padding-bottom:2px; + } + #state-bar > ul > li { + .m_14_r; + text-transform: uppercase; + text-align: left; + } + #state-bar > ul > li.active { + font-family:@font-omnes-bold; + } + + #state-bar > ul > li > .state-icon { + display: inline-block; + position: relative; + top: 2px; + margin-right:5px; + } + + #cl-header { + height:12%; + padding-top:1%; + } + + #cl-header > #cl-title { + padding-left: 0px; + .a_24; + } + #cl-header > #cl-title > span.bold { + .a_24_m; + } + #cl-header > #cl-title > #edit-checklist { + display: inline-block; + margin-right: 5px; + cursor: pointer; + } + + #cl-side-actions { + list-style: none; + margin-top: 5px; + } + + + #cl-side-actions > li { + display:inline-block; + margin-left:5px; + .n_12_m; + } + + .cl-action-buttons-frame{ + + list-style: none; + text-align: right; + } + + .cl-btn-associated { + border-bottom: 1px solid; + border-color: @main_color_l; + .a_26_m; + } + + .cl-btn-cl-audit { + margin-right: 15%; + border-bottom: 1px solid; + border-color: @main_color_l; + } + + + #state-actions { + display: inline-block; + border-bottom: 1px solid; + border-color: @main_color_q; + padding-bottom: 5px; + } + #state-actions button { + margin-left: 10px; + } + #state-actions button:first-child { + margin-left: 0px; + } + #cl-side-actions span { + cursor: pointer; + border-bottom: 2px solid @main_color_m; + //text-transform: uppercase; + border-bottom: 1px solid; + border-color: @main_color_q; + + } + + + #line-item-list { + list-style: none; + padding-right:15px; + } + + + #line-item-list > li { + margin-bottom: 25px; + } + #line-item-list > li > h2 { + text-transform: capitalize; + border-bottom: 1px solid; + border-color: @main_color_q; + width: 100%; + margin-bottom: 0px; + padding-left: 5px; + .m_24; + } + #line-item-list > li > h2 > span.bold { + .m_24_m; + } + + #line-item-list > li > ul { + list-style: none; + } + #line-item-list > li > ul >li.line-item-row { + border-bottom: 1px solid; + border-color: @main_color_q; + line-height: 30px; + padding: 0px; + vertical-align: middle; + height: 30px; + .m_16_r; + cursor: pointer; + } + + #line-item-list > li > ul >li.line-item-row .value-icon { + padding: 0px; + } + + #line-item-list > li > ul >li.line-item-row .value-icon span { + display: inline-block; + position: relative; + top: 3px; + margin-right: 5px; + margin-left: 3px; + width:15px; + height:15px; + } + + #line-item-list > li > ul >li.line-item-row .auto-icon { + text-align:right; + padding: 0px; + } + + #line-item-list > li > ul >li.line-item-row .auto-icon span { + display: inline-block; + position: relative; + top: 3px; + margin-right: 3px; + } + + #line-item-list > li > ul >li.line-item-row.selected-line { + background-color: @bg_color_a; + border-left: 2px solid; + border-top: 2px solid; + border-bottom: 2px solid; + border-color: @main_color_a; + position:relative; + z-index:1; + top: -1px; + left: -2px; + } + + #line-item-list > li > ul >li.line-item-row.selected-line > .selected-line-connector { + position: absolute; + right: -19px; + width: 20px; + height: 30px; + top: -2px; + background-color: @bg_color_a; + border-top: 2px solid; + border-bottom: 2px solid; + border-color: @main_color_a; + } + #line-item-extended { + background-color: @bg_color_a; + border: 2px solid; + border-color: @main_color_a; + padding:15px; + @media (min-width: 992px) { + max-height: 100%; + overflow-y: auto; + } + } + #line-item-extended >header { + padding: 0 30px; + padding-bottom: 0px; + } + #line-item-extended >header > h2 { + text-transform: capitalize; + padding:0px; + margin:0px; + line-height:32px; + .m_18_r; + } + #line-item-extended > header > h2 > span.bold { + .m_18_m; + } + #line-item-extended >header > #decision-actions { + list-style: none; + text-align: right; + margin:0px; + } + #line-item-extended >header > #decision-actions > li { + display: inline-block; + margin-left: 2px; + .sprite; + } + #line-item-extended >header > #decision-actions.active > li { + cursor:pointer; + } + + #line-item-extended >header > #decision-actions > li.not-relevant-btn { + .sprite.not-relevant-btn; + } + + #line-item-extended >header > #decision-actions.active > li.not-relevant-btn:hover { + .sprite.not-relevant-btn-active; + } + #line-item-extended >header > #decision-actions > li.not-relevant-btn.active { + .sprite.not-relevant-btn-active; + } + #line-item-extended >header > #decision-actions > li.denied-cl-btn { + .sprite.denied-cl-btn; + } + #line-item-extended >header > #decision-actions.active > li.denied-cl-btn:hover { + .sprite.denied-cl-btn-active; + } + #line-item-extended >header > #decision-actions > li.denied-cl-btn.active { + .sprite.denied-cl-btn-active; + } + #line-item-extended >header > #decision-actions > li.approved-cl-btn { + .sprite.approved-cl-btn; + } + #line-item-extended >header > #decision-actions.active > li.approved-cl-btn:hover { + .sprite.approved-cl-btn-active; + } + #line-item-extended >header > #decision-actions > li.approved-cl-btn.active { + .sprite.approved-cl-btn-active; + } + + + #line-item-extended > #line-item-description { + margin: 0 15px; + .m_16_r; + } + + #line-item-extended > #line-item-validation-instructions { + .m_14_r; + background-color: #fff; + border: 1px solid; + border-color: @main_color_a; + padding: 15px; + margin-top: 15px; + } + + #line-item-extended > #line-item-validation-instructions h3 { + text-transform: capitalize; + margin: 0px; + .m_18_m; + } + + #line-item-extended > #line-item-validation-instructions p { + margin-top: 5px; + + } + + #line-item-extended > #line-item-validation-instructions p ul { + padding-left: 15px; + } + + #line-item-extended > #line-item-audit-logs { + padding:0 15px; + } + + #line-item-extended > #line-item-audit-logs > h3 { + text-transform: capitalize; + .m_18_m; + + } + #line-item-extended > #line-item-audit-logs > #audit-log-list { + list-style:none; + + } + #line-item-extended > #line-item-audit-logs > #audit-log-list > li { + margin: 0 15px 10px; + border-bottom: 2px solid; + border-color: @main_color_q; + } + #line-item-extended > #line-item-audit-logs > #audit-log-list > li > .audit-creator { + .m_16_m; + margin:0px; + padding:0px; + } + #line-item-extended > #line-item-audit-logs > #audit-log-list > li > .audit-date { + text-align:right; + .m_14_r; + padding:0px; + } + #line-item-extended > #line-item-audit-logs > #audit-log-list > li > .audit-text { + .m_16_r; + margin-bottom:0px; + padding:0px; + } + + #line-item-extended > #line-item-audit-logs > #new-audit-log-from { + margin: 0 0 15px; + } + + #line-item-extended > #line-item-audit-logs > #new-audit-log-from #new-audit-log-text { + border-color: @main_color_q; + margin-bottom:15px; + } + + .btn-gradient-primary { + font-weight: bold; + color: #FFFFFF; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #37B2E5; + *background-color: #37B2E5; + background-image: -moz-linear-gradient(top, #0079AB, #37B2E5); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#0079AB), to(#37B2E5)); + background-image: -webkit-linear-gradient(top, #0079AB, #37B2E5); + background-image: -o-linear-gradient(top, #0079AB, #37B2E5); + background-image: linear-gradient(to bottom, #0079AB, #37B2E5); + background-repeat: repeat-x; + border-color: #37B2E5; + border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#0079AB', endColorstr='#37B2E5', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); + } + .btn-sample:hover, + .btn-sample:focus, + .btn-sample:active, + .btn-sample.active, + .btn-sample.disabled, + .btn-sample[disabled] { + color: #FFFFFF; + background-color: #37B2E5; + *background-color: #003bb3; + } + + .btn-gradient-success { + font-weight: bold; + color: #FFFFFF; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #41A02C; + *background-color: #41A02C; + background-image: -moz-linear-gradient(top, #A2E652, #41A02C); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#A2E652), to(#41A02C)); + background-image: -webkit-linear-gradient(top, #A2E652, #41A02C); + background-image: -o-linear-gradient(top, #A2E652, #41A02C); + background-image: linear-gradient(to bottom, #A2E652, #41A02C); + background-repeat: repeat-x; + border-color: #41A02C; + border-color: #888; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#A2E652', endColorstr='#41A02C', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); + } + .btn-sample:hover, + .btn-sample:focus, + .btn-sample:active, + .btn-sample.active, + .btn-sample.disabled, + .btn-sample[disabled] { + color: #FFFFFF; + background-color: #41A02C; + *background-color: #003bb3; + } + + .btn-gradient-danger { + font-weight: bold; + color: #FFFFFF; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #AE0020; + *background-color: #AE0020; + background-image: -moz-linear-gradient(top, #F74658, #AE0020); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#F74658), to(#AE0020)); + background-image: -webkit-linear-gradient(top, #F74658, #AE0020); + background-image: -o-linear-gradient(top, #F74658, #AE0020); + background-image: linear-gradient(to bottom, #F74658, #AE0020); + background-repeat: repeat-x; + border-color: #AE0020; + border-color: #888; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#F74658', endColorstr='#AE0020', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); + } + .btn-sample:hover, + .btn-sample:focus, + .btn-sample:active, + .btn-sample.active, + .btn-sample.disabled, + .btn-sample[disabled] { + color: #FFFFFF; + background-color: #AE0020; + *background-color: #003bb3; + } + + + + +} diff --git a/d2ice.att.io/app/main/dashboard/dashboard/dashboard.controller.js b/d2ice.att.io/app/main/dashboard/dashboard/dashboard.controller.js new file mode 100755 index 00000000..b6183b79 --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/dashboard/dashboard.controller.js @@ -0,0 +1,235 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + angular + .module('ice.dashboard.dashboard',['angularUtils.directives.dirPagination', 'ngFileSaver']) + .controller('DashboardMainController', ["$rootScope", "pageService", "stepsService", "vfService", "usersService", + "iceConstants", "localStorageService", "FileSaver", "Blob", "cmsService", "$uibModal", "$log", dashboardMainController]); + + function dashboardMainController($rootScope, pageService, stepsService, vfService, usersService, iceConstants, + localStorageService, FileSaver, Blob, cmsService, $uibModal, $log) { + var vm = this; + + var init = function () { + pageService.setPage('dashboard'); + cmsService.setAnnouncementToast(); + localStorageService.setJson("ice.settings.eng_uuid",undefined); + vm.stages = iceConstants.stages; + vm.stages.all = 'All'; + vm.search_keyword = ''; + vm.search_stage = 'All'; + vm.statistic_stage_filter = 'All'; + vm.current_starting_offset = "0"; + vm.num_of_returned_items = 0; + vm.pagination_num_of_objects = 8; + vm.me = vm.user = usersService.getUserData(); + vm.isAdminRo = usersService.isUserInRole(iceConstants.roles.admin_ro); + vm.isEngagmentEL = usersService.isUserInRole(iceConstants.roles.el); + vm.isEngagmentLead = usersService.isEngagementEL(vm.team); + vm.isAdmin = usersService.isAdmin(vm.me); + vm.page_num = 1; + vm.searchEngagements(1); + vm.request_statistics_data(); + getUserNextSteps(); + }; + + vm.request_statistics_data = function(){ + vfService.getEngagements(vm.me.uuid) + .then(function (response) { + if (response.status === 200 && response.data && response.data !== '') { + vm.enagements_search_list = response.data; + var vfc_array = undefined; + var vfc_num = 0; + var eng_num = 0; + vm.enagements_search_list.forEach(function (engagement) { + if(vm.statistic_stage_filter == "All") { + eng_num++; + if (engagement.engagement_stage == "Validated" || engagement.engagement_stage == "Completed") { + if (engagement.vfc.length > 1) { + vfc_array = engagement.vfc.split(", ").length; + vfc_num += vfc_array; + } + } + } + else { + if(engagement.engagement_stage == vm.statistic_stage_filter){ + eng_num++; + if (engagement.vfc.length > 1 && (engagement.engagement_stage == "Validated" || engagement.engagement_stage == "Completed")) { + vfc_array = engagement.vfc.split(", ").length; + vfc_num += vfc_array; + } + } + } + + }); + + vm.vfc_num = vfc_num; + vm.eng_num = eng_num; + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + + }; + + vm.onStageChange = function() { + vm.page_num = 1; + + vm.searchEngagements(); + }; + + vm.onKeywordChange = function() { + vm.page_num = 1; + + vm.searchEngagements(); + }; + + vm.searchEngagements = function () { + vm.current_starting_offset = (vm.page_num-1)*vm.pagination_num_of_objects; + vm.postData = {'stage': vm.search_stage, 'keyword': vm.search_keyword, 'offset': vm.current_starting_offset, 'limit': vm.pagination_num_of_objects}; + vfService.getExpandedEngagements(vm.postData) + .then(function (response) { + if (response.status === 200 && response.data && response.data !== '') { + vm.vf_search_list = response.data['array']; + vm.num_of_returned_items = response.data['num_of_objects']; + vm.vf_search_list.forEach(function (vf){ + var progress_needed_data = { + enable_edit: false, + completion_date: vf.engagement__target_completion_date, + ecomp_release: vf.ecomp_release__name, + vnf_version: vf.version, + aic_version: vf.deployment_target__version, + aic_instantiation_time:vf.engagement__aic_instantiation_time, + asdc_onboarding_time:vf.engagement__asdc_onboarding_time, + heat_validated_time:vf.engagement__heat_validated_time, + image_scan_time: vf.engagement__image_scan_time, + engagement_uuid: vf.engagement__uuid, + manual_id: vf.engagement__engagement_manual_id, + name: vf.vf__name, + starred: false + }; + vf.progress_needed_data = progress_needed_data; + vf.starred_users.forEach(function (user) { + if (vm.me.uuid == user) { + vf.progress_needed_data.starred = true; + } + }); + + + }); + vm.vf_display_list = vm.vf_search_list; + + addStatusesLoadedAttr(); + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + }; + + vm.goToEngagement = function(uuid){ + $rootScope.$broadcast('searchSelectEngagement',uuid); + }; + + vm.exportEngagementCSV = function() { + var stage = vm.search_stage || ""; + var keyword = vm.search_keyword || ""; + $rootScope.ice.loader.show = true; + + vfService.exportEngagementsCSV(stage, keyword) + .then(function(response) { + if(response && response.data) { + var data = new Blob([response.data], {type: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'}); + FileSaver.saveAs(data, 'D2Ice.xlsx'); + $rootScope.ice.loader.show = false; + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + }; + + vm.openCMSReadMoreModal = function(cmsPost) { + if(cmsPost) { + $uibModal.open({ + templateUrl: 'main/modals/cms-post-modal/cms-post-modal.html', + controller: 'cmsPostModalController', + controllerAs: 'vm', + size: 'cms-post-read-more', + resolve: { + post: function () { + return cmsPost; + } + } + }); + } else { + $log.warn("Cannot open cms post.") + } + }; + + function getUserNextSteps() { + vm.userNextSteps = []; + + stepsService.getByUser() + .then(function(response) { + vm.userNextSteps = response.data.data; + vm.userNextStepsCount = response.data.count; + }) + .catch(function (error) { + $log.error(error); + }); + }; + + function addStatusesLoadedAttr() { + angular.element(document).ready(function () { + var statusesTitleElement = angular.element( document.querySelector('#dashboard-title')); + if(statusesTitleElement && statusesTitleElement.length === 1) { + statusesTitleElement.attr('list-loaded', 'true'); + } + }); + }; + + init(); + } +})(); diff --git a/d2ice.att.io/app/main/dashboard/dashboard/dashboard.html b/d2ice.att.io/app/main/dashboard/dashboard/dashboard.html new file mode 100755 index 00000000..c03251b9 --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/dashboard/dashboard.html @@ -0,0 +1,111 @@ + +
+
+
+

Statuses

+ + Stage + + + +
+ +
+ + +
+ Export to Excel >> + +
+
+ +
diff --git a/d2ice.att.io/app/main/dashboard/dashboard/dashboard.less b/d2ice.att.io/app/main/dashboard/dashboard/dashboard.less new file mode 100755 index 00000000..4c824796 --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/dashboard/dashboard.less @@ -0,0 +1,189 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. + .dashboard .content-container #content { + height: 100%; + overflow-y: auto; + } +.dashboard-view { + padding: 10px; + + .steps-progress-wrapper { + border:none; + background-color: @main_color_p; + } + + + #dashboard-main-panel { + #dashboard-header { + #dashboard-title { + .a_26_m; + margin:0px; + line-height:40px; + } + .search-filters { + text-align: right; + .m_16_m; + line-height:40px; + .search-filter-stage { + margin-left:10px; + display: inline-block; + width: 40%; + } + #search-filter-keyword { + margin-left:10px; + display: inline-block; + width: 40%; + } + + } + } + #search-results { + .progress-bar-row { + padding:0px; + } + + .progress-bar-row:nth-child(even) .steps-progress-wrapper { + background-color: @func_color_r; + } + + #export-to-csv { + text-align : right; + .m_14_m; + text-decoration: underline; + cursor:pointer; + } + #engagements-pagination { + text-align:center; + .pagination { + margin:0px; + } + } + + } + + } + #dashboard-side-panel { + border-left: solid 1px @main_color_gray; + + #assgined-nextsteps { + border: 1px solid @toolbar_background_color; + padding:0px; + + #next-steps-header { + background-color: @toolbar_background_color; + .p_22_m; + padding: 10px 10px 0; + } + #next-steps-list { + list-style:none; + padding: 0 15px; + .next-step-details { + border-bottom: 1px dashed @main_color_a; + padding-bottom:10px; + + .next-step-details-header { + .engagement-title { + cursor:pointer; + .m_14_m; + margin-top: 15px; + margin-bottom: 0px; + .engagement-name { + text-decoration: underline; + } + } + .due-date { + .m_14_m; + margin-top: 10px; + margin-bottom: 0px; + text-align:right; + .due-date-icon { + } + } + } + .next-step-description { + .m_18_r; + margin: 3px 0px; + line-height: 20px; + } + .next-step-creation { + .m_14_r; + } + + } + .next-step-details:last-child { + padding:0px; + border:none; + } + } + } + .line-seperator { + border-bottom: dashed 1px @main_color_gray; + margin: 20px 0; + } + #statistics { + + border: 1px solid @main_color_gray; + padding:15px; + + #statistics-header { + margin-bottom: 10px; + h2 { + .m_24_m; + color: @main_color_gray; + margin: 0px; + } + .search-filters { + text-align: right; + .search-filter-stage { + margin-left:10px; + width:50%; + + } + } + } + #statistics-list { + .statistic-name { + } + .statistic-count { + text-align:right; + } + } + } + } +} diff --git a/d2ice.att.io/app/main/dashboard/detailed-view/detailed-view.controller.js b/d2ice.att.io/app/main/dashboard/detailed-view/detailed-view.controller.js new file mode 100755 index 00000000..c8af53f7 --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/detailed-view/detailed-view.controller.js @@ -0,0 +1,245 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + angular + .module('ice.dashboard.main') + .controller('detailedViewController', ["$rootScope", "$stateParams", "vfcService", "dtsiteService", "usersService", + "$uibModal", "vfService", "$log", "_", detailedViewController]); + + function detailedViewController($rootScope, $stateParams, vfcService, dtsiteService, usersService, $uibModal, vfService, $log, _) { + var vm = this; + + var init = function () { + $rootScope.timeGapLocal = moment().format("z");// timeGap(); + $rootScope.ampm = moment().format('A'); + $rootScope.mom = moment().tz(moment.tz.guess()).format('z'); + vm.is_aic_edit_mode = false; + vm.is_ecomp_edit_mode = false; + vm.aic_loaded = false; + vm.ecomp_loaded = false; + + if($stateParams.engagement != undefined) { + vm.engagement = $stateParams.engagement; + } + + if (vm.engagement != undefined) + { + vm.me = usersService.getUserData(); + vfService.getSingleEngagement(vm.me.uuid,vm.engagement.uuid) + .then(function (response) { + $rootScope.ice.loader.show = false; + + if (response.status === 200 && response.data && response.data !== '') { + var vf_data = response.data; + + vm.engagement_manual_id = vf_data.engagement.engagement_manual_id; + vm.vf_name = vf_data.name; + vm.vf_version = vf_data.version; + vm.vf_uuid = vf_data.uuid; + vm.ecomp_release = vf_data.ecomp_release; + vm.target_lab = new Date(vf_data.target_lab_entry_date); + vm.dtversion = vf_data.deployment_target; + vm.selected_dt_uuid = vm.dtversion.uuid; + vm.selected_ecomp_uuid = vm.ecomp_release.uuid; + vm.me = usersService.getUserData(); + vm.name = vm.engagement.name; + vm.isEngagementEL = usersService.isEngagementEL(vf_data.engagement.engagement_team); + vm.isAdmin = usersService.isAdmin(vm.me); + initDTsites(); + initVfcs(); + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + + } + }; + + + vm.addVfc = function () { + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/detailed-view/vfc/detailed-view-vfc-modal.html', + controller: 'detailedViewVFCModalController', + controllerAs: 'vm', + resolve: { + vf_uuid: function () { + return vm.vf_uuid; + }, + } + }); + modalInstance.result.then(function (data) { + if (data) { + initVfcs(); + } + }); + }; + this.personArray = [vm.dtversion,vm.vf_uuid]; + + vm.editValidationDetails = function () { + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/validation-details/detailed-view-validation-details-modal.html', + controller: 'validationDetailsModalController', + controllerAs: 'vm', + resolve: { + vf_uuid: function () { + return vm.vf_uuid; + } + } + }); + modalInstance.result.then(function (data) { + if (data) { + init(); + } + }); + }; + + vm.addDTS = function () { + if(vm.isEngagementEL || vm.isAdmin) { + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/detailed-view/dtsite/detailed-view-dtsites-modal.html', + controller: 'detailedViewDtsitesModalController', + controllerAs: 'vm', + resolve: { + vf_uuid: function () { + return vm.vf_uuid; + }, + } + }); + + modalInstance.result.then(function (data) { + if (data) { + if(data === 200) { + initDTsites(); + } + } + }); + } + }; + + + vm.changeTargetLabEntry = function(){ + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/target-lab-entry/change-lab-entry-date.html', + controller: 'ChangeLabEntryDateModalController', + controllerAs: 'vm', + resolve: { + targetLabDate: function () { + return vm.target_lab; + }, + engagementUuid: function () { + return vm.engagement.uuid; + } + } + }); + modalInstance.result.then(function (data) { + if (!data){ + return; + } + else { + vm.target_lab = new Date(data.target_date); + $log.debug("data.target_date",data.target_date) + $log.debug("vm.target_lab",vm.target_lab) + } + }, function () { + $log.error('Modal dismissed at: ' + new Date()); + }); + }; + //In case user press the delete icon next to a VFC, this function would be activated + vm.deleteVfc = function(vfc_uuid){ + vfcService.delete(vfc_uuid,vm.vf_uuid) + .then(function (response) { + if (response.status === 204) { + initVfcs(); + } + }) + .catch(function (error) { + $log.error(error); + }); + }; + + vm.deleteDTSite = function(vfUuid, dtsUuid){ + dtsiteService.delete(vm.vf_uuid, dtsUuid) + .then(function (response) { + if (response.status === 204) { + initDTsites(); + } + }) + .catch(function (error) { + $log.error(error); + }); + }; + + + var initDTsites = function() { + if(vm.isEngagementEL || vm.isAdmin) { + $rootScope.ice.loader.show = true; + dtsiteService.getVFSites(vm.vf_uuid) + .then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 200) { + vm.dtsites = response.data; + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + } + }; + + var initVfcs = function() { + $rootScope.ice.loader.show = true; + vfcService.get(vm.vf_uuid) + .then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 200) { + vm.vfcs = response.data; + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + }; + init(); + } +})(); diff --git a/d2ice.att.io/app/main/dashboard/detailed-view/detailed-view.html b/d2ice.att.io/app/main/dashboard/detailed-view/detailed-view.html new file mode 100755 index 00000000..02eb760a --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/detailed-view/detailed-view.html @@ -0,0 +1,109 @@ + +
+
+

{{vm.engagement_manual_id + ': '}}{{vm.vf_name}}

+
+
+
+
+
+ Validation Details + +
+
+
+
ECOMP Release: {{vm.ecomp_release.name}}
+
+
+
Target AIC Version:{{vm.dtversion.version}}
+
+
+
VF Version: {{vm.vf_version}}
+
+
+
+
+
+ Target Lab Entry + +
+
+

{{vm.target_lab | date:'shortDate'}}

+
+
+
+
+ Deployment Targets + +
+
+
    +
  • + {{dts.name}} + + + + +
  • +
+
+
+
+
+
+
+ Virtual Function Components + +
+
+
    +
  • + {{vfc.name +' (' + vfc.external_ref_id + ')'}} + + + + +
  • +
+
+
+
+
+
diff --git a/d2ice.att.io/app/main/dashboard/detailed-view/detailed-view.less b/d2ice.att.io/app/main/dashboard/detailed-view/detailed-view.less new file mode 100755 index 00000000..dbac5c2d --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/detailed-view/detailed-view.less @@ -0,0 +1,400 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +#detailed-view { + + padding:0px 30px 0px 30px; + + .glyphicon-cursor-detailed-view { + cursor: pointer; + margin-left: 0.5%; + } + + .detailed-view-edit-mode { + cursor: pointer; + margin-left: 0.5%; + display: inline-block; + position: relative; + top: 3px; + .sprite; + .sprite.edit-medium; + } + + .hide-element { + display:none; + } + + .show-select { + display:block; + margin-bottom: 3%; + } + + .row > h1 { + padding: 0px; + margin-bottom: 0px; + + .a_36; + + .bold { + .a_36_m; + } + } + + .remove-button { + height: 10px; + .a_16_m; + cursor: pointer; + + + .remove-icon { + .sprite; + .sprite.delete; + cursor: pointer; + display: block; + position: relative; + } + } + + .steps-progress-wrapper { + margin-top: 10px; + } + + + + h2 { + display: inline-block; + margin: 0 0 10px 0; + .a_24_m; + font-size: 20px; + position: relative; + .add-vfc { + .sprite; + .sprite.add; + display: inline-block; + margin-left: 8px; + cursor: pointer; + position: relative; + top: 3px; + } + } + + .main-section { + margin-top: 30px; + } + + .steps-header { + + .steps-filter { + display: inline-block; + float: right; + .a_16_m; + .todo { + .sprite; + .sprite.todo; + display: inline-block; + cursor: pointer; + } + .completed { + .sprite; + .sprite.pending; + display: inline-block; + cursor: pointer; + } + .confirmed { + .sprite; + .sprite.approved; + display: inline-block; + cursor: pointer; + } + } + } + + .vfc-column { + height: 100%; + padding-right: 20px; + padding-left: 20px; + padding-top: 20px; + + ul { + li.step { + + list-style: none; + position: relative; + padding: 5px 10px 0px 4px; + font-size: 16px; + } + } + } + + .vfc-steps { + border-right: dashed 1px @main_color_a; + height: 100%; + padding-right: 20px; + padding-left: 0px; + padding-top: 20px; + + ul { + li.step { + + list-style: none; + position: relative; + padding: 5px 10px 0px 4px; + font-size: 16px; + &:hover { + background-color: #DEF3FF; + + .details { + .actions { + span { + visibility: visible; + } + } + } + + } + + &.completed { + background-color: #dddddd; + opacity: 0.7; + } + + .description { + + .m_16_r; + border-bottom: dashed 1px @main_color_n; + padding: 10px 0; + + input { + position: absolute; + top: 10px; + left: 0; + margin-right: 20px; + } + + .step-text { + margin-left: 20px; + } + + .step-state { + + position: absolute; + top: 24px; + + &.todo { + .steps-sprite; + .steps-sprite.todo; + display: inline-block; + } + &.confirmed { + .steps-sprite; + .steps-sprite.confirmed; + display: inline-block; + } + &.completed { + .steps-sprite; + .steps-sprite.completed; + display: inline-block; + } + &.completed-non-el { + .steps-sprite; + .steps-sprite.completed-non-el; + display: inline-block; + } + } + + } + .details { + .m_12_r; + margin: 6px 0 10px 0; + + .actions { + float: right; + margin-top: 2px; + + span { + visibility: hidden; + } + + .moveto-confirmed { + .actions-sprite; + .actions-sprite.approve_large; + display: inline-block; + cursor: pointer; + } + .moveto-todo { + .actions-sprite; + .actions-sprite.reject_large; + display: inline-block; + cursor: pointer; + } + .moveto-delete { + .actions-sprite; + .actions-sprite.delete_large; + display: inline-block; + cursor: pointer; + } + } + } + } + } + + } + #deployment-targets { + border: 1px solid @engagement_team_color; + padding:0px; + margin-bottom: 20px; + + #deployment-targets-header { + background-color: @engagement_team_color; + .p_18_m; + padding: 5px 5px 0; + line-height: 35px; + + .edit-target-completion { + font-size: 21px; + vertical-align: middle; + padding-left: 6px; + cursor:pointer; + } + } + + #deployment-targets-content { + .f-type._16_r; + margin: 15px; + } + } + #virtual-function-components { + border: 1px solid @engagement_status_color; + padding:0px; + margin-bottom: 20px; + + #virtual-function-header { + background-color: @engagement_status_color; + .p_18_m; + padding: 5px 5px 0; + line-height: 35px; + + .edit-target-completion { + font-size: 21px; + vertical-align: middle; + padding-left: 6px; + cursor:pointer; + } + } + + #virtual-function-content { + .f-type._16_r; + margin: 15px; + } + } + + #target-lab-entry { + border: 1px solid @target_completion_color; + padding:0px; + margin-bottom: 20px; + + #target-lab-entry-header { + background-color: @target_completion_color; + .p_18_m; + padding: 5px 5px 0; + line-height: 35px; + + .edit-target-completion { + font-size: 21px; + vertical-align: middle; + padding-left: 6px; + cursor:pointer; + } + } + + #target-lab-entry-content { + .f-type._16_r; + margin: 15px; + } + } + #validation-details { + border: 1px solid #4990E2; + padding:0px; + margin-bottom: 20px; + + #validation-details-header { + background-color: #4990E2; + .p_18_m; + padding: 5px 5px 0; + line-height: 35px; + + .edit-target-completion { + font-size: 21px; + vertical-align: middle; + padding-left: 6px; + cursor:pointer; + } + } + + #validation-details-content { + .f-type._16_r; + margin: 15px; + } + } + .team-and-logs { + height: 100%; + padding-left: 20px; + padding-top: 20px; + margin-left: -1px; + border-left: dashed 1px @main_color_a; + + .line{ + margin-bottom: 10px; + } + + } + + .add-next-step-form { + .ice-wysiwyg { + height: 200px; + .wysiwyg-menu > div { + background-color: #f1f1f1; + padding: 2px; + } + } + } + + .vfc-main-section { + margin-top: 0px; + } +} diff --git a/d2ice.att.io/app/main/dashboard/get-started-modal/get-started-modal.directive.js b/d2ice.att.io/app/main/dashboard/get-started-modal/get-started-modal.directive.js new file mode 100755 index 00000000..3676e51c --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/get-started-modal/get-started-modal.directive.js @@ -0,0 +1,308 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + angular + .module('ice.dashboard.get-started-modal') + .directive('getStartedModal', function () { + return { + restrict: 'AEC', + scope: {}, + link: function (scope, elm, attrs) { + scope.$emit('openGettingStartedWizardLoaded'); + }, + controller: ['$rootScope', '$scope', '$uibModal', 'toastService', '$log', + function ($rootScope, $scope, $uibModal, toastService, $log) { + + var gm = this; + gm.data = {}; + + gm.openModal = function () { + toastService.clearToast(); + var modalInstance = $uibModal.open({ + templateUrl: 'main/dashboard/get-started-modal/wizard/wizard-container.html', + controller: 'ModalCtrl', + controllerAs: 'wizard', + resolve: { + wizardData: function () { + return gm.wizardData; + } + }, + backdrop: 'static' + }); + }; + + $scope.$on('openGettingStartedWizard', function (event, args) { + + gm.wizardData = args; + gm.openModal(); + }); + }], + controllerAs: 'gm' + }; + }) + .controller('ModalCtrl', ['$rootScope', '$scope', '$uibModalInstance', 'vfService', 'usersService', 'localStorageService', 'wizardData', 'toastService', '$log', '$i18next', + function ($rootScope, $scope, $uibModalInstance, vfService, usersService, localStorageService, wizardData, toastService, $log, $i18next) { + + var wizard = this; + wizard.steps = []; + wizard.data = {}; + wizard.user = wizardData.user; + wizard.is_service_provider_internal = wizardData.is_service_provider_internal; + wizard.eng_uuid = wizardData.eng_uuid; + wizard.requiredStep = wizardData.requiredStep; + + var serviceProviderName = $i18next.t('serviceProvider.name'); + + var availableSteps = { + addVF: {name: 'addVF', title: 'Add a VF'}, + addSponsor: { + name: 'addContact', + title: 'Add ' + serviceProviderName +' Sponsor', + mode: 'sponsor', + submitButton: 'Add ' + serviceProviderName + ' Sponsor' + }, + addVendor: { + name: 'addContact', + title: 'Add Vendor Contact', + mode: 'vendor', + submitButton: 'Add Vendor Cotact', + }, + inviteMembers: {name: 'inviteMembers', title: 'Invite Team Members'}, + addSSH: {name: 'addSSH', title: 'Add SSH Key'} + }; + + wizard.setStep = function (step) { + wizard.currentStep = step + wizard.title = step.title; + step.completed = true; + }; + + function initWizard() { + + $rootScope.ice.loader.show = true; + + if (wizardData.showActivationMessage) { + toastService.setToast('You have successfully activated your account!', 'success', {displayFor: 'modal'}); + } + + wizard.stepIndex = 0; + + if (wizard.requiredStep) { + wizard.steps.push(availableSteps[wizard.requiredStep]); + wizard.setStep(wizard.steps[wizard.stepIndex]); + $rootScope.ice.loader.show = false; + return; + } + + if (!wizard.eng_uuid || wizard.eng_uuid === "") { + wizard.steps.push(availableSteps.addVF); + } + if (wizard.user.is_service_provider_contact === true && !wizard.is_service_provider_internal) { + wizard.steps.push(availableSteps.addVendor); + } else if (!wizard.user.is_service_provider_contact) { + wizard.steps.push(availableSteps.addSponsor); + } + + getCompanies(); + + wizard.steps.push(availableSteps.inviteMembers); + + var userData = usersService.getUserData() || {}; + var ssh_public_key = userData.ssh_public_key; + if ((wizard.user.ssh_public_key === "" || wizard.user.ssh_public_key === null) && + (ssh_public_key === "" || ssh_public_key === null)) { + wizard.steps.push(availableSteps.addSSH); + } + + $rootScope.ice.loader.show = false; + wizard.setStep(wizard.steps[wizard.stepIndex]); + } + + initWizard(); + + wizard.getCurrentStep = function () { + return wizard.currentStep.name; + }; + + wizard.nextStep = function () { + wizard.clearMessage(); + wizard.stepIndex++; + + if (wizard.stepIndex === (wizard.steps.length)) { + wizard.closeWizard(); + return; + } + + wizard.setStep(wizard.steps[wizard.stepIndex]); + }; + + wizard.closeWizard = function () { + wizard.clearMessage(); + $uibModalInstance.close(); + + }; + + wizard.clearMessage = function () { + toastService.clearToast(); + }; + + wizard.onAddContactSubmit = function () { + $rootScope.ice.loader.show = true; + wizard.data.addContact.eng_uuid = wizard.eng_uuid; + + if (wizard.user.is_main_vendor_contact === true && !wizard.is_service_provider_internal) { + wizard.data.addContact.company = wizard.data.addContact.company; + } else if (!wizard.user.is_main_vendor_contact) { + wizard.data.addContact.company = wizard.data.attCompanyUuid; + } + + usersService.addVendorContact(wizard.data.addContact) + .then(function (response) { + if (response.status === 200) { + $rootScope.ice.loader.show = false; + wizard.nextStep(); + } + }, function (error) { + toastService.setToast(error.message, 'danger', {displayFor: 'modal'}); + $log.error(error.message); + $rootScope.ice.loader.show = false; + }) + .catch(function (error) { + wizard.Msg = error.status + " : " + error.statusText; + wizard.bgColor = "#FFEBEB"; // RED #FFEBEB green DFF0D9 + $log.error(error); + $rootScope.ice.loader.show = false; + }); + }; + + wizard.onInviteSubmit = function () { + $rootScope.ice.loader.show = true; + var is_service_provider_internal; + var jsonInviteMembers = []; + angular.forEach(wizard.inviteMembers.choices, function (value, key) { + wizard.item = []; + var jsonItem = new Object(); + jsonItem.email = value.email; + jsonItem.eng_uuid = wizard.eng_uuid; + jsonInviteMembers.push(jsonItem); + }); + + vfService.inviteMembers(JSON.stringify(jsonInviteMembers)) + .then(function (response) { + if (response.status === 200) { + wizard.nextStep(); + } + $rootScope.ice.loader.show = false; + }) + .catch(function (error) { + toastService.setToast(error.message.detail, 'danger', {displayFor: 'modal'}); + $rootScope.ice.loader.show = false; + $log.error(error.message); + }); + }; + + wizard.inviteMembers = { + choices: [ + { + email: '', + eng_uuid: '' + }] + }; + + wizard.addNewChoice = function () { + var newItemNo = wizard.inviteMembers.choices.length + 1; + wizard.inviteMembers.choices.push({'id': newItemNo}); + }; + + wizard.removeChoice = function () { + var lastItem = wizard.inviteMembers.choices.length - 1; + wizard.inviteMembers.choices.splice(lastItem); + }; + + wizard.onAddSSHSubmit = function () { + $rootScope.ice.loader.show = true; + usersService.setSSHKey(wizard.user.uuid, wizard.data.addSSH) + .then(function (response) { + if (response.status === 200) { + usersService.getIceUser() + .then(function (response) { + if (response.status === 200 && response.data && response.data !== '') { + wizard.user = response.data; + $rootScope.ice.loader.show = false; + $scope.$emit('onUpdateEngagements'); + } + }); + wizard.nextStep(); + } + + }).catch(function (error) { + toastService.setToast(error.message.detail, 'danger', {displayFor: 'modal'}); + $rootScope.ice.loader.show = false; + $log.error(error.message.detail); + }); + }; + + $scope.$on('moveWizardNextStep', function (event, args) { + wizard.is_service_provider_internal = args.is_service_provider_internal; + wizard.eng_uuid = args.engagement.uuid; + wizard.nextStep(); + }); + + function getCompanies() { + vfService.getCompanies() + .then(function (response) { + if (response.status === 200) { + wizard.companies = response.data; + if(wizard.companies!=undefined){ + for(var i=0; i diff --git a/d2ice.att.io/app/main/dashboard/get-started-modal/get-started-modal.less b/d2ice.att.io/app/main/dashboard/get-started-modal/get-started-modal.less new file mode 100755 index 00000000..81381198 --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/get-started-modal/get-started-modal.less @@ -0,0 +1,47 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. + +.getting-started-wizard { + + ul.step-indication { + li { + display: inline; + } + } +} diff --git a/d2ice.att.io/app/main/dashboard/get-started-modal/get-started-modal.module.js b/d2ice.att.io/app/main/dashboard/get-started-modal/get-started-modal.module.js new file mode 100755 index 00000000..6e54399a --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/get-started-modal/get-started-modal.module.js @@ -0,0 +1,48 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. + +(function () { + + 'use strict'; + + angular + .module('ice.dashboard.get-started-modal', ['ngAnimate', 'ui.bootstrap', 'ice.activation.addVf']); + + +})(); diff --git a/d2ice.att.io/app/main/dashboard/get-started-modal/wizard/wizard-container.html b/d2ice.att.io/app/main/dashboard/get-started-modal/wizard/wizard-container.html new file mode 100755 index 00000000..97628a62 --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/get-started-modal/wizard/wizard-container.html @@ -0,0 +1,192 @@ + + +
+ + + + + +
diff --git a/d2ice.att.io/app/main/dashboard/get-started-modal/wizard/wizard.less b/d2ice.att.io/app/main/dashboard/get-started-modal/wizard/wizard.less new file mode 100755 index 00000000..4398d975 --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/get-started-modal/wizard/wizard.less @@ -0,0 +1,255 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.dev-button { + position: absolute; + top: 0; + left: 0; +} + +.reject_large { + .actions-sprite; + .actions-sprite.reject_large; + cursor: pointer; +} + +.modal-content { + .getting-started-wizard { + .modal-header { + display: flex; + flex-direction: row; + + h2, h3 { + display: inline-block; + flex-grow: 10; + } + } + + .modal-body { + .btn { + width: 100%; + } + + .btn-primary { + border: 1px solid #8799A3; + border-radius: 6px; + background: #1E79B0; /* For browsers that do not support gradients */ + background: -webkit-linear-gradient(#1E79B0, #62ADD5); /* For Safari 5.1 to 6.0 */ + background: -o-linear-gradient(#1E79B0, #62ADD5); /* For Opera 11.1 to 12.0 */ + background: -moz-linear-gradient(#1E79B0, #62ADD5); /* For Firefox 3.6 to 15 */ + background: linear-gradient(#1E79B0, #62ADD5); /* Standard syntax (must be last) */ + } + } + } +} + +.getting-started-wizard { + + + + + + md-datepicker.btn.datepicker_btn { + .md-datepicker-input { + width: 100%; + text-align: center; + line-height: 32px; + } + } + #vf-name-title { + font-size: 16px; + } + #title-key-metadata{ + font-size: 16px; + position: relative; + top: 20px; + left: 30px; + background: white; + padding: 0 20px; + margin-top: -15px; + } + .fields_key_metadata{ + border:1px solid #ccc; + padding: 26px 10px; + + } + /* Override addVf pages styles */ + .container { + width: auto; + + .col-md-2 { width: 0; } + .col-md-8 { width: 100%; } + + .table-container-flex .flex-item { + padding: 5px 5px; + } + + .remove-button { + display: none; + } + } + + .table-container-flex { + + .flex-item:nth-child(1) { + padding-left: 0; + flex-grow: 33; + } + + .flex-item:nth-child(2) { + flex-grow: 33; + } + + .flex-item:nth-child(3) { + flex-grow: 33; + } + + } + + ul.step-indication { + list-style: none; + display: inline-block; + + li { + display: inline-block; + background-color: #DDDDDD; + width: 30px; + height: 30px; + margin-right: 10px; + padding: 6px 11px; + .m_14_m; + + &.selected { + .p_14_m; + background-color: #1370A3; + } + + &:last-child { + margin-right: 0; + } + } + } + + .addVendorContact-form { + padding: 20px 0 0 0; + + button { + margin-top: 10px; + } + } + + .inviteMembers-form { + padding: 20px 0 0 0; + + button { + margin-top: 10px; + } + + .add-button { + margin-top: 8px; + display: block; + .add-text { + .a_16_m; + vertical-align: top; + margin-left: 6px; + } + .add-icon { + .sprite; + .sprite.add; + display: inline-block; + } + } + + .remove-button { + vertical-align:middle; + .a_16_m; + cursor: pointer; + + .remove-icon { + display: inline-block; + vertical-align: text-top; + margin-right: 6px; + .sprite; + .sprite.delete-circle; + cursor: pointer; + } + } + + + .remove-button { + vertical-align:middle; + .a_16_m; + cursor: pointer; + + .reject-large { + display: inline-block; + vertical-align: text-top; + margin-right: 6px; + .sprite; + .sprite.delete-circle; + cursor: pointer; + } + } + + .input-wrapper { + margin-bottom: 10px; + } + + } + + .addVf-form { + padding: 0; + } + + .addSsh-form { + padding: 0; + + .form-group { + margin-top: 20px; + } + + button { + margin-top: 10px; + } + + textarea { + min-height: 80px; + } + } + +} diff --git a/d2ice.att.io/app/main/dashboard/main.module.js b/d2ice.att.io/app/main/dashboard/main.module.js new file mode 100755 index 00000000..01a34a84 --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/main.module.js @@ -0,0 +1,107 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.dashboard.main', ['ice.dashboard.get-started-modal']) + .config(config); + + function config($stateProvider) { + + $stateProvider + .state('app.dashboard', { + abstract: true, + views: { + 'navigation@app': { + templateUrl: 'core/navigation/layouts/horizontal-navigation/navigation.html', + controller: 'NavigationController as vm' + } + }, + bodyClass: 'dashboard' + }). + state('app.dashboard.dashboard', { + url: '/dashboard/dashboard', + views: { + 'content@app': { + templateUrl: 'main/dashboard/dashboard/dashboard.html', + controller: 'DashboardMainController as vm' + }, + }, + params: {engagement_uuid: null,engagement:null,messagePass: null}, + bodyClass: 'dashboard' + }). + state('app.dashboard.overview', { + url: '/dashboard/overview', + views: { + 'content@app': { + templateUrl: 'main/dashboard/overview/overview.html', + controller: 'OverviewMainController as vm' + }, + }, + params: {engagement_uuid: null,engagement:null,messagePass: null}, + bodyClass: 'dashboard' + }). + state('app.dashboard.detailedview', { + url: '/dashboard/detailedview', + views: { + 'content@app': { + templateUrl: 'main/dashboard/detailed-view/detailed-view.html', + controller: 'detailedViewController as vm' + }, + }, + params: {engagement_uuid: null,engagement:null}, + bodyClass: 'dashboard' + }). + state('app.dashboard.checklist', { + url: '/dashboard/checklist', + views: { + 'content@app': { + templateUrl: 'main/dashboard/checklist/checklist.html', + controller: 'DashboardChecklistController as vm' + }, + }, + params: {engagement_uuid: null,sub_id:null,engagement:null}, + bodyClass: 'dashboard' + }); + + } + +})(); diff --git a/d2ice.att.io/app/main/dashboard/main/main.html b/d2ice.att.io/app/main/dashboard/main/main.html new file mode 100755 index 00000000..f768619e --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/main/main.html @@ -0,0 +1,172 @@ + +
+ + +
+
+ +

{{vm.name}}

+
+ GIT: {{vm.git_repo_url}} +
+ +
+ +
+
+
+
+

Next Steps

+ + Files + + States + + +
+
    +
  • +
    + +
    +
    + + {{step.last_updater && step.last_updater.full_name || step.creator.full_name}} +  {{step.last_update_type}}:  + + {{(step.last_update_time) | date2: 'EEEE MMMM doo yyyy'}} at {{(step.last_update_time) | date: 'hh:mm' : timeGapLocal }} {{ampm}} {{mom}} +
    +
    +
    +
    +
    + {{(step['due_date']) | date2: 'EEEE MMMM doo yyyy'}} + + +
      + +
    • +
    • +
    + Associated Files ({{step.files.length}}) + +
    +
    +
  • +
+
+
+ +
+

Current Status

+ + Last updated {{(vm.status.update_time) | date2: 'EEEE MMMM doo yyyy'}} at {{(vm.status.update_time) | date: 'hh:mm' : timeGapLocal }} {{ampm}} {{mom}} + by {{vm.status.creator.full_name}} + +

{{vm.status.description == undefined && 'No status update has been provided yet.' || vm.status.description }}

+
+ +
+

Team Members

+
    +
  • + +
  • +
+
+ +
+

Activity Log

+
    +
  • + +
  • +
+
+ +
+ +
+
diff --git a/d2ice.att.io/app/main/dashboard/overview/overview.controller.js b/d2ice.att.io/app/main/dashboard/overview/overview.controller.js new file mode 100755 index 00000000..19d9839f --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/overview/overview.controller.js @@ -0,0 +1,833 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { +//test + 'use strict'; + + angular + .module('ice.dashboard.overview',[]) + .controller('OverviewMainController', ["$scope","$rootScope", "_","$stateParams", "statusService", "stepsService", "vfService", "usersService", "iceConstants", "$uibModal", "cmsService", "toastService", "$state", "$log", overviewMainController]); + + function overviewMainController($scope,$rootScope,_, $stateParams, statusService, stepsService, vfService, usersService, iceConstants, $uibModal, cmsService, toastService, $state, $log) { + var vm = this; + + vm.sortableOptions = { + handle: ' .order-nextstep', + axis: 'y', + update: function(e, ui) { + stepsService.order_next_steps(vm.engagement.uuid, vm.steps) + .then(function (response) { + if (response.status === 200) { + $log.debug('updated'); + } + }) + .catch(function (error) { + $log.error(error); + }); + } + }; + + var init = function () { + cmsService.setAnnouncementToast(); + $rootScope.timeGapLocal = moment().format("z");// timeGap(); + $rootScope.ampm = moment().format('A'); + $rootScope.mom =moment().tz( moment.tz.guess()).format('z'); + + vm.engagement = $stateParams.engagement; + + if (vm.engagement != undefined) + { + vm.me = usersService.getUserData(); + vfService.getSingleEngagement(vm.me.uuid,vm.engagement.uuid) + .then(function (response) { + $rootScope.ice.loader.show = false; + + if (response.status === 200 && response.data && response.data !== '') { + vm.vf = response.data; + vm.is_service_provider_internal = vm.vf.is_service_provider_internal; + vm.name = vm.vf.name; + vm.manual_id = vm.vf.engagement.engagement_manual_id; + if(!vm.vf.git_repo_url || vm.vf.git_repo_url==-1){ + vm.git_repo_url = false; + } + else { + vm.git_repo_url = vm.vf.git_repo_url; + } + vm.storage_bucket_url = vm.manual_id + '_' + vm.name.toLowerCase(); + vm.team = vm.vf.engagement.engagement_team; + vm.me = usersService.getUserData(); + vm.stages = iceConstants.stages; + vm.stage = vm.vf.engagement.engagement_stage; + vm.stage_num = 0; + vm.set_stage_num(vm.stage); + vm.in_overview_page = true; + vm.uuid = vm.engagement.uuid; + vm.progress = vm.vf.engagement.progress; + vm.completion_date = vm.vf.engagement.target_completion_date; + vm.starred = false; + vm.isEngagmentLead = usersService.isUserInRole('el'); + vm.isEngagementEL = usersService.isEngagementEL(vm.team); + vm.isAdmin = usersService.isAdmin(vm.me); + vm.does_user_role_allow_action_array = [vm.isAdmin, vm.isEngagementEL]; + vm.unremoveable_users_from_eng_team_array = [vm.vf.engagement.reviewer.uuid, vm.vf.engagement.peer_reviewer.uuid, + vm.vf.engagement.creator.uuid] + if (vm.vf.engagement.contact_user != null) { + vm.unremoveable_users_from_eng_team_array.push(vm.vf.engagement.contact_user.uuid); + } + vm.states = iceConstants.states; + vm.states_select = serializeStates(iceConstants.states); + vm.selected_state_filter = getSelectedStatesByUserType(); + vm.steps = []; + vm.vf_name = vm.vf.name; + vm.vf.engagement.starred_engagement.forEach(function(user) { + if (vm.me.uuid == user.uuid) + vm.starred = true; + }); + vm.all_states = false; + vm.all_files = true; + initSteps(); + vm.initActivityLogs(); + vm.files = vm.vf.files; + vm.files_filter_options = []; + vm.files_filter_options = vm.files_filter_options.concat(vm.files); + vm.files_filter_options.push("Any file"); + vm.chosen_files_filter = ["Any file"]; + vm.show_step = true; + vm.status = false; + statusService.get(vm.uuid) + .then(function (response) { + if (response.status === 200) + { + vm.status = response.data; + } else + { + $log.error(response); + } + }) + .catch(function (error) { + vm.status = false; + $log.error(error.message); + }); + vm.progress_needed_data = getEngagementProgressData(); + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + + } + }; + + vm.set_stage_num = function(state) { + switch (state) { + case 'Intake': + vm.stage_num = 1; + break; + case 'Active': + vm.stage_num = 2; + break; + case 'Validated': + vm.stage_num = 3; + break; + case 'Completed': + vm.stage_num = 4; + break; + }; + }; + + vm.checkIfAdmin = function(user){ + return usersService.isAdmin(user); + }; + + + vm.is_user_allowed = function(){ + if(_.includes(vm.does_user_role_allow_action_array, true) == true){ + return true; + } + else { + return false; + } + } + + + vm.is_able_to_delete = function(requested_user){ + if(vm.is_user_allowed() && !_.includes(vm.unremoveable_users_from_eng_team_array, requested_user.uuid) + && !vm.checkIfAdmin(requested_user)) { + return true; + } + else { + return false; + } + }; + + + vm.remove_user_from_eng = function(requested_user){ + if(vm.is_able_to_delete(requested_user)) { + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/general-prompt-modal/general-prompt-modal.html', + controller: 'generalPromptModalController', + controllerAs: 'vm', + resolve: { + modalDetails: function () { + return { + "upper_headline": 'Remove user from engagement team: ', + "upper_headline_value": requested_user.full_name, + "headline": 'Are you sure you would like to remove the user out of the team members?', + "is_message":false, + "message": '', + "approve": 'Yes', + "cancelText": 'No', + "is_close_modal_button":true + }; + } + } + }); + //in order to close the ui-popover before opening the confirmation modal. + angular.element('body').click(); + + modalInstance.result.then(function (approve_deletion) { + if(approve_deletion) { + var data = {'eng_uuid': vm.vf.engagement.uuid, 'user_uuid': requested_user.uuid} + vfService.remove_user_from_eng(data).then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 204) { + $rootScope.$broadcast('onUpdateEngagements',{select : {uuid:vm.engagement.uuid,page_type:'overview',sub_id:undefined}}); + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + } + }); + } + else { + toastService.setToast('Action is not allowed.', 'danger'); + $rootScope.ice.loader.show = false; + return; + } + }; + + + $scope.is_match_both_filters = function () { + return function (step) { + + var result = false; + + if(vm.all_files && vm.all_states) { + result = true; + } + else if (vm.all_states && vm.is_contain_files(step)){ + result = true; + } + else if (vm.all_files && vm.is_same_state(step.state)){ + result = true; + } + else if (vm.is_contain_files(step) && vm.is_same_state(step.state)){ + result = true; + } + + if (result) { + return step; + } + return false; + } + } + + vm.is_all_files = function() { + vm.all_files = vm.chosen_files_filter.indexOf("Any file") !== -1; + } + + vm.is_contain_files = function(step) { + if (step.files) { + for (var i = 0; i < step.files.length; i++) { + if (vm.chosen_files_filter.indexOf(step.files[i]) !== -1) { + return true; + } + } + } + + return false; + }; + + vm.is_same_state = function(step_state){ + return vm.selected_state_filter.indexOf(step_state) !== -1; + }; + + vm.update_next_steps_choice = function(){ + if(vm.selected_state_filter.indexOf("All") !== -1){ + vm.all_states = true; + } + else { + vm.all_states = false; + } + }; + + vm.editStatus = function () { + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/status/status.html', + controller: 'StatusModalController', + controllerAs: 'vm', + size: 'lg', + resolve: { + + engagement_uuid: function () { + return vm.engagement.uuid; + }, + action: function () { + return 'edit'; + } + } + }); + + // Update the progress after modal closed. + modalInstance.result.then(function (data) { + if (data) { + vm.status = data; + } + }, function () { + $log.debug('Modal dismissed at: ' + new Date()); + }); + }; + + vm.addStatus = function () { + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/status/status.html', + controller: 'StatusModalController', + controllerAs: 'vm', + size: 'lg', + resolve: { + + engagement_uuid: function () { + return vm.engagement.uuid; + }, + action: function () { + return 'add'; + } + } + }); + + // Update the progress after modal closed. + modalInstance.result.then(function (data) { + if (data) { + vm.status = data; + } + }, function () { + $log.debug('Modal dismissed at: ' + new Date()); + }); + }; + + vm.deleteStep = function(step_uuid){ + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/general-prompt-modal/general-prompt-modal.html', + controller: 'generalPromptModalController', + controllerAs: 'vm', + resolve: { + modalDetails: function () { + return { + "headline": 'Delete Step', + "is_message":true, + "message": 'Are you sure you want to delete this step?', + "approve": 'Delete Step', + "is_close_modal_button":true + }; + } + } + }); + + modalInstance.result.then(function (deletionApproved) { + if(deletionApproved) { + stepsService.delete(step_uuid) + .then(function (response) { + if (response.status === 204) { + initSteps(); + initActivityLogs(); + } + }) + .catch(function (error) { + $log.error(error); + }); + } + }); + }; + + // next steps modal + vm.editStep = function (nextstep) { + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/next-steps/next-steps.html', + controller: 'NextStepsModalController', + controllerAs: 'vm', + size: 'lg', + resolve: { + + engagement_team: function () { + return vm.team; + }, + title: function () { + return vm.engagement.name; + }, + associated_files: function () { + return vm.files; + }, + engagement_uuid: function () { + return vm.engagement.uuid; + }, + checklist: function () { + return undefined; + }, + nextstep: function () { + return nextstep; + } + } + }); + + // Update the progress after modal closed. + modalInstance.result.then(function (data) { + if (data) { + initSteps(); + } + }, function () { + $log.debug('Modal dismissed at: ' + new Date()); + }); + }; + + vm.addStep = function () { + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/next-steps/next-steps.html', + controller: 'NextStepsModalController', + controllerAs: 'vm', + size: 'lg', + resolve: { + engagement_team: function () { + return vm.team; + }, + title: function () { + return vm.engagement.name; + }, + associated_files: function () { + return vm.files; + }, + engagement_uuid: function () { + return vm.engagement.uuid; + }, + checklist: function () { + return undefined; + }, + nextstep: function () { + return undefined; + } + } + }); + + // Update the progress after modal closed. + modalInstance.result.then(function (data) { + if (data) { + data.forEach(function (step) { + step['creator'] = vm.me; + vm.steps.push(step); + }); + initSteps(); + } + }, function () { + $log.debug('Modal dismissed at: ' + new Date()); + }); + }; + + $rootScope.$on('onUpdateNextSteps', function (event, args) { + if(args.eng_uuid && args.stage){ + vm.uuid = args.eng_uuid; + vm.stage = args.stage; + } + else{ + $log.error("onUpdateNextStep expecting args"); + return; + } + initSteps(); + }); + + vm.starEngagement = function () { + + vfService.putStarredEngagements(vm.engagement.uuid) + .then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 200 && response.data && response.data !== '') { + if (vm.starred == true) + vm.starred = false + else + vm.starred = true + $rootScope.$broadcast('onUpdateEngagements',{select : {uuid:vm.engagement.uuid,page_type:'overview',sub_id:undefined}}); + + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + } + + vm.updateStep = function (stepUuid, stepState) { + var data = {"state":stepState}; + stepsService.update(stepUuid, data) + .then(function (response) { + if (response.status === 200) { + var step = getStepByUuid(stepUuid); + if (step){ + initSteps(); + vm.initActivityLogs(); + } + } + }) + .catch(function (error) { + $log.error(error); + }); + }; + + vm.toggleCompleted = function (stepUuid) { + var step = getStepByUuid(stepUuid); + if (step){ + if(step.state == vm.states.incomplete){ + vm.updateStep(stepUuid, iceConstants.states.completed); + }else if(step.state == vm.states.completed){ + vm.updateStep(stepUuid, iceConstants.states.incomplete); + } + + } + }; + + vm.updateProgress = function(data) { + if (data && data.progress){ + vm.progress = data.progress; + } else if (data && data.target_date){ + vm.completion_date = data.target_date; + vm.target_completion_date = data.target_date; + } + }; + + vm.addPeople = function () { + + var args = { + user: vm.me, + eng_uuid: vm.engagement.uuid, + is_service_provider_internal: vm.is_service_provider_internal, + requiredStep: 'inviteMembers' + }; + + $rootScope.$broadcast('openGettingStartedWizard', args); + }; + + var initSteps = function() { + $rootScope.ice.loader.show = true; + stepsService.get(vm.uuid, vm.stage) + .then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 200) { + vm.steps = []; + response.data.forEach(function (step) { + vm.steps.push(step); + }); + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + }; + + vm.initActivityLogs = function() { + $rootScope.ice.loader.show = true; + vfService.getActivities(vm.uuid) + .then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 200) { + vm.activities = response.data; + + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + }; + + var getStepByUuid = function(stepUuid) { + var foundStep; + if (vm.steps) { + vm.steps.forEach(function (step) { + if (step.uuid === stepUuid) { + foundStep = step; + } + }); + } + return foundStep; + }; + + var serializeStates = function(states) { + var result = [] + for(var key in states) { + result.push(states[key]) + } + + return result; + }; + + var getSelectedStatesByUserType = function() { + var result = []; + +// if(vm.isEngagementEL || vm.isAdmin) { +// result.push("All","Completed","Incomplete"); +// } else { //For normal users: + result.push("Incomplete") +// } + + return result; + }; + + var getEngagementProgressData = function() { + var result = { + "enable_edit": ((vm.isEngagementEL || vm.isAdmin) && vm.in_overview_page), + "completion_date":vm.vf.engagement.target_completion_date, + "ecomp_release": vm.vf.ecomp_release.name, + "vnf_version": vm.vf.version, + "aic_version":vm.vf.deployment_target.version, + "aic_instantiation_time":vm.vf.engagement.aic_instantiation_time, + "asdc_onboarding_time":vm.vf.engagement.asdc_onboarding_time, + "heat_validated_time":vm.vf.engagement.heat_validated_time, + "image_scan_time":vm.vf.engagement.image_scan_time, + "engagement_uuid": vm.uuid, manual_id: vm.manual_id + }; + + return result; + }; + + vm.archiveEngagement = function() { + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/archive-engagement-modal/archive-engagement-modal.html', + controller: 'archiveEngagementModalController', + controllerAs: 'vm', + resolve: { + engagementDetails: function () { + return { + "manual_id": vm.manual_id, + "name": vm.name, + "engagement": vm.engagement + }; + } + } + }); + + modalInstance.result.then(function (archiveReason) { + if(archiveReason && vm.engagement && vm.engagement.uuid) { + vfService.archiveEngagement(vm.engagement.uuid, archiveReason) + .then(function() { + $state.go('app.dashboard.dashboard'); + toastService.setToast("Engagement '" + vm.engagement.name + "' archived successfully.", 'success'); + }) + .catch (function(error) { + toastService.setToast("Server failed archiving engagement.", 'danger'); + $rootScope.ice.loader.show = false; + $log.error(error); + }); + } else { + toastService.setToast("No reason was supplied, therefor engagement cannot be archived.", 'danger'); + } + }); + }; + + vm.changeReviewer = function() { + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/select-el-modal/select-el-modal.html', + controller: 'selectELModalController', + controllerAs: 'vm', + resolve: { + // We are not allow the reviewer and peer reviewer to be the same: + excludeUuids: function () { + return [vm.engagement.peer_reviewer_uuid]; + }, + selectedOption: function() { + return vm.engagement.reviewer_uuid; + } + } + }); + + modalInstance.result.then(function (userUuid) { + if(vm.engagement && vm.engagement.uuid) { + + if (userUuid == vm.engagement.peer_reviewer_uuid) { + vfService.switchEngagementReviewers(vm.engagement.uuid, userUuid, vm.engagement.reviewer_uuid) + .then(function (response) { + vm.engagement.reviewer_uuid = response.data.reviewer; + vm.engagement.peer_reviewer_uuid = response.data.peerreviewer; + toastService.setToast("Reviewer and peer reviewer updated successfully.", 'success'); + }) + .catch(function (error) { + toastService.setToast("Server failed to update engagement reviewers.", 'danger'); + $rootScope.ice.loader.show = false; + $log.error(error); + }); + } else { + vfService.updateEngagementReviewer(vm.engagement.uuid, userUuid) + .then(function(response){ + _.remove(vm.team, function(user) {return user.uuid === vm.engagement.reviewer_uuid;}); + vm.team.push(response.data); + vm.engagement.reviewer_uuid = response.data.uuid; + toastService.setToast("Reviewer updated successfully.", 'success'); + }) + .catch(function(error) { + toastService.setToast("Server failed to update engagement reviewer.", 'danger'); + $rootScope.ice.loader.show = false; + $log.error(error); + }); + }} else { + toastService.setToast("Problem occurred while updating reviewer - missing engagement uuid.", 'danger'); + } + }) + }; + + vm.changePeerReviewer = function() { + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/select-el-modal/select-el-modal.html', + controller: 'selectELModalController', + controllerAs: 'vm', + resolve: { + // We are not allow the reviewer and peer reviewer to be the same: + excludeUuids: function () { + return [vm.engagement.reviewer_uuid]; + }, + selectedOption: function() { + return vm.engagement.peer_reviewer_uuid; + } + } + }); + + modalInstance.result.then(function (userUuid) { + if(vm.engagement && vm.engagement.uuid) { + + if (userUuid == vm.engagement.reviewer_uuid) { + vfService.switchEngagementReviewers(vm.engagement.uuid, vm.engagement.peer_reviewer_uuid, userUuid) + .then(function (response) { + vm.engagement.reviewer_uuid = response.data.reviewer; + vm.engagement.peer_reviewer_uuid = response.data.peerreviewer; + toastService.setToast("Peer reviewer and reviewer updated successfully.", 'success'); + }) + .catch(function (error) { + toastService.setToast("Server failed to update engagement reviewers.", 'danger'); + $rootScope.ice.loader.show = false; + $log.error(error); + }); + } else { + vfService.updateEngagementPeerReviewer(vm.engagement.uuid, userUuid) + .then(function(response) { + $log.debug("vm.team", vm.team); + _.remove(vm.team, function(user) {return user.uuid === vm.engagement.peer_reviewer_uuid;}); + vm.team.push(response.data); + vm.engagement.peer_reviewer_uuid = response.data.uuid; + toastService.setToast("Peer reviewer updated successfully.", 'success'); + }) + .catch(function(error) { + toastService.setToast("Server failed to update engagement peer reviewer.", 'danger'); + $rootScope.ice.loader.show = false; + $log.error(error); + }); + }} else { + toastService.setToast("Problem occurred while updating peer reviewer - missing engagement uuid.", 'danger'); + } + }) + }; + + vm.updateEngagementStatus = function() { + vm.vf.engagement.progress = parseInt(vm.progress); + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/update-engagement-status-modal/update-engagement-status-modal.html', + controller: 'updateEngagementStatusModalController', + controllerAs: 'vm', + resolve: { + engagement: function () { + // We will deliver a copy of the engagement so if the user hit 'Cancel' we won't change the original: + return angular.copy(vm.vf.engagement); + } + } + }); + + modalInstance.result.then(function (result) { + vfService.updateEngagement(result.engagement, result.status) + .then(function(response) { + vm.vf.engagement = result.engagement; + vm.progress = vm.vf.engagement.progress; + vm.progress_needed_data = getEngagementProgressData(); + vm.status = response.data; + toastService.setToast("Engagement status updated successfully.", 'success'); + }) + .catch(function(error){ + toastService.setToast("Server failed to update engagement status.", 'danger'); + $rootScope.ice.loader.show = false; + $log.error(error); + }); + }) + }; + + vm.changeTargetCompletion = function(){ + var modalInstance = $uibModal.open({ + templateUrl: 'main/modals/change-date/change-date.html', + controller: 'ChangeDateModalController', + controllerAs: 'vm', + resolve: { + completionDate: function () { + return vm.vf.engagement.target_completion_date; + }, + engagementUuid: function () { + return vm.engagement.uuid; + } + } + }); + + modalInstance.result.then(function (data) { + if (!data){ + return; + } + vm.completion_date = data.target_date || vm.vf.engagement.target_completion_date; + vm.vf.engagement.target_completion_date = vm.completion_date; + }, function () { + $log.debug('Modal dismissed at: ' + new Date()); + }); + }; + + init(); + } +})(); diff --git a/d2ice.att.io/app/main/dashboard/overview/overview.html b/d2ice.att.io/app/main/dashboard/overview/overview.html new file mode 100755 index 00000000..d1b3fc40 --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/overview/overview.html @@ -0,0 +1,212 @@ + +
+ +
+ + +
+
+ +

+ {{vm.manual_id}}: {{vm.name}} +

+ + + +
+
+ GIT: {{vm.git_repo_url}} + + STORAGE BUCKET: {{vm.storage_bucket_url}} +
+
+ +
+ + +
+ +
+
+
+

Next Steps

+ + Files + + States + + +
+
    +
  • + +
    + +
    +
    + + + {{step.engagement ? (step.last_updater && step.last_updater.full_name || step.creator.full_name) : "System Next Step"}} +  {{step.last_update_type}}:  + + {{(step.last_update_time) | date2: 'EEEE MMMM doo yyyy'}} at {{(step.last_update_time) | date: 'hh:mm' : timeGapLocal }} {{ampm}} {{mom}} +
    +
    +
    +
    +
    + {{(step['due_date']) | date2: 'EEEE MMMM doo yyyy'}} +
      +
    • +
    • +
    + Associated Files + +
    +
    +
  • +

    No next steps matching filtered results.

    +
+
+
+
+
+ Target Completion + +
+
+

{{vm.completion_date | date:'shortDate'}}

+
+
+
+
+ Current Status + +
+
+ +
+
+
+
+ Team Members + +
+ +
+ +
+
Activity Log
+
    +
  • + +
  • +
+
+
+
+
diff --git a/d2ice.att.io/app/main/dashboard/overview/overview.less b/d2ice.att.io/app/main/dashboard/overview/overview.less new file mode 100755 index 00000000..48f76a47 --- /dev/null +++ b/d2ice.att.io/app/main/dashboard/overview/overview.less @@ -0,0 +1,575 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.dashboard { + + .remove-user-from-eng { + .x_16_r; + float: right; + cursor: pointer; + .remove-icon { + .sprite; + .sprite.red-delete; + display: inline-block; + margin-left: 8px; + position: relative; + top: 3px; + } + } + + .popover-title-name { + .a_18_m; + } + + .popover-title-company { + .a_18_r; + } + + .popover-role-title { + .n_16_i; + } + + .popover-details { + .popover-details-topic { + .m_16_m; + } + .popover-details-detail { + word-wrap: break-word; + + .m_16_r; + } + } + + .content-container #content .main-wrapper { + height: 100%; + overflow-y: auto; + overflow-x: hidden; + padding: 10px ; + } + + .no-display-text{ + .a_36_m; + } + + .no-display{ + display: none; + } + + .overview { + #engagement-title { + color: @toolbar_background_color; + } + .manual-id { + .m_36_m; + color: @toolbar_background_color; + } + + .filter-wrapper { + text-align: right; + padding:0px; + span { + padding: 0px; + margin-left: 5px; + + } + .form-control-main-view{ + margin-left: 5px; + display: inline; + padding: 6px; + font-size: 14px; + line-height: 1.42857143; + color: #555; + background-color: #fff; + background-image: none; + border: 1px solid #ccc; + border-radius: 4px; + box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075); + transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s; + } + } + + .state-filter { + button { + padding: 0px 5px 0px 8px; + margin-bottom: 1px; + } + + span { + right: 6px !important; + top: 9px !important; + } + + a { + font-size: 14px; + } + } + + .steps-progress-wrapper { + margin-top: 10px; + } + + h1 { + display: inline-block; + .a_36; + margin: 0 0 30px 0; + } + + h2 { + display: inline-block; + margin: 0 0 10px 0; + .a_24_m; + position: relative; + .add-people, + .add-step { + display: inline-block; + margin-left: 8px; + cursor: pointer; + position: relative; + top: 2px; + } + } + + .main-section { + margin-top: 30px; + } + + .steps-header { + background-color: @toolbar_background_color; + color: @main_color_p; + padding: 10px 0px 0px 0px; + margin: 0px 0px 0px -5px; + + h2 { + font-size: 20px; + color: @main_color_p; + } + + .steps-filter { + display: inline-block; + float: right; + .a_16_m; + .todo { + .sprite; + .sprite.todo; + display: inline-block; + cursor: pointer; + } + .completed { + .sprite; + .sprite.pending; + display: inline-block; + cursor: pointer; + } + .confirmed { + .sprite; + .sprite.approved; + display: inline-block; + cursor: pointer; + } + } + } + + #engagement-target-completion { + border: 1px solid @target_completion_color; + padding:0px; + margin-bottom: 20px; + + #target-completion-header { + background-color: @target_completion_color; + .p_18_m; + padding: 5px 5px 0; + line-height: 35px; + + .edit-target-completion { + font-size: 21px; + vertical-align: middle; + padding-left: 6px; + cursor:pointer; + } + } + + .target-completion-content { + .f-type._16_r; + margin: 15px; + } + } + + #engagement-status { + border: 1px solid @engagement_status_color; + padding:0px; + margin-bottom: 20px; + + #engagement-status-header { + background-color: @engagement_status_color; + .p_18_m; + padding: 5px 5px 0; + line-height: 35px; + + .add-engagement-status { + font-size: 21px; + vertical-align: middle; + padding-left: 6px; + cursor:pointer; + } + } + + .engagement-status-content { + .f-type._16_r; + margin: 15px; + + #status-update-details { + display:block; + .m_12_r; + } + + #status-description { + margin: 3px 0px 0px 0px; + .m_16_r; + } + + .edit-engagement-status { + font-size: 21px; + padding-left: 6px; + cursor:pointer; + color: @main_color_m; + } + } + } + + #engagement-team { + border: 1px solid @engagement_team_color; + padding:0px; + margin-bottom: 20px; + + #engagement-team-header { + background-color: @engagement_team_color; + .p_18_m; + padding: 5px 5px 0; + line-height: 35px; + + .add-team-member { + font-size: 21px; + vertical-align: middle; + padding-left: 6px; + cursor:pointer; + } + } + + .engagement-team-content { + .f-type._16_r; + margin: 15px; + + ul.team-avatars { + li.team-member-avatar { + font-size: 40px; + cursor:pointer; + color: @engagement_team_color; + } + + li { + list-style: none; + display: inline-block; + margin-right: 10px; + } + } + } + } + + #star-engagement-action { + display: inline-block; + cursor:pointer; + position: relative; + bottom: 3px; + margin-right: 5px; + } + + #star-engagement-action.not_starred{ + .sprite.starred; + } + + #star-engagement-action.is_starred { + .sprite.starred-selected; + } + + #star-engagement-action.not_starred:hover{ + .sprite.starred-selected; + } + + #star-engagement-action.is_starred:hover { + .sprite.starred; + } + + .steps { + padding-bottom: 140px; + padding-right: 20px; + padding-left: 20px; + + ul { + li.step { + border-bottom: dashed 1px @main_color_n; + .step-wrapper { + border-left: 2px solid transparent; + margin: 7px 0px 7px 1px; + &:hover { + border-left: 2px solid @main_color_a; + background-color: #DEF3FF; + + .description { + .step-state { + &.incomplete { + color: @main_color_d; + opacity: 0.7; + } + } + } + } + } + .next-step-actions { + display:none; + height: 100%; + width: 20px; + position: relative; + padding-top: 10px; + float: left; + left: -18px; + margin-right: -20px; + + > span { + margin-bottom: 3px; + cursor: pointer; + display:block; + } + .order-nextstep { + color: @main_color_o; + cursor:pointer; + } + .edit-next-step { + cursor:pointer; + color: @main_color_o; + } + .moveto-confirmed { + .actions-sprite; + .actions-sprite.approve_large; + + } + .moveto-todo { + .actions-sprite; + .actions-sprite.reject_large; + } + .moveto-delete { + cursor:pointer; + color: @main_color_o; + } + + } + &:hover { + .next-step-actions { + display:block; + } + .details { + .actions { + span { + visibility: visible; + } + } + } + } + + div.completed { + opacity: 0.7; + } + div.confirmed { + opacity: 0.7; + } + + .details { + text-align: right; + .next-step-due-date { + color: @main_color_m; + font-weight: bold; + + .icon { + display: inline-block; + margin-right: 5px; + position: relative; + } + } + + .associated-files { + color: @main_color_m; + font-weight: bold; + cursor: pointer; + } + + ul.next-step-team-mates { + li { + list-style: none; + display: inline-block; + font-size: 27px; + padding-left: 5px; + color: @engagement_team_color; + + &.me { + color: @main_color_a; + } + } + + } + + } + list-style: none; + position: relative; + + .description { + .m_16_r; + + padding:5px; + + input { + position: absolute; + top: 10px; + left: 0; + margin-right: 20px; + } + + .step-text { + margin-left: 35px; + } + .last-action-details { + .m_12_r; + .name { + font-weight: bold; + .m_12_m; + + } + } + .step-state { + position: absolute; + top: 25px; + font-size: 25px; + + &.incomplete { + color: @main_color_o; + display: inline-block; + } + &.completed { + color: @main_color_d; + display: inline-block; + } + } + } + } + } + } + + .team-and-logs { + border-left: dashed 1px @main_color_a; + padding-left: 20px; + padding-right: 20px; + + .activity-log { + + border: 1px solid @engagement_team_color; + padding:0px; + margin-bottom: 20px; + + #activity-log-header { + background-color: @engagement_team_color; + .p_18_m; + padding: 5px 5px 0; + line-height: 35px; + } + ul.activity-log-details { + margin:15px; + li { + list-style: none; + position: relative; + margin: 0 0 10px; + + } + } + } + + } + + .admin-actions-dropdown { + .sprite.admin-dropdown; + color: @main_color_a; + font-size: 20px; + vertical-align: 4px; + margin-left: 5px; + cursor: pointer; + display: inline-block; + } + } + + .add-next-step-form { + .ice-wysiwyg { + height: 200px; + .wysiwyg-menu > div { + background-color: #f1f1f1; + padding: 2px; + } + } + } + + .git-repo-url{ + text-align: left; + .m_16_m; + } + + .storage-bucket-url{ + text-align: left; + .m_16_m; + } + + .line-separator { + border-bottom: solid thin; + margin-top: 5px; + margin-bottom: 7px; + align-items: left; + } +} + +.intl-tel-input { + width: 100%; +} + +.iti-flag { + background-image: url(images/flags.png); +} diff --git a/d2ice.att.io/app/main/documentation/documentation.controller.js b/d2ice.att.io/app/main/documentation/documentation.controller.js new file mode 100755 index 00000000..6e3ebb27 --- /dev/null +++ b/d2ice.att.io/app/main/documentation/documentation.controller.js @@ -0,0 +1,74 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.documentation') + .controller('documentationController', ["cmsService", "$stateParams", "$log", documentationController]); + + function documentationController(cmsService, $stateParams, $log) { + var vm = this; + + var init = function() + { + loadPageData(); + }; + + function loadPageData() { + if($stateParams.page_id) { + cmsService.getPage($stateParams.page_id) + .then(function(response) { + if(response && response.data) { + vm.pageId = $stateParams.page_id; + vm.pageTitle = response.data["title"]; + vm.pageContent = response.data["content"]; + vm.publishDate = response.data["publish_date"]; + } + }) + .catch(function(error) { + $log.error(error); + }); + } + } + + init(); + } +})(); diff --git a/d2ice.att.io/app/main/documentation/documentation.html b/d2ice.att.io/app/main/documentation/documentation.html new file mode 100755 index 00000000..44b7c0d8 --- /dev/null +++ b/d2ice.att.io/app/main/documentation/documentation.html @@ -0,0 +1,47 @@ + + +
+
+

{{vm.pageTitle}}

+ Updated at {{vm.publishDate | date2: 'EEEE MMMM doo yyyy'}} +
+
+
+ diff --git a/d2ice.att.io/app/main/documentation/documentation.less b/d2ice.att.io/app/main/documentation/documentation.less new file mode 100755 index 00000000..7b7f188b --- /dev/null +++ b/d2ice.att.io/app/main/documentation/documentation.less @@ -0,0 +1,96 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.documentation-container { + .page-title { + .a_26_m; + margin:0px; + } + + .page-publish { + .f-type._14_m; + + bottom: 10px; + } + + .page-content{ + .f-type._16_r; + margin-top: 10px; + + ul { + padding-left: 30px; + } + + h1 { + font-weight: bold; + } + + h2 { + font-weight: bold; + } + + h3 { + font-weight: bold; + } + + table { + border-right: 1px solid @main_color_c; + border-left: 1px solid @main_color_c; + + tr { + border-bottom: 1px solid @main_color_c; + border-top: 1px solid @main_color_c; + border-collapse: collapse; + + td { + padding: 0 0 0 7px; + } + } + + thead { + background-color: @main_color_c; + color: @main_color_p; + font-weight: bold; + } + } + } +} + +#documentation-side-panel { + border-left: dashed 1px @main_color_a; +} diff --git a/d2ice.att.io/app/main/documentation/documentation.module.js b/d2ice.att.io/app/main/documentation/documentation.module.js new file mode 100755 index 00000000..fb944e0d --- /dev/null +++ b/d2ice.att.io/app/main/documentation/documentation.module.js @@ -0,0 +1,74 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.documentation') + .config(config); + + function config($stateProvider) { + $stateProvider + .state('app.documentation', { + views: { + 'navigation@app': { + templateUrl: 'core/navigation/layouts/documentation-navigation/navigation.html', + controller: 'documentationNavigationController as vm' + }, + 'sidebar@app': { + templateUrl: 'main/documentation/sidebar/documentation.sidebar.html' + } + }, + bodyClass: 'documentation', + params: {displaySidebar: true} + }) + .state('app.documentation.page', { + url: '/documentation', + views: { + 'content@app': { + templateUrl: 'main/documentation/documentation.html', + controller: 'documentationController as vm' + } + }, + bodyClass: 'documentation', + params: {displaySidebar: true, page_id: undefined} + }); + } +})(); diff --git a/d2ice.att.io/app/main/documentation/sidebar/documentation.sidebar.html b/d2ice.att.io/app/main/documentation/sidebar/documentation.sidebar.html new file mode 100755 index 00000000..c6381a7d --- /dev/null +++ b/d2ice.att.io/app/main/documentation/sidebar/documentation.sidebar.html @@ -0,0 +1,41 @@ + + diff --git a/d2ice.att.io/app/main/documentation/sidebar/documentation.sidebar.less b/d2ice.att.io/app/main/documentation/sidebar/documentation.sidebar.less new file mode 100755 index 00000000..51694fe9 --- /dev/null +++ b/d2ice.att.io/app/main/documentation/sidebar/documentation.sidebar.less @@ -0,0 +1,61 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +#documentation-side-panel { + .tooltip-title { + font-size: 18px; + } + + #tooltip-description { + font-size: 16px; + } + + #news-and-announcements-header { + font-size: 18px; + } + + #news-and-announcements-list { + .news-and-announcements-details { + .news-and-announcements-details-header { + .news-and-announcements-details-title { + font-size: 16px; + } + } + } + } +} diff --git a/d2ice.att.io/app/main/errors/404.html b/d2ice.att.io/app/main/errors/404.html new file mode 100755 index 00000000..62309745 --- /dev/null +++ b/d2ice.att.io/app/main/errors/404.html @@ -0,0 +1,190 @@ + + + + + + Page Not Found :( + + + +
+

Not found :(

+

Sorry, but the page you were trying to view does not exist.

+

It looks like this was the result of either:

+
    +
  • a mistyped address
  • +
  • an out-of-date link
  • +
+ + +
+ + diff --git a/d2ice.att.io/app/main/main.controller.js b/d2ice.att.io/app/main/main.controller.js new file mode 100755 index 00000000..9c91aae9 --- /dev/null +++ b/d2ice.att.io/app/main/main.controller.js @@ -0,0 +1,60 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + + angular + .module('ice.main',[]) + .controller('MainController', MainController)//; + .config(function($mdDateLocaleProvider) { + $mdDateLocaleProvider.formatDate = function (date) { + return date ? moment(date).format('MMMM Do YYYY') : ''; + }; + + $mdDateLocaleProvider.parseDate = function (dateString) { + var m = moment(dateString, 'YYYY-MM-DD', true); + return m.isValid() ? m.toDate() : new Date(NaN); + }; + }); + + function MainController($scope, $rootScope) { + + } + +})(); \ No newline at end of file diff --git a/d2ice.att.io/app/main/modals/archive-engagement-modal/archive-engagement-modal.controller.js b/d2ice.att.io/app/main/modals/archive-engagement-modal/archive-engagement-modal.controller.js new file mode 100755 index 00000000..3c1226cb --- /dev/null +++ b/d2ice.att.io/app/main/modals/archive-engagement-modal/archive-engagement-modal.controller.js @@ -0,0 +1,66 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. + +(function () { + 'use strict'; + + angular + .module('ice.modals') + .controller('archiveEngagementModalController', ['$uibModalInstance','engagementDetails',archiveEngagementModalController]); + + function archiveEngagementModalController($uibModalInstance, engagementDetails) { + + var vm = this; + var init = function () { + if(engagementDetails) { + vm.engagement = engagementDetails; + } + }; + + vm.closeModal = function () { + $uibModalInstance.dismiss(); + }; + + vm.archiveEngagement = function() { + $uibModalInstance.close(vm.reason); + }; + + init(); + } +})(); diff --git a/d2ice.att.io/app/main/modals/archive-engagement-modal/archive-engagement-modal.html b/d2ice.att.io/app/main/modals/archive-engagement-modal/archive-engagement-modal.html new file mode 100755 index 00000000..7d4b5b07 --- /dev/null +++ b/d2ice.att.io/app/main/modals/archive-engagement-modal/archive-engagement-modal.html @@ -0,0 +1,56 @@ + +
+ + +
diff --git a/d2ice.att.io/app/main/modals/archive-engagement-modal/archive-engagement-modal.less b/d2ice.att.io/app/main/modals/archive-engagement-modal/archive-engagement-modal.less new file mode 100755 index 00000000..da2f8503 --- /dev/null +++ b/d2ice.att.io/app/main/modals/archive-engagement-modal/archive-engagement-modal.less @@ -0,0 +1,54 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.archive-engagement-modal { + padding: 0px 15px 0px 15px; + + .archive-engagement-title { + .a_24_m;; + } + + .archive-engagement-reason { + .m_16_r; + } + + .modal-body { + top: 10px; + } +} + diff --git a/d2ice.att.io/app/main/modals/audit-log/audit-log.controller.js b/d2ice.att.io/app/main/modals/audit-log/audit-log.controller.js new file mode 100755 index 00000000..84e7fbc6 --- /dev/null +++ b/d2ice.att.io/app/main/modals/audit-log/audit-log.controller.js @@ -0,0 +1,95 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + + angular + .module('ice.modals') + .controller('AuditLogModalController', ['$rootScope', '$uibModalInstance', 'checklistService', 'wizardData', + 'toastService', '$log', AuditLogModalController]); + + function AuditLogModalController($rootScope, $uibModalInstance, checklistService, wizardData, toastService, $log) { + var vm = this; + + var init = function() + { + var arr = []; + var i; + var region = moment().tz( moment.tz.guess()).format('z'); + var dt = ""; + vm.name = wizardData.name; + vm.checklistAuditLogs = wizardData.checklistAuditLogs; + vm.checklistAuditLogs.forEach(function (cl) + { + dt = moment(cl.create_time).local().format('YYYY-MM-DD hh:mm:ss A') + " " + region; + arr.push({"name":cl.creator.full_name,"dt":dt,"desc":cl.description}); + }); + vm.checklistAuditLogs = arr; + } + + init(); + + vm.submitForm = function () + { + var jsonPost = {"description":vm.description}; + checklistService.createAuditlogChecklist(wizardData.uuid, jsonPost) + .then(function (response) { + if (response.status === 200) + { + $uibModalInstance.close(response.data); + vm.closeModal(); + } + else + { + toastService.setToast(response.error, 'danger', {displayFor: 'modal'}); + $rootScope.ice.loader.show = false; + } + }) + .catch(function (error) { + toastService.setToast(error.message, 'danger', {displayFor: 'modal'}); + $log.error(error.message); + }); + }; + + vm.closeModal = function(){ + toastService.clearToast(); + $uibModalInstance.close(); + }; + } +})(); diff --git a/d2ice.att.io/app/main/modals/audit-log/audit-log.html b/d2ice.att.io/app/main/modals/audit-log/audit-log.html new file mode 100755 index 00000000..a4ad06f7 --- /dev/null +++ b/d2ice.att.io/app/main/modals/audit-log/audit-log.html @@ -0,0 +1,76 @@ + + + + + + diff --git a/d2ice.att.io/app/main/modals/audit-log/audit-log.less b/d2ice.att.io/app/main/modals/audit-log/audit-log.less new file mode 100755 index 00000000..7ba728e6 --- /dev/null +++ b/d2ice.att.io/app/main/modals/audit-log/audit-log.less @@ -0,0 +1,49 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.auditlog { + + .audit-log-items { + border-bottom: 1px solid; + margin-bottom: 5px; + } + + .textarea-checklist-audit { + resize: none; + } +} diff --git a/d2ice.att.io/app/main/modals/change-date/change-date.controller.js b/d2ice.att.io/app/main/modals/change-date/change-date.controller.js new file mode 100755 index 00000000..35290c99 --- /dev/null +++ b/d2ice.att.io/app/main/modals/change-date/change-date.controller.js @@ -0,0 +1,75 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.modals') + .controller('ChangeDateModalController', ["$uibModalInstance", "completionDate", "engagementUuid", "vfService", "$rootScope", "toastService", changeDateModalController]); + + function changeDateModalController($uibModalInstance, completionDate, engagementUuid, vfService, $rootScope, toastService) { + + var vm = this; + //vm.completionDate = new Date(completionDate); + vm.completionDate = completionDate; + + vm.dateOptions = { + minDate: new Date(), + showWeeks: true + }; + + vm.closeModal = function(){ + $uibModalInstance.close(); + }; + + vm.submitForm = function(){ + var postData={"target_date": moment(vm.completionDate).format("YYYY-MM-DD")}; + vfService.updateDaysLeft(engagementUuid, postData) + .then(function (response) { + if (response.status === 200) { + $uibModalInstance.close(postData); + } + }) + .catch(function (error) { + toastService.setToast(error.status + ': Error changing completion date!', 'danger'); + }); + }; + } +})(); diff --git a/d2ice.att.io/app/main/modals/change-date/change-date.html b/d2ice.att.io/app/main/modals/change-date/change-date.html new file mode 100755 index 00000000..4d3e0b59 --- /dev/null +++ b/d2ice.att.io/app/main/modals/change-date/change-date.html @@ -0,0 +1,62 @@ + +
+ + + +
diff --git a/d2ice.att.io/app/main/modals/change-progress/change-progress.controller.js b/d2ice.att.io/app/main/modals/change-progress/change-progress.controller.js new file mode 100755 index 00000000..e28b2528 --- /dev/null +++ b/d2ice.att.io/app/main/modals/change-progress/change-progress.controller.js @@ -0,0 +1,71 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.modals',[]) + .controller('ChangeProgressModalController', ["$uibModalInstance", "progress", "engagementUuid", "vfService", + "$log", "toastService", ChangeProgressModalController]); + + function ChangeProgressModalController($uibModalInstance, progress, engagementUuid, vfService, $log, toastService) { + + var vm = this; + vm.progress = progress; + + vm.closeModal = function(){ + $uibModalInstance.close(); + }; + + vm.submitForm = function(){ + var postData={"progress": vm.progress}; + vfService.updateProgress(engagementUuid, postData) + .then(function (response) { + if (response.status === 202) { + $uibModalInstance.close(postData); + } + }) + .catch(function (error) { + $log.error(error); + toastService.setToast(error.status + ': Error changing progress!', 'danger'); + }); + }; + } +})(); diff --git a/d2ice.att.io/app/main/modals/change-progress/change-progress.html b/d2ice.att.io/app/main/modals/change-progress/change-progress.html new file mode 100755 index 00000000..adfb7e7a --- /dev/null +++ b/d2ice.att.io/app/main/modals/change-progress/change-progress.html @@ -0,0 +1,65 @@ + +
+ + + + +
diff --git a/d2ice.att.io/app/main/modals/checklist/checklist.controller.js b/d2ice.att.io/app/main/modals/checklist/checklist.controller.js new file mode 100755 index 00000000..4a20b53d --- /dev/null +++ b/d2ice.att.io/app/main/modals/checklist/checklist.controller.js @@ -0,0 +1,238 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + + angular + .module('ice.modals') + .controller('ChecklistModalController', ['toastService', '$rootScope', '$uibModalInstance', 'checklistService', + 'engagementUuid', 'modal_type', 'wizardData', '$log', ChecklistModalController]); + + function ChecklistModalController(toastService, $rootScope, $uibModalInstance, checklistService, engagementUuid, + modal_type, wizardData, $log) { + var vm = this; + vm.checkListAssociatedFiles = []; + vm.selectedCheckListAssociatedFiles = []; + vm.isDisabled = false; + + var init = function() { + switch(modal_type) { + case 'create': + vm.create = true; + vm.createUpadeTitle = "Create"; + vm.modalType = 'create'; + vm.modalTitle = "Create"; + checklistService.getDataForCreateChecklist(engagementUuid) + .then(function (response) { + if (response.status === 200) { + vm.checkListTemplatesLists = []; + vm.checkListTemplates = response.data.checkListTemplates; + angular.forEach(response.data.checkListAssociatedFiles, function (value, key) { + vm.checkListAssociatedFiles.push({File: value}); + }); + $rootScope.ice.loader.show = false; + } + }) + .catch(function (error) { + toastService.setToast(error.message, 'danger', {displayFor: 'modal'}); + $rootScope.ice.loader.show = false; + $log.error(error.message); + }); + break; + case 'update': + vm.update = true; + vm.createUpadeTitle = "Update"; + vm.modalType = 'udpate'; + vm.modalTitle = "Update"; + vm.checklistUuid = wizardData.uuid; + vm.checkListName = wizardData.name; + checklistService.getDataForCreateChecklist(engagementUuid) + .then(function (response) { + if (response.status === 200) { + vm.checkListAssociatedFiles = [] + angular.forEach(response.data.checkListAssociatedFiles, function (value, key) { + vm.checkListAssociatedFiles.push({File: value}); + }); + $rootScope.ice.loader.show = false; + + vm.selectedCheckListAssociatedFiles =[] + + angular.forEach(wizardData.associatedFiles, function(val, key1) { + vm.selectedCheckListAssociatedFiles.push({File: val}); + }); + + } + }) + .catch(function (error) { + toastService.setToast(error.message, 'danger', {displayFor: 'modal'}); + $rootScope.ice.loader.show = false; + $log.error(error.message); + }); + vm.selectedTemplateUuid = wizardData.selectedTemplateUuid; + vm.selectedTemplateName = wizardData.selectedTemplateName; + + break; + } + } + init(); + + vm.addFile = function () + { + var newItemNo = vm.selectedCheckListAssociatedFiles.length + 1; + vm.selectedCheckListAssociatedFiles.push({'id': newItemNo}); + }; + + vm.removeFile = function (index) + { + vm.selectedCheckListAssociatedFiles.splice(index,1); + }; + + vm.closeModal = function(){ + toastService.clearToast(); + $rootScope.$emit('onChecklistUpdate'); + $uibModalInstance.close(vm.checkListName); + $uibModalInstance.close(); + }; + + + vm.submitForm = function () + { + vm.isDisabled = true; + var checklist_files = []; + switch(modal_type){ + case 'create': + angular.forEach(vm.selectedCheckListAssociatedFiles, function(val, key1) { + checklist_files.push(val.File); + }); + var jsonPost = { + "checkListAssociatedFiles": checklist_files, + "checkListName": vm.checkListName, + "checkListTemplateUuid" : vm.selectedTemplateUuid + }; + + checklistService.createChecklist(engagementUuid, jsonPost) + .then(function (response) { + if (response.status === 200) { + $uibModalInstance.close(response.data); + $rootScope.ice.loader.show = false; + vm.closeModal(); + } + }) + .catch(function (error) { + toastService.setToast(error.message || 'Error creating check list.', 'danger', {displayFor: 'modal'}); + $rootScope.ice.loader.show = false; + vm.isDisabled = false; + $log.error(error.message); + }); + break; + case 'update': + + var updated_file_list = []; + angular.forEach(vm.selectedCheckListAssociatedFiles, function(val, key1) { + updated_file_list.push(val.File); + }); + $log.debug("update", updated_file_list); + var jsonPut = { + "checklistUuid": vm.checklistUuid, + "checkListAssociatedFiles": updated_file_list, + "checkListName": vm.checkListName, + "checkListTemplateUuid" : vm.selectedTemplateUuid + }; + checklistService.putDataForChecklist(vm.checklistUuid, jsonPut) + .then(function (response) { + if (response.status === 200) { + $rootScope.$broadcast('onUpdateEngagements',{select:{uuid: engagementUuid, view_type : 'checklist', sub_id: vm.checklistUuid}}); + $rootScope.ice.loader.show = false; + + var response_data = {}; + response_data.checklist_name = vm.checkListName; + response_data.associated_files = updated_file_list; + var array1 = vm.checkListAssociatedFiles.sort(); + var array2 = updated_file_list.sort(); + + var is_same_files = (array1.length == array2.length) && array1.every(function(element, index) { + return element === array2[index]; + }); + // if file list changed reject checklist + if (!is_same_files && wizardData.state != 'pending') + { + var postData = {}; + postData["description"] = "Rejected due to file list change"; + postData["decline"] = "True"; + + checklistService.setState(vm.checklistUuid, postData) + .then(function (response) { + if (response.status === 200) { + $rootScope.$broadcast('onUpdateEngagements'); + } + else { + toastService.setToast(response.error, 'danger', {displayFor: 'modal'}); + $rootScope.ice.loader.show = false; + vm.isDisabled = false; + return; + } + }) + .catch(function (error) { + $log.error(error); + toastService.setToast(error.status + ': Error changing progress!', 'danger'); + vm.isDisabled = false; + return; + }); + } + + $uibModalInstance.close(response_data); + vm.closeModal(); + } + }) + .catch(function (error) { + toastService.setToast(error.message, 'danger', {displayFor: 'modal'}); + $rootScope.ice.loader.show = false; + $log.error(error.message); + vm.isDisabled = false; + + }); + break; + default: + $log.debug('no submit action found'); + vm.isDisabled = false; + break; + } + } + } +})(); diff --git a/d2ice.att.io/app/main/modals/checklist/checklist.html b/d2ice.att.io/app/main/modals/checklist/checklist.html new file mode 100755 index 00000000..d308c9d2 --- /dev/null +++ b/d2ice.att.io/app/main/modals/checklist/checklist.html @@ -0,0 +1,107 @@ + + + + + + + diff --git a/d2ice.att.io/app/main/modals/checklist/state-approve-or-reject/state-approve-or-reject.controller.js b/d2ice.att.io/app/main/modals/checklist/state-approve-or-reject/state-approve-or-reject.controller.js new file mode 100755 index 00000000..160b57cc --- /dev/null +++ b/d2ice.att.io/app/main/modals/checklist/state-approve-or-reject/state-approve-or-reject.controller.js @@ -0,0 +1,105 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. + +(function () { + 'use strict'; + + angular + .module('ice.modals') + .controller('stateDecisionModalController', ['$rootScope','$uibModalInstance', 'checklistService', + 'toastService', 'action', 'checklist', '$log', stateDecisionModalController]); + + function stateDecisionModalController($rootScope, $uibModalInstance, checklistService, toastService, action, + checklist, $log) { + + var vm = this; + + var init = function () { + vm.description = null; + vm.checklist_name = checklist.name; + vm.state = checklist.state; + vm.action = action; + vm.modalText = (vm.state == 'pending') ? "Are you sure you want to move the checklist state to Automation?": + "Please use the button below to either approve or reject the " + + "checklist.
You can also add a log entry comment."; + }; + + vm.submitForm = function(decision) { + var postData = {}; + if (vm.description != null) { + postData["description"] = vm.description; + } + else{ + postData["description"] = ''; + } + + if (decision === true) { + postData["decline"] = "False"; + } + else { + postData["decline"] = "True"; + } + + + + checklistService.setState(checklist.uuid, postData) + .then(function (response) { + if (response.status === 200) { + $uibModalInstance.close(response.data); + vm.closeModal(); + } + else { + toastService.setToast(response.error, 'danger'); + $rootScope.ice.loader.show = false; + } + }) + .catch(function (error) { + $log.error(error); + toastService.setToast(error.status + ': Error changing progress!', 'danger'); + }); + + }; + + vm.closeModal = function () { + $uibModalInstance.close(); + }; + + init(); + } +})(); diff --git a/d2ice.att.io/app/main/modals/checklist/state-approve-or-reject/state-approve-or-reject.html b/d2ice.att.io/app/main/modals/checklist/state-approve-or-reject/state-approve-or-reject.html new file mode 100755 index 00000000..4db81b1f --- /dev/null +++ b/d2ice.att.io/app/main/modals/checklist/state-approve-or-reject/state-approve-or-reject.html @@ -0,0 +1,58 @@ + + +
+ +
+ +
+ +
+
+ Inserted text should not include any special chars such as: \%_*." +
+ +
diff --git a/d2ice.att.io/app/main/modals/checklist/state-approve-or-reject/state-approve-or-reject.less b/d2ice.att.io/app/main/modals/checklist/state-approve-or-reject/state-approve-or-reject.less new file mode 100755 index 00000000..08bf14e9 --- /dev/null +++ b/d2ice.att.io/app/main/modals/checklist/state-approve-or-reject/state-approve-or-reject.less @@ -0,0 +1,173 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.modal-open .modal { + z-index: 30000 !important; +} + +#approve-or-reject-state { + + .modal-title { + .a_22_m; + } + + .decision-modal-body { + margin-bottom: 8px; + margin-top: 10px; + } + + .decision-comment { + .m_14_r;; + } + + .modal_buttons { + .custom-button { + position: relative; + width: 30%; + float: left; + display: inline-block; + } + .custom-space { + position: relative; + width: 5%; + float: left; + min-height: 1px; + } + } + + .state-title .bold { + .m_18_m; + } + .state-title { + .m_18_r; + } + .state-title-border { + border-bottom: dashed 1px; + border-color: @main_color_q; + margin-left: 0px; + } + + .comment-textarea { + resize: vertical; + } + + .btn-gradient-success { + font-weight: bold; + color: #FFFFFF; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #41A02C; + *background-color: #41A02C; + background-image: -moz-linear-gradient(top, #A2E652, #41A02C); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#A2E652), to(#41A02C)); + background-image: -webkit-linear-gradient(top, #A2E652, #41A02C); + background-image: -o-linear-gradient(top, #A2E652, #41A02C); + background-image: linear-gradient(to bottom, #A2E652, #41A02C); + background-repeat: repeat-x; + border-color: #41A02C; + border-color: #888; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#A2E652', endColorstr='#41A02C', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); + } + .btn-sample:hover, + .btn-sample:focus, + .btn-sample:active, + .btn-sample.active, + .btn-sample.disabled, + .btn-sample[disabled] { + color: #FFFFFF; + background-color: #41A02C; + *background-color: #003bb3; + } + + .btn-gradient-danger { + font-weight: bold; + color: #FFFFFF; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #AE0020; + *background-color: #AE0020; + background-image: -moz-linear-gradient(top, #F74658, #AE0020); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#F74658), to(#AE0020)); + background-image: -webkit-linear-gradient(top, #F74658, #AE0020); + background-image: -o-linear-gradient(top, #F74658, #AE0020); + background-image: linear-gradient(to bottom, #F74658, #AE0020); + background-repeat: repeat-x; + border-color: #AE0020; + border-color: #888; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#F74658', endColorstr='#AE0020', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); + } + .btn-sample:hover, + .btn-sample:focus, + .btn-sample:active, + .btn-sample.active, + .btn-sample.disabled, + .btn-sample[disabled] { + color: #FFFFFF; + background-color: #AE0020; + *background-color: #003bb3; + } + + .btn-gradient-default { + font-weight: bold; + color: #B3B3B3; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #D0D0D0; + *background-color: #D0D0D0; + background-image: -moz-linear-gradient(top, #FCFCFC, #D0D0D0); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#FCFCFC), to(#D0D0D0)); + background-image: -webkit-linear-gradient(top, #FCFCFC, #D0D0D0); + background-image: -o-linear-gradient(top, #FCFCFC, #D0D0D0); + background-image: linear-gradient(to bottom, #FCFCFC, #D0D0D0); + background-repeat: repeat-x; + border-color: #D0D0D0; + border-color: #888; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#FCFCFC', endColorstr='#D0D0D0', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); + } + .btn-sample:hover, + .btn-sample:focus, + .btn-sample:active, + .btn-sample.active, + .btn-sample.disabled, + .btn-sample[disabled] { + color: #FFFFFF; + background-color: #D0D0D0; + *background-color: #003bb3; + } + +} diff --git a/d2ice.att.io/app/main/modals/cms-post-modal/cms-post-modal.controller.js b/d2ice.att.io/app/main/modals/cms-post-modal/cms-post-modal.controller.js new file mode 100755 index 00000000..09773283 --- /dev/null +++ b/d2ice.att.io/app/main/modals/cms-post-modal/cms-post-modal.controller.js @@ -0,0 +1,92 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + + angular + .module('ice.modals') + .controller('cmsPostModalController', ['$uibModalInstance', 'cmsService','post', '$log', cmsPostModalController]); + + function cmsPostModalController($uibModalInstance, cmsService, post, $log) { + + var vm = this; + var init = function () { + if(post) { + vm.post = post; + } else { + cmsService.getLastAnnouncementPost() + .then(function(response) { + if(response && response.data && response.data.length === 1) { + vm.post = response.data[0]; + } + }) + .catch(function(error) { + $log.error(error); + }); + } + + loadRecentPosts(); + }; + + vm.closeModal = function (bool) { + $uibModalInstance.close(bool); + }; + + vm.loadSelectedPostData = function(post) { + if(post) { + vm.post = post; + } + }; + + function loadRecentPosts() { + var limit = 5; + var fromLastDays = ""; + + cmsService.getPosts(limit, fromLastDays, ['Announcement', 'News']) + .then(function(response) { + vm.recentPosts = response.data; + }) + .catch(function(error) { + $log.error(error); + }); + } + + init(); + } +})(); diff --git a/d2ice.att.io/app/main/modals/cms-post-modal/cms-post-modal.html b/d2ice.att.io/app/main/modals/cms-post-modal/cms-post-modal.html new file mode 100755 index 00000000..cd51c5e3 --- /dev/null +++ b/d2ice.att.io/app/main/modals/cms-post-modal/cms-post-modal.html @@ -0,0 +1,55 @@ + +
+ + +
+
+ Most recent news & announcements +
    +
  • + {{post.title}}Posted at {{post.publish_date | date2: 'EEEE MMMM doo yyyy'}} by {{post.user.username}} +
  • +
+
+
diff --git a/d2ice.att.io/app/main/modals/cms-post-modal/cms-post-modal.less b/d2ice.att.io/app/main/modals/cms-post-modal/cms-post-modal.less new file mode 100755 index 00000000..832ef012 --- /dev/null +++ b/d2ice.att.io/app/main/modals/cms-post-modal/cms-post-modal.less @@ -0,0 +1,106 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.toast-read-more-container { + padding: 0 20px; + word-wrap: break-word; + + .recent-cms-posts-container { + .line-separator { + border-bottom: solid 1px @main_color_m; + margin: 20px 0; + } + + .recent-cms-posts-title { + .a_16_m; + + } + + ul.recent-cms-posts { + margin-top: 3px; + + li { + .f-type._16_m; + list-style: none; + position: relative; + line-height: 28px; + cursor: pointer; + + .post-creation { + .f-type._12_r; + } + + &:before { + content: ''; + display: inline-block; + position: absolute; + top: 0; + } + } + + li.selected { + background-color: @func_color_r; + } + } + } +} + +.toast-read-more-title { + .a_26_m; + line-height: 26px; +} + +.toast-read-more-creation { + display: block; +} + +.toast-read-more-content { + .m_18_r; + line-height: 20px; + padding: 10px 20px 0; +} + +.modal-cms-post-read-more { + width: 70%; + margin: 0px auto; + height: 100%; + + .modal-content { + height: 100%; + } +} diff --git a/d2ice.att.io/app/main/modals/detailed-view/dtsite/detailed-view-dtsites-modal.controller.js b/d2ice.att.io/app/main/modals/detailed-view/dtsite/detailed-view-dtsites-modal.controller.js new file mode 100755 index 00000000..e14a9f88 --- /dev/null +++ b/d2ice.att.io/app/main/modals/detailed-view/dtsite/detailed-view-dtsites-modal.controller.js @@ -0,0 +1,100 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + + angular + .module('ice.modals') + .controller('detailedViewDtsitesModalController', ["$rootScope", "$uibModalInstance", "$stateParams", + "dtsiteService", "toastService", "vf_uuid", "$log", detailedViewDtsitesModalController]); + + function detailedViewDtsitesModalController($rootScope, $uibModalInstance, $stateParams, dtsiteService, toastService, + vf_uuid, $log) { + + var vm = this; + + var init = function () { + if($stateParams.engagement != undefined) { + vm.vf = $stateParams.engagement.vf; + } + getDTsites(); + + }; + + vm.closeModal = function(){ + $uibModalInstance.close(); + }; + + vm.json = ''; + + vm.submitForm = function(){ + var postData={ + "name": vm.json, + "vf_uuid": vf_uuid + }; + + dtsiteService.add(postData) + .then(function (response) { + $uibModalInstance.close(response.status); + }) + .catch(function (error) { + $log.error(error); + toastService.setToast(error.status + ': Error changing progress!', 'danger'); + }); + }; + + var getDTsites = function() { + $rootScope.ice.loader.show = true; + dtsiteService.get() + .then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 200) { + vm.dtsites = response.data; + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + }; + + init(); + } + +})(); diff --git a/d2ice.att.io/app/main/modals/detailed-view/dtsite/detailed-view-dtsites-modal.html b/d2ice.att.io/app/main/modals/detailed-view/dtsite/detailed-view-dtsites-modal.html new file mode 100755 index 00000000..901cd624 --- /dev/null +++ b/d2ice.att.io/app/main/modals/detailed-view/dtsite/detailed-view-dtsites-modal.html @@ -0,0 +1,62 @@ + +
+ + + + + +
diff --git a/d2ice.att.io/app/main/modals/detailed-view/vfc/detailed-view-vfc-modal.controller.js b/d2ice.att.io/app/main/modals/detailed-view/vfc/detailed-view-vfc-modal.controller.js new file mode 100755 index 00000000..983d8d99 --- /dev/null +++ b/d2ice.att.io/app/main/modals/detailed-view/vfc/detailed-view-vfc-modal.controller.js @@ -0,0 +1,124 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + + 'use strict'; + + angular + .module('ice.modals') + .controller('detailedViewVFCModalController', ["$rootScope", "$uibModalInstance", "vfcService", "toastService", + "vf_uuid", "usersService", "$log", detailedViewVFCModalController]); + + function detailedViewVFCModalController($rootScope, $uibModalInstance, vfcService, toastService, vf_uuid, usersService, $log) { + + var vm = this; + + var init = function () { + vm.me = usersService.getUserData(); + + getVendors() + }; + + vm.vfcs = [{name:'',external_ref_id:'',company:''}]; + vm.companies = []; + + vm.closeModal = function(){ + $uibModalInstance.close(); + }; + + vm.addNewChoice = function () { + var newItemNo = vm.vfcs.length + 1; + vm.vfcs.push({'id': newItemNo}); + }; + + vm.removeChoice = function (index) { + vm.vfcs.splice(index,1); + }; + + vm.submitForm = function(){ + var jsonAddVfc = []; + angular.forEach(vm.vfcs, function (value, key) { + vm.item = []; + var jsonItem = new Object(); + jsonItem.name = value.name; + jsonItem.external_ref_id = value.external_ref_id; + jsonItem.company = value.company; + jsonAddVfc.push(jsonItem); + }); + + var postData={ + "vfcs": jsonAddVfc, + "vf_uuid": vf_uuid, + "creator": vm.me, + }; + + vfcService.add(postData) + .then(function (response) { + if (response.status === 200) { + $uibModalInstance.close(response.status); + } + }) + .catch(function (error) { + $log.error(error); + toastService.setToast(error.status + ': Error changing progress!', 'danger'); + }); + }; + + var getVendors = function() { + $rootScope.ice.loader.show = true; + vfcService.getCompanies() + .then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 200) { + vm.companies = response.data; + if(vm.companies.length === 0 ){ + console.warn("No vendors pulled, request was successfull") + } + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + }; + + init(); + } +})(); diff --git a/d2ice.att.io/app/main/modals/detailed-view/vfc/detailed-view-vfc-modal.html b/d2ice.att.io/app/main/modals/detailed-view/vfc/detailed-view-vfc-modal.html new file mode 100755 index 00000000..7ac2097f --- /dev/null +++ b/d2ice.att.io/app/main/modals/detailed-view/vfc/detailed-view-vfc-modal.html @@ -0,0 +1,100 @@ + + + + + diff --git a/d2ice.att.io/app/main/modals/detailed-view/vfc/detailed-view-vfc-modal.less b/d2ice.att.io/app/main/modals/detailed-view/vfc/detailed-view-vfc-modal.less new file mode 100755 index 00000000..5ce9098d --- /dev/null +++ b/d2ice.att.io/app/main/modals/detailed-view/vfc/detailed-view-vfc-modal.less @@ -0,0 +1,68 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.vfc-remove-button { + width: 20px; + height: 40px; + float: right; + .a_16_m; + cursor: pointer; + margin: 14px 0 0 0; + + .remove-icon { + .sprite; + .sprite.delete-circle; + cursor: pointer; + display: block; + } +} + +.modal-add-vfc { + margin-top: 8px; + display: block; + .add-text { + .a_16_m; + vertical-align: top; + margin-left: 6px; + } + .add-icon { + .sprite; + .sprite.add; + display: inline-block; + } +} diff --git a/d2ice.att.io/app/main/modals/feedback/feedback.controller.js b/d2ice.att.io/app/main/modals/feedback/feedback.controller.js new file mode 100755 index 00000000..acee617b --- /dev/null +++ b/d2ice.att.io/app/main/modals/feedback/feedback.controller.js @@ -0,0 +1,82 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + + angular + .module('ice.modals') + .controller('FeedbackModalController', ['$rootScope','$uibModalInstance', 'feedbackService', + 'action', 'toastService', '$log', FeedbackModalController]); + + function FeedbackModalController($rootScope, $uibModalInstance, feedbackService, action, toastService, $log) { + var vm = this; + + var init = function() { + vm.action = action; + vm.feedback_modal_description = ''; + }; + + init(); + + vm.submitForm = function () + { + var feedbackPostData = {"description":vm.feedback_modal_description}; + if (action == 'add') { + feedbackService.add(feedbackPostData) + .then(function (response) { + if (response.status === 200) { + $uibModalInstance.close(response.data); + toastService.setToast('Feedback was sent successfully.', 'success'); + } else { + toastService.setToast(response.error, 'danger'); + $rootScope.ice.loader.show = false; + } + }) + .catch(function (error) { + toastService.setToast(error.message, 'danger'); + $log.error(error.message); + }); + } + }; + + vm.closeModal = function(){ + $uibModalInstance.close(); + }; + } +})(); diff --git a/d2ice.att.io/app/main/modals/feedback/feedback.html b/d2ice.att.io/app/main/modals/feedback/feedback.html new file mode 100755 index 00000000..88912c84 --- /dev/null +++ b/d2ice.att.io/app/main/modals/feedback/feedback.html @@ -0,0 +1,57 @@ + + + + + diff --git a/d2ice.att.io/app/main/modals/feedback/feedback.less b/d2ice.att.io/app/main/modals/feedback/feedback.less new file mode 100755 index 00000000..5d7fd8b3 --- /dev/null +++ b/d2ice.att.io/app/main/modals/feedback/feedback.less @@ -0,0 +1,44 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.feedback-modal-body { + .feedback-modal-description { + border-color: @main_color_q; + margin-bottom:15px; + } +} diff --git a/d2ice.att.io/app/main/modals/general-log-modal/general-log-modal.controller.js b/d2ice.att.io/app/main/modals/general-log-modal/general-log-modal.controller.js new file mode 100755 index 00000000..98fb2c14 --- /dev/null +++ b/d2ice.att.io/app/main/modals/general-log-modal/general-log-modal.controller.js @@ -0,0 +1,63 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + + angular + .module('ice.modals') + .controller('GeneralLogModalController', ['$uibModalInstance', 'modalDetails', GeneralLogModalController]); + + function GeneralLogModalController($uibModalInstance, modalDetails) { + + var vm = this; + + var init = function() { + if(modalDetails) { + vm.headline = modalDetails.headline || 'General log modal'; + vm.body = modalDetails.body || 'There is no body'; + } + }; + + init(); + + vm.closeModal = function(){ + $uibModalInstance.close(); + }; + } +})(); diff --git a/d2ice.att.io/app/main/modals/general-log-modal/general-log-modal.html b/d2ice.att.io/app/main/modals/general-log-modal/general-log-modal.html new file mode 100755 index 00000000..f87a8ac7 --- /dev/null +++ b/d2ice.att.io/app/main/modals/general-log-modal/general-log-modal.html @@ -0,0 +1,45 @@ + +
+ + +
diff --git a/d2ice.att.io/app/main/modals/general-log-modal/general-log-modal.less b/d2ice.att.io/app/main/modals/general-log-modal/general-log-modal.less new file mode 100755 index 00000000..e48ed525 --- /dev/null +++ b/d2ice.att.io/app/main/modals/general-log-modal/general-log-modal.less @@ -0,0 +1,72 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. + + +.general-log-containter { + height: inherit; + padding: 0 20px 30px; + word-wrap: break-word; + + .general-log-subtitle { + padding-bottom: 10px; + } + + .general-log-body { + height: inherit; + overflow:scroll; + padding: 0px 20px 0; + .m_18_r; + line-height: 20px; + } +} + +.general-log-modal-title { + .a_26_m; + line-height: 26px; +} + +.modal-general-log-modal { + width: 70%; + margin: 0px auto; + height: 100%; + + .modal-content { + height: 100%; + } +} diff --git a/d2ice.att.io/app/main/modals/general-prompt-modal/general-prompt-modal.controller.js b/d2ice.att.io/app/main/modals/general-prompt-modal/general-prompt-modal.controller.js new file mode 100755 index 00000000..f887a5ee --- /dev/null +++ b/d2ice.att.io/app/main/modals/general-prompt-modal/general-prompt-modal.controller.js @@ -0,0 +1,74 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. + +(function () { + 'use strict'; + + angular + .module('ice.modals') + .controller('generalPromptModalController', ['$uibModalInstance','modalDetails',generalPromptModalController]); + + function generalPromptModalController($uibModalInstance, modalDetails) { + + var vm = this; + var init = function () { + if(modalDetails) { + vm.upper_headline = modalDetails.upper_headline; + vm.upper_headline_value = modalDetails.upper_headline_value; + vm.headline = modalDetails.headline || 'D2ICE'; + vm.message = modalDetails.message || 'Are you sure?'; + vm.closeCallback = modalDetails.closeCallback; + vm.approveText = modalDetails.approve || 'Approve'; + vm.cancelText = modalDetails.cancel || 'Cancel'; + vm.is_close_modal_button = modalDetails.is_close_modal_button; + vm.is_message = modalDetails.is_message; + } + }; + + vm.closeModal = function (bool) { + if(vm.closeCallback) { + vm.closeCallback(bool); + } + + $uibModalInstance.close(bool); + }; + + init(); + } +})(); diff --git a/d2ice.att.io/app/main/modals/general-prompt-modal/general-prompt-modal.html b/d2ice.att.io/app/main/modals/general-prompt-modal/general-prompt-modal.html new file mode 100755 index 00000000..3bd31887 --- /dev/null +++ b/d2ice.att.io/app/main/modals/general-prompt-modal/general-prompt-modal.html @@ -0,0 +1,52 @@ + + + diff --git a/d2ice.att.io/app/main/modals/general-prompt-modal/general-prompt-modal.less b/d2ice.att.io/app/main/modals/general-prompt-modal/general-prompt-modal.less new file mode 100755 index 00000000..d367cdaa --- /dev/null +++ b/d2ice.att.io/app/main/modals/general-prompt-modal/general-prompt-modal.less @@ -0,0 +1,151 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.general-prompt-text-details { + .l_14_r; + padding: 3% 0% 3% 0%; +} + +.general-prompt-upper-headline { + .l_14_m; +} +.general-prompt-upper-dash { + border-bottom: dashed 1px #5a5a5a; + margin-bottom: 15px; +} +.upper-headline-value{ + .l_14_i; +} + +.general-prompt-body{ + margin: 0px; +} + +.general-prompt-title { + .m_18_r; + + .bold { + .a_18_m; + } + +} + + +.btn-gradient-success { + font-weight: bold; + color: #FFFFFF; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #41A02C; + *background-color: #41A02C; + background-image: -moz-linear-gradient(top, #A2E652, #41A02C); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#A2E652), to(#41A02C)); + background-image: -webkit-linear-gradient(top, #A2E652, #41A02C); + background-image: -o-linear-gradient(top, #A2E652, #41A02C); + background-image: linear-gradient(to bottom, #A2E652, #41A02C); + background-repeat: repeat-x; + border-color: #41A02C; + border-color: #888; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#A2E652', endColorstr='#41A02C', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); +} +.btn-sample:hover, +.btn-sample:focus, +.btn-sample:active, +.btn-sample.active, +.btn-sample.disabled, +.btn-sample[disabled] { + color: #FFFFFF; + background-color: #41A02C; + *background-color: #003bb3; +} + +.btn-gradient-danger { + font-weight: bold; + color: #FFFFFF; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #AE0020; + *background-color: #AE0020; + background-image: -moz-linear-gradient(top, #F74658, #AE0020); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#F74658), to(#AE0020)); + background-image: -webkit-linear-gradient(top, #F74658, #AE0020); + background-image: -o-linear-gradient(top, #F74658, #AE0020); + background-image: linear-gradient(to bottom, #F74658, #AE0020); + background-repeat: repeat-x; + border-color: #AE0020; + border-color: #888; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#F74658', endColorstr='#AE0020', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); +} +.btn-sample:hover, +.btn-sample:focus, +.btn-sample:active, +.btn-sample.active, +.btn-sample.disabled, +.btn-sample[disabled] { + color: #FFFFFF; + background-color: #AE0020; + *background-color: #003bb3; +} + +.btn-gradient-default { + font-weight: bold; + color: #B3B3B3; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #D0D0D0; + *background-color: #D0D0D0; + background-image: -moz-linear-gradient(top, #FCFCFC, #D0D0D0); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#FCFCFC), to(#D0D0D0)); + background-image: -webkit-linear-gradient(top, #FCFCFC, #D0D0D0); + background-image: -o-linear-gradient(top, #FCFCFC, #D0D0D0); + background-image: linear-gradient(to bottom, #FCFCFC, #D0D0D0); + background-repeat: repeat-x; + border-color: #D0D0D0; + border-color: #888; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#FCFCFC', endColorstr='#D0D0D0', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); +} +.btn-sample:hover, +.btn-sample:focus, +.btn-sample:active, +.btn-sample.active, +.btn-sample.disabled, +.btn-sample[disabled] { + color: #FFFFFF; + background-color: #D0D0D0; + *background-color: #003bb3; +} diff --git a/d2ice.att.io/app/main/modals/next-steps/next-steps.controller.js b/d2ice.att.io/app/main/modals/next-steps/next-steps.controller.js new file mode 100755 index 00000000..b90921ff --- /dev/null +++ b/d2ice.att.io/app/main/modals/next-steps/next-steps.controller.js @@ -0,0 +1,278 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + + angular + .module('ice.modals') + .controller('NextStepsModalController', ['$rootScope', '$uibModalInstance', 'stepsService', 'engagement_team', + 'title', 'associated_files', 'engagement_uuid', 'checklist', 'nextstep', 'toastService', '$log', NextStepsModalController]); + + function NextStepsModalController($rootScope, $uibModalInstance, stepsService, engagement_team, title, + associated_files, engagement_uuid, checklist, nextstep, toastService, $log) { + + var vm = this; + vm.nextSteps = [{assigneesUuids: '',description: '', files: '', duedate: ''}]; + + var init = function() { + + vm.myDate = new Date(); + vm.minDate = new Date( + vm.myDate.getFullYear(), + vm.myDate.getMonth(), + vm.myDate.getDate()); + vm.maxDate = new Date( + vm.myDate.getFullYear() + 2, + vm.myDate.getMonth(), + vm.myDate.getDate()); + vm.onlyWeekendsPredicate = function (date) { + var day = date.getDay(); + return day === 0 || day === 6; + }; + + vm.wysiwyg_menu = [ + ['bold', 'italic', 'strikethrough', 'underline'], + ['unordered-list', 'ordered-list', 'outdent', 'indent'] + ]; + vm.select_str = {File: 'Select All'}; + vm.select_all_flag = false; + vm.associated_files = []; + vm.associated_files.push( vm.select_str); + vm.assigness = []; + vm.title = title; + if (checklist == undefined) + { + vm.checklist = {}; + vm.checklist.uuid = undefined; + } else { + vm.checklist = checklist; + } + + var unique_files = []; + angular.forEach(associated_files, function (value, key) { + if (unique_files.indexOf(value) == -1) { + unique_files.push(value); + vm.associated_files.push({File: value}); + } + }); + angular.forEach(engagement_team, function (value, key) { + vm.assigness.push({name: value.full_name, id: value.uuid}); + }); + vm.edit = false; + + if (nextstep != undefined) + { + vm.edit = true; + var current = {}; + current.description = nextstep.description; + current.files = []; + current.duedate = new Date(nextstep.due_date); + var unique_files = []; + angular.forEach(nextstep.files, function(val, key1) { + if (unique_files.indexOf(value) == -1) { + unique_files.push(value); + current.files.push({File: val}); + } + }); + + current.assigneesUuids = []; + angular.forEach(nextstep.assignees, function(val, key1) { + current.assigneesUuids.push({name : val.full_name, id :val.uuid}); + + }); + vm.nextSteps = [current]; + } + }; + + init(); + + vm.get_chosen_files_num = function(ns){ + if (ns.files.length == associated_files.length+1) { + return ns.files.length - 1; + } + return ns.files.length + } + + vm.add_all_associated_files = function (ns , choose_option){ + if (choose_option == true) { + ns.files = []; + ns.files.push({File: 'Select All'}); + _.forEach(associated_files, function (value, key) { + ns.files.push({File: value}); + }); + } + else { + vm.select_all_flag = false; + ns.files = []; + } + return; + } + + vm.pull_select_all_from_list = function(ns){ + var shortened_files_list = []; + _.forEach(ns.files, function(item) { + if (!_.isEqual(item, vm.select_str)) { + shortened_files_list.push(item); + } + }); + ns.files = shortened_files_list; + } + + vm.verify_files_choice = function(ns){ + _.forEach(ns.files, function(item) { + if (ns.files.length == associated_files.length && vm.select_all_flag) { + if (item === vm.select_str) { + vm.select_all_flag = false; + vm.pull_select_all_from_list(ns); + } + else { + vm.add_all_associated_files(ns, false) + } + } + else if (ns.files.length == associated_files.length && !vm.select_all_flag) { + ns.files.push({File: 'Select All'}); + vm.select_all_flag = true; + } + else if (item === vm.select_str) { + vm.select_all_flag = true; + vm.add_all_associated_files(ns, true) + } + }) + } + + vm.addNewStep = function () { + var newItemNo = vm.nextSteps.length + 1; + vm.nextSteps.push({'id': newItemNo}); + }; + + vm.removeStep = function (index) { + vm.nextSteps.splice(index,1); + }; + + vm.closeModal = function(){ + $rootScope.ice.loader.show = false; + toastService.clearToast(); + $uibModalInstance.close(); + }; + + vm.submitForm = function () { + + var jsonNextSteps = []; + + var objDate; + var strDate; + angular.forEach(vm.nextSteps, function(value, key) { + var next_step = {}; + next_step.files = []; + if (value.files.length > associated_files.length) { + vm.pull_select_all_from_list(value); + } + angular.forEach(value.files, function(val, key1) { + next_step.files.push(val.File); + }); + next_step.assigneesUuids = []; + angular.forEach(value.assigneesUuids, function(val, key1) { + next_step.assigneesUuids.push(val.id); + }); + + // TODO exho correct format in one command + objDate = new Date(Date.parse((value.duedate) + moment().format("z"))); + next_step.duedate = objDate.getFullYear() + "-" + addZero(objDate.getMonth()+1) + "-" + addZero(objDate.getDate()); + next_step.description = value.description; + jsonNextSteps.push(next_step); + }); + var checklist_uuid = vm.checklist.uuid; + var engUuid = engagement_uuid; + if (vm.edit){ + stepsService.edit(engagement_uuid, nextstep.uuid,jsonNextSteps[0]) + .then(function (response) { + if (response.status === 202) { + $uibModalInstance.close(response.data); + } + }) + .catch(function (error) { + $log.error(error); + toastService.setToast(error.status + ': Error adding next step!', 'danger', {displayFor: 'modal'}); + }); + } else if (vm.checklist.uuid == undefined) { + + stepsService.add(engagement_uuid, jsonNextSteps) + .then(function (response) { + if (response.status === 200) { + $uibModalInstance.close(response.data); + } + }) + .catch(function (error) { + $log.error(error); + toastService.setToast(error.status + ': Error adding next step!', 'danger', {displayFor: 'modal'}); + }); + } else { + stepsService.createChecklistNextStep(checklist_uuid, engUuid, jsonNextSteps) + .then(function (response) { + if (response.status === 200) { + $uibModalInstance.close(response.status); + vm.closeModal(); + } + else + { + toastService.setToast(error.message, 'danger', {displayFor: 'modal'}); + $rootScope.ice.loader.show = false; + $log.error(error); + } + }) + .catch(function (error) { + toastService.setToast(error.message, 'danger', {displayFor: 'modal'}); + $rootScope.ice.loader.show = false; + $log.error(error); + }); + } + }; + + var addZero = function(x) + { + if (x<10) + { + return("0"+x); + } else + { + return(x); + } + } + } +})(); diff --git a/d2ice.att.io/app/main/modals/next-steps/next-steps.html b/d2ice.att.io/app/main/modals/next-steps/next-steps.html new file mode 100755 index 00000000..588247e8 --- /dev/null +++ b/d2ice.att.io/app/main/modals/next-steps/next-steps.html @@ -0,0 +1,138 @@ + + + + diff --git a/d2ice.att.io/app/main/modals/next-steps/next-steps.less b/d2ice.att.io/app/main/modals/next-steps/next-steps.less new file mode 100755 index 00000000..faf3eb9e --- /dev/null +++ b/d2ice.att.io/app/main/modals/next-steps/next-steps.less @@ -0,0 +1,307 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.md-datepicker-calendar-pane { + z-index:30001; +} +md-datepicker.btn { + width:100%; + padding: 0px; + position: relative; + + .md-button.md-icon-button.md-datepicker-button { + float:left; + min-height: 0px; + height: 32px; + z-index: 2; + width: 100%; + padding: 0px; + margin: 0px; + md-icon { + display:none; + } + } + + .md-datepicker-input-container{ + + line-height: 28px; + border-bottom:none; + margin-left: 0px; + position: absolute; + left: 0px; + padding-left: 0px; + width: 100% + } + + .md-datepicker-input { + width: 100%; + text-align: left; + line-height: 32px; + padding-left: 10px; + margin: 0px; + } + .md-datepicker-input::-webkit-input-placeholder { + color: #555; + } + .md-datepicker-triangle-button { + top: 7px; + } + .md-datepicker-triangle-button .md-datepicker-expand-triangle { + border-left: 4px solid transparent; + border-right: 4px solid transparent; + border-top: 4px solid transparent; + border-bottom: 4px solid transparent; + } + + .md-datepicker-triangle-button .md-datepicker-expand-triangle:before { + position: absolute; + top: -13px; + left: -3px; + display: inline-block; + border-left: 3.8px solid transparent; + border-right: 3.8px solid transparent; + border-top: 7px solid transparent; + border-bottom: 5.9px solid #555555; + content: ''; + } + + .md-datepicker-triangle-button .md-datepicker-expand-triangle:after { + position: absolute; + top: 1px; + left: -3px; + display: inline-block; + border-left: 3.8px solid transparent; + border-right: 3.8px solid transparent; + border-top: 5.9px solid #555555; + border-bottom: 7px solid transparent; + content: ''; + } + +} + +.dropdown-menu li[data-ng-if="modelValue().length > 0"] { + display:none; +} +.next-steps +{ + md-datepicker .md-datepicker-input { + text-align: center; + } + +} + +.next-steps { + + .checklist-name + { + padding-left:0px; + border-bottom:1px dashed; + } + + .addNextSteps + { + + margin-bottom:10px;margin-top:10px; + } + + .repeaterNextStep + { + + margin-bottom:10px; + padding-left:10px; + padding-right:10px; + padding-left:10px; + padding-top:10px; + padding-bottom:10px; + border:1px solid; + border-color:#CCCCCC; + } + + .padTop4 + { + padding-top:4px; + } + + .padTop10 + { + padding-top:10px; + } + + .padLeft0 + { + padding-left:0px; + } + + .add-header + { + .a_16_m; + } + + .ice-wysiwyg { + height: 200px; + .wysiwyg-menu > div { + background-color: #f1f1f1; + padding: 2px; + } + } + + .font-deco { + text-decoration-line: underline; + text-decoration-style: dashed; + } + + .text-right + { + text-align:right; + } + + .font_header + { + margin_top:0px; + .m_18_m; + } + + .font_header_add_next + { + .a_24_m; + } + + .font_header_chk_name + { + .m_18_r; + } + + .margin_btm + { + margin-bottom:12px; + } + + .ms + { + background-color:yellow; + } + + multiselect > .btn-group + { + width:100%; + } + multiselect > .btn-group > .btn + { + width:100%; + } + multiselect > .btn-group > .dropdown-menu + { + width:100%; + } + + form > .lineColor + { + background-color:#F6F3F3; + } + + .add-icon { + .sprite; + .sprite.add; + display: inline-block; + } + + .add-button { + margin-top: 8px; + display: block; + .add-text { + .a_16_m; + vertical-align: top; + margin-left: 6px; + } + } + + .remove-icon { + cursor: pointer; + vertical-align: text-top; + //.sprite; + //.sprite.delete;//-circle; + .actions-sprite; + .actions-sprite.delete_large; + + display:block; + position:relative; + top:11px; + } + + .posRelative + { + position:relative; + } + + .posAbsDelBtn + { + position:absolute; + top:10px; + right:20px; + z-index:40000; + } + + #btn-submit { + width: 100%; + } + + .btn-primary { + border: 1px solid #8799A3; + border-radius: 6px; + background: #1E79B0; /* For browsers that do not support gradients */ + background: -webkit-linear-gradient(#1E79B0, #62ADD5); /* For Safari 5.1 to 6.0 */ + background: -o-linear-gradient(#1E79B0, #62ADD5); /* For Opera 11.1 to 12.0 */ + background: -moz-linear-gradient(#1E79B0, #62ADD5); /* For Firefox 3.6 to 15 */ + background: linear-gradient(#1E79B0, #62ADD5); /* Standard syntax (must be last) */ + } + + + + .datepickerdemoBasicUsage { + /** Demo styles for mdCalendar. */ } + .datepickerdemoBasicUsage md-content { + padding-bottom: 200px; } + .datepickerdemoBasicUsage .validation-messages { + font-size: 12px; + color: #dd2c00; + margin-left: 15px; } + + + + +} diff --git a/d2ice.att.io/app/main/modals/select-el-modal/select-el-modal.controller.js b/d2ice.att.io/app/main/modals/select-el-modal/select-el-modal.controller.js new file mode 100755 index 00000000..9b73e706 --- /dev/null +++ b/d2ice.att.io/app/main/modals/select-el-modal/select-el-modal.controller.js @@ -0,0 +1,78 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. + +(function () { + 'use strict'; + + angular + .module('ice.modals') + .controller('selectELModalController', ['$uibModalInstance', 'excludeUuids', 'selectedOption', 'usersService', + '_', '$log', selectELModalController]); + + function selectELModalController($uibModalInstance, excludeUuids, selectedOption, usersService, _, $log) { + var vm = this; + vm.show_warning = false; + var init = function () { + usersService.getEngagementLeads() + .then(function(response) { + vm.engagementLeads = _.filter(response.data, function(el) { + return el.uuid; + }); + + vm.selectedUserUuid = _.find(vm.engagementLeads, ['uuid', selectedOption]); + }) + .catch(function(error) { + $log.error(error); + vm.closeModal(); + }); + }; + + vm.closeModal = function () { + $uibModalInstance.dismiss(); + }; + + vm.onUserSelect = function() { + if(vm.selectedUserUuid) { + $uibModalInstance.close(vm.selectedUserUuid); + } + }; + + init(); + } +})(); diff --git a/d2ice.att.io/app/main/modals/select-el-modal/select-el-modal.html b/d2ice.att.io/app/main/modals/select-el-modal/select-el-modal.html new file mode 100755 index 00000000..fa285a6d --- /dev/null +++ b/d2ice.att.io/app/main/modals/select-el-modal/select-el-modal.html @@ -0,0 +1,56 @@ + +
+ + +
diff --git a/d2ice.att.io/app/main/modals/select-el-modal/select-el-modal.less b/d2ice.att.io/app/main/modals/select-el-modal/select-el-modal.less new file mode 100755 index 00000000..6371cf7e --- /dev/null +++ b/d2ice.att.io/app/main/modals/select-el-modal/select-el-modal.less @@ -0,0 +1,54 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.select-engagement-lead-modal { + padding: 0px 15px 0px 15px; + + .select-engagement-lead-title { + .a_24_m;; + } + + .select-engagement-lead-description { + .m_16_r; + } + + .modal-body { + top: 10px; + } +} + diff --git a/d2ice.att.io/app/main/modals/set-eng-stage/set-eng-stage-modal.controller.js b/d2ice.att.io/app/main/modals/set-eng-stage/set-eng-stage-modal.controller.js new file mode 100755 index 00000000..3824870d --- /dev/null +++ b/d2ice.att.io/app/main/modals/set-eng-stage/set-eng-stage-modal.controller.js @@ -0,0 +1,63 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. + +(function () { + 'use strict'; + + angular + .module('ice.modals') + .controller('setEngStageModalController', ['$rootScope','$uibModalInstance','stage','eng_name','current_stage', setEngStageModalController]); + + function setEngStageModalController($rootScope, $uibModalInstance,stage, eng_name, current_stage) { + + var vm = this; + var init = function () { + vm.stage = stage; + vm.current_stage = current_stage; + vm.modalText = "Are you sure you want to set the Engagement's stage to "+vm.stage+"?"; + vm.eng_name = eng_name; + } + + vm.closeModal = function (bool) { + $uibModalInstance.close(bool); + }; + + init(); + } +})(); diff --git a/d2ice.att.io/app/main/modals/set-eng-stage/set-eng-stage-modal.html b/d2ice.att.io/app/main/modals/set-eng-stage/set-eng-stage-modal.html new file mode 100755 index 00000000..362eb93b --- /dev/null +++ b/d2ice.att.io/app/main/modals/set-eng-stage/set-eng-stage-modal.html @@ -0,0 +1,49 @@ + + + diff --git a/d2ice.att.io/app/main/modals/set-eng-stage/set-eng-stage-modal.less b/d2ice.att.io/app/main/modals/set-eng-stage/set-eng-stage-modal.less new file mode 100755 index 00000000..af7d5ba1 --- /dev/null +++ b/d2ice.att.io/app/main/modals/set-eng-stage/set-eng-stage-modal.less @@ -0,0 +1,135 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.set-stage-modal-text-details { + .m_18_r; + padding: 3% 0% 3% 0%; +} + +.set-stage-title { + .m_18_r; + + .bold { + .a_18_m; + } + +} + +.btn-gradient-success { + font-weight: bold; + color: #FFFFFF; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #41A02C; + *background-color: #41A02C; + background-image: -moz-linear-gradient(top, #A2E652, #41A02C); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#A2E652), to(#41A02C)); + background-image: -webkit-linear-gradient(top, #A2E652, #41A02C); + background-image: -o-linear-gradient(top, #A2E652, #41A02C); + background-image: linear-gradient(to bottom, #A2E652, #41A02C); + background-repeat: repeat-x; + border-color: #41A02C; + border-color: #888; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#A2E652', endColorstr='#41A02C', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); +} +.btn-sample:hover, +.btn-sample:focus, +.btn-sample:active, +.btn-sample.active, +.btn-sample.disabled, +.btn-sample[disabled] { + color: #FFFFFF; + background-color: #41A02C; + *background-color: #003bb3; +} + +.btn-gradient-danger { + font-weight: bold; + color: #FFFFFF; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #AE0020; + *background-color: #AE0020; + background-image: -moz-linear-gradient(top, #F74658, #AE0020); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#F74658), to(#AE0020)); + background-image: -webkit-linear-gradient(top, #F74658, #AE0020); + background-image: -o-linear-gradient(top, #F74658, #AE0020); + background-image: linear-gradient(to bottom, #F74658, #AE0020); + background-repeat: repeat-x; + border-color: #AE0020; + border-color: #888; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#F74658', endColorstr='#AE0020', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); +} +.btn-sample:hover, +.btn-sample:focus, +.btn-sample:active, +.btn-sample.active, +.btn-sample.disabled, +.btn-sample[disabled] { + color: #FFFFFF; + background-color: #AE0020; + *background-color: #003bb3; +} + +.btn-gradient-default { + font-weight: bold; + color: #B3B3B3; + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); + background-color: #D0D0D0; + *background-color: #D0D0D0; + background-image: -moz-linear-gradient(top, #FCFCFC, #D0D0D0); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#FCFCFC), to(#D0D0D0)); + background-image: -webkit-linear-gradient(top, #FCFCFC, #D0D0D0); + background-image: -o-linear-gradient(top, #FCFCFC, #D0D0D0); + background-image: linear-gradient(to bottom, #FCFCFC, #D0D0D0); + background-repeat: repeat-x; + border-color: #D0D0D0; + border-color: #888; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#FCFCFC', endColorstr='#D0D0D0', GradientType=0); + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); +} +.btn-sample:hover, +.btn-sample:focus, +.btn-sample:active, +.btn-sample.active, +.btn-sample.disabled, +.btn-sample[disabled] { + color: #FFFFFF; + background-color: #D0D0D0; + *background-color: #003bb3; +} diff --git a/d2ice.att.io/app/main/modals/set-eng-stage/set_eng_stage_modal.html b/d2ice.att.io/app/main/modals/set-eng-stage/set_eng_stage_modal.html new file mode 100755 index 00000000..adf81be3 --- /dev/null +++ b/d2ice.att.io/app/main/modals/set-eng-stage/set_eng_stage_modal.html @@ -0,0 +1,58 @@ + + +
+ + + +
+ +
+
+ + +
diff --git a/d2ice.att.io/app/main/modals/status/status.controller.js b/d2ice.att.io/app/main/modals/status/status.controller.js new file mode 100755 index 00000000..9a90ec52 --- /dev/null +++ b/d2ice.att.io/app/main/modals/status/status.controller.js @@ -0,0 +1,125 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + 'use strict'; + + angular + .module('ice.modals') + .controller('StatusModalController', ['$rootScope', '$uibModalInstance', 'statusService', 'engagement_uuid', + 'action', 'toastService', '$log', StatusModalController]); + + function StatusModalController($rootScope, $uibModalInstance, statusService, engagement_uuid, action, toastService, $log) { + var vm = this; + + var init = function() { + vm.engagement_uuid = engagement_uuid; + vm.action = action; + if (action == 'edit') { + statusService.get(engagement_uuid) + .then(function (response) { + if (response.status === 200) + { + vm.status = response.data; + vm.status_modal_description = vm.status.description; + vm.eng_status_uuid = vm.status.uuid; + } else + { + $log.error(response); + } + }) + .catch(function (error) { + vm.status = false; + $log.error(error.message); + }); + } else { + vm.status_modal_description = ''; + } + }; + + init(); + + vm.submitForm = function () + { + var jsonPost = {"description":vm.status_modal_description}; + if (action == 'edit') { + jsonPost.eng_status_uuid = vm.eng_status_uuid; + statusService.update(vm.engagement_uuid, jsonPost) + .then(function (response) { + if (response.status === 200) + { + $uibModalInstance.close(response.data); + vm.closeModal(); + } + else + { + toastService.setToast(response.error, 'danger'); + $rootScope.ice.loader.show = false; + } + }) + .catch(function (error) { + toastService.setToast(error.message, 'danger'); + $log.error(error.message); + }); + } else { + statusService.add(vm.engagement_uuid, jsonPost) + .then(function (response) { + if (response.status === 200) + { + + $uibModalInstance.close(response.data); + vm.closeModal(); + } + else + { + toastService.setToast(response.error, 'danger'); + $rootScope.ice.loader.show = false; + } + }) + .catch(function (error) { + toastService.setToast(error.message, 'danger'); + $log.error(error.message); + }); + } + }; + + vm.closeModal = function(){ + $uibModalInstance.close(); + }; + } +})(); diff --git a/d2ice.att.io/app/main/modals/status/status.html b/d2ice.att.io/app/main/modals/status/status.html new file mode 100755 index 00000000..83c50d2b --- /dev/null +++ b/d2ice.att.io/app/main/modals/status/status.html @@ -0,0 +1,59 @@ + + + + + diff --git a/d2ice.att.io/app/main/modals/status/status.less b/d2ice.att.io/app/main/modals/status/status.less new file mode 100755 index 00000000..ae5f7945 --- /dev/null +++ b/d2ice.att.io/app/main/modals/status/status.less @@ -0,0 +1,44 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.status-modal-body { + .status-modal-description { + border-color: @main_color_q; + margin-bottom:15px; + } +} diff --git a/d2ice.att.io/app/main/modals/target-lab-entry/change-lab-entry-date.controller.js b/d2ice.att.io/app/main/modals/target-lab-entry/change-lab-entry-date.controller.js new file mode 100755 index 00000000..a300d3da --- /dev/null +++ b/d2ice.att.io/app/main/modals/target-lab-entry/change-lab-entry-date.controller.js @@ -0,0 +1,78 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + 'use strict'; + + angular + .module('ice.modals') + .controller('ChangeLabEntryDateModalController', ["$uibModalInstance", "targetLabDate", "engagementUuid", "vfService", "$rootScope", "toastService", changeLabEntryDateModalController]); + + function changeLabEntryDateModalController($uibModalInstance, targetLabDate, engagementUuid, vfService, $rootScope, toastService) { + + var vm = this; + //vm.completionDate = new Date(completionDate); + vm.targetLabDate = targetLabDate; + vm.dateOptions = { + minDate: new Date(), + showWeeks: true + }; + + vm.closeModal = function(){ + $uibModalInstance.close(); + }; + + vm.myDate = new Date(); + vm.minDate = moment(vm.myDate).format("YYYY-MM-DD") + vm.maxDate = moment(vm.myDate).add(2, 'years').format("YYYY-MM-DD"); + + vm.submitForm = function(){ + var postData={"target_date": moment(vm.targetLabDate).format("YYYY-MM-DD")}; + vfService.updateLabEntryDaysLeft(engagementUuid, postData) + .then(function (response) { + if (response.status === 200) { + $uibModalInstance.close(postData); + } + }) + .catch(function (error) { + toastService.setToast(error.status + ': Error changing completion date!', 'danger'); + }); + }; + } +})(); diff --git a/d2ice.att.io/app/main/modals/target-lab-entry/change-lab-entry-date.html b/d2ice.att.io/app/main/modals/target-lab-entry/change-lab-entry-date.html new file mode 100755 index 00000000..cfd30f79 --- /dev/null +++ b/d2ice.att.io/app/main/modals/target-lab-entry/change-lab-entry-date.html @@ -0,0 +1,55 @@ + +
+ + + + +
diff --git a/d2ice.att.io/app/main/modals/target-lab-entry/change-lab-entry-date.less b/d2ice.att.io/app/main/modals/target-lab-entry/change-lab-entry-date.less new file mode 100755 index 00000000..8aa6f3be --- /dev/null +++ b/d2ice.att.io/app/main/modals/target-lab-entry/change-lab-entry-date.less @@ -0,0 +1,49 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. + .edit-target-lab-date-modal { + .md-datepicker-input-container { + .md-datepicker-input { + width: 100%; + text-align: left; + line-height: 32px; + padding-left: 95px; + margin: 0px; + } + } + } \ No newline at end of file diff --git a/d2ice.att.io/app/main/modals/update-engagement-status-modal/update-engagement-status-modal.controller.js b/d2ice.att.io/app/main/modals/update-engagement-status-modal/update-engagement-status-modal.controller.js new file mode 100755 index 00000000..f9afa320 --- /dev/null +++ b/d2ice.att.io/app/main/modals/update-engagement-status-modal/update-engagement-status-modal.controller.js @@ -0,0 +1,73 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. + +(function () { + 'use strict'; + + angular + .module('ice.modals') + .controller('updateEngagementStatusModalController', ['$uibModalInstance', 'engagement', updateEngagementStatusModalController]); + + function updateEngagementStatusModalController($uibModalInstance, engagement) { + var vm = this; + var init = function () { + vm.engagement = engagement; + formatDates(); + }; + + vm.closeModal = function () { + $uibModalInstance.dismiss(); + }; + + vm.updateEngagement = function() { + formatDates(); + $uibModalInstance.close({"engagement": vm.engagement, "status": vm.status}); + }; + + var formatDates = function() { + if(vm.engagement.target_completion_date){ vm.engagement.target_completion_date = new Date(vm.engagement.target_completion_date); } + if(vm.engagement.heat_validated_time){ vm.engagement.heat_validated_time = new Date(vm.engagement.heat_validated_time); } + if(vm.engagement.image_scan_time){ vm.engagement.image_scan_time = new Date(vm.engagement.image_scan_time); } + if(vm.engagement.aic_instantiation_time){ vm.engagement.aic_instantiation_time = new Date(vm.engagement.aic_instantiation_time); } + if(vm.engagement.asdc_onboarding_time){ vm.engagement.asdc_onboarding_time = new Date(vm.engagement.asdc_onboarding_time); } + }; + + init(); + } +})(); diff --git a/d2ice.att.io/app/main/modals/update-engagement-status-modal/update-engagement-status-modal.html b/d2ice.att.io/app/main/modals/update-engagement-status-modal/update-engagement-status-modal.html new file mode 100755 index 00000000..29abb24e --- /dev/null +++ b/d2ice.att.io/app/main/modals/update-engagement-status-modal/update-engagement-status-modal.html @@ -0,0 +1,97 @@ + +
+ + +
diff --git a/d2ice.att.io/app/main/modals/update-engagement-status-modal/update-engagement-status-modal.less b/d2ice.att.io/app/main/modals/update-engagement-status-modal/update-engagement-status-modal.less new file mode 100755 index 00000000..8bce9da3 --- /dev/null +++ b/d2ice.att.io/app/main/modals/update-engagement-status-modal/update-engagement-status-modal.less @@ -0,0 +1,61 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +.update-engagement-status-modal { + padding: 0px 15px 0px 15px; + + .update-engagement-status-title { + .a_24_m;; + } + + .update-engagement-status-description { + .m_16_r; + } + + .form-field-title{ + .m_16_r; + } + + .modal-body { + top: 10px; + } + + .md-datepicker-input { + max-width: none; + } +} diff --git a/d2ice.att.io/app/main/modals/validation-details/detailed-view-validation-details-modal.controller.js b/d2ice.att.io/app/main/modals/validation-details/detailed-view-validation-details-modal.controller.js new file mode 100755 index 00000000..1370e367 --- /dev/null +++ b/d2ice.att.io/app/main/modals/validation-details/detailed-view-validation-details-modal.controller.js @@ -0,0 +1,202 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +(function () { + + + 'use strict'; + + angular + .module('ice.modals') + .controller('validationDetailsModalController', ["$rootScope", "$uibModalInstance", "vfcService", "vfService", "$stateParams", "toastService", "vf_uuid", "usersService", "$log", "_", validationDetailsModalController]); + + function validationDetailsModalController($rootScope, $uibModalInstance, vfcService,vfService, $stateParams,toastService, vf_uuid, usersService,$log,_) { + + var vm = this; + var init = function () { + if($stateParams.engagement) { + vm.engagement = $stateParams.engagement; + } + vm.me = usersService.getUserData(); + vfService.getSingleEngagement(vm.me.uuid,vm.engagement.uuid) + .then(function (response) { + $rootScope.ice.loader.show = false; + + if (response.status === 200 && response.data && response.data !== '') { + var vf_data = response.data; + vm.engagement_manual_id = vf_data.engagement.engagement_manual_id; + vm.vf_name = vf_data.name; + vm.vf_uuid = vf_data.uuid; + vm.ecomp_release = vf_data.ecomp_release; + vm.target_lab = new Date(vf_data.target_lab_entry_date); + vm.dtversion = vf_data.deployment_target; + vm.selected_dt_uuid = vm.dtversion.uuid; + vm.selected_ecomp_uuid = vm.ecomp_release.uuid; + vm.me = usersService.getUserData(); + vm.name = vm.engagement.name; + vm.isEngagementEL = usersService.isEngagementEL(vf_data.engagement.engagement_team); + vm.isAdmin = usersService.isAdmin(vm.me); + vm.choices = [{TargetLab: '', TargetAic: ''}]; + getDeployTargets(); + getECOMPReleases(); + getVFVersion(); + } + }) + .catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + }; + + vm.closeModal = function(){ + $uibModalInstance.close(); + }; + + vm.addNewChoice = function () { + var newItemNo = vm.choices.length + 1; + vm.choices.push({'id': newItemNo}); + }; + + function getDeployTargets() { + vfService.getDeployTargets() + .then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 200) { + vm.deployTargets = response.data; + if (_.filter(vm.deployTargets, {'uuid': vm.dtversion.uuid}).length === 0) { + vm.dtversion.disabled = true; + vm.deployTargets.push(vm.dtversion); + } + } + }).catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + } + function getECOMPReleases(){ + vfService.getECOMPReleases() + .then(function (response) { + if (response.status === 200) { + vm.ECOMPReleases = response.data; + if (_.filter(vm.ECOMPReleases, {'uuid':vm.ecomp_release.uuid}).length === 0) { + vm.ecomp_release.disabled = true; + vm.ECOMPReleases.push(vm.ecomp_release); + } + } + }).catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + } + function getVFVersion(){ + vfService.getVFVersion(vf_uuid) + .then(function (response) { + $rootScope.ice.loader.show = false; + if (response.status === 200) { + vm.VFVersion = response.data; + } + }).catch(function (error) { + $rootScope.ice.loader.show = false; + $log.debug(error); + }); + } + vm.removeChoice = function (index) { + vm.choices.splice(index,1); + }; + + vm.submitForm = function(){ + var validationDetailsSelection = { + "vf_uuid": vm.vf_uuid, + "version": vm.VFVersion, + "target_aic_uuid": vm.TargetAic, + "ecomp_release": vm.ECOMPRelease + }; + + vfService.updateVfs(validationDetailsSelection,vm.vf_uuid) + .then(function (response) { + if (response.status === 200) { + $uibModalInstance.close(response.status); + } + }) + .catch(function (error) { + $log.error(error); + toastService.setToast(error.status + ': Error changing progress!', 'danger'); + }); + }; + + vm.update_deployment_target = function(){ + if(vm.dtversion.uuid == vm.selected_dt_uuid){ + return + } + angular.forEach(vm.dt_AIC_versions, function (value, key) { + if (value.uuid === vm.selected_dt_uuid) { + vm.dtversion = value; + }; + }); + vfService.updateDeployTargets(vm.engagement.uuid, vm.selected_dt_uuid) + .then(function (response) { + $rootScope.ice.loader.show = false; + }).catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + vm.set_edit_mode('aic'); + }; + vm.update_ECOMP_release = function(){ + if( vm.ecomp_release.uuid == vm.selected_ecomp_uuid){ + return; + } + _.each(vm.ECOMPReleases, function (value, key) { + if (value.uuid === vm.selected_ecomp_uuid) { + vm.ecomp_release = value; + }; + }); + vfService.updateECOMPReleases(vm.engagement.uuid, vm.selected_ecomp_uuid) + .then(function (response) { + $rootScope.ice.loader.show = false; + }).catch(function (error) { + $rootScope.ice.loader.show = false; + $log.error(error); + }); + vm.set_edit_mode('ecomp'); + }; + + init(); + } + +})(); diff --git a/d2ice.att.io/app/main/modals/validation-details/detailed-view-validation-details-modal.html b/d2ice.att.io/app/main/modals/validation-details/detailed-view-validation-details-modal.html new file mode 100755 index 00000000..48e3fe2a --- /dev/null +++ b/d2ice.att.io/app/main/modals/validation-details/detailed-view-validation-details-modal.html @@ -0,0 +1,101 @@ + + + diff --git a/d2ice.att.io/app/main/modals/validation-details/detailed-view-validation-details-modal.less b/d2ice.att.io/app/main/modals/validation-details/detailed-view-validation-details-modal.less new file mode 100755 index 00000000..08fd5ea8 --- /dev/null +++ b/d2ice.att.io/app/main/modals/validation-details/detailed-view-validation-details-modal.less @@ -0,0 +1,49 @@ +// +// ============LICENSE_START========================================== +// org.onap.vvp/portal +// =================================================================== +// Copyright © 2017 AT&T Intellectual Property. All rights reserved. +// =================================================================== +// +// Unless otherwise specified, all software contained herein is licensed +// under the Apache License, Version 2.0 (the “License”); +// you may not use this software except in compliance with the License. +// You may obtain a copy of the License at +// +// http:www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// +// +// Unless otherwise specified, all documentation contained herein is licensed +// under the Creative Commons License, Attribution 4.0 Intl. (the “License”); +// you may not use this documentation except in compliance with the License. +// You may obtain a copy of the License at +// +// https:creativecommons.org/licenses/by/4.0/ +// +// Unless required by applicable law or agreed to in writing, documentation +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// ============LICENSE_END============================================ +// +// ECOMP is a trademark and service mark of AT&T Intellectual Property. +#validation-details-form { + #edit-validation-setails-save-button { + margin-top: 15px; + } + + .field-title { + .m_16_m; + margin-bottom: 2px; + margin-top: 5px; + } +} -- cgit 1.2.3-korg