Unverified Commit 7014788f authored by rsayannagari-nisum-com's avatar rsayannagari-nisum-com Committed by GitHub

Merge pull request #92 from nisum-inc/Issues_Domains_controller

issues in domain module
parents 393c6ba3 3d3c7609
......@@ -211,11 +211,6 @@ public class DomainServiceImpl implements DomainService {
boolean check=false;
int count=0;
List<Domains> domainListbyAccountId=domainRepo.findByAccountId(accountId);
for(Domains domains:domainListbyAccountId )
{
if(domains.getDomainName().equalsIgnoreCase(domainName))
count++;
}
boolean deleveryManagersCheck=fromDB.toString().contentEquals(fromUser.toString());
List<Domains> domainList=domainRepo.findByDomainNameAndAccountId(domainName, accountId);
for(Domains domains:domainListbyAccountId )
......
......@@ -12,7 +12,7 @@ myApp.controller("domainController",
});
var getCellTemplate = '<p class="col-lg-12"><p class="col-lg-4"><i class="fa fa-pencil-square-o fa-2x" ng-show="row.entity.status == \'Active\'" aria-hidden="true" id="UpdateBtnVisible" style="font-size:1.5em;margin-top:3px;cursor:pointer;" data-placement="center" title="Edit" onmouseenter="$(this).tooltip(\'show\')" ng-click="grid.appScope.getRowData(row,\'Update\')"></i></p>'+
var getCellTemplate = '<p class="col-lg-12"><p class="col-lg-4"><i class="fa fa-pencil-square-o fa-2x" ng-show="row.entity.status == \'Active\'" aria-hidden="true" id="UpdateBtnVisible" style="font-size:1.5em;margin-top:3px;cursor:pointer;" data-placement="center" title="Edit" onmouseenter="$(this).tooltip(\'show\')" ng-click="grid.appScope.getRowData(row,\'Update\')"></i></p>'+
'<p class="col-lg-4"><i class="fa fa-minus-circle fa-2x" aria-hidden="true" style="font-size:1.5em;margin-top:3px;cursor:pointer;" data-placement="left" title="Delete" onmouseenter="$(this).tooltip(\'show\')" ng-click="grid.appScope.getRowData(row,\'Delete\')"></i></p></p>';
$scope.gridOptions = {
......@@ -264,14 +264,14 @@ myApp.controller("domainController",
$scope.cancel = function() {
var showConfirmDialog = false;
var totalFields = $scope.myForm.$$controls;
for (key in totalFields) {
var totalFields = $scope.myForm.$$controls;
for (key in totalFields) {
console.log("Model value of" + key + " ==>" + totalFields[key].$modelValue)
if(totalFields[key].$modelValue !== '' && totalFields[key].$modelValue !== undefined && totalFields[key].$modelValue.length !== 0) {
console.log("Came here!");
showConfirmDialog = true;
console.log("Came here!");
showConfirmDialog = true;
}
}
}
if(showConfirmDialog){
$mdDialog.show($mdDialog.confirm({
skipHide: true,
......@@ -365,8 +365,6 @@ myApp.controller("domainController",
}
}
$scope.ifEmployeeNameExists = function(empName) {
$scope.selectedEmployeeNames.push(manager.employeeName);
removeDuplicates($scope.selectedEmployeeNames);
return $scope.selectedEmployeeNames.includes(empName);
}
$scope.validateFields = function(action){
......@@ -424,11 +422,6 @@ myApp.controller("domainController",
};
function removeDuplicates(arr){
return arr.filter(function(item, pos) {
return arr.indexOf(item) == pos;
})
}
}
});
\ No newline at end of file
......@@ -91,7 +91,18 @@
<h4>Organization Info</h4>
<div class="form-group">
<table>
<tr>
<td colspan="4"><b>Functional Group:</b><span class="mandatory"></span></td>
<td colspan="8"><md-select ng-model="functionalGroup"
md-selected-text="getSelectedFunctionalGroup()"
id="functionalGroup"> <md-optgroup
label="Functional Org"> <md-option
ng-value="functionalGroup"
ng-repeat="functionalGroup in functionalGroups">{{functionalGroup}}</md-option>
</md-optgroup> </md-select></td>
</tr>
<tr>
<td colspan="4"><b>Role:</b></td>
<td colspan="8"><md-select ng-model="empRole"
md-selected-text="getSelectedRole()" id="empRole"> <md-optgroup
......@@ -146,16 +157,7 @@
</md-optgroup> </md-select></td>
</tr> -->
<tr>
<td colspan="4"><b>Functional Group:</b><span class="mandatory"></span></td>
<td colspan="8"><md-select ng-model="functionalGroup"
md-selected-text="getSelectedFunctionalGroup()"
id="functionalGroup"> <md-optgroup
label="Functional Org"> <md-option
ng-value="functionalGroup"
ng-repeat="functionalGroup in functionalGroups">{{functionalGroup}}</md-option>
</md-optgroup> </md-select></td>
</tr>
<tr>
<td colspan="1"><b>HasPassport:</b><span class="mandatory"></span></td>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment