| | |
| | | <template> |
| | | <div> |
| | | <div style="display: flex;width: 1770px;"> |
| | | <el-date-picker v-model="timeRange" type="datetimerange" range-separator="至" |
| | | :start-placeholder="$t('reportmanage.starttime')" style="margin-left: 15px;" value-format="YYYY-MM-DD hh:mm:ss" |
| | | :end-placeholder="$t('reportmanage.endtime')"> |
| | | <el-date-picker v-model="timeRange" type="daterange" range-separator="至" |
| | | :start-placeholder="$t('reportmanage.starttime')" :end-placeholder="$t('reportmanage.endtime')" |
| | | value-format="YYYY-MM-DD" style="margin-left: 15px;"> |
| | | </el-date-picker> |
| | | <el-button type="primary" style="margin-left: 10px;margin-bottom: 10px;" |
| | | @click="sethistorical()">{{ $t('reportmanage.inquire') }}</el-button> |
| | | <el-button type="primary" style="margin-left: 10px;margin-bottom: 10px;" @click="sethistorical()">{{ |
| | | $t('reportmanage.inquire') }}</el-button> |
| | | </div> |
| | | <el-table ref="table" style="margin-top: 20px;height: 580px;width: 1770px;" :data="tableDatax" |
| | | :header-cell-style="{ background: '#F2F3F5 ', color: '#1D2129' }"> |
| | | <el-table-column prop="date" align="center" :label="$t('large.date')" min-width="70" /> |
| | | <el-table-column prop="countOutOne" align="center" :label="$t('large.countOutOne')" min-width="40" /> |
| | | <el-table-column prop="totalAreaOutOne" align="center" :label="$t('large.totalAreaOutOne')" min-width="40" /> |
| | | <el-table-column prop="countOutTwo" align="center" :label="$t('large.countOutTwo')" min-width="50" /> |
| | | <el-table-column prop="totalAreaOutTwo" align="center" :label="$t('large.totalAreaOutTwo')" min-width="50" /> |
| | | <el-table-column prop="countIn" align="center" :label="$t('large.countIn')" min-width="50" /> |
| | | <el-table-column prop="totalAreaIn" align="center" :label="$t('large.totalAreaIn')" min-width="50" /> |
| | | <el-table-column prop="countOut" align="center" :label="$t('large.countOut')" min-width="40" /> |
| | | <el-table-column prop="totalAreaOut" align="center" :label="$t('large.totalAreaOut')" min-width="40" /> |
| | | <el-table-column prop="hollowCountOutOne" align="center" :label="$t('large.hollowCountOutOne')" min-width="40" /> |
| | | <el-table-column prop="hollowTotalAreaOutOne" align="center" :label="$t('large.hollowTotalAreaOutOne')" min-width="40" /> |
| | | <el-table-column prop="hollowCountOutTwo" align="center" :label="$t('large.hollowCountOutTwo')" min-width="40" /> |
| | | <el-table-column prop="hollowTotalAreaOutTwo" align="center" :label="$t('large.hollowTotalAreaOutTwo')" |
| | | min-width="40"/> |
| | | <el-table-column prop="countOutOne" align="center" :label="$t('large.countOutOne')" min-width="40" /> |
| | | <el-table-column prop="totalAreaOutOne" align="center" :label="$t('large.totalAreaOutOne')" min-width="40" /> |
| | | <el-table-column prop="countOutTwo" align="center" :label="$t('large.countOutTwo')" min-width="50" /> |
| | | <el-table-column prop="totalAreaOutTwo" align="center" :label="$t('large.totalAreaOutTwo')" min-width="50" /> |
| | | <el-table-column prop="countIn" align="center" :label="$t('large.countIn')" min-width="50" /> |
| | | <el-table-column prop="totalAreaIn" align="center" :label="$t('large.totalAreaIn')" min-width="50" /> |
| | | <el-table-column prop="countOut" align="center" :label="$t('large.countOut')" min-width="40" /> |
| | | <el-table-column prop="totalAreaOut" align="center" :label="$t('large.totalAreaOut')" min-width="40" /> |
| | | <el-table-column prop="hollowCountOutOne" align="center" :label="$t('large.hollowCountOutOne')" min-width="40" /> |
| | | <el-table-column prop="hollowTotalAreaOutOne" align="center" :label="$t('large.hollowTotalAreaOutOne')" |
| | | min-width="40" /> |
| | | <el-table-column prop="hollowCountOutTwo" align="center" :label="$t('large.hollowCountOutTwo')" min-width="40" /> |
| | | <el-table-column prop="hollowTotalAreaOutTwo" align="center" :label="$t('large.hollowTotalAreaOutTwo')" |
| | | min-width="40" /> |
| | | </el-table> |
| | | <div style="margin-top: 20px;margin-left: 40%;"> |
| | | <el-pagination v-model:current-page="currentPage2" :page-size="pageSize" :size="large" :disabled="disabled" |
| | |
| | | })); |
| | | // tableDatax.value = response.data.records; |
| | | tableDatax.value = formattedData; |
| | | console.log(response.data.pages); |
| | | totalRecords.value = response.data.total / 2 || 0 |
| | | } else { |
| | | ElMessage.error(response.message); |
| | |
| | | } |
| | | const handlePageChange2 = (newPage) => { |
| | | currentPage2.value = newPage; |
| | | console.log(currentPage2.value); |
| | | window.localStorage.setItem('pagenumber', currentPage2.value) |
| | | historicala(currentPage2.value); |
| | | }; |
| | |
| | | } |
| | | let startTime = window.localStorage.getItem('startTime') |
| | | let page = window.localStorage.getItem('pagenumber') |
| | | console.log(page); |
| | | const response = await request.post("/loadGlass/largenScreen/queryDailyProduction", { |
| | | pageNo: 1, |
| | | pageSize: 20, |
| | |
| | | const backendTime = new Date(getglobalDate); |
| | | const oneWeekAgo = new Date(backendTime.getTime() - 7 * 24 * 60 * 60 * 1000); // 减去7天 |
| | | oneWeekAgo.setHours(0, 0, 0, 0); |
| | | console.log(formatTimestamp(oneWeekAgo)); |
| | | console.log(oneWeekAgo); |
| | | timeRange.value = [formatTimestamp(oneWeekAgo), formatTimestamp(backendTime)]; |
| | | window.localStorage.setItem('startTime', formatTimestamp(oneWeekAgo)) |
| | | } |
| | |
| | | return 'primary'; |
| | | case 1: |
| | | return 'success'; |
| | | } |
| | | } |
| | | function getStatusTexta(taskRunning: number) { |
| | | switch (taskRunning) { |
| | | case 0: |
| | | return t('basicData.untask'); |
| | | case 1: |
| | | return t('basicData.up'); |
| | | } |
| | | } |
| | | onMounted(() => { |