Exemple #1
0
                ?>
)</li>
<?php 
            } else {
                ?>
    <li><a href="<?php 
                echo $upcoming_milestone->getViewUrl();
                ?>
"><?php 
                echo clean($upcoming_milestone->getName());
                ?>
</a> (<?php 
                echo format_descriptive_date($upcoming_milestone->getDueDate());
                ?>
 - <?php 
                echo format_days('days left', $upcoming_milestone->getLeftInDays());
                ?>
)</li>
<?php 
            }
            // if
            ?>

<?php 
        } else {
            ?>
    </ul>
    <p><a href="<?php 
            echo active_project()->getMilestonesUrl();
            ?>
#upcomingMilestones"> <?php 
"><?php 
                    echo clean($assigned_milestone->getName());
                    ?>
</a> - 
<?php 
                    if ($assigned_milestone->isUpcoming()) {
                        ?>
            <span><?php 
                        echo format_days('days left', $assigned_milestone->getLeftInDays());
                        ?>
</span>
<?php 
                    } elseif ($assigned_milestone->isLate()) {
                        ?>
            <span class="error"><?php 
                        echo format_days('days late', $assigned_milestone->getLateInDays());
                        ?>
</span>
<?php 
                    } elseif ($assigned_milestone->isToday()) {
                        ?>
            <span><?php 
                        echo lang('today');
                        ?>
</span>
<?php 
                    }
                    // if
                    ?>
          <td class="milestoneCheckbox"><?php 
                    echo checkbox_link($assigned_milestone->getCompleteUrl(), false);
Exemple #3
0
<?php foreach ($assigned_milestones as $assigned_milestone) { ?>
        <tr>
          <td class="milestoneText">
<?php $assigned_to = $assigned_milestone->getAssignedTo() ?>
<?php if ($assigned_to instanceof Company) { ?>
            <span class="assignedTo"><?php echo clean($assigned_to->getName()) ?> | </span> 
<?php } elseif ($assigned_to instanceof User) { ?>
            <span class="assignedTo"><?php echo clean($assigned_to->getDisplayName()) ?> | </span> 
<?php } else { ?>
            <span class="assignedTo"><?php echo lang('anyone') ?> | </span> 
<?php } // if ?>
            <a href="<?php echo $assigned_milestone->getViewUrl() ?>"><?php echo clean($assigned_milestone->getName()) ?></a> - 
<?php if ($assigned_milestone->isUpcoming()) { ?>
            <span><?php echo format_days('days left', $assigned_milestone->getLeftInDays()) ?></span>
<?php } elseif ($assigned_milestone->isLate()) { ?>
            <span class="error"><?php echo format_days('days late', $assigned_milestone->getLateInDays()) ?></span>
<?php } elseif ($assigned_milestone->isToday()) { ?>
            <span><?php echo lang('today') ?></span>
<?php } // if ?>
          <td class="milestoneCheckbox"><?php echo checkbox_link($assigned_milestone->getCompleteUrl(), false) ?></td>
          </td>
        </tr>
<?php } // foreach?>
      </table>
<?php } // if ?>

<?php if (is_array($assigned_tasks) && count($assigned_tasks)) { ?>
      <p><a href="<?php echo $active_project->getTasksUrl() ?>"><?php echo lang('tasks') ?></a>:</p>
      <table class="blank">
<?php foreach ($assigned_tasks as $assigned_task) { ?>
        <tr>
Exemple #4
0
                echo $milestone->getViewUrl();
                ?>
"><?php 
                echo clean($milestone->getName());
                ?>
</a> <?php 
                echo $lc_in;
                ?>
 <a href="<?php 
                echo $milestone->getProject()->getOverviewUrl();
                ?>
"><?php 
                echo clean($milestone->getProject()->getName());
                ?>
</a> (<?php 
                echo format_days('days late', $milestone->getLateInDays());
                ?>
)</li>
<?php 
            }
            // if
        }
        // foreach
        ?>
  </ul>
<?php 
    }
    // if
    ?>

<?php 
        $condition .= " and assigned_to_user_id = " . $user->getId();
    }
    $condition .= " and completed_on is null";
    $condition .= " and due_date < Interval " . $settings->getRemindersFuture() . " day + now()";
    $tasks = ProjectTasks::findAll(array('conditions' => $condition));
    foreach ($tasks as $task) {
        echo "<li>";
        echo "<a href='" . str_replace('&amp;', '&', externalUrl($task->getViewUrl())) . "'>";
        echo $task->getText();
        echo "</a> ";
        if ($settings->getIncludeEveryone() && $task->getAssignedTo() && $task->getAssignedTo()->getObjectName() != $user->getObjectName()) {
            echo " - <i>assigned to " . $task->getAssignedTo()->getObjectName() . "</i> - ";
        } else {
            if (!$task->getAssignedTo()) {
                echo " - <i>assigned to anyone</i> - ";
            }
        }
        if ($task->getDueDate()->isUpcoming()) {
            echo format_days('is future', $task->getDueDate()->getLeftInDays());
        } elseif ($task->getDueDate()->isToday()) {
            echo "<b>" . lang('is today') . "</b>";
        } else {
            echo "<font color=red>" . format_days('is late', $task->getDueDate()->getLeftInDays()) . "</font>";
        }
        echo "</li>\n";
    }
    ?>
</ol>
<hr>
<?php 
}