コード例 #1
0
ファイル: fees.php プロジェクト: mehulsbhatt/volcano
 /**
  * Displays a product option's fees.
  * 
  * @param int $option_id Product option ID.
  *
  * @return void
  */
 public function action_index($option_id = null)
 {
     $option = $this->get_option($option_id);
     $fees = Service_Product_Option_Fee::find(array('option' => $option));
     $this->view->product = $option->product;
     $this->view->option = $option;
     $this->view->fees = $fees;
 }
コード例 #2
0
ファイル: fees.php プロジェクト: mehulsbhatt/volcano
 /**
  * Gets one or more product option fees.
  *
  * @param int $option_id Product option ID.
  * @param int $id        Product option fee ID.
  *
  * @return void
  */
 public function get_index($option_id = null, $id = null)
 {
     $option = $this->get_option($option_id);
     if (!$id) {
         $fees = \Service_Product_Option_Fee::find(array('option' => $option));
     } else {
         $fees = $this->get_fee($id, $option);
     }
     $this->response($fees);
 }