CuspSupplierEvaluation.data.ts 7.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293
  1. import {BasicColumn} from '/@/components/Table';
  2. import {FormSchema} from '/@/components/Table';
  3. import { rules} from '/@/utils/helper/validator';
  4. import { render } from '/@/utils/common/renderUtils';
  5. import {JVxeTypes,JVxeColumn} from '/@/components/jeecg/JVxeTable/types'
  6. import { getWeekMonthQuarterYear } from '/@/utils';
  7. //列表数据
  8. export const columns: BasicColumn[] = [
  9. {
  10. title: '状态(1-启用,0-停用)',
  11. align:"center",
  12. dataIndex: 'status'
  13. },
  14. {
  15. title: '单据日期',
  16. align:"center",
  17. dataIndex: 'billDate'
  18. },
  19. {
  20. title: '考评单号',
  21. align:"center",
  22. dataIndex: 'billCode'
  23. },
  24. {
  25. title: '供应商',
  26. align:"center",
  27. dataIndex: 'supplierId_dictText'
  28. },
  29. {
  30. title: '考评期间',
  31. align:"center",
  32. dataIndex: 'evaluationPeriod'
  33. },
  34. {
  35. title: '考评等级',
  36. align:"center",
  37. dataIndex: 'evaluationLevel_dictText'
  38. },
  39. {
  40. title: '备注',
  41. align:"center",
  42. dataIndex: 'notes'
  43. },
  44. {
  45. title: '提交(1-是 ,0-否)',
  46. align:"center",
  47. dataIndex: 'submit_dictText'
  48. },
  49. ];
  50. //查询数据
  51. export const searchFormSchema: FormSchema[] = [
  52. {
  53. label: "单据日期",
  54. field: "billDate",
  55. component: 'RangePicker',
  56. componentProps: {
  57. valueType: 'Date',
  58. showTime:true
  59. },
  60. //colProps: {span: 6},
  61. },
  62. {
  63. label: "考评单号",
  64. field: "billCode",
  65. component: 'Input',
  66. //colProps: {span: 6},
  67. },
  68. {
  69. label: "供应商",
  70. field: "supplierId",
  71. component: 'JSelectMultiple',
  72. componentProps:{
  73. },
  74. //colProps: {span: 6},
  75. },
  76. {
  77. label: "考评期间",
  78. field: "evaluationPeriod",
  79. component: 'Input',
  80. //colProps: {span: 6},
  81. },
  82. {
  83. label: "考评等级",
  84. field: "evaluationLevel",
  85. component: 'JSelectMultiple',
  86. componentProps:{
  87. },
  88. //colProps: {span: 6},
  89. },
  90. {
  91. label: "提交(1-是 ,0-否)",
  92. field: "submit",
  93. component: 'JSelectMultiple',
  94. componentProps:{
  95. },
  96. //colProps: {span: 6},
  97. },
  98. ];
  99. //表单数据
  100. export const formSchema: FormSchema[] = [
  101. {
  102. label: '状态(1-启用,0-停用)',
  103. field: 'status',
  104. component: 'InputNumber',
  105. },
  106. {
  107. label: '单据日期',
  108. field: 'billDate',
  109. component: 'DatePicker',
  110. componentProps: {
  111. showTime:true,
  112. valueFormat: 'YYYY-MM-DD HH:mm:ss'
  113. },
  114. },
  115. {
  116. label: '考评单号',
  117. field: 'billCode',
  118. component: 'Input',
  119. },
  120. {
  121. label: '供应商',
  122. field: 'supplierId',
  123. component: 'JDictSelectTag',
  124. componentProps:{
  125. dictCode:""
  126. },
  127. },
  128. {
  129. label: '考评期间',
  130. field: 'evaluationPeriod',
  131. component: 'Input',
  132. },
  133. {
  134. label: '考评等级',
  135. field: 'evaluationLevel',
  136. component: 'JDictSelectTag',
  137. componentProps:{
  138. dictCode:""
  139. },
  140. },
  141. {
  142. label: '备注',
  143. field: 'notes',
  144. component: 'Input',
  145. },
  146. {
  147. label: '提交(1-是 ,0-否)',
  148. field: 'submit',
  149. component: 'JDictSelectTag',
  150. componentProps:{
  151. dictCode:""
  152. },
  153. },
  154. // TODO 主键隐藏字段,目前写死为ID
  155. {
  156. label: '',
  157. field: 'id',
  158. component: 'Input',
  159. show: false
  160. },
  161. ];
  162. //子表单数据
  163. //子表表格配置
  164. export const cuspSupplierEvaluationScoreColumns: JVxeColumn[] = [
  165. {
  166. title: '状态(1-启用,0-停用)',
  167. key: 'status',
  168. type: JVxeTypes.inputNumber,
  169. width:"200px",
  170. placeholder: '请输入${title}',
  171. defaultValue:'',
  172. },
  173. {
  174. title: '主表主键(供应商档案)',
  175. key: 'headId',
  176. type: JVxeTypes.inputNumber,
  177. width:"200px",
  178. placeholder: '请输入${title}',
  179. defaultValue:'',
  180. },
  181. {
  182. title: '价格得分',
  183. key: 'priceScore',
  184. type: JVxeTypes.inputNumber,
  185. width:"200px",
  186. placeholder: '请输入${title}',
  187. defaultValue:'',
  188. },
  189. {
  190. title: '质量得分',
  191. key: 'qualityScore',
  192. type: JVxeTypes.inputNumber,
  193. width:"200px",
  194. placeholder: '请输入${title}',
  195. defaultValue:'',
  196. },
  197. {
  198. title: '交期得分',
  199. key: 'deliveryTimeScore',
  200. type: JVxeTypes.inputNumber,
  201. width:"200px",
  202. placeholder: '请输入${title}',
  203. defaultValue:'',
  204. },
  205. {
  206. title: '服务得分',
  207. key: 'serviceScore',
  208. type: JVxeTypes.inputNumber,
  209. width:"200px",
  210. placeholder: '请输入${title}',
  211. defaultValue:'',
  212. },
  213. {
  214. title: '总计得分',
  215. key: 'totalScore',
  216. type: JVxeTypes.inputNumber,
  217. width:"200px",
  218. placeholder: '请输入${title}',
  219. defaultValue:'',
  220. },
  221. {
  222. title: '价格自动取数',
  223. key: 'priceAuto',
  224. type: JVxeTypes.input,
  225. width:"200px",
  226. placeholder: '请输入${title}',
  227. defaultValue:'',
  228. },
  229. {
  230. title: '质量自动取数',
  231. key: 'qualityAuto',
  232. type: JVxeTypes.input,
  233. width:"200px",
  234. placeholder: '请输入${title}',
  235. defaultValue:'',
  236. },
  237. {
  238. title: '交期自动取数',
  239. key: 'deliveryTimeAuto',
  240. type: JVxeTypes.input,
  241. width:"200px",
  242. placeholder: '请输入${title}',
  243. defaultValue:'',
  244. },
  245. {
  246. title: '服务自动取数',
  247. key: 'serviceAuto',
  248. type: JVxeTypes.input,
  249. width:"200px",
  250. placeholder: '请输入${title}',
  251. defaultValue:'',
  252. },
  253. ]
  254. // 高级查询数据
  255. export const superQuerySchema = {
  256. status: {title: '状态(1-启用,0-停用)',order: 0,view: 'number', type: 'number',},
  257. billDate: {title: '单据日期',order: 2,view: 'datetime', type: 'string',},
  258. billCode: {title: '考评单号',order: 3,view: 'text', type: 'string',},
  259. supplierId: {title: '供应商',order: 4,view: 'number', type: 'number',dictCode: '',},
  260. evaluationPeriod: {title: '考评期间',order: 5,view: 'text', type: 'string',},
  261. evaluationLevel: {title: '考评等级',order: 6,view: 'list', type: 'string',dictCode: '',},
  262. notes: {title: '备注',order: 7,view: 'text', type: 'string',},
  263. submit: {title: '提交(1-是 ,0-否)',order: 8,view: 'number', type: 'number',dictCode: '',},
  264. //子表高级查询
  265. cuspSupplierEvaluationScore: {
  266. title: '供应商考评-得分',
  267. view: 'table',
  268. fields: {
  269. status: {title: '状态(1-启用,0-停用)',order: 0,view: 'number', type: 'number',},
  270. headId: {title: '主表主键(供应商档案)',order: 2,view: 'number', type: 'number',},
  271. priceScore: {title: '价格得分',order: 3,view: 'number', type: 'number',},
  272. qualityScore: {title: '质量得分',order: 4,view: 'number', type: 'number',},
  273. deliveryTimeScore: {title: '交期得分',order: 5,view: 'number', type: 'number',},
  274. serviceScore: {title: '服务得分',order: 6,view: 'number', type: 'number',},
  275. totalScore: {title: '总计得分',order: 7,view: 'number', type: 'number',},
  276. priceAuto: {title: '价格自动取数',order: 8,view: 'text', type: 'string',},
  277. qualityAuto: {title: '质量自动取数',order: 9,view: 'text', type: 'string',},
  278. deliveryTimeAuto: {title: '交期自动取数',order: 10,view: 'text', type: 'string',},
  279. serviceAuto: {title: '服务自动取数',order: 11,view: 'text', type: 'string',},
  280. }
  281. },
  282. };
  283. /**
  284. * 流程表单调用这个方法获取formSchema
  285. * @param param
  286. */
  287. export function getBpmFormSchema(_formData): FormSchema[]{
  288. // 默认和原始表单保持一致 如果流程中配置了权限数据,这里需要单独处理formSchema
  289. return formSchema;
  290. }