From f59a56b7c12badbb41bb2155b6de47e9c9c48bcd Mon Sep 17 00:00:00 2001 From: GUJJA Date: Thu, 22 Feb 2018 12:21:33 -0500 Subject: Added Junits Issue-ID: PORTAL-136 Includes JUNITS Change-Id: I859aa9de0ce51a1ac699c81e98c2af7fda7ae660 Signed-off-by:GUJJA --- .../client/app/views/role/rolefunctionpopupController.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'ecomp-portal-FE-common/client') diff --git a/ecomp-portal-FE-common/client/app/views/role/rolefunctionpopupController.js b/ecomp-portal-FE-common/client/app/views/role/rolefunctionpopupController.js index 0fa84f31..4573effa 100644 --- a/ecomp-portal-FE-common/client/app/views/role/rolefunctionpopupController.js +++ b/ecomp-portal-FE-common/client/app/views/role/rolefunctionpopupController.js @@ -124,8 +124,11 @@ app.controller('rolefunctionpopupController',function($scope, confirmBoxService, break; } if (!isEditing) { - if (message.availableRoleFunctions[x].code == availableRoleFunction.code) { - confirmBoxService.showInformation("Code already exists. Please create a role function with a different code to proceed."); + if (message.availableRoleFunctions[x].type == availableRoleFunction.type + && message.availableRoleFunctions[x].code == availableRoleFunction.code + && message.availableRoleFunctions[x].action == availableRoleFunction.action + ) { + confirmBoxService.showInformation("Please make sure code, type and action is unique. Please create a role function with a different code or type or action to proceed."); exists = true; availableRoleFunction.name = $scope.tempText; break; -- cgit 1.2.3-korg