footerLeft.vue 2.6 KB
<template>
	<div class="dv-content-body-bottom-list-center">
		<dv-border-box-12 :dur="35">
			<div style="width: 100; height: 13%;padding-top: 0.5vw">
				<span class="div-span-title"> CNC机床任务信息</span>
			</div>
			<div style="width: 100%; height: 88%">
				<dv-scroll-board :config="productionInformationTable" style="width: 97%; margin-left: 0.4vw" />
			</div>
		</dv-border-box-12>
	</div>
</template>

<script>
export default {
	data() {
		return {
			sysData: {},

			productionInformationTable: null,
			optTableproductionInformation: '',
			productionInformation: {
				header: ['设备', '开机时间', '运行时间', '已加工数量', '当前刀号'],
				data: [
					['成品仓', '470 小时 57 分钟 0 秒', '55 小时 22 分钟 17 秒', '61', '0'],
					['成品仓', '470 小时 57 分钟 0 秒', '55 小时 22 分钟 17 秒', '61', '0'],
				],
				align: ['left'],
				headerBGC: '#201e1e', //表头
				oddRowBGC: '#021c66',
				evenRowBGC: '#65,105,225',
				rowNum: 5,
				columnWidth: [130, 90, 120, 80],
				headerHeight: 25,
				carousel: 'page',
				waitTime: 8000,
			},
		}
	},
	methods: {
		bingDataSource(data) {
			let listData = []
			data.forEach((item) => {
				listData.push([item.equipmentName, item.runTime, item.produceCount, item.cutterKnifeNumber])
			})
			this.initproductionInformationTable(listData)
		},
		initproductionInformationTable(e) {
			this.productionInformationTable = {
				header: ['设备', '运行时间', '已加工数', '当前刀号'],
				data: e,
				align: ['left'],
				headerBGC: '#201e1e', //表头
				oddRowBGC: '#021c66',
				evenRowBGC: '#65,105,225',
				rowNum: 4,
				columnWidth: [100, 130, 130, 130],
				headerHeight: 25,
				carousel: 'page',
				waitTime: 8000,
			}
		},
		ajaxSuccessDataBefore(res, title) {
			if (res.data.result == null || res.data.result.length == 0) {
				''.Log(title + '无数据', 'getData')
				this.initproductionInformationTable([])
				return false
			}
			return true
		},
	},
	mounted() {
		//eslint-disable-next-line no-debugger
		debugger
	},
}
</script>

<style scoped>
.dv-content-body-bottom-list-center {
	width: 33vw;
	height: 95%;
	/* background-color: #a5c8ca; */
}
.dv-scroll-board .rows .row-item {
	font-size: 12px !important;
}
</style>
<style lang="scss">
/*datav-表格-表头样式*/
.app-body {
	.dv-scroll-board .header {
		display: flex;
		flex-direction: row;
		font-size: 1.4vw !important;
		font-weight: 600 !important;
	}
	/*datav-表格-数据样式*/
	.dv-scroll-board .rows .ceil {
		font-size: 1.25vw;
	}
	/*datav-表格-行间距*/
	.dv-scroll-board .rows .row-item {
		padding-top: 2px 0 0 2px;
	}
}
</style>