aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStas Vilchik <vilchiks@gmail.com>2015-02-02 13:33:01 +0100
committerStas Vilchik <vilchiks@gmail.com>2015-02-02 13:33:01 +0100
commit93b4b26c84224a8b37e4467d3c3d3c268ec113ab (patch)
treea1237200e14fd9df69d02f9b561bb7a0f8d6fc7e
parent495b68300ce6a550ad501831a42c28ffc69fd516 (diff)
downloadsonarqube-93b4b26c84224a8b37e4467d3c3d3c268ec113ab.tar.gz
sonarqube-93b4b26c84224a8b37e4467d3c3d3c268ec113ab.zip
SONAR-6042 Add tooltips to issue transitions
-rw-r--r--server/sonar-web/src/main/coffee/issue/views/action-options-view.coffee4
-rw-r--r--server/sonar-web/src/main/hbs/issue/issue-transitions-form.hbs3
-rw-r--r--server/sonar-web/src/main/js/translate.js2
-rw-r--r--sonar-core/src/main/resources/org/sonar/l10n/core.properties7
4 files changed, 14 insertions, 2 deletions
diff --git a/server/sonar-web/src/main/coffee/issue/views/action-options-view.coffee b/server/sonar-web/src/main/coffee/issue/views/action-options-view.coffee
index a02e78a0961..8486c4ad7e4 100644
--- a/server/sonar-web/src/main/coffee/issue/views/action-options-view.coffee
+++ b/server/sonar-web/src/main/coffee/issue/views/action-options-view.coffee
@@ -27,6 +27,7 @@ define [
onRender: ->
super
@selectInitialOption()
+ @$('[data-toggle="tooltip"]').tooltip container: 'body'
getOptions: ->
@@ -84,7 +85,10 @@ define [
onClose: ->
+ super
@unbindShortcuts()
+ @$('[data-toggle="tooltip"]').tooltip 'destroy'
+ $('.tooltip').remove()
selectOption: (e) ->
diff --git a/server/sonar-web/src/main/hbs/issue/issue-transitions-form.hbs b/server/sonar-web/src/main/hbs/issue/issue-transitions-form.hbs
index ab64424207e..2fa1f4cb7dd 100644
--- a/server/sonar-web/src/main/hbs/issue/issue-transitions-form.hbs
+++ b/server/sonar-web/src/main/hbs/issue/issue-transitions-form.hbs
@@ -1,6 +1,7 @@
<div class="issue-action-options">
{{#each transitions}}
- <a href="#" class="issue-action-option js-issue-transition" data-value="{{this}}">
+ <a href="#" class="issue-action-option js-issue-transition" data-value="{{this}}"
+ title="{{t 'issue.transition' this 'description'}}" data-placement="right" data-toggle="tooltip">
{{t 'issue.transition' this}}
</a>
{{/each}}
diff --git a/server/sonar-web/src/main/js/translate.js b/server/sonar-web/src/main/js/translate.js
index 4bc86736641..14444700c15 100644
--- a/server/sonar-web/src/main/js/translate.js
+++ b/server/sonar-web/src/main/js/translate.js
@@ -8,7 +8,7 @@
var args = Array.prototype.slice.call(arguments, 0),
key = args.join('.');
- return (window.messages && window.messages[key]) || key;
+ return window.messages[key] != null ? window.messages[key] : key;
};
window.tp = function() {
diff --git a/sonar-core/src/main/resources/org/sonar/l10n/core.properties b/sonar-core/src/main/resources/org/sonar/l10n/core.properties
index fb4abbbb25d..e69d965ab71 100644
--- a/sonar-core/src/main/resources/org/sonar/l10n/core.properties
+++ b/sonar-core/src/main/resources/org/sonar/l10n/core.properties
@@ -657,12 +657,19 @@ issue.details=Details
issue.send_notifications=Send Notifications
issue.transition=Transition
issue.transition.confirm=Confirm
+issue.transition.confirm.description=This issue has been reviewed and something should be done eventually to handle it.
issue.transition.unconfirm=Unconfirm
+issue.transition.unconfirm.description=
issue.transition.resolve=Resolve as fixed
+issue.transition.resolve.description=This issue has been fixed in the code and is waiting for the next analysis to close it - or reopen it if it was not actually fixed.
issue.transition.falsepositive=Resolve as false positive
+issue.transition.falsepositive.description=This issue can be ignored because it is due to a limitation of the analysis engine. Its technical debt won't be counted.
issue.transition.reopen=Reopen
+issue.transition.reopen.description=
issue.transition.close=Close
+issue.transition.close.description=
issue.transition.wontfix=Resolve as won't fix
+issue.transition.wontfix.description=This issue can be ignored because the rule is irrelevant in this context. Its technical debt won't be counted.
issue.set_severity=Change Severity
issue.set_severity.submit=Change Severity
issue.do_plan=Plan