aboutsummaryrefslogtreecommitdiffstats
path: root/server
diff options
context:
space:
mode:
authorStas Vilchik <vilchiks@gmail.com>2014-10-30 10:03:31 +0100
committerStas Vilchik <vilchiks@gmail.com>2014-10-30 10:36:30 +0100
commitec43e0e73e765caf522323c4b656f42f704abefd (patch)
tree8d1935202f3982af2c337525e5a47ffa3d2f63dd /server
parent7c6bdb3fae33e96d69fa91da05bdbba7e6a7c840 (diff)
downloadsonarqube-ec43e0e73e765caf522323c4b656f42f704abefd.tar.gz
sonarqube-ec43e0e73e765caf522323c4b656f42f704abefd.zip
SONAR-5718 Don't allow to choose 'unassigned' and assignee at the same time
Diffstat (limited to 'server')
-rw-r--r--server/sonar-web/src/main/coffee/issues/facets-view.coffee1
-rw-r--r--server/sonar-web/src/main/coffee/issues/facets/assignee-facet.coffee10
2 files changed, 4 insertions, 7 deletions
diff --git a/server/sonar-web/src/main/coffee/issues/facets-view.coffee b/server/sonar-web/src/main/coffee/issues/facets-view.coffee
index 30811e790d7..d0f91d9a8cc 100644
--- a/server/sonar-web/src/main/coffee/issues/facets-view.coffee
+++ b/server/sonar-web/src/main/coffee/issues/facets-view.coffee
@@ -49,6 +49,5 @@ define [
updateState: ->
enabledFacets = @collection.filter (model) -> model.get('enabled')
enabledFacetIds = enabledFacets.map (model) -> model.id
- console.log enabledFacetIds
@options.app.state.set facets: enabledFacetIds
diff --git a/server/sonar-web/src/main/coffee/issues/facets/assignee-facet.coffee b/server/sonar-web/src/main/coffee/issues/facets/assignee-facet.coffee
index 0c922e9ba5e..b9bbcdfb4fe 100644
--- a/server/sonar-web/src/main/coffee/issues/facets/assignee-facet.coffee
+++ b/server/sonar-web/src/main/coffee/issues/facets/assignee-facet.coffee
@@ -23,15 +23,13 @@ define [
toggleFacet: (e) ->
unassigned = $(e.currentTarget).is "[data-unassigned]"
+ $(e.currentTarget).toggleClass 'active'
if unassigned
- $(e.currentTarget).toggleClass 'active'
checked = $(e.currentTarget).is '.active'
- if checked
- @options.app.state.updateFilter assigned: 'false', assignees: null
- else
- @options.app.state.updateFilter assigned: null, assignees: null
+ value = if checked then 'false' else null
+ @options.app.state.updateFilter assigned: value, assignees: null
else
- super
+ @options.app.state.updateFilter assigned: null, assignees: @getValue()
getValuesWithLabels: ->