当前位置: 首页>>代码示例>>PHP>>正文


PHP Client::getValidationRulesEditUser方法代码示例

本文整理汇总了PHP中app\models\Client::getValidationRulesEditUser方法的典型用法代码示例。如果您正苦于以下问题:PHP Client::getValidationRulesEditUser方法的具体用法?PHP Client::getValidationRulesEditUser怎么用?PHP Client::getValidationRulesEditUser使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在app\models\Client的用法示例。


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

示例1: postEditUser

 public function postEditUser(Request $request, User $user, Client $client, CommonCode $cCode)
 {
     //   	$bool_include_password = $cCode->setCheckboxVar($request->include_password);
     //   	$bool_include_email = $cCode->setCheckboxVar($request->include_email);
     $validation_rules = $client->getValidationRulesEditUser();
     //   	$validation_messages = $client->getValidationMessagesEditUser();
     $this->validate($request, $validation_rules);
     $arr_request = $client->getRequestArrayEditUser($request);
     $user = $user->find(Auth::user()->id);
     //    	$user = $cCode->getObject($arr_request, $user);
     //    	$user->first_name = $arr_request->first_name;
     //    	$user->last_name = $arr_request->last_name;
     //   	$user->company = $arr_request->company;
     //    	$arr_request = array();
     //   	// transfer to new array, so as not to propagate teh password
     //    	$arr_request['first_name'] = $request->first_name;
     //    	$arr_request['last_name'] = $request->last_name;
     //    	$arr_request['company'] = $request->company;
     //		$user->email = $arr_request['email'];
     //		$user->password = $arr_request['password'];
     //		$user->name = '';
     //		$user->save();
     $client = $user->client;
     //   	$client->cloaked_client_id = $client->getNewCloakedClientId($user->id);
     //    	$client->user_id = $user->id;
     $client->first_name = $arr_request['first_name'];
     $client->last_name = $arr_request['last_name'];
     $client->company = $arr_request['company'];
     $client->client_url = $arr_request['client_url'];
     $client->save();
     //    	$user_id = $user->id;
     $data = $client->getDataArrayPostEditUser($arr_request, $user->id, $this->cloakedClientId, $this->arr_logged_in_user);
     return view('client/edit_user_results')->with('data', $data);
 }
开发者ID:jenniferbradley49,项目名称:server,代码行数:34,代码来源:ClientController.php


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