log.data.ts 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149
  1. import { BasicColumn, FormSchema } from '/@/components/Table';
  2. export const columns: BasicColumn[] = [
  3. {
  4. title: '日志内容',
  5. dataIndex: 'logContent',
  6. width: 100,
  7. align: 'left',
  8. },
  9. {
  10. title: '操作人ID',
  11. dataIndex: 'userid',
  12. width: 80,
  13. },
  14. {
  15. title: '操作人',
  16. dataIndex: 'username',
  17. width: 80,
  18. },
  19. {
  20. title: 'IP',
  21. dataIndex: 'ip',
  22. width: 80,
  23. },
  24. {
  25. title: '耗时(毫秒)',
  26. dataIndex: 'costTime',
  27. width: 80,
  28. },
  29. {
  30. title: '创建时间',
  31. dataIndex: 'createTime',
  32. sorter: true,
  33. width: 80,
  34. },
  35. {
  36. title: '日志类型',
  37. dataIndex: 'logType_dictText',
  38. width: 60,
  39. },
  40. ];
  41. /**
  42. * 操作日志需要操作类型
  43. */
  44. export const operationLogColumn: BasicColumn[] = [
  45. ...columns,
  46. {
  47. title: '操作类型',
  48. dataIndex: 'operateType_dictText',
  49. width: 40,
  50. },
  51. ];
  52. export const searchFormSchema: FormSchema[] = [
  53. {
  54. field: 'keyWord',
  55. label: '搜索日志',
  56. component: 'Input',
  57. colProps: { span: 4 },
  58. },
  59. {
  60. field: 'fieldTime',
  61. component: 'RangePicker',
  62. label: '创建时间',
  63. componentProps: {
  64. valueType: 'Date',
  65. },
  66. colProps: {
  67. span: 4,
  68. },
  69. },
  70. ];
  71. export const searchFormSchema1: FormSchema[] = [
  72. {
  73. field: 'fieldTime',
  74. component: 'RangePicker',
  75. label: '创建时间',
  76. componentProps: {
  77. valueType: 'Date',
  78. },
  79. colProps: {
  80. span: 4,
  81. },
  82. },
  83. ];
  84. export const browserColumn: BasicColumn[] = [
  85. {
  86. title: '日志内容',
  87. dataIndex: 'logContent',
  88. width: 100,
  89. align: 'left',
  90. },
  91. {
  92. title: '操作人ID',
  93. dataIndex: 'userid',
  94. width: 80,
  95. },
  96. {
  97. title: '操作人',
  98. dataIndex: 'username',
  99. width: 80,
  100. },
  101. {
  102. title: 'IP',
  103. dataIndex: 'ip',
  104. width: 80,
  105. },
  106. {
  107. title: '耗时(秒)',
  108. dataIndex: 'costTime',
  109. width: 80,
  110. },
  111. {
  112. title: '创建时间',
  113. dataIndex: 'createTime',
  114. sorter: true,
  115. width: 80,
  116. },
  117. {
  118. title: '结束时间',
  119. dataIndex: 'endTime',
  120. sorter: true,
  121. width: 80,
  122. },
  123. ];
  124. export const loginTjColumn: BasicColumn[] = [
  125. {
  126. title: '操作人ID',
  127. dataIndex: 'userId',
  128. },
  129. {
  130. title: '操作人',
  131. dataIndex: 'userName',
  132. },
  133. {
  134. title: '登录次数',
  135. dataIndex: 'loginCount',
  136. },
  137. {
  138. title: '最后登录时间',
  139. dataIndex: 'lastLoginTime',
  140. },
  141. ];