一、 crud.js
import dayjs from 'dayjs'
import { GetDetail } from './api'
import { request } from '@/api/service'
export const crudOptions = (vm) => {
return {
rowHandle: {
// width: 230,
// dropdown: { // 操作列折叠
// atLeast: 1, // 至少几个以上的按钮才会被折叠,注意show=false的按钮也会计算在内(行编辑按钮默认是隐藏的也会占一个位置)
// text: '更多', // dropdown按钮文字
// type: 'primary',
// icon: 'el-icon-more'
// },
expandRow: { // 或者直接传true,不显示title,不居中
title: '展开',
align: 'center'
},
edit: {
icon: 'el-icon-edit',
text:'编辑',
size: 'mini',
show (index, row) {
return false
},
},
fixed: 'right'
},
options:{
height: '100%'
},
columns: [
{
title: '基本标