Moved Timesheet Lines List page from 'Reports' menu section to 'Cost'
Permissions for default profiles were also updated accordingly. FEA: ItEr76S04BugFixing
This commit is contained in:
parent
99ef05a2d4
commit
0d0c4c8fbd
4 changed files with 9 additions and 10 deletions
|
|
@ -49,7 +49,7 @@ import static org.libreplan.business.users.entities.UserRole.ROLE_TASK_SCHEDULIN
|
|||
import static org.libreplan.business.users.entities.UserRole.ROLE_TEMPLATES;
|
||||
import static org.libreplan.business.users.entities.UserRole.ROLE_TIMESHEETS;
|
||||
import static org.libreplan.business.users.entities.UserRole.ROLE_TIMESHEETS_TEMPLATES;
|
||||
import static org.libreplan.business.users.entities.UserRole.ROLE_TIMESHEET_LINES_LIST_REPORT;
|
||||
import static org.libreplan.business.users.entities.UserRole.ROLE_TIMESHEET_LINES_LIST;
|
||||
import static org.libreplan.business.users.entities.UserRole.ROLE_TOTAL_WORKED_HOURS_BY_RESOURCE_IN_A_MONTH_REPORT;
|
||||
import static org.libreplan.business.users.entities.UserRole.ROLE_USER_ACCOUNTS;
|
||||
import static org.libreplan.business.users.entities.UserRole.ROLE_VIRTUAL_WORKERS;
|
||||
|
|
@ -96,7 +96,7 @@ public enum PredefinedProfiles {
|
|||
TIME_TRACKING_AND_EXPENSES_RESPONSIBLE(
|
||||
"Time Tracking & Expenses Responsible", ROLE_TIMESHEETS,
|
||||
ROLE_TIMESHEETS_TEMPLATES, ROLE_EXPENSES, ROLE_HOURS_TYPES,
|
||||
ROLE_TIMESHEET_LINES_LIST_REPORT,
|
||||
ROLE_TIMESHEET_LINES_LIST,
|
||||
ROLE_HOURS_WORKED_PER_RESOURCE_REPORT,
|
||||
ROLE_TOTAL_WORKED_HOURS_BY_RESOURCE_IN_A_MONTH_REPORT),
|
||||
|
||||
|
|
@ -105,7 +105,6 @@ public enum PredefinedProfiles {
|
|||
ROLE_SEND_TO_CUSTOMERS, ROLE_RECEIVED_FROM_CUSTOMERS),
|
||||
|
||||
REPORTS_RESPONSIBLE("Reports Responsible", ROLE_READ_ALL_PROJECTS,
|
||||
ROLE_TIMESHEET_LINES_LIST_REPORT,
|
||||
ROLE_HOURS_WORKED_PER_RESOURCE_REPORT,
|
||||
ROLE_TOTAL_WORKED_HOURS_BY_RESOURCE_IN_A_MONTH_REPORT,
|
||||
ROLE_WORK_AND_PROGRESS_PER_PROJECT_REPORT,
|
||||
|
|
|
|||
|
|
@ -70,7 +70,7 @@ public enum UserRole {
|
|||
ROLE_RECEIVED_FROM_SUBCONTRACTORS(_("Received From Subcontractors")),
|
||||
ROLE_SEND_TO_CUSTOMERS(_("Send To Customers")),
|
||||
ROLE_RECEIVED_FROM_CUSTOMERS(_("Received From Customers")),
|
||||
ROLE_TIMESHEET_LINES_LIST_REPORT(_("Timesheet Lines List Report")),
|
||||
ROLE_TIMESHEET_LINES_LIST(_("Timesheet Lines List")),
|
||||
ROLE_HOURS_WORKED_PER_RESOURCE_REPORT(_("Hours Worked Per Resource Report")),
|
||||
ROLE_TOTAL_WORKED_HOURS_BY_RESOURCE_IN_A_MONTH_REPORT(_("Total Worked Hours By Resource In A Month Report")),
|
||||
ROLE_WORK_AND_PROGRESS_PER_PROJECT_REPORT(_("Work And Progress Per Project Report")),
|
||||
|
|
|
|||
|
|
@ -366,6 +366,11 @@ public class CustomMenuController extends Div implements IMenuItemsRegister {
|
|||
costItems.add(subItem(_("Timesheets Templates"),
|
||||
"/workreports/workReportTypes.zul", "09-partes.html#id2"));
|
||||
}
|
||||
if (SecurityUtils
|
||||
.isSuperuserOrUserInRoles(UserRole.ROLE_TIMESHEET_LINES_LIST)) {
|
||||
costItems.add(subItem(_("Timesheet Lines List"),
|
||||
"/workreports/workReportQuery.zul", "09-partes.html#id4"));
|
||||
}
|
||||
if (SecurityUtils.isSuperuserOrUserInRoles(UserRole.ROLE_EXPENSES)) {
|
||||
costItems.add(subItem(_("Expenses"),
|
||||
"/expensesheet/expenseSheet.zul", ""));
|
||||
|
|
@ -439,11 +444,6 @@ public class CustomMenuController extends Div implements IMenuItemsRegister {
|
|||
}
|
||||
|
||||
List<CustomMenuItem> reportsItems = new ArrayList<CustomMenuItem>();
|
||||
if (SecurityUtils
|
||||
.isSuperuserOrUserInRoles(UserRole.ROLE_TIMESHEET_LINES_LIST_REPORT)) {
|
||||
reportsItems.add(subItem(_("Timesheet Lines List"),
|
||||
"/workreports/workReportQuery.zul", "09-partes.html#id4"));
|
||||
}
|
||||
if (SecurityUtils
|
||||
.isSuperuserOrUserInRoles(UserRole.ROLE_HOURS_WORKED_PER_RESOURCE_REPORT)) {
|
||||
reportsItems.add(subItem(_("Hours Worked Per Resource"),
|
||||
|
|
|
|||
|
|
@ -96,7 +96,7 @@
|
|||
<intercept-url pattern="/subcontract/customerCommunications.zul"
|
||||
access="ROLE_SUPERUSER,ROLE_RECEIVED_FROM_CUSTOMERS" />
|
||||
<intercept-url pattern="/workreports/workReportQuery.zul"
|
||||
access="ROLE_SUPERUSER,ROLE_TIMESHEET_LINES_LIST_REPORT" />
|
||||
access="ROLE_SUPERUSER,ROLE_TIMESHEET_LINES_LIST" />
|
||||
<intercept-url pattern="/reports/hoursWorkedPerWorkerReport.zul"
|
||||
access="ROLE_SUPERUSER,ROLE_HOURS_WORKED_PER_RESOURCE_REPORT" />
|
||||
<intercept-url pattern="/reports/hoursWorkedPerWorkerInAMonthReport.zul"
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue