|
|
|
|
@ -21,6 +21,7 @@ import org.dromara.common.tenant.helper.TenantHelper;
|
|
|
|
|
import org.dromara.oa.erp.domain.ErpProjectPlan;
|
|
|
|
|
import org.dromara.oa.erp.domain.ErpProjectReportDetail;
|
|
|
|
|
import org.dromara.oa.erp.domain.vo.ErpProjectPlanVo;
|
|
|
|
|
import org.dromara.system.api.RemoteCodeRuleService;
|
|
|
|
|
import org.dromara.workflow.api.RemoteWorkflowService;
|
|
|
|
|
import org.dromara.workflow.api.domain.RemoteStartProcess;
|
|
|
|
|
import org.dromara.workflow.api.event.ProcessEvent;
|
|
|
|
|
@ -50,6 +51,9 @@ public class CrmFlightBookingServiceImpl implements ICrmFlightBookingService {
|
|
|
|
|
@DubboReference(timeout = 30000)
|
|
|
|
|
private RemoteWorkflowService remoteWorkflowService;
|
|
|
|
|
|
|
|
|
|
@DubboReference()
|
|
|
|
|
private RemoteCodeRuleService remoteCodeRuleService;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 查询机票预订
|
|
|
|
|
*
|
|
|
|
|
@ -95,16 +99,20 @@ public class CrmFlightBookingServiceImpl implements ICrmFlightBookingService {
|
|
|
|
|
.eq(CrmFlightBooking::getDelFlag, "0")
|
|
|
|
|
.like(StringUtils.isNotBlank(bo.getApplyCode()), CrmFlightBooking::getApplyCode, bo.getApplyCode())
|
|
|
|
|
.eq(bo.getPassengerId() != null, CrmFlightBooking::getPassengerId, bo.getPassengerId())
|
|
|
|
|
.like(StringUtils.isNotBlank(bo.getPassengerName()), CrmFlightBooking::getPassengerName, bo.getPassengerName())
|
|
|
|
|
.like(StringUtils.isNotBlank(bo.getPassengerName()), CrmFlightBooking::getPassengerName,
|
|
|
|
|
bo.getPassengerName())
|
|
|
|
|
.eq(bo.getTravelDate() != null, CrmFlightBooking::getTravelDate, bo.getTravelDate())
|
|
|
|
|
.like(StringUtils.isNotBlank(bo.getDepartureLocation()), CrmFlightBooking::getDepartureLocation, bo.getDepartureLocation())
|
|
|
|
|
.like(StringUtils.isNotBlank(bo.getArrivalLocation()), CrmFlightBooking::getArrivalLocation, bo.getArrivalLocation())
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getFlightDiscount()), CrmFlightBooking::getFlightDiscount, bo.getFlightDiscount())
|
|
|
|
|
.like(StringUtils.isNotBlank(bo.getDepartureLocation()), CrmFlightBooking::getDepartureLocation,
|
|
|
|
|
bo.getDepartureLocation())
|
|
|
|
|
.like(StringUtils.isNotBlank(bo.getArrivalLocation()), CrmFlightBooking::getArrivalLocation,
|
|
|
|
|
bo.getArrivalLocation())
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getFlightDiscount()), CrmFlightBooking::getFlightDiscount,
|
|
|
|
|
bo.getFlightDiscount())
|
|
|
|
|
.eq(bo.getFlightAmount() != null, CrmFlightBooking::getFlightAmount, bo.getFlightAmount())
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getOssId()), CrmFlightBooking::getOssId, bo.getOssId())
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getBookingStatus()), CrmFlightBooking::getBookingStatus, bo.getBookingStatus())
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getFlowStatus()), CrmFlightBooking::getFlowStatus, bo.getFlowStatus())
|
|
|
|
|
;
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getBookingStatus()), CrmFlightBooking::getBookingStatus,
|
|
|
|
|
bo.getBookingStatus())
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getFlowStatus()), CrmFlightBooking::getFlowStatus, bo.getFlowStatus());
|
|
|
|
|
return lqw;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@ -118,6 +126,12 @@ public class CrmFlightBookingServiceImpl implements ICrmFlightBookingService {
|
|
|
|
|
public Boolean insertByBo(CrmFlightBookingBo bo) {
|
|
|
|
|
CrmFlightBooking add = MapstructUtils.convert(bo, CrmFlightBooking.class);
|
|
|
|
|
validEntityBeforeSave(add);
|
|
|
|
|
// 自动生成申请单号
|
|
|
|
|
if(StringUtils.isBlank(add.getApplyCode())){
|
|
|
|
|
String applyCode = remoteCodeRuleService.selectCodeRuleCode("1019");
|
|
|
|
|
add.setApplyCode(applyCode);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
boolean flag = baseMapper.insert(add) > 0;
|
|
|
|
|
if (flag) {
|
|
|
|
|
bo.setBookingId(add.getBookingId());
|
|
|
|
|
@ -159,6 +173,7 @@ public class CrmFlightBookingServiceImpl implements ICrmFlightBookingService {
|
|
|
|
|
}
|
|
|
|
|
return baseMapper.deleteByIds(ids) > 0;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 机票预订并提交
|
|
|
|
|
*
|
|
|
|
|
@ -190,6 +205,7 @@ public class CrmFlightBookingServiceImpl implements ICrmFlightBookingService {
|
|
|
|
|
}
|
|
|
|
|
return MapstructUtils.convert(add, CrmFlightBookingVo.class);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 总体流程监听(例如: 草稿,撤销,退回,作废,终止,已完成等)
|
|
|
|
|
*
|
|
|
|
|
|