Exemple #1
0
	def onload(self):
		"""Load address and contacts in `__onload`"""
		load_address_and_contact(self, "customer")
		import time
		todays_date = datetime.datetime.strptime(cstr(nowdate()),'%Y-%m-%d')
		# Show popup if financial data is not updated after the 6 month of every fiscal year.
		if todays_date.month > 6:
			self.get_financial_data()
Exemple #2
0
    def onload(self):
        load_address_and_contact(self, "customer")
        billed_qty = frappe.db.sql(
            """select sum(ifnull(qty, 0)) from `tabSales Invoice Item`
			where docstatus=1 and delivery_note=%s""", self.name)
        if billed_qty:
            total_qty = sum(
                (item.qty for item in self.get("delivery_note_details")))
            self.get("__onload").billing_complete = (
                billed_qty[0][0] == total_qty)
Exemple #3
0
	def onload(self):
		customer = frappe.db.get_value("Customer", {"lead_name": self.name})
		self.get("__onload").is_customer = customer
		load_address_and_contact(self, "lead")
Exemple #4
0
 def onload(self):
     """Load address and contacts in `__onload`"""
     load_address_and_contact(self, "customer")
Exemple #5
0
 def onload(self):
     """Load address and contacts in `__onload`"""
     load_address_and_contact(self, "supplier")
     self.load_dashboard_info()
Exemple #6
0
 def onload(self):
     """Load address and contacts in `__onload`"""
     load_address_and_contact(self, "organisation")
Exemple #7
0
	def onload(self):
		"""Load address and contacts in `__onload`"""
		load_address_and_contact(self, "customer")
		self.load_dashboard_info()
Exemple #8
0
 def onload(self):
     """Load address and contacts in `__onload`"""
     load_address_and_contact(self, "supplier")
Exemple #9
0
 def onload(self):
     customer = frappe.db.get_value("Customer", {"lead_name": self.name})
     self.get("__onload").is_customer = customer
     load_address_and_contact(self, "lead")
	def onload(self):
		"""Load address and contacts in `__onload`"""
		load_address_and_contact(self, "sales_partner")
Exemple #11
0
	def onload(self):
		"""Load address and contacts in `__onload`"""
		load_address_and_contact(self, "organisation")
	def onload(self):
		"""Load address and contacts in `__onload`"""
		load_address_and_contact(self, "supplier")
		self.set_onload('links', self.meta.get_links_setup())
 def onload(self):
     """Load address and contacts in `__onload`"""
     load_address_and_contact(self, "sales_partner")
Exemple #14
0
	def onload(self):
		"""Load address and contacts in `__onload`"""
		load_address_and_contact(self, "customer")
		self.set_onload('links', self.meta.get_links_setup())