minor fixes

This commit is contained in:
Nabin Hait 2015-03-18 14:54:23 +05:30
parent f7f2372929
commit 2115ee3e71
3 changed files with 5 additions and 6 deletions

View file

@ -926,8 +926,6 @@ def attach_print(doctype, name, file_name=None):
"fcontent": scrub_urls(get_print(doctype, name)).encode("utf-8")
}
print print_settings, out
local.flags.ignore_print_permissions = False
return out

View file

@ -134,9 +134,13 @@ def reinstall(context):
frappe.clear_cache()
except:
installed = []
raise
finally:
frappe.db.close()
if frappe.db:
frappe.db.close()
frappe.destroy()
frappe.init(site=site)
_new_site(frappe.conf.db_name, site, verbose=context.verbose, force=True, reinstall=True, install_apps=installed)
@click.command('install-app')

View file

@ -16,14 +16,11 @@ def get_context(context):
context["my_account_list"] = []
for element in frappe.get_hooks("my_account_context"):
print element
if isinstance(element, dict):
context["my_account_list"].append(element)
else:
frappe.get_attr(element)(context)
print context["my_account_list"]
info = get_fullname_and_avatar(frappe.session.user)
context["fullname"] = info.fullname
context["user_image"] = info.avatar