forked from golang/hotime
1 line
51 KiB
JavaScript
1 line
51 KiB
JavaScript
(window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-2ff46b6e","chunk-1a458102"],{"00d7":function(e,t,a){"use strict";a("2cda")},"016e":function(e,t,a){"use strict";a("ad3a")},"0331":function(e,t,a){"use strict";a("7ec1")},"0cb2":function(e,t,a){var n=a("7b0b"),d=Math.floor,l="".replace,f=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,m=/\$([$&'`]|\d{1,2})/g;e.exports=function(o,i,r,c,u,e){var s=r+o.length,b=c.length,t=m;return void 0!==u&&(u=n(u),t=f),l.call(e,t,function(e,t){var a;switch(t.charAt(0)){case"$":return"$";case"&":return o;case"`":return i.slice(0,r);case"'":return i.slice(s);case"<":a=u[t.slice(1,-1)];break;default:var n,l=+t;if(0==l)return e;if(b<l)return 0!==(n=d(l/10))&&n<=b?void 0===c[n-1]?t.charAt(1):c[n-1]+t.charAt(1):e;a=c[l-1]}return void 0===a?"":a})}},"2cda":function(e,t,a){},"31a1":function(module,__webpack_exports__,__webpack_require__){"use strict";var D_work_iedc_web_node_modules_babel_runtime_helpers_esm_createForOfIteratorHelper__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__("b85c"),core_js_modules_es_number_constructor_js__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__("a9e3"),core_js_modules_es_number_constructor_js__WEBPACK_IMPORTED_MODULE_1___default=__webpack_require__.n(core_js_modules_es_number_constructor_js__WEBPACK_IMPORTED_MODULE_1__),core_js_modules_es_regexp_exec_js__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__("ac1f"),core_js_modules_es_regexp_exec_js__WEBPACK_IMPORTED_MODULE_2___default=__webpack_require__.n(core_js_modules_es_regexp_exec_js__WEBPACK_IMPORTED_MODULE_2__),core_js_modules_es_string_replace_js__WEBPACK_IMPORTED_MODULE_3__=__webpack_require__("5319"),core_js_modules_es_string_replace_js__WEBPACK_IMPORTED_MODULE_3___default=__webpack_require__.n(core_js_modules_es_string_replace_js__WEBPACK_IMPORTED_MODULE_3__),core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_4__=__webpack_require__("b0c0"),core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_4___default=__webpack_require__.n(core_js_modules_es_function_name_js__WEBPACK_IMPORTED_MODULE_4__),core_js_modules_es_string_link_js__WEBPACK_IMPORTED_MODULE_5__=__webpack_require__("9911"),core_js_modules_es_string_link_js__WEBPACK_IMPORTED_MODULE_5___default=__webpack_require__.n(core_js_modules_es_string_link_js__WEBPACK_IMPORTED_MODULE_5__),core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_6__=__webpack_require__("d81d"),core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_6___default=__webpack_require__.n(core_js_modules_es_array_map_js__WEBPACK_IMPORTED_MODULE_6__),core_js_modules_es_array_filter_js__WEBPACK_IMPORTED_MODULE_7__=__webpack_require__("4de4"),core_js_modules_es_array_filter_js__WEBPACK_IMPORTED_MODULE_7___default=__webpack_require__.n(core_js_modules_es_array_filter_js__WEBPACK_IMPORTED_MODULE_7__),_api_common_js__WEBPACK_IMPORTED_MODULE_8__=__webpack_require__("2934"),moment__WEBPACK_IMPORTED_MODULE_9__=__webpack_require__("c1df"),moment__WEBPACK_IMPORTED_MODULE_9___default=__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_9__),_bus_js__WEBPACK_IMPORTED_MODULE_10__=__webpack_require__("83c5");__webpack_exports__.a={props:{routerPath:String,routerId:Number,editDialogPath:String},components:{},data:function(){return{templateData:{},form:{},authList:[],HotimeDataTree:[],defaultProps:{children:"children",label:"label",disabled:"disabled"},formAuth:{},expandedKeys:[],checkedKeys:[],showDialog:!1,dialogData:null,dialogTitle:"",mapShow:!1,map_id:"allmap_"+(new Date).getTime()}},methods:{clickEdit:function(e,t){e=e.replace("/info",""),null!=this.routerPath&&0<this.routerPath.length?_bus_js__WEBPACK_IMPORTED_MODULE_10__.a.$emit("tabs",{name:"Edit",path:e+"/edit",id:t}):null!=this.editDialogPath?_bus_js__WEBPACK_IMPORTED_MODULE_10__.a.$emit("tabs-edit",{name:"Edit",path:e+"/edit",id:t}):this.$router.push({path:e+"/edit",query:{id:t}})},clickLink:function(e,t){t={name:"Info",path:window.Hotime.tableMapData[e].path+"/info",id:t,title:window.Hotime.tableMapData[e].parent.label+"-"+window.Hotime.tableMapData[e].label};null!=this.editDialogPath?_bus_js__WEBPACK_IMPORTED_MODULE_10__.a.$emit("tabs-edit",t):_bus_js__WEBPACK_IMPORTED_MODULE_10__.a.$emit("tabs",t)},onSubmit:function(){},routeInit:function routeInit(){var that=this,Hotime=window.Hotime,templateData,id,id=null!=Hotime.mapData[this.routerPath]?(templateData=Hotime.mapData[this.routerPath],this.routerId):(templateData=Hotime.mapData[this.$route.path.substring(0,this.$route.path.lastIndexOf("/info"))],this.$route.query.id);if(null!=templateData){if(null!=templateData.columns){var _iterator=Object(D_work_iedc_web_node_modules_babel_runtime_helpers_esm_createForOfIteratorHelper__WEBPACK_IMPORTED_MODULE_0__.a)(templateData.columns),_step;try{for(_iterator.s();!(_step=_iterator.n()).done;){var item=_step.value;null==item.value&&(item.value=item.name)}}catch(err){_iterator.e(err)}finally{_iterator.f()}}Object(_api_common_js__WEBPACK_IMPORTED_MODULE_8__.f)(Hotime.data.name+"/"+templateData.name+"/"+id).then(function(data){if(null!=templateData.columns){var _iterator2=Object(D_work_iedc_web_node_modules_babel_runtime_helpers_esm_createForOfIteratorHelper__WEBPACK_IMPORTED_MODULE_0__.a)(templateData.columns),_step2;try{for(_iterator2.s();!(_step2=_iterator2.n()).done;){var _item=_step2.value;if(null!=_item.link)try{data.result[_item.value]=eval("data.result."+_item.value)}catch(e){}else"unixtTime"==_item.type?data.result[_item.value]=moment__WEBPACK_IMPORTED_MODULE_9___default()(1e3*data.result[_item.value]).utc().format("YYYY-MM-DD HH:mm:ss"):"lng"!=_item.name&&"lat"!=_item.name||(that.mapShow=!0,that.getMap(data.result.lng,data.result.lat))}}catch(err){_iterator2.e(err)}finally{_iterator2.f()}}var arr,arr_1;that.form=data.result,that.templateData=templateData,that.form.auth&&(arr=that.getHotimeDataTree(Hotime.data.menus,""),that.HotimeDataTree=arr,that.formAuth=JSON.parse(that.form.auth),arr_1=[],arr_1.push(that.templateData.name),that.expandedKeys=arr_1,setTimeout(function(){that.changeCss()},20))})}},getHotimeDataTree:function(e,t){var a,n=[];for(a in e){var l,o=e[a];"Home"!=o.name&&(o.menus?o.children=this.getHotimeDataTree(o.menus,o.name):(o.parent_name=t,l=JSON.parse(this.form.auth)[o.name]||[],o.children=l.filter(function(e){return"show"!=e}).map(function(e){return{label:window.Hotime.data.labelConfig[e],name:o.name+"_"+e,label_1:e,parent_name:o.name,checked:!1}})),o.children.length&&n.push(o))}return n},renderContent:function(e,t){var t=t.node,a="";return e("div",{class:a=3===t.level?"foo":a},t.label)},changeCss:function(){for(var e=document.getElementsByClassName("foo"),t=0;t<e.length;t++)e[t].parentNode.style.cssFloat="left",e[t].parentNode.style.styleFloat="left",e[t].parentNode.onmouseover=function(){this.style.backgroundColor="#fff"}},handleExpand:function(){var e=this;setTimeout(function(){e.changeCss()},1)},clickJson:function(e,t){this.dialogTitle=e,this.dialogData=JSON.parse(t),this.showDialog=!0},closeDialog:function(){this.showDialog=!1,this.dialogTitle="",this.dialogData=null},getMap:function(e,t){var a=new window.BMap.Map(this.map_id),n=new window.BMap.Point(e,t),e=(a.centerAndZoom(n,18),new window.BMap.Marker(n)),l=(a.addOverlay(e),a.enableScrollWheelZoom(!0),setTimeout(function(){a.setCenter(n)},100),{width:200,height:0}),o=new window.BMap.Geocoder;e.addEventListener("click",function(){o.getLocation(n,function(e){e&&(e=e.address,e=new window.BMap.InfoWindow(e,l),a.openInfoWindow(e,n))})})}},watch:{},mounted:function(){this.routeInit()}}},"3a3a":function(e,t,a){},"50a1":function(e,t,a){"use strict";a("d14d")},5319:function(e,t,a){"use strict";var n=a("d784"),l=a("d039"),v=a("825a"),w=a("a691"),g=a("50c4"),D=a("577e"),o=a("1d80"),L=a("8aa5"),x=a("0cb2"),E=a("14c3"),i=a("b622")("replace"),T=Math.max,M=Math.min,a="$0"==="a".replace(/./,"$0"),r=!!/./[i]&&""===/./[i]("a","$0");n("replace",function(e,j,k){var y=r?"$":"$0";return[function(e,t){var a=o(this),n=null==e?void 0:e[i];return void 0!==n?n.call(e,a,t):j.call(D(a),e,t)},function(e,t){var a=v(this),n=D(e);if("string"==typeof t&&-1===t.indexOf(y)&&-1===t.indexOf("$<")){e=k(j,a,n,t);if(e.done)return e.value}for(var l,o="function"==typeof t,i=(o||(t=D(t)),a.global),r=(i&&(l=a.unicode,a.lastIndex=0),[]);null!==(d=E(a,n))&&(r.push(d),i);)""===D(d[0])&&(a.lastIndex=L(n,g(a.lastIndex),l));for(var c,u="",s=0,b=0;b<r.length;b++){for(var d=r[b],f=D(d[0]),m=T(M(w(d.index),n.length),0),h=[],p=1;p<d.length;p++)h.push(void 0===(c=d[p])?c:String(c));var O=d.groups,_=o?(_=[f].concat(h,m,n),void 0!==O&&_.push(O),D(t.apply(void 0,_))):x(f,n,m,h,O,t);s<=m&&(u+=n.slice(s,m)+_,s=m+f.length)}return u+n.slice(s)}]},!!l(function(){var e=/./;return e.exec=function(){var e=[];return e.groups={a:"7"},e},"7"!=="".replace(e,"$<a>")})||!a||r)},"72b5":function(e,t,a){"use strict";a("3a3a")},"733e":function(e,t,a){"use strict";a("7584")},7584:function(e,t,a){},"7ec1":function(e,t,a){},8625:function(e,t,a){},8668:function(e,t,a){"use strict";a("8625")},"8aa5":function(e,t,a){"use strict";var n=a("6547").charAt;e.exports=function(e,t,a){return t+(a?n(e,t).length:1)}},"8f33":function(e,t,a){"use strict";a("9911"),a("b0c0"),a("b64b");var h=a("f2bf"),p={class:"info-descriptions",style:{display:"flex","flex-direction":"column",background:"#f0f0f0",padding:"20px"}},O=Object(h.r)("查看>>"),_={key:1},j=Object(h.r)("编辑"),k={key:0,style:{}},y={style:{display:"block",height:"auto","overflow-x":"hidden"}},v=["innerHTML"],w={key:0,style:{display:"flex","flex-direction":"row",margin:"20px 0"}},g={style:{width:"130px",display:"inline-block","margin-right":"10px","text-align":"center"}},D={style:{display:"inline-block",flex:"1"}},L={class:"custom-tree-node"},x={style:{background:"rgb(240, 240, 240)"}},E=["id"],T={key:0,class:"dialog-box"},M={key:0},U={key:1};var n=a("31a1"),l=(a("0331"),a("016e"),a("6b0d")),a=a.n(l)()(n.a,[["render",function(t,e,a,n,l,o){var i=Object(h.U)("el-link"),r=Object(h.U)("el-descriptions-item"),c=Object(h.U)("el-image"),u=Object(h.U)("el-button"),s=Object(h.U)("el-descriptions"),b=Object(h.U)("el-tree"),d=Object(h.U)("el-table-column"),f=Object(h.U)("el-table"),m=Object(h.U)("el-dialog");return Object(h.L)(),Object(h.n)(h.b,null,[Object(h.o)("div",p,[Object(h.s)(s,{border:""},{default:Object(h.kb)(function(){return[(Object(h.L)(!0),Object(h.n)(h.b,null,Object(h.S)(l.templateData.columns,function(t){return Object(h.L)(),Object(h.n)(h.b,{key:t.type},[null!=t.link?(Object(h.L)(),Object(h.n)(h.b,{key:0},[0!=t.info?(Object(h.L)(),Object(h.l)(r,{key:0,label:t.label+":"},{default:Object(h.kb)(function(){return[""!=l.form[t.link]&&null!=l.form[t.link]?(Object(h.L)(),Object(h.l)(i,{key:0,icon:"el-icon-link",href:"javascript:;",onClick:function(e){return o.clickLink(t.link,l.form[t.name])}},{default:Object(h.kb)(function(){return[Object(h.r)(Object(h.Y)(l.form[t.link]&&l.form[t.link][t.value]?l.form[t.link][t.value]:"无"),1)]}),_:2},1032,["onClick"])):Object(h.m)("",!0)]}),_:2},1032,["label"])):Object(h.m)("",!0)],64)):"textArea"==t.type?(Object(h.L)(),Object(h.n)(h.b,{key:1},[],64)):null==t.link?(Object(h.L)(),Object(h.n)(h.b,{key:2},[null==t.options&&0!=t.info&&"form"!==t.type&&"auth"!==t.type?(Object(h.L)(),Object(h.l)(r,{key:0,label:t.label+":"},{default:Object(h.kb)(function(){return["json"==t.type?(Object(h.L)(),Object(h.n)(h.b,{key:0},[Object.keys(JSON.parse(l.form[t.value])).length?(Object(h.L)(),Object(h.l)(i,{key:0,href:"javascript:;",onClick:function(e){return o.clickJson(t.label,l.form[t.value])},style:{"font-size":"12px"}},{default:Object(h.kb)(function(){return[O]}),_:2},1032,["onClick"])):(Object(h.L)(),Object(h.n)("span",_,"无"))],64)):"image"==t.type?(Object(h.L)(),Object(h.l)(c,{key:1,style:{width:"50px",height:"50px"},src:l.form[t.value],"preview-src-list":[l.form[t.value]]},null,8,["src","preview-src-list"])):"file"==t.type?(Object(h.L)(),Object(h.n)(h.b,{key:2},[l.form[t.value]?(Object(h.L)(),Object(h.l)(i,{key:0,target:"_blank",href:l.form[t.value]},{default:Object(h.kb)(function(){return[Object(h.r)(Object(h.Y)(l.form[t.value]),1)]}),_:2},1032,["href"])):Object(h.m)("",!0)],64)):"image"!=t.type&&"file"!=t.type&&"form"!==t.type?(Object(h.L)(),Object(h.n)(h.b,{key:3},[Object(h.r)(Object(h.Y)(l.form[t.value])+" ",1),"id"==t.name?(Object(h.L)(),Object(h.l)(u,{key:0,onClick:e[0]||(e[0]=function(e){return o.clickEdit(l.templateData.path,l.form.id)})},{default:Object(h.kb)(function(){return[j]}),_:1})):Object(h.m)("",!0)],64)):Object(h.m)("",!0)]}),_:2},1032,["label"])):Object(h.m)("",!0),null!=t.options&&0!=t.info?(Object(h.L)(),Object(h.l)(r,{key:1,label:t.label+":"},{default:Object(h.kb)(function(){return[(Object(h.L)(!0),Object(h.n)(h.b,null,Object(h.S)(t.options,function(e){return Object(h.L)(),Object(h.n)(h.b,{key:e.name},[l.form[t.value]==e.value+""?(Object(h.L)(),Object(h.n)("span",k,Object(h.Y)(e.name),1)):Object(h.m)("",!0)],64)}),128))]}),_:2},1032,["label"])):Object(h.m)("",!0)],64)):Object(h.m)("",!0)],64)}),128))]}),_:1}),Object(h.s)(s,{column:"1"},{default:Object(h.kb)(function(){return[(Object(h.L)(!0),Object(h.n)(h.b,null,Object(h.S)(l.templateData.columns,function(e){return Object(h.L)(),Object(h.n)(h.b,{key:e.type},["textArea"==e.type?(Object(h.L)(),Object(h.l)(r,{key:0,label:" "+e.label+":",style:{margin:"40px"}},{default:Object(h.kb)(function(){return[Object(h.o)("template",y,[l.form[e.value]?(Object(h.L)(),Object(h.n)("div",{key:0,class:"textarea-box",style:{width:"auto",height:"auto",background:"#fff",padding:"20px","overflow-x":"scroll"},innerHTML:l.form[e.value]},null,8,v)):Object(h.m)("",!0)])]}),_:2},1032,["label"])):Object(h.m)("",!0)],64)}),128))]}),_:1})]),(Object(h.L)(!0),Object(h.n)(h.b,null,Object(h.S)(l.templateData.columns,function(e){return Object(h.L)(),Object(h.n)("div",{key:e.type},["auth"==e.type?(Object(h.L)(),Object(h.n)("div",w,[Object(h.o)("div",g,Object(h.Y)(e.label+":"),1),Object(h.o)("div",D,[Object(h.s)(b,{class:"tree-line",indent:0,data:l.HotimeDataTree,props:l.defaultProps,"node-key":"name","default-expanded-keys":l.expandedKeys,"default-checked-keys":l.checkedKeys,onCheck:t.checkChange,"render-content":o.renderContent,onNodeExpand:o.handleExpand,"default-expand-all":!0},{default:Object(h.kb)(function(e){e=e.node;return[Object(h.o)("span",L,[Object(h.o)("div",null,Object(h.Y)(e.label),1)])]}),_:1},8,["data","props","default-expanded-keys","default-checked-keys","onCheck","render-content","onNodeExpand"])])])):Object(h.m)("",!0)])}),128)),Object(h.o)("div",x,[Object(h.lb)(Object(h.o)("div",{id:l.map_id,style:{width:"94%",height:"50vh","min-height":"600px"}},null,8,E),[[h.hb,l.mapShow]])]),l.showDialog?(Object(h.L)(),Object(h.n)("div",T,[Object(h.s)(m,{title:l.dialogTitle,modelValue:l.showDialog,"onUpdate:modelValue":e[1]||(e[1]=function(e){return l.showDialog=e}),"destroy-on-close":"",onClose:o.closeDialog,width:"70%","lock-scroll":""},{default:Object(h.kb)(function(){return[l.dialogData.constructor==Object?(Object(h.L)(!0),Object(h.n)(h.b,{key:0},Object(h.S)(l.dialogData,function(e,t){return Object(h.L)(),Object(h.l)(s,{key:t,title:t,column:"4"},{default:Object(h.kb)(function(){return[(Object(h.L)(!0),Object(h.n)(h.b,null,Object(h.S)(e,function(e,t){return Object(h.L)(),Object(h.l)(r,{key:t,label:l.templateData.Auth[t]+":",style:{padding:"20px"}},{default:Object(h.kb)(function(){return[Object(h.r)(Object(h.Y)(e),1)]}),_:2},1032,["label"])}),128))]}),_:2},1032,["title"])}),128)):Object(h.m)("",!0),l.dialogData.constructor==Array?(Object(h.L)(),Object(h.l)(f,{key:1,data:l.dialogData,stripe:"",fit:"",border:"",size:"mini"},{default:Object(h.kb)(function(){return[(Object(h.L)(!0),Object(h.n)(h.b,null,Object(h.S)(l.dialogData[0],function(e,a){return Object(h.L)(),Object(h.n)(h.b,{key:a},[e&&e.constructor==Object?(Object(h.L)(),Object(h.l)(d,{key:0,label:a,align:"center"},{default:Object(h.kb)(function(){return[(Object(h.L)(!0),Object(h.n)(h.b,null,Object(h.S)(e,function(e,t){return Object(h.L)(),Object(h.l)(d,{key:t,label:t,align:"center"},{default:Object(h.kb)(function(e){return[l.templateData.Auth[e.row[a][t]]?(Object(h.L)(),Object(h.n)("span",M,Object(h.Y)(l.templateData.Auth[e.row[a][t]]),1)):(Object(h.L)(),Object(h.n)("span",U,Object(h.Y)(e.row[a][t]),1))]}),_:2},1032,["label"])}),128))]}),_:2},1032,["label"])):(Object(h.L)(),Object(h.l)(d,{key:1,label:a,align:"center"},{default:Object(h.kb)(function(e){return[Object(h.o)("span",null,Object(h.Y)(e.row[a]),1)]}),_:2},1032,["label"]))],64)}),128))]}),_:1},8,["data"])):Object(h.m)("",!0)]}),_:1},8,["title","modelValue","onClose"])])):Object(h.m)("",!0)],64)}],["__scopeId","data-v-4d4566fc"]]);t.a=a},ad3a:function(e,t,a){},b50c:function(e,t,a){"use strict";a.r(t);a("b0c0");var j=a("f2bf");function n(e){return Object(j.O)("data-v-51dbed3c"),e=e(),Object(j.M)(),e}var s=a("b85c"),k=(a("a9e3"),a("159b"),a("4de4"),a("fb6a"),a("ac1f"),a("5319"),a("9911"),Object(j.r)(" 清除 ")),y={style:{position:"relative"}},v=["id"],w=n(function(){return Object(j.o)("div",{style:{position:"absolute",top:"10px",left:"10px","z-index":"2",background:"#fff",padding:"5px 10px"}},[Object(j.o)("div",{id:"r-result"},[Object(j.r)("搜索:"),Object(j.o)("input",{type:"text",id:"suggestId",size:"20",value:"",style:{width:"150px"}})]),Object(j.o)("div",{id:"searchResultPanel",style:{border:"1px solid #C0C0C0",width:"150px",height:"auto",display:"none"}})],-1)}),g=["src"],D={key:1,class:"el-icon-plus avatar-uploader-icon"},L=Object(j.r)("上传文件"),x=["title"],E={key:1,class:"radio-wrap"},T=Object(j.r)("立即修改"),M=Object(j.r)("取消");a("d81d"),a("c740"),a("a434"),a("caad"),a("2532"),a("841c");var l=a("ceb0"),r=a("2934"),b=a("83c5"),l={props:{routerPath:String,routerId:Number},components:{Editor:l.a},data:function(){return{fileName:"",id:null,templateData:{},formLink:{},form:{},shortcuts:[{text:"今天",value:new Date},{text:"昨天",value:((e=new Date).setTime(e.getTime()-864e5),e)},{text:"一周前",value:((e=new Date).setTime(e.getTime()-6048e5),e)}],checkList:[],authList:[],HotimeDataTree:[],defaultProps:{children:"children",label:"label",disabled:"disabled"},formAuth:{},expandedKeys:[],checkedKeys:[],mapShow:!1,mapId:"allmap_"+(new Date).getTime()};var e},methods:{checkSelf:function(e){if(null==this.templateData||null==this.templateData.table||null==window.Hotime.user)return!1;if(this.templateData.table!=window.Hotime.user.table||window.Hotime.user.id!=this.routerId)return!1;if(null!=e.link)for(var t=0;t<window.Hotime.tableMapData[e.link].columns.length;t++)if("parent_id"==window.Hotime.tableMapData[e.link].columns[t].name)return!0;return!1},clickLink:function(t,a){var e={name:"Table",path:window.Hotime.tableMapData[t.link].path,title:window.Hotime.tableMapData[t.link].parent.label+"-"+window.Hotime.tableMapData[t.link].label};null!=this.editDialogPath?b.a.$emit("tabs-edit",e):(b.a.$emit("dialog-edit",e),b.a.$off("table:"+window.Hotime.tableMapData[t.link].path)),b.a.$on("table:"+window.Hotime.tableMapData[t.link].path,function(e){a[t.link]=e,a[t.name]=e.id})},closeDialog:function(){this.showDialog=!1,this.dialogDataPath=null,this.dialogDataId=null,this.dialogDataQuery={}},beforeAvatarUpload:function(e,t){var a=this;return null==e||Object(r.h)(e).then(function(e){a.form[t]=e.result}),!1},close:function(){b.a.$emit("tabs-close",{name:"Edit",path:this.templateData.path,id:this.id})},onSubmit:function(){var t=this,a=this;this.$confirm("此操作将进行修改操作,是否继续?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){var e=window.Hotime;Object(r.c)(e.data.name+"/"+t.templateData.name+"/"+t.id,a.form).then(function(e){0==e.status?(a.$message({type:"success",message:"修改成功!"}),a.close()):a.$message({type:"warn",message:e.error.msg})})})},routeInit:function(){var o=this,i=window.Hotime;if(null!=i.mapData[this.routerPath]?(this.templateData=i.mapData[this.routerPath],this.id=this.routerId):(this.templateData=i.mapData[this.$route.path.substring(0,this.$route.path.lastIndexOf("/edit"))],this.id=this.$route.query.id),null!=this.templateData){if(null!=this.templateData.columns){var e,t=Object(s.a)(this.templateData.columns);try{for(t.s();!(e=t.n()).done;){var a=e.value;null==a.value&&(a.value=a.name)}}catch(e){t.e(e)}finally{t.f()}}Object(r.f)(i.data.name+"/"+this.templateData.name+"/"+this.id).then(function(a){if(null!=o.templateData.columns){var e,t=Object(s.a)(o.templateData.columns);try{for(t.s();!(e=t.n()).done;)!function(){var t=e.value;null!=t.link&&Object(r.g)(i.data.name+"/"+t.link,{pageSize:100}).then(function(e){0==e.status&&(o.formLink[t.link]=e.result.data,null!=a.result[t.link]&&o.formLink[t.link].push(a.result[t.link]))}),"lng"!=t.name&&"lat"!=t.name||(o.mapShow=!0,o.getMap(a.result.lng,a.result.lat))}()}catch(e){t.e(e)}finally{t.f()}}for(var n in a.result)a.result[n]instanceof Object?o.form[n]=a.result[n]:o.form[n]=a.result[n]+"";var l=o.getHotimeDataTree(i.data.menus,"");o.HotimeDataTree=l;try{o.formAuth=JSON.parse(o.form.auth)}catch(e){o.formAuth={}}l=[];l.push(o.templateData.name),o.expandedKeys=l,setTimeout(function(){o.changeCss()},20)})}},getHotimeDataTree:function(e,t){var a,n=this,l=[];for(a in e){var o=e[a];"Home"!=o.name&&(o.menus?o.children=this.getHotimeDataTree(o.menus,o.name):(o.parent_name=t,o.disabled=!o.auth.length,o.children=o.auth.filter(function(e){return"show"!=e}).map(function(t){var e={label:window.Hotime.data.labelConfig[t],name:o.name+"_"+t,label_1:t,parent_name:o.name,checked:!1,auth:o.auth},a=[];return-1!=(a=n.form.auth?JSON.parse(n.form.auth)[o.name]||[]:a).findIndex(function(e){return e==t})&&(e.checked=!0,n.checkedKeys.push(e.name)),e})),l.push(Object.assign({},o)))}return l},checkChange:function(t,e){var a,n,l=this.form.auth?JSON.parse(this.form.auth):{};if(t.parent_name&&(-1!=(n=(a=l[t.parent_name]||[]).findIndex(function(e){return e==t.label_1}))?a.splice(n,1):a.push(t.label_1),"tag"!=t.parent_name&&("1"==a.length&&"show"==a[0]?a=[]:-1==a.findIndex(function(e){return"show"==e})&&a.unshift("show")),l[t.parent_name]=a),t.children&&t.children.length)for(var o in this.forAuth(l,t),t.children)t.children[o].children&&t.children[o].children.length&&this.forAuth(l,t.children[o]);this.form.auth=JSON.stringify(l)},forAuth:function(e,t){t.auth=e[t.name]||[];var a=!1;if(t.auth.length){for(var n in t.Auth)t.auth.includes(n)||(a=!0,t.auth.push(n));a||(t.auth=[])}else for(var l in t.Auth)t.Auth[l]&&!t.auth.includes(l)&&t.auth.push(l);e[t.name]=t.auth},renderContent:function(e,t){var t=t.node,a="";return e("div",{class:a=3===t.level?"foo":a},t.label)},changeCss:function(){for(var e=document.getElementsByClassName("foo"),t=0;t<e.length;t++)e[t].parentNode.style.cssFloat="left",e[t].parentNode.style.styleFloat="left",e[t].parentNode.onmouseover=function(){this.style.backgroundColor="#fff"}},handleExpand:function(){var e=this;setTimeout(function(){e.changeCss()},1)},getMap:function(e,t){function a(){c("suggestId").innerHTML="",c("searchResultPanel").innerHTML="",o.clearOverlays();var e=o.pointToOverlayPixel(o.getCenter()),t=o.overlayPixelToPoint({x:e.x,y:e.y});l.form.lng=t.lng,l.form.lat=t.lat,setTimeout(function(){r(t)},30)}var n,l=this,o=new window.BMap.Map(this.mapId),i=new window.BMap.Point(e,t),r=(o.centerAndZoom(i,20),o.enableScrollWheelZoom(!0),function(t){var a,e,n="";n?n.setPosition(t):n=new window.BMap.Marker(t),o.addOverlay(n),a={width:200,height:0,title:"信息窗口"},e=new window.BMap.Geocoder,n.addEventListener("click",function(){e.getLocation(t,function(e){e&&(e=e.address,e=new window.BMap.InfoWindow(e,a),o.openInfoWindow(e,t))})})}),c=(r(i),setTimeout(function(){o.setCenter(i)},100),function(e){return document.getElementById(e)}),e=new window.BMap.Autocomplete({input:"suggestId",location:o}),u=(document.addEventListener&&document.addEventListener("DOMMouseScroll",a,!1),window.onmousewheel=document.onmousewheel=a,o.addEventListener("dragend",a,!1),o.addEventListener("moveend",a,!1),o.addEventListener("zoomend",a,!1),o.addEventListener("resize",a,!1),e.addEventListener("onhighlight",function(e){var t,a=e.fromitem.value,n="";-1<e.fromitem.index&&(n=a.province+a.city+a.district+a.street+a.business),t="FromItem<br />index = "+e.fromitem.index+"<br />value = "+n,n="",-1<e.toitem.index&&(n=(a=e.toitem.value).province+a.city+a.district+a.street+a.business),t+="<br />ToItem<br />index = "+e.toitem.index+"<br />value = "+n,c("searchResultPanel").innerHTML=t}),e.addEventListener("onconfirm",function(e){var t=e.item.value;n=t.province+t.city+t.district+t.street+t.business,c("searchResultPanel").innerHTML="onconfirm<br />index = "+e.item.index+"<br />myValue = "+n,u()}),function(){o.clearOverlays();var t=new window.BMap.LocalSearch(o,{onSearchComplete:function(){var e=t.getResults().getPoi(0).point;o.centerAndZoom(e,20),r(e),l.form.lng=e.lng,l.form.lat=e.lat}});t.search(n)})},clearLink:function(e){this.form[e]=""}},watch:{},mounted:function(){this.routeInit()}},o=(a("8668"),a("72b5"),a("6b0d")),o=a.n(o),l=o()(l,[["render",function(e,t,a,n,l,o){var i=Object(j.U)("el-button"),r=Object(j.U)("el-form-item"),c=Object(j.U)("el-input"),u=Object(j.U)("Editor"),s=Object(j.U)("el-input-number"),b=Object(j.U)("el-date-picker"),d=Object(j.U)("el-upload"),f=Object(j.U)("el-option"),m=Object(j.U)("el-select"),h=Object(j.U)("el-radio"),p=Object(j.U)("el-tree"),O=Object(j.U)("el-affix"),_=Object(j.U)("el-form");return Object(j.L)(),Object(j.l)(_,{ref:"form",model:l.form,"label-width":"180px",style:{"padding-top":"10px","overflow-y":"auto",width:"90%","padding-right":"30px",background:"white",display:"block","flex-direction":"row","flex-wrap":"wrap","align-content":"flex-start","justify-content":"flex-start"}},{default:Object(j.kb)(function(){return[(Object(j.L)(!0),Object(j.n)(j.b,null,Object(j.S)(l.templateData.columns,function(t){return Object(j.L)(),Object(j.n)("div",{key:t.type},[null!=t.link?(Object(j.L)(),Object(j.n)(j.b,{key:0},[0==t.edit||o.checkSelf(t)?Object(j.m)("",!0):(Object(j.L)(),Object(j.l)(r,{key:0,label:t.label+":",required:t.must},{default:Object(j.kb)(function(){return[Object(j.s)(i,{icon:"el-icon-link",href:"javascript:;",onClick:function(e){return o.clickLink(t,l.form)}},{default:Object(j.kb)(function(){return[Object(j.r)(Object(j.Y)(l.form[t.link]&&null!=l.form[t.link][t.value]?l.form[t.link][t.value]:"选择"),1)]}),_:2},1032,["onClick"]),l.form[t.link]?(Object(j.L)(),Object(j.l)(i,{key:0,onClick:function(e){return o.clearLink(t.link)},icon:"el-icon-circle-close"},{default:Object(j.kb)(function(){return[k]}),_:2},1032,["onClick"])):Object(j.m)("",!0)]}),_:2},1032,["label","required"]))],64)):Object(j.m)("",!0),null==t.link?(Object(j.L)(),Object(j.n)(j.b,{key:1},["lng"==t.name?(Object(j.L)(),Object(j.l)(r,{key:0,required:t.must},{default:Object(j.kb)(function(){return[Object(j.lb)(Object(j.o)("div",y,[Object(j.o)("div",{id:l.mapId,style:{width:"400px",height:"300px"}},null,8,v),w],512),[[j.hb,l.mapShow]])]}),_:2},1032,["required"])):Object(j.m)("",!0),0!=t.edit?(Object(j.L)(),Object(j.l)(r,{key:1,label:t.label+":",required:t.must},{default:Object(j.kb)(function(){return[null==t.options?(Object(j.L)(),Object(j.n)(j.b,{key:0},["password"==t.type?(Object(j.L)(),Object(j.l)(c,{key:0,modelValue:l.form[t.value],"onUpdate:modelValue":function(e){return l.form[t.value]=e},"show-password":"",style:{width:"400px"}},null,8,["modelValue","onUpdate:modelValue"])):"text"==t.type||"json"==t.type?(Object(j.L)(),Object(j.l)(c,{key:1,modelValue:l.form[t.value],"onUpdate:modelValue":function(e){return l.form[t.value]=e},type:"textarea",style:{width:"400px"}},null,8,["modelValue","onUpdate:modelValue"])):"textArea"==t.type?(Object(j.L)(),Object(j.l)(u,{key:2,modelValue:l.form[t.value],"onUpdate:modelValue":function(e){return l.form[t.value]=e},style:{width:"100%","min-width":"800px"}},null,8,["modelValue","onUpdate:modelValue"])):"number"==t.type?(Object(j.L)(),Object(j.l)(s,{key:3,modelValue:l.form[t.value],"onUpdate:modelValue":function(e){return l.form[t.value]=e},style:{width:"400px"}},null,8,["modelValue","onUpdate:modelValue"])):"time"==t.type?(Object(j.L)(),Object(j.l)(b,{key:4,"value-format":"YYYY-MM-DD HH:mm:ss",modelValue:l.form[t.value],"onUpdate:modelValue":function(e){return l.form[t.value]=e},align:"right",type:"datetime",placeholder:"选择日期",shortcuts:l.shortcuts,style:{width:"400px"}},null,8,["modelValue","onUpdate:modelValue","shortcuts"])):"unixTime"==t.type?(Object(j.L)(),Object(j.l)(b,{key:5,"value-format":"X",modelValue:l.form[t.value],"onUpdate:modelValue":function(e){return l.form[t.value]=e},style:{width:"400px"},align:"right",type:"datetime",placeholder:"选择日期","disabled-date":e.disabledDate,shortcuts:l.shortcuts},null,8,["modelValue","onUpdate:modelValue","disabled-date","shortcuts"])):"image"==t.type?(Object(j.L)(),Object(j.l)(d,{key:6,action:"#","show-file-list":!1,"before-upload":function(e){return o.beforeAvatarUpload(e,t.value)}},{default:Object(j.kb)(function(){return[l.form[t.value]?(Object(j.L)(),Object(j.n)("img",{key:0,src:l.form[t.value]},null,8,g)):(Object(j.L)(),Object(j.n)("i",D))]}),_:2},1032,["before-upload"])):Object(j.m)("",!0),"file"==t.type?(Object(j.L)(),Object(j.l)(d,{key:7,class:"file-upload",action:"#","show-file-list":!1,style:{width:"400px"},"before-upload":function(e){return o.beforeAvatarUpload(e,t.value)}},{default:Object(j.kb)(function(){return[Object(j.s)(i,{type:"primary"},{default:Object(j.kb)(function(){return[L]}),_:1}),Object(j.o)("span",{class:"file-name",title:l.fileName},Object(j.Y)(l.fileName),9,x)]}),_:2},1032,["before-upload"])):Object(j.m)("",!0)],64)):Object(j.m)("",!0),null!=t.options?(Object(j.L)(),Object(j.n)(j.b,{key:1},[3<t.options.length?(Object(j.L)(),Object(j.l)(m,{key:0,modelValue:l.form[t.value],"onUpdate:modelValue":function(e){return l.form[t.value]=e},placeholder:"请选择",style:{width:"400px"}},{default:Object(j.kb)(function(){return[(Object(j.L)(!0),Object(j.n)(j.b,null,Object(j.S)(t.options,function(e){return Object(j.L)(),Object(j.l)(f,{key:e.value,label:e.name,value:e.value},null,8,["label","value"])}),128))]}),_:2},1032,["modelValue","onUpdate:modelValue"])):t.options.length<4?(Object(j.L)(),Object(j.n)("div",E,[(Object(j.L)(!0),Object(j.n)(j.b,null,Object(j.S)(t.options,function(e){return Object(j.L)(),Object(j.l)(h,{key:e,modelValue:l.form[t.value],"onUpdate:modelValue":function(e){return l.form[t.value]=e},label:e.value},{default:Object(j.kb)(function(){return[Object(j.r)(Object(j.Y)(e.name),1)]}),_:2},1032,["modelValue","onUpdate:modelValue","label"])}),128))])):Object(j.m)("",!0)],64)):"auth"==t.type?(Object(j.L)(),Object(j.n)(j.b,{key:2},[Object(j.s)(c,{modelValue:l.form[t.value],"onUpdate:modelValue":function(e){return l.form[t.value]=e},type:"textarea",style:{width:"400px",display:"none"}},null,8,["modelValue","onUpdate:modelValue"]),Object(j.s)(p,{class:"tree-line",indent:0,data:l.HotimeDataTree,props:l.defaultProps,"node-key":"name","default-expanded-keys":l.expandedKeys,"default-checked-keys":l.checkedKeys,"show-checkbox":"",onCheck:o.checkChange,"render-content":o.renderContent,onNodeExpand:o.handleExpand,"default-expand-all":!0},null,8,["data","props","default-expanded-keys","default-checked-keys","onCheck","render-content","onNodeExpand"])],64)):Object(j.m)("",!0)]}),_:2},1032,["label","required"])):Object(j.m)("",!0)],64)):Object(j.m)("",!0)])}),128)),Object(j.s)(O,{position:"bottom",offset:0,style:{width:"100%"}},{default:Object(j.kb)(function(){return[Object(j.s)(r,{style:{background:"white","padding-bottom":"10px"}},{default:Object(j.kb)(function(){return[Object(j.s)(i,{type:"primary",onClick:o.onSubmit},{default:Object(j.kb)(function(){return[T]}),_:1},8,["onClick"]),Object(j.s)(i,{onClick:o.close},{default:Object(j.kb)(function(){return[M]}),_:1},8,["onClick"])]}),_:1})]}),_:1})]}),_:1},8,["model"])}],["__scopeId","data-v-51dbed3c"]]),i=a("8f33"),c=a("0748"),a=a("d0c8"),a={props:{routerPath:String,routerId:Number,close:Function},name:"Tabs",components:{Add:a.default,Table:c.default,Info:i.a,Edit:l},data:function(){return{activeName:"",tabs:[]}},methods:{removeTab:function(a){var n=this.tabs,l=this.activeName;n.forEach(function(e,t){e.path+e.id===a&&(e=n[t+1]||n[t-1])&&(l=e.path+e.id)}),this.activeName=l,this.tabs=n.filter(function(e){return e.path+e.id!==a})}},mounted:function(){var e,t,a,n=window.Hotime,i=this,l=null!=n.mapData[this.routerPath]?(e=n.mapData[this.routerPath],this.routerId):(e=n.mapData[this.$route.path],this.$route.query.id);if(e.id=l,e.path.lastIndexOf("/info")==e.path.length-5?(e.tabType="info",this.tabs.push(e),this.activeName=e.path+l,!0===(t=n.mapData[e.path.slice(0,e.path.lastIndexOf("/info"))+"/edit"]).Auth.edit&&(t.tabType="edit",t.id=l,this.tabs.push(t))):e.path.lastIndexOf("/edit")==e.path.length-5?(e.tabType="edit",this.tabs.push(e),this.activeName=e.path+l,!0===(a=n.mapData[e.path.slice(0,e.path.lastIndexOf("/edit"))+"/info"]).Auth.info&&(a.tabType="info",a.id=l,this.tabs.push(a))):(e.path.lastIndexOf("/add")==e.path.length-4?e.tabType="add":(e.tabType="table",a.id=l),this.tabs.push(e),this.activeName=e.path),null!=e.byLink&&null!=l){var o,r=Object(s.a)(e.byLink);try{for(r.s();!(o=r.n()).done;){var c,u=o.value;null!=n.tableMapData[u.table]&&((c=Object.assign({},n.tableMapData[u.table])).label="关联"+c.label.replace("管理","").replace("关联",""),c.tabType="table",c.query={},c.query[u.name]=l,this.tabs.push(c))}}catch(e){r.e(e)}finally{r.f()}}b.a.$off("tabs"),b.a.$on("tabs",function(e){var t=Object.assign({},n.mapData[e.path]),a=(t.label="关联"+t.parent.label.replace("管理","").replace("关联","")+t.label.replace("管理","").replace("关联",""),t.tabType=t.path.slice(t.path.lastIndexOf("/")+1,t.path.length),t.id=e.id,!1);i.tabs.forEach(function(e){e.path==t.path&&e.id==t.id&&(a=!0)}),a||(t.closable=!0,t.query=e.query,i.tabs.push(t)),i.activeName=t.path+t.id}),b.a.$off("tabs-close"),b.a.$on("tabs-close",function(a){var n=i.activeName,l=-1,o=i.tabs;o.forEach(function(e,t){e.path==a.path&&e.id==a.id&&(e=o[(l=t)-1]||o[t+1])&&(n=e.path+e.id)}),1==o[l].closable?(i.activeName=n,i.tabs=o.filter(function(e,t){return t!==l})):1==l?i.activeName=n:null!=i.close?i.close():i.$router.go(-1)})}};t.default=o()(a,[["render",function(e,t,a,n,l,o){var i=Object(j.U)("Edit"),r=Object(j.U)("Info"),c=Object(j.U)("Table"),u=Object(j.U)("Add"),s=Object(j.U)("el-tab-pane"),b=Object(j.U)("el-tabs");return Object(j.L)(),Object(j.l)(b,{modelValue:l.activeName,"onUpdate:modelValue":t[0]||(t[0]=function(e){return l.activeName=e}),type:"border-card",style:{width:"100%","overflow-y":"auto"},onTabRemove:o.removeTab},{default:Object(j.kb)(function(){return[(Object(j.L)(!0),Object(j.n)(j.b,null,Object(j.S)(l.tabs,function(e){return Object(j.L)(),Object(j.l)(s,{key:e.name,label:e.label,name:e.path+e.id,lazy:"",closable:1==e.closable},{default:Object(j.kb)(function(){return["edit"==e.tabType?(Object(j.L)(),Object(j.l)(i,{key:0,"router-path":e.path,"router-id":e.id},null,8,["router-path","router-id"])):Object(j.m)("",!0),"info"==e.tabType?(Object(j.L)(),Object(j.l)(r,{key:1,"router-path":e.path,"router-id":e.id},null,8,["router-path","router-id"])):Object(j.m)("",!0),"table"==e.tabType?(Object(j.L)(),Object(j.l)(c,{key:2,"router-query":e.query,"router-path":e.path},null,8,["router-query","router-path"])):Object(j.m)("",!0),"add"==e.tabType?(Object(j.L)(),Object(j.l)(u,{key:3,"router-query":e.query,"router-path":e.path},null,8,["router-query","router-path"])):Object(j.m)("",!0)]}),_:2},1032,["label","name","closable"])}),128))]}),_:1},8,["modelValue","onTabRemove"])}]])},b64b:function(e,t,a){var n=a("23e7"),l=a("7b0b"),o=a("df75");n({target:"Object",stat:!0,forced:a("d039")(function(){o(1)})},{keys:function(e){return o(l(e))}})},d14d:function(e,t,a){},fe2e:function(e,t,a){"use strict";a.r(t);var y=a("f2bf"),v=Object(y.r)("返回"),w={class:"el-dialog-div"},g=Object(y.r)("Footer");a("b0c0");var f=Object(y.o)("i",{class:"el-icon-s-unfold"},null,-1),m={class:"title-span"},h={style:{"margin-left":"10px"}},p={class:"title-span"},O=Object(y.r)("收起/展开");function n(e){return Object(y.O)("data-v-27627ce6"),e=e(),Object(y.M)(),e}var o=a("83c5"),l={data:function(){return window.Hotime.vueComponent.leftNav=this,{leftNavHomeBar:!1,isCollapse:!1,name:"HoTime DashBoard",menus:window.Hotime.data.menus}},methods:{hideLeftHomeBar:function(){this.leftNavHomeBar=!1,window.Hotime.vueComponent.APP.showHeader=!0},setCollapse:function(){this.isCollapse=!this.isCollapse},handleOpen:function(e,t){},handleClose:function(e,t){}},mounted:function(){this.name=window.Hotime.data.label;var l=this;o.a.$off("auth"),o.a.$on("auth",function(e){if(null!=e.auth)for(var t in e.auth)if(null!==window.Hotime.mapData[e.auth[t].name]){for(var a in null==window.Hotime.mapData[e.auth[t].name].Auth&&(window.Hotime.mapData[e.auth[t].name].Auth={}),window.Hotime.mapData[e.auth[t].name].Auth)window.Hotime.mapData[e.auth[t].name].Auth[a]=!1;for(var n in e.auth[t].value)window.Hotime.mapData[e.auth[t].name].Auth[e.auth[t].value[n]]=!0}l.menus=[],setTimeout(function(){l.menus=window.Hotime.data.menus},10)})}},i=(a("50a1"),a("6b0d")),i=a.n(i),l=i()(l,[["render",function(e,t,a,n,l,o){var i=Object(y.U)("el-menu-item"),r=Object(y.U)("el-icon"),c=Object(y.U)("el-menu-item-group"),u=Object(y.U)("el-submenu"),s=Object(y.U)("el-menu"),b=Object(y.U)("el-col"),d=Object(y.U)("el-row");return Object(y.L)(),Object(y.l)(d,{class:"tac",style:{height:"100%"}},{default:Object(y.kb)(function(){return[Object(y.s)(b,{span:24},{default:Object(y.kb)(function(){return[Object(y.s)(s,{uniqueOpened:!0,"default-active":e.$route.path,class:"el-menu-vertical-demo",onOpen:o.handleOpen,onClose:o.handleClose,style:{height:"100%"},collapse:e.isCollapse,router:""},{default:Object(y.kb)(function(){return[Object(y.lb)(Object(y.s)(i,{onClick:o.hideLeftHomeBar,class:"left-nav-home-bar",index:""},{title:Object(y.kb)(function(){return[Object(y.r)(Object(y.Y)(e.name),1)]}),default:Object(y.kb)(function(){return[f]}),_:1},8,["onClick"]),[[y.hb,e.leftNavHomeBar]]),(Object(y.L)(!0),Object(y.n)(y.b,null,Object(y.S)(e.menus,function(e){return Object(y.L)(),Object(y.n)(y.b,null,[null==e.menus||null!=e.Auth&&1!=e.Auth.show?Object(y.m)("",!0):(Object(y.L)(),Object(y.l)(u,{key:e.label,index:e.path,class:"text-ellipsis"},{title:Object(y.kb)(function(){return[Object(y.s)(r,{size:16},{default:Object(y.kb)(function(){return[(Object(y.L)(),Object(y.l)(Object(y.W)(e.icon)))]}),_:2},1024),Object(y.o)("span",m,Object(y.Y)(e.label),1)]}),default:Object(y.kb)(function(){return[Object(y.s)(c,null,{default:Object(y.kb)(function(){return[(Object(y.L)(!0),Object(y.n)(y.b,null,Object(y.S)(e.menus,function(e){return Object(y.L)(),Object(y.n)(y.b,{key:e.label},[1==e.Auth.show?(Object(y.L)(),Object(y.l)(i,{key:0,index:e.path},{default:Object(y.kb)(function(){return[e.icon?(Object(y.L)(),Object(y.l)(r,{key:0,size:16},{default:Object(y.kb)(function(){return[(Object(y.L)(),Object(y.l)(Object(y.W)(e.icon)))]}),_:2},1024)):Object(y.m)("",!0),Object(y.o)("span",h,Object(y.Y)(e.label),1)]}),_:2},1032,["index"])):Object(y.m)("",!0)],64)}),128))]}),_:2},1024)]}),_:2},1032,["index"])),null==e.menus&&1==e.Auth.show?(Object(y.L)(),Object(y.l)(i,{key:e.label,index:null!=e.default?e.path+"/"+e.default.path+"?id="+e.default.id:e.path,style:{"padding-left":"10px","text-overflow":"ellipsis",overflow:"hidden"}},{title:Object(y.kb)(function(){return[Object(y.o)("span",p,Object(y.Y)(e.label),1)]}),default:Object(y.kb)(function(){return[Object(y.s)(r,{size:16},{default:Object(y.kb)(function(){return[(Object(y.L)(),Object(y.l)(Object(y.W)(e.icon)))]}),_:2},1024)]}),_:2},1032,["index"])):Object(y.m)("",!0)],64)}),256)),Object(y.s)(i,{onClick:o.setCollapse,style:{position:"absolute",bottom:"1px",width:"100%","padding-left":"10px"}},{title:Object(y.kb)(function(){return[O]}),default:Object(y.kb)(function(){return[Object(y.o)("i",{class:Object(y.B)({"el-icon-s-fold":!e.isCollapse,"el-icon-s-unfold":e.isCollapse})},null,2)]}),_:1},8,["onClick"])]}),_:1},8,["default-active","onOpen","onClose","collapse"])]}),_:1})]}),_:1})}]]),d=n(function(){return Object(y.o)("i",{class:"el-icon-s-fold",style:{"font-size":"18px","margin-right":"4px"}},null,-1)}),_={style:{"font-size":"14px","margin-left":"4px",height:"25px",top:"17.5px",position:"absolute"}},j={style:{display:"flex","flex-direction":"row","align-items":"center"}},k={class:"el-dropdown-link",style:{"margin-left":"30px"}},D=n(function(){return Object(y.o)("i",{class:"el-icon-user"},null,-1)}),L=Object(y.r)("个人信息"),x=n(function(){return Object(y.o)("i",{class:"el-icon-edit"},null,-1)}),E=Object(y.r)("修改信息"),T=n(function(){return Object(y.o)("i",{class:"el-icon-switch-button"},null,-1)}),M=Object(y.r)("系统注销 ");var r=a("2934"),c={data:function(){return window.Hotime.vueComponent.headerNav=this,{name:"HoTime DashBoard",isShowHeader:!0,activeIndex:"1",activeIndex2:"1",data:{}}},methods:{handleSelect:function(e,t){},hideHeader:function(){window.Hotime.vueComponent.APP.showHeader=!1,window.Hotime.vueComponent.leftNav.leftNavHomeBar=!0},clickLogout:function(){var e=this;Object(r.d)(window.Hotime.name+"/hotime/logout").then(function(){e.$router.push({path:"/login"})})},clickInfo:function(){o.a.$emit("dialog",{name:"Info",path:window.Hotime.tableMapData[window.Hotime.user.table].path+"/info",id:this.data.id,title:window.Hotime.tableMapData[window.Hotime.user.table].parent.label+"-"+window.Hotime.tableMapData[window.Hotime.user.table].label})},clickEdit:function(){o.a.$emit("dialog",{name:"Edit",path:window.Hotime.tableMapData[window.Hotime.user.table].path+"/edit",id:this.data.id,title:window.Hotime.tableMapData[window.Hotime.user.table].parent.label+"-"+window.Hotime.tableMapData[window.Hotime.user.table].label})}},mounted:function(){this.name=window.Hotime.data.label;var t=this;Object(r.d)(window.Hotime.name+"/hotime/info").then(function(e){0!=e.status?t.$router.push({path:"/login"}):(window.Hotime.user=e.result,t.data=e.result,null!=e.result.role&&null!=e.result.role.auth&&o.a.$emit("auth",JSON.parse(e.result.role.auth)))})}},c=(a("733e"),i()(c,[["render",function(e,t,a,n,l,o){var i=Object(y.U)("el-col"),r=Object(y.U)("el-button"),c=Object(y.U)("el-dropdown-item"),u=Object(y.U)("el-dropdown-menu"),s=Object(y.U)("el-dropdown"),b=Object(y.U)("el-row");return Object(y.L)(),Object(y.l)(b,null,{default:Object(y.kb)(function(){return[Object(y.s)(i,{span:6,class:"head-left"},{default:Object(y.kb)(function(){return[Object(y.o)("div",{role:"button",onClick:t[0]||(t[0]=function(){return o.hideHeader&&o.hideHeader.apply(o,arguments)}),style:{cursor:"pointer","font-size":"14px","margin-left":"3px","margin-bottom":"4px"}},[d,Object(y.o)("span",_,Object(y.Y)(l.name),1)])]}),_:1}),Object(y.s)(i,{span:12}),Object(y.s)(i,{span:6,class:"head-right"},{default:Object(y.kb)(function(){return[Object(y.o)("div",j,[Object(y.s)(s,{"hide-on-click":!1},{dropdown:Object(y.kb)(function(){return[Object(y.s)(u,null,{default:Object(y.kb)(function(){return[Object(y.s)(c,{onClick:o.clickInfo},{default:Object(y.kb)(function(){return[D,L]}),_:1},8,["onClick"]),Object(y.s)(c,{onClick:o.clickEdit},{default:Object(y.kb)(function(){return[x,E]}),_:1},8,["onClick"]),Object(y.s)(c,{divided:"",onClick:o.clickLogout},{default:Object(y.kb)(function(){return[T,M]}),_:1},8,["onClick"])]}),_:1})]}),default:Object(y.kb)(function(){return[Object(y.o)("span",k,[Object(y.s)(r,{icon:"el-icon-user",type:"text",style:{color:"white","font-size":"14px"}},{default:Object(y.kb)(function(){return[Object(y.r)(Object(y.Y)(l.data.name),1)]}),_:1})])]}),_:1})])]}),_:1})]}),_:1})}],["__scopeId","data-v-27627ce6"]])),u=a("b50c");a("a9e3"),a("159b"),a("4de4"),a("fb6a"),a("ac1f"),a("5319");var s=a("8f33"),b=a("0748"),U=a("d0c8"),U={props:{routerPath:String,routerId:Number,close:Function},name:"Tabs",components:{Add:U.default,Table:b.default,Info:s.a},data:function(){return{activeName:"",tabs:[]}},methods:{removeTab:function(a){var n=this.tabs,l=this.activeName;n.forEach(function(e,t){e.path+e.id===a&&(e=n[t+1]||n[t-1])&&(l=e.path+e.id)}),this.activeName=l,this.tabs=n.filter(function(e){return e.path+e.id!==a})}},mounted:function(){var e,t,n=window.Hotime,r=this,a=null!=n.mapData[this.routerPath]?(e=n.mapData[this.routerPath],this.routerId):(e=n.mapData[this.$route.path],this.$route.query.id);e.id=a,e.path.lastIndexOf("/info")==e.path.length-5?(e.tabType="info",this.tabs.push(e),this.activeName=e.path+a,!0===(t=n.mapData[e.path.slice(0,e.path.lastIndexOf("/info"))+"/edit"]).Auth.edit&&(t.tabType="edit",t.id=a,this.tabs.push(t))):e.path.lastIndexOf("/edit")==e.path.length-5?(e.tabType="edit",this.tabs.push(e),this.activeName=e.path+a,!0===(t=n.mapData[e.path.slice(0,e.path.lastIndexOf("/edit"))+"/info"]).Auth.info&&(t.tabType="info",t.id=a,this.tabs.push(t))):e.path.lastIndexOf("/add")==e.path.length-4?(e.tabType="add",this.tabs.push(e),this.activeName=e.path):(e.tabType="table",this.tabs.push(e),this.activeName=e.path+a),o.a.$off("tabs-edit"),o.a.$on("tabs-edit",function(e){var t=Object.assign({},n.mapData[e.path]),a=(t.label="关联"+t.parent.label.replace("管理","").replace("关联","")+t.label.replace("管理","").replace("关联",""),t.tabType=e.name.toLowerCase(),t.id=e.id,!1);r.tabs.forEach(function(e){e.path==t.path&&e.id==t.id&&(a=!0)}),a||(t.closable=!0,t.query=e.query,r.tabs.push(t)),r.activeName=t.path+t.id}),o.a.$off("tabs-edit-close"),o.a.$on("tabs-edit-close",function(n){var l=r.activeName,o=-1,i=r.tabs;i.forEach(function(e,t){var a;e.path==n.path&&e.id==n.id&&(a=i[(o=t)-1]||i[t+1])&&(l=a.path+a.id),e.path==n.path&&e.id==n.routerId&&(a=i[(o=t)-1]||i[t+1])&&(l=a.path+a.id)}),1==i[o].closable?(r.activeName=l,r.tabs=i.filter(function(e,t){return t!==o})):1==o?r.activeName=l:null!=r.close?r.close():r.$router.go(-1)})}},b={data:function(){return window.Hotime.vueComponent.APP=this,{showHeader:!0,routerViewShow:!0,items:[],showDialog:!1,dialogTitle:null,dialogDataPath:null,dialogDataId:null,dialogDataQuery:{},showTabDialog:!1,tabTitle:null,tabDataPath:null,tabDataId:null,tabDataQuery:{}}},components:{LeftNavMenu:l,HeaderNavMenu:c,Tabs:u.default,TabsEdit:i()(U,[["render",function(e,t,a,n,l,o){var i=Object(y.U)("Info"),r=Object(y.U)("Table"),c=Object(y.U)("Add"),u=Object(y.U)("el-tab-pane"),s=Object(y.U)("el-tabs");return Object(y.L)(),Object(y.l)(s,{modelValue:l.activeName,"onUpdate:modelValue":t[0]||(t[0]=function(e){return l.activeName=e}),type:"border-card",style:{width:"100%","overflow-y":"auto"},onTabRemove:o.removeTab},{default:Object(y.kb)(function(){return[(Object(y.L)(!0),Object(y.n)(y.b,null,Object(y.S)(l.tabs,function(e){return Object(y.L)(),Object(y.l)(u,{key:e.name,label:e.label,name:e.path+e.id,lazy:"",closable:1==e.closable},{default:Object(y.kb)(function(){return["info"==e.tabType?(Object(y.L)(),Object(y.l)(i,{key:0,"edit-dialog-path":e.path,"router-id":e.id},null,8,["edit-dialog-path","router-id"])):Object(y.m)("",!0),"table"==e.tabType?(Object(y.L)(),Object(y.l)(r,{key:1,"router-query":e.query,"router-id":e.id,"edit-dialog-path":e.path,style:{display:"flex","max-height":"70vh"}},null,8,["router-query","router-id","edit-dialog-path"])):Object(y.m)("",!0),"add"==e.tabType?(Object(y.L)(),Object(y.l)(c,{key:2,"router-query":e.query,"edit-dialog-path":e.path},null,8,["router-query","edit-dialog-path"])):Object(y.m)("",!0)]}),_:2},1032,["label","name","closable"])}),128))]}),_:1},8,["modelValue","onTabRemove"])}]])},mounted:function(){var t=this;o.a.$off("dialog"),o.a.$on("dialog",function(e){t.closeDialog(),setTimeout(function(){t.showDialog=!0,t.dialogTitle=e.title,t.dialogDataPath=e.path,t.dialogDataId=e.id,t.dialogDataQuery=e.query},150)}),o.a.$off("dialog-edit"),o.a.$on("dialog-edit",function(e){t.closeTabDialog(),setTimeout(function(){t.showTabDialog=!0,t.tabTitle=e.title,t.tabDataPath=e.path,t.tabDataId=e.id,t.tabDataQuery=e.query},150)}),this.routeInit()},methods:{goBack:function(){this.$router.back()},closeDialog:function(){this.showDialog=!1,this.dialogDataPath=null,this.dialogDataId=null,this.dialogDataQuery={}},closeTabDialog:function(){this.showTabDialog=!1,this.tabDataPath=null,this.tabDataId=null,this.tabDataQuery={}},createItems:function(e,t){return t.push({path:e.path,label:e.label,icon:e.icon,table:e.table}),t=null!=e.parent&&null!=e.parent.path?this.createItems(e.parent,t):t},routeInit:function(){var e=this,t=(this.routerViewShow=!1,setTimeout(function(){e.routerViewShow=!0},50),window.Hotime.mapData[this.$route.path]),a=[];null!=t&&((a=this.createItems(t,a)).reverse(),0!=a.length&&null==a[0].table&&(a[0].path="/"),this.items=a)}},watch:{$route:function(e){this.routeInit(e)}}};a("00d7"),t.default=i()(b,[["render",function(e,t,a,n,l,o){var i=Object(y.U)("header-nav-menu"),r=Object(y.U)("el-header"),c=Object(y.U)("left-nav-menu"),u=Object(y.U)("el-aside"),s=Object(y.U)("el-link"),b=Object(y.U)("el-divider"),d=Object(y.U)("el-breadcrumb-item"),f=Object(y.U)("el-breadcrumb"),m=Object(y.U)("router-view"),h=Object(y.U)("el-container"),p=Object(y.U)("el-main"),O=Object(y.U)("Tabs"),_=Object(y.U)("el-dialog"),j=Object(y.U)("TabsEdit"),k=Object(y.U)("el-footer");return Object(y.L)(),Object(y.l)(h,{style:{height:"100vh",background:"rgb(245,246,247)"}},{default:Object(y.kb)(function(){return[Object(y.lb)(Object(y.s)(r,{style:{"background-color":"rgb(44, 55, 89)",height:"56px"}},{default:Object(y.kb)(function(){return[Object(y.s)(i,{style:{color:"azure",height:"100%","text-align":"left",margin:"auto"}})]}),_:1},512),[[y.hb,l.showHeader]]),Object(y.s)(h,{style:{overflow:"hidden"}},{default:Object(y.kb)(function(){return[Object(y.s)(u,{width:"auto",style:{overflow:"hidden","max-width":"140px !important"}},{default:Object(y.kb)(function(){return[Object(y.s)(c)]}),_:1}),Object(y.s)(p,{style:{padding:"10px 10px 0 10px"}},{default:Object(y.kb)(function(){return[Object(y.s)(h,{style:{height:"100%"}},{default:Object(y.kb)(function(){return[Object(y.s)(r,{style:{height:"30px",padding:"0px",display:"flex"}},{default:Object(y.kb)(function(){return[Object(y.s)(s,{href:"javascript:void()",onClick:o.goBack,type:"primary",icon:"el-icon-back",underline:!1,style:{height:"13px",width:"60px"}},{default:Object(y.kb)(function(){return[v]}),_:1},8,["onClick"]),Object(y.s)(b,{direction:"vertical"}),Object(y.s)(f,{"separator-class":"el-icon-arrow-right",style:{"margin-bottom":"30px"}},{default:Object(y.kb)(function(){return[(Object(y.L)(!0),Object(y.n)(y.b,null,Object(y.S)(l.items,function(e){return Object(y.L)(),Object(y.l)(d,{key:e.path,to:{path:e.path}},{default:Object(y.kb)(function(){return[Object(y.o)("i",{class:Object(y.B)(e.icon),style:{"margin-right":"3px"}},null,2),Object(y.r)(Object(y.Y)(e.label),1)]}),_:2},1032,["to"])}),128))]}),_:1})]}),_:1}),Object(y.s)(h,{style:{"overflow-y":"auto"}},{default:Object(y.kb)(function(){return[l.routerViewShow?(Object(y.L)(),Object(y.l)(m,{key:0},{default:Object(y.kb)(function(e){var t=e.Component;return[Object(y.s)(y.f,{name:"el-zoom-in-center"},{default:Object(y.kb)(function(){return[(Object(y.L)(),Object(y.l)(y.c,null,[(Object(y.L)(),Object(y.l)(Object(y.W)(t)))],1024))]}),_:2},1024)]}),_:1})):Object(y.m)("",!0)]}),_:1})]}),_:1})]}),_:1})]}),_:1}),Object(y.s)(_,{title:l.dialogTitle,modelValue:l.showDialog,"onUpdate:modelValue":t[0]||(t[0]=function(e){return l.showDialog=e}),"destroy-on-close":"",onClose:o.closeDialog,width:"90vw","lock-scroll":""},{default:Object(y.kb)(function(){return[Object(y.o)("div",w,[l.showDialog?(Object(y.L)(),Object(y.l)(O,{key:0,"router-path":l.dialogDataPath,"router-id":l.dialogDataId,"router-query":l.dialogDataQuery,close:o.closeDialog},null,8,["router-path","router-id","router-query","close"])):Object(y.m)("",!0)])]}),_:1},8,["title","modelValue","onClose"]),Object(y.s)(_,{title:l.tabTitle,modelValue:l.showTabDialog,"onUpdate:modelValue":t[1]||(t[1]=function(e){return l.showTabDialog=e}),"destroy-on-close":"",onClose:o.closeTabDialog,width:"90vw","lock-scroll":""},{default:Object(y.kb)(function(){return[l.showTabDialog?(Object(y.L)(),Object(y.l)(j,{key:0,"router-path":l.tabDataPath,"router-id":l.tabDataId,"router-query":l.tabDataQuery,close:o.closeTabDialog},null,8,["router-path","router-id","router-query","close"])):Object(y.m)("",!0)]}),_:1},8,["title","modelValue","onClose"]),Object(y.s)(k,{style:{"background-color":"rgb(123, 08, 80)",height:"20px",color:"azure",display:"none"}},{default:Object(y.kb)(function(){return[g]}),_:1})]}),_:1})}]])}}]); |