aboutsummaryrefslogtreecommitdiffstats
path: root/server/sonar-web/src/main/js/apps/issues/sidebar
diff options
context:
space:
mode:
authorStas Vilchik <stas.vilchik@sonarsource.com>2017-10-10 16:56:47 +0200
committerStas Vilchik <stas.vilchik@sonarsource.com>2017-10-11 12:02:21 +0200
commit2076e3bd0143ffc4f88c180ce3fa3b9ac41b3f85 (patch)
treeb279ea209e0b6379017c1be3a064b9217eb54188 /server/sonar-web/src/main/js/apps/issues/sidebar
parent20ed9553b9a1012f341c1f5d4a594221ae437600 (diff)
downloadsonarqube-2076e3bd0143ffc4f88c180ce3fa3b9ac41b3f85.tar.gz
sonarqube-2076e3bd0143ffc4f88c180ce3fa3b9ac41b3f85.zip
SONAR-7709 Help users to not enter wrong date periods
Diffstat (limited to 'server/sonar-web/src/main/js/apps/issues/sidebar')
-rw-r--r--server/sonar-web/src/main/js/apps/issues/sidebar/CreationDateFacet.js2
1 files changed, 2 insertions, 0 deletions
diff --git a/server/sonar-web/src/main/js/apps/issues/sidebar/CreationDateFacet.js b/server/sonar-web/src/main/js/apps/issues/sidebar/CreationDateFacet.js
index 461d3405d14..edc61cf799d 100644
--- a/server/sonar-web/src/main/js/apps/issues/sidebar/CreationDateFacet.js
+++ b/server/sonar-web/src/main/js/apps/issues/sidebar/CreationDateFacet.js
@@ -228,6 +228,7 @@ export default class CreationDateFacet extends React.PureComponent {
<DateInput
className="search-navigator-date-facet-selection-dropdown-left"
inputClassName="search-navigator-date-facet-selection-input"
+ maxDate={createdBefore ? toShortNotSoISOString(createdBefore) : '+0'}
onChange={this.handlePeriodChangeAfter}
placeholder={translate('from')}
value={createdAfter ? toShortNotSoISOString(createdAfter) : undefined}
@@ -235,6 +236,7 @@ export default class CreationDateFacet extends React.PureComponent {
<DateInput
className="search-navigator-date-facet-selection-dropdown-right"
inputClassName="search-navigator-date-facet-selection-input"
+ minDate={createdAfter ? toShortNotSoISOString(createdAfter) : undefined}
onChange={this.handlePeriodChangeBefore}
placeholder={translate('to')}
value={createdBefore ? toShortNotSoISOString(createdBefore) : undefined}