content.config.ts 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. import { ContentConfig } from "/@/components/PageContent";
  2. import { httpRecord } from "/@/api/InvoiceSales/sheetOrderPool";
  3. import { h } from "vue";
  4. import { ElTag } from "element-plus";
  5. import { typeOptions, statusOptions } from "./_options";
  6. const columns = [
  7. {
  8. label: '记录ID',
  9. prop: 'id',
  10. width: '60px'
  11. },
  12. {
  13. label: '订单编号',
  14. prop: 'code',
  15. width: '160px'
  16. },
  17. {
  18. label: '卖出方公司',
  19. prop: 'supplierName',
  20. width: '200px'
  21. },
  22. {
  23. label: '买入方公司',
  24. prop: 'companyName',
  25. width: '200px'
  26. },
  27. {
  28. label: '业务类型',
  29. prop: 'type',
  30. width: '100px',
  31. cellRenderer({row}){
  32. return h(ElTag,null, {
  33. default: () => typeOptions.find(({value}) => String(value) === String(row.type))?.label || '--'
  34. })
  35. }
  36. },
  37. {
  38. label: '功能类型',
  39. prop: 'status',
  40. width: '70px',
  41. cellRenderer({row}){
  42. return h(ElTag,null, {
  43. default: () => statusOptions.find(({value}) => String(value) === String(row.status))?.label || '--'
  44. })
  45. }
  46. },
  47. {
  48. label: '标签名称',
  49. prop: 'tag_name'
  50. },
  51. {
  52. label: '标签金额',
  53. width: '80px',
  54. prop: 'tag_fee'
  55. },
  56. {
  57. label: '创建人',
  58. prop: 'creater'
  59. },
  60. {
  61. label: '申请时间',
  62. prop: 'addtime'
  63. }
  64. ];
  65. const contentConfig: ContentConfig = {
  66. title: "销售订单公海池",
  67. columns,
  68. superUserNoAction: true,
  69. apis: {
  70. httpList:(params = {}) => httpRecord({ ...params, order_type: '1' })
  71. }
  72. };
  73. export default contentConfig;