From 6892c31200a7ed1b0e60ee5aff794b1fcecc7ef6 Mon Sep 17 00:00:00 2001 From: liusheng <337615773@qq.com> Date: 星期三, 01 十一月 2023 16:28:06 +0800 Subject: [PATCH] 解决文件上传时,文件名重复问题 --- ruoyi-admin/src/main/resources/application.yml | 79 ++++++++++++++++++++------------------- 1 files changed, 41 insertions(+), 38 deletions(-) diff --git a/ruoyi-admin/src/main/resources/application.yml b/ruoyi-admin/src/main/resources/application.yml index 297e022..326dc40 100644 --- a/ruoyi-admin/src/main/resources/application.yml +++ b/ruoyi-admin/src/main/resources/application.yml @@ -10,11 +10,11 @@ demoEnabled: true # 鏂囦欢璺緞 绀轰緥锛� Windows閰嶇疆D:/ruoyi/uploadPath锛孡inux閰嶇疆 /home/ruoyi/uploadPath锛� # 寮�鍙戠幆澧� window - profile: D:/lihusoft/OPO/WEB/Upload + # profile: D:/lihusoft/OPO/WEB/Upload # 寮�鍙戠幆澧� linux -# profile: /home/smartor/uploadFile + # profile: /home/smartor/uploadFile # 鍖婚櫌鐜 - #profile: E:/OPO/WEB/Upload + profile: E:/OPO/WEB/Upload # 鑾峰彇ip鍦板潃寮�鍏� addressEnabled: false # 楠岃瘉鐮佺被鍨� math 鏁扮粍璁$畻 char 瀛楃楠岃瘉 @@ -23,7 +23,7 @@ # 寮�鍙戠幆澧冮厤缃� server: # 鏈嶅姟鍣ㄧ殑HTTP绔彛锛岄粯璁や负8080 - port: 8086 + port: 8080 servlet: # 搴旂敤鐨勮闂矾寰� context-path: / @@ -37,9 +37,9 @@ # 鏃ュ織閰嶇疆 logging: - file: + file: # 鏃ュ織璺緞 绀轰緥锛� Windows閰嶇疆D:/ruoyi/logs锛孡inux閰嶇疆 /home/ruoyi/logs,涓嶅~鍚岀骇鐩綍logs锛� - path: logs + path: D:/ruoyi/ls/logs level: com.ruoyi: debug org.springframework: warn @@ -50,15 +50,15 @@ messages: # 鍥介檯鍖栬祫婧愭枃浠惰矾寰� basename: i18n/messages - profiles: + profiles: active: druid # 鏂囦欢涓婁紶 servlet: - multipart: - # 鍗曚釜鏂囦欢澶у皬 - max-file-size: 20MB - # 璁剧疆鎬讳笂浼犵殑鏂囦欢澶у皬 - max-request-size: 40MB + multipart: + # 鍗曚釜鏂囦欢澶у皬 + max-file-size: 20MB + # 璁剧疆鎬讳笂浼犵殑鏂囦欢澶у皬 + max-request-size: 40MB # 鏈嶅姟妯″潡 devtools: restart: @@ -70,10 +70,10 @@ enabled: ALWAYS # redis 閰嶇疆 redis: - # 鍦板潃銆佸瘑鐮併�佺鍙o紙榛樿涓�6379锛夛細鍖婚櫌鐜 - #host: 129.88.242.37 - #password: jqserver - #port: 6379 + # # 鍦板潃銆佸瘑鐮併�佺鍙o紙榛樿涓�6379锛夛細鍖婚櫌鐜 + # host: 129.88.242.37 + # password: jqserver + # port: 6379 # 鍦板潃銆佸瘑鐮併�佺鍙o紙榛樿涓�6379锛夛細寮�鍙戠幆澧� host: 116.62.18.175 @@ -97,35 +97,38 @@ # token閰嶇疆 token: - # 浠ょ墝鑷畾涔夋爣璇� - header: Authorization - # 浠ょ墝瀵嗛挜 - secret: abcdefghijklmnopqrstuvwxyz - # 浠ょ墝鏈夋晥鏈燂紙榛樿30鍒嗛挓锛� - expireTime: 3000 - + # 浠ょ墝鑷畾涔夋爣璇� + header: Authorization + # 浠ょ墝瀵嗛挜 + secret: abcdefghijklmnopqrstuvwxyz + # 浠ょ墝鏈夋晥鏈燂紙榛樿30鍒嗛挓锛� + expireTime: 3000 + # MyBatis閰嶇疆 #mybatis: # MyBatis Plus閰嶇疆 mybatis-plus: - # 鎼滅储鎸囧畾鍖呭埆鍚� - typeAliasesPackage: com.ruoyi.**.domain - # 閰嶇疆mapper鐨勬壂鎻忥紝鎵惧埌鎵�鏈夌殑mapper.xml鏄犲皠鏂囦欢 - mapperLocations: classpath*:mapper/**/*Mapper.xml - # 鍔犺浇鍏ㄥ眬鐨勯厤缃枃浠� - configLocation: classpath:mybatis/mybatis-config.xml - # configuration: + # 鎼滅储鎸囧畾鍖呭埆鍚� + typeAliasesPackage: com.ruoyi.**.domain + # 閰嶇疆mapper鐨勬壂鎻忥紝鎵惧埌鎵�鏈夌殑mapper.xml鏄犲皠鏂囦欢 + mapperLocations: classpath*:mapper/**/*Mapper.xml + # 鍔犺浇鍏ㄥ眬鐨勯厤缃枃浠� + configLocation: classpath:mybatis/mybatis-config.xml + # configuration: # log-impl: org.apache.ibatis.logging.stdout.StdOutImpl - global-config: - db-config: - logic-delete-field: isdel # 鍏ㄥ眬閫昏緫鍒犻櫎鐨勫疄浣撳瓧娈靛悕 - logic-delete-value: 1 # 閫昏緫宸插垹闄ゅ��(榛樿涓� 1) - logic-not-delete-value: 0 # 閫昏緫鏈垹闄ゅ��(榛樿涓� 0) + global-config: + db-config: + logic-delete-field: isdel # 鍏ㄥ眬閫昏緫鍒犻櫎鐨勫疄浣撳瓧娈靛悕 + logic-delete-value: 1 # 閫昏緫宸插垹闄ゅ��(榛樿涓� 1) + logic-not-delete-value: 0 # 閫昏緫鏈垹闄ゅ��(榛樿涓� 0) +# update-strategy: IGNORED #蹇界暐涓虹┖ + + # PageHelper鍒嗛〉鎻掍欢 -pagehelper: +pagehelper: helperDialect: mysql supportMethodsArguments: true - params: count=countSql + params: count=countSql # Swagger閰嶇疆 swagger: @@ -135,7 +138,7 @@ pathMapping: / # 闃叉XSS鏀诲嚮 -xss: +xss: # 杩囨护寮�鍏� enabled: true # 鎺掗櫎閾炬帴锛堝涓敤閫楀彿鍒嗛殧锛� -- Gitblit v1.9.3