panlumeng 3 years ago
parent
commit
5a73d6deb4
1 changed files with 1 additions and 1 deletions
  1. 1 1
      app/admin/controller/Goldprice.php

+ 1 - 1
app/admin/controller/Goldprice.php

@@ -33,7 +33,7 @@ class Goldprice extends BaseController
     }
 
     public function create(){
-        $type = isset($this->post['type']) && $this->post['type'] !=="" ?trim($this->post['type']):"";
+        $type = isset($this->post['type']) && $this->post['type'] !=="" ?intval($this->post['type']):"";
         if($type==""){
             return error_show(1002,"参数type不能为空");
         }