fix: 修复1panel 请求失败的bug

This commit is contained in:
xiaojunnuo
2026-02-15 12:59:08 +08:00
parent 8387fe0d5b
commit 0283662931
11 changed files with 63 additions and 44 deletions
@@ -13,6 +13,7 @@
import { ComponentPropsType, doRequest } from "/@/components/plugins/lib";
import { ref, inject } from "vue";
import { Form } from "ant-design-vue";
import { getInputFromForm } from "./utils";
defineOptions({
name: "ApiTest",
@@ -45,13 +46,15 @@ const doTest = async () => {
message.value = "";
hasError.value = false;
loading.value = true;
const { input, record } = getInputFromForm(form, pluginType);
try {
const res = await doRequest(
{
type: pluginType,
typeName: form.type,
action: props.action,
input: pluginType === "plugin" ? form.input : form,
input,
record,
},
{
onError(err: any) {