From 5666d41460c1784d210d32cd9ec8de7b7c039035 Mon Sep 17 00:00:00 2001 From: Stas Vilchik Date: Thu, 20 Mar 2014 16:21:58 +0600 Subject: SONAR-4366 Transform WORK_DUR in read-only mode --- .../quality-gate/views/quality-gate-detail-condition-view.coffee | 2 +- .../quality-gate/views/quality-gate-detail-condition-view.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sonar-server/src/main/webapp/javascripts/quality-gate/views/quality-gate-detail-condition-view.coffee b/sonar-server/src/main/webapp/javascripts/quality-gate/views/quality-gate-detail-condition-view.coffee index 50992789af0..75aaa8084d8 100644 --- a/sonar-server/src/main/webapp/javascripts/quality-gate/views/quality-gate-detail-condition-view.coffee +++ b/sonar-server/src/main/webapp/javascripts/quality-gate/views/quality-gate-detail-condition-view.coffee @@ -118,6 +118,6 @@ define [ periodText: period?.text unless @options.app.canEdit _.extend data, - warning: jQuery('').data('type', @model.get('metric').type).val(@model.get('warning')).val() + warning: jQuery('').data('type', @model.get('metric').type).val(@model.get('warning')).originalVal() error: jQuery('').data('type', @model.get('metric').type).val(@model.get('error')).originalVal() data diff --git a/sonar-server/src/main/webapp/javascripts/quality-gate/views/quality-gate-detail-condition-view.js b/sonar-server/src/main/webapp/javascripts/quality-gate/views/quality-gate-detail-condition-view.js index fba38b1ca8f..81d4cec0d49 100644 --- a/sonar-server/src/main/webapp/javascripts/quality-gate/views/quality-gate-detail-condition-view.js +++ b/sonar-server/src/main/webapp/javascripts/quality-gate/views/quality-gate-detail-condition-view.js @@ -151,7 +151,7 @@ }); if (!this.options.app.canEdit) { _.extend(data, { - warning: jQuery('').data('type', this.model.get('metric').type).val(this.model.get('warning')).val(), + warning: jQuery('').data('type', this.model.get('metric').type).val(this.model.get('warning')).originalVal(), error: jQuery('').data('type', this.model.get('metric').type).val(this.model.get('error')).originalVal() }); } -- cgit v1.2.3