You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
2 lines
250 KiB
2 lines
250 KiB
6 years ago
|
webpackJsonp([24],{1014:function(e,t,n){"use strict";t.__esModule=!0;t.handlerSuffix={".txt":"textile",".log":"textile",".sh":"shell",".conf":"textile",".cfg":"textile",".py":"python",".java":"textile",".sql":"sql",".hql":"sql",".xml":"xml"}},1015:function(e,t,n){"use strict";t.__esModule=!0,t.default={name:"no-type"}},1053:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(1015),i=n.n(r);for(var o in r)"default"!==o&&function(e){n.d(t,e,function(){return r[e]})}(o);var a=n(1056);var s=function(e){n(1054)},l=n(29)(i.a,a.a,!1,s,null,null);t.default=l.exports},1054:function(e,t,n){var r=n(1055);"string"==typeof r&&(r=[[e.i,r,""]]),r.locals&&(e.exports=r.locals);n(35)("2c02ac1c",r,!0,{})},1055:function(e,t,n){(e.exports=n(34)(!1)).push([e.i,".no-type-model{text-align:center;padding-top:160px}.no-type-model>p{padding-top:10px;color:#666}",""])},1056:function(e,t,n){"use strict";var r={render:function(){var e=this.$createElement,t=this._self._c||e;return t("div",{staticClass:"no-type-model"},[t("img",{attrs:{src:n(1057),alt:""}}),this._v(" "),t("p",[this._v(this._s(this.$t("Online viewing type is not supported")))])])},staticRenderFns:[]};t.a=r},1057:function(e,t,n){e.exports=n.p+"images/down_error.png?4339cb288e29d420babb7d7c848b9093"},1109:function(e,t,n){"use strict";t.__esModule=!0;var r=p(n(30)),i=n(123),o=n(925),a=p(n(1053)),s=n(879),l=p(n(851)),c=p(n(701)),u=p(n(227)),d=p(n(696)),f=n(1014),h=p(n(697));function p(e){return e&&e.__esModule?e:{default:e}}var m=void 0;t.default={name:"file-details",data:function(){return{name:"",isNoType:!0,isLoading:!1,filtTypeArr:o.filtTypeArr,loadingIndex:0,mode:"python",isData:!0,size:null,spinnerLoading:!1,msg:""}},props:{},methods:Object.assign({},(0,i.mapActions)("resource",["getViewResources","updateContent"]),{ok:function(){var e=this;this.spinnerLoading=!0,this.updateContent({id:this.$route.params.id,content:m.getValue()}).then(function(t){e.$message.success(t.msg),setTimeout(function(){e.spinnerLoading=!1,e.close()},800)}).catch(function(t){e.$message.error(t.msg||""),e.spinnerLoading=!1})},close:function(){this.$router.push({name:"file"})},_getViewResources:function(){var e=this;this.isLoading=!0,this.getViewResources({id:this.$route.params.id,skipLineNum:0,limit:2e3}).then(function(t){e.name=t.data.alias.split(".")[0],t.data?(e.isData=!0,e._handlerEditor().setValue(t.data.content||""),setTimeout(function(){$(".code-mirror-model").scrollTop(12).scrollLeft(0)},200)):e.isData=!1,e.isLoading=!1}).catch(function(t){e.msg=t.msg||"error",e.$message.error(t.msg||""),e.isLoading=!1})},_handlerEditor:function(){return m=(0,l.default)("code-edit-mirror",{mode:this.mode,readOnly:!1}),this.keypress=function(){m.getOption("readOnly")||m.showHint({completeSingle:!1})},m.on("keypress",this.keypress),m}}),watch:{},created:function(){var e=r.default.split(u.default.getItem("file"),"|",2),t=e[0],n=e[1],i=t.lastIndexOf("."),o=t.substring(i,t.length);this.mode=f.handlerSuffix[o],this.size=(0,s.bytesToSize)(parseInt(n)),this.isNoType=r.default.includes(this.filtTypeArr,r.default.trimStart(o,"."))},mounted:function(){this.isNoType&&this._getViewResources()},destroyed:function(){m&&(m.toTextArea(),m.off($(".code-edit-mirror"),"keypress",this.keypress))},computed:{},components:{mListConstruction:h.default,mNoType:a.default,mSpin:c.default,mNoData:d.default}}},1221:function(e,t,n){var r=n(1222);"string"==typeof r&&(r=[[e.i,r,""]]),r.locals&&(e.exports=r.locals);n(35)("4958afcf",r,!0,{})},1222:function(e,t,n){(e.exports=n(34)(!1)).push([e.i,".file-edit-content{width:100%;background:#fff;padding-bottom:20px}.file-edit-content>h2{line-height:60px;text-align:center;padding-bottom:6px;position:relative}.file-edit-content>h2 .down{position:absolute;right:0;top:0}.file-edit-content>h2 .down>i{font-size:20px;color:#2d8cf0;cursor:pointer;vertical-align:middle}.file-edit-content>h2 .down em{font-size:12px;font-style:normal;vertical-align:middle;color:#777;margin-left:-2px}.file-edit-content .code-mirror-model{height:calc(100vh - 300px)}.file-edit-content .code-mirror-model .cm
|
||
|
//# sourceMappingURL=24.6e296a1.js.map
|