From e099ac31d888dcaa5c34f129b3a141e984fbce52 Mon Sep 17 00:00:00 2001
From: zhanghl <253316343@qq.com>
Date: 星期三, 16 四月 2025 13:41:09 +0800
Subject: [PATCH] 报表调整

---
 src/api/mainPlan/plateProcessStat.js          |   43 +++++++
 src/views/mainPlan/plateProcessStat/index.vue |  251 +++++++++++++++++++++++++++++++++++++++++
 src/views/mainPlan/weldSeam/index.vue         |   16 +-
 3 files changed, 302 insertions(+), 8 deletions(-)

diff --git a/src/api/mainPlan/plateProcessStat.js b/src/api/mainPlan/plateProcessStat.js
new file mode 100644
index 0000000..b725d59
--- /dev/null
+++ b/src/api/mainPlan/plateProcessStat.js
@@ -0,0 +1,43 @@
+import request from '@/utils/request'
+
+// 鏌ヨ閽i噾缁熻鍒楄〃
+export function listPlateStat(query) {
+  return request({
+    url: '/aps/plateProcessStat/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 鏌ヨ閽i噾缁熻璇︾粏
+export function getPlateStat(id) {
+  return request({
+    url: '/aps/plateProcessStat/' + id,
+    method: 'get'
+  })
+}
+
+// 鏂板閽i噾缁熻
+export function addPlateStat(data) {
+  return request({
+    url: '/aps/plateProcessStat/',
+    method: 'post',
+    data: data
+  })
+}
+
+// 鍒犻櫎閽i噾缁熻
+export function delStat(id) {
+  return request({
+    url: '/aps/plateProcessStat/' + id,
+    method: 'delete'
+  })
+}
+
+export function updateStat(data) {
+  return request({
+    url: '/aps/plateProcessStat/update',
+    method: 'post',
+    data: data
+  })
+}
diff --git a/src/views/mainPlan/plateProcessStat/index.vue b/src/views/mainPlan/plateProcessStat/index.vue
new file mode 100644
index 0000000..9ca9b9f
--- /dev/null
+++ b/src/views/mainPlan/plateProcessStat/index.vue
@@ -0,0 +1,251 @@
+<template>
+  <div class="app-container">
+    <el-row :gutter="20"> <el-col>
+    <el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="90px">
+      <el-row :gutter="20">
+        <el-col :span="6">
+
+      <el-form-item label="鎺掑簭" prop="num">
+        <el-input
+          v-model="queryParams.workOrderNo"
+          placeholder="璇疯緭鍏ラ挘閲戣鍒掑伐鍗曞彿"
+          clearable
+          @keyup.enter="handleQuery"
+        />
+      </el-form-item> </el-col>
+          <el-col  :span="24"  style="text-align: right;">
+      <el-form-item>
+        <el-button type="primary" icon="Search" @click="handleQuery">鎼滅储</el-button>
+        <el-button icon="Refresh" @click="resetQuery">閲嶇疆</el-button>
+      </el-form-item>
+        </el-col>
+      </el-row>
+    </el-form>
+    </el-col> </el-row>
+    <el-row :gutter="10" class="mb8">
+
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          plain
+          icon="Edit"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['aps_plate_process_stat:aps_plate_process_stat:edit']"
+        >鏇存柊缁熻琛�</el-button>
+      </el-col>
+
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          plain
+          icon="Download"
+          @click="handleExport"
+          v-hasPermi="['aps_plate_process_stat:aps_plate_process_stat:export']"
+        >瀵煎嚭</el-button>
+      </el-col>
+      <right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="aps_plate_process_statList" @selection-change="handleSelectionChange">
+      <el-table-column type="selection" width="55" align="center" />
+      <el-table-column label="宸ュ崟鍙�" align="center" prop="workOrderNo" />
+      <el-table-column label="宸ュ簭鍚嶇О" align="center" prop="processName" />
+      <el-table-column label="鎺掑簭" align="center" prop="num" />
+      <el-table-column label="宸ュ簭鍙�" align="center" prop="routeProcessNumber" />
+      <el-table-column label="褰撳墠宸ュ簭鍙�" align="center" prop="currentProcessNumber" />
+      <el-table-column label="鐢熶骇鏁伴噺" align="center" prop="productionQuantity" />
+      <el-table-column label="鏍囧噯宸ユ椂" align="center" prop="standardTime" />
+      <el-table-column label="宸ュ簭鎬诲伐鏃�" align="center" prop="processTotalTime" />
+      <el-table-column label="璁″垝瀹屾垚鏃�" align="center" prop="processPlanEndDay" />
+      <el-table-column label="璁$畻瀹屾垚鏃�" align="center" prop="computePlanEndDay" />
+      <el-table-column label="璁捐宸ユ椂" align="center" prop="designTimes" />
+      <el-table-column label="鎵规鍙�" align="center" prop="batchNumber" />
+    </el-table>
+    
+
+
+    <!-- 娣诲姞鎴栦慨鏀归挘閲戠粺璁″璇濇 -->
+    <el-dialog :title="title" v-model="open" width="500px" append-to-body>
+      <el-form ref="aps_plate_process_statRef" :model="form" :rules="rules" label-width="80px">
+        <el-form-item label="鎺掑簭" prop="num">
+          <el-input v-model="form.num" placeholder="璇疯緭鍏ユ帓搴�" />
+        </el-form-item>
+        <el-form-item label="鐢熶骇鏁伴噺" prop="productionQuantity">
+          <el-input v-model="form.productionQuantity" placeholder="璇疯緭鍏ョ敓浜ф暟閲�" />
+        </el-form-item>
+        <el-form-item label="鏍囧噯宸ユ椂" prop="standardTime">
+          <el-input v-model="form.standardTime" placeholder="璇疯緭鍏ユ爣鍑嗗伐鏃�" />
+        </el-form-item>
+        <el-form-item label="宸ュ簭鎬诲伐鏃�" prop="processTotalTime">
+          <el-input v-model="form.processTotalTime" placeholder="璇疯緭鍏ュ伐搴忔�诲伐鏃�" />
+        </el-form-item>
+        <el-form-item label="璁捐宸ユ椂" prop="designTimes">
+          <el-input v-model="form.designTimes" placeholder="璇疯緭鍏ヨ璁″伐鏃�" />
+        </el-form-item>
+      </el-form>
+      <template #footer>
+        <div class="dialog-footer">
+          <el-button type="primary" @click="submitForm">纭� 瀹�</el-button>
+          <el-button @click="cancel">鍙� 娑�</el-button>
+        </div>
+      </template>
+    </el-dialog>
+  </div>
+</template>
+
+<script setup name="Aps_plate_process_stat">
+import { listPlateStat,updateStat } from "@/api/mainPlan/plateProcessStat";
+
+const { proxy } = getCurrentInstance();
+
+const aps_plate_process_statList = ref([]);
+const open = ref(false);
+const loading = ref(true);
+const showSearch = ref(true);
+const ids = ref([]);
+const single = ref(true);
+const multiple = ref(true);
+const total = ref(0);
+const title = ref("");
+
+const data = reactive({
+  form: {},
+  queryParams: {
+    pageNum: 1,
+    pageSize: 10,
+    workOrderNo: null,
+    processName: null,
+    num: null,
+    routeProcessNumber: null,
+    currentProcessNumber: null,
+    productionQuantity: null,
+    standardTime: null,
+    processTotalTime: null,
+    processPlanEndDay: null,
+    computePlanEndDay: null,
+    designTimes: null,
+    batchNumber: null,
+  },
+  rules: {
+  }
+});
+
+const { queryParams, form, rules } = toRefs(data);
+
+/** 鏌ヨ閽i噾缁熻鍒楄〃 */
+function getList() {
+  loading.value = true;
+  listPlateStat(queryParams.value).then(response => {
+    aps_plate_process_statList.value = response.rows;
+    total.value = response.total;
+    loading.value = false;
+  });
+}
+
+// 鍙栨秷鎸夐挳
+function cancel() {
+  open.value = false;
+  reset();
+}
+
+// 琛ㄥ崟閲嶇疆
+function reset() {
+  form.value = {
+    id: null,
+    workOrderNo: null,
+    processName: null,
+    num: null,
+    routeProcessNumber: null,
+    currentProcessNumber: null,
+    productionQuantity: null,
+    standardTime: null,
+    processTotalTime: null,
+    processPlanEndDay: null,
+    computePlanEndDay: null,
+    designTimes: null,
+    batchNumber: null,
+    createBy: null,
+    delFlag: null
+  };
+  proxy.resetForm("aps_plate_process_statRef");
+}
+
+/** 鎼滅储鎸夐挳鎿嶄綔 */
+function handleQuery() {
+  queryParams.value.pageNum = 1;
+  getList();
+}
+
+/** 閲嶇疆鎸夐挳鎿嶄綔 */
+function resetQuery() {
+  proxy.resetForm("queryRef");
+  handleQuery();
+}
+
+// 澶氶�夋閫変腑鏁版嵁
+function handleSelectionChange(selection) {
+  ids.value = selection.map(item => item.id);
+  single.value = selection.length != 1;
+  multiple.value = !selection.length;
+}
+
+/** 鏂板鎸夐挳鎿嶄綔 */
+function handleAdd() {
+  reset();
+  open.value = true;
+  title.value = "娣诲姞閽i噾缁熻";
+}
+
+/** 淇敼鎸夐挳鎿嶄綔 */
+function handleUpdate(row) {
+  reset();
+  const _id = row.id || ids.value
+  getAps_plate_process_stat(_id).then(response => {
+    form.value = response.data;
+    open.value = true;
+    title.value = "淇敼閽i噾缁熻";
+  });
+}
+
+/** 鎻愪氦鎸夐挳 */
+function submitForm() {
+  proxy.$refs["aps_plate_process_statRef"].validate(valid => {
+    if (valid) {
+      if (form.value.id != null) {
+        updateAps_plate_process_stat(form.value).then(response => {
+          proxy.$modal.msgSuccess("淇敼鎴愬姛");
+          open.value = false;
+          getList();
+        });
+      } else {
+        addAps_plate_process_stat(form.value).then(response => {
+          proxy.$modal.msgSuccess("鏂板鎴愬姛");
+          open.value = false;
+          getList();
+        });
+      }
+    }
+  });
+}
+
+/** 鍒犻櫎鎸夐挳鎿嶄綔 */
+function handleDelete(row) {
+  const _ids = row.id || ids.value;
+  proxy.$modal.confirm('鏄惁纭鍒犻櫎閽i噾缁熻缂栧彿涓�"' + _ids + '"鐨勬暟鎹」锛�').then(function() {
+    return delAps_plate_process_stat(_ids);
+  }).then(() => {
+    getList();
+    proxy.$modal.msgSuccess("鍒犻櫎鎴愬姛");
+  }).catch(() => {});
+}
+
+/** 瀵煎嚭鎸夐挳鎿嶄綔 */
+function handleExport() {
+  proxy.download('aps_plate_process_stat/aps_plate_process_stat/export', {
+    ...queryParams.value
+  }, `aps_plate_process_stat_${new Date().getTime()}.xlsx`)
+}
+
+getList();
+</script>
diff --git a/src/views/mainPlan/weldSeam/index.vue b/src/views/mainPlan/weldSeam/index.vue
index 38a3d5d..e852eff 100644
--- a/src/views/mainPlan/weldSeam/index.vue
+++ b/src/views/mainPlan/weldSeam/index.vue
@@ -283,7 +283,7 @@
   {
     title: '宸ュ崟绫诲瀷',
     field: 'workOrderType',
-    width: 100,
+    width: 80,
   },
   /* {
     title: '鍛ㄦ棩',
@@ -303,22 +303,22 @@
   {
     title: '鐗╂枡缂栫爜',
     field: 'materialCode',
-    width: 80,
+    width: 160,
   },
   {
     title: '瀹㈡埛鍥惧彿',
     field: 'customerDrawingNumber',
-    width: 150,
+    width: 100,
   },
   {
     title: '缁勭粐璐﹀彿',
     field: 'organizeNumber',
-    width: 150,
+    width: 200,
   },
   {
     title: '鐢熶骇鍩哄湴',
     field: 'productionBase',
-    width: 200,
+    width: 100,
   },
   {
     title: '鍒嗙被(姘旀煖/绠¤矾)',
@@ -378,17 +378,17 @@
   {
     title: '涓诲伐鍗曞彿',
     field: 'mainWorkOrderNo',
-    width: 100,
+    width: 180,
   },
   {
     title: '涓婄骇宸ュ崟鍙�',
     field: 'superiorWorkOrderNo',
-    width: 100,
+    width: 180,
   },
   {
     title: '宸ュ崟鍙�',
     field: 'workOrderNo',
-    width: 100,
+    width: 180,
   },
 ]);
 

--
Gitblit v1.9.3