| | |
| | | <script setup> |
| | | import {Search} from "@element-plus/icons-vue"; |
| | | import {reactive} from "vue"; |
| | | import {onBeforeUnmount, onMounted, onUnmounted, reactive, ref} from "vue"; |
| | | import {useRouter} from "vue-router" |
| | | import {host, WebSocketHost} from '@/utils/constants' |
| | | import request from "@/utils/request" |
| | | import {closeWebSocket, initializeWebSocket} from '@/utils/WebSocketService'; |
| | | // import { ref } from 'vue' |
| | | import {ElMessage, ElMessageBox} from 'element-plus' |
| | | // import LanguageMixin from './lang/LanguageMixin' |
| | | import {useI18n} from 'vue-i18n' |
| | | |
| | | const router = useRouter() |
| | | const adda = ref(false) |
| | | import { WebSocketHost ,host} from '@/utils/constants' |
| | | import request from "@/utils/request" |
| | | import { ref, onMounted , onBeforeUnmount,onUnmounted} from "vue"; |
| | | import { initializeWebSocket, closeWebSocket } from '@/utils/WebSocketService'; |
| | | // import { ref } from 'vue' |
| | | import { ElMessage, ElMessageBox } from 'element-plus' |
| | | // import LanguageMixin from './lang/LanguageMixin' |
| | | import { useI18n } from 'vue-i18n' |
| | | const { t } = useI18n() |
| | | let language = ref(localStorage.getItem('lang') || 'zh') |
| | | |
| | | const {t} = useI18n() |
| | | let language = ref(localStorage.getItem('lang') || 'zh') |
| | | |
| | | const tableData = ref([]) |
| | | const slot = ref('') |
| | | const requestData = { |
| | | line: 2001 |
| | | }; |
| | | const requestData = { |
| | | line: 2001 |
| | | }; |
| | | const timeRange = ref([]) |
| | | const selectValuesa = reactive([]); |
| | | // request.post("/cacheGlass/taskCache/selectEdgTask",{ |
| | |
| | | }); |
| | | onUnmounted(() => { |
| | | if (socket) { |
| | | closeWebSocket(socket); |
| | | closeWebSocket(socket); |
| | | } |
| | | }); |
| | | }); |
| | | onBeforeUnmount(() => { |
| | | console.log("关闭了") |
| | | closeWebSocket(); |
| | | }); |
| | | </script> |
| | | <template> |
| | | <div> |
| | | <el-card style="flex: 1;margin-left: 10px;margin-top: 20px;" v-loading="loading"> |
| | | <el-select v-model="selectValuesa[0]" filterable :placeholder="$t('workOrder.cway')" clearable style="margin-left: 20px;margin-bottom: 10px;"> |
| | | <el-option :label="$t('workOrder.edgingone')" value="2001"></el-option> |
| | | <el-option :label="$t('workOrder.edgingtwo')" value="2002"></el-option> |
| | | </el-select> |
| | | |
| | | <el-select v-model="selectValuesa[1]" filterable :placeholder="$t('workOrder.cstate')" clearable style="margin-left: 20px;margin-bottom: 10px;" > |
| | | <el-option :label="$t('workOrder.nedging')" value="0"></el-option> |
| | | <el-option :label="$t('workOrder.edging')" value="1"></el-option> |
| | | <el-option :label="$t('workOrder.finedging')" value="2"></el-option> |
| | | <div style="height: 500px;"> |
| | | <div> |
| | | <el-card style="flex: 1;margin-left: 10px;margin-top: 20px;" v-loading="loading"> |
| | | <el-select v-model="selectValuesa[0]" filterable :placeholder="$t('workOrder.cway')" clearable |
| | | style="margin-left: 20px;margin-bottom: 10px;"> |
| | | <el-option :label="$t('workOrder.edgingone')" value="2001"></el-option> |
| | | <el-option :label="$t('workOrder.edgingtwo')" value="2002"></el-option> |
| | | </el-select> |
| | | |
| | | <el-select v-model="selectValuesa[1]" filterable :placeholder="$t('workOrder.cstate')" clearable |
| | | style="margin-left: 20px;margin-bottom: 10px;"> |
| | | <el-option :label="$t('workOrder.nedging')" value="0"></el-option> |
| | | <el-option :label="$t('workOrder.edging')" value="1"></el-option> |
| | | <el-option :label="$t('workOrder.finedging')" value="2"></el-option> |
| | | </el-select> |
| | | <span class="demonstration" style="margin-left: 20px;margin-bottom: 10px;">{{ $t('workOrder.time') }}</span> |
| | | <el-date-picker v-model="timeRange" type="datetimerange" range-separator="至" :start-placeholder="$t('reportmanage.starttime')" style="margin-left: 20px;margin-bottom: 10px;" value-format = "YYYY-MM-DD hh:mm:ss" |
| | |
| | | {{ scope.row.status==0?"未磨边":scope.row.status==1?"磨边中":"已磨边" }} |
| | | </template> |
| | | </el-table-column> |
| | | |
| | | |
| | | |
| | | |
| | | <el-table-column fixed="right" :label="$t('workOrder.operate')" align="center" width="200"> |
| | | <template #default="scope"> |
| | | <el-button size="mini" type="text" plain @click="open(scope.row)">{{ $t('workOrder.breakage') }}</el-button> |
| | | <el-button size="mini" type="text" plain @click="opena(scope.row)">{{ $t('workOrder.takeout') }}</el-button> |
| | | <el-button size="mini" type="text" plain @click="open(scope.row)">{{ |
| | | $t('workOrder.breakage') |
| | | }} |
| | | </el-button> |
| | | <el-button size="mini" type="text" plain @click="opena(scope.row)">{{ |
| | | $t('workOrder.takeout') |
| | | }} |
| | | </el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table-column> |
| | | </el-table> |
| | | </div> |
| | | </el-card> |
| | | </el-card> |
| | | </div> |
| | | </div> |
| | | </template> |
| | | |