|
@@ -51,7 +51,7 @@
|
|
|
align="center"
|
|
|
label="报表状态"
|
|
|
prop="isAutoReport"
|
|
|
- width="180">
|
|
|
+ width="350">
|
|
|
<template slot-scope="scope">
|
|
|
<el-tag v-if="scope.row.userId != uid" type="success" style="margin-right: 5px;">被分享</el-tag>
|
|
|
<el-tag v-if="uid == scope.row.userId && scope.row.userGroupList && scope.row.userGroupList.length > 0"
|
|
@@ -62,19 +62,19 @@
|
|
|
<el-tag v-if="scope.row.isAutoReport == 3" style="margin-right: 5px;">事件驱动报表</el-tag>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column
|
|
|
- align="center"
|
|
|
- label="自动报表"
|
|
|
- prop="isAutoReport"
|
|
|
- width="150">
|
|
|
- <template slot-scope="scope">
|
|
|
- <el-switch v-if="scope.row.isAutoReport == '2'" :value="true" active-color="#13ce66"
|
|
|
- disabled></el-switch>
|
|
|
- <el-switch v-else :value="scope.row.isAutoReport == '1'" active-color="#13ce66"
|
|
|
- @change="switchChangeEvent($event, scope.row)"
|
|
|
- :disabled="uid != scope.row.userId"></el-switch>
|
|
|
- </template>
|
|
|
- </el-table-column>
|
|
|
+<!-- <el-table-column-->
|
|
|
+<!-- align="center"-->
|
|
|
+<!-- label="自动报表"-->
|
|
|
+<!-- prop="isAutoReport"-->
|
|
|
+<!-- width="150">-->
|
|
|
+<!-- <template slot-scope="scope">-->
|
|
|
+<!-- <el-switch v-if="scope.row.isAutoReport == '2'" :value="true" active-color="#13ce66"-->
|
|
|
+<!-- disabled></el-switch>-->
|
|
|
+<!-- <el-switch v-else :value="scope.row.isAutoReport == '1'" active-color="#13ce66"-->
|
|
|
+<!-- @change="switchChangeEvent($event, scope.row)"-->
|
|
|
+<!-- :disabled="uid != scope.row.userId"></el-switch>-->
|
|
|
+<!-- </template>-->
|
|
|
+<!-- </el-table-column>-->
|
|
|
<el-table-column
|
|
|
align="center"
|
|
|
label="当前版本"
|
|
@@ -89,7 +89,7 @@
|
|
|
prop="createTime"
|
|
|
width="200">
|
|
|
</el-table-column>
|
|
|
- <el-table-column label="操作" align="center" width="300">
|
|
|
+ <el-table-column label="操作" align="center" width="380">
|
|
|
<template slot-scope="scope">
|
|
|
<el-button type="text"
|
|
|
v-if="uid == scope.row.userId"
|
|
@@ -100,6 +100,12 @@
|
|
|
<el-button type="text"
|
|
|
v-if="uid == scope.row.userId"
|
|
|
size="small"
|
|
|
+ icon="el-icon-setting"
|
|
|
+ @click="setReportStatus(scope.row)">设置报表状态
|
|
|
+ </el-button>
|
|
|
+ <el-button type="text"
|
|
|
+ v-if="uid == scope.row.userId"
|
|
|
+ size="small"
|
|
|
icon="el-icon-user"
|
|
|
@click="setUserGroupEvent(scope.row)">授权
|
|
|
</el-button>
|
|
@@ -353,6 +359,7 @@
|
|
|
:append-to-body="true">
|
|
|
<div style="text-align: center;">
|
|
|
<el-radio v-model="reportType" label="0">手动报表</el-radio>
|
|
|
+ <el-radio v-model="reportType" label="1">自动报表</el-radio>
|
|
|
<el-radio v-model="reportType" label="3">事件驱动报表</el-radio>
|
|
|
</div>
|
|
|
<span slot='footer'>
|
|
@@ -869,6 +876,18 @@ export default {
|
|
|
type: 'warning'
|
|
|
})
|
|
|
}
|
|
|
+ // 自动报表
|
|
|
+ if (this.reportType == '1') {
|
|
|
+ this.resetRadioVal()
|
|
|
+ getReportTableById(this.reportId).then(res => {
|
|
|
+ this.dialogAutoReportVisible = true
|
|
|
+ this.cronVal = res.data.cron
|
|
|
+ this.analysisCron()
|
|
|
+ }).catch((e) => {
|
|
|
+ showAlertWin(this, e)
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
const loading = showLoading(this, '请稍候···')
|
|
|
let params = {
|
|
|
'id': this.reportId,
|
|
@@ -898,6 +917,11 @@ export default {
|
|
|
}
|
|
|
this.dialogReportTypeVisible = true
|
|
|
},
|
|
|
+ setReportStatus(data) {
|
|
|
+ this.reportId = data.id
|
|
|
+ this.reportType = data.isAutoReport + ''
|
|
|
+ this.dialogReportTypeVisible = true
|
|
|
+ },
|
|
|
/** 新增报表 */
|
|
|
addReportEvent() {
|
|
|
this.getAllReportTemplate()
|