diff --git a/src/views/xm/rpt/CompsCard.vue b/src/views/xm/rpt/CompsCard.vue
index d33f3bfe..dacfb31e 100644
--- a/src/views/xm/rpt/CompsCard.vue
+++ b/src/views/xm/rpt/CompsCard.vue
@@ -14,10 +14,10 @@
退出报告
制作报告
取消制作
- 保存报告
+ 保存报告
隐藏过滤条件
显示过滤条件
-
+
pdf
@@ -36,6 +36,18 @@
+
+
+
+
+
+
+
+
+
@@ -204,7 +216,7 @@ export default {
return {
isRptCfg:false,
isRptShow:false,
- xmRptConfig:null,
+ xmRptConfig:{},
xmRptData:{id:'',rptName:'',bizId:'',bizType:'',bizDate:''},
xmRptDataInit:{id:'',rptName:'',bizId:'',bizType:'',bizDate:''},
compCfgList:[],
@@ -214,6 +226,7 @@ export default {
paramsVisible:true,
rptDataListVisible:false,
createRptDataVisible:false,
+ createRptConfigVisible:false,
}
},
@@ -237,6 +250,13 @@ export default {
this.xmRptData.rptName=this.xmRptConfig.name
this.createRptDataVisible=true
+ },
+ toSaveRptCfg(){
+ this.createRptConfigVisible=true
+ if(!this.xmRptConfig.name){
+ this.xmRptConfig.name=this.rptConfigParamsCpd.name+"-报告"
+ }
+
},
toQueryRptData(){
this.rptDataListVisible=true;
@@ -274,12 +294,12 @@ export default {
})
},
undoRptCfg(){
- this.xmRptConfig=null;
+ this.xmRptConfig={};
this.isRptCfg=false;
},
undoRptShow(){
this.isRptShow=false;
- this.xmRptConfig=null;
+ this.xmRptConfig={};
this.xmRptData={...this.xmRptDataInit};
},
toRptCfg(){
@@ -292,7 +312,8 @@ export default {
var tips = res.data.tips;
if(tips.isOk){
this.isRptCfg=false
- this.xmRptConfig=null;
+ this.xmRptConfig={};
+ this.createRptConfigVisible=false;
this.$message.success("报告保存成功。将退出报告制作模式")
}else{
@@ -361,8 +382,12 @@ export default {
}
},
submitXmPrtConfig(callback){
- if(this.xmRptConfig==null){
- var xmRptConfig={...this.rptConfigParamsCpd,cfg:[]}
+ if(!this.xmRptConfig||!this.xmRptConfig.name){
+ this.$message.error("请输入报告名称")
+ return
+ }
+ if(!this.xmRptConfig.id){
+ var xmRptConfig={...this.rptConfigParamsCpd,name:this.xmRptConfig.name,cfg:[]}
this.compCfgList.forEach(k=>{
if(this.$refs[k.id] && this.$refs[k.id][0].$refs && this.$refs[k.id][0].$refs[k.id]){
var com=this.$refs[k.id][0].$refs[k.id]