chuweiqiang 1 year ago
parent
commit
762438dca0

+ 2 - 1
app/admin/view/shopfeedback/index.html

@@ -33,9 +33,10 @@
             where: {},
             cols: [[
                // {field: 'id', title: 'ID', align: 'center'},
-                {field: 'title', title: '商家', align: 'center',templet:function (d) {
+                {field: 'user.username', title: '商家', align: 'center',templet:function (d) {
                     return d.user.username
                     }},
+                {field: 'title', title: '标题',  align: 'center'},
                 {field: 'content', title: '内容',  align: 'center'},
                 {field: 'phone', title: '手机号',  align: 'center'},
                 {field: 'image', title: '图片',  align: 'center', templet:function (d) {

+ 2 - 1
app/data/controller/api/Login.php

@@ -83,6 +83,7 @@ class Login extends Auth
             'region_city.default'     => '',
             'region_area.default'     => '',
             'username.default'        => '',
+            'openid1.default'         => '',
             'phone.mobile'            => '手机格式错误!',
             'phone.require'           => '手机不能为空!',
             'nickname.require'        => '昵称必须!',
@@ -101,7 +102,7 @@ class Login extends Auth
         $user = UserAdminService::set($map, $data, $this->type, true);
         $huanxinID = 'cbz_'.$user['id'];
         $jgalias = 'user_'.$user['id'];
-        DataUser::mk()->where('id',$user['id'])->update(['huanxinID'=>$huanxinID,'jgalias'=>$jgalias]);
+        DataUser::mk()->where('id',$user['id'])->update(['huanxinID'=>$huanxinID,'jgalias'=>$jgalias,'openid1'=>$data['openid1']]);
         huanxin_zhuce('cbz_'.$user['id'],$user['nickname']);
         empty($user) ? $this->error('手机注册失败!') : $this->success('用户注册成功!', $user);
     }

+ 1 - 3
app/data/controller/api/business/User.php

@@ -69,13 +69,11 @@ class User extends Auth
      */
     public function feedback(){
         $data = $this->_vali([
+                'title.require'=>'反馈标题不能为空',
                 'content.require'=>'反馈内容不能为空',
                 'image.default'=>'',
                 'phone.require'=>'联系方式不能为空'
             ]);
-        if(!isset($data['title'])){
-            $data['title'] = null;
-        }
         $feedback_data= [
           'admin_id'=>$this->user->id,
           'title'=>$data['title'],