Browse Source

feat(all): 配送车次成本报表

1 增加车次完结时间字段
fix-sign
zhaoqiaobo 3 months ago
parent
commit
e07c614c33
  1. 6
      blade-service-api/logpm-statisticsdata-api/src/main/java/com/logpm/statistics/entity/ExpenseDispatchTrainDetailEntity.java
  2. 13
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/QualityDeliverServiceImpl.java
  3. 6
      blade-service/logpm-statisticsdata/src/main/java/com/logpm/statistics/mapper/ExpenseDispatchTrainDetailMapper.xml
  4. 12
      blade-service/logpm-statisticsdata/src/main/java/com/logpm/statistics/query/ExpenseDispatchTrainDetailQuery.java
  5. 8
      blade-service/logpm-statisticsdata/src/main/java/com/logpm/statistics/vo/ExpenseDispatchTrainDetailVO.java

6
blade-service-api/logpm-statisticsdata-api/src/main/java/com/logpm/statistics/entity/ExpenseDispatchTrainDetailEntity.java

@ -75,6 +75,12 @@ public class ExpenseDispatchTrainDetailEntity extends TenantEntity {
@ApiModelProperty(value = "配送日期")
@ExcelProperty("车次号")
private String deliveryDate;
/**
* 车次完成时间
*/
@ApiModelProperty(value = "车次完成时间")
@ExcelProperty("车次完成时间")
private Date trainCompletionTime;
/**
* 目的仓
*/

13
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/QualityDeliverServiceImpl.java

@ -116,6 +116,7 @@ public class QualityDeliverServiceImpl extends BaseServiceImpl<QualityDeliverMap
BigDecimal fuelCost = BigDecimal.ZERO;
trainDetailEntity.setSettlementStatus("未结算");
for (QualityDeliverEntity qualityDeliverEntity : value) {
trainDetailEntity.setTrainCompletionTime(qualityDeliverEntity.getCarComplateTime());
trainDetailEntity.setTotalOrderQuantity(qualityDeliverEntity.getOrderNumber());
trainDetailEntity.setDeliveryVehicle(qualityDeliverEntity.getSignCarNumber());
trainDetailEntity.setDistributionModel(qualityDeliverEntity.getSignCarType());
@ -426,16 +427,16 @@ public class QualityDeliverServiceImpl extends BaseServiceImpl<QualityDeliverMap
baseMapper.delPlanDelivery(id);
}
@Override
public void delDistributionCarStart(Long id) {
baseMapper.delDistributionCarStart(id);
}
@Override
public void delDistributionCarStart(Long id) {
baseMapper.delDistributionCarStart(id);
}
@Override
public void carExpenseDispatchDetailFinal(String trainNumber) {
if(StrUtil.isNotEmpty(trainNumber)){
if (StrUtil.isNotEmpty(trainNumber)) {
List<QualityDeliverEntity> entities = this.list(Wrappers.<QualityDeliverEntity>lambdaQuery().eq(QualityDeliverEntity::getSignTrainNumber, trainNumber));
if(CollUtil.isNotEmpty(entities)){
if (CollUtil.isNotEmpty(entities)) {
buildCarExpenseReport(entities);
}
}

6
blade-service/logpm-statisticsdata/src/main/java/com/logpm/statistics/mapper/ExpenseDispatchTrainDetailMapper.xml

@ -37,6 +37,12 @@
<if test="expenseDispatchTrainDetail.deliveryDateEnd != null and expenseDispatchTrainDetail.deliveryDateEnd != ''">
and delivery_date &lt;= #{expenseDispatchTrainDetail.deliveryDateEnd}
</if>
<if test="expenseDispatchTrainDetail.trainCompletionTimeStart != null and expenseDispatchTrainDetail.trainCompletionTimeStart != ''">
and train_completion_time >= #{expenseDispatchTrainDetail.trainCompletionTimeStart}
</if>
<if test="expenseDispatchTrainDetail.trainCompletionTimeEnd != null and expenseDispatchTrainDetail.trainCompletionTimeEnd != ''">
and train_completion_time &lt;= #{expenseDispatchTrainDetail.trainCompletionTimeEnd}
</if>
<if test="expenseDispatchTrainDetail.distributionType != null and expenseDispatchTrainDetail.distributionType != ''">
and distribution_type = #{expenseDispatchTrainDetail.distributionType}
</if>

12
blade-service/logpm-statisticsdata/src/main/java/com/logpm/statistics/query/ExpenseDispatchTrainDetailQuery.java

@ -5,6 +5,8 @@ import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springblade.core.mp.support.Query;
import java.util.Date;
@Data
@EqualsAndHashCode(callSuper = true)
public class ExpenseDispatchTrainDetailQuery extends Query {
@ -18,6 +20,16 @@ public class ExpenseDispatchTrainDetailQuery extends Query {
*/
@ApiModelProperty(value = "配送日期结束")
private String deliveryDateEnd;
/**
* 车次完成时间开始
*/
@ApiModelProperty(value = "车次完成时间开始")
private Date trainCompletionTimeStart;
/**
* 车次完成时间结束
*/
@ApiModelProperty(value = "车次完成时间结束")
private Date trainCompletionTimeEnd;
/**
* 配送司机
*/

8
blade-service/logpm-statisticsdata/src/main/java/com/logpm/statistics/vo/ExpenseDispatchTrainDetailVO.java

@ -64,8 +64,14 @@ public class ExpenseDispatchTrainDetailVO {
* 配送日期
*/
@ApiModelProperty(value = "配送日期")
@ExcelProperty("车次号")
@ExcelProperty("配送日期")
private String deliveryDate;
/**
* 车次完成时间
*/
@ApiModelProperty(value = "车次完成时间")
@ExcelProperty("车次完成时间")
private String trainCompletionTime;
/**
* 目的仓
*/

Loading…
Cancel
Save