Explorar o código

用户绑定申请

lizhen_gitee hai 11 meses
pai
achega
fab10740b7

+ 4 - 5
application/admin/controller/Userintroapply.php

@@ -3,8 +3,9 @@
 namespace app\admin\controller;
 
 use app\common\controller\Backend;
+
 /**
- * 
+ * 用户申请绑定
  *
  * @icon fa fa-circle-o
  */
@@ -60,8 +61,8 @@ class Userintroapply extends Backend
 
             foreach ($list as $row) {
                 
-                $row->getRelation('auser')->visible(['username']);
-				$row->getRelation('buser')->visible(['username']);
+                $row->getRelation('auser')->visible(['username','nickname']);
+				$row->getRelation('buser')->visible(['username','nickname','gender','jointime']);
             }
 
             $result = array("total" => $list->total(), "rows" => $list->items());
@@ -71,6 +72,4 @@ class Userintroapply extends Backend
         return $this->view->fetch();
     }
 
-
-
 }

+ 22 - 15
application/admin/lang/zh-cn/userintroapply.php

@@ -1,19 +1,26 @@
 <?php
 
 return [
-    'Id'            => 'ID',
-    'User_id'       => '申请用户id',
-    'Down_uid'      => '绑定到下级UID',
-    'Images'        => '相册',
-    'Remark'        => '备注',
-    'Createtime'    => '创建时间',
-    'Updatetime'    => '更新时间',
-    'Status'        => '状态',
-    'Status 0'      => '待审核',
-    'Status 1'      => '审核通过',
-    'Status 2'      => '审核驳回',
-    'Audittime'     => '审核时间',
-    'Auditremark'   => '审核备注',
-    'aUser.username' => '申请人用户名',
-    'bUser.username' => '绑定下级用户名'
+    'Id'             => 'ID',
+    'User_id'        => '申请用户id',
+    'Down_uid'       => '绑定到下级UID',
+    'Images'         => '相册',
+    'Remark'         => '备注',
+    'Createtime'     => '创建时间',
+    'Updatetime'     => '更新时间',
+    'Status'         => '状态',
+    'Status 0'       => '待审核',
+    'Status 1'       => '审核通过',
+    'Status 2'       => '审核驳回',
+    'Audittime'      => '审核时间',
+    'Auditremark'    => '审核备注',
+    'aUser.username'  => '申请人用户名',
+    'aUser.nickname'  => '申请人昵称',
+    'bUser.username'  => '绑定下级用户名',
+    'bUser.nickname'  => '绑定下级昵称',
+    'bUser.gender'    => '绑定下级性别',
+    'bUser.gender -1' => '未知',
+    'bUser.gender 1'  => '男',
+    'bUser.gender 0'  => '女',
+    'bUser.jointime'  => '绑定下级注册时间'
 ];

+ 12 - 9
public/assets/js/backend/userintroapply.js

@@ -8,7 +8,7 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin
                     index_url: 'userintroapply/index' + location.search,
                     add_url: 'userintroapply/add',
                     edit_url: 'userintroapply/edit',
-                    del_url: 'userintroapply/del',
+//                    del_url: 'userintroapply/del',
                     multi_url: 'userintroapply/multi',
                     import_url: 'userintroapply/import',
                     table: 'user_intro_apply',
@@ -26,11 +26,16 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin
                     [
                         {checkbox: true},
                         {field: 'id', title: __('Id')},
-                        {field: 'user_id', title: __('User_id')},
-                        {field: 'auser.username', title: __('aUser.username'), operate: 'LIKE'},
+//                        {field: 'user_id', title: __('User_id')},
+                        {field: 'auser.username', title: __('aUser.username')},
+                        {field: 'auser.nickname', title: __('aUser.nickname'), operate: 'LIKE'},
 
-                        {field: 'down_uid', title: __('Down_uid')},
-                        {field: 'buser.username', title: __('bUser.username'), operate: 'LIKE'},
+//                        {field: 'down_uid', title: __('Down_uid')},
+                        {field: 'buser.username', title: __('bUser.username')},
+                        {field: 'buser.nickname', title: __('bUser.nickname'), operate: 'LIKE'},
+                        {field: 'buser.gender', title: __('bUser.gender'), searchList: {"-1":__('bUser.gender -1'),"1":__('bUser.gender 1'),"0":__('bUser.gender 0')}, formatter: Table.api.formatter.normal},
+
+                        {field: 'buser.jointime', title: __('bUser.jointime'), operate:'RANGE', addclass:'datetimerange', autocomplete:false, formatter: Table.api.formatter.datetime},
 
                         {field: 'remark', title: __('Remark'), operate: 'LIKE'},
                         {field: 'createtime', title: __('Createtime'), operate:'RANGE', addclass:'datetimerange', autocomplete:false, formatter: Table.api.formatter.datetime},
@@ -38,7 +43,8 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin
                         {field: 'status', title: __('Status'), searchList: {"0":__('Status 0'),"1":__('Status 1'),"2":__('Status 2')}, formatter: Table.api.formatter.status},
                         {field: 'audittime', title: __('Audittime'), operate:'RANGE', addclass:'datetimerange', autocomplete:false, formatter: Table.api.formatter.datetime},
                         {field: 'auditremark', title: __('Auditremark'), operate: 'LIKE'},
-                        {field: 'operate', title: __('Operate'), table: table, events: Table.api.events.operate, formatter: Table.api.formatter.operate}
+
+                                                {field: 'operate', title: __('Operate'), table: table, events: Table.api.events.operate, formatter: Table.api.formatter.operate}
                     ]
                 ]
             });
@@ -52,9 +58,6 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin
         edit: function () {
             Controller.api.bindevent();
         },
-        audit: function () {
-            Controller.api.bindevent();
-        },
         api: {
             bindevent: function () {
                 Form.api.bindevent($("form[role=form]"));