Pass buying or selling as filter parameters

Wherever get_exchange_rate is called, pass filter buying or selling on the basis of doctype.
diff --git a/erpnext/demo/user/purchase.py b/erpnext/demo/user/purchase.py
index d9fc1f3..327f617 100644
--- a/erpnext/demo/user/purchase.py
+++ b/erpnext/demo/user/purchase.py
@@ -56,7 +56,7 @@
 	if company_currency == party_account_currency:
 		exchange_rate = 1
 	else:
-		exchange_rate = get_exchange_rate(party_account_currency, company_currency)
+		exchange_rate = get_exchange_rate(party_account_currency, company_currency, args="for_buying")
 
 	# make supplier quotations
 	if random.random() < 0.2:
diff --git a/erpnext/demo/user/sales.py b/erpnext/demo/user/sales.py
index 2fd2565..02e1d42 100644
--- a/erpnext/demo/user/sales.py
+++ b/erpnext/demo/user/sales.py
@@ -89,7 +89,7 @@
 		if company_currency == party_account_currency:
 			exchange_rate = 1
 		else:
-			exchange_rate = get_exchange_rate(party_account_currency, company_currency)
+			exchange_rate = get_exchange_rate(party_account_currency, company_currency, args="for_selling")
 
 		qtn = frappe.get_doc({
 			"creation": frappe.flags.current_date,