From af1c9e588f1de0240390648f9bb56aa486870aff Mon Sep 17 00:00:00 2001
From: chengxiangling <291105840@qq.com>
Date: 星期五, 16 五月 2025 17:40:18 +0800
Subject: [PATCH] 提交高度修改;
---
src/views/mainPlan/sheetMetalOrderManage/index.vue | 340 ++++++++++++++++++++++++++++++++++++--------------------
1 files changed, 216 insertions(+), 124 deletions(-)
diff --git a/src/views/mainPlan/sheetMetalOrderManage/index.vue b/src/views/mainPlan/sheetMetalOrderManage/index.vue
index ddd90c4..8a5e536 100644
--- a/src/views/mainPlan/sheetMetalOrderManage/index.vue
+++ b/src/views/mainPlan/sheetMetalOrderManage/index.vue
@@ -6,16 +6,16 @@
ref="queryRef"
:inline="true"
v-show="showSearch"
- :label-width="locale == 'zh' ? '110px' : '200px'"
+ label-position="left"
>
- <el-row type="flex" justify="left">
- <el-col :span="12">
+ <el-row :gutter="20">
+ <el-col :span="6">
<el-form-item
+ :style="{ width: '100%' }"
:label="$t('plan.query.workOrderNo')"
prop="workOrderNo"
>
<el-input
- :style="{ width: '280px' }"
v-model="queryParams.workOrderNo"
:placeholder="`${$t('common.common.placeholder')}${$t(
'plan.query.workOrderNo'
@@ -25,13 +25,13 @@
/>
</el-form-item>
</el-col>
- <el-col :span="12">
+ <el-col :span="6">
<el-form-item
+ :style="{ width: '100%' }"
:label="$t('plan.query.requireTraceID')"
prop="requireTrackId"
>
<el-input
- :style="{ width: '280px' }"
v-model="queryParams.requireTrackId"
:placeholder="`${$t('common.common.placeholder')}${$t(
'plan.query.requireTraceID'
@@ -41,15 +41,13 @@
/>
</el-form-item>
</el-col>
- </el-row>
- <el-row type="flex" justify="left">
- <el-col :span="12">
+ <el-col :span="6">
<el-form-item
+ :style="{ width: '100%' }"
:label="$t('plan.query.itemNumber')"
prop="mainPartNumber"
>
<el-input
- :style="{ width:'280px' }"
v-model="queryParams.mainPartNumber"
:placeholder="`${$t('common.common.placeholder')}${$t(
'plan.query.itemNumber'
@@ -59,24 +57,15 @@
/>
</el-form-item>
</el-col>
- <el-col :span="12">
+ <el-col :span="6">
<el-form-item
+ :style="{ width: '100%' }"
:label="$t('plan.table.delayRiskIdentification')"
prop="hasDelayRisk"
>
- <!-- <el-input
- :style="{ width: locale == 'zh' ? '200px' : '280px' }"
- v-model="queryParams.hasDelayRisk"
- :placeholder="`${$t('common.common.placeholder')}${$t(
- 'plan.table.delayRiskIdentification'
- )}`"
- clearable
- @keyup.enter="handleQuery"
- /> -->
<el-select
clearable
v-model="queryParams.hasDelayRisk"
- style="width: 280px"
>
<el-option
v-for="item in delayRiskOptions"
@@ -88,26 +77,6 @@
</el-form-item>
</el-col>
</el-row>
- <el-row>
- <el-col
- :span="24"
- style="
- display: flex;
- justify-content: flex-end;
- align-item: center;
- text-align: right;
- "
- >
- <el-form-item class="column-with-margin">
- <el-button type="primary" icon="Search" @click="handleQuery">{{
- $t("common.common.query")
- }}</el-button>
- <el-button icon="Refresh" @click="resetQuery">{{
- $t("common.common.reset")
- }}</el-button>
- </el-form-item>
- </el-col>
- </el-row>
</el-form>
<el-row :gutter="10" class="mb8">
@@ -115,7 +84,7 @@
<el-button
type="primary"
plain
- icon="Plus"
+ icon="Refresh"
:disabled="multiple"
@click="handleBatchUpdatePlanDate"
v-hasPermi="['ApsPlatOrderPlanManager:requirement:list']"
@@ -135,7 +104,8 @@
</el-col>
<right-toolbar
v-model:showSearch="showSearch"
- @queryTable="getList"
+ @queryTable="handleQuery"
+ @resetTable="resetQuery"
></right-toolbar>
</el-row>
<HxlhTable
@@ -154,17 +124,24 @@
<el-button
type="primary"
link
+ @click="handleCheckLevels(row)"
+ v-hasPermi="['ApsPlatOrderPlanManager:requirement:list']"
+ >{{ $t("plan.btns.viewUpperLowerLevels") }}</el-button
+ >
+ <el-button
+ type="primary"
+ link
@click="handleCheckView(row)"
v-hasPermi="['ApsPlatOrderPlanManager:requirement:list']"
- >{{ $t("plan.btns.viewRequirement") }}</el-button
+ >{{ $t("plan.btns.viewRequirement") }}({{row.requireNum}})</el-button
>
</template>
</HxlhTable>
<el-dialog
:title="$t('plan.title.viewAssociatedRequirements')"
v-model="openDialog"
- width="900px"
- style="height: 400px; overflow: hidden"
+ width="85%"
+ style="height:90vh; overflow: hidden"
append-to-body
>
<HxlhTable
@@ -172,7 +149,7 @@
:columns="subGridOptions"
:data="subList"
:loading="loadingSub"
- :height="'280px'"
+ :height="heightSub"
>
</HxlhTable>
<template #footer>
@@ -186,8 +163,8 @@
<el-dialog
:title="$t('plan.btns.batchUpdateOrderDate')"
v-model="openBatchDialog"
- width="900px"
- style="height: 400px; overflow: hidden"
+ width="85%"
+ style="min-height:90vh; overflow: hidden"
append-to-body
>
<div class="mode_box">
@@ -196,12 +173,13 @@
<el-radio :label="1">{{
$t("plan.btns.batchUpdateOrderDate")
}}</el-radio>
- <el-radio :label="2">{{
+ <!-- <el-radio :label="2">{{
$t("plan.title.CustomizePlannedCompletionDate")
- }}</el-radio>
+ }}</el-radio> -->
</el-radio-group>
</div>
- <div class="red_color">{{ $t("plan.title.tipsBugSheetMetal") }}</div>
+ <div class="red_color" v-if="radio === 1">{{ $t("plan.title.tipsBugSheetMetal") }}</div>
+ <div class="red_color" v-if="radio === 2">{{ $t("plan.title.tipsBugSheetMetal2") }}</div>
<div class="mode_box" v-if="radio === 2">
<span>{{ $t("plan.title.CustomizePlannedCompletionDate") }}</span>
<!-- <el-date-picker
@@ -223,7 +201,7 @@
:columns="subUpdateGridOptions"
:data="subUpdateList"
:loading="loading"
- :height="'200px'"
+ :height="heightSubUpdate"
>
</HxlhTable>
<HxlhTable
@@ -232,7 +210,7 @@
:columns="subUpdateCustomGridOptions"
:data="subUpdateList"
:loading="loading"
- :height="'200px'"
+ :height="heightSubUpdate"
>
</HxlhTable>
<template #footer>
@@ -250,6 +228,30 @@
</span>
</template>
</el-dialog>
+ <!-- 鏌ョ湅涓婁笅闃� -->
+ <el-dialog
+ :title="$t('plan.title.viewUpperLowerLevels')"
+ v-model="openUpperLowerDialog"
+ width="85%"
+ style="height:90vh; overflow: hidden"
+ append-to-body
+ >
+ <HxlhTable
+ style="width: 100%"
+ :columns="subUpAndDownGridOptions"
+ :data="subUpAndDownList"
+ :loading="loadingSubUpAndDown"
+ :height="heightSub"
+ >
+ </HxlhTable>
+ <template #footer>
+ <span class="dialog-footer">
+ <el-button @click="openUpperLowerDialog = false">{{
+ $t("common.common.close")
+ }}</el-button>
+ </span>
+ </template>
+ </el-dialog>
</div>
</template>
@@ -261,6 +263,7 @@
import {
metalOrderManageList,
metalOrderManageSubList,
+ metalOrderManageUpAndDownList,
generatorPlanList,
planDateList,
} from "@/api/mainPlan/metalOrderManage.js";
@@ -269,23 +272,20 @@
const { t, locale } = useI18n();
const basicStore = useBasicStore();
const { proxy } = getCurrentInstance();
-const delayRiskOptions = ref([
- {
- label: t("plan.options.hasRisk"),
- value: "1",
- },
- {
- label: t("plan.options.noRisk"),
- value: "0",
- },
-]);
+const { aps_work_order_type } = proxy.useDict("aps_work_order_type");
+const { aps_factory } = proxy.useDict("aps_factory");
+const { aps_has_risk } = proxy.useDict("aps_has_risk");
+const delayRiskOptions = ref([]);
const radio = ref(1);
const customicDate = ref("");
const openDialog = ref(false);
+const openUpperLowerDialog = ref(false);
const openBatchDialog = ref(false);
const subGridOptions = ref([]);
+const subUpAndDownGridOptions = ref([]);
const subUpdateGridOptions = ref([]);
const subUpdateCustomGridOptions = ref([]);
+const subUpAndDownList = ref([]);
const subList = ref([]);
const subUpdateList = ref([]);
// const tableRef = ref();
@@ -293,6 +293,7 @@
const loading = ref(false);
const loadingUpdateDate = ref(false);
const loadingGenerateList = ref(false);
+const loadingSubUpAndDown = ref(false);
const loadingSub = ref(false);
const showSearch = ref(true);
const ids = ref([]);
@@ -318,7 +319,9 @@
const shopList = ref([]);
const allShopList = ref([]);
const processList = ref([]);
-const height = ref(document.documentElement.clientHeight - 320 + "px;");
+const height = ref(document.documentElement.clientHeight - 220 + "px;");
+const heightSub = ref(document.documentElement.clientHeight - 200 + "px;");
+const heightSubUpdate = ref(document.documentElement.clientHeight - 270 + "px;");
// 琛ㄦ牸閰嶇疆-鍒楄〃
const columns = ref([]);
// 鍒嗛〉灞炴��
@@ -330,72 +333,91 @@
watch(
locale,
(newLocale) => {
+ delayRiskOptions.value = [
+ {
+ label: t("plan.options.hasRisk"),
+ value: "1",
+ },
+ {
+ label: t("plan.options.noRisk"),
+ value: "0",
+ },
+ ];
columns.value = [
{ type: "checkbox", width: 60, align: "center", fixed: "left" },
- {
- title: t("basic.table.requirementID"),
- field: "requireId",
- width: 150,
- align: "center",
- },
+ // {
+ // title: t("basic.table.requirementID"),
+ // field: "requireId",
+ // width: 150,
+ // align: "center",
+ // },
{
title: t("basic.table.requirementTraceabilityID"),
field: "requireTrackId",
- width: 200,
+ width: "auto",
align: "center",
},
{
title: t("plan.table.workOrderNo"),
field: "workOrderNo",
- width: 200,
+ width: "auto",
align: "center",
},
{
title: t("basic.table.matchQuantity"),
field: "deductionAmount",
- width: 200,
+ width: "auto",
align: "center",
},
{
title: t("basic.table.workOrderType"),
field: "workOrderType",
- width: 200,
+ width: "auto",
align: "center",
+ formatter: ({ cellValue, row, column }) => {
+ if (cellValue) {
+ for (let i = 0; i < aps_work_order_type.value.length; i++) {
+ if (cellValue === aps_work_order_type.value[i].value) {
+ return aps_work_order_type.value[i].label;
+ }
+ }
+ }
+ },
},
{
title: t("plan.table.itemNumber"),
field: "mainPartNumber",
- width: 200,
+ width: "auto",
align: "center",
},
{
title: t("plan.table.mainPartDrawingNumber"),
field: "mainPartDrawingNumber",
- width: 200,
+ width: "auto",
align: "center",
},
{
title: t("basic.table.mainCustomer"),
field: "customer",
- width: 200,
+ width: "auto",
align: "center",
},
{
title: t("plan.table.productionQuantity"),
field: "productionQuantity",
- width: 100,
+ width: "auto",
align: "center",
},
{
title: t("basic.table.applicableFactories"),
field: "applicableFactories",
- width: 200,
+ width: 100,
align: "center",
formatter: ({ cellValue, row, column }) => {
if (cellValue) {
- for (let i = 0; i < plantList.value.length; i++) {
- if (cellValue === plantList.value[i].plantCode) {
- return plantList.value[i].plantName;
+ for (let i = 0; i < aps_factory.value.length; i++) {
+ if (cellValue === aps_factory.value[i].value) {
+ return aps_factory.value[i].label;
}
}
}
@@ -404,31 +426,31 @@
{
title: t("plan.table.productionBase"),
field: "productionBase",
- width: 100,
+ width: "auto",
align: "center",
},
{
title: t("plan.table.planStartDay"),
field: "planStartDay",
- width: 200,
+ width: "auto",
align: "center",
},
{
title: t("plan.table.planEndDayDate"),
field: "planEndDay",
- width: 200,
+ width: "auto",
align: "center",
},
{
title: t("plan.table.workorderCreationTime"),
field: "orderCreateTime",
- width: 200,
+ width: "auto",
align: "center",
},
{
title: t("plan.table.mismatchedProductionQuantity"),
field: "unmatchedQuantity",
- width: 100,
+ width: "auto",
align: "center",
},
{
@@ -438,17 +460,17 @@
align: "center",
formatter: ({ cellValue, row, column }) => {
if (cellValue) {
- for (let i = 0; i < delayRiskOptions.value.length; i++) {
- if (cellValue === delayRiskOptions.value[i].value) {
- return delayRiskOptions.value[i].label;
+ for (let i = 0; i < aps_has_risk.value.length; i++) {
+ if (cellValue === aps_has_risk.value[i].value) {
+ return aps_has_risk.value[i].label;
}
}
}
},
},
{
- title: t("common.common.operate"),
- width: 150,
+ title: t("common.common.require"),
+ width: "auto",
fixed: "right",
slots: { default: "buttons" },
align: "center",
@@ -461,12 +483,12 @@
width: 150,
align: "center",
},
- {
- title: t("basic.table.requirementTraceabilityID"),
- field: "requireId",
- width: 200,
- align: "center",
- },
+ // {
+ // title: t("basic.table.requirementTraceabilityID"),
+ // field: "requireId",
+ // width: 200,
+ // align: "center",
+ // },
{
title: t("plan.table.itemNumber"),
field: "bomLineCode",
@@ -485,18 +507,18 @@
width: 200,
align: "center",
},
- {
- title: t("basic.table.processRouteID"),
- field: "processRouteId",
- width: 200,
- align: "center",
- },
- {
- title: t("plan.table.processRouteWorkingHours"),
- field: "processRouteHours",
- width: 100,
- align: "center",
- },
+ // {
+ // title: t("basic.table.processRouteID"),
+ // field: "processRouteId",
+ // width: 200,
+ // align: "center",
+ // },
+ // {
+ // title: t("plan.table.processRouteWorkingHours"),
+ // field: "processRouteHours",
+ // width: 100,
+ // align: "center",
+ // },
{
title: t("plan.table.demandQuantity"),
field: "requireAmount",
@@ -532,6 +554,15 @@
field: "orgCode",
width: 100,
align: "center",
+ formatter: ({ cellValue, row, column }) => {
+ if (cellValue) {
+ for (let i = 0; i < aps_factory.value.length; i++) {
+ if (cellValue === aps_factory.value[i].value) {
+ return aps_factory.value[i].label;
+ }
+ }
+ }
+ },
},
{
title: t("plan.table.productionBase"),
@@ -570,22 +601,54 @@
align: "center",
formatter: ({ cellValue, row, column }) => {
if (cellValue) {
- for (let i = 0; i < delayRiskOptions.value.length; i++) {
- if (cellValue === delayRiskOptions.value[i].value) {
- return delayRiskOptions.value[i].label;
+ for (let i = 0; i < aps_has_risk.value.length; i++) {
+ if (cellValue === aps_has_risk.value[i].value) {
+ return aps_has_risk.value[i].label;
}
}
}
},
},
];
- subUpdateGridOptions.value = [
+ subUpAndDownGridOptions.value = [
{
- title: t("basic.table.requirementID"),
- field: "requireId",
- width: 150,
+ title: t("plan.table.documentNumber"),
+ field: "documentNumber",
align: "center",
},
+ {
+ title: t("plan.table.level"),
+ field: "requirementType",
+ align: "center",
+ },
+ {
+ title: t("plan.table.itemNumber"),
+ field: "itemNumber",
+ align: "center",
+ },
+ {
+ title: t("plan.table.planStartDay"),
+ field: "planStartDay",
+ align: "center",
+ },
+ {
+ title: t("plan.table.planEndDay"),
+ field: "planEndDay",
+ align: "center",
+ },
+ {
+ title: t("plan.table.productionQuantity"),
+ field: "productionQuantity",
+ align: "center",
+ },
+ ]
+ subUpdateGridOptions.value = [
+ // {
+ // title: t("basic.table.requirementID"),
+ // field: "requireId",
+ // width: 150,
+ // align: "center",
+ // },
{
title: t("basic.table.requirementTraceabilityID"),
field: "requireTrackId",
@@ -609,6 +672,15 @@
field: "workOrderType",
width: 200,
align: "center",
+ formatter: ({ cellValue, row, column }) => {
+ if (cellValue) {
+ for (let i = 0; i < aps_work_order_type.value.length; i++) {
+ if (cellValue === aps_work_order_type.value[i].value) {
+ return aps_work_order_type.value[i].label;
+ }
+ }
+ }
+ },
},
{
title: t("plan.table.itemNumber"),
@@ -642,12 +714,12 @@
},
];
subUpdateCustomGridOptions.value = [
- {
- title: t("basic.table.requirementID"),
- field: "requireId",
- width: 150,
- align: "center",
- },
+ // {
+ // title: t("basic.table.requirementID"),
+ // field: "requireId",
+ // width: 150,
+ // align: "center",
+ // },
{
title: t("basic.table.requirementTraceabilityID"),
field: "requireTrackId",
@@ -671,6 +743,15 @@
field: "workOrderType",
width: 200,
align: "center",
+ formatter: ({ cellValue, row, column }) => {
+ if (cellValue) {
+ for (let i = 0; i < aps_work_order_type.value.length; i++) {
+ if (cellValue === aps_work_order_type.value[i].value) {
+ return aps_work_order_type.value[i].label;
+ }
+ }
+ }
+ },
},
{
title: t("plan.table.itemNumber"),
@@ -732,6 +813,17 @@
loadingSub.value = false;
});
}
+function handleCheckLevels(row) {
+ openUpperLowerDialog.value = true;
+ loadingSubUpAndDown.value = true;
+ metalOrderManageUpAndDownList({requireId: row.requireId}).then((res) => {
+ console.log(res,"metalOrderManageUpAndDownList");
+ subUpAndDownList.value = res.rows;
+ loadingSubUpAndDown.value = false;
+ }).catch(() => {
+ loadingSubUpAndDown.value = false;
+ });
+}
async function hanleBatchUpdateDate() {
loadingUpdateDate.value = true;
let planIds = subUpdateList.value.map((item) => {
--
Gitblit v1.9.3