Overall refactoring of projectDisplay.js from the Project Management asset.
Hopefully this will make it much easier to deal with later, and hopefully this will help to flush out the remaining duration-calculation-related bugs by avoiding repetition of the calculations. Various minor fixes in the process. I'm not convinced this is completely bug-free yet, of course, but it does seem at least to be slightly less broken than before, so.
This commit is contained in:
parent
01bfe673ae
commit
6516062d4d
5 changed files with 621 additions and 284 deletions
|
|
@ -3,7 +3,8 @@
|
|||
- fix: adding Matrix listings committing the current version tag
|
||||
- fix: user searches in task resource additions in PM not displaying right without both last name and first name present
|
||||
- fix: task editor in PM not actually receiving start/end date information at first
|
||||
- fix: Error Displaying Multiple TimeTracking Wobjects (ekennedy)
|
||||
- fix: Error Displaying Multiple TimeTracking Wobjects (ekennedy)
|
||||
- refactoring of PM JavaScript stuff
|
||||
|
||||
7.0.9
|
||||
- Removed the need for DateTime::Cron::Simple, which also added the ability
|
||||
|
|
|
|||
91
docs/upgrades/templates-7.0.10/default-pm-edit-task.tmpl
Normal file
91
docs/upgrades/templates-7.0.10/default-pm-edit-task.tmpl
Normal file
|
|
@ -0,0 +1,91 @@
|
|||
#ProjectManagerTMPL0004
|
||||
|
||||
<tmpl_var form.header><tmpl_var form.seqNum>
|
||||
<table class="popUp" cellspacing="0" cellpadding="3" border="0">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td align="right" style="width:25%;" class="header">Task Name </td>
|
||||
<td style="width:75%;"><tmpl_var form.name></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">
|
||||
<table width="100%" cellpadding="3" cellspacing="0">
|
||||
<tbody>
|
||||
<tr class="clear">
|
||||
<td style="width:25%;" align="right" class="header">Start </td>
|
||||
<td style="width:25%;"><tmpl_var form.start></td>
|
||||
<td style="width:25%;" align="right" class="header">Finish </td>
|
||||
<td style="width:25%;"><tmpl_var form.end></td>
|
||||
</tr><tr class="clear">
|
||||
<td style="width:100%; text-align: center" colspan="4" class="header"><tmpl_var form.taskType></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">
|
||||
<table width="100%" cellpadding="3" cellspacing="0">
|
||||
<tbody>
|
||||
<tr class="clear">
|
||||
<td style="width:25%; text-align:right" class="header">Duration </td>
|
||||
<td style="width:25%;"><tmpl_var form.duration> <tmpl_var form.duration.units></td>
|
||||
<td style="width:25%; text-align:right" class="header">Lag Time </td>
|
||||
<td style="width:25%;"><tmpl_var form.lagTime> <tmpl_var form.lagTime.units></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="2">
|
||||
<table width="100%" cellpadding="3" cellspacing="0">
|
||||
<tbody>
|
||||
<tr class="clear">
|
||||
<td style="width:25%;" align="right" class="header">Predecessor </td>
|
||||
<td style="width:25%;"><tmpl_var form.dependants></td>
|
||||
<td style="width:25%;" align="right" class="header">% Complete </td>
|
||||
<td style="width:25%;"><tmpl_var form.percentComplete></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td colspan="2">
|
||||
<table width="100%" cellpadding="3" cellspacing="0">
|
||||
<tbody>
|
||||
<tr class="clearNoBG" style="text-align:center;">
|
||||
<td style="text-align:left;">
|
||||
<span class="header">Resources:</span><br /><br />
|
||||
<span style="margin-bottom:2px;padding-bottom:2px;padding-left:5px;-moz-box-sizing:border-box;display:block;">
|
||||
<a style="text-decoration:none;" id="<tmpl_var form.addUser.id>" href="<tmpl_var form.addUser.link>" target="_new" onclick="taskEdit_searchPopup(this.href); return false;"><img style="border-style:none;vertical-align:middle;" title="<tmpl_var form.addUser.text>" alt="<tmpl_var form.addUser.text>" src="<tmpl_var assetExtras>/users.gif" /><span style="text-decoration:none;font-size:8pt;"> Add User To Task</span></a>
|
||||
<a style="text-decoration:none;" id="<tmpl_var form.addGroup.id>" href="<tmpl_var form.addGroup.link>" target="_new" onclick="taskEdit_searchPopup(this.href); return false;"><img style="border-style:none;vertical-align:middle;" title="<tmpl_var form.addGroup.text>" alt="<tmpl_var form.addGroup.text>" src="<tmpl_var assetExtras>/groups.gif" /><span style="text-decoration:none;font-size:8pt;"> Add Group to Task</span></a>
|
||||
</span><tmpl_var form.resourceDiv>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align:right;" class="header"><a href="javascript:void(checkEditTaskForm(document.editTaskForm))" class="saveBtn">Save</a></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
<tmpl_var form.footer>
|
||||
|
||||
~~~
|
||||
|
||||
<style type="text/css">
|
||||
.PM_small {
|
||||
font-size:8pt;
|
||||
}
|
||||
tr.clearNoBG a {
|
||||
text-decoration:none;
|
||||
color:navy;
|
||||
}
|
||||
</style>
|
||||
275
docs/upgrades/templates-7.0.10/default-pm-project-display.tmpl
Normal file
275
docs/upgrades/templates-7.0.10/default-pm-project-display.tmpl
Normal file
|
|
@ -0,0 +1,275 @@
|
|||
#ProjectManagerTMPL0002
|
||||
|
||||
<script type="text/javascript">
|
||||
//<![CDATA[
|
||||
dunits = "<tmpl_var project.durationUnits>";
|
||||
hoursPerDay = <tmpl_var project.hoursPerDay>;
|
||||
taskLength = <tmpl_var project.task.length>;
|
||||
extrasPath = '<tmpl_var extras>';
|
||||
errorMsgs = {
|
||||
'name' : "<tmpl_var form.name.error>",
|
||||
'start' : "<tmpl_var form.start.error>",
|
||||
'end' : "<tmpl_var form.end.error>",
|
||||
'greaterthan' : "<tmpl_var form.greaterthan.error>",
|
||||
'invalidMove' : "<tmpl_var form.invalidMove.error>",
|
||||
'noPredecessor' : "<tmpl_var form.noPredecessor.error>",
|
||||
'samePredecessor' : "<tmpl_var form.samePredecessor.error>",
|
||||
'previousPredecessor' : "<tmpl_var form.previousPredecessor.error>",
|
||||
'untimedPredecessor' : "<tmpl_var form.untimedPredecessor.error>"
|
||||
};
|
||||
|
||||
addEvent(window, "load", initPopUp);
|
||||
//]]>
|
||||
</script>
|
||||
<tmpl_var form.header>
|
||||
<table cellpadding="0" cellspacing="0" border="0" class="project" id="mastertable" style="width:<tmpl_var project.table.width>px;">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td style="width:20px;height:20px;"> </td>
|
||||
<td style="width:300px;" align="center">Task Name</td>
|
||||
<td style="width:70px;" align="center">Duration</td>
|
||||
<td style="width:70px;" align="center">Start</td>
|
||||
<td style="width:70px;" align="center">Finish</td>
|
||||
<td style="width:30px;" align="center">Pred</td>
|
||||
<td rowspan="<tmpl_var project.gantt.rowspan>" valign="top" id="scrolltd" style="border-style:none;width:<tmpl_var project.scroll.percentWidth>%;">
|
||||
<div class="scroller" id="gantt">
|
||||
<tmpl_var project.ganttChart>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="6"> </td>
|
||||
</tr>
|
||||
<tmpl_loop task.loop>
|
||||
<tr id="<tmpl_var task.row.id>">
|
||||
<td align="center" style="height:20px"><tmpl_var task.number></td>
|
||||
<td align="left" style="height:20px">
|
||||
<tmpl_if task.canAdd>
|
||||
<script type="text/javascript">
|
||||
//<![CDATA[
|
||||
var cMenu = new cMenu_createWithLink("id_<tmpl_var task.number>","<tmpl_var task.name>");
|
||||
cMenu.addLink("<tmpl_var task.edit.url>","<tmpl_var task.edit.label>");
|
||||
cMenu.addLink("<tmpl_var task.insertAbove.url>","<tmpl_var task.insertAbove.label>");
|
||||
cMenu.addLink("<tmpl_var task.insertBelow.url>","<tmpl_var task.insertBelow.label>");
|
||||
cMenu.addLink("<tmpl_var task.delete.url>","<tmpl_var task.delete.label>");
|
||||
cMenu.print();
|
||||
//]]>
|
||||
</script>
|
||||
<!-- <a href="<tmpl_var task.edit.url>" class="submodal-400-350"><tmpl_var task.name></a> -->
|
||||
<tmpl_else>
|
||||
<tmpl_var task.name>
|
||||
</tmpl_if>
|
||||
</td>
|
||||
<td align="center" style="height:20px"><tmpl_var task.duration> <tmpl_var task.duration.units></td>
|
||||
<td align="center" style="height:20px"><tmpl_var task.start></td>
|
||||
<td align="center" style="height:20px"><tmpl_var task.end></td>
|
||||
<td align="center" style="height:20px"><tmpl_var task.dependants></td>
|
||||
<tmpl_var task.lagTime>
|
||||
<tmpl_var task.taskType><tmpl_var task.seqNum>
|
||||
</tr>
|
||||
</tmpl_loop>
|
||||
<tr><td colspan="6" style="border-style:none;"> </td></tr>
|
||||
<tr><td colspan="6" style="border-style:none;"> </td></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<tmpl_var form.footer>
|
||||
|
||||
<div id="links">
|
||||
<!-- <tmpl_if project.canEdit><a href="<tmpl_var task.resources.url>"><tmpl_var task.resources.label></a> | </tmpl_if> -->
|
||||
<tmpl_if task.canAdd><a href="<tmpl_var task.add.url>" class="submodal-400-300"><tmpl_var task.add.label></a> | </tmpl_if>
|
||||
<a href="<tmpl_var task.back.url>"><tmpl_var task.back.label></a>
|
||||
</div>
|
||||
|
||||
~~~
|
||||
<style type="text/css">
|
||||
body, html {
|
||||
margin:0px;
|
||||
padding:0px;
|
||||
}
|
||||
.project {
|
||||
position:relative;
|
||||
margin-top:5px;
|
||||
margin-left:5px;
|
||||
}
|
||||
.project td {
|
||||
border:solid silver 1px;
|
||||
border-bottom:solid gray 1px;
|
||||
font-size:9pt;
|
||||
font-family:arial;
|
||||
}
|
||||
.project a {
|
||||
color:#000000;
|
||||
font-weight: normal;
|
||||
font-size: 9pt;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.project a:hover {
|
||||
color:#7AB7E9;
|
||||
font-weight: normal;
|
||||
font-size: 9pt;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.taskname {
|
||||
font-family: verdana;
|
||||
font-size: 10px;
|
||||
font-weight: normal;
|
||||
color: black;
|
||||
width: 295px;
|
||||
}
|
||||
.taskduration {
|
||||
font-family: verdana;
|
||||
font-size: 10px;
|
||||
font-weight: normal;
|
||||
color: black;
|
||||
width: 25px;
|
||||
}
|
||||
.taskdate {
|
||||
font-family: verdana;
|
||||
font-size: 10px;
|
||||
font-weight: normal;
|
||||
color: black;
|
||||
width: 68px;
|
||||
}
|
||||
.taskdependant {
|
||||
font-family: verdana;
|
||||
font-size: 10px;
|
||||
font-weight: normal;
|
||||
color: black;
|
||||
width: 20px;
|
||||
}
|
||||
tr.monthNames td {
|
||||
text-align:center;
|
||||
}
|
||||
tr.dates td {
|
||||
width:16px;
|
||||
}
|
||||
div.scroller {
|
||||
overflow:scroll;
|
||||
position:relative;
|
||||
width:400px;
|
||||
}
|
||||
|
||||
* html div.scroller {
|
||||
overflow-x:scroll;
|
||||
}
|
||||
|
||||
td.empty {
|
||||
background-color:transparent;
|
||||
border-style:none;
|
||||
height:20px;
|
||||
}
|
||||
|
||||
div.barPositions {
|
||||
position:relative;
|
||||
}
|
||||
div.projectBar {
|
||||
position:absolute;
|
||||
height:10px;
|
||||
z-index:2;
|
||||
padding:0px;
|
||||
margin:0px;
|
||||
font-size:1pt;
|
||||
}
|
||||
div.statusBar {
|
||||
background-color:#000;
|
||||
position:absolute;
|
||||
height:5px;
|
||||
z-index:3;
|
||||
padding:0px;
|
||||
top:2px;
|
||||
margin:0px;
|
||||
font-size:1pt;
|
||||
}
|
||||
|
||||
div.projectLineH {
|
||||
background: url('images/dot.gif') top repeat-x;
|
||||
font-size:1pt;
|
||||
text-align:right;
|
||||
position:absolute;
|
||||
}
|
||||
div.projectLineV {
|
||||
width:1px;
|
||||
background-color:black;
|
||||
position:relative;
|
||||
font-size:1pt;
|
||||
height:100%;
|
||||
float:right;
|
||||
}
|
||||
|
||||
div.projectLabel {
|
||||
position:absolute;
|
||||
margin-top:-3px;
|
||||
white-space:nowrap;
|
||||
font-family: verdana;
|
||||
font-size:8px;
|
||||
}
|
||||
|
||||
div.milestone {
|
||||
color:#000000;
|
||||
position:absolute;
|
||||
z-index:4;
|
||||
margin:0px;
|
||||
padding:0px;
|
||||
margin-top:-3px;
|
||||
font-size: 10px;
|
||||
font-family: times;
|
||||
}
|
||||
|
||||
#links {
|
||||
margin-top:7px;
|
||||
margin-left:5px;
|
||||
font-family:arial;
|
||||
font-size:9pt;
|
||||
}
|
||||
|
||||
#links a {
|
||||
color:#7AB7E9;
|
||||
}
|
||||
</style>
|
||||
|
||||
<style>
|
||||
.popUp {
|
||||
width:100%;
|
||||
border:solid black 0px;
|
||||
background-color:#F5F5F5;
|
||||
}
|
||||
.popUp td {
|
||||
font-size:9pt;
|
||||
font-family:arial;
|
||||
border-top:solid #E0E0E0 1px;
|
||||
}
|
||||
.popUp tr.clear td {
|
||||
border-style:none;
|
||||
background-color:#F0F0F0;
|
||||
}
|
||||
.popUp tr.clearNoBG td {
|
||||
border-style:none;
|
||||
}
|
||||
.popUp td.header {
|
||||
font-weight:bold;
|
||||
}
|
||||
.popUp td span.header {
|
||||
font-weight:bold;
|
||||
}
|
||||
a.saveBtn {
|
||||
width:40px;
|
||||
height:15px;
|
||||
background-color:silver;
|
||||
padding:1px;
|
||||
padding-left:5px;
|
||||
padding-right:5px;
|
||||
color:white;
|
||||
border:solid gray 1px;
|
||||
text-decoration:none;
|
||||
font-weight:bold;
|
||||
display:block;
|
||||
float:right;
|
||||
text-align:center;
|
||||
}
|
||||
a.saveBtn:hover {
|
||||
background-color:#F0F0F0;
|
||||
color:gray;
|
||||
}
|
||||
</style>
|
||||
Loading…
Add table
Add a link
Reference in a new issue