0 ? this.agencyIdArray[this.agencyIdArray.length - 1] : '';
+
+ } else {
+ this.formData.agencyId = ''
+
+ }
+
+ },
+
+ getOrgTreeList () {
+ const { user } = this.$store.state
+ this.$http
+ .post('/gov/org/customeragency/my-subagency-list', {})
+ .then(({ data: res }) => {
+ if (res.code !== 0) {
+ return this.$message.error(res.msg)
+ } else {
+ console.log('获取组织树成功', res.data)
+ this.orgOptions = []
+ this.orgOptions.push(res.data)
+ }
+ })
+ .catch(() => {
+ return this.$message.error('网络错误')
+ })
+ },
+
+
handleSearch () {
this.loadTable()
},
@@ -679,7 +734,9 @@ export default {
//重置搜索条件
resetSearch () {
+ this.agencyIdArray = []
this.formData = {
+ agencyId: '',
unitName: '',
serviceMatter: '',
type: '',
diff --git a/src/views/modules/shequzhili/event/eventList.vue b/src/views/modules/shequzhili/event/eventList.vue
index 3dc1889a2..bca06c379 100644
--- a/src/views/modules/shequzhili/event/eventList.vue
+++ b/src/views/modules/shequzhili/event/eventList.vue
@@ -8,9 +8,9 @@
:label-width="'80px'">
-
-
-
+ -->
+
+
0 ? this.agencyIdArray[this.agencyIdArray.length - 1] : '';
+ this.formData.agencyId = ''
+ } else {
+ this.formData.agencyId = this.agencyIdArray.length > 0 ? this.agencyIdArray[this.agencyIdArray.length - 1] : '';
+ this.formData.gridId = ''
+ }
+
+ } else {
+ this.formData.agencyId = ''
+ this.formData.gridId = ''
+ }
+
+ },
+
handleEventType (val) {
// console.log('val-----eee', val)
console.log('nodes---', this.$refs.cascaderEvent.getCheckedNodes())
@@ -579,23 +618,22 @@ export default {
this.getTableData();
},
- async loadGrid () {
- const url = "/gov/org/customergrid/gridoption"
-
- let params = {
- agencyId: this.agencyId,
- purpose: "query"
- }
-
- const { data, code, msg } = await requestPost(url, params)
-
- if (code === 0) {
- this.gridList = data
-
- } else {
- this.$message.error(msg)
- }
-
+ getOrgTreeList () {
+ const { user } = this.$store.state
+ this.$http
+ .post('/gov/org/customeragency/agencygridtree', {})
+ .then(({ data: res }) => {
+ if (res.code !== 0) {
+ return this.$message.error(res.msg)
+ } else {
+ console.log('获取组织树成功', res.data)
+ this.orgOptions = []
+ this.orgOptions.push(res.data)
+ }
+ })
+ .catch(() => {
+ return this.$message.error('网络错误')
+ })
},
async handleExport () {
@@ -727,6 +765,7 @@ export default {
},
async getTableData () {
+ this.tableLoading = true
const url = "/gov/project/icEvent/list";
// const url = "http://yapi.elinkservice.cn/mock/245/gov/project/icEvent/list";
const { pageSize, pageNo, formData } = this;
@@ -735,6 +774,8 @@ export default {
pageNo,
...formData,
});
+
+ this.tableLoading = false
if (code === 0) {
this.total = data.total || 0;
@@ -791,7 +832,9 @@ export default {
},
resetSearch () {
+ this.agencyIdArray = []
this.formData = {
+ agencyId: '',
gridId: '',
sourceType: '',
eventContent: '',