mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-31 18:59:08 +00:00
Merge branch 'master' of github.com:webnotes/erpnext into responsive
This commit is contained in:
@@ -9,7 +9,10 @@ def execute():
|
||||
for ref_name in webnotes.conn.sql_list("""select ref_name
|
||||
from `tabEvent` where ref_type=%s and ifnull(starts_on, '')='' """, dt):
|
||||
if webnotes.conn.exists(dt, ref_name):
|
||||
webnotes.get_obj(dt, ref_name).add_calendar_event()
|
||||
if dt in ["Lead", "Opportunity"]:
|
||||
webnotes.get_obj(dt, ref_name).add_calendar_event(force=True)
|
||||
else:
|
||||
webnotes.get_obj(dt, ref_name).add_calendar_event()
|
||||
else:
|
||||
# remove events where ref doc doesn't exist
|
||||
webnotes.delete_doc("Event", webnotes.conn.sql_list("""select name from `tabEvent`
|
||||
|
||||
Reference in New Issue
Block a user