(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-5d83e469"],{"1c55":function(e,t,a){"use strict";a("23b6")},"23b6":function(e,t,a){},"38ea":function(e,t,a){"use strict";a("dd75")},dd75:function(e,t,a){},ece2:function(e,t,a){"use strict";a.r(t);var n=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticStyle:{width:"1200px",margin:"0 auto"}},[a("div",{staticClass:"title"},[a("span",{staticStyle:{"font-weight":"bold",margin:"0 8px"}},[e._v(e._s(e.searchData.text))]),e._v("搜索结果 ")]),e.searchData.keyword?a("ul",{staticClass:"search-list"},e._l(e.searchResult,(function(t,n){return a("li",{key:n},[a("div",{staticClass:"title-box"},[a("a",{staticClass:"title",on:{click:function(a){return e.onFileClicked(t)}}},[a("span",{domProps:{innerHTML:e._s(t.name)}})]),null!=t.tag?a("el-tag",[e._v(e._s(t.tag[0]))]):e._e()],1),a("div",{staticClass:"content"},[t.documentContentList.length>0?a("span",[e._v(" 【第"+e._s(t.documentContentList[0].pageIndex+1)+"页】 ")]):e._e(),a("span",{domProps:{innerHTML:e._s(t.documentContentList.length>0?t.documentContentList[0].content:"")}})])])})),0):e._e(),a("el-pagination",{staticStyle:{"text-align":"left"},style:{"margin-top":e.searchData.keyword?"0px":"30px"},attrs:{layout:"prev, pager, next","page-size":e.searchData.pageSize,total:e.pager.total},on:{"current-change":e.pageChanged}}),a("ReadFile",{ref:"readFile"})],1)},s=[],c=(a("c975"),a("d81d"),a("fb6a"),a("b0c0"),a("4d63"),a("ac1f"),a("25f0"),a("5319"),a("424e")),o=a("e853"),r=a("ff0b"),i={components:{ReadFile:r["a"]},data:function(){return{searchData:{docType:0,keyword:"",pageNum:1,pageSize:10,systemTag:null},pager:{total:0},searchResult:[]}},computed:{},watch:{$route:function(e){this.doSearch()}},methods:{doSearch:function(){var e=this;this.searchData.keyword=this.$route.query.s,this.searchData.keyword?Object(c["k"])(this.searchData).then((function(t){var a=t.code,n=(t.current,t.total),s=(t.pages,t.size,t.data);t.message;0==a&&(e.pager.total=n,e.searchResult=s.map((function(t){if(t.name=t.name.replace(new RegExp("(".concat(e.searchData.keyword,")"),"gim"),"<span class='key'>$1</span>"),t.documentContentList.length>0){t.documentContentList[0].content=t.documentContentList[0].content.replace(new RegExp("(".concat(e.searchData.keyword,")"),"gim"),"<span class='key'>$1</span>");var a,n=t.documentContentList[0].content;a=n.indexOf(e.searchData.keyword)>50?n.slice(n.indexOf(e.searchData.keyword)-50,n.indexOf(e.searchData.keyword)):n.slice(0,n.indexOf(e.searchData.keyword));var s=n.slice(n.indexOf(e.searchData.keyword),n.indexOf(e.searchData.keyword)+50);t.documentContentList[0].content=a+s}return t})))})):this.pager.total=0},onFileClicked:function(e){var t=this;null!=e.documentId&&(e.id=e.documentId),o["p"].getReaderUrl(e.shareId,e.documentId||e.id,e.documentId,e.name).then((function(e){var a=e.code,n=e.data,s=e.message;0==a?t.$refs["readFile"].showReadFile(t.$options.filters["readerUrl"](n.url)):1==a?t.$message.error(s):t.$message.error(s||"您不能查看当前文件")}))},pageChanged:function(e){this.searchData.pageNum=e,this.doSearch()}},created:function(){this.doSearch()},mounted:function(){}},d=i,l=(a("1c55"),a("38ea"),a("2877")),u=Object(l["a"])(d,n,s,!1,null,"a68cc1d6",null);t["default"]=u.exports}}]);
//# sourceMappingURL=chunk-5d83e469.eaf65b71.js.map