columns.js 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176
  1. export default function useColumns() {
  2. const FormColumns = [
  3. {
  4. item: { key: "customerName", title: "医院名称", },
  5. attr: {
  6. is: "el-popover-select-v2",
  7. valueKey: "name",
  8. referName: "MkCustomerRule",
  9. dataMapping: {
  10. customer: 'id',
  11. },
  12. placeholder: "请输入医院名称",
  13. },
  14. },
  15. {
  16. item: { key: "productionLineName", title: "产线", },
  17. attr: {
  18. is: "el-popover-tree-select",
  19. valueKey: "name",
  20. referName: "PRODUCTLINE",
  21. dataMapping: {
  22. productionLine: 'id',
  23. },
  24. placeholder: "请输入产线",
  25. },
  26. },
  27. {
  28. item: { key: "rivalName", title: "供应商名称", },
  29. attr: {
  30. is: "el-popover-select-v2",
  31. valueKey: "name",
  32. referName: "MKRIVAL_PARAM",
  33. dataMapping: {
  34. rival: 'id',
  35. },
  36. placeholder: "请输入供应商",
  37. },
  38. },
  39. {
  40. item: { key: "customerBulk", title: "医院营收总额/年(万元)", },
  41. attr: {
  42. is: "el-input-number",
  43. step: 1,
  44. precision: 2,
  45. },
  46. },
  47. {
  48. item: { key: "rivalBulk", title: "供应商体量/年(万元)", },
  49. attr: {
  50. is: "el-input-number",
  51. step: 1,
  52. precision: 2,
  53. },
  54. },
  55. {
  56. item: { key: "consumableBulk", title: "耗材体量/年(万元", },
  57. attr: {
  58. is: "el-input-number",
  59. step: 1,
  60. precision: 2,
  61. },
  62. },
  63. {
  64. item: { key: "sectionName", title: "科室", },
  65. attr: {
  66. is: "el-popover-select-v2",
  67. valueKey: "name",
  68. referName: "MkCustomersDepartmentRule",
  69. dataMapping: {
  70. section: 'id',
  71. },
  72. placeholder: "请选择科室",
  73. },
  74. },
  75. {
  76. item: { key: "sectionKeyPsnname", title: "科室关键人姓名", },
  77. attr: {
  78. is: "el-input",
  79. placeholder: "请输入科室关键人姓名",
  80. },
  81. },
  82. {
  83. item: { key: "sectionKeyPsnphone", title: "科室关键人联系电话", },
  84. attr: {
  85. is: "el-input",
  86. placeholder: "请输入科室关键人联系电话",
  87. },
  88. },
  89. {
  90. item: { key: "hospitalKeyPsnname", title: "院级关键人姓名", },
  91. attr: {
  92. is: "el-input",
  93. placeholder: "请输入院级关键人姓名",
  94. },
  95. },
  96. {
  97. item: { key: "hospitalKeyPsnphone", title: "院级关键人联系电话", },
  98. attr: {
  99. is: "el-input",
  100. placeholder: "请输入院级关键人联系电话",
  101. },
  102. },
  103. {
  104. item: { key: "rivalKeyPsnname", title: "供应商关键人姓名", },
  105. attr: {
  106. is: "el-input",
  107. placeholder: "请输入供应商关键人姓名",
  108. },
  109. },
  110. {
  111. item: { key: "rivalKeyPsnphone", title: "供应商关键人联系电话", },
  112. attr: {
  113. is: "el-input",
  114. placeholder: "请输入供应商关键人联系电话",
  115. },
  116. },
  117. {
  118. item: { key: "idea", title: "开发思路(营销策略)", span: 24, },
  119. attr: {
  120. is: "el-input",
  121. type: "textarea",
  122. placeholder: "请输入开发思路(营销策略)",
  123. },
  124. },
  125. {
  126. item: { key: "chance", title: "机会点/困难点所需资源", span: 24, },
  127. attr: {
  128. is: "el-input",
  129. type: "textarea",
  130. placeholder: "请输入机会点/困难点所需资源",
  131. },
  132. },
  133. {
  134. item: { key: "remark", title: "备注", span: 24, },
  135. attr: {
  136. is: "el-input",
  137. type: "textarea",
  138. placeholder: "请输入备注",
  139. },
  140. },
  141. ].map(({ item, attr }) => ({
  142. attr,
  143. item: {
  144. ...item,
  145. span: item.span || 6,
  146. }
  147. }));
  148. const TabColumns = [
  149. {
  150. item: { key: "gatherCgItem", title: "品牌信息", },
  151. attr: { value: [] },
  152. TableColumns: [
  153. {
  154. item: { key: "brandName", title: "品牌名称", width: 200, },
  155. attr: {},
  156. },
  157. {
  158. item: { key: "brandPortion", title: "品牌份额(万)", },
  159. attr: {
  160. isSummary: true,
  161. },
  162. },
  163. {
  164. item: { key: "cooperationstart", title: "合作期跟(开始)", },
  165. attr: {},
  166. },
  167. {
  168. item: { key: "cooperationEnd", title: "合作期限(结束)", },
  169. attr: {},
  170. },
  171. ],
  172. },
  173. ];
  174. return { FormColumns, TabColumns }
  175. }