text: (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([[10],{"+9YH":function(e,t,n){"use strict";n("vc6j");var r=n("Q9CN"),a=n("tJVT"),i=n("q1tI"),o=n.n(i);function c(e){var t=e.onChange,n=e.value;n=void 0===n?[null,null]:n;var i=Object(a["a"])(n,2),c=i[0],u=i[1],l=function(e){t(null===e&&null===u?void 0:[e,u])},s=function(e){t(null===c&&null===e?void 0:[c,e])},d=function(e){return""===e?null:e};return o.a.createElement("div",{style:{width:"100%",display:"flex"}},o.a.createElement(r["a"],{placeholder:"\u5927\u4e8e\u7b49\u4e8e",style:{flex:1},value:c,onBlur:function(e){return l(d(e.target.value))},max:null===u?void 0:u}),o.a.createElement("span",{style:{marginLeft:8,marginRight:8}},"~"),o.a.createElement(r["a"],{style:{flex:1},placeholder:"\u5c0f\u4e8e\u7b49\u4e8e",value:u,onBlur:function(e){return s(d(e.target.value))},min:null===c?void 0:c}))}t["a"]=c},"+s2E":function(e,t,n){"use strict";var r=n("0Owb"),a=n("k1fw"),i=n("jrin"),o=n("q1tI"),c=n.n(o),u=n("LyJH"),l=n("jfUH");t["a"]=function(e){var t,n=e.value,o=e.field,s=o.refField,d=o.ref,f=e.onChange,p=Object(u["b"])(e),m=Object(l["qb"])(d),h=n&&(t={},Object(i["a"])(t,s,n[s]),Object(i["a"])(t,m,n[m]),t);return c.a.createElement(u["a"],Object(r["a"])({},e,{fields:p.filter((function(e){return![s,m].includes(e.name)})),onChange:function(e){f(Object(a["a"])(Object(a["a"])({},e),h))}}))}},"04aD":function(e,t,n){"use strict";(function(e){n("52nx");var r,a=n("7bDm"),i=(n("eNCU"),n("pjJH")),o=n("oBTY"),c=n("fWQN"),u=n("mtLc"),l=n("yKVA"),s=n("879j"),d=n("q1tI"),f=n.n(d),p=n("AAgL"),m=n("xNPh"),h=n("sMR+"),b=n("jfUH"),v=n("txBY"),_=n("VW+w"),g=Object(h["a"])(),y=Object(m["a"])(),O=Object(v["a"])(r=function(t){Object(l["a"])(r,t);var n=Object(s["a"])(r);function r(){var e;Object(c["a"])(this,r);for(var t=arguments.length,a=new Array(t),i=0;i<t;i++)a[i]=arguments[i];return e=n.call.apply(n,[this].concat(a)),e.state={adding:!1},e}return Object(u["a"])(r,[{key:"refSchema",get:function(){var e=this.props.schemas;return e[this.refModel]}},{key:"refModel",get:function(){var e=this.props.field;return e.ref}},{key:"refAdmin",get:function(){var e=this.props.adminConfig;return e[this.refModel]}},{key:"fields",get:function(){var e=this.props.fields;return e}},{key:"display",get:function(){var e=this.props,t=e.display,n=e.schemas;return Object(_["displayPreprocess"])(t||this.refAdmin.display,this.refModel,n)}},{key:"sort",value:function(t){var n,r,a=this.display;return(n=e).orderBy.apply(n,[t].concat(Object(o["a"])((r=e).zip.apply(r,Object(o["a"])(a.filter((function(e){return e.sort_direction})).map((function(e){return[e.name,e.sort_direction]})))))))}},{key:"handleChange",value:function(e){var t=this.props.onChange;t(e)}},{key:"render",value:function(){var e=this,t=this.fields,n=this.display,r=this.props,c=r.value,u=r.canAdd,l=void 0===u||u,s=this.state.adding;return f.a.createElement(f.a.Fragment,null,f.a.createElement(g,{showFilter:!1,modalForm:!0,formProps:function(n){return{fields:t,object:c.find((function(t){return Object(b["K"])(t,e.refModel)===Object(b["K"])(n.state.currentObject,e.refModel)})),onSubmit:function(t,r){var a=c.find((function(t){return Object(b["K"])(t,e.refModel)===r}));Object.assign(a,t),e.handleChange(c),n.hideModal()}}},display:n,data:{list:this.sort(c)||[]},model:this.refModel,showCreate:!0,showStat:!1,inlineActions:Object(_["inlineActionsPreprocess"])(["edit",{title:"\u5220\u9664",type:"func",confirm:!0,params:{func:function(t){var n=e.props.value;e.handleChange(n.filter((function(n){return Object(b["K"])(n,e.refModel)!==t})))}}}])}),!0===l?f.a.createElement(f.a.Fragment,null,f.a.createElement(i["a"],{style:{width:"100%",marginTop:16,marginBottom:8},type:"dashed",onClick:function(){return e.setState({adding:!0})},icon:"plus"},"\u65b0\u589e"),f.a.createElement(a["a"],{title:this.refSchema&&"\u65b0\u589e".concat(this.refSchema.displayName),width:"60%",destroyOnClose:!0,visible:s,closable:!0,keyboard:!0,onCancel:function(){return e.setState({adding:!1})},footer:null},f.a.createElement(y,{model:this.refModel,fields:t,onSubmit:function(t){e.handleChange([].concat(Object(o["a"])(c),[t])),e.setState({adding:!1})}}))):"")}}]),r}(p["a"]))||r;t["a"]=O}).call(this,n("LvDl"))},"0SIm":function(e,t,n){"use strict";(function(e){n("lNFX");var r,a=n("VE2L"),i=n("jrin"),o=n("tJVT"),c=n("k1fw"),u=n("fWQN"),l=n("mtLc"),s=n("yKVA"),d=n("879j"),f=n("q1tI"),p=n.n(f),m=n("AAgL"),h=n("jfUH"),b=n("txBY"),v=Object(b["a"])(r=function(t){Object(s["a"])(r,t);var n=Object(d["a"])(r);function r(){var e;Object(u["a"])(this,r);for(var t=arguments.length,a=new Array(t),i=0;i<t;i++)a[i]=arguments[i];return e=n.call.apply(n,[this].concat(a)),e.state={dataMap:{},leaves:{},loadings:{}},e.loadData=function(t){var n=e.props,r=n.fetchAll,a=n.groupBy,i=e.state.dataMap,o=t[t.length-1];e.setState((function(e){var n=e.loadings,r=new Set(n[t.length]);return r.add(o.value),n[t.length]=r,{loadings:Object(c["a"])({},n)}}));var u=e.paths.slice(-t.length-1)[0];r({model:u.name,filters:[{field:a.split(".").slice(-t.length)[0],operator:"=",value:Object(h["Q"])(i[e.paths.slice(-t.length)[0].name][o.value],u.name,a.split(".").slice(-t.length)[0])}],expandFields:[]}).then((function(n){n.length?e.setState((function(e){var t=e.dataMap;return n.forEach((function(e){t[u.name]||(t[u.name]={}),t[u.name][Object(h["K"])(e,u.name)]=e})),{dataMap:Object(c["a"])({},t)}})):e.setState((function(e){var n=e.leaves,r=new Set(n[t.length]);return r.add(o.value),n[t.length]=r,{leaves:n}}))})).finally((function(){e.setState((function(e){var n=e.loadings,r=new Set(n[t.length]);return r.delete(o.value),n[t.length]=r,{loadings:Object(c["a"])({},n)}}))}))},e}return Object(l["a"])(r,[{key:"componentDidMount",value:function(){var e=this,t=this.props.fetchAll,n=this.paths.slice(-1)[0];t({model:n.name}).then((function(t){return e.setState((function(e){var r=e.dataMap;return t.forEach((function(e){r[n.name]||(r[n.name]={}),r[n.name][Object(h["K"])(e,n.name)]=e})),{dataMap:Object(c["a"])({},r)}}))}))}},{key:"componentDidUpdate",value:function(){var e=this,t=this.props,n=t.value,r=t.detail,a=t.groupBy,i=t.fetchAll,o=this.state.dataMap;!this.fetchedDetail&&n&&Object.keys(o).length<=1&&(this.fetchedDetail=!0,r({model:this.refModel,id:Object(h["K"])(n,this.refModel),expandFields:a&&[a]}).then((function(t){e.setState({detail:t});var n=a.split("."),r=t;e.paths.slice(0,-1).forEach((function(t){var a=n.shift();r=r[a],i({model:t.name,filters:[{field:a,operator:"=",value:Object(h["Q"])(r,t.name,a)}],expandFields:[]}).then((function(n){e.setState((function(e){var r=e.dataMap;return n.forEach((function(e){r[t.name]||(r[t.name]={}),r[t.name][Object(h["K"])(e,t.name)]=e})),{dataMap:Object(c["a"])({},r)}}))}))}))})))}},{key:"refSchema",get:function(){var e=this.props.schemas;return e[this.refModel]}},{key:"refModel",get:function(){var e=this.props.field;return e.ref}},{key:"paths",get:function(){var e=this.props,t=e.schemas,n=e.groupBy,r=[this.refSchema];return n&&n.split(".").forEach((function(e){var n=r[r.length-1].fields.find((function(t){return t.name===e}));r.push(t[n.ref])})),r}},{key:"choicesOptions",get:function(){var t,n=this.props.groupBy,r=this.state,a=r.dataMap,i=r.loadings,o=r.leaves,u=n.split(".");return e.values(this.paths.reduce((function(r,l,s){var d=u.shift(),f=e.cloneDeep(a[l.name])||[],p=e(f).groupBy(d).mapValues((function(e){return e.map((function(e){var a=r[e[t]],f=!n||!!d&&n.split(".").length-u.length===1,p=(o[n.split(".").length+1-s]||new Set).has(Object(h["K"])(e,l.name));return Object(c["a"])(Object(c["a"])({value:Object(h["K"])(e,l.name),label:e[l.titleField],isLeaf:p||f,disabled:p&&!f},a&&{children:a}),{},{loading:(i[n.split(".").length+1-s]||new Set).has(Object(h["K"])(e,l.name))})}))})).value();return t=d&&Object(h["w"])(l.name,d),p}),{})).flat()}},{key:"value",get:function(){var e=this.props.groupBy,t=this.state.detail;if(!t)return[];var n=e.split("."),r=[];return this.paths.forEach((function(e){r.unshift(Object(h["K"])(t,e.name)),t=t[n.shift()]})),r}},{key:"render",value:function(){var t=this,n=this.props,r=n.onChange,u=n.groupBy,l=this.state.dataMap;return p.a.createElement(a["a"],{options:this.choicesOptions,loadData:this.loadData,onChange:function(n){if(n.length){var a=l[t.refModel][n.slice(-1)[0]];if(r(Object(c["a"])({},a)),u){var s=e.zip(u.split(".").reverse(),n.slice(1),t.paths.reverse().slice(1)).reduce((function(e,t){var n=Object(o["a"])(t,3),r=n[0],a=n[1],u=n[2];return Object(c["a"])(Object(c["a"])({},l[u.name][a]),{},Object(i["a"])({},r,e))}),Object(c["a"])({},l[t.paths.slice(-1)[0].name][n[0]]));t.setState({detail:s})}else t.setState({detail:Object(c["a"])({},a)})}else r(null)},value:this.value})}}]),r}(m["a"]))||r;t["a"]=v}).call(this,n("LvDl"))},"1X5l":function(e,t,n){"use strict";(function(e){n("cW/2");var r,a=n("RtDF"),i=n("0Owb"),o=n("fWQN"),c=n("mtLc"),u=n("yKVA"),l=n("879j"),s=n("q1tI"),d=n.n(s),f=n("AAgL"),p=n("jfUH"),m=n("txBY"),h=Object(m["a"])(r=function(t){Object(u["a"])(r,t);var n=Object(l["a"])(r);function r(){var e;Object(o["a"])(this,r);for(var t=arguments.length,a=new Array(t),i=0;i<t;i++)a[i]=arguments[i];return e=n.call.apply(n,[this].concat(a)),e.myProps=["parent"],e.doSearch=function(){var t=e.props.cacheAll;if(Object(p["C"])(e.fieldType)||"mref"===e.fieldType){var n=e.refSchema;t({model:n.name,titleField:n.titleField})}},e}return Object(c["a"])(r,[{key:"componentDidMount",value:function(){this.doSearch()}},{key:"titleField",get:function(){return this.refSchema.titleField}},{key:"fieldType",get:function(){var e=this.props.field;return e.type}},{key:"refSchema",get:function(){var e=this.props.schemas;return e[this.refModel]}},{key:"refModel",get:function(){var e=this.props.field;return e.ref}},{key:"parentField",get:function(){var e=this.props,t=e.parent,n=e.adminConfig,r=e.schemas;return t||n[this.refModel].parentField||r[this.refModel].parentField||"parent"}},{key:"choiceObject",get:function(){var t=this,n=this.props.all;return e.fromPairs((n[this.refModel]||[]).map((function(e){return[t.toField(e),e]})))}},{key:"toField",value:function(e){return Object(p["Q"])(e,this.refModel,this.parentField)}},{key:"render",value:function(){var t=this,n=this.props,r=n.value,o=n.onChange,c={placeholder:"\u672a\u9009\u62e9",allowClear:!0},u=e.values(this.choiceObject).map((function(e){return{id:t.toField(e),pId:e[t.parentField],title:e[t.titleField],value:t.toField(e)}}));return Object(p["C"])(this.fieldType)?d.a.createElement(a["a"],Object(i["a"])({},c,{treeData:u,treeDataSimpleMode:!0,onChange:function(e){return o(t.choiceObject[e])},value:r&&this.toField(r),treeDefaultExpandedKeys:r&&[r.toString()],showSearch:!0,treeNodeFilterProp:"title"},this.widgetProps)):"mref"===this.fieldType?d.a.createElement(a["a"],Object(i["a"])({},c,{treeData:u,treeDataSimpleMode:!0,onChange:function(e){return o(e.map((function(e){return t.choiceObject[e]})))},value:r&&r.map((function(e){return t.toField(e)})),treeDefaultExpandedKeys:r&&r.map((function(e){return t.toField(e).toString()})),multiple:!0,treeNodeFilterProp:"title"},this.widgetProps)):d.a.createElement(a["a"],c)}}]),r}(f["a"]))||r;t["a"]=h}).call(this,n("LvDl"))},"2CK3":function(e,t,n){e.exports={tableListForm:"tableListForm___2HivC",submitButtons:"submitButtons___1Zcv2"}},"2W84":function(e,t,n){"use strict";var r=n("Utjr");t["a"]=Object(r["d"])((function(){return Promise.all([n.e(33),n.e(25)]).then(n.bind(null,"U2hj"))}))},"2mwZ":function(e,t,n){"use strict";n.d(t,"b",(function(){return f})),n.d(t,"a",(function(){return p}));var r=n("0Owb"),a=n("fWQN"),i=n("mtLc"),o=n("yKVA"),c=n("879j"),u=n("q1tI"),l=n.n(u),s=n("9Ndd"),d=n("AAgL"),f={char:"string",int:"integer",positiveint:"integer",positivesmallint:"integer",smallint:"integer",bigint:"integer",bool:"bool",text:"text",time:"time",email:"string",slug:"string",url:"string",float:"float",decimal:"decimal",date:"date",datetime:"datetime",auto:"integer",ipaddr:"string",uuid:"string",image:"image",file:"file",bigauto:"integer"},p=function(e){Object(o["a"])(n,e);var t=Object(c["a"])(n);function n(){return Object(a["a"])(this,n),t.apply(this,arguments)}return Object(i["a"])(n,[{key:"render",value:function(){var e=this.props,t=e.type_field,n=e.form,a=e.value,i=e.onChange,o=n.getFieldValue(t),c=f[o];if(!c)return null;var u=s["b"][s["e"][c]];return l.a.createElement(u,Object(r["a"])({},this.props,{value:a&&a.value,onChange:function(e){return i({value:e})}}))}}]),n}(d["a"])},"3V3B":function(e,t,n){"use strict";(function(e){var r,a,i,o,c,u,l,s=n("jrin"),d=n("0Owb"),f=(n("OaEy"),n("2fM7")),p=n("tJVT"),m=n("k1fw"),h=n("fWQN"),b=n("mtLc"),v=n("yKVA"),_=n("879j"),g=n("q1tI"),y=n.n(g),O=n("17x9"),j=n.n(O),w=n("/MKj"),k=n("AAgL"),E=n("jfUH"),C=n("Utjr"),x=n("jxO0"),S=(r=Object(w["c"])((function(e){var t=e.content;return{schemas:t.schemas}})),a=Object(E["d"])((function(){return{relativeFormContext:Object(g["useContext"])(C["c"])}})),i=Reflect.metadata("design:type",Function),o=Reflect.metadata("design:paramtypes",[void 0]),r(c=a(c=i(c=o((l=u=function(t){Object(v["a"])(r,t);var n=Object(_["a"])(r);function r(t){var a;Object(h["a"])(this,r),a=n.call(this,t),a.myProps=["choices","excludes","canAdd","titlefield","idfield","addfields","choicesFilter","optionSize","choicesDisabled","choicesShow"],a.doSearch=function(t){var n=a.props,r=n.dispatch,i=n.monitorfields,o=n.monitormodel,c=n.form,u=n.choicesFilter,l=n.choicesFilterAllowNull,s=void 0!==l&&l,d=n.instance,f=n.optionSize,p=n.relativeFormContext,h=a.state.watchValues;if(!e.isEmpty(i)&&c&&(h=c.getFieldsValue()),Object(E["C"])(a.fieldType)||"mref"===a.fieldType){var b=Object(x["a"])(u,s,h,o,d,p);if(!b)return void a.setState({remoteChoices:[]});var v=a.refSchema,_=a.props.field,g=30;r({type:"content/choices",payload:{model:v.name,q:t,conditions:b,titleField:a.titleField,query:{page:1,size:f||g+1},data:Object(m["a"])({order_by:["-".concat(Object(E["L"])(v.name))]},"oref"===a.fieldType?{expand_fields:[_.refField]}:{})}}).then((function(e){var n=f||(!t&&e.length>g?7:g);a.setState({remoteChoices:e.slice(0,n)})}))}};var i=t.monitorvalues,o=t.monitorfields,c={};if(o&&i&&i.length){var u=Object(p["a"])(i,2),l=u[0],s=u[1];-1!==o.map((function(e){return e.split(".")[0]})).indexOf(l)&&(c[l]=s)}return a.state={watchValues:c,remoteChoices:[]},a}return Object(b["a"])(r,[{key:"componentWillReceiveProps",value:function(e){var t=e.monitorvalues,n=e.monitorfields,r=e.value,a=this.props,i=a.monitorvalues,o=a.onChange,c=a.allowUndefined,u=a.value,l=this.state.watchValues;if(Object(E["C"])(this.fieldType)&&r&&u&&r[this.idField]===u[this.idField]&&r[this.titleField]!==u[this.titleField]&&this.doSearch(),t!==i){var s=Object(p["a"])(t,2),d=s[0],f=s[1];-1!==n.map((function(e){return e.split(".")[0]})).indexOf(d)&&l[d]!==f&&(l[d]=f,this.setState({watchValues:l}),Object(E["C"])(this.fieldType)?(o(c?void 0:null),this.doSearch()):"mref"===this.fieldType&&(o([]),this.doSearch()))}}},{key:"titleField",get:function(){return this.props.titlefield||this.refSchema.titleField}},{key:"fieldType",get:function(){var t=this.props,n=t.field,r=t.choices;return e.isPlainObject(r)?"ref":n.type}},{key:"realFieldType",get:function(){var e=this.props.field;return e.type}},{key:"refSchema",get:function(){var e=this.props.schemas;return e[this.refModel]}},{key:"refModel",get:function(){var t=this.props,n=t.field,r=t.choices;return e.isPlainObject(r)?r.model:n.ref}},{key:"idField",get:function(){return this.props.idfield||Object(E["L"])(this.refModel)}},{key:"render",value:function(){var t=this,n=this.props,r=n.choices,a=n.dispatch,i=n.value,o=n.onChange,c=n.canAdd,u=n.excludes,l=n.addfields,h=n.nullOption,b=n.allowUndefined,v=n.choicesDisabled,_=n.choicesShow,g=n.choicesPipe,O=n.form,j=n.field,w=this.state.remoteChoices,k=g?g(w):w,C={placeholder:Object(E["C"])(this.fieldType)||"mref"===this.fieldType?"\u641c\u7d22".concat(this.refSchema?this.refSchema.displayName:""):"\u672a\u9009\u62e9",allowClear:!0};if(e.isArray(r)&&r.length)return y.a.createElement(f["a"],Object(d["a"])({},C,this.widgetProps,{showSearch:r.length>7,onChange:function(e){o(void 0===e?b?void 0:null:e)},value:i,filterOption:function(e,t){var n=t.value,r=t.children;return r.toLowerCase().includes(e.toLowerCase())||n.toLowerCase().includes(e.toLowerCase())}}),r.filter((function(e){return!_[e[0]]||!O||e[0]===i||Object(E["i"])(_[e[0]],(function(e){return O.getFieldValue(e)}))})).map((function(e){return y.a.createElement(f["a"].Option,{key:e[0],value:e[0],disabled:v[e[0]]&&O&&e[0]!==i&&Object(E["i"])(v[e[0]],(function(e){return O.getFieldValue(e)}))},e[1])})));if(e.isPlainObject(r))return y.a.createElement(f["a"],Object(d["a"])({},C,this.widgetProps,{onChange:o,value:i,onSearch:this.doSearch,filterOption:!1,showSearch:!0}),k.map((function(e){return y.a.createElement(f["a"].Option,{key:e[1][t.idField],value:e[1][t.idField]},e[1][t.titleField])})));var x=k;return Object(E["C"])(this.fieldType)?(i&&i[this.idField]&&!x.find((function(e){return e[0]===i[t.idField]}))&&x.push([i[this.idField],i]),y.a.createElement(f["a"],Object(d["a"])({},C,this.widgetProps,{virtual:!1,onChange:function(e){o(void 0===e?b?void 0:null:null===e?null:x.find((function(t){return t[0]===e}))[1])},value:i&&i[this.idField],onSearch:this.doSearch,filterOption:!1,showSearch:!0,onDropdownVisibleChange:function(e){e&&t.doSearch()}}),h&&y.a.createElement(f["a"].Option,{value:null},"\u65e0"),x.map((function(e){var n=Object(p["a"])(e,2),r=n[0],a=n[1],o=u.map((function(e){return e[t.idField]})),c=-1!==o.indexOf(r)&&r!==i[t.idField],l=(!i||r!==i[t.idField])&&"oref"===t.fieldType&&a[j.refField];return y.a.createElement(f["a"].Option,{key:r,value:r,disabled:c||l},a[t.titleField])})))):"mref"!==this.fieldType||c?"mref"===this.fieldType&&c?(i&&i.forEach((function(e){x.find((function(n){return n[0]===e[t.idField]}))||x.push([e[t.idField],e])})),y.a.createElement(f["a"],Object(d["a"])({},C,this.widgetProps,{virtual:!1,mode:"tags",onChange:function(e){o(e.map((function(e){var n=x.find((function(n){return n[1][t.titleField]===e}));return n?n[1]:(a({type:"content/createTag",payload:{model:t.refModel,values:Object(m["a"])(Object(s["a"])({},t.titleField,e),l)}}).then((function(e){o((i||[]).concat(e)),t.doSearch()})),null)})).filter(Boolean))},value:i&&i.map((function(e){return e[t.titleField]})),onSearch:function(e){t.doSearch(e)},filterOption:!1,onDropdownVisibleChange:function(e){e&&t.doSearch()}}),x.map((function(e){return y.a.createElement(f["a"].Option,{key:e[0],value:e[1][t.titleField]},e[1][t.titleField])})))):y.a.createElement(f["a"],null):(i&&i.forEach((function(e){x.find((function(n){return n[0]===e[t.idField]}))||x.push([e[t.idField],e])})),y.a.createElement(f["a"],Object(d["a"])({},C,this.widgetProps,{virtual:!1,mode:"multiple",onChange:function(e){o(e.map((function(e){return x.find((function(t){return t[0]===e}))[1]})))},value:i&&i.map((function(e){return e[t.idField]})),onSearch:this.doSearch,filterOption:!1,onDropdownVisibleChange:function(e){e&&t.doSearch()}}),x.map((function(e){return y.a.createElement(f["a"].Option,{key:e[0],value:e[0]},e[1][t.titleField])}))))}}]),r}(k["a"]),u.propTypes={field:j.a.object.isRequired,choices:j.a.any,monitorfields:j.a.array,excludes:j.a.array,titlefield:j.a.string,idfield:j.a.string,addfields:j.a.object,nullOption:j.a.bool},u.defaultProps={choices:[],monitorfields:[],excludes:[],titlefield:void 0,addfields:{},nullOption:!1,allowUndefined:!1,choicesDisabled:{},choicesShow:{}},c=l))||c)||c)||c)||c);t["a"]=S}).call(this,n("LvDl"))},"3hZV":function(e,t,n){"use strict";(function(e){var r,a=n("fWQN"),i=n("mtLc"),o=n("yKVA"),c=n("879j"),u=n("q1tI"),l=n.n(u),s=n("/MKj"),d=n("sMR+"),f=Object(d["a"])(),p=Object(s["c"])((function(e){var t=e.content,n=e.user.currentUser,r=e.bsmSetting;return{content:t,currentUser:n,bsmSetting:r}})),m=p(r=function(t){Object(o["a"])(r,t);var n=Object(c["a"])(r);function r(){return Object(a["a"])(this,r),n.apply(this,arguments)}return Object(i["a"])(r,[{key:"render",value:function(){var t,n=this.props,r=n.value,a=n.field,i=n.content.schemas,o=n.fields;if(!r||e.isEmpty(r))return l.a.createElement(u["Fragment"],null);var c=(null===a||void 0===a?void 0:a.ref)||o[0].ref,s={list:r},d=null===(t=i[c])||void 0===t?void 0:t.fields,p={size:"small"};return l.a.createElement("div",{style:{display:"flex"}},l.a.createElement(f,{model:c,showFilter:!1,data:s,display:d,tableProps:p}))}}]),r}(u["Component"]))||r;t["a"]=m}).call(this,n("LvDl"))},"3i6F":function(e,t,n){"use strict";(function(e){n.d(t,"e",(function(){return C})),n.d(t,"f",(function(){return S})),n.d(t,"d",(function(){return F})),n.d(t,"c",(function(){return R})),n.d(t,"b",(function(){return J})),n.d(t,"k",(function(){return ne})),n.d(t,"j",(function(){return re})),n.d(t,"m",(function(){return ie})),n.d(t,"g",(function(){return oe})),n.d(t,"l",(function(){return ce})),n.d(t,"h",(function(){return ue})),n.d(t,"i",(function(){return le})),n.d(t,"a",(function(){return se}));var r=n("k1fw"),a=n("PpiC"),i=n("0Owb"),o=(n("eE3J"),n("GSZB")),c=(n("En1n"),n("71Ds")),u=(n("Ztx6"),n("8Ik2")),l=n("tJVT"),s=(n("+BJd"),n("mr32")),d=n("9og8"),f=n("WmNS"),p=n.n(f),m=n("q1tI"),h=n.n(m),b=n("wd/R"),v=n.n(b),_=n("jfUH"),g=n("iXby"),y=n("LVWL"),O=n("xceu"),j=n("2W84"),w=n("bDUM"),k=n("3hZV"),E=n("nKGo"),C={string:["text","timeStamp","image"],integer:["text","timeStamp"],float:["text"],decimal:["text"],bool:["bool"],date:["date"],datetime:["datetime"],time:["text"],image:["image"],file:["file"],video:["video"],ref:["title"],oref:["title"],boref:["title"],mref:["title"],bref:["title"],object:["object"],array:["array"],text:["text","longtext"],duration:["duration"]},x=e(C).mapValues(e.first).mapValues((function(e){return e||"ErrorWidget"})).value(),S=function(e){return x[e]},F=["textimg"],M={text:"\u6587\u5b57",timeStamp:"\u65f6\u95f4\u6233\u683c\u5f0f",RichTextEditor:"\u5bcc\u6587\u672c\u7f16\u8f91\u5668",bool:"\u5f00\u5173",tag:"\u5f69\u8679\u6807\u7b7e",link:"\u94fe\u63a5",image:"\u56fe\u7247",datetime:"\u65e5\u671f\u65f6\u95f4",video:"\u89c6\u9891",textimg:"\u56fe\u6587",urlImg:"\u56fe\u96c6",title:"\u6807\u9898",longtext:"\u957f\u6587\u672c"},P={promise:void 0};function A(e){return D.apply(this,arguments)}function D(){return D=Object(d["a"])(p.a.mark((function e(t){return p.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(!P.promise){e.next=2;break}return e.abrupt("return",P.promise);case 2:return P.promise=new Promise((function(e){setTimeout((function(){t(),e()}),0)})),e.prev=3,e.next=6,P.promise;case 6:return e.abrupt("return",e.sent);case 7:return e.prev=7,P.promise=void 0,e.finish(7);case 10:case"end":return e.stop()}}),e,null,[[3,,7,10]])}))),D.apply(this,arguments)}function T(t){var n=t.Schemas,r=t.model,a=t.field,i=t.value;if(!i)return h.a.createElement(s["a"],null,"\u65e0");var o=n[r],c=[],u=e.isArray(i)?i:[i],l=o.fields.filter((function(e){return e.name===a.name}))[0].ref,d=n[l],f=d.titleField;return u.forEach((function(e){return c.push(e[f])})),c.join(", ")}function L(t){var n=t.value;if(!n)return h.a.createElement(s["a"],null,"\u65e0");var r=e.last(n.split(".")[0].split(" ")),a=r.split(":").map((function(e){return parseInt(e,10)})),i=Object(l["a"])(a,3),o=i[0],c=i[1],u=i[2],d=n.includes(" ")?parseInt(n.split(" ")[0],10):0,f=86400*d+3600*o+60*c+u,p=f<0,m=Math.abs(f),b=Math.floor(m/86400),v=Math.floor(m%86400/3600),_=Math.floor(m%3600/60),g=m%60,y="";return b&&(y+="".concat(b,"\u5929")),v&&(y+="".concat(v,"\u65f6")),_&&(y+="".concat(_,"\u5206")),g&&(y+="".concat(g,"\u79d2")),y?(p&&(y="-".concat(y)),y):"0"}function I(e){var t,n=e.value,r=e.field,a=e.fields;if(r&&void 0!==r.choices){var i=r.choices.find((function(e){return e[0]===n}));return i?i[1]:n||""}if(a&&void 0!==a[0].choices){var o=a[0].choices.find((function(e){return e[0]===n}));return o?o[1]:n||""}return["number","boolean"].includes(typeof n)?n:"text"===(null===r||void 0===r?void 0:r.type)||a&&"text"===(null===(t=a[0])||void 0===t?void 0:t.type)?h.a.createElement(O["a"],{value:n,type:"text"}):null===n?h.a.createElement(s["a"],null,"\u65e0"):h.a.createElement("span",{style:{whiteSpace:"pre"}},n)}function U(t){var n=t.value,r=t.isExpand,a=t.textType,i=void 0===a?"longText":a,o=n;return e.isObject(n)&&(o=JSON.stringify(n)),h.a.createElement(O["a"],{value:o,type:i,isExpand:r})}function V(e){var t=e.avatar,n=e.title,r=e.text,a=e.changePreviewImageUrl,i=e.setPreviewImageVisible,o=e.placeholderIcon,l=void 0===o?"picture":o,s=e.uploadProvider;return h.a.createElement(c["a"].Item.Meta,{avatar:h.a.createElement(u["a"],{size:"large",style:t&&{cursor:"zoom-in"},onClick:function(){t&&(a(t),i(!0))},src:Object(_["v"])(t,{width:40,height:40,uploadProvider:s}),icon:!t&&l}),title:n,description:r})}function R(e){var t=e.value,n=e.fields,r=e.field,a=void 0===r?n&&n[0]:r,i=e.tagSetting,o=void 0===i?{}:i,c=o[t];return null===t?null:h.a.createElement("div",null,h.a.createElement(s["a"],{color:c},h.a.createElement(I,{value:t,field:a})))}function W(e){var t=e.value,n=null===t||void 0===t?void 0:t.lastIndexOf("/"),r=null===t||void 0===t?void 0:t.slice(n+1);return h.a.createElement("a",{target:-1!==(null===t||void 0===t?void 0:t.indexOf("http"))?"_blank":"_self",href:t},r||t)}function q(e){var t=e.value,n=t?t.split("#"):[t||void 0],r=Object(l["a"])(n,1),a=r[0],i=null===a||void 0===a?void 0:a.lastIndexOf("/"),o=null===a||void 0===a?void 0:a.slice(i+1);return h.a.createElement("a",{href:a,target:"_blank",rel:"noopener noreferrer"},o)}function B(e){var t=e.value,n=e.date;return t||n?v()(t||n).format("YYYY-MM-DD"):""}function K(e){var t=e.value,n=e.datetime;return t||n?v()(t||n).format("YYYY-MM-DD HH:mm:ss"):""}function N(e){var t=e.value,n=e.timeFormat,r=e.customFormat,a=void 0===r?n:r;return v()(Number(t),"X").format(a||"YYYY-MM-DD HH:mm:ss")}function H(e){var t=e.value,n=e.bool;return t||n?h.a.createElement(o["a"],{type:"check-circle",theme:"filled",style:{color:"#70BF2B"}}):h.a.createElement(o["a"],{type:"close-circle",theme:"filled",style:{color:"#DD4646"}})}function z(e){var t=e.value,n=e.changePreviewImageUrl,r=e.setPreviewImageVisible,a=e.component,i=e.uploadProvider;return t?h.a.createElement("div",{style:{height:100}},h.a.createElement("img",{src:Object(_["v"])(t,{width:100,height:100,uploadProvider:i}),alt:"",className:E["gmImg"],style:{width:100,maxHeight:100,objectFit:"cover",cursor:"zoom-in"},onClick:function(){n(t),r(!0)},onLoad:function(){return A((function(){a&&a.forceUpdate()}))}})):h.a.createElement(m["Fragment"],null)}function J(e){var t=e.icon,n=e.restProps,r=void 0===n?{}:n;if(!t)return null;var a=Object(_["n"])(t);return h.a.createElement(o["a"],Object(i["a"])({},a,r))}function Y(e){var t=e.icon,n=e.text;return h.a.createElement("span",null,J({icon:t}),h.a.createElement("span",{style:{marginLeft:10}},n))}function G(){return h.a.createElement("span",{style:{color:"red"}},"\u6682\u4e0d\u652f\u6301\u663e\u793a\u8be5\u7c7b\u578b\u5b57\u6bb5")}function Q(e){var t=e.value;return JSON.stringify(t)}var Z={text:I,longtext:U,tag:R,link:W,file:q,video:y["a"],date:B,datetime:K,timeStamp:N,bool:H,image:z,icon:J,title:T,duration:L,ErrorWidget:G},X=function(e){return function(t){var n=t.value,r=Object(a["a"])(t,["value"]);return null===n||void 0===n?void 0:n.map((function(t,a){return h.a.createElement(h.a.Fragment,null,h.a.createElement(e,Object(i["a"])({},r,{value:t})),a<n.length-1&&", ")}))}},$=Object(r["a"])(Object(r["a"])({},e(Z).mapValues(X).mapKeys((function(e,t){return"multi-".concat(t)})).value()),{},{"multi-image":j["a"],"multi-title":T}),ee=Object(r["a"])(Object(r["a"])(Object(r["a"])({},Z),$),{},{textimg:V,iconText:Y,array:k["a"],object:Q,table:g["a"],MultiFile:w["a"]});function te(){var e=Object(_["fb"])((function(e){var t=e.displayWidgets;return t}));return e?Object(r["a"])(Object(r["a"])({},ee),e):ee}function ne(){var e=Object(_["fb"])((function(e){var t=e.displayWidgetName;return t}));return e?Object(r["a"])(Object(r["a"])({},M),e):M}function re(){var e=Object(_["fb"])((function(e){var t=e.displayWidgetMapping;return t}));if(e){var t=Object(r["a"])({},C);return e.forEach((function(e){var n=Object(l["a"])(e,2),r=n[0],a=n[1];a in t&&t[a].push(r)})),t}return C}function ae(e,t,n){var r=t,a=!1;return e.split(".").forEach((function(e){if(r){var t=Object(_["t"])(r,e,n);t&&Object(_["z"])(t)&&(a=!0),r=null===t||void 0===t?void 0:t.ref}})),a}function ie(){var e=Object(_["ub"])();return oe(e)}function oe(e){return function(t,n){var r=t.widget,a=t.name,i=t.fields,o=void 0===i?{value:a}:i,c=r,u=o.value,l=void 0===u?a:u;if(l){if(!c&&l){var s=Object(_["j"])(n,l,e);if(!s)return"ErrorWidget";c=S(s.type)}ae(l,n,e)&&c in Z&&(c="multi-".concat(c))}return c}}function ce(e){var t=ie();return function(n){return t(n,e)}}function ue(t,n,r,a){return ae(a,n,t)?Object(_["m"])(a,r):e.get(r,a)}function le(e){var t=te();if(!e)return G;var n=t[e];return n||G}function se(t){var n=t.fields,r=t.model,a=t.widgetName,o=t.record,c=t.widgetProps,u=t.providedSchemas,l=Object(_["ub"])(),s=u||l,d=le(a),f=e.mapValues(n,(function(e){return ue(s,r,o,e)}));return h.a.createElement(d,Object(i["a"])({},c,f))}}).call(this,n("LvDl"))},"4l6Y":function(e,t,n){"use strict";n.d(t,"b",(function(){return a})),n.d(t,"a",(function(){return i}));var r=n("Utjr"),a=Object(r["d"])((function(){return Promise.all([n.e(31),n.e(23)]).then(n.bind(null,"ZnhR"))})),i=Object(r["d"])((function(){return Promise.all([n.e(29),n.e(21)]).then(n.bind(null,"CCXB"))}))},"556t":function(e,t,n){"use strict";n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return a}));var r={edit:"\u7f16\u8f91",delete:"\u5220\u9664",detail:"\u8be6\u60c5",action:"\u4e91\u51fd\u6570",info:"\u5f39\u7a97\u6d88\u606f",link:"\u94fe\u63a5",copy:"\u590d\u5236",partEdit:"\u90e8\u5206\u7f16\u8f91",nowEdit:"\u66f4\u65b0\u6570\u636e",refEdit:"\u5173\u8054\u7f16\u8f91",refDetail:"\u5173\u8054\u8be6\u60c5",refAdd:"\u5173\u8054\u521b\u5efa"},a=["refEdit","refDetail","refAdd"]},"6GND":function(e,t,n){"use strict";n("vc6j");var r=n("Q9CN"),a=n("fWQN"),i=n("yKVA"),o=n("879j"),c=n("lt+M"),u=function(e){Object(i["a"])(n,e);var t=Object(o["a"])(n);function n(){var e;Object(a["a"])(this,n);for(var i=arguments.length,o=new Array(i),c=0;c<i;c++)o[c]=arguments[c];return e=t.call.apply(t,[this].concat(o)),e.Component=r["a"],e}return n}(c["a"]);t["a"]=u},"6nhF":function(e,t,n){},"8MRj":function(e,t,n){"use strict";n("h/qz");var r=n("GmeQ"),a=n("0Owb"),i=n("fWQN"),o=n("mtLc"),c=n("yKVA"),u=n("879j"),l=n("q1tI"),s=n.n(l),d=n("AAgL"),f=function(e){Object(c["a"])(n,e);var t=Object(u["a"])(n);function n(){return Object(i["a"])(this,n),t.apply(this,arguments)}return Object(o["a"])(n,[{key:"render",value:function(){var e=this.props,t=e.value,n=e.onChange;return s.a.createElement(r["a"],Object(a["a"])({checked:!!t},this.widgetProps,{onChange:n}))}}]),n}(d["a"]);t["a"]=f},"91mv":function(e,t,n){"use strict";n("A06R");var r=n("+Gxc"),a=(n("En1n"),n("71Ds")),i=(n("SePM"),n("PMX6")),o=(n("eE3J"),n("GSZB")),c=n("tJVT"),u=n("q1tI"),l=n.n(u);t["a"]=function(e){var t=e.loading,n=e.data,u=n.list,s=n.pagination,d=s.current,f=s.total,p=s.pageSize,m=e.field,h=m.id,b=m.title,v=m.url,_=e.onImageClick,g=e.onPaginationChange,y=e.actions,O=void 0===y?[]:y,j=v.split("#"),w=Object(c["a"])(j,1),k=w[0];return l.a.createElement("div",null,l.a.createElement(a["a"],{rowKey:h,loading:t,grid:{gutter:24,lg:3,md:2,sm:1,xs:1},dataSource:u,renderItem:function(e){return l.a.createElement(a["a"].Item,{key:e[h]},l.a.createElement(i["a"],{cover:l.a.createElement("img",{alt:e[b],style:{objectFit:"cover",height:400,maxWidth:800,cursor:"zoom-in"},src:-1!==e[k].indexOf(".myqcloud.com/")?"".concat(e[k],"?imageView2/1/w/800/h/400"):"".concat(e[k],"?x-oss-process=image/resize,m_mfit,h_400,w_800"),onClick:function(){return _(e)}}),hoverable:!0,actions:O.map((function(t){return l.a.createElement("div",{key:t.name,onClick:function(){return t.onClick(e)}},t.icon&&l.a.createElement(o["a"],{type:t.icon}),t.label)}))},l.a.createElement(i["a"].Meta,{style:{height:24},title:e[b]})))}}),l.a.createElement(r["a"],{showSizeChanger:!0,showQuickJumper:!0,onChange:g,onShowSizeChange:g,current:d,total:f,pageSize:p||0}))}},"9Ndd":function(e,t,n){"use strict";(function(e){n.d(t,"d",(function(){return q})),n.d(t,"e",(function(){return B})),n.d(t,"b",(function(){return N})),n.d(t,"a",(function(){return H})),n.d(t,"f",(function(){return z})),n.d(t,"c",(function(){return J})),n.d(t,"i",(function(){return Y})),n.d(t,"h",(function(){return G})),n.d(t,"g",(function(){return Q}));var r=n("tJVT"),a=n("k1fw"),i=n("oBTY"),o=n("COtZ"),c=n("0SIm"),u=n("Rzkh"),l=n("lO8B"),s=n("GPui"),d=n("WRAw"),f=n("6GND"),p=n("EKfP"),m=n("3V3B"),h=n("8MRj"),b=n("mefr"),v=n("hJ9C"),_=n("Vtfu"),g=n("chM4"),y=n("buKw"),O=n("UCuA"),j=n("FJV0"),w=n("1X5l"),k=n("oORW"),E=n("uRgk"),C=n("dUs0"),x=n("04aD"),S=n("qa+J"),F=n("LyJH"),M=n("+s2E"),P=n("K/pY"),A=n("HrPU"),D=n("juLU"),T=n("hNBN"),L=n("psPf"),I=n("sw8h"),U=n("onda"),V=n("AGEi"),R=n("k5tp"),W=n("jfUH"),q={string:void 0,integer:void 0,float:void 0,decimal:void 0,bool:!1,date:void 0,datetime:void 0,time:void 0,image:void 0,file:void 0,video:void 0,ref:void 0,mref:[],bref:[],object:{},array:[]},B={string:"TextInput",text:"TextArea",richtext:"RichTextEditor",integer:"NumberInput",float:"NumberInput",decimal:"NumberInput",bool:"Switch",ref:"Select",mref:"Select",bref:"InlineForm",oref:"Select",boref:"BORefForm",time:"TimePicker",datetime:"DatePicker",date:"DatePicker",image:"ImageUploader",file:"FileUploader",video:"VideoUploader",gallery:"Gallery",transfer:"Transfer",treeselect:"TreeSelect",password:"PasswordInput",checkbox:"Checkbox",cascader:"Cascader",radio:"Radio",object:"ObjectForm",array:"ArrayForm"},K=e.mapValues(B,(function(e,t){return[e].concat(Object(i["a"])({string:["TextArea","PasswordInput","ImageUploader","FileUploader","Radio","VideoUploader"],bool:["Checkbox"],integer:["Radio","TimeStamp"],ref:["Gallery","TreeSelect","Cascader","GroupCascader","Radio","TableSelect"],mref:["Gallery","MultiFileUploader","Transfer","TreeSelect","Checkbox","TableSelect"],text:["RichTextEditor","JsonEditor","CodeEditor"],bref:["InnerTable"]}[t]||[]))})),N={TextInput:_["a"],TextArea:b["a"],RichTextEditor:v["a"],NumberInput:f["a"],Switch:h["a"],Select:m["a"],InlineForm:C["a"],InnerTable:x["a"],TimePicker:g["a"],ImageUploader:s["a"],FileUploader:l["a"],MultiFileUploader:V["a"],VideoUploader:d["a"],Gallery:j["a"],Transfer:O["a"],TreeSelect:w["a"],PasswordInput:k["a"],Checkbox:u["a"],Cascader:o["a"],GroupCascader:c["a"],Radio:p["a"],DatePicker:y["a"],ObjectForm:F["a"],BORefForm:M["a"],ArrayForm:S["a"],IconSelect:E["a"],ModelSelect:P["a"],FieldPicker:A["a"],RefEdit:D["a"],JsonEditor:T["a"],CodeEditor:L["a"],TimeStamp:I["a"],MapPicker:U["a"],TableSelect:R["a"]},H={TextInput:"\u5355\u884c\u8f93\u5165\u6846",TextArea:"\u591a\u884c\u8f93\u5165\u6846",RichTextEditor:"\u5bcc\u6587\u672c\u7f16\u8f91\u5668",NumberInput:"\u6570\u5b57\u8f93\u5165\u6846",Switch:"\u5f00\u5173",Select:"\u4e0b\u62c9\u9009\u62e9\u5668",TableSelect:"\u8868\u683c\u9009\u62e9",InlineForm:"\u5185\u8054\u8868\u5355",InnerTable:"\u5185\u5d4c\u8868\u683c",TimePicker:"\u65f6\u95f4\u9009\u62e9\u5668",ImageUploader:"\u56fe\u7247\u4e0a\u4f20",FileUploader:"\u6587\u4ef6\u4e0a\u4f20",MultiFileUploader:"\u6587\u4ef6\u4e0a\u4f20",VideoUploader:"\u89c6\u9891\u4e0a\u4f20",Gallery:"\u56fe\u7247\u4e0a\u4f20",Transfer:"\u7a7f\u68ad\u6846",TreeSelect:"\u6811\u578b\u9009\u62e9\u5668",PasswordInput:"\u5bc6\u7801\u8f93\u5165\u6846",Checkbox:"\u590d\u9009\u6846",Cascader:"\u7ea7\u8054\u9009\u62e9\u5668\uff08\u6811\u5f62\uff09",GroupCascader:"\u7ea7\u8054\u9009\u62e9\u5668\uff08\u5206\u7ec4\uff09",Radio:"\u5355\u9009\u6846",DatePicker:"\u65e5\u671f\u9009\u62e9\u5668",ObjectForm:"\u5bf9\u8c61\u8868\u5355",ArrayForm:"\u6570\u7ec4\u8868\u5355",IconSelect:"\u56fe\u6807\u9009\u62e9\u5668",ModelSelect:"\u6a21\u578b\u9009\u62e9\u5668",JsonEditor:"JSON",CodeEditor:"\u4ee3\u7801\u7f16\u8f91\u5668",TimeStamp:"\u65f6\u95f4\u6233",FieldPicker:"\u5b57\u6bb5\u9009\u62e9\u5668",MapPicker:"\u5730\u56fe\u62fe\u53d6\u5668"};function z(e,t,n){N[e]=t,H[e]=n||e}function J(t,n){var r={};if(!t||!n)return r;var a=n.map((function(t){return e.isObject(t)?t.name:t}));return t.fields.filter((function(e){return a.includes(e.name)})).forEach((function(e){var t=e.default;r[e.name]=void 0!==t?t:q[e.type]})),r}function Y(){var e=Object(W["fb"])((function(e){var t=e.formWidgets;return t}));return e?Object(a["a"])(Object(a["a"])({},N),e):N}function G(){var e=Object(W["fb"])((function(e){var t=e.formWidgetNames;return t}));return e?Object(a["a"])(Object(a["a"])({},H),e):H}function Q(){var t=Object(W["fb"])((function(e){var t=e.formTypeMapWidget;return t}));if(t){var n=e.mapValues(K,(function(e){return Object(i["a"])(e)}));return t.forEach((function(e){var t=Object(r["a"])(e,2),a=t[0],i=t[1];i in n&&n[i].push(a)})),n}return K}}).call(this,n("LvDl"))},AAgL:function(e,t,n){"use strict";n.d(t,"a",(function(){return s}));var r=n("k1fw"),a=n("fWQN"),i=n("mtLc"),o=n("yKVA"),c=n("879j"),u=n("q1tI"),l=n.n(u),s=function(e){Object(o["a"])(n,e);var t=Object(c["a"])(n);function n(){var e;Object(a["a"])(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),e.options={},e.commonProps=["dispatch","children","data-__field","data-__meta","content","schemas","value","form","field","onChange","monitorfields","monitorvalues","validateparams","extra"],e.myProps=[],e}return Object(i["a"])(n,[{key:"widgetProps",get:function(){var e=this.props,t=this.commonProps.concat(this.myProps),n=Object(r["a"])({},this.options);return Object.keys(this.props).forEach((function(r){-1===t.indexOf(r)&&(n[r]=e[r])})),n}}]),n}(l.a.PureComponent)},AGEi:function(e,t,n){"use strict";n("nTdE");var r=n("IZHl"),a=(n("+L6B"),n("2/Rp")),i=n("jrin"),o=n("oBTY"),c=n("tJVT"),u=n("q1tI"),l=n.n(u),s=n("z7Xi"),d=n("jfUH");t["a"]=function(e){var t=e.field.ref,n=e.urlField,f=void 0===n?"url":n,p=e.onChange,m=e.value,h=Object(u["useState"])([]),b=Object(c["a"])(h,2),v=b[0],_=b[1],g=Object(d["pb"])(t),y=Object(d["xb"])(t),O=Object(o["a"])(v);m&&m.length&&(O=O.concat(m.map((function(e){var t;return{id:g(e),url:e[f]&&e[f].split("#")[0],uid:e[f],name:null!==(t=y(e))&&void 0!==t?t:e[f]}}))));var j=Object(d["zb"])(),w=Object(d["yb"])(t),k=Object(d["qb"])(t);return l.a.createElement(r["a"].Dragger,{action:j.uploadHost,data:j.formData,beforeUpload:j.init,multiple:!0,fileList:O,onChange:function(e){var t=e.file,n=e.fileList;_(n.filter((function(e){return"uploading"===e.status})));var r=function(){var e=j.getUrl(t),n=Object(i["a"])({},f,e);return k!==w&&(n[w]=t.name),n};p(n.filter((function(e){return"done"===e.status})).map(r).concat(n.filter((function(e){return void 0===e.status})).map((function(e){return m.find((function(t){return t[f]===e.uid}))}))))}},l.a.createElement("p",{className:"ant3-upload-drag-icon"},l.a.createElement(s["a"],null)),l.a.createElement("p",{className:"ant3-upload-text"},l.a.createElement(a["a"],null,"\u70b9\u51fb\u4e0a\u4f20")),l.a.createElement("p",{className:"ant3-upload-hint"},"\u6216\u62d6\u52a8\u6587\u4ef6\u76f4\u6b64\u5904"))}},AhFF:function(e,t,n){"use strict";(function(e){n("UvA9");var r=n("u4G2"),a=(n("eNCU"),n("pjJH")),i=(n("GPKB"),n("mFAc")),o=n("k1fw"),c=n("oBTY"),u=n("9og8"),l=n("tJVT"),s=(n("Dvpn"),n("myml")),d=n("WmNS"),f=n.n(d),p=n("q1tI"),m=n.n(p),h=n("/MKj"),b=n("jfUH"),v=n("mmaM"),_=s["a"].Column,g=s["a"].ColumnGroup,y="read",O="write",j=function(t){var n=t.dispatch,d=t.detailObject,h=d.app_label,j=d.table_name,w="".concat(h,"__").concat(j),k=Object(p["useState"])([]),E=Object(l["a"])(k,2),C=E[0],x=E[1],S=Object(p["useState"])(),F=Object(l["a"])(S,2),M=F[0],P=F[1],A=Object(p["useState"])(!1),D=Object(l["a"])(A,2),T=D[0],L=D[1],I=Object(p["useState"])([]),U=Object(l["a"])(I,2),V=U[0],R=U[1],W=Object(b["rb"])(w),q=Object(b["db"])(w),B=function(){var t=Object(u["a"])(f.a.mark((function t(){return f.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(e.isEmpty(C)){t.next=2;break}return t.abrupt("return");case 2:Object(v["queryContent"])({model:"auth__group"}).then(P),null===W||void 0===W||W.fields.forEach((function(e){C.push({name:e.name,field:e.displayName})})),x(Object(c["a"])(C)),R(q.map((function(e){return Object(o["a"])({},e)})));case 6:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}();Object(p["useEffect"])((function(){B()}),[W]);var K=function(e,t,n,r){var a=V.find((function(e){return e.group===t&&e.field===n})),i=a||{group:t,field:n};"write"===r&&e&&(i.read=!0),i[r]=e,a||V.push(i),R(Object(c["a"])(V))},N=function(e,t,n){var r=V.find((function(n){return n.group===e&&n.field===t}))||{};return r[n]},H=function(){var e=Object(u["a"])(f.a.mark((function e(){return f.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return L(!0),e.prev=1,e.next=4,Object(v["cloudFunction"])({model:"bsm_config__fieldpermission",functionName:"update_field_permission",params:{model:w,permissions:V}});case 4:n({type:"content/getConfig"}),e.next=10;break;case 7:e.prev=7,e.t0=e["catch"](1),i["a"].error("error");case 10:L(!1),i["a"].success("\u4fee\u6539\u6210\u529f");case 12:case"end":return e.stop()}}),e,null,[[1,7]])})));return function(){return e.apply(this,arguments)}}();return m.a.createElement("div",null,m.a.createElement(s["a"],{bordered:!0,dataSource:C,pagination:!1,footer:function(){return m.a.createElement("div",{style:{display:"flex",justifyContent:"flex-end"}},m.a.createElement(a["a"],{type:"primary",loading:T,onClick:H},"\u66f4\u65b0"))}},m.a.createElement(_,{title:"\u5b57\u6bb5\u540d",dataIndex:"field",key:"name"}),m.a.createElement(g,{title:"\u89d2\u8272"},M&&M.list.map((function(e){return m.a.createElement(_,{title:e.name,key:e.id,render:function(t,n){return m.a.createElement("div",null,m.a.createElement(r["a"],{disabled:N(e.id,n.name,O),checked:N(e.id,n.name,y),onChange:function(t){var r=t.target.checked;return K(r,e.id,n.name,y)}},"\u8bfb"),m.a.createElement(r["a"],{checked:N(e.id,n.name,O),onChange:function(t){var r=t.target.checked;return K(r,e.id,n.name,O)}},"\u5199"))}})})))))};t["a"]=Object(h["c"])()(j)}).call(this,n("LvDl"))},BAaj:function(e,t,n){"use strict";n("g9YV");var r=n("wCAj"),a=n("0Owb"),i=(n("ascH"),n("GqlH")),o=n("PpiC"),c=n("fWQN"),u=n("mtLc"),l=n("yKVA"),s=n("879j"),d=n("k1fw"),f=n("q1tI"),p=n.n(f),m=n("FTpL"),h=n.n(m);function b(e){var t=[];return e.forEach((function(e){e.needTotal&&t.push(Object(d["a"])(Object(d["a"])({},e),{},{total:0}))})),t}var v=function(e){Object(l["a"])(n,e);var t=Object(s["a"])(n);function n(e){var r;Object(c["a"])(this,n),r=t.call(this,e),r.handleRowSelectChange=function(e,t){var n=r.state.needTotalList;n=n.map((function(e){return Object(d["a"])(Object(d["a"])({},e),{},{total:t.reduce((function(t,n){return t+parseFloat(n[e.dataIndex],10)}),0)})}));var a=r.props.onSelectRow;a&&a(t),r.setState({selectedRowKeys:e,needTotalList:n})},r.handleTableChange=function(e,t,n){var a=r.props.onChange;a&&a(e,t,n)},r.cleanSelectedKeys=function(){r.handleRowSelectChange([],[])};var a=e.columns,i=b(a);return r.state={selectedRowKeys:[],needTotalList:i},r}return Object(u["a"])(n,[{key:"render",value:function(){var e=this.state,t=e.selectedRowKeys,n=e.needTotalList,c=this.props,u=c.data,l=void 0===u?{}:u,s=c.rowKey,m=c.shouldSelect,b=c.expandOptions,v=void 0===b?{}:b,_=Object(o["a"])(c,["data","rowKey","shouldSelect","expandOptions"]),g=l.list,y=void 0===g?[]:g,O=l.pagination,j=!!O&&Object(d["a"])({showSizeChanger:!0,showQuickJumper:!0},O),w=m?{selectedRowKeys:t,onChange:this.handleRowSelectChange,getCheckboxProps:function(e){return{disabled:e.disabled}}}:null;return p.a.createElement("div",{className:h.a.standardTable},t.length>0?p.a.createElement("div",{className:h.a.tableAlert},p.a.createElement(i["a"],{message:p.a.createElement(f["Fragment"],null,"\u5df2\u9009\u62e9 ",p.a.createElement("a",{style:{fontWeight:600}},t.length)," \u9879\xa0\xa0",n.map((function(e){return p.a.createElement("span",{style:{marginLeft:8},key:e.dataIndex},e.title,"\u603b\u8ba1\xa0",p.a.createElement("span",{style:{fontWeight:600}},e.render?e.render(e.total):e.total))})),p.a.createElement("a",{onClick:this.cleanSelectedKeys,style:{marginLeft:24}},"\u6e05\u7a7a")),type:"info",showIcon:!0})):"",p.a.createElement(r["a"],Object(a["a"])({rowKey:s||"key",rowSelection:w,dataSource:y,pagination:j,onChange:this.handleTableChange},_,v)))}}],[{key:"getDerivedStateFromProps",value:function(e){if(0===e.selectedRows.length){var t=b(e.columns);return{selectedRowKeys:[],needTotalList:t}}return null}}]),n}(f["PureComponent"]);t["a"]=v},"BE/h":function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));n("52nx");var r=n("7bDm"),a=n("q1tI"),i=n.n(a),o=n("jfUH");function c(e){var t=e.currentActionObject,n=e.currentActionParams,c=void 0===n?{}:n,u=e.model,l=e.currentObject,s=e.context,d=e.visible,f=e.handleOk,p=e.handleCancel,m=Object(o["ub"])();function h(){var e=t.name,n=t.title;return n?"function"===typeof n?n({model:u,currentObject:l,currentActionObject:t,currentActionParams:c,Schemas:m}):n:e}function b(){var e=t.width,n="60%";return e||n}function v(){var e=t.component;return e?e({model:u,currentActionObject:t,currentObject:l,currentActionParams:c,context:s}):i.a.createElement(a["Fragment"],null)}return i.a.createElement(r["a"],{title:h(),width:b(),destroyOnClose:!0,visible:d,closable:!0,keyboard:!0,onOk:f,onCancel:p,footer:null},v())}},COtZ:function(e,t,n){"use strict";(function(e){var r=n("fWQN"),a=n("mtLc"),i=n("yKVA"),o=n("879j"),c=(n("lNFX"),n("VE2L")),u=n("0Owb"),l=n("q1tI"),s=n.n(l),d=n("AAgL"),f=n("jfUH"),p=function(e){var t=e.optionList,n=e.choiceObject,r=e.initialValue,a=e.widgetProps,i=e.onChange,o=e.leafOnly,l=void 0!==o&&o;return s.a.createElement(c["a"],Object(u["a"])({options:t,onChange:function(e){return i(e.length?n[e.slice(-1)[0]]:null)},value:r,changeOnSelect:!l,expandTrigger:l?"click":"hover"},a))},m=function(e){Object(i["a"])(n,e);var t=Object(o["a"])(n);function n(){var e;Object(r["a"])(this,n);for(var a=arguments.length,i=new Array(a),o=0;o<a;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),e.myProps=["remoteChoices"],e}return Object(a["a"])(n,[{key:"render",value:function(){var e=this.props,t=e.onChange,n=e.leafOnly,r=e.choiceObject,a=e.optionList,i=e.initialValue;return s.a.createElement(p,{onChange:t,leafOnly:n,optionList:a,choiceObject:r,initialValue:i,widgetProps:this.widgetProps})}}]),n}(d["a"]);t["a"]=function(t){var n=Object(f["vb"])((function(e){var t=e.content;return t.all})),r=t.field.ref,a=Object(f["S"])(r),i=Object(f["rb"])(r),o=Object(f["yb"])(r),c=t.parent,d=void 0===c?a.parentField||i.parentField||"parent":c,p=Object(l["useCallback"])((function(e){return Object(f["Q"])(e,r,d)}),[d,r]),h=n[r],b=Object(l["useMemo"])((function(){return e.fromPairs((h||[]).map((function(e){return[p(e),e]})))}),[h,p]),v=Object(l["useMemo"])((function(){var t=e.mapValues(b,(function(e){return{value:p(e),label:e[o]}}));return e.forEach(b,(function(e,n){var r=e[d];r&&(t[r].children||(t[r].children=[]),t[r].children.push(t[n]))})),e.filter(t,(function(e,t){return!b[t][d]}))}),[b,p,d,o]),_=t.value,g=_&&!e.isEmpty(b),y=Object(l["useMemo"])((function(){if(!g)return[];var e=p(_),t=[];do{t.unshift(e),e=b[e][d]}while(e);return t}),[g,b,p,d,_]),O=Object(f["Y"])("cacheAll"),j=t.field.type,w=Object(l["useCallback"])((function(){Object(f["C"])(j)&&O({model:r,titleField:o})}),[O,j,r,o]);return Object(l["useEffect"])((function(){w()}),[w]),s.a.createElement(m,Object(u["a"])({},t,{choiceObject:b,optionList:v,initialValue:y}))}}).call(this,n("LvDl"))},CsTM:function(e,t,n){e.exports={clickable:"clickable___1U41I"}},CzB9:function(e,t,n){"use strict";(function(e){n("O3gP");var r=n("lrIw"),a=(n("5NDa"),n("5rEg")),i=n("tJVT"),o=n("q1tI"),c=n.n(o),u=n("mmaM"),l=n("jfUH"),s=n("l+S1");t["a"]=function(t){var n=t.model,d=t.searchFields,f=void 0===d?[]:d,p=t.onSearch,m=Object(o["useState"])([]),h=Object(i["a"])(m,2),b=h[0],v=h[1],_=Object(l["sb"])(n),g=Object(l["yb"])(n),y=Object(o["useRef"])(null),O=function(e){var t;return null===(t=_(e))||void 0===t?void 0:t.displayName},j=function(e){return e?Object(u["queryContent"])({model:n,page:1,size:7,filters:[{operator:"or",children:f.map((function(t){return{field:t,operator:"icontains",value:e}}))}]}).then((function(e){return e.list})):[]},w=Object(l["ab"])(j,(function(t,n){var r=f.map((function(r){return{label:"\u6309".concat(O(r),"\u67e5\u627e"),options:t.map((function(t){return[e.get(t,r),t]})).map((function(e){var t=Object(i["a"])(e,2),n=t[0],r=t[1];return[String(n),r]})).filter((function(e){var t=Object(i["a"])(e,1),r=t[0];return null===r||void 0===r?void 0:r.includes(n)})).map((function(e){var t=Object(i["a"])(e,2),a=t[0],o=t[1];return{value:a,label:c.a.createElement(c.a.Fragment,null,Object(l["y"])(a,n)," ",g!==r&&c.a.createElement("span",{style:{opacity:.45}},o[g]))}}))}})).filter((function(e){return e.options.length}));v(r)})),k=Object(i["a"])(w,1),E=k[0];return c.a.createElement(r["a"],{backfill:!0,style:{width:"100%"},options:b,onSearch:function(e){return E(e.trim())}},c.a.createElement(a["a"].Search,{placeholder:"\u641c\u7d22".concat(f.map(O).join("\u3001")),ref:y,onMouseDown:function(e){e.stopPropagation(),e.preventDefault()},size:"large",enterButton:c.a.createElement(c.a.Fragment,null,c.a.createElement(s["a"],null)," \u641c \u7d22",c.a.createElement("div",{style:{position:"absolute",left:0,right:0,top:0,bottom:0},onMouseDown:function(e){e.stopPropagation(),e.preventDefault()}})),onSearch:function(e,t){t.stopPropagation(),t.preventDefault(),y.current.blur(),p(e.trim())}}))}}).call(this,n("LvDl"))},EBSl:function(e,t,n){"use strict";(function(e){n.d(t,"c",(function(){return h})),n.d(t,"d",(function(){return b})),n.d(t,"b",(function(){return v})),n.d(t,"j",(function(){return _})),n.d(t,"e",(function(){return g})),n.d(t,"g",(function(){return y})),n.d(t,"h",(function(){return O})),n.d(t,"f",(function(){return j})),n.d(t,"i",(function(){return w})),n.d(t,"a",(function(){return k})),n.d(t,"p",(function(){return E})),n.d(t,"m",(function(){return C})),n.d(t,"n",(function(){return x})),n.d(t,"o",(function(){return P})),n.d(t,"l",(function(){return K})),n.d(t,"k",(function(){return N}));n("GPKB");var r=n("mFAc"),a=(n("52nx"),n("7bDm")),i=n("tJVT"),o=n("9og8"),c=n("k1fw"),u=n("WmNS"),l=n.n(u),s=n("RLxJ"),d=n("4a3J"),f=n("jfUH"),p=n("mmaM"),m=n("q1tI"),h="ACTION_TYPE_INLINE",b="ACTION_TYPE_MODEL",v="ACTION_TYPE_BATCH",_="modal",g="action",y="func",O="info",j="drawer",w="link",k={ACTION_TYPE_INLINE:{},ACTION_TYPE_MODEL:{},ACTION_TYPE_BATCH:{}};function E(e){var t=e.type,n=e.action,r=k[t];r[n]=e}function C(e,t){var n=k[e];return n[t]}function x(t,n){var r=window.g_app._store.getState(),a=r.bsmSetting,i=k[t];return e.values(i).filter((function(e){var t=e.autoAdd,r=e.shouldShow,i=e.model,o=!1;if(n&&i){var c="function"===typeof i?i({setting:a}):i;o=c===n}var u=!0;return r&&"function"===typeof r&&(u=r({setting:a})),t&&o&&u}))}function S(e){var t=e.config;return t}function F(e){var t=e.config;return t}function M(t){var n,r,a=t.config,i=t.record,o=t.model,c=t.modalForm,u=t.modalDetail,l=Object(f["K"])(i,o),s=o;if(null!==(n=a.params)&&void 0!==n&&n.field){var d=Object(f["r"])(o,a.params.field,i),p=d.id,m=d.schemaField;if(void 0===p)return{type:"message",title:a.title,action:"message",params:{type:"info",text:"\u6682\u65e0".concat(a.title)}};s=m.ref,p&&(l=p)}switch(a.action||a.type){case"copy":return{action:"copy",type:"modal",title:a.title,confirm:a.confirm,params:{isCopy:!0}};case"nowEdit":return{action:"patch",type:"func",title:a.title,confirm:a.confirm,params:{payload:a.params}};case"partEdit":return e.isEmpty(a.params.editFields)?{action:"patch",type:"func",title:a.title,confirm:a.confirm,params:{payload:a.params}}:{type:"modal",action:"partEdit",title:a.title,confirm:a.confirm,params:a.params};case"edit":return c&&(null===(r=a.params)||void 0===r||!r.field)||a.modalForm||a.showInModal?{type:"modal",action:"edit",title:a.title,confirm:a.confirm}:{type:"link",action:"edit",params:{link:"/content/".concat(s,"/edit/").concat(l)},confirm:a.confirm,title:a.title};case"refEdit":return a.showInModal?{type:"modal",action:"refEdit",title:a.title,confirm:a.confirm,params:{field:a.params.field}}:{type:"link",action:"refEdit",params:{link:"/content/".concat(s,"/edit/").concat(l)},title:a.title,confirm:a.confirm};case"refAdd":return{type:"modal",action:"refAdd",title:a.title,confirm:a.confirm,params:{field:a.params.field,action:"refAdd",values:a.params.values}};case"delete":return{type:"func",action:"delete",title:a.title,confirm:a.confirm||!0,params:{action:"delete",payload:{model:o,id:Object(f["K"])(i,o)}}};case"detail":var h,b=a.params.page;return!u||null!==(h=a.params)&&void 0!==h&&h.field?{type:"link",action:"detail",params:{link:"/content/".concat(s,"/detail/").concat(l).concat(b?"/".concat(b):"")},title:a.title,confirm:a.confirm}:{type:"modal",title:a.title,confirm:a.confirm,action:"detail",params:{page:b,type:"detail"}};case"refDetail":return a.showInModal?{type:"modal",title:a.title,confirm:a.confirm,action:"refDetail",params:{type:"detail",field:a.params.field}}:{type:"link",action:"refDetail",params:{link:"/content/".concat(s,"/detail/").concat(l)},title:a.title,confirm:a.confirm};default:return a.action||(a.action=a.type),a}}function P(e,t){return e===h?Object(c["a"])(Object(c["a"])({},M(t)),{},{sence:h}):e===v?Object(c["a"])(Object(c["a"])({},S(t)),{},{sence:v}):Object(c["a"])(Object(c["a"])({},F(t)),{},{sence:b})}function A(e){e.startsWith("http")?window.open(e,"__blank"):s["a"].push(e)}function D(e,t,n){var r=t.record,a=C(e.sence,e.action),i=n.link(r,a,e.params);A(i)}function T(e,t,n){var r=t.record,a=C(e.sence,e.action);n.showModal(r,a,e.params)}function L(e,t,n){var r=t.record,a=C(e.sence,e.action);n.showDrawer(r,a,e.params)}function I(e,t,n){var r,a=t.record,i=t.model,o=Object(c["a"])(Object(c["a"])({},C(e.sence,e.action)),{},{params:e.params}),u=o.func;if(!u&&(null!==(r=e.params)&&void 0!==r&&r.func))return e.params.func(Object(f["K"])(a,i));return e.sence===h?u(a,i,o,n):e.sence===b?u(i,o,n):e.sence===v?u(a,i,o,n):null}function U(e,t,n){return V.apply(this,arguments)}function V(){return V=Object(o["a"])(l.a.mark((function e(t,n,r){var a,i,o,c,u,s,d,p,m,h,b=arguments;return l.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:for(a=n.success,i=n.error,o=n.title,c=r.record,u=r.model,s=c?Object(f["K"])(c,u):"",d="".concat(n.title,":").concat(s),p=b.length,m=new Array(p>3?p-3:0),h=3;h<p;h++)m[h-3]=b[h];return e.next=7,Object(f["M"])(t.apply(void 0,[n,r].concat(m)),{title:o,key:d,success:a,error:i});case 7:case"end":return e.stop()}}),e)}))),V.apply(this,arguments)}var R=U.bind(null,I);function W(e,t,n){var o,u,l,s=t.record,m=void 0===s?null:s,b=t.model,_={type:e.sence,action:"action",name:"\u4e91\u51fd\u6570",rspType:g,confirm:e.sence===v},y=Object(c["a"])(Object(c["a"])({},_),{},{params:e.params}),O=(null===y||void 0===y||null===(o=y.params)||void 0===o?void 0:o.payload)||{};e.sence===h&&(O.id=Object(f["K"])(m,b)),e.sence===v&&(O.ids=m.map((function(e){return Object(f["K"])(e,b)})));var j=function(t,o,c){return Object(p["cloudFunction"])({model:b,functionName:y.cloudFunc||y.params.action,params:t}).then((function(t){var u=t.result,l=void 0===u?"":u,s=t.error_code,d=t.error_message,f=t.logs;null===f||void 0===f||f.forEach((function(e){var t=Object(i["a"])(e,2),n=t[0],r=t[1];switch(n){case 10:console.debug(r);break;case 20:console.info(r);break;case 30:console.warn(r);break;case 40:case 50:console.error(r);break;default:console.log(r)}}));var p=y.callback;p?p(n):n.refresh(),"0"===s?o?o(l,n):r["a"].success("".concat(e.title||e.name||"","\u6267\u884c\u6210\u529f")):c?c(s,d):a["a"].error({title:"\u6267\u884c\u5931\u8d25",content:d})}))},w=function(t,i){var o="tip";return i||r["a"].loading({content:"".concat(e.title||e.name||"","\u6267\u884c\u4e2d"),key:o,duration:0}),j(t,(function(t){var c;i&&n.hideCollectInput(),null!==(c=y.params)&&void 0!==c&&c.rsp_processor?("show"===y.params.rsp_processor&&(a["a"].info({title:"\u6267\u884c\u7ed3\u679c",content:Object(d["a"])(t)}),r["a"].success({content:"".concat(e.title||e.name||"","\u6267\u884c\u5b8c\u6bd5"),duration:1,key:o})),"nop"===y.params.rsp_processor&&r["a"].success({content:"".concat(e.title||e.name||"","\u6267\u884c\u6210\u529f"),key:o})):r["a"].success({content:"".concat(e.title||e.name||"","\u6267\u884c\u6210\u529f"),key:o})}),(function(t,n){r["a"].error({key:o,content:"".concat(e.title||e.name||"","\u6267\u884c\u5931\u8d25, \u9519\u8bef\u4ee3\u7801\uff1a").concat(t,", \u9519\u8bef\u6d88\u606f\uff1a").concat(n)})}))};return null!==y&&void 0!==y&&null!==(u=y.params)&&void 0!==u&&u.fields&&(null===y||void 0===y||null===(l=y.params)||void 0===l?void 0:l.fields.length)>0?n.collectInputs(y.params.fields,(function(e){return O=Object(c["a"])(Object(c["a"])({},O),e),w(O,!0)}),(function(){console.log("\u53d6\u6d88\u4e86\u8f93\u5165")})):w(O,!1)}function q(e){var t=e.params,n=t.type,a=void 0===n?"info":n,i=t.text,o=void 0===i?"":i;r["a"][a](o)}function B(e,t){var n=e.params,r=n.type,i=void 0===r?"info":r,o=n.title,c=n.content,u=t.record;a["a"][i]({title:Object(f["O"])(o,(function(e){return u[e]})),content:Object(f["O"])(c,(function(e){return u[e]}))})}function K(e,t,n){var r=e.type,i=a["a"].confirm,o=C(e.sence,e.action);r||(r=o.rspType);var c=function(){switch(r){case"link":return D(e,t,n);case"modal":return T(e,t,n);case"action":return W(e,t,n);case"func":return R(e,t,n);case"info":return B(e,t,n);case"message":return q(e,t,n);case"drawer":return L(e,t,n);default:return null}},u=e.confirm||(null===o||void 0===o?void 0:o.confirm);if(u&&e.sence!==h){var l="string"===typeof u?u:"\u60a8\u786e\u8ba4\u5bf9\u9009\u4e2d\u7684\u591a\u6761\u6570\u636e\u8fdb\u884c".concat(e.title||e.name,"\u64cd\u4f5c\u5417\uff1f");return i({title:"\u786e\u8ba4\u6267\u884c\u6279\u91cf\u64cd\u4f5c",content:l,onOk:function(){return c()},onCancel:function(){}})}return c()}var N=function(e){var t=e.action,n=e.model,r=e.handler,a=e.children,i=Object(m["useContext"])(f["b"]);if(t.action in i.tableActions){var o=i.tableActions[t.action],c=new o(t.title);return a(c.onTrigger,c.renderTitle())}return a((function(){return K(t,{model:n},r)}),t.title)}}).call(this,n("LvDl"))},EKfP:function(e,t,n){"use strict";n.d(t,"a",(function(){return p}));var r=n("0Owb"),a=(n("6dnR"),n("CQJL")),i=n("tJVT"),o=n("fWQN"),c=n("mtLc"),u=n("yKVA"),l=n("879j"),s=n("q1tI"),d=n.n(s),f=n("AAgL"),p=function(e){Object(u["a"])(n,e);var t=Object(l["a"])(n);function n(){var e;Object(o["a"])(this,n);for(var r=arguments.length,a=new Array(r),i=0;i<r;i++)a[i]=arguments[i];return e=t.call.apply(t,[this].concat(a)),e.myProps=["choices"],e}return Object(c["a"])(n,[{key:"render",value:function(){var e=this.props,t=e.value,n=e.onChange,o=e.choices;return d.a.createElement(a["a"].Group,Object(r["a"])({onChange:function(e){return n(e.target.value)},value:t},this.widgetProps),o.map((function(e){var t=Object(i["a"])(e,2),n=t[0],r=t[1];return d.a.createElement(a["a"],{key:n,value:n},r)})))}}]),n}(f["a"])},"EnK/":function(e,t,n){e.exports={renderField:"renderField___1NkOd",renderIcon:"renderIcon___36Kxc"}},FJV0:function(e,t,n){"use strict";n("nTdE");var r,a,i,o=n("IZHl"),c=n("0Owb"),u=(n("eE3J"),n("GSZB")),l=n("jrin"),s=n("fWQN"),d=n("mtLc"),f=n("yKVA"),p=n("879j"),m=n("q1tI"),h=n.n(m),b=n("/MKj"),v=n("OFLC"),_=n("AAgL"),g=n("jfUH"),y=(r=Object(b["c"])((function(e){var t=e.content;return{content:t}})),a=Object(g["d"])((function(){return{uploader:Object(g["zb"])()}})),r(i=a(i=function(e){Object(f["a"])(n,e);var t=Object(p["a"])(n);function n(){var e;Object(s["a"])(this,n);for(var r=arguments.length,a=new Array(r),i=0;i<r;i++)a[i]=arguments[i];return e=t.call.apply(t,[this].concat(a)),e.state={previewUrl:!1,preview:!1,uploadingList:[]},e.getThumb=function(t){var n=e.props.uploadProvider;return Object(g["v"])(t,{uploadProvider:n})},e.handleUpload=function(t){var n=t.file,r=t.fileList,a=e.props,i=a.onChange,o=a.urlField,c=void 0===o?"url":o,u=a.field,s=a.value;e.setState({uploadingList:r.filter((function(e){return"uploading"===e.status}))});var d=function(){var t=e.props.uploader.getUrl(n),r=Object(l["a"])({},c,t);return Object(g["L"])(u.ref)!==e.titleField&&(r[e.titleField]=n.name),r};Object(g["D"])(u)?"done"===n.status&&i(d(n)):"mref"!==u.type&&"array"!==u.type||i(r.filter((function(e){return"done"===e.status})).map(d).concat(r.filter((function(e){return void 0===e.status})).map((function(e){return s.find((function(t){return t[c]===e.uid}))}))))},e}return Object(d["a"])(n,[{key:"titleField",get:function(){return this.refSchema.titleField}},{key:"refSchema",get:function(){var e=this.props.content.schemas;return e[this.refModel]}},{key:"refModel",get:function(){var e=this.props.field;return e.ref}},{key:"render",value:function(){var e=this,t=this.state,n=t.previewUrl,r=t.preview,a=t.uploadingList,i=this.props,l=i.value,s=i.field,d=i.urlField,f=void 0===d?"url":d,p=i.onChange,m=h.a.createElement("div",null,h.a.createElement(u["a"],{type:"plus"}),h.a.createElement("div",{className:"ant-upload-text"},"\u4e0a\u4f20")),b=h.a.createElement(v["a"],{onClose:function(){return e.setState({preview:!1})},url:n,visible:r}),_=a;return Object(g["D"])(s)?(l&&l[f]&&(_=_.concat({id:Object(g["K"])(l,s.ref),url:l[f],thumbUrl:this.getThumb(l[f]),uid:l[f]})),h.a.createElement("div",null,h.a.createElement(o["a"],Object(c["a"])({listType:"picture-card",action:this.props.uploader.uploadHost,data:this.props.uploader.formData,fileList:_,onChange:this.handleUpload,onRemove:function(){return p(null)},onPreview:function(t){return e.setState({previewUrl:t.url,preview:!0})},beforeUpload:this.props.uploader.init,accept:"image/*",multiple:!0},this.widgetProps),_.length?null:m),b)):"mref"===s.type||"array"===s.type?(l&&l.length&&(_=_.concat(l.map((function(t){return{id:Object(g["K"])(t,s.ref),url:t[f],thumbUrl:e.getThumb(t[f]),uid:t[f]}})))),h.a.createElement("div",null,h.a.createElement(o["a"],Object(c["a"])({listType:"picture-card",action:this.props.uploader.uploadHost,data:this.props.uploader.formData,fileList:_,onChange:this.handleUpload,beforeUpload:this.props.uploader.init,onPreview:function(t){return e.setState({previewUrl:t.url,preview:!0})},accept:"image/*",multiple:!0},this.widgetProps),m),b)):null}}]),n}(_["a"]))||i)||i);t["a"]=y},FTpL:function(e,t,n){e.exports={standardTable:"standardTable___22bpW",tableAlert:"tableAlert___3nGm4"}},G3ML:function(e,t,n){"use strict";(function(e){n("4csm");var r=n("2Fwu"),a=(n("eE3J"),n("GSZB")),i=(n("9kbU"),n("vbHR")),o=(n("QjdF"),n("U4Vl")),c=(n("eNCU"),n("pjJH")),u=n("0Owb"),l=n("PpiC"),s=n("tJVT"),d=(n("uPNz"),n("Oedt")),f=(n("52nx"),n("7bDm")),p=n("9og8"),m=n("fWQN"),h=n("mtLc"),b=n("yKVA"),v=n("879j"),_=n("WmNS"),g=n.n(_),y=n("q1tI"),O=n.n(y),j=n("EBSl"),w=n("rQ+i"),k=n("Utjr"),E=n("gMH0"),C=n.n(E),x="link",S="button",F=function(t){Object(b["a"])(_,t);var n=Object(v["a"])(_);function _(e){var t;Object(m["a"])(this,_),t=n.call(this,e),t.onClick=function(){var e=Object(p["a"])(g.a.mark((function e(t,n,r){return g.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,Object(j["l"])(t,n,r);case 2:case"end":return e.stop()}}),e)})));return function(t,n,r){return e.apply(this,arguments)}}();var r=t.props,a=r.items,i=r.model,o=r.record;return t.props.items=Object(w["d"])(a,i,o),t}return Object(h["a"])(_,[{key:"items",get:function(){var t=this.props,n=t.maxItem,r=t.items,a=t.model,i=t.record,o=t.modalForm,c=t.modalDetail,u=r.map((function(t){return e.isFunction(t)?t(i):t})).map((function(e){return Object(j["o"])(j["c"],{config:e,record:i,model:a,modalForm:o,modalDetail:c})})),l=u,s=[];return!1!==n&&u.length>n&&(l=u.slice(0,n-1),s=u.slice(n-1)),{flatenItems:l,foldItems:s}}},{key:"handleMenuClick",value:function(e){var t=this.items.foldItems,n=t[e],r=this.handleItemClick.bind(this,n);if(n.confirm){var a="string"===typeof n.confirm?n.confirm:"\u786e\u5b9a".concat(n.title,"\uff1f");f["a"].confirm({title:a,onOk:r,maskClosable:!0})}else r()}},{key:"handleItemClick",value:function(e){var t=this.props,n=t.onClick,r=t.record,a=t.model;n(e,{record:r,model:a},this.onClick)}},{key:"renderItem",value:function(e,t,n){var r=this,a=this.props.popPlacement,i=function(){return r.handleItemClick(e)},o=function(r){var a=r.onClick,i=r.danger,o=void 0!==i&&i;return O.a.createElement(n,{danger:o,onClick:a,key:t},e.title)};if(e.confirm){var c="string"===typeof e.confirm?e.confirm:"\u786e\u5b9a".concat(e.title,"\uff1f");return O.a.createElement(d["a"],{key:"pop_".concat(t),title:c,onConfirm:i,placement:a,arrowPointAtCenter:!0},O.a.createElement(o,{danger:!0,key:t}))}return O.a.createElement(o,{onClick:i,key:t})}},{key:"render",value:function(){var e=this,t=this.props,n=t.type,d=void 0===n?x:n,f=t.children,p=void 0===f?null:f,m=this.items,h=m.foldItems,b=m.flatenItems;if(!b.length)return p;var v,_=d===S?[function(e){var t=e.danger,n=Object(l["a"])(e,["danger"]);return O.a.createElement(c["a"],Object(u["a"])({className:t&&C.a["action-danger-btn"]},n))},c["a"].Group]:[function(e){var t=e.children,n=e.onClick,r=e.danger;return O.a.createElement("a",{className:r&&C.a["action-danger"],onClick:n},t)},y["Fragment"]],g=Object(s["a"])(_,2),j=g[0],w=g[1],k=[],E=0;return b.forEach((function(t,n){k.push(e.renderItem(t,n,j)),E+=1,d===x&&(E<b.length||h.length)&&k.push(O.a.createElement(o["a"],{type:"vertical",key:"div".concat(E)}))})),h.length>0&&(v=O.a.createElement(r["a"],{overlay:O.a.createElement(i["a"],{onClick:function(t){var n=t.key;return e.handleMenuClick(n)}},h.map((function(e,t){return O.a.createElement(i["a"].Item,{className:e.confirm&&C.a["action-danger"],key:t},e.title)})))},j({children:["\u66f4\u591a ",O.a.createElement(a["a"],{type:"down"})]}))),O.a.createElement("div",{style:{whiteSpace:"nowrap"}},O.a.createElement(w,null,k,v))}}]),_}(k["b"]);F.defaultProps={items:[],maxItem:3,modalForm:!1,model:void 0},t["a"]=F.component}).call(this,n("LvDl"))},G9e4:function(e,t,n){"use strict";(function(e){n.d(t,"b",(function(){return y})),n.d(t,"a",(function(){return _})),n.d(t,"c",(function(){return g}));var r,a=n("PpiC"),i=n("k1fw"),o=n("fWQN"),c=n("mtLc"),u=n("w4Tj"),l=n("oZsa"),s=n("yKVA"),d=n("879j"),f=n("q1tI"),p=n.n(f),m=n("oV5b"),h=n.n(m),b=n("xJcd"),v=n("Utzx"),_=p.a.createContext(),g=p.a.createContext(),y=Object(b["c"])(r=function(t){Object(s["a"])(r,t);var n=Object(d["a"])(r);function r(){var e;Object(o["a"])(this,r);for(var t=arguments.length,a=new Array(t),i=0;i<t;i++)a[i]=arguments[i];return e=n.call.apply(n,[this].concat(a)),e.formItemLayout={},e}return Object(c["a"])(r,[{key:"accessibleFields",value:function(){var e=adminConfig[model]||{},t=e.inlineFormFields,n=void 0===t?[]:t;return Object(u["a"])(Object(l["a"])(r.prototype),"accessibleFields",this).call(this,n)}},{key:"onFieldChange",value:function(e,t,n){var a=this;Object(u["a"])(Object(l["a"])(r.prototype),"onFieldChange",this).call(this,e,t,n);var i=this.inlineData.hasError,o=this.props,c=o.form,s=o.onChange,d=c.getFieldsValue();d[e]=t;var f=this.schema.fields.filter((function(e){return-1!==Object.keys(d).indexOf(e.name)&&"bref"!==e.type})),p={};f.forEach((function(e){var t=Object(v["a"])(e),n=e.name;p[n]=t}));var m=new h.a(p);m.validate(d,(function(e){var t=null!==e;a.inlineData.hasError=t,i===t&&t||s&&s(d)}))}},{key:"fieldProps",value:function(e,t){var n=Object(u["a"])(Object(l["a"])(r.prototype),"fieldProps",this).call(this,e,t);return Object(i["a"])(Object(i["a"])({},n),{},{itemProps:Object(i["a"])(Object(i["a"])({},n.itemProps),{},{label:void 0})})}},{key:"componentDidMount",value:function(){var e=this,t=this.state.contentObject,n=this.props.form;-1===Object.keys(t).indexOf("is__new")&&n.validateFields((function(t){e.inlineData.hasError=null!==t}))}},{key:"getWidget",value:function(t,n){var a=this.props.extraOptions,i=void 0===a?{}:a,o=Object(u["a"])(Object(l["a"])(r.prototype),"getWidget",this).call(this,t,n),c=o.Widget,s=o.options;return{Widget:c,options:e.merge(s,i)}}},{key:"render",value:function(){var e=this,t=this.props,n=(t.form,t.dispatch,Object(a["a"])(t,["form","dispatch"])),r=this.props["data-row-key"],i=function(t,n){return e.renderField(t,n.find((function(e){return(e.name||e)===t.name})))};return p.a.createElement(_.Provider,{value:i},p.a.createElement(g.Consumer,null,(function(t){var a=t;return a[r]||(a[r]=e),p.a.createElement("tr",n)})))}}]),r}(b["b"]))||r}).call(this,n("LvDl"))},GPui:function(e,t,n){"use strict";n("nTdE");var r,a,i=n("IZHl"),o=n("0Owb"),c=(n("eE3J"),n("GSZB")),u=n("fWQN"),l=n("mtLc"),s=n("yKVA"),d=n("879j"),f=n("q1tI"),p=n.n(f),m=n("OFLC"),h=n("AAgL"),b=n("jfUH"),v=(r=Object(b["d"])((function(){return{uploader:Object(b["zb"])()}})),r(a=function(e){Object(s["a"])(n,e);var t=Object(d["a"])(n);function n(){var e;Object(u["a"])(this,n);for(var r=arguments.length,a=new Array(r),i=0;i<r;i++)a[i]=arguments[i];return e=t.call.apply(t,[this].concat(a)),e.state={preview:!1,uploadingList:[]},e.handleChange=function(t){var n=t.file,r=t.fileList,a=e.props.onChange;if(e.setState({uploadingList:r.filter((function(e){return"uploading"===e.status}))}),"done"===n.status){var i=e.props.uploader.getUrl(n);a(i)}},e}return Object(l["a"])(n,[{key:"render",value:function(){var e=this,t=this.state,n=t.preview,r=t.uploadingList,a=this.props,u=a.value,l=a.uploadProvider,s=a.onChange,d=p.a.createElement("div",null,p.a.createElement(c["a"],{type:"plus"}),p.a.createElement("div",{className:"ant-upload-text"},"\u4e0a\u4f20")),f=r;return u&&(f=f.concat({url:u,thumbUrl:Object(b["v"])(u,{uploadProvider:l}),uid:u})),p.a.createElement("div",null,p.a.createElement(i["a"],Object(o["a"])({listType:"picture-card",action:this.props.uploader.uploadHost,data:this.props.uploader.formData,fileList:f,onChange:this.handleChange,onRemove:function(){return s("")},onPreview:function(){return e.setState({preview:!0})},accept:"image/*",beforeUpload:this.props.uploader.init},this.widgetProps),f.length?null:d),p.a.createElement(m["a"],{onClose:function(){return e.setState({preview:!1})},url:u,visible:n}))}}]),n}(h["a"]))||a);t["a"]=v},GfHQ:function(e,t,n){"use strict";n.d(t,"a",(function(){return l}));var r=n("oBTY"),a=n("mtLc"),i=n("yKVA"),o=n("879j"),c=n("fWQN"),u=function e(){Object(c["a"])(this,e),this.params={},this.showIf=[],this.icon=null},l=function(e){Object(i["a"])(n,e);var t=Object(o["a"])(n);function n(e,a){var i;Object(c["a"])(this,n),i=t.call(this),i.submenus=[];var o,u=a?"type":"action";("add"===e?(i[u]="add",i.title="\u65b0\u5efa",i.icon="plus"):(i[u]=e.action||e.type,e.params&&(Object.assign(i.params,e.params),a||"add"!==e.params.action||(i[u]="add")),i.title=e.title,i.icon=e.icon,i.showIf=e.showIf,i.confirm=e.confirm),e.submenus)&&(o=i.submenus).push.apply(o,Object(r["a"])(e.submenus.map((function(e){return new n(e)}))));return i._action=i[u],i}return Object(a["a"])(n,[{key:"setModalForm",value:function(e,t,n){if(!n){var r=n?"type":"action";"add"===this[r]&&(!1===e?(this[r]="link",this.params.link="/content/".concat(t,"/add")):this.params.modalForm=e),this.submenus.forEach((function(n){return n.setModalForm(e,t)}))}}}]),n}(u)},HrPU:function(e,t,n){"use strict";n("6UJt");var r=n("DFOY"),a=n("oBTY"),i=n("tJVT"),o=(n("eE3J"),n("GSZB")),c=n("q1tI"),u=n.n(c),l=n("jfUH"),s=(n("Xazh"),o["a"].createFromIconfontCN()),d={string:"icon-string",text:"icon-text",richtext:"icon-richtext",integer:"icon-integer",float:"icon-decimal",decimal:"icon-decimal",bool:"icon-bool",ref:"icon-object",mref:"icon-m2m",bref:"icon-array",time:"icon-time",datetime:"icon-date",date:"icon-date",image:"icon-image",file:"icon-file",video:"icon-video",gallery:"icon-gallery",transfer:"icon-transfer",treeselect:"icon-tree",password:"icon-password",checkbox:"icon-bool",cascader:"icon-cascader",radio:"icon-radio",object:"icon-object",array:"icon-array"},f=function(e){var t=e.model,n=e.value,o=e.onChange,f=e.style,p=e.fieldFilter,m=e.fieldDisable,h=e.placeholder,b=e.allowClear,v=e.refType,_=void 0===v?l["N"]:v,g=e.disabled,y=void 0!==g&&g,O=e.layer,j=e.children,w=Object(l["ub"])(),k=function(e,t){return e?w[e].fields.filter((function(e){return!p||p(e)})).map((function(e){return{name:e.name,displayName:u.a.createElement("span",null,u.a.createElement(s,{type:d[e.type],style:{padding:3}}),e.displayName),label:e.displayName,disabled:m&&m(e),isLeaf:!(_.includes(e.type)&&(!O||t<O))||!w[e.ref]||0===w[e.ref].fields.filter((function(e){return!p||p(e)})).length,layer:t}})):[]},E=k(t,1);n&&function(){for(var e=n.split("."),r=E,a=function(n){var a=e.slice(0,n+1).join("."),i=Object(l["j"])(t,a,w);if(!i||!_.includes(i.type))return"break";var o=k(i.ref,n+2);r.find((function(t){return t.name===e[n]})).children=o,r=o},i=0;i<e.length;i+=1){var o=a(i);if("break"===o)break}}();var C=Object(c["useState"])(E),x=Object(i["a"])(C,2),S=x[0],F=x[1];Object(c["useEffect"])((function(){F(E)}),[t]);var M=function(e){var n=Object(l["j"])(t,e.map((function(e){return e.name})).join("."),w);e[e.length-1].children=k(n.ref,e[e.length-1].layer+1),F(Object(a["a"])(S))};return u.a.createElement(r["a"],{style:f,value:n&&n.split("."),onChange:function(e,t){var n=t[t.length-1];(!n||n.isLeaf||n.children)&&o(e.join("."),t)},expandTrigger:"hover",changeOnSelect:!0,displayRender:function(e,t){return t.map((function(e){return e.label})).join(".")},options:S,loadData:M,fieldNames:{label:"displayName",value:"name"},placeholder:h,allowClear:b,disabled:y,showSearch:{filter:function(e,t){return t.some((function(t){return t.label.toLowerCase().includes(e.toLowerCase())}))},sort:function(e,t,n){var r=function(e){return e.findIndex((function(e){return e.label.includes(n)}))};return r(e)-r(t)},render:function(e,t){return t.map((function(t,n){var r=Object(l["y"])(t.label,e);return 0===n?r:[" > ",r]}))},matchInputWidth:!1}},j&&u.a.createElement("div",null,j))};t["a"]=f},JN3n:function(e,t,n){"use strict";var r,a,i=n("jrin"),o=n("k1fw"),c=n("PpiC"),u=n("oBTY"),l=n("fWQN"),s=n("mtLc"),d=n("yKVA"),f=n("879j"),p=n("q1tI"),m=n.n(p),h=n("/MKj"),b=n("mmaM"),v=n("NnbD"),_=n("sMR+"),g=n("jfUH"),y=(r=Object(h["c"])((function(e){var t=e.content,n=t.schemas,r=t.adminConfig,a=e.user.currentUser;return{schemas:n,adminConfig:r,currentUser:a}})),r(a=function(e){Object(d["a"])(n,e);var t=Object(f["a"])(n);function n(){var e;Object(l["a"])(this,n);for(var r=arguments.length,a=new Array(r),i=0;i<r;i++)a[i]=arguments[i];return e=t.call.apply(t,[this].concat(a)),e.state={data:null,page:1,size:30,filters:[],orderBy:void 0,expandFields:[]},e.availableActions=function(){var t=e.props.tableConf.inlineActions;return t.filter((function(t){return!(t in v["a"])||e.permissions.includes(v["a"][t])}))},e}return Object(s["a"])(n,[{key:"componentDidUpdate",value:function(e){var t=e.refValue,n=e.refModel,r=e.refField,a=this.props,i=a.refValue,o=a.refModel,c=a.refField;t===i&&n===o&&r===c||this.setState({page:1,size:30,data:null},this.fetchData)}},{key:"permissions",get:function(){var e=this.props,t=e.currentUser.permissions,n=e.refModel;return t?t.filter((function(e){return e.endsWith(n)})).map((function(e){return e.split("_")[0]})):[]}},{key:"fetchData",value:function(){var e=this,t=this.props,n=t.refModel,r=t.refField,a=t.refValue,i=this.state,o=i.page,c=i.size,l=i.filters,s=i.orderBy,d=i.expandFields;Object(b["queryContent"])({model:n,page:o,size:c,orderBy:s,expandFields:d,filters:[{field:r,operator:"=",value:a}].concat(Object(u["a"])(l))}).then((function(t){e.setState({data:t})}))}},{key:"render",value:function(){var e=this,t=this.props,n=t.refModel,r=t.refField,a=t.refValue,l=t.refObject,s=t.tableConf,d=void 0===s?{}:s,f=d.display,p=d.exportable,h=d.filter,v=d.tableActions,y=d.modalDetail,O=d.maxInlineActions,j=d.actions,w=this.state.data,k=Object(_["a"])(n);return m.a.createElement(k,{fetchOnMounted:!0,showFilter:!0,actions:j,filter:h,display:f,exportable:p,data:w||[],model:n,tableActions:v.filter((function(t){var n=t.type;return"add"!==n||e.permissions.includes("add")})),showStat:!1,fetch:function(t){var r=t.page,a=t.size,i=t.filters,o=t.orderBy,c=t.expandFields,u=void 0===c?[]:c,l=Object(b["getExpandFields"])(n,"display",d);e.setState({page:r,size:a,filters:i,orderBy:o,expandFields:u.concat(l)},e.fetchData)},onExport:function(e){var t=e.filters,i=Object(c["a"])(e,["filters"]);return Object(b["downloadContent"])(Object(o["a"])({model:n,detailId:a,detailModel:Object(g["t"])(n,r).ref,filters:[].concat(Object(u["a"])(t),[{field:r,operator:"=",value:a}])},i))},modalForm:!0,modalDetail:y,inlineActions:this.availableActions(),maxInlineActions:O,loading:!w,formProps:{hiddenFields:Object(i["a"])({},r,a),hiddenvalues:Object(i["a"])({},r,a)},linkContext:{pId:a},superior:{id:a,field:r,value:l,model:Object(g["t"])(n,r).ref}})}}]),n}(p["Component"]))||a);t["a"]=y},"K/pY":function(e,t,n){"use strict";(function(e){n("lNFX");var r=n("VE2L"),a=n("tJVT"),i=n("q1tI"),o=n.n(i),c=n("/MKj"),u=n("Wwog"),l=Object(u["a"])((function(e,t,n){var r=[];return Object.keys(e).forEach((function(i){var o=i.split("__"),c=Object(a["a"])(o,2),u=c[0],l=c[1];if((void 0===t||t.includes(u))&&(void 0===n||n(i))){var s=r.find((function(e){return e.value===u}));s?s.children.push({value:l,label:"".concat(l,"(").concat(e[i].displayName,")")}):r.push({value:u,label:u,children:[{value:l,label:"".concat(l,"(").concat(e[i].displayName,")")}]})}})),r}));function s(t){var n=Object(i["useState"])([]),c=Object(a["a"])(n,2),u=c[0],s=c[1],d=t.schemas,f=t.models,p=t.filter,m=t.onChange,h=t.value,b=void 0===h?"":h,v=function(){if(!e.isEmpty(d)){var t=l(d,f,p);s(t)}};return Object(i["useEffect"])((function(){v()}),[d,f]),o.a.createElement(r["a"],{options:u,placeholder:"\u8bf7\u9009\u62e9",displayRender:function(e){return e.join(".")},onChange:function(e){return m(e.join("__"))},value:b?b.split("__"):[],allowClear:!0})}t["a"]=Object(c["c"])((function(e){var t=e.content.schemas;return{schemas:t}}))(s)}).call(this,n("LvDl"))},L5Lq:function(e,t,n){e.exports=n.p+"static/logo-enterprise.44e6a2eb.png"},LVWL:function(e,t,n){"use strict";var r=n("Utjr");t["a"]=Object(r["d"])((function(){return Promise.all([n.e(37),n.e(38)]).then(n.bind(null,"7IKC"))}))},LyJH:function(e,t,n){"use strict";n.d(t,"b",(function(){return l}));n("c94q");var r=n("Y/eX"),a=n("q1tI"),i=n.n(a),o=n("xJcd"),c=n("VW+w"),u=n("jfUH"),l=function(e){var t=e.field.ref,n=Object(u["S"])(t),r=n.formFields,a=void 0===r?[]:r,i=Object(u["rb"])(t),o=i.fields,l=e.fields,s=void 0===l?a:l;return Object(c["formFieldsPreprocess"])(s,o)};t["a"]=function(e){var t=e.field,n=e.value,a=e.onChange,c=l(e),u={};return c.forEach((function(e){u[e.name]=null===n||void 0===n?void 0:n[e.name]})),i.a.createElement(r["a"],{defaultActiveKey:n?[t.name]:[],key:n?0:1},i.a.createElement(r["a"].Panel,{key:t.name,header:t.displayName||t.name},i.a.createElement(o["a"],{model:t.ref,object:u,onChange:a,fields:c})))}},NnbD:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return G}));n("+BJd");var r=n("mr32"),a=(n("e+1C"),n("Nd5c")),i=(n("ER8q"),n("Ai5L")),o=(n("yavW"),n("WuMn")),c=n("0Owb"),u=n("PpiC"),l=(n("GPKB"),n("mFAc")),s=(n("52nx"),n("7bDm")),d=n("k1fw"),f=n("oBTY"),p=(n("Dvpn"),n("myml")),m=n("9og8"),h=n("fWQN"),b=n("mtLc"),v=n("tS8v"),_=n("yKVA"),g=n("879j"),y=(n("eNCU"),n("pjJH")),O=n("jrin"),j=(n("eE3J"),n("GSZB")),w=n("tJVT"),k=n("WmNS"),E=n.n(k),C=n("q1tI"),x=n.n(C),S=n("BAaj"),F=n("OFLC"),M=n("9Ndd"),P=n("dTNC"),A=n("jfUH"),D=n("VW+w"),T=n("mmaM"),L=n("vbsh"),I=n("rQ+i"),U=n("y/44"),V=n("EBSl"),R=n("flKx"),W=n("BE/h"),q=n("3i6F"),B=n("G3ML"),K=n("CzB9"),N=n("rAFZ"),H=n("91mv"),z=n("EnK/"),J=n.n(z),Y=n("mJsi"),G={edit:"change",delete:"delete",detail:"view"},Q=function(e){var t=e.Widgets,n=e.renderField,r=e.instances,a=e.realField,i=e.model,o=e.dispatch,c=e.schema,u=e.displayField,l=Object(C["useState"])(!1),s=Object(w["a"])(l,2),d=s[0],f=s[1],p=Object(C["useState"])(""),m=Object(w["a"])(p,2),h=m[0],b=m[1];return u&&u.inplaceEdit&&!0===u.inplaceEdit?x.a.createElement("span",{className:J.a.renderField},d?x.a.createElement(t,{field:a,instance:r,value:h,onChange:function(e){b(e)}}):n(),x.a.createElement("span",{className:J.a.renderIcon},d?null:x.a.createElement(j["a"],{type:"edit",onClick:function(){f(!d),b(r[a.name])}}),d?x.a.createElement("div",{style:{display:"flex"}},x.a.createElement(y["a"],{size:"small",type:"primary",onClick:function(){var e=Object(O["a"])({},a.name,h),t=c[i],n=Object(A["K"])(r,i);o({type:"content/patch",payload:{model:i,id:n,newValues:e,schema:t}}).then((function(){f(!d)}))}},"\u4fee\u6539"),x.a.createElement(y["a"],{size:"small",type:"default",style:{marginLeft:10},onClick:function(){f(!d)}},"\u53d6\u6d88")):null)):n()},Z=function(e){var t=e.children;return x.a.createElement("td",{style:{paddingTop:0,paddingBottom:0,overflow:"hidden"}},t)},X=function(t){Object(_["a"])(r,t);var n=Object(g["a"])(r);function r(){var e;Object(h["a"])(this,r);for(var t=arguments.length,a=new Array(t),i=0;i<t;i++)a[i]=arguments[i];return e=n.call.apply(n,[this].concat(a)),e.state={selectedRows:[],showModal:!1,showDrawer:!1,currentObject:{},currentActionObject:{},selectedAction:void 0,currentActionParams:{},previewImageUrl:void 0,previewImageVisible:!1,plainFormVisible:!1,plainFormFields:[],plainFormSubmit:void 0,plainFormCancel:void 0},e.setPreviewImageVisible=function(t){e.setState({previewImageVisible:t})},e.fetch=function(){var t=e.props.refresh;t()},e.handleStandardTableChange=function(t,n,r){var a=t.current,i=t.pageSize,o=e.getOrderBy(r),c=e.props,u=c.onPaginationChange,l=c.onOrderChange;u(a,i),l(o)},e.getOrderBy=function(e){var t=e.order,n=e.field;switch(t){case"ascend":return[n];case"descend":return["-".concat(n)];default:return[]}},e.handleSelectRows=function(t){e.setState({selectedRows:t})},e.handleOk=function(){e.setState({showModal:!1})},e.hideModal=function(){e.setState({showModal:!1})},e.hideDrawer=function(){e.setState({showDrawer:!1})},e.changePreviewImageUrl=function(t){e.setState({previewImageUrl:t})},e.moveRow=function(t,n){var r=e.props.model;Object(T["sortUpdate"])(r,t[e.pk],n[e.pk]).then((function(){Object(L["d"])(r,L["b"].afterUpdate),e.fetch()}))},e.inplaceEdit=function(e,t,n,r,a,i,o){var c=M["b"][M["e"][n.type]]||M["b"][M["e"][n.widget]];return x.a.createElement(Q,{Widgets:c,renderField:t,instances:e,realField:n,model:r,dispatch:a,schema:i,displayField:o})},e.checkFieldPermission=function(t){var n=e.props.model,r=Object(A["p"])(n);return t.filter((function(e){var t,n;return null===(t=null===(n=r[e.name||e])||void 0===n?void 0:n.read)||void 0===t||t}))},e.handleInlineAction=function(){var t=Object(m["a"])(E.a.mark((function t(n,r,a){var i;return E.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,a(n,r,{refresh:function(){return e.fetch()},showModal:e.showModal.bind(Object(v["a"])(e)),showDrawer:e.showDrawer.bind(Object(v["a"])(e)),link:e.link.bind(Object(v["a"])(e)),collectInputs:e.collectInputs.bind(Object(v["a"])(e)),hideCollectInput:e.hideCollectInput.bind(Object(v["a"])(e))});case 2:return i=t.sent,"delete"!==n.type&&"delete"!==n.action||e.fetch(),t.abrupt("return",i);case 5:case"end":return t.stop()}}),t)})));return function(e,n,r){return t.apply(this,arguments)}}(),e}return Object(b["a"])(r,[{key:"componentDidMount",value:function(){var e=this.props.onDidMount;e&&e(this)}},{key:"getExpandRender",value:function(e,t,n){var r=this,a=Object(A["j"])(t,e.name,n),i=a.ref;return function(t){var a=t[e.name],o=r.buildColumns(i,e.display,n,!1,{getDisplayWidgetName:function(e){return Object(q["g"])(n)(e,i)}});return x.a.createElement(p["a"],{columns:o,dataSource:a,pagination:!1,bordered:!1,rowKey:Object(A["L"])(i),scroll:{x:"max-content"}})}}},{key:"isDisplayInTree",get:function(){var e=this.props.displayInTree;return!0===e}},{key:"displayInSort",get:function(){var e=this.props.displayInSort;return!0===e}},{key:"pk",get:function(){var e=this.props.model;return Object(A["L"])(e)}},{key:"permissions",get:function(){var e=this.props,t=e.currentUser.permissions,n=void 0===t?[]:t,r=e.model;return n.filter((function(e){return e.endsWith(r)})).map((function(e){return e.split("_")[0]}))}},{key:"getInlineActions",value:function(){var e=this.props.validInlineActions;return e}},{key:"getActions",value:function(){var e=this,t=this.props,n=t.model,r=t.actions,a=t.currentUser,i=r.filter((function(t){var n=t.action;return"delete"!==n||e.permissions.includes("delete")})),o={actions:i,currentUser:a,model:n};return Object(I["a"])(o)}},{key:"getTableActions",value:function(){var t=this,n=this.props,r=n.tableActions,a=n.superior;a=void 0===a?{}:a;var i=a.value,o=a.model,c=n.content.schemas;return r.filter((function(e){var n=e.action,r=e._action;return!["add","excelImport"].includes(n)&&!["add","excelImport"].includes(r)||t.permissions.includes("add")})).filter((function(t){if(e.isEmpty(t.showIf)||e.isEmpty(i))return!0;var n=Object(A["G"])(t.showIf,i,c,o);return n}))}},{key:"link",value:function(e,t,n){var r=this.props.linkContext;return Object(A["O"])(n.link,(function(t){var n;return null!==(n=r[t])&&void 0!==n?n:null===e||void 0===e?void 0:e[t]}))}},{key:"showModal",value:function(e,t,n){this.setState({currentObject:e,currentActionObject:t,currentActionParams:n,showModal:!0})}},{key:"collectInputs",value:function(e,t,n){this.setState({plainFormVisible:!0,plainFormFields:e,plainFormSubmit:t,plainFormCancel:n})}},{key:"hideCollectInput",value:function(){this.setState({plainFormVisible:!1,plainFormFields:[],plainFormSubmit:void 0,plainFormCancel:void 0})}},{key:"showDrawer",value:function(e,t,n){this.setState({currentObject:e,currentActionObject:t,currentActionParams:n,showDrawer:!0})}},{key:"buildRowColumns",value:function(t,n,r,a,i,o,c,u){var l=this,s=r.groupField,p=r.groupTitle,m=r.field,h=r.title,b=r.value,v=r.columns,_=p;if(!v||"onDeman"===v){if(u&&u.length>0){var g,y=u.map((function(e){return e[t].map((function(e){var t=Object(A["x"])(m,e),n=Object(A["x"])(h,e),r=Object(A["x"])(b,e),a=_;return!_&&s&&(a=Object(A["x"])(s,e)),{group:a,field:t,title:n,value:r}}))})),j={};y=y.reduce((function(e,t){return j[t.name]||(j[t.name]=!0,e.push(t)),e}),[]);var w={};y[0].forEach((function(e){w[e.group]||(w[e.group]=[]),w[e.group]=w[e.group].concat(e)}));var k=a[n],E="".concat(n,"__asColumn"),C=[].concat(Object(f["a"])(k.fields),[{name:"".concat(t,"__asColumn"),type:"ref",ref:E}]),x=Object(d["a"])(Object(d["a"])({},k),{},{fields:C}),S=Object(d["a"])(Object(d["a"])({},a),{},(g={},Object(O["a"])(g,n,x),Object(O["a"])(g,E,{name:E,fields:y[0].map((function(e){return{name:e.field,type:"string"}}))}),g)),F=Object(q["g"])(S);return e.keys(w).flatMap((function(e){var r=w[e];return void 0!==e&&"undefined"!==e?[{title:e,children:r.flatMap((function(e){return l.buildSingleColumn({dataIndex:"".concat(t,"__asColumn.").concat(e.field),alias:e.title,name:"".concat(t,"__asColumn.").concat(e.field)},n,S,i,F,c,u)}))}]:r.flatMap((function(e){return l.buildSingleColumn({dataIndex:"".concat(t,"__asColumn.").concat(e.field),alias:e.title,name:"".concat(t,"__asColumn.").concat(e.field)},n,S,i,F,c,u)}))}))}return[]}return[]}},{key:"buildSingleColumn",value:function(e,t,n,r,a,i,o){var c=e.widget,u=e.fields,l=e.alias,s=e.fixed,f=e.width,p=e.name,m=void 0===p?null===u||void 0===u?void 0:u.value:p,h=e.params,b=void 0===h?{}:h,v=e.dataIndex,_=e.type,g=m?Object(A["j"])(t,m,n):null,y=c;if("asColumn"===_)return this.buildRowColumns(m,t,b,n,r,a,i,o);var O={fixed:s,width:f,dataIndex:v||m,sortDirections:["descend","ascend"],title:x.a.createElement("div",{style:{whiteSpace:"nowrap"}},l||(null===g||void 0===g?void 0:g.displayName)),sorter:r.includes(m)};!y&&g&&(y=a(e,t));var j=Object(d["a"])(Object(d["a"])({},b),{},{displayField:e,field:g,model:null!==m&&void 0!==m&&m.includes(".")?Object(A["j"])(t,m.split(".").slice(0,-1).join("."),n).ref:t,Schemas:n,changePreviewImageUrl:this.changePreviewImageUrl,setPreviewImageVisible:this.setPreviewImageVisible,component:this});return O.render=function(r,a,o){var c={fields:u||{value:m},model:t,widgetName:y,record:a,widgetProps:j,providedSchemas:n};return i(c,e,o)},[O]}},{key:"buildColumns",value:function(e,t,n,r,a,i){var o=this,c=a.sortable,u=a.getDisplayWidgetName,l=this.props.renderColumn,s=void 0===l?function(e){return x.a.createElement(q["a"],e)}:l,d=[];this.checkFieldPermission(Object(D["displayPreprocess"])(t,e,n)).forEach((function(t){d=d.concat(o.buildSingleColumn(t,e,n,c,u,s,i))}));var f=this.getInlineActions();if(f&&f.length>0){var p=this.props,m=p.modalForm,h=p.modalDetail,b=p.maxInlineActions;d.push({title:x.a.createElement("div",{style:{whiteSpace:"nowrap"}},"\u64cd\u4f5c"),fixed:"right",width:1,render:function(t,n){return x.a.createElement(B["a"],{record:n,modalForm:m,modalDetail:h,maxItem:b,model:e,onClick:o.handleInlineAction,items:f},"\u6682\u65e0")}})}return d}},{key:"batchAction",value:function(){var e=this,t=this.props.model,n=this.state,r=n.selectedRows,a=n.selectedAction;Object(V["l"])(a,{record:r,model:t},{refresh:function(){e.setState({selectedRows:[]}),e.fetch()},showModal:this.showModal.bind(this),collectInputs:this.collectInputs.bind(this),hideCollectInput:this.hideCollectInput.bind(this)})}},{key:"renderContent",value:function(){var t=this,n=this.props,r=n.data,a=void 0===r?{list:[]}:r,i=n.loading,o=n.listStyle,f=n.model,p=n.dispatch,m=n.editable,h=n.sortable,b=n.display,v=n.showStat,_=n.content,g=_.schemas,y=_.stat,j=_.adminConfig,w=n.sortKey,k=n.tableProps,E=n.shouldSelect,F=n.currentUser,M=n.getDisplayWidgetName,P=n.onPaginationChange;if(!Object.keys(g).length)return x.a.createElement(C["Fragment"],null);var D=this.state.selectedRows,T=g[f]?g[f]:{},L=T.titleField,U=this.getActions(),R={fields:b,currentUser:F,model:f},W=Object(I["b"])(R);switch(o){case"gallery":return x.a.createElement(H["a"],{loading:i,data:a,field:{id:Object(A["L"])(f),title:L,url:"url"},onImageClick:function(e){return t.setState({previewImageUrl:e.url,previewImageVisible:!0})},onPaginationChange:P,actions:[{label:"\u7f16\u8f91",icon:"edit",name:"edit",onClick:function(e){return t.showModal(e,Object(V["m"])(V["c"],"edit"))}},{label:"\u5220\u9664",icon:"delete",name:"delete",onClick:function(e){s["a"].confirm({title:"\u786e\u5b9a\u5220\u9664\uff1f",onOk:function(){var t=this;p({type:"content/delete",payload:{id:Object(A["K"])(e,f),model:f}}).then((function(){t.fetch(),l["a"].success("\u5220\u9664\u6210\u529f")}))}})}}]});default:var q={},B=W.find((function(t){return e.isObject(t)&&"embed"===t.type})),K=W.find((function(t){return e.isObject(t)&&"asColumn"===t.type}));B&&(q={expandedRowKeys:a.list.map((function(e){return Object(A["K"])(e,f)})),expandedRowRender:this.getExpandRender(B,f,g),expandIconAsCell:!1,expandIconColumnIndex:-1});var N=this.buildColumns(f,W,g,m,{sortable:h,getDisplayWidgetName:M},null===a||void 0===a?void 0:a.list);if(this.isDisplayInTree){var z=e.keyBy(a.list,Object(A["L"])(f)),J=e.sortBy(e.values(z),[w,Object(A["L"])(f)]);J.forEach((function(e){if(e.parent){var t=z[e.parent];t.children||(t.children=[]),t.children.push(e)}})),a.list=J.filter((function(e){return!e.parent}))}if(K){var G=K.name,Q=K.params,X=Q.field,$=Q.value;a.list=a.list.map((function(e){var t={};return e[G].forEach((function(e){t[Object(A["x"])(X,e)]=Object(A["x"])($,e)})),Object(d["a"])(Object(d["a"])({},e),{},Object(O["a"])({},"".concat(G,"__asColumn"),t))}))}var ee=function(n){var r=U.length>0||E;return x.a.createElement(S["a"],Object(c["a"])({sticky:!0,tableLayout:"auto",selectedRows:D,loading:i,data:a,columns:N,onSelectRow:t.handleSelectRows,onChange:t.handleStandardTableChange,rowKey:Object(A["L"])(f),shouldSelect:r,expandOptions:Object(d["a"])(Object(d["a"])({},q),{},{scroll:{x:"max-content"},footer:v?y[f]&&function(){return e.map(j[f].statistics,(function(e,t){var n=e.verbose_name;return"".concat(n,"\uff1a").concat(y[f][t])})).join("\uff0c ")}:e.noop})},n,{components:e.merge(null===n||void 0===n?void 0:n.components,{body:{wrapper:function(e){var t=e.children,n=Object(u["a"])(e,["children"]);return x.a.createElement("tbody",n,x.a.createElement("tr",null,r&&x.a.createElement(Z,null),N.map((function(e){return x.a.createElement(Z,null,x.a.createElement("div",{style:{height:0}},e.title))}))),t)}}})},k))};return this.displayInSort?x.a.createElement(Y["a"],{table:ee,onRow:function(e){return{moveRow:t.moveRow,sortKey:w,data:a,item:Object(d["a"])({},e)}}}):ee()}}},{key:"render",value:function(){var t=this,n=this.state,r=n.selectedRows,c=n.showModal,u=n.selectedAction,l=this.state,d=l.currentActionObject,f=l.currentActionParams,p=l.currentObject,m=l.showDrawer,h=this.state,b=h.previewImageUrl,v=h.previewImageVisible,_=this.state,g=_.plainFormVisible,O=_.plainFormFields,j=_.plainFormCancel,w=_.plainFormSubmit,k=this.props,E=k.model,S=k.formProps,M=k.superior,A=this.getTableActions(),D=o["a"].Option,T=x.a.createElement(P["a"],{model:E,tableActions:A,context:{showModal:this.showModal.bind(this),showDrawer:this.showDrawer.bind(this),collectInputs:this.collectInputs.bind(this),hideCollectInput:this.hideCollectInput.bind(this),refresh:function(){t.fetch()},link:this.link.bind(this),exportData:this.props.onExport,superior:M}}),L=this.getActions(),I=L.length>0?x.a.createElement(C["Fragment"],null,x.a.createElement(o["a"],{placeholder:"\u8bf7\u9009\u62e9\u6279\u91cf\u64cd\u4f5c",style:{width:200},onChange:function(e){t.setState({selectedAction:Object(V["o"])(V["b"],{config:L.find((function(t){return t.action===e}))})})},allowClear:!0},L.map((function(t,n){return e.isArray(t)?x.a.createElement(D,{key:t[0],value:t[0]},t[1]):x.a.createElement(D,{key:"".concat(t.action+n),value:t.action},t.name)}))),x.a.createElement(y["a"],{style:{marginLeft:10},type:"primary",disabled:void 0===u||0===r.length,onClick:function(){return t.batchAction()}},"\u6279\u91cf\u6267\u884c")):"";return[((null===A||void 0===A?void 0:A.length)||L.length)&&x.a.createElement(a["a"],{style:{marginBottom:10,marginTop:10}},x.a.createElement(i["a"],{span:24},T,I))||null,this.renderContent(),x.a.createElement(W["a"],{visible:c,handleOk:this.hideModal,handleCancel:this.hideModal,currentActionObject:d,currentObject:p,currentActionParams:f,model:E,context:{refresh:function(){t.fetch(),t.hideModal()},hideModal:this.hideModal,close:this.hideModal,formProps:"function"===typeof S?S(this):S,superior:M}}),x.a.createElement(F["a"],{url:b,visible:v,onClose:function(){return t.setState({previewImageVisible:!1})}}),x.a.createElement(R["a"],{currentActionObject:d,currentObject:p,currentActionParams:f,visible:m,model:E,context:{hideDrawer:this.hideDrawer,refresh:function(){t.fetch(),t.hideDrawer()},close:this.hideDrawer,formProps:"function"===typeof S?S(this):S}}),x.a.createElement(s["a"],{title:"\u8bf7\u8f93\u5165\u53c2\u6570",width:"60%",footer:null,visible:g,onCancel:function(){return t.setState({plainFormVisible:!1})}},x.a.createElement(U["a"],{fields:O,onSubmit:w,onCancel:j}))]}}]),r}(x.a.PureComponent);X.defaultProps={display:[],inlineActions:[],loading:!1,actions:[],showFilter:!0,sortable:[],showStat:!0,showDrawer:!1,handleStandardTableChange:null,onCreate:function(){},onUpdate:function(){},formProps:{},tableActions:[],linkContext:{}},t["b"]=function(e){var t,n=e.model,a=e.display,i=e.filter,o=e.showFilter,l=void 0===o||o,s=e.exportable,f=e.fetch,p=void 0===f?function(){}:f,m=e.onExport,h=e.fetchOnMounted,b=void 0!==h&&h,v=e.searchFields,_=void 0===v?[]:v,g=e.renderSearchBar,y=void 0===g?function(e){return e}:g,O=e.renderTable,j=void 0===O?function(e){return e}:O,k=e.tableProps,E=void 0===k?{}:k,S=Object(u["a"])(e,["model","display","filter","showFilter","exportable","fetch","onExport","fetchOnMounted","searchFields","renderSearchBar","renderTable","tableProps"]),F=Object(C["useState"])(!1),M=Object(w["a"])(F,2),P=M[0],D=M[1],L=Object(C["useState"])([]),I=Object(w["a"])(L,2),U=I[0],V=I[1],R=Object(C["useState"])(1),W=Object(w["a"])(R,2),q=W[0],B=W[1],H=Object(C["useState"])(50),z=Object(w["a"])(H,2),J=z[0],Y=z[1],G=Object(C["useState"])([]),Q=Object(w["a"])(G,2),Z=Q[0],$=Q[1],ee=Object(C["useState"])(),te=Object(w["a"])(ee,2),ne=te[0],re=te[1],ae=S.content.adminConfig,ie=S.filterLayout,oe=Object(C["useCallback"])((function(){var e,t={model:n,filters:U,page:q,size:J,orderBy:Z};ne&&(t.filters=t.filters.concat({operator:"or",children:_.map((function(e){return{field:e,operator:"icontains",value:ne}}))})),null!==(e=ae[n])&&void 0!==e&&e._enableDisplayOnTableList&&(t.displayFields=Object(T["getDisplayFields"])(n,a)),p(t)}),[q,U,Z,ne]);Object(C["useEffect"])((function(){(P||b)&&oe()}),[oe]),Object(C["useEffect"])((function(){D(!0)}),[]);var ce=Object(C["useRef"])(null);Object(C["useEffect"])((function(){if(P&&ce.current){var e=ce.current.parentElement||ce.current;e.scrollIntoView()}}),[q]);var ue=Object(A["kb"])();return x.a.createElement(x.a.Fragment,null,x.a.createElement("div",{ref:ce}),!!_.length&&y(x.a.createElement(K["a"],{model:n,searchFields:_,onSearch:function(e){re(e),B(1)}})),ne&&x.a.createElement(r["a"],{style:{marginTop:16},closable:!0,onClose:function(){return re(void 0)}},"\u201c",ne,"\u201d\u7684\u641c\u7d22\u7ed3\u679c"),x.a.createElement("div",{style:{height:24}}),l&&x.a.createElement(N["b"],{model:n,layout:ie||(null===(t=ae[n])||void 0===t?void 0:t.filterLayout),onSubmit:function(e){V(e),B(1)},filter:i,exportable:s,onExport:function(e,t){V(e),m({filters:U,exportKey:t})}}),j(x.a.createElement(X,Object(c["a"])({model:n,display:a,onPaginationChange:function(e,t){B(e),Y(t)},onOrderChange:$,refresh:oe,onExport:function(e){var t=e.exportKey;return m({exportKey:t,filters:U})},tableProps:Object(d["a"])({size:ue&&"middle"},E)},S))))}}).call(this,n("LvDl"))},OFLC:function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));n("52nx");var r=n("7bDm"),a=n("q1tI"),i=n.n(a),o=n("nKGo");function c(e){var t=e.url,n=e.onClose,a=e.visible;return i.a.createElement(r["a"],{width:"fit-content",footer:null,visible:a,onCancel:n},i.a.createElement("img",{className:o["gmImg"],onClick:n,alt:t,key:t,style:{maxWidth:"100%",cursor:"zoom-out"},src:t}))}},RLxJ:function(e,t,n){"use strict";var r=n("9kvl");n.d(t,"a",(function(){return r["b"]}))},Rzkh:function(e,t,n){"use strict";n.d(t,"a",(function(){return f}));n("UvA9");var r=n("u4G2"),a=n("0Owb"),i=n("fWQN"),o=n("mtLc"),c=n("yKVA"),u=n("879j"),l=n("q1tI"),s=n.n(l),d=n("AAgL"),f=function(e){Object(c["a"])(n,e);var t=Object(u["a"])(n);function n(){return Object(i["a"])(this,n),t.apply(this,arguments)}return Object(o["a"])(n,[{key:"render",value:function(){var e=this.props,t=e.value,n=e.onChange;return s.a.createElement(r["a"],Object(a["a"])({checked:t,onChange:n},this.widgetProps))}}]),n}(d["a"])},UCuA:function(e,t,n){"use strict";n("A1Tt");var r,a,i=n("QYOG"),o=n("0Owb"),c=n("tJVT"),u=n("fWQN"),l=n("mtLc"),s=n("yKVA"),d=n("879j"),f=n("q1tI"),p=n.n(f),m=n("/MKj"),h=n("AAgL"),b=n("jfUH"),v=(r=Object(m["c"])((function(e){var t=e.content;return{schemas:t.schemas}})),r(a=function(e){Object(s["a"])(n,e);var t=Object(d["a"])(n);function n(){var e;Object(u["a"])(this,n);for(var r=arguments.length,a=new Array(r),i=0;i<r;i++)a[i]=arguments[i];return e=t.call.apply(t,[this].concat(a)),e.state={remoteChoices:[]},e.myProps=["titlefield"],e.doSearch=function(){var t=e.props.dispatch,n=e.refSchema;t({type:"content/choices",payload:{model:n.name,titleField:e.titleField}}).then((function(t){e.setState({remoteChoices:t})}))},e}return Object(l["a"])(n,[{key:"componentDidMount",value:function(){this.doSearch()}},{key:"titleField",get:function(){return this.props.titlefield||this.refSchema.titleField}},{key:"refSchema",get:function(){var e=this.props.schemas;return e[this.refModel]}},{key:"refModel",get:function(){var e=this.props.field;return e.ref}},{key:"render",value:function(){var e=this,t=this.props,n=t.value,r=t.onChange,a=this.state.remoteChoices;return p.a.createElement(i["a"],Object(o["a"])({dataSource:a.map((function(t){var n=Object(c["a"])(t,2),r=n[0],a=n[1];return{key:r,title:a[e.titleField]}})),showSearch:!0,render:function(e){return e.title},targetKeys:n&&n.map((function(t){return Object(b["K"])(t,e.refModel)})),titles:["\u672a\u542f\u7528","\u5df2\u542f\u7528"],onChange:function(e){return r(e.map((function(e){return a.find((function(t){return t[0]===e}))[1]})))}},this.widgetProps))}}]),n}(h["a"]))||a);t["a"]=v},Utjr:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return v})),n.d(t,"d",(function(){return g})),n.d(t,"b",(function(){return y})),n.d(t,"c",(function(){return O}));var r=n("k1fw"),a=n("fWQN"),i=n("mtLc"),o=n("yKVA"),c=n("879j"),u=(n("EQ8j"),n("1JPr")),l=n("tJVT"),s=n("q1tI"),d=n.n(s),f=n("506c"),p=n("95SA"),m=[[404,"\u54ce\u5440\uff0c\u7cdf\u7cd5\uff0c\u600e\u4e48\u4f1a\u8fd9\u6837\uff1f\ud83d\ude30"],[500,"\u5929\u5450\uff0c\u6211\u5230\u5e95\u505a\u9519\u4e86\u4e9b\u4ec0\u4e48\uff1f"]],h=function(t){var n=t.title,r=void 0===n?"\u51fa\u9519\u5566\uff01":n,a=t.subTitle,i=Object(s["useState"])(e.sample(m)),o=Object(l["a"])(i,1),c=Object(l["a"])(o[0],2),f=c[0],p=c[1];return d.a.createElement(u["a"],{status:f,subTitle:a||p,title:r})},b=function(e){Object(o["a"])(n,e);var t=Object(c["a"])(n);function n(){var e;Object(a["a"])(this,n);for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return e=t.call.apply(t,[this].concat(i)),e.state={hasError:!1},e}return Object(i["a"])(n,[{key:"render",value:function(){var e=this.state.hasError,t=this.props,n=t.children,r=t.fallback;return e?r:n}}],[{key:"getDerivedStateFromError",value:function(){return{hasError:!0}}}]),n}(d.a.Component),v=function(t){var n=t.keyMaps,r=void 0===n?{}:n,a=t.children,i=d.a.useRef(null);return e.forEach(r,(function(e,t){Object(f["a"])(i,t.split("+"),e)})),d.a.createElement("div",{ref:i},a)},_=d.a.createElement(u["a"],{status:"warning",title:"\u7f51\u7edc\u52a0\u8f7d\u5931\u8d25"}),g=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.loading,r=t.fallback,a=void 0===r?_:r,i=d.a.lazy(e);return function(e){var t=d.a.createElement(i,e);return d.a.createElement(b,{fallback:a},d.a.createElement(s["Suspense"],{fallback:d.a.createElement(p["a"],{tip:n})},d.a.createElement(b,{fallback:d.a.createElement(h,null)},t)))}},y=function(){function t(n){Object(a["a"])(this,t),this.props=void 0,this.props=Object(r["a"])(Object(r["a"])({},this.constructor.defaultProps),e.omitBy(n,(function(e){return void 0===e})))}return Object(i["a"])(t,null,[{key:"component",get:function(){var e=this;return function(t){return new e(t).render()}}}]),t}(),O=d.a.createContext({})}).call(this,n("LvDl"))},Utzx:function(e,t,n){"use strict";(function(e){n.d(t,"b",(function(){return U}));var r=n("k1fw"),a=n("rAM+"),i=n("oBTY"),o=n("eWa3"),c=n.n(o),u=n("hHZz"),l=n.n(u),s=n("bZbt"),d=n.n(s),f=n("DO/+"),p=n.n(f),m=n("bM/q"),h=n.n(m),b={email:function(e){return e&&c()(e)},ip:function(e){return e&&l()(e)},mobile:function(e){return e&&d()(e,"zh-CN")},regex:function(e,t){var n=t.regex;return e&&p()(e,new RegExp(n.replace("\\Z","$")))},slug:function(e){return e&&p()(e,new RegExp("^[-a-zA-Z0-9_]+$"))},unicode_slug:function(e){return e&&p()(e,new RegExp("^[-\\w]+$"))},url:function(e){return e&&h()(e)},max_value:function(e,t){var n=t.value;return e&&e<=n},min_value:function(e,t){var n=t.value;return e&&e>=n}},v={email:"\u8bf7\u586b\u5199\u6b63\u786e\u7684\u90ae\u7bb1\u683c\u5f0f",ip:"\u8bf7\u586b\u5199\u6b63\u786e\u7684IP\u5730\u5740\u683c\u5f0f",mobile:"\u8bf7\u586b\u5199\u6b63\u586b\u7684\u624b\u673a\u53f7\u7801\u683c\u5f0f",regex:function(e){var t=e.regex;return"\u4e0d\u5339\u914d\u6b63\u5219\u8868\u8fbe\u5f0f".concat(t)},slug:"\u5185\u5bb9\u53ea\u5141\u8bb8\u5b57\u6bcd\u3001\u6570\u5b57\u3001\u8fde\u63a5\u7ebf\u53ca\u4e0b\u5212\u7ebf",unicode_slug:"\u5185\u5bb9\u53ea\u5141\u8bb8Unicode\u5b57\u7b26\u3001\u6570\u5b57\u3001\u8fde\u63a5\u7ebf\u53ca\u4e0b\u5212\u7ebf",url:"\u8bf7\u586b\u5199\u6b63\u786e\u7684URL\u5730\u5740\u683c\u5f0f",max_value:function(e){var t=e.value;return"\u4e0d\u80fd\u5927\u4e8e".concat(t)},min_value:function(e){var t=e.value;return"\u4e0d\u80fd\u5c0f\u4e8e".concat(t)}};function _(e){var t=[];return"maxLength"in e&&null!==e.maxLength&&t.push({max:e.maxLength,message:"\u6700\u5927\u957f\u5ea6\u4e0d\u80fd\u8d85\u8fc7 ".concat(e.maxLength)}),"minLength"in e&&null!==e.minLength&&t.push({min:e.minLength,message:"\u6700\u5c0f\u957f\u5ea6\u4e0d\u80fd\u5c0f\u4e8e ".concat(e.maxLength)}),t}function g(e){return[]}function y(e){var t=[];return t.push({type:"integer",message:"\u6570\u5b57"}),t}function O(e){var t=[];return t.push({type:"number",message:"\u6d6e\u70b9\u578b\u6570\u5b57"}),t}function j(e){var t=[];return t.push({type:"boolean",message:"\u65e0\u9009\u62e9\u503c"}),t}function w(e){return[]}function k(e){return[]}function E(e,t){return[{validator:function(e,n,r){var a=t.instance;if(a&&a.validate){var i=a.validate();i?r(i):r()}else r()},message:"\u8bf7\u4fee\u6b63".concat(e.displayName,"\u4e2d\u7684\u9519\u8bef")}]}function C(e){return[]}function x(e){return[]}function S(e){var t=[];return t.push({type:"date",message:"\u5408\u6cd5\u7684\u65e5\u671f"}),[]}function F(e){return[]}function M(e){return[]}var P={string:_,text:g,integer:y,float:O,bool:j,ref:w,mref:k,bref:E,time:C,datetime:x,date:S,image:F,file:M};function A(t,n,o){var c=[];if("required"in t&&t.required&&c.push({required:!0,message:"\u8bf7\u8f93\u5165".concat(t.displayName)}),t.type in P){var u=P[t.type](t,n);u&&c.push.apply(c,Object(i["a"])(u))}var l=t.validators;if(l){var s,d=Object(a["a"])(l);try{var f=function(){var t=s.value,n=t;e.isObject(t)&&e.isString(e.get(t,"type",void 0))&&(n=t.type);var a=v[n]||"\u8f93\u5165\u6709\u8bef";e.isFunction(a)&&e.isObject(t)&&(a=a(Object(r["a"])({},t)));var i={};e.isObject(t)&&(i=t),c.push({validator:function(e,t,a){n in b&&t&&!b[n](t,Object(r["a"])({},i))?a(!1):a()},message:a})};for(d.s();!(s=d.n()).done;)f()}catch(p){d.e(p)}finally{d.f()}}return o&&e.isArray(o)&&!e.isEmpty(o)?c.concat(o):c}var D={"=":function(e,t){return e===t},"==":function(e,t){return e===t},"===":function(e,t){return e===t},"!=":function(e,t){return e!==t},"!==":function(e,t){return e!==t},">":function(e,t){return e>t},"<":function(e,t){return e<t},in:function(t,n){return e.isArray(n)&&-1!==n.indexOf(t)},include:function(t,n){return e.isArray(t)&&-1!==t.indexOf(n)}};function T(e,t,n){var r=n.condition_field,a=n.operator,i=n.value;if(r&&a&&void 0!==i&&r&&void 0!==e[r]){var o=e[r],c=D[a];if(c&&c(o,i))return{required:!0,message:"\u672c\u5b57\u6bb5\u662f\u5fc5\u586b\u7684"}}}function L(e){function t(t,n,r){var a=r.condition_field,i=t[a];if(i)return"lt"===e?{validator:function(e,t,n){b.max_value(t,{value:i})?n():n(!1)},message:v.max_value({value:i})}:"gt"===e?{validator:function(e,t,n){b.min_value(t,{value:i})?n():n(!1)},message:v.min_value({value:i})}:void 0}return t}var I={condition_required:T,condition_less:L("lt"),condition_great:L("gt")};function U(t,n,r){var a=[];return e.isEmpty(r)||r.forEach((function(r){if(e.isArray(r.field)&&-1!==r.field.indexOf(n.name)||e.isString(r.field)&&r.field===n.name){var i=I[r.type];if(i){var o=i(t,n,r);o&&a.push(o)}}})),a}t["a"]=A}).call(this,n("LvDl"))},"VW+w":function(e,t,n){"use strict";n.r(t),function(e){n.d(t,"formFieldsPreprocess",(function(){return s})),n.d(t,"displayPreprocess",(function(){return d})),n.d(t,"inlineActionsPreprocess",(function(){return f})),n.d(t,"configPreprocess",(function(){return h}));var r=n("tJVT"),a=n("k1fw"),i=n("556t"),o=n("9Ndd"),c=n("jfUH"),u=n("GfHQ"),l=n("uCub");function s(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=r.noDefault,u=void 0!==i&&i,l=[];return t?(t.forEach((function(t){var r=t;e.isString(r)&&(r={name:r}),r.params||(r.params={}),e.isObject(r.widget)&&(r.params=Object(a["a"])(Object(a["a"])({},r.params),r.widget.attrs),r.widget=r.widget.type);var i=n.find((function(e){return e.name===r.name}));i?(u||r.widget||(i.choices?r.widget="Select":r.widget=o["e"][i.type]),Object(c["D"])(i)?("boolean"===typeof r.nestedForm&&(r.nestedForm?r.nestedForm=["add","edit"]:r.nestedForm=[]),void 0===r.nestedForm&&(r.nestedForm=["add","edit"])):void 0!==r.nestedForm&&delete r.nestedForm,l.push(r)):console.error("formFields\u4e2d\u627e\u4e0d\u5230".concat(r.name))})),l):l}function d(t,n,r){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=a.noDefault,o=void 0!==i&&i,u=[];return(t&&t.length?t:[Object(c["L"])(n,{content:{schemas:r}})]).forEach((function(t){var a=t;if(e.isString(a))a={name:a};else if(e.isObject(t)&&t.widget&&t.fields)return void u.push(t);try{var i=Object(c["l"])(r,a.name,n);o||a.alias||(a.alias=i.map((function(e){return e.displayName})).join(""))}catch(l){return void console.error(l)}u.push(a)})),u}function f(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=n.noDefault,a=[];return t?(t.forEach((function(t){var n=t;e.isString(n)&&(n={action:n}),n.action||(n.action=n.type),r||n.title||(n.title=i["a"][n.action]||n.action),n.params||(n.params={}),i["b"].includes(n.action)&&n.field&&(n.params.field=n.field),n.userField&&(n.params.userField=n.userField),a.push(n)})),a):a}function p(e,t,n,r){var a=r.noDefault,i=[];return(e||["add"]).forEach((function(e){var r=new u["a"](e,a);r.setModalForm(t,n,a),r.groups=e.groups,r.id=e.id,i.push(r)})),i}function m(e,t){var n,r=e;return e||(r=[]),[r.filter((function(e){return"tab"!==e.widget&&t.fields.find((function(t){return t.name===((null===e||void 0===e?void 0:e.name)||e)}))})),null===(n=r.find((function(e){return"tab"===e.widget})))||void 0===n?void 0:n.name]}function h(t,n,i){e.forEach(n,(function(t){t.fieldMap=e.keyBy(t.fields,"name"),e.forEach(t.fieldMap,(function(e){e.ref&&e.ref in n&&(e.refLink=n[e.ref])}))}));var o=Object(a["a"])({noDefault:!1},i);Object.keys(n).forEach((function(e){n[e].fields=n[e].fields.filter((function(e){return!e.ref||e.ref in n})),t[e]||(t[e]={});var a=t[e];a.formFields=s(a.formFields,n[e].fields,o),a.display=d(a.display,e,n,o);var i=m(a.filter,n[e]),c=Object(r["a"])(i,2);a.filter=c[0],a.tabField=c[1],void 0===a.modalForm&&(a.modalForm=!0),a.inlineActions=f(a.inlineActions,o),a.tableActions=p(a.tableActions,a.modalForm,e,o),a.details=Object(l["a"])(t,n,e)}))}}.call(this,n("LvDl"))},Vtfu:function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var r=n("fWQN"),a=n("yKVA"),i=n("879j"),o=n("lt+M"),c=function(e){Object(a["a"])(n,e);var t=Object(i["a"])(n);function n(){return Object(r["a"])(this,n),t.apply(this,arguments)}return n}(o["a"])},WRAw:function(e,t,n){"use strict";n("nTdE");var r,a,i=n("IZHl"),o=n("0Owb"),c=(n("eNCU"),n("pjJH")),u=(n("eE3J"),n("GSZB")),l=n("fWQN"),s=n("mtLc"),d=n("yKVA"),f=n("879j"),p=n("q1tI"),m=n.n(p),h=n("AAgL"),b=n("jfUH"),v=(r=Object(b["d"])((function(){return{uploader:Object(b["zb"])()}})),r(a=function(e){Object(d["a"])(n,e);var t=Object(f["a"])(n);function n(){var e;Object(l["a"])(this,n);for(var r=arguments.length,a=new Array(r),i=0;i<r;i++)a[i]=arguments[i];return e=t.call.apply(t,[this].concat(a)),e.state={preview:!1,uploadingList:[]},e.handleChange=function(t){var n=t.file,r=t.fileList,a=e.props.onChange;if(e.setState({uploadingList:r.filter((function(e){return"uploading"===e.status}))}),"done"===n.status){var i=e.props.uploader.getUrl(n);a(i)}},e}return Object(s["a"])(n,[{key:"render",value:function(){var e=this.state.uploadingList,t=this.props,n=t.onChange,r=t.value,a=m.a.createElement(c["a"],null,m.a.createElement(u["a"],{type:"upload"})," \u70b9\u6b64\u4e0a\u4f20"),l=e;return r&&(l=l.concat({url:r,name:r,uid:r})),m.a.createElement("div",null,m.a.createElement(i["a"],Object(o["a"])({action:this.props.uploader.uploadHost,data:this.props.uploader.formData,onChange:this.handleChange,beforeUpload:this.props.uploader.init,onRemove:function(){return n()},fileList:l,accept:"video/*,audio/*,.mp4,.Ogg,.WebM"},this.widgetProps),l.length?null:a))}}]),n}(h["a"]))||a);t["a"]=v},WTkp:function(e,t,n){"use strict";n("0yxu");var r=n("/r5h"),a=n("io9h"),i=n("Iab2"),o={200:"\u670d\u52a1\u5668\u6210\u529f\u8fd4\u56de\u8bf7\u6c42\u7684\u6570\u636e\u3002",201:"\u65b0\u5efa\u6216\u4fee\u6539\u6570\u636e\u6210\u529f\u3002",202:"\u4e00\u4e2a\u8bf7\u6c42\u5df2\u7ecf\u8fdb\u5165\u540e\u53f0\u6392\u961f\uff08\u5f02\u6b65\u4efb\u52a1\uff09\u3002",204:"\u5220\u9664\u6570\u636e\u6210\u529f\u3002",400:"\u53d1\u51fa\u7684\u8bf7\u6c42\u6709\u9519\u8bef\uff0c\u670d\u52a1\u5668\u6ca1\u6709\u8fdb\u884c\u65b0\u5efa\u6216\u4fee\u6539\u6570\u636e\u7684\u64cd\u4f5c\u3002",401:"\u7528\u6237\u6ca1\u6709\u6743\u9650\uff08\u4ee4\u724c\u3001\u7528\u6237\u540d\u3001\u5bc6\u7801\u9519\u8bef\uff09\u3002",403:"\u7528\u6237\u5f97\u5230\u6388\u6743\uff0c\u4f46\u662f\u8bbf\u95ee\u662f\u88ab\u7981\u6b62\u7684\u3002",404:"\u53d1\u51fa\u7684\u8bf7\u6c42\u9488\u5bf9\u7684\u662f\u4e0d\u5b58\u5728\u7684\u8bb0\u5f55\uff0c\u670d\u52a1\u5668\u6ca1\u6709\u8fdb\u884c\u64cd\u4f5c\u3002",406:"\u8bf7\u6c42\u7684\u683c\u5f0f\u4e0d\u53ef\u5f97\u3002",410:"\u8bf7\u6c42\u7684\u8d44\u6e90\u88ab\u6c38\u4e45\u5220\u9664\uff0c\u4e14\u4e0d\u4f1a\u518d\u5f97\u5230\u7684\u3002",422:"\u5f53\u521b\u5efa\u4e00\u4e2a\u5bf9\u8c61\u65f6\uff0c\u53d1\u751f\u4e00\u4e2a\u9a8c\u8bc1\u9519\u8bef\u3002",500:"\u670d\u52a1\u5668\u53d1\u751f\u9519\u8bef\uff0c\u8bf7\u68c0\u67e5\u670d\u52a1\u5668\u3002",502:"\u7f51\u5173\u9519\u8bef\u3002",503:"\u670d\u52a1\u4e0d\u53ef\u7528\uff0c\u670d\u52a1\u5668\u6682\u65f6\u8fc7\u8f7d\u6216\u7ef4\u62a4\u3002",504:"\u7f51\u5173\u8d85\u65f6\u3002"},c=function(e){var t=e.response,n=void 0===t?{}:t,a=o[n.status]||n.statusText,i=n.status,c=n.url;if(401===i)return r["a"].error({message:"\u672a\u767b\u5f55\u6216\u767b\u5f55\u5df2\u8fc7\u671f\uff0c\u8bf7\u91cd\u65b0\u767b\u5f55\u3002"}),void window.g_app._store.dispatch({type:"content/logout"});throw r["a"].error({message:"\u8bf7\u6c42\u9519\u8bef ".concat(i,": ").concat(c),description:a}),o[i]},u=Object(a["a"])({errorHandler:c,credentials:"include"});u.interceptors.response.use((function(e){if(e.headers.get("content-disposition")){var t=e.headers.get("content-disposition"),n='"'===t.substr(t.length-1)?'filename="':"filename=";t=t.substr(t.indexOf(n)+n.length);var r=decodeURI('"'===t.substr(t.length-1)?t.substr(0,t.length-1):t);e.clone().blob().then((function(e){return Object(i["saveAs"])(e,r)}))}return e})),t["a"]=u},Xazh:function(e,t){!function(e){var t,n,r,a,i,o,c='<svg><symbol id="icon-integer" viewBox="0 0 1024 1024"><path d="M170.666667 725.333333V384H85.333333V298.666667h170.666667v426.666666H170.666667m768-85.333333a85.333333 85.333333 0 0 1-85.333334 85.333333h-170.666666v-85.333333h170.666666v-85.333333h-85.333333v-85.333334h85.333333V384h-170.666666V298.666667h170.666666a85.333333 85.333333 0 0 1 85.333334 85.333333v64a64 64 0 0 1-64 64 64 64 0 0 1 64 64V640m-341.333334 0v85.333333H341.333333v-170.666666a85.333333 85.333333 0 0 1 85.333334-85.333334h85.333333V384H341.333333V298.666667h170.666667a85.333333 85.333333 0 0 1 85.333333 85.333333v85.333333a85.333333 85.333333 0 0 1-85.333333 85.333334h-85.333333v85.333333h170.666666z" fill="" ></path></symbol><symbol id="icon-bool" viewBox="0 0 1024 1024"><path d="M896 0H128C57.6 0 0 57.6 0 128v768c0 70.4 57.6 128 128 128h768c70.4 0 128-57.6 128-128V128c0-70.4-57.6-128-128-128zM448 794.496L210.752 557.248l90.496-90.496L448 613.504l306.752-306.752 90.496 90.496L448 794.496z" fill="" ></path></symbol><symbol id="icon-decimal" viewBox="0 0 1024 1024"><path d="M352 928h-256A32 32 0 0 1 64 896V128a32 32 0 0 1 32-32h256A32 32 0 0 1 384 128v768a32 32 0 0 1-32 32z m-224-64h192v-704H128zM928 928h-256a32 32 0 0 1 0-64H896v-320h-224A32 32 0 0 1 640 512V128a32 32 0 0 1 32-32h256a32 32 0 0 1 0 64H704v320h224a32 32 0 0 1 32 32v384a32 32 0 0 1-32 32z" fill="#4D4D4D" ></path><path d="M512 896m-64 0a64 64 0 1 0 128 0 64 64 0 1 0-128 0Z" fill="#4D4D4D" ></path></symbol><symbol id="icon-tree" viewBox="0 0 1025 1024"><path d="M1013.860543 719.452148a39.969564 39.969564 0 0 1 10.392086 27.978695V983.251269a39.969564 39.969564 0 0 1-10.392086 28.778086c-6.39513 7.194521-15.188434 10.392087-24.78113 10.392087H782.836464a31.975651 31.975651 0 0 1-23.981738-10.392087 39.969564 39.969564 0 0 1-10.392087-28.778086V747.430843c0-7.993913 1.598783-13.589652 4.796348-19.984782 3.197565-6.39513 7.993913-11.191478 12.79026-14.389043a30.376868 30.376868 0 0 1 16.787217-5.595739h77.540954V551.57998a30.376868 30.376868 0 0 0-3.197566-14.389043 28.778086 28.778086 0 0 0-8.793304-10.392086 21.583564 21.583564 0 0 0-12.79026-3.996956H543.818472v184.659384h78.340345c8.793304 0 16.787217 3.996956 23.981739 11.990869a39.969564 39.969564 0 0 1 9.592695 27.978695V983.251269c0 7.194521-0.799391 13.589652-3.996956 19.984782s-7.993913 11.191478-12.790261 14.389043a30.376868 30.376868 0 0 1-16.787217 4.796348H415.915868a30.376868 30.376868 0 0 1-16.787217-4.796348 39.969564 39.969564 0 0 1-13.589651-14.389043 39.969564 39.969564 0 0 1-4.796348-19.984782V747.430843a39.969564 39.969564 0 0 1 10.392087-27.978695 31.975651 31.975651 0 0 1 24.781129-11.990869h76.741563V522.801895H189.688137a23.981738 23.981738 0 0 0-19.185391 7.993912c-4.796348 6.39513-7.194521 12.79026-7.194521 20.784173v155.881299H240.849179c10.392087 0 18.385999 3.996956 24.781129 11.990869 6.39513 7.993913 9.592695 17.586608 9.592696 27.978695V983.251269c0 11.191478-3.197565 20.784173-9.592696 28.778086-6.39513 7.194521-14.389043 10.392087-23.981738 10.392087H34.606229c-3.996956 0-7.993913 0-11.191477-1.598783a32.775042 32.775042 0 0 1-8.793304-5.595738 37.57139 37.57139 0 0 1-7.993913-7.993913 41.568346 41.568346 0 0 1-4.796348-11.191478A44.765911 44.765911 0 0 1 1.031796 983.251269V747.430843l0.799391-10.392087A31.975651 31.975651 0 0 1 5.828144 727.446061 51.161042 51.161042 0 0 1 17.019621 713.057018a23.981738 23.981738 0 0 1 7.993913-3.996956l9.592695-1.598783H112.946575V492.425026c0-7.993913 2.398174-14.389043 7.993912-19.984782 4.796348-5.595739 10.392087-7.993913 17.586608-7.993913h354.130336V315.759554h-76.741563a31.975651 31.975651 0 0 1-24.781129-11.990869 39.969564 39.969564 0 0 1-10.392087-27.179304V39.969564c0-11.191478 3.197565-20.784173 10.392087-28.778086A31.975651 31.975651 0 0 1 415.915868 0.799391h206.242949c5.595739 0 11.191478 1.598783 16.787217 5.595739a41.568346 41.568346 0 0 1 12.790261 15.188434c3.197565 5.595739 3.996956 12.79026 3.996956 19.185391v236.619818a39.969564 39.969564 0 0 1-9.592695 27.179303c-7.194521 7.993913-15.188434 11.990869-23.981739 11.990869h-78.340345V463.64694h342.139466c7.993913 0 13.589652 3.197565 19.185391 7.993913 4.796348 6.39513 7.194521 12.79026 7.194522 20.784173v215.835645h76.741562a31.975651 31.975651 0 0 1 24.78113 11.191477z"  ></path></symbol><symbol id="icon-radio" viewBox="0 0 1024 1024"><path d="M512 85.290667C747.648 85.290667 938.666667 276.352 938.666667 512.042667c0 235.648-191.061333 426.709333-426.709334 426.709333-235.690667 0-426.752-191.061333-426.752-426.709333C85.248 276.352 276.309333 85.248 512 85.248z m0 64a362.752 362.752 0 1 0 0 725.461333A362.752 362.752 0 0 0 512 149.333333z m-0.170667 106.666666a255.914667 255.914667 0 1 1 0 511.829334 255.914667 255.914667 0 0 1 0-511.829334z"  ></path></symbol><symbol id="icon-m2m" viewBox="0 0 1024 1024"><path d="M307.2 768a51.2 51.2 0 0 0-51.2-51.2H153.6a51.2 51.2 0 0 0-51.2 51.2v102.4a51.2 51.2 0 0 0 51.2 51.2h102.4a51.2 51.2 0 0 0 51.2-51.2v-102.4z m102.4-51.2v204.8a102.4 102.4 0 0 1-102.4 102.4H102.4a102.4 102.4 0 0 1-102.4-102.4v-204.8a102.4 102.4 0 0 1 102.4-102.4h204.8a102.4 102.4 0 0 1 102.4 102.4zM921.6 153.6a51.2 51.2 0 0 0-51.2-51.2h-102.4a51.2 51.2 0 0 0-51.2 51.2v102.4a51.2 51.2 0 0 0 51.2 51.2h102.4a51.2 51.2 0 0 0 51.2-51.2V153.6z m102.4-51.2v204.8a102.4 102.4 0 0 1-102.4 102.4h-204.8a102.4 102.4 0 0 1-102.4-102.4V102.4a102.4 102.4 0 0 1 102.4-102.4h204.8a102.4 102.4 0 0 1 102.4 102.4z m-153.6 409.6h-102.4a50.9952 50.9952 0 1 0 0 101.888v102.4c0 28.3136-22.9376 51.712-51.2 51.712h-102.4c0-51.2-22.9376-51.456-51.2-51.456s-51.2 22.6816-51.2 50.944v102.4c0 28.3136 22.9376 51.456 51.2 51.456S614.4 921.6 614.4 870.4h153.6c56.576 0 102.4-46.336 102.4-102.912v-153.6A50.9952 50.9952 0 1 0 870.4 512z m-358.4-256a51.2 51.2 0 0 1-102.4 0H307.2a51.2 51.2 0 0 0-51.2 51.2v102.4a51.2 51.2 0 0 1 0 102.4H153.6a51.2 51.2 0 0 1 0-102.4V256a102.4 102.4 0 0 1 102.4-102.4h153.6a51.2 51.2 0 0 1 102.4 0v102.4z"  ></path></symbol><symbol id="icon-string" viewBox="0 0 1024 1024"><path d="M85.333333 742.4v-81.066667c29.866667 12.8 85.333333 21.333333 136.533334 21.333334 64 0 93.866667-17.066667 93.866666-64 0-42.666667-17.066667-55.466667-93.866666-76.8-102.4-21.333333-132.266667-51.2-132.266667-136.533334 0-98.133333 59.733333-136.533333 170.666667-136.533333 51.2 0 98.133333 8.533333 123.733333 17.066667v76.8C354.133333 349.866667 302.933333 341.333333 260.266667 341.333333c-59.733333 0-85.333333 12.8-85.333334 59.733334 0 38.4 12.8 46.933333 85.333334 64 110.933333 25.6 140.8 59.733333 140.8 149.333333 0 93.866667-55.466667 140.8-179.2 140.8-51.2 4.266667-110.933333-4.266667-136.533334-12.8zM584.533333 448v179.2c0 46.933333 8.533333 59.733333 46.933334 59.733333 12.8 0 21.333333 0 34.133333-4.266666v68.266666c-12.8 0-29.866667 4.266667-46.933333 4.266667-89.6 0-119.466667-21.333333-119.466667-119.466667v-187.733333h-51.2V379.733333h51.2V290.133333h85.333333v89.6h81.066667v68.266667h-81.066667zM938.666667 371.2l-4.266667 76.8h-8.533333c-46.933333 0-93.866667 17.066667-106.666667 81.066667v221.866666h-85.333333V379.733333h85.333333v68.266667c21.333333-59.733333 68.266667-72.533333 110.933333-72.533333h8.533334z"  ></path></symbol><symbol id="icon-object" viewBox="0 0 1024 1024"><path d="M106.057143 830.171429v-193.828572c0-43.885714-36.571429-80.457143-80.457143-80.457143H0v-84.114285h25.6c43.885714 0 80.457143-36.571429 80.457143-80.457143V193.828571c0-87.771429 73.142857-157.257143 160.914286-157.257142h54.857142v106.057142H266.971429c-29.257143 0-54.857143 21.942857-54.857143 51.2v215.771429c0 43.885714-29.257143 87.771429-73.142857 98.742857 43.885714 14.628571 73.142857 54.857143 73.142857 98.742857v215.771429c0 29.257143 25.6 51.2 54.857143 51.2h54.857142V987.428571H266.971429c-87.771429 0-160.914286-69.485714-160.914286-157.257142z m811.885714-197.485715v193.828572c0 87.771429-73.142857 157.257143-160.914286 157.257143h-54.857142V877.714286h54.857142c29.257143 0 54.857143-21.942857 54.857143-51.2v-215.771429c0-43.885714 29.257143-87.771429 73.142857-98.742857-43.885714-14.628571-73.142857-54.857143-73.142857-98.742857v-219.428572c0-29.257143-25.6-51.2-54.857143-51.2h-54.857142V36.571429h54.857142c87.771429 0 160.914286 69.485714 160.914286 157.257142v193.828572c0 43.885714 36.571429 80.457143 80.457143 80.457143h25.6v84.114285h-25.6c-43.885714 3.657143-80.457143 36.571429-80.457143 80.457143z"  ></path></symbol><symbol id="icon-array" viewBox="0 0 1024 1024"><path d="M352 64H128A64 64 0 0 0 64 128v768a64 64 0 0 0 64 64h224a32 32 0 0 0 32-32v-64a32 32 0 0 0-32-32H192V192h160a32 32 0 0 0 32-32V96a32 32 0 0 0-32-32z m544 0H672a32 32 0 0 0-32 32v64a32 32 0 0 0 32 32h160v640h-160a32 32 0 0 0-32 32v64a32 32 0 0 0 32 32h224a64 64 0 0 0 64-64V128a64 64 0 0 0-64-64z"  ></path></symbol><symbol id="icon-time" viewBox="0 0 1024 1024"><path d="M812.36544 493.26838c0 22.533202-18.260899 40.782845-40.782845 40.782845l-234.203066-0.348947c-3.663436 1.075495-7.467065 1.841951-11.489682 1.841951-17.524119 0-32.340569-11.120268-38.116109-26.643823-2.090615-4.920056-3.264347-10.314926-3.264347-16.000416 0-2.101871 0.319272-4.121877 0.618077-6.134721l0.35918-238.295268c0-22.521946 18.261922-40.783869 40.782845-40.783869 22.522969 0 40.782845 18.261922 40.782845 40.783869l-0.298805 203.706495 204.831109 0.319272C794.104541 452.495768 812.36544 470.746434 812.36544 493.26838zM525.828448 941.493891c-95.78453 0-184.14088-30.547737-256.965489-81.735559-17.244756-4.758374-29.990035-20.392446-29.990035-39.149649l-0.35918-3.784186c0-22.521946 18.241456-40.782845 40.763402-40.782845 11.830443 0 22.404266 5.108345 29.850865 13.142322 60.695361 44.268226 135.213541 70.75446 216.102826 70.75446 203.079208 0 367.703593-164.627455 367.703593-367.703593 0-203.080232-164.624385-367.70564-367.703593-367.70564S157.527245 289.154609 157.527245 492.233817c0 56.095599 12.922311 109.046578 35.385928 156.609851l-6.610558 6.612605c14.914688 6.073322 25.449625 20.658506 25.449625 37.745672l0.35918 3.783163c0 22.522969-18.260899 40.782845-40.782845 40.782845-18.600637 0-34.133402-12.546757-39.032992-29.582759C97.22995 644.243907 77.156776 570.912761 77.156776 492.831428c0-247.786433 200.88831-448.663486 448.673719-448.663486 247.785409 0 448.670649 200.8791 448.670649 448.663486C974.501144 740.626048 773.614881 941.493891 525.828448 941.493891z"  ></path></symbol><symbol id="icon-password" viewBox="0 0 1024 1024"><path d="M851.450696 21.647662l-399.545757 399.609756c-117.438165-55.551132-262.011906-35.007453-359.162388 62.143029-123.646068 123.646068-123.646068 324.218934 0 447.865002s324.218934 123.646068 447.865002 0c97.150482-97.150482 117.630162-241.660224 62.143029-359.226387l151.741629-151.741629 96.382494 96.382494c28.79955 28.79955 75.51882 28.863549 104.382369 0l43.51932-43.51932c28.79955-28.79955 28.863549-75.51882 0-104.382369l-54.463149-54.463149 0.063999-0.063999-41.983344-41.791347 99.966438-99.966438c28.79955-28.79955 28.863549-75.51882 0-104.382369l-46.463274-46.463274c-28.863549-28.863549-75.582819-28.863549-104.446368 0zM392.065874 782.787769c-41.663349 41.663349-109.182294 41.59935-150.781644-0.063999-41.663349-41.663349-41.663349-109.182294 0-150.845643s109.182294-41.59935 150.781644 0.063999 41.727348 109.118295 0 150.845643z"  ></path></symbol><symbol id="icon-date" viewBox="0 0 1024 1024"><path d="M883.278513 148.539035l-43.016723 0 0-12.780071c0-38.310537-31.199583-69.632917-69.323878-69.632917l-1.02433 0c-38.129412 0-69.323878 31.321356-69.323878 69.632917l0 12.780071L317.20292 148.539035l0-12.780071c0-38.310537-31.195489-69.632917-69.323878-69.632917l-1.055029 0c-38.127366 0-69.322855 31.321356-69.322855 69.632917l0 12.780071-42.924625 0c-38.127366 0-69.323878 31.351032-69.323878 69.609381l0 665.701614c0 38.309514 31.195489 69.632917 69.323878 69.632917l748.70198 0c38.127366 0 69.322855-31.323403 69.322855-69.632917l0-665.701614C952.601368 179.890067 921.405879 148.539035 883.278513 148.539035L883.278513 148.539035zM728.318232 135.758963c0-23.024389 18.632359-41.777499 41.594327-41.777499l1.02433 0c22.931269 0 41.593304 18.753109 41.593304 41.777499L812.530193 259.615852c0 23.024389-18.662035 41.778522-41.593304 41.778522l-1.02433 0c-22.961968 0-41.594327-18.754133-41.594327-41.778522L728.318232 135.758963 728.318232 135.758963zM205.23071 135.758963c0-23.024389 18.632359-41.777499 41.599444-41.777499l1.048889 0c22.903639 0 41.594327 18.753109 41.594327 41.777499L289.473369 259.615852c0 23.024389-18.691711 41.778522-41.594327 41.778522l-1.048889 0c-22.967084 0-41.599444-18.754133-41.599444-41.778522L205.23071 135.758963 205.23071 135.758963zM883.278513 897.807926l-748.70198 0c-7.519254 0-13.864776-6.468318-13.864776-13.957897L120.711757 394.394489l776.433578 0 0 489.455541C897.144312 891.338584 890.797767 897.807926 883.278513 897.807926L883.278513 897.807926zM222.614635 494.083955l127.918391 0 0 62.950727L222.614635 557.034682 222.614635 494.083955 222.614635 494.083955zM445.963493 494.083955l126.906342 0 0 62.950727L445.963493 557.034682 445.963493 494.083955 445.963493 494.083955zM668.299277 494.083955l124.873032 0 0 62.950727L668.299277 557.034682 668.299277 494.083955 668.299277 494.083955zM222.614635 622.00951l127.918391 0 0 61.927421L222.614635 683.936931 222.614635 622.00951 222.614635 622.00951zM445.963493 622.00951l126.906342 0 0 61.927421L445.963493 683.936931 445.963493 622.00951 445.963493 622.00951zM668.299277 622.00951l124.873032 0 0 61.927421L668.299277 683.936931 668.299277 622.00951 668.299277 622.00951zM222.614635 746.884588l127.918391 0 0 64.97278L222.614635 811.857369 222.614635 746.884588 222.614635 746.884588zM445.963493 746.884588l126.906342 0 0 64.97278L445.963493 811.857369 445.963493 746.884588 445.963493 746.884588zM668.299277 746.884588l124.873032 0 0 64.97278L668.299277 811.857369 668.299277 746.884588 668.299277 746.884588zM668.299277 746.884588"  ></path></symbol><symbol id="icon-transfer" viewBox="0 0 1024 1024"><path d="M783.272333 949.20655c-1.848091 0-3.607154-0.293689-5.249561-0.820692-6.451946-2.287089-10.763135-8.388041-10.763135-15.192004L767.259638 789.016151 422.917102 789.016151c-30.912034 0-56.075133-25.104771-56.075133-56.016805 0-30.912034 25.163099-56.016805 56.075133-56.016805L767.258615 676.982542 767.258615 532.805862c0-6.803963 4.281513-12.845563 10.67513-15.074324 1.612731-0.176009 3.108804-0.234337 4.457522-0.234337 7.214309 0 10.851139 2.052752 13.403265 5.279237L955.956278 723.028251c4.721535 5.865591 4.721535 14.077623 0.029676 19.943215L795.794531 943.223279C792.745079 947.036118 788.198529 949.20655 783.272333 949.20655z"  ></path><path d="M240.727667 72.29556c1.848091 0 3.607154 0.293689 5.249561 0.820692 6.451946 2.287089 10.763135 8.388041 10.763135 15.192004l0 144.17668 344.341512 0c30.912034 0 56.075133 25.104771 56.075133 56.016805s-25.163099 56.016805-56.075133 56.016805L256.741385 344.518544l0 144.17668c0 6.803963-4.281513 12.845563-10.67513 15.074324-1.612731 0.176009-3.108804 0.234337-4.457522 0.234337-7.214309 0-10.851139-2.052752-13.403265-5.279237L68.043722 298.473859c-4.721535-5.865591-4.721535-14.077623-0.029676-19.943215L228.204445 78.278831C231.254921 74.465992 235.800447 72.29556 240.727667 72.29556z"  ></path></symbol><symbol id="icon-image" viewBox="0 0 1024 1024"><path d="M736 448c53 0 96-43 96-96 0-53-43-96-96-96-53 0-96 43-96 96C640 405 683 448 736 448z"  ></path><path d="M904 128 120 128c-31.2 0-56 25.4-56 56.6l0 654.8c0 31.2 24.8 56.6 56 56.6l784 0c31.2 0 56-25.4 56-56.6L960 184.6C960 153.4 935.2 128 904 128zM697.8 523.4c-6-7-15.2-12.4-25.6-12.4-10.2 0-17.4 4.8-25.6 11.4l-37.4 31.6c-7.8 5.6-14 9.4-23 9.4-8.6 0-16.4-3.2-22-8.2-2-1.8-5.6-5.2-8.6-8.2L448 430.6c-8-9.2-20-15-33.4-15-13.4 0-25.8 6.6-33.6 15.6L128 736.4 128 215.4c2-13.6 12.6-23.4 26.2-23.4l715.4 0c13.8 0 25 10.2 25.8 24l0.6 520.8L697.8 523.4z"  ></path></symbol><symbol id="icon-file" viewBox="0 0 1024 1024"><path d="M672 480 352 480c-19.2 0-32 12.8-32 32s12.8 32 32 32l320 0c19.2 0 32-12.8 32-32S691.2 480 672 480z"  ></path><path d="M672 672 352 672c-19.2 0-32 12.8-32 32s12.8 32 32 32l320 0c19.2 0 32-12.8 32-32S691.2 672 672 672z"  ></path><path d="M352 352l96 0c19.2 0 32-12.8 32-32s-12.8-32-32-32l-96 0c-19.2 0-32 12.8-32 32S332.8 352 352 352z"  ></path><path d="M608 64 256 64C220.8 64 192 92.8 192 128l0 768c0 35.2 28.8 64 64 64l64 0 384 0 64 0c35.2 0 64-28.8 64-64L832 288 608 64zM742.4 288 608 288 608 153.6 742.4 288zM704 896 320 896 256 896 256 128l288 0 0 192c0 19.2 12.8 32 32 32l192 0 0 544L704 896z"  ></path></symbol><symbol id="icon-text" viewBox="0 0 1024 1024"><path d="M799.999887 289.356358H224.000113a31.970084 31.970084 0 0 0 0 63.940169h575.999774a31.970084 31.970084 0 0 0 0-63.940169zM799.999887 480.093133H224.000113a31.970084 31.970084 0 1 0 0 63.940169h575.999774a31.970084 31.970084 0 1 0 0-63.940169zM799.999887 670.829908H224.000113a31.970084 31.970084 0 0 0 0 63.940169h575.999774a31.970084 31.970084 0 0 0 0-63.940169z" fill="" ></path><path d="M948.041247 156.14406A150.750689 150.750689 0 0 0 809.164645 63.940169h-0.278158l-73.444496 1.325765a31.988147 31.988147 0 0 0 1.112631 63.965456l72.866506-1.260741a86.124156 86.124156 0 0 1 61.100792 25.449632c16.41131 16.41131 25.366546 38.234054 25.366546 61.440361v594.278716c0 23.206308-8.955236 44.956802-25.366546 61.368112a86.059133 86.059133 0 0 1-61.357275 25.377384H214.835355c-23.206308 0-45.061563-8.969686-61.472873-25.377384A86.18918 86.18918 0 0 1 127.880338 809.139358V214.860642a86.94418 86.94418 0 0 1 86.940568-86.882768h73.173562a31.970084 31.970084 0 1 0 0-63.940169H214.835355A150.82655 150.82655 0 0 0 63.940169 214.860642v594.278716A150.598966 150.598966 0 0 0 214.835355 959.825022h594.32929A150.328033 150.328033 0 0 0 959.825022 809.139358V214.860642a149.836742 149.836742 0 0 0-11.783775-58.716582z" fill="" ></path><path d="M415.997629 127.880338h192.001129a31.970084 31.970084 0 0 0 0-63.940169h-192.001129a31.970084 31.970084 0 0 0 0 63.940169z" fill="" ></path></symbol><symbol id="icon-gallery" viewBox="0 0 1024 1024"><path d="M896 1024H128a128 128 0 0 1-128-128V128a128 128 0 0 1 128-128h768a128 128 0 0 1 128 128v768a128 128 0 0 1-128 128z m64-896a64 64 0 0 0-64-64H128a64 64 0 0 0-64 64v768a64 64 0 0 0 64 64h768a64 64 0 0 0 64-64V128z m-69.632 722.112a32 32 0 0 1-44.512 8.256L351.712 518.656l-173.952 115.968a32 32 0 1 1-35.488-53.248l192-128h0.32a30.56 30.56 0 0 1 7.552-3.2 29.28 29.28 0 0 1 4.064-1.6 31.424 31.424 0 0 1 3.84 0 32 32 0 0 1 8.32 0 26.592 26.592 0 0 1 2.944 1.184 32.64 32.64 0 0 1 8.608 3.648h0.256l225.664 155.168 152.224-121.792 0.288 0.352a31.584 31.584 0 0 1 37.472-1.984l96 64a32 32 0 1 1-35.488 53.248l-76.544-51.008-118.816 95.04 231.232 158.976a32 32 0 0 1 8.16 44.704zM592 416A144 144 0 1 1 736 272a144 144 0 0 1-144 144z m0-224A80 80 0 1 0 672 272 80 80 0 0 0 592 192z"  ></path></symbol><symbol id="icon-video" viewBox="0 0 1024 1024"><path d="M910.222336 284.444672H113.77664V170.667008c0-31.419392 25.469952-56.889344 56.889344-56.889344h682.665984c31.419392 0 56.889344 25.469952 56.889344 56.889344v113.77664z m0 56.88832v512c0 31.419392-25.469952 56.889344-56.889344 56.889344H170.667008c-31.419392 0-56.889344-25.469952-56.889344-56.889344v-512H910.22336zM284.444672 170.667008l57.2416 113.77664h56.88832l-57.2416-113.77664h-56.88832z m170.665984 0l57.2416 113.77664H569.2416L512 170.668032h-56.889344z m170.667008 0l57.2416 113.77664h56.88832l-57.2416-113.77664h-56.88832z m6.00576 452.108288a28.444672 28.444672 0 0 0 12.721152-12.721152c7.02464-14.051328 1.330176-31.136768-12.721152-38.162432L439.38816 475.69408a28.444672 28.444672 0 0 0-12.720128-3.003392c-15.710208 0-28.444672 12.735488-28.444672 28.444672v192.396288c0 4.415488 1.028096 8.77056 3.002368 12.720128 7.025664 14.051328 24.112128 19.746816 38.162432 12.721152l192.396288-96.197632z" fill="#323233" ></path></symbol><symbol id="icon-richtext" viewBox="0 0 1024 1024"><path d="M192 560h640v32H192v-32z m448-288h192v32h-192v-32z m0 96h192v32h-192v-32z m0 96h192v32h-192v-32z m-448 192h640v32H192v-32z m0 96h640v32H192v-32z m672-736H160a96 96 0 0 0-96 96v768a96 96 0 0 0 96 96h704a96 96 0 0 0 96-96v-768a96 96 0 0 0-96-96z m64 864a64 64 0 0 1-64 64H160a64 64 0 0 1-64-64v-768a64 64 0 0 1 64-64h704a64 64 0 0 1 64 64v768z m-352-672H192v288h384v-288z m-32 256H224v-224h320v224z"  ></path></symbol><symbol id="icon-cascader" viewBox="0 0 1024 1024"><path d="M772.87 734.061c-43.34 0-80.008 27.933-93.768 66.577H475.91c-56.607 0-102.667-46.06-102.667-102.667v-97.147h305.86c13.76 38.645 50.426 66.578 93.767 66.578 55.124 0 99.948-44.825 99.948-99.949s-44.824-99.948-99.948-99.948c-43.34 0-80.008 27.933-93.768 66.578h-305.86V401.01H695.17c55.123 0 99.948-44.825 99.948-99.949V190.073c0-55.124-44.825-99.948-99.948-99.948H251.13c-55.124 0-99.948 44.824-99.948 99.948v110.99c0 55.123 44.824 99.948 99.948 99.948h55.536v296.96c0 93.356 75.97 169.327 169.326 169.327h203.192c13.76 38.644 50.428 66.577 93.769 66.577 55.124 0 99.948-44.824 99.948-99.948s-44.907-99.866-100.03-99.866z m0-199.896c18.375 0 33.289 14.914 33.289 33.288s-14.914 33.29-33.289 33.29-33.288-14.915-33.288-33.29 14.914-33.288 33.288-33.288zM217.76 301.063v-110.99c0-18.375 14.914-33.288 33.288-33.288h444.04c18.375 0 33.289 14.913 33.289 33.288v110.99c0 18.374-14.914 33.288-33.289 33.288H251.13c-18.375 0-33.371-14.914-33.371-33.289zM772.87 867.298c-18.374 0-33.288-14.914-33.288-33.289 0-18.374 14.914-33.288 33.288-33.288s33.289 14.914 33.289 33.288c0.082 18.293-14.914 33.289-33.289 33.289z"  ></path></symbol></svg>',u=(u=document.getElementsByTagName("script"))[u.length-1].getAttribute("data-injectcss");if(u&&!e.__iconfont__svg__cssinject__){e.__iconfont__svg__cssinject__=!0;try{document.write("<style>.svgfont {display: inline-block;width: 1em;height: 1em;fill: currentColor;vertical-align: -0.1em;font-size:16px;}</style>")}catch(e){console&&console.log(e)}}function l(){i||(i=!0,r())}t=function(){var e,t,n,r;(r=document.createElement("div")).innerHTML=c,c=null,(n=r.getElementsByTagName("svg")[0])&&(n.setAttribute("aria-hidden","true"),n.style.position="absolute",n.style.width=0,n.style.height=0,n.style.overflow="hidden",e=n,(t=document.body).firstChild?(r=e,(n=t.firstChild).parentNode.insertBefore(r,n)):t.appendChild(e))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(t,0):(n=function(){document.removeEventListener("DOMContentLoaded",n,!1),t()},document.addEventListener("DOMContentLoaded",n,!1)):document.attachEvent&&(r=t,a=e.document,i=!1,(o=function(){try{a.documentElement.doScroll("left")}catch(e){return void setTimeout(o,50)}l()})(),a.onreadystatechange=function(){"complete"==a.readyState&&(a.onreadystatechange=null,l())})}(window)},Z3Gc:function(e,t,n){"use strict";n.d(t,"b",(function(){return o})),n.d(t,"f",(function(){return c})),n.d(t,"e",(function(){return u})),n.d(t,"a",(function(){return l})),n.d(t,"g",(function(){return s})),n.d(t,"c",(function(){return d})),n.d(t,"d",(function(){return f})),n.d(t,"h",(function(){return p}));var r=n("gyLe"),a=n.n(r),i=(n("L5Lq"),function(e){return decodeURIComponent(window.atob(e))}),o=a.a,c=i("JUU5JTk3JUFBJUU3JTk0JUI1JUU2JTk1JUIwJUU2JThEJUFFJUU3JUFFJUExJUU3JTkwJTg2"),u="".concat(c,"\u7cfb\u7edf"),l=i("MjAxOCUyMCVFNSVCOSVCRiVFNCVCOCU5QyVFNiU5RCVCMCVFNiU5OCU4RSVFNyVBNyU5MSVFNiU4QSU4MCVFNSU4NyVCQSVFNSU5MyU4MQ=="),s=i("aHR0cCUzQSUyRiUyRnd3dy5naXRtZW4uY29t"),d=i("R2l0bWVuLkx0ZA=="),f=i("aHR0cCUzQSUyRiUyRnd3dy5naXRtZW4uY29t"),p=465033416},bDUM:function(e,t,n){"use strict";n("Mwp2");var r=n("VXEj"),a=n("tJVT"),i=n("q1tI"),o=n.n(i),c=n("9jjd"),u=n("jfUH");t["a"]=function(e){var t=e.value,n=e.field.ref,i=e.urlField,l=void 0===i?"url":i,s=Object(u["xb"])(n);return o.a.createElement(r["b"],{dataSource:t,renderItem:function(e){var t=s(e),n=e[l]||void 0,i=n?n.split("#"):[n],u=Object(a["a"])(i,1),d=u[0];return o.a.createElement(r["b"].Item,{actions:[o.a.createElement("a",{href:d},"\u94fe\u63a5")]},o.a.createElement(r["b"].Item.Meta,{avatar:o.a.createElement(c["a"],null),title:t}))}})}},buKw:function(e,t,n){"use strict";n.d(t,"a",(function(){return m}));n("+Xjd");var r=n("Ij4x"),a=n("0Owb"),i=n("fWQN"),o=n("mtLc"),c=n("yKVA"),u=n("879j"),l=n("q1tI"),s=n.n(l),d=n("wd/R"),f=n.n(d),p=n("AAgL"),m=function(e){Object(c["a"])(n,e);var t=Object(u["a"])(n);function n(){return Object(i["a"])(this,n),t.apply(this,arguments)}return Object(o["a"])(n,[{key:"render",value:function(){var e=this.props,t=e.value,n=e.onChange,i=e.field.type,o={date:"YYYY-MM-DD",datetime:"YYYY-MM-DD HH:mm:ssZ"}[i],c={date:"YYYY-MM-DD",datetime:"YYYY-MM-DD HH:mm:ss"}[i];return s.a.createElement(r["a"],Object(a["a"])({value:t?f()(t):null,onChange:function(e){n("date"===i?e&&e.format(o):e)},format:c},this.widgetProps,{showTime:"datetime"===i}))}}]),n}(p["a"])},chM4:function(e,t,n){"use strict";n.d(t,"a",(function(){return h}));n("gmZI");var r=n("hdkw"),a=n("0Owb"),i=n("fWQN"),o=n("mtLc"),c=n("yKVA"),u=n("879j"),l=n("q1tI"),s=n.n(l),d=n("wd/R"),f=n.n(d),p=n("AAgL"),m="HH:mm:ss",h=function(e){Object(c["a"])(n,e);var t=Object(u["a"])(n);function n(){return Object(i["a"])(this,n),t.apply(this,arguments)}return Object(o["a"])(n,[{key:"render",value:function(){var e=this.props,t=e.value,n=e.onChange;return s.a.createElement(r["a"],Object(a["a"])({value:t?f()(t,m):null,onChange:function(e){return n(e&&e.format(m))},format:m},this.widgetProps))}}]),n}(p["a"])},ctVj:function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n("tJVT"),a=n("q1tI");function i(){var e=Object(a["useState"])("ready"),t=Object(r["a"])(e,2),n=t[0],i=t[1],o=function(e){return function(){"ready"===n&&(e.apply(void 0,arguments),i("submitting"))}},c=function(){return i("submitted")},u=function(){return i("ready")};return{loading:"submitting"===n,finish:c,retry:u,dispatch:o,dispatchPromise:function(e){return o((function(){return e.apply(void 0,arguments).finally(u)}))}}}},d76M:function(e,t,n){"use strict";n.d(t,"b",(function(){return i})),n.d(t,"a",(function(){return c}));var r={},a="fieldHandler";function i(e,t){r[e]=t}function o(e,t,n,a){if(t in r){var i=r[t][e],o=i[n];o&&o(a)}}function c(e,t,n){o(a,e,t,n)}},dTNC:function(e,t,n){"use strict";(function(e){var r=n("9og8"),a=(n("4csm"),n("2Fwu")),i=(n("9kbU"),n("vbHR")),o=n("0Owb"),c=n("PpiC"),u=(n("eNCU"),n("pjJH")),l=n("tJVT"),s=(n("eE3J"),n("GSZB")),d=n("WmNS"),f=n.n(d),p=n("q1tI"),m=n.n(p),h=n("EBSl"),b=n("jfUH");function v(t){for(var n=t,r=["outlined","filled","twoTone"],a=0;a<r.length;a+=1){var i="__".concat(r[a]);if(n&&n.endsWith(i)){n=m.a.createElement(s["a"],{type:n.slice(0,-i.length),theme:"outlined"});break}}return e.isString(n)&&(n=m.a.createElement(s["a"],{type:n})),n}t["a"]=function(t){var n=t.tableActions,d=t.context,_=t.model,g=Object(b["ob"])();return n.filter((function(t){if(e.isEmpty(t.groups))return!0;var n=_.split("__"),r=Object(l["a"])(n,2),a=r[0],i=r[1],o="".concat(t.action,"_").concat(i,"_").concat(t.id,"__").concat(a);return g.includes(o)})).map((function(e){return Object(h["o"])(h["d"],{config:e})})).map((function(e){return function(t){var n=Object(p["useState"])(!1),b=Object(l["a"])(n,2),g=b[0],y=b[1],O=e.icon,j=e.submenus,w=u["a"];if(j&&j.length){var k=function e(t){var n=t.action,r=Object(c["a"])(t,["action"]);return m.a.createElement(h["k"],{action:item,model:_,handler:d},(function(t,a){var c=Object(h["o"])(h["d"],{config:n});return c.submenus&&c.submenus.length?m.a.createElement(i["a"].SubMenu,Object(o["a"])({},r,{title:[c.icon&&v(c.icon),a],onTitleClick:function(){return t()}}),c.submenus.map((function(t){return m.a.createElement(e,{action:t})}))):m.a.createElement(i["a"].Item,Object(o["a"])({},r,{onClick:function(){return t()}}),c.icon&&v(c.icon),a)}))},E=m.a.createElement(i["a"],null,j.map((function(e){return m.a.createElement(k,{action:e})})));w=e.action?function(e){return m.a.createElement(a["a"].Button,Object(o["a"])({},e,{overlay:E}))}:function(e){e.onClick;var t=Object(c["a"])(e,["onClick"]);return m.a.createElement(a["a"],{overlay:E},m.a.createElement(u["a"],t,t.children,m.a.createElement(s["a"],{type:"down"})))}}return m.a.createElement(h["k"],{action:e,model:_,handler:d},(function(e,n){return m.a.createElement(w,Object(o["a"])({},t,{onClick:Object(r["a"])(f.a.mark((function t(){return f.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return y(!0),t.prev=1,t.next=4,e();case 4:return t.prev=4,y(!1),t.finish(4);case 7:case"end":return t.stop()}}),t,null,[[1,,4,7]])}))),loading:g}),O&&!g&&v(O),n)}))}})).map((function(e,t){return m.a.createElement(e,{type:0===t&&"primary",style:{marginRight:8}})}))}}).call(this,n("LvDl"))},dUs0:function(e,t,n){"use strict";(function(e){n("eNCU");var r,a,i,o,c=n("pjJH"),u=(n("Dvpn"),n("myml")),l=n("jrin"),s=(n("uPNz"),n("Oedt")),d=n("oBTY"),f=n("k1fw"),p=n("fWQN"),m=n("mtLc"),h=n("tS8v"),b=n("yKVA"),v=n("879j"),_=n("0Owb"),g=n("q1tI"),y=n.n(g),O=n("/MKj"),j=n("G9e4"),w=n("jVA4"),k=n("9Ndd"),E=n("AAgL"),C=n("jfUH"),x=n("Utjr"),S=function(e){return y.a.createElement(j["b"],Object(_["a"])({},e,{extraOptions:{disabled:!0}}))},F=(r=Object(O["c"])((function(e){var t=e.content,n=t.schemas,r=t.adminConfig;return{schemas:n,adminConfig:r}})),a=Reflect.metadata("design:type",Function),i=Reflect.metadata("design:paramtypes",[void 0]),r(o=a(o=i(o=function(t){Object(b["a"])(r,t);var n=Object(v["a"])(r);function r(e){var t;Object(p["a"])(this,r),t=n.call(this,e),t.myProps=["canAdd","fields"],t.tmpRowIndex=0,t.formSet={},t.lastChangeField=[];var a=t.props,i=a.validateparams,o=a.extra,c=a.field,u=a.schemas,l=a.adminConfig,s=a.value;return t.model=c.ref,t.schema=u[t.model],t.admin=l[t.model],i.instance=Object(h["a"])(t),o.brefFields[c.name]=Object(h["a"])(t),t.formValidated=!1,t.state={data:s||[]},t}return Object(m["a"])(r,[{key:"componentWillReceiveProps",value:function(e){var t=this,n=e.validateparams,r=this.props.validateparams;n.instance=r.instance;var a=this.props.value,i=e.value;if(this.tmpRowIndex=0,i&&i!==a){var o=i.map((function(e){var n=Object(f["a"])({},e);return n.row__key=Object(C["K"])(e,t.model),Object(C["K"])(e,t.model)||(n.row__key="temp_id_".concat(t.tmpRowIndex),t.tmpRowIndex+=1),n}));this.setState({data:o})}}},{key:"onRowChange",value:function(e,t){if(t&&t.target)t.stopPropagation();else{var n=this.state.data,r=Object(d["a"])(n),a=r.find((function(t){return t.row__key===e}));Object.keys(t).forEach((function(n){e&&(a[n]=t[n])})),this.setState({data:r}),this.notifyFormChange(r,!0)}}},{key:"validate",value:function(){var t=[],n=!1;return e.values(this.formSet).forEach((function(e){e.inlineData.hasError&&(n=!0)})),n&&t.push({message:"\u6709\u9519\u8bef\u4e86"}),t}},{key:"notifyFormChange",value:function(e,t){if(this.formValidated||t){this.formValidated=!0;var n=this.props.onChange,r=e.map((function(e){var t={};return Object.keys(e).forEach((function(n){"row__key"!==n&&"is__new"!==n&&(t[n]=e[n])})),t}));n(r)}}},{key:"delete",value:function(e){var t=this.state.data,n=t.filter((function(t){return t.row__key!==e}));this.setState({data:n}),delete this.formSet[e],this.notifyFormChange(n,!0)}},{key:"newRecord",value:function(){var e=this.state.data,t=this.props.fields,n=t||this.admin.inlineFormFields,r=Object(d["a"])(e),a=Object(k["c"])(this.schema,n);a.row__key="temp_id_".concat(this.tmpRowIndex),a.is__new=!0,this.tmpRowIndex+=1,r.push(a),this.setState({data:r})}},{key:"buildColumns",value:function(){var e=this,t=this.props,n=t.fields,r=t.field,a=t.disabled,i=n||this.admin.inlineFormFields||this.admin.formFields.filter((function(e){return(e.name||e)!==r.refField})),o={};this.schema.fields.forEach((function(e){o[e.name]=e}));var c=[];return i.forEach((function(t){var r="string"===typeof t?t:t.name,a=o[r],u={title:a.displayName,dataIndex:a.name,sortOrder:!1,onCell:function(){return{field:a,formFields:n||e.admin.inlineFormFields||i,editing:!0}}};t.width&&(u.width=t.width),c.push(u)})),a||c.push({title:"\u64cd\u4f5c",render:function(t,n){return e.renderOperationColumn(t,n)}}),c}},{key:"renderOperationColumn",value:function(e,t){var n=this;return y.a.createElement("div",null,y.a.createElement(g["Fragment"],null,y.a.createElement(s["a"],{title:"\u786e\u5b9a\u8981\u5220\u9664\u5417\uff1f",onConfirm:function(){return n.delete(t.row__key)}},y.a.createElement("a",null,"\u5220\u9664"))))}},{key:"render",value:function(){var e=this,t=this.props.disabled,n={body:{row:t?S:j["b"],cell:w["a"]}},r=this.props,a=r.canAdd,i=r.form,o=r.field.refField,s=this.state.data;return y.a.createElement(j["c"].Provider,{value:this.formSet},y.a.createElement(g["Fragment"],null,s&&s.length||!a?y.a.createElement(x["c"].Provider,{value:Object(l["a"])({},o,i.getFieldsValue())},y.a.createElement(u["a"],{components:n,bordered:!1,dataSource:s,columns:this.buildColumns(),rowClassName:"editable-row",pagination:!1,rowKey:function(e){return e.row__key},onRow:function(t){return{object:t,objectid:Object(C["K"])(t,e.model),model:e.model,parentform:i,onChange:function(n){return e.onRowChange(t.row__key,n)}}},scroll:{x:"max-content"}})):y.a.createElement(g["Fragment"],null),a&&!t&&y.a.createElement(c["a"],{style:{width:"100%",marginTop:16,marginBottom:8},type:"dashed",onClick:function(){return e.newRecord()},icon:"plus"},"\u65b0\u589e")))}}]),r}(E["a"]))||o)||o)||o);t["a"]=F}).call(this,n("LvDl"))},eljF:function(e,t,n){"use strict";(function(e){var r=n("0Owb"),a=(n("g9YV"),n("wCAj")),i=n("k1fw"),o=n("oBTY"),c=n("q1tI"),u=n.n(c),l=n("QSgb"),s=n("3i6F"),d=n("VW+w"),f=n("NnbD"),p=n("jfUH"),m={Sum:function(e){return e.filter(Boolean).map(String).map(l["Decimal"]).reduce((function(e,t){return e.plus(t)}),new l["Decimal"](0)).toString()},Avg:function(e){return e.filter(Boolean).map(String).map(l["Decimal"]).reduce((function(e,t){return e.plus(t)}),new l["Decimal"](0)).dividedBy(e.length).toString()},Max:function(e){var t;return 0===e.filter((function(e){return void 0!==e})).length?null:null===(t=e.filter((function(e){return void 0!==e})).map(String).map(l["Decimal"]).reduce((function(e,t){return Math.max(e,t)})))||void 0===t?void 0:t.toString()},Min:function(e){var t;return 0===e.filter((function(e){return void 0!==e})).length?null:null===(t=e.filter((function(e){return void 0!==e})).map(String).map(l["Decimal"]).reduce((function(e,t){return Math.min(e,t)})))||void 0===t?void 0:t.toString()}},h=function(t){var n=t.display,c=t.model,l=t.data,h=Object(p["ub"])(),b=Object(p["bb"])(),v=function(e,t){return Object(s["h"])(h,c,e,t)},_=Object(d["displayPreprocess"])(n,c,h).filter((function(e){return e.mergeRow}));return u.a.createElement(f["b"],Object(r["a"])({},t,{fetch:function(t){var n=_.map((function(e){return e.name})).map((function(e){return e.replace(".","__")}));n.push.apply(n,Object(o["a"])(t.orderBy)),b({type:"content/fetchAll",payload:Object(i["a"])(Object(i["a"])({},e.omit(t,["page","size"])),{},{orderBy:n})});var r=t.filters;b({type:"content/statistics",payload:{model:c,filters:r}})},renderColumn:function(t,n,r){var a=t.fields,i=t.record,o=(null===l||void 0===l?void 0:l.list)||[],c=e.mapValues(a,(function(e){return v(i,e)})),d=function(t){return!e.some(e.mapValues(a,(function(e){return v(o[t],e)})),(function(e,t){return c[t]!==e}))},f=1;if(n.mergeRow)if(r>0&&d(r-1))f=0;else{f=1;while(o[r+f]&&d(r+f))f+=1}return{props:{rowSpan:f},children:u.a.createElement(s["a"],t)}},tableProps:{summary:function(e){if(!e.length)return null;try{return u.a.createElement(a["a"].Summary.Row,null,n.map((function(t){var n=t.summary;return u.a.createElement(a["a"].Summary.Cell,null,n&&u.a.createElement(u.a.Fragment,null,n.prefix,m[n.method](e.map((function(e){return Object(s["h"])(h,c,e,n.field)}))),n.suffix))})))}catch(t){return console.error(t),null}}}}))};t["a"]=function(e){var t=e.display,n=e.model,r=Object(p["ub"])(),a=Object(d["displayPreprocess"])(t,n,r),i=f["b"];return a.some((function(e){return e.summary||e.mergeRow}))&&(i=h),u.a.createElement(i,e)}}).call(this,n("LvDl"))},fNJA:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return o})),n.d(t,"c",(function(){return d})),n.d(t,"b",(function(){return f}));var r,a=n("jrin"),i=0,o=1,c=2,u=3,l=[i,o,c,u],s=(r={},Object(a["a"])(r,i,{}),Object(a["a"])(r,o,{}),Object(a["a"])(r,c,{}),Object(a["a"])(r,u,{}),r);function d(e,t,n,r){s[e][t]=[n,r]}function f(t,n,r,a,i,c){if(void 0!==i&&0!==i.length&&-1!==l.indexOf(t)){var u=i;if(!Array.isArray(i)){if(!e.isObject(i))return;u=[i]}u.forEach((function(e){var i=e.type,u=e.action,l=e.watchFields,d=void 0===l?[]:l;if(i===t&&(i!==o||-1!==d.indexOf[n])){var f=s[i];-1!==Object.keys(f).indexOf(u)&&f[u][1](a,n,r,e,c)}}))}}}).call(this,n("LvDl"))},fapc:function(e,t,n){"use strict";(function(e){n.d(t,"b",(function(){return F})),n.d(t,"a",(function(){return A}));var r=n("k1fw"),a=n("yKVA"),i=n("879j"),o=(n("4X2C"),n("xvon")),c=(n("yavW"),n("WuMn")),u=n("tJVT"),l=n("fWQN"),s=n("mtLc"),d=(n("+Xjd"),n("Ij4x")),f=n("q1tI"),p=n.n(f),m=n("wd/R"),h=n.n(m),b=n("3V3B"),v=n("jfUH"),_=n("+9YH"),g=d["a"].RangePicker,y=function(e){var t=e.value,n=e.onChange,r=e.date;return p.a.createElement(g,{ranges:{"\u4eca\u5929":[h()().startOf("day"),h()().endOf("day")],"\u672c\u5468":[h()().startOf("week"),h()().endOf("week")],"\u5f53\u6708":[h()().startOf("month"),h()().endOf("month")],"\u8fd1\u4e09\u4e2a\u6708":[h()().subtract(90,"days"),h()().subtract(1,"days")]},showTime:!r,style:{width:"100%"},value:r?t&&[h()(t[0]),h()(t[1]).subtract(1,"day")]:t,onChange:function(e){return n(r?[e[0].format("YYYY-MM-DD"),e[1].add(1,"day").format("YYYY-MM-DD")]:e)}})},O=function(){function t(e,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a=r.stateInitialValue,i=r.initValue;Object(l["a"])(this,t),this.field=void 0,this.stateInitialValue=void 0,this.initValue=void 0,this.filterConf=void 0,this.operatorMap={string:"icontains",mref:"in",datetime:"between",date:"between"},this.filterConf=n,this.field=e,this.stateInitialValue=a,this.initValue=i}return Object(s["a"])(t,[{key:"fieldPath",get:function(){var t=this.filterConf;return e.isObject(t)?t.name:t}},{key:"label",get:function(){var e=this.filterConf,t=this.field;return"string"!==typeof e&&e.displayName?e.displayName:t.displayName}},{key:"initialValue",get:function(){var t=this.field,n=this.filterConf,r=this.stateInitialValue,a=this.initValue;if(!e.isObject(n)||!n.choices)return t.choices?a?"number"===typeof t.choices[0][0]?parseInt(a,10):a:void 0:r||void 0}},{key:"getOperator",value:function(){var t=this.field,n=this.filterConf;if(e.isObject(n)){if(n.operator)return n.operator;if(n.choices)return"="}return t.choices?"in":this.getFieldOperator()}},{key:"getFieldOperator",value:function(){var e=this.field;return this.operatorMap[e.type]||"="}},{key:"commonComponent",get:function(){var t=this.field,n=this.filterConf;if(e.isObject(n)&&n.choices){var r=n.choices,a=r.model,i=r.key,o=void 0===i?Object(v["L"])(a):i,l=r.allow_null,s=void 0!==l&&l;return p.a.createElement(b["a"],{field:{name:t.name,type:"ref",ref:a},idfield:o,nullOption:s})}return t.choices?p.a.createElement(c["a"],{placeholder:"\u672a\u9009\u62e9",mode:"multiple",allowClear:!0},t.choices.map((function(e){var t=Object(u["a"])(e,2),n=t[0],r=t[1];return p.a.createElement(c["a"].Option,{key:n,value:n},r)}))):null}},{key:"component",get:function(){return p.a.createElement(o["a"],{allowClear:!0})}},{key:"id",get:function(){var e=this.field,t=this.fieldPath;return t||e.name}},{key:"getValue",value:function(e){var t=this.field,n=this.filterConf,r=t.refTo;return"string"!==typeof n&&n.operator&&(r=n.choices&&n.choices.idfield),Array.isArray(e)?e.map((function(e){return e[r]||e})):e&&e[r]||e}},{key:"render",value:function(){var e=this.component,t=this.commonComponent;return t||e}}]),t}(),j=function(e){Object(a["a"])(n,e);var t=Object(i["a"])(n);function n(){return Object(l["a"])(this,n),t.apply(this,arguments)}return Object(s["a"])(n,[{key:"initialValue",get:function(){return parseInt(this.stateInitialValue,10)}},{key:"component",get:function(){return p.a.createElement(c["a"],{placeholder:"\u672a\u9009\u62e9",allowClear:!0},p.a.createElement(c["a"].Option,{value:1},"\u662f"),p.a.createElement(c["a"].Option,{value:0},"\u5426"))}}]),n}(O),w=function(e){Object(a["a"])(n,e);var t=Object(i["a"])(n);function n(){return Object(l["a"])(this,n),t.apply(this,arguments)}return Object(s["a"])(n,[{key:"getFieldOperator",value:function(){return"in"}},{key:"component",get:function(){var e=this.field;return p.a.createElement(b["a"],{placeholder:"\u641c\u7d22".concat(e.displayName),field:Object(r["a"])(Object(r["a"])({},e),{},{type:"mref"}),allowUndefined:!0})}}]),n}(O),k=function(e){Object(a["a"])(n,e);var t=Object(i["a"])(n);function n(){return Object(l["a"])(this,n),t.apply(this,arguments)}return Object(s["a"])(n,[{key:"component",get:function(){var e=this.field;return p.a.createElement(b["a"],{placeholder:"\u641c\u7d22".concat(e.displayName),field:e})}}]),n}(O),E=function(e){Object(a["a"])(n,e);var t=Object(i["a"])(n);function n(){return Object(l["a"])(this,n),t.apply(this,arguments)}return Object(s["a"])(n,[{key:"component",get:function(){var e=this.field;return p.a.createElement(y,{date:"date"===e.type})}}]),n}(O),C=function(e){Object(a["a"])(n,e);var t=Object(i["a"])(n);function n(){return Object(l["a"])(this,n),t.apply(this,arguments)}return Object(s["a"])(n,[{key:"initialValue",get:function(){}},{key:"getFieldOperator",value:function(e){var t=this.field;if(t.primaryKey)return"icontains";if(e){var n=Object(u["a"])(e,2),r=n[0],a=n[1],i=function(e){return""===e||null===e};return i(r)?"<=":i(a)?">=":"between"}return"="}},{key:"getValue",value:function(e){if(e){var t=Object(u["a"])(e,2),n=t[0],r=t[1];if(null===n)return r;if(null===r)return n}return e}},{key:"component",get:function(){var e=this.field;return e.primaryKey?p.a.createElement(o["a"],{allowClear:!0}):p.a.createElement(_["a"],null)}}]),n}(O),x={bool:j,ref:w,oref:w,boref:w,mref:k,datetime:E,date:E,integer:C,decimal:C,float:C};function S(e,t,n){var r=t.split("."),a=e.fields.find((function(e){return e.name===r[0]}));if(!a)throw new Error("filter[ ".concat(t," ]\u914d\u7f6e\u9519\u8bef"));if(1===r.length)return a;if(!a)throw new Error("filter[ ".concat(t," ]\u914d\u7f6e\u9519\u8bef"));if(!a.ref)throw new Error("filter[ ".concat(t," ]\u914d\u7f6e\u9519\u8bef\uff0c\u627e\u4e0d\u5230\u5173\u8054\u5b57\u6bb5"));return S(n[a.ref],r.slice(1).join("."),n)}function F(t,n,r){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=a.initialValues,o=a.query,c=S(t[n],e.isObject(r)?r.name:r,t),u=x[c.type]||O;return new u(c,r,{stateInitialValue:null===i||void 0===i?void 0:i[c.name],initValue:null===o||void 0===o?void 0:o[c.name]})}var M=function(){function e(t){Object(l["a"])(this,e),this.dimension=void 0,this.component=function(e){var t=e.onChange,n=e.value;return p.a.createElement(d["a"].MonthPicker,{style:{width:"100%"},onChange:function(e){return t(e?h.a.utc(e.format("YYYY-MM")):void 0)},value:n&&h.a.utc(n)})},this.dimension=t}return Object(s["a"])(e,[{key:"getOperator",value:function(){return"="}},{key:"id",get:function(){return this.dimension.name}},{key:"label",get:function(){return this.dimension.display_name}},{key:"render",value:function(){var e=this.component;return p.a.createElement(e,null)}}]),e}(),P={TruncMonth:M};function A(e,t,n){if(!n.method){var r=S(e[t],n.field,e),o=x[r.type]||O,c=function(e){Object(a["a"])(r,e);var t=Object(i["a"])(r);function r(){return Object(l["a"])(this,r),t.apply(this,arguments)}return Object(s["a"])(r,[{key:"id",get:function(){return n.field}},{key:"label",get:function(){return n.display_name}}]),r}(o);return new c(r,n.field)}if(n.method in P){var u=P[n.method];return new u(n)}throw new Error("".concat(n.method," \u7c7b\u578b\u627e\u4e0d\u5230\u76f8\u5e94\u7684Filter"))}}).call(this,n("LvDl"))},flKx:function(e,t,n){"use strict";n("QV15");var r=n("DAsn"),a=n("fWQN"),i=n("mtLc"),o=n("yKVA"),c=n("879j"),u=n("q1tI"),l=n.n(u),s=n("jfUH"),d=function(e){Object(o["a"])(n,e);var t=Object(c["a"])(n);function n(){return Object(a["a"])(this,n),t.apply(this,arguments)}return Object(i["a"])(n,[{key:"getComponent",value:function(){var e=this.props,t=e.currentActionObject,n=e.currentActionParams,r=void 0===n?{}:n,a=e.currentObject,i=e.model,o=e.context,c=t.component;return c?c({model:i,currentActionObject:t,currentObject:a,currentActionParams:r,context:o}):l.a.createElement(u["Fragment"],null)}},{key:"getWidth",value:function(){var e=this.props.currentActionObject.width,t="50%";return e||t}},{key:"render",value:function(){var e=this.props,t=e.visible,n=e.context,a=e.currentObject,i=e.model;return l.a.createElement(r["a"],{width:this.getWidth(),onClose:n.hideDrawer,visible:t,key:a&&Object(s["K"])(a,i)},this.getComponent())}}]),n}(u["PureComponent"]);t["a"]=d},gMH0:function(e,t,n){e.exports={"action-danger-btn":"action-danger-btn___1w2WB","action-danger":"action-danger___7GBMh"}},gyLe:function(e,t,n){e.exports=n.p+"static/logo.3ac90302.png"},hJ9C:function(e,t,n){"use strict";var r=n("Utjr");t["a"]=Object(r["d"])((function(){return Promise.all([n.e(36),n.e(27)]).then(n.bind(null,"NKAz"))}),{loading:"\u52a0\u8f7d\u5bcc\u6587\u672c\u7f16\u8f91\u5668..."})},hNBN:function(e,t,n){"use strict";(function(e){var r=n("tJVT"),a=n("q1tI"),i=n.n(a),o=n("Utjr"),c=Object(o["d"])((function(){return n.e(34).then(n.t.bind(null,"ovOe",7))}),{loading:"\u52a0\u8f7dJSON\u7f16\u8f91\u5668..."});function u(t){var n=Object(a["useState"])("\u60a8\u7684json\u4e0d\u5408\u6cd5"),o=Object(r["a"])(n,2),u=o[0],l=o[1],s=function(e){var n=t.onChange;n(JSON.stringify(e.updated_src))},d=t.value,f=t.isEdit,p=void 0===f||f,m=t.isAdd,h=void 0===m||m,b=t.isDelete,v=void 0===b||b;return Object(a["useEffect"])((function(){if(e.isObject(d))l(d);else try{l(JSON.parse(d))}catch(t){l("\u60a8\u7684json\u4e0d\u5408\u6cd5")}}),[d]),i.a.createElement(c,{src:u,iconStyle:"square",onEdit:!!p&&s,onAdd:!!h&&s,onDelete:!!v&&s,collapsed:1})}t["a"]=u}).call(this,n("LvDl"))},iXby:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return l}));var r=n("k1fw"),a=n("q1tI"),i=n.n(a),o=n("jfUH"),c=n("VW+w"),u=n("JN3n");function l(t){var n,a=t.Schemas,l=t.Admins,s=t.model,d=t.field,f=t.value,p=t.instance,m=t.displayField,h=Object(o["kb"])(),b=d.refField,v=d.type,_=d.ref,g=d.refTo;if(!f&&Object(o["C"])(v))return"";if(Object(o["C"])(v)){var y=a[_].titleField;return f[y]}var O=e.isObject(m)?m:{},j=O.listView,w=e.isObject(m)?m:{},k=w.params,E=void 0===k?{}:k;if(null!==(n=E)&&void 0!==n&&n.inherit&&(E=Object(r["a"])(Object(r["a"])({},Object(o["H"])(l,_,"list")),E)),e.isEmpty(E))if(j)E=Object(o["H"])(l,_,"list",j);else{var C=Object(o["H"])(l,s,"detail"),x=C.detail;if(x){var S,F=null===x||void 0===x||null===(S=x.sections)||void 0===S?void 0:S.find((function(e){return e.fields[0]===m}));null!==F&&void 0!==F&&F.display&&(E={display:F.display,inlineFormFields:F.display,inlineActions:Object(c["inlineActionsPreprocess"])(F.inlineActions)})}}return e.isEmpty(E)&&(E=Object(o["H"])(l,_,"list")),E=Object(r["a"])(Object(r["a"])({},o["E"]),E),i.a.createElement("div",{style:h?{marginLeft:-16,marginRight:-16}:{}},i.a.createElement(u["a"],{key:"".concat(_,":").concat(b,":").concat(p[g]),refModel:_,refField:b,refValue:p[g],refObject:p,tableConf:E}))}}).call(this,n("LvDl"))},jVA4:function(e,t,n){"use strict";var r=n("PpiC"),a=n("fWQN"),i=n("mtLc"),o=n("yKVA"),c=n("879j"),u=n("q1tI"),l=n.n(u),s=n("G9e4"),d=function(e){Object(o["a"])(n,e);var t=Object(c["a"])(n);function n(){return Object(a["a"])(this,n),t.apply(this,arguments)}return Object(i["a"])(n,[{key:"render",value:function(){var e=this.props,t=e.editing,n=e.field,a=e.formFields,i=Object(r["a"])(e,["editing","field","formFields"]);return l.a.createElement(s["a"].Consumer,null,(function(e){return l.a.createElement("td",i,t?e(n,a):i.children)}))}}]),n}(u["PureComponent"]);t["a"]=d},jfUH:function(module,__webpack_exports__,__webpack_require__){"use strict";(function(_){__webpack_require__.d(__webpack_exports__,"L",(function(){return pkField})),__webpack_require__.d(__webpack_exports__,"K",(function(){return pk})),__webpack_require__.d(__webpack_exports__,"l",(function(){return getFieldsFromSchemaByPath})),__webpack_require__.d(__webpack_exports__,"I",(function(){return parseFieldNames})),__webpack_require__.d(__webpack_exports__,"O",(function(){return renderTemplate})),__webpack_require__.d(__webpack_exports__,"i",(function(){return evalCondition})),__webpack_require__.d(__webpack_exports__,"s",(function(){return getSchema})),__webpack_require__.d(__webpack_exports__,"t",(function(){return getSchemaField})),__webpack_require__.d(__webpack_exports__,"o",(function(){return getModelDisplayName})),__webpack_require__.d(__webpack_exports__,"w",(function(){return getToField})),__webpack_require__.d(__webpack_exports__,"Q",(function(){return toField})),__webpack_require__.d(__webpack_exports__,"c",(function(){return checkParent})),__webpack_require__.d(__webpack_exports__,"k",(function(){return getFieldValue})),__webpack_require__.d(__webpack_exports__,"n",(function(){return getIcon})),__webpack_require__.d(__webpack_exports__,"q",(function(){return getModelPermissions})),__webpack_require__.d(__webpack_exports__,"f",(function(){return copy})),__webpack_require__.d(__webpack_exports__,"G",(function(){return matchAndConditions})),__webpack_require__.d(__webpack_exports__,"P",(function(){return singleRefTypes})),__webpack_require__.d(__webpack_exports__,"C",(function(){return isSingleRef})),__webpack_require__.d(__webpack_exports__,"D",(function(){return isSingleRefField})),__webpack_require__.d(__webpack_exports__,"z",(function(){return isMultiRefField})),__webpack_require__.d(__webpack_exports__,"N",(function(){return refTypes})),__webpack_require__.d(__webpack_exports__,"A",(function(){return isRef})),__webpack_require__.d(__webpack_exports__,"B",(function(){return isRefField})),__webpack_require__.d(__webpack_exports__,"r",(function(){return getRefFieldAndPk})),__webpack_require__.d(__webpack_exports__,"F",(function(){return mapShowIfID})),__webpack_require__.d(__webpack_exports__,"x",(function(){return getValueFromPath})),__webpack_require__.d(__webpack_exports__,"j",(function(){return getFieldDef})),__webpack_require__.d(__webpack_exports__,"m",(function(){return getFieldsObjValue})),__webpack_require__.d(__webpack_exports__,"h",(function(){return ddQRcode})),__webpack_require__.d(__webpack_exports__,"v",(function(){return getThumb})),__webpack_require__.d(__webpack_exports__,"M",(function(){return progressMessage})),__webpack_require__.d(__webpack_exports__,"Ab",(function(){return withRoute})),__webpack_require__.d(__webpack_exports__,"nb",(function(){return useParams})),__webpack_require__.d(__webpack_exports__,"gb",(function(){return useLocation})),__webpack_require__.d(__webpack_exports__,"a",(function(){return DvaContextConnect})),__webpack_require__.d(__webpack_exports__,"bb",(function(){return useDispatcher})),__webpack_require__.d(__webpack_exports__,"Y",(function(){return useContentDispatcher})),__webpack_require__.d(__webpack_exports__,"vb",(function(){return useSelector})),__webpack_require__.d(__webpack_exports__,"wb",(function(){return useSettings})),__webpack_require__.d(__webpack_exports__,"W",(function(){return useBSMSettings})),__webpack_require__.d(__webpack_exports__,"V",(function(){return useBSMSetting})),__webpack_require__.d(__webpack_exports__,"Z",(function(){return useCurrentUser})),__webpack_require__.d(__webpack_exports__,"ob",(function(){return usePermissions})),__webpack_require__.d(__webpack_exports__,"ib",(function(){return useModelPermissions})),__webpack_require__.d(__webpack_exports__,"ub",(function(){return useSchemas})),__webpack_require__.d(__webpack_exports__,"rb",(function(){return useSchema})),__webpack_require__.d(__webpack_exports__,"tb",(function(){return useSchemaFields})),__webpack_require__.d(__webpack_exports__,"T",(function(){return useAdmins})),__webpack_require__.d(__webpack_exports__,"U",(function(){return useAdminsWithoutDefault})),__webpack_require__.d(__webpack_exports__,"S",(function(){return useAdmin})),__webpack_require__.d(__webpack_exports__,"db",(function(){return useFieldPermissions})),__webpack_require__.d(__webpack_exports__,"qb",(function(){return usePkField})),__webpack_require__.d(__webpack_exports__,"pb",(function(){return usePk})),__webpack_require__.d(__webpack_exports__,"yb",(function(){return useTitleField})),__webpack_require__.d(__webpack_exports__,"xb",(function(){return useTitle})),__webpack_require__.d(__webpack_exports__,"sb",(function(){return useSchemaField})),__webpack_require__.d(__webpack_exports__,"d",(function(){return connectHook})),__webpack_require__.d(__webpack_exports__,"e",(function(){return connectShouldShow})),__webpack_require__.d(__webpack_exports__,"X",(function(){return useCheckManaged})),__webpack_require__.d(__webpack_exports__,"jb",(function(){return useModelsData})),__webpack_require__.d(__webpack_exports__,"u",(function(){return getServer})),__webpack_require__.d(__webpack_exports__,"zb",(function(){return useUpload})),__webpack_require__.d(__webpack_exports__,"p",(function(){return getModelFieldsPermission})),__webpack_require__.d(__webpack_exports__,"J",(function(){return permissionConvert})),__webpack_require__.d(__webpack_exports__,"E",(function(){return listViewAttributes})),__webpack_require__.d(__webpack_exports__,"H",(function(){return modelAdminForView})),__webpack_require__.d(__webpack_exports__,"hb",(function(){return useModelAdminForView})),__webpack_require__.d(__webpack_exports__,"g",(function(){return createLightContext})),__webpack_require__.d(__webpack_exports__,"b",(function(){return LightningContext})),__webpack_require__.d(__webpack_exports__,"fb",(function(){return useLightningConfig})),__webpack_require__.d(__webpack_exports__,"eb",(function(){return useGetFieldDef})),__webpack_require__.d(__webpack_exports__,"cb",(function(){return useDisplayPathGetter})),__webpack_require__.d(__webpack_exports__,"ab",(function(){return useDebounce})),__webpack_require__.d(__webpack_exports__,"kb",(function(){return useOnMobile})),__webpack_require__.d(__webpack_exports__,"mb",(function(){return useOnWideScreen})),__webpack_require__.d(__webpack_exports__,"lb",(function(){return useOnNarrowScreen})),__webpack_require__.d(__webpack_exports__,"R",(function(){return useA2SH})),__webpack_require__.d(__webpack_exports__,"y",(function(){return highlightKeyword}));var antd3_es_message_style__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__("GPKB"),antd3_es_message__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__("mFAc"),_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_classCallCheck__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__("fWQN"),_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_createClass__WEBPACK_IMPORTED_MODULE_3__=__webpack_require__("mtLc"),_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_extends__WEBPACK_IMPORTED_MODULE_4__=__webpack_require__("0Owb"),_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_objectWithoutProperties__WEBPACK_IMPORTED_MODULE_5__=__webpack_require__("PpiC"),_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_asyncToGenerator__WEBPACK_IMPORTED_MODULE_6__=__webpack_require__("9og8"),_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_slicedToArray__WEBPACK_IMPORTED_MODULE_7__=__webpack_require__("tJVT"),_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_toArray__WEBPACK_IMPORTED_MODULE_8__=__webpack_require__("Pv/L"),_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_objectSpread2__WEBPACK_IMPORTED_MODULE_9__=__webpack_require__("k1fw"),_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_regenerator__WEBPACK_IMPORTED_MODULE_10__=__webpack_require__("WmNS"),_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_regenerator__WEBPACK_IMPORTED_MODULE_10___default=__webpack_require__.n(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_regenerator__WEBPACK_IMPORTED_MODULE_10__),react__WEBPACK_IMPORTED_MODULE_11__=__webpack_require__("q1tI"),react__WEBPACK_IMPORTED_MODULE_11___default=__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_11__),dva__WEBPACK_IMPORTED_MODULE_12__=__webpack_require__("/MKj"),memoize_one__WEBPACK_IMPORTED_MODULE_13__=__webpack_require__("Wwog"),react_router_dom__WEBPACK_IMPORTED_MODULE_14__=__webpack_require__("Ty5D"),_bsm_service__WEBPACK_IMPORTED_MODULE_15__=__webpack_require__("mmaM"),DEFAULT_PK="id",pkField=function(e,t){if(e){var n=t||window.g_app._store.getState(),r=n.content.schemas;if(_.isEmpty(r)||_.isEmpty(r[e]))return DEFAULT_PK;var a=r[e].fields.find((function(e){return e.primaryKey}));return a?a.name:DEFAULT_PK}return DEFAULT_PK};function pk(e,t){var n=pkField(t);return n?e[n]:e[DEFAULT_PK]}function getFieldsFromSchemaByPath(e,t,n){var r=n,a=[];return t.split(".").forEach((function(n){if(!n)throw new Error("\u8def\u5f84".concat(t,"\u4e0d\u6b63\u786e"));var i=e[r].fields.find((function(e){return e.name===n}));if(!i)throw new Error("\u8def\u5f84 [".concat(t,"] \u4e0d\u6b63\u786e\uff0cmodel [").concat(r,"] \u4e2d\u627e\u4e0d\u5230 [").concat(n,"]"));a.push(i),r=i.ref})),a}function parseFieldNames(e){var t=/\$\{[^}]+\}/g,n=e.match(t);if(!n)return[];var r=n.map((function(e){return e.replace("${","").replace("}","")}));return r}function renderTemplate(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0;return e.replace(/\$\{(\w+)\}/g,(function(e,n){var r;return null!==(r=t(n))&&void 0!==r?r:""}))}function evalCondition(statement,resolver){var showExpress=statement.replace(/\$\{([\w\.]+)\}/g,(function(e,t){return JSON.stringify(resolver(t))}));try{return eval("(".concat(showExpress,")"))}catch(_unused){return}}function getSchema(e,t){var n=window.g_app._store.getState(),r=n.content.schemas,a=t||r;if(!(e in a)){var i=new Error("\u627e\u4e0d\u5230\u6a21\u578b\uff1a".concat(e));return console.error(i),null}return a[e]}function getSchemaField(e,t,n){var r=getSchema(e,n);if(r){var a=r.fields.find((function(e){return e.name===t.split(".")[0]}));return a?t.includes(".")&&a.ref?getSchemaField(a.ref,t.split(".").slice(1).join("."),n):a:null}return null}function getModelDisplayName(e,t){var n=getSchema(e,t);return n&&n.displayName}function getAdmin(e){var t=window.g_app._store.getState(),n=t.content.adminConfig;if(!(e in n)){var r=new Error("\u627e\u4e0d\u5230Admin\u914d\u7f6e\uff1a".concat(e));return console.error(r),null}return n[e]}function getUserInfo(){var e=window.g_app._store.getState(),t=e.user.currentUser;return t}var getToField=function(e,t,n){var r=getSchemaField(e,t,n);return r&&r.refTo};function toField(e,t,n,r){return e[getToField(t,n,r)]}var sortList=function(e,t,n,r){var a=e[r],i=t[r],o=a<i||a===i&&e.id<t.id;return n.map((function(n){var a=Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_objectSpread2__WEBPACK_IMPORTED_MODULE_9__["a"])({},n);return n.parent!==t.parent||(n[r]>=i&&n.id!==e.id&&(n[r]===i?n.id>t.id?a[r]+=2:n.id!==t.id||o||(a[r]+=2):a[r]+=2),n.id===e.id&&(a[r]=i+1)),a}))},getAllData=Object(memoize_one__WEBPACK_IMPORTED_MODULE_13__["a"])((function(e){var t=[];function n(e){e.forEach((function(e){t.push(e),_.isEmpty(e.children)||n(e.children)}))}return n(e),t})),checkParent=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],r=t.parent,a=getAllData(n),i=_.keyBy(a,"id"),o=0,c=!1;while(r&&o<a.length){if(o+=1,r===e.id)return c=!0,!0;r=i["".concat(r)].parent}return c},getFieldValue=function e(t,n){return _.isEmpty(n)?n:t.includes(".")?_.isArray(n)?n.map((function(n){return e(t.split(".").slice(1).join("."),n[t.split(".")[0]])})):e(t.split(".").slice(1).join("."),n[t.split(".")[0]]):_.isArray(n)?n.map((function(e){return e[t]})):n[t]},getIcon=Object(memoize_one__WEBPACK_IMPORTED_MODULE_13__["a"])((function(e){var t=e.split("__"),n=t[0],r=t[1],a=t[2],i={};return n&&(i.type=n),r&&(i.theme=r),"twoTone"===r&&a&&(i.twoToneColor=a),i})),getModelPermissions=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:window.g_app._store.getState().user.currentUser.permissions;return t?t.filter((function(t){return t.endsWith("_".concat(e))})).map((function(e){return e.split("_")[0]})):[]};function getTypeValue(e,t){var n={False:!1,True:!0},r={string:t,bool:t in n&&n[t]},a=e in r?r[e]:t;return a}function copy(e){var t=document.createElement("textarea");t.innerText=e,t.innerHTML=t.innerHTML.replace(/<br>/g,"\n"),document.body.appendChild(t),t.select(),document.execCommand("copy"),t.remove()}function matchCondition(e,t,n,r){var a=e.field,i=e.operator,o=void 0===i?"=":i,c=e.value,u=t[a];if(_.isObject(u)){var l,s,d=null===(l=n[r])||void 0===l||null===(s=l.fields)||void 0===s?void 0:s.find((function(e){return e.name===a}));return _.isArray(u)?(u=u.map((function(e){return _.isObject(e)?pk(e,d.ref):e})),u.reduce((function(e,t){return e||c.includes(t)}),!1)):(u=pk(u,d.ref),null===c||void 0===c?void 0:c.includes(u))}return _.isArray(c)?c.includes(u):"="===o?u===c:">"===o?u>c:"<"===o?u<c:">="===o?u>=c:"<="===o&&u<=c}function matchAndConditions(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0;return e.reduce((function(e,a){return!1!==e&&(e&&matchCondition(a,t,n,r))}),!0)}function getModelsData(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,n=[];return Object.keys(e).forEach((function(r){var a=r.split("__");if(t(r)){var i=n.find((function(e){return e.value===a[0]}));i?i.children.push({value:a[1],label:"".concat(a[1],"(").concat(e[r].displayName,")")}):n.push({value:a[0],label:a[0],children:[{value:a[1],label:"".concat(a[1],"(").concat(e[r].displayName,")")}]})}})),n}var singleRefTypes=["ref","oref","boref"],isSingleRef=function(e){return singleRefTypes.includes(e)},isSingleRefField=function(e){return isSingleRef(e.type)},multiRefTypes=["mref","bref"],isMultiRef=function(e){return multiRefTypes.includes(e)},isMultiRefField=function(e){return isMultiRef(e.type)},refTypes=singleRefTypes.concat(multiRefTypes),isRef=function(e){return refTypes.includes(e)},isRefField=function(e){return isRef(null===e||void 0===e?void 0:e.type)};function getRefFieldAndPk(e,t,n,r){var a=getSchemaField(e,t,r);if(!isSingleRefField(a))return{id:null,value:null,schemaField:a};var i=getFieldValue(t,n)||{},o=i[pkField(a.ref)];return{id:o,value:i,schemaField:a}}function mapShowIfID(e,t,n){return e.map((function(e){var r=e,a=getSchemaField(t,r.field,n);return _.isArray(r.value)&&(r.value=r.value.map((function(e){return pk(e,a.ref)}))),r}))}function getValueFromPath(e,t){if(!t)return null;if(!e)return"";var n=e.split("."),r=Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_toArray__WEBPACK_IMPORTED_MODULE_8__["a"])(n),a=r[0],i=r.slice(1),o=t[a];return i.length?getValueFromPath(i.join("."),o):o}function getFieldDef(e,t,n){if(n[e]){var r=n[e].fields.find((function(e){return e.name===t.split(".")[0]}));return t.includes(".")?getFieldDef(r.ref,t.split(".").slice(1).join("."),n):r}}function getFieldsObjValue(e,t){var n=getFieldValue(e,t);return n?n.flat(e.length).filter((function(e){return void 0!==e})):[]}function ddQRcode(){var e=window.g_app._store.getState(),t=e.bsmSetting,n=t.dingding_flexible_login_redirect_uri,r=t.dingding_flexible_login_app_key,a=encodeURIComponent(n),i="https://oapi.dingtalk.com/connect/qrconnect?appid=".concat(r,"&response_type=code&scope=snsapi_login&state=STATE&redirect_uri=").concat(a);window.location.href=i}var thumbHandler=[],registerThumbHandler=function(e){thumbHandler.push(e)},getThumb=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.mode,r=void 0===n?"fill":n,a=t.width,i=void 0===a?100:a,o=t.height,c=void 0===o?100:o,u=t.uploadProvider,l=void 0===u?void 0:u;if(null===e||void 0===e)return e;for(var s=_.isString(e)?_.split(e,"#"):[e],d=Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_slicedToArray__WEBPACK_IMPORTED_MODULE_7__["a"])(s,1),f=d[0],p=0;p<thumbHandler.length;p+=1)try{var m=thumbHandler[p](f,{width:i,height:c,uploadProvider:l});if(m)return m}catch(b){console.error(b,"thumbHandler error")}if(!1===l)return f;var h={cos:"".concat(f,"?imageView2/").concat("lfit"===r?2:1,"/w/").concat(i,"/h/").concat(c),oss:"".concat(f,"?x-oss-process=image/resize,m_").concat(r,",h_").concat(c,",w_").concat(i)};return h[l]?h[l]:f.includes(".myqcloud.com")?h.cos:f.includes(".aliyuncs.com")?h.oss:f};function progressMessage(e,t){return _progressMessage.apply(this,arguments)}function _progressMessage(){return _progressMessage=Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_asyncToGenerator__WEBPACK_IMPORTED_MODULE_6__["a"])(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_regenerator__WEBPACK_IMPORTED_MODULE_10___default.a.mark((function e(t,n){var r,a,i,o,c,u,l;return _home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_regenerator__WEBPACK_IMPORTED_MODULE_10___default.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=n.title,a=n.key,i=n.success,o=n.error,c=_.isString(r)?r:"",u=antd3_es_message__WEBPACK_IMPORTED_MODULE_1__["a"].loading({content:"".concat(c,"\u6267\u884c\u4e2d"),key:a,duration:0}),e.prev=3,e.next=6,t;case 6:return l=e.sent,i?(u(),i(l)):antd3_es_message__WEBPACK_IMPORTED_MODULE_1__["a"].success({content:_.isString(l)?l:"".concat(c,"\u64cd\u4f5c\u6210\u529f"),key:a}),e.abrupt("return",l);case 11:throw e.prev=11,e.t0=e["catch"](3),console.error(e.t0),o?(u(),o(e.t0)):antd3_es_message__WEBPACK_IMPORTED_MODULE_1__["a"].error({content:_.isString(e.t0)?e.t0:"".concat(c,"\u64cd\u4f5c\u5931\u8d25"),key:a}),e.t0;case 16:case"end":return e.stop()}}),e,null,[[3,11]])}))),_progressMessage.apply(this,arguments)}var RouteContext=Object(react__WEBPACK_IMPORTED_MODULE_11__["createContext"])({match:{params:{}},location:{query:""}}),RouteProvider=Object(react_router_dom__WEBPACK_IMPORTED_MODULE_14__["n"])((function(e){var t=e.match,n=e.history,r=e.location,a=e.children;return react__WEBPACK_IMPORTED_MODULE_11___default.a.createElement(RouteContext.Provider,{value:{match:t,history:n,location:r}},a)})),withRoute=function(e){return function(t){return react__WEBPACK_IMPORTED_MODULE_11___default.a.createElement(RouteProvider,null,react__WEBPACK_IMPORTED_MODULE_11___default.a.createElement(e,t))}},useRouteContext=function(){return Object(react__WEBPACK_IMPORTED_MODULE_11__["useContext"])(RouteContext)},useParams=function(){return useRouteContext().match.params},useLocation=function(){return useRouteContext().location},DvaContext=Object(react__WEBPACK_IMPORTED_MODULE_11__["createContext"])({}),DvaContextConnect=function(e){return Object(dva__WEBPACK_IMPORTED_MODULE_12__["c"])((function(e){return{_dvaState:e}}))((function(t){var n=t._dvaState,r=t.dispatch,a=Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_objectWithoutProperties__WEBPACK_IMPORTED_MODULE_5__["a"])(t,["_dvaState","dispatch"]);return react__WEBPACK_IMPORTED_MODULE_11___default.a.createElement(DvaContext.Provider,{value:Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_objectSpread2__WEBPACK_IMPORTED_MODULE_9__["a"])(Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_objectSpread2__WEBPACK_IMPORTED_MODULE_9__["a"])({},n),{},{$$dispatch$$:r})},react__WEBPACK_IMPORTED_MODULE_11___default.a.createElement(e,a))}))},useDispatcher=function(){return Object(react__WEBPACK_IMPORTED_MODULE_11__["useContext"])(DvaContext).$$dispatch$$},useContentDispatcher=function(e){var t=useDispatcher();return Object(react__WEBPACK_IMPORTED_MODULE_11__["useCallback"])((function(n){return t({type:"content/".concat(e),payload:n})}),[e,t])},useSelector=function(e){return e(Object(react__WEBPACK_IMPORTED_MODULE_11__["useContext"])(DvaContext))},useSettings=function(e){return useSelector((function(t){var n=t.setting;return null===n||void 0===n?void 0:n[e]}))},useBSMSettings=function(){return useSelector((function(e){var t=e.bsmSetting;return t}))},useBSMSetting=function(e){var t;return null===(t=useBSMSettings())||void 0===t?void 0:t[e]},useCurrentUser=function(){return useSelector((function(e){var t=e.user.currentUser;return t}))},usePermissions=function(){var e;return null===(e=useCurrentUser())||void 0===e?void 0:e.permissions},useModelPermissions=function(e){var t=usePermissions();return t&&getModelPermissions(e,t)},useModelList=function(e){return useSelector((function(t){var n,r=t.content.data;return null===(n=r[e])||void 0===n?void 0:n.list}))},useSchemas=function(){return useSelector((function(e){var t=e.content.schemas;return t}))},useSchema=function(e){return useSchemas()[e]},useSchemaFields=function(e){var t;return null===(t=useSchema(e))||void 0===t?void 0:t.fields},AdminContext=react__WEBPACK_IMPORTED_MODULE_11___default.a.createContext({}),ExtendAdmin=AdminContext.Provider,useAdmins=function(){var e=useSelector((function(e){var t=e.content.adminConfig;return t})),t=Object(react__WEBPACK_IMPORTED_MODULE_11__["useContext"])(AdminContext);return Object(react__WEBPACK_IMPORTED_MODULE_11__["useMemo"])((function(){return _.isFunction(t)?t(e):_.merge(e,t)}),[e,t])},useAdminsWithoutDefault=function(){return useSelector((function(e){var t=e.content.adminWithoutDefault;return t}))},useAdmin=function(e){return useAdmins()[e]},useFieldPermissions=function(e){var t;return(null===(t=useAdmin(e))||void 0===t?void 0:t.field_permissions)||[]},usePkField=function(e){return pkField(e,Object(react__WEBPACK_IMPORTED_MODULE_11__["useContext"])(DvaContext))},usePk=function(e){var t=usePkField(e);return function(e){return t?e[t]:e[DEFAULT_PK]}},useTitleField=function(e){var t;return null===(t=useSchema(e))||void 0===t?void 0:t.titleField},useTitle=function(e){var t=useTitleField(e);return function(e){return e[t]}},useFieldsFromSchemaByPath=function(e){var t=useSchemas();return function(n){return getFieldsFromSchemaByPath(t,n,e)}},useSchemaField=function(e){var t=useSchemas();return function(n){return getSchemaField(e,n,t)}},connectHook=function(e){return function(t){return function(n){return react__WEBPACK_IMPORTED_MODULE_11___default.a.createElement(t,Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_extends__WEBPACK_IMPORTED_MODULE_4__["a"])({},e(n),n))}}},connectShouldShow=function(e){return function(t){return function(n){return n[e]?react__WEBPACK_IMPORTED_MODULE_11___default.a.createElement(t,n):null}}},BSM_EXPORT_APPS=["api_db","contenttypes","meta","bsm_config","auth","admin","api_basebone","guardian","trigger_core","db_tool","chart","member","shield"],checkModelManaged=function(e){var t=function(t){return e.startsWith("".concat(t,"__"))};return!BSM_EXPORT_APPS.some(t)},useCheckManaged=function(e){return checkModelManaged(e,useModelList("meta__app"))};function useModelsData(){var e=useSchemas();return _.isEmpty(e)?[]:getModelsData(e,useCheckManaged)}function getRanStr(){var e=(+new Date).toString(36)+Math.random().toString(36).slice(2);return e}function getOss(e){return{host:e.host,getUrl:function(t){return"".concat(e.host,"/").concat(e.dir).concat("/"===e.dir.substring(e.dir.length-1)?"":"/").concat(t)},getFormData:function(t){var n=e.accessid,r=e.policy,a=e.signature,i=e.dir,o="".concat(i).concat("/"===i.substring(i.length-1)?"":"/").concat(t);return{OSSAccessKeyId:n,policy:r,Signature:a,key:o}}}}function getCos(e){return{host:e.host,getUrl:function(t){return"".concat(e.host,"/").concat(e.dir).concat("/"===e.dir.substring(e.dir.length-1)?"":"/").concat(t)},getFormData:function(t){var n=e.policy,r=e.q_ak,a=e.key_time,i=e.dir,o=e.signature,c="".concat(i).concat("/"===i.substring(i.length-1)?"":"/").concat(t);return{key:c,policy:n,"q-sign-algorithm":"sha1","q-ak":r,"q-key-time":a,"q-signature":o}}}}function getFileStorage(e){return{host:"/basebone/storage/upload ",getUrl:function(e){return"/basebone/storage/file/".concat(e)},getFormData:function(t){return{key:t,policy:e.policy}}}}var fileToName=function(e){return"".concat(e.uid,"/").concat(e.name)};function getServer(e,t){var n={file_storage:getFileStorage,oss:getOss,cos:getCos},r=n[e](t);return{getUrl:function(t){return"".concat(r.getUrl(fileToName(t)),"#").concat(e)},getFormData:function(e){return r.getFormData(fileToName(e))},host:r.host}}function useUpload(){var e=Object(react__WEBPACK_IMPORTED_MODULE_11__["useState"])({}),t=Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_slicedToArray__WEBPACK_IMPORTED_MODULE_7__["a"])(e,2),n=t[0],r=n.provider,a=Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_objectWithoutProperties__WEBPACK_IMPORTED_MODULE_5__["a"])(n,["provider"]),i=t[1],o=r?getServer(r,a):{host:""},c=o.getUrl,u=o.getFormData,l=o.host;return{init:function(){return Object(_bsm_service__WEBPACK_IMPORTED_MODULE_15__["getUploadToken"])().then(i)},uploadHost:l,formData:u,getUrl:c}}function getModelFieldsPermission(e){var t,n,r=getSchema(e),a=(null===(t=getAdmin(e))||void 0===t?void 0:t.field_permissions)||[],i=getUserInfo(),o={};return null===r||void 0===r||null===(n=r.fields)||void 0===n||n.forEach((function(e){o[e.name]={read:!0,write:!0}})),a.forEach((function(e){i.groups.includes(e.group)&&(o[e.field]=e)})),o}function permissionConvert(e){var t=e.split(".")[1].split("_")[0];return["view","change","add","delete"].includes(t)&&e.split(".")[1].split("_").length>=2?"".concat(t,"_").concat(e.split(".")[0],"__").concat(e.split(".")[1].split("_").slice(1).join("_")):"".concat(e.split(".")[1],"__").concat(e.split(".")[0])}var viewKey={list:"listViews",detail:"detailViews",form:"formViews",export:"exportViews",import:"importViews"},listViewAttributes={display:[],filter:[],modalForm:!0,modalDetail:!1,tableActions:[],actions:[],inlineActions:[],sortable:[],orderBy:[],filterLayout:"default",listStyle:"",defaultFilter:[],listTitle:"",display_in_tree:!1,maxInlineActions:3,tableProps:{}},detailViewAttributes={detailFields:[],details:[],detailTitle:"",detailLayout:""},formViewAttributes={formFields:[],formLayout:"",inline_form_fields:[],formTitle:""},defaultAttributesForView={list:listViewAttributes,form:formViewAttributes,detail:detailViewAttributes};function modelAdminForView(e,t,n,r){var a=e[t]||{};if(!r)return a;var i=viewKey[n];if(a[i]&&a[i][r]){var o=a[i][r]||{};if(!0===o.inherit)return Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_objectSpread2__WEBPACK_IMPORTED_MODULE_9__["a"])(Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_objectSpread2__WEBPACK_IMPORTED_MODULE_9__["a"])({},a),o);var c=defaultAttributesForView[n];return Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_objectSpread2__WEBPACK_IMPORTED_MODULE_9__["a"])(Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_objectSpread2__WEBPACK_IMPORTED_MODULE_9__["a"])(Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_objectSpread2__WEBPACK_IMPORTED_MODULE_9__["a"])({},a),c),o)}return a||{}}var useModelAdminForView=function(e,t,n){return modelAdminForView(useAdmins(),e,t,n)},Ctx=function(){function e(){Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_classCallCheck__WEBPACK_IMPORTED_MODULE_2__["a"])(this,e),this.displayWidgets={},this.displayWidgetName={},this.displayWidgetMapping=[],this.formWidgets={},this.formWidgetNames={},this.formTypeMapWidget=[],this.inlineActions={},this.tableActions={}}return Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_createClass__WEBPACK_IMPORTED_MODULE_3__["a"])(e,[{key:"displayWidget",value:function(e,t){var n=this,r=t.displayName,a=t.type;if(!e)throw new Error("\u6ce8\u518c\u663e\u793a\u7ec4\u4ef6name\u662f\u5fc5\u586b\u7684");return function(t){t&&n.addDisplayWidget(e,t,r,a)}}},{key:"formWidget",value:function(e,t){var n=this,r=t.displayName,a=t.type;if(!e)throw new Error("\u6ce8\u518c\u8868\u5355\u7ec4\u4ef6\u7684name\u662f\u5fc5\u586b\u7684");return function(t){t&&n.addFormWidget(e,t,r,a)}}},{key:"inlineAction",value:function(e,t){this.inlineActions[e]=t}},{key:"tableAction",value:function(e,t){this.tableActions[e]=t}},{key:"addDisplayWidget",value:function(e,t,n,r){this.displayWidgets[e]=t,this.displayWidgetName[e]=n||e,r&&this.displayWidgetMapping.push([e,r])}},{key:"addFormWidget",value:function(e,t,n,r){this.formWidgets[e]=t,this.formWidgetNames[e]=n||e,r&&this.formTypeMapWidget.push([e,r])}}]),e}();function createLightContext(){return new Ctx}var LightningContext=Object(react__WEBPACK_IMPORTED_MODULE_11__["createContext"])(createLightContext());function useLightningConfig(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:function(e){return e};return e(Object(react__WEBPACK_IMPORTED_MODULE_11__["useContext"])(LightningContext))}function useGetFieldDef(e){var t=useSchemas();return Object(react__WEBPACK_IMPORTED_MODULE_11__["useCallback"])((function(n){return getFieldDef(e,n,t)}),[e,t])}function useGetFieldsFromSchemaByPath(e){var t=useSchemas();return function(n){return getFieldsFromSchemaByPath(t,n,e)}}function useDisplayPathGetter(e){var t=useGetFieldsFromSchemaByPath(e);return function(e){return t(e).map((function(e){return e.displayName}))}}var useDebounce=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.debounceTimeout,a=void 0===r?500:r,i=react__WEBPACK_IMPORTED_MODULE_11___default.a.useState(!1),o=Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_slicedToArray__WEBPACK_IMPORTED_MODULE_7__["a"])(i,2),c=o[0],u=o[1],l=react__WEBPACK_IMPORTED_MODULE_11___default.a.useRef(0),s=react__WEBPACK_IMPORTED_MODULE_11___default.a.useMemo((function(){var n=function(){var n=Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_asyncToGenerator__WEBPACK_IMPORTED_MODULE_6__["a"])(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_regenerator__WEBPACK_IMPORTED_MODULE_10___default.a.mark((function n(r){var a,i;return _home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_regenerator__WEBPACK_IMPORTED_MODULE_10___default.a.wrap((function(n){while(1)switch(n.prev=n.next){case 0:return l.current+=1,a=l.current,t([]),u(!0),n.next=6,e(r);case 6:if(i=n.sent,a===l.current){n.next=9;break}return n.abrupt("return");case 9:t(i,r),u(!1);case 11:case"end":return n.stop()}}),n)})));return function(e){return n.apply(this,arguments)}}();return _.debounce(n,a)}),[e,a]);return[s,c]},useListener=function(e,t,n){Object(react__WEBPACK_IMPORTED_MODULE_11__["useEffect"])((function(){return e.addEventListener(t,n),function(){e.removeEventListener(t,n)}}),[])},getWindowWidth=function(){return window.innerWidth},useWindowWidth=function(){var e=Object(react__WEBPACK_IMPORTED_MODULE_11__["useReducer"])(getWindowWidth,getWindowWidth()),t=Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_slicedToArray__WEBPACK_IMPORTED_MODULE_7__["a"])(e,2),n=t[0],r=t[1];return useListener(window,"resize",_.throttle(r,200)),n},useOnMobile=function(){return useWindowWidth()<576},useOnWideScreen=function(){return useWindowWidth()>=992},useOnNarrowScreen=function(){return useWindowWidth()<767},useA2SH=function(){var e=Object(react__WEBPACK_IMPORTED_MODULE_11__["useState"])(),t=Object(_home_ivan_db_tool_admin_node_modules_umijs_babel_preset_umi_node_modules_babel_runtime_helpers_esm_slicedToArray__WEBPACK_IMPORTED_MODULE_7__["a"])(e,2),n=t[0],r=t[1];return useListener(window,"beforeinstallprompt",r),[n,r]};function highlightKeyword(e,t){var n=e.toLowerCase().indexOf(t.toLowerCase());return n<0?e:[e.slice(0,n),react__WEBPACK_IMPORTED_MODULE_11___default.a.createElement("span",{style:{color:"red"}},e.slice(n,n+t.length)),e.slice(n+t.length)]}var useDisplayNameOfModel=function(){var e=useSchemas();return function(t){var n;return null===(n=e[t])||void 0===n?void 0:n.displayName}}}).call(this,__webpack_require__("LvDl"))},juLU:function(e,t,n){"use strict";(function(e){n("52nx");var r=n("7bDm"),a=n("0Owb"),i=(n("eNCU"),n("pjJH")),o=n("tJVT"),c=n("q1tI"),u=n.n(c),l=n("BGR+"),s=n("xNPh"),d=n("jfUH"),f=function(t){var n=Object(c["useState"])(),f=Object(o["a"])(n,2),p=f[0],m=f[1],h=Object(c["useState"])(!1),b=Object(o["a"])(h,2),v=b[0],_=b[1],g=t.Widget,y=t.value,O=t.field,j=t.onChange,w=t.nestedForm,k=void 0===w?[]:w;"boolean"===typeof k&&(k=k?["add","edit"]:[]);var E=O.ref,C=Object(d["s"])(E),x=function(){_(!1)},S=function(){_(!1)},F=function(){if(!e.isEmpty(y)){var t=Object(d["K"])(y,E);m(t),_(!0)}},M=function(){m(p),_(!0),m(void 0)},P=function(){var t,n=y;return t=!e.isEmpty(n)&&p?"".concat(n[C.titleField]?"\u3010".concat(n[C.titleField],"\u3011- "):"","\u7f16\u8f91").concat(C.displayName):"\u65b0\u5efa".concat(C.displayName),t},A=Object(s["a"])(O.ref),D=Object(d["q"])(O.ref),T={};y||(T.partialupdate=!0);var L=Object(l["a"])(t,["Widget","nestedForm","parentPk","model"]);return u.a.createElement("div",{style:{display:"flex",alignItems:"center"}},u.a.createElement("div",{style:{flexGrow:2}},u.a.createElement(g,L)),u.a.createElement("div",{style:{display:"flex"}},k.includes("add")&&D.includes("add")&&u.a.createElement(i["a"],{style:{marginLeft:8},onClick:M,icon:"plus"}),k.includes("edit")&&D.includes("change")&&!e.isEmpty(y)&&u.a.createElement(i["a"],{style:{marginLeft:8},onClick:F,icon:"form"})),u.a.createElement(r["a"],{title:P(),width:"60%",destroyOnClose:!0,visible:v,closable:!0,keyboard:!0,onOk:x,onCancel:S,footer:null},u.a.createElement(A,Object(a["a"])({model:E,objectid:p,onCreate:function(e){j(e),S()},onUpdate:function(e){j(e),S()}},T))))};t["a"]=f}).call(this,n("LvDl"))},jxO0:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return o}));var r=n("tJVT"),a=n("jfUH"),i=function t(n,r){return e.some(n,(function(n){return n.children?t(n.children):e.isUndefined(n.value)||!r&&e.isNull(n.value)}))},o=function(t,n,o,c,u,l){var s=function(t){var n=o[t];if(n instanceof Array)return n.map((function(e){return e instanceof Object?Object(a["Q"])(e,c,t):e}));if(n instanceof Object)return Object(a["Q"])(n,c,t);if(void 0===n){if(t.startsWith("instance."))return u[t.slice("instance.".length)];var r=e.get(o,t);return void 0!==r?r:e.get(l,t)}return n},d=[];return t&&(Array.isArray(t)?d=t.map((function(e){var t=e.field,n=e.operator,r=e.value,a=e.variable,i=e.children;return i?{operator:n,children:i}:{field:t,operator:n,value:a?s(a):r}})):t.split("&").forEach((function(e){var t=e.includes("=")?e.split("="):[e.slice(2,-1),e],n=Object(r["a"])(t,2),a=n[0],i=n[1],o=i.startsWith("$")?s(i.slice(2,-1)):i;d.push({field:a,operator:"=",value:o})}))),t&&i(d,n)?null:d}}).call(this,n("LvDl"))},k5tp:function(e,t,n){"use strict";(function(e){n("2qtc");var r,a,i,o,c=n("kLXV"),u=n("k1fw"),l=(n("eE3J"),n("GSZB")),s=n("oBTY"),d=n("fWQN"),f=n("mtLc"),p=n("yKVA"),m=n("879j"),h=(n("5Dmo"),n("3S7+")),b=(n("+BJd"),n("mr32")),v=n("PpiC"),_=n("q1tI"),g=n.n(_),y=n("AAgL"),O=n("sMR+"),j=n("jfUH"),w=n("mmaM"),k=n("CsTM"),E=n.n(k),C=n("jxO0"),x=n("Utjr"),S=function(e){var t=e.tag,n=e.model,r=Object(v["a"])(e,["tag","model"]),a=Object(j["xb"])(n),i=a(t).length>20,o=g.a.createElement(b["a"],r,i?"".concat(a(t).slice(0,20),"..."):a(t));return i?g.a.createElement(h["a"],{title:a(t)},o):o},F=(r=Object(j["d"])((function(){return{relativeFormContext:Object(_["useContext"])(x["c"]),schemas:Object(j["ub"])(),adminConfig:Object(j["T"])()}})),a=Reflect.metadata("design:type",Function),i=Reflect.metadata("design:paramtypes",[void 0]),r(o=a(o=i(o=function(t){Object(p["a"])(r,t);var n=Object(m["a"])(r);function r(t){var a;return Object(d["a"])(this,r),a=n.call(this,t),a.getTags=function(t){return e.isArray(t)?t:e.isPlainObject(t)?[t]:[]},a.getInitRow=function(t){return e.isArray(t)?t:e.isPlainObject(t)?[t]:[]},a.getInitKeys=function(t){return e.isArray(t)?t.map((function(e){return Object(j["K"])(e,a.refModel)})):e.isPlainObject(t)?[Object(j["K"])(t,a.refModel)]:[]},a.handleClose=function(e){var t=Object(j["K"])(e,a.refModel),n=a.state.tags.filter((function(e){return Object(j["K"])(e,a.refModel)!==t})),r=[];"checkbox"===a.state.tableType&&(r=a.state.selectedRows.filter((function(e){return Object(j["K"])(e,a.refModel)!==t})));var i=a.getInitKeys(r);a.doChange("radio"===a.state.tableType?null:r),a.setState({tags:n,selectedRows:r,selectedKeys:i})},a.onClickTag=function(){"radio"===a.state.tableType&&a.setState({visible:!0})},a.showModal=function(){a.setState({visible:!0})},a.handleOk=function(){var e=a.state.selectedRows;a.doChange(e),a.setState({confirmLoading:!0,tags:a.getTags(e)}),setTimeout((function(){a.setState({visible:!1,confirmLoading:!1})}),1e3)},a.handleCancel=function(){var e=a.props.value;a.setState({visible:!1,selectedKeys:a.getInitKeys(e),selectedRows:a.getInitRow(e)})},a.onSelectChange=function(e,t){a.setState({selectedKeys:e,selectedRows:"radio"===a.state.tableType?t[0]:t})},a.onTableRow=function(e){var t=a.state.tableType;return{onClick:function(){var n=Object(j["K"])(e,a.refModel);"radio"===t?a.setState({selectedKeys:[n],selectedRows:e}):"checkbox"===t&&a.setState((function(t){var r=t.selectedKeys,i=t.selectedRows;return r.includes(n)?{selectedKeys:r.filter((function(e){return e!==n})),selectedRows:i.filter((function(e){return Object(j["K"])(e,a.refModel)!==n}))}:{selectedKeys:[].concat(Object(s["a"])(r),[n]),selectedRows:[].concat(Object(s["a"])(i),[e])}}))}}},a.state={tags:a.getTags(t.value)||[],visible:!1,confirmLoading:!1,selectedKeys:a.getInitKeys(t.value),selectedRows:a.getInitRow(t.value),tableType:"",data:{list:[]},fetching:!1},a}return Object(f["a"])(r,[{key:"refModel",get:function(){var t=this.props,n=t.field,r=t.choices;return e.isPlainObject(r)?r.model:n.ref}},{key:"modelAdmin",get:function(){var e=this.props.adminConfig,t=this.refModel;return e[t]||{}}},{key:"isPointer",get:function(){return"radio"===this.state.tableType?E.a.clickable:""}},{key:"doChange",value:function(t){var n=this.props.onChange;n(e.isArray(t)?t.map(this.pickPkAndTitle.bind(this)):this.pickPkAndTitle(t))}},{key:"pickPkAndTitle",value:function(t){var n;if(!t)return null;var r=Object(j["L"])(this.refModel),a=this.props.schemas,i=null===(n=a[this.refModel])||void 0===n?void 0:n.titleField;return e.pick(t,[r,i])}},{key:"render",value:function(){var e=this,t=this.state,n=t.tags,r=t.visible,a=t.confirmLoading,i=t.selectedKeys,o=t.tableType,d=t.data,f=void 0===d?{}:d,p=t.fetching,m=this.props.field,h=this.refModel;f.pagination&&(f.pagination.showTotal=function(e){return"\u5171".concat(e,"\u6761\u6570\u636e")});var v=m.name,_=this.modelAdmin,y=_.display,k=void 0===y?[Object(j["L"])(h)]:y,x=_.sortable,F=Object(O["a"])(h);return"ref"===m.type?this.setState({tableType:"radio"}):"mref"===m.type&&this.setState({tableType:"checkbox"}),g.a.createElement("div",null,n.map((function(t,n){return g.a.createElement(S,{key:Object(j["K"])(t,e.refModel),className:e.isPointer,closable:-1!==n,onClose:function(){return e.handleClose(t)},onClick:e.onClickTag,tag:t,model:e.refModel})})),n.length<1||"radio"!==o?g.a.createElement(b["a"],{onClick:this.showModal,style:{background:"white",cursor:"pointer"}},g.a.createElement(l["a"],{type:"plus"})," \u9009 \u62e9"):null,g.a.createElement(c["a"],{width:"80%",title:v,visible:r,onOk:this.handleOk,confirmLoading:a,onCancel:this.handleCancel,destroyOnClose:!0},g.a.createElement(F,{fetchOnMounted:!0,fetch:function(t){var n=e.props,r=n.monitormodel,a=n.form,i=n.choicesFilter,o=n.choicesFilterAllowNull,c=void 0!==o&&o,l=n.instance,d=n.relativeFormContext,f=Object(C["a"])(i,c,a.getFieldsValue(),r,l,d);return f?(e.setState({fetching:!0}),Object(w["queryContent"])(Object(u["a"])(Object(u["a"])({},t),{},{filters:[].concat(Object(s["a"])(t.filters),Object(s["a"])(f))})).then((function(t){return e.setState({data:t})})).finally((function(){return e.setState({fetching:!1})}))):(e.setState({data:{list:[]}}),Promise.reject())},loading:p,shouldSelect:!0,tableProps:{onRow:this.onTableRow,rowClassName:function(){return E.a.clickable},rowSelection:{onChange:this.onSelectChange,selectedRowKeys:i,type:o}},tableActions:[],data:f,model:h,display:k,inlineActions:[],sortable:x})))}}]),r}(y["a"]))||o)||o)||o);t["a"]=F}).call(this,n("LvDl"))},lO8B:function(e,t,n){"use strict";n("nTdE");var r,a,i=n("IZHl"),o=n("0Owb"),c=(n("eNCU"),n("pjJH")),u=(n("eE3J"),n("GSZB")),l=n("fWQN"),s=n("mtLc"),d=n("yKVA"),f=n("879j"),p=n("q1tI"),m=n.n(p),h=n("AAgL"),b=n("jfUH"),v=(r=Object(b["d"])((function(){return{uploader:Object(b["zb"])()}})),r(a=function(e){Object(d["a"])(n,e);var t=Object(f["a"])(n);function n(){var e;Object(l["a"])(this,n);for(var r=arguments.length,a=new Array(r),i=0;i<r;i++)a[i]=arguments[i];return e=t.call.apply(t,[this].concat(a)),e.state={preview:!1,uploadingList:[]},e.handleChange=function(t){var n=t.file,r=t.fileList,a=e.props.onChange;if(e.setState({uploadingList:r.filter((function(e){return"uploading"===e.status}))}),"done"===n.status){var i=e.props.uploader.getUrl(n);a(i)}},e}return Object(s["a"])(n,[{key:"render",value:function(){var e=this.state.uploadingList,t=this.props,n=t.onChange,r=t.accept,a=t.value,l=m.a.createElement(c["a"],null,m.a.createElement(u["a"],{type:"upload"})," \u70b9\u6b64\u4e0a\u4f20"),s=e;return a&&(s=s.concat({url:a&&a.split("#")[0],name:a,uid:a})),m.a.createElement("div",null,m.a.createElement(i["a"],Object(o["a"])({action:this.props.uploader.uploadHost,data:this.props.uploader.formData,onChange:this.handleChange,beforeUpload:this.props.uploader.init,onRemove:function(){return n()},fileList:s,accept:r},this.widgetProps),s.length?null:l))}}]),n}(h["a"]))||a);t["a"]=v},"lt+M":function(e,t,n){"use strict";(function(e){var r=n("0Owb"),a=(n("4X2C"),n("xvon")),i=n("fWQN"),o=n("mtLc"),c=n("yKVA"),u=n("879j"),l=n("q1tI"),s=n.n(l),d=n("AAgL"),f=function(t){Object(c["a"])(l,t);var n=Object(u["a"])(l);function l(){var e;Object(i["a"])(this,l);for(var t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];return e=n.call.apply(n,[this].concat(r)),e.Component=a["a"],e}return Object(o["a"])(l,[{key:"render",value:function(){var t=this.props,n=t.value,a=t.onChange;return s.a.createElement(this.Component,Object(r["a"])({value:e.isObject(n)?JSON.stringify(n):n,onChange:function(e){var t,n;return a(null!==(t=null===e||void 0===e||null===(n=e.target)||void 0===n?void 0:n.value)&&void 0!==t?t:e)}},this.widgetProps))}}]),l}(d["a"]);f.propTypes={},t["a"]=f}).call(this,n("LvDl"))},mJsi:function(e,t,n){"use strict";var r=n("0Owb"),a=n("k1fw"),i=n("PpiC"),o=n("fWQN"),c=n("mtLc"),u=n("yKVA"),l=n("879j"),s=n("q1tI"),d=n.n(s),f=n("jfUH"),p=n("4l6Y"),m=(n("6nhF"),function(e){Object(u["a"])(n,e);var t=Object(l["a"])(n);function n(){return Object(o["a"])(this,n),t.apply(this,arguments)}return Object(c["a"])(n,[{key:"render",value:function(){var e=this.props,t=e.isOver,n=e.connectDragSource,o=e.connectDropTarget,c=(e.moveRow,e.sortKey),u=e.data,l=e.item,s=e.dragingItems,p=Object(i["a"])(e,["isOver","connectDragSource","connectDropTarget","moveRow","sortKey","data","item","dragingItems"]),m=Object(a["a"])(Object(a["a"])({},p.style),{},{cursor:"move"}),h=p.className;if(t){var b=s.item,v=Object(f["c"])(b,l,u.list);if(!v&&b.id!==l.id){var _=b[c],g=l[c],y=_<g||_===g&&b.id<l.id;l.parent===b.parent?h+=y?" drop-over-downward":" drop-over-upward":h+=y?" drop-over-downward-diff":" drop-over-upward-diff"}}return n(o(d.a.createElement("tr",Object(r["a"])({},p,{className:h,style:m}))))}}]),n}(d.a.Component)),h={beginDrag:function(e){return Object(a["a"])({},e)}},b={drop:function(e,t){var n=t.getItem().item,r=e.item,a=e.data,i=Object(f["c"])(n,r,a.list);n.id===r.id||i||e.moveRow(n,r)}};t["a"]=function(e){var t=e.table,n=e.onRow;return d.a.createElement(p["b"],null,(function(e){var r=e.DropTarget,a=e.DragSource,i=r("row",b,(function(e,t){return{connectDropTarget:e.dropTarget(),isOver:t.isOver(),dragingItems:t.getItem()}}))(a("row",h,(function(e){return{connectDragSource:e.dragSource()}}))(m));return t({components:{body:{row:i}},onRow:n})}))}},mefr:function(e,t,n){"use strict";n.d(t,"a",(function(){return u}));n("4X2C");var r=n("xvon"),a=n("fWQN"),i=n("yKVA"),o=n("879j"),c=n("lt+M"),u=function(e){Object(i["a"])(n,e);var t=Object(o["a"])(n);function n(){var e;Object(a["a"])(this,n);for(var i=arguments.length,o=new Array(i),c=0;c<i;c++)o[c]=arguments[c];return e=t.call.apply(t,[this].concat(o)),e.Component=r["a"].TextArea,e.options={autosize:{minRows:5,maxRows:30},style:{width:"100%"}},e}return n}(c["a"])},mmaM:function(e,t,n){"use strict";n.r(t),function(e){n.d(t,"request",(function(){return O})),n.d(t,"getExpandFields",(function(){return k})),n.d(t,"getDisplayFields",(function(){return C})),n.d(t,"queryContent",(function(){return x})),n.d(t,"downloadContent",(function(){return P})),n.d(t,"getFunctions",(function(){return D})),n.d(t,"createContent",(function(){return L})),n.d(t,"updateFullContent",(function(){return I})),n.d(t,"getChoices",(function(){return U})),n.d(t,"expandDetailFields",(function(){return R})),n.d(t,"contentDetail",(function(){return W})),n.d(t,"deleteContent",(function(){return B})),n.d(t,"batchAction",(function(){return K})),n.d(t,"verify",(function(){return H})),n.d(t,"emailVerify",(function(){return J})),n.d(t,"smsLoginSend",(function(){return G})),n.d(t,"smsLogin",(function(){return Z})),n.d(t,"register",(function(){return $})),n.d(t,"cloudFunction",(function(){return te})),n.d(t,"cloudFunc",(function(){return re})),n.d(t,"updateContent",(function(){return ie})),n.d(t,"sortUpdate",(function(){return ce})),n.d(t,"accountLogin",(function(){return se})),n.d(t,"weChatworkLogin",(function(){return fe})),n.d(t,"ddLogin",(function(){return me})),n.d(t,"accountLogout",(function(){return be})),n.d(t,"login",(function(){return ge})),n.d(t,"queryCurrent",(function(){return Oe})),n.d(t,"getAdminConfig",(function(){return we})),n.d(t,"getConfig",(function(){return Ee})),n.d(t,"getSettings",(function(){return xe})),n.d(t,"getSettingConf",(function(){return Fe})),n.d(t,"getSchemas",(function(){return Pe})),n.d(t,"getUploadToken",(function(){return De})),n.d(t,"uploadServer",(function(){return Le})),n.d(t,"statistics",(function(){return Ue})),n.d(t,"groupStatistics",(function(){return Re})),n.d(t,"getChart",(function(){return qe})),n.d(t,"getMenus",(function(){return Ke})),n.d(t,"updateAdmin",(function(){return He})),n.d(t,"installApp",(function(){return ze})),n.d(t,"checkDatabase",(function(){return Ye})),n.d(t,"chartShowAdmin",(function(){return Qe})),n.d(t,"checkInstall",(function(){return Xe})),n.d(t,"setIntermediaryTable",(function(){return et})),n.d(t,"setUserPassword",(function(){return nt})),n.d(t,"setUserGroups",(function(){return at})),n.d(t,"getUserGroups",(function(){return ot})),n.d(t,"upDateActive",(function(){return ut})),n.d(t,"getVersion",(function(){return st}));var r=n("tJVT"),a=n("PpiC"),i=n("k1fw"),o=n("oBTY"),c=n("9og8"),u=(n("GPKB"),n("mFAc")),l=n("WmNS"),s=n.n(l),d=n("Qyje"),f=n("RLxJ"),p=n("WTkp"),m=n("jfUH"),h=n("VW+w"),b=n("vbsh"),v=n("Z3Gc"),_=!1;function g(t){var n=5381;return e.forEach(t,(function(e){n=(n<<5)+n+e.charCodeAt(0)})),n}var y=function(){var e,t,n,r=document.getElementsByClassName("ant-pro-basicLayout-content ant-pro-basicLayout-has-header")[0],a=(null===r||void 0===r||null===(e=r.parentElement)||void 0===e||null===(t=e.nextElementSibling)||void 0===t||null===(n=t.innerText)||void 0===n?void 0:n.replace(/\s/g,""))||"";return a&&g(a)!==v["h"]?(u["a"].warn({content:decodeURIComponent(window.atob("JUU2JUEzJTgwJUU2JUI1JThCJUU1JTg4JUIwJUU5JTlEJTlFJUU2JUIzJTk1JUU3JUFGJUExJUU2JTk0JUI5JUVGJUJDJTgx")),key:"ILLEGAL_TAMPERING"}),Promise.reject()):p["a"].apply(void 0,arguments)};function O(e,t){return j.apply(this,arguments)}function j(){return j=Object(c["a"])(s.a.mark((function t(n,a){var i,o,l,d,p,m,h=arguments;return s.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return o=h.length>2&&void 0!==h[2]?h[2]:{},l=o.msgOption,t.next=3,y(n,a);case 3:d=t.sent,(null===(i=d.logs)||void 0===i?void 0:i.length)>0&&d.logs.forEach((function(e){var t=Object(r["a"])(e,2),n=t[0],a=t[1];switch(n){case 10:console.debug(a);break;case 20:console.info(a);break;case 30:console.warn(a);break;case 40:case 50:console.error(a);break;default:console.log(a)}})),p=parseInt(d.error_code,10),m=function(){var t=Object(c["a"])(s.a.mark((function t(n){var r,a;return s.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(!1!==l){t.next=2;break}return t.abrupt("return");case 2:if(e.isPlainObject(l)&&p in l&&m(n,p,l[p]),!e.isFunction(l)){t.next=8;break}return t.next=6,l(n,p,d);case 6:r=t.sent,u["a"].error(r);case 8:e.isString(l)&&u["a"].error(l),void 0===l&&(a={"FOREIGN KEY constraint failed":"\u5916\u952e\u7ea6\u675f\u9519\u8bef"},u["a"].error(a[d.error_data]||n));case 10:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),t.t0=p,t.next=0===t.t0?10:403===t.t0?11:1e4===t.t0?14:21002===t.t0||21003===t.t0||21004===t.t0?15:18;break;case 10:return t.abrupt("return",d.result);case 11:return u["a"].error({content:"\u8eab\u4efd\u8ba4\u8bc1\u5931\u6548",key:"AUTH_INVALID"}),window.g_app._store.dispatch({type:"content/logout"}),t.abrupt("return",Promise.reject(d));case 14:return t.abrupt("break",19);case 15:return m({21002:"License \u65e0\u6548\uff0c\u8bf7\u91cd\u65b0\u586b\u5199\uff01",21003:"License \u5df2\u8fc7\u671f\uff0c\u8bf7\u91cd\u65b0\u7533\u8bf7\uff01",21004:"\u8bf7\u586b\u5199 License\uff01"}[p]),f["a"].push("/account/settings"),t.abrupt("return",Promise.reject(d));case 18:return t.abrupt("break",19);case 19:return m("".concat(d.error_message).concat(e.isString(d.error_data)&&!e.isEmpty(d.error_data)?"\uff1a".concat(d.error_data):"")),t.abrupt("return",Promise.reject(d));case 21:case"end":return t.stop()}}),t)}))),j.apply(this,arguments)}var w=function(e,t){var n=window.g_app._store.getState(),r=n.content.adminConfig,a=Object(m["H"])(r,e,"list",t);return a&&a.orderBy?"string"===typeof a.orderBy||a.orderBy instanceof String?[a.orderBy]:a.orderBy:["-".concat(Object(m["L"])(e))]},k=function(t){var n,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"display",a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=window.g_app._store.getState(),c=i.content,u=c.adminConfig,l=c.schemas,s=a||u[t]||{};if("detailFields"===r){var d=s.detail;if(!d||!d.fields&&!d.sections)return[];d.fields&&(s.detailFields=d.fields.map((function(e){return e.name||e}))),d.sections&&(s.detailFields=d.sections.reduce((function(e,t){return e.concat(t.fields.map((function(e){return e.name||e})))}),[])),s.detailFields=Object(h["displayPreprocess"])(s.detailFields,t,l)}if("display"===r&&(s.display=Object(h["displayPreprocess"])(s.display,t,l)),!s||!s[r]||!l[t])return[];var f=s[r].filter((function(e){return!e.type&&!e.depand&&!e.widget})).map((function(e){return e.name}));s[r].filter((function(t){return e.isObject(t)&&"combo"===t.type&&t.mapping})).forEach((function(t){f=f.concat(e.values(t.mapping))})),s[r].filter((function(t){return e.isObject(t)&&"asColumn"===t.type&&t.params})).forEach((function(e){var t=e.params,n=t.field,r=t.title,a=t.value,i=t.groupField,o=[n,r,a];i&&o.push(i),f=f.concat(o.map((function(t){return"".concat(e.name,".").concat(t)})))})),s[r].filter((function(t){return e.isObject(t)&&"embed"===t.type&&t[r]})).forEach((function(t){f=f.concat(e.values(t[r]).map((function(e){return"".concat(t.name,".").concat(e)})))})),s[r].filter((function(t){return e.isObject(t)&&t.depand})).forEach((function(e){f.push(e.depand)})),s[r].filter((function(t){return e.isObject(t)&&t.widget&&t.fields})).forEach((function(e){Object.keys(e.fields).forEach((function(t){return f.push(e.fields[t])}))}));var p=s.inlineActions,b=[];(p||[]).forEach((function(t){var n,r,a,i,o;null!==(n=t.params)&&void 0!==n&&n.userField&&b.push(null===(r=t.params)||void 0===r?void 0:r.userField),null!==(a=t.params)&&void 0!==a&&a.field&&e.isString(null===(i=t.params)||void 0===i?void 0:i.field)&&b.push(null===(o=t.params)||void 0===o?void 0:o.field)})),(n=f).push.apply(n,b),f=Object(o["a"])(new Set(f));var v=f.filter((function(e){return e.includes(".")})).map((function(e){return Object(m["B"])(Object(m["j"])(t,e,l))?e:e.split(".").slice(0,-1).join(".")})),_=[];return _=f.filter((function(e){return!e.includes(".")})).filter((function(e){var n=l[t].fields.find((function(t){return t.name===e}));return n&&Object(m["A"])(n.type)})),Object(o["a"])(new Set(v.concat(_)))};function E(e){return e.results||e.list||e}var C=function(t,n){var r;return n&&e.uniq(n.map((function(t){return t.fields?e.values(t.fields):t.name||t})).flat().map((function(e){var n=window.g_app._store.getState(),r=n.content.schemas;if(!r[t])return e;var a=e.split(".");return a.map((function(e,t){return a.slice(0,t+1)})).map((function(e){return e.join(".")})).map((function(e){var n=Object(m["j"])(t,e,r);return n&&Object(m["B"])(n)?["".concat(e,".").concat(r[n.ref].titleField),"".concat(e,".").concat(Object(m["L"])(n.ref))]:e})).flat()})).flat().concat([null===(r=window.g_app._store.getState().content.schemas[t])||void 0===r?void 0:r.titleField,Object(m["L"])(t)]))};function x(e){return S.apply(this,arguments)}function S(){return S=Object(c["a"])(s.a.mark((function e(t){var n,r,a,o,c,u,l,f,p,h,b,v,g,y;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.model,r=t.filters,a=t.page,o=t.size,c=t.orderBy,u=void 0===c?[]:c,l=t.expandFields,f=t.displayFields,p=t.extra,h=void 0!==a&&void 0!==o,b=window.g_app._store.getState(),v=b.content.adminConfig,g=l||k(n,"display",Object(m["H"])(v,n,"list",null===p||void 0===p?void 0:p.view)),e.next=6,O(h?"/basebone/".concat(n,"/list/?").concat(Object(d["stringify"])({page:a,size:o})):"/basebone/".concat(n,"/list/"),{method:"POST",data:Object(i["a"])({filters:r,expand_fields:_?[]:g,order_by:u.concat(w(n,null===p||void 0===p?void 0:p.view)),display_fields:f},p)});case 6:if(y=e.sent,!_){e.next=10;break}return e.next=10,F(n,g,y);case 10:if(!h){e.next=12;break}return e.abrupt("return",{list:y.results,pagination:{total:y.count,current:a,pageSize:o}});case 12:return e.abrupt("return",{list:y,pagination:{total:-1,current:-1,pageSize:-1}});case 13:case"end":return e.stop()}}),e)}))),S.apply(this,arguments)}function F(e,t,n){return M.apply(this,arguments)}function M(){return M=Object(c["a"])(s.a.mark((function t(n,r,a){var i,o,c,u,l,d,f;return s.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return i=window.g_app._store.getState(),o=i.content.schemas,c=o[n],u=[],l=e.groupBy(r,(function(e){return e.split(".")[0]})),d=e.groupBy(l,(function(e){return c.fields.find((function(t){return t.name===e[0].split(".")[0]})).ref})),e.forEach(d,(function(t,r){var i=t.flat().map((function(e){return e.split(".")})).filter((function(e){return e.length>1})).map((function(e){return e.slice(1).join(".")})),o=t.map((function(e){return e[0].split(".")[0]})).map((function(e){return c.fields.find((function(t){return t.name===e}))})),l=o.filter(m["D"]).map((function(e){return e.name})),s=e.uniq(E(a).map((function(e){return l.map((function(t){return e[t]})).filter((function(e){return null!==e}))})).flat());s.length&&u.push(x({model:r,expandFields:i,filters:[{field:Object(m["L"])(r),operator:"in",value:s}]}).then((function(e){return{resultList:E(e),type:"ref",fieldNames:l,refModel:r}}))),o.filter((function(e){return"bref"===e.type})).forEach((function(e){var t=E(a).map((function(e){return Object(m["K"])(e,n)}));u.push(x({model:r,expandFields:i,filters:[{field:e.refField,operator:"in",value:t}]}).then((function(t){return{resultList:E(t),type:"bref",fieldName:e.name,refField:e.refField,refModel:r}})))}))})),t.next=8,Promise.all(u);case 8:f=t.sent,f.forEach((function(t){var r=t.resultList,i=t.type,o=t.fieldNames,c=t.fieldName,u=t.refField,l=t.refModel;if("ref"===i){var s=e.keyBy(r,Object(m["L"])(l));E(a).forEach((function(e){o.forEach((function(t){null!==e[t]&&(e[t]=s[e[t]])}))}))}else if("bref"===i){var d=e.groupBy(E(r),u);E(a).forEach((function(e){e[c]=d[Object(m["K"])(e,n)]||[]}))}}));case 10:case"end":return t.stop()}}),t)}))),M.apply(this,arguments)}function P(e){return A.apply(this,arguments)}function A(){return A=Object(c["a"])(s.a.mark((function t(n){var r,a,o,c,u,l,d,f;return s.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return r=n.model,a=n.filters,o=n.exportKey,c=n.detailModel,u=n.detailId,l=o&&!e.isObject(o)?"/basebone/".concat(r,"/export/file/?fileformat=").concat(o):"/basebone/".concat(r,"/export/file/"),d=Object(i["a"])({filters:a},!e.isObject(o)||"v2"!==o.version&&"v3"!==o.version?{}:{basebone_export_config:o}),c&&(d.detail_model=c,d.detail_id=u),t.next=6,y(l,{method:"POST",data:d,getResponse:!0,responseType:"blob"});case 6:return f=t.sent,t.abrupt("return",f);case 8:case"end":return t.stop()}}),t)}))),A.apply(this,arguments)}function D(e){return T.apply(this,arguments)}function T(){return T=Object(c["a"])(s.a.mark((function e(t){var n,r,a,i;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.model,r=t.scene,a="/basebone/".concat(n,"/functions/?scene=").concat(r),e.next=4,y(a,{method:"GET",getResponse:!0});case 4:return i=e.sent,e.abrupt("return",i);case 6:case"end":return e.stop()}}),e)}))),T.apply(this,arguments)}var L=b["a"].Create((function(e,t){var n=e.model,r=e.values;return O("/basebone/".concat(n,"/"),{method:"POST",data:r},t)})),I=b["a"].Update((function(e){var t=e.model,n=e.values,r=e.id;return O("/basebone/".concat(t,"/").concat(r,"/"),{method:"PUT",data:n})}));function U(e){return V.apply(this,arguments)}function V(){return V=Object(c["a"])(s.a.mark((function e(t){var n,r,a,c,u,l,f,p,h,b;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.model,r=t.titleField,a=t.q,c=t.query,u=t.condictions,l=t.conditions,f=t.data,l=l||u,p=[],a&&p.push({field:r,value:a,operator:"icontains"}),Array.isArray(l)?p.push.apply(p,Object(o["a"])(l)):l&&Object.keys(l).length&&Object.keys(l).forEach((function(e){p.push({field:e,operator:"=",value:l[e]})})),e.next=7,O("/basebone/".concat(n,"/list/?").concat(Object(d["stringify"])(c)),{method:"POST",data:Object(i["a"])({filters:p},f)});case 7:return h=e.sent,b=c&&Object.keys(c).length?h.results:h,e.abrupt("return",b.map((function(e){return[Object(m["K"])(e,n),e]})));case 10:case"end":return e.stop()}}),e)}))),V.apply(this,arguments)}function R(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=arguments.length>2?arguments[2]:void 0,r=window.g_app._store.getState(),a=r.content,c=a.schemas,u=a.adminConfig,l=u[e];if(!l)return[];var s=l.formFields,d=l.inlineFormFields,f=t&&(n||d)||s,p=c[e];if(!p||!f)return[];var h=[];return f.forEach((function(e){var t,n="string"===typeof e?{name:e,expand:[]}:Object(i["a"])({expand:[]},e),r=p.fields.find((function(e){return e.name===n.name}));r&&Object(m["B"])(r)&&(h.push(n.name),["bref","boref"].includes(r.type)&&(t=n.expand).push.apply(t,Object(o["a"])(R(r.ref,!0,(e.params||{}).fields))));h.push.apply(h,Object(o["a"])(n.expand.map((function(e){return"".concat(n.name,".").concat(e)}))))})),h}function W(e,t){return q.apply(this,arguments)}function q(){return q=Object(c["a"])(s.a.mark((function e(t,n){var r,a,o,c,u,l,d,f,p;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=t.model,a=t.id,o=t.expandFields,c=t.fieldsType,u=t.detail,l=window.g_app._store.getState(),d=l.content.adminConfig,f=o||("detailFields"===c?k(r,c,Object(i["a"])(Object(i["a"])({},d[r]),{},{detail:u})):R(r)),e.next=5,O("/basebone/".concat(r,"/").concat(a,"/"),{method:"POST",data:{expand_fields:_?[]:f}},n);case 5:if(p=e.sent,!_){e.next=9;break}return e.next=9,F(r,f,[p]);case 9:return e.abrupt("return",p);case 10:case"end":return e.stop()}}),e)}))),q.apply(this,arguments)}var B=b["a"].Delete((function(e){var t=e.model,n=e.id;return O("/basebone/".concat(t,"/").concat(n,"/"),{method:"DELETE"})}));function K(e){return N.apply(this,arguments)}function N(){return N=Object(c["a"])(s.a.mark((function e(t){var n,r,a,i;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.model,r=t.ids,a=t.action,i=t.payload,e.abrupt("return",O("/basebone/".concat(n,"/batch/"),{method:"POST",data:{action:a,data:r,payload:i}}));case 2:case"end":return e.stop()}}),e)}))),N.apply(this,arguments)}function H(e){return z.apply(this,arguments)}function z(){return z=Object(c["a"])(s.a.mark((function e(t){return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",y("/basebone/member/sms/code",{method:"POST",data:{mobile:t}}));case 1:case"end":return e.stop()}}),e)}))),z.apply(this,arguments)}function J(e){return Y.apply(this,arguments)}function Y(){return Y=Object(c["a"])(s.a.mark((function e(t){return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",y("/basebone/member/email/code",{method:"POST",data:{email:t,lang:"zh_CN"}}));case 1:case"end":return e.stop()}}),e)}))),Y.apply(this,arguments)}function G(e){return Q.apply(this,arguments)}function Q(){return Q=Object(c["a"])(s.a.mark((function e(t){var n;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=new FormData,n.append("phone",t),e.abrupt("return",O("/basebone/auth/sms/login-send",{method:"POST",data:n}));case 3:case"end":return e.stop()}}),e)}))),Q.apply(this,arguments)}function Z(e){return X.apply(this,arguments)}function X(){return X=Object(c["a"])(s.a.mark((function e(t){var n,r,a;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.mobile,r=t.captcha,a=new FormData,a.append("phone",n),a.append("code",r),e.abrupt("return",y("/basebone/auth/sms/login",{method:"POST",data:a}));case 5:case"end":return e.stop()}}),e)}))),X.apply(this,arguments)}function $(e){return ee.apply(this,arguments)}function ee(){return ee=Object(c["a"])(s.a.mark((function e(t){return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",y("/basebone/member/register",{method:"POST",data:t}));case 1:case"end":return e.stop()}}),e)}))),ee.apply(this,arguments)}function te(e){return ne.apply(this,arguments)}function ne(){return ne=Object(c["a"])(s.a.mark((function e(t){var n,r,a;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.model,r=t.functionName,a=t.params,e.abrupt("return",y("/basebone/".concat(n,"/func/"),{method:"POST",data:{func_name:r,params:a}}));case 2:case"end":return e.stop()}}),e)}))),ne.apply(this,arguments)}function re(e){return ae.apply(this,arguments)}function ae(){return ae=Object(c["a"])(s.a.mark((function e(t){var n,r,a;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.model,r=t.functionName,a=t.params,e.abrupt("return",O("/basebone/".concat(n,"/func/"),{method:"POST",data:{func_name:r,params:a}}));case 2:case"end":return e.stop()}}),e)}))),ae.apply(this,arguments)}function ie(e){return oe.apply(this,arguments)}function oe(){return oe=Object(c["a"])(s.a.mark((function e(t){var n,r,a,i,o,c;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.model,r=t.id,a=t.newValues,i=t.appendModeFields,o={},Object.keys(a).forEach((function(e){void 0!==a[e]&&(o[e]=a[e])})),c="/basebone/".concat(n,"/").concat(r,"/"),i&&(c="/basebone/".concat(n,"/").concat(r,"/?rfum_append=").concat(i.join(","))),e.abrupt("return",O(c,{method:"PATCH",data:o}));case 6:case"end":return e.stop()}}),e)}))),oe.apply(this,arguments)}function ce(e,t,n){return ue.apply(this,arguments)}function ue(){return ue=Object(c["a"])(s.a.mark((function e(t,n,r){return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",O("/basebone/".concat(t,"/update_sort/"),{method:"POST",data:{dragId:n,hoverId:r}}));case 1:case"end":return e.stop()}}),e)}))),ue.apply(this,arguments)}var le=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"account";switch(parseInt(e.error_code,10)){case 0:return{status:"ok",type:t,currentAuthority:"admin"};default:return{status:"error",type:t,currentAuthority:"guest"}}};function se(e){return de.apply(this,arguments)}function de(){return de=Object(c["a"])(s.a.mark((function e(t){var n,r;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.userName,r=t.password,e.abrupt("return",y("/basebone/manage/account/login/",{method:"POST",data:{username:n,password:r}}));case 2:case"end":return e.stop()}}),e)}))),de.apply(this,arguments)}function fe(e){return pe.apply(this,arguments)}function pe(){return pe=Object(c["a"])(s.a.mark((function e(t){return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",y("/basebone_wechat_work/login/",{method:"POST",data:t}));case 1:case"end":return e.stop()}}),e)}))),pe.apply(this,arguments)}function me(e){return he.apply(this,arguments)}function he(){return he=Object(c["a"])(s.a.mark((function e(t){return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",y("/basebone/member/dingding/login/",{method:"POST",data:t}));case 1:case"end":return e.stop()}}),e)}))),he.apply(this,arguments)}function be(){return ve.apply(this,arguments)}function ve(){return ve=Object(c["a"])(s.a.mark((function e(){return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",y("/basebone/manage/account/logout/",{method:"POST"}));case 1:case"end":return e.stop()}}),e)}))),ve.apply(this,arguments)}var _e={account:se,weChatWork:fe,ddLogin:me,mobile:Z};function ge(e){return ye.apply(this,arguments)}function ye(){return ye=Object(c["a"])(s.a.mark((function e(t){var n,r,i,o;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.type,r=void 0===n?"account":n,i=Object(a["a"])(t,["type"]),e.next=3,_e[r](i);case 3:return o=e.sent,e.abrupt("return",le(o,["account","mobile"].includes(r)?r:"account"));case 5:case"end":return e.stop()}}),e)}))),ye.apply(this,arguments)}function Oe(){return je.apply(this,arguments)}function je(){return je=Object(c["a"])(s.a.mark((function e(){var t;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t={},e.prev=1,e.next=4,O("/basebone/manage/account/userinfo/");case 4:t=e.sent,e.next=10;break;case 7:return e.prev=7,e.t0=e["catch"](1),e.abrupt("return",{});case 10:return e.abrupt("return",Object(i["a"])(Object(i["a"])({},t),{},{permissions:t.permissions.map(m["J"])}));case 11:case"end":return e.stop()}}),e,null,[[1,7]])}))),je.apply(this,arguments)}function we(){return ke.apply(this,arguments)}function ke(){return ke=Object(c["a"])(s.a.mark((function e(){return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",O("/basebone/config/admin/"));case 1:case"end":return e.stop()}}),e)}))),ke.apply(this,arguments)}function Ee(){return Ce.apply(this,arguments)}function Ce(){return Ce=Object(c["a"])(s.a.mark((function e(){return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",O("/basebone/config/all/"));case 1:case"end":return e.stop()}}),e)}))),Ce.apply(this,arguments)}function xe(){return Se.apply(this,arguments)}function Se(){return Se=Object(c["a"])(s.a.mark((function e(){return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",O("/basebone/config/settings/"));case 1:case"end":return e.stop()}}),e)}))),Se.apply(this,arguments)}function Fe(){return Me.apply(this,arguments)}function Me(){return Me=Object(c["a"])(s.a.mark((function e(){return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",O("/basebone/config/setting_config/"));case 1:case"end":return e.stop()}}),e)}))),Me.apply(this,arguments)}function Pe(){return Ae.apply(this,arguments)}function Ae(){return Ae=Object(c["a"])(s.a.mark((function e(){return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",O("/basebone/config/schema/"));case 1:case"end":return e.stop()}}),e)}))),Ae.apply(this,arguments)}function De(){return Te.apply(this,arguments)}function Te(){return Te=Object(c["a"])(s.a.mark((function e(){return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",O("/basebone/manage/upload/token/"));case 1:case"end":return e.stop()}}),e)}))),Te.apply(this,arguments)}function Le(e){return Ie.apply(this,arguments)}function Ie(){return Ie=Object(c["a"])(s.a.mark((function t(n){var r,i,o,c,u,l,d,f,p,h;return s.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,De();case 2:return r=t.sent,i=r.provider,o=Object(a["a"])(r,["provider"]),c=Object(m["u"])(i,o),u=c.getUrl,l=c.getFormData,d=c.host,f=u(n),p=l(n),h=new FormData,e.forEach(p,(function(e,t){h.append(t,e)})),h.append("file",n),t.next=13,y(d,{method:"POST",data:h});case 13:return t.abrupt("return",{url:f});case 14:case"end":return t.stop()}}),t)}))),Ie.apply(this,arguments)}function Ue(e){return Ve.apply(this,arguments)}function Ve(){return Ve=Object(c["a"])(s.a.mark((function e(t){var n,r;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.model,r=t.filters,e.abrupt("return",O("/basebone/".concat(n,"/statistics/"),{method:"POST",data:{filters:r}}));case 2:case"end":return e.stop()}}),e)}))),Ve.apply(this,arguments)}function Re(e){return We.apply(this,arguments)}function We(){return We=Object(c["a"])(s.a.mark((function e(t){var n,r,a,i;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.model,r=t.filters,a=t.group,i=t.fields,e.abrupt("return",O("/basebone/".concat(n,"/group_statistics/"),{method:"POST",data:{filters:r,group:a,fields:i}}));case 2:case"end":return e.stop()}}),e)}))),We.apply(this,arguments)}function qe(e){return Be.apply(this,arguments)}function Be(){return Be=Object(c["a"])(s.a.mark((function e(t){var n,r;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.model,r=t.id,e.abrupt("return",O("/basebone/".concat(n,"/get_chart/"),{method:"POST",data:{id:r}}));case 2:case"end":return e.stop()}}),e)}))),Be.apply(this,arguments)}function Ke(){return Ne.apply(this,arguments)}function Ne(){return Ne=Object(c["a"])(s.a.mark((function e(){return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",O("/basebone/config/manage/menu/?menutype=database"));case 1:case"end":return e.stop()}}),e)}))),Ne.apply(this,arguments)}function He(e){var t=e.model,n=e.config;return O("/basebone/config/admin/".concat(t,"/"),{method:"PUT",data:n})}function ze(){return Je.apply(this,arguments)}function Je(){return Je=Object(c["a"])(s.a.mark((function e(){var t,n=arguments;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=n.length>0&&void 0!==n[0]?n[0]:{},e.abrupt("return",O("/basebone/meta__app/func/",{method:"POST",data:{func_name:"init_models",params:t}}));case 2:case"end":return e.stop()}}),e)}))),Je.apply(this,arguments)}function Ye(){return Ge.apply(this,arguments)}function Ge(){return Ge=Object(c["a"])(s.a.mark((function e(){var t,n=arguments;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=n.length>0&&void 0!==n[0]?n[0]:{},e.abrupt("return",O("/basebone/meta__app/func/",{method:"POST",data:{func_name:"check_database",params:t}}));case 2:case"end":return e.stop()}}),e)}))),Ge.apply(this,arguments)}function Qe(){return Ze.apply(this,arguments)}function Ze(){return Ze=Object(c["a"])(s.a.mark((function e(){var t,n=arguments;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=n.length>0&&void 0!==n[0]?n[0]:{},e.abrupt("return",O("/basebone/guardian__userobjectpermission/func/",{method:"POST",data:{func_name:"set_user_group_object_permission",params:t}}));case 2:case"end":return e.stop()}}),e)}))),Ze.apply(this,arguments)}function Xe(){return $e.apply(this,arguments)}function $e(){return $e=Object(c["a"])(s.a.mark((function e(){var t,n;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,re({model:"db_tool__setting",functionName:"check_install"});case 2:return t=e.sent,n=t.installed,e.abrupt("return",n);case 5:case"end":return e.stop()}}),e)}))),$e.apply(this,arguments)}function et(){return tt.apply(this,arguments)}function tt(){return tt=Object(c["a"])(s.a.mark((function e(){var t,n=arguments;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=n.length>0&&void 0!==n[0]?n[0]:{},e.abrupt("return",O("/basebone/meta__model/func/",{method:"POST",data:{func_name:"create_many_to_many_filed",params:t}}));case 2:case"end":return e.stop()}}),e)}))),tt.apply(this,arguments)}function nt(){return rt.apply(this,arguments)}function rt(){return rt=Object(c["a"])(s.a.mark((function e(){var t,n=arguments;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=n.length>0&&void 0!==n[0]?n[0]:{},e.abrupt("return",O("/basebone/member__user/func/",{method:"POST",data:{func_name:"set_password",params:t}}));case 2:case"end":return e.stop()}}),e)}))),rt.apply(this,arguments)}function at(){return it.apply(this,arguments)}function it(){return it=Object(c["a"])(s.a.mark((function e(){var t,n=arguments;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=n.length>0&&void 0!==n[0]?n[0]:{},e.abrupt("return",O("/basebone/member__user/func/",{method:"POST",data:{func_name:"set_groups",params:t}}));case 2:case"end":return e.stop()}}),e)}))),it.apply(this,arguments)}function ot(){return ct.apply(this,arguments)}function ct(){return ct=Object(c["a"])(s.a.mark((function e(){var t,n=arguments;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=n.length>0&&void 0!==n[0]?n[0]:{},e.abrupt("return",O("/basebone/member__user/func/",{method:"POST",data:{func_name:"get_groups",params:t}}));case 2:case"end":return e.stop()}}),e)}))),ct.apply(this,arguments)}function ut(){return lt.apply(this,arguments)}function lt(){return lt=Object(c["a"])(s.a.mark((function e(){var t,n=arguments;return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t=n.length>0&&void 0!==n[0]?n[0]:{},e.abrupt("return",O("/basebone/member__user/func/",{method:"POST",data:{func_name:"set_active",params:t}}));case 2:case"end":return e.stop()}}),e)}))),lt.apply(this,arguments)}function st(){return dt.apply(this,arguments)}function dt(){return dt=Object(c["a"])(s.a.mark((function e(){return s.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.abrupt("return",O("/basebone/version/",{method:"GET"}));case 1:case"end":return e.stop()}}),e)}))),dt.apply(this,arguments)}}.call(this,n("LvDl"))},nKGo:function(e,t,n){e.exports={gmImg:"gmImg___24rv6"}},oORW:function(e,t,n){"use strict";n("4X2C");var r=n("xvon"),a=n("0Owb"),i=n("fWQN"),o=n("mtLc"),c=n("yKVA"),u=n("879j"),l=(n("eE3J"),n("GSZB")),s=n("q1tI"),d=n.n(s),f=n("AAgL"),p=l["a"].createFromIconfontCN({scriptUrl:"//at.alicdn.com/t/font_895448_qna83b20tb.js"}),m=function(e){Object(c["a"])(n,e);var t=Object(u["a"])(n);function n(){var e;Object(i["a"])(this,n);for(var r=arguments.length,a=new Array(r),o=0;o<r;o++)a[o]=arguments[o];return e=t.call.apply(t,[this].concat(a)),e.state={raw:!1},e.handleChange=function(t){var n=e.props.onChange;n(t.target.value||void 0)},e.toggleRaw=function(){return e.setState((function(e){var t=e.raw;return{raw:!t}}))},e}return Object(o["a"])(n,[{key:"componentDidMount",value:function(){var e=this.props.onChange;e()}},{key:"render",value:function(){var e=this.props.value,t=this.state.raw;return d.a.createElement(r["a"],Object(a["a"])({type:t?"text":"password",value:e,onChange:this.handleChange,autoComplete:"new-password",addonAfter:d.a.createElement("div",{onClick:this.toggleRaw},t?d.a.createElement(p,{type:"icon-eye-off"}):d.a.createElement(l["a"],{type:"eye"}))},this.widgetProps))}}]),n}(f["a"]);m.propTypes={},t["a"]=m},onda:function(e,t,n){"use strict";var r=n("q1tI"),a=n.n(r),i=n("jfUH"),o=(n("52nx"),n("7bDm")),c=(n("eNCU"),n("pjJH")),u=n("fWQN"),l=n("mtLc"),s=n("tS8v"),d=n("yKVA"),f=n("879j"),p=n("4l6Y"),m=n("AAgL"),h=function(e){Object(d["a"])(n,e);var t=Object(f["a"])(n);function n(){var e;Object(u["a"])(this,n);for(var r=arguments.length,a=new Array(r),i=0;i<r;i++)a[i]=arguments[i];return e=t.call.apply(t,[this].concat(a)),e.state={showModal:!1,tempValue:void 0},e.myProps=[],e.onTempChange=function(t){return e.setState({tempValue:t})},e.handleSelect=function(t){var n=Object(s["a"])(e),r=n.onTempChange,a=t.poi,i=a.district,o=a.address,c=a.name,u=a.location,l=u.lat,d=u.lng,f=a.adcode;r({address:i+o+c,latitude:l,longitude:d,ad_code:f})},e.handleDrag=function(t){var n=e.state.tempValue,r=Object(s["a"])(e),a=r.onTempChange,i=t.address,o=t.position,c=o.lng,u=o.lat,l=t.regeocode.addressComponent.adcode;n&&c===n.longitude&&u===n.latitude||a({address:i,latitude:u,longitude:c,ad_code:l})},e.openModal=function(){var t=e.props.value;e.setState({showModal:!0,tempValue:t})},e}return Object(l["a"])(n,[{key:"render",value:function(){var e=this,t=this.state,n=t.tempValue,r=t.showModal,i=this.props,u=i.value,l=i.amapkey,s=a.a.createElement(p["a"],{useAMapUI:!0,zoom:n&&20,amapkey:l,center:n},(function(t){var n=t.Wrapper,r=t.Autocomplete,i=t.PositionPicker;return a.a.createElement(a.a.Fragment,null,a.a.createElement(n,null,a.a.createElement(i,{instanceName:"PositionPicker",eventSupport:!0,events:{success:e.handleDrag}})),a.a.createElement(r,{options:{},onSelect:e.handleSelect,placeholder:"\u641c\u7d22",style:{transform:"translateY(-200%)",marginLeft:8}}))}));return a.a.createElement("div",null,a.a.createElement(c["a"],{onClick:this.openModal},"\u9009\u62e9\u4f4d\u7f6e"),a.a.createElement(o["a"],{title:n?"\u5f53\u524d\u9009\u4e2d\u4f4d\u7f6e\uff1a\uff08".concat(n.address,"\uff09"):"\u9009\u62e9\u4f4d\u7f6e",width:800,visible:r,onCancel:function(){return e.setState({showModal:!1})},onOk:function(){e.props.onChange(n),e.setState({showModal:!1,tempValue:void 0})}},a.a.createElement("div",{style:{height:600}},s)),u&&a.a.createElement("span",{style:{marginLeft:10}},u.address))}}]),n}(m["a"]);t["a"]=function(){var e=Object(i["V"])("amap_key");return a.a.createElement(h,{amapkey:e})}},psPf:function(e,t,n){"use strict";var r=n("Utjr");t["a"]=Object(r["d"])((function(){return Promise.all([n.e(30),n.e(22)]).then(n.bind(null,"jU8G"))}),{loading:"\u52a0\u8f7d\u4ee3\u7801\u7f16\u8f91\u5668..."})},"qa+J":function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return f}));var r=n("0Owb"),a=n("fWQN"),i=n("mtLc"),o=n("yKVA"),c=n("879j"),u=n("q1tI"),l=n.n(u),s=n("lt+M"),d=n("dUs0"),f=function(t){Object(o["a"])(u,t);var n=Object(c["a"])(u);function u(){var e;Object(a["a"])(this,u);for(var t=arguments.length,r=new Array(t),i=0;i<t;i++)r[i]=arguments[i];return e=n.call.apply(n,[this].concat(r)),e.isObjectItemType=function(){var t=e.props.field;return"object"===t.item_type},e.handleChange=function(t){var n=e.props.onChange,r=t;e.isObjectItemType()||(r=t.map((function(e){return e.item}))),n(r)},e}return Object(i["a"])(u,[{key:"render",value:function(){var t=this.props.value,n=t;return e.isArray(n)?this.isObjectItemType()||(n=t.map((function(e){return{item:e}}))):n=[],l.a.createElement("div",null,l.a.createElement(d["a"],Object(r["a"])({},this.props,{value:n,onChange:this.handleChange,canAdd:!0})))}}]),u}(s["a"])}).call(this,n("LvDl"))},qoBN:function(e,t,n){"use strict";(function(e){n("Ahcs");var r=n("k0dM"),a=n("fWQN"),i=n("mtLc"),o=n("yKVA"),c=n("879j"),u=n("q1tI"),l=n.n(u),s=function(t){Object(o["a"])(u,t);var n=Object(c["a"])(u);function u(){return Object(a["a"])(this,u),n.apply(this,arguments)}return Object(i["a"])(u,[{key:"render",value:function(){var t=this.props,n=t.choices,a=t.value,i=t.tabs,o=void 0===i?[]:i,c=t.showAll,u=void 0!==c&&c,s=t.allTitle,d=void 0===s?"\u5168\u90e8":s,f=t.onChange,p=n;return o.length&&(p=o.map((function(t){return e.isArray(t)?t:n.find((function(e){return e[0]===t}))}))),l.a.createElement(r["a"],{activeKey:a||u&&"",onChange:function(e){return f(e)},tabPosition:"top",type:"card"},u?l.a.createElement(r["a"].TabPane,{key:"",tab:d}):"",p.map((function(e){return l.a.createElement(r["a"].TabPane,{key:e[0],tab:e[1]})})))}}]),u}(l.a.PureComponent);t["a"]=s}).call(this,n("LvDl"))},rAFZ:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return V}));n("4csm");var r,a,i,o=n("2Fwu"),c=(n("9kbU"),n("vbHR")),u=n("oBTY"),l=n("9og8"),s=n("jrin"),d=n("fWQN"),f=n("mtLc"),p=n("yKVA"),m=n("879j"),h=(n("QV15"),n("DAsn")),b=n("k1fw"),v=(n("e+1C"),n("Nd5c")),_=(n("ER8q"),n("Ai5L")),g=(n("eE3J"),n("GSZB")),y=(n("eNCU"),n("pjJH")),O=n("tJVT"),j=(n("vmZS"),n("NjVP")),w=n("WmNS"),k=n.n(w),E=n("q1tI"),C=n.n(E),x=n("/MKj"),S=n("wd/R"),F=n.n(S),M=n("Ty5D"),P=n("jfUH"),A=n("rQ+i"),D=n("2CK3"),T=n.n(D),L=n("qoBN"),I=n("fapc"),U=function(t,n,r){return new Promise((function(a,i){t.validateFields((function(t,o){if(t)return i(t);var c=e.keyBy(n,"id"),u=e(o).pickBy((function(e){return void 0!==e&&""!==e&&!(Array.isArray(e)&&0===e.length)})).mapKeys((function(e,t){return t.replaceAll("__",".")})).map((function(e,t){if(t===r)return{field:t,operator:"=",value:e};var n=c[t];return{field:t,value:n.getValue?n.getValue(e):e,operator:n.getOperator(e)}})).value();return a(u)}))}))},V=j["a"].create()((function(t){var n,r,a=t.onSubmit,i=t.filters,o=t.formInstance,c=t.form,u=t.moreButtons,l=t.layout,s=t.tab,d=t.tabField,f=t.showButtons,p=void 0===f||f,m=o||c,w=Object(E["useState"])(!1),k=Object(O["a"])(w,2),x=k[0],S=k[1],F=Object(E["useState"])(!1),M=Object(O["a"])(F,2),P=M[0],A=M[1],D=function(){return U(m,i,d).then(a).catch(console.error)},L=function(e){e.preventDefault(),D()},I=C.a.createElement(C.a.Fragment,null,C.a.createElement(y["a"],{icon:"search",type:"primary",htmlType:"submit"},"\u67e5\u8be2"),C.a.createElement(y["a"],{onClick:function(){m.resetFields(),D()},style:{marginLeft:8,marginRight:8}},"\u91cd\u7f6e")),V=function(e){var t={},n=e.initialValue;return n&&(t={initialValue:n}),C.a.createElement(j["a"].Item,{label:e.label},m.getFieldDecorator(e.id.replaceAll(".","__"),t)(e.render()))};if("drawer"===l)n=i.map(V),r=C.a.createElement(v["a"],{gutter:{md:8,lg:24,xl:48},type:"flex",justify:"end"},C.a.createElement(_["a"],null,C.a.createElement("span",{className:T.a.submitButtons},C.a.createElement(y["a"],{id:"button",type:"primary",onClick:function(){return S(!0)},style:{marginLeft:8,marginRight:8}},C.a.createElement(g["a"],{type:"search"})," \u7b5b\u9009"))));else{var R=e.chunk(i,3);n=R.map((function(e,t){return C.a.createElement(v["a"],{key:e[0].id,gutter:{md:8,lg:24,xl:48},style:Object(b["a"])({},R.length>3&&!P&&t>1&&{display:"none"})},e.map((function(e){return C.a.createElement(_["a"],{key:e.id,md:8,sm:24},V(e))})))})),r=p&&C.a.createElement(v["a"],{gutter:{md:8,lg:24,xl:48},type:"flex",justify:"end"},C.a.createElement(_["a"],null,C.a.createElement("span",{className:T.a.submitButtons},I,u,R.length>3?C.a.createElement("a",{style:{marginLeft:8},onClick:function(){return A((function(e){return!e}))}},P?"\u6536\u8d77":"\u5c55\u5f00"," ",C.a.createElement(g["a"],{type:P?"up":"down"})):null)))}return"drawer"===l?C.a.createElement(j["a"],{layout:"vertical",onSubmit:L},C.a.createElement(h["a"],{title:"\u7b5b\u9009",width:420,onClose:function(){return S(!1)},visible:x,headerStyle:{width:"100%",zIndex:3,borderbottom:"1px solid #e9e9e9",left:0,top:0,position:"absolute"},bodyStyle:{paddingBottom:80}},C.a.createElement(j["a"],{layout:"vertical"},C.a.createElement("div",{style:{paddingTop:"50px"}},n),C.a.createElement("div",{style:{position:"absolute",right:0,bottom:0,width:"100%",borderTop:"1px solid #e9e9e9",padding:"10px 16px",background:"#fff",textAlign:"right"}},I))),r,s):C.a.createElement("div",{className:T.a.tableListForm},C.a.createElement(j["a"],{layout:"inline",onSubmit:L},n,r,s))})),R=(r=j["a"].create(),a=Object(x["c"])((function(e){var t=e.content,n=e.user.currentUser;return{content:t,currentUser:n}})),r(i=Object(M["n"])(i=a(i=function(t){Object(p["a"])(r,t);var n=Object(m["a"])(r);function r(){var e;Object(d["a"])(this,r);for(var t=arguments.length,a=new Array(t),i=0;i<t;i++)a[i]=arguments[i];return e=n.call.apply(n,[this].concat(a)),e.state={initialValues:[]},e}return Object(f["a"])(r,[{key:"componentDidMount",value:function(){this.getFieldValue()}},{key:"onTabSelect",value:function(e,t){var n=this.props,r=n.form,a=n.onSubmit,i=this.fields,o=this.tabField;""===t?r.resetFields([e]):r.setFieldsValue(Object(s["a"])({},e,t)),U(r,i,null===o||void 0===o?void 0:o.name).then(a)}},{key:"getFieldValue",value:function(){var e=Object(l["a"])(k.a.mark((function e(){var t,n,r,a,i,o,c,u,l,s=this;return k.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:t=this.props,n=t.location.query,r=t.dispatch,a=this.filterConf.map((function(e){return s.modelSchema.fields.find((function(t){return t.name===e}))})),i={},o=k.a.mark((function e(){var t,n,o,s,d,f,p,m,h,b,v,_,g;return k.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t=u[c],l=Object(O["a"])(t,2),n=l[0],o=l[1],s=a.find((function(e){return e.name===n})),!s){e.next=23;break}if(!Object(P["D"])(s)){e.next=15;break}return e.next=9,r({type:"content/choices",payload:{model:s.ref}});case 9:d=e.sent,f=d.find((function(e){return e[0].toString()===o})),p=Object(O["a"])(f,2),i[n]=p[1],e.next=23;break;case 15:if("mref"!==s.type){e.next=22;break}return e.next=18,r({type:"content/choices",payload:{model:s.ref}});case 18:m=e.sent,i[n]=[m.find((function(e){return e[0].toString()===o}))[1]],e.next=23;break;case 22:"string"===s.type||"bool"===s.type?i[n]=o:"datetime"!==s.type&&"date"!==s.type||(h="YYYY/MM/DD",b=o.split(","),v=Object(O["a"])(b,2),_=v[0],g=v[1],i[n]=[F()(_,h),F()(g,h)]);case 23:case"end":return e.stop()}}),e)})),c=0,u=Object.entries(n);case 5:if(!(c<u.length)){e.next=10;break}return e.delegateYield(o(),"t0",7);case 7:c++,e.next=5;break;case 10:this.setState({initialValues:i});case 11:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"filterConf",get:function(){var e=this.props,t=e.model,n=e.content.adminConfig,r=e.schemas,a=e.currentUser,i=this.props,o=i.filter,c=i.tabField;if(!o){var l=n[t]||{},s=l.filter;o=void 0===s?[]:s}if(!c){var d=n[t]||{},f=d.tabField;c=void 0===f?[]:f}var p={fields:c?[].concat(Object(u["a"])(o),[{name:c,widget:"tab",showAll:!0}]):o,currentUser:a,model:t,schemas:r},m=Object(A["b"])(p);return m}},{key:"modelSchema",get:function(){var e=this.props,t=e.model,n=e.content.schemas;return n[t]||{fields:[]}}},{key:"fields",get:function(){var t=this.props,n=t.content.schemas,r=t.model,a=t.location.query,i=this.filterConf,o=i.filter((function(t){return e.isString(t)||e.isString(t.name)})),c=[],u=this.state.initialValues;return o.forEach((function(e){try{var t=Object(I["b"])(n,r,e,{initialValues:u,query:a});c.push(t)}catch(i){console.error("filter\u914d\u7f6e\u9519\u8bef:",e,i)}})),c}},{key:"tabField",get:function(){return this.filterConf.find((function(e){return"tab"===e.widget}))}},{key:"handleExport",value:function(e){var t=this.props,n=t.onExport,r=t.form,a=this.fields,i=this.tabField;U(r,a,null===i||void 0===i?void 0:i.name).then((function(t){n(t,e)}))}},{key:"renderExport",value:function(t){var n=this;if(e.isArray(t)){var r=C.a.createElement(c["a"],{onClick:function(e){var t=e.key;return n.handleExport(t)}},t.map((function(e){return C.a.createElement(c["a"].Item,{key:e.key},e.name)})));return C.a.createElement(o["a"],{overlay:r},C.a.createElement(y["a"],null,"\u5bfc\u51fa\u6570\u636e ",C.a.createElement(g["a"],{type:"down"})))}return e.isBoolean(t)||e.isObject(t)&&!e.isEmpty(t.fields)?C.a.createElement(y["a"],{onClick:function(){return n.handleExport(e.isObject(t)&&t)}},t.name||"\u5bfc\u51fa\u6570\u636e"):""}},{key:"render",value:function(){var e=this,t=this.filterConf;if(!t||!t.length||!this.modelSchema)return null;var n,r=this.fields,a=this.tabField,i=this.props,o=i.form,c=i.exportable,u=i.model,l=i.layout,s=i.onSubmit,d=Object(P["p"])(u),f=r.filter((function(e){return e.fieldPath!==(a&&a.name)})).filter((function(e){var t,n;return null===(t=null===(n=d[e.field.name])||void 0===n?void 0:n.read)||void 0===t||t}));a&&(n=this.modelSchema.fields.find((function(e){return e.name===a.name})));var p=a&&n&&n.choices&&C.a.createElement(v["a"],null,C.a.createElement(_["a"],{span:24},C.a.createElement(j["a"].Item,null,o.getFieldDecorator(a.name)(C.a.createElement(L["a"],{choices:n.choices,tabs:a.tabs||[],showAll:a.showAll,allTitle:a.allTitle||"\u5168\u90e8",onChange:function(t){return e.onTabSelect(a.name,t)}})))));return C.a.createElement(V,{filters:f,onSubmit:s,formInstance:o,layout:l,tab:p,tabField:null===a||void 0===a?void 0:a.name,showButtons:!(a&&1===t.length),moreButtons:c?this.renderExport(c):""})}}]),r}(C.a.Component))||i)||i)||i);t["b"]=R}).call(this,n("LvDl"))},"rQ+i":function(e,t,n){"use strict";(function(e){n.d(t,"d",(function(){return l})),n.d(t,"a",(function(){return s})),n.d(t,"b",(function(){return d})),n.d(t,"c",(function(){return f}));var r=n("k1fw"),a=n("tJVT"),i=n("jfUH"),o=n("EBSl"),c=n("NnbD");function u(t,n,r){return t.filter((function(t){var i=!0;if(!e.isEmpty(t.groups)){var o=n.split("__"),c=Object(a["a"])(o,2),u=c[0],l=c[1],s="".concat(t.name,"_").concat(l,"_").concat(t.id,"__").concat(u),d=r.permissions.includes(s);if(!d)return d;i=i&&d}return i}))}function l(t,n,r){var u=Object(i["ub"])(),l=Object(i["V"])("staff_username"),s=Object(i["ob"])(),d=Object(i["Z"])(),f=Object(o["n"])(o["c"],n).map((function(e){return{type:e.rspType,action:e.action,title:e.title,permission:e.permission,show:e.show}}));return t.concat(f).filter((function(t){var o,f=s.filter((function(e){return e.endsWith(n)})).map((function(e){return e.split("_")[0]}));if(t.action in c["a"]&&!f.includes(c["a"][t.action]))return!1;if(r&&null!==(o=t.params)&&void 0!==o&&o.userField&&l){var p=d.username,m=r[t.params.userField];if(e.isArray(m)){var h=m.map((function(e){return e[l]})).includes(p);if(!h)return h}else{var b=m&&p===m[l];if(!b)return b}}if(!e.isEmpty(t.groups)&&!["edit","delete","detail"].includes(t.action)){var v=n.split("__"),_=Object(a["a"])(v,2),g=_[0],y=_[1],O="".concat(t.action,"_").concat(y,"_").concat(t.id,"__").concat(g),j=s.includes(O);if(!j)return j}if(t.permission){var w=s.includes(t.permission);if(!w)return w}if("boolean"===typeof t.show){var k=t.show;if(!k)return k}if(r&&"string"===typeof t.show){var E=t.show&&Object(i["i"])(t.show,(function(e){return r[e]}));if(!E)return E}if(r&&"function"===typeof t.show)return t.show(r,n);if(r&&!e.isEmpty(t.showIf)){var C=Object(i["G"])(t.showIf,r,u,n);if(!C)return C}return!0}))}function s(e){var t=e.actions,n=void 0===t?[{}]:t,a=e.currentUser,i=e.model,o=[];return n.map((function(e){return o.push(Object(r["a"])({},e))})),u(o,i,a)}function d(e){var t=e.fields,n=void 0===t?[{}]:t,r=e.currentUser,a=e.model;return u(n,a,r)}function f(e){var t=e.fields,n=void 0===t?{}:t,r=e.currentUser,a=e.model,i=[];i.push(n);var o=u(i,a,r);return o[0]}}).call(this,n("LvDl"))},"sMR+":function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return f}));var r=n("/MKj"),a=n("wiuW"),i=n("3i6F"),o=n("jfUH"),c=n("rQ+i"),u=n("eljF"),l=e.flow(Object(o["d"])((function(e){var t=e.inlineActions,n=e.model;return{validInlineActions:Object(c["d"])(t||[],n)}})),Object(r["c"])((function(e){var t=e.content,n=e.user.currentUser,r=e.bsmSetting;return{content:t,currentUser:n,bsmSetting:r}})),Object(o["d"])((function(e){var t=e.model;return{getDisplayWidgetName:Object(i["l"])(t),getDisplayWidgetNameByModel:Object(i["m"])()}}))),s=e.mapValues(a["b"],l),d=l(u["a"]),f=function(e){return s[e]||d}}).call(this,n("LvDl"))},sw8h:function(e,t,n){"use strict";n("+Xjd");var r=n("Ij4x"),a=n("q1tI"),i=n.n(a),o=n("wd/R"),c=n.n(o),u="YYYY-MM-DD HH:mm:ss";function l(e){var t=e.value,n=e.onChange;return i.a.createElement(r["a"],{value:t?c()(c()(t,"X").format(u),u):null,onChange:function(e){return e&&n(e.unix())},format:u,showTime:!0})}t["a"]=l},txBY:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return O}));var r=n("jrin"),a=(n("GPKB"),n("mFAc")),i=n("k1fw"),o=n("WmNS"),c=n.n(o),u=n("Qyje"),l=n("RLxJ"),s=n("s4NR"),d=n("/MKj"),f=n("mmaM"),p=n("jfUH"),m=n("VW+w"),h=function(){return Object(s["parse"])(window.location.href.split("?")[1])},b=function t(n,r){return e.mapValues(n,(function(n,a){var i=r.fields,o=i.find((function(e){return e.name===a}));if(o){if(["mref","ref","oref"].includes(o.type)){if(Array.isArray(n))return n.map((function(e){var t;return null!==(t=Object(p["K"])(e,o.refTo))&&void 0!==t?t:e}));if(e.isObject(n)){if(o.refTo in n)return n[o.refTo];if(Object(p["L"])(o.ref)in n)return Object(p["K"])(n,o.ref)}}else{if("bref"===o.type)return n.map((function(n){return e.isObject(n)?t(n,Object(p["s"])(o.ref)):n}));if("boref"===o.type)return e.isObject(n)?t(n,Object(p["s"])(o.ref)):n}return n}}))},v=window.$$schemas,_=window.$$admins,g=e.cloneDeep(_);v&&_&&Promise.resolve().then(n.bind(null,"VW+w")).then((function(e){var t=e.configPreprocess;t(_,v),t(g,v,{noDefault:!0})}));var y={namespace:"content",state:{data:{},choices:{},schemas:null!==v&&void 0!==v?v:{},adminConfig:null!==_&&void 0!==_?_:{},adminWithoutDefault:g,stat:{},all:{}},effects:{fetch:c.a.mark((function e(t,n){var r,a,o,u,l,s,d,p,m;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=t.payload,a=n.call,o=n.put,u=n.select,l=r.model,s=r.extra,s=void 0===s?{}:s,d=s.view,e.next=7,u((function(e){return e.content.data[l]}));case 7:return p=e.sent,e.prev=8,e.next=11,a(f["queryContent"],Object(i["a"])(Object(i["a"])({},r),{},{page:r.page||p&&p.pagination&&p.pagination.current||1,size:r.size||p&&p.pagination&&p.pagination.pageSize||30}));case 11:m=e.sent,e.next=17;break;case 14:return e.prev=14,e.t0=e["catch"](8),e.abrupt("return",Promise.reject(e.t0));case 17:return e.next=19,o({type:"save",payload:{model:l,view:d,response:m}});case 19:return e.abrupt("return",m);case 20:case"end":return e.stop()}}),e,null,[[8,14]])})),fetchAll:c.a.mark((function e(t,n){var r,a,o,u,l,s,d;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=t.payload,a=n.call,o=n.put,u=r.model,l=r.extra,l=void 0===l?{}:l,s=l.view,e.prev=5,e.next=8,a(f["queryContent"],Object(i["a"])({},r));case 8:d=e.sent,e.next=14;break;case 11:return e.prev=11,e.t0=e["catch"](5),e.abrupt("return",Promise.reject(e.t0));case 14:return d=d.list,e.next=17,o({type:"saveAll",payload:{model:u,response:d,view:s}});case 17:return e.abrupt("return",d);case 18:case"end":return e.stop()}}),e,null,[[5,11]])})),download:c.a.mark((function e(t,n){var r,a,o;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=t.payload,a=n.call,e.prev=2,e.next=5,a(f["downloadContent"],Object(i["a"])({},r));case 5:o=e.sent,e.next=11;break;case 8:return e.prev=8,e.t0=e["catch"](2),e.abrupt("return",Promise.reject(e.t0));case 11:return e.abrupt("return",o);case 12:case"end":return e.stop()}}),e,null,[[2,8]])})),create:c.a.mark((function e(t,n){var r,o,u,l,s,d;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=t.payload,o=n.call,u=n.put,l=r.values,s=r.schema,e.prev=3,e.next=6,o(f["createContent"],Object(i["a"])(Object(i["a"])({},r),{},{values:b(l,s)}));case 6:d=e.sent,e.next=12;break;case 9:return e.prev=9,e.t0=e["catch"](3),e.abrupt("return",Promise.reject(e.t0));case 12:return a["a"].success("\u63d0\u4ea4\u6210\u529f"),e.next=15,u({type:"clearAllOfModel",payload:{model:r.model}});case 15:return e.abrupt("return",d);case 16:case"end":return e.stop()}}),e,null,[[3,9]])})),createTag:c.a.mark((function e(t,n){var r,a,i,o,u;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=t.payload,a=n.call,i=n.put,o=r.model,e.prev=3,e.next=6,a(f["createContent"],r);case 6:u=e.sent,e.next=12;break;case 9:return e.prev=9,e.t0=e["catch"](3),e.abrupt("return",Promise.reject(e.t0));case 12:return e.next=14,i({type:"clearAllOfModel",payload:{model:r.model}});case 14:return e.next=16,i({type:"saveDetail",payload:{model:o,id:Object(p["K"])(u,o),response:u}});case 16:return e.abrupt("return",u);case 17:case"end":return e.stop()}}),e,null,[[3,9]])})),update:c.a.mark((function e(t,n){var r,o,u,l,s,d;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=t.payload,o=n.call,u=n.put,l=r.values,s=r.schema,e.prev=3,e.next=6,o(f["updateFullContent"],Object(i["a"])(Object(i["a"])({},r),{},{values:b(l,s)}));case 6:d=e.sent,e.next=12;break;case 9:return e.prev=9,e.t0=e["catch"](3),e.abrupt("return",Promise.reject(e.t0));case 12:return a["a"].success("\u5df2\u4fdd\u5b58"),e.next=15,u({type:"clearAllOfModel",payload:{model:r.model}});case 15:return e.next=17,u({type:"detail",payload:{model:r.model,id:r.id}});case 17:return e.abrupt("return",d);case 18:case"end":return e.stop()}}),e,null,[[3,9]])})),detail:c.a.mark((function(e,t){var n,r,a,o,u,l,s,d;return c.a.wrap((function(c){while(1)switch(c.prev=c.next){case 0:return n=e.payload,r=t.call,a=t.put,o=n.model,u=n.id,l=n.wrapOptions,s=n.detail,c.prev=3,c.next=6,r(f["contentDetail"],Object(i["a"])(Object(i["a"])({},n),{},{detail:s}),l);case 6:d=c.sent,c.next=12;break;case 9:return c.prev=9,c.t0=c["catch"](3),c.abrupt("return",Promise.reject(c.t0));case 12:return c.next=14,a({type:"saveDetail",payload:{model:o,id:u,response:d}});case 14:return c.abrupt("return",d);case 15:case"end":return c.stop()}}),s,null,[[3,9]])})),delete:c.a.mark((function e(t,n){var r,a,i,o,u,l;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=t.payload,a=n.call,i=n.put,o=r.model,u=r.id,e.prev=3,e.next=6,a(f["deleteContent"],{model:o,id:u});case 6:l=e.sent,e.next=12;break;case 9:return e.prev=9,e.t0=e["catch"](3),e.abrupt("return",Promise.reject(e.t0));case 12:return e.next=14,i({type:"clearAllOfModel",payload:{model:r.model}});case 14:return e.abrupt("return",l);case 15:case"end":return e.stop()}}),e,null,[[3,9]])})),batchAction:c.a.mark((function e(t,n){var r,a;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=t.payload,a=n.call,e.prev=2,e.next=5,a(f["batchAction"],r);case 5:return e.abrupt("return",e.sent);case 8:return e.prev=8,e.t0=e["catch"](2),e.abrupt("return",Promise.reject(e.t0));case 11:case"end":return e.stop()}}),e,null,[[2,8]])})),patch:c.a.mark((function e(t,n){var r,a,i,o,u,l,s,d,p;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=t.payload,a=n.call,i=n.put,o=r.model,u=r.id,l=r.newValues,s=r.schema,d=r.appendModeFields,e.prev=3,e.next=6,a(f["updateContent"],{model:o,id:u,newValues:b(l,s),appendModeFields:d});case 6:p=e.sent,e.next=12;break;case 9:return e.prev=9,e.t0=e["catch"](3),e.abrupt("return",Promise.reject(e.t0));case 12:return e.next=14,i({type:"clearAllOfModel",payload:{model:r.model}});case 14:return e.abrupt("return",p);case 15:case"end":return e.stop()}}),e,null,[[3,9]])})),choices:c.a.mark((function e(t,n){var r,a,i;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=t.payload,a=n.call,e.prev=2,e.next=5,a(f["getChoices"],r);case 5:i=e.sent,e.next=11;break;case 8:return e.prev=8,e.t0=e["catch"](2),e.abrupt("return",Promise.reject(e.t0));case 11:return e.abrupt("return",i);case 12:case"end":return e.stop()}}),e,null,[[2,8]])})),cacheAll:c.a.mark((function e(t,n){var r,a,i,o,u,l,s;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=t.payload,a=n.call,i=n.put,o=n.select,e.next=4,o((function(e){return e.content.all[r.model]}));case 4:if(u=e.sent,!u){e.next=7;break}return e.abrupt("return",u);case 7:return e.prev=7,e.next=10,a(f["queryContent"],{model:r.model,expandFields:[]});case 10:s=e.sent,l=s.list,e.next=17;break;case 14:return e.prev=14,e.t0=e["catch"](7),e.abrupt("return",Promise.reject(e.t0));case 17:return e.next=19,i({type:"saveAllOfModel",payload:{model:r.model,response:l}});case 19:return e.next=21,o((function(e){return e.content.all[r.model]}));case 21:return e.abrupt("return",e.sent);case 22:case"end":return e.stop()}}),e,null,[[7,14]])})),getSchemas:c.a.mark((function e(t,n){var r,a,i;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=n.call,a=n.put,e.prev=1,e.next=4,r(f["getSchemas"]);case 4:i=e.sent,e.next=10;break;case 7:return e.prev=7,e.t0=e["catch"](1),e.abrupt("return",Promise.reject(e.t0));case 10:return e.next=12,a({type:"saveSchema",payload:{schemas:i}});case 12:return e.abrupt("return",i);case 13:case"end":return e.stop()}}),e,null,[[1,7]])})),getAdminConfig:c.a.mark((function e(t,n){var r,a,i;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=n.call,a=n.put,e.prev=1,e.next=4,r(f["getAdminConfig"]);case 4:i=e.sent,e.next=10;break;case 7:return e.prev=7,e.t0=e["catch"](1),e.abrupt("return",Promise.reject(e.t0));case 10:return e.next=12,a({type:"saveAdminConfig",payload:{adminConfig:i}});case 12:return e.abrupt("return",i);case 13:case"end":return e.stop()}}),e,null,[[1,7]])})),getConfig:c.a.mark((function t(n,r){var a,i,o,u;return c.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return a=r.call,i=r.put,t.prev=1,t.next=4,a(f["getConfig"]);case 4:o=t.sent,u=e.cloneDeep(o.admins),Object(m["configPreprocess"])(o.admins,o.schemas),Object(m["configPreprocess"])(u,o.schemas,{noDefault:!0}),t.next=13;break;case 10:return t.prev=10,t.t0=t["catch"](1),t.abrupt("return",Promise.reject(t.t0));case 13:return t.next=15,i({type:"saveConfig",payload:{config:o,adminWithoutDefault:u}});case 15:return t.abrupt("return",o);case 16:case"end":return t.stop()}}),t,null,[[1,10]])})),updateAdmin:c.a.mark((function t(n,o){var u,l,s,d,p,h,b,v,_,g,y;return c.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return u=n.payload,l=u.model,s=u.config,d=o.call,p=o.put,h=o.select,t.next=4,h((function(e){return e.content.adminConfig}));case 4:return b=t.sent,t.next=7,h((function(e){return e.content.schemas}));case 7:return v=t.sent,_=Object(i["a"])(Object(i["a"])({},b),{},Object(r["a"])({},l,e.cloneDeep(s))),Object(m["configPreprocess"])(_,v),t.next=12,h((function(e){return e.content.adminWithoutDefault}));case 12:return g=t.sent,y=Object(i["a"])(Object(i["a"])({},g),{},Object(r["a"])({},l,e.cloneDeep(s))),t.prev=14,t.next=17,d(f["updateAdmin"],{model:l,config:s});case 17:t.next=22;break;case 19:return t.prev=19,t.t0=t["catch"](14),t.abrupt("return",Promise.reject(t.t0));case 22:return t.next=24,p({type:"saveAdminConfig",payload:{adminConfig:_,adminWithoutDefault:y}});case 24:return a["a"].success("\u66f4\u65b0\u6210\u529f"),t.abrupt("return",!0);case 26:case"end":return t.stop()}}),t,null,[[14,19]])})),cloudFunction:c.a.mark((function e(t,n){var r,a,i,o,u,l;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=n.call,a=t.payload,i=a.model,o=a.functionName,u=a.params,e.next=4,r(f["cloudFunction"],{model:i,functionName:o,params:u});case 4:if(l=e.sent,!(parseInt(l.error_code,10)>0)){e.next=7;break}return e.abrupt("return",Promise.reject(l.error_message));case 7:return e.abrupt("return",l.message);case 8:case"end":return e.stop()}}),e)})),action:c.a.mark((function e(t,n){var r,a,o,u,l,s,d,p;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=n.call,a=n.put,o=t.payload,u=o.model,l=o.action,s=o.id,d=o.params,e.next=4,r(f["cloudFunction"],{model:u,functionName:l,params:Object(i["a"])({id:s},d)});case 4:if(p=e.sent,!(parseInt(p.error_code,10)>0)){e.next=7;break}return e.abrupt("return",Promise.reject(p.error_message));case 7:return e.next=9,a({type:"fetch",payload:{model:u}});case 9:return e.abrupt("return",p);case 10:case"end":return e.stop()}}),e)})),statistics:c.a.mark((function e(t,n){var r,a,i,o,u,l,s,d,p;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=n.call,a=n.put,i=n.select,o=t.payload,u=o.model,l=o.filters,s=void 0===l?[]:l,e.next=4,i((function(e){return e.content.adminConfig[u]}));case 4:if(d=e.sent,d.statistics){e.next=7;break}return e.abrupt("return",null);case 7:return e.prev=7,e.next=10,r(f["statistics"],{model:u,filters:s});case 10:p=e.sent,e.next=16;break;case 13:return e.prev=13,e.t0=e["catch"](7),e.abrupt("return",Promise.reject(e.t0));case 16:return e.next=18,a({type:"saveStat",payload:{model:u,stat:p}});case 18:return e.abrupt("return",p);case 19:case"end":return e.stop()}}),e,null,[[7,13]])})),login:c.a.mark((function e(t,n){var r,a,i,o,u,s,d,p,m;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=t.payload,a=n.call,i=n.put,e.next=4,a(f["login"],r);case 4:return o=e.sent,e.next=7,i({type:"login/changeLoginStatus",payload:o});case 7:"ok"===o.status&&(u=new URL(window.location.href),s=h(),d=s,p=d.redirect,p&&p.startsWith("http")&&(m=new URL(p),m.origin===u.origin?(p=p.substr(u.origin.length),p.match(/^\/.*#/)&&(p=p.substr(p.indexOf("#")+1))):p="/"),l["a"].replace(p||"/"));case 8:case"end":return e.stop()}}),e)})),getVersions:c.a.mark((function e(t,n){var r,a,i;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=n.call,a=n.put,e.next=3,r(f["getVersion"]);case 3:return i=e.sent,e.next=6,a({type:"saveVersions",payload:i});case 6:case"end":return e.stop()}}),e)})),logout:c.a.mark((function e(t,n){var r,a,i,o,s;return c.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return r=n.call,a=n.select,e.next=3,r(f["accountLogout"]);case 3:return i=h(),o=i.redirect,e.next=6,a((function(e){return e.router.location.pathname}));case 6:s=e.sent,"/user/login"===s||o||l["a"].replace({pathname:"/user/login",search:Object(u["stringify"])({redirect:window.location.origin+s})});case 8:case"end":return e.stop()}}),e)}))},reducers:{save:function(e,t){var n=t.payload,r=n.model,a=n.view,o=n.response,c=e.data,u=a?"".concat(r,"#").concat(a):r;return c[u]?(c[u]=Object(i["a"])(Object(i["a"])({},c[u]),{},{list:o.list}),c[u]=Object(i["a"])(Object(i["a"])({},c[u]),{},{pagination:o.pagination})):c[u]=o,Object(i["a"])(Object(i["a"])({},e),{},{data:c})},saveAll:function(e,t){var n=t.payload,r=n.model,a=n.view,o=n.response,c=e.data,u=a?"".concat(r,"#").concat(a):r;return c[u]?(c[u].list=o,delete c[u].pagination):c[u]={list:o},Object(i["a"])(Object(i["a"])({},e),{},{data:c})},saveChoices:function(e,t){var n=t.payload,r=n.model,a=n.response,o=e.choices;return o[r]=a,Object(i["a"])(Object(i["a"])({},e),{},{choices:o})},saveAllOfModel:function(e,t){var n=t.payload,a=n.model,o=n.response;return Object(i["a"])(Object(i["a"])({},e),{},{all:Object(i["a"])(Object(i["a"])({},e.all),{},Object(r["a"])({},a,o))})},clearAllOfModel:function(e,t){var n=t.payload.model,r=e.all;return delete r[n],Object(i["a"])(Object(i["a"])({},e),{},{all:Object(i["a"])({},r)})},saveDetail:function(e,t){var n,a=t.payload,o=a.model,c=a.id,u=a.response;return Object(i["a"])(Object(i["a"])({},e),{},{data:Object(i["a"])(Object(i["a"])({},e.data),{},Object(r["a"])({},o,Object(i["a"])(Object(i["a"])({},e.data[o]),{},{detail:Object(i["a"])(Object(i["a"])({},null===(n=e.data[o])||void 0===n?void 0:n.detail),{},Object(r["a"])({},c,u))})))})},saveSchema:function(e,t){var n=t.payload.schemas;return Object(i["a"])(Object(i["a"])({},e),{},{schemas:n})},saveAdminConfig:function(e,t){var n=t.payload,r=n.adminConfig,a=n.adminWithoutDefault;return Object(i["a"])(Object(i["a"])({},e),{},{adminConfig:r,adminWithoutDefault:a})},saveConfig:function(e,t){var n=t.payload,r=n.config,a=r.schemas,o=r.admins,c=n.adminWithoutDefault;return Object(i["a"])(Object(i["a"])({},e),{},{schemas:a,adminConfig:o,adminWithoutDefault:c})},saveStat:function(e,t){var n=t.payload,a=n.model,o=n.stat;return Object(i["a"])(Object(i["a"])({},e),{},{stat:Object(i["a"])(Object(i["a"])({},e.stat),{},Object(r["a"])({},a,o))})},saveVersions:function(e,t){var n=t.payload;return Object(i["a"])(Object(i["a"])({},e),n)}}};t["b"]=y;var O=Object(d["c"])((function(e){var t=e.content;return Object(i["a"])({},t)}),(function(t){return e.mapValues(y.effects,(function(e,n){return function(e){return t({type:"content/".concat(n),payload:e})}}))}))}).call(this,n("LvDl"))},uCub:function(e,t,n){"use strict";n.d(t,"a",(function(){return u}));var r=n("oBTY"),a=n("k1fw"),i=n("4b23"),o=n.n(i),c=n("BGR+"),u=function(e,t,n){var i,u,l=null===(i=e[n])||void 0===i?void 0:i.details,s=null===(u=e[n])||void 0===u?void 0:u.detail,d=t[n],f=[];if(s&&(s.sections&&"tab"===s.style?s.sections.forEach((function(e){f.push(Object(a["a"])(Object(a["a"])({},s),{},{key:o()(6),title:e.title,sections:[Object(c["a"])(e,"title")],style:"group"}))})):f.push(Object(a["a"])(Object(a["a"])({key:o()(6)},s),{},{style:"group"}))),l){var p=function(e){return e.key?Object(a["a"])({},e):Object(a["a"])(Object(a["a"])({},e),{},{key:o()(6)})};f=[].concat(Object(r["a"])(f),Object(r["a"])(l.map(p)))}return f.forEach((function(e){var t;null===e||void 0===e||null===(t=e.sections)||void 0===t||t.forEach((function(e){e.fields=e.fields.filter((function(e){return d.fields.find((function(t){return t.name===((null===e||void 0===e?void 0:e.name)||e)}))}))}))})),f}},uRgk:function(e,t,n){"use strict";n.d(t,"a",(function(){return b}));n("52nx");var r=n("7bDm"),a=(n("6dnR"),n("CQJL")),i=(n("eE3J"),n("GSZB")),o=n("fWQN"),c=n("mtLc"),u=n("yKVA"),l=n("879j"),s=n("q1tI"),d=n.n(s),f=n("AAgL"),p=n("3i6F"),m={filled:["account-book","alert","alipay-circle","alipay-square","aliwangwang","amazon-circle","android","amazon-square","api","appstore","audio","apple","backward","bank","behance-circle","bell","behance-square","book","box-plot","bug","bulb","calculator","build","calendar","camera","car","caret-down","caret-left","caret-right","carry-out","caret-up","check-circle","check-square","chrome","ci-circle","clock-circle","close-circle","cloud","close-square","code-sandbox-square","code-sandbox-circle","code","codepen-circle","compass","codepen-square","contacts","container","control","copy","copyright-circle","credit-card","crown","customer-service","dashboard","delete","diff","dingtalk-circle","database","dingtalk-square","dislike","dollar-circle","down-circle","down-square","dribbble-circle","dribbble-square","dropbox-circle","dropbox-square","environment","edit","exclamation-circle","euro-circle","experiment","eye-invisible","eye","facebook","fast-backward","fast-forward","file-add","file-excel","file-exclamation","file-image","file-markdown","file-pdf","file-ppt","file-text","file-unknown","file-word","file-zip","file","filter","fire","flag","folder-add","folder","folder-open","forward","frown","fund","funnel-plot","gift","github","gitlab","golden","google-circle","google-plus-circle","google-plus-square","google-square","hdd","heart","highlight","home","hourglass","html5","idcard","ie-circle","ie-square","info-circle","instagram","insurance","interaction","interation","layout","left-circle","left-square","like","linkedin","lock","mail","medicine-box","medium-circle","medium-square","meh","message","minus-circle","minus-square","mobile","money-collect","pause-circle","pay-circle","notification","phone","picture","pie-chart","play-circle","play-square","plus-circle","plus-square","pound-circle","printer","profile","project","pushpin","property-safety","qq-circle","qq-square","question-circle","read","reconciliation","red-envelope","reddit-circle","reddit-square","rest","right-circle","rocket","right-square","safety-certificate","save","schedule","security-scan","setting","shop","shopping","sketch-circle","sketch-square","skin","slack-circle","skype","slack-square","sliders","smile","snippets","sound","star","step-backward","step-forward","stop","switcher","tablet","tag","tags","taobao-circle","taobao-square","tool","thunderbolt","trademark-circle","twitter-circle","trophy","twitter-square","unlock","up-circle","up-square","usb","video-camera","wallet","warning","wechat","weibo-circle","windows","yahoo","weibo-square","yuque","youtube","zhihu-circle","zhihu-square"],outlined:["account-book","alert","alipay-circle","aliwangwang","android","api","appstore","audio","apple","backward","bank","bell","behance-square","book","box-plot","bug","bulb","calculator","build","calendar","camera","car","caret-down","caret-left","caret-right","carry-out","caret-up","check-circle","check-square","chrome","clock-circle","close-circle","cloud","close-square","code","codepen-circle","compass","contacts","container","control","copy","credit-card","crown","customer-service","dashboard","delete","diff","database","dislike","down-circle","down-square","dribbble-square","environment","edit","exclamation-circle","experiment","eye-invisible","eye","facebook","fast-backward","fast-forward","file-add","file-excel","file-exclamation","file-image","file-markdown","file-pdf","file-ppt","file-text","file-unknown","file-word","file-zip","file","filter","fire","flag","folder-add","folder","folder-open","forward","frown","fund","funnel-plot","gift","github","gitlab","hdd","heart","highlight","home","hourglass","html5","idcard","info-circle","instagram","insurance","interaction","interation","layout","left-circle","left-square","like","linkedin","lock","mail","medicine-box","meh","message","minus-circle","minus-square","mobile","money-collect","pause-circle","pay-circle","notification","phone","picture","pie-chart","play-circle","play-square","plus-circle","plus-square","printer","profile","project","pushpin","property-safety","question-circle","read","reconciliation","red-envelope","rest","right-circle","rocket","right-square","safety-certificate","save","schedule","security-scan","setting","shop","shopping","skin","skype","slack-square","sliders","smile","snippets","sound","star","step-backward","step-forward","stop","switcher","tablet","tag","tags","taobao-circle","tool","thunderbolt","trophy","unlock","up-circle","up-square","usb","video-camera","wallet","warning","wechat","weibo-circle","windows","yahoo","weibo-square","yuque","youtube","alibaba","align-center","align-left","align-right","alipay","aliyun","amazon","ant-cloud","apartment","ant-design","area-chart","arrow-left","arrow-down","arrow-up","arrows-alt","arrow-right","audit","bar-chart","barcode","bars","behance","bg-colors","block","bold","border-bottom","border-left","border-outer","border-inner","border-right","border-horizontal","border-top","border-verticle","border","branches","check","ci","close","cloud-download","cloud-server","cloud-sync","cloud-upload","cluster","codepen","code-sandbox","colum-height","column-width","column-height","coffee","copyright","dash","deployment-unit","desktop","dingding","disconnect","dollar","double-left","dot-chart","double-right","down","drag","download","dribbble","dropbox","ellipsis","enter","euro","exception","exclamation","export","fall","file-done","file-jpg","file-protect","file-sync","file-search","font-colors","font-size","fork","form","fullscreen-exit","fullscreen","gateway","global","google-plus","gold","google","heat-map","history","ie","import","inbox","info","italic","key","issues-close","laptop","left","line-chart","link","line-height","line","loading-3-quarters","loading","login","logout","man","medium","medium-workmark","menu-unfold","menu-fold","menu","minus","monitor","more","ordered-list","number","pause","percentage","paper-clip","pic-center","pic-left","pic-right","plus","pound","poweroff","pull-request","qq","question","radar-chart","qrcode","radius-bottomleft","radius-bottomright","radius-upleft","radius-setting","radius-upright","reddit","redo","reload","retweet","right","rise","rollback","safety","robot","scan","search","scissor","select","shake","share-alt","shopping-cart","shrink","sketch","slack","small-dash","solution","sort-descending","sort-ascending","stock","swap-left","swap-right","strikethrough","swap","sync","table","team","taobao","to-top","trademark","transaction","twitter","underline","undo","unordered-list","up","upload","user-add","user-delete","usergroup-add","user","usergroup-delete","vertical-align-bottom","vertical-align-middle","vertical-align-top","vertical-left","vertical-right","weibo","wifi","zhihu","woman","zoom-out","zoom-in"]},h=m,b=function(e){Object(u["a"])(n,e);var t=Object(l["a"])(n);function n(){var e;Object(o["a"])(this,n);for(var r=arguments.length,a=new Array(r),i=0;i<r;i++)a[i]=arguments[i];return e=t.call.apply(t,[this].concat(a)),e.state={visible:!1,theme:"outlined"},e.showModal=function(){e.setState({visible:!0})},e.handleOk=function(){e.setState({visible:!1})},e.handleCancel=function(){e.setState({visible:!1})},e.handleSizeChange=function(t){e.setState({theme:t.target.value})},e}return Object(c["a"])(n,[{key:"render",value:function(){var e=this,t=this.props,n=t.value,o=t.onChange,c=this.state.theme;return d.a.createElement("div",null,d.a.createElement("div",{style:{display:"flex",alignItems:"center"}},n&&Object(p["b"])({icon:n,restProps:{style:{fontSize:24,marginRight:10}}}),d.a.createElement("div",null,d.a.createElement("span",{style:{color:"#1890ff",cursor:"pointer",marginRight:10},onClick:this.showModal},"\u9009\u62e9\u56fe\u6807"),!!n&&d.a.createElement(i["a"],{onClick:function(){return o("")},type:"close"}))),d.a.createElement(r["a"],{visible:this.state.visible,onOk:this.handleOk,onCancel:this.handleCancel,width:"60%",footer:null},d.a.createElement(a["a"].Group,{value:c,onChange:this.handleSizeChange},d.a.createElement(a["a"].Button,{value:"outlined"},"\u7ebf\u6846\u98ce\u683c"),d.a.createElement(a["a"].Button,{value:"filled"},"\u5b9e\u5e95\u98ce\u683c")),d.a.createElement("div",{style:{display:"flex",flexWrap:"wrap",marginTop:10,height:800,overflowY:"scroll"}},h[c].map((function(t){var r="".concat(t,"__").concat(c),a=r===n;return d.a.createElement("div",{style:{padding:10,backgroundColor:a?"#1890ff":"white"},key:t},Object(p["b"])({icon:r,restProps:{style:{fontSize:32,color:a?"white":"#595959"},onClick:function(){e.handleOk(),o(r)}}}))})))))}}]),n}(f["a"])},vbsh:function(e,t,n){"use strict";n.d(t,"b",(function(){return f})),n.d(t,"c",(function(){return p})),n.d(t,"d",(function(){return m})),n.d(t,"a",(function(){return h}));var r=n("PpiC"),a=n("9og8"),i=n("k1fw"),o=n("WmNS"),c=n.n(o),u=n("LvDl"),l=n.n(u),s=["Create","Update","Delete","List","Detail"],d={},f={};s.forEach((function(e){f["before".concat(e)]="before".concat(e),f["after".concat(e)]="after".concat(e)}));var p=function(e,t,n){e in d||(d[e]=[]),d[e].push({events:Array.isArray(t)?t:[t],handler:n})},m=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};e in d&&d[e].forEach((function(r){var a=r.events,o=r.handler;a.includes(t)&&o(Object(i["a"])({model:e,event:t},n))}))},h=l()(s).map((function(e){return[e,function(t){return function(){var n=Object(a["a"])(c.a.mark((function n(a){var o,u,l,s,d,f,p=arguments;return c.a.wrap((function(n){while(1)switch(n.prev=n.next){case 0:for(o=a.model,u=Object(r["a"])(a,["model"]),m(o,"before".concat(e)),l=p.length,s=new Array(l>1?l-1:0),d=1;d<l;d++)s[d-1]=p[d];return n.next=5,t.apply(void 0,[Object(i["a"])({model:o},u)].concat(s));case 5:return f=n.sent,m(o,"after".concat(e)),n.abrupt("return",f);case 8:case"end":return n.stop()}}),n)})));return function(e){return n.apply(this,arguments)}}()}]})).fromPairs().value()},wiuW:function(e,t,n){"use strict";n.d(t,"b",(function(){return U})),n.d(t,"a",(function(){return V})),n.d(t,"c",(function(){return R})),n.d(t,"e",(function(){return W})),n.d(t,"d",(function(){return q}));var r=n("oBTY"),a=n("0Owb"),i=n("k1fw"),o=n("q1tI"),c=n.n(o),u=n("eljF"),l=n("2mwZ"),s=n("mmaM"),d=n("3i6F");function f(e){function t(e){var t,n=e.widgetProps,r=e.record,o=n.field;if("default"!==(null===o||void 0===o?void 0:o.name))return c.a.createElement(d["a"],e);var u=r[null===o||void 0===o?void 0:o.name],s=Object(i["a"])({},n),f=Object(i["a"])({},r);f[o.name]=null===u||void 0===u?void 0:u.value;var p=r.name,m=r.type,h=r.verbose_name,b=r.primary_key,v=r.choice_items;return u&&u.value&&(s.field=Object(i["a"])({name:p,displayName:h||p,primaryKey:b,type:l["b"][m]},null!==v&&void 0!==v&&v.length?{choices:v.map((function(e){return[e.value,e.name]}))}:{})),c.a.createElement(d["a"],Object(a["a"])({},e,{widgetProps:s,record:f,widgetName:null===(t=d["e"][l["b"][m]||"string"])||void 0===t?void 0:t[0]}))}var n=e.fetch,o=e.model;return c.a.createElement(u["a"],Object(a["a"])({},e,{fetch:function(e){return n(Object(i["a"])(Object(i["a"])({},e),{},{expandFields:[].concat(Object(r["a"])(Object(s["getExpandFields"])(o,"display")),["choice_items"])}))},renderColumn:t}))}var p=n("/MKj");function m(e){var t=e.tableActions,n=void 0===t?[]:t,i=e.provider,o=Object(r["a"])(n);return"wechat"===i&&o.push({type:"action",title:"\u540c\u6b65\u4f01\u4e1a\u5fae\u4fe1\u7528\u6237",params:{action:"export_wechat_work_departmemt_user"}}),"dingding"===i&&o.push({action:"action",title:"\u540c\u6b65\u9489\u9489\u7528\u6237",params:{action:"export_dingding_departmemt_user"}}),c.a.createElement(u["a"],Object(a["a"])({},e,{tableActions:o}))}var h=Object(p["c"])((function(e){var t=e.bsmSetting.third_party_provider;return{provider:t}}))(m),b=n("yRbM"),v=n("tJVT"),_=n("PpiC"),g=n("jrin"),y=n("fWQN"),O=n("mtLc"),j=n("w4Tj"),w=n("oZsa"),k=n("yKVA"),E=n("879j"),C=n("xJcd"),x=["bigint","timestamp","bigauto"],S=["auto","int","positiveint","smallint","positivesmallint"],F=["uuid","ipaddr","image","url","email","slug","char","file"],M=["array","object","text"],P=[x,F,M,["time"],["date"],["datetime"],["decimal"],S,["float"],["bool"]],A=["bigint","bigauto","uuid","email","slug","char","auto","int","positiveint","smallint","positivesmallint"];function D(e){return P.find((function(t){return t.includes(e)}))}var T={operator:"or",children:[{field:"unique",operator:"=",value:!0},{field:"primary_key",operator:"=",value:!0}]},L=function(e){Object(k["a"])(n,e);var t=Object(E["a"])(n);function n(){return Object(y["a"])(this,n),t.apply(this,arguments)}return Object(O["a"])(n,[{key:"fieldProps",value:function(e,t){var a,o=this,c=this.props.form,u=this.getContentValue("type"),l=this.getContentValue("to_field"),s=S.includes(u)||"fk"===u&&(null===l||S.includes(null===l||void 0===l?void 0:l.type)),d="to_field"===e.name&&(void 0===u||s&&!0===(null===(a=c.getFieldValue("to"))||void 0===a?void 0:a.implicit_id)),f=d?Object(i["a"])(Object(i["a"])({},e),{},{required:!1}):e,p=[],m={field:"primary_key",operator:"=",value:!0};d?(p.push({field:"type",operator:"in",value:S}),p.push(T)):"fk"===u?p.push(m):(p.push({field:"type",operator:"in",value:D(u)}),p.push(T));var h="to_field"===e.name?Object(i["a"])(Object(i["a"])({},t),{},{widget:"Select",params:Object(i["a"])({filterRequired:!0,choicesFilter:[{field:"model",operator:"=",variable:"to"}].concat(Object(r["a"])(p))},d?{choicesPipe:function(e){return[[null,Object(g["a"])({},o.schema.titleField,"\u9ed8\u8ba4\u5173\u8054\u4e3b\u952e")]].concat(Object(r["a"])(e))}}:{})}):t,b=Object(j["a"])(Object(w["a"])(n.prototype),"fieldProps",this).call(this,f,h),y=b.widgetProps,O=Object(_["a"])(b,["widgetProps"]);if(y&&"type"===e.name&&u){var k="fk"===u?null===l?S:D(null===l||void 0===l?void 0:l.type):D(u);y.choices=y.choices.filter((function(e){var t=Object(v["a"])(e,1),n=t[0];return n===u||k&&k.includes(n)||["o2o","fk"].includes(n)&&A.includes(u)}))}return Object(i["a"])({widgetProps:y},O)}}]),n}(C["b"]),I=n("AhFF"),U={meta__field:f,member__user:h},V={shield__rule:b["a"],meta__field:L},R={FieldPermission:I["a"]},W={FieldPermission:["meta__model"]},q={}},xJcd:function(e,t,n){"use strict";(function(e){n.d(t,"c",(function(){return G})),n.d(t,"a",(function(){return ee})),n.d(t,"b",(function(){return te}));var r,a=n("9og8"),i=n("tS8v"),o=n("w4Tj"),c=n("oZsa"),u=(n("DYRE"),n("zeV3")),l=(n("R/sH"),n("djfd")),s=(n("eNCU"),n("pjJH")),d=n("0Owb"),f=n("oBTY"),p=n("k1fw"),m=n("jrin"),h=n("fWQN"),b=n("mtLc"),v=n("yKVA"),_=n("879j"),g=n("tJVT"),y=(n("5RCp"),n("a82I")),O=(n("Ahcs"),n("k0dM")),j=(n("SePM"),n("PMX6")),w=n("qqnG"),k=(n("vmZS"),n("NjVP")),E=n("WmNS"),C=n.n(E),x=n("q1tI"),S=n.n(x),F=n("/MKj"),M=n("vOnD"),P=n("9Ndd"),A=n("d76M"),D=n("VW+w"),T=n("jfUH"),L=n("rQ+i"),I=n("ctVj"),U=n("mmaM"),V=n("Utjr"),R=n("3V3B"),W=n("fNJA"),q=n("Utzx"),B=k["a"].Item,K=Object(M["a"])(k["a"].Item)(r||(r=Object(w["a"])(["\n  &.bsm-bref .has-error [class^='ant-'] {\n    border-color: #d9d9d9 !important;\n  }\n  &.bsm-bref .has-error .has-error [class^='ant-'] {\n    border-color: red !important;\n  }\n"])));function N(e){if("decimal"===e.type){if(!e.maxDigits||!e.precision)return{};var t=Math.pow(10,e.maxDigits)-Math.pow(10,-1*e.precision);return{precision:e.precision,max:t,min:-t,step:Math.pow(10,-1*e.precision)}}return{}}var H={wrapperCol:{xs:{span:24,offset:0},sm:{span:20,offset:4}}};function z(e){var t=e.title,n=e.children,r=e.description,a=e.style,i=e.index,o=e.loading,c=a;return-1===["group","tab","step"].indexOf(a)&&(c="group"),"group"===c?S.a.createElement(j["a"],{bordered:!1,title:t,style:{marginBottom:24},loading:o},n):"tab"===c?S.a.createElement(O["a"].TabPane,{key:i,tab:t},n):S.a.createElement(y["a"].Step,{title:t,description:r},n)}function J(e){return e.filter((function(e){return e.variable})).map((function(e){return e.variable})).concat(e.children||[])}function Y(e,t){var n=t;if(!n)return[];var r=[];if((Object(T["D"])(e)||"mref"===e.type)&&(n.params&&n.params.choicesFilter||n.choicesFilter)){var a=n.params&&n.params.choicesFilter||n.choicesFilter,i="string"===typeof a?Object(T["I"])(a).filter((function(e){return!e.startsWith("instance.")})):J(a);r=r.concat(i)}return r}var G=e.flow(k["a"].create({onValuesChange:function(e,t,n){var r=e.onChange,a=e.object;r&&Object.entries(t).some((function(e){var t=Object(g["a"])(e,2),n=t[0],r=t[1];return a[n]!==r}))&&r(n)}}),Object(F["c"])((function(e){var t=e.content,n=e.user.currentUser;return{content:t,currentUser:n}})),Object(T["d"])((function(){return{formWidgets:Object(P["i"])()}}))),Q=["ref","oref"],Z=function(t){Object(v["a"])(r,t);var n=Object(_["a"])(r);function r(){var e;Object(h["a"])(this,r);for(var t=arguments.length,a=new Array(t),i=0;i<t;i++)a[i]=arguments[i];return e=n.call.apply(n,[this].concat(a)),e.state={contentObject:void 0},e.inlineData={uniqueValues:{}},e.changingField=[],e.sharedData={brefFields:{}},e.formItemLayout={labelCol:{xs:{span:24},sm:{span:4}},wrapperCol:{xs:{span:24},sm:{span:20},md:{span:19}}},e}return Object(b["a"])(r,[{key:"componentWillMount",value:function(){var t=this.props.object;if(e.isEmpty(t)){if(this.isAdd()){var n=Object(P["c"])(this.schema,this.formFields);this.setState({contentObject:n})}}else this.setState({contentObject:t})}},{key:"componentWillReceiveProps",value:function(t){var n=t.content,r=t.model,a=t.objectid,i=t.object,o=t.form,c=o.setFieldsValue,u=o.getFieldsValue,l=this.props.object,s=n.data[r];s&&s.detail&&!e.isEmpty(s.detail[a])&&this.setState({contentObject:s.detail[a]}),i&&i!==l&&Object.keys(u()).forEach((function(e){Object.keys(i).includes(e)&&c(Object(m["a"])({},e,i[e]))}))}},{key:"model",get:function(){var e=this.props.model;return e}},{key:"schema",get:function(){return this.schemas[this.model]}},{key:"schemas",get:function(){var e=this.props,t=e.schemas,n=e.content.schemas;return t||n}},{key:"admin",get:function(){return this.admins[this.model]}},{key:"admins",get:function(){var e=this.props,t=e.admins,n=e.content.adminConfig;return t||n}},{key:"formFields",get:function(){var t=this.props,n=t.model,r=t.fields,a=t.admins,i=t.currentUser,o=this.admins;if(r&&e.isEmpty(a))return Object(D["formFieldsPreprocess"])(r,this.schema.fields);var c=o[n]||{},u=c.formFields,l=void 0===u?[]:u,s={fields:l,currentUser:i,model:n},d=Object(L["b"])(s);return a?Object(D["formFieldsPreprocess"])(d,this.schema.fields):this.accessibleFields(d)}},{key:"accessibleFields",value:function(e){var t=this.props.model;if(e.length){var n=Object(T["p"])(t);return e.filter((function(e){var t,r;return null===(t=null===(r=n[e.name])||void 0===r?void 0:r.write)||void 0===t||t}))}return e}},{key:"getContentValue",value:function(e){var t=this.state.contentObject;return null===t||void 0===t?void 0:t[e]}},{key:"getWidget",value:function(t,n){var r=this,a=this.state.contentObject,i=this.props,o=i.form,c=i.objectid,u=i.content.schemas,l=i.formWidgets,s=this.model,d=Object(p["a"])(Object(p["a"])({form:o},N(t)),{},{objectid:c,instance:a});n.options&&Object.keys(n.options).forEach((function(e){"SCHEMAS"===n.options[e]?d[e]=u:/^\$\{.*\}$/.test(n.options[e])?d[e]=o.getFieldValue(Object(T["I"])(n.options[e])[0]):d[e]=n.options[e]}));var f,m=Y(t,n);m&&(d.monitormodel=s,d.monitorfields=m,d.monitorvalues=this.changingField,d.choicesFilter=(null===(f=n.params)||void 0===f?void 0:f.choicesFilter)||n.choicesFilter);(!this.isAdd()&&t.name===this.schema.fields.find((function(e){return e.primaryKey})).name||n&&n.disabled&&this.meetStatement(n.disabled))&&(d.disabled=!0);var h=l[P["e"][t.type]];void 0!==t.choices&&(d.choices=t.choices,h=R["a"]);var b=n.widget;if(e.isString(b))h=l[b];else if(e.isObject(b)){h=l[b.type];var v=b.attrs;d=Object(p["a"])(Object(p["a"])({},d),v)}var _=n&&n.params||{};d=Object(p["a"])(Object(p["a"])({},d),_),d.field=t,d.onChange=function(e){return r.changeHandler(t.name,e,n)},d.validateparams={},d.extra=this.sharedData;var g=n.nestedForm;return!e.isEmpty(g)&&Q.includes(t.type)&&(d=Object(p["a"])(Object(p["a"])({Widget:h,model:s},d),{},{nestedForm:g,parentPk:c}),h=l.RefEdit),{Widget:h,options:d}}},{key:"onFieldChange",value:function(e,t,n){this.changingField=[e,t];var r=this.props,a=r.form,i=r.model,o=r.dispatch,c=r.parentform,u=r.onValuesChange,l=n;if(u&&u(e,t),l&&l.changeHandler){var s,d=null!==(s=this.getContentValue(e))&&void 0!==s?s:null;Object(A["a"])(i,l.changeHandler,{name:e,value:t,initialValue:d,form:a,dispatch:o,parentform:c})}}},{key:"changeHandler",value:function(e,t,n){this.onFieldChange(e,t,n);var r=this.props,a=r.form,i=r.model,o=r.content,c=o.adminConfig,u=o.schemas,l=c[i]||{},s=l.formHooks,d=void 0===s?[]:s;Object(W["b"])(W["a"],e,t,a,d,{model:i,schemas:u,adminConfig:c})}},{key:"meetStatement",value:function(e){var t=this.props.form.getFieldValue,n=this.state.contentObject,r=function(e){return void 0===t(e)?null===n||void 0===n?void 0:n[e]:t(e)};return Object(T["i"])(e,(function(e){if(-1!==e.indexOf(".")){var t=e.split("."),n=r(t[0]);if(void 0===n)return JSON.stringify(void 0);var a=n;return t.slice(1).forEach((function(e){a=Array.isArray(a)?a.flatMap((function(t){return t[e]})):a[e]})),a}return r(e)}))}},{key:"isAdd",value:function(){var e=this.props.objectid;return!e}},{key:"fieldProps",value:function(t,n){var r=this.props,a=r.form,i=r.hiddenFields,o=this.state.contentObject,c=this.model;if(n&&n.show&&!this.meetStatement(n.show)||n.showIf&&!Object(T["G"])(n.showIf,a.getFieldsValue(),this.schemas,c)||!this.isAdd()&&Object(U["expandDetailFields"])(c).includes(t.name)&&!e.isNull(null===o||void 0===o?void 0:o[t.name])&&!e.isPlainObject(null===o||void 0===o?void 0:o[t.name])&&(!e.isArray(null===o||void 0===o?void 0:o[t.name])||null!==o&&void 0!==o&&o[t.name].length&&!e.isPlainObject(null===o||void 0===o?void 0:o[t.name][0])))return S.a.createElement(x["Fragment"],{key:t.name});if(t.name in i)return a.getFieldDecorator(t.name,{initialValue:i[t.name]});var u=this.schema||{},l=u.validators,s="bref"===t.type?K:B,d=n&&n.alias||t.displayName,f="bsm-".concat(t.type),p=this.getWidget(t,n),m=p.Widget,h=p.options;return{Widget:m,widgetProps:h,Item:s,itemProps:{label:d,key:t.name,className:f,extra:t.help},decoratorArgs:[t.name,{initialValue:this.getContentValue(t.name),rules:Object(q["a"])(t,{},Object(q["b"])(a.getFieldsValue(),t,l))}]}}},{key:"renderFields",value:function(t){var n=this,r=this.schema||{},a=r.fields,i=void 0===a?[]:a,o=this.formFields;return e.sortBy(o.filter((function(e){return void 0===t||t.includes(e.name)})),(function(e){return t&&t.indexOf(e.name)})).map((function(e){var t=i.find((function(t){return t.name===e.name}));return t&&!1!==t.editable?n.renderField(t,e):null}))}},{key:"renderField",value:function(e,t){var n=this.fieldProps(e,t),r=n.Widget,a=n.Item,i=n.widgetProps,o=n.itemProps,c=n.decoratorArgs;if(!r)return null;var u=this.props.form;return S.a.createElement(a,Object(d["a"])({},this.formItemLayout,o),u.getFieldDecorator.apply(u,Object(f["a"])(c))(S.a.createElement(r,i)))}},{key:"render",value:function(){return S.a.createElement(k["a"],null,this.renderFields())}}]),r}(S.a.Component);Z.defaultProps={object:void 0,objectid:void 0,parentform:void 0,hiddenvalues:{},hiddenFields:{},partialupdate:!1,showButtons:!0};var X=function(e){var t=e.onSubmit,n=e.onReset,r=e.submitting;return S.a.createElement(u["b"],null,S.a.createElement(l["a"],{title:"Ctrl+Enter",mouseEnterDelay:1,placement:"bottom"},S.a.createElement(s["a"],{type:"primary",onClick:t,loading:r},"\u63d0\u4ea4")),S.a.createElement(s["a"],{onClick:n},"\u91cd\u7f6e"))},$=function(e){var t=e.children,n=e.showButtons,r=e.onSubmit,a=e.onReset,i=e.renderSubmitter,o=void 0===i?function(e){return S.a.createElement(B,Object(d["a"])({},H,{style:{marginTop:32}}),e)}:i,c=Object(I["a"])(),u=c.loading,l=c.dispatchPromise,s=l(r);return S.a.createElement(V["a"],{keyMaps:{"mod+enter":s}},S.a.createElement(k["a"],{hideRequiredMark:!1,style:{marginTop:8}},t,n&&o(S.a.createElement(X,{onSubmit:s,onReset:a,submitting:u}))))},ee=G(Z),te=function(t){Object(v["a"])(r,t);var n=Object(_["a"])(r);function r(){var e;Object(h["a"])(this,r);for(var t=arguments.length,a=new Array(t),o=0;o<t;o++)a[o]=arguments[o];return e=n.call.apply(n,[this].concat(a)),e.handleSubmit=function(t){var n=e.props.form;t.preventDefault(),t.stopPropagation();var r=e.sharedData.brefFields,a=Object.keys(r),o={force:!0};return a.length&&(o.force=!0),new Promise((function(e,t){n.validateFieldsAndScroll(o,(function(n,r){n?t(n):e(r)}))})).then(e.submit.bind(Object(i["a"])(e)))},e}return Object(b["a"])(r,[{key:"componentWillMount",value:function(){var t=this.props,n=t.objectid,a=t.object,i=t.model,u=t.dispatch,l=t.content.schemas;if(void 0!==n&&void 0===a&&!e.isEmpty(l)&&!e.isEmpty(this.admins)){var s=this.expandFields,d=s&&{expandFields:s};u({type:"content/detail",payload:Object(p["a"])({model:i,id:n},d)})}Object(o["a"])(Object(c["a"])(r.prototype),"componentWillMount",this).call(this)}},{key:"componentDidUpdate",value:function(t){var n=t.content,r=n.schemas,a=n.adminConfig,i=this.props,o=i.content.schemas,c=i.dispatch,u=i.model,l=i.objectid,s=i.object;if(void 0!==l&&void 0===s&&(e.isEmpty(r)||e.isEmpty(a))&&!e.isEmpty(o)&&!e.isEmpty(this.admins)){var d=this.expandFields,f=d&&{expandFields:d};c({type:"content/detail",payload:Object(p["a"])({model:u,id:l},f)})}}},{key:"submit",value:function(){var e=Object(a["a"])(C.a.mark((function e(t){var n,r,a,i,o,c,u,l,s,d,f,m,h,b;return C.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=this.props,r=n.dispatch,a=n.model,i=n.objectid,o=n.hiddenvalues,c=n.onSubmit,u=n.onUpdate,l=n.onCreate,s=n.partialupdate,d=n.isCopy,f=d?void 0:i,m=Object(p["a"])({},t),o&&Object.keys(o)&&(h=Object.keys(o).filter((function(e){return-1===Object.keys(t).indexOf(e)})),h.length&&h.forEach((function(e){m[e]=o[e]}))),!c){e.next=9;break}return e.next=7,c(m,f);case 7:e.next=27;break;case 9:if(void 0===f){e.next=23;break}if(!s){e.next=17;break}return e.next=13,r({type:"content/patch",payload:{newValues:m,model:a,id:f,schema:this.schema}});case 13:b=e.sent,u(b),e.next=21;break;case 17:return e.next=19,r({type:"content/update",payload:{values:m,model:a,id:f,schema:this.schema}});case 19:b=e.sent,u(b);case 21:e.next=27;break;case 23:return e.next=25,r({type:"content/create",payload:{values:m,model:a,schema:this.schema}});case 25:b=e.sent,l(b);case 27:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"expandFields",get:function(){var e=this,t=this.props.fields,n=[];return t?(t.forEach((function(t){var r,a,i=null===(r=e.schema)||void 0===r||null===(a=r.fields)||void 0===a?void 0:a.find((function(e){return e.name===(t.name||t)}));i&&Object(T["B"])(i)&&n.push(i.name)})),n):null}},{key:"render",value:function(){var e=this,t=this.state.contentObject,n=this.props,r=n.model,a=n.hideCard,i=void 0!==a&&a,o=n.showButtons,c=n.form,u=n.renderSubmitter,l=this.admins,s=this.handleSubmit,d=l[r]||{},f=d.formLayout,p=!this.isAdd()&&!t,m={onReset:function(){return c.resetFields()},onSubmit:s,showButtons:o,renderSubmitter:u};if(f){var h=f.style,b=f.sections,v=x["Fragment"];"tab"===h?v=O["a"]:"step"===h&&(v=y["a"]);var _=S.a.createElement(v,null,b.map((function(t,n){var r=t.title,a=t.fields,i=t.description;return z({title:r,description:i,style:h,children:e.renderFields(a),index:n,loading:p})})));return S.a.createElement($,m,"group"===h?_:S.a.createElement(j["a"],{bordered:!1},_))}var g=S.a.createElement($,m,this.renderFields(this.formFields.map((function(e){return e.name})).filter((function(e){return!e.includes(".")}))));return i?g:S.a.createElement(j["a"],{bordered:!1,loading:p},g)}}]),r}(Z)}).call(this,n("LvDl"))},xNPh:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return u}));var r=n("wiuW"),a=n("xJcd"),i={},o=!1,c=Object(a["c"])(a["b"]),u=function(t){return o||(e.forEach(r["a"],(function(e,t){i[t]=Object(a["c"])(e)})),o=!0),i[t]||c}}).call(this,n("LvDl"))},xceu:function(e,t,n){"use strict";(function(e){n("52nx");var r=n("7bDm"),a=n("fWQN"),i=n("mtLc"),o=n("yKVA"),c=n("879j"),u=(n("eNCU"),n("pjJH")),l=(n("4X2C"),n("xvon")),s=n("q1tI"),d=n.n(s),f=n("hJ9C"),p=n("hNBN"),m=l["a"].TextArea;function h(e){return e.replace(/<[^>]+>/g,"").replace(/&nbsp;/gi," ")}function b(e,t){var n=".txt";"richText"===t&&(n=".html"),"jsonText"===t&&(n=".json");var r=e,a=new Blob([r],{type:"text/plain"}),i=document.createElement("a");i.download="File".concat(n),i.href=URL.createObjectURL(a),document.getElementsByTagName("body")[0].appendChild(i),i.click(),document.getElementsByTagName("body")[0].removeChild(i)}function v(e){var t=e.type,n=e.value;return"richText"===t?d.a.createElement(d.a.Fragment,null,d.a.createElement(f["a"],{value:n,LONGTEXT:!0}),d.a.createElement(u["a"],{style:{"margin-top":"10px"},onClick:function(){return b(n,t)}}," ","\u4e0b\u8f7d")):"jsonText"===t?d.a.createElement("div",{style:{maxHeight:700,overflow:"auto",maxWidth:"100%",margin:"auto"}},d.a.createElement(p["a"],{value:n,theme:"google",iconStyle:"square",isEdit:!1,isAdd:!1,isDelete:!1}),d.a.createElement(u["a"],{style:{"margin-top":"10px"},onClick:function(){return b(n,t)}}," ","\u4e0b\u8f7d")):d.a.createElement(d.a.Fragment,null,d.a.createElement(m,{autoSize:{minRows:1,maxRows:20},style:{resize:"none"},value:n}),d.a.createElement(u["a"],{style:{"margin-top":"10px"},onClick:function(){return b(n,t)}}," ","\u4e0b\u8f7d"))}var _=function(t){Object(o["a"])(u,t);var n=Object(c["a"])(u);function u(){var e;Object(a["a"])(this,u);for(var t=arguments.length,r=new Array(t),i=0;i<t;i++)r[i]=arguments[i];return e=n.call.apply(n,[this].concat(r)),e.state={visible:!1},e.showModal=function(){e.setState({visible:!0})},e.handleCancel=function(){e.setState({visible:!1})},e}return Object(i["a"])(u,[{key:"render",value:function(){var t=this.state.visible,n=this.props,a=n.isExpand,i=n.value,o=n.type,c=e.isPlainObject(i)||e.isArray(i)?JSON.stringify(i):i,u=c;return c&&(u="longText"===o?c.length<10?c:c.substr(0,10):h(c.substr(0,200)).substr(0,20)),"text"===o&&(!c||(null===c||void 0===c?void 0:c.length)<300)?c||"":a&&c&&c.length>50?d.a.createElement(v,{type:o,value:c}):d.a.createElement(d.a.Fragment,null,u,u&&c.length>50&&d.a.createElement(d.a.Fragment,null,"...",d.a.createElement("a",{style:{fontSize:10},onClick:this.showModal},"\u67e5\u770b\u66f4\u591a")),d.a.createElement(r["a"],{width:"60%",visible:t,onCancel:this.handleCancel,footer:null},d.a.createElement(v,{type:o,value:c})))}}]),u}(d.a.Component);t["a"]=_}).call(this,n("LvDl"))},"y/44":function(e,t,n){"use strict";var r=n("jrin"),a=n("k1fw"),i=n("q1tI"),o=n.n(i),c=n("jfUH"),u=n("xNPh"),l=n("LvDl"),s=n.n(l),d=Object(u["a"])(),f="bsm_builtin__plainform",p=["choices","default","displayName","editable","help","maxDigits","maxLength","name","precision","primaryKey","readonly","ref","refField","refTo","required","type","validators"];function m(e){var t=e.fields,n=e.onSubmit,u=Object(c["ub"])();if(!t||0===t.length)return o.a.createElement(i["Fragment"],null);u=Object(a["a"])(Object(a["a"])({},u),{},Object(r["a"])({},f,{fields:t.map((function(e){return s.a.pick(e,p)}))}));var l=Object(r["a"])({},f,{formFields:t.map((function(e){return Object(a["a"])(Object(a["a"])({},s.a.omit(e,p)),{},{name:e.name})}))});return o.a.createElement(d,{hideCard:!0,model:f,schemas:u,admins:l,onSubmit:n})}t["a"]=m},yRbM:function(e,t,n){"use strict";(function(e){var r=n("k1fw"),a=n("fWQN"),i=n("mtLc"),o=n("w4Tj"),c=n("oZsa"),u=n("yKVA"),l=n("879j"),s=n("xJcd"),d=function(t){Object(u["a"])(s,t);var n=Object(l["a"])(s);function s(){return Object(a["a"])(this,s),n.apply(this,arguments)}return Object(i["a"])(s,[{key:"renderField",value:function(t,n){var a=this.props,i=a.form,u=a.content.data;if("condition"===n.name&&n.params&&n.params.fields){var l=e.cloneDeep(n);return l.params.fields=n.params.fields.map((function(t){var n=i.getFieldValue("model"),a=e.isString(n)?n:n&&(e.isObject(n)?n:u.meta__model.detail[n]),o={widget:"FieldPicker",show:String(!!a),params:{model:e.isString(a)?a:a&&"".concat(a.app_label,"__").concat(a.name.toLowerCase()),fieldFilter:function(e){return e.ref}}};return"field"===t?Object(r["a"])({name:"field"},o):"field"===t.name?Object(r["a"])(Object(r["a"])({},t),o):t})),Object(o["a"])(Object(c["a"])(s.prototype),"renderField",this).call(this,t,l)}return Object(o["a"])(Object(c["a"])(s.prototype),"renderField",this).call(this,t,n)}}]),s}(s["b"]);t["a"]=d}).call(this,n("LvDl"))}}]);