Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
wxiaoguang committed Apr 14, 2023
1 parent 4df0a52 commit c99db35
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
8 changes: 4 additions & 4 deletions templates/org/team/repositories.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@
</div>
<div class="inline ui field right">
<form class="ui form" id="repo-multiple-form" action="{{$.OrgLink}}/teams/{{$.Team.LowerName | PathEscape}}/repositories" method="post">
<button class="ui red button delete-button right" data-url="{{$.OrgLink}}/teams/{{$.Team.LowerName | PathEscape}}/action/repo/removeall">{{.locale.Tr "remove_all"}}</button>
<button class="ui green button add-all-button right" data-url="{{$.OrgLink}}/teams/{{$.Team.LowerName | PathEscape}}/action/repo/addall">{{.locale.Tr "add_all"}}</button>
<button class="ui red button delete-button right" data-modal-id="org-team-remove-all-repo" data-url="{{$.OrgLink}}/teams/{{$.Team.LowerName | PathEscape}}/action/repo/removeall">{{.locale.Tr "remove_all"}}</button>
<button class="ui green button add-all-button right" data-modal-id="org-team-add-all-repo" data-url="{{$.OrgLink}}/teams/{{$.Team.LowerName | PathEscape}}/action/repo/addall">{{.locale.Tr "add_all"}}</button>
</form>
</div>
</div>
Expand Down Expand Up @@ -64,7 +64,7 @@
</div>
</div>

<div class="ui small basic delete modal">
<div class="ui small basic delete modal" id="org-team-remove-all-repo">
<div class="ui icon header">
{{svg "octicon-trash"}}
{{.locale.Tr "org.teams.remove_all_repos_title"}}
Expand All @@ -75,7 +75,7 @@
{{template "base/delete_modal_actions" .}}
</div>

<div class="ui small basic addall modal">
<div class="ui small basic addall modal" id="org-team-add-all-repo">
<div class="ui icon header">
{{svg "octicon-globe"}}
{{.locale.Tr "org.teams.add_all_repos_title"}}
Expand Down
2 changes: 1 addition & 1 deletion templates/org/team/sidebar.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@
</div>
{{end}}
</div>
<div class="ui small basic delete modal{{if not (.Team.IsMember $.SignedUser.ID)}} gt-hidden{{end}}" id="leave-team-sidebar">
<div class="ui small basic delete modal" id="leave-team-sidebar">
<div class="ui icon header">
{{svg "octicon-x" 16 "close inside"}}
{{$.locale.Tr "org.teams.leave"}}
Expand Down
8 changes: 4 additions & 4 deletions web_src/js/features/common-global.js
Original file line number Diff line number Diff line change
Expand Up @@ -194,8 +194,8 @@ export function initGlobalLinkActions() {
const $this = $(this);
const dataArray = $this.data();
let filter = '';
if ($this.data('modal-id')) {
filter += `#${$this.data('modal-id')}`;
if ($this.attr('data-modal-id')) {
filter += `#${$this.attr('data-modal-id')}`;
}

const dialog = $(`.delete.modal${filter}`);
Expand Down Expand Up @@ -237,8 +237,8 @@ export function initGlobalLinkActions() {
e.preventDefault();
const $this = $(this);
let filter = '';
if ($this.attr('id')) {
filter += `#${$this.attr('id')}`;
if ($this.attr('data-modal-id')) {
filter += `#${$this.attr('data-modal-id')}`;
}

const dialog = $(`.addall.modal${filter}`);
Expand Down

0 comments on commit c99db35

Please sign in to comment.