songxingwei 2 years ago
parent
commit
1f6bcc86bb

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

@@ -242,7 +242,8 @@ class Queue extends Controller
      */
     public function remove()
     {
-        $this->_delete($this->table);
+        $log = ['action'=>'上传记录'];
+        $this->_delete($this->table,$log);
     }
 
     /**

+ 2 - 2
vendor/zoujingli/think-library/src/Controller.php

@@ -316,9 +316,9 @@ abstract class Controller extends \stdClass
      * @throws \think\Exception
      * @throws \think\exception\PDOException
      */
-    protected function _delete($dbQuery, $field = '', $where = [])
+    protected function _delete($dbQuery, $log = [], $field = '', $where = [])
     {
-        return DeleteHelper::instance()->init($dbQuery, $field, $where);
+        return DeleteHelper::instance()->init($dbQuery, $log, $field, $where);
     }
 
 }

+ 2 - 1
vendor/zoujingli/think-library/src/helper/DeleteHelper.php

@@ -52,12 +52,13 @@ class DeleteHelper extends Helper
      * @throws \think\Exception
      * @throws \think\exception\PDOException
      */
-    public function init($dbQuery, $field = '', $where = [])
+    public function init($dbQuery, $log = [], $field = '', $where = [])
     {
         $this->where = $where;
         $this->query = $this->buildQuery($dbQuery);
         $this->field = empty($field) ? $this->query->getPk() : $field;
         $this->value = $this->app->request->post($this->field, null);
+        dump($this->field);die;
         // 主键限制处理
         if (!isset($this->where[$this->field]) && is_string($this->value)) {
             $this->query->whereIn($this->field, explode(',', $this->value));