@@ -13,7 +13,7 @@ import os, sys, importlib, inspect, json | |||||
from .exceptions import * | from .exceptions import * | ||||
from .utils.jinja import get_jenv, get_template, render_template | from .utils.jinja import get_jenv, get_template, render_template | ||||
__version__ = "7.0.10" | |||||
__version__ = "7.0.11" | |||||
local = Local() | local = Local() | ||||
@@ -20,7 +20,7 @@ To enable these signups, you need to have **Client ID** and **Client Secret** fr | |||||
1. Click on Apps (topbar) > New App, fill in the form. | 1. Click on Apps (topbar) > New App, fill in the form. | ||||
1. Go to Settings > Basic, set the **Contact Email** and save the changes. | 1. Go to Settings > Basic, set the **Contact Email** and save the changes. | ||||
1. Go to Settings > Advanced, find the field **Valid OAuth redirect URIs**, and enter: | 1. Go to Settings > Advanced, find the field **Valid OAuth redirect URIs**, and enter: | ||||
**http://{{ yoursite }}/api/method/frappe.templates.pages.login.login\_via\_facebook** | |||||
**http://{{ yoursite }}/api/method/frappe.www.login.login\_via\_facebook** | |||||
1. Save the changes in Advance tab. | 1. Save the changes in Advance tab. | ||||
1. Go to Status & Review and switch on "Do you want to make this app and all its live features available to the general public?" | 1. Go to Status & Review and switch on "Do you want to make this app and all its live features available to the general public?" | ||||
1. Go to Dashboard, click on the show button besides App Secret, and copy the App ID and App Secret into **Desktop > Website > Setup > Social Login Keys** | 1. Go to Dashboard, click on the show button besides App Secret, and copy the App ID and App Secret into **Desktop > Website > Setup > Social Login Keys** | ||||
@@ -40,7 +40,7 @@ To enable these signups, you need to have **Client ID** and **Client Secret** fr | |||||
- Web Application | - Web Application | ||||
- Authorized JavaScript origins as **http://{{ yoursite }}** | - Authorized JavaScript origins as **http://{{ yoursite }}** | ||||
- Authorized redirect URI as | - Authorized redirect URI as | ||||
**http://{{ yoursite }}/api/method/frappe.templates.pages.login.login\_via\_google** | |||||
**http://{{ yoursite }}/api/method/frappe.www.login.login\_via\_google** | |||||
1. Go to the section **Client ID for web application** and copy the Client ID and Client Secret into **Desktop > Website > Setup > Social Login Keys** | 1. Go to the section **Client ID for web application** and copy the Client ID and Client Secret into **Desktop > Website > Setup > Social Login Keys** | ||||
<div class="embed-responsive embed-responsive-16by9"> | <div class="embed-responsive embed-responsive-16by9"> | ||||
@@ -56,7 +56,7 @@ To enable these signups, you need to have **Client ID** and **Client Secret** fr | |||||
1. Fill the form with: | 1. Fill the form with: | ||||
- Homepage URL as **http://{{ yoursite }}** | - Homepage URL as **http://{{ yoursite }}** | ||||
- Authorization callback URL as | - Authorization callback URL as | ||||
**http://{{ yoursite }}/api/method/frappe.templates.pages.login.login\_via\_github** | |||||
**http://{{ yoursite }}/api/method/frappe.www.login.login\_via\_github** | |||||
1. Click on Register application. | 1. Click on Register application. | ||||
1. Copy the generated Client ID and Client Secret into **Desktop > Website > Setup > Social Login Keys** | 1. Copy the generated Client ID and Client Secret into **Desktop > Website > Setup > Social Login Keys** | ||||
@@ -64,4 +64,4 @@ To enable these signups, you need to have **Client ID** and **Client Secret** fr | |||||
<iframe src="https://www.youtube.com/embed/bG71DxxkVjQ" class="embed-responsive-item" allowfullscreen></iframe> | <iframe src="https://www.youtube.com/embed/bG71DxxkVjQ" class="embed-responsive-item" allowfullscreen></iframe> | ||||
</div> | </div> | ||||
<!-- markdown --> | |||||
<!-- markdown --> |
@@ -188,6 +188,12 @@ def remove_app(app_name, dry_run=False): | |||||
if not doctype.issingle: | if not doctype.issingle: | ||||
drop_doctypes.append(doctype.name) | drop_doctypes.append(doctype.name) | ||||
# remove reports | |||||
for report in frappe.get_list("Report", filters={"module": module_name}): | |||||
print "removing {0}...".format(report.name) | |||||
if not dry_run: | |||||
frappe.delete_doc("Report", report.name) | |||||
for page in frappe.get_list("Page", filters={"module": module_name}): | for page in frappe.get_list("Page", filters={"module": module_name}): | ||||
print "removing Page {0}...".format(page.name) | print "removing Page {0}...".format(page.name) | ||||
@@ -89,12 +89,16 @@ def rename_parent_and_child(doctype, old, new, meta): | |||||
def validate_rename(doctype, new, meta, merge, force, ignore_permissions): | def validate_rename(doctype, new, meta, merge, force, ignore_permissions): | ||||
# using for update so that it gets locked and someone else cannot edit it while this rename is going on! | # using for update so that it gets locked and someone else cannot edit it while this rename is going on! | ||||
exists = frappe.db.sql("select name from `tab{doctype}` where name=%s COLLATE utf8mb4_unicode_ci for update".format(doctype=frappe.db.escape(doctype)), new) | |||||
exists = frappe.db.sql("select name from `tab{doctype}` where name=%s for update".format(doctype=frappe.db.escape(doctype)), new) | |||||
exists = exists[0][0] if exists else None | exists = exists[0][0] if exists else None | ||||
if merge and not exists: | if merge and not exists: | ||||
frappe.msgprint(_("{0} {1} does not exist, select a new target to merge").format(doctype, new), raise_exception=1) | frappe.msgprint(_("{0} {1} does not exist, select a new target to merge").format(doctype, new), raise_exception=1) | ||||
if exists and exists != new: | |||||
# for fixing case, accents | |||||
exists = None | |||||
if (not merge) and exists: | if (not merge) and exists: | ||||
frappe.msgprint(_("Another {0} with name {1} exists, select another name").format(doctype, new), raise_exception=1) | frappe.msgprint(_("Another {0} with name {1} exists, select another name").format(doctype, new), raise_exception=1) | ||||
@@ -4,6 +4,7 @@ frappe.patches.v6_1.rename_file_data | |||||
execute:frappe.reload_doc('core', 'doctype', 'doctype', force=True) #2016-07-11 | execute:frappe.reload_doc('core', 'doctype', 'doctype', force=True) #2016-07-11 | ||||
execute:frappe.reload_doc('core', 'doctype', 'docfield', force=True) #2016-02-26 | execute:frappe.reload_doc('core', 'doctype', 'docfield', force=True) #2016-02-26 | ||||
execute:frappe.reload_doc('core', 'doctype', 'docperm') #2014-06-24 | execute:frappe.reload_doc('core', 'doctype', 'docperm') #2014-06-24 | ||||
execute:frappe.reload_doc('core', 'doctype', 'role') | |||||
execute:frappe.reload_doc('custom', 'doctype', 'custom_field') #2015-10-19 | execute:frappe.reload_doc('custom', 'doctype', 'custom_field') #2015-10-19 | ||||
execute:frappe.reload_doc('core', 'doctype', 'page') #2013-13-26 | execute:frappe.reload_doc('core', 'doctype', 'page') #2013-13-26 | ||||
execute:frappe.reload_doc('core', 'doctype', 'report') #2014-06-03 | execute:frappe.reload_doc('core', 'doctype', 'report') #2014-06-03 | ||||