brazeCom.vue 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. <!-- 点检判定 -->
  2. <template>
  3. <el-scrollbar :height="tableHeight">
  4. <avue-crud ref="crudRef2" :data="tableData" :option="option" />
  5. </el-scrollbar>
  6. </template>
  7. <script setup>
  8. import { processBrazePage } from "@/api/braze";
  9. import { useProcessStore } from "@/store";
  10. import { collectData, tableDatas } from "@/api/process/traceability";
  11. import { useDictionaryStore } from "@/store";
  12. const dictS = useDictionaryStore();
  13. const store = useProcessStore();
  14. const tableData = ref([]);
  15. const tableHeight = ref(null);
  16. const setTableHeight = () => {
  17. tableHeight.value =
  18. Number(document.getElementById("tabBox").offsetHeight) - 110;
  19. };
  20. const option = {
  21. addBtn: false,
  22. selection: false,
  23. viewBtn: false,
  24. editBtn: false,
  25. delBtn: false,
  26. menu: false,
  27. column: [
  28. {
  29. label: "工序名称",
  30. prop: "operationName",
  31. },
  32. {
  33. label: "钎焊编码",
  34. prop: "brazeCode",
  35. },
  36. {
  37. label: "钎焊名称",
  38. prop: "brazeName",
  39. },
  40. {
  41. label: "起始端",
  42. prop: "lineStart",
  43. },
  44. {
  45. label: "结束端",
  46. prop: "lineEnd",
  47. },
  48. {
  49. label: "线径",
  50. prop: "wireDiameter",
  51. hide: true,
  52. },
  53. {
  54. label: "长度",
  55. prop: "length",
  56. hide: true,
  57. },
  58. {
  59. label: "操作人",
  60. prop: "updator",
  61. },
  62. {
  63. label: "操作时间",
  64. prop: "updated",
  65. },
  66. ],
  67. };
  68. const refreshTra = (row) => {
  69. const data = {
  70. seqNo: store.useSeqNo,
  71. workOrderCode: store.odersData.workOrderCode,
  72. };
  73. dataList(data);
  74. };
  75. defineExpose({ refreshTra });
  76. onMounted(() => {
  77. refreshTra();
  78. setTableHeight();
  79. });
  80. const dataList = (data) => {
  81. processBrazePage(data).then((res) => {
  82. tableData.value = res.data.records;
  83. });
  84. };
  85. </script>