Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mytime
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Narendar Vakiti
mytime
Commits
f68830f6
Commit
f68830f6
authored
Jun 06, 2019
by
Prayas Jain
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added Reserved Reports and Allocation change screen
parent
fe8b2e4d
Changes
11
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
322 additions
and
25 deletions
+322
-25
ReportsController.java
...n/java/com/nisum/myteam/controller/ReportsController.java
+17
-7
ReportVo.java
src/main/java/com/nisum/myteam/model/vo/ReportVo.java
+9
-9
AllocationChangeController.js
.../webapp/WEB-INF/controllers/AllocationChangeController.js
+98
-0
ChartsController.js
src/main/webapp/WEB-INF/controllers/ChartsController.js
+8
-5
LeftMenuController.js
src/main/webapp/WEB-INF/controllers/LeftMenuController.js
+4
-1
LoginController.js
src/main/webapp/WEB-INF/controllers/LoginController.js
+6
-0
ReservedReportController.js
...in/webapp/WEB-INF/controllers/ReservedReportController.js
+99
-0
custom-theme.css
src/main/webapp/WEB-INF/css/custom-theme.css
+4
-3
allocationChangeReport.html
...main/webapp/WEB-INF/templates/allocationChangeReport.html
+26
-0
index.html
src/main/webapp/WEB-INF/templates/index.html
+3
-0
reservedReport.html
src/main/webapp/WEB-INF/templates/reservedReport.html
+48
-0
No files found.
src/main/java/com/nisum/myteam/controller/ReportsController.java
View file @
f68830f6
...
...
@@ -382,13 +382,17 @@ public class ReportsController {
ReportVo
reportVo
=
new
ReportVo
();
Map
<
String
,
Object
>
billableData
=
new
HashMap
();
Map
<
String
,
Object
>
nonBillableData
=
new
HashMap
();
List
<
Integer
>
billableCount
=
new
ArrayList
<>();
List
<
Integer
>
nonBillableCount
=
new
ArrayList
<>();
List
<
Object
>
billableCount
=
new
ArrayList
<>();
List
<
Object
>
nonBillableCount
=
new
ArrayList
<>();
billableData
.
put
(
"name"
,
"Billable"
);
nonBillableData
.
put
(
"name"
,
"Non Billable"
);
for
(
String
functionalGroup:
reportVo
.
getCategories
()){
for
(
String
functionalGroup:
reportVo
.
getCategoriesList
()){
Map
<
String
,
Object
>
billableObj
=
new
HashMap
();
Map
<
String
,
Object
>
nonbillableObj
=
new
HashMap
();
Integer
billableC
=
0
;
Integer
nonBillableC
=
0
;
float
billper
;
float
nonBillPer
;
List
<
Employee
>
employeeList
=
employeeService
.
getAllEmployees
().
stream
().
filter
(
e
->
e
.
getFunctionalGroup
().
equals
(
functionalGroup
)).
collect
(
Collectors
.
toList
());
for
(
Employee
employee:
employeeList
){
...
...
@@ -399,13 +403,19 @@ public class ReportsController {
nonBillableC
++;
}
}
billableCount
.
add
(
billableC
);
nonBillableCount
.
add
(
nonBillableC
);
billper
=
((
billableC
/
(
float
)
employeeList
.
size
())*
100
);
nonBillPer
=
nonBillableC
/(
float
)
employeeList
.
size
()*
100
;
billableObj
.
put
(
"percent"
,
billper
);
billableObj
.
put
(
"y"
,
billableC
);
nonbillableObj
.
put
(
"percent"
,
nonBillPer
);
nonbillableObj
.
put
(
"y"
,
nonBillableC
);
billableCount
.
add
(
billableObj
);
nonBillableCount
.
add
(
nonbillableObj
);
}
billableData
.
put
(
"data"
,
billableCount
);
nonBillableData
.
put
(
"data"
,
nonBillableCount
);
reportVo
.
getSeries
().
add
(
billableData
);
reportVo
.
getSeries
().
add
(
nonBillableData
);
reportVo
.
getSeries
DataList
().
add
(
billableData
);
reportVo
.
getSeries
DataList
().
add
(
nonBillableData
);
return
reportVo
;
}
...
...
src/main/java/com/nisum/myteam/model/vo/ReportVo.java
View file @
f68830f6
...
...
@@ -12,16 +12,16 @@ import java.util.Map;
public
class
ReportVo
{
List
<
String
>
categories
=
new
ArrayList
();
List
<
Map
<
String
,
Object
>>
series
=
new
ArrayList
();
List
<
String
>
categories
List
=
new
ArrayList
();
List
<
Map
<
String
,
Object
>>
series
DataList
=
new
ArrayList
();
public
ReportVo
(){
categories
.
add
(
"ES"
);
categories
.
add
(
"CI"
);
categories
.
add
(
"APPS"
);
categories
.
add
(
"ACI - QE"
);
categories
.
add
(
"ACI - DevOps"
);
categories
.
add
(
"ACI - Support"
);
categories
.
add
(
"I&A"
);
categories
List
.
add
(
"ES"
);
categories
List
.
add
(
"CI"
);
categories
List
.
add
(
"APPS"
);
categories
List
.
add
(
"ACI - QE"
);
categories
List
.
add
(
"ACI - DevOps"
);
categories
List
.
add
(
"ACI - Support"
);
categories
List
.
add
(
"I&A"
);
}
}
src/main/webapp/WEB-INF/controllers/AllocationChangeController.js
0 → 100644
View file @
f68830f6
myApp
.
controller
(
"allocationChangeReportController"
,
function
(
$scope
,
exportUiGridService
,
myFactory
,
$mdDialog
,
$http
,
appConfig
,
$timeout
,
$element
,
$window
){
$scope
.
records
=
[];
// +' <i ng-show="row.entity.status == \'InActive\'"> </i><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>';
$scope
.
gridOptions
=
{
paginationPageSizes
:
[
10
,
20
,
30
,
40
,
50
,
100
],
paginationPageSize
:
10
,
pageNumber
:
1
,
pageSize
:
10
,
enableFiltering
:
true
,
columnDefs
:
[
{
field
:
'employeeId'
,
displayName
:
'Employee Id'
,
enableColumnMenu
:
false
,
enableSorting
:
false
,
enableFiltering
:
true
},
{
field
:
'employeeName'
,
displayName
:
'Employee Name'
,
enableColumnMenu
:
false
,
enableSorting
:
true
,
enableFiltering
:
true
},
{
name
:
' prevClient'
,
displayName
:
'Previous Client'
,
enableColumnMenu
:
false
,
enableSorting
:
false
,
enableFiltering
:
false
},
{
field
:
'prevProjectName'
,
displayName
:
'Previous Project'
,
enableColumnMenu
:
false
,
enableSorting
:
true
,
enableFiltering
:
true
},
{
name
:
'prevBillableStatus'
,
displayName
:
'Previous Billability'
,
enableColumnMenu
:
false
,
enableSorting
:
false
,
enableFiltering
:
false
},
{
name
:
'prevBillingStartDate'
,
displayName
:
'Previous Billing Start Date'
,
enableColumnMenu
:
false
,
enableSorting
:
false
,
enableFiltering
:
false
},
{
name
:
'currentClient'
,
displayName
:
'Current Client'
,
enableColumnMenu
:
false
,
enableSorting
:
false
,
enableFiltering
:
false
},
{
field
:
'currentProjectName'
,
displayName
:
'Current Project'
,
enableColumnMenu
:
false
,
enableSorting
:
true
,
enableFiltering
:
true
},
{
name
:
'currentBillingStartDate'
,
displayName
:
'Current Billing Start Date'
,
enableColumnMenu
:
false
,
enableSorting
:
false
,
enableFiltering
:
false
},
{
name
:
'currentBillingStartDate'
,
displayName
:
'Current Billing End Date'
,
enableColumnMenu
:
false
,
enableSorting
:
false
,
enableFiltering
:
false
},
],
enableGridMenu
:
true
,
enableSelectAll
:
true
,
exporterMenuExcel
:
false
,
exporterMenuCsv
:
false
,
exporterCsvFilename
:
'EmployeeEfforts.csv'
,
exporterExcelFilename
:
'EmployeeEfforts'
,
exporterPdfDefaultStyle
:
{
fontSize
:
9
},
exporterPdfTableStyle
:
{
margin
:
[
15
,
15
,
15
,
15
]},
exporterPdfTableHeaderStyle
:
{
fontSize
:
10
,
bold
:
true
,
italics
:
true
,
color
:
'red'
},
exporterPdfHeader
:
{
text
:
"Employee Efforts"
,
style
:
'headerStyle'
},
exporterPdfFooter
:
function
(
currentPage
,
pageCount
)
{
return
{
text
:
currentPage
.
toString
()
+
' of '
+
pageCount
.
toString
(),
style
:
'footerStyle'
};
},
exporterPdfCustomFormatter
:
function
(
docDefinition
)
{
docDefinition
.
styles
.
headerStyle
=
{
fontSize
:
22
,
bold
:
true
};
docDefinition
.
styles
.
footerStyle
=
{
fontSize
:
10
,
bold
:
true
};
return
docDefinition
;
},
exporterPdfOrientation
:
'portrait'
,
exporterPdfPageSize
:
'LETTER'
,
exporterPdfMaxGridWidth
:
500
,
exporterCsvLinkElement
:
angular
.
element
(
document
.
querySelectorAll
(
".custom-csv-link-location"
)),
onRegisterApi
:
function
(
gridApi
){
$scope
.
gridApi
=
gridApi
;
},
gridMenuCustomItems
:
[{
title
:
'Export all data as EXCEL'
,
action
:
function
(
$event
)
{
exportUiGridService
.
exportToExcel
(
'sheet 1'
,
$scope
.
gridApi
,
'all'
,
'all'
);
},
order
:
110
},
{
title
:
'Export visible data as EXCEL'
,
action
:
function
(
$event
)
{
exportUiGridService
.
exportToExcel
(
'sheet 1'
,
$scope
.
gridApi
,
'visible'
,
'visible'
);
},
order
:
111
}
]
};
$scope
.
gridOptions
.
data
=
[];
/* $scope.getEmployeeEffortsData = function(){
var fromDate = getFormattedDate($scope.fromDate);
var toDate = getFormattedDate($scope.toDate);
$http({
method : "GET",
url : appConfig.appUri + "employeeEfforts/getWeeklyReport?fromDate=" + fromDate + "&toDate=" +toDate
}).then(function mySuccess(response) {
$scope.gridOptions.data = response.data;
if(response.data.length > 10){
$scope.gridOptions.enablePaginationControls = true;
}
else{
$scope.gridOptions.enablePaginationControls = false;
}
}, function myError(response) {
showAlert("Something went wrong while fetching data!!!");
$scope.gridOptions.data = [];
});
}*/
function
showAlert
(
message
)
{
$mdDialog
.
show
(
$mdDialog
.
alert
().
parent
(
angular
.
element
(
document
.
querySelector
(
'#popupContainer'
)))
.
clickOutsideToClose
(
true
).
textContent
(
message
).
ariaLabel
(
'Alert Dialog'
).
ok
(
'Ok'
));
}
});
src/main/webapp/WEB-INF/controllers/ChartsController.js
View file @
f68830f6
...
...
@@ -3,13 +3,13 @@ myApp.directive('hcPieChart', function () {
restrict
:
'E'
,
template
:
'<div></div>'
,
link
:
function
(
scope
,
element
)
{
getEmployeeDetails
(
scope
,
element
[
0
].
baseURI
+
'reports/
getEmployeesByFunctionalGroup'
,
'pie'
,
element
,
"Employees Overview Report
"
);
getEmployeeDetails
(
scope
,
element
[
0
].
baseURI
+
'reports/
billabilityByFunctionalGroup'
,
'column'
,
element
,
"Billability By Functional Group
"
);
//getEmployeeDetails(scope,element[0].baseURI+'reports/getBillabilityDetailsByAccount','column',element,"Billability By Account");
scope
.
clickMe
=
function
()
{
if
(
scope
.
reportId
==
1
){
getEmployeeDetails
(
scope
,
element
[
0
].
baseURI
+
'reports/getBillabilityDetailsByAccount'
,
'column'
,
element
,
" Billability By Account"
);
}
else
if
(
scope
.
reportId
==
2
){
getEmployeeDetails
(
scope
,
element
[
0
].
baseURI
+
'reports/
getEmployeesByFunctionalGroup'
,
'pie'
,
element
,
"Employees Overview Report
"
);
getEmployeeDetails
(
scope
,
element
[
0
].
baseURI
+
'reports/
billabilityByFunctionalGroup'
,
'column'
,
element
,
"Billability By Functional Group
"
);
}
else
if
(
scope
.
reportId
==
3
){
getEmployeeDetails
(
scope
,
element
[
0
].
baseURI
+
'reports/getBillabilityDetailsByMonth'
,
'line'
,
element
,
" Billability Monthly Trends"
);
}
...
...
@@ -24,7 +24,7 @@ myApp.directive('hcPieChart', function () {
//$scope.reportId = "1"
$scope
.
reportId
=
"2"
$scope
.
reports
=
$scope
.
reportId
;
$scope
.
reports
=
[
/*{Name:"Billability Report",Id:"1"},*/
{
Name
:
"
Employees
By Functional Group"
,
Id
:
"2"
},{
Name
:
"Billability Monthly Trends"
,
Id
:
"3"
}];
$scope
.
reports
=
[
/*{Name:"Billability Report",Id:"1"},*/
{
Name
:
"
Billability
By Functional Group"
,
Id
:
"2"
},{
Name
:
"Billability Monthly Trends"
,
Id
:
"3"
}];
$scope
.
employees
=
[];
...
...
@@ -186,8 +186,10 @@ myApp.directive('hcPieChart', function () {
shadow
:
false
},
tooltip
:
{
headerFormat
:
'<b>{point.x}</b><br/>'
,
pointFormat
:
'{point.name}: {point.y}'
formatter
:
function
()
{
return
'<b>'
+
this
.
x
+
'</b><br/>'
+
(
this
.
point
.
percent
?
this
.
series
.
name
+
':'
+
this
.
point
.
y
+
' ( '
+
this
.
point
.
percent
.
toFixed
(
2
)
+
' % )'
:
this
.
series
.
name
+
':'
+
this
.
point
.
y
);
}
},
plotOptions
:
{
pie
:
{
...
...
@@ -203,6 +205,7 @@ myApp.directive('hcPieChart', function () {
},
series
:{
events
:{
click
:
function
(
event
)
{
$scope
.
getMyTeamDetails
(
event
.
point
.
series
.
name
,
event
.
point
.
category
,
event
.
point
.
options
.
name
,
title
);
}
...
...
src/main/webapp/WEB-INF/controllers/LeftMenuController.js
View file @
f68830f6
...
...
@@ -25,7 +25,10 @@ myApp.controller("leftmenuController",function($scope, myFactory, $compile){
if
(
$scope
.
menuItems
[
i
].
menu
.
indexOf
(
'Manage'
)
!==
-
1
)
{
$scope
.
manageGroup
.
push
(
$scope
.
menuItems
[
i
]);
}
else
if
(
$scope
.
menuItems
[
i
].
menu
.
indexOf
(
'Report'
)
!==
-
1
||
$scope
.
menuItems
[
i
].
menu
.
indexOf
(
'Efforts'
)
!==
-
1
||
$scope
.
menuItems
[
i
].
menu
.
indexOf
(
'Dashboard'
)
!==
-
1
)
{
else
if
(
$scope
.
menuItems
[
i
].
menu
.
indexOf
(
'Report'
)
!==
-
1
||
$scope
.
menuItems
[
i
].
menu
.
indexOf
(
'Efforts'
)
!==
-
1
||
$scope
.
menuItems
[
i
].
menu
.
indexOf
(
'Dashboard'
)
!==
-
1
||
$scope
.
menuItems
[
i
].
menu
.
indexOf
(
'Change'
)
!==
-
1
)
{
$scope
.
reportsGroup
.
push
(
$scope
.
menuItems
[
i
]);
}
else
{
...
...
src/main/webapp/WEB-INF/controllers/LoginController.js
View file @
f68830f6
...
...
@@ -264,6 +264,8 @@ myApp.controller("loginController",function($scope, myFactory, $compile, $window
menuItems
.
push
({
"menu"
:
"My Profile"
,
"icon"
:
"fa fa-address-book-o fa-2x"
,
"path"
:
"templates/profile.html"
});
menuItems
.
push
({
"menu"
:
"Import Data"
,
"icon"
:
"fa fa-upload fa-2x"
,
"path"
:
"templates/exportData.html"
});
menuItems
.
push
({
"menu"
:
"Employee Efforts"
,
"icon"
:
"fa fa-user-circle-o fa-2x"
,
"path"
:
"templates/employeeEfforts.html"
});
menuItems
.
push
({
"menu"
:
"Reserved Reports"
,
"icon"
:
"fa fa-file-pdf-o fa-2x"
,
"path"
:
"templates/reservedReport.html"
});
menuItems
.
push
({
"menu"
:
"Allocation Change"
,
"icon"
:
"fa fa-file-excel-o fa-2x"
,
"path"
:
"templates/allocationChangeReport.html"
});
}
else
if
(
role
==
"Delivery Lead"
){
//menuItems.push({"menu" : "Manage Employees","icon" : "fa fa-user-plus fa-2x","path" : "templates/roles.html"});
//menuItems.push({"menu" : "Manage Team","icon" : "fa fa-sitemap fa-2x","path" : "templates/projectDetails.html"});
...
...
@@ -300,6 +302,8 @@ myApp.controller("loginController",function($scope, myFactory, $compile, $window
menuItems
.
push
({
"menu"
:
"My Profile"
,
"icon"
:
"fa fa-address-book-o fa-2x"
,
"path"
:
"templates/profile.html"
});
menuItems
.
push
({
"menu"
:
"Import Data"
,
"icon"
:
"fa fa-upload fa-2x"
,
"path"
:
"templates/exportData.html"
});
menuItems
.
push
({
"menu"
:
"Employee Efforts "
,
"icon"
:
"fa fa-user-circle-o fa-2x"
,
"path"
:
"templates/employeeEfforts.html"
});
menuItems
.
push
({
"menu"
:
"Reserved Reports"
,
"icon"
:
"fa fa-file-pdf-o fa-2x"
,
"path"
:
"templates/reservedReport.html"
});
menuItems
.
push
({
"menu"
:
"Allocation Change"
,
"icon"
:
"fa fa-file-excel-o fa-2x"
,
"path"
:
"templates/allocationChangeReport.html"
});
}
else
if
(
role
==
"Lead"
){
menuItems
.
push
({
"menu"
:
"My Team"
,
"icon"
:
"fa fa-futbol-o fa-2x"
,
"path"
:
"templates/myTeam.html"
});
menuItems
.
push
({
"menu"
:
"Reportee Login Details"
,
"icon"
:
"fa fa-users fa-2x"
,
"path"
:
"templates/reportees.html"
});
...
...
@@ -329,6 +333,8 @@ myApp.controller("loginController",function($scope, myFactory, $compile, $window
menuItems
.
push
({
"menu"
:
"My Org"
,
"icon"
:
"fa fa-address-card-o fa-2x"
,
"path"
:
"templates/myOrg.html"
});
menuItems
.
push
({
"menu"
:
"My Profile"
,
"icon"
:
"fa fa-address-book-o fa-2x"
,
"path"
:
"templates/profile.html"
});
menuItems
.
push
({
"menu"
:
"Employee Efforts"
,
"icon"
:
"fa fa-user-circle-o fa-2x"
,
"path"
:
"templates/employeeEfforts.html"
});
menuItems
.
push
({
"menu"
:
"Reserved Reports"
,
"icon"
:
"fa fa-file-pdf-o fa-2x"
,
"path"
:
"templates/reservedReport.html"
});
menuItems
.
push
({
"menu"
:
"Allocation Change"
,
"icon"
:
"fa fa-file-excel-o fa-2x"
,
"path"
:
"templates/allocationChangeReport.html"
});
}
else
{
menuItems
.
push
({
"menu"
:
"My Team"
,
"icon"
:
"fa fa-futbol-o fa-2x"
,
"path"
:
"templates/myTeam.html"
});
menuItems
.
push
({
"menu"
:
"My Project Allocations"
,
"icon"
:
"fa fa-life-ring fa-2x"
,
"path"
:
"templates/myProjectAllocations.html"
});
...
...
src/main/webapp/WEB-INF/controllers/ReservedReportController.js
0 → 100644
View file @
f68830f6
myApp
.
controller
(
"reservedReportsController"
,
function
(
$scope
,
exportUiGridService
,
myFactory
,
$mdDialog
,
$http
,
appConfig
,
$timeout
,
$element
,
$window
){
$scope
.
records
=
[];
$scope
.
gridOptions
=
{
paginationPageSizes
:
[
10
,
20
,
30
,
40
,
50
,
100
],
paginationPageSize
:
10
,
pageNumber
:
1
,
pageSize
:
10
,
enableFiltering
:
true
,
columnDefs
:
[
{
field
:
'employeeId'
,
displayName
:
'Employee Id'
,
enableColumnMenu
:
false
,
enableSorting
:
false
,
enableFiltering
:
true
},
{
field
:
'employeeName'
,
displayName
:
'Employee Name'
,
enableColumnMenu
:
false
,
enableSorting
:
true
,
enableFiltering
:
true
,
cellClass
:
function
(
grid
,
row
,
col
){
if
(
daysBetween
(
row
.
entity
.
reservedStartDate
,
row
.
entity
.
reservedEndDate
)
>
'14'
)
{
return
'red'
;
}
}},
{
name
:
'accountName'
,
displayName
:
'Client'
,
enableColumnMenu
:
false
,
enableSorting
:
false
,
enableFiltering
:
false
},
{
field
:
'projectName'
,
displayName
:
'Project Name'
,
enableColumnMenu
:
false
,
enableSorting
:
true
,
enableFiltering
:
true
},
{
name
:
'reservedStartDate'
,
displayName
:
'Reserved Start Date'
,
enableColumnMenu
:
false
,
cellFilter
:
'date:"dd-MMM-yyyy"'
,
enableSorting
:
false
,
enableFiltering
:
false
},
{
name
:
'reservedEndDate'
,
displayName
:
'Reserved End Date'
,
enableColumnMenu
:
false
,
cellFilter
:
'date:"dd-MMM-yyyy"'
,
enableSorting
:
false
,
enableFiltering
:
false
}
],
enableGridMenu
:
true
,
enableSelectAll
:
true
,
exporterMenuExcel
:
false
,
exporterMenuCsv
:
false
,
exporterCsvFilename
:
'ReservedReport.csv'
,
exporterExcelFilename
:
'ReservedReport'
,
exporterPdfDefaultStyle
:
{
fontSize
:
9
},
exporterPdfTableStyle
:
{
margin
:
[
15
,
15
,
15
,
15
]},
exporterPdfTableHeaderStyle
:
{
fontSize
:
10
,
bold
:
true
,
italics
:
true
,
color
:
'red'
},
exporterPdfHeader
:
{
text
:
"Reserved Report"
,
style
:
'headerStyle'
},
exporterPdfFooter
:
function
(
currentPage
,
pageCount
)
{
return
{
text
:
currentPage
.
toString
()
+
' of '
+
pageCount
.
toString
(),
style
:
'footerStyle'
};
},
exporterPdfCustomFormatter
:
function
(
docDefinition
)
{
docDefinition
.
styles
.
headerStyle
=
{
fontSize
:
22
,
bold
:
true
};
docDefinition
.
styles
.
footerStyle
=
{
fontSize
:
10
,
bold
:
true
};
return
docDefinition
;
},
exporterPdfOrientation
:
'portrait'
,
exporterPdfPageSize
:
'LETTER'
,
exporterPdfMaxGridWidth
:
500
,
exporterCsvLinkElement
:
angular
.
element
(
document
.
querySelectorAll
(
".custom-csv-link-location"
)),
onRegisterApi
:
function
(
gridApi
){
$scope
.
gridApi
=
gridApi
;
},
gridMenuCustomItems
:
[{
title
:
'Export all data as EXCEL'
,
action
:
function
(
$event
)
{
exportUiGridService
.
exportToExcel
(
'sheet 1'
,
$scope
.
gridApi
,
'all'
,
'all'
);
},
order
:
110
},
{
title
:
'Export visible data as EXCEL'
,
action
:
function
(
$event
)
{
exportUiGridService
.
exportToExcel
(
'sheet 1'
,
$scope
.
gridApi
,
'visible'
,
'visible'
);
},
order
:
111
}
]
};
$scope
.
gridOptions
.
data
=
[{
employeeId
:
"16727"
,
employeeName
:
"Prayas"
,
accountName
:
'Nisum India'
,
projectName
:
'Bench'
,
reservedStartDate
:
1559563534000
,
reservedEndDate
:
1559996723000
},{
employeeId
:
"16728"
,
employeeName
:
"Abhijeet"
,
accountName
:
'Macys'
,
projectName
:
'MyProject'
,
reservedStartDate
:
1559563534000
,
reservedEndDate
:
1560860723000
}];
/* $scope.getReservedEnployeesData = function(){
$http({
method : "GET",
url : appConfig.appUri + "employeeEfforts/getWeeklyReport?fromDate=" + fromDate + "&toDate=" +toDate
}).then(function mySuccess(response) {
$scope.gridOptions.data = response.data;
if(response.data.length > 10){
$scope.gridOptions.enablePaginationControls = true;
}
else{
$scope.gridOptions.enablePaginationControls = false;
}
}, function myError(response) {
showAlert("Something went wrong while fetching data!!!");
$scope.gridOptions.data = [];
});
}*/
function
showAlert
(
message
)
{
$mdDialog
.
show
(
$mdDialog
.
alert
().
parent
(
angular
.
element
(
document
.
querySelector
(
'#popupContainer'
)))
.
clickOutsideToClose
(
true
).
textContent
(
message
).
ariaLabel
(
'Alert Dialog'
).
ok
(
'Ok'
));
}
function
treatAsUTC
(
date
)
{
var
result
=
new
Date
(
date
);
result
.
setMinutes
(
result
.
getMinutes
()
-
result
.
getTimezoneOffset
());
return
result
;
}
function
daysBetween
(
fromDate
,
toDate
)
{
var
millisecondsPerDay
=
24
*
60
*
60
*
1000
;
return
Math
.
round
((
treatAsUTC
(
toDate
)
-
treatAsUTC
(
fromDate
))
/
millisecondsPerDay
);
}
});
\ No newline at end of file
src/main/webapp/WEB-INF/css/custom-theme.css
View file @
f68830f6
...
...
@@ -182,7 +182,7 @@ i.fa.fa-refresh:hover {
background
:
transparent
;
}
#sidebar-wrapper
.sidebar-nav
li
ul
.reportsGroup
{
max-height
:
2
07
px
;
max-height
:
2
91
px
;
height
:
auto
;
overflow
:
hidden
;
padding
:
0
;
...
...
@@ -254,7 +254,7 @@ i.fa.fa-refresh:hover {
display
:
flex
;
/* height: calc(100% - 105px); need to test and enable*/
overflow
:
hidden
;
height
:
100%
;
height
:
calc
(
100%
-
102px
)
;
}
/* .main-container #sidebar-left, .main-container #main {
flex: 1;
...
...
@@ -328,6 +328,7 @@ i.fa.fa-refresh:hover {
/* ===== Footer Styles ===== */
#footer
{
clear
:
both
;
height
:
40px
;
}
#footer
.navbar-inverse
,
#footer
.navbar-inverse
{
background
:
#eeeef6
;
...
...
@@ -577,7 +578,7 @@ top: 22px;
font-weight
:
bold
;
}
.violet
{
background-color
:
violet
!important
;
background-color
:
#ab0a0a
!important
;
color
:
white
;
font-weight
:
bold
;
}
...
...
src/main/webapp/WEB-INF/templates/allocationChangeReport.html
0 → 100644
View file @
f68830f6
<div
class=
"md-padding"
id=
"popupContainer"
ng-controller=
"allocationChangeReportController"
>
<div
class=
"container-fluid mainDivHeaderClass"
>
<div
class=
"row"
>
<div
class=
"col-lg-12"
>
<h1
class=
"no-padding"
>
Allocation Change Details
<span
class=
"right"
>
<i
class=
"fa fa-refresh"
aria-hidden=
"true"
ng-click=
"refreshPage()"
></i>
</span>
</h1>
</div>
<div
class=
"clearfix"
></div>
</div>
</div>
<div
class=
"form-horizontal"
>
<div
class=
"form-group"
>
<div
class=
"form-inline col-lg-12"
>
<div
id=
"gridTest"
ui-grid=
"gridOptions"
ui-grid-pagination
ui-grid-exporter
class=
"mygrid manage-employee-efforts"
>
<div
class=
"watermark"
ng-show=
"!gridOptions.data.length"
>
No
data available
</div>
</div>
</div>
</div>
</div>
</div>
\ No newline at end of file
src/main/webapp/WEB-INF/templates/index.html
View file @
f68830f6
...
...
@@ -82,6 +82,9 @@
<script
src=
"controllers/ChartsController.js"
></script>
<script
src=
"controllers/TestController2.js"
></script>
<script
src=
"controllers/DomainController.js"
></script>
<script
src=
"controllers/ReservedReportController.js"
></script>
<script
src=
"controllers/AllocationChangeController.js"
></script>
</head>
<body>
<ng-include
src=
"'templates/login.html'"
id=
"home"
></ng-include>
...
...
src/main/webapp/WEB-INF/templates/reservedReport.html
0 → 100644
View file @
f68830f6
<div
class=
"md-padding"
id=
"popupContainer"
ng-controller=
"reservedReportsController"
ng-init=
"getReservedEnployeesData()"
>
<div
class=
"container-fluid mainDivHeaderClass"
>
<div
class=
"row"
>
<div
class=
"col-lg-12"
>
<h1
class=
"no-padding"
>
Reserved Reports
<span
class=
"right"
>
<i
class=
"fa fa-refresh"
aria-hidden=
"true"
ng-click=
"refreshPage()"
></i>
</span>
</h1>
</div>
<div
class=
"clearfix"
></div>
</div>
</div>
<div
class=
"row col-lg-12"
>
<div
class=
"col-lg-4"
style=
"float: left;padding-left:20px;"
>
<!-- <md-button class="md-raised md-primary"
style="width:182px;background: cadetblue;"
ng-click="getUnAssignedEmployees('UnAssigned', parentData)"> <i
class="fa fa-crosshairs fa-2x"
style="margin-top: 5px; font-size: 1.5em; float: left"></i>Bench Employees</md-button> -->
</div>
<div
class=
"col-lg-4"
style=
"float: left;padding-left:20px;"
>
<!-- <md-button class="md-raised md-primary"
style="width:182px;background: cadetblue;"
ng-click="getAllocatedEmployees('allocated', parentData)"> <i
class="fa fa-product-hunt fa-2x"
style="margin-top: 5px; font-size: 1.5em; float: left"></i>Project Allocations</md-button> -->
</div>
<div
class=
"col-lg-1"
style=
"cursor: pointer; float: right; right: 75px;"
>
<!-- <md-button class="md-raised md-primary"
style="width:142px;background: cadetblue;"
ng-click="addProject('Assign', parentData)"> <i
class="fa fa-plus-circle fa-2x"
style="margin-top: 5px; font-size: 1.5em; float: left"></i> Add
Project</md-button> -->
</div>
</div>
<div
class=
"row"
>
<div
class=
"col-lg-12"
>
<div
id=
"gridTest"
ui-grid=
"gridOptions"
ui-grid-pagination
ui-grid-exporter
class=
"myGrid grid-full-view"
>
<div
class=
"watermark"
ng-show=
"!gridOptions.data.length"
>
No
data available
</div>
</div>
</div>
</div>
</div>
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment