wupengfei 3 år sedan
förälder
incheckning
de8df62b4d

+ 2 - 0
application/store/controller/Integral.php

@@ -26,6 +26,8 @@ class Integral extends Controller
         $this->title = '积分列表';
         $query = $this->_query($this->table);
         $where= [];
+        $int_type = Db::table('integral_type')->where('status',1)->select();
+        $this->int_type = array_column($int_type,null,'id');
         if($this->request->request('phone'))      $where[]= ['m.phone','=',$this->request->request('phone')];
         $where[]= ['i.is_deleted','=',0];
         $query->alias('i')

+ 2 - 0
application/store/view/integral/index.html

@@ -10,6 +10,7 @@
             <th class='text-left nowrap'>名称</th>
             <th class='text-left nowrap'>手机号</th>
             <th class='text-left nowrap'>积分</th>
+            <th class='text-left nowrap'>变更类型</th>
             <th class="text-center nowrap">时间</th>
             <th class="text-center nowrap">操作</th>
         </tr>
@@ -22,6 +23,7 @@
             <td class='text-left nowrap'>{$vo.name|default='--'}</td>
             <td class='text-left nowrap'>{$vo.phone|default='--'}</td>
             <td class='text-left nowrap'>{$vo.integral|default='--'}</td>
+            <td class='text-left nowrap'>{$int_type[$vo.type]['desc']|default='--'}</td>
             <td class='text-center nowrap'>{$vo.create_at}</td>
             <td class='text-center nowrap'>
                 <span class="layui-btn layui-btn-sm layui-btn-danger" onclick="btn_confirm('删除','del','{$vo.id}');">删 除</span>