CD配唱片
2025-05-09 84ee03eb7701d8aeb8aa9514989f2c8b4ce53e79
src/views/basicData/bom/index.vue
@@ -65,8 +65,9 @@
          type="success"
          plain
          icon="Refresh"
          :disabled="loadingRefresh"
          @click="handleRefresh"
          v-hasPermi="['apsPartRouteStat:edit']"
          v-hasPermi="['Aps:ApsBomHeader:refreshBomData']"
          >{{ $t("common.common.update") }}</el-button
        >
      </el-col>
@@ -94,7 +95,7 @@
          type="primary"
          link
          @click="handleCheckView(row)"
          v-hasPermi="['aps:calendar:update']"
          v-hasPermi="['Aps:apsBom:list']"
          >查看</el-button
        >
      </template>
@@ -104,19 +105,20 @@
      v-model="openDialog"
      width="900px"
      append-to-body
      style="height:400px;overflow:hidden;"
    >
      <HxlhTable
        style="width: 100%"
        :columns="subGridOptions"
        :data="subList"
        :loading="loadingSub"
        :height="heightSub"
        :height="'280px;'"
      >
      </HxlhTable>
      <template #footer>
        <span class="dialog-footer">
          <el-button @click="openDialog = false">{{
            $t("common.common.cancel")
            $t("common.common.close")
          }}</el-button>
        </span>
      </template>
@@ -128,6 +130,7 @@
import {
  listApsBomHeaderList,
  listApsBomLineList,
  listApsBomRefreshBomDataList
} from "@/api/basicData/bom/bom.js";
import { listAll_plant } from "@/api/basicData/plant";
import HxlhTable from "@/components/HxlhTable/index.vue";
@@ -146,6 +149,7 @@
const subList = ref([]);
const loading = ref(false);
const loadingSub = ref(false);
const loadingRefresh = ref(false);
const showSearch = ref(true);
const total = ref(0);
const height = ref(document.documentElement.clientHeight - 210 + "px;");
@@ -301,7 +305,20 @@
  },
  { immediate: true, deep: true }
);
async function handleRefresh() {
  loadingRefresh.value = true;
  const res = await listApsBomRefreshBomDataList()
  if(res.code == 200){
    ElMessage({
        message: t("plan.message.update"),
        type: "success",
    });
    loadingRefresh.value = false;
    getList();
  }else{
    loadingRefresh.value = false;
  }
}
function changePageNo(currentPage) {
  queryParams.value.pageNum = currentPage;
  page.value.current = currentPage;