← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 14872: DV, new options: range axis maxvalue/steps/decimals.

 

Merge authors:
  Jan Henrik Øverland (janhenrik-overland)
------------------------------------------------------------
revno: 14872 [merge]
committer: Jan Henrik Overland <janhenrik.overland@xxxxxxxxx>
branch nick: dhis2
timestamp: Tue 2014-04-15 14:45:31 +0200
message:
  DV, new options: range axis maxvalue/steps/decimals.
modified:
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/chart/Chart.java
  dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/chart/hibernate/Chart.hbm.xml
  dhis-2/dhis-web/dhis-web-visualizer/src/main/resources/org/hisp/dhis/visualizer/i18n_module.properties
  dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/i18n.json
  dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/scripts/app.js
  dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/scripts/core.js


--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk

Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/chart/Chart.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/chart/Chart.java	2014-03-25 14:01:51 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/chart/Chart.java	2014-04-15 12:43:39 +0000
@@ -107,6 +107,12 @@
     private boolean showData;
     
     private boolean hideEmptyRows;
+    
+    private Double rangeAxisMaxValue;
+    
+    private Integer rangeAxisSteps; //min 1
+    
+    private Integer rangeAxisDecimals;
 
     // -------------------------------------------------------------------------
     // Transient properties
@@ -517,11 +523,44 @@
         this.rewindRelativePeriods = rewindRelativePeriods;
     }
 
+    @JsonProperty
+    @JsonView({ DetailedView.class, ExportView.class, DimensionalView.class })
+    @JacksonXmlProperty(namespace = DxfNamespaces.DXF_2_0)
+    public Double getRangeAxisMaxValue() {
+		return rangeAxisMaxValue;
+	}
+
+	public void setRangeAxisMaxValue(Double rangeAxisMaxValue) {
+		this.rangeAxisMaxValue = rangeAxisMaxValue;
+	}
+
+	@JsonProperty
+    @JsonView({ DetailedView.class, ExportView.class, DimensionalView.class })
+    @JacksonXmlProperty(namespace = DxfNamespaces.DXF_2_0)
+	public Integer getRangeAxisSteps() {
+		return rangeAxisSteps;
+	}
+
+	public void setRangeAxisSteps(Integer rangeAxisSteps) {
+		this.rangeAxisSteps = rangeAxisSteps;
+	}
+
+	@JsonProperty
+    @JsonView({ DetailedView.class, ExportView.class, DimensionalView.class })
+    @JacksonXmlProperty(namespace = DxfNamespaces.DXF_2_0)
+	public Integer getRangeAxisDecimals() {
+		return rangeAxisDecimals;
+	}
+
+	public void setRangeAxisDecimals(Integer rangeAxisDecimals) {
+		this.rangeAxisDecimals = rangeAxisDecimals;
+	}
+
     // -------------------------------------------------------------------------
     // Getters and setters for transient properties
     // -------------------------------------------------------------------------
 
-    @JsonIgnore
+	@JsonIgnore
     public I18nFormat getFormat()
     {
         return format;
@@ -575,6 +614,9 @@
             showData = chart.isShowData();
             hideEmptyRows = chart.isHideEmptyRows();
             rewindRelativePeriods = chart.isRewindRelativePeriods();
+            rangeAxisMaxValue = chart.getRangeAxisMaxValue() == null ? rangeAxisMaxValue : chart.getRangeAxisMaxValue();
+            rangeAxisSteps = chart.getRangeAxisSteps() == null ? rangeAxisSteps : chart.getRangeAxisSteps();
+            rangeAxisDecimals = chart.getRangeAxisDecimals() == null ? rangeAxisDecimals : chart.getRangeAxisDecimals();
 
             filterDimensions.clear();
             filterDimensions.addAll( chart.getFilterDimensions() );

=== modified file 'dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/chart/hibernate/Chart.hbm.xml'
--- dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/chart/hibernate/Chart.hbm.xml	2014-03-25 14:01:51 +0000
+++ dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/chart/hibernate/Chart.hbm.xml	2014-04-15 12:43:39 +0000
@@ -162,6 +162,12 @@
 
     <property name="rewindRelativePeriods" />
 
+    <property name="rangeAxisMaxValue" />
+
+    <property name="rangeAxisSteps" />
+
+    <property name="rangeAxisDecimals" />
+
     <!-- Access properties -->
     <property name="externalAccess" />
 

=== modified file 'dhis-2/dhis-web/dhis-web-visualizer/src/main/resources/org/hisp/dhis/visualizer/i18n_module.properties'
--- dhis-2/dhis-web/dhis-web-visualizer/src/main/resources/org/hisp/dhis/visualizer/i18n_module.properties	2014-03-25 14:13:37 +0000
+++ dhis-2/dhis-web/dhis-web-visualizer/src/main/resources/org/hisp/dhis/visualizer/i18n_module.properties	2014-04-15 12:43:39 +0000
@@ -215,4 +215,6 @@
 financial_april=Financial April
 all_indicators=All indicators
 all_data_elements=All data elements
-hide_empty_category_items=Hide empty category items
\ No newline at end of file
+hide_empty_category_items=Hide empty category items
+axes=Axes
+general=General
\ No newline at end of file

=== modified file 'dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/i18n.json'
--- dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/i18n.json	2014-03-25 14:13:37 +0000
+++ dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/i18n.json	2014-04-15 12:43:39 +0000
@@ -215,5 +215,7 @@
 "financial_april",
 "all_indicators",
 "all_data_elements",
-"hide_empty_category_items"
+"hide_empty_category_items",
+"axes",
+"general"
 ]

=== modified file 'dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/scripts/app.js'
--- dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/scripts/app.js	2014-04-14 21:38:11 +0000
+++ dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/scripts/app.js	2014-04-15 12:43:39 +0000
@@ -50,9 +50,13 @@
 			rangeAxisTitle,
 
 			data,
-			style,
+			axes,
+			general,
+			window,
 
-			window;
+			cmpWidth = 310,
+			labelWidth = 125,
+			numberWidth = 60;
 
 		showTrendLine = Ext.create('Ext.form.field.Checkbox', {
 			boxLabel: NS.i18n.trend_line,
@@ -60,8 +64,7 @@
 		});
 
 		targetLineValue = Ext.create('Ext.form.field.Number', {
-			//cls: 'gis-numberfield',
-			width: 60,
+			width: numberWidth,
 			height: 18,
 			listeners: {
 				change: function(nf) {
@@ -71,11 +74,10 @@
 		});
 
 		targetLineTitle = Ext.create('Ext.form.field.Text', {
-			//cls: 'ns-textfield-alt1',
-			style: 'margin-left:2px; margin-bottom:2px',
+			style: 'margin-left:1px; margin-bottom:1px',
 			fieldStyle: 'padding-left:3px',
 			emptyText: NS.i18n.target,
-			width: 120,
+			width: cmpWidth - labelWidth - 5 - numberWidth - 1,
 			maxLength: 100,
 			enforceMaxLength: true,
 			disabled: true,
@@ -86,7 +88,7 @@
 
 		baseLineValue = Ext.create('Ext.form.field.Number', {
 			//cls: 'gis-numberfield',
-			width: 60,
+			width: numberWidth,
 			height: 18,
 			listeners: {
 				change: function(nf) {
@@ -97,10 +99,10 @@
 
 		baseLineTitle = Ext.create('Ext.form.field.Text', {
 			//cls: 'ns-textfield-alt1',
-			style: 'margin-left:2px',
+			style: 'margin-left:1px; margin-bottom:1px',
 			fieldStyle: 'padding-left:3px',
 			emptyText: NS.i18n.base,
-			width: 120,
+			width: cmpWidth - labelWidth - 5 - numberWidth - 1,
 			maxLength: 100,
 			enforceMaxLength: true,
 			disabled: true,
@@ -109,17 +111,40 @@
 			}
 		});
 
+		hideEmptyRows = Ext.create('Ext.form.field.Checkbox', {
+			boxLabel: NS.i18n.hide_empty_category_items,
+			style: 'margin-bottom:4px'
+		});
+
+		rangeAxisMaxValue = Ext.create('Ext.form.field.Number', {
+			width: 190,
+			height: 18,
+			fieldLabel: 'Range axis max value',
+			labelWidth: 125
+		});
+
+		rangeAxisSteps = Ext.create('Ext.form.field.Number', {
+			width: 190,
+			height: 18,
+			fieldLabel: 'Range axis tick steps',
+			labelWidth: 125,
+			minValue: 1
+		});
+
+		rangeAxisDecimals = Ext.create('Ext.form.field.Number', {
+			width: 190,
+			height: 18,
+			fieldLabel: 'Range axis decimals',
+			labelWidth: 125,
+			minValue: 0
+		});
+
 		showValues = Ext.create('Ext.form.field.Checkbox', {
 			boxLabel: NS.i18n.show_values,
 			style: 'margin-bottom:4px',
 			checked: true
 		});
 
-		hideEmptyRows = Ext.create('Ext.form.field.Checkbox', {
-			boxLabel: NS.i18n.hide_empty_category_items,
-			style: 'margin-bottom:4px'
-		});
-
 		hideLegend = Ext.create('Ext.form.field.Checkbox', {
 			boxLabel: NS.i18n.hide_legend,
 			style: 'margin-bottom:4px'
@@ -136,11 +161,11 @@
 		});
 
 		title = Ext.create('Ext.form.field.Text', {
-			style: 'margin-bottom:2px; margin-left:2px',
-			width: 310,
+			style: 'margin-bottom:2px',
+			width: cmpWidth,
 			fieldLabel: NS.i18n.chart_title,
-			labelStyle: 'color:#333',
-			labelWidth: 123,
+			labelStyle: 'color:#333; padding-left:2px',
+			labelWidth: 125,
 			maxLength: 100,
 			enforceMaxLength: true,
 			xable: function() {
@@ -148,24 +173,24 @@
 			}
 		});
 
+		rangeAxisTitle = Ext.create('Ext.form.field.Text', {
+			width: cmpWidth,
+			fieldLabel: NS.i18n.range_axis_label,
+			labelStyle: 'color:#333',
+			labelWidth: 125,
+			maxLength: 100,
+			enforceMaxLength: true,
+			style: 'margin-bottom:1px'
+		});
+		
 		domainAxisTitle = Ext.create('Ext.form.field.Text', {
-			style: 'margin-bottom:2px; margin-left:2px',
 			width: 310,
 			fieldLabel: NS.i18n.domain_axis_label,
 			labelStyle: 'color:#333',
-			labelWidth: 123,
-			maxLength: 100,
-			enforceMaxLength: true
-		});
-
-		rangeAxisTitle = Ext.create('Ext.form.field.Text', {
-			style: 'margin-bottom:0; margin-left:2px',
-			width: 310,
-			fieldLabel: NS.i18n.range_axis_label,
-			labelStyle: 'color:#333',
-			labelWidth: 123,
-			maxLength: 100,
-			enforceMaxLength: true
+			labelWidth: 125,
+			maxLength: 100,
+			enforceMaxLength: true,
+			style: 'margin-bottom:1px'
 		});
 
         data = {
@@ -173,6 +198,8 @@
 			bodyStyle: 'border:0 none',
 			style: 'margin-left:14px',
 			items: [
+				showValues,
+				hideEmptyRows,
 				showTrendLine,
 				{
 					xtype: 'container',
@@ -201,27 +228,35 @@
 						baseLineValue,
 						baseLineTitle
 					]
-				},
-				hideEmptyRows
+				}
 			]
 		};
 
-		style = {
-			bodyStyle: 'border:0 none',
-			style: 'margin-left:14px',
-			items: [
-				showValues,
+		axes = {
+			bodyStyle: 'border:0 none',
+			style: 'margin-left:14px',
+			items: [
+				rangeAxisMaxValue,
+				rangeAxisSteps,
+				rangeAxisDecimals,
+				rangeAxisTitle,
+				domainAxisTitle
+			]
+		};			
+
+		general = {
+			bodyStyle: 'border:0 none',
+			style: 'margin-left:14px',
+			items: [
 				hideLegend,
 				hideTitle,
-				title,
-				domainAxisTitle,
-				rangeAxisTitle
+				title
 			]
 		};
 
 		window = Ext.create('Ext.window.Window', {
 			title: NS.i18n.table_options,
-			bodyStyle: 'background-color:#fff; padding:5px',
+			bodyStyle: 'background-color:#fff; padding:5px 5px 3px',
 			closeAction: 'hide',
 			autoShow: true,
 			modal: true,
@@ -229,36 +264,29 @@
 			hideOnBlur: true,
 			getOptions: function() {
 				return {
+					showValues: showValues.getValue(),
+                    hideEmptyRows: hideEmptyRows.getValue(),
 					showTrendLine: showTrendLine.getValue(),
 					targetLineValue: targetLineValue.getValue(),
 					targetLineTitle: targetLineTitle.getValue(),
 					baseLineValue: baseLineValue.getValue(),
 					baseLineTitle: baseLineTitle.getValue(),
-					showValues: showValues.getValue(),
-                    hideEmptyRows: hideEmptyRows.getValue(),
+					rangeAxisMaxValue: rangeAxisMaxValue.getValue(),
+					rangeAxisSteps: rangeAxisSteps.getValue(),
+					rangeAxisDecimals: rangeAxisDecimals.getValue(),
+					rangeAxisTitle: rangeAxisTitle.getValue(),
+					domainAxisTitle: domainAxisTitle.getValue(),
 					hideLegend: hideLegend.getValue(),
 					hideTitle: hideTitle.getValue(),
-					title: title.getValue(),
-					domainAxisTitle: domainAxisTitle.getValue(),
-					rangeAxisTitle: rangeAxisTitle.getValue()
+					title: title.getValue()
 				};
 			},
 			setOptions: function(layout) {
-				showTrendLine.setValue(Ext.isBoolean(layout.showTrendLine) ? layout.showTrendLine : false);
 				showValues.setValue(Ext.isBoolean(layout.showValues) ? layout.showValues : false);
 				hideEmptyRows.setValue(Ext.isBoolean(layout.hideEmptyRows) ? layout.hideEmptyRows : false);
-				hideLegend.setValue(Ext.isBoolean(layout.hideLegend) ? layout.hideLegend : false);
-				hideTitle.setValue(Ext.isBoolean(layout.hideTitle) ? layout.hideTitle : false);
-
-				// Title
-				if (Ext.isString(layout.title)) {
-					title.setValue(layout.title);
-				}
-				else {
-					title.reset();
-				}
-
-				// Target line
+				showTrendLine.setValue(Ext.isBoolean(layout.showTrendLine) ? layout.showTrendLine : false);
+
+				// target line
 				if (Ext.isNumber(layout.targetLineValue)) {
 					targetLineValue.setValue(layout.targetLineValue);
 				}
@@ -273,7 +301,7 @@
 					targetLineTitle.reset();
 				}
 
-				// Base line
+				// base line
 				if (Ext.isNumber(layout.baseLineValue)) {
 					baseLineValue.setValue(layout.baseLineValue);
 				}
@@ -288,38 +316,82 @@
 					baseLineTitle.reset();
 				}
 
-				// Domain axis
+				// rangeAxisMaxValue
+				if (Ext.isNumber(layout.rangeAxisMaxValue)) {
+					rangeAxisMaxValue.setValue(layout.rangeAxisMaxValue);
+				}
+				else {
+					rangeAxisMaxValue.reset();
+				}
+
+				// rangeAxisSteps
+				if (Ext.isNumber(layout.rangeAxisSteps)) {
+					rangeAxisSteps.setValue(layout.rangeAxisSteps);
+				}
+				else {
+					rangeAxisSteps.reset();
+				}
+
+				// rangeAxisDecimals
+				if (Ext.isNumber(layout.rangeAxisDecimals)) {
+					rangeAxisDecimals.setValue(layout.rangeAxisDecimals);
+				}
+				else {
+					rangeAxisDecimals.reset();
+				}
+
+				// range axis title
+				if (Ext.isString(layout.rangeAxisTitle)) {
+					rangeAxisTitle.setValue(layout.rangeAxisTitle);
+				}
+				else {
+					rangeAxisTitle.reset();
+				}
+
+				// domain axis title
 				if (Ext.isString(layout.domainAxisTitle)) {
 					domainAxisTitle.setValue(layout.domainAxisTitle);
 				}
 				else {
 					domainAxisTitle.reset();
 				}
+				
+				hideLegend.setValue(Ext.isBoolean(layout.hideLegend) ? layout.hideLegend : false);
+				hideTitle.setValue(Ext.isBoolean(layout.hideTitle) ? layout.hideTitle : false);
 
-				// Range axis
-				if (Ext.isString(layout.rangeAxisTitle)) {
-					rangeAxisTitle.setValue(layout.rangeAxisTitle);
+				// title
+				if (Ext.isString(layout.title)) {
+					title.setValue(layout.title);
 				}
 				else {
-					rangeAxisTitle.reset();
+					title.reset();
 				}
 			},
 			items: [
 				{
 					bodyStyle: 'border:0 none; color:#222; font-size:12px; font-weight:bold',
-					style: 'margin-bottom:6px',
+					style: 'margin-bottom:6px; margin-left:2px',
 					html: NS.i18n.data
 				},
 				data,
 				{
-					bodyStyle: 'border:0 none; padding:7px'
-				},
-				{
-					bodyStyle: 'border:0 none; color:#222; font-size:12px; font-weight:bold',
-					style: 'margin-bottom:6px',
-					html: NS.i18n.style
-				},
-				style
+					bodyStyle: 'border:0 none; padding:5px'
+				},
+				{
+					bodyStyle: 'border:0 none; color:#222; font-size:12px; font-weight:bold',
+					style: 'margin-bottom:6px; margin-left:2px',
+					html: NS.i18n.axes
+				},
+				axes,
+				{
+					bodyStyle: 'border:0 none; padding:5px'
+				},
+				{
+					bodyStyle: 'border:0 none; color:#222; font-size:12px; font-weight:bold',
+					style: 'margin-bottom:6px; margin-left:2px',
+					html: NS.i18n.general
+				},
+				general
 			],
 			bbar: [
 				'->',
@@ -356,18 +428,23 @@
 					}
 
 					// cmp
+					w.showValues = showValues;
+                    w.hideEmptyRows = hideEmptyRows;
 					w.showTrendLine = showTrendLine;
 					w.targetLineValue = targetLineValue;
 					w.targetLineTitle = targetLineTitle;
 					w.baseLineValue = baseLineValue;
 					w.baseLineTitle = baseLineTitle;
-					w.showValues = showValues;
-                    w.hideEmptyRows = hideEmptyRows;
+
+					w.rangeAxisMaxValue = rangeAxisMaxValue;
+					w.rangeAxisSteps = rangeAxisSteps;
+					w.rangeAxisDecimals = rangeAxisDecimals;
+					w.rangeAxisTitle = rangeAxisTitle;
+					w.domainAxisTitle = domainAxisTitle;
+					
 					w.hideLegend = hideLegend;
 					w.hideTitle = hideTitle;
 					w.title = title;
-					w.domainAxisTitle = domainAxisTitle;
-					w.rangeAxisTitle = rangeAxisTitle;
 				}
 			}
 		});
@@ -430,21 +507,24 @@
 				favorite = Ext.clone(ns.app.layout);
 				dimensions = [].concat(favorite.columns || [], favorite.rows || [], favorite.filters || []);
 
-				// Server sync
-				favorite.totals = favorite.showTotals;
-				delete favorite.showTotals;
-
-				favorite.subtotals = favorite.showSubTotals;
-				delete favorite.showSubTotals;
-
-				favorite.reportParams = {
-					paramReportingPeriod: favorite.reportingPeriod,
-					paramOrganisationUnit: favorite.organisationUnit,
-					paramParentOrganisationUnit: favorite.parentOrganisationUnit
-				};
-				delete favorite.reportingPeriod;
-				delete favorite.organisationUnit;
-				delete favorite.parentOrganisationUnit;
+				// server sync
+				favorite.showData = favorite.showValues;
+				delete favorite.showValues;
+
+				favorite.regression = favorite.showTrendLine;
+				delete favorite.showTrendLine;
+
+				favorite.targetLineLabel = favorite.targetLineTitle;
+				delete favorite.targetLineTitle;
+
+				favorite.baseLineLabel = favorite.baseLineTitle;
+				delete favorite.baseLineTitle;
+
+				favorite.domainAxisLabel = favorite.domainAxisTitle;
+				delete favorite.domainAxisTitle;
+
+				favorite.rangeAxisLabel = favorite.rangeAxisTitle;
+				delete favorite.rangeAxisTitle;
 
 				delete favorite.parentGraphMap;
 

=== modified file 'dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/scripts/core.js'
--- dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/scripts/core.js	2014-03-25 15:06:12 +0000
+++ dhis-2/dhis-web/dhis-web-visualizer/src/main/webapp/dhis-web-visualizer/app/scripts/core.js	2014-04-15 12:43:39 +0000
@@ -313,6 +313,12 @@
 
                 // baseLineTitle: string
 
+                // rangeAxisMaxValue: number
+
+                // rangeAxisSteps: number
+
+                // rangeAxisDecimals: number
+
                 // showValues: boolean (true)
 
                 // hideEmptyRows: boolean (false)
@@ -541,13 +547,9 @@
                     layout.filters = config.filters;
 
                     // properties
-                    layout.showTrendLine = Ext.isBoolean(config.regression) ? config.regression : (Ext.isBoolean(config.showTrendLine) ? config.showTrendLine : false);
                     layout.showValues = Ext.isBoolean(config.showData) ? config.showData : (Ext.isBoolean(config.showValues) ? config.showValues : true);
                     layout.hideEmptyRows = Ext.isBoolean(config.hideEmptyRows) ? config.hideEmptyRows : (Ext.isBoolean(config.hideEmptyRows) ? config.hideEmptyRows : true);
-
-                    layout.hideLegend = Ext.isBoolean(config.hideLegend) ? config.hideLegend : false;
-                    layout.hideTitle = Ext.isBoolean(config.hideTitle) ? config.hideTitle : false;
-
+                    layout.showTrendLine = Ext.isBoolean(config.regression) ? config.regression : (Ext.isBoolean(config.showTrendLine) ? config.showTrendLine : false);
                     layout.targetLineValue = Ext.isNumber(config.targetLineValue) ? config.targetLineValue : null;
                     layout.targetLineTitle = Ext.isString(config.targetLineLabel) && !Ext.isEmpty(config.targetLineLabel) ? config.targetLineLabel :
                         (Ext.isString(config.targetLineTitle) && !Ext.isEmpty(config.targetLineTitle) ? config.targetLineTitle : null);
@@ -555,11 +557,17 @@
                     layout.baseLineTitle = Ext.isString(config.baseLineLabel) && !Ext.isEmpty(config.baseLineLabel) ? config.baseLineLabel :
                         (Ext.isString(config.baseLineTitle) && !Ext.isEmpty(config.baseLineTitle) ? config.baseLineTitle : null);
 
+					layout.rangeAxisMaxValue = Ext.isNumber(config.rangeAxisMaxValue) ? config.rangeAxisMaxValue : null;
+					layout.rangeAxisSteps = Ext.isNumber(config.rangeAxisSteps) ? config.rangeAxisSteps : null;
+					layout.rangeAxisDecimals = Ext.isNumber(config.rangeAxisDecimals) ? config.rangeAxisDecimals : null;
+					layout.rangeAxisTitle = Ext.isString(config.rangeAxisLabel) && !Ext.isEmpty(config.rangeAxisLabel) ? config.rangeAxisLabel :
+                        (Ext.isString(config.rangeAxisTitle) && !Ext.isEmpty(config.rangeAxisTitle) ? config.rangeAxisTitle : null);
+					layout.domainAxisTitle = Ext.isString(config.domainAxisLabel) && !Ext.isEmpty(config.domainAxisLabel) ? config.domainAxisLabel :
+                        (Ext.isString(config.domainAxisTitle) && !Ext.isEmpty(config.domainAxisTitle) ? config.domainAxisTitle : null);
+                        
+                    layout.hideLegend = Ext.isBoolean(config.hideLegend) ? config.hideLegend : false;
+                    layout.hideTitle = Ext.isBoolean(config.hideTitle) ? config.hideTitle : false;
                     layout.title = Ext.isString(config.title) &&  !Ext.isEmpty(config.title) ? config.title : null;
-                    layout.domainAxisTitle = Ext.isString(config.domainAxisLabel) && !Ext.isEmpty(config.domainAxisLabel) ? config.domainAxisLabel :
-                        (Ext.isString(config.domainAxisTitle) && !Ext.isEmpty(config.domainAxisTitle) ? config.domainAxisTitle : null);
-                    layout.rangeAxisTitle = Ext.isString(config.rangeAxisLabel) && !Ext.isEmpty(config.rangeAxisLabel) ? config.rangeAxisLabel :
-                        (Ext.isString(config.rangeAxisTitle) && !Ext.isEmpty(config.rangeAxisTitle) ? config.rangeAxisTitle : null);
 
                     layout.parentGraphMap = Ext.isObject(config.parentGraphMap) ? config.parentGraphMap : null;
 
@@ -1919,12 +1927,17 @@
                         axis.maximum = maximum;
                     }
 
-                    //if (store.getMaximum() < 10) {
-                        //alert(store.rangeFields.length);
-                        //axis.majorTickSteps = 12;
-                    //}
-
-                    //axis.majorTickSteps = 6;
+                    if (xLayout.rangeAxisMaxValue) {
+						axis.maximum = xLayout.rangeAxisMaxValue;
+					}
+
+					if (xLayout.rangeAxisSteps) {
+						axis.majorTickSteps = xLayout.rangeAxisSteps - 1;
+					}
+
+					if (xLayout.rangeAxisDecimals) {
+						axis.label.renderer = Ext.util.Format.numberRenderer(getRenderer(xLayout.rangeAxisDecimals));
+					}                    
 
                     if (xLayout.rangeAxisTitle) {
                         axis.title = xLayout.rangeAxisTitle;