(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-669e4f68"],{1592:function(t,e,n){"use strict";n.r(e);var a=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticClass:"data-list",attrs:{"element-loading-text":"加载中..."}},[n("el-table",{staticStyle:{width:"100%"},attrs:{data:t.dataList,"header-row-class-name":"headerBg","empty-text":"没有模板信息"}},[n("el-table-column",{attrs:{prop:"id",label:"ID",align:"center",width:"80"}}),n("el-table-column",{attrs:{prop:"title",label:"模板名称",align:"left"}}),n("el-table-column",{attrs:{prop:"create_time",label:"创建时间",align:"center"}}),n("el-table-column",{attrs:{prop:"status",label:"模板状态",align:"center"},scopedSlots:t._u([{key:"default",fn:function(e){return[5==e.row.status?n("div",[t._v("启用")]):t._e(),6==e.row.status?n("div",[t._v("停用")]):t._e()]}}])}),n("el-table-column",{attrs:{label:"操作",align:"center",width:t.editWidth()},scopedSlots:t._u([{key:"default",fn:function(e){return[n("div",{staticClass:"btns"},[t.allowEdit?n("el-button",{attrs:{type:"primary",size:"small"},on:{click:function(n){return t.btnEdit(e.row.id)}}},[n("svg-icon",{attrs:{"icon-class":"edit"}}),t._v("编辑")],1):t._e(),t.allowDelete?n("el-button",{attrs:{type:"danger",size:"small"},on:{click:function(n){return t.btnDelete(e.row.id)}}},[n("svg-icon",{attrs:{"icon-class":"delete"}}),t._v("删除")],1):t._e()],1)]}}])})],1),n("div",{staticClass:"page-info"},[n("el-pagination",{attrs:{currentPage:t.queryForm.page,"page-size":t.queryForm.pageSize,total:t.recordCount,"page-count":t.pageTotal,background:"",layout:"prev, pager, next"},on:{"current-change":t.ChangePage}})],1)],1)},o=[],r=(n("14d9"),n("ac1f"),n("841c"),n("424e")),c={props:{queryForm:{type:Object,default:function(){return{page:1,pageSize:10,title:"",category_id:"",status:""}}},allowEdit:{type:Boolean,default:!1},allowDelete:{type:Boolean,default:!1}},watch:{queryForm:{handler:function(t){this.search()},deep:!0}},data:function(){return{loading:!1,dialogVisible:!1,currentDataId:0,recordCount:0,pageTotal:1,dataList:[],currentData:{}}},mounted:function(){this.search()},methods:{editWidth:function(){return this.allowDelete&&this.allowEdit?200:this.allowDelete||this.allowEdit?120:100},onFocusVal:function(t){var e=this;e.currentDataId=t.target.dataset.id},onChangeVal:function(t){var e=this;e.currentDataId},btnDelete:function(t){var e=this,n={id:t};e.$confirm("您是否确认删除该记录？","提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then((function(t){Object(r["c"])(n).then((function(t){e.search()}))})).catch((function(){}))},searchData:function(){var t=this;t.dialogVisible=!1,t.search()},btnEdit:function(t){this.$router.push("/document/system/document/create?articleId="+t)},handleClose:function(){var t=this;t.currentData={},t.dialogVisible=!1},search:function(){var t=this;t.loading=!0,Object(r["j"])(t.queryForm).then((function(e){e&&(t.dataList=e.data.dataList,t.recordCount=e.data.totalRecord,t.pageTotal=e.data.pageTotal,t.loading=!1)})).catch((function(){t.loading=!1}))},ChangePage:function(t){var e=this;e.queryForm.page=t,e.search()}}},u=c,i=(n("e315"),n("2877")),l=Object(i["a"])(u,a,o,!1,null,null,null);e["default"]=l.exports},"424e":function(t,e,n){"use strict";n.d(e,"h",(function(){return o})),n.d(e,"e",(function(){return r})),n.d(e,"l",(function(){return c})),n.d(e,"a",(function(){return u})),n.d(e,"g",(function(){return i})),n.d(e,"c",(function(){return l})),n.d(e,"i",(function(){return d})),n.d(e,"b",(function(){return s})),n.d(e,"m",(function(){return f})),n.d(e,"f",(function(){return h})),n.d(e,"d",(function(){return p})),n.d(e,"j",(function(){return m})),n.d(e,"k",(function(){return g}));var a=n("b775");function o(t){return Object(a["a"])({url:"/document/pageDocument",method:"post",data:t})}function r(t){return Object(a["a"])({url:"/document/export",method:"post",data:t})}function c(t){return Object(a["a"])({url:"/document/update",method:"post",data:t})}function u(t){return Object(a["a"])({url:"/document/create",method:"post",data:t})}function i(t){return Object(a["a"])({url:"/document/info",method:"post",data:t})}function l(t){return Object(a["a"])({url:"/document/delete",method:"post",data:t})}function d(t){return Object(a["a"])({url:"/document/category/search",method:"post",data:t})}function s(t){return Object(a["a"])({url:"/document/category/create",method:"post",data:t})}function f(t){return Object(a["a"])({url:"/document/category/update",method:"post",data:t})}function h(t){return Object(a["a"])({url:"/document/category/info",method:"post",data:t})}function p(t){return Object(a["a"])({url:"/document/category/delete",method:"post",data:t})}function m(t){return Object(a["a"])({url:"/template/searchList",method:"post",data:t})}function g(t){return Object(a["a"])({url:"/document/searchlistDoc",method:"post",data:t})}},d7be:function(t,e,n){},e315:function(t,e,n){"use strict";n("d7be")}}]);