Merge remote-tracking branch 'origin/dev' into dev

This commit is contained in:
wanglf3 2024-03-19 08:35:11 +08:00
commit cc5ee788d9
4 changed files with 12 additions and 5 deletions

View File

@ -13,11 +13,10 @@ import com.chint.domain.value_object.UserLoginParam;
import com.chint.infrastructure.util.BaseContext;
import com.chint.infrastructure.util.OrderNo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;
import java.util.List;
@Component
@ -26,6 +25,8 @@ public class RouteOrderFactory implements OrderFactory {
@Autowired
private RouteLegFactory routeLegFactory;
@Value("${chint.envMark}")
private String envMark;
@Override
@ -54,8 +55,13 @@ public class RouteOrderFactory implements OrderFactory {
String syscode = loginParam.getSyscode();
String billcode = loginParam.getBillcode();
RouteOrder routeOrder = new RouteOrder();
routeOrder.setRouteOrderNo(OrderNo.generate(syscode, billcode));
//用于区分测试环境和正式环境的出差申请单
String generate = OrderNo.generate(syscode, billcode);
if (envMark.equals("prod")) {
generate = generate + envMark;
}
routeOrder.setRouteOrderNo(generate);
//根据项目需求需要保存假审批订单号真审批订单号 创建的时候保存假审批订单号

View File

@ -17,7 +17,7 @@ chint:
port: 6379
password: Worktask@Redis2023
database: 5
envMark: dev
logging:

View File

@ -23,6 +23,7 @@ chint:
port: 6889
password: 33WJTKrlJ(5lf#x%Vg
database: 5
envMark: prod
logging:
level:

View File

@ -28,7 +28,7 @@ chint:
port: 6379
password: Worktask@Redis2023
database: 5
envMark: test
logging:
level: