import {BasicColumn} from '/@/components/Table';
import {FormSchema} from '/@/components/Table';
import { rules} from '/@/utils/helper/validator';
import { render } from '/@/utils/common/renderUtils';
//列表数据
export const columns: BasicColumn[] = [
    {
    title: '会员名称',
    align:"center",
    dataIndex: 'name'
   },
   {
    title: '会员开通金额',
    align:"center",
    dataIndex: 'price'
   },
   {
    title: '充值类型',
    align:"center",
    dataIndex: 'recharge_dictText'
   },
   {
    title: '专属特权',
    align:"center",
    dataIndex: 'perquisite'
   },
   {
    title: '会员类型',
    align:"center",
    dataIndex: 'type_dictText'
   },
];
//查询数据
export const searchFormSchema: FormSchema[] = [
	{
      label: "会员名称",
      field: "name",
      component: 'Input',
      colProps: {span: 6},
 	},
	{
      label: "充值类型",
      field: "recharge",
      component: 'JDictSelectTag',
      componentProps:{
          dictCode:"employ_recharge"
      },
      colProps: {span: 6},
 	},
	{
      label: "会员类型",
      field: "type",
      component: 'JDictSelectTag',
      componentProps:{
          dictCode:"employ_vip_type"
      },
      colProps: {span: 6},
 	},
];
//表单数据
export const formSchema: FormSchema[] = [
  {
    label: '会员名称',
    field: 'name',
    component: 'Input',
  },
  {
    label: '会员开通金额',
    field: 'price',
    component: 'InputNumber',
  },
  {
    label: '充值类型',
    field: 'recharge',
    component: 'JDictSelectTag',
    componentProps:{
        dictCode:"employ_recharge"
     },
  },
  {
    label: '专属特权',
    field: 'perquisite',
    component: 'InputTextArea',//TODO 注意string转换问题
  },
  {
    label: '会员类型',
    field: 'type',
    component: 'JDictSelectTag',
    componentProps:{
        dictCode:"employ_vip_type"
     },
  },
];
