Skip to content

Commit 9493cfe

Browse files
rushk014xingzhang-suse
authored andcommitted
fix: Remove Scan option in action menu on details page
1 parent 5075524 commit 9493cfe

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

pkg/sbombastic-image-vulnerability-scanner/models/sbombastic.rancher.io.registry.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ export default class Registry extends SteveModel {
77
console.log("Registry _availableActions");
88
const out = super._availableActions.filter(action => !['download','downloadYaml'].includes(action.action));
99

10+
// In details page, we don't want to show the scan action
11+
if (this.$rootState.targetRoute && 'id' in this.$rootState.targetRoute.params) {
12+
return out;
13+
}
14+
1015
const scanAction = {
1116
action: 'scanRegistry',
1217
label: this.t('imageScanner.registries.button.startScan'),

0 commit comments

Comments
 (0)