dashboard-shell-shell 1.0.1000000112 → 1.0.1000000113

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -416,6 +416,7 @@ export default {
416
416
  </script>
417
417
 
418
418
  <template>
419
+ 测试111111111111111111111111
419
420
  <div class="project-namespaces outlet">
420
421
  <Masthead
421
422
  :schema="projectSchema"
@@ -418,26 +418,13 @@ export default {
418
418
  let isCreatable = false;
419
419
  const lastPath = this.$route.path.split('/'.pop());
420
420
 
421
- if (lastPath?.includes('.')) {
421
+ if (lastPath.includes('.')) {
422
422
  isCreatable = this.$store.getters['type-map/optionsFor'](lastPath).isCreatable;
423
423
  } else if (lastPath === 'namespace') {
424
424
  isCreatable = this.$store.getters['type-map/optionsFor'](this.$route.name).isCreatable;
425
425
  }
426
426
 
427
- const resource = this.$route.params.resource;
428
-
429
- let hasEditComponent = false
430
-
431
- if (lastPath?.includes('.')) {
432
- hasEditComponent = this.$store.getters['type-map/hasCustomEdit'](lastPath);
433
- } else if (lastPath === 'namespace') {
434
- hasEditComponent = this.$store.getters['type-map/hasCustomEdit'](this.$route.name);
435
- } else {
436
- hasEditComponent = this.$store.getters['type-map/hasCustomEdit'](resource);
437
- }
438
-
439
427
  return {
440
- hasEditComponent,
441
428
  refreshButtonPhase: isLoading ? ASYNC_BUTTON_STATES.WAITING : ASYNC_BUTTON_STATES.ACTION,
442
429
  expanded: {},
443
430
  searchQuery,
@@ -1240,7 +1227,7 @@ export default {
1240
1227
  <div
1241
1228
  :class="{'titled': $slots.title && $slots.title.length, 'mb-40': isFilterLabel, 'mb-20': search || isCreatable}"
1242
1229
  class="sortable-table-header "
1243
- :style="{marginTop: search&& !isBanner ? marginTopValue + 'px' : '0px',marginLeft: isCreatable && hasEditComponent ? '100px' : '-10px',maxHeight: '32px'}"
1230
+ :style="{marginTop: search&& !isBanner ? marginTopValue + 'px' : '0px',marginLeft: isCreatable ? '100px' : '-10px',maxHeight: '32px'}"
1244
1231
  >
1245
1232
  <slot name="title" />
1246
1233
  <div
@@ -737,7 +737,7 @@ export default {
737
737
  <Tab
738
738
  v-if="isRancherRoleTemplate"
739
739
  name="inherit-from"
740
- label="继承表单"
740
+ label="Inherit From"
741
741
  :weight="0"
742
742
  >
743
743
  <ArrayList
@@ -22,17 +22,17 @@ export function installNavigationGuards(router, context) {
22
22
  let changed = false;
23
23
  const params = { ...to.params };
24
24
 
25
- if (params?.product?.includes('cloud')) {
25
+ if (params.product?.includes('cloud')) {
26
26
  params.product = params.product.replace(/cloud/g, 'harvester');
27
27
  changed = true;
28
28
  }
29
29
 
30
- if (params?.cluster?.includes('cloud')) {
30
+ if (params.cluster?.includes('cloud')) {
31
31
  params.cluster = params.cluster.replace(/cloud/g, 'harvester');
32
32
  changed = true;
33
33
  }
34
34
 
35
- if (params?.resource?.includes('cloud')) {
35
+ if (params.resource?.includes('cloud')) {
36
36
  params.resource = params.resource.replace(/cloud/g, 'harvester');
37
37
  changed = true;
38
38
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dashboard-shell-shell",
3
- "version": "1.0.1000000112",
3
+ "version": "1.0.1000000113",
4
4
  "description": "Rancher Dashboard Shell",
5
5
  "repository": "https://github.com/rancherlabs/dashboard",
6
6
  "license": "Apache-2.0",
package/utils/router.js CHANGED
@@ -89,7 +89,7 @@ export const getPackageFromRoute = (route) => {
89
89
  };
90
90
 
91
91
  export const getResourceFromRoute = (to) => {
92
- let resource = to.params?.resource;
92
+ let resource = cloud2harvesterhci(to.params?.resource);
93
93
 
94
94
  if (!resource) {
95
95
  resource = findMeta(to, 'resource');