Browse Source

超节损

tty 1 year ago
parent
commit
11a986ef17

+ 31 - 4
src/api/mes_api_gty/orderAccounting.js

@@ -68,11 +68,38 @@ export const getOrderYj = (params) => {
 }
 
 // 4.2考核设置-更新工单印件资料
+export const updateOrderYj = (params) => {
+  return service({
+    url: '/mes_server/order_super_loss/updateOrderYj',
+    method: 'get',
+    params
+  })
+}
 
 // 5.1修正工单实际投料-获取列表
-
+export const getOrderFeedList = (params) => {
+  return service({
+    url: '/mes_server/order_super_loss/getOrderFeedList',
+    method: 'get',
+    params
+  })
+}
 // 5.2更新工单实际投料
-
+export const updateOrderFeed = (data) => {
+  return service({
+    url: '/mes_server/order_super_loss/updateOrderFeed',
+    method: 'post',
+    data
+  })
+}
 // 6工单工序产量查核
-
-//
+export const getOrderProcessCount = (params) => {
+  return service({
+    url: '/mes_server/order_super_loss/getOrderProcessCount',
+    method: 'get',
+    params
+  })
+}
+// 7核检废品分布(工单核检单维护3.1)
+// 8流程单查询(工单核检单维护5.1,5.2)
+// 9工单质检废品统计(工单核检单维护8)

+ 7 - 18
src/view/performance/09-workOrderVerification/gongdanzhijianfeipintongji.vue → src/view/performance/09-workOrderVerification/componets/gongdanzhijianfeipintongji.vue

@@ -1,10 +1,10 @@
 <template>
   <el-dialog
-    :model-value="props.isShow"
+    :model-value="modelValue"
     title="核检废品日统计"
     fullscreen
     destroy-on-close
-    @close="handleExit"
+    :before-close="() => emits('update:modelValue', false )"
   >
     <el-container>
       <!-- 按钮部分 -->
@@ -18,7 +18,7 @@
         <el-button
           type="primary"
           size="large"
-          @click="handleExit"
+          @click="() => emits('update:modelValue', false )"
         >退出
         </el-button>
       </el-header>
@@ -44,7 +44,6 @@
         />
         <el-table
           ref="multipleTable"
-          width="100%"
           height="70vh"
           :data="tableData"
           row-key="ID"
@@ -91,8 +90,8 @@ export const getOrderWasteTotal = (params) => {
 <script setup>
 import { watch, ref, reactive, defineProps, defineEmits } from 'vue'
 
-const props = defineProps(['isShow', 'val'])
-const emits = defineEmits(['myClose'])
+const props = defineProps(['modelValue', 'val'])
+const emits = defineEmits(['update:modelValue'])
 
 const tableColumns = reactive([
   { label: '工单编号', prop: 'gdbh', width: '150' },
@@ -114,19 +113,10 @@ const tableColumns = reactive([
   { label: '数量', prop: 'fp_sl', width: '150' },
 ])
 const tableData = ref([])
-const input = ref('')
+const input = ref(props.val)
 const inputCpmc = ref('')
 const isLoading = ref(false)
 
-watch(props, (value, oldValue, onCleanup) => {
-  if (value.isShow === true) {
-    input.value = value.val
-  }
-})
-const handleExit = () => {
-  emits('myClose')
-}
-
 const handleExcel = () => {
 }
 
@@ -152,7 +142,6 @@ const handleSearch = async() => {
 <style scoped>
 
 :deep(.el-table td .cell) {
-  line-height: 30px !important;
+  line-height: 20px !important;
 }
-
 </style>

+ 5 - 9
src/view/performance/09-workOrderVerification/meirihejiantongji.vue → src/view/performance/09-workOrderVerification/componets/meirihejiantongji.vue

@@ -1,10 +1,10 @@
 <template>
   <el-dialog
-    :model-value="props.isShow"
+    :model-value="modelValue"
     title="核检废品日统计"
     fullscreen
     destroy-on-close
-    @close="handleExit"
+    :before-close="() => emits('update:modelValue', false )"
   >
     <el-container>
       <!-- 按钮部分 -->
@@ -18,7 +18,7 @@
         <el-button
           type="primary"
           size="large"
-          @click="handleExit"
+          @click="() => emits('update:modelValue', false )"
         >退出
         </el-button>
       </el-header>
@@ -90,8 +90,8 @@ const getDaysWast = (params) => {
 <script setup>
 import { ref, reactive, defineProps, defineEmits } from 'vue'
 
-const props = defineProps(['isShow'])
-const emits = defineEmits(['myClose'])
+const props = defineProps(['modelValue'])
+const emits = defineEmits(['update:modelValue'])
 
 const tableColumns = reactive([
   { label: '日期', prop: 'qczl_rq', width: '150' },
@@ -107,10 +107,6 @@ const tableData = reactive([])
 const date = ref()
 const isLoading = ref(false)
 
-const handleExit = () => {
-  emits('myClose')
-}
-
 const handleExcel = () => {
 }
 

+ 12 - 6
src/view/performance/09-workOrderVerification/shebeizhuangtai.vue → src/view/performance/09-workOrderVerification/componets/shebeizhuangtai.vue

@@ -1,5 +1,11 @@
 <template>
-  <div>
+  <el-dialog
+    :model-value="modelValue"
+    fullscreen
+    :title="props.title"
+    destroy-on-close
+    :before-close="() => emits('update:modelValue', false )"
+  >
     <el-row>
       <el-col :span="20">
         <el-row
@@ -100,15 +106,13 @@
         >生产</el-button><br>
       </el-col>
     </el-row>
-
-  </div>
+  </el-dialog>
 
 </template>
 <script>
 export default {
   name: 'Shebeizhuangtai',
 }
-
 // 机台数据详情
 import service from '@/utils/request'
 export const getMachineDetail = (params) => {
@@ -127,7 +131,10 @@ import { CanvasRenderer } from 'echarts/renderers'
 import { BarChart, LineChart, PieChart, ScatterChart } from 'echarts/charts'
 import { GridComponent, LegendComponent, TitleComponent, TooltipComponent } from 'echarts/components'
 import VChart, { THEME_KEY } from 'vue-echarts'
-import { provide, ref } from 'vue'
+import { defineEmits, defineProps, provide, ref } from 'vue'
+
+const props = defineProps(['modelValue', 'title'])
+const emits = defineEmits(['update:modelValue'])
 
 use([
   CanvasRenderer,
@@ -145,7 +152,6 @@ use([
 const activeBtn = ref(null)
 const handleBtnActive = (e) => {
   activeBtn.value = e.target.innerText
-  console.log(e.target.innerText)
 }
 
 const currentFrequency = ref('2023-01-02 08:30')

+ 19 - 19
src/view/performance/09-workOrderVerification/index.vue

@@ -35,7 +35,7 @@
               <el-button
                 type="primary"
                 :icon="Search"
-                @click="isShowMrhjtj = true"
+                @click="dialogMrhjtj = true"
               >每日核检统计
               </el-button>
 
@@ -395,27 +395,25 @@
             </el-table>
           </el-dialog>
 
-          <!-- 核验废品日统计弹出框 -->
+          <!-- 废品日统计 -->
           <Meirihejiantongji
-            :is-show="isShowMrhjtj"
-            @my-close="isShowMrhjtj = false"
+            v-if="dialogMrhjtj"
+            v-model="dialogMrhjtj"
           />
 
           <!-- 工单质检废品统计 -->
           <Gongdanzhijianfeipintongji
-            :is-show="isShowGdzjfptj"
+            v-if="dialogGdzjfptj"
+            v-model="dialogGdzjfptj"
             :val="value1"
-            @my-close="isShowGdzjfptj =false"
           />
 
           <!-- 测试图表 -->
-          <el-dialog
-            title="【01.24 08:30】【JY01#--海德堡对开八色平版胶印机(JY08-01)】【2311116-->钻石(荷花)盒包装纸】【01--胶印】"
-            destroy-on-close
-            fullscreen
-          >
-            <Shebeizhuangtai />
-          </el-dialog>
+          <Shebeizhuangtai
+            v-if="dialogSbyxgl"
+            v-model="dialogSbyxgl"
+            title="【01.30 08:30】【JY01#--海德堡对开八色平版胶印机(JY08-01)】【2311116-->钻石(荷花)盒包装纸】【01--胶印】"
+          />
 
         </el-main>
       </el-container>
@@ -439,9 +437,9 @@ import { ElMessage } from 'element-plus'
 import { Search, Refresh, Download } from '@element-plus/icons-vue'
 import { ref, reactive } from 'vue'
 import { getSide, getTable, getOneWorkOrder, getOrderInfo, getGxAndLeader, getWastInfo, updateData } from '@/api/mes_api_gty/workOrderVerification'
-import Meirihejiantongji from './meirihejiantongji.vue'
-import Gongdanzhijianfeipintongji from './gongdanzhijianfeipintongji.vue'
-import Shebeizhuangtai from '@/view/performance/09-workOrderVerification/shebeizhuangtai.vue'
+import Meirihejiantongji from './componets/meirihejiantongji.vue'
+import Gongdanzhijianfeipintongji from './componets/gongdanzhijianfeipintongji.vue'
+import Shebeizhuangtai from '@/view/performance/09-workOrderVerification/componets/shebeizhuangtai.vue'
 
 defineOptions({
   name: '06PackingDocuments'
@@ -832,17 +830,19 @@ const closeDialog = () => {
 // 导出excel
 function exportExcel() {
   console.log('导出到excel')
+  dialogSbyxgl.value = true
 }
 
-const isShowMrhjtj = ref(false)
-const isShowGdzjfptj = ref(false)
+const dialogMrhjtj = ref(false)
+const dialogGdzjfptj = ref(false)
+const dialogSbyxgl = ref(false)
 const value1 = ref('')
 const table = ref(null)
 const currentRow = ref()
 
 const showGdzjfptj = () => {
   value1.value = currentRow.value?.qczl_gdbh
-  isShowGdzjfptj.value = true
+  dialogGdzjfptj.value = true
 }
 
 const handleSelectChange = (row, column, event) => {

+ 166 - 0
src/view/performance/12-orderAccounting/componets/detail.vue

@@ -0,0 +1,166 @@
+<template>
+  <el-dialog
+    :model-value="modelValue"
+    title="产品工艺流程"
+    destroy-on-close
+    :before-close="()=>{emits('update:modelValue', false )}"
+    style="width: 80vw; height: 80vh"
+  >
+    <el-form
+      inline
+      label-position="left"
+    >
+      <el-form-item
+        label="工单编号"
+      >
+        <el-input
+          v-model="input"
+          style="width: 120px;"
+          @keyup.enter="handleShowDetail"
+        />
+      </el-form-item>
+
+      <el-table
+        :data="detailData"
+        border
+        height="50vh"
+        :row-style="{ height: '20px' }"
+        :cell-style="{ padding: '0px' }"
+        :header-row-style="{ height: '20px' }"
+        :header-cell-style="{ padding: '0px' }"
+      >
+        <el-table-column
+          label="印件及工序"
+          width="100"
+          prop="Gy0_yjno"
+        />
+
+        <el-table-column
+          label="工序名称"
+          width="300"
+          prop="Gy0_gxmc"
+        />
+
+        <el-table-column
+          label="基础损耗"
+          width="100"
+          prop="Gy0_rate0"
+        />
+
+        <el-table-column
+          label="损耗率"
+          width="100"
+          prop="Gy0_rate1"
+        />
+
+        <el-table-column
+          label="损耗系数"
+          width="100"
+          prop="损耗系数"
+        />
+        <el-table-column
+          label="无形损减免比例"
+          width="150"
+        >
+          <template #default="{ row }">
+            <el-input v-model="row['loss_one']" />
+          </template>
+        </el-table-column>
+        <el-table-column
+          label="超节损承担比例"
+          width="150"
+        >
+          <template #default="{ row }">
+            <el-input v-model="row['loss_two']" />
+          </template>
+        </el-table-column>
+        <el-table-column
+          label="超节损核算单价"
+          width="150"
+        >
+          <template #default="{ row }">
+            <el-input v-model="row['loss_thr']" />
+          </template>
+        </el-table-column>
+
+      </el-table>
+
+    </el-form>
+
+    <template #footer>
+      <div class="dialog-footer">
+        <el-button @click="()=>{emits('update:modelValue', false )}">取 消</el-button>
+        <el-button
+          type="primary"
+          @click="handleUpdateDatail"
+        >更 新
+        </el-button>
+      </div>
+    </template>
+  </el-dialog>
+</template>
+
+<script>
+export default {
+  name: 'Detail',
+}
+import service from '@/utils/request'
+// 3.1查改-获取工单工艺流程
+const getOrderGy = (params) => {
+  return service({
+    url: '/mes_server/order_super_loss/getOrderGy',
+    method: 'get',
+    params
+  })
+}
+
+// 3.2查改-更新产品工艺资料
+const updateOrderGy = (data) => {
+  return service({
+    url: '/mes_server/order_super_loss/updateOrderGy',
+    method: 'post',
+    data
+  })
+}
+
+</script>
+<script setup>
+
+import { defineEmits, defineProps, ref } from 'vue'
+import { ElMessage } from 'element-plus'
+
+const props = defineProps(['modelValue', 'gdbh'])
+const emits = defineEmits(['update:modelValue'])
+const detailData = ref([])
+const input = ref(props['gdbh'])
+
+const handleShowDetail = async() => {
+  const res = await getOrderGy({ order: input.value })
+  if (res['code'] === 0) {
+    const { data } = res
+    detailData.value = data.map(item => ({
+      ...item,
+      Gy0_yjno: item['Gy0_yjno'] + '-' + item['Gy0_gxh'],
+    }))
+  }
+}
+const handleUpdateDatail = async() => {
+  const val = detailData.value.map(item => ({
+    UniqId: item['UniqId'],
+    loss_one: item['loss_one'],
+    loss_two: item['loss_two'],
+    loss_thr: item['loss_thr'],
+  }))
+  const res = await updateOrderGy(val)
+  if (res['code'] === 0) {
+    ElMessage({
+      type: 'success',
+      message: '更新成功',
+    })
+  }
+}
+
+</script>
+
+<style scoped>
+</style>

+ 4 - 6
src/view/performance/12-orderAccounting/gdcjstj.vue → src/view/performance/12-orderAccounting/componets/gdcjstj.vue

@@ -1,5 +1,6 @@
 <template>
-  <div>
+  <div style="width: 30vw; height: 50vh">
+    <el-input v-model="input" />
     <el-button
       @click="handlePrint"
     >打印测试
@@ -746,10 +747,7 @@ const jsonData = {
   }],
 }
 const props = defineProps(['gdbh'])
-console.log(props)
-watch(props, (value, oldValue, onCleanup) => {
-  console.log(value)
-})
+const input = ref(props?.['gdbh'])
 
 // 引入后使用示例
 hiprint.init()
@@ -759,7 +757,7 @@ const hiprintTemplate = new hiprint.PrintTemplate({ template: jsonData })
 
 const handlePrint = async() => {
   const params = {
-    order: '2310720',
+    order: input.value,
     type: '1',
   }
   const res = await getOrderSuperLossCount(params)

+ 167 - 0
src/view/performance/12-orderAccounting/componets/gxclhc.vue

@@ -0,0 +1,167 @@
+<template>
+  <el-dialog
+    :model-value="modelValue"
+    title="工序产量核查"
+    fullscreen
+    :before-close="()=>{emits('update:modelValue', false )}"
+  >
+    <el-button
+      type="primary"
+      style="width:80px; height: 40px;margin-bottom: 20px"
+      @click="emits('update:modelValue', false )"
+    >退出</el-button>
+
+    <el-form inline>
+      <el-form-item label="工单编号">
+        <el-input
+          v-model="input"
+          style="width: 100px"
+          @keyup.enter="handleGetTable"
+        />
+        <el-input
+          v-model="cpmc"
+          class="cpmc"
+          readonly
+          style="width: 400px;margin-left: 3px"
+        />
+      </el-form-item>
+
+      <el-table
+        :data="tableData"
+        border
+        highlight-current-row
+        show-overflow-tooltip
+        height="70vh"
+        :row-style="{ height: '20px' }"
+        :cell-style="{ padding: '0px' }"
+        :header-row-style="{ height: '20px' }"
+        :header-cell-style="{ padding: '0px' }"
+      >
+        <el-table-column
+          label="印件及工序名称"
+          width="250"
+          prop="Gy0_yjno"
+        />
+
+        <el-table-column
+          label="工序计划产量"
+          width="120"
+          prop="Gy0_计划接货数"
+        />
+
+        <el-table-column
+          label="联数"
+          width="80"
+          prop="Gy0_ls"
+        />
+
+        <el-table-column
+          label="折算车头产量"
+          width="120"
+          prop=""
+        />
+
+        <el-table-column
+          label="实际上报产量"
+          width="120"
+          prop="Gy0_ls"
+        />
+        <el-table-column
+          label="制程废品"
+          width="120"
+          prop=""
+        />
+        <el-table-column
+          label="制程废品率"
+          width="120"
+          prop="制程废品率"
+        />
+        <el-table-column
+          label="来料异常"
+          width="120"
+          prop="来料异常"
+        />
+        <el-table-column
+          label="流程单数"
+          width="120"
+          prop="process_num"
+        />
+        <el-table-column
+          label="当前设备"
+          width="120"
+          prop="Gy0_sbbh"
+        />
+        <el-table-column
+          label="工序状态"
+          width="120"
+          prop="PD_WG"
+        />
+        <el-table-column
+          label="首板生产日期"
+          width="120"
+          prop="sczl_rq"
+        />
+
+      </el-table>
+
+    </el-form>
+  </el-dialog>
+
+</template>
+
+<script>
+export default {
+  name: 'Gxclhc',
+}
+
+// 4.1考核设置-获取工单印件资料
+import service from '@/utils/request'
+const getOrderProcessCount = (params) => {
+  return service({
+    url: '/mes_server/order_super_loss/getOrderProcessCount',
+    method: 'get',
+    params
+  })
+}
+
+const getGxMc = (params) => {
+  return service({
+    url: '/mes_server/packaging_count_document/getGxMc',
+    method: 'get',
+    params
+  })
+}
+
+</script>
+
+<script setup>
+import { watch, ref, reactive, defineProps, defineEmits, onBeforeUnmount } from 'vue'
+
+const props = defineProps(['modelValue', 'gdbh'])
+const emits = defineEmits(['update:modelValue'])
+const input = ref(props.gdbh)
+const cpmc = ref('')
+const tableData = ref([])
+const handleGetTable = async() => {
+  const ret = await getGxMc({ gdbh: input.value })
+  if (ret['code'] === 0) {
+    cpmc.value = ret['data'][0]['Gd_cpmc']
+    console.log(ret['data'])
+  }
+  const res = await getOrderProcessCount({ order: input.value })
+  if (res['code'] === 0) {
+    const { data } = res
+    tableData.value = data.map(item => ({
+      ...item,
+      Gy0_yjno: `${item['Gy0_yjno']}-${item['Gy0_gxh']} ${item['Gy0_gxmc']} ${item['Add_gxmc']}`,
+    }))
+  }
+}
+handleGetTable()
+</script>
+
+<style scoped>
+:deep(.cpmc .el-input__inner) {
+  color: red !important;
+}
+</style>

+ 138 - 0
src/view/performance/12-orderAccounting/componets/khsz.vue

@@ -0,0 +1,138 @@
+<template>
+  <el-dialog
+    :model-value="modelValue"
+    title="修正工单印件质量考核设置"
+    fullscreen
+    :before-close="()=>{emits('update:modelValue', false )}"
+  >
+    <el-button
+      type="primary"
+      disabled
+      style="width:80px; height: 40px;margin-bottom: 20px"
+      @click=""
+    >更新</el-button>
+    <el-button
+      type="primary"
+      style="width:80px; height: 40px;margin-bottom: 20px"
+      @click="emits('update:modelValue', false )"
+    >退出</el-button>
+
+    <el-form inline>
+      <el-form-item label="工单编号">
+        <el-input
+          v-model="input"
+          autocomplete="off"
+          style="width: 100px"
+          @keyup.enter="handleGetTable"
+        />
+      </el-form-item>
+
+      <el-table
+        :data="tableData"
+        border
+        height="70vh"
+        :row-style="{ height: '20px' }"
+        :cell-style="{ padding: '0px' }"
+        :header-row-style="{ height: '20px' }"
+        :header-cell-style="{ padding: '0px' }"
+      >
+        <el-table-column
+          label="工单编号"
+          width="100"
+          prop="Yj_gdbh"
+        />
+
+        <el-table-column
+          label="印件编码"
+          width="100"
+          prop="yj_Yjdh"
+        />
+
+        <el-table-column
+          label="印件号"
+          width="100"
+          prop="yj_Yjno"
+        />
+
+        <el-table-column
+          label="印件名称"
+          width="400"
+          prop="yj_yjmc"
+        />
+
+        <el-table-column
+          label="当前考核设置"
+          width="150"
+          prop="当前考核设置"
+        />
+        <el-table-column
+          label="新考核设置"
+          width="150"
+        >
+
+          <template #default="{ row }">
+            <!-- 使用 el-select 来创建选择框 -->
+            <el-select
+              v-model="row.新考核设置"
+              placeholder="请选择"
+            >
+              <el-option
+                label="参与"
+                value="参与"
+              />
+              <el-option
+                label="剔除"
+                value="剔除"
+              />
+            </el-select>
+          </template>
+
+        </el-table-column>
+
+      </el-table>
+
+    </el-form>
+  </el-dialog>
+
+</template>
+
+<script>
+export default {
+  name: 'Khsz',
+}
+
+// 4.1考核设置-获取工单印件资料
+import service from '@/utils/request'
+export const getOrderYj = (params) => {
+  return service({
+    url: '/mes_server/order_super_loss/getOrderYj',
+    method: 'get',
+    params
+  })
+}
+
+</script>
+
+<script setup>
+import { watch, ref, reactive, defineProps, defineEmits, onBeforeUnmount } from 'vue'
+
+const props = defineProps(['modelValue', 'gdbh'])
+const emits = defineEmits(['update:modelValue'])
+const input = ref(props.gdbh)
+const tableData = ref([])
+const handleGetTable = async() => {
+  const res = await getOrderYj({ order: input.value })
+  if (res['code'] === 0) {
+    const { data } = res
+    data['当前考核设置'] = data['质量考核'] === 0 ? '参与' : '剔除'
+    data['新考核设置'] = data['当前考核设置']
+    const arr = [data]
+    console.log(arr)
+    tableData.value = arr
+  }
+}
+</script>
+
+<style scoped>
+
+</style>

+ 199 - 0
src/view/performance/12-orderAccounting/componets/xzgdtl.vue

@@ -0,0 +1,199 @@
+<template>
+  <el-dialog
+    :model-value="modelValue"
+    :title="`修正工单实际投料(${props?.['date']})`"
+    fullscreen
+    :before-close="()=>{emits('update:modelValue', false )}"
+  >
+    <el-button
+      type="primary"
+      disabled
+      style="width:80px; height: 40px;margin-bottom: 20px"
+    >更新</el-button>
+
+    <el-button
+      type="primary"
+      style="width:80px; height: 40px;margin-bottom: 20px"
+      @click="handleSearch"
+    >定位</el-button>
+
+    <el-button
+      type="primary"
+      style="width:80px; height: 40px;margin-bottom: 20px"
+      @click="emits('update:modelValue', false )"
+    >退出</el-button>
+
+    <el-table
+      ref="table"
+      highlight-current-row
+      show-overflow-tooltip
+      border
+      :data="tableData"
+      :row-style="{ height: '25px' }"
+      :cell-style="{ padding: '0px' }"
+      :header-row-style="{ height: '20px' }"
+      :header-cell-style="{ padding: '0px' }"
+      style="width: 100%;height: 75vh;"
+      @selection-change="handleSelectionChange"
+    >
+      <el-table-column
+        type="selection"
+        width="55"
+      />
+      <el-table-column
+        label="工单编号"
+        prop="Gd_gdbh"
+        width="100"
+      />
+      <el-table-column
+        label="印件号"
+        prop="yj_Yjno"
+        width="100"
+      />
+      <el-table-column
+        label="印件代号"
+        prop="yj_yjdh"
+        width="100"
+      />
+      <el-table-column
+        label="开数*联数"
+        prop=""
+        width="120"
+      />
+      <el-table-column
+        label="物料代码"
+        prop="yj_zzdh"
+        width="100"
+      />
+      <el-table-column
+        label="物料名称"
+        prop="BOM_物料名称"
+        width="250"
+      />
+      <el-table-column
+        label="规格"
+        prop="yj_tlgg"
+        width="100"
+      />
+      <el-table-column
+        label="领用单位"
+        prop=""
+        width="100"
+      />
+      <el-table-column
+        label="订单数量(万张)"
+        prop="订单数量"
+        width="150"
+      />
+      <el-table-column
+        label="当前投料"
+        prop="yj_平张投料"
+        width="100"
+      />
+      <el-table-column
+        label="实际用量"
+        prop=""
+        width="100"
+      />
+      <el-table-column
+        label="换算率"
+        prop=""
+        width="100"
+      />
+      <el-table-column
+        label="折算投料(万张)"
+        prop=""
+        width="150"
+      />
+      <el-table-column
+        label="投料确认"
+        prop="投料确认"
+        width="200"
+      />
+
+    </el-table>
+
+  </el-dialog>
+
+</template>
+
+<script>
+export default {
+  name: 'Xzgdtl',
+}
+// 5.1修正工单实际投料-获取列表
+import service from '@/utils/request'
+
+const getOrderFeedList = (params) => {
+  return service({
+    url: '/mes_server/order_super_loss/getOrderFeedList',
+    method: 'get',
+    params
+  })
+}
+</script>
+
+<script setup>
+import { ElMessage, ElMessageBox } from 'element-plus'
+import { watch, ref, reactive, defineProps, defineEmits, onBeforeUnmount } from 'vue'
+
+const props = defineProps(['modelValue', 'date'])
+const emits = defineEmits(['update:modelValue'])
+const tableData = ref([])
+const table = ref(null)
+const multipleSelection = ref([])
+const getTable = async() => {
+  let params
+  if (props?.['date']) {
+    const { date } = props
+    params = {
+      year: date.slice(0, 4),
+      month: date.slice(4, 6),
+    }
+  } else {
+    return
+  }
+  const res = await getOrderFeedList(params)
+  if (res['code'] === 0) {
+    const { data } = res
+    tableData.value = data
+  }
+}
+getTable()
+
+const handleSelectionChange = (val) => {
+  multipleSelection.value = val
+}
+
+const handleSearch = () => {
+  ElMessageBox.prompt('输入工单编号', '定位', {
+    confirmButtonText: '确认',
+    cancelButtonText: '取消',
+  })
+    .then(({ value }) => {
+      console.log(value)
+      if (!value) {
+        getTable()
+      } else {
+        tableData.value = tableData.value.filter(item => {
+          return item['Gd_gdbh'] === value ?? item
+        })
+      }
+      ElMessage({
+        type: 'success',
+        message: '定位',
+      })
+    })
+    .catch(() => {
+      ElMessage({
+        type: 'info',
+        message: '取消',
+      })
+    })
+}
+
+</script>
+
+<style scoped>
+
+</style>

+ 129 - 29
src/view/performance/12-orderAccounting/index.vue

@@ -20,13 +20,15 @@
                 type="primary"
                 icon="search"
                 class="search"
+                @click="handleSearch"
               />
               <el-button
                 type="primary"
                 icon="edit"
                 class="bt"
-                @click="onStatusClick"
-              ><i class="el-icon-edit" />查改</el-button>
+                @click="() => {dialogDetail = true}"
+              ><i class="el-icon-edit" />查改
+              </el-button>
               <!--                <el-button type="primary" disabled icon="edit" @click="" style="margin-left: 10px">工艺方案复制</el-button>-->
               <el-button
                 type="primary"
@@ -36,18 +38,87 @@
               >工单超节损统计
               </el-button>
 
+              <el-button
+                type="primary"
+                icon="edit"
+                class="bt"
+                @click="()=>{dialogKhsz = true}"
+              >考核设置
+              </el-button>
+
+              <el-button
+                type="primary"
+                icon="edit"
+                class="bt"
+                @click="()=>{dialogXzgdtl = true}"
+              >修正工单投料
+              </el-button>
+
+              <el-button
+                type="primary"
+                icon="edit"
+                class="bt"
+                @click="()=>{dialogGxclhc = true}"
+              >工序产量核查
+              </el-button>
+
+              <el-button
+                type="primary"
+                icon="edit"
+                class="bt"
+                @click="()=>{dialogGdzjfptj = true}"
+              >工单质检废品统计
+              </el-button>
+
             </el-form-item>
           </el-form>
 
           <!--按钮弹窗部分-->
+
+          <!-- 查改 -->
+          <Detail
+            v-if="dialogDetail"
+            v-model="dialogDetail"
+            :gdbh="gdbh"
+          />
+
+          <!-- 工单超节损统计 -->
           <el-dialog
             v-model="dialogGdcjstj"
             title="工单超节损统计"
-            style="width: 20vw;height: 30vh"
+            destroy-on-close
           >
-            <Gdcjstj :gdbh="currentRow" />
+            <Gdcjstj :gdbh="gdbh" />
           </el-dialog>
 
+          <!-- 修正工单印件质量考核设置 -->
+          <Khsz
+            v-if="dialogKhsz"
+            v-model="dialogKhsz"
+            :gdbh="gdbh"
+          />
+
+          <!-- 修正工单投料 -->
+          <Xzgdtl
+            v-if="dialogXzgdtl"
+            v-model="dialogXzgdtl"
+            :date="date"
+          />
+
+          <!-- 工序产量核查 -->
+          <Gxclhc
+            v-if="dialogGxclhc"
+            v-model="dialogGxclhc"
+            :gdbh="gdbh"
+          />
+
+          <!-- 工单质检废品统计 -->
+          <Gongdanzhijianfeipintongji
+            v-if="dialogGdzjfptj"
+            v-model="dialogGdzjfptj"
+            :val="gdbh"
+          />
+
         </div>
       </layout-header>
 
@@ -119,7 +190,6 @@
             :cell-style="{ padding: '0px' }"
             :header-row-style="{ height: '20px' }"
             :header-cell-style="{ padding: '0px' }"
-            @row-dblclick="doubleClick"
           >
             <el-table-column
               type="selection"
@@ -134,28 +204,33 @@
               :width="column.width"
               show-overflow-tooltip="true"
             />
-
           </el-table>
-
         </layout-content>
-
       </layout>
     </layout>
   </div>
 </template>
 <script setup>
 // 全量引入格式化工具 请按需保留
-import { ElMessage, ElMessageBox } from 'element-plus'
-import { Layout, LayoutSider, LayoutContent, LayoutHeader } from '@arco-design/web-vue'
-import { ref, reactive } from 'vue'
-import { getSide, getTable, getOrderSuperLossGy } from '@/api/mes_api_gty/orderAccounting'
-import Gdcjstj from '@/view/performance/12-orderAccounting/gdcjstj.vue'
-
-defineOptions({ name: 'Company' })
+import { Layout, LayoutContent, LayoutHeader, LayoutSider } from '@arco-design/web-vue'
+import { ref, watch } from 'vue'
+import { getOrderGy, getOrderSuperLossGy, getSide, getTable, updateOrderGy } from '@/api/mes_api_gty/orderAccounting'
+import Gdcjstj from '@/view/performance/12-orderAccounting/componets/gdcjstj.vue'
+import Khsz from '@/view/performance/12-orderAccounting/componets/khsz.vue'
+import Xzgdtl from '@/view/performance/12-orderAccounting/componets/xzgdtl.vue'
+import Gxclhc from '@/view/performance/12-orderAccounting/componets/gxclhc.vue'
+import Gongdanzhijianfeipintongji
+  from '@/view/performance/09-workOrderVerification/componets/gongdanzhijianfeipintongji.vue'
+import Detail from '@/view/performance/12-orderAccounting/componets/detail.vue'
 
+// 弹窗
 const dialogGdcjstj = ref(false)
+const dialogDetail = ref(false)
+const dialogKhsz = ref(false)
+const dialogXzgdtl = ref(false)
+const dialogGxclhc = ref(false)
+const dialogGdzjfptj = ref(false)
 
-// =========== 左侧树侧形结构 ===========
 // 侧边栏数据
 const treeData = ref([])
 const getSideData = async() => {
@@ -172,7 +247,7 @@ const getSideData = async() => {
         children: value.map(item => ({
           label: `${item['客户编号']}【${item['客户名称']}】(工单数:${item.total})`,
           date: date,
-          code: item?.['客户编号']
+          code: item?.['客户编号'],
         })),
       }
       transformedData.push(transformedItem)
@@ -180,10 +255,9 @@ const getSideData = async() => {
     treeData.value = transformedData
   }
 }
-
 getSideData()
 
-// =========== 表格数据部分 ===========
+// 表格数据
 const tableCols1 = [
   { label: '超损工单', prop: '', width: '90' },
   { label: '工单编号', prop: 'Gd_gdbh', width: '100' },
@@ -227,17 +301,24 @@ const tableCols2 = [
 const tableData1 = ref([])
 const tableData2 = ref([])
 const currentRow = ref({})
+const gdbh = ref('')
+const date = ref('')
+const searchInfo = ref('')
+
+watch(currentRow, (value, oldValue, onCleanup) => {
+  gdbh.value = value?.['Gd_gdbh']
+  date.value = value?.['年月']
+})
 
 // 显示上方表格
 const handleNodeClick = async(node) => {
   if (node.children) {
-    console.log(node.date)
     const { date } = node
     const res = await getTable({ date, limit: 9999, page: 1 })
     tableData1.value = res.data.data
     console.log(res.data)
   } else {
-    console.log(node.date, node.code)
+    // console.log(node.date, node.code)
   }
 }
 
@@ -254,7 +335,14 @@ const showOrderSuperLossGy = async() => {
     }))
   }
 }
-
+// 定位
+const handleSearch = () => {
+  if (searchInfo.value) {
+    tableData1.value = tableData1.value.filter(item => {
+      return item['Gd_gdbh'] === searchInfo.value ?? item
+    })
+  }
+}
 const rowClassName = ({ row, rowIndex }) => {
 
 }
@@ -263,9 +351,11 @@ const rowClassName = ({ row, rowIndex }) => {
 :deep(.plan-usage-low div) {
   color: red !important;
 }
+
 .JKWTree-container {
   display: flex;
 }
+
 .JKWTree-tree {
   width: 300px;
   background-color: #fff;
@@ -273,23 +363,27 @@ const rowClassName = ({ row, rowIndex }) => {
   padding: 10px;
   margin-right: 20px;
 }
+
 .JKWTree-tree h3 {
   font-size: 15px;
   font-weight: 700;
   margin: 10px 0;
 }
+
 .JKWTree-content {
   flex: 1;
 }
+
 :deep(.el-table__body .warning-row) {
   background: #FFFF80 !important;
 }
+
 /* 选中某行时的背景色 */
 :deep(.el-table__body tr.current-row) > td {
   background: #ff80ff !important;
 }
 
-:deep(.el-table .bg-yellow){
+:deep(.el-table .bg-yellow) {
   background: yellow;
 }
 
@@ -298,25 +392,31 @@ const rowClassName = ({ row, rowIndex }) => {
 :deep(.el-table td .cell) {
   line-height: 20px !important;
 }
-:deep(.el-tabs__header){
+
+:deep(.el-tabs__header) {
   margin-bottom: 0;
 }
-.search{
+
+.search {
   margin-left: 0px !important;
   margin-right: 10px !important;
 }
-.bt{
+
+.bt {
   margin-left: 2px !important;
   padding: 3px !important;
   font-size: 12px;
 }
-.el-tabs__header{
+
+.el-tabs__header {
   margin: 0px !important;
 }
-.gva-table-box{
+
+.gva-table-box {
   padding: 0px !important;
 }
-.mab{
+
+.mab {
   margin-bottom: 5px;
 }
 </style>