You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1 line
4.6 KiB
JavaScript
1 line
4.6 KiB
JavaScript
12 months ago
|
"use strict";(self.webpackChunkfurion=self.webpackChunkfurion||[]).push([[7896],{6950:(e,n,s)=>{s.r(n),s.d(n,{assets:()=>d,contentTitle:()=>o,default:()=>u,frontMatter:()=>r,metadata:()=>a,toc:()=>c});var t=s(5893),i=s(1151);const r={id:"validationTypemessagesettings",title:"3. \u9a8c\u8bc1\u6d88\u606f\u914d\u7f6e",sidebar_label:"3. \u9a8c\u8bc1\u6d88\u606f\u914d\u7f6e"},o=void 0,a={id:"settings/validationTypemessagesettings",title:"3. \u9a8c\u8bc1\u6d88\u606f\u914d\u7f6e",description:"\u5982\u9700\u7f16\u5199\u914d\u7f6e\u7684\u65f6\u5019\u63d0\u4f9b\u667a\u80fd\u63d0\u793a\u548c\u6821\u9a8c\uff0c\u53ef\u67e5\u770b \u30102.7 JSON Schema \u4f7f\u7528\u3011",source:"@site/docs/settings/validationTypemessagesettings.mdx",sourceDirName:"settings",slug:"/settings/validationTypemessagesettings",permalink:"/docs/settings/validationTypemessagesettings",draft:!1,unlisted:!1,editUrl:"https://gitee.com/dotnetchina/Furion/tree/v4/handbook/docs/settings/validationTypemessagesettings.mdx",tags:[],version:"current",lastUpdatedBy:"MonkSoul",lastUpdatedAt:1663034296,formattedLastUpdatedAt:"Sep 13, 2022",frontMatter:{id:"validationTypemessagesettings",title:"3. \u9a8c\u8bc1\u6d88\u606f\u914d\u7f6e",sidebar_label:"3. \u9a8c\u8bc1\u6d88\u606f\u914d\u7f6e"},sidebar:"settings",previous:{title:"2. \u8de8\u57df\u914d\u7f6e",permalink:"/docs/settings/corsaccessorsettings"},next:{title:"4. \u4f9d\u8d56\u6ce8\u5165\u914d\u7f6e",permalink:"/docs/settings/dependencyinjectionsettings"}},d={},c=[{value:"3.1 \u5173\u4e8e\u914d\u7f6e",id:"31-\u5173\u4e8e\u914d\u7f6e",level:2},{value:"3.2 \u914d\u7f6e\u4fe1\u606f",id:"32-\u914d\u7f6e\u4fe1\u606f",level:2},{value:"3.3 \u914d\u7f6e\u793a\u4f8b",id:"33-\u914d\u7f6e\u793a\u4f8b",level:2}];function l(e){const n={a:"a",admonition:"admonition",code:"code",h2:"h2",li:"li",p:"p",pre:"pre",ul:"ul",...(0,i.a)(),...e.components};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(n.admonition,{title:"\u914d\u7f6e\u667a\u80fd\u63d0\u793a\u548c\u6821\u9a8c",type:"tip",children:[(0,t.jsxs)(n.p,{children:["\u5982\u9700\u7f16\u5199\u914d\u7f6e\u7684\u65f6\u5019\u63d0\u4f9b\u667a\u80fd\u63d0\u793a\u548c\u6821\u9a8c\uff0c\u53ef\u67e5\u770b \u3010",(0,t.jsx)(n.a,{href:"../jsonschema",children:"2.7 JSON Schema \u4f7f\u7528"}),"\u3011"]}),(0,t.jsxs)(n.p,{children:["\u53ea\u9700\u8981\u5728 ",(0,t.jsx)(n.code,{children:".json"})," \u6587\u4ef6\u5934\u90e8\u6dfb\u52a0\u4e0b\u5217\u914d\u7f6e\u5373\u53ef\uff1a"]}),(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{className:"language-json",metastring:"showLineNumbers {2}",children:'{\r\n "$schema": "https://gitee.com/dotnetchina/Furion/raw/v4/schemas/v4/furion-schema.json"\r\n}\n'})})]}),"\n",(0,t.jsx)(n.h2,{id:"31-\u5173\u4e8e\u914d\u7f6e",children:"3.1 \u5173\u4e8e\u914d\u7f6e"}),"\n",(0,t.jsxs)(n.p,{children:["\u9a8c\u8bc1\u6d88\u606f\u914d\u7f6e\u6307\u7684\u662f ",(0,t.jsx)(n.code,{children:"Furion"})," \u6846\u67b6\u6570\u636e\u6821\u9a8c\u4e2d\u9a8c\u8bc1\u7c7b\u578b\u9ed8\u8ba4\u6d88\u606f\u914d\u7f6e\u9009\u9879\u3002"]}),"\n",(0,t.jsx)(n.h2,{id:"32-\u914d\u7f6e\u4fe1\u606f",children:"3.2 \u914d\u7f6e\u4fe1\u606f"}),"\n",(0,t.jsxs)(n.ul,{children:["\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"ValidationTypeMessageSettings"}),"\uff1a\u914d\u7f6e\u6839\u8282\u70b9","\n",(0,t.jsxs)(n.ul,{children:["\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"Definitions"}),"\uff1a\u914d\u7f6e\u9a8c\u8bc1\u7c7b\u578b\u5bf9\u5e94\u7684\u6d88\u606f\u7c7b\u578b\uff0c",(0,t.jsx)(n.code,{children:"[\u7c7b\u578b\u540d\u79f0\uff0c\u7c7b\u578b\u6d88\u606f][]"})," \u7c7b\u578b\uff0c\u5982\uff1a",(0,t.jsx)(n.code,{children:'["Required", "\u503c\u4e0d\u80fd\u4e3a\u7a7a\u6216Null"]'})]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,t.jsx)(n.h2,{id:"33-\u914d\u7f6e\u793a\u4f8b",children:"3.3 \u914d\u7f6e\u793a\u4f8b"}),"\n",(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{className:"language-json",metastring:"showLineNumbers",children:'{\r\n "ValidationTypeMessageSettings": {\r\n "Definitions": [\r\n ["Required", "\u503c\u4e0d\u80fd\u4e3a\u7a7a\u6216Null"],\r\n ["Numeric", "\u5fc5\u98
|