Exemple #1
0
 static function create($arr)
 {
     $arr['id'] = md5($arr['email']);
     if (static::count() == 0) {
         $arr['type'] = 0;
         static::first_user_tasks($arr);
     } else {
         $arr['type'] = 1;
     }
     $user = parent::create($arr);
     $user->export();
     return $user;
 }
 /**
  * Store a newly created resource in storage.
  *
  * @param  \Illuminate\Http\Request  $request
  * @return \Illuminate\Http\Response
  */
 public function store(Request $request)
 {
     return BaseModel::create($request->all());
 }