From f0c673877d2dd1bdeea0e1ddb6a7222c9e012f95 Mon Sep 17 00:00:00 2001
From: Mr.Zhang <710666463@qq.com>
Date: 星期四, 17 八月 2023 09:32:39 +0800
Subject: [PATCH] Merge commit 'd044dc871c16f05c9a1fb1489621020c91ec9d59'

---
 h5_standard/src/views/workOrder/reportingForWork.vue                                    | 1853 +++++++++---------------
 h5_standard/src/views/wxLogin.vue                                                       |    4 
 server/src/main/java/doumeemes/service/ext/impl/WorkPlansExtServiceImpl.java            |   12 
 server/src/main/resources/mappers/WorkorderRecordExtMapper.xml                          |   12 
 server/src/main/java/doumeemes/service/ext/CategoryExtService.java                      |    2 
 h5_standard/src/apis/PlanningAPI.ts                                                     |   44 
 server/src/main/java/doumeemes/config/shiro/ShiroRealm.java                             |    7 
 server/src/main/java/doumeemes/service/business/impl/WOutboundServiceImpl.java          |    3 
 server/src/main/java/doumeemes/service/ext/impl/WorkorderRecordStandardServiceImpl.java |  276 ++-
 h5_standard/.env.production                                                             |    4 
 h5_standard/src/views/workOrder/afterWorkReport.vue                                     |   20 
 h5_standard/src/views/workOrder/processPlan.vue                                         |  232 +++
 server/src/main/java/doumeemes/service/business/impl/UnqualifiedRecordServiceImpl.java  |  124 +
 server/src/main/java/doumeemes/api/ext/CategoryExtController.java                       |    9 
 h5_standard/src/views/LogInAgain.vue                                                    |    2 
 server/src/main/java/doumeemes/dao/ext/vo/CompanyExtListVO.java                         |    3 
 h5_standard/src/components/newCom/productionProcess.vue                                 |  258 +++
 server/src/main/java/doumeemes/api/business/SalaryParamController.java                  |   28 
 server/src/main/java/doumeemes/core/utils/excel/EasyExcelUtil.java                      |    5 
 server/src/main/resources/mappers/PlansExtMapper.xml                                    |   24 
 h5_standard/src/main.ts                                                                 |    3 
 h5_standard/src/apis/ExWarehouse.ts                                                     |    9 
 server/src/main/java/doumeemes/dao/business/model/UnqualifiedRecord.java                |   79 +
 server/src/main/java/doumeemes/dao/ext/vo/BomExtListVO.java                             |    7 
 server/src/main/resources/mappers/UserDeviceExtMapper.xml                               |    2 
 h5_standard/src/views/workOrder/index.vue                                               |    3 
 server/src/main/java/doumeemes/service/ext/impl/CategoryExtServiceImpl.java             |    6 
 server/src/main/java/doumeemes/dao/business/vo/WorkPlansVO.java                         |   30 
 server/src/main/java/doumeemes/dao/business/vo/SalaryParamVO.java                       |   23 
 server/src/main/java/doumeemes/dao/ext/dto/SalaryParamImportDTO.java                    |    8 
 server/src/main/java/doumeemes/api/business/UnqualifiedRecordController.java            |   71 
 server/src/main/java/doumeemes/service/business/impl/CompanyServiceImpl.java            |   45 
 server/src/main/java/doumeemes/service/ext/impl/PlansExtServiceImpl.java                |   80 
 server/src/main/java/doumeemes/service/business/UnqualifiedRecordService.java           |   97 +
 h5_standard/src/components/common/Access.vue                                            |    2 
 h5_standard/src/components/newCom/quality.vue                                           |    1 
 server/src/main/java/doumeemes/dao/business/UnqualifiedRecordMapper.java                |   12 
 h5_standard/src/components/newCom/location.vue                                          |    2 
 h5_standard/src/views/needToBeDealtWith/addWarehousing.vue                              |   66 
 server/src/main/resources/mappers/SalaryParamMapper.xml                                 |    8 
 server/src/main/java/doumeemes/api/ext/SalaryParamExtController.java                    |    2 
 h5_standard/src/views/needToBeDealtWith/outbound.vue                                    |    4 
 server/src/main/java/doumeemes/dao/business/dto/AutoWorkReportDTO.java                  |    3 
 server/src/main/resources/mappers/WorkPlansExtMapper.xml                                |    6 
 h5_standard/src/components/newCom/Material.vue                                          |   45 
 server/src/main/java/doumeemes/dao/business/dto/CreateUnqualifiedDTO.java               |   23 
 server/src/main/java/doumeemes/service/business/impl/CompanyOpenServiceImpl.java        |   21 
 server/src/main/java/doumeemes/dao/ext/dto/QueryUserSalaryListDTO.java                  |    4 
 server/src/main/java/doumeemes/dao/ext/dto/QueryPlansExtDTO.java                        |    4 
 h5_standard/src/components/newCom/user.vue                                              |  330 ++++
 h5_standard/src/router/module/workOrder/index.ts                                        |   11 
 server/src/main/java/doumeemes/service/business/impl/SalaryParamServiceImpl.java        |   30 
 h5_standard/src/assets/icon/ic_ar@2x.png                                                |    0 
 h5_standard/.env.development                                                            |    5 
 server/src/main/java/doumeemes/api/ext/PlansExtController.java                          |    1 
 server/src/main/java/doumeemes/service/ext/impl/DepartmentExtServiceImpl.java           |    4 
 h5_standard/src/assets/icon/ic_close@2x.png                                             |    0 
 server/src/main/java/doumeemes/dao/ext/vo/PlansExtListVO.java                           |   45 
 h5_standard/src/components/newCom/MaterialY.vue                                         |  417 +++++
 59 files changed, 3,005 insertions(+), 1,426 deletions(-)

diff --git a/h5_standard/.env.development b/h5_standard/.env.development
index 506a37f..386cd58 100644
--- a/h5_standard/.env.development
+++ b/h5_standard/.env.development
@@ -13,9 +13,10 @@
 # VUE_APP_API = 'http://192.168.0.12:10012/'
 
 # 浠诲悍鏈湴
-# VUE_APP_API = 'http://192.168.0.15:10021/'
+VUE_APP_API = 'http://192.168.0.15:10021/'
+# VUE_APP_API = 'http://192.168.0.127:10021/'
 
-VUE_APP_API = 'https://dmtest.ahapp.net/doumeeplant_api/'
+# VUE_APP_API = 'https://dmtest.ahapp.net/doumeeplant_api/'
 
 # VUE_APP_API = 'http://192.168.0.13:10012/'
 
diff --git a/h5_standard/.env.production b/h5_standard/.env.production
index c874a31..af03e19 100644
--- a/h5_standard/.env.production
+++ b/h5_standard/.env.production
@@ -18,7 +18,7 @@
 # VUE_APP_API = 'https://hsky.doumee.com/doumeeplant_api/'
 
 # 娴嬭瘯
-# VUE_APP_API = 'https://dmtest.ahapp.net/doumeeplant_api/'
+VUE_APP_API = 'https://dmtest.ahapp.net/doumeeplant_api/'
 
 # 婕旂ず
-VUE_APP_API = 'https://www.mes.red/doumeeplant/'
+# VUE_APP_API = 'https://www.mes.red/doumeeplant/'
diff --git a/h5_standard/src/apis/ExWarehouse.ts b/h5_standard/src/apis/ExWarehouse.ts
index 680857c..e102b65 100644
--- a/h5_standard/src/apis/ExWarehouse.ts
+++ b/h5_standard/src/apis/ExWarehouse.ts
@@ -186,4 +186,13 @@
         method: 'post',
         data
     })
+}
+
+// 鏍规嵁渚涢渶璁″垝鏌ヨ鍙敤搴撳瓨
+export function getStockByPlansForStandard(data: any): Promise<any> {
+    return httpRequest({
+        url:  '/ext/workorderRecordExt/getStockByPlansForStandard',
+        method: 'post',
+        data
+    })
 }
\ No newline at end of file
diff --git a/h5_standard/src/apis/PlanningAPI.ts b/h5_standard/src/apis/PlanningAPI.ts
index 2454c45..c4d5099 100644
--- a/h5_standard/src/apis/PlanningAPI.ts
+++ b/h5_standard/src/apis/PlanningAPI.ts
@@ -104,3 +104,47 @@
         method: 'get'
     })
 }
+
+// 鏍规嵁瀵硅薄淇℃伅鏌ヨ
+export function queryOne (data: any): Promise<any> {
+    return httpRequest({
+        url: '/ext/salaryParam/queryOne',
+        method: 'post',
+        data
+    })
+}
+
+// 涓�閿姤宸�
+export function autoWorkReport (data: any): Promise<any> {
+    return httpRequest({
+        url: '/ext/plansExt/autoWorkReport',
+        method: 'post',
+        data
+    })
+}
+
+// 鏍规嵁id鏌ヨ
+export function getIdPlansExt(id: any): Promise<any> {
+    return httpRequest({
+        url: `/ext/plansExt/${id}`,
+        method: 'get'
+    })
+}
+
+// 鍒楄〃鏌ヨ
+export function categoryExtList (data: any): Promise<any> {
+    return httpRequest({
+        url: '/ext/categoryExt/list',
+        method: 'post',
+        data
+    })
+}
+
+// 鏌ヨ鍏ㄩ儴
+export function allUser (data: any): Promise<any> {
+    return httpRequest({
+        url: '/ext/companyUserExt/allUser',
+        method: 'post',
+        data
+    })
+}
\ No newline at end of file
diff --git a/h5_standard/src/assets/icon/ic_ar@2x.png b/h5_standard/src/assets/icon/ic_ar@2x.png
new file mode 100644
index 0000000..043e5b6
--- /dev/null
+++ b/h5_standard/src/assets/icon/ic_ar@2x.png
Binary files differ
diff --git a/h5_standard/src/assets/icon/ic_close@2x.png b/h5_standard/src/assets/icon/ic_close@2x.png
new file mode 100644
index 0000000..29468f1
--- /dev/null
+++ b/h5_standard/src/assets/icon/ic_close@2x.png
Binary files differ
diff --git a/h5_standard/src/components/common/Access.vue b/h5_standard/src/components/common/Access.vue
index ef366c6..881bf60 100644
--- a/h5_standard/src/components/common/Access.vue
+++ b/h5_standard/src/components/common/Access.vue
@@ -53,7 +53,7 @@
     import { choiceStockPageByTransfer } from '@/apis/ExWarehouse'
     import { model } from '@/interface'
     import { Attribute } from '@/enum'
-    import { judgmentPlatform } from "@/utils/utils"
+    import { judgmentPlatform } from "@/utils"
     import vSearch from '@/components/common/Search.vue'
     import vLableSelection from '@/components/common/LabelSelection.vue'
 
diff --git a/h5_standard/src/components/newCom/Material.vue b/h5_standard/src/components/newCom/Material.vue
index 5621f22..4d9246d 100644
--- a/h5_standard/src/components/newCom/Material.vue
+++ b/h5_standard/src/components/newCom/Material.vue
@@ -1,13 +1,17 @@
 <template>
     <van-popup
         v-model:show="props.show"
+        :close-on-click-overlay="false"
+        round
         position="bottom"
         :style="{ height: '80%' }">
-        <div class="title">
-            <div class="close" @click="close"><van-icon name="arrow-down" size="30" color="#ffffff" /></div>
-        </div>
         <div class="content">
             <div class="content_search content_top">
+                <div class="title">
+                    <img class="close" src="@/assets/icon/ic_close@2x.png" alt="" style="opacity: 0;" />
+                    <span>閫夋嫨鐢熶骇浜哄憳</span>
+                    <img class="close" src="@/assets/icon/ic_close@2x.png" alt="" @click="close" />
+                </div>
                 <v-Search @searchInput="searchInput" @submit="submit" :isShow="false" placeholder="鎼滅储鐗╂枡鍚嶇О"></v-Search>
             </div>
             <div class="content_total">鍏眥{form.total}}鏉℃暟鎹�</div>
@@ -163,21 +167,6 @@
 </script>
 
 <style lang="scss" scoped>
-    .title {
-        position: fixed;
-        right: 50px;
-        bottom: 100px;
-        z-index: 9;
-        .close {
-            width: 80px;
-            height: 80px;
-            border-radius: 50%;
-            background: #999999;
-            display: flex;
-            align-items: center;
-            justify-content: center;
-        }
-    }
     .content {
         .content_code {
             position: fixed;
@@ -197,6 +186,24 @@
             position: sticky;
             top: 88px;
             z-index: 9;
+            .title {
+                width: 100%;
+                padding: 0 0 30px 0;
+                box-sizing: border-box;
+                display: flex;
+                align-items: center;
+                justify-content: space-between;
+                span {
+                    font-size: 30px;
+                    font-family: PingFangSC-Medium, PingFang SC;
+                    font-weight: 500;
+                    color: #222222;
+                }
+                .close {
+                    width: 28px;
+                    height: 28px;
+                }
+            }
             .content_search_x {
                 height: 24px;
             }
@@ -209,7 +216,7 @@
             color: #666666;
             position: sticky;
             z-index: 99;
-            top: 127px;
+            top: 195px;
         }
         .content_list {
             width: 100%;
diff --git a/h5_standard/src/components/newCom/MaterialY.vue b/h5_standard/src/components/newCom/MaterialY.vue
new file mode 100644
index 0000000..352c652
--- /dev/null
+++ b/h5_standard/src/components/newCom/MaterialY.vue
@@ -0,0 +1,417 @@
+<template>
+    <van-popup
+        v-model:show="props.show"
+        :close-on-click-overlay="false"
+        round
+        position="bottom"
+        :style="{ height: '80%' }">
+        <div class="title">
+            <div class="close" @click="close"><van-icon name="arrow-down" size="30" color="#ffffff" /></div>
+        </div>
+        <div class="content">
+            <div class="content_search content_top">
+                <v-Search @searchInput="searchInput" @submit="submit" :isShow="false" placeholder="鎼滅储鐗╂枡鍚嶇О"></v-Search>
+            </div>
+            <div class="content_total">鍏眥{form.total}}鏉℃暟鎹�</div>
+            <van-pull-refresh v-model="refreshing" @refresh="onRefresh">
+                <van-list
+                    v-model:loading="loading"
+                    :finished="finished"
+                    finished-text="娌℃湁鏇村浜唦"
+                    @load="onLoad"
+                >
+                <div class="content_list">
+                        <div class="page_content" v-for="(item1, idx) in list" :key="idx" @click="jump(item1)">
+                            <div class="page_content_title">
+                                <div class="page_content_title_top">
+                                    <span v-if="item1.batch">{{ item1.materialName + ' | ' + item1.materialCode }}</span>
+                                    <span v-else>{{ item1.materialName + ' | ' + item1.materialCode }}</span>
+                                    <!-- <span>{{item1.num}}{{item1.unitName}}</span> -->
+                                </div>
+                                <div class="page_content_title_bottom">
+                                    <span>{{ item1.locationName }}&nbsp;/&nbsp;</span>
+                                    <span>{{ item1.num }}{{ item1.unitName }}</span>
+                                </div>
+                                <div class="page_content_title_bottom">
+                                    <span class="green" v-if="item1.qualityType == 0">鍚堟牸&nbsp;<span class="black">/</span>&nbsp;</span>
+                                    <span class="warning" v-else-if="item1.qualityType == 1">涓嶈壇&nbsp;<span class="black">/</span>&nbsp;</span>
+                                    <span class="error" v-else-if="item1.qualityType == 2">鎶ュ簾&nbsp;<span class="black">/</span>&nbsp;</span>
+                                    <span v-else>-&nbsp;/&nbsp;</span>
+                                    <span>{{item1.procedureName ? item1.procedureName : '-'}}&nbsp;/&nbsp;</span>
+                                    <span>{{item1.batch ? item1.batch : '-'}}</span>
+                                </div>
+                            </div>
+                        </div>
+                        <!-- <div class="content_list_item" v-for="(item, i) in props.list" :key="i" @click="jump(item)">
+                            <div class="content_list_item_name">{{item.materialName}}</div>
+                        </div> -->
+                    </div>
+                    <!-- <div class="content_list">
+                        <div class="content_list_item" v-for="(item, i) in list" :key="i" @click="jump(item)">
+                            <div class="content_list_item_name">{{item.mmodelUnionName}}</div>
+                        </div>
+                    </div> -->
+                </van-list>
+            </van-pull-refresh>
+        </div>
+    </van-popup>
+</template>
+
+<script setup lang="ts">
+    import { defineProps, defineEmits, onMounted, ref, reactive, watch } from 'vue'
+    import { getStockByPlansForStandard } from '@/apis/ExWarehouse'
+    import { model } from '@/interface'
+    import { judgmentPlatform } from "@/utils/utils"
+    import vSearch from '@/components/common/Search.vue'
+
+    // 鎼滅储鏁版嵁鎺ュ彛
+    interface form extends model {
+        total: number,
+        name: string
+    }
+
+    const form = reactive<form>({
+        capacity: 50,
+        page: 0,
+        total: 0,
+        name: '',
+    })
+
+    // 鍒楄〃鏁版嵁
+    const list: any = ref([]);
+    const loading = ref(false);
+    const finished = ref(false);
+    const refreshing = ref(false);
+    let isOne = ref(true)
+
+    // 鎼滅储妗�
+    const searchInput = (data: any) => {
+        form.page = 0
+        finished.value = false
+        list.value = []
+        form.name = data
+        onLoad()
+    }
+
+    // 鎼滅储鎻愪氦
+    const submit = (): void => {
+        form.page = 0
+        finished.value = false
+        list.value = []
+        onLoad()
+    }
+
+    // 杩斿洖涓婁竴椤靛甫鍙傛暟
+    const jump = (item: any) => {
+        emit('value', item)
+    }
+
+    // 鑾峰彇鐗╂枡鍒楄〃鏁版嵁
+    const onLoad = async () => {
+        if (!finished.value) {
+            loading.value = true;
+            form.page = form.page + 1
+            getStockByPlansForStandard({
+                capacity: form.capacity,
+                page: form.page,
+                model: {
+                    ids: props.ids,
+                    materialName: form.name,
+                    deviceId: props.deviceId,
+                    plansId: props.plansId
+                }
+            }).then(res => {
+                isOne.value = false
+                if (refreshing.value) {
+                    list.value = []
+                    refreshing.value = false;
+                }
+                loading.value = false;
+                if (res.code === 200 && res.data.records && res.data.records.length !== 0) {
+                    form.total = res.data.total
+                    list.value.push(...res.data.records)
+                } else {
+                    finished.value = true;
+                }
+            }).catch((err: any) => {
+                loading.value = false;
+                finished.value = true;
+                if (refreshing.value) {
+                    list.value = []
+                    refreshing.value = false;
+                }
+            })
+        }
+    }
+
+    // 涓嬫媺鍒锋柊浼樺寲椤甸潰
+    const onRefresh = () => {
+        finished.value = false;
+        form.page = 0
+        loading.value = true;
+        onLoad()
+    }
+
+    let status = ref<boolean>(false)
+
+    const props = defineProps({
+        show: {
+            type: Boolean,
+            required: true
+        },
+        plansId: {
+            type: String,
+            required: true
+        },
+        deviceId: {
+            type: String,
+            required: true
+        },
+        ids: {
+            type: String,
+            required: false
+        }
+    })
+
+    const emit = defineEmits(['close', 'value'])
+
+    // 鍏抽棴鍥炶皟
+    const close = () => {
+        emit('close')
+    }
+
+    onMounted(() => {
+        status.value = judgmentPlatform()
+    })
+
+    watch(() => props.show, (news) => {
+        if (news && !isOne.value) {
+            list.value = []
+            finished.value = false;
+            form.page = 0
+            form.name = ''
+            loading.value = true;
+            onLoad()
+        }
+    })
+</script>
+
+<style lang="scss" scoped>
+    .title {
+        position: fixed;
+        right: 50px;
+        bottom: 100px;
+        z-index: 9;
+        .close {
+            width: 80px;
+            height: 80px;
+            border-radius: 50%;
+            background: #999999;
+            display: flex;
+            align-items: center;
+            justify-content: center;
+        }
+    }
+    .content {
+        .content_code {
+            position: fixed;
+            right: 30px;
+            bottom: 100px;
+            img {
+                width: 138px;
+                height: 138px;
+            }
+        }
+        .content_top {
+            top: 0 !important;
+        }
+        .content_search {
+            padding: 30px;
+            background: white;
+            position: sticky;
+            top: 88px;
+            z-index: 9;
+            .content_search_x {
+                height: 24px;
+            }
+        }
+        .content_total {
+            padding: 24px 30px;
+            background: #F7F7F7;
+            font-size: 24px;
+            font-weight: 400;
+            color: #666666;
+            position: sticky;
+            z-index: 99;
+            top: 127px;
+        }
+        .content_list {
+            width: 100%;
+            height: 100%;
+            display: flex;
+            flex-direction: column;
+            .page_content {
+                margin-top: 36px;
+                padding: 0 30px;
+                box-sizing: border-box;
+                .page_content_title {
+                    display: flex;
+                    flex-direction: column;
+                    margin-bottom: 10px;
+                    .page_content_title_top {
+                        display: flex;
+                        align-items: center;
+                        justify-content: space-between;
+                        span {
+                            &:nth-child(1) {
+                                font-size: 30px;
+                                font-weight: 500;
+                                color: #222222;
+                            }
+                            &:nth-child(2) {
+                                flex-shrink: 0;
+                                font-size: 24px;
+                                font-weight: 400;
+                                color: #333333;
+                                span {
+                                    font-size: 24px;
+                                    color: $nav-color;
+                                }
+                            }
+                        }
+                    }
+                    .page_content_title_loa {
+                        font-size: 26px;
+                        font-family: PingFangSC-Regular, PingFang SC;
+                        font-weight: 400;
+                        color: #333333;
+                        margin-top: 10px;
+                    }
+                    .page_content_title_bottom {
+                        margin-top: 10px;
+                        .green {
+                            color: $nav-stateColor7 !important;
+                            .black {
+                                color: black !important;
+                            }
+                        }
+                        .warning {
+                            color: $nav-stateColor5 !important;
+                            .black {
+                                color: black !important;
+                            }
+                        }
+                        .error {
+                            color: $nav-stateColor4 !important;
+                            .black {
+                                color: black !important;
+                            }
+                        }
+                        span {
+                            font-size: 24px;
+                            font-weight: 400;
+                            color: #666666;
+                        }
+                    }
+                }
+                .lineBorder {
+                    border: none !important;
+                    padding-bottom: 0 !important;
+                    margin-bottom: 24px;
+                }
+                .page_content_list {
+                    width: 100%;
+                    display: flex;
+                    align-items: center;
+                    flex-wrap: wrap;
+                    &:first-child {
+                        margin: 0;
+                    }
+                    &:last-child {
+                        border: none;
+                    }
+                    .page_content_list_nums {
+                        width: 30%;
+                        display: flex;
+                        .page_content_list_num_label {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #666666;
+                        }
+                        .page_content_list_num_nr {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #222222;
+                        }
+                    }
+                    .page_content_list_num {
+                        width: 70%;
+                        display: flex;
+                        .page_content_list_num_label {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #666666;
+                        }
+                        .page_content_list_num_nr {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #222222;
+                        }
+                    }
+                    .page_content_list_items {
+                        width: 30%;
+                        display: flex;
+                        margin-top: 24px;
+                        .page_content_list_item_label {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #666666;
+                            flex-shrink: 0;
+                        }
+                        .page_content_list_item_nr {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #222222;
+                        }
+                    }
+                    .page_content_list_item {
+                        width: 70%;
+                        display: flex;
+                        .page_content_list_item_label {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #666666;
+                            flex-shrink: 0;
+                        }
+                        .page_content_list_item_nr {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #222222;
+                        }
+                    }
+                }
+            }
+            .content_list_item {
+                padding: 30px;
+                display: flex;
+                border-bottom: 1px solid #ececec;
+                .serious {
+                    color: $nav-stateColor4 !important;
+                }
+                .success {
+                    color: $nav-stateColor2 !important;
+                }
+                .warning {
+                    color: $nav-stateColor5 !important;
+                }
+                .content_list_item_status {
+                    font-size: 28px;
+                    margin-right: 10px;
+                }
+                .content_list_item_name {
+                    font-size: 28px;
+                }
+            }
+        }
+    }
+</style>
diff --git a/h5_standard/src/components/newCom/location.vue b/h5_standard/src/components/newCom/location.vue
index 77cc21f..9ce6f58 100644
--- a/h5_standard/src/components/newCom/location.vue
+++ b/h5_standard/src/components/newCom/location.vue
@@ -1,6 +1,8 @@
 <template>
     <van-popup
         v-model:show="props.show"
+        :close-on-click-overlay="false"
+        round
         position="bottom"
         :style="{ height: '60%' }">
         <div class="title">
diff --git a/h5_standard/src/components/newCom/productionProcess.vue b/h5_standard/src/components/newCom/productionProcess.vue
new file mode 100644
index 0000000..f685c59
--- /dev/null
+++ b/h5_standard/src/components/newCom/productionProcess.vue
@@ -0,0 +1,258 @@
+<template>
+    <van-popup
+        v-model:show="props.show"
+        :close-on-click-overlay="false"
+        round
+        position="bottom"
+        :style="{ height: '60%' }">
+        <div class="title">
+            <div class="close" @click="close"><van-icon name="arrow-down" size="30" color="#ffffff" /></div>
+        </div>
+        <div class="content">
+            <div class="content_list">
+                <div class="content_list_item" v-for="(item, i) in props.list" :key="i" @click="jump(item)">
+                    <div class="content_list_item_name">{{item.name}}</div>
+                </div>
+            </div>
+        </div>
+    </van-popup>
+</template>
+
+<script setup lang="ts">
+    import { defineProps, defineEmits, ref } from 'vue'
+
+    // 杩斿洖涓婁竴椤靛甫鍙傛暟
+    const jump = (item: any) => {
+        emit('value', item)
+    }
+
+    const props: any = defineProps({
+        show: {
+            type: Boolean,
+            required: true
+        },
+        list: {
+            type: Array,
+            required: true
+        }
+    })
+
+    const emit = defineEmits(['close', 'value'])
+
+    // 鍏抽棴鍥炶皟
+    const close = () => {
+        emit('close')
+    }
+</script>
+
+<style lang="scss" scoped>
+    .title {
+        position: fixed;
+        right: 50px;
+        bottom: 100px;
+        z-index: 9;
+        .close {
+            width: 80px;
+            height: 80px;
+            border-radius: 50%;
+            background: #999999;
+            display: flex;
+            align-items: center;
+            justify-content: center;
+        }
+    }
+    .content {
+        .content_code {
+            position: fixed;
+            right: 30px;
+            bottom: 100px;
+            img {
+                width: 138px;
+                height: 138px;
+            }
+        }
+        .content_top {
+            top: 0 !important;
+        }
+        .content_search {
+            padding: 30px;
+            background: white;
+            position: sticky;
+            top: 88px;
+            z-index: 9;
+            .content_search_x {
+                height: 24px;
+            }
+        }
+        .content_total {
+            padding: 24px 30px;
+            background: #F7F7F7;
+            font-size: 24px;
+            font-weight: 400;
+            color: #666666;
+            position: sticky;
+            z-index: 99;
+            top: 127px;
+        }
+        .content_list {
+            width: 100%;
+            height: 100%;
+            display: flex;
+            flex-direction: column;
+            .page_content {
+                margin-top: 36px;
+                padding: 0 30px;
+                box-sizing: border-box;
+                .page_content_title {
+                    display: flex;
+                    flex-direction: column;
+                    margin-bottom: 10px;
+                    .page_content_title_top {
+                        display: flex;
+                        align-items: center;
+                        justify-content: space-between;
+                        span {
+                            &:nth-child(1) {
+                                font-size: 30px;
+                                font-weight: 500;
+                                color: #222222;
+                            }
+                            &:nth-child(2) {
+                                flex-shrink: 0;
+                                font-size: 24px;
+                                font-weight: 400;
+                                color: #333333;
+                                span {
+                                    font-size: 24px;
+                                    color: $nav-color;
+                                }
+                            }
+                        }
+                    }
+                    .page_content_title_bottom {
+                        .green {
+                            color: $nav-stateColor7 !important;
+                            .black {
+                                color: black !important;
+                            }
+                        }
+                        .warning {
+                            color: $nav-stateColor5 !important;
+                            .black {
+                                color: black !important;
+                            }
+                        }
+                        .error {
+                            color: $nav-stateColor4 !important;
+                            .black {
+                                color: black !important;
+                            }
+                        }
+                        span {
+                            font-size: 24px;
+                            font-weight: 400;
+                            color: #666666;
+                        }
+                    }
+                }
+                .lineBorder {
+                    border: none !important;
+                    padding-bottom: 0 !important;
+                    margin-bottom: 24px;
+                }
+                .page_content_list {
+                    width: 100%;
+                    display: flex;
+                    align-items: center;
+                    flex-wrap: wrap;
+                    &:first-child {
+                        margin: 0;
+                    }
+                    &:last-child {
+                        border: none;
+                    }
+                    .page_content_list_nums {
+                        width: 30%;
+                        display: flex;
+                        .page_content_list_num_label {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #666666;
+                        }
+                        .page_content_list_num_nr {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #222222;
+                        }
+                    }
+                    .page_content_list_num {
+                        width: 70%;
+                        display: flex;
+                        .page_content_list_num_label {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #666666;
+                        }
+                        .page_content_list_num_nr {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #222222;
+                        }
+                    }
+                    .page_content_list_items {
+                        width: 30%;
+                        display: flex;
+                        margin-top: 24px;
+                        .page_content_list_item_label {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #666666;
+                            flex-shrink: 0;
+                        }
+                        .page_content_list_item_nr {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #222222;
+                        }
+                    }
+                    .page_content_list_item {
+                        width: 70%;
+                        display: flex;
+                        .page_content_list_item_label {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #666666;
+                            flex-shrink: 0;
+                        }
+                        .page_content_list_item_nr {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #222222;
+                        }
+                    }
+                }
+            }
+            .content_list_item {
+                padding: 30px;
+                display: flex;
+                border-bottom: 1px solid #ececec;
+                .serious {
+                    color: $nav-stateColor4 !important;
+                }
+                .success {
+                    color: $nav-stateColor2 !important;
+                }
+                .warning {
+                    color: $nav-stateColor5 !important;
+                }
+                .content_list_item_status {
+                    font-size: 28px;
+                    margin-right: 10px;
+                }
+                .content_list_item_name {
+                    font-size: 28px;
+                }
+            }
+        }
+    }
+</style>
diff --git a/h5_standard/src/components/newCom/quality.vue b/h5_standard/src/components/newCom/quality.vue
index 20bf926..c1c67a6 100644
--- a/h5_standard/src/components/newCom/quality.vue
+++ b/h5_standard/src/components/newCom/quality.vue
@@ -1,6 +1,7 @@
 <template>
     <van-popup
         v-model:show="props.show"
+        :close-on-click-overlay="false"
         position="bottom"
         :style="{ height: '60%' }">
         <div class="title">
diff --git a/h5_standard/src/components/newCom/user.vue b/h5_standard/src/components/newCom/user.vue
new file mode 100644
index 0000000..55d4505
--- /dev/null
+++ b/h5_standard/src/components/newCom/user.vue
@@ -0,0 +1,330 @@
+<template>
+    <van-popup
+        v-model:show="props.show"
+        :close-on-click-overlay="false"
+        position="bottom"
+        round
+        :style="{ height: '80%' }">
+        <div class="content">
+            <div class="content_search content_top">
+                <div class="title">
+                    <img class="close" src="@/assets/icon/ic_close@2x.png" alt="" style="opacity: 0;" />
+                    <span>閫夋嫨鐢熶骇浜哄憳</span>
+                    <img class="close" src="@/assets/icon/ic_close@2x.png" alt="" @click="close" />
+                </div>
+                <v-Search @searchInput="searchInput" @submit="submit" :isShow="false" placeholder="鎼滅储濮撳悕"></v-Search>
+            </div>
+            <div class="content_total">鍏眥{form.total}}鏉℃暟鎹�</div>
+            <div class="content_list">
+                <div class="content_list_item" v-for="(item, i) in list" :key="i" @click="jump(item)">
+                    <div class="content_list_item_name">{{item.name}}&nbsp;|&nbsp;{{item.dmodel.name}}</div>
+                </div>
+            </div>
+        </div>
+    </van-popup>
+</template>
+
+<script setup lang="ts">
+    import { defineProps, defineEmits, onMounted, ref, reactive } from 'vue'
+    import { materialDistributeExt } from '@/apis/ExWarehouse'
+    import { getFindAll, allUser } from '@/apis/PlanningAPI'
+    import { model } from '@/interface'
+    import { judgmentPlatform } from "@/utils/utils"
+    import vSearch from '@/components/common/Search.vue'
+
+    // 鎼滅储鏁版嵁鎺ュ彛
+    interface form extends model {
+        total: number,
+        name: string
+    }
+
+    const form = reactive<form>({
+        capacity: 50,
+        page: 0,
+        total: 0,
+        name: '',
+    })
+
+    // 鍒楄〃鏁版嵁
+    const list: any = ref([]);
+    const loading = ref(false);
+    const finished = ref(false);
+    const refreshing = ref(false)
+
+    // 鎼滅储妗�
+    const searchInput = (data: any) => {
+        form.page = 0
+        finished.value = false
+        list.value = []
+        form.name = data
+        onLoad()
+    }
+
+    // 鎼滅储鎻愪氦
+    const submit = (): void => {
+        form.page = 0
+        finished.value = false
+        list.value = []
+        onLoad()
+    }
+
+    // 杩斿洖涓婁竴椤靛甫鍙傛暟
+    const jump = (item: any) => {
+        emit('value', item)
+    }
+
+    // 鑾峰彇鐗╂枡鍒楄〃鏁版嵁
+    const onLoad = async () => {
+        loading.value = true;
+        allUser({ name: form.name })
+            .then(res => {
+                loading.value = false;
+                if (res.code === 200 && res.data && res.data.length !== 0) {
+                    form.total = res.data.length
+                    list.value = res.data
+                } else {
+                    finished.value = true;
+                }
+            }).catch((err: any) => {
+                loading.value = false;
+                finished.value = true;
+                if (refreshing.value) {
+                    list.value = []
+                    refreshing.value = false;
+                }
+            })
+    }
+
+    const props = defineProps({
+        show: {
+            type: Boolean,
+            required: true
+        }
+    })
+
+    const emit = defineEmits(['close', 'value'])
+
+    // 鍏抽棴鍥炶皟
+    const close = () => {
+        emit('close')
+    }
+
+    onMounted(() => {
+        onLoad()
+    })
+</script>
+
+<style lang="scss" scoped>
+    .content {
+        .content_code {
+            position: fixed;
+            right: 30px;
+            bottom: 100px;
+            img {
+                width: 138px;
+                height: 138px;
+            }
+        }
+        .content_top {
+            top: 0 !important;
+        }
+        .content_search {
+            padding: 30px;
+            background: white;
+            position: sticky;
+            top: 88px;
+            z-index: 9;
+            .title {
+                width: 100%;
+                padding: 0 0 30px 0;
+                box-sizing: border-box;
+                display: flex;
+                align-items: center;
+                justify-content: space-between;
+                span {
+                    font-size: 30px;
+                    font-family: PingFangSC-Medium, PingFang SC;
+                    font-weight: 500;
+                    color: #222222;
+                }
+                .close {
+                    width: 28px;
+                    height: 28px;
+                }
+            }
+            .content_search_x {
+                height: 24px;
+            }
+        }
+        .content_total {
+            padding: 24px 30px;
+            background: #F7F7F7;
+            font-size: 24px;
+            font-weight: 400;
+            color: #666666;
+            position: sticky;
+            z-index: 99;
+            top: 195px;
+        }
+        .content_list {
+            width: 100%;
+            height: 100%;
+            display: flex;
+            flex-direction: column;
+            .page_content {
+                margin-top: 36px;
+                padding: 0 30px;
+                box-sizing: border-box;
+                .page_content_title {
+                    display: flex;
+                    flex-direction: column;
+                    margin-bottom: 10px;
+                    .page_content_title_top {
+                        display: flex;
+                        align-items: center;
+                        justify-content: space-between;
+                        span {
+                            &:nth-child(1) {
+                                font-size: 30px;
+                                font-weight: 500;
+                                color: #222222;
+                            }
+                            &:nth-child(2) {
+                                flex-shrink: 0;
+                                font-size: 24px;
+                                font-weight: 400;
+                                color: #333333;
+                                span {
+                                    font-size: 24px;
+                                    color: $nav-color;
+                                }
+                            }
+                        }
+                    }
+                    .page_content_title_bottom {
+                        .green {
+                            color: $nav-stateColor7 !important;
+                            .black {
+                                color: black !important;
+                            }
+                        }
+                        .warning {
+                            color: $nav-stateColor5 !important;
+                            .black {
+                                color: black !important;
+                            }
+                        }
+                        .error {
+                            color: $nav-stateColor4 !important;
+                            .black {
+                                color: black !important;
+                            }
+                        }
+                        span {
+                            font-size: 24px;
+                            font-weight: 400;
+                            color: #666666;
+                        }
+                    }
+                }
+                .lineBorder {
+                    border: none !important;
+                    padding-bottom: 0 !important;
+                    margin-bottom: 24px;
+                }
+                .page_content_list {
+                    width: 100%;
+                    display: flex;
+                    align-items: center;
+                    flex-wrap: wrap;
+                    &:first-child {
+                        margin: 0;
+                    }
+                    &:last-child {
+                        border: none;
+                    }
+                    .page_content_list_nums {
+                        width: 30%;
+                        display: flex;
+                        .page_content_list_num_label {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #666666;
+                        }
+                        .page_content_list_num_nr {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #222222;
+                        }
+                    }
+                    .page_content_list_num {
+                        width: 70%;
+                        display: flex;
+                        .page_content_list_num_label {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #666666;
+                        }
+                        .page_content_list_num_nr {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #222222;
+                        }
+                    }
+                    .page_content_list_items {
+                        width: 30%;
+                        display: flex;
+                        margin-top: 24px;
+                        .page_content_list_item_label {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #666666;
+                            flex-shrink: 0;
+                        }
+                        .page_content_list_item_nr {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #222222;
+                        }
+                    }
+                    .page_content_list_item {
+                        width: 70%;
+                        display: flex;
+                        .page_content_list_item_label {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #666666;
+                            flex-shrink: 0;
+                        }
+                        .page_content_list_item_nr {
+                            font-size: 26px;
+                            font-weight: 400;
+                            color: #222222;
+                        }
+                    }
+                }
+            }
+            .content_list_item {
+                padding: 30px;
+                display: flex;
+                border-bottom: 1px solid #ececec;
+                .serious {
+                    color: $nav-stateColor4 !important;
+                }
+                .success {
+                    color: $nav-stateColor2 !important;
+                }
+                .warning {
+                    color: $nav-stateColor5 !important;
+                }
+                .content_list_item_status {
+                    font-size: 28px;
+                    margin-right: 10px;
+                }
+                .content_list_item_name {
+                    font-size: 28px;
+                }
+            }
+        }
+    }
+</style>
diff --git a/h5_standard/src/main.ts b/h5_standard/src/main.ts
index 83fc3dd..08a246d 100644
--- a/h5_standard/src/main.ts
+++ b/h5_standard/src/main.ts
@@ -1,4 +1,5 @@
 import { createApp } from 'vue'
+import mitt from 'mitt'
 // import VConsole from 'vconsole'
 import App from './App.vue'
 import router from './router'
@@ -16,6 +17,8 @@
 
 const app = createApp(App)
 
+app.config.globalProperties.$Bus = mitt()
+
 app.config.globalProperties.$onWait = new Promise((resolve) => {
     app.config.globalProperties.$reslove = resolve
 })
diff --git a/h5_standard/src/router/module/workOrder/index.ts b/h5_standard/src/router/module/workOrder/index.ts
index b2df459..6513a3a 100644
--- a/h5_standard/src/router/module/workOrder/index.ts
+++ b/h5_standard/src/router/module/workOrder/index.ts
@@ -192,9 +192,18 @@
                 name: 'reportingForWork',
                 meta: {
                     title: '涓�閿姤宸�',
-                    keepAlive: false
+                    keepAlive: true
                 },
                 component: () => import('@/views/workOrder/reportingForWork.vue')
+            },
+            {
+                path: '/workOrder/processPlans',
+                name: 'processPlans',
+                meta: {
+                    title: '閫夋嫨宸ュ簭璁″垝',
+                    keepAlive: false
+                },
+                component: () => import('@/views/workOrder/processPlan.vue')
             }
         ]
     }
diff --git a/h5_standard/src/views/LogInAgain.vue b/h5_standard/src/views/LogInAgain.vue
index e28e4a7..bcfda83 100644
--- a/h5_standard/src/views/LogInAgain.vue
+++ b/h5_standard/src/views/LogInAgain.vue
@@ -80,7 +80,7 @@
       // let res = await testLogin({  // 鑻卞瓙濮�
       //   username: '18055151023',
       //   password: '123456',
-      //   companyId: '1',
+      //   companyId: '8',
       //   uuid: '0000',
       //   code: '0000'
       // })
diff --git a/h5_standard/src/views/needToBeDealtWith/addWarehousing.vue b/h5_standard/src/views/needToBeDealtWith/addWarehousing.vue
index 55b20d0..ef5e6ea 100644
--- a/h5_standard/src/views/needToBeDealtWith/addWarehousing.vue
+++ b/h5_standard/src/views/needToBeDealtWith/addWarehousing.vue
@@ -29,7 +29,7 @@
             </div>
             <van-swipe-cell v-for="(item, index) in list" :key="index">
                 <div class="rework_qd_list">
-                    <div class="rework_qd_item" @click="openL(index)">
+                    <div class="rework_qd_item" @click="openL(index)" v-if="location">
                         <span><b>*</b>鍏ュ簱璐т綅</span>
                         <div class="rework_qd_item_right">
                             <span :class="item.locationName ? 'black' : ''">{{item.locationName ? item.locationName : '璇烽�夋嫨'}}</span>
@@ -43,13 +43,13 @@
                             <van-icon name="arrow" size="20" color="#999999" />
                         </div>
                     </div>
-                    <!-- <div class="rework_qd_item" v-if="form.type != 25">
+                    <div class="rework_qd_item" v-if="form.type != 25" @click="openGX(index)">
                         <span>鐢熶骇宸ュ簭</span>
                         <div class="rework_qd_item_right">
                             <span :class="item.procedureName ? 'black' : ''">{{item.procedureName ? item.procedureName : '璇烽�夋嫨'}}</span>
                             <van-icon name="arrow" size="20" color="#999999" />
                         </div>
-                    </div> -->
+                    </div>
                     <div class="rework_qd_item" @click="openQ(index)">
                         <span><b>*</b>璐ㄩ噺灞炴��</span>
                         <div class="rework_qd_item_right">
@@ -87,8 +87,10 @@
         <Quality :show="qualityShow" @close="close2" @value="getValue2" />
         <!-- 閫夋嫨璐т綅 -->
         <Location :show="locationShow" :list="locationList" @close="close3" @value="getValue3" />
+        <!-- 宸ュ簭 -->
+        <ProductionProcess :show="productionShow" :list="productionList" @close="close4" @value="getValue4" />
         <!-- 鍗曟嵁绫诲瀷 -->
-        <van-popup v-model:show="typeShow" position="bottom" :style="{ height: '50%' }">
+        <van-popup v-model:show="typeShow" round position="bottom" :style="{ height: '50%' }">
             <van-picker
                 :columns="columns"
                 @confirm="onConfirm1"
@@ -103,11 +105,13 @@
     import { onMounted, ref, reactive } from 'vue'
     import { useRouter } from 'vue-router'
     import { Toast } from 'vant'
-    import { createForStandard, getListByWarehouseId, wOutBoundForStockUp } from '@/apis/WorkOrderAPI'
+    import { getListByWarehouseId, wOutBoundForStockUp } from '@/apis/WorkOrderAPI'
+    import { getListByMaterialId } from '@/apis/ExWarehouse'
     import Warehouse from '@/components/common/Warehouse.vue'
     import Material from '@/components/newCom/Material.vue'
     import Quality from '@/components/newCom/quality.vue'
     import Location from '@/components/newCom/location.vue'
+    import ProductionProcess from '@/components/newCom/productionProcess.vue'
 
     const router = useRouter()
     // 琛ㄥ崟鏁版嵁
@@ -119,6 +123,8 @@
     })
 
     let locationList: any = ref([])
+    let location: any = ref(true)
+    let productionList: any = ref([])
 
     let i = ref(0)
 
@@ -150,6 +156,7 @@
     let qualityShow = ref<boolean>(false)
     let locationShow = ref<boolean>(false)
     let typeShow = ref<boolean>(false)
+    let productionShow = ref<boolean>(false)
 
     // 鎵撳紑閫夋嫨鐗╂枡
     const openMaterial = (index: number) => {
@@ -160,6 +167,11 @@
     const openQ = (index: number) => {
         i.value = index
         qualityShow.value = true
+    }
+    // 鎵撳紑宸ュ簭
+    const openGX = (index: number) => {
+        i.value = index
+        productionShow.value = true
     }
     // 鎵撳紑閫夋嫨璐т綅
     const openL = (index: number) => {
@@ -188,6 +200,12 @@
     const onConfirm1 = (value: any) => {
         form.typeName = value.name
         form.type = value.id
+        if (value.id == 25) {
+            list.value.forEach(item => {
+                item.procedureId = ''
+                item.procedureName = ''
+            })
+        }
         typeShow.value = false
     };
     const onCancel = () => {
@@ -265,6 +283,10 @@
     const close3 = (): void => {
         locationShow.value = false
     }
+    // 鍏抽棴璐т綅閫夋嫨寮规
+    const close4 = (): void => {
+        productionShow.value = false
+    }
     // 閫夋嫨浠撳簱鍥炶皟
     const getValue = (item: any): void => {
         form.warehouseName = item.name
@@ -273,21 +295,39 @@
             .then(res => {
                 if (res.code === 200) {
                     locationList.value = res.data
-                    list.value.forEach(item => {
-                        item.locationId = ''
-                        item.locationName = ''
-                    })
+                    if (res.data.length === 1) {
+                        location.value = false
+                        list.value.forEach(item => {
+                            item.locationId = res.data[0].id
+                            item.locationName = res.data[0].unionName
+                        })
+                    } else {
+                        location.value = true
+                        list.value.forEach(item => {
+                            item.locationId = ''
+                            item.locationName = ''
+                        })
+                    }
                 }
             })
         warehouseShow.value = false
     }
     // 閫夋嫨鐗╂枡
     const getValue1 = (item: any): void => {
-        console.log(item)
         list.value[i.value].materialName = item.mmodelUnionName
         list.value[i.value].materialId = item.id
         list.value[i.value].unitId = item.unitId
         list.value[i.value].unitName = item.umodelName
+        // 鑾峰彇鐗╂枡涓嬪伐搴�
+        getListByMaterialId({
+            materialId: item.id
+        }).then(res => {
+            if (res.code === 200) {
+                productionList.value = res.data
+                list.value[i.value].procedureId = ''
+                list.value[i.value].procedureName = ''
+            }
+        })
         materialsShow.value = false
     }
     // 閫夋嫨璐ㄩ噺灞炴��
@@ -302,6 +342,12 @@
         list.value[i.value].locationName = item.unionName
         locationShow.value = false
     }
+    // 閫夋嫨宸ュ簭
+    const getValue4 = (item: any): void => {
+        list.value[i.value].procedureId = item.id
+        list.value[i.value].procedureName = item.name
+        productionShow.value = false
+    }
     onMounted(() => {
         // 鑾峰彇宸ヨ淇℃伅
         // getLKInfo(route.query.id as string)
diff --git a/h5_standard/src/views/needToBeDealtWith/outbound.vue b/h5_standard/src/views/needToBeDealtWith/outbound.vue
index 634b0f8..21d39a9 100644
--- a/h5_standard/src/views/needToBeDealtWith/outbound.vue
+++ b/h5_standard/src/views/needToBeDealtWith/outbound.vue
@@ -61,7 +61,7 @@
         <Warehouse :show="warehouseShow" @close="close" @value="getValue" />
         <Materials ref="Material" :show="materialsShow" :id="form.warehouseId.toString()" @close="close1" @value="getValue1" />
         <!-- 鍗曟嵁绫诲瀷 -->
-        <van-popup v-model:show="typeShow" position="bottom" :style="{ height: '50%' }">
+        <van-popup v-model:show="typeShow" round position="bottom" :style="{ height: '50%' }">
             <van-picker
                 :columns="columns"
                 @confirm="onConfirm1"
@@ -124,6 +124,8 @@
     // 鎻愪氦
     const onConfirm = () => {
         if (!form.type) return Toast('璇烽�夋嫨鍗曟嵁绫诲瀷')
+        if (!form.warehouseId) return Toast('璇烽�夋嫨鍑哄簱浠撳簱')
+        if (list.value.length === 0) return Toast('鑷冲皯閫夋嫨涓�鏉″嚭搴撶墿鏂�')
         for (let i = 0; i < list.value.length; i++) {
             if (!list.value[i].num || list.value[i].num == '' || list.value[i].num == 0) {
                 return Toast(`绗�${i + 1}涓嚭搴撶墿鏂欐暟閲忓繀椤诲ぇ浜�0`)
diff --git a/h5_standard/src/views/workOrder/afterWorkReport.vue b/h5_standard/src/views/workOrder/afterWorkReport.vue
index 0ca8b7b..1d9d87b 100644
--- a/h5_standard/src/views/workOrder/afterWorkReport.vue
+++ b/h5_standard/src/views/workOrder/afterWorkReport.vue
@@ -357,15 +357,17 @@
         }).then(res => {
             if (res.code === 200) {
                 if (res.data.length > 0) {
-                    res.data.forEach((item: any) => {
-                        if (item.doneType === 1) {
-                            produceFrom.undesirable = item.num
-                            produceFrom.undesirableId = item.id
-                        } else {
-                            produceFrom.qualified = item.num
-                            produceFrom.qualifiedId = item.id
-                        }
-                    })
+                    produceFrom.qualified = res.data[0].qualifiedNum
+                    produceFrom.undesirable = res.data[0].unqualifiedNum
+                    // res.data.forEach((item: any) => {
+                    //     if (item.doneType === 1) {
+                    //         produceFrom.undesirable = item.num
+                    //         produceFrom.undesirableId = item.id
+                    //     } else {
+                    //         produceFrom.qualified = item.num
+                    //         produceFrom.qualifiedId = item.id
+                    //     }
+                    // })
                 }
                 // res.data.forEach((item: any) => {
                 //     if (item.doneType === 0) { // 鍚堟牸
diff --git a/h5_standard/src/views/workOrder/index.vue b/h5_standard/src/views/workOrder/index.vue
index e228f38..2076a5b 100644
--- a/h5_standard/src/views/workOrder/index.vue
+++ b/h5_standard/src/views/workOrder/index.vue
@@ -150,7 +150,7 @@
             num: '0'
         },
         {
-            id: [2,3],
+            id: [2,3,7],
             name: '鐢熶骇涓�',
             num: '0'
         },
@@ -213,6 +213,7 @@
 
     // 鍒囨崲鍒嗙被
     const clickTag = (id: any): void => {
+        console.log()
         form.total = 0
         form.statusList = id
         form.page = 0
diff --git a/h5_standard/src/views/workOrder/processPlan.vue b/h5_standard/src/views/workOrder/processPlan.vue
new file mode 100644
index 0000000..d23877b
--- /dev/null
+++ b/h5_standard/src/views/workOrder/processPlan.vue
@@ -0,0 +1,232 @@
+<template>
+    <div class="content">
+        <van-pull-refresh v-model="refreshing" @refresh="onRefresh">
+            <van-list
+                v-model:loading="loading"
+                :finished="finished"
+                finished-text="娌℃湁鏇村浜唦"
+                @load="onLoad">
+                <div class="content_list">
+                    <van-swipe-cell v-for="(item, i) in listData" :key="i">
+                        <div class="content_list_item" @click="clickItem(item)">
+                            <div class="content_list_item_title">
+                                <span>{{item.materialName}}锝渰{item.produceName}}</span>
+                                <div class="content_list_item_title_tips" v-if="item.urgent">浼樺厛{{ item.urgent }}</div>
+                            </div>
+                            <div class="content_list_item_nr">
+                                <div class="content_list_item_nr_box">
+                                    <div class="label">鐗╂枡缂栫爜锛�</div>
+                                    <div class="cr">{{item.materialName}}涓▄{item.materialCode}}</div>
+                                </div>
+                                <div class="content_list_item_nr_box">
+                                    <div class="label">璁″垝鏁伴噺锛�</div>
+                                    <div class="cr">{{item.num}}{{item.umodel.name}}</div>
+                                </div>
+                                <div class="content_list_item_nr_box">
+                                    <div class="label">璁″垝鏃ユ湡锛�</div>
+                                    <div class="cr">{{item.workPlanStartDate}} ~ {{item.workPlanEndDate}}</div>
+                                </div>
+                                <div class="content_list_item_nr_box">
+                                    <div class="label">璁″垝鍛橈細</div>
+                                    <div class="cr">{{item.planUserName}}</div>
+                                </div>
+                                <div class="content_list_item_nr_box">
+                                    <div class="label">鐢熶骇鎵规锛�</div>
+                                    <div class="cr">{{item.batch}}</div>
+                                </div>
+                                <div class="content_list_item_nr_box" v-if="item.salesOrder">
+                                    <div class="label">閿�鍞鍗曪細</div>
+                                    <div class="cr">{{ item.salesOrder }}</div>
+                                </div>
+                            </div>
+                        </div>
+                    </van-swipe-cell>
+                </div>
+            </van-list>
+        </van-pull-refresh>
+    </div>
+</template>
+
+<script setup lang="ts">
+    import { reactive, ref, onBeforeUnmount, getCurrentInstance } from "vue"
+    import { useRouter, useRoute } from "vue-router"
+    import { getList } from "@/apis/PlanningAPI"
+
+    const route = useRoute()
+    const router = useRouter()
+
+    const { $Bus }  = getCurrentInstance().appContext.config.globalProperties 
+
+    // 鍒嗛〉鏌ヨ鏁版嵁
+    const pageData = reactive({
+        capacity: 10,
+        page: 0,
+        total: 0
+    })
+
+    // 鍒楄〃鏁版嵁
+    let listData: any = ref([])
+    const loading = ref(false)
+    const finished = ref(false)
+    const refreshing = ref(false)
+
+    const clickItem = (obj: any) => {
+        $Bus.emit('callback', obj)
+        router.go(-1)
+    }
+
+    // 鍒楄〃
+    const onLoad = () => {
+        if (!finished.value) {
+            pageData.page = pageData.page + 1
+            loading.value = true
+            getList({
+                capacity: pageData.capacity,
+                page: pageData.page,
+                model: {
+                    statusList: [1, 4],
+                    paused: 0
+                },
+                sorts: [
+                    { direction: 'DESC', property: 'CREATE_TIME' }
+                ]
+            }).then(res => {
+                if (refreshing.value) {
+                    listData.value = []
+                    refreshing.value = false;
+                }
+                loading.value = false
+                if (res.code === 200 && res.data.records && res.data.records.length !== 0) {
+                    pageData.total = res.data.total
+                    listData.value.push(...res.data.records)
+                } else {
+                    finished.value = true
+                }
+            }).catch(err => {
+                loading.value = false
+                finished.value = true
+                if (refreshing.value) {
+                    listData.value = []
+                    refreshing.value = false;
+                }
+            })
+        }
+    }
+
+    // 涓嬫媺鍒锋柊浼樺寲椤甸潰
+    const onRefresh = () => {
+        finished.value = false;
+        pageData.page = 0
+        loading.value = true;
+        onLoad();
+    }
+
+    onBeforeUnmount(() => {
+        $Bus.all.delete("changeOdr")
+    })
+</script>
+
+<style lang="scss" scoped>
+    .content {
+        width: 100%;
+        // height: 100%;
+        position: absolute;
+        background: #F7F7F7;
+        .content_list {
+            width: 100%;
+            height: 100%;
+            display: flex;
+            flex-direction: column;
+            .content_list_item {
+                padding: 30px;
+                background: #ffffff;
+                margin-bottom: 20px;
+                .content_list_item_title {
+                    display: flex;
+                    align-items: center;
+                    .content_list_item_title_tips {
+                        padding: 4px 8px;
+                        box-sizing: border-box;
+                        background: #DE5243;
+                        border-radius: 8px;
+                        font-size: 22px;
+                        font-family: PingFangSC-Regular, PingFang SC;
+                        font-weight: 400;
+                        color: #FFFFFF;
+                        margin-left: 16px;
+                    }
+                    .warning {
+                        color: $nav-stateColor1 !important;
+                    }
+                    .green {
+                        color: $nav-stateColor6 !important;
+                    }
+                    span {
+                        font-size: 32px;
+                        font-family: PingFangSC-Medium, PingFang SC;
+                        font-weight: 500;
+                        color: #333333;
+                    }
+                }
+                .content_list_item_nr {
+                    padding: 24px 30px;
+                    background: #F7F7F7;
+                    border-radius: 16px;
+                    margin-top: 30px;
+                    display: flex;
+                    justify-content: space-between;
+                    flex-wrap: wrap;
+                    .content_list_item_nr_boxs {
+                        width: 45%;
+                        display: flex;
+                        margin-top: 24px;
+                        &:nth-child(1) {
+                            margin-top: 0;
+                        }
+                        &:nth-child(2) {
+                            margin-top: 0;
+                        }
+                        .warning {
+                            color: $nav-stateColor4 !important;
+                        }
+                        .label {
+                            flex-shrink: 0;
+                            font-size: 24px;
+                            font-weight: 400;
+                            color: #666666;
+                        }
+                        .cr {
+                            flex: 1;
+                            font-size: 24px;
+                            font-weight: 400;
+                            color: #222222;
+                            overflow: hidden;
+                            white-space: nowrap;
+                            text-overflow: ellipsis;
+                            -o-text-overflow:ellipsis;
+                        }
+                    }
+                    .content_list_item_nr_box {
+                        width: 100%;
+                        display: flex;
+                        margin-top: 24px;
+                        &:nth-child(1) {
+                            margin-top: 0;
+                        }
+                        .label {
+                            font-size: 24px;
+                            font-weight: 400;
+                            color: #666666;
+                            flex-shrink: 0;
+                        }
+                        .cr {
+                            font-size: 24px;
+                            font-weight: 400;
+                            color: #222222;
+                        }
+                    }
+                }
+            }
+        }
+    }
+</style>
diff --git a/h5_standard/src/views/workOrder/reportingForWork.vue b/h5_standard/src/views/workOrder/reportingForWork.vue
index bd1cbe8..f6d30eb 100644
--- a/h5_standard/src/views/workOrder/reportingForWork.vue
+++ b/h5_standard/src/views/workOrder/reportingForWork.vue
@@ -1,42 +1,84 @@
 <template>
     <div class="bg">
-        <!--  鎶曟枡鏄庣粏/鍚堟牸浜у嚭鏄庣粏/涓嶈壇浜у嚭鏄庣粏  -->
+        <div class="bg_plan" @click="selectPlan">
+            <div class="bg_plan_label" v-if="!from.processPlan">
+                <span><b>*</b>宸ュ簭鐢熶骇璁″垝</span>
+            </div>
+            <div class="bg_plan_nr" v-else>
+                <span>{{ from.processPlan.materialName }} | {{ from.processPlan.materialCode }} | {{ from.processPlan.produceName }}</span>
+                <span>{{ from.processPlan.batch }}{{ from.processPlan.salesOrder ? ` / ${from.processPlan.salesOrder}` : '' }}</span>
+                <span>璁″垝鏃堕棿锛歿{ from.processPlan.workPlanStartDate }} ~ {{ from.processPlan.workPlanEndDate }}</span>
+                <span>璁″垝杩涘害锛歿{from.processPlan.num}}/{{from.processPlan.workorderDistributNum}}{{ from.processPlan.unitName }}</span>
+            </div>
+            <div class="bg_plan_label_val">
+                <span v-if="!from.processPlan">璇烽�夋嫨</span>
+                <img src="@/assets/icon/ic_ar@2x.png" alt="" />
+            </div>
+        </div>
         <div class="bg_list">
             <div class="bg_list_item">
                 <div class="bg_list_item_top">
                     <div class="bg_list_item_top_left">
                         <div class="bg_list_item_top_left_x"></div>
-                        <span>鎶曟枡鏄庣粏</span>
-                        <!-- <span class="blue left">{{tlTotal()}}</span> -->
-                    </div>
-                    <div class="bg_list_item_top_right" @click="jumpTL" v-if="proxy.$auth('h5:workorderinput:create') && (info.bomType !== 1 || info.bomType == 0 || !info.bomType)">
-                        <img src="@/assets/icon/gongdan_ic_shoudong@2x.png" alt="" />
-                        <span>鎵嬪姩褰曞叆</span>
+                        <span>鐢熶骇淇℃伅</span>
                     </div>
                 </div>
-                <template v-if="feedingData && feedingData.length > 0">
-                    <van-swipe-cell v-for="(item, index) in feedingData" :key="index">
-                        <div class="bg_list_item_num">
-                            <div class="bg_list_item_num_item">
-                                <!-- <span>{{item.code}}</span> -->
-                                <div class="bg_list_item_num_item_wl">
-                                    <span> {{ item.materialName }}{{ item.procedureName ? `&nbsp;|&nbsp;${item.procedureName}` : '' }}</span>
-                                    <div class="bg_list_item_num_item_wl_lx">
-                                        <span class="green" v-if="item.qualityType == 0">鍚堟牸&nbsp;/&nbsp;</span>
-                                        <span class="yellow" v-if="item.qualityType == 1">涓嶈壇&nbsp;/&nbsp;</span>
-                                        <span class="red" v-if="item.qualityType == 2">鎶ュ簾&nbsp;/&nbsp;</span>
-                                        <span>{{ item.locationName }}</span>
-                                        <span>{{ item.batch ? `&nbsp;/&nbsp;${item.batch}` : '' }}</span>
+                <div class="bg_list_item_h">
+                    <div class="bg_list_item_num" @click="openDev">
+                        <div class="bg_list_item_num_item">
+                            <span>鐢熶骇璁惧</span>
+                            <div class="bg_list_item_num_item_sr">
+                                <span :style="{color: from.deviceName ? '#333' : ''}">{{from.deviceName ? from.deviceName : '璇烽�夋嫨'}}</span>
+                                <img src="@/assets/icon/ic_ar@2x.png" alt="" />
+                            </div>
+                        </div>
+                    </div>
+                    <div class="bg_list_item_num" @click="userShow = true">
+                        <div class="bg_list_item_num_item">
+                            <span>鐢熶骇浜哄憳</span>
+                            <div class="bg_list_item_num_item_sr">
+                                <span :style="{color: from.userName ? '#333' : ''}">{{from.userName ? from.userName : '璇烽�夋嫨'}}</span>
+                                <img src="@/assets/icon/ic_ar@2x.png" alt="" />
+                            </div>
+                        </div>
+                    </div>
+                </div>
+            </div>
+            <div class="bg_list_item">
+                <div class="bg_list_item_top">
+                    <div class="bg_list_item_top_left">
+                        <div class="bg_list_item_top_left_x"></div>
+                        <span>鐢熶骇淇℃伅</span>
+                    </div>
+                    <div class="bg_list_item_top_right" @click="openMaterial" v-if="(hasBom == 1 && bomType != 1) || hasBom == 0">
+                        <img src="@/assets/icon/gongdan_ic_shoudong@2x.png" alt="" />
+                        <span>鏂板鎶曟枡</span>
+                    </div>
+                </div>
+                <template v-if="wuList.length > 0">
+                    <van-swipe-cell v-for="(item, index) in wuList" :key="index">
+                        <div class="bg_list_item_h">
+                            <div class="bg_list_item_num">
+                                <div class="bg_list_item_num_item">
+                                    <div class="bg_list_item_num_item_wl">
+                                        <span>{{ item.materialName }}{{ item.procedureName ? ` | ${item.procedureName}` : '' }}</span>
+                                        <div class="bg_list_item_num_item_wl_lx">
+                                            <span class="green" v-if="item.qualityType == 0">鍚堟牸&nbsp;/&nbsp;</span>
+                                            <span class="yellow" v-if="item.qualityType == 1">涓嶈壇&nbsp;/&nbsp;</span>
+                                            <span class="red" v-if="item.qualityType == 2">鎶ュ簾&nbsp;/&nbsp;</span>
+                                            <span>{{ item.locationName }}&nbsp;/&nbsp;</span>
+                                            <span>{{ item.batch }}</span>
+                                        </div>
                                     </div>
-                                </div>
-                                <div class="bg_list_item_num_item_sr">
-                                    <input v-model="item.num" :disabled="!proxy.$auth('h5:workorderinput:update')" @blur="change(item.id, item.num, 'T', item.maxNum, item, item.unitAttribute)" type="number" />
-                                    <span>{{item.unitName}}</span>
+                                    <div class="bg_list_item_num_item_sr">
+                                        <input type="number" v-model="item.num" @input="inputwl(index)" />
+                                        <span>{{ item.unitName }}</span>
+                                    </div>
                                 </div>
                             </div>
                         </div>
-                        <template #right v-if="proxy.$auth('h5:workorderinput:delete')">
-                            <van-button style="height: 100%;" square text="鍒犻櫎" @click="deleItem(item.id, 'T')" type="danger" />
+                        <template #right>
+                            <van-button style="height: 100%;" @click="deleItem(index)" square text="鍒犻櫎" type="danger" />
                         </template>
                     </van-swipe-cell>
                 </template>
@@ -45,993 +87,538 @@
                         <span>鏆傛棤鏁版嵁</span>
                     </div>
                 </template>
+                <div class="kong" v-if="hasBom == 1 && bomType == 1">
+                    <span>褰撳墠宸ュ簭鏃犻渶鎶曟枡</span>
+                </div>
             </div>
-            <div class="bg_list_item">
+            <div class="bg_list_item bottomval">
                 <div class="bg_list_item_top">
                     <div class="bg_list_item_top_left">
                         <div class="bg_list_item_top_left_x"></div>
                         <span>浜у嚭鏄庣粏</span>
                     </div>
                 </div>
-                <!-- <template v-if="produceData && produceData.length > 0"> -->
-                    <!-- v-for="(item, index) in produceData" :key="index" -->
-                    <van-swipe-cell>
-                        <div class="bg_list_item_num">
-                            <div class="bg_list_item_num_item">
-                                <span>鑹搧鏁�</span>
-                                <div class="bg_list_item_num_item_sr">
-                                    <!-- :disabled="!proxy.$auth('h5:workorderoutput:update')" -->
-                                    <!-- @blur="change(item.id, item.num, 'C', item.maxNum, item)" -->
-                                    <input type="number" v-model="produceFrom.qualified" @blur="changeCC('0', produceFrom.qualified, produceFrom.qualifiedId)" placeholder="璇疯緭鍏�" />
-                                    <span v-if="info.umodel">{{info.umodel.name}}</span>
-                                </div>
+                <div class="bg_list_item_h">
+                    <div class="bg_list_item_num">
+                        <div class="bg_list_item_num_item">
+                            <span><b>*</b>鑹搧鏁�</span>
+                            <div class="bg_list_item_num_item_sr">
+                                <input type="number" v-model="from.qualified" @input="changeNum(1)" placeholder="璇疯緭鍏�" />
+                                <span>鍧�</span>
                             </div>
                         </div>
-                    </van-swipe-cell>
-                    <van-swipe-cell>
-                        <div class="bg_list_item_num">
-                            <!-- @blur="change(item.id, item.num, 'C', item.maxNum, item)" -->
-                            <div class="bg_list_item_num_item">
-                                <span>涓嶈壇鏁�</span>
-                                <div class="bg_list_item_num_item_sr">
-                                    <!-- :disabled="!proxy.$auth('h5:workorderoutput:update')" -->
-                                    <!-- @blur="change(item.id, item.num, 'C', item.maxNum, item)" -->
-                                    <input type="number" v-model="produceFrom.undesirable" @blur="changeCC('1', produceFrom.undesirable, produceFrom.undesirableId)" placeholder="璇疯緭鍏�" />
-                                    <span v-if="info.umodel">{{info.umodel.name}}</span>
-                                </div>
-                            </div>
-                        </div>
-                    </van-swipe-cell>
-                    <!-- <van-swipe-cell>
-                        <div class="bg_list_item_num">
-                            <div class="bg_list_item_num_item" @click="show = true">
-                                <span>涓嶈壇椤�</span>
-                                <div class="bg_list_item_num_item_sr">
-                                    <span>璁剧疆 ></span>
-                                </div>
-                            </div>
-                        </div>
-                    </van-swipe-cell> -->
-                <!-- </template>
-                <template v-else>
-                    <div class="kong">
-                        <span>鏆傛棤鏁版嵁</span>
                     </div>
-                </template> -->
+                    <div class="bg_list_item_num">
+                        <div class="bg_list_item_num_item">
+                            <span>涓嶈壇鏁�</span>
+                            <div class="bg_list_item_num_item_sr">
+                                <input type="number" v-model="from.undesirable" @input="changeNum(2)" placeholder="璇疯緭鍏�" />
+                                <span>鍧�</span>
+                            </div>
+                        </div>
+                    </div>
+                    <div class="bg_list_item_num" v-if="from.undesirable > 0">
+                        <div class="bg_list_item_num_item" @click="show = true">
+                            <span><b>*</b>涓嶈壇椤�</span>
+                            <div class="bg_list_item_num_item_sr">
+                                <span class="wulll" :style="{color: from.defectiveName ? '#305ED5' : ''}">{{from.defectiveName ? from.defectiveName : '璁剧疆'}}</span>
+                                <img src="@/assets/icon/ic_ar@2x.png" alt="" />
+                            </div>
+                        </div>
+                    </div>
+                </div>
             </div>
-            <!-- <div class="bg_list_item">
+            <div class="bg_plan" @click="TimeShow = true">
+                <div class="bg_plan_label">
+                    <span><b>*</b>鎶ュ伐鏃堕暱</span>
+                </div>
+                <div class="bg_plan_label_val">
+                    <span :style="{color: from.durationName ? '#333' : ''}">{{from.durationName ? from.durationName : '璇烽�夋嫨'}}</span>
+                    <img src="@/assets/icon/ic_ar@2x.png" alt="" />
+                </div>
+            </div>
+            <div class="bg_list_item" v-if="infoBox">
                 <div class="bg_list_item_top">
                     <div class="bg_list_item_top_left">
                         <div class="bg_list_item_top_left_x"></div>
-                        <span>鍚堟牸浜у嚭鏄庣粏</span>
-                        <span class="blue left">{{ccTotal()}}</span>
-                    </div>
-                    <div class="bg_list_item_top_right" @click="jumpCC" v-if="proxy.$auth('h5:workorderoutput:create')">
-                        <img src="@/assets/icon/gongdan_ic_shoudong@2x.png" alt="" />
-                        <span>鎵嬪姩褰曞叆</span>
+                        <span>宸ヨ祫缁╂晥</span>
                     </div>
                 </div>
-                <template v-if="produceData && produceData.length > 0">
-                    <van-swipe-cell v-for="(item, index) in produceData" :key="index">
-                        <div class="bg_list_item_num">
-                            <div class="bg_list_item_num_item">
-                                <span>{{item.code}}</span>
-                                <div class="bg_list_item_num_item_sr">
-                                    <input v-model="item.num" :disabled="!proxy.$auth('h5:workorderoutput:update')" @blur="change(item.id, item.num, 'C', item.maxNum, item)" type="number" />
-                                    <span>{{item.company}}</span>
-                                </div>
+                <div class="bg_list_item_h">
+                    <div class="bg_list_item_num">
+                        <div class="bg_list_item_num_item">
+                            <span>璁′欢鏂瑰紡</span>
+                            <div class="bg_list_item_num_item_list">
+                                <div class="bg_list_item_num_item_list_item active" v-if="infoBox.type == 0">璁′欢</div>
+                                <div class="bg_list_item_num_item_list_item active" v-if="infoBox.type == 1">璁℃椂</div>
                             </div>
                         </div>
-                        <template #right v-if="proxy.$auth('h5:workorderoutput:delete')">
-                            <van-button style="height: 100%;" square text="鍒犻櫎" @click="deleItem(item.id, 'C')" type="danger" />
-                        </template>
-                    </van-swipe-cell>
-                </template>
-                <template v-else>
-                    <div class="kong">
-                        <span>鏆傛棤鏁版嵁</span>
                     </div>
-                </template>
-            </div>
-
-            <div class="bg_list_item">
-                <div class="bg_list_item_top">
-                    <div class="bg_list_item_top_left">
-                        <div class="warning"></div>
-                        <span>涓嶈壇浜у嚭鏄庣粏</span>
-                        <span class="yellow left">{{blTotal()}}</span>
-                    </div>
-                </div>
-                <template v-if="undesirable && undesirable.length > 0">
-                    <van-swipe-cell v-for="(item, index) in undesirable" :key="index">
-                        <div class="bg_list_item_num">
-                            <div class="bg_list_item_num_item">
-                                <span>{{item.code}}</span>
-                                <div class="bg_list_item_num_item_sr">
-                                    <input v-model="item.num" :disabled="!proxy.$auth('h5:workorderoutput:update')" @blur="change(item.id, item.num, 'C', item.maxNum, item)" type="number" />
-                                    <span>{{item.company}}</span>
-                                </div>
+                    <div class="bg_list_item_num">
+                        <div class="bg_list_item_num_item">
+                            <span>宸ヨ祫鍗曚环</span>
+                            <div class="bg_list_item_num_item_sr">
+                                <span class="color1">{{infoBox.salary}}鍏�/{{infoBox.type == 0 ? '浠�' : '鏃�'}}</span>
                             </div>
                         </div>
-                        <template #right v-if="proxy.$auth('h5:workorderoutput:delete')">
-                            <van-button style="height: 100%;" square text="鍒犻櫎" @click="deleItem(item.id, 'C')" type="danger" />
-                        </template>
-                    </van-swipe-cell>
-                </template>
-                <template v-else>
-                    <div class="kong">
-                        <span>鏆傛棤鏁版嵁</span>
                     </div>
-                </template>
-            </div>
-
-            <div class="bg_list_item">
-                <div class="bg_list_item_top">
-                    <div class="bg_list_item_top_left">
-                        <div class="error"></div>
-                        <span>鎶ュ簾浜у嚭鏄庣粏</span>
-                        <span class="red left">{{bfTotal()}}</span>
-                    </div>
-                </div>
-                <template v-if="scrap && scrap.length > 0">
-                    <van-swipe-cell v-for="(item, index) in scrap" :key="index">
-                        <div class="bg_list_item_num">
-                            <div class="bg_list_item_num_item">
-                                <span>{{item.code}}</span>
-                                <div class="bg_list_item_num_item_sr">
-                                    <input v-model="item.num" :disabled="!proxy.$auth('h5:workorderoutput:update')" @blur="change(item.id, item.num, 'C', item.maxNum, item)" type="number" />
-                                    <span>{{item.company}}</span>
-                                </div>
+                    <div class="bg_list_item_num">
+                        <div class="bg_list_item_num_item">
+                            <span>棰勮宸ヨ祫</span>
+                            <div class="bg_list_item_num_item_sr">
+                                <span class="color1">{{expectedSalary}}鍏�</span>
                             </div>
                         </div>
-                        <template #right v-if="proxy.$auth('h5:workorderoutput:delete')">
-                            <van-button style="height: 100%;" square text="鍒犻櫎" @click="deleItem(item.id, 'C')" type="danger" />
-                        </template>
-                    </van-swipe-cell>
-                </template>
-                <template v-else>
-                    <div class="kong">
-                        <span>鏆傛棤鏁版嵁</span>
                     </div>
-                </template>
-            </div> -->
-        </div>
-        <div class="details_dj">
-            <div class="details_dj_title">
-                <div class="details_dj_title_left">
-                    <div class="details_x"></div>
-                    <span>鐢熶骇鐐规</span>
-                </div>
-                <div class="details_dj_title_right" @click="jumpdj" v-if="proxy.$auth('h5:workorder:processRecord')">
-                    <img src="@/assets/icon/gongdan_ic_shoudong@2x.png" alt="" />
-                    <span>鎵嬪姩褰曞叆</span>
-                </div>
-            </div>
-            <div class="details_dj_list">
-                <van-list
-                    v-model:loading="loading"
-                    :finished="finished"
-                    finished-text="娌℃湁鏇村浜唦"
-                    @load="pageDJs">
-                    <van-swipe-cell v-for="(item, index) in djData" :key="index">
-                        <div class="details_dj_list_item">
-                            <span>{{item.attrName}}锛歿{item.val}}</span>
-                            <span>{{item.userName}} {{item.createTime}}</span>
+                    <div class="bg_list_item_num">
+                        <div class="bg_list_item_num_item">
+                            <span>杈炬爣鐜�</span>
+                            <div class="bg_list_item_num_item_sr">
+                                <span class="color1">{{complianceRate}}%</span>
+                            </div>
                         </div>
-                        <template #right>
-                            <van-button square type="danger" style="height: 100%;" @click="dele(item.id)" text="鍒犻櫎" />
-                        </template>
-                    </van-swipe-cell>
-                </van-list>
+                    </div>
+                </div>
             </div>
         </div>
         <!--  鎶ュ伐鎸夐挳  -->
-        <template v-if="info.status === 2 || info.procedureNeedcheck === 1">
-            <div class="bh_zw"></div>
-            <div class="bg_footer">
-                <div class="bg_footer_submit" @click="submit">纭鎶ュ伐</div>
-            </div>
-        </template>
-        <!--  鎵爜缁勪欢  -->
-        <v-ScanCode
-            :openCode="openCode"
-            :infos="['璇锋壂鎻忓伐瑁呯爜']"
-            @closePopup="closePopup"
-            @onDecode="onDecode" />
-        <!--  鎶ュ伐缁熻鏁版嵁  -->
-        <van-popup v-model:show="statistics" round :closeable="true" position="bottom" :style="{ height: '53%' }">
-            <div class="tg">
-                <div class="tg_header">璇风‘璁ゆ姤宸ヤ俊鎭�</div>
-                <div class="tg_table">
-                    <div class="tg_table_header">
-                        <div class="tg_table_header_item">绫诲瀷</div>
-                        <div class="tg_table_header_item">鐗╂枡鍚嶇О</div>
-                        <!-- <div class="tg_table_header_item">宸ヨ鏁伴噺</div> -->
-                        <div class="tg_table_header_item">鐗╂枡鏁伴噺</div>
-                    </div>
-                    <div class="nr" v-if="statisticsData.length > 0">
-                        <div class="tg_table_nr" v-for="(item, index) in statisticsData" :key="index">
-                            <div class="tg_table_nr_item">{{item.name}}</div>
-                            <div class="tg_table_nr_item">{{item.materialName}}</div>
-                            <!-- <div class="tg_table_nr_item">{{item.gznum}}</div> -->
-                            <div class="tg_table_nr_item" :style="item.name === '宸ュ崟鏈姇鏂�' ? 'color: #DE5243' : ''">{{item.num}}</div>
-                        </div>
-                    </div>
-                    <div class="nr" v-else>
-                        <div class="tg_table_nr">
-                            <div class="tg_table_nr_item1">鏆傛棤鏁版嵁</div>
-                        </div>
-                    </div>
-                </div>
-                <div class="tg_footer">
-                    <button class="tg_footer_qr" @click="submitBG" v-if="proxy.$auth('h5:workorderoutput:confirm') && isSubmit">纭鎶ュ伐</button>
-                    <div class="tg_footer_fh" @click="gofh" v-else-if="!isSubmit">杩斿洖淇敼</div>
-                </div>
-            </div>
-        </van-popup>
+        <div class="bh_zw"></div>
+        <div class="bg_footer">
+            <div class="bg_footer_submit1">缁х画鎶ュ伐</div>
+            <div class="bg_footer_submit" @click="submit">鎻愪氦</div>
+        </div>
         <!-- 閫夋嫨涓嶈壇椤� -->
         <van-popup v-model:show="show" round position="bottom" :style="{ height: '53%' }">
             <div class="bl">
                 <div class="bl_head">
-                    <span @click="show = false">鍙栨秷</span>
+                    <img src="@/assets/icon/ic_close@2x.png" style="opacity: 0;" alt="" />
                     <span>涓嶈壇椤�</span>
-                    <span>纭</span>
+                    <!-- <span>纭</span> -->
+                    <img src="@/assets/icon/ic_close@2x.png" @click="show = false" alt="" />
                 </div>
                 <div class="bl_list">
-                    <div class="bl_list_item" v-for="(item, i) in 12" :key="i">
+                    <div class="bl_list_item" v-for="(item, i) in cateList" :key="i" @click="changeChecked(i)">
                         <div class="bl_list_item_left">
-                            <input type="checkbox" :checked="true" name="" id="" />
-                            <span>鏈夊垝鐥�</span>
+                            <input type="checkbox" :checked="item.active" />
+                            <span>{{ item.name }}</span>
                         </div>
                         <div class="bl_list_item_right">
-                            <input type="number" placeholder="璇疯緭鍏�" />
+                            <input type="number" @click.stop v-model="item.num" placeholder="0" />
                         </div>
                     </div>
                 </div>
+                <div class="bl_footer" @click="onConfirm3">纭</div>
             </div>
+        </van-popup>
+        <!--  鍏ュ簱鐗╂枡  -->
+        <MaterialY :show="show1" :plansId="String(plansId)" :ids="ids" :deviceId="String(deviceId)" @close="close" @value="getValue" />
+        <!-- 璁惧 -->
+        <van-popup v-model:show="deviceShow" round position="bottom" :style="{ height: '50%' }">
+            <van-picker
+                :columns="deviceList"
+                @confirm="onConfirm"
+                @cancel="onCancel"
+                :columns-field-names="customFieldName"
+            />
+        </van-popup>
+        <!-- 浜哄憳 -->
+        <user :show="userShow" @close="onCancel1" @value="onConfirm1" />
+        <!-- 鏃堕棿 -->
+        <van-popup v-model:show="TimeShow" round position="bottom" :style="{ height: '50%' }">
+            <van-datetime-picker
+                v-model="from.time"
+                type="time"
+                title="閫夋嫨鏃堕棿"
+                @confirm="onConfirm2"
+                @cancel="onCancel2"
+            />
         </van-popup>
     </div>
 </template>
 
 <script setup lang="ts">
-    import { getCurrentInstance, nextTick, onMounted, ref, reactive } from 'vue'
-    import { useRouter, useRoute } from "vue-router"
-    import { Dialog, Toast } from 'vant'
-    import { REGULAR } from '@/utils/utils'
-    import {
-        getBarcodeContent,
-        queryById,
-        getOrocessRecord,
-        deleteCT,
-        updateById,
-        comfirmDone,
-        comfirmDoneStandard,
-        getListByCondition,
-        allForStandard,
-        pageDJ,
-        deletedj,
-        dealWorkorderRecordStandard,
-        getWorkorderRecordListStandard
-    } from '@/apis/WorkOrderAPI'
-    import { QRCodeType } from '@/enum'
-    const { proxy }: any = getCurrentInstance()
-    import VWorkOrderInfo from '@/components/common/WorkOrderInfo.vue'
+    import { onMounted, ref, reactive, getCurrentInstance, computed } from 'vue'
+    import { useRouter } from 'vue-router'
+    import { getDeviceByCondition, getFindAll, queryOne, autoWorkReport, getIdPlansExt, categoryExtList } from '@/apis/PlanningAPI'
+    import MaterialY from '@/components/newCom/MaterialY.vue'
+    import user from '@/components/newCom/user.vue'
+    import { Toast } from 'vant'
 
+    const {$Bus} = getCurrentInstance().appContext.config.globalProperties 
     const router = useRouter()
-    const route = useRoute()
-
-    const loading = ref(false);
-    const finished = ref(false);
     let show = ref(false)
-    // 鐐规鏁版嵁
-    let djData: any = ref([])
-    // 鍒嗛〉鏌ヨ鏁版嵁
-    let page = reactive({
-        capacity: 10,
-        page: 0
+    let show1 = ref(false)
+    let TimeShow = ref(false)
+    let deviceId = ref('')
+    let plansId = ref('')
+    let ids = ref('')
+    let total: any = ref('')    // 鍙姇鏁伴噺
+
+    let from: any = reactive({
+        processPlan: null,
+        deviceId: '',
+        deviceName: '',
+        userId: '',
+        userName: '',
+        qualified: '',  // 鑹搧鏁�
+        undesirable: '', // 涓嶈壇鏁�
+        duration: '',
+        durationName: '',
+        time: '',
+        defective: [],
+        defectiveName: ''
     })
 
-    // 浜у嚭鍚堟牸/涓嶈壇
-    let produceFrom = reactive({
-        qualifiedId: '',
-        qualified: '',  // 鍚堟牸
-        undesirableId: '',
-        undesirable: '' // 涓嶈壇
-    })
+    let infoBox: any = ref(null)     // 宸ヨ祫缁╂晥
 
-    // 璇︽儏鏁版嵁
-    const info: any = ref({})
+    let bomType: any = ref('')
+    let hasBom: any = ref('')
+    let deviceShow = ref(false)
+    let deviceList = ref([])
+    let cateList:any = ref([])
+    const customFieldName = {
+        text: 'name'
+    };
+    let userShow = ref(false)
+    let userList = ref([])
+    let wuList: any = ref([])
 
-    // 鍒ゆ柇鏄惁鑳芥彁浜�
-    let isSubmit: any = ref<boolean>(false)
-
-    // 涓嶈壇鏄庣粏
-    let undesirable: any = ref([])
-
-    // 鎶ュ簾鏄庣粏
-    let scrap: any = ref([])
-
-    // 鎵爜绫诲瀷
-    let type: any = ref('')
-
-    // 缁熻鏁版嵁
-    let statisticsData: any = ref([
-        // {
-        //     name: '宸ュ崟鎶曟枡',
-        //     materialName: '榛勬矙',
-        //     num: 0
-        // },
-        // {
-        //     name: '宸ュ崟鍚堟牸浜у嚭',
-        //     materialName: '榛勬矙',
-        //     num: 0
-        // },
-        // {
-        //     name: '宸ュ崟涓嶈壇浜у嚭',
-        //     materialName: '榛勬矙',
-        //     num: 0
-        // },
-        // {
-        //     name: '宸ュ崟鏈姇鏂�',
-        //     materialName: '榛勬矙',
-        //     num: 0
-        // }
-    ])
-
-    // 鎶曟枡鏁版嵁
-    const feedingData: any = ref([])
-
-    // 浜у嚭鏁版嵁
-    const produceData: any = ref([])
-
-    // 鎺у埗鎵爜鏄剧ず闅愯棌
-    const openCode = ref<boolean>(false)
-
-    // 鎺у埗鎶ュ伐缁熻
-    const statistics = ref<boolean>(false)
-
-    // 鎶曟枡缁熻
-    const tlTotal = (): string => {
-        if (feedingData.value.length > 0) {
-            let total: number = 0
-            feedingData.value.forEach((element: any) => {
-                total = total + element.num
-            })
-            return `${total}`
+    // 浜у嚭鏁伴噺楠岃瘉
+    const changeNum = (type: number) => {
+        let num = total.value - (Number(from.qualified) + Number(from.undesirable))
+        if (type == 2) {
+            from.defective = []
+            from.defectiveName = ''
         }
-        return ''
-    }
-
-    // 淇敼浜у嚭
-    const changeCC = (downType: string, num: number, recordId: string) => {
-        if (!num) return
-        console.log(produceFrom.qualified + produceFrom.undesirable)
-        if ((produceFrom.qualified + produceFrom.undesirable) > info.value.planNum) {
-            return Toast.fail({ message: '浜у嚭鏁伴噺涓嶈兘澶т簬璁″垝鏁伴噺', duration: 2000 })
-        }
-        if (num >= 0) {
-            dealWorkorderRecordStandard({
-                downType, num, recordId, workorderId: route.query.id
-            }).then(res => {
-                if (res.code === 200) {
-                    getOrocessRecordCC()
-                }
-            })
-        } else {
-            if (downType == 0) {
-                produceFrom.qualified = 0
+        if (num < 0) {
+            Toast('浜у嚭鏁伴噺涓嶈兘澶т簬鍙骇鍑烘暟閲忥紒')
+            if (type == 1) {
+                from.qualified = ''
             } else {
-                produceFrom.undesirable = 0
+                from.undesirable = ''
             }
-            Toast.fail({ message: '浜у嚭鏁伴噺涓嶈兘灏忎簬0', duration: 2000 })
         }
     }
 
-    // 璺宠浆鐐规
-    const jumpdj = () => {
-        router.push({ name: 'spotCheck', query: { id: route.query.id } })
-    }
-
-    // 鍒犻櫎鐐规
-    const dele = (id: string | number): void => {
-        deletedj(id)
-            .then(res => {
-                if (res.code === 200) {
-                    djData.value = []
-                    finished.value = false
-                    page.page = 0
-                    pageDJs()
-                }
-            })
-    }
-
-    // 鐐规鏁版嵁
-    const pageDJs = () => {
-        if (!finished.value) {
-            page.page = page.page + 1
-            loading.value = true
-            pageDJ({
-                capacity: page.capacity,
-                page: page.page,
-                model: {
-                    workorderId: route.query.id
-                }
-            }).then(res => {
-                if (res.code === 200 && res.data && res.data.records.length !== 0) {
-                    djData.value.push(...res.data.records)
-                } else {
-                    finished.value = true
-                }
-                loading.value = false
-            }).catch(err => {
-                loading.value = false
-                finished.value = true
-            })
+    // 楠岃瘉鐗╂枡鏁伴噺
+    const inputwl = (i: number) => {
+        if (wuList.value[i].num > wuList.value[i].total) {
+            wuList.value[i].num = ''
+            Toast('鎶曟枡鏁伴噺涓嶈兘澶т簬搴撳瓨鏁伴噺')
         }
     }
 
-    // 缁熻
-    const ccTotal = (): string => {
-        if (produceData.value.length > 0) {
-            let total: number = 0
-            produceData.value.forEach((element: any) => {
-                total = total + element.num
-            })
-            return `${total}${produceData.value[0].company}`
-        }
-        return ''
+    const changeChecked = (i: number) => {
+        cateList.value[i].active = !cateList.value[i].active
     }
 
-    // 缁熻
-    const blTotal = (): string => {
-        if (undesirable.value.length > 0) {
-            let total: number = 0
-            undesirable.value.forEach((element: any) => {
-                total = total + element.num
-            })
-            return `${total}${undesirable.value[0].company}`
-        }
-        return ''
-    }
-
-    // 缁熻
-    const bfTotal = (): string => {
-        if (scrap.value.length > 0) {
-            let total: number = 0
-            scrap.value.forEach((element: any) => {
-                total = total + element.num
-            })
-            return `${total}${scrap.value[0].company}`
-        }
-        return ''
-    }
-
-    // 鍒犻櫎浜у嚭/鎶曟枡
-    const deleItem = (id: any, type: string) => {
-        Dialog.confirm({
-            title: '鎻愮ず',
-            message: '纭畾鍒犻櫎姝ゆ潯璁板綍鍚楋紵',
-        }).then(() => {
-            deleteCT(id)
-                .then(res => {
-                    if (res.code === 200 && type === 'C') {
-                        getOrocessRecordCC()
-                    } else if (res.code === 200 && type === 'T') {
-                        getOrocessRecords()
-                    }
-                })
-        }).catch(() => {
-            // on cancel
+    const onConfirm3 = () => {
+        let isOpen = false
+        cateList.value.forEach((item: any, index: number) => {
+            if (item.active) {
+                isOpen = true
+            }
         })
-    }
-
-    // 璺宠浆鎵嬪姩浜у嚭
-    const jumpCC = () => {
-        router.push({ name: 'manualOutput', query: { id: route.query.id, num: produceData.value.length > 0 ? produceData.value[0].num : '' } })
-    }
-
-    // 璺宠浆鎵嬪姩鎶曟枡
-    const jumpTL = () => {
-        router.push({ name: 'manualFeeding', query: { id: route.query.id } })
-    }
-
-    // 鍏抽棴鎵爜缁勪欢
-    const closePopup = (): void => {
-        openCode.value = false
-    }
-
-    // 鑾峰彇鎵爜鍊�
-    const onDecode = (data: string[]): void => {
-        getBarcodeContent({
-            barcode: data[0]
-        }).then(res => {
-            if (res.code === 200) {
-                if (res.data.barcodeType === QRCodeType.GZ) {
-                    if (type.value === 'tl') {    // 鎶曟枡鎿嶄綔
-                        getListByCondition({ id: res.data.id })
-                            .then(gz => {
-                                if (gz.code === 200) {
-                                    if (gz.data[0].status !== 1) {
-                                        router.push({ name: 'codeScanningFeeding', query: { id: route.query.id, gzId: res.data.id } })
-                                    } else {
-                                        Toast.fail({ message: '鎵弿鐨勫伐瑁呯姸鎬佷笉鑳戒负绌�', duration: 2000 })
-                                    }
-                                }
-                            })
-                    }
-                    if (type.value === 'cc') {    // 浜у嚭鎿嶄綔
-                        router.push({ name: 'codeScanningOutput', query: { id: route.query.id, gzId: res.data.id } })
-                    }
-                } else {
-                    Toast({ message: '璇锋壂鎻忔纭殑绡瓙鐮�', duration: 2000 })
+        if (!isOpen) return Toast('璇烽�夋嫨涓嶈壇椤�')
+        let arr: any = []
+        let total: any = 0
+        let name: any = ''
+        cateList.value.forEach((item: any, index: number) => {
+            if (item.active) {
+                if (item.num <= 0) {
+                    return Toast('涓嶈壇鏁伴噺蹇呴』澶т簬0')
                 }
+                total = total += item.num
+                arr.push(item)
+                name += item.name + item.num + '锛�'
             }
         })
-        nextTick(() => {
-            openCode.value = false
-        })
+        if (total !== from.undesirable) return Toast('涓嶈壇鏁板繀椤荤瓑浜庝骇鍑轰笉鑹暟')
+        from.defective = arr
+        from.defectiveName = name
+        show.value = false
     }
 
-    // 璺宠浆鎵嬪姩鎶曟枡
-    const jump = () => {
-        router.push({ name: 'manualFeeding', query: { id: route.query.id } })
-    }
-
-    // 璺宠浆鎵爜鎶曟枡
-    const jump1 = (types: string) => {
-        type.value = types
-        openCode.value = true
-    }
-
-    // 鏌ヨ宸ュ崟璇︽儏
-    const queryByIds = () => {
-        queryById(route.query.id).then(res => {
-            if (res.code === 200) {
-                info.value = res.data
-            }
-        })
-    }
-
-    // 鏌ヨ宸ュ崟鐢熶骇璁板綍---鎶曟枡
-    const getOrocessRecords = () => {
-        feedingData.value = []
-        allForStandard({
-            workorderId: route.query.id,
-            type: 0
-        }).then(res => {
-            if (res.code === 200) {
-                feedingData.value = res.data
-                // res.data.forEach((item: any) => {
-                //     feedingData.value.push({ id: item.id, company: item.umodel.name, gz: item.amodel.code, name: item.mmodel.name, code: item.amodel.code + ' - ' + item.mmodel.name, num: item.num, ynum: item.num, maxNum: item.amodel.num })
-                // })
-            }
-        })
-    }
-
-    // 鏌ヨ宸ュ崟鐢熶骇璁板綍---浜у嚭
-    const getOrocessRecordCC = () => {
-        produceData.value = []
-        undesirable.value = []
-        scrap.value = []
-        getWorkorderRecordListStandard({
-            workorderId: route.query.id
-        }).then(res => {
-            if (res.code === 200) {
-                if (res.data.length > 0) {
-                    res.data.forEach((item: any) => {
-                        if (item.doneType === 1) {
-                            produceFrom.undesirable = item.num
-                            produceFrom.undesirableId = item.id
-                        } else {
-                            produceFrom.qualified = item.num
-                            produceFrom.qualifiedId = item.id
-                        }
-                    })
-                }
-                // res.data.forEach((item: any) => {
-                //     if (item.doneType === 0 || !item.doneType) { // 鍚堟牸 | 娣峰悎
-
-                //         produceData.value.push({ id: item.id, company: item.umodel.name, name: item.mmodel.name, code: item.amodel.code + ' - ' + item.mmodel.name, num: item.num, ynum: item.num, maxNum: item.amodel.num })
-                //     } else if (item.doneType === 1) { // 涓嶈壇
-                //         undesirable.value.push({ id: item.id, company: item.umodel.name, name: item.mmodel.name, code: item.amodel.code + ' - ' + item.mmodel.name, num: item.num, ynum: item.num, maxNum: item.amodel.num })
-                //     } else if (item.doneType === 2) { // 鎶ュ簾
-                //         scrap.value.push({ id: item.id, company: item.umodel.name, name: item.mmodel.name, code: item.amodel.code + ' - ' + item.mmodel.name, num: item.num, ynum: item.num, maxNum: item.amodel.num })
-                //     }
-                // })
-            }
-        })
-    }
-
-    // 缂栬緫鎶曟枡/浜у嚭
-    const change = (id: any, num: any, type: any, maxNum: number, item: object, unitAttribute: number): void => {
-        let obj: any = item
-        if (type === 'T') {
-            if (unitAttribute == 0 && num != '') {
-                if(!REGULAR.positiveInteger.test(num)){
-                    obj.num = obj.ynum
-                    Toast({ message: '鍙兘杈撳叆姝f暣鏁�' })
-                    return
-                }
-            }
-            if (unitAttribute == 1 && num != '') {
-                if(!REGULAR.number.test(num)){
-                    Toast({ message: '鍙兘杈撳叆姝f暣鏁版垨灏忔暟锛堟渶澶氬洓浣嶏級' })
-                    obj.num = obj.ynum
-                    return
-                }
-            }
-            if (num > maxNum) {
-                obj.num = obj.ynum
-                Toast.fail({ message: '瓒呭嚭宸ヨ鎬绘暟' })
-                return
-            }
-        } else if (type === 'C' && num > info.value.planNum) {
-            obj.num = obj.ynum
-            Toast.fail({ message: '浜у嚭鏁伴噺涓嶈兘瓒呰繃璁″垝鏁伴噺' })
-            return
-        }
-        updateById({ id: id, num: num }).then(res => {
-            if (res.code === 200 && type === 'T') {
-                getOrocessRecords()
-            } else if (res.code === 200 && type === 'C') {
-                getOrocessRecordCC()
-            }
-        })
-    }
-
-    // 纭鎶ュ伐
     const submit = () => {
-        if (info.value.bomType === 1) {  // 鎷夊紡
-            console.log('鎷夊紡')
-            statisticsData.value = []
-            if (info.value.hasBom === 0) {
-                console.log('鏃燽om')
-                // let data: any = [
-                //     { name: '宸ュ崟鎶曟枡', gznum: feedingData.value.length, wlmc: feedingData.value.length > 0 ? feedingData.value[0].name : '', wlnum: 0 },
-                //     { name: '宸ュ崟鍚堟牸浜у嚭', gznum: produceData.value.length, wlmc: produceData.value.length > 0 ? produceData.value[0].name : '', wlnum: 0 },
-                //     { name: '宸ュ崟涓嶈壇浜у嚭', gznum: 0, wlmc: '', wlnum: 0 },
-                //     { name: '宸ュ崟鏈姇鏂�', gznum: '', wlmc: feedingData.value.length > 0 ? feedingData.value[0].name : '', wlnum: 0 }
-                // ]
-                // if (undesirable.value.length > 0) {   // 鍒ゆ柇鏈夋病鏈変笉鑹�
-                //     data[2].wlmc = undesirable.value[0].name
-                //     data[2].gznum = data[2].gznum + undesirable.value.length
-                // }
-                // if (scrap.value.length > 0) {   // 鍒ゆ柇鏈夋病鏈変笉鑹�
-                //     data[2].wlmc = scrap.value[0].name
-                //     data[2].gznum = data[2].gznum + scrap.value.length
-                // }
-                // let tl: number = 0
-                // let cc: number = 0
-                // let bl: number = 0
-                // undesirable.value.forEach((item: any) => {  // 涓嶈壇
-                //     bl = bl + item.num
-                // })
-                // scrap.value.forEach((item: any) => {  // 鎶ュ簾
-                //     bl = bl + item.num
-                // })
-                // if (produceData.value.length > 0) {   // 鍒ゆ柇鏈夋病鏈夊悎鏍间骇鍑�
-                //     produceData.value.forEach((item: any) => {  // 浜у嚭
-                //         cc = cc + item.num
-                //     })
-                // }
-                // feedingData.value.forEach((item: any) => {  // 鎶曟枡
-                //     tl = tl + item.num
-                // })
-                // data[0].wlnum = tl.toString() + info.value.umodel.name
-                // if (produceData.value.length > 0) {
-                //     data[1].wlnum = cc.toString() + info.value.umodel.name
-                // }
-                // data[2].wlnum = bl.toString() + info.value.umodel.name
-                // let total: number = info.value.planNum - (Number(cc) + Number(bl))
-                // data[data.length - 1].wlnum = (info.value.planNum - Number(cc) - Number(bl)).toString() + info.value.umodel.name
-                // if (total === 0) {
-                //     isSubmit.value = true
-                // } else {
-                //     isSubmit.value = false
-                // }
-
-                let arr: any = []
-                let tl = 0
-                let res = getGroupNum(feedingData.value)
-                for (let i in res) {
-                    let num = 0
-                    res[i].forEach((item: any) => {
-                        num += item.num
-                    })
-                    arr.push({ name: '宸ュ崟鎶曟枡', materialName: i + res[i][0].procedureName, num: num })
-                }
-                feedingData.value.forEach((item: any) => {
-                    tl += item.num
-                })
-                statisticsData.value = [...statisticsData.value, ...arr]
-                statisticsData.value.push({ name: '宸ュ崟鍚堟牸浜у嚭', materialName:  info.value.mmodel.name + '-' + info.value.procedureName, num: produceFrom.qualified })
-                statisticsData.value.push({ name: '宸ュ崟涓嶈壇浜у嚭', materialName:  info.value.mmodel.name + '-' + info.value.procedureName, num: produceFrom.undesirable })
-                statisticsData.value.push({ name: '宸ュ崟鏈姇鏂�', materialName: '', num: info.value.planNum - Number(produceFrom.qualified) - Number(produceFrom.undesirable) })
-                let total: number = info.value.planNum - (Number(produceFrom.qualified) + Number(produceFrom.undesirable))
-                if (total === 0) {
-                    isSubmit.value = true
-                } else {
-                    isSubmit.value = false
-                }
-                // if (Number(tl) <= info.value.planNum) {
-                //   let total: number = Number(tl) - Number(cc) - Number(bl)  // 鏄惁鏈変綑
-                //   data[data.length - 1].wlnum = (Number(tl) - Number(cc) - Number(bl)).toString() + info.value.umodel.name
-                //   if (total === 0) {
-                //     isSubmit.value = true
-                //   } else {
-                //     isSubmit.value = false
-                //   }
-                // } else {
-                //   isSubmit.value = false
-                // }
-                // statisticsData.value = data
-            } else if (info.value.hasBom === 1) {  // 鏈塨om鎯呭喌
-                console.log('鏈塨om')
-                // let cc: number = 0
-                // let bl: number = 0
-                // let newData: any = {}
-                // if (feedingData.value.length > 0) {  // 鎶曟枡
-                //     feedingData.value.forEach((e: any) => {
-                //         if (Object.keys(newData).indexOf('' + e.name) === -1) {
-                //             newData[e.name] = []
-                //         }
-                //         newData[e.name].push(e)
-                //     })
-                //     for (let key in newData) {
-                //         let obj = { name: '宸ュ崟鎶曟枡', gznum: newData[key].length, wlmc: key, wlnum: 0, num: 0 }
-                //         newData[key].forEach((item: any) => {
-                //             obj.wlnum = obj.wlnum + item.num
-                //             obj.num = item.num
-                //         })
-                //         obj.wlnum = obj.wlnum.toString() + newData[key][0].company as never
-                //         statisticsData.value.push(obj)
-                //     }
-                // }
-                // if (produceData.value.length > 0) {  // 浜у嚭
-                //     produceData.value.forEach((item: any) => {
-                //         cc = cc + item.num
-                //     })
-                //     statisticsData.value.push({ name: '宸ュ崟鍚堟牸浜у嚭', gznum: produceData.value.length, wlmc: info.value.mmodel.name, wlnum: cc + info.value.umodel.name, num: cc })
-                // }
-                // if (undesirable.value.length > 0 || scrap.value.length > 0) {  // 涓嶈壇/鎶ュ簾
-                //     undesirable.value.forEach((item: any) => {
-                //         bl = bl + item.num
-                //     })
-                //     scrap.value.forEach((item: any) => {
-                //         bl = bl + item.num
-                //     })
-                //     statisticsData.value.push({ name: '宸ュ崟涓嶈壇浜у嚭', gznum: undesirable.value.length + scrap.value.length, wlmc: info.value.mmodel.name, wlnum: bl + info.value.umodel.name, num: bl })
-                // }
-                // let totaltl: number = 0
-                // let totalcc: number = 0
-                // let totalbl: number = 0
-                // statisticsData.value.forEach((item: any) => {
-                //     if (item.name === '宸ュ崟鎶曟枡') {
-                //         totaltl = totaltl + item.num
-                //     } else if (item.name === '宸ュ崟鍚堟牸浜у嚭') {
-                //         totalcc = totalcc + item.num
-                //     } else if (item.name === '宸ュ崟涓嶈壇浜у嚭') {
-                //         totalbl = totalbl + item.num
-                //     }
-                // })
-                // isSubmit.value = totalcc + totalbl <= info.value.planNum;
-                let arr: any = []
-                let tl = 0
-                let res = getGroupNum(feedingData.value)
-                for (let i in res) {
-                    let num = 0
-                    res[i].forEach((item: any) => {
-                        num += item.num
-                    })
-                    arr.push({ name: '宸ュ崟鎶曟枡', materialName: i, num: num })
-                }
-                feedingData.value.forEach((item:any) => {
-                    tl += item.num
-                })
-                statisticsData.value = [...statisticsData.value, ...arr]
-                statisticsData.value.push({ name: '宸ュ崟鍚堟牸浜у嚭', materialName:  info.value.mmodel.name + '-' + info.value.procedureName, num: produceFrom.qualified })
-                statisticsData.value.push({ name: '宸ュ崟涓嶈壇浜у嚭', materialName:  info.value.mmodel.name + '-' + info.value.procedureName, num: produceFrom.undesirable })
-                isSubmit.value = produceFrom.qualified + produceFrom.undesirable <= info.value.planNum;
-            }
+        if (!from.processPlan) return Toast('璁″垝涓嶈兘涓虹┖')
+        if (!from.deviceId) return Toast('璁惧涓嶈兘涓虹┖')
+        if (!from.userId) return Toast('鐢熶骇浜哄憳涓嶈兘涓虹┖')
+        if (hasBom.value == 1 && bomType.value == 1) {
+            console.log('涓嶉渶瑕佹姇鏂�')
         } else {
-            console.log('鎺ㄥ紡')
-            if (feedingData.value.length === 0) {
-                Toast.fail({ message: '鎶曟枡鏄庣粏涓嶈兘涓虹┖' })
-                return
-            }
-            statisticsData.value = []
-            if (info.value.hasBom === 0) {
-                console.log('鏃燽om')
-                // let data: any = [
-                //     { name: '宸ュ崟鎶曟枡', gznum: feedingData.value.length, wlmc: feedingData.value.length > 0 ? feedingData.value[0].name : '', wlnum: 0 },
-                //     { name: '宸ュ崟鍚堟牸浜у嚭', gznum: produceData.value.length, wlmc: produceData.value.length > 0 ? produceData.value[0].name : '', wlnum: 0 },
-                //     { name: '宸ュ崟涓嶈壇浜у嚭', gznum: 0, wlmc: '', wlnum: 0 },
-                //     { name: '宸ュ崟鏈姇鏂�', gznum: '', wlmc: feedingData.value.length > 0 ? feedingData.value[0].name : '', wlnum: 0 }
-                // ]
-                // if (undesirable.value.length > 0) {   // 鍒ゆ柇鏈夋病鏈変笉鑹�
-                //     data[2].wlmc = undesirable.value[0].name
-                //     data[2].gznum = data[2].gznum + undesirable.value.length
-                // }
-                // if (scrap.value.length > 0) {   // 鍒ゆ柇鏈夋病鏈変笉鑹�
-                //     data[2].wlmc = scrap.value[0].name
-                //     data[2].gznum = data[2].gznum + scrap.value.length
-                // }
-                // let tl = 0
-                // let cc = 0
-                // let bl = 0
-                // undesirable.value.forEach((item: any) => {  // 涓嶈壇
-                //     bl = bl + item.num
-                // })
-                // scrap.value.forEach((item: any) => {  // 鎶ュ簾
-                //     bl = bl + item.num
-                // })
-                // if (produceData.value.length > 0) {   // 鍒ゆ柇鏈夋病鏈夊悎鏍间骇鍑�
-                //     produceData.value.forEach((item: any) => {  // 浜у嚭
-                //         cc = cc + item.num
-                //     })
-                // }
-                // feedingData.value.forEach((item: any) => {  // 鎶曟枡
-                //     tl = tl + item.num
-                // })
-                // data[0].wlnum = tl.toString() + info.value.umodel.name
-                // if (produceData.value.length > 0) {
-                //     data[1].wlnum = cc.toString() + info.value.umodel.name
-                // }
-                // data[2].wlnum = bl.toString() + info.value.umodel.name
-                // if (Number(tl) <= info.value.planNum) {
-                //     let total: number = Number(tl) - Number(cc) - Number(bl)  // 鏄惁鏈変綑
-                //     data[data.length - 1].wlnum = (Number(tl) - Number(cc) - Number(bl)).toString() + info.value.umodel.name
-                //     if (total === 0) {
-                //         isSubmit.value = true
-                //     } else {
-                //         isSubmit.value = false
-                //     }
-                // } else {
-                //     isSubmit.value = false
-                // }
-                // statisticsData.value = data
-                let arr: any = []
-                let tl = 0
-                let res = getGroupNum(feedingData.value)
-                for (let i in res) {
-                    let num = 0
-                    res[i].forEach((item: any) => {
-                        num += item.num
-                    })
-                    arr.push({ name: '宸ュ崟鎶曟枡', materialName: i + '-' + res[i][0].procedureName, num: num })
-                }
-                feedingData.value.forEach((item:any) => {
-                    tl += item.num
-                })
-                statisticsData.value = [...statisticsData.value, ...arr]
-                statisticsData.value.push({ name: '宸ュ崟鍚堟牸浜у嚭', materialName: info.value.mmodel.name + '-' + info.value.procedureName, num: produceFrom.qualified })
-                statisticsData.value.push({ name: '宸ュ崟涓嶈壇浜у嚭', materialName: info.value.mmodel.name + '-' + info.value.procedureName, num: produceFrom.undesirable })
-                if (Number(tl) <= info.value.planNum) {
-                    let total: number = Number(tl) - Number(produceFrom.qualified) - Number(produceFrom.undesirable)  // 鏄惁鏈変綑
-                    statisticsData.value.push({ name: '宸ュ崟鏈姇鏂�', materialName: '', num: (Number(tl) - Number(produceFrom.qualified) - Number(produceFrom.undesirable)).toFixed(2) })
-                    if (total === 0) {
-                        isSubmit.value = true
-                    } else {
-                        isSubmit.value = false
-                    }
-                } else {
-                    isSubmit.value = false
-                }
-            } else if (info.value.hasBom === 1) {  // 鏈塨om鎯呭喌
-                console.log('鏈塨om')
-                let arr: any = []
-                let tl = 0
-                let res = getGroupNum(feedingData.value)
-                for (let i in res) {
-                    let num = 0
-                    res[i].forEach((item: any) => {
-                        num += item.num
-                    })
-                    arr.push({ name: '宸ュ崟鎶曟枡', materialName: i, num: num })
-                }
-                feedingData.value.forEach((item:any) => {
-                    tl += item.num
-                })
-                statisticsData.value = [...statisticsData.value, ...arr]
-                statisticsData.value.push({ name: '宸ュ崟鍚堟牸浜у嚭', materialName: info.value.mmodel.name + '-' + info.value.procedureName, num: produceFrom.qualified })
-                statisticsData.value.push({ name: '宸ュ崟涓嶈壇浜у嚭', materialName: info.value.mmodel.name + '-' + info.value.procedureName, num: produceFrom.undesirable })
-                // isSubmit.value = produceFrom.qualified + produceFrom.undesirable <= info.value.planNum;
-                isSubmit.value = true
-            }
+            if (!wuList.value.length === 0) return Toast('鎶曟枡涓嶈兘涓虹┖')
         }
-        statistics.value = true
-    }
-
-    // 鏍规嵁鏌愪釜瀛楁杩涜鍒嗙粍
-    const getGroupNum = (arr: any) => {
-        let newArry: any = {};
-        for (let i = 0; i < arr.length; i++) {
-            if (newArry[arr[i].materialName]) {
-                newArry[arr[i].materialName].push(arr[i])
-            } else {
-                newArry[arr[i].materialName] = [arr[i]]
-            }
+        if (!from.qualified) return Toast('鑹搧鏁颁笉鑳戒负绌�')
+        // 鏈変笉鑹暟
+        if (from.undesirable > 0) {
+            if (from.defective.length === 0) return Toast('涓嶈壇椤逛笉鑳戒负绌�')
         }
-        return newArry;
-    }
-
-    // 杩斿洖淇敼
-    const gofh = () => {
-        statistics.value = false
-    }
-
-    // 纭鎶ュ伐
-    const submitBG = () => {
-        comfirmDoneStandard({
-            id: route.query.id
+        if (!from.duration) return Toast('鎶ュ伐鏃堕暱涓嶈兘涓虹┖')
+        autoWorkReport({
+            createWorkorderRecordDTO: {
+                duration: from.duration,
+                qualifiedNum: from.qualified,
+                unQualifiedNum: from.undesirable
+            },
+            plansId: from.processPlan.id,
+            proGroupId: deviceId.value,
+            proUserList: [from.userId],
+            recordList: wuList.value.map((item: any) => {
+                return {
+                    wstockId: item.id,
+                    num: item.num
+                }
+            }),
+            createUnqualifiedDTOList: from.defective.map((item: any) => {
+                return {
+                    categoryId: item.id,
+                    unQualifiedNum: item.num
+                }
+            })
         }).then(res => {
             if (res.code === 200) {
-                Toast.success({ message: '鎶ュ伐鎴愬姛', forbidClick: true, duration: 2000 })
+                Toast.success({message: '鎶ュ伐鎴愬姛锛�'})
                 setTimeout(() => {
-                    router.go(-2)
-                }, 2000)
+                    router.go(-1)
+                }, 2000);
             }
         })
+    }
+
+    // 棰勮宸ヨ祫
+    const expectedSalary = computed(() => {
+        if (!infoBox.value) return 0
+        // 鎸変欢璁$畻
+        if (infoBox.value.type == 0) {
+            console.log('璁′欢')
+            if (!from.qualified) return 0
+            if (infoBox.value.unqualified == 1) {   // 鏄惁璁″叆涓嶈壇鍝�
+                let total = Number(from.qualified) + Number(from.undesirable)
+                return total * infoBox.value.salary
+            } else {
+                return Number(from.qualified) * infoBox.value.salary
+            }
+        } else {
+            console.log('璁℃椂')
+            if (!from.duration) return 0;
+            let h = (from.duration / 60 / 60).toFixed(2)
+            return Number(h) * infoBox.value.salary
+        }
+    })
+
+    // 杈炬爣鐜�
+    const complianceRate = computed(() => {
+        if (!infoBox.value) return 0;
+        if (!from.qualified) return 0;
+        if (!from.duration) return 0;
+        // 鎸変欢璁$畻
+        // if (infoBox.value.type == 0) {
+            // if (infoBox.value.unqualified == 1) {   // 鏄惁璁″叆涓嶈壇鍝�
+                let a = ((Number(from.qualified) + Number(from.undesirable)) / (from.duration / 60 / 60)).toFixed(2)
+                let b = (infoBox.value.num / (infoBox.value.times / 60 / 60)).toFixed(2)
+                console.log(a)
+                console.log(b)
+                return (Number(a) / Number(b)).toFixed(2)
+                // let total = (Number(from.qualified) + Number(from.undesirable)) / ((from.duration * 60 * 60) * infoBox.value.num / )
+                // return total * infoBox.value.salary;
+            // } else {
+            //     return Number(from.qualified) * infoBox.value.salary;
+            // }
+        // } else {
+        //     console.log('鎸夋椂闀�')
+        // }
+    })
+
+    const deleItem = (index: number) => {
+        if (wuList.value.length === 1) return Toast('鑷冲皯淇濈暀涓�椤瑰唴瀹�')
+        wuList.value.splice(index, 1)
+    }
+    const openDev = () => {
+        if (!from.processPlan) return Toast('璇峰厛閫夋嫨宸ュ簭鐢熶骇璁″垝')
+        deviceShow.value = true
+    }
+    const openMaterial = () => {
+        if (!plansId.value) return Toast('璇峰厛閫夋嫨宸ュ簭鐢熶骇璁″垝')
+        if (!deviceId.value) return Toast('璇峰厛閫夋嫨鐢熶骇璁惧')
+        show1.value = true
+    }
+    const onConfirm1 = (e: any) => {
+        from.userId = e.userId
+        from.userName = e.name
+        userShow.value = false
+    }
+    const onConfirm2 = (e: string) => {
+        let h = Number(e.substring(0, 2))
+        let m = Number(e.substring(3, 5))
+        let s = 0
+        if (h > 0) {
+            s += h * 60 * 60
+        }
+        if (m > 0) {
+            s += m * 60
+        }
+        from.duration = s
+        from.durationName = `${h}灏忔椂${m}鍒嗛挓`
+        TimeShow.value = false
+    }
+    const onCancel1 = () => {
+        userShow.value = false
+    }
+    const onCancel2 = () => {
+        TimeShow.value = false
+    }
+    const onConfirm = (e: any) => {
+        from.deviceId = e.id
+        from.deviceName = e.name
+        deviceId.value = e.id
+        from.userId = ''
+        from.userName = ''
+        // getFindAll({
+        //     deviceId: e.id,
+        //     planId: from.processPlan.id
+        // }).then(res => {
+        //     if (res.code === 200) {
+        //         res.data.forEach((item: any) => {
+        //             item.name = item.umodel.name + '-' + item.tmodel.name
+        //         })
+        //         userList.value = res.data
+        //     }
+        // })
+        deviceShow.value = false
+    }
+    const onCancel = () => {
+        deviceShow.value = false
+    }
+
+    const selectPlan = () => {
+        router.push({ name: 'processPlans' })
+    }
+
+    const close = () => {
+        show1.value = false
+    }
+    const getData = () => {
+        categoryExtList({
+            cateType: "3"
+        }).then(res => {
+            if (res.code === 200) {
+                res.data.forEach((item: any) => {
+                    item.active = false
+                    item.num = ''
+                })
+                cateList.value = res.data
+            }
+        })
+    }
+    // 閫夋嫨鐗╂枡
+    const getValue = (val: any) => {
+        let obj = JSON.parse(JSON.stringify(val))
+        obj.total = val.num
+        wuList.value.unshift(obj)
+        let arr = wuList.value.map((item: any) => item.id)
+        ids.value = arr.join(',')
+        show1.value = false
     }
 
     onMounted(() => {
-        pageDJs()
-        queryByIds()
-        getOrocessRecords()
-        getOrocessRecordCC()
+        getData()
+        $Bus.on('callback', (res: any)=>{
+            from.processPlan = res
+            plansId.value = res.id
+            from.deviceId = ''
+            from.deviceName = ''
+            deviceId.value = ''
+            from.userId = ''
+            from.userName = ''
+            total.value = res.num - res.workorderDistributNum
+            // 鑾峰彇璁惧
+            getDeviceByCondition({ procedureId: res.procedureId })
+                .then(res1 => {
+                    if (res1.code === 200) {
+                        deviceId.value = res1.data[0].id
+                        from.deviceId = res1.data[0].id
+                        from.deviceName = res1.data[0].name
+                        deviceList.value = res1.data
+                    }
+                })
+            // 鑾峰彇绫诲瀷
+            getIdPlansExt(res.id)
+                .then(res2 => {
+                    if (res.code === 200) {
+                        bomType.value = res2.data.bomType
+                        hasBom.value = res2.data.hasBom
+                    }
+                })
+            // 鑾峰彇宸ヨ祫缁╂晥鏁版嵁
+            queryOne({
+                deleted: 0,
+                departId: res.factoryId,
+                materialId: res.materialId,
+                procedureId: res.procedureId
+            }).then(result => {
+                if (result.code === 200) {
+                    infoBox.value = result.data
+                }
+            })
+        })
     })
 </script>
 
 <style lang="scss" scoped>
     .bg {
         width: 100%;
-        /*height: 100%;*/
         position: absolute;
         background: #F7F7F7;
-        .details_cz {
+        .bg_plan {
             width: 100%;
+            // height: 98px;
             padding: 30px;
             box-sizing: border-box;
+            background: #FFFFFF;
+            margin-bottom: 40px;
             display: flex;
             align-items: center;
             justify-content: space-between;
-            .details_cz_sdtl {
-                width: 330px;
-                height: 76px;
-                background: #FFFFFF;
-                border-radius: 36px;
-                display: flex;
-                align-items: center;
-                justify-content: center;
-                img {
-                    width: 28px;
-                    height: 28px;
-                    margin-right: 14px;
-                }
-                span {
-                    font-size: 26px;
-                    font-weight: 400;
-                    color: #222222;
+            span {
+                font-size: 30px;
+                font-family: PingFangSC-Regular, PingFang SC;
+                font-weight: 400;
+                color: #222222;
+                b {
+                    color: red;
                 }
             }
-            .details_cz_smtl {
-                /*width: 330px;*/
-                flex: 1;
-                height: 76px;
-                background: $nav-color;
-                border-radius: 36px;
+            .bg_plan_nr {
+                display: flex;
+                flex-direction: column;
+                span {
+                    font-size: 24px;
+                    font-family: PingFangSC-Regular, PingFang SC;
+                    font-weight: 400;
+                    color: #666666;
+                    margin-top: 20px;
+                    &:first-child {
+                        font-size: 32px;
+                        font-family: PingFangSC-Medium, PingFang SC;
+                        font-weight: 500;
+                        color: #333333;
+                        margin-top: 0 !important;
+                    }
+                }
+            }
+            .bg_plan_label_val {
                 display: flex;
                 align-items: center;
-                justify-content: center;
-                img {
-                    width: 28px;
-                    height: 28px;
-                    margin-right: 14px;
-                }
                 span {
-                    font-size: 26px;
+                    font-size: 28px;
+                    font-family: PingFangSC-Regular, PingFang SC;
                     font-weight: 400;
-                    color: #ffffff;
+                    color: #999999;
+                }
+                img {
+                    width: 12px;
+                    height: 24px;
+                    margin-left: 20px;
                 }
             }
         }
@@ -1039,7 +626,9 @@
             width: 100%;
             display: flex;
             flex-direction: column;
-            margin-top: 30px;
+            .bottomval {
+                margin-bottom: 20px !important;
+            }
             .bg_list_item {
                 display: flex;
                 flex-direction: column;
@@ -1111,172 +700,165 @@
                         }
                     }
                 }
-                .bg_list_item_num {
+                .top {
+                    margin-top: 20px !important;
+                }
+                .bg_list_item_h {
                     width: 100%;
-                    background: white;
                     padding: 0 30px;
                     box-sizing: border-box;
-                    .kong {
-                        text-align: center;
-                        font-size: 25px;
-                        padding: 30px 0;
-                        background: #ffffff;
-                    }
-                    .bg_list_item_num_item {
+                    background: white;
+                    .bg_list_item_num {
+                        width: 100%;
+                        min-height: 98px;
+                        background: white;
                         display: flex;
+                        justify-content: center;
                         align-items: center;
-                        // height: 118px;
-                        padding: 15px 0;
-                        box-sizing: border-box;
-                        justify-content: space-between;
-                        border-bottom: 1px solid #E5E5E5;
+                        border-bottom: 1PX solid #E5E5E5;
                         &:last-child {
-                            border: none;
+                            border: none !important;
                         }
-                        .bg_list_item_num_item_wl {
-                            flex-shrink: 0;
+                        .kong {
+                            text-align: center;
+                            font-size: 25px;
+                            padding: 30px 0;
+                            background: #ffffff;
+                        }
+                        .bg_list_item_num_item {
+                            width: 100%;
+                            height: 100%;
                             display: flex;
-                            flex-direction: column;
-                            span {
-                                font-size: 34px;
-                                color: #222222;
+                            align-items: center;
+                            // height: 118px;
+                            padding: 15px 0;
+                            box-sizing: border-box;
+                            justify-content: space-between;
+                            border-bottom: 1px solid #E5E5E5;
+                            &:last-child {
+                                border: none;
                             }
-                            .bg_list_item_num_item_wl_lx {
-                                margin-top: 10px;
-                                span {
-                                    color: #222222;
-                                    font-size: 28px;
+                            .bg_list_item_num_item_list {
+                                display: flex;
+                                align-items: center;
+                                .active {
+                                    background: #305ED5 !important;
+                                    color: #FFFFFF !important;
+                                }
+                                .bg_list_item_num_item_list_item {
+                                    width: 116px;
+                                    height: 62px;
+                                    line-height: 62px;
+                                    text-align: center;
+                                    background: #F2F2F2;
+                                    border-radius: 8px;
+                                    font-size: 26px;
+                                    font-family: PingFangSC-Regular, PingFang SC;
+                                    font-weight: 400;
+                                    color: #333333;
+                                    margin-right: 20px;
+                                    &:last-child {
+                                        margin: 0 !important;
+                                    }
                                 }
                             }
-                        }
-                        .warning {
-                            color: $nav-stateColor5 !important;
-                        }
-                        .err {
-                            color: $nav-stateColor4 !important;
-                        }
-                        span {
-                            flex-shrink: 0;
-                            overflow: hidden;
-                            text-overflow: ellipsis;
-                            white-space: nowrap;
+                            .bg_list_item_num_item_wl {
+                                flex-shrink: 0;
+                                display: flex;
+                                flex-direction: column;
+                                span {
+                                    font-size: 34px;
+                                    color: #222222;
+                                }
+                                .bg_list_item_num_item_wl_lx {
+                                    margin-top: 10px;
+                                    span {
+                                        color: #222222;
+                                        font-size: 28px;
+                                    }
+                                }
+                            }
                             .warning {
                                 color: $nav-stateColor5 !important;
-                                margin-right: 5px;
                             }
                             .err {
                                 color: $nav-stateColor4 !important;
-                                margin-right: 5px;
                             }
-                            &:nth-child(1) {
-                                font-size: 30px;
-                                font-weight: 400;
-                                color: #222222;
-                            }
-                            &:nth-child(2) {
-                                font-size: 28px;
-                                font-weight: 400;
-                                color: #333333;
-                                flex-shrink: 0;
-                            }
-                        }
-                        .bg_list_item_num_item_sr {
-                            flex: 1;
-                            display: flex;
-                            align-items: center;
-                            justify-content: flex-end;
-                            input::-webkit-input-placeholder {
-                                font-size: 28px;
-                            }
-                            input {
-                                text-align: right;
-                                width: 180px;
-                                height: 60px;
-                                border-radius: 8px;
-                                border: 1PX solid #E5E5E5;
-                                margin-right: 20px;
-                                font-size: 28px;
-                                font-weight: 400;
-                                color: #333333;
-                                padding: 0 30px
+                            img {
+                                width: 12px;
+                                height: 24px;
+                                margin-left: 20px;
                             }
                             span {
-                                font-size: 28px;
-                                font-weight: 400;
-                                color: #666666;
+                                flex-shrink: 0;
+                                overflow: hidden;
+                                text-overflow: ellipsis;
+                                white-space: nowrap;
+                                b {
+                                    font-size: 30px;
+                                    color: red;
+                                    margin-right: 5px;
+                                }
+                                .warning {
+                                    color: $nav-stateColor5 !important;
+                                    margin-right: 5px;
+                                }
+                                .err {
+                                    color: $nav-stateColor4 !important;
+                                    margin-right: 5px;
+                                }
+                                &:nth-child(1) {
+                                    font-size: 30px;
+                                    font-weight: 400;
+                                    color: #222222;
+                                }
+                                &:nth-child(2) {
+                                    font-size: 28px;
+                                    font-weight: 400;
+                                    color: #333333;
+                                    flex-shrink: 0;
+                                }
                             }
-                        }
-                    }
-                }
-            }
-        }
-        .details_dj {
-            display: flex;
-            flex-direction: column;
-            .details_dj_title {
-                width: 100%;
-                display: flex;
-                align-items: center;
-                justify-content: space-between;
-                padding: 0 30px 30px 30px;
-                box-sizing: border-box;
-                .details_dj_title_left {
-                    display: flex;
-                    align-items: center;
-                    .details_x {
-                        width: 8px;
-                        height: 30px;
-                        background: $nav-color;
-                        border-radius: 2px;
-                        margin-right: 12px;
-                    }
-                    span {
-                        font-size: 32px;
-                        font-weight: 500;
-                        color: #222222;
-                    }
-                }
-                .details_dj_title_right {
-                    display: flex;
-                    align-items: center;
-                    img {
-                        width: 28px;
-                        height: 28px;
-                        margin-right: 12px;
-                    }
-                    span {
-                        font-size: 28px;
-                        font-weight: 400;
-                        color: $nav-color;
-                    }
-                }
-            }
-            .details_dj_list {
-                width: 100%;
-                /*padding: 30px;*/
-                box-sizing: border-box;
-                background: #ffffff;
-                display: flex;
-                flex-direction: column;
-                .details_dj_list_item {
-                    display: flex;
-                    flex-direction: column;
-                    border-bottom: 1px solid #E5E5E5;
-                    padding: 30px;
-                    /*margin: 30px;*/
-                    /*padding-bottom: 30px;*/
-                    /*margin-bottom: 30px !important;*/
-                    span {
-                        &:nth-child(1) {
-                            font-size: 28px;
-                            font-weight: 400;
-                            color: #222222;
-                        }
-                        &:nth-child(2) {
-                            font-size: 24px;
-                            font-weight: 400;
-                            color: #999999;
-                            margin-top: 24px;
+                            .bg_list_item_num_item_sr {
+                                flex: 1;
+                                display: flex;
+                                align-items: center;
+                                justify-content: flex-end;
+                                .color1 {
+                                    font-size: 28px;
+                                    font-family: PingFangSC-Regular, PingFang SC;
+                                    font-weight: 400;
+                                    color: #333333;
+                                }
+                                input::-webkit-input-placeholder {
+                                    font-size: 28px;
+                                }
+                                input {
+                                    text-align: right;
+                                    width: 180px;
+                                    height: 60px;
+                                    border-radius: 8px;
+                                    border: 1PX solid #E5E5E5;
+                                    margin-right: 20px;
+                                    font-size: 28px;
+                                    font-weight: 400;
+                                    color: #333333;
+                                    padding: 0 30px
+                                }
+                                .wulll {
+                                    width: 400px;
+                                    text-align: right;
+                                    overflow: hidden;
+                                    white-space: nowrap;
+                                    text-overflow: ellipsis;
+                                }
+                                span {
+                                    font-size: 28px;
+                                    font-family: PingFangSC-Regular, PingFang SC;
+                                    font-weight: 400;
+                                    color: #999999;
+                                }
+                            }
                         }
                     }
                 }
@@ -1290,10 +872,27 @@
             bottom: 0;
             left: 0;
             width: 100%;
+            z-index: 9;
             padding: 0 30px 60px 30px;
             box-sizing: border-box;
+            display: flex;
+            align-items: center;
+            justify-content: space-between;
+            .bg_footer_submit1 {
+                width: 334px;
+                height: 88px;
+                line-height: 88px;
+                text-align: center;
+                background: #FFFFFF;
+                box-shadow: 0px 0px 12px 0px rgba(0,0,0,0.08);
+                border-radius: 8px;
+                font-size: 30px;
+                font-family: PingFangSC-Medium, PingFang SC;
+                font-weight: 500;
+                color: #305ED5;
+            }
             .bg_footer_submit {
-                width: 690px;
+                width: 334px;
                 height: 88px;
                 background: $nav-color;
                 box-shadow: 0 0 12px 0 rgba(0, 0, 0, 0.08);
@@ -1304,108 +903,6 @@
                 display: flex;
                 align-items: center;
                 justify-content: center;
-            }
-        }
-        .tg {
-            width: 100%;
-            height: 100%;
-            padding: 30px;
-            box-sizing: border-box;
-            .tg_header {
-                width: 100%;
-                height: 45px;
-                text-align: center;
-                line-height: 45px;
-                font-size: 30px;
-                font-weight: 500;
-                color: #222222;
-            }
-            .tg_table {
-                width: 100%;
-                margin-top: 40px;
-                .tg_table_header {
-                    width: 100%;
-                    height: 72px;
-                    background: #EFF2FC;
-                    display: flex;
-                    align-items: center;
-                    .tg_table_header_item {
-                        flex: 1;
-                        font-size: 26px;
-                        font-weight: 500;
-                        color: #333333;
-                        display: flex;
-                        align-items: center;
-                        justify-content: center;
-                    }
-                }
-            }
-            .nr {
-                max-height: 400px;
-                overflow-x: scroll;
-                .tg_table_nr {
-                    width: 100%;
-                    padding: 24px 10px;
-                    box-sizing: border-box;
-                    display: flex;
-                    align-items: center;
-                    background: white;
-                    box-shadow: inset 0px -2px 0px 0px #E5E5E5;
-                    .tg_table_nr_item {
-                        flex: 1;
-                        font-size: 26px;
-                        font-weight: 500;
-                        color: #333333;
-                        display: flex;
-                        align-items: center;
-                        justify-content: center;
-                    }
-                    .tg_table_nr_item1 {
-                        flex: 1;
-                        font-size: 26px;
-                        font-weight: 500;
-                        color: #333333;
-                        display: flex;
-                        align-items: center;
-                        justify-content: center;
-                    }
-                }
-            }
-        }
-        .tg_footer {
-            width: calc(100% - 60px);
-            position: fixed;
-            bottom: 0;
-            display: flex;
-            justify-content: space-between;
-            align-items: center;
-            box-sizing: border-box;
-            padding-bottom: 40px;
-            .tg_footer_fh {
-                width: 100%;
-                height: 88px;
-                display: flex;
-                align-items: center;
-                justify-content: center;
-                background: rgba(66, 117, 252, 0.05);
-                border-radius: 8px;
-                border: 1PX solid #4275FC;
-                font-size: 32px;
-                font-weight: 500;
-                color: $nav-color;
-            }
-            .tg_footer_qr {
-                width: 100%;
-                height: 88px;
-                border: none;
-                display: flex;
-                align-items: center;
-                justify-content: center;
-                background: $nav-color;
-                border-radius: 8px;
-                font-size: 32px;
-                font-weight: 500;
-                color: #FFFFFF;
             }
         }
         .bl {
@@ -1425,21 +922,38 @@
                         font-size: 32px !important;
                     }
                 }
+                img {
+                    width: 28px;
+                    height: 28px;
+                }
+            }
+            .bl_footer {
+                width: 100%;
+                height: 88px;
+                line-height: 88px;
+                text-align: center;
+                background: #305ED5;
+                border-radius: 8px;
+                font-size: 32px;
+                font-family: PingFangSC-Medium, PingFang SC;
+                font-weight: 500;
+                color: #FFFFFF;
+                margin-top: 30px;
             }
             .bl_list {
                 width: 100%;
-                height: 580px;
+                height: 550px;
                 overflow-y: scroll;
                 margin-top: 30px;
                 .bl_list_item {
                     width: 100%;
-                    height: 60px;
+                    height: 96px;
                     display: flex;
                     align-items: center;
                     justify-content: space-between;
-                    margin-bottom: 20px;
+                    border-bottom: 1PX solid #E5E5E5;
                     &:last-child {
-                        margin-bottom: 0 !important;
+                        border: none !important;
                     }
                     .bl_list_item_left {
                         flex: 1;
@@ -1448,6 +962,7 @@
                         input {
                             width: 30px;
                             height: 30px;
+                            border: 1PX solid #CCCCCC;
                             margin: 0 !important;
                         }
                         span {
@@ -1464,9 +979,19 @@
                             padding-left: 5px;
                             width: 160px;
                             height: 100%;
+                            padding: 0 30px;
+                            box-sizing: border-box;
+                            text-align: right;
                             font-size: 28px;
+                            color: #333333;
                             border-radius: 10px;
-                            border: 2px solid #999999
+                            border: 1PX solid #CCCCCC;
+                            &::-webkit-input-placeholder {
+                                font-size: 28px;
+                                font-family: PingFangSC-Regular, PingFang SC;
+                                font-weight: 400;
+                                color: #999999;
+                            }
                         }
                     }
                 }
diff --git a/h5_standard/src/views/wxLogin.vue b/h5_standard/src/views/wxLogin.vue
index 87c9825..6ef2cc8 100644
--- a/h5_standard/src/views/wxLogin.vue
+++ b/h5_standard/src/views/wxLogin.vue
@@ -45,8 +45,8 @@
 })
 
 const login = async () => {
-    if (!from.openid) return Toast('openid涓嶈兘涓虹┖')
-    if (!from.unionid) return Toast('unionid涓嶈兘涓虹┖')
+    // if (!from.openid) return Toast('openid涓嶈兘涓虹┖')
+    // if (!from.unionid) return Toast('unionid涓嶈兘涓虹┖')
     if (!from.companyId) return Toast('浼佷笟浠g爜涓嶈兘涓虹┖')
     if (!from.username) return Toast('鎵嬫満鍙蜂笉鑳戒负绌�')
     if (!from.password) return Toast('瀵嗙爜涓嶈兘涓虹┖')
diff --git a/server/src/main/java/doumeemes/api/business/SalaryParamController.java b/server/src/main/java/doumeemes/api/business/SalaryParamController.java
index d405ec3..6c7e751 100644
--- a/server/src/main/java/doumeemes/api/business/SalaryParamController.java
+++ b/server/src/main/java/doumeemes/api/business/SalaryParamController.java
@@ -11,13 +11,21 @@
 import doumeemes.dao.ext.dto.SalaryParamDTO;
 import doumeemes.service.business.SalaryParamService;
 import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiImplicitParam;
+import io.swagger.annotations.ApiImplicitParams;
 import io.swagger.annotations.ApiOperation;
 import org.apache.shiro.authz.annotation.RequiresPermissions;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.web.bind.annotation.*;
+import org.springframework.web.multipart.MultipartFile;
+import org.springframework.web.multipart.MultipartHttpServletRequest;
+import org.springframework.web.multipart.commons.CommonsMultipartResolver;
+
+import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
 
 import java.util.ArrayList;
+import java.util.Iterator;
 import java.util.List;
 
 /**
@@ -89,4 +97,24 @@
     public ApiResponse findById(@PathVariable Integer id) {
         return ApiResponse.success(salaryParamService.findById(id));
     }
+
+    @ApiOperation(value = "鎵归噺瀵煎叆璁″垝", notes = "鎵归噺瀵煎叆璁″垝", httpMethod = "POST", position = 6)
+    @ApiImplicitParams({
+            @ApiImplicitParam(name = "folder", value = "鏂囦欢澶�", required = true, paramType = "query", dataType = "String", dataTypeClass = String.class),
+    })
+    @PostMapping(value = "/importBatch", headers = "content-type=multipart/form-data")
+//    @RequiresPermissions("business:salaryparam:create")
+    public ApiResponse importBatch(String folder, HttpServletRequest request, HttpServletResponse response) throws Exception {
+        CommonsMultipartResolver multipartResovler = new CommonsMultipartResolver();
+        if (multipartResovler.isMultipart(request)) {
+            MultipartHttpServletRequest multipartRequest = (MultipartHttpServletRequest) request;
+            Iterator<String> it = multipartRequest.getFileNames();
+            while (it.hasNext()) {
+                MultipartFile file = multipartRequest.getFile((String) it.next());
+                salaryParamService.importPlans(file);
+                break;
+            }
+        }
+        return ApiResponse.success( null);
+    }
 }
diff --git a/server/src/main/java/doumeemes/api/business/UnqualifiedRecordController.java b/server/src/main/java/doumeemes/api/business/UnqualifiedRecordController.java
new file mode 100644
index 0000000..5fd198e
--- /dev/null
+++ b/server/src/main/java/doumeemes/api/business/UnqualifiedRecordController.java
@@ -0,0 +1,71 @@
+package doumeemes.api.business;
+
+import doumeemes.api.BaseController;
+import doumeemes.core.annotation.excel.ExcelExporter;
+import doumeemes.core.annotation.pr.PreventRepeat;
+import doumeemes.core.model.ApiResponse;
+import doumeemes.core.model.PageWrap;
+import doumeemes.core.model.PageData;
+import doumeemes.dao.business.model.UnqualifiedRecord;
+import doumeemes.service.business.UnqualifiedRecordService;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.apache.shiro.authz.annotation.RequiresPermissions;    
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+import javax.servlet.http.HttpServletResponse;
+
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * @author 姹熻箘韫�
+ * @since 2023/08/16 14:15
+ */
+@Api(tags = "宸ュ崟绫�-鎶ュ伐涓嶈壇璁板綍绫诲瀷琛�")
+@RestController
+@RequestMapping("/business/unqualifiedRecord")
+public class UnqualifiedRecordController extends BaseController {
+
+    @Autowired
+    private UnqualifiedRecordService unqualifiedRecordService;
+
+    @PreventRepeat
+    @ApiOperation("鏂板缓")
+    @PostMapping("/create")
+    @RequiresPermissions("business:unqualifiedrecord:create")
+    public ApiResponse create(@RequestBody UnqualifiedRecord unqualifiedRecord) {
+        return ApiResponse.success(unqualifiedRecordService.create(unqualifiedRecord));
+    }
+
+    @ApiOperation("鏍规嵁ID鍒犻櫎")
+    @GetMapping("/delete/{id}")
+    @RequiresPermissions("business:unqualifiedrecord:delete")
+    public ApiResponse deleteById(@PathVariable Integer id) {
+        unqualifiedRecordService.deleteById(id);
+        return ApiResponse.success(null);
+    }
+
+
+    @ApiOperation("鏍规嵁ID淇敼")
+    @PostMapping("/updateById")
+    @RequiresPermissions("business:unqualifiedrecord:update")
+    public ApiResponse updateById(@RequestBody UnqualifiedRecord unqualifiedRecord) {
+        unqualifiedRecordService.updateById(unqualifiedRecord);
+        return ApiResponse.success(null);
+    }
+
+    @ApiOperation("鍒嗛〉鏌ヨ")
+    @PostMapping("/page")
+    @RequiresPermissions("business:unqualifiedrecord:query")
+    public ApiResponse<PageData<UnqualifiedRecord>> findPage (@RequestBody PageWrap<UnqualifiedRecord> pageWrap) {
+        return ApiResponse.success(unqualifiedRecordService.findPage(pageWrap));
+    }
+
+    @ApiOperation("鏍规嵁ID鏌ヨ")
+    @GetMapping("/{id}")
+    @RequiresPermissions("business:unqualifiedrecord:query")
+    public ApiResponse findById(@PathVariable Integer id) {
+        return ApiResponse.success(unqualifiedRecordService.findById(id));
+    }
+}
diff --git a/server/src/main/java/doumeemes/api/ext/CategoryExtController.java b/server/src/main/java/doumeemes/api/ext/CategoryExtController.java
index 48cbff8..ebb69c3 100644
--- a/server/src/main/java/doumeemes/api/ext/CategoryExtController.java
+++ b/server/src/main/java/doumeemes/api/ext/CategoryExtController.java
@@ -154,6 +154,15 @@
         return ApiResponse.success(categoryExtService.findPage(pageWrap));
     }
 
+    @ApiOperation("鍒楄〃鏌ヨ")
+    @PostMapping("/list")
+    @RequiresPermissions("ext:categoryext:query")
+    public ApiResponse<List<CategoryExtListVO>> list(@RequestBody QueryCategoryExtDTO queryCategoryExtDTO) {
+        queryCategoryExtDTO.setDeleted(Constants.ZERO);
+        queryCategoryExtDTO.setRootDepartId(getLoginUser().getRootDepartment().getId());
+        return ApiResponse.success(categoryExtService.findList(queryCategoryExtDTO));
+    }
+
     @ApiOperation("瀵煎嚭Excel")
     @PostMapping("/exportExcel")
     @RequiresPermissions("ext:categoryext:exportExcel")
diff --git a/server/src/main/java/doumeemes/api/ext/PlansExtController.java b/server/src/main/java/doumeemes/api/ext/PlansExtController.java
index 7741d95..27cc2d0 100644
--- a/server/src/main/java/doumeemes/api/ext/PlansExtController.java
+++ b/server/src/main/java/doumeemes/api/ext/PlansExtController.java
@@ -223,7 +223,6 @@
         return ApiResponse.success(plansExtService.pageCount(param));
     }
 
-
     @ApiOperation("涓�閿姤宸�")
     @PostMapping("/autoWorkReport")
     public ApiResponse autoWorkReport (@RequestBody AutoWorkReportDTO autoWorkReportDTO) {
diff --git a/server/src/main/java/doumeemes/api/ext/SalaryParamExtController.java b/server/src/main/java/doumeemes/api/ext/SalaryParamExtController.java
index 8d38ddf..4eec3eb 100644
--- a/server/src/main/java/doumeemes/api/ext/SalaryParamExtController.java
+++ b/server/src/main/java/doumeemes/api/ext/SalaryParamExtController.java
@@ -79,7 +79,7 @@
     @ApiOperation("鏍规嵁瀵硅薄淇℃伅鏌ヨ")
     @PostMapping("/queryOne")
     @RequiresPermissions("business:salaryparam:query")
-    public ApiResponse queryOne(@RequestBody SalaryParam salaryParam) {
+    public ApiResponse<SalaryParam> queryOne(@RequestBody SalaryParam salaryParam) {
         SalaryParam data = salaryParamService.findOne(salaryParam);
         return ApiResponse.success(data);
     }
diff --git a/server/src/main/java/doumeemes/config/shiro/ShiroRealm.java b/server/src/main/java/doumeemes/config/shiro/ShiroRealm.java
index 9b3e2f5..e130db9 100644
--- a/server/src/main/java/doumeemes/config/shiro/ShiroRealm.java
+++ b/server/src/main/java/doumeemes/config/shiro/ShiroRealm.java
@@ -37,6 +37,7 @@
 
 import java.util.Date;
 import java.util.List;
+import java.util.Objects;
 
 /**
  * 鑷畾涔塕ealm锛屽鐞嗚璇佸拰鏉冮檺
@@ -130,8 +131,10 @@
             if(com == null){
                 throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"瀵逛笉璧凤紝璇ヨ处鎴峰紓甯革紒");
             }
-
-            if(com.getOepnValidDate().before(new Date())){
+            if(Constants.equalsInteger( com.getStatus(),Constants.ZERO) ){
+                throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"瀵逛笉璧凤紝璇ヤ紒涓氬凡杩囩鐢紒");
+            }
+            if(com.getOepnValidDate() != null && com.getOepnValidDate().before(new Date())){
                 throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"瀵逛笉璧凤紝璇ヤ紒涓氬凡杩囦娇鐢ㄦ湁鏁堟湡锛�");
             }
             //濡傛灉鏄紒涓氱敤鎴�
diff --git a/server/src/main/java/doumeemes/core/utils/excel/EasyExcelUtil.java b/server/src/main/java/doumeemes/core/utils/excel/EasyExcelUtil.java
index 952b0cf..ffde846 100644
--- a/server/src/main/java/doumeemes/core/utils/excel/EasyExcelUtil.java
+++ b/server/src/main/java/doumeemes/core/utils/excel/EasyExcelUtil.java
@@ -87,6 +87,9 @@
     }
 
     /**
+     *
+     * titleRows : 鏍囬鍗犲嚑琛�
+     * headerRows : 鍚屽崰鍑犺
      * excel甯歌瀵煎叆(榛樿鍙鍙栫涓�寮爏heet宸ヤ綔绨�)
      */
     public static <T> List<T> importExcel(MultipartFile file, Integer titleRows, Integer headerRows, Class<T> pojoClass){
@@ -150,4 +153,4 @@
         }
         return list;
     }
-}
\ No newline at end of file
+}
diff --git a/server/src/main/java/doumeemes/dao/business/UnqualifiedRecordMapper.java b/server/src/main/java/doumeemes/dao/business/UnqualifiedRecordMapper.java
new file mode 100644
index 0000000..828d535
--- /dev/null
+++ b/server/src/main/java/doumeemes/dao/business/UnqualifiedRecordMapper.java
@@ -0,0 +1,12 @@
+package doumeemes.dao.business;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import doumeemes.dao.business.model.UnqualifiedRecord;
+
+/**
+ * @author 姹熻箘韫�
+ * @since 2023/08/16 14:15
+ */
+public interface UnqualifiedRecordMapper extends BaseMapper<UnqualifiedRecord> {
+
+}
diff --git a/server/src/main/java/doumeemes/dao/business/dto/AutoWorkReportDTO.java b/server/src/main/java/doumeemes/dao/business/dto/AutoWorkReportDTO.java
index f77d297..4026b98 100644
--- a/server/src/main/java/doumeemes/dao/business/dto/AutoWorkReportDTO.java
+++ b/server/src/main/java/doumeemes/dao/business/dto/AutoWorkReportDTO.java
@@ -33,4 +33,7 @@
     @ApiModelProperty(value = "浜у嚭璁板綍")
     private CreateWorkorderRecordDTO createWorkorderRecordDTO;
 
+    @ApiModelProperty(value = "涓嶈壇鍝佸垎绫昏褰�")
+    private List<CreateUnqualifiedDTO> createUnqualifiedDTOList ;
+
 }
diff --git a/server/src/main/java/doumeemes/dao/business/dto/CreateUnqualifiedDTO.java b/server/src/main/java/doumeemes/dao/business/dto/CreateUnqualifiedDTO.java
new file mode 100644
index 0000000..079b616
--- /dev/null
+++ b/server/src/main/java/doumeemes/dao/business/dto/CreateUnqualifiedDTO.java
@@ -0,0 +1,23 @@
+package doumeemes.dao.business.dto;
+
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+import java.math.BigDecimal;
+
+/**
+ * @author 姹熻箘韫�
+ * @date 2022/05/12 10:18
+ */
+@Data
+public class CreateUnqualifiedDTO {
+
+    @ApiModelProperty(value = "涓嶈壇绫诲埆涓婚敭"  )
+    private Integer categoryId;
+
+    @ApiModelProperty(value = "妫�楠屼笉鍚堟牸鏁伴噺")
+    private BigDecimal unQualifiedNum;
+
+
+
+}
diff --git a/server/src/main/java/doumeemes/dao/business/model/UnqualifiedRecord.java b/server/src/main/java/doumeemes/dao/business/model/UnqualifiedRecord.java
new file mode 100644
index 0000000..485712f
--- /dev/null
+++ b/server/src/main/java/doumeemes/dao/business/model/UnqualifiedRecord.java
@@ -0,0 +1,79 @@
+package doumeemes.dao.business.model;
+
+import doumeemes.core.annotation.excel.ExcelColumn;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import java.util.Date;
+import java.math.BigDecimal;
+
+/**
+ * 宸ュ崟绫�-鎶ュ伐涓嶈壇璁板綍绫诲瀷琛�
+ * @author 姹熻箘韫�
+ * @since 2023/08/16 14:15
+ */
+@Data
+@ApiModel("宸ュ崟绫�-鎶ュ伐涓嶈壇璁板綍绫诲瀷琛�")
+@TableName("`unqualified_record`")
+public class UnqualifiedRecord {
+
+    @TableId(type = IdType.AUTO)
+    @ApiModelProperty(value = "涓婚敭", example = "1")
+    @ExcelColumn(name="涓婚敭")
+    private Integer id;
+
+    @ApiModelProperty(value = "鏄惁宸插垹闄� 0鏈垹闄� 1宸插垹闄�", example = "1")
+    @ExcelColumn(name="鏄惁宸插垹闄� 0鏈垹闄� 1宸插垹闄�")
+    private Integer deleted;
+
+    @ApiModelProperty(value = "鍒涘缓浜虹紪鐮�", example = "1")
+    @ExcelColumn(name="鍒涘缓浜虹紪鐮�")
+    private Integer createUser;
+
+    @ApiModelProperty(value = "鍒涘缓鏃堕棿")
+    @ExcelColumn(name="鍒涘缓鏃堕棿")
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    private Date createTime;
+
+    @ApiModelProperty(value = "鏇存柊浜虹紪鐮�", example = "1")
+    @ExcelColumn(name="鏇存柊浜虹紪鐮�")
+    private Integer updateUser;
+
+    @ApiModelProperty(value = "鏇存柊鏃堕棿")
+    @ExcelColumn(name="鏇存柊鏃堕棿")
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    private Date updateTime;
+
+    @ApiModelProperty(value = "澶囨敞")
+    @ExcelColumn(name="澶囨敞")
+    private String remark;
+
+    @ApiModelProperty(value = "涓荤粍缁囩紪鐮侊紙鍏宠仈department琛ㄦ牴缁勭粐锛�", example = "1")
+    @ExcelColumn(name="涓荤粍缁囩紪鐮侊紙鍏宠仈department琛ㄦ牴缁勭粐锛�")
+    private Integer rootDepartId;
+
+    @ApiModelProperty(value = "鍏徃绾х粍缁囩紪鐮侊紙鍏宠仈department琛級", example = "1")
+    @ExcelColumn(name="鍏徃绾х粍缁囩紪鐮侊紙鍏宠仈department琛級")
+    private Integer departId;
+
+    @ApiModelProperty(value = "宸ュ崟涓婚敭", example = "1")
+    @ExcelColumn(name="宸ュ崟涓婚敭")
+    private Integer workorderId;
+
+    @ApiModelProperty(value = "浜у嚭璁板綍涓婚敭", example = "1")
+    @ExcelColumn(name="浜у嚭璁板綍涓婚敭")
+    private Integer recordId;
+
+    @ApiModelProperty(value = "绫诲埆涓婚敭", example = "1")
+    @ExcelColumn(name="绫诲埆涓婚敭")
+    private Integer categoryId;
+
+    @ApiModelProperty(value = "妫�楠屼笉鍚堟牸鏁伴噺", example = "1")
+    @ExcelColumn(name="妫�楠屼笉鍚堟牸鏁伴噺")
+    private BigDecimal unqualifiedNum;
+
+}
diff --git a/server/src/main/java/doumeemes/dao/business/vo/SalaryParamVO.java b/server/src/main/java/doumeemes/dao/business/vo/SalaryParamVO.java
index e3d3525..3f79317 100644
--- a/server/src/main/java/doumeemes/dao/business/vo/SalaryParamVO.java
+++ b/server/src/main/java/doumeemes/dao/business/vo/SalaryParamVO.java
@@ -14,14 +14,15 @@
 public class SalaryParamVO {
 
     @ApiModelProperty(value = "涓婚敭")
+    @ExcelColumn(name="搴忓彿",index = 1)
     private Integer id;
 
     @ApiModelProperty(value = "鍒涘缓浜虹紪鐮�")
-    @ExcelColumn(name="鍒涘缓浜虹紪鐮�")
+    @ExcelColumn(name="鍒涘缓浜虹紪鐮�",index = 11)
     private String createUserName;
 
     @ApiModelProperty(value = "鍒涘缓鏃堕棿")
-    @ExcelColumn(name="鍒涘缓鏃堕棿")
+    @ExcelColumn(name="鍒涘缓鏃堕棿",index = 10, dateFormat = "yyyy-MM-dd HH:mm:ss")
     private Date createTime;
 
     @ApiModelProperty(value = "涓荤粍缁囩紪鐮侊紙鍏宠仈department琛ㄦ牴缁勭粐锛�")
@@ -39,42 +40,42 @@
     private Integer procedureId;
 
     @ApiModelProperty(value = "宸ュ簭缂栫爜锛堝叧鑱攑rocedure琛級")
-    @ExcelColumn(name="宸ュ簭缂栫爜锛堝叧鑱攑rocedure琛級")
+//    @ExcelColumn(name="宸ュ簭缂栫爜锛堝叧鑱攑rocedure琛級")
     @NotEmpty(message = "宸ュ簭缂栫爜涓嶈兘涓虹┖")
     private Integer procedureCode;
 
     @ApiModelProperty(value = "宸ュ簭缂栫爜锛堝叧鑱攑rocedure琛級")
-    @ExcelColumn(name="宸ュ簭缂栫爜锛堝叧鑱攑rocedure琛級")
+    @ExcelColumn(name="宸ュ簭鍚嶇О",index =5)
     private String procedureName;
 
     @ApiModelProperty(value = "浜у搧鍚嶇О" )
-    @Excel(name="浜у搧鍚嶇О",orderNum ="3")
+    @ExcelColumn(name="鐗╂枡鍚嶇О",index =3)
     private String materialName;
 
     @ApiModelProperty(value = "浜у搧缂栫爜" )
-    @Excel(name="浜у搧缂栫爜",orderNum ="4")
+    @ExcelColumn(name="鐗╂枡缂栫爜",index =4)
     private String materialCode;
 
     @ApiModelProperty(value = "鐗╂枡缂栫爜锛堝叧鑱攎aterial_distribute琛級", example = "1")
     private Integer materialId;
 
     @ApiModelProperty(value = "宸ヨ祫鍗曚环锛堝厓)")
-    @ExcelColumn(name="宸ヨ祫鍗曚环锛堝厓)")
+    @ExcelColumn(name="宸ヨ祫鍗曚环锛堝厓)",index =6)
     private BigDecimal salary;
 
     @ApiModelProperty(value = "鏍囧噯鏁伴噺")
-    @ExcelColumn(name="鏍囧噯鏁伴噺")
+    @ExcelColumn(name="鏍囧噯浜у嚭",index =7)
     private Integer num;
 
     @ApiModelProperty(value = "鏍囧噯鏃堕暱锛堢锛�")
-    @ExcelColumn(name="鏍囧噯鏃堕暱锛堢锛�")
+    @ExcelColumn(name="鏍囧噯鏃堕暱锛堢锛�",index =8)
     private String times;
 
     @ApiModelProperty(value = "涓嶈壇鍝佹槸鍚﹁鍏� 0鍚� 1鏄�")
-    @ExcelColumn(name="涓嶈壇鍝佹槸鍚﹁鍏� 0鍚� 1鏄�")
+    @ExcelColumn(name="涓嶈壇鍝佹槸鍚﹁鍏� 0鍚� 1鏄�",index = 9 ,valueMapping = "0=鍚�;1=鏄�")
     private Integer unqualified;
 
     @ApiModelProperty(value = "璁′环鏂瑰紡 0璁′欢 1璁℃椂")
-    @ExcelColumn(name="璁′环鏂瑰紡 0璁′欢 1璁℃椂")
+    @ExcelColumn(name="璁′环鏂瑰紡",index = 2 ,valueMapping = "0=璁′欢;1=璁℃椂")
     private Integer type;
 }
diff --git a/server/src/main/java/doumeemes/dao/business/vo/WorkPlansVO.java b/server/src/main/java/doumeemes/dao/business/vo/WorkPlansVO.java
index 3b72cd2..b9107ac 100644
--- a/server/src/main/java/doumeemes/dao/business/vo/WorkPlansVO.java
+++ b/server/src/main/java/doumeemes/dao/business/vo/WorkPlansVO.java
@@ -57,7 +57,7 @@
     private Integer factoryId;
 
     @ApiModelProperty(value = "宸ュ巶鍚嶇О", example = "1")
-    @ExcelColumn(name="宸ュ巶鍚嶇О",index = 4,width =15)
+    @ExcelColumn(name="宸ュ巶鍚嶇О",index = 5,width =15)
     private String factoryName;
 
     @ApiModelProperty(value = "鏉ユ簮 0浜哄伐鍒涘缓銆�1Excel瀵煎叆", example = "1")
@@ -67,12 +67,12 @@
     @ExcelColumn(name="璁″垝缂栫爜",index = 0,width =15)
     private String planCode;
 
-    @ApiModelProperty(value = "璁″垝鏃ユ湡")
-    @ExcelColumn(name="璁″垝鏃ユ湡",index = 3,width =15)
+    @ApiModelProperty(value = "璁″垝瀹屾垚鏃ユ湡")
+    @ExcelColumn(name="璁″垝鏃ユ湡",index = 4,width =15)
     @JsonFormat(pattern = "yyyy-MM-dd")
     private Date planDate;
     @ApiModelProperty(value = "璁″垝寮�濮嬫棩鏈�")
-    @ExcelColumn(name="璁″垝寮�濮嬫棩鏈�",index = 17,width =15)
+    @ExcelColumn(name="璁″垝寮�濮嬫棩鏈�",index = 3,width =15)
     @JsonFormat(pattern = "yyyy-MM-dd")
     private Date startDate;
     @ApiModelProperty(value = "閿�鍞崟鍙�" )
@@ -94,26 +94,26 @@
     private Integer unitId;
 
     @ApiModelProperty(value = "鍗曚綅缂栫爜鍚嶇О", example = "1")
-    @ExcelColumn(name="鍗曚綅鍚嶇О",index = 6,width =15)
+    @ExcelColumn(name="鍗曚綅鍚嶇О",index = 7,width =15)
     private String unitName;
 
     @ApiModelProperty(value = "璁″垝鏁伴噺", example = "1")
-    @ExcelColumn(name="璁″垝鏁伴噺",index = 5,width =15)
+    @ExcelColumn(name="璁″垝鏁伴噺",index = 6,width =15)
     private Integer num;
 
     @ApiModelProperty(value = "鎵规鍙�")
-    @ExcelColumn(name="鎵规鍙�",index = 7,width =15)
+    @ExcelColumn(name="鎵规鍙�",index = 8,width =15)
     private String batch;
 
     @ApiModelProperty(value = "鐘舵�� 1=宸茬敓鎴�;2=宸插彂甯冦��3宸插彇娑堛��4宸插垎閰嶃��5宸叉殏鍋溿��6宸插畬宸ャ��7宸插叆搴撱��8宸插叧闂�", example = "1")
-    @ExcelColumn(name="璁″垝鐘舵��",valueMapping = "0=宸茬敓鎴�;1=鎵ц涓�;3=宸插彇娑�;4=宸插垎閰�;5=宸叉殏鍋�;6=宸插畬宸�;7=宸插叆搴�;8=宸插叧闂�;",index = 8,width =15)
+    @ExcelColumn(name="璁″垝鐘舵��",valueMapping = "0=宸茬敓鎴�;1=鎵ц涓�;3=宸插彇娑�;4=宸插垎閰�;5=宸叉殏鍋�;6=宸插畬宸�;7=宸插叆搴�;8=宸插叧闂�;",index = 9,width =15)
     private Integer status;
 
     @ApiModelProperty(value = "瀵煎叆鎵瑰彿锛堝叧鑱攑lan_import琛�)", example = "1")
     private Integer importId;
 
     @ApiModelProperty(value = "鏄惁鏆傚仠 0鏈殏鍋� 1宸叉殏鍋�", example = "1")
-    @ExcelColumn(name="鏄惁鏆傚仠",valueMapping = "0=鍚�;1=鏄�",index = 9,width =15)
+    @ExcelColumn(name="鏄惁鏆傚仠",valueMapping = "0=鍚�;1=鏄�",index = 10,width =15)
     private Integer paused;
 
     @ApiModelProperty(value = "璁″垝鍛樼紪鐮侊紙涓巗ystem_user琛ㄥ叧鑱旓級", example = "1")
@@ -123,31 +123,31 @@
     private Integer urgent;
 
     @ApiModelProperty(value = "璁″垝鍛樺鍚�", example = "1")
-    @ExcelColumn(name="璁″垝鍛樺鍚�",index = 14,width =15)
+    @ExcelColumn(name="璁″垝鍛樺鍚�",index = 15,width =15)
     private String userName;
 
     @ApiModelProperty(value = "璁″垝鍛樻墜鏈哄彿", example = "1")
-    @ExcelColumn(name="璁″垝鍛樻墜鏈哄彿",index = 15,width =15)
+    @ExcelColumn(name="璁″垝鍛樻墜鏈哄彿",index = 16,width =15)
     private String userMobile;
 
     @ApiModelProperty(value = "璁″垝鍙戝竷鏃堕棿")
     @JsonFormat(pattern = "yyyy-MM-dd")
-    @ExcelColumn(name="璁″垝鍙戝竷鏃堕棿",index = 13,width =15)
+    @ExcelColumn(name="璁″垝鍙戝竷鏃堕棿",index = 14,width =15)
     private Date publishDate;
 
     @ApiModelProperty(value = "鐢ㄦ埛閮ㄩ棬鍚嶇О", example = "1")
     private String userDepartName;
 
     @ApiModelProperty(value = "瀹屽伐鏁伴噺", example = "1")
-    @ExcelColumn(name="瀹屽伐鏁伴噺" ,index = 10,width =15)
+    @ExcelColumn(name="瀹屽伐鏁伴噺" ,index = 11,width =15)
     private Integer finishNum;
 
     @ApiModelProperty(value = "瀹屽伐鍚堟牸鏁伴噺", example = "1")
-    @ExcelColumn(name="瀹屽伐鍚堟牸鏁伴噺",index = 11,width =15)
+    @ExcelColumn(name="瀹屽伐鍚堟牸鏁伴噺",index = 12,width =15)
     private Integer finishQualifiedNum;
 
     @ApiModelProperty(value = "瀹屽伐涓嶈壇鏁伴噺", example = "1")
-    @ExcelColumn(name="瀹屽伐涓嶈壇鏁伴噺",index = 12,width =15)
+    @ExcelColumn(name="瀹屽伐涓嶈壇鏁伴噺",index = 13,width =15)
     private Integer finishUnQualifiedNum;
 
     @ApiModelProperty(value = "瀛愯鍒掓槑缁嗕俊鎭�", example = "1")
diff --git a/server/src/main/java/doumeemes/dao/ext/dto/QueryPlansExtDTO.java b/server/src/main/java/doumeemes/dao/ext/dto/QueryPlansExtDTO.java
index 65687e6..7a2e907 100644
--- a/server/src/main/java/doumeemes/dao/ext/dto/QueryPlansExtDTO.java
+++ b/server/src/main/java/doumeemes/dao/ext/dto/QueryPlansExtDTO.java
@@ -441,8 +441,8 @@
     private String mixParam;
     @ApiModelProperty(value = "寮�濮嬫椂闂�")
     @JsonFormat(pattern = "yyyy-MM-dd")
-    private Date startDate;
+    private String planDateStartDate;
     @ApiModelProperty(value = "鎴鏃堕棿")
     @JsonFormat(pattern = "yyyy-MM-dd")
-    private Date endDate;
+    private String planDateEndDate;
 }
diff --git a/server/src/main/java/doumeemes/dao/ext/dto/QueryUserSalaryListDTO.java b/server/src/main/java/doumeemes/dao/ext/dto/QueryUserSalaryListDTO.java
index 049cf7d..7551472 100644
--- a/server/src/main/java/doumeemes/dao/ext/dto/QueryUserSalaryListDTO.java
+++ b/server/src/main/java/doumeemes/dao/ext/dto/QueryUserSalaryListDTO.java
@@ -28,10 +28,10 @@
     private Integer rootDepartId;
     @ApiModelProperty(value = "寮�濮嬫椂闂�")
     @JsonFormat(pattern = "yyyy-MM-dd")
-    private Date startDate;
+    private String startDate;
     @ApiModelProperty(value = "缁撴潫鏃堕棿")
     @JsonFormat(pattern = "yyyy-MM-dd")
-    private Date endDate;
+    private String endDate;
     @ApiModelProperty(value = "鏁版嵁鏉冮檺閮ㄩ棬缂栫爜闆嗗悎" ,hidden = true)
     private List<Integer> departIds;
 
diff --git a/server/src/main/java/doumeemes/dao/ext/dto/SalaryParamImportDTO.java b/server/src/main/java/doumeemes/dao/ext/dto/SalaryParamImportDTO.java
index 59044f2..851d29e 100644
--- a/server/src/main/java/doumeemes/dao/ext/dto/SalaryParamImportDTO.java
+++ b/server/src/main/java/doumeemes/dao/ext/dto/SalaryParamImportDTO.java
@@ -1,6 +1,7 @@
 package doumeemes.dao.ext.dto;
 
 import cn.afterturn.easypoi.excel.annotation.Excel;
+import cn.afterturn.easypoi.excel.annotation.ExcelTarget;
 import io.swagger.annotations.ApiModel;
 import lombok.Data;
 
@@ -12,6 +13,7 @@
  */
 @Data
 @ApiModel("缁╂晥宸ヨ祫閰嶇疆瀵煎叆")
+@ExcelTarget("SalaryParamImportDTO")
 public class SalaryParamImportDTO {
 
     @Excel(name="璁′环鏂瑰紡",orderNum ="1")
@@ -20,10 +22,10 @@
     @Excel(name="宸ュ巶鍚嶇О",orderNum ="2")
     private String departName;
 
-    @Excel(name="浜у搧鍚嶇О",orderNum ="3")
+    @Excel(name="鐗╂枡鍚嶇О",orderNum ="3")
     private String materialName;
 
-    @Excel(name="浜у搧缂栫爜",orderNum ="4")
+    @Excel(name="鐗╂枡缂栫爜",orderNum ="4")
     private String materialCode;
 
     @Excel(name="宸ュ簭鍚嶇О",orderNum ="5")
@@ -33,7 +35,7 @@
     private BigDecimal salary;
 
     @Excel(name="鏍囧噯浜у嚭",orderNum ="7")
-    private Integer NUM;
+    private String num;
 
     @Excel(name="鏍囧噯宸ユ椂",orderNum ="8")
     private String timesName;
diff --git a/server/src/main/java/doumeemes/dao/ext/vo/BomExtListVO.java b/server/src/main/java/doumeemes/dao/ext/vo/BomExtListVO.java
index 830af01..174a563 100644
--- a/server/src/main/java/doumeemes/dao/ext/vo/BomExtListVO.java
+++ b/server/src/main/java/doumeemes/dao/ext/vo/BomExtListVO.java
@@ -60,8 +60,8 @@
     @ExcelColumn(name="鍏徃绾х粍缁囩紪鐮侊紙鍏宠仈department琛級")
     private Integer departId;
 
-    @ApiModelProperty(value = "鐗╂枡ID锛堝叧鑱攎aterial琛級", example = "1")
-    @ExcelColumn(name="鐗╂枡ID锛堝叧鑱攎aterial琛級")
+    @ApiModelProperty(value = "鐗╂枡ID锛堣瀛楁鍏宠仈 material_distribute 琛↖D 锛侊紒锛侊紒 锛�", example = "1")
+    @ExcelColumn(name="鐗╂枡ID锛堝叧鑱攎aterial_distribute琛級")
     private Integer materialId;
 
     @ApiModelProperty(value = "鐗堟湰鍙�")
@@ -157,5 +157,6 @@
     @ApiModelProperty(value = "宸ュ簭鍚嶇О")
     private String procedureName;
 
-
+    @ApiModelProperty(value = "material id")
+    private Integer realMaterialId;
 }
diff --git a/server/src/main/java/doumeemes/dao/ext/vo/CompanyExtListVO.java b/server/src/main/java/doumeemes/dao/ext/vo/CompanyExtListVO.java
index 7df00ab..f58062f 100644
--- a/server/src/main/java/doumeemes/dao/ext/vo/CompanyExtListVO.java
+++ b/server/src/main/java/doumeemes/dao/ext/vo/CompanyExtListVO.java
@@ -165,4 +165,7 @@
     @ApiModelProperty(value = "缇氱緤骞冲彴搴旂敤鍙傛暟锛宩son鏍煎紡瀛樺偍{app_key:,aes_key:,app_secret:}" )
     private String lingyangInfo;
 
+    @ApiModelProperty(value = "鐘舵�� 1 寮�鍚� 0 绂佺敤")
+    private Integer status;
+
 }
diff --git a/server/src/main/java/doumeemes/dao/ext/vo/PlansExtListVO.java b/server/src/main/java/doumeemes/dao/ext/vo/PlansExtListVO.java
index 43c59ef..697f643 100644
--- a/server/src/main/java/doumeemes/dao/ext/vo/PlansExtListVO.java
+++ b/server/src/main/java/doumeemes/dao/ext/vo/PlansExtListVO.java
@@ -71,7 +71,7 @@
     private Integer lessDistributNum;
 
     @ApiModelProperty(value = "璁″垝绫诲瀷 0姝e父1寮傚父2杩斿伐", example = "1")
-    @ExcelColumn(name="璁″垝绫诲瀷",valueMapping = "0=姝e父;1=寮傚父;2=杩斿伐;",index = 11,width =15)
+    @ExcelColumn(name="璁″垝绫诲瀷",valueMapping = "0=姝e父;1=寮傚父;2=杩斿伐;",index = 12,width =15)
     private Integer type;
 
     @ApiModelProperty(value = "鐢熶骇宸ュ簭缂栫爜锛堝叧鑱攑rocedures琛級", example = "1")
@@ -84,15 +84,15 @@
     private Integer unitId;
 
     @ApiModelProperty(value = "璁″垝鏁伴噺", example = "1")
-    @ExcelColumn(name="璁″垝鏁伴噺",index = 6,width =15)
+    @ExcelColumn(name="璁″垝鏁伴噺",index = 7,width =15)
     private Integer num;
 
     @ApiModelProperty(value = "鎵规鍙�")
-    @ExcelColumn(name="鐢熶骇鎵规鍙�",index = 8,width =15)
+    @ExcelColumn(name="鐢熶骇鎵规鍙�",index = 9,width =15)
     private String batch;
 
     @ApiModelProperty(value = "浼樺厛绾э紙鎺掑簭鐮侊級瀛楁", example = "1")
-    @ExcelColumn(name="浼樺厛绾�",index = 9,width =15)
+    @ExcelColumn(name="浼樺厛绾�",index = 10,width =15)
     private Integer urgent;
 
     @ApiModelProperty(value = "瀵煎叆鎵瑰彿锛堝叧鑱攑lan_import琛�)", example = "1")
@@ -102,14 +102,14 @@
     private Integer userId;
 
     @ApiModelProperty(value = "鐘舵�� 0宸茬敓鎴愩��1宸插彂甯冦��2宸叉挙鍥炪��3宸插彇娑堛��4宸插垎閰嶃��5宸叉殏鍋溿��6宸插畬宸ャ��7宸插叆搴撱��8宸插叧闂�", example = "1")
-    @ExcelColumn(name="璁″垝鐘舵��",valueMapping = "0=宸茬敓鎴�;1=宸插彂甯�;2=宸叉挙鍥�;3=宸插彇娑�;4=宸插垎閰�;5=宸叉殏鍋�;6=宸插畬宸�;7=宸插叆搴�;8=宸插叧闂�;",index = 10,width =15)
+    @ExcelColumn(name="璁″垝鐘舵��",valueMapping = "0=宸茬敓鎴�;1=宸插彂甯�;2=宸叉挙鍥�;3=宸插彇娑�;4=宸插垎閰�;5=宸叉殏鍋�;6=宸插畬宸�;7=宸插叆搴�;8=宸插叧闂�;",index = 11,width =15)
     private Integer status;
 
     @ApiModelProperty(value = "杩斾慨鐢宠鍗曞彿锛堝叧鑱攂ackorder琛級", example = "1")
     private Integer backorderId;
 
     @ApiModelProperty(value = "璁″垝鍙戝竷鏃堕棿")
-    @ExcelColumn(name="鍙戝竷鏃ユ湡",index = 15,width =15)
+    @ExcelColumn(name="鍙戝竷鏃ユ湡",index = 16,width =15)
     @JsonFormat(pattern = "yyyy-MM-dd")
     private Date publishDate;
 
@@ -133,20 +133,29 @@
     @ApiModelProperty(value = "宸插畬宸ユ暟閲�", example = "0")
     private Integer  doneNum;
     @ApiModelProperty(value = "鍚堟牸鏁伴噺", example = "0")
-    @ExcelColumn(name="鍚堟牸鏁伴噺",index = 13,width =15)
+    @ExcelColumn(name="鍚堟牸鏁伴噺",index = 14,width =15)
     private Integer  qulifiedNum;
     @ApiModelProperty(value = "涓嶈壇鏁伴噺", example = "0")
-    @ExcelColumn(name="涓嶈壇鏁伴噺",index = 14,width =15)
+    @ExcelColumn(name="涓嶈壇鏁伴噺",index = 15,width =15)
     private Integer  unqulifiedNum;
     @ApiModelProperty(value = "宸插垎閰嶇敓浜ф暟閲�", example = "1",hidden = true)
     private Integer distributNum;
     @ApiModelProperty(value = "宸ュ崟宸插垎閰嶇敓浜ф暟閲�", example = "1",hidden = true)
     private Integer workorderDistributNum;
     @ApiModelProperty(value = "宸插垎閰嶆湭瀹屽伐鐢熶骇鏁伴噺", example = "1",hidden = true)
-    @ExcelColumn(name="宸插垎閰嶆湭瀹屽伐鐢熶骇鏁伴噺",index = 12,width =15)
+    @ExcelColumn(name="宸插垎閰嶆湭瀹屽伐鐢熶骇鏁伴噺",index = 13,width =15)
     private Integer distributNoDoneNum;
     @ApiModelProperty(value = "搴撳瓨鏄惁婊¤冻 0涓嶆弧瓒� 1婊¤冻", example = "0")
     private Integer  isStock;
+    @ApiModelProperty(value = "鏄惁寤舵湡")
+    private Boolean hasExpire;
+    @ApiModelProperty(value = "鎴愬搧璁″垝寮�濮嬫棩鏈�")
+    @ExcelColumn(name="璁″垝鏃ユ湡",index = 4,width =15)
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    private  Date workPlanPlanDate;
+    @ApiModelProperty(value = "鎴愬搧璁″垝寮�濮嬫棩鏈�")
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    private  Date workPlanStartDate;
 
 
     @ExcelColumn(name="鐗╂枡鍚嶇О",index = 1,width =15)
@@ -155,16 +164,16 @@
     @ExcelColumn(name="鐗╂枡缂栫爜",index = 2,width =15)
     private String materialCode;
 
-    @ExcelColumn(name="宸ュ巶",index = 4,width =15)
+    @ExcelColumn(name="宸ュ巶",index = 5,width =15)
     private String factoryName;
 
-    @ExcelColumn(name="宸ュ簭",index = 5,width =15)
+    @ExcelColumn(name="宸ュ簭",index = 6,width =15)
     private String produceName;
 
-    @ExcelColumn(name="璁″垝鍛�",index = 16,width =15)
+    @ExcelColumn(name="璁″垝鍛�",index = 17,width =15)
     private String planUserName;
 
-    @ExcelColumn(name="鍗曚綅鍚嶇О",index = 7,width =15)
+    @ExcelColumn(name="鍗曚綅鍚嶇О",index = 8,width =15)
     private String unitName;
 
     @ExcelColumn(name="鎴愬搧璁″垝缂栫爜")
@@ -173,14 +182,16 @@
     @ExcelColumn(name="閿�鍞鍗�")
     private String salesOrder;
 
-    @ApiModelProperty(value = "鎴愬搧璁″垝寮�濮嬫椂闂�")
-    @JsonFormat(pattern = "yyyy-MM-dd")
-    private Date workPlanStartDate;
-
     @ApiModelProperty(value = "鎴愬搧璁″垝缁撴潫鏃堕棿")
     @JsonFormat(pattern = "yyyy-MM-dd")
     private Date workPlanEndDate;
 
     @ApiModelProperty(value = "宸茬敓浜ф暟閲�")
     private Integer produceNum;
+
+    @ApiModelProperty(value = "鏄惁鏈塨om閰嶇疆 0鏃� 1鏈�", example = "1")
+    private Integer hasBom;
+    @ApiModelProperty(value = "bom鎶曟枡鏂瑰紡 0鎺ㄥ紡 1鎷夊紡", example = "1")
+    private Integer bomType;
+
 }
diff --git a/server/src/main/java/doumeemes/service/business/UnqualifiedRecordService.java b/server/src/main/java/doumeemes/service/business/UnqualifiedRecordService.java
new file mode 100644
index 0000000..0024bb7
--- /dev/null
+++ b/server/src/main/java/doumeemes/service/business/UnqualifiedRecordService.java
@@ -0,0 +1,97 @@
+package doumeemes.service.business;
+
+import doumeemes.core.model.PageData;
+import doumeemes.core.model.PageWrap;
+import doumeemes.dao.business.model.UnqualifiedRecord;
+import java.util.List;
+
+/**
+ * 宸ュ崟绫�-鎶ュ伐涓嶈壇璁板綍绫诲瀷琛⊿ervice瀹氫箟
+ * @author 姹熻箘韫�
+ * @since 2023/08/16 14:15
+ */
+public interface UnqualifiedRecordService {
+
+    /**
+     * 鍒涘缓
+     * 
+     * @param unqualifiedRecord 瀹炰綋瀵硅薄
+     * @return Integer
+     */
+    Integer create(UnqualifiedRecord unqualifiedRecord);
+
+    /**
+     * 涓婚敭鍒犻櫎
+     *
+     * @param id 涓婚敭
+     */
+    void deleteById(Integer id);
+
+    /**
+     * 鍒犻櫎
+     *
+     * @param unqualifiedRecord 瀹炰綋瀵硅薄
+     */
+    void delete(UnqualifiedRecord unqualifiedRecord);
+
+    /**
+     * 鎵归噺涓婚敭鍒犻櫎
+     *
+     * @param ids 涓婚敭闆�
+     */
+    void deleteByIdInBatch(List<Integer> ids);
+
+    /**
+     * 涓婚敭鏇存柊
+     *
+     * @param unqualifiedRecord 瀹炰綋瀵硅薄
+     */
+    void updateById(UnqualifiedRecord unqualifiedRecord);
+
+    /**
+     * 鎵归噺涓婚敭鏇存柊
+     *
+     * @param unqualifiedRecords 瀹炰綋闆�
+     */
+    void updateByIdInBatch(List<UnqualifiedRecord> unqualifiedRecords);
+
+    /**
+     * 涓婚敭鏌ヨ
+     *
+     * @param id 涓婚敭
+     * @return UnqualifiedRecord
+     */
+    UnqualifiedRecord findById(Integer id);
+
+    /**
+     * 鏉′欢鏌ヨ鍗曟潯璁板綍
+     *
+     * @param unqualifiedRecord 瀹炰綋瀵硅薄
+     * @return UnqualifiedRecord
+     */
+    UnqualifiedRecord findOne(UnqualifiedRecord unqualifiedRecord);
+
+    /**
+     * 鏉′欢鏌ヨ
+     *
+     * @param unqualifiedRecord 瀹炰綋瀵硅薄
+     * @return List<UnqualifiedRecord>
+     */
+    List<UnqualifiedRecord> findList(UnqualifiedRecord unqualifiedRecord);
+  
+    /**
+     * 鍒嗛〉鏌ヨ
+     *
+     * @param pageWrap 鍒嗛〉瀵硅薄
+     * @return PageData<UnqualifiedRecord>
+     */
+    PageData<UnqualifiedRecord> findPage(PageWrap<UnqualifiedRecord> pageWrap);
+
+    /**
+     * 鏉′欢缁熻
+     *
+     * @param unqualifiedRecord 瀹炰綋瀵硅薄
+     * @return long
+     */
+    long count(UnqualifiedRecord unqualifiedRecord);
+}
diff --git a/server/src/main/java/doumeemes/service/business/impl/CompanyOpenServiceImpl.java b/server/src/main/java/doumeemes/service/business/impl/CompanyOpenServiceImpl.java
index ab6ebbd..0dd3049 100644
--- a/server/src/main/java/doumeemes/service/business/impl/CompanyOpenServiceImpl.java
+++ b/server/src/main/java/doumeemes/service/business/impl/CompanyOpenServiceImpl.java
@@ -11,14 +11,18 @@
 import doumeemes.dao.business.model.Company;
 import doumeemes.dao.business.model.CompanyLog;
 import doumeemes.dao.business.model.CompanyOpen;
+import doumeemes.dao.ext.vo.CompanyExtListVO;
 import doumeemes.service.business.CompanyLogService;
 import doumeemes.service.business.CompanyOpenService;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
 import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import doumeemes.service.ext.DepartmentExtService;
 import org.apache.shiro.SecurityUtils;
+import org.springframework.beans.BeanUtils;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.context.annotation.Lazy;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
 import org.springframework.util.CollectionUtils;
@@ -43,6 +47,10 @@
 
     @Autowired
     CompanyLogService companyLogService;
+
+    @Autowired
+    @Lazy
+    private DepartmentExtService departmentExtService;
 
     @Override
     public Integer create(CompanyOpen companyOpen) {
@@ -90,7 +98,7 @@
         company.setOepnValidDate(companyOpen.getValidDate());
         company.setOepnType(companyOpen.getOepnType());
         companyMapper.updateById(company);
-
+        Company company1 = companyMapper.selectById(companyOpen.getCompanyId());
 
         CompanyLog companyLog = new CompanyLog();
         companyLog.setDeleted((byte) Constants.ZERO);
@@ -103,6 +111,15 @@
         companyLog.setUpdateType(Constants.CompanyUpdateType.UPDATE_VAIL_DATE.getKey());
         companyLog.setDetail("鏈夋晥鏈熶粠"+format.format(cyResult.getOepnValidDate())+"鏃ヨ皟鏁磋嚦"+format.format(companyOpen.getValidDate()));
         companyLogService.create(companyLog);
+
+        initRedisCache(company1);
+    }
+
+    private void initRedisCache(Company com) {
+        CompanyExtListVO c = new CompanyExtListVO();
+        BeanUtils.copyProperties(com,c);
+        departmentExtService.loadComDepart(c);
+        departmentExtService.initCompnayCodesByCom(com);
     }
 
     @Override
@@ -131,7 +148,7 @@
         QueryWrapper<CompanyOpen> wrapper = new QueryWrapper<>(companyOpen);
         return companyOpenMapper.selectList(wrapper);
     }
-  
+
     @Override
     public PageData<CompanyOpen> findPage(PageWrap<CompanyOpen> pageWrap) {
         IPage<CompanyOpen> page = new Page<>(pageWrap.getPage(), pageWrap.getCapacity());
diff --git a/server/src/main/java/doumeemes/service/business/impl/CompanyServiceImpl.java b/server/src/main/java/doumeemes/service/business/impl/CompanyServiceImpl.java
index 726b6bf..256c3b0 100644
--- a/server/src/main/java/doumeemes/service/business/impl/CompanyServiceImpl.java
+++ b/server/src/main/java/doumeemes/service/business/impl/CompanyServiceImpl.java
@@ -14,6 +14,7 @@
 import doumeemes.dao.business.model.CompanyLog;
 import doumeemes.dao.business.model.Multifiles;
 import doumeemes.dao.ext.dto.DingDingConfig;
+import doumeemes.dao.ext.vo.CompanyExtListVO;
 import doumeemes.service.business.CompanyLogService;
 import doumeemes.service.business.CompanyService;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
@@ -21,9 +22,12 @@
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import doumeemes.service.business.MultifilesService;
+import doumeemes.service.ext.DepartmentExtService;
 import org.apache.commons.lang3.StringUtils;
 import org.apache.shiro.SecurityUtils;
+import org.springframework.beans.BeanUtils;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.context.annotation.Lazy;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
 import org.springframework.util.CollectionUtils;
@@ -46,6 +50,10 @@
 
     @Autowired
     private CompanyLogService companyLogService;
+
+    @Autowired
+    @Lazy
+    private DepartmentExtService departmentExtService;
 
 
     @Override
@@ -115,36 +123,35 @@
         update.setStatus(company.getStatus());
         update.setDingdingInfo(company.getDingdingInfo());
         companyMapper.updateById(update);
-
 //        鏇存柊璁板綍
-
+        CompanyLog companyLog = new CompanyLog();
+        companyLog.setDeleted((byte)Constants.ZERO);
+        companyLog.setUpdateUser(principal.getId());
+        companyLog.setCreateUser(principal.getId());
+        companyLog.setCreateTime(new Date());
+        companyLog.setUpdateTime(new Date());
+        companyLog.setCompanyId(company.getId());
         if(Objects.nonNull(company.getStatus())){
-            CompanyLog companyLog = new CompanyLog();
-            companyLog.setDeleted((byte)Constants.ZERO);
-            companyLog.setUpdateUser(principal.getId());
-            companyLog.setCreateUser(principal.getId());
-            companyLog.setCreateTime(new Date());
-            companyLog.setUpdateTime(new Date());
             companyLog.setRemark(company.getStatus() == 1 ? "鏁版嵁鍚敤" : "鏁版嵁绂佺敤");
-            companyLog.setCompanyId(company.getId());
             companyLog.setUpdateType(company.getStatus() == 1 ? Constants.CompanyUpdateType.UPDATE_ENABLE.getKey()
                     : Constants.CompanyUpdateType.UPDATE_DISABLE.getKey());
             companyLog.setDetail(company.getStatus() == 1 ? "鏁版嵁鍚敤" : "鏁版嵁绂佺敤");
-            companyLogService.create(companyLog);
         }else {
-            CompanyLog companyLog = new CompanyLog();
-            companyLog.setDeleted((byte)Constants.ZERO);
-            companyLog.setUpdateUser(principal.getId());
-            companyLog.setCreateUser(principal.getId());
-            companyLog.setCreateTime(new Date());
-            companyLog.setUpdateTime(new Date());
             companyLog.setRemark("鏇存柊浼佷笟鏁版嵁");
-            companyLog.setCompanyId(company.getId());
             companyLog.setUpdateType(Constants.CompanyUpdateType.UPDATE_CONTENT.getKey());
             companyLog.setDetail("鏇存柊浼佷笟鏁版嵁");
-            companyLogService.create(companyLog);
         }
+        companyLogService.create(companyLog);
+        Company company1 = companyMapper.selectById(company.getId());
+        initRedisCache(company1);
+    }
 
+
+    private void initRedisCache(Company com) {
+        CompanyExtListVO c = new CompanyExtListVO();
+        BeanUtils.copyProperties(com,c);
+        departmentExtService.loadComDepart(c);
+        departmentExtService.initCompnayCodesByCom(com);
     }
 
     private Boolean isParseObject(String dingdingInfo){
@@ -185,7 +192,7 @@
         QueryWrapper<Company> wrapper = new QueryWrapper<>(company);
         return companyMapper.selectList(wrapper);
     }
-  
+
     @Override
     public PageData<Company> findPage(PageWrap<Company> pageWrap) {
         IPage<Company> page = new Page<>(pageWrap.getPage(), pageWrap.getCapacity());
diff --git a/server/src/main/java/doumeemes/service/business/impl/SalaryParamServiceImpl.java b/server/src/main/java/doumeemes/service/business/impl/SalaryParamServiceImpl.java
index 7d63f71..d98d0ca 100644
--- a/server/src/main/java/doumeemes/service/business/impl/SalaryParamServiceImpl.java
+++ b/server/src/main/java/doumeemes/service/business/impl/SalaryParamServiceImpl.java
@@ -54,19 +54,24 @@
 
     @Override
     public Integer create(SalaryParam salaryParam) {
+
+
         LoginUserInfo principal = (LoginUserInfo) SecurityUtils.getSubject().getPrincipal();
 
         SalaryParam insert = new SalaryParam();
+        insert.setRootDepartId(salaryParam.getRootDepartId());
+        insert.setDepartId(salaryParam.getDepartId());
+        insert.setProcedureId(salaryParam.getProcedureId());
+        insert.setMaterialId(salaryParam.getMaterialId());
         insert.setDeleted((byte) Constants.ZERO);
+        if(findOne(insert) != null){
+            throw  new BusinessException(ResponseStatus.DATA_EXISTS.getCode(),"鍚屼竴涓墿鏂欏湪鐩稿悓宸ュ簭涓嶈兘閲嶅閰嶇疆鍝︼紒");
+        }
         insert.setCreateUser(principal.getId());
         insert.setCreateTime(new Date());
         insert.setUpdateUser(principal.getId());
         insert.setUpdateTime(new Date());
         insert.setRemark(salaryParam.getRemark());
-        insert.setRootDepartId(salaryParam.getRootDepartId());
-        insert.setDepartId(salaryParam.getDepartId());
-        insert.setProcedureId(salaryParam.getProcedureId());
-        insert.setMaterialId(salaryParam.getMaterialId());
         insert.setSalary(salaryParam.getSalary());
         insert.setNum(salaryParam.getNum());
         insert.setTimes(salaryParam.getTimes());
@@ -109,9 +114,9 @@
                 .set(SalaryParam::getUpdateTime,new Date())
                 .set(SalaryParam::getUpdateUser,principal.getId())
                 .set(SalaryParam::getType,salaryParam.getType())
-                .set(SalaryParam::getDepartId,salaryParam.getDepartId())
-                .set(SalaryParam::getMaterialId,salaryParam.getMaterialId())
-                .set(SalaryParam::getProcedureId,salaryParam.getProcedureId())
+//                .set(SalaryParam::getDepartId,salaryParam.getDepartId())
+//                .set(SalaryParam::getMaterialId,salaryParam.getMaterialId())
+//                .set(SalaryParam::getProcedureId,salaryParam.getProcedureId())
                 .set(SalaryParam::getSalary,salaryParam.getSalary())
                 .set(SalaryParam::getNum,salaryParam.getNum())
                 .set(SalaryParam::getTimes,salaryParam.getTimes())
@@ -137,6 +142,7 @@
     @Override
     public SalaryParam findOne(SalaryParam salaryParam) {
         QueryWrapper<SalaryParam> wrapper = new QueryWrapper<>(salaryParam);
+        wrapper.last("limit 1");
         return salaryParamMapper.selectOne(wrapper);
     }
 
@@ -178,7 +184,7 @@
                 || Objects.isNull(s.getDepartName())
                 || Objects.isNull(s.getMaterialCode())
                 || Objects.isNull(s.getProcedureName())
-                || Objects.isNull(s.getNUM())){
+                || Objects.isNull(s.getNum())){
                 throw new BusinessException(ResponseStatus.SERVER_ERROR.getCode(), "瀵煎叆鏁版嵁鍐呭鏈夎锛�");
             }
         });
@@ -214,7 +220,7 @@
             proceduresWrapper.lambda()
                     .eq(Procedures::getName,salaryParamImportDTO.getProcedureName())
                     .eq(Procedures::getRootDepartId,department.getRootId())
-                    .eq(Procedures::getDepartId,department.getId())
+                    .eq(Procedures::getOrgId,department.getId())
                     .last("limit 1");
             Procedures procedures = proceduresMapper.selectOne(proceduresWrapper);
             if (Objects.isNull(procedures)){
@@ -226,10 +232,8 @@
             salaryParam.setProcedureId(procedures.getId());
             salaryParam.setMaterialId(material.getId());
             salaryParam.setSalary(salaryParamImportDTO.getSalary());
-            salaryParam.setNum(new BigDecimal(salaryParamImportDTO.getNUM()));
-
+            salaryParam.setNum(new BigDecimal(salaryParamImportDTO.getNum()));
             salaryParam.setTimes(getIntegerTimes(salaryParamImportDTO.getTimesName()));
-
             Integer unqualified = Optional.ofNullable(salaryParamImportDTO.getUnqualified()).map(s -> {
                 if ("鍚�".equals(s)) {
                     return 0;
@@ -265,7 +269,7 @@
                 m = Integer.parseInt(a.substring(hIndex >=0?hIndex+2:0,mIndex));
             }
             if(sIndex > mIndex){
-               s = Integer.parseInt(a.substring(mIndex >=0?mIndex+2:0,mIndex));
+               s = Integer.parseInt(a.substring(mIndex >= 0 ? mIndex+2 : 0, sIndex));
             }
             return  h*3600+m*60+s;
         }catch (Exception e){
diff --git a/server/src/main/java/doumeemes/service/business/impl/UnqualifiedRecordServiceImpl.java b/server/src/main/java/doumeemes/service/business/impl/UnqualifiedRecordServiceImpl.java
new file mode 100644
index 0000000..d0fa52f
--- /dev/null
+++ b/server/src/main/java/doumeemes/service/business/impl/UnqualifiedRecordServiceImpl.java
@@ -0,0 +1,124 @@
+package doumeemes.service.business.impl;
+
+import doumeemes.core.model.PageData;
+import doumeemes.core.model.PageWrap;
+import doumeemes.core.utils.Utils;
+import doumeemes.dao.business.UnqualifiedRecordMapper;
+import doumeemes.dao.business.model.UnqualifiedRecord;
+import doumeemes.service.business.UnqualifiedRecordService;
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.util.CollectionUtils;
+
+import java.util.List;
+
+/**
+ * 宸ュ崟绫�-鎶ュ伐涓嶈壇璁板綍绫诲瀷琛⊿ervice瀹炵幇
+ * @author 姹熻箘韫�
+ * @since 2023/08/16 14:15
+ */
+@Service
+public class UnqualifiedRecordServiceImpl implements UnqualifiedRecordService {
+
+    @Autowired
+    private UnqualifiedRecordMapper unqualifiedRecordMapper;
+
+    @Override
+    public Integer create(UnqualifiedRecord unqualifiedRecord) {
+        unqualifiedRecordMapper.insert(unqualifiedRecord);
+        return unqualifiedRecord.getId();
+    }
+
+    @Override
+    public void deleteById(Integer id) {
+        unqualifiedRecordMapper.deleteById(id);
+    }
+
+    @Override
+    public void delete(UnqualifiedRecord unqualifiedRecord) {
+        UpdateWrapper<UnqualifiedRecord> deleteWrapper = new UpdateWrapper<>(unqualifiedRecord);
+        unqualifiedRecordMapper.delete(deleteWrapper);
+    }
+
+    @Override
+    public void deleteByIdInBatch(List<Integer> ids) {
+        if (CollectionUtils.isEmpty(ids)) {
+            return;
+        }
+        unqualifiedRecordMapper.deleteBatchIds(ids);
+    }
+
+    @Override
+    public void updateById(UnqualifiedRecord unqualifiedRecord) {
+        unqualifiedRecordMapper.updateById(unqualifiedRecord);
+    }
+
+    @Override
+    public void updateByIdInBatch(List<UnqualifiedRecord> unqualifiedRecords) {
+        if (CollectionUtils.isEmpty(unqualifiedRecords)) {
+            return;
+        }
+        for (UnqualifiedRecord unqualifiedRecord: unqualifiedRecords) {
+            this.updateById(unqualifiedRecord);
+        }
+    }
+
+    @Override
+    public UnqualifiedRecord findById(Integer id) {
+        return unqualifiedRecordMapper.selectById(id);
+    }
+
+    @Override
+    public UnqualifiedRecord findOne(UnqualifiedRecord unqualifiedRecord) {
+        QueryWrapper<UnqualifiedRecord> wrapper = new QueryWrapper<>(unqualifiedRecord);
+        return unqualifiedRecordMapper.selectOne(wrapper);
+    }
+
+    @Override
+    public List<UnqualifiedRecord> findList(UnqualifiedRecord unqualifiedRecord) {
+        QueryWrapper<UnqualifiedRecord> wrapper = new QueryWrapper<>(unqualifiedRecord);
+        return unqualifiedRecordMapper.selectList(wrapper);
+    }
+  
+    @Override
+    public PageData<UnqualifiedRecord> findPage(PageWrap<UnqualifiedRecord> pageWrap) {
+        IPage<UnqualifiedRecord> page = new Page<>(pageWrap.getPage(), pageWrap.getCapacity());
+        QueryWrapper<UnqualifiedRecord> queryWrapper = new QueryWrapper<>();
+        Utils.MP.blankToNull(pageWrap.getModel());
+        queryWrapper.lambda()
+                .eq(pageWrap.getModel().getId() != null, UnqualifiedRecord::getId, pageWrap.getModel().getId())
+                .eq(pageWrap.getModel().getDeleted() != null, UnqualifiedRecord::getDeleted, pageWrap.getModel().getDeleted())
+                .eq(pageWrap.getModel().getCreateUser() != null, UnqualifiedRecord::getCreateUser, pageWrap.getModel().getCreateUser())
+                .ge(pageWrap.getModel().getCreateTime() != null, UnqualifiedRecord::getCreateTime, Utils.Date.getStart(pageWrap.getModel().getCreateTime()))
+                .le(pageWrap.getModel().getCreateTime() != null, UnqualifiedRecord::getCreateTime, Utils.Date.getEnd(pageWrap.getModel().getCreateTime()))
+                .eq(pageWrap.getModel().getUpdateUser() != null, UnqualifiedRecord::getUpdateUser, pageWrap.getModel().getUpdateUser())
+                .ge(pageWrap.getModel().getUpdateTime() != null, UnqualifiedRecord::getUpdateTime, Utils.Date.getStart(pageWrap.getModel().getUpdateTime()))
+                .le(pageWrap.getModel().getUpdateTime() != null, UnqualifiedRecord::getUpdateTime, Utils.Date.getEnd(pageWrap.getModel().getUpdateTime()))
+                .eq(pageWrap.getModel().getRemark() != null, UnqualifiedRecord::getRemark, pageWrap.getModel().getRemark())
+                .eq(pageWrap.getModel().getRootDepartId() != null, UnqualifiedRecord::getRootDepartId, pageWrap.getModel().getRootDepartId())
+                .eq(pageWrap.getModel().getDepartId() != null, UnqualifiedRecord::getDepartId, pageWrap.getModel().getDepartId())
+                .eq(pageWrap.getModel().getWorkorderId() != null, UnqualifiedRecord::getWorkorderId, pageWrap.getModel().getWorkorderId())
+                .eq(pageWrap.getModel().getRecordId() != null, UnqualifiedRecord::getRecordId, pageWrap.getModel().getRecordId())
+                .eq(pageWrap.getModel().getCategoryId() != null, UnqualifiedRecord::getCategoryId, pageWrap.getModel().getCategoryId())
+                .eq(pageWrap.getModel().getUnqualifiedNum() != null, UnqualifiedRecord::getUnqualifiedNum, pageWrap.getModel().getUnqualifiedNum())
+        ;
+        for(PageWrap.SortData sortData: pageWrap.getSorts()) {
+            if (sortData.getDirection().equalsIgnoreCase(PageWrap.DESC)) {
+                queryWrapper.orderByDesc(sortData.getProperty());
+            } else {
+                queryWrapper.orderByAsc(sortData.getProperty());
+            }
+        }
+        return PageData.from(unqualifiedRecordMapper.selectPage(page, queryWrapper));
+    }
+
+    @Override
+    public long count(UnqualifiedRecord unqualifiedRecord) {
+        QueryWrapper<UnqualifiedRecord> wrapper = new QueryWrapper<>(unqualifiedRecord);
+        return unqualifiedRecordMapper.selectCount(wrapper);
+    }
+}
diff --git a/server/src/main/java/doumeemes/service/business/impl/WOutboundServiceImpl.java b/server/src/main/java/doumeemes/service/business/impl/WOutboundServiceImpl.java
index d82226a..67abb5c 100644
--- a/server/src/main/java/doumeemes/service/business/impl/WOutboundServiceImpl.java
+++ b/server/src/main/java/doumeemes/service/business/impl/WOutboundServiceImpl.java
@@ -2126,6 +2126,9 @@
             WOutboundInBodyBean wOutboundInBodyBean = wOutboundInBodyBeans.get(Constants.ZERO);
             //绱鍏ュ簱鏁伴噺
             wOutboundInBodyBean.setNum(wOutboundInBodyBeans.stream().map(s -> s.getNum()).reduce(BigDecimal.ZERO, BigDecimal::add));
+            if(wOutboundInBodyBean.getNum().compareTo(BigDecimal.ZERO)<=Constants.ZERO){
+                throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(), "鏁伴噺寮傚父,璇锋鏌ユ暟閲�!");
+            }
             WOutboundDetail wOutboundDetail = new WOutboundDetail();
             //鏌ヨ鐗╂枡鏁版嵁
             MaterialDistribute materialDistribute = materialDistributeMapper.selectById(wOutboundInBodyBean.getMaterialId());
diff --git a/server/src/main/java/doumeemes/service/ext/CategoryExtService.java b/server/src/main/java/doumeemes/service/ext/CategoryExtService.java
index ec98c94..d5f239d 100644
--- a/server/src/main/java/doumeemes/service/ext/CategoryExtService.java
+++ b/server/src/main/java/doumeemes/service/ext/CategoryExtService.java
@@ -33,4 +33,6 @@
     CategoryExtListVO getByCategoryId(Integer comid, Integer id);
     CategoryExtListVO getByCategoryId(Integer comid, Integer id,List<CategoryExtListVO> allList);
     void loadAll();
+
+    List<CategoryExtListVO> findList(QueryCategoryExtDTO queryCategoryExtDTO);
 }
diff --git a/server/src/main/java/doumeemes/service/ext/impl/CategoryExtServiceImpl.java b/server/src/main/java/doumeemes/service/ext/impl/CategoryExtServiceImpl.java
index b906671..d8ac8f3 100644
--- a/server/src/main/java/doumeemes/service/ext/impl/CategoryExtServiceImpl.java
+++ b/server/src/main/java/doumeemes/service/ext/impl/CategoryExtServiceImpl.java
@@ -49,6 +49,12 @@
     }
 
     @Override
+    public List<CategoryExtListVO> findList(QueryCategoryExtDTO queryCategoryExtDTO) {
+        List<CategoryExtListVO> result = categoryExtMapper.selectList(queryCategoryExtDTO);
+        return result;
+    }
+
+    @Override
     public List<CategoryExtListVO> getListByType(String type,Integer rootDepartId,String cateType,String id) {
         QueryCategoryExtDTO queryCategoryExtDTO=new QueryCategoryExtDTO();
         queryCategoryExtDTO.setDeleted(Constants.ZERO);
diff --git a/server/src/main/java/doumeemes/service/ext/impl/DepartmentExtServiceImpl.java b/server/src/main/java/doumeemes/service/ext/impl/DepartmentExtServiceImpl.java
index d918101..aedce83 100644
--- a/server/src/main/java/doumeemes/service/ext/impl/DepartmentExtServiceImpl.java
+++ b/server/src/main/java/doumeemes/service/ext/impl/DepartmentExtServiceImpl.java
@@ -37,6 +37,7 @@
 import org.springframework.transaction.annotation.Transactional;
 import org.springframework.util.CollectionUtils;
 
+import javax.annotation.PostConstruct;
 import java.util.*;
 import java.util.stream.Collectors;
 
@@ -443,6 +444,7 @@
             //鍔犲叆redis缂撳瓨锛屽瓨鍌ㄤ紒涓氫俊鎭�
             RedisUtil.addObject(redisTemplate,Constants.RedisKeys.COM_DEPART_TREE_KEY+com.getId(),rootDepart);
     }
+    @PostConstruct
     @Override
     public  void loadAllDepart() {
         QueryCompanyExtDTO dto = new QueryCompanyExtDTO();
@@ -796,7 +798,7 @@
             for (Department department:departmentList ) {
                 this.dealDepartmentData(department,user);
             }
-        } 
+        }
     }
 
     public void dealDepartmentData(Department department,LoginUserInfo user){
diff --git a/server/src/main/java/doumeemes/service/ext/impl/PlansExtServiceImpl.java b/server/src/main/java/doumeemes/service/ext/impl/PlansExtServiceImpl.java
index 271a637..d283106 100644
--- a/server/src/main/java/doumeemes/service/ext/impl/PlansExtServiceImpl.java
+++ b/server/src/main/java/doumeemes/service/ext/impl/PlansExtServiceImpl.java
@@ -16,6 +16,8 @@
 import doumeemes.core.utils.excel.EasyExcelUtil;
 import doumeemes.core.utils.redis.RedisUtil;
 import doumeemes.dao.business.PlansMapper;
+import doumeemes.dao.business.UnqualifiedRecordMapper;
+import doumeemes.dao.business.WorkorderMapper;
 import doumeemes.dao.business.dto.*;
 import doumeemes.dao.business.model.*;
 import doumeemes.dao.ext.*;
@@ -34,6 +36,7 @@
 import org.springframework.web.multipart.MultipartFile;
 
 import java.math.BigDecimal;
+import java.time.LocalDate;
 import java.util.ArrayList;
 import java.util.Date;
 import java.util.List;
@@ -64,7 +67,8 @@
     private WorkorderHistoryExtMapper workorderHistoryExtMapper;
     @Autowired
     private WorkorderRecordExtMapper workorderRecordExtMapper;
-
+    @Autowired
+    private WorkorderMapper workorderMapper;
     @Autowired
     private RouteProcedureExtMapper routeProcedureExtMapper;
     @Autowired
@@ -89,6 +93,8 @@
     private WStockExtService  wStockExtService;
     @Autowired
     private WorkorderRecordStandardService workorderRecordStandardService;
+    @Autowired
+    private UnqualifiedRecordMapper unqualifiedRecordMapper;
 
     @Override
     public  PlansExtListVO findById(Integer id){
@@ -139,6 +145,19 @@
 //        //缁熻宸插畬宸ユ暟閲�
 //        param.setStatus(Constants.WORKORDER_STATUS.done);
 //        plan.setDoneNum(workorderExtMapper.sumOrderNum(param));
+        QueryBomExtDTO bb = new QueryBomExtDTO();
+        bb.setDepartId(plan.getDepartId());
+        bb.setDeleted(Constants.ZERO);
+        bb.setRootDepartId(user.getRootDepartment().getId());
+        bb.setMaterialId(plan.getMaterialId());
+        bb.setProcedureId(plan.getProcedureId());
+        BomExtListVO versionBom = bomExtMapper.selectByModel( bb);
+        if(versionBom == null || StringUtils.isBlank(versionBom.getVersion()) || versionBom.getBomVersionId() == null){
+            plan.setHasBom(Constants.ZERO);
+        }else {
+            plan.setBomType(Constants.formatIntegerNum(versionBom.getType()));
+            plan.setHasBom(Constants.ONE);
+        }
         return plan;
     }
 
@@ -197,6 +216,14 @@
 //                p.setDistributNum(tp.getDistributNum());
 //                p.setDoneNum(tp.getDoneNum());
                 p.setIsStock(wStockExtService.isStockForPlan(p));
+                p.setHasExpire(false);
+                p.setStatus(Constants.formatIntegerNum(p.getStatus()));
+                if ( !p.getStatus().equals(Constants.PLAN_STATUS.done) &&
+                        !p.getStatus().equals(Constants.PLAN_STATUS.close)){
+                    if (Objects.nonNull(p.getPlanDate())){
+                        p.setHasExpire(DateUtil.toDateLocalDateTime(p.getWorkPlanPlanDate()).toLocalDate().isBefore(LocalDate.now()));
+                    }
+                }
             }
         }
         return PageData.from(new PageInfo<>(result));
@@ -592,7 +619,7 @@
         if(Constants.equalsInteger(mp.getPaused(),Constants.ONE)){
             throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(), "瀵逛笉璧凤紝璁″垝宸叉殏鍋滐紒");
         }
-        if(Constants.formatIntegerNum(mp.getDistributNum())+thisPlanNum > Constants.formatIntegerNum(mp.getNum())){
+        if(Constants.formatIntegerNum(mp.getWorkorderDistributNum())+thisPlanNum > Constants.formatIntegerNum(mp.getNum())){
             throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(), "瀵逛笉璧凤紝绱鍒嗛厤鏁伴噺澶т簬璁″垝鏁伴噺锛�");
         }
         if(!Constants.equalsInteger(mp.getStatus(),Constants.PLAN_STATUS.publish)&&!Constants.equalsInteger(mp.getStatus(),Constants.PLAN_STATUS.distribute)){
@@ -678,9 +705,9 @@
         if(ulist == null){
             throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(), "瀵逛笉璧凤紝鐢熶骇浜哄憳淇℃伅涓嶆纭紝璇峰埛鏂伴〉闈㈤噸璇曪紒");
         }
-        if(ulist.size() < param.getProUserList().size()){
-            throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(), "瀵逛笉璧凤紝瀛樺湪鐢熶骇浜哄憳淇℃伅涓嶆纭紝璇峰埛鏂伴〉闈㈤噸璇曪紒");
-        }
+//        if(ulist.size() < param.getProUserList().size()){
+//            throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(), "瀵逛笉璧凤紝瀛樺湪鐢熶骇浜哄憳淇℃伅涓嶆纭紝璇峰埛鏂伴〉闈㈤噸璇曪紒");
+//        }
         List<WorkorderUser> userList = new ArrayList<>();
         for(UserDeviceExtListVO uModel : ulist){
             WorkorderUser u = new WorkorderUser();
@@ -1507,7 +1534,7 @@
     }
     /**
      * 鎭㈠璁″垝
-     * @param p
+     * @param
      */
     @Transactional(rollbackFor = {BusinessException.class,Exception.class})
     @Override
@@ -1563,7 +1590,7 @@
         if(Objects.isNull(plans)){
             throw new BusinessException(ResponseStatus.DATA_EMPTY.getCode(),"鏈煡璇㈠埌宸ュ簭璁″垝鏁版嵁");
         }
-        if(!(plans.getStatus().equals(Constants.PLAN_STATUS.create)||plans.getStatus().equals(Constants.PLAN_STATUS.distribute))){
+        if(!(plans.getStatus().equals(Constants.PLAN_STATUS.create)||plans.getStatus().equals(Constants.PLAN_STATUS.publish)||plans.getStatus().equals(Constants.PLAN_STATUS.distribute))){
             throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"宸ュ簭璁″垝宸叉祦杞紝鏃犳硶鎿嶄綔");
         }
         if(plans.getPaused().equals(Constants.ONE)){
@@ -1573,7 +1600,8 @@
             throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"鍙傛暟閿欒锛氫骇鍑烘暟鎹�");
         }
         //鏌ヨ宸ュ簭璁″垝宸插垎閰嶆暟閲�
-        List<Workorder> workorderList = workorderExtMapper.selectList(new QueryWrapper<Workorder>().eq("PLAN_ID",plans.getId()).notIn("STATUS",7,8));
+        List<Workorder> workorderList = workorderMapper.selectList(new QueryWrapper<Workorder>().eq("PLAN_ID",plans.getId())
+                .eq("STATUS",Constants.WORKORDER_STATUS.baogong));
         //鏈浜у嚭鏁伴噺
         BigDecimal num = autoWorkReportDTO.getCreateWorkorderRecordDTO().getQualifiedNum().add(autoWorkReportDTO.getCreateWorkorderRecordDTO().getUnQualifiedNum());
         if(num.compareTo(BigDecimal.ZERO)<=Constants.ZERO){
@@ -1590,7 +1618,7 @@
         param.setPlanDate(new Date());
         param.setProGroupId(autoWorkReportDTO.getProGroupId());
         param.setProUserList(autoWorkReportDTO.getProUserList());
-        param.setPlanNum(plans.getNum());
+        param.setPlanNum(num.intValue());
         //鐢熸垚宸ュ崟淇℃伅
         Workorder workorder = this.distributeDone(user,param,plans.getNum());
         //宸ュ崟鎶曟枡璁板綍
@@ -1601,7 +1629,8 @@
             workorderRecordStandardService.createMaterialStandard(createMaterialDTO);
         }
         //宸ュ崟浜у嚭璁板綍
-        workorderRecordStandardService.createWorkorderRecord(autoWorkReportDTO.getCreateWorkorderRecordDTO(),user);
+        autoWorkReportDTO.getCreateWorkorderRecordDTO().setWorkorderId(workorder.getId());
+        WorkorderRecord workorderRecord = workorderRecordStandardService.createWorkorderRecord(autoWorkReportDTO.getCreateWorkorderRecordDTO(),user);
         //宸ュ崟鎶ュ伐
         workorderRecordStandardService.comfirmDone(workorder);
         //鏇存柊宸ュ崟鐘舵��
@@ -1613,8 +1642,35 @@
             }
         }
         plansExtMapper.updateById(plans);
-
-
+        //瀛樺偍鎶ュ伐涓嶈壇椤规暟鎹�
+        if(autoWorkReportDTO.getCreateWorkorderRecordDTO().getUnQualifiedNum().compareTo(BigDecimal.ZERO)<=Constants.ZERO){
+            if(!Objects.isNull(autoWorkReportDTO.getCreateUnqualifiedDTOList())&&autoWorkReportDTO.getCreateUnqualifiedDTOList().size()>Constants.ZERO){
+                throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"涓嶈壇椤归敊璇細璇锋鏌ヤ笉鑹」鏁版嵁");
+            }
+        }else{
+            List<CreateUnqualifiedDTO> createUnqualifiedDTOList = autoWorkReportDTO.getCreateUnqualifiedDTOList();
+            BigDecimal unqualified = createUnqualifiedDTOList.stream().map(s -> s.getUnQualifiedNum()).reduce(BigDecimal.ZERO, BigDecimal::add);
+            if(unqualified.compareTo(autoWorkReportDTO.getCreateWorkorderRecordDTO().getUnQualifiedNum())!=Constants.ZERO){
+                throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"涓嶈壇椤归敊璇細璇锋鏌ヤ笉鑹」鏁版嵁");
+            }
+            for (CreateUnqualifiedDTO createUnqualifiedDTO:createUnqualifiedDTOList) {
+                if(createUnqualifiedDTO.getUnQualifiedNum().compareTo(BigDecimal.ZERO)==Constants.ZERO
+                ||Objects.isNull(createUnqualifiedDTO.getCategoryId())){
+                    throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"涓嶈壇椤归敊璇細璇锋鏌ヤ笉鑹」鏁版嵁");
+                }
+                UnqualifiedRecord unqualifiedRecord = new UnqualifiedRecord();
+                unqualifiedRecord.setDeleted(Constants.ZERO);
+                unqualifiedRecord.setCreateUser(user.getId());
+                unqualifiedRecord.setCreateTime(new Date());
+                unqualifiedRecord.setRootDepartId(plans.getRootDepartId());
+                unqualifiedRecord.setDepartId(plans.getDepartId());
+                unqualifiedRecord.setWorkorderId(workorder.getId());
+                unqualifiedRecord.setRecordId(workorderRecord.getId());
+                unqualifiedRecord.setCategoryId(createUnqualifiedDTO.getCategoryId());
+                unqualifiedRecord.setUnqualifiedNum(createUnqualifiedDTO.getUnQualifiedNum());
+                unqualifiedRecordMapper.insert(unqualifiedRecord);
+            }
+        }
     }
 
 
diff --git a/server/src/main/java/doumeemes/service/ext/impl/WorkPlansExtServiceImpl.java b/server/src/main/java/doumeemes/service/ext/impl/WorkPlansExtServiceImpl.java
index f33817e..4885ee4 100644
--- a/server/src/main/java/doumeemes/service/ext/impl/WorkPlansExtServiceImpl.java
+++ b/server/src/main/java/doumeemes/service/ext/impl/WorkPlansExtServiceImpl.java
@@ -175,12 +175,16 @@
                     i.setFinishUnQualifiedNum(Objects.isNull(plansExtListVO.getUnqulifiedNum())?Constants.ZERO:plansExtListVO.getUnqulifiedNum());
                     i.setFinishNum(Objects.isNull(plansExtListVO.getDoneNum())?Constants.ZERO:plansExtListVO.getDoneNum());
                 }
-                if (Objects.nonNull(i.getPlanDate())){
-                    i.setHasExpire(DateUtil.toDateLocalDateTime(i.getPlanDate()).toLocalDate().isBefore(LocalDate.now()));
-                }else {
-                    i.setHasExpire(false);
+                i.setHasExpire(false);
+                i.setStatus(Constants.formatIntegerNum(i.getStatus()));
+                if ( !i.getStatus().equals(Constants.WORKPLANHISTORY_TYPE.done) &&
+                        !i.getStatus().equals(Constants.WORKPLANHISTORY_TYPE.close)){
+                    if (Objects.nonNull(i.getPlanDate())){
+                        i.setHasExpire(DateUtil.toDateLocalDateTime(i.getPlanDate()).toLocalDate().isBefore(LocalDate.now()));
+                    }
                 }
 
+
             });
         }
         return PageData.from(new PageInfo<>(result));
diff --git a/server/src/main/java/doumeemes/service/ext/impl/WorkorderRecordStandardServiceImpl.java b/server/src/main/java/doumeemes/service/ext/impl/WorkorderRecordStandardServiceImpl.java
index ffb5760..596283d 100644
--- a/server/src/main/java/doumeemes/service/ext/impl/WorkorderRecordStandardServiceImpl.java
+++ b/server/src/main/java/doumeemes/service/ext/impl/WorkorderRecordStandardServiceImpl.java
@@ -669,13 +669,13 @@
             if (bomDetailList == null || bomDetailList.size() == 0) {
                 throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(), "瀵逛笉璧凤紝璇ョ敓浜х墿鏂欑殑bom閰嶇疆鏈夎锛岃鑱旂郴绠$悊鍛橈紒");
             }
-            for (BomDetailExtListVO i :bomDetailList) {
-                //鏌ヨ鏄惁鎶曟枡
-                if(workorderRecordExtMapper.selectCount(new QueryWrapper<WorkorderRecord>()
-                        .eq("DELETED",Constants.ZERO).eq("MATERIAL_ID",i.getMaterialId()).eq("TYPE",Constants.ZERO))<=0){
-                    throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"瀛樺湪鏈姇鏂橞OM鐗╂枡锛屾棤娉曡繘琛屾姤宸�");
-                }
-            }
+//            for (BomDetailExtListVO i :bomDetailList) {
+//                //鏌ヨ鏄惁鎶曟枡
+//                if(workorderRecordExtMapper.selectCount(new QueryWrapper<WorkorderRecord>()
+//                        .eq("DELETED",Constants.ZERO).eq("MATERIAL_ID",i.getMaterialId()).eq("TYPE",Constants.ZERO))<=0){
+//                    throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"瀛樺湪鏈姇鏂橞OM鐗╂枡锛屾棤娉曡繘琛屾姤宸�");
+//                }
+//            }
         }
 
         WOutbound outbound = new WOutbound();
@@ -794,6 +794,126 @@
 
 
 
+//    private void dealAppliancePro(Workorder mp
+//            , LoginUserInfo user
+//            , List<WorkorderRecordExtListVO> allRecordList
+//            , List<Appliances> updateApplianceList
+//            , List<Appliances> updateApplianceProList
+//            ,   List<WOutboundDetail> outboundDetailList
+//            ,   List<WStock> stockList) {
+//        WOutbound outbound = new WOutbound();
+//        outbound.setDeleted(Constants.ZERO);
+//        outbound.setCreateTime(DateUtil.getCurrentDate());
+//        outbound.setDealDate(outbound.getCreateTime());
+//        outbound.setValidDate(outbound.getCreateTime());
+//        outbound.setCreateUser(user.getId());
+//        outbound.setRootDepartId(mp.getRootDepartId());
+//        outbound.setDepartId(mp.getDepartId());
+//        outbound.setStatus(Constants.WOUTBOUND_STATUS.dealed);
+//        outbound.setType(Constants.WOUTBOUND_TYPE.in);
+//        //2022骞�7鏈�1鏃�14:42:41 鍔犲叆鍗曟嵁绫诲埆
+//        outbound.setBillType(Constants.WOUTBOUND_BILLTYPE.workerOrderIn);
+//        outbound.setCode(wOutboundService.getNextInCode(user.getCompany().getId()));
+//        outbound.setOrigin(Constants.ONE);
+//        outbound.setOriginType(Constants.WOUTBOUND_ORIGIN_TYPE.produce);
+//        outbound.setOriginCode(mp.getCode());
+//        outbound.setOriginId(mp.getId());
+//        outbound.setPlanDate(DateUtil.getCurrentDate());
+//        outbound.setProcedureId(mp.getProcedureId());
+//        outbound.setUserId(user.getId());
+//        outbound.setWarehouseId(mp.getFinishWarehouseId());
+//        wOutboundService.create(outbound);
+//
+//        List<WOutboundDetail> detailList = new ArrayList<>();
+//        List<WOutboundRecord> recordList = new ArrayList<>();
+//        for(WorkorderRecordExtListVO tModel :allRecordList){
+//            if(Constants.equalsInteger(tModel.getType(),Constants.WORKORDER_RECORD_TYPE.produce)){
+//                if(tModel.getNum().compareTo(BigDecimal.ZERO)<=Constants.ZERO){
+//                    continue;
+//                }
+//                //濡傛灉鏄骇鍑�
+//                mp.setHasProduceNum(Constants.formatBigdecimal(tModel.getNum()).intValue()+Constants.formatIntegerNum(mp.getHasProduceNum()));
+//
+//                //鐗╂枡+鎵规+宸ュ簭+璐ㄩ噺灞炴�у幓閲�
+//                WOutboundDetail detail =getWoutbondDetailByList(tModel,detailList);
+//                if(detail!=null){
+//                    detail.setNum(Constants.formatBigdecimal(detail.getNum()).add(tModel.getNum()));
+//                }else{
+//                    detail = new WOutboundDetail();
+//                    detail.setDeleted(Constants.ZERO);
+//                    detail.setCreateTime(DateUtil.getCurrentDate());
+//                    detail.setCreateUser(user.getId());
+//                    detail.setOutboundId(outbound.getId());
+//                    detail.setRootDepartId(outbound.getRootDepartId());
+//                    detail.setWarehouseId(outbound.getWarehouseId());
+//                    detail.setLocationId(mp.getFinishWarehouseLocationId());
+//                    detail.setNum(tModel.getNum());
+//                    detail.setStatus(Constants.ONE);
+//                    detail.setDoneNum(tModel.getNum());
+//                    detail.setDoneDate(new Date());
+//                    detail.setUnitId(tModel.getUnitId());
+//                    detail.setBatch(tModel.getMaterialBatch());
+//                    detail.setProcedureId(tModel.getProcedureId());
+//                    detail.setMaterialId(tModel.getMaterialId());
+//                    detail.setQualityType(tModel.getDoneType());
+//                    detail.setWOutboundRecordInList(new ArrayList<>());
+//                    detailList.add(detail);
+//                }
+//
+//                WOutboundRecord record = new WOutboundRecord();
+//                record.setDeleted(Constants.ZERO);
+//                record.setCreateTime(DateUtil.getCurrentDate());
+//                record.setCreateUser(user.getId());
+//                record.setAppliancesId(tModel.getAppliancesId());
+//                record.setBatch(detail.getBatch());
+//                record.setRootDepartId(mp.getRootDepartId());
+//                record.setNum(tModel.getNum());
+//                record.setOutboundId(detail.getOutboundId());
+//                record.setUnitId(detail.getUnitId());
+//                record.setWarehouseId(detail.getWarehouseId());
+//                record.setMaterialId(detail.getMaterialId());
+//                record.setProcedureId(detail.getProcedureId());
+//                record.setLocationId(detail.getLocationId());
+//                record.setQualityType(detail.getQualityType());
+//                detail.getWOutboundRecordInList().add(record);
+//
+//                WStock stock = getFromStockList(mp.getFinishWarehouseLocationId(),detail.getWarehouseId(),detail.getMaterialId(),detail.getBatch(),
+//                        tModel.getProcedureId(),tModel.getDoneType(),stockList);
+//                if(stock!=null){
+//                    //濡傛灉搴撳瓨瀵硅薄宸插瓨鍦紝鐩存帴澧炲姞瀵瑰簲鐨勫簱瀛橀噺
+//                    stock.setNum(Constants.formatBigdecimal(stock.getNum()).add(Constants.formatBigdecimal(tModel.getNum())));
+//                }else{
+//                    stock = new WStock();
+//                    stock.setMaterialId(detail.getMaterialId());
+//                    stock.setBatch(detail.getBatch());
+//                    stock.setWarehouseId(outbound.getWarehouseId());
+//                    stock.setLocationId(mp.getFinishWarehouseLocationId());
+//                    stock.setUnitId(detail.getUnitId());
+//                    stock.setNum(Constants.formatBigdecimal(tModel.getNum()));
+//                    stock.setProcedureId(tModel.getProcedureId());
+//                    stock.setQualityType(tModel.getDoneType());
+//                    //寰呮洿鏂板簱瀛樹俊鎭�
+//                    stockList.add(stock);
+//                }
+//            }
+//        }
+//        for(WOutboundDetail detail : detailList){
+//            wOutboundDetailExtMapper.insert(detail);
+//            //璁板綍搴撳瓨鍙樺姩璁板綍
+//            wStockRecordExtService.saveRecord(Constants.ONE,detail.getId(),user);
+//            if(detail.getWOutboundRecordInList()!=null){
+//                for(WOutboundRecord r : detail.getWOutboundRecordInList()){
+//                    r.setDetailId(detail.getId());
+//                    wOutboundRecordExtMapper.insert(r);
+//                }
+//            }
+//        }
+//        if(Constants.formatIntegerNum(mp.getHasProduceNum()) >Constants.formatIntegerNum(mp.getPlanNum())){
+//            throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(), "瀵逛笉璧凤紝璇ュ伐鍗曠殑浜у嚭鏁伴噺涓嶈兘澶т簬宸ュ崟璁″垝鏁伴噺锛�");
+//        }
+//    }
+
+
     private void dealAppliancePro(Workorder mp
             , LoginUserInfo user
             , List<WorkorderRecordExtListVO> allRecordList
@@ -833,78 +953,10 @@
                 }
                 //濡傛灉鏄骇鍑�
                 mp.setHasProduceNum(Constants.formatBigdecimal(tModel.getNum()).intValue()+Constants.formatIntegerNum(mp.getHasProduceNum()));
-                if(tModel.getDoneType() == null){
-                    throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(), "瀵逛笉璧凤紝宸ヨ鍣ㄥ叿銆�"+tModel.getAmodel().getCode()+"銆戜骇鍑鸿川閲忓睘鎬т负绌猴紝鏃犳硶鎶ュ伐锛�");
-                }
-                if(!Constants.equalsInteger(tModel.getDoneType(),Constants.ZERO)){
-                    //濡傛灉涓嶈壇锛岀疮璁″伐鍗曠殑涓嶈壇浜у嚭
-                    mp.setUnqualifiedNum(Constants.formatIntegerNum(mp.getUnqualifiedNum())+(Constants.formatBigdecimal(tModel.getNum()).intValue()));
-                }else{
-                    //濡傛灉鏄悎鏍硷紝绱宸ュ崟鐨勫悎鏍兼暟閲�
-                    mp.setQualifiedNum(Constants.formatIntegerNum(mp.getQualifiedNum())+(Constants.formatBigdecimal(tModel.getNum()).intValue()));
-                }
-
-                //鐗╂枡+鎵规+宸ュ簭+璐ㄩ噺灞炴�у幓閲�
-                WOutboundDetail detail =getWoutbondDetailByList(tModel,detailList);
-                if(detail!=null){
-                    detail.setNum(Constants.formatBigdecimal(detail.getNum()).add(tModel.getNum()));
-                }else{
-                    detail = new WOutboundDetail();
-                    detail.setDeleted(Constants.ZERO);
-                    detail.setCreateTime(DateUtil.getCurrentDate());
-                    detail.setCreateUser(user.getId());
-                    detail.setOutboundId(outbound.getId());
-                    detail.setRootDepartId(outbound.getRootDepartId());
-                    detail.setWarehouseId(outbound.getWarehouseId());
-                    detail.setLocationId(mp.getFinishWarehouseLocationId());
-                    detail.setNum(tModel.getNum());
-                    detail.setStatus(Constants.ONE);
-                    detail.setDoneNum(tModel.getNum());
-                    detail.setDoneDate(new Date());
-                    detail.setUnitId(tModel.getUnitId());
-                    detail.setBatch(tModel.getMaterialBatch());
-                    detail.setProcedureId(tModel.getProcedureId());
-                    detail.setMaterialId(tModel.getMaterialId());
-                    detail.setQualityType(tModel.getDoneType());
-                    detail.setWOutboundRecordInList(new ArrayList<>());
-                    detailList.add(detail);
-                }
-
-                WOutboundRecord record = new WOutboundRecord();
-                record.setDeleted(Constants.ZERO);
-                record.setCreateTime(DateUtil.getCurrentDate());
-                record.setCreateUser(user.getId());
-                record.setAppliancesId(tModel.getAppliancesId());
-                record.setBatch(detail.getBatch());
-                record.setRootDepartId(mp.getRootDepartId());
-                record.setNum(tModel.getNum());
-                record.setOutboundId(detail.getOutboundId());
-                record.setUnitId(detail.getUnitId());
-                record.setWarehouseId(detail.getWarehouseId());
-                record.setMaterialId(detail.getMaterialId());
-                record.setProcedureId(detail.getProcedureId());
-                record.setLocationId(detail.getLocationId());
-                record.setQualityType(detail.getQualityType());
-                detail.getWOutboundRecordInList().add(record);
-
-                WStock stock = getFromStockList(mp.getFinishWarehouseLocationId(),detail.getWarehouseId(),detail.getMaterialId(),detail.getBatch(),
-                        tModel.getProcedureId(),tModel.getDoneType(),stockList);
-                if(stock!=null){
-                    //濡傛灉搴撳瓨瀵硅薄宸插瓨鍦紝鐩存帴澧炲姞瀵瑰簲鐨勫簱瀛橀噺
-                    stock.setNum(Constants.formatBigdecimal(stock.getNum()).add(Constants.formatBigdecimal(tModel.getNum())));
-                }else{
-                    stock = new WStock();
-                    stock.setMaterialId(detail.getMaterialId());
-                    stock.setBatch(detail.getBatch());
-                    stock.setWarehouseId(outbound.getWarehouseId());
-                    stock.setLocationId(mp.getFinishWarehouseLocationId());
-                    stock.setUnitId(detail.getUnitId());
-                    stock.setNum(Constants.formatBigdecimal(tModel.getNum()));
-                    stock.setProcedureId(tModel.getProcedureId());
-                    stock.setQualityType(tModel.getDoneType());
-                    //寰呮洿鏂板簱瀛樹俊鎭�
-                    stockList.add(stock);
-                }
+                //浜у嚭鍚堟牸
+               this.createOutDetail(user,outbound,mp,tModel,Constants.ZERO,detailList,stockList);
+               //浜у嚭涓嶈壇
+                this.createOutDetail(user,outbound,mp,tModel,Constants.ONE,detailList,stockList);
             }
         }
         for(WOutboundDetail detail : detailList){
@@ -922,6 +974,68 @@
             throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(), "瀵逛笉璧凤紝璇ュ伐鍗曠殑浜у嚭鏁伴噺涓嶈兘澶т簬宸ュ崟璁″垝鏁伴噺锛�");
         }
     }
+
+
+    public void createOutDetail(LoginUserInfo user,WOutbound outbound,Workorder mp,WorkorderRecordExtListVO tModel,Integer doneType
+            ,List<WOutboundDetail> detailList,List<WStock> stockList ){
+        //鐗╂枡+鎵规+宸ュ簭+璐ㄩ噺灞炴�у幓閲�
+        WOutboundDetail detail =  new WOutboundDetail();
+        detail.setDeleted(Constants.ZERO);
+        detail.setCreateTime(DateUtil.getCurrentDate());
+        detail.setCreateUser(user.getId());
+        detail.setOutboundId(outbound.getId());
+        detail.setRootDepartId(outbound.getRootDepartId());
+        detail.setWarehouseId(outbound.getWarehouseId());
+        detail.setLocationId(mp.getFinishWarehouseLocationId());
+        detail.setNum(BigDecimal.valueOf(doneType.equals(Constants.ZERO)?tModel.getQualifiedNum():tModel.getUnqualifiedNum()));
+        detail.setStatus(Constants.ONE);
+        detail.setDoneNum(detail.getNum());
+        detail.setDoneDate(new Date());
+        detail.setUnitId(tModel.getUnitId());
+        detail.setBatch(tModel.getMaterialBatch());
+        detail.setProcedureId(tModel.getProcedureId());
+        detail.setMaterialId(tModel.getMaterialId());
+        detail.setQualityType(doneType);
+        detail.setWOutboundRecordInList(new ArrayList<>());
+        detailList.add(detail);
+
+        WOutboundRecord record = new WOutboundRecord();
+        record.setDeleted(Constants.ZERO);
+        record.setCreateTime(DateUtil.getCurrentDate());
+        record.setCreateUser(user.getId());
+        record.setAppliancesId(tModel.getAppliancesId());
+        record.setBatch(detail.getBatch());
+        record.setRootDepartId(mp.getRootDepartId());
+        record.setNum(tModel.getNum());
+        record.setOutboundId(detail.getOutboundId());
+        record.setUnitId(detail.getUnitId());
+        record.setWarehouseId(detail.getWarehouseId());
+        record.setMaterialId(detail.getMaterialId());
+        record.setProcedureId(detail.getProcedureId());
+        record.setLocationId(detail.getLocationId());
+        record.setQualityType(detail.getQualityType());
+        detail.getWOutboundRecordInList().add(record);
+
+        WStock stock = getFromStockList(mp.getFinishWarehouseLocationId(),detail.getWarehouseId(),detail.getMaterialId(),detail.getBatch(),
+                tModel.getProcedureId(),tModel.getDoneType(),stockList);
+        if(stock!=null){
+            //濡傛灉搴撳瓨瀵硅薄宸插瓨鍦紝鐩存帴澧炲姞瀵瑰簲鐨勫簱瀛橀噺
+            stock.setNum(Constants.formatBigdecimal(stock.getNum()).add(Constants.formatBigdecimal(tModel.getNum())));
+        }else{
+            stock = new WStock();
+            stock.setMaterialId(detail.getMaterialId());
+            stock.setBatch(detail.getBatch());
+            stock.setWarehouseId(outbound.getWarehouseId());
+            stock.setLocationId(mp.getFinishWarehouseLocationId());
+            stock.setUnitId(detail.getUnitId());
+            stock.setNum(Constants.formatBigdecimal(tModel.getNum()));
+            stock.setProcedureId(tModel.getProcedureId());
+            stock.setQualityType(tModel.getDoneType());
+            //寰呮洿鏂板簱瀛樹俊鎭�
+            stockList.add(stock);
+        }
+    }
+
 
     private WStock initMaterialNum(Integer materialId, BigDecimal num) {
         WStock s = new WStock();
@@ -1247,16 +1361,14 @@
         workorderRecord.setSalaryPrice(salaryParam.getSalary());
         workorderRecord.setSalaryType(salaryParam.getType());
         workorderRecord.setSalaryUnqualified(salaryParam.getUnqualified());
-
         //璁′欢宸ヨ祫
         if(salaryParam.getType().equals(Constants.ZERO)){
             workorderRecord.setSalaryNum(salaryParam.getNum());
-            workorderRecord.setSalary(salaryParam.getSalary().multiply(salaryParam.getUnqualified()==Constants.ZERO?num:createWorkorderRecordDTO.getUnQualifiedNum()));
+            workorderRecord.setSalary(salaryParam.getSalary().multiply(salaryParam.getUnqualified()==Constants.ONE?num:createWorkorderRecordDTO.getQualifiedNum()));
         }else{
             workorderRecord.setDuration(createWorkorderRecordDTO.getDuration());
             workorderRecord.setSalary(BigDecimal.valueOf(createWorkorderRecordDTO.getDuration()).multiply(salaryParam.getSalary()).divide(new BigDecimal(3600)));
         }
-
         //鎻掑叆宸ュ崟鎿嶄綔璁板綍锛屽苟涓斿垽鏂槸鍚︽洿鏀逛负宸ュ崟鐨勭姸鎬併�愮敓浜т腑銆�
         updateOrderInfo(loginUserInfo,workorder,Constants.WORKORDER_HISTORY_STATUS.produce);
         workorderRecordExtMapper.insert(workorderRecord);
diff --git a/server/src/main/resources/mappers/PlansExtMapper.xml b/server/src/main/resources/mappers/PlansExtMapper.xml
index 588478d..3556f9a 100644
--- a/server/src/main/resources/mappers/PlansExtMapper.xml
+++ b/server/src/main/resources/mappers/PlansExtMapper.xml
@@ -123,7 +123,7 @@
   <select id="selectByModel" parameterType="doumeemes.dao.ext.dto.QueryPlansExtDTO" resultMap="PlansExtListVO">
   SELECT
   `a`.*
-    ,(  SELECT sum( b.PLAN_NUM ) FROM  workorder b  WHERE b.deleted = 0 AND b.PLAN_ID = a.id and b.status !=6) AS workorderDistributNum
+    ,ifnull((  SELECT sum( b.PLAN_NUM ) FROM  workorder b  WHERE b.deleted = 0 AND b.PLAN_ID = a.id and b.status not in (7,8) ),0) AS workorderDistributNum
     from plans a
     <where>
     <if test="id != null">
@@ -363,13 +363,13 @@
       `usermodel`.`SYSTEMID` AS USERMODEL_SYSTEMID,
       `usermodel`.`INVALID_TIME` AS USERMODEL_INVALID_TIME,
       `usermodel`.`TYPE` AS USERMODEL_TYPE
-    ,(  SELECT sum( b.PLAN_NUM ) FROM  workorder b  WHERE b.deleted = 0 AND b.PLAN_ID = a.id  and b.status !=6) AS workorderDistributNum ,
+    , ifnull((  SELECT sum( b.PLAN_NUM ) FROM  workorder b  WHERE b.deleted = 0  AND b.PLAN_ID = a.id  and b.status !=6),0) AS workorderDistributNum ,
     `mmodel`.name as materialName , `mmodel`.code as materialCode ,`fmodel`.name as factoryName , `pmodel`.name as produceName ,
       concat(`usermodel`.realname,' ',`usermodel`.mobile) as planUserName , `umodel`.name as unitName ,
       w.PLAN_CODE as workPlanCode , w.SALESORDER as salesOrder ,
       w.START_DATE as workPlanStartDate  , w.PLAN_DATE as workPlanEndDate,
+      w.`PLAN_DATE` as workPlanPlanDate,
       ifnull((select  sum(worder.PLAN_NUM) from workorder worder where worder.PLAN_ID = a.id and worder.STATUS not in (7,8)  ),0) as produceNum
-
     FROM `plans` `a`
     LEFT JOIN `department` `dmodel` ON a.DEPART_ID=dmodel.ID
     LEFT JOIN `material_distribute` `mdmodel` ON a.MATERIAL_ID=mdmodel.ID
@@ -422,6 +422,12 @@
       </if>
       <if test="planDate != null">
         AND `a`.`PLAN_DATE` = #{planDate}
+      </if>
+      <if test="planDateStartDate != null and planDateStartDate != ''">
+        AND `a`.`PLAN_DATE` >= concat(#{planDateStartDate},' 00:00:00')
+      </if>
+      <if test="planDateEndDate != null and planDateEndDate != ''">
+        AND concat(#{planDateEndDate},' 23:59:59') >= `a`.`PLAN_DATE`
       </if>
       <if test="materialId != null">
         AND `a`.`MATERIAL_ID` = #{materialId}
@@ -765,12 +771,12 @@
       <if test="usermodelInvalidTime != null">
         AND `usermodel`.`INVALID_TIME` = #{usermodelInvalidTime}
       </if>
-      <if test="startDate != null">
-        AND `a`.`PLAN_DATE` >= #{startDate}
-      </if>
-      <if test="endDate != null">
-        AND   #{endDate} >= `a`.`PLAN_DATE`
-      </if>
+<!--      <if test="startDate != null">-->
+<!--        AND `a`.`PLAN_DATE` >= #{startDate}-->
+<!--      </if>-->
+<!--      <if test="endDate != null">-->
+<!--        AND   #{endDate} >= `a`.`PLAN_DATE`-->
+<!--      </if>-->
       <if test="mixParam != null and mixParam!=''">
         AND  (mmodel.name like concat('%',#{mixParam},'%') or mmodel.code like concat('%',#{mixParam},'%') or pmodel.name like concat('%',#{mixParam},'%'))
       </if>
diff --git a/server/src/main/resources/mappers/SalaryParamMapper.xml b/server/src/main/resources/mappers/SalaryParamMapper.xml
index e97d95f..34d04dd 100644
--- a/server/src/main/resources/mappers/SalaryParamMapper.xml
+++ b/server/src/main/resources/mappers/SalaryParamMapper.xml
@@ -13,14 +13,16 @@
         from
             salary_param sp
         LEFT JOIN procedures p on p.ID = sp.PROCEDURE_ID
-        LEFT JOIN material m on m.ID = sp.MATERIAL_ID
+        LEFT JOIN material_distribute md on md.ID = sp.MATERIAL_ID
+        LEFT JOIN material m on m.ID = md.MATERIAL_ID
         LEFT JOIN `system_user` su  on su.ID = sp.CREATE_USER
         where
         sp.DELETED = 0
         <if test="model.keyWord != null and model.keyWord != ''">
-           and  ( p`NAME` like concat('%',#{model.keyWord},'%')
-            or   p.`CODE` = #{model.keyWord})</if>
+           and  ( m.`NAME` like concat('%',#{model.keyWord},'%')
+            or   m.`CODE` = #{model.keyWord})</if>
         <if test="model.procedureName != null and model.procedureName != ''"> and p.`NAME` like concat('%',#{model.procedureName},'%')</if>
         <if test="model.type != null"> and sp.`TYPE` = #{model.type}</if>
+        order by sp.CREATE_TIME desc
     </select>
 </mapper>
diff --git a/server/src/main/resources/mappers/UserDeviceExtMapper.xml b/server/src/main/resources/mappers/UserDeviceExtMapper.xml
index 7259c9f..6b93738 100644
--- a/server/src/main/resources/mappers/UserDeviceExtMapper.xml
+++ b/server/src/main/resources/mappers/UserDeviceExtMapper.xml
@@ -201,7 +201,7 @@
         AND `umodel`.`ROOT_DEPART_ID` = #{umodelRootDepartId}
       </if>
       <if test="umodelName != null and umodelName != ''">
-        AND `umodel`.`NAME` = #{umodelName}
+        AND `umodel`.`NAME` like concat('%', #{umodelName} , '%')
       </if>
       <if test="umodelPhone != null and umodelPhone != ''">
         AND `umodel`.`PHONE` = #{umodelPhone}
diff --git a/server/src/main/resources/mappers/WorkPlansExtMapper.xml b/server/src/main/resources/mappers/WorkPlansExtMapper.xml
index 5ff0a6b..82f864a 100644
--- a/server/src/main/resources/mappers/WorkPlansExtMapper.xml
+++ b/server/src/main/resources/mappers/WorkPlansExtMapper.xml
@@ -156,10 +156,10 @@
         AND `a`.`SALESORDER` like concat('%',#{salesorder},'%')
       </if>
       <if test="startDateStart != null and startDateStart != ''">
-        AND `a`.`START_DATE` >= concat(#{planDateStart},' 00:00:00')
+        AND `a`.`START_DATE` >= concat(#{startDateStart},' 00:00:00')
       </if>
       <if test="startDateEnd != null and startDateEnd != ''">
-        AND concat(#{planDateEnd},' 23:59:59') >= `a`.`START_DATE`
+        AND concat(#{startDateEnd},' 23:59:59') >= `a`.`START_DATE`
       </if>
       <if test="planDateStart != null and planDateStart != ''">
         AND `a`.`PLAN_DATE` >= concat(#{planDateStart},' 00:00:00')
@@ -168,7 +168,7 @@
         AND concat(#{planDateEnd},' 23:59:59') >= `a`.`PLAN_DATE`
       </if>
     </where>
-        order by a.PLAN_DATE desc, a.CREATE_TIME  desc
+        order by a.START_DATE desc, a.CREATE_TIME  desc
   </select>
 
 
diff --git a/server/src/main/resources/mappers/WorkorderRecordExtMapper.xml b/server/src/main/resources/mappers/WorkorderRecordExtMapper.xml
index c8fb3d7..edb56c3 100644
--- a/server/src/main/resources/mappers/WorkorderRecordExtMapper.xml
+++ b/server/src/main/resources/mappers/WorkorderRecordExtMapper.xml
@@ -453,11 +453,11 @@
     <if test="materialName != null and materialName !=''">
       AND  (c.`name` like concat('%', #{materialName},'%') or c.`code` like concat('%', #{materialName},'%'))
     </if>
-    <if test="startDate != null">
-      AND  a.`CREATE_TIME` >= #{startDate}
+    <if test="startDate != null and startDate != ''">
+      AND  a.`CREATE_TIME` >= concat(#{startDate},' 00:00:00')
     </if>
-    <if test="endDate != null">
-      AND   #{endDate} >= a.`CREATE_TIME`
+    <if test="endDate != null and endDate != ''">
+      AND   concat(#{endDate},' 23:59:59') >= a.`CREATE_TIME`
     </if>
     <if test="userId != null">
       AND  a.`CREATE_USER` = #{userId}
@@ -479,10 +479,10 @@
       AND  `CREATE_USER` = #{userId}
     </if>
     <if test="startDate != null">
-      AND  a.`CREATE_TIME` >= #{startDate}
+      AND  `CREATE_TIME` >= #{startDate}
     </if>
     <if test="endDate != null">
-      AND   #{endDate} >= a.`CREATE_TIME`
+      AND   #{endDate} >= `CREATE_TIME`
     </if>
     group by  `CREATE_USER`
    <!-- order by `CREATE_TIME` desc-->

--
Gitblit v1.9.3