import type { VbenFormProps } from '#/adapter/form';

/**
 * 开票中心列表搜索表单
 */
export const formOptions: VbenFormProps = {
  collapsed: false,
  schema: [
    {
      component: 'Input',
      componentProps: {
        placeholder: '订单号 / 抬头 / 邮箱',
        allowClear: true,
      },
      fieldName: 'keyword',
      label: '关键词',
    },
    {
      component: 'Input',
      componentProps: {
        placeholder: '订单号',
        allowClear: true,
      },
      fieldName: 'order_no',
      label: '订单号',
    },
    {
      component: 'Select',
      componentProps: {
        placeholder: '接收方式',
        allowClear: true,
        options: [
          { label: '全部', value: '' },
          { label: '小程序下载', value: 1 },
          { label: '邮箱接收', value: 2 },
        ],
      },
      defaultValue: '',
      fieldName: 'receive_type',
      label: '接收方式',
    },
  ],
  showCollapseButton: false,
  submitButtonOptions: { content: '查询' },
  submitOnChange: false,
  submitOnEnter: true,
};
