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: 'userId',
    align:"center",
    dataIndex: 'userId'
   },
   {
    title: '店主名',
    align:"center",
    dataIndex: 'userName'
   },
   {
    title: '手机号',
    align:"center",
    dataIndex: 'phone'
   },
   {
    title: 'latitude',
    align:"center",
    dataIndex: 'latitude'
   },
   {
    title: 'longitude',
    align:"center",
    dataIndex: 'longitude'
   },
   {
    title: '地址',
    align:"center",
    dataIndex: 'address'
   },
   {
    title: 'delFlag',
    align:"center",
    dataIndex: 'delFlag_dictText'
   },
];
//查询数据
export const searchFormSchema: FormSchema[] = [
];
//表单数据
export const formSchema: FormSchema[] = [
  {
    label: '商铺名',
    field: 'name',
    component: 'Input',
  },
  {
    label: 'userId',
    field: 'userId',
    component: 'Input',
  },
  {
    label: '店主名',
    field: 'userName',
    component: 'Input',
  },
  {
    label: '手机号',
    field: 'phone',
    component: 'Input',
  },
  {
    label: 'latitude',
    field: 'latitude',
    component: 'Input',
  },
  {
    label: 'longitude',
    field: 'longitude',
    component: 'Input',
  },
  {
    label: '地址',
    field: 'address',
    component: 'Input',
  },
  {
    label: 'delFlag',
    field: 'delFlag',
    component: 'JDictSelectTag',
    componentProps:{
        dictCode:""
     },
    dynamicRules: ({model,schema}) => {
          return [
                 { required: true, message: '请输入delFlag!'},
          ];
     },
  },
];
