| | |
| | | prop="taskType" |
| | | > |
| | | <template #default="scope"> |
| | | <el-tag :type="getStatusText1(scope.row.taskType)"> |
| | | {{ getStatusType1(scope.row.taskType) }} |
| | | <el-tag :type="getStatusType1(scope.row.taskType)"> |
| | | {{ getStatusText1(scope.row.taskType) }} |
| | | </el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="createTime" align="center" :label="$t('reportmanage.starttime')" min-width="100" /> |
| | | <el-table-column prop="updateTime" align="center" :label="$t('reportmanage.endtime')" min-width="100" /> |
| | | <el-table-column prop="formattedCreateTime" align="center" :label="$t('reportmanage.starttime')" min-width="100" /> |
| | | <el-table-column prop="formattedUpdateTime" align="center" :label="$t('reportmanage.endtime')" min-width="100" /> |
| | | </el-table> |
| | | <div style="margin-top: 20px;margin-left: 40%;"> |
| | | <el-pagination |
| | |
| | | }) |
| | | if (response.code == 200) { |
| | | ElMessage.success(response.message); |
| | | tableDatax.value = response.data.records; |
| | | console.log(response.data.pages); |
| | | |
| | | const formattedData = response.data.records.map(record => ({ |
| | | ...record, |
| | | formattedCreateTime: formatTimestamp(record.createTime), |
| | | formattedUpdateTime: formatTimestamp(record.updateTime), |
| | | })); |
| | | // tableDatax.value = response.data.records; |
| | | tableDatax.value = formattedData; |
| | | totalRecords.value = response.data.total/2 || 0 |
| | | } else { |
| | | ElMessage.error(response.message); |
| | |
| | | historicala(currentPage2.value); |
| | | }; |
| | | const historicala = async (page) => { |
| | | try { |
| | | let page = window.localStorage.getItem('pagenumber') |
| | | let startTime = window.localStorage.getItem('startTime') |
| | | const response = await request.post("/glassStorage/rawGlassStorageTask/queryRawGlassHistoryTask", { |
| | | pageNo: page, |
| | | pageSize: 20, |
| | | taskState: [], |
| | | taskType: [], |
| | | beginDate: startTime, |
| | | endDate: getglobalDate |
| | | }) |
| | | if (response.code == 200) { |
| | | ElMessage.success(response.message); |
| | | tableDatax.value = response.data.records; |
| | | console.log(response.data.pages); |
| | | |
| | | totalRecords.value = response.data.total/2 || 0 |
| | | } else { |
| | | ElMessage.error(response.message); |
| | | } |
| | | } |
| | | catch (error) { |
| | | console.error(error); |
| | | } |
| | | } |
| | | // 历史查询点击 |
| | | const sethistorical = async () => { |
| | | try { |
| | | let startTime = window.localStorage.getItem('startTime') |
| | | let celllist=[] |
| | |
| | | pageSize: 20, |
| | | taskState: celllist, |
| | | taskType: stateList, |
| | | beginDate: startTime, |
| | | endDate: getglobalDate |
| | | beginDate: (timeRange.value && timeRange.value[0]) || '', |
| | | endDate: (timeRange.value && timeRange.value[1]) || '', |
| | | }) |
| | | if (response.code == 200) { |
| | | ElMessage.success(response.message); |
| | | tableDatax.value = response.data.records; |
| | | const formattedData = response.data.records.map(record => ({ |
| | | ...record, |
| | | formattedCreateTime: formatTimestamp(record.createTime), |
| | | formattedUpdateTime: formatTimestamp(record.updateTime), |
| | | })); |
| | | // tableDatax.value = response.data.records; |
| | | tableDatax.value = formattedData; |
| | | totalRecords.value = response.data.total/2 || 0 |
| | | } else { |
| | | ElMessage.error(response.message); |
| | | } |
| | | } |
| | | catch (error) { |
| | | console.error(error); |
| | | } |
| | | } |
| | | // 历史查询点击 |
| | | const sethistorical = async () => { |
| | | try { |
| | | let startTime = window.localStorage.getItem('startTime') |
| | | let celllist=[] |
| | | let stateList=[] |
| | | let pstartSlot= '' |
| | | let ptargetSlot='' |
| | | if(selectValuesa[0]!=null&&selectValuesa[0]!='undefined'){ |
| | | if(selectValuesa[0]!=""){ |
| | | celllist=[selectValuesa[0]]; |
| | | } |
| | | } |
| | | if(selectValuesa[1]!=null&&selectValuesa[1]!='undefined'){ |
| | | if(selectValuesa[1]!=""){ |
| | | stateList=[selectValuesa[1]]; |
| | | } |
| | | } |
| | | if(startSlot.value != ""){ |
| | | pstartSlot = startSlot.value |
| | | }else{ |
| | | pstartSlot = '0' |
| | | } |
| | | if(targetSlot.value != ""){ |
| | | ptargetSlot = targetSlot.value |
| | | }else{ |
| | | ptargetSlot = '0' |
| | | } |
| | | let page = window.localStorage.getItem('pagenumber') |
| | | const response = await request.post("/glassStorage/rawGlassStorageTask/queryRawGlassHistoryTask", { |
| | | pageNo: 1, |
| | | pageSize: 20, |
| | | taskState: celllist, |
| | | taskType: stateList, |
| | | beginDate: (timeRange.value && timeRange.value[0]) || '', |
| | | endDate: (timeRange.value && timeRange.value[1]) || '', |
| | | }) |
| | | if (response.code == 200) { |
| | | ElMessage.success(response.message); |
| | | currentPage2.value = 1; |
| | | const formattedData = response.data.records.map(record => ({ |
| | | ...record, |
| | | formattedCreateTime: formatTimestamp(record.createTime), |
| | | formattedUpdateTime: formatTimestamp(record.updateTime), |
| | | })); |
| | | // tableDatax.value = response.data.records; |
| | | tableDatax.value = formattedData; |
| | | totalRecords.value = response.data.total/2 || 0 |
| | | } else { |
| | | ElMessage.error(response.message); |
| | | } |