Пример #1
0
 public static function getAllOutstandingCount($user_id)
 {
     $count = 0;
     foreach (TaskList::get($where = array('user_id' => $user_id)) as $tasklist) {
         $count += count(Task::get($where = array('list_id' => $tasklist->getId(), 'complete' => '0')));
     }
     return $count;
 }
Пример #2
0
}
?>
        
        <div class="row">
		    <div class="col-md-2">
		    <!--<a class="btn btn-default" href="#" role="button"><i class="fa fa-plus"></i> New List</a>-->
		    </div>
        </div>
        
        <hr>
        
        <div id="alert-area"></div>
        
        <?php 
$nolists = true;
$tasklist_collection = TaskList::get($where = $conditions);
foreach ($tasklist_collection as $tasklist) {
    $nolists = false;
    ?>
        	
        	<div class="col-md-4">
        	
        	<?php 
    echo '<h3><i class="fa fa-' . htmlspecialchars($tasklist->getIcon()) . '"></i>&nbsp;' . $tasklist->getName();
    if (!$viewing_single) {
        echo ' <small><a href="tasks.php?list=' . $tasklist->getId();
        if (isset($_GET['show_complete'])) {
            echo '&show_complete';
        }
        echo '">view</a></small>';
    }