<template>
	<div class="list_box">
		<Table
			:tableData="datas.tableData"
			:columns="datas.columns"
			:cell-class-name="tableCellClassName"
			:tableOptions="{
				maxHeight: '430',
				// isLoading: isLoading,
			}"
			:isFixed="true"
			:isCheckend="true"
			@select="selectRow"
			@select-all="selectRow"
			ref="multipleTable"
		/>
	</div>
</template>

<script setup>
import Table from './components/Table';
import { COLUMNS } from './constant/index.js';
import { approvalFlowList } from '@/utils/api.js';
import { reactive, getCurrentInstance } from 'vue';
const { proxy } = getCurrentInstance();
const { $http } = proxy;
const datas = reactive({
	columns: COLUMNS,
	tableData: [
		{
			billNo: 'SP202303270001',
			name: '通用不带电源',
			useOrderType: '采购订单',
			date: '2023-03-27 11:02:30',
			maintainerName: '杨春龙',
		},
		{
			billNo: 'SP202303270002',
			name: '通用不带电源1',
			useOrderType: '采购订单1',
			date: '2023-03-27 11:02:30',
			maintainerName: '杨春龙',
		},
		{
			billNo: 'SP202303270003',
			name: '通用不带电源2',
			useOrderType: '采购订单2',
			date: '2023-03-27 11:02:30',
			maintainerName: '杨春龙',
		},
	],
});
//获取列表数据
const getList = () => {
	$http.post(approvalFlowList).then((res) => {
		if (res.status == 200) {
			tableData = res.data.list;
			console.log(res.data, '请求成功');
		}
	});
};
</script>

<style lang="scss" scoped>
.list_box {
	width: 100%;
	height: 100%;
	// margin: 16px;
	background: red;
}
</style>
