|
@@ -172,6 +172,7 @@ class User extends Backend
|
|
*/
|
|
*/
|
|
public function detail($ids)
|
|
public function detail($ids)
|
|
{
|
|
{
|
|
|
|
+
|
|
$row = $this->model->get($ids);
|
|
$row = $this->model->get($ids);
|
|
if (!$row) {
|
|
if (!$row) {
|
|
$this->error(__('No Results were found'));
|
|
$this->error(__('No Results were found'));
|
|
@@ -181,12 +182,24 @@ class User extends Backend
|
|
}
|
|
}
|
|
$detail = $row->toArray();
|
|
$detail = $row->toArray();
|
|
$detail['gender'] = $detail['gender'] == 0?'女':'男';
|
|
$detail['gender'] = $detail['gender'] == 0?'女':'男';
|
|
|
|
+
|
|
$detail['region_province'] = Area::where('id',$detail['region_province'])->value('name');
|
|
$detail['region_province'] = Area::where('id',$detail['region_province'])->value('name');
|
|
$detail['region_city'] = Area::where('id',$detail['region_city'])->value('name');
|
|
$detail['region_city'] = Area::where('id',$detail['region_city'])->value('name');
|
|
$detail['region_area'] = Area::where('id',$detail['region_area'])->value('name');
|
|
$detail['region_area'] = Area::where('id',$detail['region_area'])->value('name');
|
|
- $detail['education'] = $detail['education']?Category::get(['id'=>$detail['education']])->toArray()['name']:'';
|
|
|
|
|
|
+ $detail['province'] = Area::where('id',$detail['province'])->value('name');
|
|
|
|
+ $detail['city'] = Area::where('id',$detail['city'])->value('name');
|
|
|
|
+ $detail['area'] = Area::where('id',$detail['area'])->value('name');
|
|
|
|
+
|
|
|
|
+ if($detail['education']){
|
|
|
|
+ $category = Category::where(['id'=>$detail['education']])->value('name');
|
|
|
|
+ if($category)$detail['education']=$category;
|
|
|
|
+ }
|
|
|
|
+ // print_r(Category::where(['id'=>$detail['education']])->value('name'));
|
|
|
|
+ // exit();
|
|
$detail['user_object'] = UserObject::get(['uid'=>$detail['id']])?UserObject::get(['uid'=>$detail['id']])->toArray():'';
|
|
$detail['user_object'] = UserObject::get(['uid'=>$detail['id']])?UserObject::get(['uid'=>$detail['id']])->toArray():'';
|
|
|
|
+
|
|
$this->view->assign("row",$detail);
|
|
$this->view->assign("row",$detail);
|
|
|
|
+
|
|
return $this->view->fetch();
|
|
return $this->view->fetch();
|
|
}
|
|
}
|
|
// /**
|
|
// /**
|