| | |
| | | columns:[ |
| | | {type:'expand',fixed:"left",width: 80}, |
| | | {type: 'seq',fixed:"left", title: '自序', width: 80 }, |
| | | {field: '1', width: 120, title: '报工时间',filters:[{ data: '' }],slots: { filter: 'num1_filter' }, sortable: true, }, |
| | | {field: '2',width: 120, title: '责任工序', sortable: true,showOverflow:"ellipsis" ,filters:[{ data: '' }],slots: { filter: 'num1_filter' }}, |
| | | {field: '3', width: 130,title: '责任班组', sortable: true,filters:[{ data: '' }],slots: { filter: 'num1_filter' }}, |
| | | {field: '5', width: 100,title: '次破类型', sortable: true,showOverflow:"ellipsis"}, |
| | | {field: '5', width: 100,title: '次破原因', sortable: true,showOverflow:"ellipsis"}, |
| | | {field: '6', width: 100,title: '次破数量', sortable: true}, |
| | | {field: '7',width: 100, title: '次破面积', sortable: true}, |
| | | {field: '9', width: 120,title: '项目名称', sortable: true}, |
| | | {field: '11',width: 120, title: '销售单号', sortable: true}, |
| | | {field: '12',width: 120, title: '单品名称', sortable: true}, |
| | | {field: '13',width: 120, title: '产地', sortable: true}, |
| | | {field: 'reportingWork.reportingWorkTime', width: 120, title: '报工时间',filters:[{ data: '' }],slots: { filter: 'num1_filter' }, sortable: true, }, |
| | | {field: 'responsibleProcess',width: 120, title: '责任工序', sortable: true,showOverflow:"ellipsis" ,filters:[{ data: '' }],slots: { filter: 'num1_filter' }}, |
| | | {field: 'responsibleTeam', width: 130,title: '责任班组', sortable: true,filters:[{ data: '' }],slots: { filter: 'num1_filter' }}, |
| | | {field: 'breakageType', width: 100,title: '次破类型', sortable: true,showOverflow:"ellipsis"}, |
| | | {field: 'breakageReason', width: 100,title: '次破原因', sortable: true,showOverflow:"ellipsis"}, |
| | | {field: 'breakageQuantity', width: 100,title: '次破数量', sortable: true}, |
| | | {field: 'area',width: 100, title: '次破面积', sortable: true}, |
| | | {field: 'order.project', width: 120,title: '项目名称', sortable: true}, |
| | | {field: 'order.orderId',width: 120, title: '销售单号', sortable: true}, |
| | | {field: 'orderGlassDetail.glassChild',width: 120, title: '单品名称', sortable: true}, |
| | | ],//表格表头字段 |
| | | data:[],//表格数据 |
| | | url :'/report/crossProcessBreaking', |
| | |
| | | package com.example.erp.entity.pp; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.example.erp.entity.sd.Order; |
| | | import com.example.erp.entity.sd.OrderGlassDetail; |
| | | import com.example.erp.entity.sd.Product; |
| | | import lombok.Data; |
| | | |
| | | |
| | |
| | | private Integer qualityInsStatus; |
| | | //数量 |
| | | private Integer quantity; |
| | | |
| | | @TableField(select = false,exist = false) |
| | | private String area; |
| | | |
| | | @TableField(select = false,exist = false) |
| | | private ReportingWork reportingWork; |
| | | |
| | | @TableField(select = false,exist = false) |
| | | private Order order; |
| | | |
| | | @TableField(select = false,exist = false) |
| | | private OrderGlassDetail orderGlassDetail; |
| | | } |
| | |
| | | Map<String,Object> map = new HashMap<>(); |
| | | map.put("data",reportMapper.getProcessBreaking(offset, pageSize, startDate, endDate, damageDetails)); |
| | | map.put("total",reportMapper.getProcessBreakingTotal(offset, pageSize, startDate, endDate, damageDetails)); |
| | | System.out.println(reportMapper.getProcessBreaking(offset, pageSize, startDate, endDate, damageDetails)); |
| | | List<String> list = new ArrayList<>(); |
| | | list.add(startDate); |
| | | list.add(endDate); |
| | |
| | | <result column="total_thickness" property="totalThickness"/> |
| | | <result column="thickness" property="thickness"/> |
| | | </association> |
| | | |
| | | |
| | | <!--<result column="g_typeId" property="glassTypes.typeId"/> |
| | | <result column="g_type" property="glassTypes.type"/>--> |
| | | |
| | | |
| | | </resultMap> |
| | | |
| | | |
| | | <resultMap id="damageDetailsTableMap" type="com.example.erp.entity.pp.DamageDetails"> |
| | | <result column="responsible_process" property="responsibleProcess"/> |
| | | <result column="responsible_team" property="responsibleTeam"/> |
| | | <result column="breakage_type" property="breakageType"/> |
| | | <result column="breakage_reason" property="breakageReason"/> |
| | | <result column="breakage_quantity" property="breakageQuantity"/> |
| | | <result column="area" property="area"/> |
| | | <result column="reporting_work_id" property="reportingWork.reportingWorkId"/> |
| | | <result column="reporting_work_time" property="reportingWork.reportingWorkTime"/> |
| | | <result column="this_process" property="reportingWork.thisProcess"/> |
| | | <result column="project" property="order.project"/> |
| | | <result column="order_id" property="order.orderId"/> |
| | | <result column="glass_child" property="orderGlassDetail.glassChild"/> |
| | | </resultMap> |
| | | |
| | | |
| | | <!-- 流程卡进度--> |
| | | <select id="processCardProgressMp"> |
| | | select |
| | |
| | | |
| | | </select> |
| | | |
| | | <select id="getProcessBreaking" resultMap="flowCardMap"> |
| | | <select id="getProcessBreaking" resultMap="damageDetailsTableMap"> |
| | | select rw.reporting_work_id,rw.reporting_work_time,dd.responsible_process,dd.responsible_team, |
| | | dd.breakage_type,dd.breakage_reason,ROUND(SUM(dd.breakage_quantity)), |
| | | round(ogd.child_width*ogd.child_height*SUM(dd.breakage_quantity)/1000000,2),rw.this_process, |
| | | dd.breakage_type,dd.breakage_reason,ROUND((dd.breakage_quantity)) as breakage_quantity, |
| | | round(ogd.child_width*ogd.child_height*(dd.breakage_quantity)/1000000,2) as area,rw.this_process, |
| | | o.project,o.order_id,ogd.glass_child |
| | | from |
| | | damage_details as dd |
| | |
| | | and reviewed_state!=2 |
| | | and rw.this_process!=dd.responsible_process |
| | | GROUP BY dd.id |
| | | order by dd.reporting_work_id desc |
| | | order by dd.id desc |
| | | limit #{offset},#{pageSize} |
| | | </select> |
| | | |
| | |
| | | <result column="total_thickness" property="totalThickness"/> |
| | | <result column="thickness" property="thickness"/> |
| | | </association> |
| | | |
| | | |
| | | <!--<result column="g_typeId" property="glassTypes.typeId"/> |
| | | <result column="g_type" property="glassTypes.type"/>--> |
| | | |
| | | |
| | | </resultMap> |
| | | |
| | | |
| | | <resultMap id="damageDetailsTableMap" type="com.example.erp.entity.pp.DamageDetails"> |
| | | <result column="responsible_process" property="responsibleProcess"/> |
| | | <result column="responsible_team" property="responsibleTeam"/> |
| | | <result column="breakage_type" property="breakageType"/> |
| | | <result column="breakage_reason" property="breakageReason"/> |
| | | <result column="breakage_quantity" property="breakageQuantity"/> |
| | | <result column="area" property="area"/> |
| | | <result column="reporting_work_id" property="reportingWork.reportingWorkId"/> |
| | | <result column="reporting_work_time" property="reportingWork.reportingWorkTime"/> |
| | | <result column="this_process" property="reportingWork.thisProcess"/> |
| | | <result column="project" property="order.project"/> |
| | | <result column="order_id" property="order.orderId"/> |
| | | <result column="glass_child" property="orderGlassDetail.glassChild"/> |
| | | </resultMap> |
| | | |
| | | |
| | | <!-- 流程卡进度--> |
| | | <select id="processCardProgressMp"> |
| | | select |
| | |
| | | |
| | | </select> |
| | | |
| | | <select id="getProcessBreaking" resultMap="flowCardMap"> |
| | | <select id="getProcessBreaking" resultMap="damageDetailsTableMap"> |
| | | select rw.reporting_work_id,rw.reporting_work_time,dd.responsible_process,dd.responsible_team, |
| | | dd.breakage_type,dd.breakage_reason,ROUND(SUM(dd.breakage_quantity)), |
| | | round(ogd.child_width*ogd.child_height*SUM(dd.breakage_quantity)/1000000,2),rw.this_process, |
| | | dd.breakage_type,dd.breakage_reason,ROUND((dd.breakage_quantity)) as breakage_quantity, |
| | | round(ogd.child_width*ogd.child_height*(dd.breakage_quantity)/1000000,2) as area,rw.this_process, |
| | | o.project,o.order_id,ogd.glass_child |
| | | from |
| | | damage_details as dd |
| | |
| | | and reviewed_state!=2 |
| | | and rw.this_process!=dd.responsible_process |
| | | GROUP BY dd.id |
| | | order by dd.reporting_work_id desc |
| | | order by dd.id desc |
| | | limit #{offset},#{pageSize} |
| | | </select> |
| | | |