fan.data.ts 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155
  1. import { BasicColumn } from '/@/components/Table';
  2. import { FormSchema } from '/@/components/Table';
  3. import { list } from '../substationTabel/substation.api';
  4. export const columns: BasicColumn[] = [
  5. {
  6. title: '名称',
  7. dataIndex: 'strname',
  8. width: 120,
  9. },
  10. {
  11. title: '安装位置',
  12. dataIndex: 'strinstallpos',
  13. width: 100,
  14. },
  15. {
  16. title: '风筒长度(m)',
  17. dataIndex: 'flength',
  18. width: 100,
  19. },
  20. {
  21. title: '风筒直径(m)',
  22. dataIndex: 'fclearwidth',
  23. width: 80,
  24. },
  25. {
  26. title: '风机类型',
  27. dataIndex: 'ntype_dictText',
  28. width: 100,
  29. },
  30. {
  31. title: '所属分站',
  32. width: 150,
  33. dataIndex: 'stationname',
  34. },
  35. ];
  36. export const recycleColumns: BasicColumn[] = [
  37. {
  38. title: '名称',
  39. dataIndex: 'strname',
  40. width: 100,
  41. },
  42. {
  43. title: '是否为常闭型',
  44. dataIndex: 'bnormalclose',
  45. width: 100,
  46. },
  47. ];
  48. export const searchFormSchema: FormSchema[] = [
  49. {
  50. label: '名称',
  51. field: 'strname',
  52. component: 'Input',
  53. colProps: { span: 6 },
  54. },
  55. {
  56. label: '安装位置',
  57. field: 'strinstallpos',
  58. component: 'Input',
  59. colProps: { span: 6 },
  60. },
  61. {
  62. label: '所属分站',
  63. field: 'nsubstationid',
  64. component: 'ApiSelect',
  65. componentProps: {
  66. api: list,
  67. labelField: 'strname',
  68. valueField: 'id',
  69. },
  70. },
  71. ];
  72. export const formSchema: FormSchema[] = [
  73. {
  74. label: '',
  75. field: 'id',
  76. component: 'Input',
  77. show: false,
  78. },
  79. {
  80. label: '名称',
  81. field: 'strname',
  82. component: 'Input',
  83. },
  84. {
  85. label: '安装位置',
  86. field: 'strinstallpos',
  87. component: 'Input',
  88. },
  89. {
  90. label: '风筒长度(m)',
  91. field: 'flength',
  92. component: 'InputNumber',
  93. },
  94. {
  95. label: '风筒直径(m)',
  96. field: 'fclearwidth',
  97. component: 'InputNumber',
  98. },
  99. {
  100. label: '风机类型',
  101. field: 'ntype',
  102. component: 'JDictSelectTag',
  103. componentProps: {
  104. dictCode: 'fantype',
  105. placeholder: '请选择状态',
  106. // stringToNumber: true,
  107. },
  108. },
  109. {
  110. label: '所属分站',
  111. field: 'nsubstationid',
  112. component: 'ApiSelect',
  113. componentProps: {
  114. api: list,
  115. labelField: 'strname',
  116. valueField: 'id',
  117. },
  118. },
  119. {
  120. label: '点表',
  121. field: 'strtype',
  122. component: 'JDictSelectTag',
  123. componentProps: {
  124. dictCode: 'fanlocalkind',
  125. placeholder: '请选择状态',
  126. },
  127. },
  128. {
  129. label: '监测类型',
  130. field: 'monitorflag_dictText',
  131. component: 'JDictSelectTag',
  132. componentProps: {
  133. dictCode: 'monitorflag',
  134. placeholder: '请选择状态',
  135. },
  136. },
  137. {
  138. label: '是否模拟数据',
  139. field: 'testflag',
  140. component: 'RadioGroup',
  141. defaultValue: 1,
  142. componentProps: () => {
  143. return {
  144. options: [
  145. { label: '是', value: 1, key: '1' },
  146. { label: '否', value: 0, key: '2' },
  147. ],
  148. };
  149. },
  150. },
  151. ];