work-search.vue 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394
  1. <!-- 搜索表单 -->
  2. <template>
  3. <seekPage ref="seekPage" :seekList="seekList" :formLength="3" @search="search"></seekPage>
  4. </template>
  5. <script>
  6. export default {
  7. data() {
  8. return {};
  9. },
  10. props: {
  11. levelList: {
  12. type: Array,
  13. default: () => []
  14. }
  15. },
  16. computed: {
  17. // 表格列配置
  18. seekList() {
  19. return [
  20. {
  21. label: '关键字:',
  22. value: 'keyWord',
  23. type: 'input',
  24. placeholder: '单号/客户名称/设备名称'
  25. },
  26. {
  27. label: '工单编号:',
  28. value: 'code',
  29. type: 'input',
  30. placeholder: ''
  31. },
  32. {
  33. label: '客户名称:',
  34. value: 'contactName',
  35. type: 'input',
  36. placeholder: ''
  37. },
  38. {
  39. label: '设备名称:',
  40. value: 'deviceName',
  41. width: 380,
  42. type: 'input',
  43. placeholder: ''
  44. },
  45. {
  46. label: '故障等级:',
  47. value: 'faultLevel',
  48. width: 380,
  49. type: 'select',
  50. planList: this.levelList,
  51. placeholder: ''
  52. },
  53. {
  54. label: '计划单号:',
  55. value: 'planCode',
  56. width: 380,
  57. type: 'input',
  58. placeholder: ''
  59. },
  60. {
  61. label: '计划名称:',
  62. value: 'planName',
  63. width: 380,
  64. type: 'input',
  65. placeholder: ''
  66. },
  67. {
  68. label: '报工人:',
  69. value: 'executeUserName',
  70. width: 380,
  71. type: 'input',
  72. placeholder: ''
  73. },
  74. {
  75. label: '验收人:',
  76. value: 'accepterUserName',
  77. width: 380,
  78. type: 'input',
  79. placeholder: ''
  80. }
  81. ];
  82. }
  83. },
  84. methods: {
  85. /* 搜索 */
  86. search(e) {
  87. console.log(e, 'eeeeeeeeee');
  88. this.$emit('search', {
  89. ...e
  90. });
  91. }
  92. }
  93. };
  94. </script>