You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dubbo.apache.org by mi...@apache.org on 2018/09/25 09:58:47 UTC

[incubator-dubbo-ops] branch develop updated: Add $router.push for search access control (#120)

This is an automated email from the ASF dual-hosted git repository.

min pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/incubator-dubbo-ops.git


The following commit(s) were added to refs/heads/develop by this push:
     new 5254c54   Add $router.push for search access control (#120)
5254c54 is described below

commit 5254c54a6c686199f941c373456eef6c8d2a00e9
Author: 马金凯 <ma...@vip.qq.com>
AuthorDate: Tue Sep 25 17:58:43 2018 +0800

     Add $router.push for search access control (#120)
    
    * add Access Control search/delete/batch delete.
    
    * add Access Control create.
    
    * Change to use one DTO.
    
    * add edit Access Control
    
    * Fix access control `click got null` error
    
    * Add $router.push for search access control
---
 dubbo-admin-frontend/src/components/AccessControl.vue | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/dubbo-admin-frontend/src/components/AccessControl.vue b/dubbo-admin-frontend/src/components/AccessControl.vue
index 68c6fe1..bae3492 100644
--- a/dubbo-admin-frontend/src/components/AccessControl.vue
+++ b/dubbo-admin-frontend/src/components/AccessControl.vue
@@ -211,8 +211,9 @@ export default {
     },
     search (filter) {
       this.loading = true
+      this.$router.push({path: 'access', query: (filter !== '' ? {service: filter} : null)})
       AXIOS.post('/access/search', {
-        service: this.filter
+        service: filter
       }).then(response => {
         this.accesses = response.data
         this.loading = false
@@ -297,6 +298,14 @@ export default {
     }
   },
   mounted () {
+    let query = this.$route.query
+    let service = ''
+    Object.keys(query).forEach(function (key) {
+      if (key === 'service') {
+        service = query[key]
+      }
+    })
+    this.filter = service
     this.search(this.filter)
   },
   components: {