Exemplo n.º 1
0
 public static function getPayPlanOptions()
 {
     $allPayPlans = PayPlan::select('id', 'title')->get();
     $aPayPlans = [];
     if (sizeof($allPayPlans) == 0) {
         $aPayPlans = ['' => 'There is no pay plan, create one.'];
     }
     foreach ($allPayPlans as $data) {
         $aPayPlans[$data->id] = $data->title;
     }
     return $aPayPlans;
 }
Exemplo n.º 2
0
 protected function listPayPlans()
 {
     $aPayplans = [];
     $payplans = PayPlan::all();
     if (sizeof($payplans) > 0) {
         foreach ($payplans as $payplan) {
             $aPayplans[] = ['id' => $payplan->id, 'title' => $payplan->title];
         }
     }
     return $aPayplans;
 }