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: 'processScore'
   },
   {
    title: '景点分数',
    align:"center",
    dataIndex: 'spotScore'
   },
   {
    title: '导师分数',
    align:"center",
    dataIndex: 'teacherScore'
   },
   {
    title: '活动掠影',
    align:"center",
    dataIndex: 'image',
    customRender:render.renderAvatar,
   },
   {
    title: '学员心得',
    align:"center",
    dataIndex: 'content'
   },
   {
    title: '关联活动',
    align:"center",
    dataIndex: 'activityId_dictText'
   },
   {
    title: '关联用户',
    align:"center",
    dataIndex: 'userId_dictText'
   },
];
//查询数据
export const searchFormSchema: FormSchema[] = [
];
//表单数据
export const formSchema: FormSchema[] = [
  {
    label: '行程分数',
    field: 'processScore',
    component: 'InputNumber',
  },
  {
    label: '景点分数',
    field: 'spotScore',
    component: 'InputNumber',
  },
  {
    label: '导师分数',
    field: 'teacherScore',
    component: 'InputNumber',
  },
  {
    label: '活动掠影',
    field: 'image',
     component: 'JImageUpload',
     componentProps:{
      },
  },
  {
    label: '学员心得',
    field: 'content',
    component: 'InputTextArea',//TODO 注意string转换问题
  },
  {
    label: '关联活动',
    field: 'activityId',
    component: 'JDictSelectTag',
    componentProps:{
        dictCode:"studytour_activity,title,id"
     },
  },
  {
    label: '关联用户',
    field: 'userId',
    component: 'JSearchSelect',
    componentProps:{
       dict:"han_hai_member,nick_name,id"
    },
  },
];
