예제 #1
0
                    <tr class="list even">
						<!--td><?php 
        #echo $i + ($pager->getPage() - 1) * $pager->getMaxPerPage()
        ?>
</td-->
						<td colspan="8" style="color: #017FC0; font-weight: bold;">
						<?php 
        echo '&nbsp;&nbsp;&middot;&nbsp;&nbsp;&nbsp;' . $location->getDepartment()->toString() . '&nbsp;&nbsp;-&nbsp;&nbsp;&nbsp;' . $location->getName();
        ?>
</td>
					</tr>
                    <?php 
        $c = new Criteria();
        $c->add(LocationPeer::ACADEMIC_CALENDAR_ID, $location->getAcademicCalendarId());
        $locates = LocationPeer::doSelect($c);
        $locate_count = LocationPeer::doCount($c);
        ?>
                    <?php 
        if ($locate_count < 1) {
            ?>
                    	<tr class="list"><td colspan="100"><div class="no_record"><?php 
            echo __('No record found');
            ?>
</div></td></tr>
                    <?php 
        } else {
            ?>
                    <?php 
            $j = 0;
            foreach ($locates as $locate) {
                ?>
예제 #2
0
 public function countLocations($criteria = null, $distinct = false, $con = null)
 {
     include_once 'lib/model/om/BaseLocationPeer.php';
     if ($criteria === null) {
         $criteria = new Criteria();
     } elseif ($criteria instanceof Criteria) {
         $criteria = clone $criteria;
     }
     $criteria->add(LocationPeer::LOCATION_CONDITION_ID, $this->getId());
     return LocationPeer::doCount($criteria, $distinct, $con);
 }