|
@@ -80,7 +80,11 @@
|
|
|
<a-button style="margin: 0px 2px;" @click="colseMenuClick">取消</a-button>
|
|
|
</a-menu-item>
|
|
|
</a-menu>
|
|
|
- <a-button style="margin-left: 8px;" @click="e => e.preventDefault()" v-has="'applyListByTableName:display-column'">
|
|
|
+ <a-button
|
|
|
+ style="margin-left: 8px;"
|
|
|
+ @click="e => e.preventDefault()"
|
|
|
+ v-has="'applyListByTableName:display-column'"
|
|
|
+ >
|
|
|
显示列
|
|
|
<a-icon type="down" />
|
|
|
</a-button>
|
|
@@ -429,32 +433,12 @@ export default {
|
|
|
created() {
|
|
|
console.log(this.$route.params)
|
|
|
this.tableName = this.$route.params.tableName
|
|
|
+ this.initial();
|
|
|
},
|
|
|
//时刻监听,一旦切换到其他申请表单则重新加载数据
|
|
|
watch: {
|
|
|
$route(to, from) {
|
|
|
- if (this.tableName != this.$route.params.tableName) {
|
|
|
- this.clear()
|
|
|
- this.tableName = this.$route.params.tableName
|
|
|
- ///////根据表单名称查询对应相关数据
|
|
|
- let businessTable = this.$route.params.tableName //表单表名称
|
|
|
- this.postFormAction('/activiti_process/listData', {
|
|
|
- businessTable: businessTable,
|
|
|
- status: 1,
|
|
|
- roles: true
|
|
|
- }).then(res => {
|
|
|
- // this.activeKeyAll = []
|
|
|
- //是否查询成功
|
|
|
- if (res.success) {
|
|
|
- var result = res.result || []
|
|
|
- if (result.length > 0) {
|
|
|
- //获取所属表单的相关数据
|
|
|
- this.tableDataObject = result[0]
|
|
|
- }
|
|
|
- }
|
|
|
- })
|
|
|
- this.loadData(1)
|
|
|
- }
|
|
|
+ this.initial();
|
|
|
}
|
|
|
},
|
|
|
|
|
@@ -570,6 +554,30 @@ export default {
|
|
|
},
|
|
|
computed: {},
|
|
|
methods: {
|
|
|
+ initial() {
|
|
|
+ // if (this.tableName != this.$route.params.tableName) {
|
|
|
+ this.clear()
|
|
|
+ this.tableName = this.$route.params.tableName
|
|
|
+ ///////根据表单名称查询对应相关数据
|
|
|
+ let businessTable = this.$route.params.tableName //表单表名称
|
|
|
+ this.postFormAction('/activiti_process/listData', {
|
|
|
+ businessTable: businessTable,
|
|
|
+ status: 1,
|
|
|
+ roles: true
|
|
|
+ }).then(res => {
|
|
|
+ // this.activeKeyAll = []
|
|
|
+ //是否查询成功
|
|
|
+ if (res.success) {
|
|
|
+ var result = res.result || []
|
|
|
+ if (result.length > 0) {
|
|
|
+ //获取所属表单的相关数据
|
|
|
+ this.tableDataObject = result[0]
|
|
|
+ }
|
|
|
+ }
|
|
|
+ })
|
|
|
+ this.loadData(1)
|
|
|
+ // }
|
|
|
+ },
|
|
|
handleMenuClickAll_comm() {
|
|
|
console.log(this.tableColumns)
|
|
|
if (this.checkedColumn.length === this.tableColumns.length) {
|
|
@@ -685,7 +693,7 @@ export default {
|
|
|
// }
|
|
|
},
|
|
|
colseMenuClick() {
|
|
|
- this.checkedColumn=[]
|
|
|
+ this.checkedColumn = []
|
|
|
this.tableColumns.forEach(t => {
|
|
|
if (t.isShow == '2') {
|
|
|
//默认显示列选择选中的列
|