|
@@ -47,7 +47,7 @@
|
|
|
<!-- 第一步 -->
|
|
|
<el-button v-if="showOne" size="small" type="primary" @click="NextStep()">下一步</el-button>
|
|
|
<!-- 第二步 -->
|
|
|
- <el-button v-if="newDailyTemplate" size="small" type="primary" @click="reportReturn">上一步</el-button>
|
|
|
+ <el-button v-if="newDailyTemplate" size="small" type="primary" @click="report_return">上一步</el-button>
|
|
|
<el-button v-if="newDailyTemplate" size="small" type="primary" @click="getCreateData">保存, 下一步</el-button>
|
|
|
<!-- 第三步 -->
|
|
|
<el-button v-if="dailyPreview" size="small" type="primary" @click="sendReportReturn">上一步</el-button>
|
|
@@ -170,14 +170,24 @@ export default {
|
|
|
},
|
|
|
|
|
|
created_out() { // 新建模版
|
|
|
- if (this.tits === '模版管理') {
|
|
|
- this.getreportTemplate()
|
|
|
- this.reportHome = '模版管理'
|
|
|
- this.showOne = true
|
|
|
- }
|
|
|
+ // if (this.tits === '模版管理') {
|
|
|
+ // this.getreportTemplate()
|
|
|
+ // this.reportHome = '模版管理'
|
|
|
+ // this.showOne = true
|
|
|
+ // }
|
|
|
this.$refs.newReleaeTemplate.getCreateData(this.templateId)
|
|
|
},
|
|
|
|
|
|
+ report_return() {
|
|
|
+ this.reportHome = '准出报告' // 步骤条
|
|
|
+ this.showOne = true // 模版选择
|
|
|
+ this.reportTamplate = false // 编辑区域
|
|
|
+ this.newDailyTemplate = false // 隐藏第二步
|
|
|
+ this.dailyPreview = false // 隐藏第三步
|
|
|
+ this.customList = []
|
|
|
+ this.getreportTemplate()
|
|
|
+ },
|
|
|
+
|
|
|
reportReturn() { // 新建模版点击返回
|
|
|
this.reportHome = this.tits // 步骤条
|
|
|
this.showOne = true // 模版选择
|
|
@@ -189,7 +199,7 @@ export default {
|
|
|
},
|
|
|
|
|
|
open_new_template(val, show) { // 点击新建模版
|
|
|
- !val ? this.templateId = { 'name': '新建模版', from: this.customList.length === 0 ? this.temporary.from : [] } : this.templateId = { 'name': '编辑模版', 'set_up': val.id }
|
|
|
+ !val ? this.templateId = { 'name': '新建模版', from: this.customList.length !== 0 ? this.temporary.from : {}} : this.templateId = { 'name': '编辑模版', 'set_up': val.id }
|
|
|
this.tits = this.reportHome
|
|
|
if (this.templateId.name === '新建模版') {
|
|
|
this.reportTamplate = true // 编辑区域
|
|
@@ -224,6 +234,7 @@ export default {
|
|
|
|
|
|
getCustom(arr) { // 自定义确认
|
|
|
console.log(arr, this.temporary.name, '结果')
|
|
|
+ this.templateId = { 'from': this.temporary.from, 'name': this.temporary.name === '创建准出报告模版' ? '新建模版' : '编辑模版' }
|
|
|
this.customList = [...arr]
|
|
|
this.reportHome = this.temporary.name
|
|
|
},
|
|
@@ -260,6 +271,7 @@ export default {
|
|
|
if (res.code === 200) {
|
|
|
this.daily_taskIds = null// 关联任务
|
|
|
this.fromData.radio = res.data // 选择的模块
|
|
|
+ this.customList = res.data.customFields
|
|
|
}
|
|
|
this.reportHome = '准出报告' // 步骤条
|
|
|
this.active = 2 // 步骤条状态第三步
|