1 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-a579a368","chunk-234dc130","chunk-699f01e8"],{1065:function(t,e,n){},2873:function(t,e,n){},"2e99":function(t,e,n){"use strict";n("2873")},"424e":function(t,e,n){"use strict";n.d(e,"h",(function(){return r})),n.d(e,"e",(function(){return o})),n.d(e,"l",(function(){return c})),n.d(e,"a",(function(){return i})),n.d(e,"g",(function(){return u})),n.d(e,"c",(function(){return l})),n.d(e,"i",(function(){return s})),n.d(e,"b",(function(){return d})),n.d(e,"m",(function(){return m})),n.d(e,"f",(function(){return f})),n.d(e,"d",(function(){return p})),n.d(e,"j",(function(){return h})),n.d(e,"k",(function(){return b}));var a=n("b775");function r(t){return Object(a["a"])({url:"/document/list",method:"post",data:t})}function o(t){return Object(a["a"])({url:"/document/export",method:"post",data:t})}function c(t){return Object(a["a"])({url:"/document/edit",method:"post",data:t})}function i(t){return Object(a["a"])({url:"/document/add",method:"post",data:t})}function u(t){return Object(a["a"])({url:"/document/info/".concat(t),method:"get"})}function l(t){return Object(a["a"])({url:"/document/dele/".concat(t),method:"get"})}function s(t){return Object(a["a"])({url:"/document/category/search",method:"post",data:t})}function d(t){return Object(a["a"])({url:"/document/category/create",method:"post",data:t})}function m(t){return Object(a["a"])({url:"/document/category/update",method:"post",data:t})}function f(t){return Object(a["a"])({url:"/document/category/info",method:"post",data:t})}function p(t){return Object(a["a"])({url:"/document/category/delete/".concat(t),method:"get"})}function h(t){return Object(a["a"])({url:"/template/searchList",method:"post",data:t})}function b(t){return Object(a["a"])({url:"/document/list",method:"post",data:t})}},"8be6a":function(t,e,n){"use strict";n("1065")},a843: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",{staticClass:"data-search"},[n("el-form",{staticClass:"demo-form-inline",attrs:{inline:!0,model:t.queryForm}},[n("el-form-item",{attrs:{label:"文档标题:"}},[n("el-input",{attrs:{placeholder:"请填写文档标题"},model:{value:t.queryForm.dcm_title,callback:function(e){t.$set(t.queryForm,"dcm_title",e)},expression:"queryForm.dcm_title"}})],1),n("el-form-item",{attrs:{label:"所属分类:"}},[n("el-select",{staticClass:"m-2",attrs:{clearable:"",placeholder:"请选择分类",size:"large"},model:{value:t.queryForm.dcm_type,callback:function(e){t.$set(t.queryForm,"dcm_type",e)},expression:"queryForm.dcm_type"}},[n("el-option",{attrs:{label:"官方模板",value:1}}),n("el-option",{attrs:{label:"私有模板",value:2}}),n("el-option",{attrs:{label:"共享模板",value:3}})],1)],1),n("el-form-item",[n("el-button",{attrs:{type:"primary"},on:{click:t.onSubmit}},[n("svg-icon",{attrs:{"icon-class":"search"}}),t._v(" 搜索")],1)],1),t.createNewDocument?n("el-form-item",[n("el-button",{staticClass:"el-icon-circle-plus-outline",attrs:{type:"primary"},on:{click:t.addDocument}},[t._v("创建文档")])],1):t._e()],1)],1)},r=[],o=(n("14d9"),n("424e")),c={props:{queryForm:{type:Object,default:function(){return{page:1,pageSize:10,dcm_title:"",dcm_type:"",isContentShow:!1}}}},data:function(){return{statusOptions:[{value:"",label:"请选择状态"},{value:5,label:"启用"},{value:6,label:"停用"}],dialogVisible:!1,categoryList:[],createNewDocument:!0}},created:function(){this.initCategoryList(),this.checkCreatePermission()},methods:{checkCreatePermission:function(){},initCategoryList:function(){var t=this;Object(o["i"])({page:1,pageSize:999,status:5}).then((function(e){200==e.status&&(t.categoryList=e.data.dataList)}))},onCreate:function(t){this.dialogVisible=!0},onSubmit:function(){this.$emit("bindSetQuery",this.$props.queryForm)},addDocument:function(){this.$router.push("system/document/create?type=document")}}},i=c,u=(n("2e99"),n("2877")),l=Object(u["a"])(i,a,r,!1,null,null,null);e["default"]=l.exports},b792:function(t,e,n){"use strict";n.r(e);var a=n("a843");n.d(e,"dataSearch",(function(){return a["default"]}));var r=n("c6b2");n.d(e,"dataList",(function(){return r["default"]}))},c6b2: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:"dcm_id",label:"ID",align:"center",width:"80"}}),n("el-table-column",{attrs:{prop:"dcm_title",label:"文档标题",align:"left"}}),n("el-table-column",{attrs:{prop:"dcm_type",label:"文档模板类别",align:"center"},scopedSlots:t._u([{key:"default",fn:function(e){return[1==e.row.dcm_type?n("div",[t._v("官方模板")]):t._e(),2==e.row.dcm_type?n("div",[t._v("私有模板")]):t._e(),3==e.row.dcm_type?n("div",[t._v("共享模板")]):t._e()]}}])}),n("el-table-column",{attrs:{prop:"status",label:"文档状态",align:"center"},scopedSlots:t._u([{key:"default",fn:function(e){return[4==e.row.dcm_status?n("div",[t._v("已删除")]):t._e(),5==e.row.dcm_status?n("div",[t._v("启用")]):t._e(),6==e.row.dcm_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.dcm_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.dcm_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)},r=[],o=(n("14d9"),n("ac1f"),n("841c"),n("424e")),c={props:{queryForm:{type:Object,default:function(){return{page:1,pageSize:10,dcm_title:"",dcm_type:"",isContentShow:!1}}},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;e.$confirm("您是否确认删除该记录?","提示",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then((function(n){Object(o["c"])(t).then((function(t){e.search()}))})).catch((function(){}))},searchData:function(){var t=this;t.dialogVisible=!1,t.search()},btnEdit:function(t){this.$router.push("system/document/create?articleId="+t+"&type=document")},handleClose:function(){var t=this;t.currentData={},t.dialogVisible=!1},search:function(){var t=this;t.loading=!0,Object(o["k"])(t.queryForm).then((function(e){e?(t.dataList=e.data.dataList,t.recordCount=e.data.totalRecord,t.pageTotal=e.data.pageTotal,t.loading=!1):t.loading=!1})).catch((function(){t.loading=!1}))},ChangePage:function(t){var e=this;e.queryForm.page=t,e.search()}}},i=c,u=(n("8be6a"),n("2877")),l=Object(u["a"])(i,a,r,!1,null,null,null);e["default"]=l.exports}}]);
|