From 999ac56a03c8221a084a3afab870d258dd4d9741 Mon Sep 17 00:00:00 2001
From: wangfei <3597712270@qq.com>
Date: 星期四, 21 十一月 2024 17:09:40 +0800
Subject: [PATCH] 预览状态,开始上片,暂停接口完善,前端页面新增字段
---
UI-Project/src/views/Returns/upreturns.vue | 68 +++++++++++++++++++++++++--------
1 files changed, 51 insertions(+), 17 deletions(-)
diff --git a/UI-Project/src/views/Returns/upreturns.vue b/UI-Project/src/views/Returns/upreturns.vue
index a7a4448..27a1d77 100644
--- a/UI-Project/src/views/Returns/upreturns.vue
+++ b/UI-Project/src/views/Returns/upreturns.vue
@@ -96,7 +96,8 @@
const response = await request.post('/loadGlass/up-patten-usage/selectUpPattenUsage', {
stationCell: 5,
engineerId: selectedProjectNo.value,
- filmRemove: filmRemove.value,
+ // filmRemove: filmRemove.value,
+ filmRemove: parseInt(filmRemove.value, 10),
})
window.localStorage.setItem('engineeringId', selectedProjectNo.value)
window.localStorage.setItem('filmRemove', filmRemove.value)
@@ -121,10 +122,10 @@
let engineeringId = window.localStorage.getItem('engineeringId')
if (markingMachineStatus.value === 'green' && cuttingMachineStatus.value === 'green') {
try {
- // const response = await request.post('/loadGlass/engineering/engineering/pauseTask', {
- const response = await request.post('/loadGlass/engineering/engineering/changeTask', {
- stationCell: 5,
- filmRemove: filmRemove,
+ const response = await request.post('/loadGlass/engineering/engineering/pause', {
+ // const response = await request.post('/loadGlass/engineering/engineering/changeTask', {
+ // stationCell: 5,
+ // filmRemove: filmRemove,
engineerId: engineeringId,
state: 1,
})
@@ -148,8 +149,8 @@
let engineeringId = window.localStorage.getItem('engineeringId')
console.log(engineeringId);
if (engineeringId !== '') {
- const response = await request.post('/loadGlass/engineering/engineering/pauseTask', {
- stationCell: 5,
+ const response = await request.post('/loadGlass/engineering/engineering/pause', {
+ // stationCell: 5,
engineerId: engineeringId,
state: 0,
})
@@ -236,6 +237,28 @@
ElMessage.error(t('basicData.glassnull'));
}
};
+
+function getStatusType2(filmRemove) {
+ switch (filmRemove) {
+ case 0:
+ return 'success';
+ case 1:
+ return 'info';
+ case 2:
+ return 'warning';
+ }
+}
+
+function getStatusText2(filmRemove) {
+ switch (filmRemove) {
+ case 0:
+ return t('Mounting.noremoval');//瀹屾垚
+ case 1:
+ return t('Mounting.coarselyground');//鏂板缓
+ case 2:
+ return t('Mounting.finegrinding');//鎵ц涓�
+ }
+}
</script>
<template>
<div style="height: 500px;">
@@ -301,18 +324,29 @@
min-width="80"
prop="state"
>
- <template #default="scope">
- <el-tag
- :type="scope.row.state === 100 ? 'success' : 'warning'"
- @click="toggleEnableState(scope.row)"
- >
- {{ scope.row.state === 100 ? $t('Mounting.pass') : $t('Mounting.waiting') }}
- </el-tag>
- </template>
- </el-table-column>
+ <template #default="scope">
+ <el-tag
+ :type="scope.row.state === 100 ? 'success' : 'warning'"
+ @click="toggleEnableState(scope.row)"
+ >
+ {{ scope.row.state === 100 ? $t('Mounting.pass') : $t('Mounting.waiting') }}
+ </el-tag>
+ </template>
+ </el-table-column>
<el-table-column prop="filmsId" :label="$t('Mounting.createtime')" align="center"/>
<!-- <el-table-column prop="filmRemove" :label="$t('Mounting.removalmethodp')" align="center"/> -->
- <!-- <el-table-column prop="stationCell" :label="$t('Mounting.loadinglinea')" align="center"/> -->
+ <el-table-column
+ align="center"
+ :label="$t('Mounting.removalmethodp')"
+ prop="filmRemove"
+ >
+ <template #default="scope">
+ <el-tag :type="getStatusType2(scope.row.filmRemove)">
+ {{ getStatusText2(scope.row.filmRemove) }}
+ </el-tag>
+ </template>
+ </el-table-column>
+ <el-table-column prop="stationCell" :label="$t('Mounting.loadinglinea')" align="center"/>
</el-table>
</div>
</el-card>
--
Gitblit v1.8.0