From 3d460140b7af3a281b54d17b457c8aff12b9d5c2 Mon Sep 17 00:00:00 2001
From: doum <doum>
Date: 星期一, 15 九月 2025 17:09:52 +0800
Subject: [PATCH] 前端
---
server/services/src/main/java/com/doumee/core/constants/Constants.java | 62 ++++++++++++++++++++++++++----
1 files changed, 53 insertions(+), 9 deletions(-)
diff --git a/server/services/src/main/java/com/doumee/core/constants/Constants.java b/server/services/src/main/java/com/doumee/core/constants/Constants.java
index ea8fd78..49726e0 100644
--- a/server/services/src/main/java/com/doumee/core/constants/Constants.java
+++ b/server/services/src/main/java/com/doumee/core/constants/Constants.java
@@ -1,5 +1,6 @@
package com.doumee.core.constants;
+import com.doumee.dao.business.model.Orders;
import lombok.AllArgsConstructor;
import lombok.Getter;
@@ -56,6 +57,7 @@
public static final String AUTO_DISPATCH ="AUTO_DISPATCH" ;
public static final String AUTO_DISPATCH_DISTANCE ="AUTO_DISPATCH_DISTANCE" ;
public static final String AUTO_CONFIRM ="AUTO_CONFIRM" ;
+ public static final String AUTO_CANCEL_WAIT_PAY ="AUTO_CANCEL_WAIT_PAY" ;
public static final String QYWX = "QYWX";
public static final Integer ONE = 1;
@@ -142,6 +144,12 @@
d = 0L;
}
return d.longValue();
+ }
+ public static BigDecimal formatBigDecimal(BigDecimal d) {
+ if (d == null) {
+ new BigDecimal(0);
+ }
+ return d;
}
/**
@@ -439,6 +447,8 @@
AUTO_COMMENT(13, "绯荤粺-鑷姩璇勪环","瓒呭嚭7鏃ユ湭璇勪环锛岀郴缁熷凡鑷姩璇勪环",2),
AUTO_AGREE(14, "绯荤粺-鑷姩鍚屾剰","鎺ュ崟鏂硅秴鏃舵湭澶勭悊锛屽凡鑷姩鍚屾剰",2),
+ FEE_CONFIRM(15, "鎺ュ崟鏂�-纭璐圭敤","{userName}宸茬‘璁よ垂鐢�",1),
+
;
// 鎴愬憳鍙橀噺
private String name;
@@ -553,21 +563,23 @@
public enum ordersStatus {
- waitPay(0, "寰呮敮浠�"),
- wait(1, "寰呮帴鍗�"),
- accept(2, "宸叉帴鍗�"),
- doing(3, "杩涜涓�"),
- done(4, "宸插畬鎴�"),
- cancel(99, "宸插彇娑�"),
+ waitPay(0, "寰呮敮浠�","寰呮敮浠�"),
+ wait(1, "寰呮帴鍗�","寰呮帴鍗�"),
+ accept(2, "宸叉帴鍗�","宸叉帴鍗�"),
+ doing(3, "杩涜涓�","杩涜涓�"),
+ done(4, "宸插畬鎴�","宸插畬鎴�"),
+ feeconfirm(5, "寰呮敮浠�","寰呭彂鍗曟柟鏀粯"),//閲戦宸茬‘璁�
+ cancel(99, "宸插彇娑�","宸插彇娑�"),
;
// 鎴愬憳鍙橀噺
private int key;
- private String name;
-
+ private String name; //鎺ュ崟鏂规枃妗�
+ private String info; //鍙戝崟鏂规枃妗�
// 鏋勯�犳柟娉�
- ordersStatus(int key, String name) {
+ ordersStatus(int key, String name,String info) {
this.name = name;
this.key = key;
+ this.info = info;
}
// 鏅�氭柟娉�
@@ -575,6 +587,15 @@
for (ordersStatus c : ordersStatus.values()) {
if (c.getKey() == index) {
return c.name;
+ }
+ }
+ return null;
+ }
+
+ public static String getInfo(int index) {
+ for (ordersStatus c : ordersStatus.values()) {
+ if (c.getKey() == index) {
+ return c.info;
}
}
return null;
@@ -594,6 +615,14 @@
public void setKey(int key) {
this.key = key;
+ }
+
+ public String getInfo() {
+ return info;
+ }
+
+ public void setInfo(String info) {
+ this.info = info;
}
}
@@ -708,6 +737,21 @@
}
+ public static String getOrderInfo(Orders orders){
+ String orderTypeInfo = "鐢ㄥ伐鍗�";
+ if(!Constants.equalsInteger(orders.getType(),Constants.ZERO)){
+ orderTypeInfo = Constants.equalsInteger(orders.getType(),Constants.ONE)?"鐢ㄨ溅鍗�":"閫侀鍗�";
+ }else{
+ if(Constants.equalsInteger(orders.getWorkType(),Constants.ZERO)){
+ orderTypeInfo = orderTypeInfo + "-閲囨憳宸�";
+ }else{
+ orderTypeInfo = orderTypeInfo + (Constants.equalsInteger(orders.getWorkType(),Constants.ONE)?"-鍒嗘嫞宸�":"-鍖呰宸�");
+ }
+ }
+ return orderTypeInfo;
+
+ }
+
}
--
Gitblit v1.9.3