|
@@ -3,7 +3,7 @@
|
|
|
<breadcrumb-view :breadcrumbList="breadcrumbList" :show-index="false"></breadcrumb-view>
|
|
|
<div v-if="btnType != 'show' && btnType != 'add'" class="cy-nav-sx">
|
|
|
<el-select v-model="searchValue"
|
|
|
- style="width: 180px;"
|
|
|
+ style="width: 280px;"
|
|
|
placeholder="请选择报表类型"
|
|
|
@change="changeReportTypeEvent">
|
|
|
<el-option v-for="item in reportOptions"
|
|
@@ -221,7 +221,7 @@
|
|
|
|
|
|
<script>
|
|
|
import BreadcrumbView from '@/components/BreadcrumbView'
|
|
|
-import {getNowFormatDate, showLoading} from '@/utils/cqcy'
|
|
|
+import {getNowFormatDate, showAlertWin, showLoading} from '@/utils/cqcy'
|
|
|
import {
|
|
|
delReportTableById,
|
|
|
getAllDataModel, getAllOkReportTable,
|
|
@@ -238,7 +238,6 @@ import {getUsername} from '@/utils/auth'
|
|
|
import {exportExcel} from '@/utils/export'
|
|
|
import {getAllUserGroup} from "@/api/user";
|
|
|
import {mapGetters} from "vuex";
|
|
|
-import errorCode from "@/utils/errorCode";
|
|
|
|
|
|
export default {
|
|
|
name: "index",
|
|
@@ -433,11 +432,7 @@ export default {
|
|
|
this.loadReport()
|
|
|
}).catch((e) => {
|
|
|
loading.close()
|
|
|
- this.$alert(e, errorCode[100], {
|
|
|
- confirmButtonText: '确定',
|
|
|
- callback: action => {
|
|
|
- }
|
|
|
- })
|
|
|
+ showAlertWin(this, e)
|
|
|
})
|
|
|
},
|
|
|
switchChangeEvent(val, data) {
|
|
@@ -447,7 +442,7 @@ export default {
|
|
|
getReportTableById(data.id).then(res => {
|
|
|
this.cronVal = res.data.cron
|
|
|
}).catch((e) => {
|
|
|
- console.log(e)
|
|
|
+ showAlertWin(this, e)
|
|
|
})
|
|
|
return
|
|
|
}
|
|
@@ -461,11 +456,7 @@ export default {
|
|
|
this.loadReport()
|
|
|
}).catch((e) => {
|
|
|
loading.close()
|
|
|
- this.$alert(e, errorCode[100], {
|
|
|
- confirmButtonText: '确定',
|
|
|
- callback: action => {
|
|
|
- }
|
|
|
- })
|
|
|
+ showAlertWin(this, e)
|
|
|
})
|
|
|
},
|
|
|
/** 新增报表 */
|
|
@@ -503,13 +494,8 @@ export default {
|
|
|
this.breadcrumbList = ['新增报表']
|
|
|
})
|
|
|
}).catch((e) => {
|
|
|
- console.log(e)
|
|
|
loading.close()
|
|
|
- this.$alert(e, errorCode[100], {
|
|
|
- confirmButtonText: '确定',
|
|
|
- callback: action => {
|
|
|
- }
|
|
|
- })
|
|
|
+ showAlertWin(this, e)
|
|
|
})
|
|
|
}
|
|
|
})
|
|
@@ -534,11 +520,7 @@ export default {
|
|
|
this.dialogReportTemplateVisible = false
|
|
|
}).catch((e) => {
|
|
|
loading.close()
|
|
|
- this.$alert(e, errorCode[100], {
|
|
|
- confirmButtonText: '确定',
|
|
|
- callback: action => {
|
|
|
- }
|
|
|
- })
|
|
|
+ showAlertWin(this, e)
|
|
|
})
|
|
|
},
|
|
|
/** 绘制 Excel 表 */
|
|
@@ -572,6 +554,7 @@ export default {
|
|
|
if (callback) callback(res.data)
|
|
|
}).catch((e) => {
|
|
|
if (callback) callback([])
|
|
|
+ showAlertWin(this, e)
|
|
|
})
|
|
|
},
|
|
|
/** 获取表格数据 */
|
|
@@ -584,6 +567,7 @@ export default {
|
|
|
if (callback) callback(res.data)
|
|
|
}).catch((e) => {
|
|
|
if (callback) callback([])
|
|
|
+ showAlertWin(this, e)
|
|
|
})
|
|
|
},
|
|
|
/** 向 Excel 插入表格 */
|
|
@@ -764,11 +748,7 @@ export default {
|
|
|
this.reportTemplateList = res.data.tableTemplateList
|
|
|
}).catch((e) => {
|
|
|
loading.close()
|
|
|
- this.$alert(e, errorCode[100], {
|
|
|
- confirmButtonText: '确定',
|
|
|
- callback: action => {
|
|
|
- }
|
|
|
- })
|
|
|
+ showAlertWin(this, e)
|
|
|
})
|
|
|
},
|
|
|
/** 查询所有数据模型 */
|
|
@@ -783,6 +763,7 @@ export default {
|
|
|
}
|
|
|
this.dataModelList = res.data.dataModelList
|
|
|
}).catch((e) => {
|
|
|
+ showAlertWin(this, e)
|
|
|
})
|
|
|
},
|
|
|
/** 查询我的报表列表 */
|
|
@@ -808,11 +789,7 @@ export default {
|
|
|
this.reportDataList = res.data.reportTableList
|
|
|
}).catch((e) => {
|
|
|
loading.close()
|
|
|
- this.$alert(e, errorCode[100], {
|
|
|
- confirmButtonText: '确定',
|
|
|
- callback: action => {
|
|
|
- }
|
|
|
- })
|
|
|
+ showAlertWin(this, e)
|
|
|
})
|
|
|
},
|
|
|
/** 设置用户组信息 */
|
|
@@ -835,6 +812,7 @@ export default {
|
|
|
}
|
|
|
})
|
|
|
}).catch((e) => {
|
|
|
+ showAlertWin(this, e)
|
|
|
})
|
|
|
},
|
|
|
chooseUserGroupEvent() {
|
|
@@ -859,6 +837,7 @@ export default {
|
|
|
this.dialogClose()
|
|
|
this.loadReport()
|
|
|
}).catch((e) => {
|
|
|
+ showAlertWin(this, e)
|
|
|
})
|
|
|
},
|
|
|
/** 处理自动报表数据信息 */
|
|
@@ -991,11 +970,7 @@ export default {
|
|
|
this.btnType = 'show'
|
|
|
}).catch((e) => {
|
|
|
loading.close()
|
|
|
- this.$alert(e, errorCode[100], {
|
|
|
- confirmButtonText: '确定',
|
|
|
- callback: action => {
|
|
|
- }
|
|
|
- })
|
|
|
+ showAlertWin(this, e)
|
|
|
})
|
|
|
},
|
|
|
/** 修改报表信息 */
|
|
@@ -1032,11 +1007,7 @@ export default {
|
|
|
this.loadReport()
|
|
|
}).catch((e) => {
|
|
|
loading.close()
|
|
|
- this.$alert(e, errorCode[100], {
|
|
|
- confirmButtonText: '确定',
|
|
|
- callback: action => {
|
|
|
- }
|
|
|
- })
|
|
|
+ showAlertWin(this, e)
|
|
|
})
|
|
|
}).catch((e) => {
|
|
|
console.log(e)
|
|
@@ -1064,11 +1035,7 @@ export default {
|
|
|
this.cancelSaveReport()
|
|
|
}).catch((e) => {
|
|
|
loading.close()
|
|
|
- this.$alert(e, errorCode[100], {
|
|
|
- confirmButtonText: '确定',
|
|
|
- callback: action => {
|
|
|
- }
|
|
|
- })
|
|
|
+ showAlertWin(this, e)
|
|
|
})
|
|
|
}).catch(() => {
|
|
|
})
|
|
@@ -1252,11 +1219,7 @@ export default {
|
|
|
this.cancelSaveReport()
|
|
|
}).catch((e) => {
|
|
|
loading.close()
|
|
|
- this.$alert(e, errorCode[100], {
|
|
|
- confirmButtonText: '确定',
|
|
|
- callback: action => {
|
|
|
- }
|
|
|
- })
|
|
|
+ showAlertWin(this, e)
|
|
|
})
|
|
|
}).catch((e) => {
|
|
|
console.log(e)
|