| 1 |
- "use strict";(self["webpackChunkyos_manage"]=self["webpackChunkyos_manage"]||[]).push([[208],{4208:function(e,t,r){r.r(t),r.d(t,{default:function(){return b}});var a=function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"container"},[r("addTemp",{on:{onSuccess:e.queryReport}}),r("el-dialog",{attrs:{title:"编辑报表",visible:e.dialogTableVisible,width:"400px","append-to-body":"","close-on-click-modal":!1},on:{"update:visible":function(t){e.dialogTableVisible=t}}},[r("el-form",{staticClass:"demo-form-inline",attrs:{inline:!1,model:e.report,size:"small"}},[r("el-form-item",{staticStyle:{"padding-left":"30px"},attrs:{label:"应用"}},[r("el-select",{attrs:{placeholder:"请选择",filterable:""},model:{value:e.report.systemappid,callback:function(t){e.$set(e.report,"systemappid",t)},expression:"report.systemappid"}},e._l(e.apps,(function(e){return r("el-option",{key:e.systemappid,attrs:{label:e.systemmodulename+"-"+e.systemappname,value:e.systemappid}})})),1)],1),r("el-form-item",{staticStyle:{"padding-left":"30px"},attrs:{label:"站点"}},[r("el-select",{attrs:{placeholder:"请选择",filterable:"",clearable:""},model:{value:e.report.siteid,callback:function(t){e.$set(e.report,"siteid",t)},expression:"report.siteid"}},e._l(e.siteids,(function(e){return r("el-option",{key:e.siteid,attrs:{label:e.sitename,value:e.siteid}})})),1)],1),r("el-form-item",{staticStyle:{"padding-left":"30px"},attrs:{label:"启用"}},[r("el-switch",{attrs:{"active-value":1,"inactive-value":0,"active-color":"#13ce66","inactive-color":"#ff4949"},model:{value:e.report.isused,callback:function(t){e.$set(e.report,"isused",t)},expression:"report.isused"}})],1)],1),r("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[r("el-button",{attrs:{size:"small"},on:{click:function(t){e.dialogTableVisible=!1}}},[e._v("取 消")]),r("el-button",{attrs:{type:"primary",size:"small"},on:{click:function(t){return e.updatereport()}}},[e._v("确 定")])],1)],1),r("el-table",{staticStyle:{width:"100%"},attrs:{data:e.reports,border:"",stripe:"",size:"small","header-cell-style":{background:"#f1f2f3",color:"#333"}}},[r("el-table-column",{attrs:{prop:"rowindex",label:"行",width:"50",align:"center"}}),r("el-table-column",{attrs:{label:"操作",width:"60",align:"center"},scopedSlots:e._u([{key:"default",fn:function(t){return[r("el-button",{attrs:{slot:"reference",type:"text",size:"small"},on:{click:function(r){return e.openupdatedoalog(t.row)}},slot:"reference"},[e._v("编辑")])]}}])}),r("el-table-column",{attrs:{prop:"type",label:"类型",width:"100",align:"center"},scopedSlots:e._u([{key:"default",fn:function(t){return["printinfo"==t.row.type?r("el-tag",{attrs:{type:"primary",size:"mini"}},[e._v(" 打 印")]):e._e(),"chartinfo"==t.row.type?r("el-tag",{attrs:{type:"primary",size:"mini"}},[e._v(" 图 表")]):e._e(),"datainfo"==t.row.type?r("el-tag",{attrs:{type:"primary",size:"mini"}},[e._v(" 报 表")]):e._e()]}}])}),r("el-table-column",{attrs:{prop:"name",label:"报表名称"}}),r("el-table-column",{attrs:{prop:"systemappname",label:"应用",width:"150"}}),r("el-table-column",{attrs:{prop:"isused",label:"启用",width:"50",align:"center"},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v(" "+e._s(0===t.row.isused?"":"✅")+" ")]}}])}),r("el-table-column",{attrs:{prop:"siteid",label:"站点",width:"120"}}),r("el-table-column",{attrs:{label:"操作",width:"100",align:"center"},scopedSlots:e._u([{key:"default",fn:function(t){return[r("el-button",{attrs:{slot:"reference",type:"text",size:"small"},on:{click:function(r){return e.editreport(t.row)}},slot:"reference"},[e._v("设计")])]}}])}),r("el-table-column",{attrs:{prop:"create_time",label:"创建时间",width:"150"}}),r("el-table-column",{attrs:{prop:"update_time",label:"修改时间",width:"150"}}),r("el-table-column",{attrs:{prop:"view_count",label:"访问次数",width:"100"}}),r("el-table-column",{attrs:{label:"操作",width:"60",align:"center"},scopedSlots:e._u([{key:"default",fn:function(t){return[r("el-popconfirm",{attrs:{title:"确定删除吗?"},on:{confirm:function(r){return e.deleteReport(t.row)}}},[r("el-button",{attrs:{slot:"reference",type:"text",size:"small"},slot:"reference"},[e._v("删 除")])],1)]}}])})],1)],1)},n=[],s=r(6198),i=(r(5666),function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",[r("el-button",{staticStyle:{"margin-bottom":"10px"},attrs:{type:"primary",size:"small"},on:{click:function(t){e.dialogTableVisible=!0}}},[e._v("新 增")]),r("el-dialog",{attrs:{title:"新增报表",visible:e.dialogTableVisible,width:"400px"},on:{"update:visible":function(t){e.dialogTableVisible=t}}},[r("el-form",{staticClass:"demo-form-inline",attrs:{inline:!1,model:e.form,size:"small"}},[r("el-form-item",{staticStyle:{"padding-left":"30px"},attrs:{label:"应用"}},[r("el-select",{attrs:{placeholder:"请选择",filterable:""},model:{value:e.form.systemappid,callback:function(t){e.$set(e.form,"systemappid",t)},expression:"form.systemappid"}},e._l(e.apps,(function(e){return r("el-option",{key:e.systemappid,attrs:{label:e.systemmodulename+"-"+e.systemappname,value:e.systemappid}})})),1)],1),r("el-form-item",{staticStyle:{"padding-left":"30px"},attrs:{label:"站点"}},[r("el-select",{attrs:{placeholder:"请选择",filterable:"",clearable:""},model:{value:e.form.siteid,callback:function(t){e.$set(e.form,"siteid",t)},expression:"form.siteid"}},e._l(e.siteids,(function(e){return r("el-option",{key:e.siteid,attrs:{label:e.sitename,value:e.siteid}})})),1)],1),r("el-form-item",{staticStyle:{"padding-left":"30px"},attrs:{label:"启用"}},[r("el-switch",{attrs:{"active-value":1,"inactive-value":0,"active-color":"#13ce66","inactive-color":"#ff4949"},model:{value:e.form.isused,callback:function(t){e.$set(e.form,"isused",t)},expression:"form.isused"}})],1)],1),r("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[r("el-button",{attrs:{size:"small"},on:{click:function(t){e.dialogTableVisible=!1}}},[e._v("取 消")]),r("el-button",{attrs:{type:"primary",size:"small"},on:{click:function(t){return e.createreport()}}},[e._v("确 定")])],1)],1)],1)}),o=[],l={data:function(){return{dialogTableVisible:!1,form:{systemappid:"",siteid:""},param:{},apps:[],siteids:[]}},methods:{createreport:function(){var e=this;return(0,s.Z)(regeneratorRuntime.mark((function t(){var r;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,e.$api.requested({classname:"sysmanage.develop.report.report",method:"insertReport",content:e.form});case 2:r=t.sent,1===r.code?(e.$emit("onSuccess"),e.dialogTableVisible=!1,window.open(r.data)):e.$notify({title:r.msg,message:r.data,type:"error"});case 4:case"end":return t.stop()}}),t)})))()},appselect:function(){var e=this;return(0,s.Z)(regeneratorRuntime.mark((function t(){var r;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,e.$api.requested({classname:"sysmanage.develop.optiontype.optiontype",method:"optiontypeselect",content:{pageNumber:1,pageSize:1e4,typename:"appselectwithoutcondition",parameter:{}}});case 2:r=t.sent,e.apps=r.data,e.form.systemappid=163;case 5:case"end":return t.stop()}}),t)})))()},siteidselect:function(){var e=this;return(0,s.Z)(regeneratorRuntime.mark((function t(){var r;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,e.$api.requested({classname:"sysmanage.develop.optiontype.optiontype",method:"optiontypeselect",content:{pageNumber:1,pageSize:1e4,typename:"selecsiteid",parameter:{}}});case 2:r=t.sent,e.siteids=r.data;case 4:case"end":return t.stop()}}),t)})))()}},mounted:function(){this.appselect(),this.siteidselect()}},p=l,c=r(1001),u=(0,c.Z)(p,i,o,!1,null,null,null),d=u.exports,m={data:function(){return{dialogTableVisible:!1,reports:[],report:{},apps:[],siteids:[]}},components:{addTemp:d},methods:{queryReport:function(){var e=this;return(0,s.Z)(regeneratorRuntime.mark((function t(){var r;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return console.log("asds11d"),t.next=3,e.$api.requested({classname:"sysmanage.develop.report.report",method:"queryReportList",content:{}});case 3:r=t.sent,e.reports=r.data;case 5:case"end":return t.stop()}}),t)})))()},appselect:function(){var e=this;return(0,s.Z)(regeneratorRuntime.mark((function t(){var r;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,e.$api.requested({classname:"sysmanage.develop.optiontype.optiontype",method:"optiontypeselect",content:{pageNumber:1,pageSize:1e4,typename:"appselectwithoutcondition",parameter:{}}});case 2:r=t.sent,e.apps=r.data;case 4:case"end":return t.stop()}}),t)})))()},siteidselect:function(){var e=this;return(0,s.Z)(regeneratorRuntime.mark((function t(){var r;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,e.$api.requested({classname:"sysmanage.develop.optiontype.optiontype",method:"optiontypeselect",content:{pageNumber:1,pageSize:1e4,typename:"selecsiteid",parameter:{}}});case 2:r=t.sent,e.siteids=r.data;case 4:case"end":return t.stop()}}),t)})))()},editreport:function(e){var t=this;return(0,s.Z)(regeneratorRuntime.mark((function r(){var a;return regeneratorRuntime.wrap((function(r){while(1)switch(r.prev=r.next){case 0:return r.next=2,t.$api.requested({classname:"sysmanage.develop.report.report",method:"editReport",content:{sys_reportid:e.sys_reportid}});case 2:a=r.sent,window.open(a.data);case 4:case"end":return r.stop()}}),r)})))()},updatereport:function(){var e=this;return(0,s.Z)(regeneratorRuntime.mark((function t(){var r;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,e.$api.requested({classname:"sysmanage.develop.report.report",method:"updateReport",content:{sys_reportid:e.report.sys_reportid,siteid:e.report.siteid,systemappid:e.report.systemappid,isused:e.report.isused}});case 2:r=t.sent,1===r.code?(e.dialogTableVisible=!1,e.$emit("onSuccess"),e.queryReport()):e.$notify({title:r.msg,message:r.data,type:"error"});case 4:case"end":return t.stop()}}),t)})))()},openupdatedoalog:function(e){var t=this;return(0,s.Z)(regeneratorRuntime.mark((function r(){return regeneratorRuntime.wrap((function(r){while(1)switch(r.prev=r.next){case 0:t.dialogTableVisible=!0,t.report=Object.assign({},t.report,e);case 2:case"end":return r.stop()}}),r)})))()},deleteReport:function(e){var t=this;return(0,s.Z)(regeneratorRuntime.mark((function r(){var a;return regeneratorRuntime.wrap((function(r){while(1)switch(r.prev=r.next){case 0:return r.next=2,t.$api.requested({classname:"sysmanage.develop.report.report",method:"deleteReport",content:{sys_reportid:e.sys_reportid}});case 2:a=r.sent,1===a.code?t.queryReport():t.$notify({title:a.msg,message:a.data,type:"error"});case 4:case"end":return r.stop()}}),r)})))()}},mounted:function(){this.queryReport(),this.appselect(),this.siteidselect()}},f=m,y=(0,c.Z)(f,a,n,!1,null,null,null),b=y.exports}}]);
|