file.data.ts 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. import { BasicColumn, FormSchema } from '/@/components/Table';
  2. export const columns: BasicColumn[] = [
  3. {
  4. title: '文件描述',
  5. width: 150,
  6. dataIndex: 'des',
  7. },
  8. {
  9. title: '文件名',
  10. width: 150,
  11. dataIndex: 'fileName',
  12. },
  13. {
  14. title: '文件类型',
  15. dataIndex: 'fileType',
  16. width: 140,
  17. },
  18. {
  19. title: '文件',
  20. width: 150,
  21. dataIndex: 'path',
  22. },
  23. // {
  24. // title: '操作',
  25. // width: 150,
  26. // dataIndex: 'operation',
  27. // },
  28. ];
  29. export const searchFormSchema: FormSchema[] = [
  30. {
  31. label: '文件名',
  32. field: 'fileName',
  33. component: 'Input',
  34. colProps: { span: 6 },
  35. },
  36. {
  37. label: '文件描述',
  38. field: 'des',
  39. component: 'Input',
  40. colProps: { span: 6 },
  41. },
  42. ];
  43. export const formSchema: FormSchema[] = [
  44. {
  45. field: 'id',
  46. label: 'id',
  47. component: 'Input',
  48. show: false,
  49. },
  50. // {
  51. // field: 'fileName',
  52. // label: '文件名',
  53. // component: 'Input',
  54. // },
  55. {
  56. field: 'des',
  57. label: '文件描述',
  58. component: 'Input',
  59. },
  60. {
  61. field: 'fileType',
  62. label: '文件类型',
  63. component: 'RadioGroup',
  64. defaultValue: 1,
  65. componentProps: {
  66. options: [
  67. {
  68. label: '图片',
  69. value: 'image',
  70. },
  71. {
  72. label: '模型',
  73. value: 'modal',
  74. },
  75. ],
  76. },
  77. },
  78. {
  79. field: 'path',
  80. label: '上传文件',
  81. component: 'JUpload',
  82. componentProps: {
  83. maxCount: 1,
  84. fileMax: 50,
  85. bizPath: 'webfile',
  86. change: (value) => {},
  87. },
  88. },
  89. ];