Browse Source

first commit

liuhairui 3 months ago
parent
commit
38ed7ac66f
2 changed files with 3 additions and 1 deletions
  1. 1 1
      application/admin/controller/Rfiduser.php
  2. 2 0
      application/api/controller/Index.php

+ 1 - 1
application/admin/controller/Rfiduser.php

@@ -86,7 +86,7 @@ class Rfiduser extends Backend
                 'password' => md5($param['row']['password'])
             ];
             $res = Db::name("rfid_user")->where('id',$ids)->update($arr);
-            if ($res) {
+            if ($res == 0) {
                 $this->success('修改成功');
             } else {
                 $this->error('修改失败');

+ 2 - 0
application/api/controller/Index.php

@@ -268,6 +268,8 @@ class Index extends Api
                 'buildingName' => $param['buildingName'] ?? '',
                 'roomName'     => $param['roomName'] ?? '',
                 'penNo'        => $param['penNo'] ?? '',
+                'model'        => $param['deviceModel'] ?? '',
+                'version'        => $param['deviceVersion'] ?? '',
                 'type'         => trim($type),
                 'sys_rq'       => date('Y-m-d H:i:s'),
             ];