廖井涛
2025-08-25 fec9f42e00f2df68a2a20cbf132b17bdeed8e63a
Merge remote-tracking branch 'origin/master'

# Conflicts:
# north-glass-erp/northglass-erp/src/views/sd/order/CreateOrder2.vue
8个文件已修改
253 ■■■■ 已修改文件
north-glass-erp/northglass-erp/src/router/index.js 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
north-glass-erp/northglass-erp/src/views/pp/report/OrderPlanDecomposition.vue 22 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
north-glass-erp/northglass-erp/src/views/pp/report/OrderReportingWorks.vue 22 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
north-glass-erp/northglass-erp/src/views/pp/report/ProcessToBeCompleted.vue 56 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
north-glass-erp/northglass-erp/src/views/pp/report/WorkInProgress.vue 15 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
north-glass-erp/northglass-erp/src/views/sd/order/CreateOrder.vue 18 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
north-glass-erp/src/main/resources/mapper/pp/Report.xml 100 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
north-glass-erp/src/main/resources/mapper/sd/OrderProcessDetailMapper.xml 15 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
north-glass-erp/northglass-erp/src/router/index.js
@@ -217,6 +217,11 @@
              component: () => import('../views/sd/order/CreateOrder.vue'),
            },
            {
              path: 'createOrder2',
              name: 'createOrder2',
              component: () => import('../views/sd/order/CreateOrder2.vue'),
            },
            {
              path: 'updateOrderCraft',
              name: 'updateOrderCraft',
              component: () => import('../views/sd/order/UpdateOrderCraft.vue'),
north-glass-erp/northglass-erp/src/views/pp/report/OrderPlanDecomposition.vue
@@ -1,6 +1,6 @@
<script setup>
import {reactive, ref} from "vue";
import {onMounted, reactive, ref} from "vue";
import {useRouter} from 'vue-router'
import request from "@/utils/request";
import deepClone from "@/utils/deepClone";
@@ -9,6 +9,8 @@
import {changeFilterEvent, filterChanged} from "@/hook"
import exportExcel from "@/hook/exportExcel";
import footSum from "@/hook/footSum"
import {addListener} from "@/hook/mouseMove";
import {VxeUI} from "vxe-pc-ui";
//语言获取
const {t} = useI18n()
let router = useRouter()
@@ -65,6 +67,11 @@
  return [start, end]
}
onMounted(() => {
  //启用表格拖动选中
  addListener(xGrid.value, gridOptions)
})
//第一次加载获取近七天时间和默认状态
form.date1 = getNowTime()
@@ -298,7 +305,9 @@
})
const handleCellDblClick = ({ row, column, cell, $event }) => {
  VxeUI.clipboard.copy(row[column.property])
}
</script>
<template>
@@ -322,7 +331,7 @@
          class="mytable-scrollbar"
          height="100%"
          v-bind="gridOptions"
          @cell-dblclick="handleCellDblClick"
      >
        <!--      @toolbar-button-click="toolbarButtonClickEvent"-->
        <!--      下拉显示所有信息插槽-->
@@ -368,4 +377,11 @@
  width: 100%;
  height: calc(100% - 35px);
}
.vxe-grid {
  /* 禁用浏览器默认选中 */
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}
</style>
north-glass-erp/northglass-erp/src/views/pp/report/OrderReportingWorks.vue
@@ -1,6 +1,6 @@
<script setup>
import {reactive, ref} from "vue";
import {onMounted, reactive, ref} from "vue";
import {useRouter} from 'vue-router'
import request from "@/utils/request";
import deepClone from "@/utils/deepClone";
@@ -10,6 +10,8 @@
import exportExcel from "@/hook/exportExcel";
import footSum from "@/hook/footSum"
import moment from "moment";
import {VxeUI} from "vxe-pc-ui";
import {addListener} from "@/hook/mouseMove";
//语言获取
const {t} = useI18n()
let router = useRouter()
@@ -105,7 +107,10 @@
  }
})
onMounted(() => {
  //启用表格拖动选中
  addListener(xGrid.value, gridOptions)
})
//点击查询
const getWorkOrder = () => {
@@ -259,7 +264,9 @@
})
const handleCellDblClick = ({ row, column, cell, $event }) => {
  VxeUI.clipboard.copy(row[column.property])
}
</script>
<template>
@@ -283,7 +290,7 @@
          class="mytable-scrollbar"
          height="100%"
          v-bind="gridOptions"
          @cell-dblclick="handleCellDblClick"
      >
        <!--      @toolbar-button-click="toolbarButtonClickEvent"-->
        <!--      下拉显示所有信息插槽-->
@@ -336,4 +343,11 @@
  width: 100%;
  height: calc(100% - 35px);
}
.vxe-grid {
  /* 禁用浏览器默认选中 */
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}
</style>
north-glass-erp/northglass-erp/src/views/pp/report/ProcessToBeCompleted.vue
@@ -1,6 +1,6 @@
<script setup>
import {reactive, ref} from "vue";
import {onMounted, reactive, ref} from "vue";
import {useRouter} from 'vue-router'
import request from "@/utils/request";
import deepClone from "@/utils/deepClone";
@@ -8,6 +8,8 @@
import {useI18n} from 'vue-i18n'
import {changeFilterEvent, filterChanged} from "@/hook"
import footSum from "@/hook/footSum"
import {VxeUI} from "vxe-pc-ui";
import {addListener} from "@/hook/mouseMove";
//语言获取
const {t} = useI18n()
let router = useRouter()
@@ -64,6 +66,10 @@
  return [start, end]
}
onMounted(() => {
  //启用表格拖动选中
  addListener(xGrid.value, gridOptions)
})
//第一次加载获取近七天时间和默认状态
form.date1 = getNowTime()
@@ -273,15 +279,33 @@
    {field: 'glass_child', width: 100, title: t('reportingWorks.glassChild'), filters: [{data: ''}],
      slots: {filter: 'num1_filter'},
      filterMethod: filterChanged},
    {field: 'child_width', width: 120, title: t('order.width')},
    {field: 'child_height', width: 120, title: t('order.height')},
    {field: 'quantity', width: 120, title: t('order.quantity')},
    {field: 'childArea', width: 120, title: t('order.trueArea')},
    {field: 'actualArea', width: 120, title: t('order.trueGrossArea')},
    {field: 'completeNum', width: 120, title: t('report.completedQuantity')},
    {field: 'completeArea', width: 120, title: t('report.completedArea')},
    {field: 'incompleteNum', width: 120, title: t('report.unfinishedQuantity')},
    {field: 'incompleteArea', width: 120, title: t('report.unfinishedArea')},
    {field: 'child_width', width: 120, title: t('order.width'),filters: [{data: ''}],
      slots: {filter: 'num1_filter'},
      filterMethod: filterChanged},
    {field: 'child_height', width: 120, title: t('order.height'),filters: [{data: ''}],
      slots: {filter: 'num1_filter'},
      filterMethod: filterChanged},
    {field: 'quantity', width: 120, title: t('order.quantity'),filters: [{data: ''}],
      slots: {filter: 'num1_filter'},
      filterMethod: filterChanged},
    {field: 'childArea', width: 130, title: t('order.trueArea'),filters: [{data: ''}],
      slots: {filter: 'num1_filter'},
      filterMethod: filterChanged},
    {field: 'actualArea', width: 130, title: t('order.trueGrossArea'),filters: [{data: ''}],
      slots: {filter: 'num1_filter'},
      filterMethod: filterChanged},
    {field: 'completeNum', width: 120, title: t('report.completedQuantity'),filters: [{data: ''}],
      slots: {filter: 'num1_filter'},
      filterMethod: filterChanged},
    {field: 'completeArea', width: 120, title: t('report.completedArea'),filters: [{data: ''}],
      slots: {filter: 'num1_filter'},
      filterMethod: filterChanged},
    {field: 'incompleteNum', width: 120, title: t('report.unfinishedQuantity'),filters: [{data: ''}],
      slots: {filter: 'num1_filter'},
      filterMethod: filterChanged},
    {field: 'incompleteArea', width: 120, title: t('report.unfinishedArea'),filters: [{data: ''}],
      slots: {filter: 'num1_filter'},
      filterMethod: filterChanged},
    {field: 'product_name', width: 120, title: t('order.product'), filters: [{data: ''}],
      slots: {filter: 'num1_filter'},
      filterMethod: filterChanged},
@@ -370,6 +394,9 @@
  })
}
const handleCellDblClick = ({ row, column, cell, $event }) => {
  VxeUI.clipboard.copy(row[column.property])
}
</script>
<template>
@@ -408,6 +435,7 @@
          class="mytable-scrollbar"
          height="100%"
          v-bind="gridOptions"
          @cell-dblclick="handleCellDblClick"
      >
        <!--      @toolbar-button-click="toolbarButtonClickEvent"-->
@@ -462,4 +490,12 @@
  width: 100%;
  height: calc(100% - 35px);
}
.vxe-grid {
  /* 禁用浏览器默认选中 */
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}
</style>
north-glass-erp/northglass-erp/src/views/pp/report/WorkInProgress.vue
@@ -344,11 +344,16 @@
      slots: {filter: 'num1_filter'}, showOverflow: "ellipsis",visible: true},
    {field: 'shape', width: 100, title: t('order.shape'),visible: true},
    {field: 'process', width: 120, title: t('craft.process'),visible: true},
    {field: 'quantity', width: 120, title: t('order.quantity'),visible: true},
    {field: 'childWidth', width: 120, title: t('order.width'),visible: true},
    {field: 'childHeight', width: 120, title: t('order.height'),visible: true},
    {field: 'stockNum', width: 120, title: t('productStock.inventoryQuantity'),visible: true},
    {field: 'stockArea', width: 120, title: t('report.inventoryArea'),visible: true},
    {field: 'quantity', width: 120, title: t('order.quantity'),visible: true,filters: [{data: ''}],
      slots: {filter: 'num1_filter'},},
    {field: 'childWidth', width: 120, title: t('order.width'),visible: true,filters: [{data: ''}],
      slots: {filter: 'num1_filter'},},
    {field: 'childHeight', width: 120, title: t('order.height'),visible: true,filters: [{data: ''}],
      slots: {filter: 'num1_filter'},},
    {field: 'stockNum', width: 120, title: t('productStock.inventoryQuantity'),visible: true,filters: [{data: ''}],
      slots: {filter: 'num1_filter'},},
    {field: 'stockArea', width: 120, title: t('report.inventoryArea'),visible: true,filters: [{data: ''}],
      slots: {filter: 'num1_filter'},},
    {field: 'productName', width: 120, title:  t('order.product'),visible: true},
    {field: 'glassName', width: 120, title:  t('report.workProcessName'),visible: true},
    {field: 'bendRadius', width: 120, title: t('order.bendRadius'),visible: true},
north-glass-erp/northglass-erp/src/views/sd/order/CreateOrder.vue
@@ -390,6 +390,24 @@
            const grossAreaList = $grid.getTableData().fullData.filter(
                item=>item.grossArea === 0
            )
            //判断宽高相乘与字段结算面积是否相同
            $grid.getTableData().fullData.forEach((item,index)=>{
            })
            for (const i in $grid.getTableData().fullData) {
              const item = $grid.getTableData().fullData[i]
              const grossArea =  countArea(item)
              if(item.grossArea !== grossArea ){
                ElMessage.warning(`${t('order.OrderNum')}
                ${Number(i)+1}${t('order.area')}: ${grossArea} != ${item.grossArea}`)
                return
              }
            }
            const errorAreaList = $grid.getTableData().fullData.filter(
                item=>(item.width*item.height/1000000 < errorArea.value*1)
            )
north-glass-erp/src/main/resources/mapper/pp/Report.xml
@@ -1367,56 +1367,74 @@
    <select id="teamOutputMp" resultMap="teamOutputMap">
        SELECT
        *
        FROM
        (
        SELECT
        rw.reporting_work_time,
        rw.this_process,
        rw.teams_groups_name,
        o.project,
        rw.process_id,
        fc.order_number,
        MAX( ogd.child_width ) as width,
        MAX( ogd.child_height ) as height,
        MAX(ogd.child_width)  AS width,
        MAX(ogd.child_height) AS height,
        od.edging_type,
        rwd.completed_quantity as completed_quantity,
        ROUND(MAX( ogd.child_width )*MAX( ogd.child_height )*rwd.completed_quantity/1000000,2) as area,
        rwd.completed_quantity AS completed_quantity,
        ROUND(MAX(ogd.child_width) * MAX(ogd.child_height) * rwd.completed_quantity / 1000000, 2) AS area,
        od.product_name,
        JSON_UNQUOTE( JSON_EXTRACT( od.other_columns, '$.S01' )) AS code,
        JSON_UNQUOTE(JSON_EXTRACT(od.other_columns, '$.S01')) AS code,
        rw.reviewed,
        rw.examine_time,
        rw.device_name,
        o.order_type,
--         GROUP_CONCAT(ogd.glass_child SEPARATOR '+') as workProcessName
        CASE
        WHEN LOCATE('step',#{laminating})>0 THEN GROUP_CONCAT(ogd.glass_child SEPARATOR '+')
        ELSE MAX( ogd.glass_child )
        WHEN LOCATE('step', #{laminating}) > 0 THEN GROUP_CONCAT(ogd.glass_child SEPARATOR '+')
        ELSE MAX(ogd.glass_child)
        END AS workProcessName,
            o.batch
        o.batch
        FROM
        reporting_work as rw left join reporting_work_detail as rwd on rwd.reporting_work_id=rw.reporting_work_id
        left join flow_card as fc on fc.order_id=rw.order_id and fc.process_id=rw.process_id  and fc.order_number=rwd.order_number and fc.technology_number=rwd.technology_number
        left join sd.order_glass_detail as ogd on ogd.order_id=fc.order_id and ogd.order_number=fc.order_number and ogd.technology_number=fc.technology_number
        left join sd.order_detail as od  on od.order_id=ogd.order_id and od.order_number=ogd.order_number
        left join sd.`order` as o on o.order_id=od.order_id
        where o.create_order>0 and rw.reviewed_state>=0 and rwd.completed_quantity>0 and
        rw.reporting_work_time >= #{selectTime1}
        reporting_work AS rw
        LEFT JOIN reporting_work_detail AS rwd
        ON rwd.reporting_work_id = rw.reporting_work_id
        LEFT JOIN flow_card AS fc
        ON fc.order_id = rw.order_id
        AND fc.process_id = rw.process_id
        AND fc.order_number = rwd.order_number
        AND fc.technology_number = rwd.technology_number
        LEFT JOIN sd.order_glass_detail AS ogd
        ON ogd.order_id = fc.order_id
        AND ogd.order_number = fc.order_number
        AND ogd.technology_number = fc.technology_number
        LEFT JOIN sd.order_detail AS od
        ON od.order_id = ogd.order_id
        AND od.order_number = ogd.order_number
        LEFT JOIN sd.`order` AS o
        ON o.order_id = od.order_id
        WHERE
        o.create_order > 0
        AND rw.reviewed_state >= 0
        AND rwd.completed_quantity > 0
        AND rw.reporting_work_time &gt;= #{selectTime1}
        AND rw.reporting_work_time &lt;  #{selectTime2}
        and position(#{selectProcesses} in rw.this_process)
        AND POSITION(#{selectProcesses} IN rw.this_process)
        <if test="teamOutputDTO.thisProcess != null and teamOutputDTO.thisProcess != ''">
            and rw.this_process regexp #{teamOutputDTO.thisProcess}
            AND rw.this_process REGEXP #{teamOutputDTO.thisProcess}
        </if>
        <if test="teamOutputDTO.teamsGroupsName != null and teamOutputDTO.teamsGroupsName != ''">
            and rw.teams_groups_name regexp #{teamOutputDTO.teamsGroupsName}
            AND rw.teams_groups_name REGEXP #{teamOutputDTO.teamsGroupsName}
        </if>
        <if test="teamOutputDTO.project != null and teamOutputDTO.project != ''">
            and o.project regexp #{teamOutputDTO.project}
            AND o.project REGEXP #{teamOutputDTO.project}
        </if>
        <if test="teamOutputDTO.processId != null and teamOutputDTO.processId != ''">
            and rw.process_id regexp #{teamOutputDTO.processId}
            AND rw.process_id REGEXP #{teamOutputDTO.processId}
        </if>
        <if test="teamOutputDTO.edgingType != null and teamOutputDTO.edgingType != ''">
            and od.edging_type regexp #{teamOutputDTO.edgingType}
            AND od.edging_type REGEXP #{teamOutputDTO.edgingType}
        </if>
        <if test="teamOutputDTO.deviceName != null and teamOutputDTO.deviceName != ''">
            and rw.device_name regexp #{teamOutputDTO.deviceName}
            AND rw.device_name REGEXP #{teamOutputDTO.deviceName}
        </if>
        <choose>
@@ -1431,7 +1449,7 @@
            </when>
            <otherwise>
                GROUP BY
                <if test="laminating == 'stepA' || laminating == 'stepC'" >
                <if test="laminating == 'stepA' || laminating == 'stepC'">
                    ogd.`group`,
                </if>
                rw.reporting_work_id,
@@ -1439,16 +1457,20 @@
                rw.this_process,
                rw.teams_groups_name,
                rwd.order_number
            </otherwise>
        </choose>
        ) t
        WHERE 1 = 1
        <if test="teamOutputDTO.workProcessName != null and teamOutputDTO.workProcessName != ''">
            AND t.workProcessName REGEXP #{teamOutputDTO.workProcessName}
        </if>
        ORDER BY
        rw.this_process,
        rw.process_id,
        rwd.order_number,
        rw.reporting_work_time,
        rw.teams_groups_name
        limit #{offset},#{pageSize};
        t.this_process,
        t.process_id,
        t.order_number,
        t.reporting_work_time,
        t.teams_groups_name
        LIMIT #{offset}, #{pageSize};
    </select>
    <select id="exportTeamOutputMp">
@@ -2341,6 +2363,22 @@
        <if test="workInProgressDTO.technologyNumber != null and workInProgressDTO.technologyNumber != ''">
            and ogd.technology_number regexp #{workInProgressDTO.technologyNumber}
        </if>
        <if test="workInProgressDTO.quantity != null and workInProgressDTO.quantity != ''">
            and od.quantity regexp #{workInProgressDTO.quantity}
        </if>
        <if test="workInProgressDTO.childWidth != null and workInProgressDTO.childWidth != ''">
            and ogd.child_width regexp #{workInProgressDTO.childWidth}
        </if>
        <if test="workInProgressDTO.childHeight != null and workInProgressDTO.childHeight != ''">
            and ogd.child_height regexp #{workInProgressDTO.childHeight}
        </if>
        <if test="workInProgressDTO.stockNum != null and workInProgressDTO.stockNum != ''">
            and (d.numCounts + d.patchNumSum - d.numCount -d.broken_num) regexp #{workInProgressDTO.stockNum}
        </if>
        <if test="workInProgressDTO.stockArea != null and workInProgressDTO.stockArea != ''">
            and ROUND(ogd.child_width * ogd.child_height * (d.numCounts + d.patchNumSum - d.numCount -
            d.broken_num) / 1000000, 2) regexp #{workInProgressDTO.stockArea}
        </if>
        <if test="workInProgressDTO.glassNumber != null and workInProgressDTO.glassNumber != ''">
            and ifnull(JSON_UNQUOTE(JSON_EXTRACT(od.other_columns, '$.S01')),'') regexp #{workInProgressDTO.glassNumber}
        </if>
north-glass-erp/src/main/resources/mapper/sd/OrderProcessDetailMapper.xml
@@ -214,13 +214,24 @@
    </select>
    <select id="selectShiftQuantitySv">
        select *,sum(break) as 'breakage_quantity' from(select CAST(concat(b.order_id,'/',a.order_number,'/',a.technology_number) as char ) as 'order_id',
        select *
        <if test="step != null and step != ''">
            ,sum(e.break) as 'breakage_quantity'
            ,Round(sum(e.break)*e.area,2) as 'breakage_area'
        </if>
        <if test="step == null || step == ''">
            ,e.break as 'breakage_quantity'
            ,Round(e.break*e.area,2) as 'breakage_area'
        </if>
        from(select CAST(concat(b.order_id,'/',a.order_number,'/',a.technology_number) as char ) as 'order_id',
               c.child_width,
               c.child_height,
               a.completed_quantity,
               a.breakage_quantity as break,
               a.order_number,
               b.reporting_work_id
               b.reporting_work_id,
               round(c.area*a.completed_quantity,2) as finish_area,
               c.area
        from pp.reporting_work as b
        left join pp.reporting_work_detail as a
            on a.reporting_work_id = b.reporting_work_id