(self.webpackChunkant_design_pro=self.webpackChunkant_design_pro||[]).push([[76915],{96278:function(X){X.exports={root:"root___7VXfh",colorWeak:"colorWeak___2fQ5G","ant-layout":"ant-layout___2lk2i",globalSpin:"globalSpin___3wjkL","ant-table":"ant-table___3MoMQ","ant-table-thead":"ant-table-thead___2F4eD","ant-table-tbody":"ant-table-tbody___1iFAX",formBox:"formBox___1MR6m",hrefModal:"hrefModal___GOUPi",shop:"shop___3KrmS"}},64752:function(){},76915:function(X,V,e){"use strict";e.r(V),e.d(V,{default:function(){return P}});var A=e(43358),N=e(34041),J=e(34792),L=e(48086),se=e(71194),c=e(50146),q=e(63185),ee=e(9676),U=e(57663),Q=e(71577),ne=e(47673),$=e(4107),I=e(67294),te=e(49101),F=e(73218),S=e(28216),m=e(96278),o=e.n(m),O=e(41273),T=e(56173),k=e(30672),t=e(85893),W,g,r=$.Z.TextArea,P=(W=(0,S.$j)(n=>{var a=n.commondesign,_=n.globaldesign;return{commondesign:a,globaldesign:_}}),W(g=class extends I.PureComponent{constructor(){super(...arguments);this.state={visible:!1,type:"static",list:[],marginLeft:0,editModel:!1,editsrc:"",editHref:"",editdesc:"",edittarget:""},this.updataDomCallBack=a=>{for(var _=this.props.commondesign,f=_.Suspend,d=f.element,b=f.callback,y=f.callClose,E="",h=a.list,p=0,M=h.length<5?h.length:5;p':E+=''}var D=d.find(".box");D.remove(),d.append('
'.concat(E,"
")),d.css("height","auto"),d.attr("data-suspend",JSON.stringify(a))},this.show=a=>{a?(a=JSON.parse(a),this.setState({list:a.list,type:a.type,marginLeft:0})):this.setState({list:[],type:"static",marginLeft:0})},this.renderEditModal=()=>{var a=this,_=a.props.dispatch,f=this.state,d=f.editModel,b=f.editsrc,y=f.editHref,E=f.editdesc,h=f.edittarget,p=f.list,M=()=>{var v=p;v[this.index]={src:b,href:y||"",desc:E||"",target:h||""},this.setState({list:v,editModel:!1,editsrc:"",editHref:"",editdesc:"",edittarget:""})},x=()=>{this.setState({editModel:!1})},D=this.index==0,u=this.index==p.length-1,i=()=>{if(this.index>0){this.index--;var v=p[this.index];this.setState({editsrc:v.path,editHref:v.href||"",editdesc:v.desc||"",edittarget:v.target||""})}},l=()=>{if(this.index{this.setState({editHref:v})},s=v=>{this.setState({editdesc:v.target.value})},B=()=>{_({type:"commondesign/setState",payload:{Href:{visible:!0,type:{course:!0,information:!0,link:!0,dialog:!0,page:!0,member:!0,shop:!0,forum:!0,question:!0},typex:!1,callback:v=>{var G=(0,T.wS)(v,a),z=G.url;a.setState({editHref:z||""})}}}})},H=v=>{this.setState({edittarget:v.target.value})};return(0,t.jsxs)(c.Z,{title:"\u7F16\u8F91\u56FE\u7247",visible:d,onOk:M,width:520,onCancel:x,maskClosable:!1,className:o().hrefModal,children:[(0,t.jsx)("div",{className:"editImgbox",children:(0,t.jsxs)("div",{className:"viewer-content",children:[(0,t.jsx)("div",{className:"leftbtn2 "+(D?"disabled":""),onClick:i}),(0,t.jsx)("img",{src:b}),(0,t.jsx)("div",{className:"rightbtn2 "+(u?"disabled":""),onClick:l})]})}),(0,t.jsxs)("div",{className:"item-label",children:[(0,t.jsx)("div",{className:"labelName",children:"\u56FE\u7247\u94FE\u63A5\uFF1A"}),(0,t.jsxs)("div",{className:"itemContent",children:[(0,t.jsx)($.Z,{style:{width:205,marginRight:10},value:y,onChange:C}),(0,t.jsx)(Q.Z,{onClick:B,children:"\u8BBE\u7F6E\u94FE\u63A5"})]})]}),(0,t.jsxs)("div",{className:"item-label",children:[(0,t.jsx)("div",{className:"labelName",children:"\u56FE\u7247\u63CF\u8FF0\uFF1A"}),(0,t.jsx)("div",{className:"itemContent",children:(0,t.jsx)(r,{autosize:{minRows:3,maxRows:3},style:{width:303},value:E,onChange:s})})]}),(0,t.jsxs)("div",{className:"item-label",children:[(0,t.jsx)("div",{className:"labelName",children:"\u6253\u5F00\u65B9\u5F0F\uFF1A"}),(0,t.jsx)("div",{className:"itemContent",children:(0,t.jsx)(ee.Z,{onChange:H,checked:h=="_blank",value:"_blank",children:"\u65B0\u7A97\u53E3"})})]})]})},this.renderSeletPictrue=()=>{var a=this,_=this.props.dispatch,f=this.state,d=f.list,b=f.marginLeft,y=(0,k.lw)((0,k.Kd)()),E=i=>{var l=this.refs.banliBox,C=l.currentStyle?l.currentStyle:window.getComputedStyle(l,null);if(parseInt(C.marginLeft)!=0){var s=parseInt(C.marginLeft)+733;s>0&&(s=0),this.setState({marginLeft:s}),l.style.marginLeft=s+"px"}},h=i=>{var l=this.refs.banliBox,C=l.currentStyle?l.currentStyle:window.getComputedStyle(l,null),s=733-l.offsetWidth;if(parseInt(l.style.marginLeft)!=s){var B=parseInt(C.marginLeft)-733;B{var i=this.state.list;window.fileBoxApi.fileSelect({title:y.formatMessage({id:"explorer.selectImage"}),type:"file",single:!1,allowExt:"jpg,jpeg,png",callback:function(C){var s=C.data||{},B=s.selectIds.length?s.selectItems||[]:[];a.setState({list:[...i,...B]})}})},D=i=>{var l=[...d];l.splice(i,1),this.setState({list:l})},u=(i,l)=>{var C=this.state,s=C.editModel,B=C.editsrc,H=C.editHref,v=C.editdesc,G=C.edittarget;this.index=l,this.setState({editModel:!0,editsrc:i.path,editHref:i.href||"",editdesc:i.desc||"",edittarget:i.target||""})};return(0,t.jsxs)("div",{children:[(0,t.jsxs)("div",{className:"label",children:["\u6DFB\u52A0\uFF1A",d.length>0?(0,t.jsxs)("div",{className:"timsg",style:{right:"-832",bottom:"-14"},children:["\u56FE\u7247\u5DF2\u4E0A\u4F20 ",d.length," \u5F20\uFF0C( \u60AC\u6D6E\u5E7F\u544A\u663E\u793A\u4E0D\u8D85\u8FC75\u5F20\u56FE\u7247 )\u3002"]}):""]}),(0,t.jsxs)("div",{className:"banContent",children:[d.length>5?(0,t.jsx)("div",{className:"leftBtn "+(p?"disabled":""),onClick:E}):"",(0,t.jsxs)("div",{className:"bannerBox",children:[(0,t.jsx)("div",{className:"add banli",onClick:x,style:d.length==0?{width:875}:{},children:(0,t.jsx)(te.Z,{})}),(0,t.jsx)("div",{className:"banul",children:(0,t.jsx)("div",{className:"banliBox",style:{width:d.length*148},ref:"banliBox",children:d.map((i,l)=>(0,t.jsxs)("div",{className:"banli",children:[(0,t.jsx)("img",{src:i.path}),(0,t.jsx)("div",{className:"close",onClick:C=>D(l),children:(0,t.jsx)(F.Z,{})}),(0,t.jsx)("div",{className:"edit",onClick:C=>u(i,l)})]},l))})})]}),d.length>5?(0,t.jsx)("div",{className:"rightBtn "+(M?"disabled":""),onClick:h}):""]}),this.renderEditModal()]})},this.cancelEvent=()=>{var a=this,_=this.props.dispatch;_({type:"commondesign/setState",payload:{Suspend:{visible:!1,callback:()=>{},callClose:()=>{}}}})}}componentDidMount(){var a=this.props.commondesign,_=a.Suspend,f=_.visible,d=_.element,b=_.callback,y=_.callClose;this.setState({visible:f});var E=d.attr("data-suspend");this.show(E)}render(){var a=this,_=this.props,f=_.dispatch,d=_.commondesign,b=d.Suspend.callback,y=this.state,E=y.visible,h=y.type,p=y.list,M=u=>{a.cancelEvent()},x=u=>{if(p.length>0){var i={list:p,type:h};a.updataDomCallBack(i),b&&b(i),a.cancelEvent()}else L.ZP.error("\u8BF7\u6DFB\u52A0\u5E7F\u544A")},D=u=>{this.setState({type:u})};return(0,t.jsx)(c.Z,{title:"\u60AC\u6D6E\u5E7F\u544A",visible:E,onOk:x,width:1e3,onCancel:M,maskClosable:!1,className:o().hrefModal,children:(0,t.jsxs)("div",{className:"divRow",children:[(0,t.jsx)("div",{className:"label",children:"\u60AC\u6D6E\u65B9\u5F0F\uFF1A"}),(0,t.jsx)("div",{className:"content",children:(0,t.jsxs)(N.Z,{value:h,onChange:D,style:{width:200},children:[(0,t.jsx)(Option,{value:"static",children:"\u9759\u6001\u60AC\u6D6E"}),(0,t.jsx)(Option,{value:"dynamic",children:"\u52A8\u6001\u60AC\u6D6E"})]})}),this.renderSeletPictrue()]})})}})||g)},9676:function(X,V,e){"use strict";e.d(V,{Z:function(){return W}});var A=e(96156),N=e(22122),J=e(94184),L=e.n(J),se=e(50132),c=e(67294),q=e(53124),ee=e(65223),U=e(85061),Q=e(28481),ne=e(98423),$=function(g,r){var P={};for(var n in g)Object.prototype.hasOwnProperty.call(g,n)&&r.indexOf(n)<0&&(P[n]=g[n]);if(g!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,n=Object.getOwnPropertySymbols(g);a0&&(a=v().map(function(j){return c.createElement(k,{prefixCls:Z,key:j.value.toString(),disabled:"disabled"in j?j.disabled:h.disabled,value:j.value,checked:i.includes(j.value),onChange:j.onChange,className:"".concat(ae,"-item"),style:j.style},j.label)}));var re={toggleOption:R,value:i,disabled:h.disabled,name:h.name,registerValue:z,cancelValue:G},ce=L()(ae,(0,A.Z)({},"".concat(ae,"-rtl"),x==="rtl"),b);return c.createElement("div",(0,N.Z)({className:ce,style:y},le,{ref:P}),c.createElement(I.Provider,{value:re},a))},F=c.forwardRef(te),S=c.memo(F),m=e(98866),o=function(g,r){var P={};for(var n in g)Object.prototype.hasOwnProperty.call(g,n)&&r.indexOf(n)<0&&(P[n]=g[n]);if(g!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,n=Object.getOwnPropertySymbols(g);a