mirror of
http://192.168.1.205:9980/cf_devdept2/cf_imes_server.git
synced 2026-08-12 21:02:08 +08:00
添加机台字段
This commit is contained in:
+10
-5
@@ -2,10 +2,7 @@ package com.cf.imes.module.executor.controller.admin.plan;
|
||||
|
||||
import com.cf.imes.framework.common.pojo.CommonResult;
|
||||
import com.cf.imes.framework.operatelog.core.annotations.OperateLog;
|
||||
import com.cf.imes.module.executor.controller.admin.plan.vo.AddRemainReqVO;
|
||||
import com.cf.imes.module.executor.controller.admin.plan.vo.OptimizeParamResVO;
|
||||
import com.cf.imes.module.executor.controller.admin.plan.vo.PlateOptimize;
|
||||
import com.cf.imes.module.executor.controller.admin.plan.vo.SavePlanPlateResult;
|
||||
import com.cf.imes.module.executor.controller.admin.plan.vo.*;
|
||||
import com.cf.imes.module.executor.service.optimizeplan.OptimizePlanService;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
@@ -73,7 +70,15 @@ public class OptimizePlanController {
|
||||
@PreAuthorize("@ss.hasPermission('executor:optimize-plate:create')")
|
||||
public CommonResult<OptimizeParamResVO> getCfData(@RequestParam @Valid @NotNull(message = "排单id不能空") Long planId) {
|
||||
//todo
|
||||
return CommonResult.success(null);//optimizePlanService.getCfData(planId));
|
||||
return CommonResult.success(null);
|
||||
}
|
||||
|
||||
@GetMapping("/getOptimizePlanParam")
|
||||
@Operation(summary = "获取优化排单参数 (未完成)")
|
||||
@PreAuthorize("@ss.hasPermission('executor:optimize-plate:create')")
|
||||
public CommonResult<OptimizeParamRespVO> getOptimizePlanParam (@RequestParam @Valid @NotNull(message = "排单id不能空") Long planId) {
|
||||
//todo
|
||||
return CommonResult.success(optimizePlanService.getOptimizePlanParam(planId));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
+59
@@ -0,0 +1,59 @@
|
||||
package com.cf.imes.module.executor.controller.admin.plan.vo;
|
||||
|
||||
import com.cf.imes.module.executor.controller.admin.goods.vo.GoodsRespVO;
|
||||
import com.cf.imes.module.executor.controller.admin.plate.vo.PlateRespVO;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
import static com.cf.imes.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
|
||||
import static com.cf.imes.framework.common.util.date.DateUtils.TIME_ZONE_DEFAULT;
|
||||
|
||||
/**
|
||||
* @author Beal
|
||||
*/
|
||||
@Data
|
||||
public class OptimizeParamRespVO {
|
||||
@Schema(description = "排单id")
|
||||
private Long planId;
|
||||
@Schema(description = "排单号")
|
||||
private String planNo;
|
||||
@Schema(description = "排序优先级")
|
||||
private Integer sort;
|
||||
@Schema(description = "排单类型:1 混单排单,2 生产单排单")
|
||||
private Integer type;
|
||||
@Schema(description = "排单状态 0 新单,1 板材已申请,2 开料中,3 已开料")
|
||||
private Integer status;
|
||||
@Schema(description = "是否支付")
|
||||
private Boolean isPay;
|
||||
@Schema(description = "机台 ID")
|
||||
private Long machineId;
|
||||
@Schema(description = "计划时间")
|
||||
private LocalDateTime planTime;
|
||||
@Schema(description = "生产单号")
|
||||
private String orderNos;
|
||||
@Schema(description = "排单优化文件地址")
|
||||
private String placeDateFileUrl;
|
||||
@Schema(description = "排单优化文件地址")
|
||||
private String placeOrderFileUrl;
|
||||
@Schema(description = "备注")
|
||||
private String remark;
|
||||
@Schema(description = "生产操作人")
|
||||
private String operator;
|
||||
@Schema(description = "生产时间")
|
||||
@JsonFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND, timezone = TIME_ZONE_DEFAULT)
|
||||
private Date produceTime;
|
||||
|
||||
@Schema(description = "生产单列表")
|
||||
private List<OrderResp> orderList;
|
||||
|
||||
@Schema(description = "商品列表")
|
||||
private List<GoodsRespVO> goodsList;
|
||||
|
||||
@Schema(description = "小板列表")
|
||||
private List<PlateRespVO> plateList;
|
||||
}
|
||||
+52
@@ -0,0 +1,52 @@
|
||||
package com.cf.imes.module.executor.controller.admin.plan.vo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
import static com.cf.imes.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
|
||||
import static com.cf.imes.framework.common.util.date.DateUtils.TIME_ZONE_DEFAULT;
|
||||
|
||||
/**
|
||||
* @author Beal
|
||||
*/
|
||||
@Data
|
||||
public class OrderResp {
|
||||
@Schema(description = "生产单id")
|
||||
private Long orderId;
|
||||
@Schema(description = "父id")
|
||||
private Long parentNo;
|
||||
@Schema(description = "自定义单号")
|
||||
private String customOrderNo;
|
||||
@Schema(description = "客户")
|
||||
private String customer;
|
||||
@Schema(description = "地址")
|
||||
private String address;
|
||||
@Schema(description = "客户电话")
|
||||
private String phoneNumber;
|
||||
@Schema(description = "经销商")
|
||||
private String dealer;
|
||||
@Schema(description = "经销商电话")
|
||||
private String dealerPhoneNumber;
|
||||
@Schema(description = "业务员")
|
||||
private String salesman;
|
||||
@Schema(description = "拆单员")
|
||||
private String splitter;
|
||||
@Schema(description = "备注")
|
||||
private String remark;
|
||||
@Schema(description = "交付日期")
|
||||
@JsonFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND, timezone = TIME_ZONE_DEFAULT)
|
||||
private Date deliveryDate;
|
||||
@Schema(description = "生产单类型,1主单 2子单")
|
||||
private Integer type;
|
||||
@Schema(description = "生产单排序号")
|
||||
private Integer sort;
|
||||
@Schema(description = "CAD数据类型,1CAD 2WebCAD 3Excel")
|
||||
private Integer dataType;
|
||||
@Schema(description = "订单状态,0未排单1已排单2生产中3加工完成4打包完成5入库完成6出库完成")
|
||||
private Integer status;
|
||||
|
||||
}
|
||||
+3
@@ -35,4 +35,7 @@ public interface PlanMapper extends BaseMapperX<PlanDO> {
|
||||
}
|
||||
|
||||
List<PlateOptimize> selectPlateListByPlanId(Long planId);
|
||||
|
||||
OptimizeParamRespVO getOptimizePlanParam(Long planId);
|
||||
|
||||
}
|
||||
+3
-4
@@ -1,9 +1,6 @@
|
||||
package com.cf.imes.module.executor.service.optimizeplan;
|
||||
|
||||
import com.cf.imes.module.executor.controller.admin.plan.vo.AddRemainReqVO;
|
||||
import com.cf.imes.module.executor.controller.admin.plan.vo.OptimizeParamResVO;
|
||||
import com.cf.imes.module.executor.controller.admin.plan.vo.PlateOptimize;
|
||||
import com.cf.imes.module.executor.controller.admin.plan.vo.SavePlanPlateResult;
|
||||
import com.cf.imes.module.executor.controller.admin.plan.vo.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@@ -17,4 +14,6 @@ public interface OptimizePlanService {
|
||||
Boolean commit(Long planId);
|
||||
|
||||
OptimizeParamResVO getOptimizeParam(Long planId);
|
||||
|
||||
OptimizeParamRespVO getOptimizePlanParam(Long planId);
|
||||
}
|
||||
|
||||
+5
@@ -200,5 +200,10 @@ public class OptimizePlanServiceImpl implements OptimizePlanService {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public OptimizeParamRespVO getOptimizePlanParam(Long planId) {
|
||||
return planMapper.getOptimizePlanParam(planId);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
+61
@@ -19,6 +19,56 @@
|
||||
<collection property="plateDOList" javaType="java.util.List" ofType="com.cf.imes.module.executor.dal.dataobject.remainplaten.RemainPlateDO"/>
|
||||
</resultMap>
|
||||
|
||||
<resultMap id="optimizeMap" type="com.cf.imes.module.executor.controller.admin.plan.vo.OptimizeParamRespVO">
|
||||
<result column="planId" property="planId"/>
|
||||
<result column="plan_no" property="planNo"/>
|
||||
<result column="sort" property="sort"/>
|
||||
<result column="type" property="type"/>
|
||||
<result column="status" property="status"/>
|
||||
<result column="is_pay" property="isPay"/>
|
||||
<result column="machine_id" property="machineId"/>
|
||||
<result column="plan_time" property="planTime"/>
|
||||
<result column="remark" property="remark"/>
|
||||
<collection property="goodsList" javaType="java.util.List" ofType="com.cf.imes.module.executor.controller.admin.goods.vo.GoodsRespVO"/>
|
||||
<collection property="orderList" javaType="java.util.List" ofType="com.cf.imes.module.executor.controller.admin.plan.vo.OrderResp"/>
|
||||
<collection property="plateList" javaType="java.util.List" ofType="com.cf.imes.module.executor.controller.admin.plate.vo.PlateRespVO" >
|
||||
<result column="plateId" property="id"/>
|
||||
<result column="plan_no" property="plateNo"/>
|
||||
<result column="type" property="type"/>
|
||||
<result column="goods_id" property="goodsId"/>
|
||||
<result column="width" property="width"/>
|
||||
<result column="height" property="height"/>
|
||||
<result column="thickness" property="thickness"/>
|
||||
<result column="split_width" property="splitWidth"/>
|
||||
<result column="split_height" property="splitHeight"/>
|
||||
<result column="split_thickness" property="splitThickness"/>
|
||||
<result property="sealLeft" column="seal_left"/>
|
||||
<result property="sealRight" column="seal_right"/>
|
||||
<result property="sealUp" column="seal_up"/>
|
||||
<result property="sealDown" column="seal_down"/>
|
||||
<result property="area" column="area"/>
|
||||
<result property="texture" column="texture"/>
|
||||
<result property="holeFace" column="hole_face"/>
|
||||
<result property="holeArrange" column="hole_arrange"/>
|
||||
<result property="unregularPointCount" column="unregular_point_count"/>
|
||||
<result property="frontHoleCount" column="front_hole_count"/>
|
||||
<result property="backHoleCount" column="back_hole_count"/>
|
||||
<result property="sideHoleCount" column="side_hole_count"/>
|
||||
<result property="backModelCount" column="back_model_count"/>
|
||||
<result property="isDoor" column="is_door"/>
|
||||
<result property="openDoorType" column="open_door_type"/>
|
||||
<result property="offsetX" column="offset_x"/>
|
||||
<result property="offsetY" column="offset_y"/>
|
||||
<result property="isArcAcross" column="is_arc_across"/>
|
||||
<result property="moduleTypeId" column="module_typeId"/>
|
||||
<result property="filterType" column="filter_type"/>
|
||||
<result property="filterType" column="filter_type"/>
|
||||
<result property="isCancel" column="is_cancel"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
</collection>
|
||||
</resultMap>
|
||||
|
||||
|
||||
<select id="selectPlateListByPlanId"
|
||||
resultType="com.cf.imes.module.executor.controller.admin.plan.vo.PlateOptimize">
|
||||
select a.goods_id, a.goods_name, a.material, a.color, a.width, a.height, a.thickness, count(b.id) as plateNum, d.*
|
||||
@@ -30,4 +80,15 @@
|
||||
GROUP BY a.id, d.id
|
||||
|
||||
</select>
|
||||
|
||||
<select id="getOptimizePlanParam" resultMap="optimizeMap">
|
||||
select op.*, oi.order_id, opl.id as plateId, opl.*, og.*
|
||||
from order_plan op
|
||||
left JOIN order_plan_item opi on op.id = opi.plan_id
|
||||
left join order_item oi on opi.item_id = oi.id
|
||||
left join order_plate opl on oi.plate_id = opl.id
|
||||
left join order_goods og on opl.goods_id = og.goods_id
|
||||
where op.id = #{planId}
|
||||
|
||||
</select>
|
||||
</mapper>
|
||||
Reference in New Issue
Block a user