Advertisement
Guest User

Untitled

a guest
Aug 1st, 2014
209
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.71 KB | None | 0 0
  1. public function index() {
  2.         App::uses('Clinic', 'Model');
  3.         Clinic::$current=5;
  4.         $this->Paginator->settings = array(
  5.             'conditions' => array(
  6.                 'Provider.clinic_id' => Clinic::$current,),
  7.             'order' => array('Provider.name' => 'DESC'),
  8.             'contain' => array(
  9.                 'City',
  10.                 'Clinic',
  11.                 'CreatedBy', 'UpdatedBy')
  12.         );
  13.         $this->Prg->commonProcess();
  14.         $this->Paginator->settings['conditions'] = $this->Provider->parseCriteria($this->Prg->parsedParams());
  15.  
  16.         $providers = $this->paginate();
  17. //      debug(Clinic::$current);
  18. //      debug($providers);exit();
  19.  
  20.         $this->set(compact('providers'));
  21.         $this->pdfConfig = array(
  22.             'filename' => __('listado-proveedores') . '.pdf',          
  23.             );         
  24.         $this->setList();
  25.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement