zhangyuewww 2 年之前
父節點
當前提交
c38f21fbb9

+ 7 - 3
winsea-haixin-plugin-yiliangyiyun/src/main/java/com/yh/saas/plugin/yiliangyiyun/service/impl/TranSettlementReportServiceImpl.java

@@ -334,14 +334,18 @@ public class TranSettlementReportServiceImpl extends ServiceImpl<TranSettlementR
             String newNo="";
             //一位数
             if (num < 10) {
-                newNo="00" + num;
+                newNo="000" + num;
             }
-            //两位数xibg
+            //两位数
             else if (num < 100) {
-                newNo="0" + num;
+                newNo="00" + num;
             }
             //三位数
             else if (num < 1000) {
+                newNo="0" + num;
+            }
+            //四位数
+            else if (num < 10000) {
                 newNo=String.valueOf(num);
             }
             String no = "YF"+df.format(new Date())+newNo;