Платформа ЦРНП "Мирокод" для разработки проектов
https://git.mirocod.ru
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
90 lines
3.6 KiB
90 lines
3.6 KiB
3 years ago
|
<div id="issue-actions" class="ui stackable grid hide">
|
||
|
<div class="six wide column">
|
||
|
{{template "repo/issue/openclose" .}}
|
||
|
</div>
|
||
|
{{/* Ten wide does not cope well and makes the columns stack.
|
||
|
This seems to be related to jQuery's hide/show: in fact, switching
|
||
|
issue-actions and issue-filters and having this ten wide will show
|
||
|
this one correctly, but not the other one. */}}
|
||
|
<div class="nine wide right aligned right floated column">
|
||
|
<div class="ui secondary filter stackable menu">
|
||
|
{{if not .Repository.IsArchived}}
|
||
|
<!-- Action Button -->
|
||
|
{{if .IsShowClosed}}
|
||
|
<div class="ui green active basic button issue-action" data-action="open" data-url="{{$.RepoLink}}/issues/status" style="margin-left: auto">{{.i18n.Tr "repo.issues.action_open"}}</div>
|
||
|
{{else}}
|
||
|
<div class="ui red active basic button issue-action" data-action="close" data-url="{{$.RepoLink}}/issues/status" style="margin-left: auto">{{.i18n.Tr "repo.issues.action_close"}}</div>
|
||
|
{{end}}
|
||
|
<!-- Labels -->
|
||
|
<div class="ui {{if not .Labels}}disabled{{end}} dropdown jump item">
|
||
|
<span class="text">
|
||
|
{{.i18n.Tr "repo.issues.action_label"}}
|
||
|
{{svg "octicon-triangle-down" 14 "dropdown icon"}}
|
||
|
</span>
|
||
|
<div class="menu">
|
||
|
{{range .Labels}}
|
||
|
<div class="item issue-action" data-action="toggle" data-element-id="{{.ID}}" data-url="{{$.RepoLink}}/issues/labels">
|
||
|
{{if contain $.SelLabelIDs .ID}}{{svg "octicon-check"}}{{end}}<span class="label color" style="background-color: {{.Color}}"></span> {{.Name | RenderEmoji}}
|
||
|
</div>
|
||
|
{{end}}
|
||
|
</div>
|
||
|
</div>
|
||
|
|
||
|
<!-- Milestone -->
|
||
|
<div class="ui {{if not .Milestones}}disabled{{end}} dropdown jump item">
|
||
|
<span class="text">
|
||
|
{{.i18n.Tr "repo.issues.action_milestone"}}
|
||
|
{{svg "octicon-triangle-down" 14 "dropdown icon"}}
|
||
|
</span>
|
||
|
<div class="menu">
|
||
|
<div class="item issue-action" data-element-id="0" data-url="{{$.Link}}/milestone">
|
||
|
{{.i18n.Tr "repo.issues.action_milestone_no_select"}}
|
||
|
</div>
|
||
|
{{range .Milestones}}
|
||
|
<div class="item issue-action" data-element-id="{{.ID}}" data-url="{{$.RepoLink}}/issues/milestone">
|
||
|
{{.Name}}
|
||
|
</div>
|
||
|
{{end}}
|
||
|
</div>
|
||
|
</div>
|
||
|
|
||
|
<!-- Projects -->
|
||
|
<div class="ui {{if not .Projects}}disabled{{end}} dropdown jump item">
|
||
|
<span class="text">
|
||
|
{{.i18n.Tr "repo.project_board"}}
|
||
|
{{svg "octicon-triangle-down" 14 "dropdown icon"}}
|
||
|
</span>
|
||
|
<div class="menu">
|
||
|
<div class="item issue-action" data-element-id="0" data-url="{{$.Link}}/projects">
|
||
|
{{.i18n.Tr "repo.issues.new.no_projects"}}
|
||
|
</div>
|
||
|
{{range .Projects}}
|
||
|
<div class="item issue-action" data-element-id="{{.ID}}" data-url="{{$.RepoLink}}/issues/projects">
|
||
|
{{.Title}}
|
||
|
</div>
|
||
|
{{end}}
|
||
|
</div>
|
||
|
</div>
|
||
|
|
||
|
<!-- Assignees -->
|
||
|
<div class="ui {{if not .Assignees}}disabled{{end}} dropdown jump item">
|
||
|
<span class="text">
|
||
|
{{.i18n.Tr "repo.issues.action_assignee"}}
|
||
|
{{svg "octicon-triangle-down" 14 "dropdown icon"}}
|
||
|
</span>
|
||
|
<div class="menu">
|
||
|
<div class="item issue-action" data-element-id="0" data-url="{{$.Link}}/assignee">
|
||
|
{{.i18n.Tr "repo.issues.action_assignee_no_select"}}
|
||
|
</div>
|
||
|
{{range .Assignees}}
|
||
|
<div class="item issue-action" data-element-id="{{.ID}}" data-url="{{$.RepoLink}}/issues/assignee">
|
||
|
{{avatar .}} {{.GetDisplayName}}
|
||
|
</div>
|
||
|
{{end}}
|
||
|
</div>
|
||
|
</div>
|
||
|
{{end}}
|
||
|
</div>
|
||
|
</div>
|
||
|
</div>
|