add migrate from issue.label_ids to issue_label

This commit is contained in:
Unknwon committed 2015-08-10 14:42:50 +08:00
1 parent 48f12d4ead
commit 17de3ab0a3
13 files changed
+286 -100

No files matched your search

+5
View File
@@ -367,6 +367,11 @@ commits.older = Older
commits.newer = Newer
issues.new = New Issue
issues.new.labels = Labels
issues.new.clear_labels = Clear labels
issues.new.milestone = Milestone
issues.new.assignee = Assignee
issues.new.no_label = No Label
issues.create = Create Issue
issues.new_label = New Label
issues.new_label_placeholder = Label name...
+1 -1
View File
@@ -17,7 +17,7 @@ import (
"github.com/gogits/gogs/modules/setting"
)
const APP_VER = "0.6.4.0809 Beta"
const APP_VER = "0.6.4.0810 Beta"
func init() {
runtime.GOMAXPROCS(runtime.NumCPU())
+20
View File
@@ -239,6 +239,26 @@ func (err ErrRepoAlreadyExist) Error() string {
return fmt.Sprintf("repository already exists [uname: %d, name: %s]", err.Uname, err.Name)
}
// .____ ___. .__
// | | _____ \_ |__ ____ | |
// | | \__ \ | __ \_/ __ \| |
// | |___ / __ \| \_\ \ ___/| |__
// |_______ (____ /___ /\___ >____/
// \/ \/ \/ \/
type ErrLabelNotExist struct {
ID int64
}
func IsErrLabelNotExist(err error) bool {
_, ok := err.(ErrLabelNotExist)
return ok
}
func (err ErrLabelNotExist) Error() string {
return fmt.Sprintf("label does not exist [id: %d]", err.ID)
}
// _____ .__.__ __
// / \ |__| | ____ _______/ |_ ____ ____ ____
// / \ / \| | | _/ __ \ / ___/\ __\/ _ \ / \_/ __ \
+138 -48
View File
@@ -7,6 +7,7 @@ package models
import (
"bytes"
"errors"
"fmt"
"html/template"
"os"
"strconv"
@@ -22,7 +23,6 @@ import (
var (
ErrIssueNotExist = errors.New("Issue does not exist")
ErrLabelNotExist = errors.New("Label does not exist")
ErrWrongIssueCounter = errors.New("Invalid number of issues for this milestone")
ErrAttachmentNotExist = errors.New("Attachment does not exist")
ErrAttachmentNotLinked = errors.New("Attachment does not belong to this issue")
@@ -38,7 +38,6 @@ type Issue struct {
Repo *Repository `xorm:"-"`
PosterID int64
Poster *User `xorm:"-"`
LabelIDs string `xorm:"label_ids TEXT"`
Labels []*Label `xorm:"-"`
MilestoneID int64
Milestone *Milestone `xorm:"-"`
@@ -76,29 +75,50 @@ func (i *Issue) GetPoster() (err error) {
return err
}
func (i *Issue) GetLabels() error {
if len(i.LabelIDs) < 3 {
func (i *Issue) hasLabel(e Engine, labelID int64) bool {
return hasIssueLabel(e, i.ID, labelID)
}
// HasLabel returns true if issue has been labeled by given ID.
func (i *Issue) HasLabel(labelID int64) bool {
return i.hasLabel(x, labelID)
}
func (i *Issue) addLabel(e Engine, labelID int64) error {
return newIssueLabel(e, i.ID, labelID)
}
// AddLabel adds new label to issue by given ID.
func (i *Issue) AddLabel(labelID int64) error {
return i.addLabel(x, labelID)
}
func (i *Issue) getLabels(e Engine) (err error) {
if len(i.Labels) > 0 {
return nil
}
strIds := strings.Split(strings.TrimSuffix(i.LabelIDs[1:], "|"), "|$")
i.Labels = make([]*Label, 0, len(strIds))
for _, strId := range strIds {
id := com.StrTo(strId).MustInt64()
if id > 0 {
l, err := GetLabelById(id)
if err != nil {
if err == ErrLabelNotExist {
continue
}
return err
}
i.Labels = append(i.Labels, l)
}
i.Labels, err = getLabelsByIssueID(e, i.ID)
if err != nil {
return fmt.Errorf("getLabelsByIssueID: %v", err)
}
return nil
}
// GetLabels retrieves all labels of issue and assign to corresponding field.
func (i *Issue) GetLabels() error {
return i.getLabels(x)
}
func (i *Issue) removeLabel(e Engine, labelID int64) error {
return deleteIssueLabel(e, i.ID, labelID)
}
// RemoveLabel removes a label from issue by given ID.
func (i *Issue) RemoveLabel(labelID int64) error {
return i.removeLabel(x, labelID)
}
func (i *Issue) GetAssignee() (err error) {
if i.AssigneeID == 0 {
return nil
@@ -261,12 +281,6 @@ const (
IS_CLOSE
)
// GetIssuesByLabel returns a list of issues by given label and repository.
func GetIssuesByLabel(repoID, labelID int64) ([]*Issue, error) {
issues := make([]*Issue, 0, 10)
return issues, x.Where("repo_id=?", repoID).And("label_ids like '%$" + com.ToStr(labelID) + "|%'").Find(&issues)
}
// GetIssueCountByPoster returns number of issues of repository by poster.
func GetIssueCountByPoster(uid, rid int64, isClosed bool) int64 {
count, _ := x.Where("repo_id=?", rid).And("poster_id=?", uid).And("is_closed=?", isClosed).Count(new(Issue))
@@ -550,7 +564,7 @@ func UpdateIssueUserPairsByMentions(uids []int64, iid int64) error {
// Label represents a label of repository for issues.
type Label struct {
ID int64 `xorm:"pk autoincr"`
RepoId int64 `xorm:"INDEX"`
RepoID int64 `xorm:"INDEX"`
Name string
Color string `xorm:"VARCHAR(7)"`
NumIssues int
@@ -570,10 +584,9 @@ func NewLabel(l *Label) error {
return err
}
// GetLabelById returns a label by given ID.
func GetLabelById(id int64) (*Label, error) {
func getLabelByID(e Engine, id int64) (*Label, error) {
if id <= 0 {
return nil, ErrLabelNotExist
return nil, ErrLabelNotExist{id}
}
l := &Label{ID: id}
@@ -581,16 +594,43 @@ func GetLabelById(id int64) (*Label, error) {
if err != nil {
return nil, err
} else if !has {
return nil, ErrLabelNotExist
return nil, ErrLabelNotExist{l.ID}
}
return l, nil
}
// GetLabels returns a list of labels of given repository ID.
func GetLabels(repoId int64) ([]*Label, error) {
// GetLabelByID returns a label by given ID.
func GetLabelByID(id int64) (*Label, error) {
return getLabelByID(x, id)
}
// GetLabelsByRepoID returns all labels that belong to given repository by ID.
func GetLabelsByRepoID(repoID int64) ([]*Label, error) {
labels := make([]*Label, 0, 10)
err := x.Where("repo_id=?", repoId).Find(&labels)
return labels, err
return labels, x.Where("repo_id=?", repoID).Find(&labels)
}
func getLabelsByIssueID(e Engine, issueID int64) ([]*Label, error) {
issueLabels, err := getIssueLabels(e, issueID)
if err != nil {
return nil, fmt.Errorf("getIssueLabels: %v", err)
}
var label *Label
labels := make([]*Label, 0, len(issueLabels))
for idx := range issueLabels {
label, err = getLabelByID(e, issueLabels[idx].LabelID)
if err != nil && !IsErrLabelNotExist(err) {
return nil, fmt.Errorf("getLabelByID: %v", err)
}
labels = append(labels, label)
}
return labels, nil
}
// GetLabelsByIssueID returns all labels that belong to given issue by ID.
func GetLabelsByIssueID(issueID int64) ([]*Label, error) {
return getLabelsByIssueID(x, issueID)
}
// UpdateLabel updates label information.
@@ -601,38 +641,88 @@ func UpdateLabel(l *Label) error {
// DeleteLabel delete a label of given repository.
func DeleteLabel(repoID, labelID int64) error {
l, err := GetLabelById(labelID)
l, err := GetLabelByID(labelID)
if err != nil {
if err == ErrLabelNotExist {
if IsErrLabelNotExist(err) {
return nil
}
return err
}
issues, err := GetIssuesByLabel(repoID, labelID)
if err != nil {
return err
}
sess := x.NewSession()
defer sessionRelease(sess)
if err = sess.Begin(); err != nil {
return err
}
for _, issue := range issues {
issue.LabelIDs = strings.Replace(issue.LabelIDs, "$"+com.ToStr(labelID)+"|", "", -1)
if _, err = sess.Id(issue.ID).AllCols().Update(issue); err != nil {
return err
}
}
if _, err = sess.Delete(l); err != nil {
if _, err = x.Where("label_id=?", labelID).Delete(new(IssueLabel)); err != nil {
return err
} else if _, err = sess.Delete(l); err != nil {
return err
}
return sess.Commit()
}
// .___ .____ ___. .__
// | | ______ ________ __ ____ | | _____ \_ |__ ____ | |
// | |/ ___// ___/ | \_/ __ \| | \__ \ | __ \_/ __ \| |
// | |\___ \ \___ \| | /\ ___/| |___ / __ \| \_\ \ ___/| |__
// |___/____ >____ >____/ \___ >_______ (____ /___ /\___ >____/
// \/ \/ \/ \/ \/ \/ \/
// IssueLabel represetns an issue-lable relation.
type IssueLabel struct {
ID int64 `xorm:"pk autoincr"`
IssueID int64 `xorm:"UNIQUE(s)"`
LabelID int64 `xorm:"UNIQUE(s)"`
}
func hasIssueLabel(e Engine, issueID, labelID int64) bool {
has, _ := e.Where("issue_id=? AND label_id=?", issueID, labelID).Get(new(IssueLabel))
return has
}
// HasIssueLabel returns true if issue has been labeled.
func HasIssueLabel(issueID, labelID int64) bool {
return hasIssueLabel(x, issueID, labelID)
}
func newIssueLabel(e Engine, issueID, labelID int64) error {
_, err := e.Insert(&IssueLabel{
IssueID: issueID,
LabelID: labelID,
})
return err
}
// NewIssueLabel creates a new issue-label relation.
func NewIssueLabel(issueID, labelID int64) error {
return newIssueLabel(x, issueID, labelID)
}
func getIssueLabels(e Engine, issueID int64) ([]*IssueLabel, error) {
issueLabels := make([]*IssueLabel, 0, 10)
return issueLabels, e.Where("issue_id=?", issueID).Find(&issueLabels)
}
// GetIssueLabels returns all issue-label relations of given issue by ID.
func GetIssueLabels(issueID int64) ([]*IssueLabel, error) {
return getIssueLabels(x, issueID)
}
func deleteIssueLabel(e Engine, issueID, labelID int64) error {
_, err := e.Delete(&IssueLabel{
IssueID: issueID,
LabelID: labelID,
})
return err
}
// DeleteIssueLabel deletes issue-label relation.
func DeleteIssueLabel(issueID, labelID int64) error {
return deleteIssueLabel(x, issueID, labelID)
}
// _____ .__.__ __
// / \ |__| | ____ _______/ |_ ____ ____ ____
// / \ / \| | | _/ __ \ / ___/\ __\/ _ \ / \_/ __ \
+60 -1
View File
@@ -58,6 +58,7 @@ var migrations = []Migration{
NewMigration("generate team-repo from team", teamToTeamRepo), // V3 -> V4:v0.5.13
NewMigration("fix locale file load panic", fixLocaleFileLoadPanic), // V4 -> V5:v0.6.0
NewMigration("trim action compare URL prefix", trimCommitActionAppUrlPrefix), // V5 -> V6:v0.6.3
NewMigration("generate issue-label from issue", issueToIssueLabel), // V6 -> V7:v0.6.4
}
// Migrate database to current version
@@ -130,6 +131,9 @@ func accessToCollaboration(x *xorm.Engine) (err error) {
results, err := x.Query("SELECT u.id AS `uid`, a.repo_name AS `repo`, a.mode AS `mode`, a.created as `created` FROM `access` a JOIN `user` u ON a.user_name=u.lower_name")
if err != nil {
if strings.Contains(err.Error(), "no such column") {
return nil
}
return err
}
@@ -278,6 +282,9 @@ func accessRefactor(x *xorm.Engine) (err error) {
results, err = x.Query("SELECT `id`,`authorize`,`repo_ids` FROM `team` WHERE org_id=? AND authorize>? ORDER BY `authorize` ASC", ownerID, int(minAccessLevel))
if err != nil {
if strings.Contains(err.Error(), "no such column") {
return nil
}
return fmt.Errorf("select teams from org: %v", err)
}
@@ -339,6 +346,9 @@ func teamToTeamRepo(x *xorm.Engine) error {
results, err := x.Query("SELECT `id`,`org_id`,`repo_ids` FROM `team`")
if err != nil {
if strings.Contains(err.Error(), "no such column") {
return nil
}
return fmt.Errorf("select teams: %v", err)
}
for _, team := range results {
@@ -369,7 +379,7 @@ func teamToTeamRepo(x *xorm.Engine) error {
}
if err = sess.Sync2(new(TeamRepo)); err != nil {
return fmt.Errorf("sync: %v", err)
return fmt.Errorf("sync2: %v", err)
} else if _, err = sess.Insert(teamRepos); err != nil {
return fmt.Errorf("insert team-repos: %v", err)
}
@@ -453,3 +463,52 @@ func trimCommitActionAppUrlPrefix(x *xorm.Engine) error {
}
return sess.Commit()
}
func issueToIssueLabel(x *xorm.Engine) error {
type IssueLabel struct {
ID int64 `xorm:"pk autoincr"`
IssueID int64 `xorm:"UNIQUE(s)"`
LabelID int64 `xorm:"UNIQUE(s)"`
}
issueLabels := make([]*IssueLabel, 0, 50)
results, err := x.Query("SELECT `id`,`label_ids` FROM `issue`")
if err != nil {
if strings.Contains(err.Error(), "no such column") {
return nil
}
return fmt.Errorf("select issues: %v", err)
}
for _, issue := range results {
issueID := com.StrTo(issue["id"]).MustInt64()
// Just in case legacy code can have duplicated IDs for same label.
mark := make(map[int64]bool)
for _, idStr := range strings.Split(string(issue["label_ids"]), "|") {
labelID := com.StrTo(strings.TrimPrefix(idStr, "$")).MustInt64()
if labelID == 0 || mark[labelID] {
continue
}
mark[labelID] = true
issueLabels = append(issueLabels, &IssueLabel{
IssueID: issueID,
LabelID: labelID,
})
}
}
sess := x.NewSession()
defer sessionRelease(sess)
if err = sess.Begin(); err != nil {
return err
}
if err = sess.Sync2(new(IssueLabel)); err != nil {
return fmt.Errorf("sync2: %v", err)
} else if _, err = sess.Insert(issueLabels); err != nil {
return fmt.Errorf("insert issue-labels: %v", err)
}
return sess.Commit()
}
+2 -1
View File
@@ -57,7 +57,8 @@ func init() {
new(User), new(PublicKey), new(Oauth2), new(AccessToken),
new(Repository), new(DeployKey), new(Collaboration), new(Access),
new(Watch), new(Star), new(Follow), new(Action),
new(Issue), new(Comment), new(Attachment), new(IssueUser), new(Label), new(Milestone),
new(Issue), new(Comment), new(Attachment), new(IssueUser),
new(Label), new(IssueLabel), new(Milestone),
new(Mirror), new(Release), new(LoginSource), new(Webhook),
new(UpdateTask), new(HookTask),
new(Team), new(OrgUser), new(TeamUser), new(TeamRepo),
+3 -3
View File
@@ -127,7 +127,7 @@ func confAppIni() (*asset, error) {
return nil, err
}
info := bindataFileInfo{name: "conf/app.ini", size: 9185, mode: os.FileMode(420), modTime: time.Unix(1438976559, 0)}
info := bindataFileInfo{name: "conf/app.ini", size: 9185, mode: os.FileMode(420), modTime: time.Unix(1439185159, 0)}
a := &asset{bytes: bytes, info: info}
return a, nil
}
@@ -772,7 +772,7 @@ func confLocaleLocale_deDeIni() (*asset, error) {
return a, nil
}
var _confLocaleLocale_enUsIni = []byte("\x1f\x8b\x08\x00\x00\x09\x6e\x88\x00\xff\xc4\x7d\xeb\x72\xdc\x46\xb2\xe6\x7f\x3c\x05\xac\x0d\xad\xec\x08\xaa\x15\xb6\x63\x2f\xe1\x90\xe4\xa5\x49\xeb\x32\x47\x14\x75\x44\x6a\x66\x67\x15\x0a\x0c\xba\x01\x76\x63\xd4\x0d\xb4\x71\x61\x9b\xf3\x6b\x5f\x63\x5f\x6f\x9f\x64\x33\xbf\xcc\xac\x0b\x80\xa6\xe4\x39\x27\xf6\xfc\x21\xab\xab\xb2\x6e\x59\x59\x59\x79\xab\x42\xbe\xdf\x67\x45\xd9\xad\xd2\x67\xe9\x69\xba\xcf\xab\x7a\x5b\x76\x5d\xda\x95\xdb\x9b\xc7\x9b\xa6\xeb\xcb\x22\x7d\x59\xf5\xf4\xbb\xbd\xad\x56\x65\x92\x6c\x9a\x5d\x49\xa0\xaf\xe8\x5f\x52\xe4\xdd\x66\xd9\xe4\x6d\x41\x19\xe7\x96\x4e\xca\xdf\xf7\xdb\xa6\x65\xa0\x5f\x25\x95\x6c\xca\xed\x9e\xeb\xd0\xbf\xa4\xab\xd6\x75\x56\xd5\xf4\xf3\x8a\x52\xe9\xeb\x3a\xe9\x9a\x55\x95\x6f\xb3\xa0\x00\x19\x56\xfe\x53\xfa\x43\x5d\xa4\x57\x7d\xb9\x4f\x9f\x76\xbb\x7c\xbb\x7d\x9e\x77\xa8\xd2\x97\x69\xbe\x5a\x35\x43\xdd\x3f\x7d\x22\x05\xd2\x78\x33\xf4\xd6\xfa\xe5\xd0\x4b\xde\xb0\xb7\xac\x0f\xfb\xa4\x2d\xd7\x15\x4d\xac\xa5\xac\xf7\x9a\x4c\x0e\xe5\xb2\xab\x7a\x1e\xf4\x5f\x24\x95\xdc\x96\x6d\x57\x35\x3c\x9e\x3f\x4b\x2a\xd9\xe7\x6b\x06\x78\x47\xff\x92\xbe\xdc\xed\xb7\x39\x2a\x5c\x6b\x32\xd9\xe6\xf5\x7a\x10\x98\x37\x9a\x4c\x92\x81\x30\x57\xe7\xc0\xd9\x07\x4d\x26\xe5\x2e\xaf\xb6\x8c\x9f\xc7\x9c\xa0\x76\xbb\xee\xd0\x00\x8b\xef\x34\x49\x63\xcc\xfa\xbb\x7d\x89\x21\x3e\xbe\xa6\x54\xb2\xca\xf7\xfd\x6a\x93\x53\xce\x99\xa4\x12\x02\xda\x37\x34\xd6\xa6\xbd\x03\x9c\xfd\x48\x9a\x76\x9d\xd7\xd5\x3f\xf2\x5e\xc6\x7f\x19\xfc\x4c\x76\x55\xdb\x36\x3c\xf5\x0b\x24\x92\xba\x3c\x64\xdc\x0e\xe5\xbc\x2d\x0f\x61\x2b\x5c\xb2\xab\xd6\xad\xcc\x92\x0b\x2f\xf0\x8b\x5b\xe1\xb2\x9b\xa6\xfd\xac\x05\x2f\x38\x39\xaa\x4a\x83\xd0\xd2\xb8\xff\xbc\x26\xbc\x68\xe9\x05\x7e\x44\x00\x5d\x92\x17\xbb\xaa\xce\xf6\x79\x5d\x32\x8e\x4e\xf9\x17\xe1\x85\x7e\x25\xba\xdc\x59\x57\xf6\x7d\x55\xaf\x3b\x2e\x96\xac\xf4\x4a\xb3\x92\xa0\xcc\xe5\xf1\x78\xba\xec\xa6\x2c\x0b\x19\x51\x97\xbe\xa0\x74\xb2\x1f\xb6\x5b\x9a\xfb\x6f\x43\xd9\xf5\x0c\xff\x8e\x7e\xd3\x2c\xe4\x77\x52\x75\x1d\x25\x28\xfb\x35\x12\x09\x2d\x40\xbd\xc2\x90\xce\x90\x48\x92\x8f\x5d\x99\xb7\xab\xcd\xa7\x44\xfe\xa3\x47\x4e\x2c\x16\x8b\xa3\x4b\xc3\xe4\xa0\xa4\x20\x3d\x58\x07\xc9\xaa\x29\xf8\xc7\x19\xfd\xa3\xa6\xab\xba\xeb\x89\xa4\x3f\x25\x9a\x60\x30\x49\x09\x1a\xfb\xaa\xdf\x96\x3e\x13\xfb\xa3\xe3\x75\x48\x5f\x54\x6d\xd7\x3f\xee\x2b\x22\xb9\xf7\x43\x9d\xf0\xfc\x88\x9c\xb3\x62\x69\xbb\xfc\x65\x43\xd8\x41\x76\x4b\xf3\xbb\xb8\xbb\xfa\xd7\x37\x27\xe9\x3b\xda\xea\xeb\xb6\xa4\x74\x4a\x6d\xd0\x3f\xaa\xf3\xe3\x22\xa1\x5a\xd6\xd3\x79\xde\xe7\xcb\xbc\x2b\x3d\x5a\xb9\x50\x68\xd4\x95\x81\x52\x99\x6d\x80\x45\x74\x7d\x34\xdf\x39\x3a\xa7\x36\x74\x77\xb8\x36\xde\xf2\x16\xa1\x7c\xe6\x1a\xa8\xfc\x6e\x5b\x72\x3e\x35\x95\xbe\x7e\xfb\xf6\xf2\xfc\x97\xb4\xac\xd7\x55\x5d\xa6\x87\xaa\xdf\xa4\x43\x7f\xf3\xdf\xb3\x75\x59\x97\x2d\x31\x91\x55\x95\xd2\xce\x68\x89\x08\x52\x22\x4f\x99\xdc\x22\xe9\xba\x6d\xb6\x13\xf4\x5e\x5d\xbd\x49\x2f\x18\xc5\xfb\xbc\xdf\x60\x20\xfd\x26\xe9\x7e\xdb\x32\x8a\x5c\x87\xd7\x9b\x32\xbd\xa9\x68\xd6\x00\x6a\x6e\x0c\x1f\x69\xa1\x63\x5c\x24\x65\xdb\x66\xb4\xef\xfb\xbb\x4c\x2b\x6b\x7b\x63\x48\x69\x82\x48\xa7\x6e\xfa\x74\x59\xa6\xa8\xb3\x48\x12\x1b\xb0\x61\xf7\x74\xbf\xdf\x56\x2b\xd9\xb1\x2f\xa5\xcc\x23\x9a\x59\xb4\x62\x29\x84\x03\xa2\xac\x2c\x40\x17\xf1\xbf\xbb\x66\x68\xd3\x88\x0d\xa0\xfe\xa6\x24\xbe\xbc\x19\x68\xcb\xe5\xc4\x53\xb7\xcd\x50\x7c\x03\x4a\xb5\xd1\x7b\x42\x4d\xdf\x37\x34\x60\x60\xc7\x01\xf8\x2e\x4e\x89\xe2\xf8\x54\x68\xcb\x5d\x43\xdc\xc1\x11\x7b\x45\x04\x75\xa8\xa8\x90\x66\xda\xe5\xb7\xb4\xdf\xfa\x26\xed\x37\x55\x97\x16\x44\x6c\x2b\x6e\x98\xb6\xc6\x40\xfc\x58\xc8\x82\x08\x54\x48\xc3\xf2\xe2\x35\x00\xd4\x6e\x20\x6a\xda\x50\x63\xcc\xed\xf9\x68\xa2\x26\xe7\xc6\x89\x29\x51\x3b\xa0\x6f\xa2\xdc\x86\x78\x2b\x73\xbf\x73\x24\xf4\x77\xd8\x3e\x8d\x2a\xbf\xb9\xa1\x51\x75\x44\x15\xaf\xd2\xd5\xb6\x21\x92\xfa\xf0\xfe\x0d\x55\xde\xf4\xfd\x3e\xdb\x37\x2d\xc8\xf8\xfa\xfa\x1d\x6d\x8f\xb6\xf7\xb9\x01\xae\x19\xa6\x1e\x76\x4b\xfa\x75\xd8\x54\xc4\x04\xf2\x60\x81\x80\x8a\x2d\x1f\x30\x75\xda\xd4\x0b\xac\xd5\xd0\x6e\x47\xcb\x48\x5d\x5a\xc9\x91\xe1\xf1\x10\x9e\xf0\x9f\x2b\x3f\x4a\x4c\xb7\xa3\x53\xf8\x80\x45\xa5\xa9\x96\x38\x4d\x88\xb6\x9a\x3d\xb7\x1b\x10\xd7\xa5\x66\x78\x8a\xc2\x09\xe4\xca\xe5\x1c\xa2\x52\x9c\xf1\x01\x2f\xdd\xd1\x84\x75\x37\x5f\x5d\x10\x1a\xb0\xa5\x91\x7b\xd3\x36\x3b\xca\x7d\x41\xff\x7c\x86\x1f\xfe\x05\xb7\x07\x98\xbc\x28\x88\xcd\x74\x27\xe9\xfb\x17\x67\xe9\x7f\xf9\xf1\x87\x1f\x16\xe9\xeb\x9e\x37\x04\xd3\xc8\xdf\x79\x6d\x29\x29\x07\xa2\x03\xa5\x9d\xdb\xd3\xf2\x3f\x60\x02\x7f\x90\x3e\x45\xe9\xff\x28\x7f\xcf\xe9\x9c\x2d\x17\xab\x66\xf7\x9c\x37\xf7\x2e\xef\x17\x09\x97\x10\xd5\x28\x39\x5d\x95\x75\x41\x09\x3d\x56\xb5\x2c\xe0\x3a\x5a\x1e\x1c\xb2\x72\xfa\x67\xab\xa6\xbe\xa9\x5a\x9e\xd0\xaf\x75\xbe\x24\x9c\x98\x5c\x40\xec\x18\x25\x76\x76\x11\xd2\x68\x23\x57\x37\x77\x1e\x14\x53\x7d\xcb\x99\xba\xa0\x09\xcb\x4a\xd4\xa8\x8a\x4c\x0e\xcb\x57\xc8\xc6\xba\x5d\xd2\xf4\x5a\xc3\x77\xe7\x11\xde\xdc\xdc\x6c\x89\xb1\x19\xb3\xd2\x1e\x2e\x25\x57\xf8\x56\x08\x42\xc4\xb8\x87\x64\x7Line truncated
var _confLocaleLocale_enUsIni = []byte("\x1f\x8b\x08\x00\x00\x09\x6e\x88\x00\xff\xc4\x7d\xeb\x72\xdc\x46\xb2\xe6\x7f\x3c\x05\xac\x0d\xad\xec\x08\xaa\x15\xb6\x63\x2f\xe1\x90\xe4\xa5\x49\xeb\x32\x47\x14\x75\x44\x6a\x66\x67\x15\x0a\x0c\xba\x01\x76\x63\xd4\x0d\xb4\x71\x61\x9b\xf3\x6b\x5f\x63\x5f\x6f\x9f\x64\x33\xbf\xcc\xac\x0b\x80\xa6\xe4\x39\x27\xf6\xfc\x21\xab\xab\xb2\x6e\x59\x59\x79\xab\xac\x42\xbe\xdf\x67\x45\xd9\xad\xd2\x67\xe9\x69\xba\xcf\xab\x7a\x5b\x76\x5d\xda\x95\xdb\x9b\xc7\x9b\xa6\xeb\xcb\x22\x7d\x59\xf5\xf4\xbb\xbd\xad\x56\x65\x92\x6c\x9a\x5d\x49\xa0\xaf\xe8\x5f\x52\xe4\xdd\x66\xd9\xe4\x6d\x41\x19\xe7\x96\x4e\xca\xdf\xf7\xdb\xa6\x65\xa0\x5f\x25\x95\x6c\xca\xed\x9e\xeb\xd0\xbf\xa4\xab\xd6\x75\x56\xd5\xf4\xf3\x8a\x52\xe9\xeb\x3a\xe9\x9a\x55\x95\x6f\xb3\xa0\x00\x19\x56\xfe\x53\xfa\x43\x5d\xa4\x57\x7d\xb9\x4f\x9f\x76\xbb\x7c\xbb\x7d\x9e\x77\xa8\xd2\x97\x69\xbe\x5a\x35\x43\xdd\x3f\x7d\x22\x05\xd2\x78\x33\xf4\xd6\xfa\xe5\xd0\x4b\xde\xb0\xb7\xac\x0f\xfb\xa4\x2d\xd7\x15\x4d\xac\xa5\xac\xf7\x9a\x4c\x0e\xe5\xb2\xab\x7a\x1e\xf4\x5f\x24\x95\xdc\x96\x6d\x57\x35\x3c\x9e\x3f\x4b\x2a\xd9\xe7\x6b\x06\x78\x47\xff\x92\xbe\xdc\xed\xb7\x39\x2a\x5c\x6b\x32\xd9\xe6\xf5\x7a\x10\x98\x37\x9a\x4c\x92\x81\x30\x57\xe7\xc0\xd9\x07\x4d\x26\xe5\x2e\xaf\xb6\x8c\x9f\xc7\x9c\xa0\x76\xbb\xee\xd0\x00\x8b\xef\x34\x49\x63\xcc\xfa\xbb\x7d\x89\x21\x3e\xbe\xa6\x54\xb2\xca\xf7\xfd\x6a\x93\x53\xce\x99\xa4\x12\x02\xda\x37\x34\xd6\xa6\xbd\x03\x9c\xfd\x48\x9a\x76\x9d\xd7\xd5\x3f\xf2\x5e\xc6\x7f\x19\xfc\x4c\x76\x55\xdb\x36\x3c\xf5\x0b\x24\x92\xba\x3c\x64\xdc\x0e\xe5\xbc\x2d\x0f\x61\x2b\x5c\xb2\xab\xd6\xad\xcc\x92\x0b\x2f\xf0\x8b\x5b\xe1\xb2\x9b\xa6\xfd\xac\x05\x2f\x38\x39\xaa\x4a\x83\xd0\xd2\xb8\xff\xbc\x26\xbc\x68\xe9\x05\x7e\x44\x00\x5d\x92\x17\xbb\xaa\xce\xf6\x79\x5d\x32\x8e\x4e\xf9\x17\xe1\x85\x7e\x25\xba\xdc\x59\x57\xf6\x7d\x55\xaf\x3b\x2e\x96\xac\xf4\x4a\xb3\x92\xa0\xcc\xe5\xf1\x78\xba\xec\xa6\x2c\x0b\x19\x51\x97\xbe\xa0\x74\xb2\x1f\xb6\x5b\x9a\xfb\x6f\x43\xd9\xf5\x0c\xff\x8e\x7e\xd3\x2c\xe4\x77\x52\x75\x1d\x25\x28\xfb\x35\x12\x09\x2d\x40\xbd\xc2\x90\xce\x90\x48\x92\x8f\x5d\x99\xb7\xab\xcd\xa7\x44\xfe\xa3\x47\x4e\x2c\x16\x8b\xa3\x4b\xc3\xe4\xa0\xa4\x20\x3d\x58\x07\xc9\xaa\x29\xf8\xc7\x19\xfd\xa3\xa6\xab\xba\xeb\x89\xa4\x3f\x25\x9a\x60\x30\x49\x09\x1a\xfb\xaa\xdf\x96\x3e\x13\xfb\xa3\xe3\x75\x48\x5f\x54\x6d\xd7\x3f\xee\x2b\x22\xb9\xf7\x43\x9d\xf0\xfc\x88\x9c\xb3\x62\x69\xbb\xfc\x65\x43\xd8\x41\x76\x4b\xf3\xbb\xb8\xbb\xfa\xd7\x37\x27\xe9\x3b\xda\xea\xeb\xb6\xa4\x74\x4a\x6d\xd0\x3f\xaa\xf3\xe3\x22\xa1\x5a\xd6\xd3\x79\xde\xe7\xcb\xbc\x2b\x3d\x5a\xb9\x50\x68\xd4\x95\x81\x52\x99\x6d\x80\x45\x74\x7d\x34\xdf\x39\x3a\xa7\x36\x74\x77\xb8\x36\xde\xf2\x16\xa1\x7c\xe6\x1a\xa8\xfc\x6e\x5b\x72\x3e\x35\x95\xbe\x7e\xfb\xf6\xf2\xfc\x97\xb4\xac\xd7\x55\x5d\xa6\x87\xaa\xdf\xa4\x43\x7f\xf3\xdf\xb3\x75\x59\x97\x2d\x31\x91\x55\x95\xd2\xce\x68\x89\x08\x52\x22\x4f\x99\xdc\x22\xe9\xba\x6d\xb6\x13\xf4\x5e\x5d\xbd\x49\x2f\x18\xc5\xfb\xbc\xdf\x60\x20\xfd\x26\xe9\x7e\xdb\x32\x8a\x5c\x87\xd7\x9b\x32\xbd\xa9\x68\xd6\x00\x6a\x6e\x0c\x1f\x69\xa1\x63\x5c\x24\x65\xdb\x66\xb4\xef\xfb\xbb\x4c\x2b\x6b\x7b\x63\x48\x69\x82\x48\xa7\x6e\xfa\x74\x59\xa6\xa8\xb3\x48\x12\x1b\xb0\x61\xf7\x74\xbf\xdf\x56\x2b\xd9\xb1\x2f\xa5\xcc\x23\x9a\x59\xb4\x62\x29\x84\x03\xa2\xac\x2c\x40\x17\xf1\xbf\xbb\x66\x68\xd3\x88\x0d\xa0\xfe\xa6\x24\xbe\xbc\x19\x68\xcb\xe5\xc4\x53\xb7\xcd\x50\x7c\x03\x4a\xb5\xd1\x7b\x42\x4d\xdf\x37\x34\x60\x60\xc7\x01\xf8\x2e\x4e\x89\xe2\x58\x2a\xb4\xe5\xae\x21\xee\xe0\x88\xbd\x22\x82\x3a\x54\x54\x48\x33\xed\xf2\x5b\xda\x6f\x7d\x93\xf6\x9b\xaa\x4b\x0b\x22\xb6\x15\x37\x4c\x5b\x63\x20\x7e\x2c\x64\x41\x04\x2a\xa4\x61\x79\xf1\x1a\x00\x6a\x37\x10\x35\x6d\xa8\x31\xe6\xf6\x2c\x9a\xa8\xc9\xb9\x71\x62\x4a\xd4\x0e\xe8\x9b\x28\xb7\x21\xde\xca\xdc\xef\x1c\x09\xfd\x1d\xb6\x4f\xa3\xca\x6f\x6e\x68\x54\x1d\x51\xc5\xab\x74\xb5\x6d\x88\xa4\x3e\xbc\x7f\x43\x95\x37\x7d\xbf\xcf\xf6\x4d\x0b\x32\xbe\xbe\x7e\x47\xdb\xa3\xed\x7d\x6e\x80\x6b\x86\xa9\x87\xdd\x92\x7e\x1d\x36\x15\x31\x81\x3c\x58\x20\xa0\x62\xcb\x02\xa6\x4e\x9b\x7a\x81\xb5\x1a\xda\xed\x68\x19\xa9\x4b\x2b\x39\x32\x3c\x1e\xc2\x13\xfe\x73\xe5\x47\x89\xe9\x76\x24\x85\x0f\x58\x54\x9a\x6a\x09\x69\x42\xb4\xd5\xec\xb9\xdd\x80\xb8\x2e\x35\xc3\x53\x14\x24\x90\x2b\x17\x39\x44\xa5\x90\xf1\x01\x2f\xdd\xd1\x84\x75\x37\x5f\x5d\x10\x1a\xb0\xa5\x91\x7b\xd3\x36\x3b\xca\x7d\x41\xff\x7c\x86\x1f\xfe\x05\xb7\x07\x98\xbc\x28\x88\xcd\x74\x27\xe9\xfb\x17\x67\xe9\x7f\xf9\xf1\x87\x1f\x16\xe9\xeb\x9e\x37\x04\xd3\xc8\xdf\x79\x6d\x29\x29\x02\xd1\x81\xd2\xce\xed\x69\xf9\x1f\x30\x81\x3f\x48\x9f\xa2\xf4\x7f\x94\xbf\xe7\x24\x67\xcb\xc5\xaa\xd9\x3d\xe7\xcd\xbd\xcb\xfb\x45\xc2\x25\x44\x35\x4a\x4e\x57\x65\x5d\x50\x42\xc5\xaa\x96\x05\x5c\x47\xcb\x03\x21\x2b\xd2\x3f\x5b\x35\xf5\x4d\xd5\xf2\x84\x7e\xad\xf3\x25\xe1\xc4\xf4\x02\x62\xc7\x28\x31\xd9\x45\x48\xa3\x8d\x5c\xdd\xdc\x79\x50\x4c\xf5\x2d\x67\xea\x82\x26\xac\x2b\x51\xa3\xaa\x32\x39\x2c\x5f\x21\x1b\xeb\x76\x49\xd3\x6b\x0d\xdf\x9d\x47\x78\x73\x73\xb3\x25\xc6\x66\xcc\x4a\x7b\xb8\x94\x5c\xe1\x5b\x21\x08\x11\xe3\x1e\x9a\xcd\x79\xdLine truncated
func confLocaleLocale_enUsIniBytes() ([]byte, error) {
return bindataRead(
@@ -787,7 +787,7 @@ func confLocaleLocale_enUsIni() (*asset, error) {
return nil, err
}
info := bindataFileInfo{name: "conf/locale/locale_en-US.ini", size: 36214, mode: os.FileMode(420), modTime: time.Unix(1439139678, 0)}
info := bindataFileInfo{name: "conf/locale/locale_en-US.ini", size: 36375, mode: os.FileMode(420), modTime: time.Unix(1439188430, 0)}
a := &asset{bytes: bytes, info: info}
return a, nil
}
+29 -18
View File
@@ -44,7 +44,7 @@ var (
)
func RetrieveLabels(ctx *middleware.Context) {
labels, err := models.GetLabels(ctx.Repo.Repository.ID)
labels, err := models.GetLabelsByRepoID(ctx.Repo.Repository.ID)
if err != nil {
ctx.Handle(500, "RetrieveLabels.GetLabels: %v", err)
return
@@ -180,10 +180,16 @@ func NewIssue(ctx *middleware.Context) {
ctx.Data["IsAttachmentEnabled"] = setting.AttachmentEnabled
ctx.Data["AttachmentAllowedTypes"] = setting.AttachmentAllowedTypes
// var (
// repo = ctx.Repo.Repository
// err error
// )
var (
repo = ctx.Repo.Repository
err error
)
ctx.Data["Labels"], err = models.GetLabelsByRepoID(repo.ID)
if err != nil {
ctx.Handle(500, "GetLabelsByRepoID: %v", err)
return
}
// // Get all milestones.
// ctx.Data["OpenMilestones"], err = models.GetMilestones(repo.ID, -1, false)
// if err != nil {
@@ -403,7 +409,7 @@ func ViewIssue(ctx *middleware.Context) {
ctx.Handle(500, "GetLabels", err)
return
}
labels, err := models.GetLabels(ctx.Repo.Repository.ID)
labels, err := models.GetLabelsByRepoID(ctx.Repo.Repository.ID)
if err != nil {
ctx.Handle(500, "GetLabels.2", err)
return
@@ -560,10 +566,10 @@ func UpdateIssueLabel(ctx *middleware.Context) {
isAttach := ctx.Query("action") == "attach"
labelStrId := ctx.Query("id")
labelId := com.StrTo(labelStrId).MustInt64()
label, err := models.GetLabelById(labelId)
labelID := com.StrTo(labelStrId).MustInt64()
label, err := models.GetLabelByID(labelID)
if err != nil {
if err == models.ErrLabelNotExist {
if models.IsErrLabelNotExist(err) {
ctx.Handle(404, "issue.UpdateIssueLabel(GetLabelById)", err)
} else {
ctx.Handle(500, "issue.UpdateIssueLabel(GetLabelById)", err)
@@ -571,16 +577,21 @@ func UpdateIssueLabel(ctx *middleware.Context) {
return
}
isHad := strings.Contains(issue.LabelIDs, "$"+labelStrId+"|")
isNeedUpdate := false
if isAttach {
if !isHad {
issue.LabelIDs += "$" + labelStrId + "|"
if !issue.HasLabel(labelID) {
if err = issue.AddLabel(labelID); err != nil {
ctx.Handle(500, "AddLabel", err)
return
}
isNeedUpdate = true
}
} else {
if isHad {
issue.LabelIDs = strings.Replace(issue.LabelIDs, "$"+labelStrId+"|", "", -1)
if issue.HasLabel(labelID) {
if err = issue.RemoveLabel(labelID); err != nil {
ctx.Handle(500, "RemoveLabel", err)
return
}
isNeedUpdate = true
}
}
@@ -958,7 +969,7 @@ func NewLabel(ctx *middleware.Context, form auth.CreateLabelForm) {
}
l := &models.Label{
RepoId: ctx.Repo.Repository.ID,
RepoID: ctx.Repo.Repository.ID,
Name: form.Title,
Color: form.Color,
}
@@ -970,10 +981,10 @@ func NewLabel(ctx *middleware.Context, form auth.CreateLabelForm) {
}
func UpdateLabel(ctx *middleware.Context, form auth.CreateLabelForm) {
l, err := models.GetLabelById(form.ID)
l, err := models.GetLabelByID(form.ID)
if err != nil {
switch err {
case models.ErrLabelNotExist:
switch {
case models.IsErrLabelNotExist(err):
ctx.Error(404)
default:
ctx.Handle(500, "UpdateLabel", err)
+1 -1
View File
@@ -1 +1 @@
0.6.4.0809 Beta
0.6.4.0810 Beta
-2
View File
@@ -28,8 +28,6 @@
{{end}}
<link href="{{AppSubUrl}}/css/todc-bootstrap.min.css" rel="stylesheet" />
<link href="{{AppSubUrl}}/css/datepicker3.css" rel="stylesheet" />
<link href="{{AppSubUrl}}/css/bootstrap-colorpicker.min.css" rel="stylesheet" />
<link href="{{AppSubUrl}}/css/markdown.css" rel="stylesheet" />
<link href="{{AppSubUrl}}/css/gogs.css" rel="stylesheet" />
+1 -1
View File
@@ -17,7 +17,7 @@
<i class="fa fa-star{{if not $.IsStaringRepo}}-o{{end}}"></i>
{{if $.IsStaringRepo}}{{$.i18n.Tr "repo.unstar"}}{{else}}{{$.i18n.Tr "repo.star"}}{{end}} <span class="num">{{.NumStars}}</span>
</a>
<a class="ui black basic button {{if $.IsRepositoryOwner}}poping up{{end}}" {{if not $.IsRepositoryOwner}}href="{{AppSubUrl}}/repo/fork/{{.Id}}"{{end}} {{if $.IsRepositoryOwner}}data-content="{{$.i18n.Tr "repo.fork_from_self"}}" data-position="top right"{{end}}>
<a class="ui black basic button {{if $.IsRepositoryOwner}}poping up{{end}}" {{if not $.IsRepositoryOwner}}href="{{AppSubUrl}}/repo/fork/{{.ID}}"{{end}} {{if $.IsRepositoryOwner}}data-content="{{$.i18n.Tr "repo.fork_from_self"}}" data-position="top right"{{end}}>
<i class="octicon octicon-repo-forked"></i>
{{$.i18n.Tr "repo.fork"}} <span class="num">{{.NumForks}}</span>
</a>
+2 -2
View File
@@ -11,11 +11,11 @@
<ul id="repo-file-nav" class="clear menu menu-line">
{{if and .IsRepositoryAdmin .Repository.BaseRepo}}
{{ $baseRepo := .Repository.BaseRepo}}
<li>
<!-- <li>
<a href="{{AppSubUrl}}/{{$baseRepo.Owner.Name}}/{{$baseRepo.Name}}/compare/{{$.BaseDefaultBranch}}...{{$.Owner.Name}}:{{$.BranchName}}">
<button class="btn btn-green btn-small btn-radius" id="repo-compare-btn"><i class="octicon octicon-git-compare"></i></button>
</a>
</li>
</li> -->
{{end}}
<li id="repo-branch-switch" class="down drop">
<a>
+24 -22
View File
@@ -8,7 +8,7 @@
<div class="twelve wide column">
<div class="ui comments">
<div class="comment">
<a class="avatar">
<a class="avatar" href="{{.SignedUser.HomeLink}}">
<img src="{{.SignedUser.AvatarLink}}">
</a>
<div class="ui segment content">
@@ -37,17 +37,34 @@
</div>
</div>
{{if .IsRepositoryAdmin}}
<div class="four wide column">
<div class="ui segment metas">
<div class="ui {{if .Labels}}disabled{{end}} dropdown jump item">
<div class="ui {{if not .Labels}}disabled{{end}} dropdown jump item">
<span class="text">
<strong>{{.i18n.Tr "repo.issues.new.labels"}}</strong>
<span class="octicon octicon-gear"></span>
</span>
<div class="filter menu">
<a class="item" href="#">{{.i18n.Tr "repo.issues.new.clear_labels"}}</a>
{{range .Labels}}
<a class="item" href="#"><span class="octicon {{if .IsChecked}}octicon-check{{end}}"></span><span class="label color" style="background-color: {{.Color}}"></span> {{.Name}}</a>
{{end}}
</div>
</div>
<div class="ui list">
<span class="item {{if .SelectedLabels}}hide{{end}}">{{.i18n.Tr "repo.issues.new.no_label"}}</span>
</div>
<!-- <div class="ui divider"></div>
<div class="ui {{if .Labels}}disabled{{end}} dropdown jump item">
<span class="text">
<strong>{{.i18n.Tr "repo.issues.new.milestone"}}</strong>
<span class="octicon octicon-gear"></span>
</span>
<div class="menu">
<a class="item" href="{{$.RepoLink}}/issues?type={{$.ViewType}}&state={{$.State}}&milestone={{$.MilestoneID}}">{{.i18n.Tr "repo.issues.filter_label_no_select"}}</a>
{{range .Labels}}
<a class="item" href="{{$.RepoLink}}/issues?type={{$.ViewType}}&state={{$.State}}&labels={{.ID}}&milestone={{$.MilestoneID}}"><span class="octicon {{if eq $.SelectLabels .ID}}octicon-check{{end}}"></span><span class="label color" style="background-color: {{.Color}}"></span> {{.Name}}</a>
<a class="item" href="{{$.RepoLink}}/issues?type={{$.ViewType}}&state={{$.State}}&labels={{.ID}}&milestone={{$.MilestoneID}}"><span class="octicon {{if .IsChecked}}octicon-check{{end}}"></span><span class="label color" style="background-color: {{.Color}}"></span> {{.Name}}</a>
{{end}}
</div>
</div>
@@ -57,35 +74,20 @@
<div class="ui divider"></div>
<div class="ui {{if .Labels}}disabled{{end}} dropdown jump item">
<span class="text">
<strong>{{.i18n.Tr "repo.issues.new.labels"}}</strong>
<strong>{{.i18n.Tr "repo.issues.new.assignee"}}</strong>
<span class="octicon octicon-gear"></span>
</span>
<div class="menu">
<a class="item" href="{{$.RepoLink}}/issues?type={{$.ViewType}}&state={{$.State}}&milestone={{$.MilestoneID}}">{{.i18n.Tr "repo.issues.filter_label_no_select"}}</a>
{{range .Labels}}
<a class="item" href="{{$.RepoLink}}/issues?type={{$.ViewType}}&state={{$.State}}&labels={{.ID}}&milestone={{$.MilestoneID}}"><span class="octicon {{if eq $.SelectLabels .ID}}octicon-check{{end}}"></span><span class="label color" style="background-color: {{.Color}}"></span> {{.Name}}</a>
<a class="item" href="{{$.RepoLink}}/issues?type={{$.ViewType}}&state={{$.State}}&labels={{.ID}}&milestone={{$.MilestoneID}}"><span class="octicon {{if .IsChecked}}octicon-check{{end}}"></span><span class="label color" style="background-color: {{.Color}}"></span> {{.Name}}</a>
{{end}}
</div>
</div>
<div class="ui list">
<span class="item">filter_label_no_select</span>
</div>
<div class="ui divider"></div>
<div class="ui {{if .Labels}}disabled{{end}} dropdown jump item">
<span class="text">
<strong>{{.i18n.Tr "repo.issues.new.labels"}}</strong>
<span class="octicon octicon-gear"></span>
</span>
<div class="menu">
<a class="item" href="{{$.RepoLink}}/issues?type={{$.ViewType}}&state={{$.State}}&milestone={{$.MilestoneID}}">{{.i18n.Tr "repo.issues.filter_label_no_select"}}</a>
{{range .Labels}}
<a class="item" href="{{$.RepoLink}}/issues?type={{$.ViewType}}&state={{$.State}}&labels={{.ID}}&milestone={{$.MilestoneID}}"><span class="octicon {{if eq $.SelectLabels .ID}}octicon-check{{end}}"></span><span class="label color" style="background-color: {{.Color}}"></span> {{.Name}}</a>
{{end}}
</div>
</div>
<div class="ui list">
<span class="item">filter_label_no_select</span>
</div>
</div> -->
</div>
</div>
{{end}}
</form>