浏览代码

提现剥离,增加来源

lizhen_gitee 1 年之前
父节点
当前提交
ccaf0da704

+ 2 - 1
application/admin/controller/Userwithdraw.php

@@ -24,6 +24,7 @@ class Userwithdraw extends Backend
         $this->model = new \app\admin\model\Userwithdraw;
         $this->model = new \app\admin\model\Userwithdraw;
         $this->view->assign("typeList", $this->model->getTypeList());
         $this->view->assign("typeList", $this->model->getTypeList());
         $this->view->assign("statusList", $this->model->getStatusList());
         $this->view->assign("statusList", $this->model->getStatusList());
+        $this->view->assign("fromList", $this->model->getFromList());
     }
     }
 
 
 
 
@@ -130,7 +131,7 @@ class Userwithdraw extends Backend
                     $this->error('操作失败');
                     $this->error('操作失败');
                 }
                 }
 
 
-                //滑落完成
+                //剥离完成
 
 
             }elseif($status == 2){
             }elseif($status == 2){
                 //还钱
                 //还钱

+ 3 - 0
application/admin/lang/zh-cn/userwithdraw.php

@@ -17,6 +17,9 @@ return [
     'Status 0'      => '待审核',
     'Status 0'      => '待审核',
     'Status 1'      => '通过',
     'Status 1'      => '通过',
     'Status 2'      => '拒绝',
     'Status 2'      => '拒绝',
+    'from'          => '提现来源',
+    'from 1'        => '全部',
+    'from 2'        => '收益',
     'Audittime'     => '审核时间',
     'Audittime'     => '审核时间',
     'Auditremark'   => '审核备注',
     'Auditremark'   => '审核备注',
     'User.username' => '用户名',
     'User.username' => '用户名',

+ 10 - 0
application/admin/model/Userwithdraw.php

@@ -41,6 +41,10 @@ class Userwithdraw extends Model
     {
     {
         return ['0' => __('Status 0'), '1' => __('Status 1'), '2' => __('Status 2')];
         return ['0' => __('Status 0'), '1' => __('Status 1'), '2' => __('Status 2')];
     }
     }
+    public function getFromList()
+    {
+        return ['1' => __('from 1'), '2' => __('from 2')];
+    }
 
 
 
 
     public function getTypeTextAttr($value, $data)
     public function getTypeTextAttr($value, $data)
@@ -58,6 +62,12 @@ class Userwithdraw extends Model
         return isset($list[$value]) ? $list[$value] : '';
         return isset($list[$value]) ? $list[$value] : '';
     }
     }
 
 
+    public function getFromTextAttr($value, $data)
+    {
+        $value = $value ? $value : (isset($data['from']) ? $data['from'] : '');
+        $list = $this->getFromList();
+        return isset($list[$value]) ? $list[$value] : '';
+    }
 
 
     public function getAudittimeTextAttr($value, $data)
     public function getAudittimeTextAttr($value, $data)
     {
     {

+ 14 - 1
application/admin/view/userwithdraw/audit.html

@@ -49,6 +49,17 @@
         </div>
         </div>
     </div>
     </div>
     <div class="form-group">
     <div class="form-group">
+        <label class="control-label col-xs-12 col-sm-2">{:__('from')}:</label>
+        <div class="col-xs-12 col-sm-8">
+
+            <div class="radio">
+                {foreach name="fromList" item="vo"}
+                <label for="row[from]-{$key}"><input id="row[from]-{$key}" disabled name="from" type="radio" value="{$key}" {in name="key" value="$row.from"}checked{/in} /> {$vo}</label>
+                {/foreach}
+            </div>
+        </div>
+    </div>
+    <div class="form-group">
         <label class="control-label col-xs-12 col-sm-2">{:__('Status')}:</label>
         <label class="control-label col-xs-12 col-sm-2">{:__('Status')}:</label>
         <div class="col-xs-12 col-sm-8">
         <div class="col-xs-12 col-sm-8">
             
             
@@ -57,9 +68,11 @@
             <label for="row[status]-{$key}"><input id="row[status]-{$key}" name="status" type="radio" value="{$key}" {in name="key" value="$row.status"}checked{/in} /> {$vo}</label>
             <label for="row[status]-{$key}"><input id="row[status]-{$key}" name="status" type="radio" value="{$key}" {in name="key" value="$row.status"}checked{/in} /> {$vo}</label>
             {/foreach}
             {/foreach}
             </div>
             </div>
-
+            <font color="red">拒绝后,积分会原路返回</font><br/>
+            <font color="red">全部提现通过后 剥离,即:用户账号封禁,该用户的下级向上平移,将没有上下级</font>
         </div>
         </div>
     </div>
     </div>
+
     <div class="form-group">
     <div class="form-group">
         <label class="control-label col-xs-12 col-sm-2">{:__('Audittime')}:</label>
         <label class="control-label col-xs-12 col-sm-2">{:__('Audittime')}:</label>
         <div class="col-xs-12 col-sm-8">
         <div class="col-xs-12 col-sm-8">

+ 5 - 3
public/assets/js/backend/userwithdraw.js

@@ -30,6 +30,9 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin
                         {field: 'id', title: __('Id')},
                         {field: 'id', title: __('Id')},
                         {field: 'order_no', title: __('Order_no'), operate: 'LIKE'},
                         {field: 'order_no', title: __('Order_no'), operate: 'LIKE'},
                         {field: 'user_id', title: __('User_id')},
                         {field: 'user_id', title: __('User_id')},
+                        {field: 'user.username', title: __('User.username'), operate: 'LIKE'},
+                        {field: 'user.nickname', title: __('User.nickname'), operate: 'LIKE'},
+                        {field: 'user.mobile', title: __('User.mobile'), operate: 'LIKE'},
                         {field: 'score', title: __('Score')},
                         {field: 'score', title: __('Score')},
                         {field: 'type', title: __('Type'), searchList: {"1":__('Type 1'),"2":__('Type 2'),"3":__('Type 3')}, formatter: Table.api.formatter.normal},
                         {field: 'type', title: __('Type'), searchList: {"1":__('Type 1'),"2":__('Type 2'),"3":__('Type 3')}, formatter: Table.api.formatter.normal},
                         {field: 'realname', title: __('Realname'), operate: 'LIKE'},
                         {field: 'realname', title: __('Realname'), operate: 'LIKE'},
@@ -37,11 +40,10 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin
                         {field: 'bankname', title: __('Bankname'), operate: 'LIKE'},
                         {field: 'bankname', title: __('Bankname'), operate: 'LIKE'},
                         {field: 'createtime', title: __('Createtime'), operate:'RANGE', addclass:'datetimerange', autocomplete:false, formatter: Table.api.formatter.datetime},
                         {field: 'createtime', title: __('Createtime'), operate:'RANGE', addclass:'datetimerange', autocomplete:false, formatter: Table.api.formatter.datetime},
                         {field: 'status', title: __('Status'), searchList: {"0":__('Status 0'),"1":__('Status 1'),"2":__('Status 2')}, formatter: Table.api.formatter.status},
                         {field: 'status', title: __('Status'), searchList: {"0":__('Status 0'),"1":__('Status 1'),"2":__('Status 2')}, formatter: Table.api.formatter.status},
+                        {field: 'from', title: __('from'), searchList: {"1":__('from 1'),"2":__('from 2')}, formatter: Table.api.formatter.status},
                         {field: 'audittime', title: __('Audittime'), operate:'RANGE', addclass:'datetimerange', autocomplete:false, formatter: Table.api.formatter.datetime},
                         {field: 'audittime', title: __('Audittime'), operate:'RANGE', addclass:'datetimerange', autocomplete:false, formatter: Table.api.formatter.datetime},
                         {field: 'auditremark', title: __('Auditremark'), operate: 'LIKE'},
                         {field: 'auditremark', title: __('Auditremark'), operate: 'LIKE'},
-                        {field: 'user.username', title: __('User.username'), operate: 'LIKE'},
-                        {field: 'user.nickname', title: __('User.nickname'), operate: 'LIKE'},
-                        {field: 'user.mobile', title: __('User.mobile'), operate: 'LIKE'},
+
                         {field: 'operate', title: __('Operate'),
                         {field: 'operate', title: __('Operate'),
                             buttons:[
                             buttons:[
                                 {
                                 {