Commit a6abbc45 authored by Vanavaraju's avatar Vanavaraju

Updated java changes based on backend team code refactoring

parent deb28aca
......@@ -2,7 +2,6 @@ package com.nisum.mytime.controller;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;
import org.slf4j.Logger;
......@@ -24,7 +23,6 @@ import com.nisum.mytime.model.Account;
import com.nisum.mytime.model.AccountInfo;
import com.nisum.mytime.model.Domain;
import com.nisum.mytime.model.Employee;
import com.nisum.mytime.model.MasterData;
import com.nisum.mytime.service.IEmployeeService;
import com.nisum.mytime.service.IRoleMappingService;
......
......@@ -15,13 +15,13 @@ import org.springframework.web.bind.annotation.RestController;
import com.nisum.mytime.exception.handler.MyTimeException;
import com.nisum.mytime.model.MasterData;
import com.nisum.mytime.service.impl.MasterDataService;
import com.nisum.mytime.service.IMasterDataService;
@RestController
public class MasterDataController {
@Autowired
MasterDataService masterDataService;
IMasterDataService masterDataService;
@RequestMapping(value = "/getMasterData", method = RequestMethod.GET, produces = MediaType.APPLICATION_JSON_VALUE)
public ResponseEntity<Map<String, List<String>>> getMasterData() throws MyTimeException {
......
......@@ -6,7 +6,6 @@ import java.util.List;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import org.bson.types.ObjectId;
import org.hibernate.validator.constraints.NotBlank;
import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.mapping.Document;
......
......@@ -3,13 +3,14 @@ package com.nisum.mytime.service.impl;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.nisum.mytime.exception.handler.MyTimeException;
import com.nisum.mytime.model.MasterData;
import com.nisum.mytime.repository.MasterDataRepo;
import com.nisum.mytime.service.IMasterDataService;
@Service("masterDataService")
public class MasterDataService implements IMasterDataService {
@Autowired
......
......@@ -31,7 +31,7 @@ myApp.controller("loginController",function($scope, myFactory, $compile, $window
function getUserRole(profile){
$http({
method : "GET",
url : appConfig.appUri + "user/employee?emailId="+profile.getEmail()
url : appConfig.appUri + "employees?emailId="+profile.getEmail()
}).then(function mySuccess(response) {
var result = response.data;
if(result == "" || result.length == 0){
......@@ -50,7 +50,7 @@ myApp.controller("loginController",function($scope, myFactory, $compile, $window
function getAllUserRoles(){
$http({
method : "GET",
url : appConfig.appUri + "user/getUserRoles"
url : appConfig.appUri + "employees/active"
}).then(function mySuccess(response) {
$scope.rolesData = response.data;
}, function myError(response) {
......@@ -61,7 +61,7 @@ myApp.controller("loginController",function($scope, myFactory, $compile, $window
function getMasterData(){
$http({
method : "GET",
url : appConfig.appUri + "user/getMasterData"
url : appConfig.appUri + "getMasterData"
}).then(function mySuccess(response) {
myFactory.setEmployementTypes(response.data['EmpType']);
myFactory.setFunctionalgroups(response.data['FunctionalGrp'])
......@@ -78,7 +78,7 @@ myApp.controller("loginController",function($scope, myFactory, $compile, $window
function getAllLocations(){
$http({
method : "GET",
url : appConfig.appUri + "user/getLocations"
url : appConfig.appUri + "employees/locations/"
}).then(function mySuccess(response) {
myFactory.setLocations(response.data);
}, function myError(response) {
......@@ -88,7 +88,7 @@ myApp.controller("loginController",function($scope, myFactory, $compile, $window
function getAllAccounts(){
$http({
method : "GET",
url : appConfig.appUri + "user/getAccounts"
url : appConfig.appUri + "accounts"
}).then(function mySuccess(response) {
myFactory.setAccounts(response.data);
}, function myError(response) {
......
......@@ -120,7 +120,7 @@ myApp.controller("projectController", function ($scope, myFactory, exportUiGridS
$scope.getManagerDetails = function () {
$http({
method: "GET",
url: appConfig.appUri + "/user/getManagers"
url: appConfig.appUri + "/employees/managers/"
}).then(function mySuccess(response) {
$scope.managers = response.data;
}, function myError(response) {
......
......@@ -255,9 +255,9 @@ myApp.controller("projectTeamController",function($scope, myFactory, $mdDialog,
function deleteUserRole(empId, projectId,id){
var record = {"id":id,"employeeId":empId,"projectId":projectId};
var loginEmpId = myFactory.getEmpId();
var req = {
method : 'POST',
var loginEmpId = myFactory.getEmpId();
url : appConfig.appUri+ "projectTeam/deleteTeammate?loginEmpId="+loginEmpId,
headers : {
"Content-type" : "application/json"
......
......@@ -341,8 +341,14 @@ i.fa.fa-refresh:hover {
}
/* Grid Styles */
.grid-full-view {
height: calc(100vh - 195px) !important;
}
.grid-half-view {
height: calc(85vh - 215px) !important;
}
.ui-grid-contents-wrapper {
/* height: 90% !important; */
}
.ui-grid {
border: none !important;
......@@ -382,7 +388,7 @@ i.fa.fa-refresh:hover {
/* .ui-grid-contents-wrapper .ui-grid-header-cell div:empty {
background: #eeeef6;
min-height: 30px;
}
} */
.ui-grid-contents-wrapper .ui-grid-header-cell:last-child div:empty:last-child:after {
background: #eeeef6;
content: "";
......@@ -391,7 +397,7 @@ i.fa.fa-refresh:hover {
height: 30px;
position: absolute;
right: -6px;
} */
}
.ui-grid-contents-wrapper .ui-grid-cell-contents {
/* border-bottom: 1px solid #e5e5e5; */
padding: 10px 8px;
......
......@@ -59,7 +59,7 @@
<div class="form-group">
<div class="form-inline col-lg-12">
<div id="gridTest" ui-grid="gridOptions" ui-grid-pagination
class="myGrid">
class="myGrid grid-half-view">
<div class="watermark" ng-show="!gridOptions.data.length">No
data available</div>
</div>
......
......@@ -39,7 +39,7 @@
<div class="row">
<div class="col-lg-12">
<div id="gridTest" ui-grid="gridOptionsOrgView" ui-grid-pagination
class="myGrid">
class="myGrid grid-full-view">
<div class="watermark" ng-show="!gridOptionsOrgView.data.length">No
data available</div>
</div>
......
......@@ -17,7 +17,7 @@
</div>
<div class="col-lg-12">
<div id="gridTest" ui-grid="gridOptions" ui-grid-pagination
class="myGrid">
class="myGrid grid-full-view">
<div class="watermark" ng-show="!gridOptions.data.length">No
data available</div>
</div>
......
......@@ -11,7 +11,7 @@
<div class="row">
<div class="col-lg-12">
<div id="gridTest" ui-grid="gridOptions" ui-grid-pagination
class="myGrid">
class="myGrid grid-full-view">
<div class="watermark" ng-show="!gridOptions.data.length">No
data available</div>
</div>
......
......@@ -28,7 +28,7 @@
<div class="row col-lg-12">
<div id="gridTest" ui-grid="gridOptions" ui-grid-pagination
class="myGrid" style="width:99%;height:370px;margin-left:0px;">
class="myGrid grid-full-view">
<div class="watermark" ng-show="!gridOptions.data.length">No
data available</div>
</div>
......
......@@ -2,7 +2,7 @@
ng-init="getUserRoles()">
<div class="container-fluid mainDivHeaderClass">
<div class="row">
<div class="col-lg-6">
<div class="col-lg-6">
<h1 class="no-padding">Manage Employees</h1>
</div>
<div class="col-lg-6 add-emp no-padding">
......@@ -24,7 +24,7 @@
<div class="row col-lg-12">
<div id="gridTest" ui-grid="gridOptions" ui-grid-pagination
class="myGrid">
class="myGrid grid-full-view">
<div class="watermark" ng-show="!gridOptions.data.length">No
data available</div>
......
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