-
Notifications
You must be signed in to change notification settings - Fork 0
/
p__form__basic-form.1e6b4fd3.async.js
1 lines (1 loc) · 16.6 KB
/
p__form__basic-form.1e6b4fd3.async.js
1
(self.webpackChunkant_design_pro=self.webpackChunkant_design_pro||[]).push([[8734],{34540:function(L,h,e){"use strict";var c=e(22122),v=e(28991),r=e(81253),o=e(67294),D=e(62404),u=e(86190),E=e(66758),F=["fieldProps","proFieldProps"],f="dateRange",M=o.forwardRef(function(P,C){var y=P.fieldProps,p=P.proFieldProps,n=(0,r.Z)(P,F),d=(0,o.useContext)(E.Z);return o.createElement(D.Z,(0,c.Z)({ref:C,mode:"edit",fieldProps:(0,v.Z)({getPopupContainer:d.getPopupContainer},y),valueType:f,proFieldProps:p,filedConfig:{valueType:f,lightFilterLabelFormatter:function(_){return(0,u.Z)(_,(y==null?void 0:y.format)||"YYYY-MM-DD")}}},n))});h.Z=M},31199:function(L,h,e){"use strict";var c=e(22122),v=e(28991),r=e(81253),o=e(67294),D=e(62404),u=["fieldProps","min","proFieldProps","max"],E=function(f,M){var P=f.fieldProps,C=f.min,y=f.proFieldProps,p=f.max,n=(0,r.Z)(f,u);return o.createElement(D.Z,(0,c.Z)({mode:"edit",valueType:"digit",fieldProps:(0,v.Z)({min:C,max:p},P),ref:M,filedConfig:{defaultProps:{width:"100%"}},proFieldProps:y},n))};h.Z=o.forwardRef(E)},86615:function(L,h,e){"use strict";var c=e(88983),v=e(47933),r=e(22122),o=e(28991),D=e(81253),u=e(67294),E=e(62404),F=e(22270),f=e(64893),M=["fieldProps","options","radioType","layout","proFieldProps","valueEnum"],P=u.forwardRef(function(n,d){var B=n.fieldProps,_=n.options,b=n.radioType,A=n.layout,g=n.proFieldProps,t=n.valueEnum,s=(0,D.Z)(n,M);return u.createElement(E.Z,(0,r.Z)({mode:"edit",valueType:b==="button"?"radioButton":"radio",ref:d,valueEnum:(0,F.h)(t,void 0)},s,{fieldProps:(0,o.Z)({options:_,layout:A},B),proFieldProps:g,filedConfig:{customLightMode:!0}}))}),C=u.forwardRef(function(n,d){var B=n.fieldProps,_=n.children;return u.createElement(v.ZP,(0,r.Z)({},B,{ref:d}),_)}),y=(0,f.G)(C,{valuePropName:"checked",ignoreWidth:!0}),p=y;p.Group=P,p.Button=v.ZP.Button,p.displayName="ProFormComponent",h.Z=p},64317:function(L,h,e){"use strict";var c=e(22122),v=e(28991),r=e(81253),o=e(67294),D=e(62404),u=e(22270),E=e(66758),F=["fieldProps","children","params","proFieldProps","mode","valueEnum","request","showSearch","options"],f=["fieldProps","children","params","proFieldProps","mode","valueEnum","request","options"],M=o.forwardRef(function(n,d){var B=n.fieldProps,_=n.children,b=n.params,A=n.proFieldProps,g=n.mode,t=n.valueEnum,s=n.request,i=n.showSearch,a=n.options,l=(0,r.Z)(n,F),T=(0,o.useContext)(E.Z);return o.createElement(D.Z,(0,c.Z)({mode:"edit",valueEnum:(0,u.h)(t),request:s,params:b,valueType:"select",filedConfig:{customLightMode:!0},fieldProps:(0,v.Z)({options:a,mode:g,showSearch:i,getPopupContainer:T.getPopupContainer},B),ref:d,proFieldProps:A},l),_)}),P=o.forwardRef(function(n,d){var B=n.fieldProps,_=n.children,b=n.params,A=n.proFieldProps,g=n.mode,t=n.valueEnum,s=n.request,i=n.options,a=(0,r.Z)(n,f),l=(0,v.Z)({options:i,mode:g||"multiple",labelInValue:!0,showSearch:!0,showArrow:!1,autoClearSearchValue:!0,optionLabelProp:"label"},B),T=(0,o.useContext)(E.Z);return o.createElement(D.Z,(0,c.Z)({mode:"edit",valueEnum:(0,u.h)(t),request:s,params:b,valueType:"select",filedConfig:{customLightMode:!0},fieldProps:(0,v.Z)({getPopupContainer:T.getPopupContainer},l),ref:d,proFieldProps:A},a),_)}),C=M,y=P,p=C;p.SearchSelect=y,p.displayName="ProFormComponent",h.Z=p},5966:function(L,h,e){"use strict";var c=e(22122),v=e(81253),r=e(67294),o=e(62404),D=["fieldProps","proFieldProps"],u=["fieldProps","proFieldProps"],E="text",F=function(C){var y=C.fieldProps,p=C.proFieldProps,n=(0,v.Z)(C,D);return r.createElement(o.Z,(0,c.Z)({mode:"edit",valueType:E,fieldProps:y,filedConfig:{valueType:E},proFieldProps:p},n))},f=function(C){var y=C.fieldProps,p=C.proFieldProps,n=(0,v.Z)(C,u);return r.createElement(o.Z,(0,c.Z)({mode:"edit",valueType:"password",fieldProps:y,proFieldProps:p,filedConfig:{valueType:E}},n))},M=F;M.Password=f,M.displayName="ProFormComponent",h.Z=M},90672:function(L,h,e){"use strict";var c=e(22122),v=e(81253),r=e(67294),o=e(62404),D=["fieldProps","proFieldProps"],u=function(F,f){var M=F.fieldProps,P=F.proFieldProps,C=(0,v.Z)(F,D);return r.createElement(o.Z,(0,c.Z)({ref:f,mode:"edit",valueType:"textarea",fieldProps:M,proFieldProps:P},C))};h.Z=r.forwardRef(u)},952:function(L,h,e){"use strict";var c=e(56640),v=e.n(c),r=e(5894);h.ZP=r.A},5894:function(L,h,e){"use strict";e.d(h,{A:function(){return i}});var c=e(9715),v=e(86835),r=e(22122),o=e(67294),D=e(96156),u=e(49111),E=e(19650),F=e(84305),f=e(75901),M=e(28481),P=e(28991),C=e(8812),y=e(66758),p=e(96138),n=e(56725),d=e(53621),B=e(94184),_=e.n(B),b=e(2514),A=o.forwardRef(function(a,l){var T=o.useContext(y.Z),x=T.groupProps,m=(0,P.Z)((0,P.Z)({},x),a),Z=m.children,R=m.collapsible,I=m.defaultCollapsed,U=m.style,V=m.labelLayout,G=m.title,$=G===void 0?a.label:G,Y=m.tooltip,w=m.align,k=w===void 0?"start":w,q=m.direction,ee=m.size,le=ee===void 0?32:ee,me=m.titleStyle,te=m.titleRender,z=m.spaceProps,H=m.extra,S=m.autoFocus,Ee=(0,n.Z)(function(){return I||!1},{value:a.collapsed,onChange:a.onCollapse}),ae=(0,M.Z)(Ee,2),re=ae[0],pe=ae[1],Pe=(0,o.useContext)(f.ZP.ConfigContext),se=Pe.getPrefixCls,ie=(0,b.z)(a),fe=ie.ColWrapper,O=ie.RowWrapper,J=se("pro-form-group"),W=R&&o.createElement(C.Z,{style:{marginRight:8},rotate:re?void 0:90}),ue=o.createElement(d.Z,{label:W?o.createElement("div",null,W,$):$,tooltip:Y}),ne=(0,o.useCallback)(function(N){var Q=N.children;return o.createElement(E.Z,(0,r.Z)({},z,{className:"".concat(J,"-container"),size:le,align:k,direction:q,style:(0,P.Z)({rowGap:0},z==null?void 0:z.style)}),Q)},[k,J,q,le,z]),de=te?te(ue,a):ue,ce=(0,o.useMemo)(function(){var N=[],Q=o.Children.toArray(Z).map(function(K,De){var j;return o.isValidElement(K)&&(K==null||(j=K.props)===null||j===void 0?void 0:j.hidden)?(N.push(K),null):De===0&&o.isValidElement(K)&&S?o.cloneElement(K,(0,P.Z)((0,P.Z)({},K.props),{},{autoFocus:S})):K});return[o.createElement(O,{key:"children",Wrapper:ne},Q),N.length>0?o.createElement("div",{style:{display:"none"}},N):null]},[Z,O,ne,S]),oe=(0,M.Z)(ce,2),Ce=oe[0],he=oe[1];return o.createElement(fe,null,o.createElement("div",{className:_()(J,(0,D.Z)({},"".concat(J,"-twoLine"),V==="twoLine")),style:U,ref:l},he,($||Y||H)&&o.createElement("div",{className:"".concat(J,"-title"),style:me,onClick:function(){pe(!re)}},H?o.createElement("div",{style:{display:"flex",width:"100%",alignItems:"center",justifyContent:"space-between"}},de,o.createElement("span",{onClick:function(Q){return Q.stopPropagation()}},H)):de),R&&re?null:Ce))});A.displayName="ProForm-Group";var g=A,t=e(7525),s=e(88374);function i(a){return o.createElement(s.I,(0,r.Z)({layout:"vertical",submitter:{render:function(T,x){return x.reverse()}},contentRender:function(T,x){return o.createElement(o.Fragment,null,T,x)}},a))}i.Group=g,i.useForm=v.Z.useForm,i.Item=t.Z},53621:function(L,h,e){"use strict";var c=e(22385),v=e(61580),r=e(96156),o=e(84305),D=e(75901),u=e(67294),E=e(68628),F=e(47369),f=e.n(F),M=e(94184),P=e.n(M),C=function(p){var n=p.label,d=p.tooltip,B=p.ellipsis,_=p.subTitle,b=(0,u.useContext)(D.ZP.ConfigContext),A=b.getPrefixCls;if(!d&&!_)return u.createElement(u.Fragment,null,n);var g=A("pro-core-label-tip"),t=typeof d=="string"||u.isValidElement(d)?{title:d}:d,s=(t==null?void 0:t.icon)||u.createElement(E.Z,null);return u.createElement("div",{className:g,onMouseDown:function(a){return a.stopPropagation()},onMouseLeave:function(a){return a.stopPropagation()},onMouseMove:function(a){return a.stopPropagation()}},u.createElement("div",{className:P()("".concat(g,"-title"),(0,r.Z)({},"".concat(g,"-title-ellipsis"),B))},n),_&&u.createElement("div",{className:"".concat(g,"-subtitle")},_),d&&u.createElement(v.Z,t,u.createElement("span",{className:"".concat(g,"-icon")},s)))};h.Z=u.memo(C)},7721:function(L){L.exports={optional:"optional___2NpJz"}},96138:function(){},56640:function(){},47369:function(){},70347:function(){},7232:function(L,h,e){"use strict";e.r(h),e.d(h,{default:function(){return i}});var c=e(58024),v=e(39144),r=e(3182),o=e(34792),D=e(48086),u=e(94043),E=e.n(u),F=e(952),f=e(5966),M=e(34540),P=e(90672),C=e(31199),y=e(86615),p=e(97462),n=e(64317),d=e(21010),B=e(75362);function _(a){return b.apply(this,arguments)}function b(){return b=(0,r.Z)(E().mark(function a(l){return E().wrap(function(x){for(;;)switch(x.prev=x.next){case 0:return x.abrupt("return",(0,d.WY)("/api/basicForm",{method:"POST",data:l}));case 1:case"end":return x.stop()}},a)})),b.apply(this,arguments)}var A=e(7721),g=e.n(A),t=e(85893),s=function(){var l=(0,d.QT)(_,{manual:!0,onSuccess:function(){D.default.success("\u63D0\u4EA4\u6210\u529F")}}),T=l.run,x=function(){var m=(0,r.Z)(E().mark(function Z(R){return E().wrap(function(U){for(;;)switch(U.prev=U.next){case 0:T(R);case 1:case"end":return U.stop()}},Z)}));return function(R){return m.apply(this,arguments)}}();return(0,t.jsx)(B.ZP,{content:"\u8868\u5355\u9875\u7528\u4E8E\u5411\u7528\u6237\u6536\u96C6\u6216\u9A8C\u8BC1\u4FE1\u606F\uFF0C\u57FA\u7840\u8868\u5355\u5E38\u89C1\u4E8E\u6570\u636E\u9879\u8F83\u5C11\u7684\u8868\u5355\u573A\u666F\u3002",children:(0,t.jsx)(v.Z,{bordered:!1,children:(0,t.jsxs)(F.ZP,{hideRequiredMark:!0,style:{margin:"auto",marginTop:8,maxWidth:600},name:"basic",layout:"vertical",initialValues:{public:"1"},onFinish:x,children:[(0,t.jsx)(f.Z,{width:"md",label:"\u6807\u9898",name:"title",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u6807\u9898"}],placeholder:"\u7ED9\u76EE\u6807\u8D77\u4E2A\u540D\u5B57"}),(0,t.jsx)(M.Z,{label:"\u8D77\u6B62\u65E5\u671F",width:"md",name:"date",rules:[{required:!0,message:"\u8BF7\u9009\u62E9\u8D77\u6B62\u65E5\u671F"}],placeholder:["\u5F00\u59CB\u65E5\u671F","\u7ED3\u675F\u65E5\u671F"]}),(0,t.jsx)(P.Z,{label:"\u76EE\u6807\u63CF\u8FF0",width:"xl",name:"goal",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u76EE\u6807\u63CF\u8FF0"}],placeholder:"\u8BF7\u8F93\u5165\u4F60\u7684\u9636\u6BB5\u6027\u5DE5\u4F5C\u76EE\u6807"}),(0,t.jsx)(P.Z,{label:"\u8861\u91CF\u6807\u51C6",name:"standard",width:"xl",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u8861\u91CF\u6807\u51C6"}],placeholder:"\u8BF7\u8F93\u5165\u8861\u91CF\u6807\u51C6"}),(0,t.jsx)(f.Z,{width:"md",label:(0,t.jsxs)("span",{children:["\u5BA2\u6237",(0,t.jsx)("em",{className:g().optional,children:"\uFF08\u9009\u586B\uFF09"})]}),tooltip:"\u76EE\u6807\u7684\u670D\u52A1\u5BF9\u8C61",name:"client",placeholder:"\u8BF7\u63CF\u8FF0\u4F60\u670D\u52A1\u7684\u5BA2\u6237\uFF0C\u5185\u90E8\u5BA2\u6237\u76F4\u63A5 @\u59D3\u540D\uFF0F\u5DE5\u53F7"}),(0,t.jsx)(f.Z,{width:"md",label:(0,t.jsxs)("span",{children:["\u9080\u8BC4\u4EBA",(0,t.jsx)("em",{className:g().optional,children:"\uFF08\u9009\u586B\uFF09"})]}),name:"invites",placeholder:"\u8BF7\u76F4\u63A5 @\u59D3\u540D\uFF0F\u5DE5\u53F7\uFF0C\u6700\u591A\u53EF\u9080\u8BF7 5 \u4EBA"}),(0,t.jsx)(C.Z,{label:(0,t.jsxs)("span",{children:["\u6743\u91CD",(0,t.jsx)("em",{className:g().optional,children:"\uFF08\u9009\u586B\uFF09"})]}),name:"weight",placeholder:"\u8BF7\u8F93\u5165",min:0,max:100,width:"xs",fieldProps:{formatter:function(Z){return"".concat(Z||0,"%")},parser:function(Z){return Z?Z.replace("%",""):"0"}}}),(0,t.jsx)(y.Z.Group,{options:[{value:"1",label:"\u516C\u5F00"},{value:"2",label:"\u90E8\u5206\u516C\u5F00"},{value:"3",label:"\u4E0D\u516C\u5F00"}],label:"\u76EE\u6807\u516C\u5F00",help:"\u5BA2\u6237\u3001\u9080\u8BC4\u4EBA\u9ED8\u8BA4\u88AB\u5206\u4EAB",name:"publicType"}),(0,t.jsx)(p.Z,{name:["publicType"],children:function(Z){var R=Z.publicType;return(0,t.jsx)(n.Z,{width:"md",name:"publicUsers",fieldProps:{style:{margin:"8px 0",display:R&&R==="2"?"block":"none"}},options:[{value:"1",label:"\u540C\u4E8B\u7532"},{value:"2",label:"\u540C\u4E8B\u4E59"},{value:"3",label:"\u540C\u4E8B\u4E19"}]})}})]})})})},i=s},39144:function(L,h,e){"use strict";e.d(h,{Z:function(){return g}});var c=e(96156),v=e(22122),r=e(67294),o=e(94184),D=e.n(o),u=e(98423),E=e(65632),F=function(t,s){var i={};for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&s.indexOf(a)<0&&(i[a]=t[a]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var l=0,a=Object.getOwnPropertySymbols(t);l<a.length;l++)s.indexOf(a[l])<0&&Object.prototype.propertyIsEnumerable.call(t,a[l])&&(i[a[l]]=t[a[l]]);return i},f=function(s){var i=s.prefixCls,a=s.className,l=s.hoverable,T=l===void 0?!0:l,x=F(s,["prefixCls","className","hoverable"]);return r.createElement(E.C,null,function(m){var Z=m.getPrefixCls,R=Z("card",i),I=D()("".concat(R,"-grid"),a,(0,c.Z)({},"".concat(R,"-grid-hoverable"),T));return r.createElement("div",(0,v.Z)({},x,{className:I}))})},M=f,P=function(t,s){var i={};for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&s.indexOf(a)<0&&(i[a]=t[a]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var l=0,a=Object.getOwnPropertySymbols(t);l<a.length;l++)s.indexOf(a[l])<0&&Object.prototype.propertyIsEnumerable.call(t,a[l])&&(i[a[l]]=t[a[l]]);return i},C=function(s){return r.createElement(E.C,null,function(i){var a=i.getPrefixCls,l=s.prefixCls,T=s.className,x=s.avatar,m=s.title,Z=s.description,R=P(s,["prefixCls","className","avatar","title","description"]),I=a("card",l),U=D()("".concat(I,"-meta"),T),V=x?r.createElement("div",{className:"".concat(I,"-meta-avatar")},x):null,G=m?r.createElement("div",{className:"".concat(I,"-meta-title")},m):null,$=Z?r.createElement("div",{className:"".concat(I,"-meta-description")},Z):null,Y=G||$?r.createElement("div",{className:"".concat(I,"-meta-detail")},G,$):null;return r.createElement("div",(0,v.Z)({},R,{className:U}),V,Y)})},y=C,p=e(51752),n=e(71230),d=e(15746),B=e(97647),_=function(t,s){var i={};for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&s.indexOf(a)<0&&(i[a]=t[a]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var l=0,a=Object.getOwnPropertySymbols(t);l<a.length;l++)s.indexOf(a[l])<0&&Object.prototype.propertyIsEnumerable.call(t,a[l])&&(i[a[l]]=t[a[l]]);return i};function b(t){var s=t.map(function(i,a){return r.createElement("li",{style:{width:"".concat(100/t.length,"%")},key:"action-".concat(a)},r.createElement("span",null,i))});return s}var A=r.forwardRef(function(t,s){var i,a,l=r.useContext(E.E_),T=l.getPrefixCls,x=l.direction,m=r.useContext(B.Z),Z=function(ve){var X;(X=t.onTabChange)===null||X===void 0||X.call(t,ve)},R=function(){var ve;return r.Children.forEach(t.children,function(X){X&&X.type&&X.type===M&&(ve=!0)}),ve},I=t.prefixCls,U=t.className,V=t.extra,G=t.headStyle,$=G===void 0?{}:G,Y=t.bodyStyle,w=Y===void 0?{}:Y,k=t.title,q=t.loading,ee=t.bordered,le=ee===void 0?!0:ee,me=t.size,te=t.type,z=t.cover,H=t.actions,S=t.tabList,Ee=t.children,ae=t.activeTabKey,re=t.defaultActiveTabKey,pe=t.tabBarExtraContent,Pe=t.hoverable,se=t.tabProps,ie=se===void 0?{}:se,fe=_(t,["prefixCls","className","extra","headStyle","bodyStyle","title","loading","bordered","size","type","cover","actions","tabList","children","activeTabKey","defaultActiveTabKey","tabBarExtraContent","hoverable","tabProps"]),O=T("card",I),J=w.padding===0||w.padding==="0px"?{padding:24}:void 0,W=r.createElement("div",{className:"".concat(O,"-loading-block")}),ue=r.createElement("div",{className:"".concat(O,"-loading-content"),style:J},r.createElement(n.Z,{gutter:8},r.createElement(d.Z,{span:22},W)),r.createElement(n.Z,{gutter:8},r.createElement(d.Z,{span:8},W),r.createElement(d.Z,{span:15},W)),r.createElement(n.Z,{gutter:8},r.createElement(d.Z,{span:6},W),r.createElement(d.Z,{span:18},W)),r.createElement(n.Z,{gutter:8},r.createElement(d.Z,{span:13},W),r.createElement(d.Z,{span:9},W)),r.createElement(n.Z,{gutter:8},r.createElement(d.Z,{span:4},W),r.createElement(d.Z,{span:3},W),r.createElement(d.Z,{span:16},W))),ne=ae!==void 0,de=(0,v.Z)((0,v.Z)({},ie),(i={},(0,c.Z)(i,ne?"activeKey":"defaultActiveKey",ne?ae:re),(0,c.Z)(i,"tabBarExtraContent",pe),i)),ce,oe=S&&S.length?r.createElement(p.Z,(0,v.Z)({size:"large"},de,{className:"".concat(O,"-head-tabs"),onChange:Z}),S.map(function(j){return r.createElement(p.Z.TabPane,{tab:j.tab,disabled:j.disabled,key:j.key})})):null;(k||V||oe)&&(ce=r.createElement("div",{className:"".concat(O,"-head"),style:$},r.createElement("div",{className:"".concat(O,"-head-wrapper")},k&&r.createElement("div",{className:"".concat(O,"-head-title")},k),V&&r.createElement("div",{className:"".concat(O,"-extra")},V)),oe));var Ce=z?r.createElement("div",{className:"".concat(O,"-cover")},z):null,he=r.createElement("div",{className:"".concat(O,"-body"),style:w},q?ue:Ee),N=H&&H.length?r.createElement("ul",{className:"".concat(O,"-actions")},b(H)):null,Q=(0,u.Z)(fe,["onTabChange"]),K=me||m,De=D()(O,(a={},(0,c.Z)(a,"".concat(O,"-loading"),q),(0,c.Z)(a,"".concat(O,"-bordered"),le),(0,c.Z)(a,"".concat(O,"-hoverable"),Pe),(0,c.Z)(a,"".concat(O,"-contain-grid"),R()),(0,c.Z)(a,"".concat(O,"-contain-tabs"),S&&S.length),(0,c.Z)(a,"".concat(O,"-").concat(K),K),(0,c.Z)(a,"".concat(O,"-type-").concat(te),!!te),(0,c.Z)(a,"".concat(O,"-rtl"),x==="rtl"),a),U);return r.createElement("div",(0,v.Z)({ref:s},Q,{className:De}),ce,Ce,he,N)});A.Grid=M,A.Meta=y;var g=A},58024:function(L,h,e){"use strict";var c=e(38663),v=e.n(c),r=e(70347),o=e.n(r),D=e(18106),u=e(13062),E=e(89032)}}]);