用车需求计算添加定标价格
This commit is contained in:
parent
525f51de28
commit
22b76ec5f7
@ -183,7 +183,8 @@ public class VehicleDemandCountController extends JeecgController<VehicleDemandC
|
|||||||
*/
|
*/
|
||||||
@GetMapping(value = "/getByVdNo")
|
@GetMapping(value = "/getByVdNo")
|
||||||
public Result<?> getByVdNo(@RequestParam(name="vdNo",required=true) String vdNo) {
|
public Result<?> getByVdNo(@RequestParam(name="vdNo",required=true) String vdNo) {
|
||||||
List<VehicleDemandCount> vdNos = vehicleDemandCountService.query().eq("vd_no", vdNo).list();
|
// List<VehicleDemandCount> vdNos = vehicleDemandCountService.query().eq("vd_no", vdNo).list();
|
||||||
|
List<VehicleDemandCount> vdNos = vehicleDemandCountService.getByVdNo(vdNo);
|
||||||
IPage<VehicleDemandCount> page = new Page<>(1, vdNos.size());
|
IPage<VehicleDemandCount> page = new Page<>(1, vdNos.size());
|
||||||
page.setRecords(vdNos);
|
page.setRecords(vdNos);
|
||||||
page.setTotal(vdNos.size());
|
page.setTotal(vdNos.size());
|
||||||
|
@ -4,10 +4,8 @@ import java.io.Serializable;
|
|||||||
import java.io.UnsupportedEncodingException;
|
import java.io.UnsupportedEncodingException;
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
import java.math.BigDecimal;
|
import java.math.BigDecimal;
|
||||||
import com.baomidou.mybatisplus.annotation.IdType;
|
|
||||||
import com.baomidou.mybatisplus.annotation.TableId;
|
import com.baomidou.mybatisplus.annotation.*;
|
||||||
import com.baomidou.mybatisplus.annotation.TableName;
|
|
||||||
import com.baomidou.mybatisplus.annotation.TableLogic;
|
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
import org.springframework.format.annotation.DateTimeFormat;
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
@ -84,6 +82,11 @@ public class VehicleDemandCount implements Serializable {
|
|||||||
@Excel(name = "取货仓库", width = 15)
|
@Excel(name = "取货仓库", width = 15)
|
||||||
@ApiModelProperty(value = "取货仓库")
|
@ApiModelProperty(value = "取货仓库")
|
||||||
private java.lang.String pickUpHub;
|
private java.lang.String pickUpHub;
|
||||||
|
/**定标价格*/
|
||||||
|
@Excel(name = "定标价格", width = 15)
|
||||||
|
@ApiModelProperty(value = "定标价格")
|
||||||
|
@TableField(exist = false)
|
||||||
|
private java.math.BigDecimal tandardPrice;
|
||||||
/**审核结果*/
|
/**审核结果*/
|
||||||
@Excel(name = "审核结果", width = 15, dicCode = "audit_result")
|
@Excel(name = "审核结果", width = 15, dicCode = "audit_result")
|
||||||
@Dict(dicCode = "audit_result")
|
@Dict(dicCode = "audit_result")
|
||||||
|
@ -14,4 +14,5 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
|||||||
*/
|
*/
|
||||||
public interface VehicleDemandCountMapper extends BaseMapper<VehicleDemandCount> {
|
public interface VehicleDemandCountMapper extends BaseMapper<VehicleDemandCount> {
|
||||||
|
|
||||||
|
List<VehicleDemandCount> getByVdNo(@Param("vdNo") String vdNo);
|
||||||
}
|
}
|
||||||
|
@ -2,4 +2,14 @@
|
|||||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
<mapper namespace="org.jeecg.modules.tms.outbound.vehicledemandcount.mapper.VehicleDemandCountMapper">
|
<mapper namespace="org.jeecg.modules.tms.outbound.vehicledemandcount.mapper.VehicleDemandCountMapper">
|
||||||
|
|
||||||
|
<select id="getByVdNo"
|
||||||
|
resultType="org.jeecg.modules.tms.outbound.vehicledemandcount.entity.VehicleDemandCount">
|
||||||
|
select a.*, b.tandard_price from tms_vehicle_demand_count a
|
||||||
|
left join tms_iogistics_price b
|
||||||
|
on a.car_type = b.car_type
|
||||||
|
and a.car_long = b.car_long
|
||||||
|
and a.pick_up_hub = b.start_city
|
||||||
|
and a.delivery_address = b.target_city
|
||||||
|
where a.vd_no = #{vdNo}
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
@ -3,6 +3,8 @@ package org.jeecg.modules.tms.outbound.vehicledemandcount.service;
|
|||||||
import org.jeecg.modules.tms.outbound.vehicledemandcount.entity.VehicleDemandCount;
|
import org.jeecg.modules.tms.outbound.vehicledemandcount.entity.VehicleDemandCount;
|
||||||
import com.baomidou.mybatisplus.extension.service.IService;
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @Description: 用车需求计算
|
* @Description: 用车需求计算
|
||||||
* @Author: jeecg-boot
|
* @Author: jeecg-boot
|
||||||
@ -11,4 +13,5 @@ import com.baomidou.mybatisplus.extension.service.IService;
|
|||||||
*/
|
*/
|
||||||
public interface IVehicleDemandCountService extends IService<VehicleDemandCount> {
|
public interface IVehicleDemandCountService extends IService<VehicleDemandCount> {
|
||||||
|
|
||||||
|
List<VehicleDemandCount> getByVdNo(String vdNo);
|
||||||
}
|
}
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
package org.jeecg.modules.tms.outbound.vehicledemandcount.service.impl;
|
package org.jeecg.modules.tms.outbound.vehicledemandcount.service.impl;
|
||||||
|
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
import org.jeecg.modules.tms.outbound.vehicledemandcount.entity.VehicleDemandCount;
|
import org.jeecg.modules.tms.outbound.vehicledemandcount.entity.VehicleDemandCount;
|
||||||
import org.jeecg.modules.tms.outbound.vehicledemandcount.mapper.VehicleDemandCountMapper;
|
import org.jeecg.modules.tms.outbound.vehicledemandcount.mapper.VehicleDemandCountMapper;
|
||||||
import org.jeecg.modules.tms.outbound.vehicledemandcount.service.IVehicleDemandCountService;
|
import org.jeecg.modules.tms.outbound.vehicledemandcount.service.IVehicleDemandCountService;
|
||||||
@ -7,6 +8,8 @@ import org.springframework.stereotype.Service;
|
|||||||
|
|
||||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @Description: 用车需求计算
|
* @Description: 用车需求计算
|
||||||
* @Author: jeecg-boot
|
* @Author: jeecg-boot
|
||||||
@ -14,6 +17,13 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
|||||||
* @Version: V1.0
|
* @Version: V1.0
|
||||||
*/
|
*/
|
||||||
@Service
|
@Service
|
||||||
|
@RequiredArgsConstructor
|
||||||
public class VehicleDemandCountServiceImpl extends ServiceImpl<VehicleDemandCountMapper, VehicleDemandCount> implements IVehicleDemandCountService {
|
public class VehicleDemandCountServiceImpl extends ServiceImpl<VehicleDemandCountMapper, VehicleDemandCount> implements IVehicleDemandCountService {
|
||||||
|
|
||||||
|
private final VehicleDemandCountMapper vehicleDemandCountMapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<VehicleDemandCount> getByVdNo(String vdNo) {
|
||||||
|
return vehicleDemandCountMapper.getByVdNo(vdNo);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user