提交 de3e4429 authored 作者: lihuihui's avatar lihuihui

修改bug

上级 b6b82ec0
......@@ -89,6 +89,7 @@ export default {
},
'objFn.paramsFn': {
handler () {
console.log(11111)
this.getList()
}
}
......
......@@ -136,7 +136,7 @@ export default {
this.dialogVisible = true
},
gobackActiveList () {
this.$router.push({ path: '/app/affairs-hall/hall' })
this.$router.push({ path: '/app/affairs-hall/hall', query: { index: 2 } })
},
onApplyFrom () {
this.$refs.setApplyForm.validate((valid) => {
......
......@@ -76,7 +76,9 @@ export default {
this.VueEvent.$off('command-tablelist-x')
},
mounted () {
this.getTapData()
const i = this.$route.query.index || 0
this.tapParam[0].selectIndex = i
this.getTapData(i)
this.VueEvent.$on('command-tablelist-x', (_obj) => {
if (_obj.command.command === 'activelist-show') {
const rid = _obj.tableData[_obj.index - 1].formId
......@@ -111,8 +113,9 @@ export default {
this.dialogVisible = false
},
setmPage () {
console.log(111)
this.objFn = {
paramsFn: (_this) => { return { affair_id: this.dataParam } },
paramsFn: (_this) => { return { affair_id: this.dataParam, action: Math.random() } },
nameAPI: 'getAffairsData',
actionClass: 'Affairs',
// nameExcel: 'getStatSummaryExcel',
......@@ -165,8 +168,8 @@ export default {
this.getData(data)
},
getData (data) {
console.log(5555)
const n = parseInt(data.index)
this.dataParam = data.id
switch (n) {
case 0:
this.tableHead = [
......@@ -204,22 +207,29 @@ export default {
]
break
}
this.dataParam = data.id
this.setmPage()
},
getTapData () {
const affairId = this.$route.query.id || ''
console.log(affairId, '=======')
getTapData (index) {
index = index !== undefined ? index : 0
const affairId = this.$route.query.affairId || ''
// 获取事务类型 tap切换
cAction.Affairs.getAffairsType().then(data => {
for (let i = 0; i < data.length; i++) {
console.log(this.tapParam[0])
this.tapParam[0].arrItem.push(
{ val: data[i].id, name: data[i].affair_name }
)
}
const param = {
id: this.tapParam[0].arrItem[0].val,
index: 0
const param = {}
if (affairId === '') {
param.id = this.tapParam[0].arrItem[index].val
param.index = index
} else {
param.id = affairId
param.index = 1
}
this.tapIndex = index
this.getData(param)
}).catch(e => {
this.$message.error(e.message)
......
......@@ -158,7 +158,7 @@ export default {
}).catch(e => { this.filesArr.pop(); this.$message.error(e.message) }).finally(() => { loading.close() })
},
gobackActiveList () {
this.$router.push({ path: '/app/affairs-hall/hall' })
this.$router.push({ path: '/app/affairs-hall/hall', query: { index: 0 } })
},
onApplyFrom () {
this.$refs.setApplyForm.validate((valid) => {
......
......@@ -150,7 +150,7 @@ export default {
}).catch(e => { this.filesArr.pop(); this.$message.error(e.message) }).finally(() => { loading.close() })
},
gobackActiveList () {
this.$router.push({ path: '/app/affairs-hall/hall', query: { id: this.$route.query.id } })
this.$router.push({ path: '/app/affairs-hall/hall', query: { index: 1 } })
},
onApplyFrom () {
this.$refs.setApplyForm.validate((valid) => {
......@@ -188,7 +188,7 @@ export default {
if (data.success) {
this.$message({ type: 'success', message: '提交成功' })
setTimeout(() => {
this.$router.push({ path: '/app/affairs-hall/hall' })
this.$router.push({ path: '/app/affairs-hall/hall', query: { index: 1 } })
}, 500)
}
}).catch(e => { this.filesArr.pop(); this.$message.error(e.message) }).finally(() => { loading.close() })
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论