Browse Source

序号

master
han\hanst 17 hours ago
parent
commit
ee993dc91d
  1. 31
      src/views/modules/longtron/screen-renovation-progress.vue
  2. 7
      src/views/modules/longtron/screen-whole-lift-progress.vue

31
src/views/modules/longtron/screen-renovation-progress.vue

@ -46,7 +46,7 @@
<span class="section-count"> {{ renovationPage + 1 }}/{{ renovationPageCount }} · 显示 {{ displayRenovationList.length }} / {{ renovationList.length }} </span>
</div>
<el-table class="board-table" :data="displayRenovationList" :height="tableHeightTop" border stripe>
<el-table-column type="index" label="序号" width="54" align="center"></el-table-column>
<el-table-column type="index" :index="renovationPage * topRowLimit + 1" label="序号" width="54" align="center"></el-table-column>
<el-table-column prop="projectNo" label="项目号" min-width="80" align="center"></el-table-column>
<el-table-column prop="floors" label="楼层" min-width="70" align="center"></el-table-column>
<el-table-column prop="planFinishDate" label="计划完工日期" min-width="100" align="center"></el-table-column>
@ -65,7 +65,7 @@
<span class="section-count"> {{ cableCopPage + 1 }}/{{ cableCopPageCount }} · 显示 {{ displayCableCopList.length }} / {{ cableCopList.length }} </span>
</div>
<el-table class="board-table" :data="displayCableCopList" :height="tableHeightBottom" border stripe>
<el-table-column type="index" label="序号" width="54" align="center"></el-table-column>
<el-table-column type="index" :index="cableCopPage * bottomRowLimit + 1" label="序号" width="54" align="center"></el-table-column>
<el-table-column prop="projectNo" label="项目号" min-width="126" align="center"></el-table-column>
<el-table-column prop="taskType" label="任务类型" min-width="96" align="center">
<template slot-scope="scope">
@ -81,7 +81,6 @@
<el-tag class="board-tag" :class="getStatusTagClass(scope.row.status)" size="small">{{ scope.row.status }}</el-tag>
</template>
</el-table-column>
<el-table-column prop="finishDate" label="完工时间" width="118" align="center"><template slot-scope="scope">{{ scope.row.finishDate || '-' }}</template></el-table-column>
</el-table>
</div>
@ -91,7 +90,7 @@
<span class="section-count"> {{ machiningPage + 1 }}/{{ machiningPageCount }} · 显示 {{ displayMachiningList.length }} / {{ machiningList.length }} </span>
</div>
<el-table class="board-table" :data="displayMachiningList" :height="tableHeightBottom" border stripe>
<el-table-column type="index" label="序号" width="54" align="center"></el-table-column>
<el-table-column type="index" :index="machiningPage * bottomRowLimit + 1" label="序号" width="54" align="center"></el-table-column>
<el-table-column prop="modelNo" label="物料号" min-width="170" align="center"></el-table-column>
<el-table-column prop="materialSpec" label="规格" min-width="120" align="center" show-overflow-tooltip></el-table-column>
<el-table-column prop="taskQty" label="计划数量" min-width="88" align="center"></el-table-column>
@ -102,9 +101,6 @@
<el-tag class="board-tag" :class="getStatusTagClass(scope.row.status)" size="small">{{ scope.row.status }}</el-tag>
</template>
</el-table-column>
<el-table-column prop="finishDate" label="实际完工日期" min-width="120" align="center">
<template slot-scope="scope">{{ scope.row.finishDate || '-' }}</template>
</el-table-column>
</el-table>
</div>
</div>
@ -116,6 +112,7 @@ import { getCableCopTaskList, getMachiningTaskList, getRenovationOrderList } fro
import { getScreenInnerHeight } from '@/utils/screenAdapt'
const STATUS_ALLOW_LIST = ['已排产', '进行中', '已完成']
const STATUS_EXCLUDE_FROM_LIST = ['已完成']
const RENOVATION_NODE_TEMPLATE = ['stocking', 'assy', 'inspect', 'pack']
const CABLE_COP_NODE_TEMPLATE = ['lineProduction', 'copProduction']
const BOARD_PAGE_SIZE = 6
@ -207,12 +204,17 @@ export default {
getCableCopTaskList(params).catch(() => null),
getMachiningTaskList(params).catch(() => null)
]).then(([renovationRes, cableCopRes, machiningRes]) => {
this.renovationList = this.buildRenovationList(this.getListFromResponse(renovationRes))
this.cableCopList = this.buildCableCopList(this.getListFromResponse(cableCopRes))
this.machiningList = this.buildMachiningList(this.getListFromResponse(machiningRes))
this.renovationKpi = this.buildKpi(this.renovationList)
this.cableCopKpi = this.buildKpi(this.cableCopList)
this.machiningKpi = this.buildKpi(this.machiningList)
const renovationFullList = this.buildRenovationList(this.getListFromResponse(renovationRes))
const cableCopFullList = this.buildCableCopList(this.getListFromResponse(cableCopRes))
const machiningFullList = this.buildMachiningList(this.getListFromResponse(machiningRes))
this.renovationKpi = this.buildKpi(renovationFullList)
this.cableCopKpi = this.buildKpi(cableCopFullList)
this.machiningKpi = this.buildKpi(machiningFullList)
this.renovationList = this.excludeFinishedList(renovationFullList)
this.cableCopList = this.excludeFinishedList(cableCopFullList)
this.machiningList = this.excludeFinishedList(machiningFullList)
this.normalizeCarouselPage()
}).finally(() => {
this.loading = false
@ -259,6 +261,9 @@ export default {
const list = data && data.code === 0 && data.page && Array.isArray(data.page.list) ? data.page.list : null
return list || this.getMockList()
},
excludeFinishedList(list) {
return (list || []).filter(item => !STATUS_EXCLUDE_FROM_LIST.includes(item.status))
},
buildRenovationList(sourceList) {
return (sourceList || [])
.filter(item => STATUS_ALLOW_LIST.includes(item.status))

7
src/views/modules/longtron/screen-whole-lift-progress.vue

@ -29,7 +29,6 @@
<el-table-column label="门组装" width="95" align="center"><template slot-scope="scope"><span :class="getNodeCellClass(scope.row, 'doorAssy')"></span></template></el-table-column>
<el-table-column label="打包" width="90" align="center"><template slot-scope="scope"><span :class="getNodeCellClass(scope.row, 'pack')"></span></template></el-table-column>
<el-table-column prop="status" label="订单状态" width="100" align="center"><template slot-scope="scope"><el-tag class="board-tag" :class="getOrderStatusClass(scope.row.status)" size="small">{{ scope.row.status }}</el-tag></template></el-table-column>
<el-table-column prop="finishDate" label="完工时间" width="120" align="center"><template slot-scope="scope">{{ scope.row.finishDate || '-' }}</template></el-table-column>
</el-table>
</div>
</template>
@ -39,6 +38,7 @@ import { getHomeLiftOrderList } from '@/api/longchuang/productionPlan'
import { getScreenInnerHeight } from '@/utils/screenAdapt'
const NODE_TEMPLATE = ['stocking', 'platformDebug', 'bgCeiling', 'doorAssy', 'pack']
const DISPLAY_STATUS_LIST = ['已排产', '进行中']
export default {
name: 'ScreenWholeLiftProgress',
@ -83,8 +83,7 @@ export default {
loadBoardData() {
if (this.loading) return
this.loading = true
let statusList = ['已排产', '进行中', '已完成']
getHomeLiftOrderList({ page: 1, limit: 300,statusList: statusList}).then(({data}) => {
getHomeLiftOrderList({ page: 1, limit: 300, statusList: DISPLAY_STATUS_LIST }).then(({data}) => {
this.loading = false
const source = (data && data.code === 0 && data.page && data.page.list) ? data.page.list : this.getMockList()
this.boardList = this.buildBoardList(source)
@ -94,7 +93,7 @@ export default {
})
},
buildBoardList(sourceList) {
const statusAllow = ['已排产', '进行中', '已完成']
const statusAllow = DISPLAY_STATUS_LIST
return sourceList.filter(item => statusAllow.includes(item.status)).map(item => ({
projectNo: item.projectNo || '',
modelNo: item.modelNo || '',

Loading…
Cancel
Save