fix: Chart fix in Analytics report
diff --git a/erpnext/selling/report/sales_analytics/sales_analytics.js b/erpnext/selling/report/sales_analytics/sales_analytics.js
index 149c923..80874c1 100644
--- a/erpnext/selling/report/sales_analytics/sales_analytics.js
+++ b/erpnext/selling/report/sales_analytics/sales_analytics.js
@@ -80,10 +80,14 @@
 
 					var tree_type = frappe.query_report.filters[0].value;
 
-					if(tree_type == "Customer" || tree_type == "Item") {
+					if(tree_type == "Customer") {
 						row_values = data.slice(4,length-1).map(function (column) {
 							return column.content;
 						})
+					} else if (tree_type == "Item") {
+						row_values = data.slice(5,length-1).map(function (column) {
+							return column.content;
+						})
 					}
 					else {
 						row_values = data.slice(3,length-1).map(function (column) {
diff --git a/erpnext/selling/report/sales_analytics/sales_analytics.py b/erpnext/selling/report/sales_analytics/sales_analytics.py
index 72767f0..f1726ab 100644
--- a/erpnext/selling/report/sales_analytics/sales_analytics.py
+++ b/erpnext/selling/report/sales_analytics/sales_analytics.py
@@ -136,7 +136,7 @@
 		if self.filters["value_quantity"] == 'Value':
 			value_field = 'base_amount'
 		else:
-			value_field = 'qty'
+			value_field = 'stock_qty'
 
 		self.entries = frappe.db.sql("""
 			select i.item_code as entity, i.item_name as entity_name, i.stock_uom, i.{value_field} as value_field, s.{date_field}
@@ -338,8 +338,10 @@
 	def get_chart_data(self):
 		length = len(self.columns)
 
-		if self.filters.tree_type in ["Customer", "Supplier", "Item"]:
+		if self.filters.tree_type in ["Customer", "Supplier"]:
 			labels = [d.get("label") for d in self.columns[2:length - 1]]
+		elif self.filters.tree_type == "Item":
+			labels = [d.get("label") for d in self.columns[3:length - 1]]
 		else:
 			labels = [d.get("label") for d in self.columns[1:length - 1]]
 		self.chart = {