Sfoglia il codice sorgente

Merge branch 'develop'

version-14
Nabin Hait 9 anni fa
parent
commit
bb835047a8
5 ha cambiato i file con 17 aggiunte e 6 eliminazioni
  1. +1
    -1
      frappe/__init__.py
  2. +4
    -4
      frappe/docs/user/en/guides/deployment/how-to-enable-social-logins.md
  3. +6
    -0
      frappe/installer.py
  4. +5
    -1
      frappe/model/rename_doc.py
  5. +1
    -0
      frappe/patches.txt

+ 1
- 1
frappe/__init__.py Vedi File

@@ -13,7 +13,7 @@ import os, sys, importlib, inspect, json
from .exceptions import *
from .utils.jinja import get_jenv, get_template, render_template

__version__ = "7.0.10"
__version__ = "7.0.11"

local = Local()



+ 4
- 4
frappe/docs/user/en/guides/deployment/how-to-enable-social-logins.md Vedi File

@@ -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. 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:
**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. 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**
@@ -40,7 +40,7 @@ To enable these signups, you need to have **Client ID** and **Client Secret** fr
- Web Application
- Authorized JavaScript origins as **http://{{ yoursite }}**
- 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**

<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:
- Homepage URL as **http://{{ yoursite }}**
- 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. 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>
</div>

<!-- markdown -->
<!-- markdown -->

+ 6
- 0
frappe/installer.py Vedi File

@@ -188,6 +188,12 @@ def remove_app(app_name, dry_run=False):

if not doctype.issingle:
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}):
print "removing Page {0}...".format(page.name)


+ 5
- 1
frappe/model/rename_doc.py Vedi File

@@ -89,12 +89,16 @@ def rename_parent_and_child(doctype, old, new, meta):

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!
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

if merge and not exists:
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:
frappe.msgprint(_("Another {0} with name {1} exists, select another name").format(doctype, new), raise_exception=1)



+ 1
- 0
frappe/patches.txt Vedi File

@@ -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', 'docfield', force=True) #2016-02-26
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('core', 'doctype', 'page') #2013-13-26
execute:frappe.reload_doc('core', 'doctype', 'report') #2014-06-03


Caricamento…
Annulla
Salva