车辆出入厂审核
This commit is contained in:
parent
b1aba0c921
commit
274e356708
@ -181,6 +181,10 @@ public class VehicleInOutController extends JeecgController<VehicleInOut, IVehic
|
|||||||
|
|
||||||
@PostMapping(value = "/handleConfirm")
|
@PostMapping(value = "/handleConfirm")
|
||||||
public Result<String> handleConfirm(@RequestBody VehicleInOut vehicleInOut) {
|
public Result<String> handleConfirm(@RequestBody VehicleInOut vehicleInOut) {
|
||||||
|
VehicleInOut byId = vehicleInOutService.getById(vehicleInOut.getId());
|
||||||
|
if (Integer.parseInt(vehicleInOut.getCurrentStatus()) <= Integer.parseInt(byId.getCurrentStatus())) {
|
||||||
|
return Result.error("操作失败,请按照流程操作!");
|
||||||
|
}
|
||||||
if ("3".equals(vehicleInOut.getCurrentStatus())) {
|
if ("3".equals(vehicleInOut.getCurrentStatus())) {
|
||||||
vehicleInOut.setAtaTime(new Date());
|
vehicleInOut.setAtaTime(new Date());
|
||||||
} else if ("4".equals(vehicleInOut.getCurrentStatus())) {
|
} else if ("4".equals(vehicleInOut.getCurrentStatus())) {
|
||||||
@ -233,4 +237,13 @@ public class VehicleInOutController extends JeecgController<VehicleInOut, IVehic
|
|||||||
page.setTotal(vehicleInOuts.size());
|
page.setTotal(vehicleInOuts.size());
|
||||||
return Result.OK(page);
|
return Result.OK(page);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@GetMapping(value = "/getCarNum")
|
||||||
|
public Result<?> getCarNum() {
|
||||||
|
List<VehicleInOut> vehicleInOuts = vehicleInOutService.getCarNum();
|
||||||
|
IPage<VehicleInOut> page = new Page<>(1, vehicleInOuts.size());
|
||||||
|
page.setRecords(vehicleInOuts);
|
||||||
|
page.setTotal(vehicleInOuts.size());
|
||||||
|
return Result.OK(page);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -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;
|
||||||
@ -100,7 +98,7 @@ public class VehicleInOut implements Serializable {
|
|||||||
@Excel(name = "出厂门", width = 15)
|
@Excel(name = "出厂门", width = 15)
|
||||||
@ApiModelProperty(value = "出厂门")
|
@ApiModelProperty(value = "出厂门")
|
||||||
private java.lang.String exitFactoryDoor;
|
private java.lang.String exitFactoryDoor;
|
||||||
/**当前状态 创建-0,对接人确认-1,预约入厂-2,审核入库-3,审核出厂-4*/
|
/**当前状态 创建-0,预约入厂-1,对接人确认-2,审核入库-3,审核出厂-4*/
|
||||||
@Excel(name = "当前状态", width = 15, dicCode = "currentStatus")
|
@Excel(name = "当前状态", width = 15, dicCode = "currentStatus")
|
||||||
@Dict(dicCode = "currentStatus")
|
@Dict(dicCode = "currentStatus")
|
||||||
@ApiModelProperty(value = "当前状态")
|
@ApiModelProperty(value = "当前状态")
|
||||||
@ -141,4 +139,7 @@ public class VehicleInOut implements Serializable {
|
|||||||
private java.lang.Double exitWeight;
|
private java.lang.Double exitWeight;
|
||||||
/**用车需求计算id*/
|
/**用车需求计算id*/
|
||||||
private java.lang.String vehicleDemandCountId;
|
private java.lang.String vehicleDemandCountId;
|
||||||
|
/** 当前排队数 */
|
||||||
|
@TableField(exist = false)
|
||||||
|
private Integer lineUpCount;
|
||||||
}
|
}
|
||||||
|
@ -18,4 +18,6 @@ public interface VehicleInOutMapper extends BaseMapper<VehicleInOut> {
|
|||||||
VehicleInOutCount getCount();
|
VehicleInOutCount getCount();
|
||||||
|
|
||||||
List<VehicleInOut> getVehicle(VehicleParam vehicleParam);
|
List<VehicleInOut> getVehicle(VehicleParam vehicleParam);
|
||||||
|
|
||||||
|
List<VehicleInOut> getCarNum();
|
||||||
}
|
}
|
||||||
|
@ -23,4 +23,13 @@
|
|||||||
WHERE b.SHIP_DATE >= #{beginDate}
|
WHERE b.SHIP_DATE >= #{beginDate}
|
||||||
and b.SHIP_DATE <= #{endDate};
|
and b.SHIP_DATE <= #{endDate};
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<select id="getCarNum" resultType="org.jeecg.modules.tms.carinout.vehicleinout.entity.VehicleInOut">
|
||||||
|
SELECT a.*, SUM(CASE WHEN a.CURRENT_STATUS = '2' THEN 1 ELSE 0 END) OVER () AS line_up_count
|
||||||
|
FROM tms_vehicle_in_out a
|
||||||
|
LEFT JOIN tms_vehicle_demand b
|
||||||
|
ON a.VD_NO = b.VD_NO
|
||||||
|
WHERE b.SHIP_DATE = TRUNC(SYSDATE)
|
||||||
|
AND a.CURRENT_STATUS != '4';
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
@ -18,4 +18,6 @@ public interface IVehicleInOutService extends IService<VehicleInOut> {
|
|||||||
VehicleInOutCount getCount();
|
VehicleInOutCount getCount();
|
||||||
|
|
||||||
List<VehicleInOut> getVehicle(VehicleParam vehicleParam);
|
List<VehicleInOut> getVehicle(VehicleParam vehicleParam);
|
||||||
|
|
||||||
|
List<VehicleInOut> getCarNum();
|
||||||
}
|
}
|
||||||
|
@ -32,4 +32,9 @@ public class VehicleInOutServiceImpl extends ServiceImpl<VehicleInOutMapper, Veh
|
|||||||
public List<VehicleInOut> getVehicle(VehicleParam vehicleParam) {
|
public List<VehicleInOut> getVehicle(VehicleParam vehicleParam) {
|
||||||
return vehicleInOutMapper.getVehicle(vehicleParam);
|
return vehicleInOutMapper.getVehicle(vehicleParam);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<VehicleInOut> getCarNum() {
|
||||||
|
return vehicleInOutMapper.getCarNum();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -225,7 +225,7 @@ public class DeliveryDemandController extends JeecgController<DeliveryDemand, ID
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 更具发货时间获取发货计划
|
* 根据发货时间获取发货计划
|
||||||
* @param vehicleParam
|
* @param vehicleParam
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
|
Loading…
x
Reference in New Issue
Block a user