(("undefined"!==typeof self?self:this)["webpackJsonpportal_management_std"]=("undefined"!==typeof self?self:this)["webpackJsonpportal_management_std"]||[]).push([[111],{"99af":function(e,t,n){"use strict";var o=n("23e7"),a=n("d039"),l=n("e8b5"),c=n("861d"),r=n("7b0b"),i=n("07fa"),s=n("3511"),u=n("8418"),m=n("65f0"),f=n("1dde"),d=n("b622"),h=n("1212"),b=d("isConcatSpreadable"),g=h>=51||!a((function(){var e=[];return e[b]=!1,e.concat()[0]!==e})),p=function(e){if(!c(e))return!1;var t=e[b];return void 0!==t?!!t:l(e)},v=!g||!f("concat");o({target:"Array",proto:!0,arity:1,forced:v},{concat:function(e){var t,n,o,a,l,c=r(this),f=m(c,0),d=0;for(t=-1,o=arguments.length;t<o;t++)if(l=-1===t?c:arguments[t],p(l))for(a=i(l),s(d+a),n=0;n<a;n++,d++)n in l&&u(f,d,l[n]);else s(d+1),u(f,d++,l);return f.length=d,f}})},ca3b:function(e,t,n){"use strict";n.r(t);var o=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("el-form",{attrs:{model:e.form,"label-width":"95px",disabled:"view"===e.mode}},[n("el-form-item",{attrs:{label:"全局配置使用"}},[n("el-checkbox",{on:{change:e.setGlobalConfig},model:{value:e.form.useGlobal,callback:function(t){e.$set(e.form,"useGlobal",t)},expression:"form.useGlobal"}})],1),n("el-form-item",{attrs:{label:"栏目个数"}},[n("el-select",{attrs:{disabled:e.form.useGlobal},model:{value:e.columnNum,callback:function(t){e.columnNum=t},expression:"columnNum"}},e._l(9,(function(e){return n("el-option",{key:e,attrs:{label:e,value:e}})})),1)],1),e._l(e.form.columnIds,(function(t,o){return n("el-form-item",{key:"id"+o,attrs:{label:"栏目"+(o+1)}},[n("el-select",{attrs:{disabled:e.form.useGlobal},on:{change:e.selectChange},model:{value:e.form.columnIds[o],callback:function(t){e.$set(e.form.columnIds,o,t)},expression:"form.columnIds[index]"}},e._l(e.getColumnFilterData(e.form.columnIds[o]),(function(e){return n("el-option",{key:e.id,attrs:{label:e.name,value:e.id}})})),1)],1)}))],2)},a=[],l=n("c7eb"),c=n("3835"),r=n("1da1"),i=(n("99af"),n("4de4"),n("7db0"),n("caad"),n("b64b"),n("d3b7"),n("2532"),n("78a9")),s=new i["ColumApi"],u=new i["WorkbenchSettingApi"],m={props:["configData","mode"],data:function(){return{columnNum:1,form:{columnIds:[],useGlobal:!1},columnData:[],globalConfig:{columnIds:[]}}},computed:{columnFilterData:function(){var e=this;return _.filter(this.columnData,(function(t){return!e.form.columnIds.includes(t.id)}))}},watch:{columnNum:{immediate:!0,handler:function(){this.form.columnIds.length=this.columnNum,this.selectChange()}},configData:{deep:!0,immediate:!0,handler:function(e){_.isEmpty(e)||(this.form.columnIds=e.columnIds||[],this.form.useGlobal=e.useGlobal||!1,this.columnNum=this.form.columnIds.length||1)}}},methods:{getColumnData:function(){var e=this;return Object(r["a"])(Object(l["a"])().mark((function t(){var n,o,a,r;return Object(l["a"])().wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,s.tree(0);case 2:n=t.sent,o=Object(c["a"])(n,2),a=o[0],r=o[1],a||(e.columnData=r);case 7:case"end":return t.stop()}}),t)})))()},getSetting:function(){var e=this;return Object(r["a"])(Object(l["a"])().mark((function t(){var n,o,a,r;return Object(l["a"])().wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,u.getWorkbenchSetting({code:"navConfig"});case 2:n=t.sent,o=Object(c["a"])(n,2),a=o[0],r=o[1],!a&&r.config&&(e.globalConfig=JSON.parse(r.config));case 7:case"end":return t.stop()}}),t)})))()},selectChange:function(){this.$emit("configChange",this.form)},setGlobalConfig:function(){this.form.useGlobal&&(this.form.columnIds=_.cloneDeep(this.globalConfig.columnIds),this.columnNum=this.form.columnIds.length||1),this.selectChange()},getColumnFilterData:function(e){var t=_.find(this.columnData,{id:e});return t?_.concat([t],this.columnFilterData):this.columnFilterData}},created:function(){this.getColumnData(),this.getSetting()}},f=m,d=n("2877"),h=Object(d["a"])(f,o,a,!1,null,null,null);t["default"]=h.exports}}]);