• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP app\Profile类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中app\Profile的典型用法代码示例。如果您正苦于以下问题:PHP Profile类的具体用法?PHP Profile怎么用?PHP Profile使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



在下文中一共展示了Profile类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: settingupdate

 public function settingupdate($id, Request $request)
 {
     $accout = DB::table('users')->find($id);
     $user = new Profile();
     $data = array('Address' => $request->input('Address'), 'Contact' => $request->input('Contact'), 'Graduation_Date' => $request->input('Graduation_Date'), 'Comments' => $request->input('Comments'), 'Email' => $request->input('Email'));
     $user->where('id', $accout->profile_id)->update($data);
     return Redirect('/');
 }
开发者ID:kritishpahi,项目名称:SoftwareEngineering,代码行数:8,代码来源:UC.php


示例2: store

 /**
  * Store a newly created resource in storage.
  *
  * @param  \Illuminate\Http\Request  $request
  * @return \Illuminate\Http\Response
  */
 public function store(ProfileCreateRequest $request)
 {
     $profile = new Profile(['nombre' => $request['nombre'], 'apP' => $request['apP'], 'apM' => $request['apM'], 'telefono' => $request['telefono'], 'fechaNac' => $request['telefono'], 'user_id' => $request['id']]);
     $profile->save();
     $user = User::find($request['id']);
     Session::flash('message', 'Datos ingresados Correctamente');
     return view('profileUsr.profile', compact('user', 'profile'));
 }
开发者ID:behimar,项目名称:sistema-contabilidad,代码行数:14,代码来源:ProfileController.php


示例3: createDefaultUserProfile

 public function createDefaultUserProfile(User $new_user)
 {
     $profile = new Profile();
     $profile->user_id = $new_user->id;
     $profile->about_me = '';
     $profile->profile_image_name = UserController::getDefaultImageName();
     $profile->save();
 }
开发者ID:ebrimamaubeh,项目名称:utg_bantaba,代码行数:8,代码来源:RegisterController.php


示例4: getInsert

 public function getInsert()
 {
     //インスタンス生成
     $profile = new Profile();
     $profile->name = "fujimon";
     $profile->age = 23;
     $profile->detail = "ikemen";
     //保存
     $profile->save();
 }
开发者ID:iiyuda7,项目名称:laravel5_testing,代码行数:10,代码来源:TestController.php


示例5: confirm

 public function confirm($token)
 {
     $confirm = ConfirmUser::where('token', $token)->firstOrFail();
     $user = User::where('email', $confirm->email)->first();
     $user->attachRole(3);
     $user->status = 1;
     $user->save();
     $profile = new Profile();
     $profile->user_id = $user->id;
     $profile->city_id = $confirm->city_id;
     $profile->save();
     $confirm->delete();
     return redirect('auth/login')->with('status', 'Вы успешно потдвердили регистрацию. Теперь войдите в систему используя свой email и пароль.');
 }
开发者ID:AbuLoot,项目名称:vi,代码行数:14,代码来源:CustomAuthController.php


示例6: confirm

 public function confirm($token)
 {
     $confirm = ConfirmUser::where('token', $token)->firstOrFail();
     $user = User::where('email', $confirm->email)->first();
     $user->attachRole(3);
     $user->status = 1;
     $user->save();
     $profile = new Profile();
     $profile->user_id = $user->id;
     $profile->city_id = $confirm->city_id;
     $contacts = ['phone' => null, 'telegram' => null, 'whatsapp' => null, 'viber' => null, 'phone2' => null, 'telegram2' => null, 'whatsapp2' => null, 'viber2' => null];
     $profile->phone = json_encode($contacts);
     $profile->save();
     $confirm->delete();
     return redirect('auth/login')->with('status', 'Вы успешно потдвердили регистрацию. Теперь войдите в систему используя свой email и пароль.');
 }
开发者ID:vizovteam,项目名称:vizov,代码行数:16,代码来源:CustomAuthController.php


示例7: create

 public function create()
 {
     $user = Auth::user();
     // try to find the profile id that matches the user profile
     try {
         $profile = Profile::where('user_id', $user->id)->firstOrFail();
     } catch (ModelNotFoundException $e) {
         // if it fails create profile
         $profile = new Profile();
         $profile->user_id = $user->id;
         $profile->save();
         flash()->overlay('Welcome to Baking Amigo!', 'Now tell us a bit about yourself.', 'info');
     }
     // redirect to the edit page
     return redirect("/users/{$user->id}/edit");
 }
开发者ID:adrianapope,项目名称:baking-amigo,代码行数:16,代码来源:ProfilesController.php


示例8: getProfile

 public function getProfile(Request $request)
 {
     $id = $request->input('id');
     $profile = Profile::find($id);
     $profile->delete();
     return response()->json(['status' => 'valid']);
 }
开发者ID:JordanRodriguezU,项目名称:classroom_management,代码行数:7,代码来源:UserController.php


示例9: multiple

 public function multiple(Request $request)
 {
     if (!$request->has('toCall')) {
         return response()->json(['error' => 'nope'], 400);
     }
     $input = $request->all();
     $toCall = json_decode($input['toCall']);
     foreach ($toCall as $id) {
         $profile = \App\Profile::where('id', '=', $id)->get()->first();
         $post_data = ['From' => '0' . $profile->phone, 'CallerId' => '07930447021', 'Url' => 'http://my.exotel.in/exoml/start/56809', 'CallType' => 'trans'];
         $exotel_sid = 'ruralfuse';
         // Your Exotel SID - Get it here: http://my.exotel.in/Exotel/settings/site#exotel-settings
         $exotel_token = '072f910fe7c604a3aba59c768a78e1d498ba17fe';
         // Your exotel token - Get it here: http://my.exotel.in/Exotel/settings/site#exotel-settings
         $url = "https://" . $exotel_sid . ":" . $exotel_token . "@twilix.exotel.in/v1/Accounts/" . $exotel_sid . "/Calls/connect";
         $ch = curl_init();
         curl_setopt($ch, CURLOPT_VERBOSE, 1);
         curl_setopt($ch, CURLOPT_URL, $url);
         curl_setopt($ch, CURLOPT_POST, 1);
         curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
         curl_setopt($ch, CURLOPT_FAILONERROR, 0);
         curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);
         curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query($post_data));
         $http_result = curl_exec($ch);
         $error = curl_error($ch);
         $http_code = curl_getinfo($ch, CURLINFO_HTTP_CODE);
         curl_close($ch);
     }
 }
开发者ID:simmimourya1,项目名称:Ruralfuse_final,代码行数:29,代码来源:CallController.php


示例10: getCompletedProfiles

 /**
  * @return mixed
  */
 private function getCompletedProfiles($limit = null)
 {
     $profiles = Profile::completed()->get()->filter(function ($profile) {
         return $profile->hasProfilePic();
     });
     return !is_null($limit) && $profiles->count() > $limit ? $profiles->random($limit) : $profiles;
 }
开发者ID:michaeljoyner,项目名称:expeditionists,代码行数:10,代码来源:PagesController.php


示例11: update

 /**
  * Update the specified resource in storage.
  *
  * @param  int  $id
  * @return Response
  */
 public function update($id)
 {
     $data = ['first_name' => Input::get('first_name'), 'last_name' => Input::get('last_name'), 'address' => Input::get('address'), 'pin' => Input::get('pin'), 'emirate_id' => Input::get('emirate_id'), 'phone' => Input::get('phone')];
     //          return response()->json($data);
     Profile::find($id)->update($data);
     return redirect('/home');
 }
开发者ID:bluecipherz,项目名称:gl-ct,代码行数:13,代码来源:ProfileController.php


示例12: getPreview

 public function getPreview()
 {
     $profile = Profile::where("user_id", "=", Auth::id())->first();
     if (!$profile) {
         return redirect('/register');
     } else {
         if ($profile->isActive == 1) {
             return redirect('/profile/index/' . $profile->id);
         }
     }
     $photos = [];
     if ($profile->photo1 != "") {
         $photos[] = $profile->photo1;
     }
     if ($profile->photo2 != "") {
         $photos[] = $profile->photo2;
     }
     if ($profile->photo3 != "") {
         $photos[] = $profile->photo3;
     }
     if ($profile->photo4 != "") {
         $photos[] = $profile->photo4;
     }
     if ($profile->photo5 != "") {
         $photos[] = $profile->photo5;
     }
     $data = array('selectedPage' => 2, 'profile' => Profile::where("user_id", "=", Auth::id())->first(), 'user' => Auth::user(), 'pageUrl' => $_ENV['BASE_FB_URL'] . 'profile/index/' . $profile->id, 'photos' => $photos);
     return view('register.preview', $data);
 }
开发者ID:ElasticOrange,项目名称:canon-orasul-respira-foto,代码行数:29,代码来源:RegistrationController.php


示例13: run

 public function run()
 {
     \App\Profile::create(array('userid' => 1, 'about' => 'anurdha is great'));
     \App\Profile::create(array('userid' => 2, 'about' => 'yeah is great'));
     \App\Profile::create(array('userid' => 3, 'about' => 'ret is weak'));
     \App\Profile::create(array('userid' => 4, 'about' => 'pep is beek'));
 }
开发者ID:anuradhacse,项目名称:UOM-RESOURCE-MANAGER,代码行数:7,代码来源:ProfileSeeder.php


示例14: index

 public function index(Request $request)
 {
     $miss = Profile::online()->miss()->orderByVotes()->get();
     $mister = Profile::online()->mister()->orderByVotes()->get();
     $profiles = ['miss' => $miss, 'mister' => $mister];
     return view('guest.home')->with('profiles', $profiles);
 }
开发者ID:antonioiradukunda,项目名称:missbelge,代码行数:7,代码来源:HomeController.php


示例15: noAnggota

 public function noAnggota()
 {
     $profiles = Profile::where('no_gaji', Request::get('no_gaji'))->get();
     if ($profiles->isEmpty()) {
         Session::flash('error', 'Gagal. No Gaji * ' . Request::get('no_gaji') . ' * tidak berdaftar sebagai ahli KOMADA.');
         return Redirect::route('members.index');
     }
     $yurans = Yuran::where('no_gaji', Request::get('no_gaji'))->where('bulan_tahun', 'like', '%' . Carbon::now()->format('Y'))->orderBy('bulan_tahun', 'asc')->get();
     $yuranTambahan = [];
     for ($i = 1; $i <= 12; $i++) {
         if ($i < 10) {
             $bulan = '0' . $i;
         } else {
             $bulan = $i;
         }
         $yuranTambahans = Yurantambahan::where('created_at', 'like', Carbon::now()->format('Y') . '-' . $bulan . '%')->orderBy('created_at', 'asc')->get();
         if ($yuranTambahans->isEmpty()) {
             $yuranTambahan = 0.0;
         } else {
             foreach ($yuranTambahans as $tambahan) {
                 array_push($yuranTambahan, ['bulan' => $bulan, 'no_gaji' => $tambahan->no_gaji, 'nama' => $tambahan->profileName($tambahan->no_gaji), 'catatan' => $tambahan->sumbangan->nama, 'penerima' => $tambahan->penerima, 'tarikh' => $tambahan->tarikh, 'jumlah' => $tambahan->jumlah]);
             }
         }
         if ($i == Carbon::now()->format('m')) {
             $i = 13;
         }
     }
     $bil = 1;
     $biasas = AkaunPotongan::where('no_gaji', Request::get('no_gaji'))->get();
     return View('members.profile', compact('bil', 'profiles', 'yurans', 'yuranTambahan', 'biasas'));
 }
开发者ID:suhairi,项目名称:komada,代码行数:31,代码来源:CarianController.php


示例16: store

 /**
  * Store a newly created resource in storage.
  *
  * @return Response
  */
 public function store(CreateUserRequest $request, User $user, Profile $profile)
 {
     $user->create(['username' => $request->get('username'), 'password' => bcrypt($request->get('password')), 'role' => $request->get('role')])->save();
     $profile->create(['username' => $request->get('username'), 'name' => $request->get('name'), 'email' => $request->get('email')])->save();
     flash()->info('Created a New User !!');
     return redirect()->route('admin.all');
 }
开发者ID:ambarsetyawan,项目名称:e-rapor.v.1,代码行数:12,代码来源:AdminController.php


示例17: create

 /**
  * Create a new user and connected profile instance after a valid registration.
  *
  * @param  array $data
  * @return User
  */
 protected function create(array $data)
 {
     $user = User::create(['username' => $data['username'], 'email' => $data['email'], 'password' => bcrypt($data['password'])]);
     $profile = Profile::create(['user_id' => $user->id, 'picture' => "default-avatar.jpg"]);
     $user->profile()->save($profile);
     return $user;
 }
开发者ID:uidaho,项目名称:squireproject,代码行数:13,代码来源:AuthController.php


示例18: run

 /**
  * Run the Profiles table seeds.
  *
  * @return void
  */
 public function run()
 {
     Eloquent::unguard();
     Profile::create(['id' => 1, 'user_id' => 1, 'bio' => 'I like to soccer, women, and beer.', 'location' => 'Long Beach, CA', 'twitter_username' => 'johnsfeed', 'instagram_username' => 'johnwashere']);
     Profile::create(['id' => 2, 'user_id' => 2, 'bio' => 'I like to cooking, reading, and swimming.', 'location' => 'Oceanside, CA', 'twitter_username' => 'karenwho', 'instagram_username' => 'karenthequeen']);
     Profile::create(['id' => 3, 'user_id' => 3, 'bio' => 'I like eating raw food and yoga.', 'location' => 'San Francisco, CA', 'twitter_username' => 'janesworld', 'instagram_username' => 'janedidit']);
 }
开发者ID:adrianapope,项目名称:baking-amigo,代码行数:12,代码来源:ProfilesSeeder.php


示例19: get

 public function get($userId)
 {
     //        $profiles = Profile::find($userId);
     $profiles = Profile::where('userId', $userId)->first();
     return $profiles;
     //        return array('name' => 'Sheldon Nofer');
 }
开发者ID:sheldonnofer,项目名称:laravel-angular,代码行数:7,代码来源:ProfileController.php


示例20: run

 /**
  * Run the database seeds.
  *
  * @return void
  */
 public function run()
 {
     ProfileCategory::create(['id' => 1, 'nama' => 'AHLI BIASA', 'catatan' => '']);
     ProfileCategory::create(['id' => 2, 'nama' => 'PPK', 'catatan' => '']);
     ProfileCategory::create(['id' => 3, 'nama' => 'YPPPM', 'catatan' => 'Y']);
     ProfileCategory::create(['id' => 4, 'nama' => 'SPPM', 'catatan' => 'S']);
     ProfileCategory::create(['id' => 5, 'nama' => 'KOMADA', 'catatan' => '']);
     ProfileCategory::create(['id' => 6, 'nama' => 'PELADANG MART', 'catatan' => 'PM']);
     $profiles = Profile::all();
     foreach ($profiles as $profile) {
         $no_anggota = (int) $profile->no_anggota;
         if ($no_anggota != 0) {
             $profile->profile_category_id = 1;
             $profile->save();
         }
         if (strpos($profile->no_anggota, 'Y') !== false) {
             $profile->profile_category_id = 3;
             $profile->save();
         }
         if (strpos($profile->no_anggota, 'S') !== false) {
             $profile->profile_category_id = 4;
             $profile->save();
         }
         if (strpos($profile->no_anggota, 'PM') !== false) {
             $profile->profile_category_id = 6;
             $profile->save();
         }
         if (strpos($profile->no_anggota, 'A') !== false || strpos($profile->no_anggota, 'B') !== false || strpos($profile->no_anggota, 'C') !== false || strpos($profile->no_anggota, 'F') !== false) {
             $profile->profile_category_id = 2;
             $profile->save();
         }
     }
 }
开发者ID:suhairi,项目名称:komada,代码行数:38,代码来源:UserTableSeeder3.php



注:本文中的app\Profile类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP app\Project类代码示例发布时间:2022-05-23
下一篇:
PHP app\Product类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap