예제 #1
0
파일: supplier.php 프로젝트: noikiy/vis
 public function view($supplierId = null)
 {
     $supplierService = new SupplierService();
     $supplierDetails = $supplierService->fetchDetailed($supplierId);
     if ($supplierDetails == null) {
         $this->renderView('/common/general_error', array('errorMessage' => "Oops, this supplier does not exist."));
         return;
     }
     $itemsSupplied = $supplierService->fetchItemsSupplied($supplierId);
     $this->renderView('view', array('supplier' => $supplierDetails, 'itemsSupplied' => $itemsSupplied));
 }