From e318fad8492e8eb11594527cd85eb5e70c9b4eee Mon Sep 17 00:00:00 2001 From: Stas Vilchik Date: Tue, 23 Dec 2014 09:26:35 +0100 Subject: [PATCH] SONAR-5971 The component viewer, in differential mode, might display some unexpected issues --- server/sonar-web/src/main/coffee/component-viewer/main.coffee | 3 +-- .../src/main/coffee/component-viewer/mixins/main-issues.coffee | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/server/sonar-web/src/main/coffee/component-viewer/main.coffee b/server/sonar-web/src/main/coffee/component-viewer/main.coffee index ab9241fcbed..f19d698d48d 100644 --- a/server/sonar-web/src/main/coffee/component-viewer/main.coffee +++ b/server/sonar-web/src/main/coffee/component-viewer/main.coffee @@ -190,8 +190,7 @@ define [ @periods.reset [{label: t('none')}] data.periods.forEach (p) => d = moment p[2] - date = new Date d.get('year'), d.get('month'), d.get('date') - p = @periods.add key: p[0], label: p[1], sinceDate: date + p = @periods.add key: p[0], label: p[1], sinceDate: d.toDate() requestMeasures: (key, period = null) -> diff --git a/server/sonar-web/src/main/coffee/component-viewer/mixins/main-issues.coffee b/server/sonar-web/src/main/coffee/component-viewer/mixins/main-issues.coffee index a0bf0148157..d4976ffd101 100644 --- a/server/sonar-web/src/main/coffee/component-viewer/mixins/main-issues.coffee +++ b/server/sonar-web/src/main/coffee/component-viewer/mixins/main-issues.coffee @@ -85,7 +85,7 @@ define [ p = predicate predicate = (issue) => creationDate = new Date moment(issue.creationDate).format() - (creationDate >= period.get('sinceDate')) && p issue + (creationDate > period.get('sinceDate')) && p issue if requestIssues && !@state.get 'hasIssues' @requestIssues(@key).done => @_filterByIssues(predicate) -- 2.39.5