Merge branch 'master' of http://10.153.19.25:10105/r/YiWuProject
| | |
| | | export default { |
| | | // serverUrl: "10.153.19.150:88/api", |
| | | // serverUrl: "192.168.2.100:88/api", |
| | | serverUrl: "10.153.19.162:88", |
| | | // serverUrl: "10.153.19.162:88", |
| | | // serverUrl: "127.0.0.1:88", |
| | | // serverUrl: "192.168.0.39:88", |
| | | // serverUrl: "10.153.19.47:88", |
| | | // serverUrl2: "10.153.19.150:88" |
| | | // serverUrl2: "192.168.2.100:88" |
| | | serverUrl2: "10.153.19.162:88" |
| | | // serverUrl2: "10.153.19.162:88" |
| | | // serverUrl2: "127.0.0.1:88" |
| | | // serverUrl2: "192.168.0.39:88" |
| | | //serverUrl:"res.abeim.cn" |
| | |
| | | quit:"Exit", |
| | | }, |
| | | basicData:{ |
| | | rackreset:'架子复位', |
| | | prackreset:'是否架子复位?', |
| | | printing:'自动打印', |
| | | laserprinting:'Laser printing machine ready status:', |
| | | cuttingmachine:'Cutting machine ready status:', |
| | |
| | | quit: "Выход", |
| | | }, |
| | | basicData: { |
| | | rackreset:'架子复位', |
| | | prackreset:'是否架子复位?', |
| | | deletemessage: 'Удалить эту информацию или нет?', |
| | | laserprinting: 'Машина лазерной маркировки готова:', |
| | | cuttingmachine: 'Машина для резки готова:', |
| | |
| | | quit:"退出", |
| | | }, |
| | | basicData:{ |
| | | printing:'自动打印', |
| | | rackreset:'架子复位', |
| | | prackreset:'是否架子复位?', |
| | | laserprinting:'打标机就绪状态:', |
| | | cuttingmachine:'切割机就绪状态:', |
| | | machine:'上片机联机状态:', |
| | |
| | | // export const WebSocketHost = "192.168.2.100"; |
| | | // export const WebSocketHost = "192.168.0.39"; |
| | | // export const WebSocketHost = "10.153.19.150"; |
| | | // export const WebSocketHost = "192.168.2.100"; |
| | | export const WebSocketHost = "10.153.19.162"; |
| | | export const WebSocketHost = "10.153.19.150"; |
| | | // export const WebSocketHost = "10.153.19.47"; |
| | | // export const WebSocketHost = "10.153.19.162"; |
| | | // export const WebSocketHost = "127.0.0.1"; |
| | | export const host = "88"; |
| | |
| | | import axios from 'axios' |
| | | import config from '../../config'; |
| | | import useUserInfoStore from '@/stores/userInfo' |
| | | import {host, WebSocketHost} from '@/utils/constants' |
| | | const userStore=useUserInfoStore() |
| | | const request = axios.create({ |
| | | baseURL: `http://${config.serverUrl}`, // 注意!! 这里是全局统一加上了 后端接口前缀 前缀,后端必须进行跨域配置! |
| | | timeout: 30000 |
| | | baseURL: `http://${WebSocketHost}:${host}/api`, // 注意!! 这里是全局统一加上了 后端接口前缀 前缀,后端必须进行跨域配置! |
| | | timeout: 30000 |
| | | }) |
| | | |
| | | // |
| | | |
| | | // request 拦截器 |
| | | // 可以自请求发送前对请求做一些处理 |
| | | // 比如统一加token,对请求参数统一加密 |
| | | request.interceptors.request.use(config => { |
| | | config.headers['Content-Type'] = 'application/json;charset=utf-8'; |
| | | if(userStore.user){ |
| | | config.headers['token'] = userStore.user.token; |
| | | } |
| | | // 设置请求头 |
| | | return config |
| | | config.headers['Content-Type'] = 'application/json;charset=utf-8'; |
| | | if(userStore.user){ |
| | | config.headers['token'] = userStore.user.token; |
| | | } |
| | | // 设置请求头 |
| | | return config |
| | | }, error => { |
| | | return Promise.reject(error) |
| | | }); |
| | | |
| | | // response 拦截器 |
| | | // 可以在接口响应后统一处理结果 |
| | | request.interceptors.response.use( |
| | | response => { |
| | | let res = response.data; |
| | | // 如果是返回的文件 |
| | | if (response.config.responseType === 'blob') { |
| | | return res |
| | | } |
| | | // 兼容服务端返回的字符串数据 |
| | | if (typeof res === 'string') { |
| | | res = res ? JSON.parse(res) : res |
| | | } |
| | | return res; |
| | | }, |
| | | error => { |
| | | console.log('err' + error) // for debug |
| | | return Promise.reject(error) |
| | | } |
| | | response => { |
| | | let res = response.data; |
| | | // 如果是返回的文件 |
| | | if (response.config.responseType === 'blob') { |
| | | return res |
| | | } |
| | | // 兼容服务端返回的字符串数据 |
| | | if (typeof res === 'string') { |
| | | res = res ? JSON.parse(res) : res |
| | | } |
| | | return res; |
| | | }, |
| | | error => { |
| | | console.log('err' + error) // for debug |
| | | return Promise.reject(error) |
| | | } |
| | | ) |
| | | |
| | | |
| | | export default request |
| | |
| | | } |
| | | }; |
| | | const handleEdit = (row) => { |
| | | window.localStorage.setItem('slotId', row.slotId) |
| | | window.localStorage.setItem('slotId', row.slot) |
| | | Edit.value = true; |
| | | }; |
| | | const handleBinda = (row) => { |
| | |
| | | const response = await request.post("/glassStorage/rawGlassStorageTask/setRawGlassTaskRequest", { |
| | | beginDate: (timeRange.value && timeRange.value[0]) || '', |
| | | endDate: (timeRange.value && timeRange.value[1]) || '', |
| | | taskState: stateList, |
| | | taskType: celllist |
| | | taskState: celllist, |
| | | taskType: stateList |
| | | }) |
| | | if (response.code === 200) { |
| | | // tableDataa.value = response.data; |
| | |
| | | } |
| | | const newState = row.state === 1 ? 0 : 1; |
| | | try { |
| | | var url="/glassStorage/rawGlassStorageStation/updateSlotState?slot="+row.deviceId + "&state=" + newState; |
| | | var url="/glassStorage/rawGlassStorageStation/updateSlotState?slot="+row.slot + "&state=" + newState; |
| | | const response = await request.post(url) |
| | | if (response.code === 200) { |
| | | ElMessage.success(response.message); |
| | |
| | | const response = await request.post('/glassStorage/rawGlassStorageDetails/updateQuantity', { |
| | | slotId: slotId, |
| | | remainQuantity: remainQuantity.value, |
| | | filmsId: filmsId.value, |
| | | patternThickness: patternThickness.value, |
| | | patternHeight: patternHeight.value, |
| | | patternWidth: patternWidth.value, |
| | | } |
| | | ); |
| | | if (response.code === 200) { |
| | | ElMessage.success(response.message); |
| | | Edit.value = false; |
| | | tableDatab.value = response.data; |
| | | patternWidth.value = ''; |
| | | patternHeight.value = ''; |
| | | patternThickness.value = ''; |
| | | filmsId.value = ''; |
| | | remainQuantity.value = ''; |
| | | } else { |
| | | ElMessage.error(response.message); |
| | | } |
| | |
| | | </el-table-column> |
| | | <el-table-column fixed="right" :label="$t('film.operate')" align="center" width="270"> |
| | | <template #default="scope"> |
| | | <el-button :disabled="!scope.row.remainQuantity" size="mini" type="text" plain @click="handleEdit(scope.row)">{{ $t('film.exit') }}</el-button> |
| | | <el-button size="mini" type="text" plain @click="handleEdit(scope.row)">{{ $t('film.exit') }}</el-button> |
| | | <el-button :disabled="!scope.row.remainQuantity" size="mini" type="text" plain @click="deleteWarehousing(scope.row)">{{ $t('film.delete') }}</el-button> |
| | | <el-button :disabled="!scope.row.remainQuantity || scope.row.remainQuantity === 0" size="mini" type="text" plain @click="openc(scope.row)">{{ $t('film.outbound') }}</el-button> |
| | | </template> |
| | |
| | | </div> |
| | | </template> |
| | | </el-dialog> |
| | | <el-dialog v-model="Edit" top="21vh" width="40%"> |
| | | <div style="margin-left: 50px;margin-top: 10px;margin-bottom: 10px;"> |
| | | <el-form size="mini" label-width="100px"> |
| | | <el-form label-width="210px" label-position="right"> |
| | | <el-form-item :label="$t('film.thickremainquantity')" :required="true" style="width: 25vw"> |
| | | <el-input v-model="remainQuantity" autocomplete="off" /> |
| | | <el-dialog v-model="Edit" top="23vh" width="55%" :title="$t('film.addglass')" > |
| | | <div style="margin-left: -50px;margin-top: 10px;margin-bottom: 10px;"> |
| | | <el-form size="mini" label-width="150px"> |
| | | <el-form label-width="100px" label-position="right"> |
| | | <el-row style="margin-top: -15px;margin-bottom: -2px;"> |
| | | <el-col :span="6"> |
| | | <div id="dt" style="font-size: 15px;"> |
| | | <div> |
| | | <el-form-item :label="$t('film.widtha')" :required="true" style="width: 17vw;"> |
| | | <el-input :placeholder="$t('film.inwidth')" v-model="patternWidth" autocomplete="off" /> |
| | | </el-form-item> |
| | | </div></div> |
| | | </el-col> |
| | | <el-col :span="9"> |
| | | <div id="dta" style="font-size: 15px;"> |
| | | <div> |
| | | <el-form-item :label="$t('film.heighta')" :required="true" style="width: 17vw;"> |
| | | <el-input :placeholder="$t('film.inheight')" v-model="patternHeight" autocomplete="off" /> |
| | | </el-form-item></div> |
| | | </div> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row style="margin-top: 10px;"> |
| | | <el-col :span="6"> |
| | | <div id="dt" style="font-size: 15px;"> |
| | | <div> |
| | | <el-form-item :label="$t('film.thicknessa')" :required="true" style="width: 17vw;"> |
| | | <el-input :placeholder="$t('film.inthickness')" v-model="patternThickness" autocomplete="off" /> |
| | | </el-form-item></div></div> |
| | | </el-col> |
| | | <el-col :span="9"> |
| | | <div id="dta" style="font-size: 15px;"> |
| | | <div> |
| | | <el-form-item :label="$t('film.filmsa')" :required="true" style="width: 17vw;"> |
| | | <el-input :placeholder="$t('film.infilms')" v-model="filmsId" autocomplete="off" /> |
| | | </el-form-item></div></div> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row style="margin-top: 10px;"> |
| | | <el-col :span="6"> |
| | | <div id="dt" style="font-size: 15px;"> |
| | | <div> |
| | | <el-form label-width="210px"> |
| | | <el-form-item :label="$t('film.thickremainquantity')" :required="true" style="width: 44.5vw;margin-left: -40px;"> |
| | | <el-input v-model="remainQuantity" autocomplete="off" :placeholder="$t('film.inquantity')"/> |
| | | </el-form-item> |
| | | </el-form> |
| | | </el-form> |
| | | </div> |
| | | </div></div> |
| | | </el-col> |
| | | </el-row> |
| | | </el-form> |
| | | </el-form> |
| | | </div> |
| | | <template #footer> |
| | | <div id="dialog-footer"> |
| | | <el-button type="primary" @click="Editclick"> |
| | | {{ $t('reportWork.sure') }} |
| | | {{ $t('basicData.confirm') }} |
| | | </el-button> |
| | | <el-button @click="Edit = false">{{ $t('reportWork.cancel') }}</el-button> |
| | | <el-button @click="Edit = false">{{ $t('basicData.cancel') }}</el-button> |
| | | </div> |
| | | </template> |
| | | </el-dialog> |
| | |
| | | <script lang="ts" setup> |
| | | import {onBeforeUnmount, onMounted, onUnmounted, reactive, ref} from "vue"; |
| | | import {onBeforeUnmount, onMounted, onUnmounted, reactive, ref, computed} from "vue"; |
| | | import {useRouter} from "vue-router" |
| | | import { ElMessage, ElMessageBox } from 'element-plus' |
| | | import {useI18n} from 'vue-i18n' |
| | |
| | | const tableDataa = ref<any[]>([]); |
| | | const tableDatab = ref<any[]>([]); |
| | | const tableData = ref([]) |
| | | const filteredData = computed(() => { |
| | | // applyFilters 函数应该在某处定义,用于根据当前筛选条件过滤数据 |
| | | return applyFilters(tableData, currentFilters); |
| | | }); |
| | | // 当前筛选条件,应该是一个响应式变量,用于存储用户选择的筛选值 |
| | | const currentFilters = ref<{ state?: string }>({}); |
| | | const filterTag = (value: string, row: any) => { |
| | | return row.state === value |
| | | }; |
| | | // 应用筛选条件的函数 |
| | | const applyFilters = (data: any[], filters: { state?: string }) => { |
| | | return data.filter(row => { |
| | | return (!filters.state || String(row.state) === filters.state); |
| | | }); |
| | | }; |
| | | const titleSelectJson = ref({ |
| | | engineerId: [], |
| | | }) |
| | |
| | | try { |
| | | const response = await request.get("/loadGlass/up-patten-usage/prioritylist"); |
| | | if (response.code === 200) { |
| | | tableData.splice(0, tableData.length, ...response.data); |
| | | tableData.value = response.data |
| | | // tableData.splice(0, tableData.length, ...response.data); |
| | | ElMessage.error(response.message); |
| | | window.localStorage.setItem('engineeringIda', tableData[0].engineeringId) |
| | | } |
| | | } catch (error) { |
| | | ElMessage.error(response.message); |
| | | } |
| | | }; |
| | | let socket = null; |
| | |
| | | tableDataa.value = data.list[0].slice(0, 2); |
| | | if(data.loadTask1.length !=0){ |
| | | tableData.value = data.loadTask1[0] |
| | | window.localStorage.setItem('engineeringIda', tableData.value[0].engineeringId) |
| | | canSelectProjecta.value = false; |
| | | canSelectProjectb.value = false; |
| | | canSelectProjectc.value = true; |
| | |
| | | const deleteTask = async () => { |
| | | try { |
| | | let engineeringId = window.localStorage.getItem('engineeringIda') |
| | | console.log(engineeringId); |
| | | if (engineeringId !== '') { |
| | | const response = await request.post('/loadGlass/engineering/engineering/deleteTask', { |
| | | engineerId: engineeringId, |
| | |
| | | // 开始上片 |
| | | const handleon = async () => { |
| | | let filmRemove = window.localStorage.getItem('filmRemove') |
| | | let engineeringIda = window.localStorage.getItem('engineeringIda') |
| | | let engineeringId = window.localStorage.getItem('engineeringIda') |
| | | if (markingMachineStatus.value === 'green' && cuttingMachineStatus.value === 'green') { |
| | | try { |
| | | const response = await request.post('/loadGlass/engineering/engineering/changeTask', { |
| | | stationCell: 5, |
| | | filmRemove: filmRemove, |
| | | engineerId: engineeringIda, |
| | | engineerId: engineeringId, |
| | | state: 1, |
| | | }) |
| | | if (response.code == 200) { |
| | |
| | | try { |
| | | let filmRemove = window.localStorage.getItem('filmRemove') |
| | | let engineeringId = window.localStorage.getItem('engineeringIda') |
| | | console.log(engineeringId); |
| | | if (engineeringId !== '') { |
| | | const response = await request.post('/loadGlass/engineering/engineering/pause', { |
| | | stationCell: 5, |
| | |
| | | console.error('发生错误:', error); |
| | | } |
| | | }; |
| | | // 架子复位 |
| | | const handleptask = async() => { |
| | | try { |
| | | const confirmResult = await ElMessageBox.confirm( |
| | | t('basicData.prackreset'), |
| | | t('workOrder.prompt'), |
| | | { |
| | | confirmButtonText: t('workOrder.yes'), |
| | | cancelButtonText: t('workOrder.cancel'), |
| | | type: 'warning', |
| | | } |
| | | ); |
| | | if (confirmResult === 'confirm') { |
| | | var url="/loadGlass/rawGlassStorageDetails/shelfReset?slot="+ 1; |
| | | const response = await request.post(url) |
| | | if (response.code === 200) { |
| | | ElMessage.success(response.message); |
| | | } else { |
| | | ElMessage.error(response.msg); |
| | | } |
| | | } |
| | | } catch (error) { |
| | | console.error('发生错误:', error); |
| | | } |
| | | }; |
| | | function getStatusType2(filmRemove) { |
| | | switch (filmRemove) { |
| | | case 0: |
| | |
| | | <el-button :disabled="!canSelectProjectc" style="margin-top: 5px;margin-left: 20px;" id="searchButton" type="warning" @click="handleBinda">{{ $t('basicData.stop') }}</el-button> |
| | | <el-button :disabled="!canSelectProjectc" style="margin-top: 5px;margin-left: 20px;" id="searchButton" type="danger" @click="handledelete">{{ $t('searchOrder.deleteTask') }}</el-button> |
| | | <el-button style="margin-top: 5px;margin-left: 20px;" id="searchButton" type="info" @click="handlezhiban">{{ $t('searchOrder.dutyinformation') }}</el-button> |
| | | <el-select disabled v-model="selectValuesa[1]" clearable :placeholder="$t('Mounting.oneloadingline')" |
| | | style="margin-top: 5px;margin-left: 20px;"> |
| | | <el-option :label="$t('Mounting.all')" value="0"></el-option> |
| | | <el-option :label="$t('Mounting.oneloadingline')" value="1"></el-option> |
| | | <el-option :label="$t('Mounting.twoloadingline')" value="2"></el-option> |
| | | </el-select> |
| | | <el-select v-model="selectValuesa[0]" clearable :placeholder="$t('film.taskstatus')" style="margin-top: 5px;margin-left: 20px;" > |
| | | <el-option :label="$t('Mounting.waiting')" value="1"></el-option> |
| | | <el-option :label="$t('film.execution')" value="2"></el-option> |
| | | <el-option :label="$t('film.finish')" value="3"></el-option> |
| | | </el-select> |
| | | <el-button type="primary" style="margin-left: 10px;" @click="selectReportData()">{{ $t('Mounting.setparameters') }}</el-button> |
| | | <el-card style="flex: 1;margin-left: 10px;margin-top: 15px;" v-loading="loading"> |
| | | <div style="width: 98%; height: calc(100% - 35px); overflow-y: auto;"> |
| | | <el-table |
| | |
| | | <span>{{ 1 }}</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column |
| | | align="center" |
| | | :label="$t('Mounting.state')" |
| | | min-width="80" |
| | | prop="state" |
| | | > |
| | | <template #default="scope"> |
| | | <el-tag |
| | | <el-table-column |
| | | align="center" |
| | | prop="state" |
| | | :label="$t('Mounting.state')" |
| | | min-width="80" |
| | | :filters="[ |
| | | { text: t('Mounting.pass'), value: 100 }, |
| | | { text: t('Mounting.waiting'), value: 0 }, |
| | | ]" |
| | | :filter-method="filterTag" |
| | | filter-placement="bottom-end" |
| | | > |
| | | <template #default="scope"> |
| | | <el-tag |
| | | :type="scope.row.state === 100 ? 'success' : 'warning'" |
| | | @click="toggleEnableState(scope.row)" |
| | | disable-transitions |
| | | > |
| | | {{ scope.row.state === 100 ? $t('Mounting.pass') : $t('Mounting.waiting') }} |
| | | </el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | </div> |
| | | </el-card> |
| | |
| | | <el-table-column prop="patternHeight" align="center" :label="$t('basicData.height')" min-width="80"/> |
| | | <el-table-column prop="filmsId" align="center" :label="$t('basicData.coatingtypes')" min-width="80"/> |
| | | <el-table-column prop="number" align="center" :label="$t('basicData.quantity')" min-width="80"/> |
| | | <el-table-column fixed="right" :label="$t('film.operate')" align="center" width="70"> |
| | | <template #default="scope"> |
| | | <el-button size="mini" type="text" plain @click="handleptask()">{{ $t('basicData.rackreset') }}</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | </div> |
| | | </div> |
| | |
| | | <script lang="ts" setup> |
| | | import {onBeforeUnmount, onMounted, onUnmounted, reactive, ref} from "vue"; |
| | | import {onBeforeUnmount, onMounted, onUnmounted, reactive, ref, computed} from "vue"; |
| | | import {useRouter} from "vue-router" |
| | | import { ElMessage, ElMessageBox } from 'element-plus' |
| | | import {useI18n} from 'vue-i18n' |
| | |
| | | const tableDataa = ref<any[]>([]); |
| | | const tableDatab = ref<any[]>([]); |
| | | const tableData = ref([]) |
| | | const filteredData = computed(() => { |
| | | // applyFilters 函数应该在某处定义,用于根据当前筛选条件过滤数据 |
| | | return applyFilters(tableData, currentFilters); |
| | | }); |
| | | // 当前筛选条件,应该是一个响应式变量,用于存储用户选择的筛选值 |
| | | const currentFilters = ref<{ state?: string }>({}); |
| | | const filterTag = (value: string, row: any) => { |
| | | // return String(row.state) === value; |
| | | return row.state === value |
| | | }; |
| | | // 应用筛选条件的函数 |
| | | const applyFilters = (data: any[], filters: { state?: string }) => { |
| | | return data.filter(row => { |
| | | return (!filters.state || String(row.state) === filters.state); |
| | | }); |
| | | }; |
| | | const titleSelectJson = ref({ |
| | | engineerId: [], |
| | | }) |
| | |
| | | const handleMessage = (data: any) => { |
| | | tableDataa.value = data.list[0].slice(2, 4); |
| | | if(data.loadTask2.length !=0){ |
| | | // tableData.splice(0, tableData.length, ...data.loadTask2[0]); |
| | | tableData.value = data.loadTask2[0] |
| | | window.localStorage.setItem('engineeringIda', tableData.value[0].engineeringId) |
| | | canSelectProjecta.value = false; |
| | | canSelectProjectb.value = false; |
| | | canSelectProjectc.value = true; |
| | |
| | | <el-button :disabled="!canSelectProjectc" style="margin-top: 5px;margin-left: 20px;" id="searchButton" type="warning" @click="handleBinda">{{ $t('basicData.stop') }}</el-button> |
| | | <el-button :disabled="!canSelectProjectc" style="margin-top: 5px;margin-left: 20px;" id="searchButton" type="danger" @click="handledelete">{{ $t('searchOrder.deleteTask') }}</el-button> |
| | | <el-button style="margin-top: 5px;margin-left: 20px;" id="searchButton" type="info" @click="handlezhiban">{{ $t('searchOrder.dutyinformation') }}</el-button> |
| | | <el-select disabled v-model="selectValuesa[1]" clearable :placeholder="$t('Mounting.twoloadingline')" |
| | | style="margin-top: 5px;margin-left: 20px;"> |
| | | <el-option :label="$t('Mounting.all')" value="0"></el-option> |
| | | <el-option :label="$t('Mounting.oneloadingline')" value="1"></el-option> |
| | | <el-option :label="$t('Mounting.twoloadingline')" value="2"></el-option> |
| | | </el-select> |
| | | <el-select v-model="selectValuesa[0]" clearable :placeholder="$t('film.taskstatus')" style="margin-top: 5px;margin-left: 20px;" > |
| | | <el-option :label="$t('Mounting.waiting')" value="1"></el-option> |
| | | <el-option :label="$t('film.execution')" value="2"></el-option> |
| | | <el-option :label="$t('film.finish')" value="3"></el-option> |
| | | </el-select> |
| | | <el-button type="primary" style="margin-left: 10px;" @click="selectReportData()">{{ $t('Mounting.setparameters') }}</el-button> |
| | | <el-card style="flex: 1;margin-left: 10px;margin-top: 15px;" v-loading="loading"> |
| | | <div style="width: 98%; height: calc(100% - 35px); overflow-y: auto;"> |
| | | <el-table |
| | |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column |
| | | align="center" |
| | | :label="$t('Mounting.state')" |
| | | min-width="80" |
| | | prop="state" |
| | | > |
| | | <template #default="scope"> |
| | | <el-tag |
| | | align="center" |
| | | prop="state" |
| | | :label="$t('Mounting.state')" |
| | | min-width="80" |
| | | :filters="[ |
| | | { text: t('Mounting.pass'), value: 100 }, |
| | | { text: t('Mounting.waiting'), value: 0 }, |
| | | ]" |
| | | :filter-method="filterTag" |
| | | filter-placement="bottom-end" |
| | | > |
| | | <template #default="scope"> |
| | | <el-tag |
| | | :type="scope.row.state === 100 ? 'success' : 'warning'" |
| | | @click="toggleEnableState(scope.row)" |
| | | disable-transitions |
| | | > |
| | | {{ scope.row.state === 100 ? $t('Mounting.pass') : $t('Mounting.waiting') }} |
| | | </el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | </div> |
| | | </el-card> |
| | |
| | | </div> |
| | | <!-- // 父级框 --> |
| | | <div class="img-dlpl" > |
| | | <div class="img-car1" :style="'z-index:999;left:475px;top:' + 1450*carPosition[0] + 'px;position:absolute;'"> |
| | | <div class="img-car1" :style="'z-index:999;left:475px;top:' + 1700*carPosition[0] + 'px;position:absolute;'"> |
| | | <div |
| | | v-for="(rect, index) in adjusta" |
| | | :key="rect.id" |
| | |
| | | > |
| | | </div> |
| | | </div> |
| | | <div class="img-car4" :style="'z-index:999;left:890px;top:' + 50*carPosition[1] + 'px;position:absolute;'"> |
| | | <div class="img-car4" :style="'z-index:999;left:890px;top:' + 600*carPosition[1] + 'px;position:absolute;'"> |
| | | <div |
| | | v-for="(rect, index) in adjust" |
| | | :key="rect.id" |
| | |
| | | public List<Engineering> selectTask() { |
| | | //查询可开始任务的工程 |
| | | QueryWrapper<Engineering> wrapper = new QueryWrapper<>(); |
| | | // wrapper.eq("state", 0); |
| | | wrapper.eq("state", 5); |
| | | return engineeringMapper.selectList(wrapper); |
| | | } |
| | | |
| | |
| | | public boolean pauseTask(String engineerId, Integer state) { |
| | | //暂停正在进行工程 |
| | | LambdaUpdateChainWrapper<Engineering> pauseWrapper = new LambdaUpdateChainWrapper<>(this.getBaseMapper()); |
| | | pauseWrapper.set(Engineering::getState, state); |
| | | pauseWrapper.set(Engineering::getState, 5); |
| | | pauseWrapper.eq(Engineering::getEngineerId, engineerId); |
| | | return pauseWrapper.update(); |
| | | } |
| | |
| | | |
| | | |
| | | import com.mes.damage.entity.Damage; |
| | | import com.mes.damage.entity.request.DamageRequest; |
| | | import com.mes.damage.service.DamageService; |
| | | import com.mes.engineering.entity.Engineering; |
| | | import com.mes.engineering.service.EngineeringService; |
| | |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.List; |
| | |
| | | private OptimizeProjectService optimizeProjectService; |
| | | @Autowired |
| | | DamageService damageService; |
| | | |
| | | |
| | | @ApiOperation("开始/暂停任务/传递工程号和状态,开始是1 暂停是0") |
| | | @PostMapping("/pauseTask") //暂停上片任务 |
| | |
| | | boolean work = engineeringService.changeTasks(engineering); |
| | | List<UpPattenUsage> glass = upPattenUsageService.prioritylist(); |
| | | optimizeProjectService.changeTask(engineering.getEngineerId(), 200); |
| | | return Result.build(200, "已保存过", work); |
| | | return Result.build(200, "开始上片", work); |
| | | } else { |
| | | List<UpPattenUsage> upPattenUsages = upPattenUsageService.selectSaveUpPattenUsage(engineering.getEngineerId()); |
| | | log.info("将查询出的UpPattenUsage数据保存到数据库表里"); |
| | |
| | | return Result.build(200, "操作成功", null); |
| | | } |
| | | |
| | | @ApiOperation("识别操作: 破损/拿走 参数(ID,功能[9:拿走,8:破损])") |
| | | @PostMapping("/identControls") |
| | | public Result<String> identControls(@RequestBody @Validated DamageRequest request) { |
| | | return Result.build(200, "成功", upPattenUsageService.identControls(request)); |
| | | } |
| | | |
| | | } |
| | | |
| | |
| | | if(upPattenUsages!=null){ |
| | | jsonObject.append("prioritylist", upPattenUsages); |
| | | } |
| | | //查询1、2号线的任务 |
| | | //查询1号线的任务 |
| | | List<UpPattenUsage> upPattenUsages1 = upPattenUsageService.selectLoadTask(5); |
| | | jsonObject.append("loadTask1", upPattenUsages1); |
| | | //查询1、2号线的任务 |
| | | //查询2号线的任务 |
| | | List<UpPattenUsage> upPattenUsages2 = upPattenUsageService.selectLoadTask(6); |
| | | jsonObject.append("loadTask2", upPattenUsages2); |
| | | |
| | | //查询工位任务 |
| | | |
| | | |
| | | //工位信息 |
| | | List<UpWorkstation> upWorkstations = upWorkstationService.list(); |
| | | jsonObject.append("list", upWorkstations); |
| | | //是否开始工程 |
| | | Engineering engineering = engineeringService.selectInitiate(1); |
| | | jsonObject.append("engineering", engineering); |
| | | |
| | | ArrayList<WebSocketServer> sendwServer = WebSocketServer.sessionMap.get("loadGlass"); |
| | | if (sendwServer != null) { |
| | |
| | | package com.mes.uppattenusage.service; |
| | | |
| | | import com.github.yulichang.base.MPJBaseService; |
| | | import com.mes.damage.entity.request.DamageRequest; |
| | | import com.mes.engineering.entity.Engineering; |
| | | import com.mes.uppattenusage.entity.UpPattenUsage; |
| | | |
| | |
| | | |
| | | List<UpPattenUsage> selectLoadTask(Integer i); |
| | | |
| | | /** |
| | | * 拿走:9/破损:8 |
| | | * |
| | | * @param request |
| | | * @return |
| | | */ |
| | | String identControls(DamageRequest request); |
| | | |
| | | } |
| | | |
| | |
| | | import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper; |
| | | import com.github.yulichang.base.MPJBaseServiceImpl; |
| | | import com.github.yulichang.query.MPJQueryWrapper; |
| | | import com.mes.damage.entity.request.DamageRequest; |
| | | import com.mes.damage.service.DamageService; |
| | | import com.mes.engineering.entity.Engineering; |
| | | import com.mes.engineering.service.EngineeringService; |
| | | import com.mes.pp.entity.OptimizeProject; |
| | |
| | | OptimizeProjectMapper optimizeProjectMapper; |
| | | @Autowired |
| | | EngineeringService engineeringService; |
| | | @Autowired |
| | | DamageService damageService; |
| | | @Override |
| | | public List<UpPattenUsage> prioritylist() { |
| | | //获取正在上片的任务id |
| | |
| | | return null; |
| | | } |
| | | |
| | | |
| | | @Override |
| | | public String identControls(DamageRequest request) { |
| | | //将识别破损的玻璃直接加入破损表 |
| | | damageService.autoSubmitReport(request.getGlassId(), request.getLine(), request.getWorkingProcedure(), "上片机", request.getState()); |
| | | return "success"; |
| | | } |
| | | } |