wesmiler пре 6 година
родитељ
комит
11c4c23f7c

+ 1 - 1
data/config/files.php

@@ -8,7 +8,7 @@ return [
     // 转换类型
     'convertTypes'=> [
         'doc'=> 'application/msword',
-        'docx'=> 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
+//        'docx'=> 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
         'xls'=> 'application/vnd.ms-excel',
         'xlsx'=> 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',
         'ppt'=> 'application/vnd.ms-powerpoint',

+ 4 - 0
vendor/thinkcmf/cmf-app/src/weixin/controller/TestController.php

@@ -26,6 +26,10 @@ class TestController extends HomeBaseController
 
     }
 
+    public function filterColor()
+    {
+    }
+
     public function qrcode(){
         $id = input('id', 'test');
         $qrcode = Devices::makeQrcode($id);

+ 4 - 2
vendor/thinkcmf/cmf-app/src/weixin/model/Stroage.php

@@ -238,7 +238,7 @@ class Stroage extends Model
 
         // 表格文件转PDF
         $typeData = config('files.convertTypes');
-        $typeData = $typeData ? array_keys($typeData) : ['doc', 'xls', 'xlsx', 'ppt', 'pptx'];
+        $typeData = $typeData ? array_keys($typeData) : ['doc','docx', 'xls', 'xlsx', 'ppt', 'pptx'];
         if (in_array($fileType, $typeData)) {
             $file = Stroage::onLineConvertFile($file);
             return Stroage::getPdfFilePage($file);
@@ -246,7 +246,7 @@ class Stroage extends Model
 
         // 其他文件
         $fileTypes = config('files.fileTypes');
-        $fileTypes = $fileTypes ? $fileTypes : ['txt', 'doc', 'xls', 'xlsx', 'ppt', 'pptx', 'pdf'];
+        $fileTypes = $fileTypes ? $fileTypes : ['txt', 'docx', 'xls', 'xlsx', 'ppt', 'pptx', 'pdf'];
         if (!in_array($fileType, $fileTypes)) {
             return 0;
         }
@@ -326,6 +326,8 @@ class Stroage extends Model
             $newFile = '';
         }
 
+
+
         imagedestroy($im);
         return $newFile;
     }