2 lines
13 KiB
JavaScript
2 lines
13 KiB
JavaScript
"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[3226],{36428:function(J,j,e){var t=e(88351),P=e(87841),i=e(993),E=e(96268),y=e(93236),O=e(90040),W=e(8263),I=e(62086),p=["fieldProps","options","radioType","layout","proFieldProps","valueEnum"],R=y.forwardRef(function(m,Z){var d=m.fieldProps,M=m.options,H=m.radioType,u=m.layout,r=m.proFieldProps,g=m.valueEnum,$=(0,P.Z)(m,p);return(0,I.jsx)(W.Z,(0,t.Z)((0,t.Z)({valueType:H==="button"?"radioButton":"radio",ref:Z,valueEnum:(0,i.h)(g,void 0)},$),{},{fieldProps:(0,t.Z)({options:M,layout:u},d),proFieldProps:r,filedConfig:{customLightMode:!0}}))}),_=y.forwardRef(function(m,Z){var d=m.fieldProps,M=m.children;return(0,I.jsx)(E.ZP,(0,t.Z)((0,t.Z)({},d),{},{ref:Z,children:M}))}),L=(0,O.G)(_,{valuePropName:"checked",ignoreWidth:!0}),o=L;o.Group=R,o.Button=E.ZP.Button,o.displayName="ProFormComponent",j.Z=o},52586:function(J,j,e){var t=e(88351),P=e(87841),i=e(93236),E=e(8263),y=e(62086),O=["fieldProps","proFieldProps"],W=function(p,R){var _=p.fieldProps,L=p.proFieldProps,o=(0,P.Z)(p,O);return(0,y.jsx)(E.Z,(0,t.Z)({ref:R,valueType:"textarea",fieldProps:_,proFieldProps:L},o))};j.Z=i.forwardRef(W)},61786:function(J,j,e){var t=e(88351),P=e(87841),i=e(93236),E=e(8263),y=e(62086),O=["fieldProps","proFieldProps"],W=["fieldProps","proFieldProps"],I="text",p=function(o){var m=o.fieldProps,Z=o.proFieldProps,d=(0,P.Z)(o,O);return(0,y.jsx)(E.Z,(0,t.Z)({valueType:I,fieldProps:m,filedConfig:{valueType:I},proFieldProps:Z},d))},R=function(o){var m=o.fieldProps,Z=o.proFieldProps,d=(0,P.Z)(o,W);return(0,y.jsx)(E.Z,(0,t.Z)({valueType:"password",fieldProps:m,proFieldProps:Z,filedConfig:{valueType:I}},d))},_=p;_.Password=R,_.displayName="ProFormComponent",j.Z=_},28931:function(J,j,e){e.d(j,{Y:function(){return H}});var t=e(99177),P=e(42700),i=e(88351),E=e(67654),y=e(87841),O=e(29320),W=e(50126),I=e(92750),p=e(72266),R=e.n(p),_=e(71639),L=e(24599),o=e(93236),m=e(19103),Z=e(96630),d=e(62086),M=["children","trigger","onVisibleChange","onOpenChange","modalProps","onFinish","submitTimeout","title","width","visible","open"];function H(u){var r,g,$,b,A=u.children,D=u.trigger,s=u.onVisibleChange,C=u.onOpenChange,n=u.modalProps,c=u.onFinish,B=u.submitTimeout,Q=u.title,w=u.width,S=u.visible,ee=u.open,x=(0,y.Z)(u,M);(0,L.ET)(!x.footer||!(n!=null&&n.footer),"ModalForm \u662F\u4E00\u4E2A ProForm \u7684\u7279\u6B8A\u5E03\u5C40\uFF0C\u5982\u679C\u60F3\u81EA\u5B9A\u4E49\u6309\u94AE\uFF0C\u8BF7\u4F7F\u7528 submit.render \u81EA\u5B9A\u4E49\u3002");var V=(0,o.useContext)(W.ZP.ConfigContext),le=(0,o.useState)([]),ae=(0,E.Z)(le,2),ie=ae[1],se=(0,o.useState)(!1),oe=(0,E.Z)(se,2),k=oe[0],ne=oe[1],de=(0,_.Z)(!!S,{value:ee||S,onChange:C||s}),K=(0,E.Z)(de,2),G=K[0],U=K[1],q=(0,o.useRef)(null),ue=(0,o.useCallback)(function(a){q.current===null&&a&&ie([]),q.current=a},[]),N=(0,o.useRef)(),fe=(0,o.useCallback)(function(){var a,l,f,v=(a=(l=x.form)!==null&&l!==void 0?l:(f=x.formRef)===null||f===void 0?void 0:f.current)!==null&&a!==void 0?a:N.current;v&&n!==null&&n!==void 0&&n.destroyOnClose&&v.resetFields()},[n==null?void 0:n.destroyOnClose,x.form,x.formRef]);(0,o.useImperativeHandle)(x.formRef,function(){return N.current},[N.current]),(0,o.useEffect)(function(){G&&(ee||S)&&(C==null||C(!0),s==null||s(!0))},[S,ee,G]);var me=(0,o.useMemo)(function(){return D?o.cloneElement(D,(0,i.Z)((0,i.Z)({key:"trigger"},D.props),{},{onClick:function(){var a=(0,P.Z)((0,t.Z)().mark(function f(v){var F,h;return(0,t.Z)().wrap(function(T){for(;;)switch(T.prev=T.next){case 0:U(!G),(F=D.props)===null||F===void 0||(h=F.onClick)===null||h===void 0||h.call(F,v);case 2:case"end":return T.stop()}},f)}));function l(f){return a.apply(this,arguments)}return l}()})):null},[U,D,G]),Pe=(0,o.useMemo)(function(){var a,l,f,v,F,h,X,T;return x.submitter===!1?!1:R()({searchConfig:{submitText:(a=(l=n==null?void 0:n.okText)!==null&&l!==void 0?l:(f=V.locale)===null||f===void 0||(v=f.Modal)===null||v===void 0?void 0:v.okText)!==null&&a!==void 0?a:"\u786E\u8BA4",resetText:(F=(h=n==null?void 0:n.cancelText)!==null&&h!==void 0?h:(X=V.locale)===null||X===void 0||(T=X.Modal)===null||T===void 0?void 0:T.cancelText)!==null&&F!==void 0?F:"\u53D6\u6D88"},resetButtonProps:{preventDefault:!0,disabled:B?k:void 0,onClick:function(pe){var te;U(!1),n==null||(te=n.onCancel)===null||te===void 0||te.call(n,pe)}}},x.submitter)},[(r=V.locale)===null||r===void 0||(g=r.Modal)===null||g===void 0?void 0:g.cancelText,($=V.locale)===null||$===void 0||(b=$.Modal)===null||b===void 0?void 0:b.okText,n,x.submitter,U,k,B]),ce=(0,o.useCallback)(function(a,l){return(0,d.jsxs)(d.Fragment,{children:[a,q.current&&l?(0,d.jsx)(o.Fragment,{children:(0,m.createPortal)(l,q.current)},"submitter"):l]})},[]),Ee=(0,o.useCallback)(function(){var a=(0,P.Z)((0,t.Z)().mark(function l(f){var v,F,h;return(0,t.Z)().wrap(function(T){for(;;)switch(T.prev=T.next){case 0:return v=c==null?void 0:c(f),B&&v instanceof Promise&&(ne(!0),F=setTimeout(function(){return ne(!1)},B),v.finally(function(){clearTimeout(F),ne(!1)})),T.next=4,v;case 4:return h=T.sent,h&&U(!1),T.abrupt("return",h);case 7:case"end":return T.stop()}},l)}));return function(l){return a.apply(this,arguments)}}(),[c,U,B]),ve=(0,O.X)(G);return(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(I.Z,(0,i.Z)((0,i.Z)((0,i.Z)({title:Q,width:w||800},n),ve),{},{onCancel:function(l){var f;B&&k||(U(!1),n==null||(f=n.onCancel)===null||f===void 0||f.call(n,l))},afterClose:function(){var l;fe(),U(!1),n==null||(l=n.afterClose)===null||l===void 0||l.call(n)},footer:x.submitter!==!1?(0,d.jsx)("div",{ref:ue,style:{display:"flex",justifyContent:"flex-end"}}):null,children:(0,d.jsx)(Z.I,(0,i.Z)((0,i.Z)({formComponentType:"ModalForm",layout:"vertical"},x),{},{onInit:function(l,f){var v;x.formRef&&(x.formRef.current=f),x==null||(v=x.onInit)===null||v===void 0||v.call(x,l,f),N.current=f},formRef:N,submitter:Pe,onFinish:function(){var a=(0,P.Z)((0,t.Z)().mark(function l(f){var v;return(0,t.Z)().wrap(function(h){for(;;)switch(h.prev=h.next){case 0:return h.next=2,Ee(f);case 2:return v=h.sent,h.abrupt("return",v);case 4:case"end":return h.stop()}},l)}));return function(l){return a.apply(this,arguments)}}(),contentRender:ce,children:A}))})),me]})}},40882:function(J,j,e){e.d(j,{A:function(){return A}});var t=e(88351),P=e(84974),i=e(93236),E=e(96630),y=e(5424),O=e(40749),W=e(67654),I=e(67817),p=e(71639),R=e(80128),_=e(50126),L=e(61385),o=e(84875),m=e.n(o),Z=e(75986),d=e(16216),M=e(21983),H=function(s){var C;return(0,O.Z)({},s.componentCls,{"&-title":{marginBlockEnd:s.marginXL,fontWeight:"bold"},"&-container":(0,O.Z)({flexWrap:"wrap",maxWidth:"100%"},"> div".concat(s.antCls,"-space-item"),{maxWidth:"100%"}),"&-twoLine":(C={display:"block",width:"100%"},(0,O.Z)(C,"".concat(s.componentCls,"-title"),{width:"100%",margin:"8px 0"}),(0,O.Z)(C,"".concat(s.componentCls,"-container"),{paddingInlineStart:16}),(0,O.Z)(C,"".concat(s.antCls,"-space-item,").concat(s.antCls,"-form-item"),{width:"100%"}),(0,O.Z)(C,"".concat(s.antCls,"-form-item"),{"&-control":{display:"flex",alignItems:"center",justifyContent:"flex-end","&-input":{alignItems:"center",justifyContent:"flex-end","&-content":{flex:"none"}}}}),C)})};function u(D){return(0,M.Xj)("ProFormGroup",function(s){var C=(0,t.Z)((0,t.Z)({},s),{},{componentCls:".".concat(D)});return[H(C)]})}var r=e(62086),g=i.forwardRef(function(D,s){var C=i.useContext(Z.Z),n=C.groupProps,c=(0,t.Z)((0,t.Z)({},n),D),B=c.children,Q=c.collapsible,w=c.defaultCollapsed,S=c.style,ee=c.labelLayout,x=c.title,V=x===void 0?D.label:x,le=c.tooltip,ae=c.align,ie=ae===void 0?"start":ae,se=c.direction,oe=c.size,k=oe===void 0?32:oe,ne=c.titleStyle,de=c.titleRender,K=c.spaceProps,G=c.extra,U=c.autoFocus,q=(0,p.Z)(function(){return w||!1},{value:D.collapsed,onChange:D.onCollapse}),ue=(0,W.Z)(q,2),N=ue[0],fe=ue[1],me=(0,i.useContext)(_.ZP.ConfigContext),Pe=me.getPrefixCls,ce=(0,d.zx)(D),Ee=ce.ColWrapper,ve=ce.RowWrapper,a=Pe("pro-form-group"),l=u(a),f=l.wrapSSR,v=l.hashId,F=Q&&(0,r.jsx)(I.Z,{style:{marginInlineEnd:8},rotate:N?void 0:90}),h=(0,r.jsx)(R.G,{label:F?(0,r.jsxs)("div",{children:[F,V]}):V,tooltip:le}),X=(0,i.useCallback)(function(Y){var re=Y.children;return(0,r.jsx)(L.Z,(0,t.Z)((0,t.Z)({},K),{},{className:m()("".concat(a,"-container ").concat(v),K==null?void 0:K.className),size:k,align:ie,direction:se,style:(0,t.Z)({rowGap:0},K==null?void 0:K.style),children:re}))},[ie,a,se,v,k,K]),T=de?de(h,D):h,he=(0,i.useMemo)(function(){var Y=[],re=i.Children.toArray(B).map(function(z,Me){var Ce;return i.isValidElement(z)&&z!==null&&z!==void 0&&(Ce=z.props)!==null&&Ce!==void 0&&Ce.hidden?(Y.push(z),null):Me===0&&i.isValidElement(z)&&U?i.cloneElement(z,(0,t.Z)((0,t.Z)({},z.props),{},{autoFocus:U})):z});return[(0,r.jsx)(ve,{Wrapper:X,children:re},"children"),Y.length>0?(0,r.jsx)("div",{style:{display:"none"},children:Y}):null]},[B,ve,X,U]),pe=(0,W.Z)(he,2),te=pe[0],_e=pe[1];return f((0,r.jsx)(Ee,{children:(0,r.jsxs)("div",{className:m()(a,v,(0,O.Z)({},"".concat(a,"-twoLine"),ee==="twoLine")),style:S,ref:s,children:[_e,(V||le||G)&&(0,r.jsx)("div",{className:"".concat(a,"-title ").concat(v).trim(),style:ne,onClick:function(){fe(!N)},children:G?(0,r.jsxs)("div",{style:{display:"flex",width:"100%",alignItems:"center",justifyContent:"space-between"},children:[T,(0,r.jsx)("span",{onClick:function(re){return re.stopPropagation()},children:G})]}):T}),(0,r.jsx)("div",{style:{display:Q&&N?"none":void 0},children:te})]})}))});g.displayName="ProForm-Group";var $=g,b=e(9664);function A(D){return(0,r.jsx)(E.I,(0,t.Z)({layout:"vertical",submitter:{render:function(C,n){return n.reverse()}},contentRender:function(C,n){return(0,r.jsxs)(r.Fragment,{children:[C,n]})}},D))}A.Group=$,A.useForm=P.Z.useForm,A.Item=b.Z,A.useWatch=P.Z.useWatch,A.ErrorList=P.Z.ErrorList,A.Provider=P.Z.Provider,A.useFormInstance=P.Z.useFormInstance,A.EditOrReadOnlyContext=y.A},80128:function(J,j,e){e.d(j,{G:function(){return H}});var t=e(88351),P=e(40749),i=e(52319),E=e(93236),y={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M464 336a48 48 0 1096 0 48 48 0 10-96 0zm72 112h-48c-4.4 0-8 3.6-8 8v272c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V456c0-4.4-3.6-8-8-8z"}}]},name:"info-circle",theme:"outlined"},O=y,W=e(85651),I=function(r,g){return E.createElement(W.Z,(0,i.Z)({},r,{ref:g,icon:O}))},p=E.forwardRef(I),R=e(50126),_=e(87087),L=e(84875),o=e.n(L),m=e(21983),Z=function(r){return(0,P.Z)({},r.componentCls,{display:"inline-flex",alignItems:"center",maxWidth:"100%","&-icon":{display:"block",marginInlineStart:"4px",cursor:"pointer","&:hover":{color:r.colorPrimary}},"&-title":{display:"inline-flex",flex:"1"},"&-subtitle ":{marginInlineStart:8,color:r.colorTextSecondary,fontWeight:"normal",fontSize:r.fontSize,whiteSpace:"nowrap"},"&-title-ellipsis":{overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis",wordBreak:"keep-all"}})};function d(u){return(0,m.Xj)("LabelIconTip",function(r){var g=(0,t.Z)((0,t.Z)({},r),{},{componentCls:".".concat(u)});return[Z(g)]})}var M=e(62086),H=E.memo(function(u){var r=u.label,g=u.tooltip,$=u.ellipsis,b=u.subTitle,A=(0,E.useContext)(R.ZP.ConfigContext),D=A.getPrefixCls,s=D("pro-core-label-tip"),C=d(s),n=C.wrapSSR,c=C.hashId;if(!g&&!b)return(0,M.jsx)(M.Fragment,{children:r});var B=typeof g=="string"||E.isValidElement(g)?{title:g}:g,Q=(B==null?void 0:B.icon)||(0,M.jsx)(p,{});return n((0,M.jsxs)("div",{className:o()(s,c),onMouseDown:function(S){return S.stopPropagation()},onMouseLeave:function(S){return S.stopPropagation()},onMouseMove:function(S){return S.stopPropagation()},children:[(0,M.jsx)("div",{className:o()("".concat(s,"-title"),c,(0,P.Z)({},"".concat(s,"-title-ellipsis"),$)),children:r}),b&&(0,M.jsx)("div",{className:"".concat(s,"-subtitle ").concat(c).trim(),children:b}),g&&(0,M.jsx)(_.Z,(0,t.Z)((0,t.Z)({},B),{},{children:(0,M.jsx)("span",{className:"".concat(s,"-icon ").concat(c).trim(),children:Q})}))]}))})},98007:function(J,j,e){e.r(j);var t=e(93236),P=e(71516),i=e(47821),E=e(28931),y=e(61786),O=e(40882),W=e(36428),I=e(52586),p=e(62086);j.default=function(R){var _=R.values,L=R.modalOpenState,o=R.onModalOpenState,m=R.onSubmit,Z=(0,t.useRef)();return(0,t.useEffect)(function(){var d;(d=Z.current)===null||d===void 0||d.setFieldsValue(_)},[_]),(0,p.jsx)(p.Fragment,{children:(0,p.jsxs)(E.Y,{title:"\u7EBF\u4E0B\u5145\u503C-\u5BA1\u6838",formRef:Z,submitter:{searchConfig:{resetText:"\u91CD\u7F6E"},resetButtonProps:{onClick:function(){var M;(M=Z.current)===null||M===void 0||M.resetFields()}}},initialValues:_,onFinish:m,open:L,onOpenChange:o,children:[(0,p.jsx)(y.Z,{hidden:!0,width:"md",name:"id"}),(0,p.jsx)("div",{children:"\u4ED8\u6B3E\u51ED\u8BC1"}),(0,p.jsx)(P.Z,{src:_==null?void 0:_.proof,width:100}),(0,p.jsx)(i.Z,{}),(0,p.jsx)(O.A.Group,{children:(0,p.jsx)(W.Z.Group,{rules:[{required:!0,message:"\u8BF7\u9009\u62E9"}],name:"success",radioType:"button",label:"\u5BA1\u6838\u7ED3\u679C",options:[{label:"\u5145\u503C\u6210\u529F",value:1},{label:"\u5145\u503C\u5931\u8D25",value:0}]})}),(0,p.jsx)(I.Z,{name:"admin_note",label:"\u5907\u6CE8",placeholder:"\u8BF7\u8F93\u5165"})]})})}}}]);
|