Changeset 663

Show
Ignore:
Timestamp:
07/21/08 22:49:17 (3 months ago)
Author:
aarkerio
Message:

Update general

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/app/models/subject.php

    r661 r663  
    5151 public function getSubject($code) 
    5252 { 
     53  try{ 
    5354   $data           = array(); 
    5455   $this->unbindAll(); 
     
    6162   $data['Lesson'] = $this->Lesson->findAll($conditions, $fields, $order, $limit); 
    6263 
    63  
    6464   $conditions     = array('Entry.subject_id'=>$data['S']['Subject']['id']); 
    6565   $fields         = array('Entry.id', 'Entry.title', 'User.username', 'User.id'); 
     
    6767   $limit          = 10; 
    6868   $data['Entry']  = $this->Entry->findAll($conditions, $fields, $order, $limit); 
    69  
    7069 
    7170   $conditions     = array('Share.subject_id'=>$data['S']['Subject']['id'], 'Share.public'=>1); 
     
    7675 
    7776   return $data; 
     77  } 
     78 
     79  catch(Exception $e) 
     80  { 
     81    echo $e->getMessage(); 
     82    exit(); 
     83  } 
    7884 } 
    7985