![]() |
|
|
|||||||
| Register | FAQ | Top Posters | Members List | Calendar | Search | Today's Posts | Resend Activation Email | Mark Forums Read |
| dotProject Documentation | dotProject FAQ | Bugs & Feature Requests | Language Packs & Themes | Download dotProject |
| Permissions Because the permissions system is the biggest change in 2.x we have created a special forum for discussing items. |
![]() |
|
|
Thread Tools | Display Modes |
|
#21
|
|||
|
|||
|
I used Mohamed's code snippet, too, for that annoying limitation with employees being able to edit the actual Task,
when I only wanted them to be able to add Task Logs (that was a real problem for me). The code worked great and it's the first time I've 'customized' the dotProject code myself. Thanks so much for posting that, Mohamed! Keep it coming! |
|
#22
|
|||
|
|||
|
Hi friends,
I did some changes in code to solve this problem, its working for me but it is not properly tested. File name:- modules/tasks/view.php Changes:- 1. There is one JavaScript function "updateTask()" above that there is one php if condition like: if ($canEdit) { change it to: // Allow add task_logs $canEdit_taskLog = getPermission('task_log', 'edit', $task_id); if ($canEdit || $canEdit_taskLog) { 2. At the bottom of file there is one block oh php code, in that there is on if condition similar to:- // fixed bug that dP automatically ...... if ($perms->checkModuleItem('tasks', 'edit', $task_id)) { Changes: comment out this "if" condition but don't comment code inside if condetion. Note:- don't forget to comment ending braces of if condetion Now in second file- File: modules/tasks/vw_log_update.php 1. In starting of file you can find code like:- if (!$perms->checkModuleItem('tasks', 'edit', $task_id)) { changes:- comment this line add code if (!$perms->checkModuleItem('task_log', 'edit', $task_id)) { In short change first parameter of function "tasks" to "task_log". Note:-Please take backup of files before applying changes. |
|
#23
|
|||
|
|||
|
Quote:
Thanks a lot, this helped for me. |
|
#24
|
|||
|
|||
|
Just an update:
I implemented the patch proposed by prabhatmaurya. Apparently, in DotProject 2.1.3, only the first modification is needed (the creation and test of variable $CanEdit_taskLog) |
![]() |
| Thread Tools | |
| Display Modes | |
|
|