Skip to content

Commit

Permalink
[webui] fix repository state description
Browse files Browse the repository at this point in the history
prepare for adding details, not used yet

obs#1274
  • Loading branch information
adrianschroeter committed Oct 21, 2015
1 parent 3c43d8c commit 2b96dc3
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/api/app/helpers/webui/webui_helper.rb
Expand Up @@ -144,11 +144,11 @@ def arch_repo_table_cell(repo, arch, packname)
'building' => 'Build jobs exists',
'finished' => 'Build jobs have been processed, new repository is not yet created',
'blocked' => 'No build possible atm, waiting for jobs in other repositories',
'broken' => 'The repository setup is broken, build not possible',
'broken' => 'The repository setup is broken, build or publish not possible',
'scheduling' => 'The repository state is being calculated right now'
}

def repo_status_icon(status)
def repo_status_icon(status, details = nil)
icon = REPO_STATUS_ICONS[status] || 'eye'

outdated = nil
Expand All @@ -159,6 +159,7 @@ def repo_status_icon(status)

description = REPO_STATUS_DESCRIPTIONS[status] || 'Unknown state of repository'
description = 'State needs recalculations, former state was: ' + description if outdated
description += " (" + details + ")" if details

sprite_tag icon, title: description
end
Expand Down

0 comments on commit 2b96dc3

Please sign in to comment.