data.ts 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. import type { VxeTableGridOptions } from '@vben/plugins/vxe-table';
  2. import type { VbenFormSchema } from '#/adapter/form';
  3. import type { SystemModel } from '#/api/method/system';
  4. import { $t } from '#/locales';
  5. export function useTisaneSearchFormSchema(): VbenFormSchema[] {
  6. return [
  7. {
  8. component: 'Input',
  9. fieldName: 'name',
  10. label: $t('system.tisane.name'),
  11. },
  12. {
  13. component: 'Input',
  14. fieldName: 'relatedEnterprise',
  15. label: $t('system.tisane.relatedEnterprise'),
  16. },
  17. ];
  18. }
  19. export function useTisaneTableColumns(): VxeTableGridOptions<SystemModel.Tisane>['columns'] {
  20. return [
  21. { type: 'seq', title: $t('table.column.seq'), width: 50 },
  22. {
  23. field: 'name',
  24. title: $t('system.tisane.name'),
  25. minWidth: 120,
  26. },
  27. {
  28. field: 'code',
  29. title: $t('system.tisane.code'),
  30. minWidth: 100,
  31. },
  32. {
  33. field: 'type',
  34. title: $t('system.tisane.type'),
  35. minWidth: 120,
  36. },
  37. {
  38. field: 'relatedOrganizations',
  39. title: $t('system.tisane.relatedOrganization'),
  40. minWidth: 120,
  41. },
  42. {
  43. field: 'relatedEnterprise',
  44. title: $t('system.tisane.relatedEnterprise'),
  45. minWidth: 120,
  46. },
  47. {
  48. field: 'remark',
  49. title: $t('system.tisane.remark'),
  50. minWidth: 100,
  51. },
  52. {
  53. field: 'createTime',
  54. title: $t('system.tisane.createTime'),
  55. minWidth: 160,
  56. },
  57. {
  58. field: 'createUser',
  59. title: $t('system.tisane.createUser'),
  60. minWidth: 100,
  61. },
  62. ];
  63. }
  64. export function useTisaneFormSchema(): VbenFormSchema[] {
  65. return [];
  66. }