chunk-52f4.8f228ad0.js 4.6 KB

1
  1. (window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-52f4"],{"8y9R":function(e,t,o){"use strict";var l=o("dcMo");o.n(l).a},WvJ4:function(e,t,o){"use strict";o.r(t);var l={name:"PermissionsList",data:function(){return{list:[{id:1,is_open:1,user_group:"标准版",username:"hdnjsd",at_register:"2019年2月21日",at_expire:"2019年12月31日",status:"有效"},{id:2,is_open:0,user_group:"定制版",username:"yan",at_register:"2019年2月21日",at_expire:"2019年12月31日",status:"已过期"},{id:3,is_open:1,user_group:"标准版",username:"leng",at_register:"2019年2月21日",at_expire:"2019年12月31日",status:"已禁用"},{id:4,is_open:0,user_group:"标准版",username:"liang",at_register:"2019年2月21日",at_expire:"2019年12月31日",status:"有效"}],dialogTableVisible:!1,search_form:{},form:{},loading:!1,table_loading:!1,rules:{}}},created:function(){console.log("created"),this.id=this.$route.params.id},destroyed:function(){console.log("destroyed")},methods:{edit:function(e){console.log(e);this.dialogTableVisible=!0},confirm:function(){console.log(this.form);this.dialogTableVisible=!1},search:function(){console.log(this.search_form)},delRow:function(e){var t=this;t.$confirm("确定删除吗","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){t.$message({type:"success",message:"删除成功!"})}).catch(function(){t.$message({type:"info",message:"已取消删除"})})}}},a=(o("8y9R"),o("KHd+")),r=Object(a.a)(l,function(){var e=this,t=e.$createElement,o=e._self._c||t;return o("div",{staticClass:"right"},[o("div",{staticClass:"right-head"},[o("div",{staticClass:"right-head-con"},[o("router-link",{attrs:{to:"/users/permissions"}},[o("el-button",{attrs:{type:"warning",size:"small",icon:"el-icon-back"}},[e._v("返回顶级菜单")])],1)],1),e._v(" "),o("el-button",{attrs:{type:"primary",size:"small",icon:"el-icon-plus"},on:{click:function(t){e.edit(0)}}},[e._v("添加权限")])],1),e._v(" "),o("el-form",{ref:"search_form",attrs:{inline:!0,model:e.search_form}},[o("el-form-item",[o("el-input",{attrs:{placeholder:""},model:{value:e.search_form.keyword,callback:function(t){e.$set(e.search_form,"keyword",t)},expression:"search_form.keyword"}})],1),e._v(" "),o("el-form-item",[o("el-button",{on:{click:function(t){e.search()}}},[e._v("搜索")])],1)],1),e._v(" "),[o("el-table",{directives:[{name:"loading",rawName:"v-loading",value:e.table_loading,expression:"table_loading"}],staticStyle:{width:"100%"},attrs:{data:e.list}},[o("el-table-column",{attrs:{prop:"id",label:"",align:"center"}}),e._v(" "),o("el-table-column",{attrs:{prop:"username",label:"权限规则",align:"center"}}),e._v(" "),o("el-table-column",{attrs:{prop:"user_group",label:"权限名称",align:"center"}}),e._v(" "),o("el-table-column",{attrs:{prop:"at_register",label:"权限概述",align:"center"}}),e._v(" "),o("el-table-column",{attrs:{prop:"at_expire",label:"权限创建日期",align:"center"}}),e._v(" "),o("el-table-column",{attrs:{prop:"status",label:"权限修改日期",align:"center"}}),e._v(" "),o("el-table-column",{attrs:{label:"操作","min-width":"180",align:"center"},scopedSlots:e._u([{key:"default",fn:function(t){return[o("el-button",{attrs:{type:"primary"},on:{click:function(o){e.edit(t.row.id)}}},[e._v("编辑")]),e._v(" "),o("el-button",{attrs:{type:"danger"},on:{click:function(o){e.delRow(t.row.id)}}},[e._v("删除")])]}}])})],1)],e._v(" "),o("el-dialog",{attrs:{title:"添加/编辑权限",visible:e.dialogTableVisible},on:{"update:visible":function(t){e.dialogTableVisible=t}}},[o("el-form",{ref:"form",attrs:{model:e.form,rules:e.rules,"label-width":"15%"}},[o("el-form-item",{attrs:{label:"权限规则",prop:"rule"}},[o("el-input",{attrs:{type:"text"},model:{value:e.form.rule,callback:function(t){e.$set(e.form,"rule",t)},expression:"form.rule"}})],1),e._v(" "),o("el-form-item",{attrs:{label:"权限名称",prop:"name"}},[o("el-input",{attrs:{type:"text"},model:{value:e.form.name,callback:function(t){e.$set(e.form,"name",t)},expression:"form.name"}})],1),e._v(" "),o("el-form-item",{attrs:{label:"权限概述",prop:"content"}},[o("el-input",{attrs:{type:"textarea",rows:5},model:{value:e.form.content,callback:function(t){e.$set(e.form,"content",t)},expression:"form.content"}})],1)],1),e._v(" "),o("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[o("el-button",{on:{click:function(t){e.dialogTableVisible=!1}}},[e._v("取 消")]),e._v(" "),o("el-button",{attrs:{type:"primary"},on:{click:function(t){e.confirm()}}},[e._v("确 定")])],1)],1)],2)},[],!1,null,null,null);r.options.__file="second_menu.vue";t.default=r.exports},dcMo:function(e,t,o){}}]);