|
@@ -10,6 +10,7 @@
|
|
</el-option>
|
|
</el-option>
|
|
</el-select>
|
|
</el-select>
|
|
</template>
|
|
</template>
|
|
|
|
+
|
|
<template slot="content">
|
|
<template slot="content">
|
|
<div v-if="reportData.roleCode !== 30">
|
|
<div v-if="reportData.roleCode !== 30">
|
|
<el-button type="primary" size="small" @click="createReport">新建月报</el-button>
|
|
<el-button type="primary" size="small" @click="createReport">新建月报</el-button>
|
|
@@ -38,7 +39,14 @@
|
|
</el-row>
|
|
</el-row>
|
|
</div>
|
|
</div>
|
|
<!-- 新建月报 -->
|
|
<!-- 新建月报 -->
|
|
- <normal-dialog :show-dialog="createReportDialog" :title="'新建月报'" :width="'40%'" @confirm="createReportDatas()" @cancel="createReportDialog=false">
|
|
|
|
|
|
+ <normal-dialog
|
|
|
|
+ref="normalDialog"
|
|
|
|
+:show-dialog="false"
|
|
|
|
+is-succes
|
|
|
|
+:title="'新建月报'"
|
|
|
|
+:width="'40%'"
|
|
|
|
+@succes="createReportDatas()"
|
|
|
|
+@cancel="$refs.normalDialog.visible = false">
|
|
<el-form ref="setReportData" :rules="rules" label-position="left" :model="setReportData" label-width="120px" class="report-create-margin">
|
|
<el-form ref="setReportData" :rules="rules" label-position="left" :model="setReportData" label-width="120px" class="report-create-margin">
|
|
<el-form-item label="名称" prop="reportName">
|
|
<el-form-item label="名称" prop="reportName">
|
|
<el-input v-model="setReportData.reportName" clearable placeholder="请输入内容" style="width: 100%;" />
|
|
<el-input v-model="setReportData.reportName" clearable placeholder="请输入内容" style="width: 100%;" />
|
|
@@ -132,7 +140,8 @@ export default {
|
|
}
|
|
}
|
|
},
|
|
},
|
|
async createReport() {
|
|
async createReport() {
|
|
- this.createReportDialog = true
|
|
|
|
|
|
+ // this.createReportDialog = true
|
|
|
|
+ this.$refs.normalDialog.visible = true
|
|
const res = await getReportBizInfo()
|
|
const res = await getReportBizInfo()
|
|
if (res.code === 200) {
|
|
if (res.code === 200) {
|
|
const list = res.data.bizList.map(x => { return x.id })
|
|
const list = res.data.bizList.map(x => { return x.id })
|
|
@@ -152,6 +161,7 @@ export default {
|
|
createMonthlyReport(data).then(res => {
|
|
createMonthlyReport(data).then(res => {
|
|
if (res.code === 200) {
|
|
if (res.code === 200) {
|
|
this.loading = false
|
|
this.loading = false
|
|
|
|
+ this.$refs.normalDialog.visible = false
|
|
this.$router.push({ path: '/monthlyReport/edit', query: { pageType: 'editAll', reportId: res.data.id, type: 'create' }})
|
|
this.$router.push({ path: '/monthlyReport/edit', query: { pageType: 'editAll', reportId: res.data.id, type: 'create' }})
|
|
window.log({ c: 'report_home', d: 'report_home_create' })
|
|
window.log({ c: 'report_home', d: 'report_home_create' })
|
|
}
|
|
}
|