Skip to content

Commit

Permalink
fix RepoBranchTagSelector
Browse files Browse the repository at this point in the history
  • Loading branch information
wxiaoguang committed Dec 16, 2024
1 parent cfbb5a5 commit e618f1f
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions web_src/js/components/RepoBranchTagSelector.vue
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,16 @@ const sfc = {
if (this.menuVisible) this.menuVisible = false;
});
},
mounted() {
if (this.refFormActionTemplate) {
// if the selector is used in a form and needs to change the form action,
// make a mock item and select it to update the form action
const item: ListItem = {selected: true, refType: this.currentRefType, refShortName: this.currentRefShortName, rssFeedLink: ''};
this.selectItem(item);
}
},
methods: {
selectItem(item: ListItem) {
this.menuVisible = false;
Expand Down

0 comments on commit e618f1f

Please sign in to comment.