예제 #1
0
 public function getFlagTypeCount($id, $type)
 {
     return Flags::where('proposition', [$id])->where('type', $type)->count();
 }
예제 #2
0
 public function flag($type, $id)
 {
     return Flags::create(["type" => $type, "proposition" => $id]);
 }