File tree Expand file tree Collapse file tree 8 files changed +10
-10
lines changed
Expand file tree Collapse file tree 8 files changed +10
-10
lines changed Original file line number Diff line number Diff line change 622622 <div class =" resource-detail-item__label" >{{ $t('label.storagepool') }}</div >
623623 <div class =" resource-detail-item__details" >
624624 <database-outlined />
625- <router-link v-if =" !isStatic && $router.resolve('/storagepool/' + resource.storageid).matched[0].redirect !== '/exception/404'" :to =" { path: '/storagepool/' + resource.storageid }" >{{ resource.storage || resource.storageid }} </router-link >
625+ <router-link v-if =" !isStatic && $router.resolve('/storagepool/' + encodeURIComponent( resource.storageid)) .matched[0].redirect !== '/exception/404'" :to =" { path: '/storagepool/' + encodeURIComponent( resource.storageid) }" >{{ resource.storage || resource.storageid }} </router-link >
626626 <span v-else >{{ resource.storage || resource.storageid }}</span >
627627 <a-tag style =" margin-left : 5px ;" v-if =" resource.storagetype" >
628628 {{ resource.storagetype }}
Original file line number Diff line number Diff line change 9494 <router-link :to =" { path: $route.path + '/' + record.id, query: { displaynetwork: false } }" v-if =" record.id" >{{ $t(text.toLowerCase()) }}</router-link >
9595 </span >
9696 <span v-else >
97- <router-link :to =" { path: $route.path + '/' + record.id }" v-if =" record.id" >{{ text }}</router-link >
97+ <router-link :to =" { path: $route.path + '/' + encodeURIComponent( record.id) }" v-if =" record.id" >{{ text }}</router-link >
9898 <router-link :to =" { path: $route.path + '/' + record.name }" v-else >{{ text }}</router-link >
9999 <span v-if =" ['guestnetwork','vpc'].includes($route.path.split('/')[1]) && record.restartrequired && !record.vpcid" >
100100   ;
306306 <span v-else >{{ text }}</span >
307307 </template >
308308 <template v-if =" column .key === ' storage' " >
309- <router-link v-if =" record.storageid" :to =" { path: '/storagepool/' + record.storageid }" >{{ text }}</router-link >
309+ <router-link v-if =" record.storageid" :to =" { path: '/storagepool/' + encodeURIComponent( record.storageid) }" >{{ text }}</router-link >
310310 <span v-else >{{ text }}</span >
311311 </template >
312312 <template v-for =" (value , name ) in thresholdMapping " :key =" name " >
Original file line number Diff line number Diff line change 4141 {{ parseFloat(record.size / (1024.0 * 1024.0 * 1024.0)).toFixed(2) }} GB
4242 </template >
4343 <template v-if =" column .key === ' storage' " >
44- <router-link v-if =" record.storageid" :to =" { path: '/storagepool/' + record.storageid }" >{{ text }}</router-link >
44+ <router-link v-if =" record.storageid" :to =" { path: '/storagepool/' + encodeURIComponent( record.storageid) }" >{{ text }}</router-link >
4545 <span v-else >{{ text }}</span >
4646 </template >
4747 </template >
Original file line number Diff line number Diff line change @@ -100,7 +100,7 @@ export default {
100100 this .breadList = []
101101 this .$route .matched .forEach ((item , idx ) => {
102102 const parent = this .$route .matched [idx - 1 ]
103- if (item && parent && parent .name !== ' index' && ! item .path .endsWith (' :id' )) {
103+ if (item && parent && parent .name !== ' index' && ! item .path .endsWith (' :id' ) && ! item . path . endsWith ( ' :id(.*) ' ) ) {
104104 this .breadList .pop ()
105105 }
106106 this .breadList .push (item)
Original file line number Diff line number Diff line change @@ -90,7 +90,7 @@ function generateRouterMap (section) {
9090 hideChildrenInMenu : true ,
9191 children : [
9292 {
93- path : '/' + child . name + '/:id' ,
93+ path : '/' + child . name + '/:id(.*) ' ,
9494 hidden : child . hidden ,
9595 meta : {
9696 title : child . title ,
@@ -145,7 +145,7 @@ function generateRouterMap (section) {
145145 map . meta . tabs = section . tabs
146146
147147 map . children = [ {
148- path : '/' + section . name + '/:id' ,
148+ path : '/' + section . name + '/:id(.*) ' ,
149149 actions : section . actions ? section . actions : [ ] ,
150150 meta : {
151151 title : section . title ,
Original file line number Diff line number Diff line change 9090 :rowKey =" record => record.zoneid" >
9191 <template #bodyCell =" { text , record , column } " >
9292 <template v-if =" column .dataIndex === ' datastore' && record .datastoreId " >
93- <router-link :to =" { path: '/storagepool/' + record.datastoreId }" >
93+ <router-link :to =" { path: '/storagepool/' + encodeURIComponent( record.datastoreId) }" >
9494 {{ text }}
9595 </router-link >
9696 </template >
Original file line number Diff line number Diff line change 8080 :rowKey =" record => record.datastoreId" >
8181 <template #bodyCell =" { text , record , column } " >
8282 <template v-if =" column .dataIndex === ' datastore' && record .datastoreId " >
83- <router-link :to =" { path: '/storagepool/' + record.datastoreId }" >
83+ <router-link :to =" { path: '/storagepool/' + encodeURIComponent( record.datastoreId) }" >
8484 {{ text }}
8585 </router-link >
8686 </template >
Original file line number Diff line number Diff line change 3838 <template #bodyCell =" { column , record } " >
3939 <template v-if =" column .key === ' zonename' " >
4040 <span v-if =" record.datastoreid" >
41- <router-link :to =" { path: (record.datastoretype === 'Primary' ? '/storagepool/' : '/imagestore/') + record.datastoreid }" >
41+ <router-link :to =" { path: (record.datastoretype === 'Primary' ? '/storagepool/' : '/imagestore/') + encodeURIComponent( record.datastoreid) }" >
4242 <span v-if =" fetchZoneIcon(record.zoneid)" >
4343 <resource-icon :image =" zoneIcon" size =" 1x" style =" margin-right : 5px " />
4444 </span >
You can’t perform that action at this time.
0 commit comments