chenhj
6 小时以前 217cda7380e07a355053e6ca34fb77334248b7db
src/views/productionManagement/productionOrder/index.vue
@@ -37,7 +37,8 @@
        </el-form-item>
        <el-form-item>
          <el-button type="primary"
                     @click="handleQuery">搜索</el-button>
                     @click="handleQuery">搜索
          </el-button>
        </el-form-item>
      </el-form>
      <div>
@@ -106,11 +107,12 @@
    productOrderListPage,
    listProcessRoute,
    bindingRoute,
    listProcessBom, delProductOrder,
  delProductOrder, finishOrder,
  } from "@/api/productionManagement/productionOrder.js";
  import { listMain as getOrderProcessRouteMain } from "@/api/productionManagement/productProcessRoute.js";
  import {fileDel} from "@/api/financialManagement/revenueManagement.js";
  import PIMTable from "@/components/PIMTable/PIMTable.vue";
  const NewProductOrder = defineAsyncComponent(() => import("@/views/productionManagement/productionOrder/New.vue"));
  const { proxy } = getCurrentInstance();
@@ -215,6 +217,14 @@
          type: "text",
          clickFun: row => {
            showProductStructure(row);
        },
      },
      {
        name: "结束生产",
        type: "text",
        showHide: row => !row.isEnd,
        clickFun: row => {
          handleFinishOrder(row);
          },
        },
      ],
@@ -449,8 +459,25 @@
      });
  };
  const handleConfirmRoute = () => {};
const handleConfirmRoute = () => {
};
const handleFinishOrder = (row) => {
  ElMessageBox.confirm("是否确认结束?", "结束", {
    confirmButtonText: "确认",
    cancelButtonText: "取消",
    type: "warning",
  })
      .then(() => {
        finishOrder(row.id).then(res => {
          proxy.$modal.msgSuccess("结束成功");
          getList()
        })
      })
      .catch(() => {
        proxy.$modal.msg("已取消");
      });
};
  onMounted(() => {
    getList();
  });