zhangback
2025-11-18 f7490c5b05906399fe754fecdb1f32172a01170d
api/src/main/java/com/ruoyi/api/third/controller/CarWxController.java
@@ -19,6 +19,7 @@
import com.ruoyi.tms.service.ITmsFinanceDetailService;
import com.ruoyi.tms.service.ITmsTripService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
@@ -43,6 +44,10 @@
    private ServerConfig serverConfig;
    @Autowired
    private ISysDictTypeService dictTypeService;
    @Value("${custom.upload.network-path}")
    private String networkPath;
    /**
     * 登录方法[pda]
     *
@@ -155,7 +160,7 @@
            String filePath = RuoYiConfig.getUploadPath();
            // 上传并返回新文件名称
            String fileName = FileUploadUtils.upload(filePath, file);
            String url = serverConfig.getUrl() + fileName;
            String url = networkPath + fileName;
            AjaxResult ajax = AjaxResult.success();
            ajax.put("fileName", fileName);
            ajax.put("url", url);