GSTR1 for B2B (#12296)

diff --git a/erpnext/regional/india/utils.py b/erpnext/regional/india/utils.py
index 2cd71a5..10a9c97 100644
--- a/erpnext/regional/india/utils.py
+++ b/erpnext/regional/india/utils.py
@@ -60,6 +60,14 @@
 
 	return hsn_tax, hsn_taxable_amount
 
+def set_place_of_supply(doc, method):
+	if not hasattr(doc, 'customer_gstin'):
+		return
+
+	address_name = doc.shipping_address_name or doc.customer_address
+	address = frappe.db.get_value("Address", address_name, ["gst_state", "gst_state_number"], as_dict=1)
+	doc.place_of_supply = address.gst_state_number + "-" + address.gst_state
+
 # don't remove this function it is used in tests
 def test_method():
 	'''test function'''