gaoluyang
2 天以前 c25a27347be2c46177b615426297836b30915608
src/views/procureMent/components/ProductionDialog.vue
@@ -133,7 +133,7 @@
import { ref, defineProps, watch, onMounted, nextTick, computed } from "vue";
import { ElMessage } from "element-plus";
import useUserStore from "@/store/modules/user";
import { addOrEditPR } from "@/api/procureMent";
import { addOrEditPR,getSupplyList, getCoalInfoList } from "@/api/procureMent";
import { getSupply } from "@/api/basicInformation/supplier";
import { getCoalInfo } from "@/api/basicInformation/coal";
const props = defineProps({
@@ -161,11 +161,12 @@
const getDropdownData = async () => {
  try {
    const [supplyRes, coalRes] = await Promise.all([
      getSupply(),
      getCoalInfo(),
      getSupplyList(),
      getCoalInfoList(),
    ]);
    let supplyData = supplyRes.data.records;
    let coalData = coalRes.data.records;
    console.log(supplyRes, coalRes);
    let supplyData = supplyRes.data;
    let coalData = coalRes.data;
    supplyList.value = supplyData.map((item) => ({
      value: item.id,
      label: item.supplierName,
@@ -288,6 +289,7 @@
onMounted(async () => {
  let res = await userStore.getInfo();
  userInfo.value = res;
  getDropdownData()
});
const rules = {
  supplierName: [