Example #1
0
 public function hasAnswered($offerin_id, $category_id, $reseller_id)
 {
     $a = Model::Offerout()->where(['reseller_id', '=', $reseller_id])->where(['offerin_id', '=', $offerin_id])->where(['category', '=', $category_id])->first(true);
     return !empty($a) ? Model::ResellerEmployee()->find($a->reselleremployee_id) : false;
     // Model::offerincategory()->firstOrCreate([
     //     'reseller_id' => $reseller_id,
     //     'offerin_id' => $offerin_id,
     //     'category' => $category,
     // ]);
 }