Update schema.ts
This commit is contained in:
parent
0e0ae91473
commit
8a90e46aae
|
|
@ -27,6 +27,7 @@ export const ModelCertificateFrom: VbenFormProps = {
|
||||||
fieldName: "modelType",
|
fieldName: "modelType",
|
||||||
label: "模型类型",
|
label: "模型类型",
|
||||||
component: "Select",
|
component: "Select",
|
||||||
|
rules: "selectRequired",
|
||||||
componentProps: {
|
componentProps: {
|
||||||
options: [
|
options: [
|
||||||
{ label: 'LLM', value: 'llm' },
|
{ label: 'LLM', value: 'llm' },
|
||||||
|
|
@ -38,6 +39,25 @@ export const ModelCertificateFrom: VbenFormProps = {
|
||||||
triggerFields: ["CertificateType"],
|
triggerFields: ["CertificateType"],
|
||||||
show: (values) => values.CertificateType === 'other',
|
show: (values) => values.CertificateType === 'other',
|
||||||
},
|
},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
fieldName: "certificateName",
|
||||||
|
label: "凭证名称",
|
||||||
|
component: "Input",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
fieldName: "baseUrl",
|
||||||
|
label: "基础URL",
|
||||||
|
component: "Input",
|
||||||
|
dependencies: {
|
||||||
|
rules: ({ values }) => {
|
||||||
|
if (values.CertificateType === 'other') {
|
||||||
|
return "required";
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
},
|
||||||
|
triggerFields: ["CertificateType"],
|
||||||
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue