Quellcode durchsuchen

[fixes] document_type, added set-config in commands, prompt in form.js

version-14
Rushabh Mehta vor 10 Jahren
Ursprung
Commit
6985d4127e
30 geänderte Dateien mit 940 neuen und 871 gelöschten Zeilen
  1. +13
    -0
      frappe/commands.py
  2. +2
    -2
      frappe/core/doctype/async_task/async_task.json
  3. +2
    -2
      frappe/core/doctype/communication/communication.json
  4. +4
    -3
      frappe/core/doctype/doctype/doctype.json
  5. +1
    -1
      frappe/core/doctype/doctype/doctype.py
  6. +417
    -417
      frappe/core/doctype/user/user.json
  7. +2
    -2
      frappe/core/doctype/version/version.json
  8. +2
    -2
      frappe/desk/doctype/note/note.json
  9. +4
    -8
      frappe/desk/moduleview.py
  10. +2
    -2
      frappe/email/doctype/email_account/email_account.json
  11. +2
    -7
      frappe/email/doctype/standard_reply/standard_reply.json
  12. +2
    -2
      frappe/geo/doctype/country/country.json
  13. +30
    -2
      frappe/installer.py
  14. +1
    -0
      frappe/patches.txt
  15. +7
    -0
      frappe/patches/v6_0/document_type_rename.py
  16. +1
    -1
      frappe/public/js/frappe/form/layout.js
  17. +38
    -22
      frappe/public/js/frappe/form/save.js
  18. +3
    -0
      frappe/public/js/frappe/form/toolbar.js
  19. +12
    -10
      frappe/public/js/frappe/ui/dialog.js
  20. +8
    -0
      frappe/public/js/frappe/ui/messages.js
  21. +1
    -2
      frappe/public/js/legacy/form.js
  22. +2
    -2
      frappe/website/doctype/blog_category/blog_category.json
  23. +2
    -2
      frappe/website/doctype/blogger/blogger.json
  24. +3
    -3
      frappe/website/doctype/web_form/web_form.json
  25. +2
    -2
      frappe/website/doctype/web_page/web_page.json
  26. +2
    -2
      frappe/website/doctype/website_slideshow/website_slideshow.json
  27. +238
    -238
      frappe/website/doctype/website_theme/website_theme.json
  28. +76
    -76
      frappe/workflow/doctype/workflow/workflow.json
  29. +59
    -59
      frappe/workflow/doctype/workflow_document_state/workflow_document_state.json
  30. +2
    -2
      frappe/workflow/doctype/workflow_state/workflow_state.json

+ 13
- 0
frappe/commands.py Datei anzeigen

@@ -759,6 +759,18 @@ def move(dest_dir, site):
frappe.destroy()
return final_new_path


@click.command('set-config')
@click.argument('key')
@click.argument('value')
@pass_context
def set_config(context, key, value):
from frappe.installer import update_site_config
for site in context.sites:
frappe.init(site=site)
update_site_config(key, value)
frappe.destroy()

@click.command('drop-site')
@click.argument('site')
@click.option('--root-login', default='root')
@@ -837,4 +849,5 @@ commands = [
backup,
remove_from_installed_apps,
drop_site,
set_config,
]

+ 2
- 2
frappe/core/doctype/async_task/async_task.json Datei anzeigen

@@ -7,7 +7,7 @@
"custom": 0,
"docstatus": 0,
"doctype": "DocType",
"document_type": "Transaction",
"document_type": "Document",
"fields": [
{
"allow_on_submit": 0,
@@ -114,7 +114,7 @@
"is_submittable": 0,
"issingle": 0,
"istable": 0,
"modified": "2015-07-04 14:33:26.791024",
"modified": "2015-07-28 16:18:11.344349",
"modified_by": "Administrator",
"module": "Core",
"name": "Async Task",


+ 2
- 2
frappe/core/doctype/communication/communication.json Datei anzeigen

@@ -5,7 +5,7 @@
"description": "Keep a track of all communications",
"docstatus": 0,
"doctype": "DocType",
"document_type": "Master",
"document_type": "Setup",
"fields": [
{
"default": "COMM-",
@@ -182,7 +182,7 @@
"idx": 1,
"in_dialog": 0,
"issingle": 0,
"modified": "2015-03-23 02:33:55.289739",
"modified": "2015-07-28 16:18:11.664740",
"modified_by": "Administrator",
"module": "Core",
"name": "Communication",


+ 4
- 3
frappe/core/doctype/doctype/doctype.json Datei anzeigen

@@ -7,6 +7,7 @@
"description": "DocType is a Table / Form in the application.",
"docstatus": 0,
"doctype": "DocType",
"document_type": "Document",
"fields": [
{
"fieldname": "sb0",
@@ -65,7 +66,7 @@
"label": "Document Type",
"oldfieldname": "document_type",
"oldfieldtype": "Select",
"options": "\nMaster\nTransaction\nSystem\nOther",
"options": "\nDocument\nSetup\nSystem\nOther",
"permlevel": 0
},
{
@@ -108,7 +109,7 @@
"oldfieldtype": "Table",
"options": "DocField",
"permlevel": 0,
"reqd": 1,
"reqd": 0,
"search_index": 0
},
{
@@ -337,7 +338,7 @@
"idx": 1,
"issingle": 0,
"istable": 0,
"modified": "2015-03-03 10:40:45.768116",
"modified": "2015-07-28 16:18:11.925264",
"modified_by": "Administrator",
"module": "Core",
"name": "DocType",


+ 1
- 1
frappe/core/doctype/doctype/doctype.py Datei anzeigen

@@ -87,7 +87,7 @@ class DocType(Document):

if autoname and (not autoname.startswith('field:')) \
and (not autoname.startswith('eval:')) \
and (not autoname in ('Prompt', 'hash')) \
and (not autoname.lower() in ('prompt', 'hash')) \
and (not autoname.startswith('naming_series:')):

prefix = autoname.split('.')[0]


+ 417
- 417
frappe/core/doctype/user/user.json Datei anzeigen

@@ -1,519 +1,519 @@
{
"allow_copy": 0,
"allow_import": 1,
"allow_rename": 1,
"creation": "2014-03-11 14:55:00",
"description": "Represents a User in the system.",
"docstatus": 0,
"doctype": "DocType",
"document_type": "Master",
"allow_copy": 0,
"allow_import": 1,
"allow_rename": 1,
"creation": "2014-03-11 14:55:00",
"description": "Represents a User in the system.",
"docstatus": 0,
"doctype": "DocType",
"document_type": "Setup",
"fields": [
{
"fieldname": "sb0_5",
"fieldtype": "Section Break",
"label": "",
"fieldname": "sb0_5",
"fieldtype": "Section Break",
"label": "",
"permlevel": 0
},
{
"default": "1",
"fieldname": "enabled",
"fieldtype": "Check",
"in_list_view": 0,
"label": "Enabled",
"no_copy": 0,
"oldfieldname": "enabled",
"oldfieldtype": "Check",
"permlevel": 0,
},
{
"default": "1",
"fieldname": "enabled",
"fieldtype": "Check",
"in_list_view": 0,
"label": "Enabled",
"no_copy": 0,
"oldfieldname": "enabled",
"oldfieldtype": "Check",
"permlevel": 0,
"read_only": 1
},
},
{
"fieldname": "section_break_3",
"fieldtype": "Section Break",
"permlevel": 0,
"fieldname": "section_break_3",
"fieldtype": "Section Break",
"permlevel": 0,
"precision": ""
},
{
"fieldname": "email",
"fieldtype": "Data",
"hidden": 0,
"label": "Email",
"no_copy": 1,
"oldfieldname": "email",
"oldfieldtype": "Data",
"options": "Email",
"permlevel": 0,
"reqd": 1,
},
{
"fieldname": "email",
"fieldtype": "Data",
"hidden": 0,
"label": "Email",
"no_copy": 1,
"oldfieldname": "email",
"oldfieldtype": "Data",
"options": "Email",
"permlevel": 0,
"reqd": 1,
"search_index": 0
},
{
"fieldname": "first_name",
"fieldtype": "Data",
"in_list_view": 0,
"label": "First Name",
"no_copy": 0,
"oldfieldname": "first_name",
"oldfieldtype": "Data",
"permlevel": 0,
},
{
"fieldname": "first_name",
"fieldtype": "Data",
"in_list_view": 0,
"label": "First Name",
"no_copy": 0,
"oldfieldname": "first_name",
"oldfieldtype": "Data",
"permlevel": 0,
"reqd": 1
},
{
"fieldname": "middle_name",
"fieldtype": "Data",
"label": "Middle Name (Optional)",
"no_copy": 0,
"oldfieldname": "middle_name",
"oldfieldtype": "Data",
},
{
"fieldname": "middle_name",
"fieldtype": "Data",
"label": "Middle Name (Optional)",
"no_copy": 0,
"oldfieldname": "middle_name",
"oldfieldtype": "Data",
"permlevel": 0
},
{
"fieldname": "last_name",
"fieldtype": "Data",
"in_list_view": 0,
"label": "Last Name",
"oldfieldname": "last_name",
"oldfieldtype": "Data",
},
{
"fieldname": "last_name",
"fieldtype": "Data",
"in_list_view": 0,
"label": "Last Name",
"oldfieldname": "last_name",
"oldfieldtype": "Data",
"permlevel": 0
},
{
"default": "1",
"depends_on": "eval:doc.__islocal",
"fieldname": "send_welcome_email",
"fieldtype": "Check",
"label": "Send Welcome Email",
"permlevel": 0,
},
{
"default": "1",
"depends_on": "eval:doc.__islocal",
"fieldname": "send_welcome_email",
"fieldtype": "Check",
"label": "Send Welcome Email",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "unsubscribed",
"fieldtype": "Check",
"hidden": 1,
"label": "Unsubscribed",
"no_copy": 1,
"fieldname": "unsubscribed",
"fieldtype": "Check",
"hidden": 1,
"label": "Unsubscribed",
"no_copy": 1,
"permlevel": 0
},
},
{
"fieldname": "column_break0",
"fieldtype": "Column Break",
"oldfieldtype": "Column Break",
"permlevel": 0,
"print_width": "50%",
"fieldname": "column_break0",
"fieldtype": "Column Break",
"oldfieldtype": "Column Break",
"permlevel": 0,
"print_width": "50%",
"width": "50%"
},
},
{
"description": "",
"fieldname": "language",
"fieldtype": "Select",
"label": "Language",
"options": "Loading...",
"description": "",
"fieldname": "language",
"fieldtype": "Select",
"label": "Language",
"options": "Loading...",
"permlevel": 0
},
},
{
"description": "",
"fieldname": "time_zone",
"fieldtype": "Select",
"label": "Timezone",
"description": "",
"fieldname": "time_zone",
"fieldtype": "Select",
"label": "Timezone",
"permlevel": 0
},
},
{
"depends_on": "eval:!doc.__islocal",
"fieldname": "change_password",
"fieldtype": "Section Break",
"label": "",
"depends_on": "eval:!doc.__islocal",
"fieldname": "change_password",
"fieldtype": "Section Break",
"label": "",
"permlevel": 0
},
},
{
"fieldname": "new_password",
"fieldtype": "Password",
"label": "Set New Password",
"no_copy": 1,
"fieldname": "new_password",
"fieldtype": "Password",
"label": "Set New Password",
"no_copy": 1,
"permlevel": 0
},
},
{
"depends_on": "",
"fieldname": "send_password_update_notification",
"fieldtype": "Check",
"label": "Send Password Update Notification",
"permlevel": 0,
"depends_on": "",
"fieldname": "send_password_update_notification",
"fieldtype": "Check",
"label": "Send Password Update Notification",
"permlevel": 0,
"precision": ""
},
{
"fieldname": "reset_password_key",
"fieldtype": "Data",
"hidden": 1,
"label": "Reset Password Key",
"no_copy": 1,
"permlevel": 0,
"print_hide": 1,
},
{
"fieldname": "reset_password_key",
"fieldtype": "Data",
"hidden": 1,
"label": "Reset Password Key",
"no_copy": 1,
"permlevel": 0,
"print_hide": 1,
"read_only": 1
},
},
{
"depends_on": "eval:!doc.__islocal",
"fieldname": "display_settings",
"fieldtype": "Section Break",
"label": "",
"depends_on": "eval:!doc.__islocal",
"fieldname": "display_settings",
"fieldtype": "Section Break",
"label": "",
"permlevel": 0
},
{
"description": "Get your globally recognized avatar from Gravatar.com",
"fieldname": "user_image",
"fieldtype": "Attach",
"hidden": 0,
"label": "User Image",
"no_copy": 1,
},
{
"description": "Get your globally recognized avatar from Gravatar.com",
"fieldname": "user_image",
"fieldtype": "Attach",
"hidden": 0,
"label": "User Image",
"no_copy": 1,
"permlevel": 0
},
},
{
"fieldname": "cb21",
"fieldtype": "Column Break",
"fieldname": "cb21",
"fieldtype": "Column Break",
"permlevel": 0
},
},
{
"fieldname": "user_image_show",
"fieldtype": "Image",
"label": "user_image_show",
"options": "user_image",
"fieldname": "user_image_show",
"fieldtype": "Image",
"label": "user_image_show",
"options": "user_image",
"permlevel": 0
},
},
{
"fieldname": "email_settings",
"fieldtype": "Section Break",
"label": "Email Settings",
"permlevel": 0,
"fieldname": "email_settings",
"fieldtype": "Section Break",
"label": "Email Settings",
"permlevel": 0,
"precision": ""
},
},
{
"default": "1",
"fieldname": "thread_notify",
"fieldtype": "Check",
"label": "Send Notifications for Transactions I Follow",
"permlevel": 0,
"default": "1",
"fieldname": "thread_notify",
"fieldtype": "Check",
"label": "Send Notifications for Transactions I Follow",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "email_signature",
"fieldtype": "Small Text",
"label": "Email Signature",
"no_copy": 1,
"fieldname": "email_signature",
"fieldtype": "Small Text",
"label": "Email Signature",
"no_copy": 1,
"permlevel": 0
},
},
{
"fieldname": "background",
"fieldtype": "Section Break",
"label": "",
"permlevel": 0,
"fieldname": "background",
"fieldtype": "Section Break",
"label": "",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "background_image",
"fieldtype": "Attach",
"label": "Background Image",
"permlevel": 0,
"fieldname": "background_image",
"fieldtype": "Attach",
"label": "Background Image",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "background_style",
"fieldtype": "Select",
"label": "Background Style",
"options": "Fill Screen\nTile",
"permlevel": 0,
"fieldname": "background_style",
"fieldtype": "Select",
"label": "Background Style",
"options": "Fill Screen\nTile",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "short_bio",
"fieldtype": "Section Break",
"label": "",
"fieldname": "short_bio",
"fieldtype": "Section Break",
"label": "",
"permlevel": 0
},
{
"fieldname": "gender",
"fieldtype": "Select",
"label": "Gender",
"oldfieldname": "gender",
"oldfieldtype": "Select",
"options": "\nMale\nFemale\nOther",
"permlevel": 0,
},
{
"fieldname": "gender",
"fieldtype": "Select",
"label": "Gender",
"oldfieldname": "gender",
"oldfieldtype": "Select",
"options": "\nMale\nFemale\nOther",
"permlevel": 0,
"search_index": 0
},
{
"fieldname": "birth_date",
"fieldtype": "Date",
"label": "Birth Date",
"no_copy": 1,
"oldfieldname": "birth_date",
"oldfieldtype": "Date",
},
{
"fieldname": "birth_date",
"fieldtype": "Date",
"label": "Birth Date",
"no_copy": 1,
"oldfieldname": "birth_date",
"oldfieldtype": "Date",
"permlevel": 0
},
},
{
"fieldname": "location",
"fieldtype": "Data",
"label": "Location",
"no_copy": 1,
"fieldname": "location",
"fieldtype": "Data",
"label": "Location",
"no_copy": 1,
"permlevel": 0
},
},
{
"fieldname": "column_break_22",
"fieldtype": "Column Break",
"fieldname": "column_break_22",
"fieldtype": "Column Break",
"permlevel": 0
},
},
{
"fieldname": "bio",
"fieldtype": "Small Text",
"label": "Bio",
"no_copy": 1,
"permlevel": 0,
"fieldname": "bio",
"fieldtype": "Small Text",
"label": "Bio",
"no_copy": 1,
"permlevel": 0,
"set_only_once": 0
},
},
{
"description": "Check / Uncheck roles assigned to the User. Click on the Role to find out what permissions that Role has.",
"fieldname": "sb1",
"fieldtype": "Section Break",
"label": "Roles",
"permlevel": 1,
"description": "Check / Uncheck roles assigned to the User. Click on the Role to find out what permissions that Role has.",
"fieldname": "sb1",
"fieldtype": "Section Break",
"label": "Roles",
"permlevel": 1,
"read_only": 1
},
},
{
"fieldname": "roles_html",
"fieldtype": "HTML",
"label": "Roles HTML",
"permlevel": 0,
"fieldname": "roles_html",
"fieldtype": "HTML",
"label": "Roles HTML",
"permlevel": 0,
"read_only": 1
},
{
"fieldname": "user_roles",
"fieldtype": "Table",
"hidden": 1,
"label": "Roles Assigned",
"options": "UserRole",
"permlevel": 1,
"print_hide": 1,
},
{
"fieldname": "user_roles",
"fieldtype": "Table",
"hidden": 1,
"label": "Roles Assigned",
"options": "UserRole",
"permlevel": 1,
"print_hide": 1,
"read_only": 1
},
{
"default": "",
"description": "Uncheck modules to hide from user's desktop",
"fieldname": "modules_access",
"fieldtype": "Section Break",
"label": "Modules Access",
"permlevel": 1,
},
{
"default": "",
"description": "Uncheck modules to hide from user's desktop",
"fieldname": "modules_access",
"fieldtype": "Section Break",
"label": "Modules Access",
"permlevel": 1,
"precision": ""
},
},
{
"fieldname": "modules_html",
"fieldtype": "HTML",
"label": "Modules HTML",
"permlevel": 1,
"fieldname": "modules_html",
"fieldtype": "HTML",
"label": "Modules HTML",
"permlevel": 1,
"precision": ""
},
{
"fieldname": "block_modules",
"fieldtype": "Table",
"hidden": 1,
"label": "Block Modules",
"options": "Block Module",
"permlevel": 1,
},
{
"fieldname": "block_modules",
"fieldtype": "Table",
"hidden": 1,
"label": "Block Modules",
"options": "Block Module",
"permlevel": 1,
"precision": ""
},
{
"description": "These values will be automatically updated in transactions and also will be useful to restrict permissions for this user on transactions containing these values.",
"fieldname": "sb2",
"fieldtype": "Section Break",
"hidden": 1,
"label": "Defaults",
"oldfieldtype": "Column Break",
"permlevel": 1,
"print_width": "50%",
"read_only": 1,
},
{
"description": "These values will be automatically updated in transactions and also will be useful to restrict permissions for this user on transactions containing these values.",
"fieldname": "sb2",
"fieldtype": "Section Break",
"hidden": 1,
"label": "Defaults",
"oldfieldtype": "Column Break",
"permlevel": 1,
"print_width": "50%",
"read_only": 1,
"width": "50%"
},
{
"description": "Enter default value fields (keys) and values. If you add multiple values for a field, the first one will be picked. These defaults are also used to set \"match\" permission rules. To see list of fields, go to \"Customize Form\".",
"fieldname": "defaults",
"fieldtype": "Table",
"hidden": 1,
"label": "User Defaults",
"no_copy": 1,
"options": "DefaultValue",
},
{
"description": "Enter default value fields (keys) and values. If you add multiple values for a field, the first one will be picked. These defaults are also used to set \"match\" permission rules. To see list of fields, go to \"Customize Form\".",
"fieldname": "defaults",
"fieldtype": "Table",
"hidden": 1,
"label": "User Defaults",
"no_copy": 1,
"options": "DefaultValue",
"permlevel": 0
},
},
{
"fieldname": "sb3",
"fieldtype": "Section Break",
"label": "Security Settings",
"oldfieldtype": "Section Break",
"permlevel": 0,
"fieldname": "sb3",
"fieldtype": "Section Break",
"label": "Security Settings",
"oldfieldtype": "Section Break",
"permlevel": 0,
"read_only": 1
},
{
"default": "System User",
"description": "User Type \"System User\" can access Desktop. \"Website User\" can only be logged into the website and portal pages. ",
"fieldname": "user_type",
"fieldtype": "Select",
"in_list_view": 1,
"label": "User Type",
"oldfieldname": "user_type",
"oldfieldtype": "Select",
"options": "System User\nWebsite User",
"permlevel": 0,
"read_only": 1,
},
{
"default": "System User",
"description": "User Type \"System User\" can access Desktop. \"Website User\" can only be logged into the website and portal pages. ",
"fieldname": "user_type",
"fieldtype": "Select",
"in_list_view": 1,
"label": "User Type",
"oldfieldname": "user_type",
"oldfieldtype": "Select",
"options": "System User\nWebsite User",
"permlevel": 0,
"read_only": 1,
"reqd": 1
},
},
{
"description": "Allow user to login only after this hour (0-24)",
"fieldname": "login_after",
"fieldtype": "Int",
"label": "Login After",
"permlevel": 0,
"description": "Allow user to login only after this hour (0-24)",
"fieldname": "login_after",
"fieldtype": "Int",
"label": "Login After",
"permlevel": 0,
"read_only": 1
},
},
{
"description": "Allow user to login only before this hour (0-24)",
"fieldname": "login_before",
"fieldtype": "Int",
"label": "Login Before",
"permlevel": 0,
"description": "Allow user to login only before this hour (0-24)",
"fieldname": "login_before",
"fieldtype": "Int",
"label": "Login Before",
"permlevel": 0,
"read_only": 1
},
},
{
"description": "Restrict user from this IP address only. Multiple IP addresses can be added by separating with commas. Also accepts partial IP addresses like (111.111.111)",
"fieldname": "restrict_ip",
"fieldtype": "Data",
"label": "Restrict IP",
"permlevel": 0,
"description": "Restrict user from this IP address only. Multiple IP addresses can be added by separating with commas. Also accepts partial IP addresses like (111.111.111)",
"fieldname": "restrict_ip",
"fieldtype": "Data",
"label": "Restrict IP",
"permlevel": 0,
"read_only": 1
},
},
{
"fieldname": "column_break1",
"fieldtype": "Column Break",
"oldfieldtype": "Column Break",
"permlevel": 0,
"print_width": "50%",
"fieldname": "column_break1",
"fieldtype": "Column Break",
"oldfieldtype": "Column Break",
"permlevel": 0,
"print_width": "50%",
"width": "50%"
},
{
"fieldname": "last_login",
"fieldtype": "Read Only",
"hidden": 0,
"label": "Last Login",
"no_copy": 1,
"oldfieldname": "last_login",
"oldfieldtype": "Read Only",
"permlevel": 0,
"read_only": 1,
"reqd": 0,
},
{
"fieldname": "last_login",
"fieldtype": "Read Only",
"hidden": 0,
"label": "Last Login",
"no_copy": 1,
"oldfieldname": "last_login",
"oldfieldtype": "Read Only",
"permlevel": 0,
"read_only": 1,
"reqd": 0,
"search_index": 0
},
{
"fieldname": "last_ip",
"fieldtype": "Read Only",
"label": "Last IP",
"no_copy": 1,
"oldfieldname": "last_ip",
"oldfieldtype": "Read Only",
"permlevel": 0,
},
{
"fieldname": "last_ip",
"fieldtype": "Read Only",
"label": "Last IP",
"no_copy": 1,
"oldfieldname": "last_ip",
"oldfieldtype": "Read Only",
"permlevel": 0,
"read_only": 1
},
{
"description": "Stores the JSON of last known versions of various installed apps. It is used to show release notes.",
"fieldname": "last_known_versions",
"fieldtype": "Text",
"hidden": 1,
"label": "Last Known Versions",
"permlevel": 0,
"precision": "",
},
{
"description": "Stores the JSON of last known versions of various installed apps. It is used to show release notes.",
"fieldname": "last_known_versions",
"fieldtype": "Text",
"hidden": 1,
"label": "Last Known Versions",
"permlevel": 0,
"precision": "",
"read_only": 1
},
},
{
"fieldname": "third_party_authentication",
"fieldtype": "Section Break",
"label": "Third Party Authentication",
"fieldname": "third_party_authentication",
"fieldtype": "Section Break",
"label": "Third Party Authentication",
"permlevel": 1
},
},
{
"fieldname": "fb_username",
"fieldtype": "Data",
"label": "Facebook Username",
"no_copy": 1,
"permlevel": 0,
"fieldname": "fb_username",
"fieldtype": "Data",
"label": "Facebook Username",
"no_copy": 1,
"permlevel": 0,
"read_only": 1
},
},
{
"fieldname": "fb_userid",
"fieldtype": "Data",
"label": "Facebook User ID",
"no_copy": 1,
"permlevel": 0,
"fieldname": "fb_userid",
"fieldtype": "Data",
"label": "Facebook User ID",
"no_copy": 1,
"permlevel": 0,
"read_only": 1
},
},
{
"fieldname": "google_userid",
"fieldtype": "Data",
"label": "Google User ID",
"no_copy": 1,
"permlevel": 0,
"fieldname": "google_userid",
"fieldtype": "Data",
"label": "Google User ID",
"no_copy": 1,
"permlevel": 0,
"read_only": 1
},
},
{
"fieldname": "column_break_49",
"fieldtype": "Column Break",
"permlevel": 0,
"fieldname": "column_break_49",
"fieldtype": "Column Break",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "github_userid",
"fieldtype": "Data",
"label": "Github User ID",
"no_copy": 1,
"permlevel": 0,
"fieldname": "github_userid",
"fieldtype": "Data",
"label": "Github User ID",
"no_copy": 1,
"permlevel": 0,
"read_only": 1
},
},
{
"fieldname": "github_username",
"fieldtype": "Data",
"label": "Github Username",
"no_copy": 1,
"permlevel": 0,
"fieldname": "github_username",
"fieldtype": "Data",
"label": "Github Username",
"no_copy": 1,
"permlevel": 0,
"read_only": 1
}
],
"hide_heading": 0,
"hide_toolbar": 0,
"icon": "icon-user",
"idx": 1,
"issingle": 0,
"istable": 0,
"max_attachments": 5,
"modified": "2015-07-27 01:00:32.901851",
"modified_by": "Administrator",
"module": "Core",
"name": "User",
"owner": "Administrator",
],
"hide_heading": 0,
"hide_toolbar": 0,
"icon": "icon-user",
"idx": 1,
"issingle": 0,
"istable": 0,
"max_attachments": 5,
"modified": "2015-07-28 16:18:12.510213",
"modified_by": "Administrator",
"module": "Core",
"name": "User",
"owner": "Administrator",
"permissions": [
{
"create": 1,
"delete": 1,
"email": 1,
"permlevel": 0,
"print": 1,
"read": 1,
"report": 1,
"role": "System Manager",
"share": 1,
"submit": 0,
"create": 1,
"delete": 1,
"email": 1,
"permlevel": 0,
"print": 1,
"read": 1,
"report": 1,
"role": "System Manager",
"share": 1,
"submit": 0,
"write": 1
},
{
"amend": 0,
"cancel": 0,
"create": 0,
"delete": 0,
"permlevel": 1,
"read": 1,
"report": 1,
"role": "System Manager",
"submit": 0,
},
{
"amend": 0,
"cancel": 0,
"create": 0,
"delete": 0,
"permlevel": 1,
"read": 1,
"report": 1,
"role": "System Manager",
"submit": 0,
"write": 1
}
],
"read_only": 0,
],
"read_only": 0,
"search_fields": "first_name, last_name"
}
}

+ 2
- 2
frappe/core/doctype/version/version.json Datei anzeigen

@@ -3,7 +3,7 @@
"creation": "2014-02-20 17:22:37",
"docstatus": 0,
"doctype": "DocType",
"document_type": "Master",
"document_type": "Setup",
"fields": [
{
"fieldname": "ref_doctype",
@@ -33,7 +33,7 @@
],
"icon": "icon-copy",
"idx": 1,
"modified": "2014-08-05 01:23:37.541856",
"modified": "2015-07-28 16:18:12.706419",
"modified_by": "Administrator",
"module": "Core",
"name": "Version",


+ 2
- 2
frappe/desk/doctype/note/note.json Datei anzeigen

@@ -4,7 +4,7 @@
"description": "Note is a free page where users can share documents / notes",
"docstatus": 0,
"doctype": "DocType",
"document_type": "Transaction",
"document_type": "Document",
"fields": [
{
"fieldname": "title",
@@ -35,7 +35,7 @@
],
"icon": "icon-file-text",
"idx": 1,
"modified": "2015-02-06 00:44:06.475116",
"modified": "2015-07-28 16:18:12.301520",
"modified_by": "Administrator",
"module": "Desk",
"name": "Note",


+ 4
- 8
frappe/desk/moduleview.py Datei anzeigen

@@ -59,10 +59,10 @@ def build_standard_config(module, doctype_info):
data = []

add_section(data, _("Documents"), "icon-star",
[d for d in doctype_info if in_document_section(d)])
[d for d in doctype_info if d.document_type in ("Document", "Transaction")])

add_section(data, _("Setup"), "icon-cog",
[d for d in doctype_info if not in_document_section(d)])
[d for d in doctype_info if d.document_type in ("Master", "Setup", "")])

add_section(data, _("Standard Reports"), "icon-list",
get_report_list(module, is_standard="Yes"))
@@ -82,14 +82,10 @@ def add_section(data, label, icon, items):
def add_custom_doctypes(data, doctype_info):
"""Adds Custom DocTypes to modules setup via `config/desktop.py`."""
add_section(data, _("Documents"), "icon-star",
[d for d in doctype_info if (d.custom and in_document_section(d))])
[d for d in doctype_info if (d.custom and d.document_type in ("Document", "Transaction"))])

add_section(data, _("Setup"), "icon-cog",
[d for d in doctype_info if (d.custom and not in_document_section(d))])

def in_document_section(d):
"""Returns True if `document_type` property is one of `Master`, `Transaction` or not set."""
return d.document_type in ("Transaction", "Master", "")
[d for d in doctype_info if (d.custom and d.document_type in ("Setup", "Master", ""))])

def get_doctype_info(module):
"""Returns list of non child DocTypes for given module."""


+ 2
- 2
frappe/email/doctype/email_account/email_account.json Datei anzeigen

@@ -7,7 +7,7 @@
"custom": 0,
"docstatus": 0,
"doctype": "DocType",
"document_type": "Master",
"document_type": "Setup",
"fields": [
{
"fieldname": "email_settings",
@@ -429,7 +429,7 @@
"is_submittable": 0,
"issingle": 0,
"istable": 0,
"modified": "2015-07-16 10:11:06.466258",
"modified": "2015-07-28 16:18:12.116327",
"modified_by": "Administrator",
"module": "Email",
"name": "Email Account",


+ 2
- 7
frappe/email/doctype/standard_reply/standard_reply.json Datei anzeigen

@@ -4,7 +4,7 @@
"creation": "2014-06-19 05:20:26.331041",
"docstatus": 0,
"doctype": "DocType",
"document_type": "Transaction",
"document_type": "Document",
"fields": [
{
"fieldname": "subject",
@@ -33,18 +33,13 @@
}
],
"icon": "icon-comment",
"modified": "2015-02-05 05:11:46.922356",
"modified": "2015-07-28 16:18:12.432775",
"modified_by": "Administrator",
"module": "Email",
"name": "Standard Reply",
"name_case": "",
"owner": "Administrator",
"permissions": [
{
"permlevel": 0,
"read": 1,
"role": "All"
},
{
"apply_user_permissions": 1,
"create": 1,


+ 2
- 2
frappe/geo/doctype/country/country.json Datei anzeigen

@@ -5,7 +5,7 @@
"creation": "2013-01-19 10:23:30",
"docstatus": 0,
"doctype": "DocType",
"document_type": "Master",
"document_type": "Setup",
"fields": [
{
"fieldname": "country_name",
@@ -42,7 +42,7 @@
"icon": "icon-globe",
"idx": 1,
"in_create": 0,
"modified": "2015-02-05 05:11:36.234753",
"modified": "2015-07-28 16:18:11.855617",
"modified_by": "Administrator",
"module": "Geo",
"name": "Country",


+ 30
- 2
frappe/installer.py Datei anzeigen

@@ -188,7 +188,7 @@ def make_conf(db_name=None, db_password=None, site_config=None):

def make_site_config(db_name=None, db_password=None, site_config=None):
frappe.create_folder(os.path.join(frappe.local.site_path))
site_file = os.path.join(frappe.local.site_path, "site_config.json")
site_file = get_site_config_path()

if not os.path.exists(site_file):
if not (site_config and isinstance(site_config, dict)):
@@ -197,6 +197,34 @@ def make_site_config(db_name=None, db_password=None, site_config=None):
with open(site_file, "w") as f:
f.write(json.dumps(site_config, indent=1, sort_keys=True))

def update_site_config(key, value):
"""Update a value in site_config"""
with open(get_site_config_path(), "r") as f:
site_config = json.loads(f.read())

# int
try:
value = int(value)
except ValueError:
pass

# boolean
if value in ("False", "True"):
value = eval(value)

# remove key if value is None
if value == "None":
if key in site_config:
del site_config[key]
else:
site_config[key] = value

with open(get_site_config_path(), "w") as f:
f.write(json.dumps(site_config, indent=1, sort_keys=True))

def get_site_config_path():
return os.path.join(frappe.local.site_path, "site_config.json")

def get_conf_params(db_name=None, db_password=None):
if not db_name:
db_name = raw_input("Database Name: ")
@@ -215,7 +243,7 @@ def make_site_dirs():
for dir_path in (
os.path.join(site_private_path, 'backups'),
os.path.join(site_public_path, 'files'),
os.path.join(site_public_path, 'task-logs')):
os.path.join(frappe.local.site_path, 'task-logs')):
if not os.path.exists(dir_path):
os.makedirs(dir_path)
locks_dir = frappe.get_site_path('locks')


+ 1
- 0
frappe/patches.txt Datei anzeigen

@@ -85,3 +85,4 @@ execute:frappe.permissions.reset_perms("DocType")
execute:frappe.db.sql("delete from `tabProperty Setter` where `property` = 'idx'")

frappe.patches.v6_0.make_task_log_folder
frappe.patches.v6_0.document_type_rename

+ 7
- 0
frappe/patches/v6_0/document_type_rename.py Datei anzeigen

@@ -0,0 +1,7 @@
import frappe

def execute():
frappe.db.sql("""update tabDocType set document_type='Document'
where document_type='Transaction'""")
frappe.db.sql("""update tabDocType set document_type='Setup'
where document_type='Master'""")

+ 1
- 1
frappe/public/js/frappe/form/layout.js Datei anzeigen

@@ -85,7 +85,7 @@ frappe.ui.form.Layout = Class.extend({

this.section = null;
this.column = null;
if(this.fields[0] && this.fields[0].fieldtype!="Section Break") {
if((this.fields[0] && this.fields[0].fieldtype!="Section Break") || !this.fields.length) {
this.make_section();
}
$.each(this.fields, function(i, df) {


+ 38
- 22
frappe/public/js/frappe/form/save.js Datei anzeigen

@@ -18,21 +18,23 @@ frappe.ui.form.save = function(frm, action, callback, btn) {
var freeze_message = working_label ? __(working_label) : "";

var save = function() {
check_name();
if(check_mandatory()) {
_call({
method: "frappe.desk.form.save.savedocs",
args: { doc: frm.doc, action:action},
callback: function(r) {
$(document).trigger("save", [frm.doc]);
callback(r);
},
btn: btn,
freeze_message: freeze_message
});
} else {
$(btn).prop("disabled", false);
}
check_name(function() {
if(check_mandatory()) {
_call({
method: "frappe.desk.form.save.savedocs",
args: { doc: frm.doc, action:action},
callback: function(r) {
$(document).trigger("save", [frm.doc]);
callback(r);
},
btn: btn,
freeze_message: freeze_message
});
} else {
$(btn).prop("disabled", false);
}
});

};

var cancel = function() {
@@ -48,19 +50,33 @@ frappe.ui.form.save = function(frm, action, callback, btn) {
});
};

var check_name = function() {
var check_name = function(callback) {
var doc = frm.doc;
var meta = locals.DocType[doc.doctype];
if(doc.__islocal && (meta && meta.autoname
&& meta.autoname.toLowerCase()=='prompt')) {
var newname = prompt('Enter the name of the new '+ doc.doctype, '');
if(newname) {
doc.__newname = strip(newname);
} else {
msgprint(__("Name is required"));
var d = frappe.prompt(__("Name"), function(values) {
var newname = values.value;
if(newname) {
doc.__newname = strip(newname);
} else {
msgprint(__("Name is required"));
throw "name required";
}

callback();

}, __('Enter the name of the new {0}', [doc.doctype]), __("Create"));

if(doc.__newname) {
d.set_value("value", doc.__newname);
}

d.onhide = function() {
$(btn).prop("disabled", false);
throw "name required";
}
} else {
callback();
}
};



+ 3
- 0
frappe/public/js/frappe/form/toolbar.js Datei anzeigen

@@ -220,6 +220,9 @@ frappe.ui.form.Toolbar = Class.extend({
} else {
var click = {
"Save": function() {
if(!frappe.dom.is_touchscreen()) {
show_alert(__("You can also use Ctrl+S to Save"));
}
me.frm.save('Save', null, this);
},
"Submit": function() {


+ 12
- 10
frappe/public/js/frappe/ui/dialog.js Datei anzeigen

@@ -48,19 +48,21 @@ frappe.ui.Dialog = frappe.ui.FieldGroup.extend({
me.display = true;
cur_dialog = me;
frappe.ui.open_dialogs.push(me);
var first = $(me.body).find('.modal-content :input:first');
if(first.length && first.attr("data-fieldtype")!="Date") {
try {
first.get(0).focus();
} catch(e) {
console.log("Dialog: unable to focus on first input: " + e);
}
}
me.focus_on_first_input();
me.on_page_show && me.on_page_show();
})

});

},
focus_on_first_input: function() {
var first = $(this.body).find(':input:first');
if(first.length && first.attr("data-fieldtype")!="Date") {
try {
first.get(0).focus();
} catch(e) {
console.log("Dialog: unable to focus on first input: " + e);
}
}
},
get_primary_btn: function() {
return this.$wrapper.find(".modal-header .btn-primary");
},


+ 8
- 0
frappe/public/js/frappe/ui/messages.js Datei anzeigen

@@ -44,6 +44,14 @@ frappe.confirm = function(message, ifyes, ifno) {
}

frappe.prompt = function(fields, callback, title, primary_label) {
if (typeof fields === "string") {
fields = [{
label: fields,
fieldname: "value",
fieldtype: "Data",
reqd: 1
}];
}
if(!$.isArray(fields)) fields = [fields];
var d = new frappe.ui.Dialog({
fields: fields,


+ 1
- 2
frappe/public/js/legacy/form.js Datei anzeigen

@@ -273,7 +273,7 @@ _f.Frm.prototype.rename_notify = function(dt, old, name) {
return;

// cleanup
if(this && this.opendocs[old]) {
if(this && this.opendocs[old] && frappe.meta.docfield_copy[dt]) {
// delete docfield copy
frappe.meta.docfield_copy[dt][name] = frappe.meta.docfield_copy[dt][old];
delete frappe.meta.docfield_copy[dt][old];
@@ -820,4 +820,3 @@ _f.Frm.prototype.validate_form_action = function(action) {
_f.Frm.prototype.get_handlers = function(fieldname, doctype, docname) {
return this.script_manager.get_handlers(fieldname, doctype || this.doctype, docname || this.docname)
}


+ 2
- 2
frappe/website/doctype/blog_category/blog_category.json Datei anzeigen

@@ -4,7 +4,7 @@
"creation": "2013-03-08 09:41:11",
"docstatus": 0,
"doctype": "DocType",
"document_type": "Master",
"document_type": "Setup",
"fields": [
{
"fieldname": "category_name",
@@ -49,7 +49,7 @@
],
"icon": "icon-tag",
"idx": 1,
"modified": "2015-02-05 05:11:34.877605",
"modified": "2015-07-28 16:18:11.486847",
"modified_by": "Administrator",
"module": "Website",
"name": "Blog Category",


+ 2
- 2
frappe/website/doctype/blogger/blogger.json Datei anzeigen

@@ -5,7 +5,7 @@
"description": "User ID of a Blogger",
"docstatus": 0,
"doctype": "DocType",
"document_type": "Master",
"document_type": "Setup",
"fields": [
{
"fieldname": "disabled",
@@ -61,7 +61,7 @@
"icon": "icon-user",
"idx": 1,
"max_attachments": 1,
"modified": "2015-02-19 09:29:25.836280",
"modified": "2015-07-28 16:18:11.567110",
"modified_by": "Administrator",
"module": "Website",
"name": "Blogger",


+ 3
- 3
frappe/website/doctype/web_form/web_form.json Datei anzeigen

@@ -7,7 +7,7 @@
"custom": 0,
"docstatus": 0,
"doctype": "DocType",
"document_type": "Transaction",
"document_type": "Document",
"fields": [
{
"allow_on_submit": 0,
@@ -230,7 +230,7 @@
"is_submittable": 0,
"issingle": 0,
"istable": 0,
"modified": "2015-02-05 05:11:48.897157",
"modified": "2015-07-28 16:18:12.772231",
"modified_by": "Administrator",
"module": "Website",
"name": "Web Form",
@@ -262,4 +262,4 @@
"sort_field": "modified",
"sort_order": "DESC",
"title_field": "title"
}
}

+ 2
- 2
frappe/website/doctype/web_page/web_page.json Datei anzeigen

@@ -3,7 +3,7 @@
"description": "Page to show on the website\n",
"docstatus": 0,
"doctype": "DocType",
"document_type": "Transaction",
"document_type": "Document",
"fields": [
{
"fieldname": "section_title",
@@ -200,7 +200,7 @@
"icon": "icon-file-alt",
"idx": 1,
"max_attachments": 20,
"modified": "2015-07-22 12:38:08.696692",
"modified": "2015-07-28 16:18:12.887565",
"modified_by": "Administrator",
"module": "Website",
"name": "Web Page",


+ 2
- 2
frappe/website/doctype/website_slideshow/website_slideshow.json Datei anzeigen

@@ -4,7 +4,7 @@
"description": "Slideshow like display for the website",
"docstatus": 0,
"doctype": "DocType",
"document_type": "Transaction",
"document_type": "Document",
"fields": [
{
"fieldname": "slideshow_name",
@@ -42,7 +42,7 @@
"icon": "icon-play",
"idx": 1,
"max_attachments": 10,
"modified": "2015-02-20 05:04:19.614170",
"modified": "2015-07-28 16:18:13.013029",
"modified_by": "Administrator",
"module": "Website",
"name": "Website Slideshow",


+ 238
- 238
frappe/website/doctype/website_theme/website_theme.json Datei anzeigen

@@ -1,304 +1,304 @@
{
"allow_copy": 0,
"allow_import": 1,
"allow_rename": 0,
"autoname": "field:theme",
"creation": "2015-02-18 12:46:38.168929",
"custom": 0,
"docstatus": 0,
"doctype": "DocType",
"document_type": "Master",
"allow_copy": 0,
"allow_import": 1,
"allow_rename": 0,
"autoname": "field:theme",
"creation": "2015-02-18 12:46:38.168929",
"custom": 0,
"docstatus": 0,
"doctype": "DocType",
"document_type": "Setup",
"fields": [
{
"allow_on_submit": 0,
"fieldname": "theme",
"fieldtype": "Data",
"hidden": 0,
"ignore_user_permissions": 0,
"in_filter": 0,
"in_list_view": 0,
"label": "Theme",
"no_copy": 0,
"permlevel": 0,
"precision": "",
"print_hide": 0,
"read_only": 0,
"report_hide": 0,
"reqd": 1,
"search_index": 1,
"allow_on_submit": 0,
"fieldname": "theme",
"fieldtype": "Data",
"hidden": 0,
"ignore_user_permissions": 0,
"in_filter": 0,
"in_list_view": 0,
"label": "Theme",
"no_copy": 0,
"permlevel": 0,
"precision": "",
"print_hide": 0,
"read_only": 0,
"report_hide": 0,
"reqd": 1,
"search_index": 1,
"set_only_once": 0
},
},
{
"allow_on_submit": 0,
"default": "Website",
"fieldname": "module",
"fieldtype": "Link",
"hidden": 0,
"ignore_user_permissions": 0,
"in_filter": 0,
"in_list_view": 0,
"label": "Module",
"no_copy": 0,
"options": "Module Def",
"permlevel": 0,
"precision": "",
"print_hide": 0,
"read_only": 0,
"report_hide": 0,
"reqd": 1,
"search_index": 0,
"allow_on_submit": 0,
"default": "Website",
"fieldname": "module",
"fieldtype": "Link",
"hidden": 0,
"ignore_user_permissions": 0,
"in_filter": 0,
"in_list_view": 0,
"label": "Module",
"no_copy": 0,
"options": "Module Def",
"permlevel": 0,
"precision": "",
"print_hide": 0,
"read_only": 0,
"report_hide": 0,
"reqd": 1,
"search_index": 0,
"set_only_once": 0
},
},
{
"default": "1",
"description": "This must be checked if the below style settings are applicable",
"fieldname": "apply_style",
"fieldtype": "Check",
"hidden": 0,
"label": "Apply Style",
"permlevel": 0,
"default": "1",
"description": "This must be checked if the below style settings are applicable",
"fieldname": "apply_style",
"fieldtype": "Check",
"hidden": 0,
"label": "Apply Style",
"permlevel": 0,
"precision": ""
},
},
{
"default": "1",
"fieldname": "custom",
"fieldtype": "Check",
"label": "Custom?",
"permlevel": 0,
"default": "1",
"fieldname": "custom",
"fieldtype": "Check",
"label": "Custom?",
"permlevel": 0,
"precision": ""
},
},
{
"allow_on_submit": 0,
"fieldname": "column_break_2",
"fieldtype": "Column Break",
"hidden": 0,
"ignore_user_permissions": 0,
"in_filter": 0,
"in_list_view": 0,
"no_copy": 0,
"permlevel": 0,
"precision": "",
"print_hide": 0,
"read_only": 0,
"report_hide": 0,
"reqd": 0,
"search_index": 0,
"allow_on_submit": 0,
"fieldname": "column_break_2",
"fieldtype": "Column Break",
"hidden": 0,
"ignore_user_permissions": 0,
"in_filter": 0,
"in_list_view": 0,
"no_copy": 0,
"permlevel": 0,
"precision": "",
"print_hide": 0,
"read_only": 0,
"report_hide": 0,
"reqd": 0,
"search_index": 0,
"set_only_once": 0
},
},
{
"description": "Link to your Bootstrap theme",
"fieldname": "bootstrap",
"fieldtype": "Small Text",
"label": "Link to Bootstrap CSS",
"permlevel": 0,
"description": "Link to your Bootstrap theme",
"fieldname": "bootstrap",
"fieldtype": "Small Text",
"label": "Link to Bootstrap CSS",
"permlevel": 0,
"precision": ""
},
},
{
"depends_on": "apply_style",
"fieldname": "section_break_14",
"fieldtype": "Section Break",
"permlevel": 0,
"depends_on": "apply_style",
"fieldname": "section_break_14",
"fieldtype": "Section Break",
"permlevel": 0,
"precision": ""
},
},
{
"default": "",
"fieldname": "font_size",
"fieldtype": "Select",
"label": "Font Size",
"options": "\n12px\n13px\n14px\n15px\n16px\n17px\n18px",
"permlevel": 0,
"default": "",
"fieldname": "font_size",
"fieldtype": "Select",
"label": "Font Size",
"options": "\n12px\n13px\n14px\n15px\n16px\n17px\n18px",
"permlevel": 0,
"precision": ""
},
},
{
"description": "Add the name of a \"Google Web Font\" e.g. \"Open Sans\"",
"fieldname": "text_webfont",
"fieldtype": "Data",
"label": "Google Font (Text)",
"permlevel": 0,
"description": "Add the name of a \"Google Web Font\" e.g. \"Open Sans\"",
"fieldname": "text_webfont",
"fieldtype": "Data",
"label": "Google Font (Text)",
"permlevel": 0,
"precision": ""
},
},
{
"description": "Add the name of a \"Google Web Font\" e.g. \"Open Sans\"",
"fieldname": "heading_webfont",
"fieldtype": "Data",
"label": "Google Font (Heading)",
"permlevel": 0,
"description": "Add the name of a \"Google Web Font\" e.g. \"Open Sans\"",
"fieldname": "heading_webfont",
"fieldtype": "Data",
"label": "Google Font (Heading)",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "column_break_18",
"fieldtype": "Column Break",
"permlevel": 0,
"fieldname": "column_break_18",
"fieldtype": "Column Break",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "text_color",
"fieldtype": "Data",
"label": "Text Color",
"permlevel": 0,
"fieldname": "text_color",
"fieldtype": "Data",
"label": "Text Color",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "link_color",
"fieldtype": "Data",
"label": "Link Color",
"permlevel": 0,
"fieldname": "link_color",
"fieldtype": "Data",
"label": "Link Color",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "heading_style",
"fieldtype": "Select",
"label": "Heading Style",
"options": "\nUPPERCASE\nTitle Case\nlowercase",
"permlevel": 0,
"fieldname": "heading_style",
"fieldtype": "Select",
"label": "Heading Style",
"options": "\nUPPERCASE\nTitle Case\nlowercase",
"permlevel": 0,
"precision": ""
},
},
{
"depends_on": "apply_style",
"fieldname": "section_break_8",
"fieldtype": "Section Break",
"permlevel": 0,
"depends_on": "apply_style",
"fieldname": "section_break_8",
"fieldtype": "Section Break",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "top_bar_color",
"fieldtype": "Data",
"label": "Top Bar Color",
"permlevel": 0,
"fieldname": "top_bar_color",
"fieldtype": "Data",
"label": "Top Bar Color",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "top_bar_text_color",
"fieldtype": "Data",
"label": "Top Bar Text Color",
"permlevel": 0,
"fieldname": "top_bar_text_color",
"fieldtype": "Data",
"label": "Top Bar Text Color",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "no_sidebar",
"fieldtype": "Check",
"label": "Hide Sidebar",
"permlevel": 0,
"fieldname": "no_sidebar",
"fieldtype": "Check",
"label": "Hide Sidebar",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "column_break_11",
"fieldtype": "Column Break",
"permlevel": 0,
"fieldname": "column_break_11",
"fieldtype": "Column Break",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "footer_color",
"fieldtype": "Data",
"label": "Footer Color",
"permlevel": 0,
"fieldname": "footer_color",
"fieldtype": "Data",
"label": "Footer Color",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "footer_text_color",
"fieldtype": "Data",
"label": "Footer Text Color",
"permlevel": 0,
"fieldname": "footer_text_color",
"fieldtype": "Data",
"label": "Footer Text Color",
"permlevel": 0,
"precision": ""
},
},
{
"depends_on": "apply_style",
"fieldname": "section_break_4",
"fieldtype": "Section Break",
"permlevel": 0,
"depends_on": "apply_style",
"fieldname": "section_break_4",
"fieldtype": "Section Break",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "background_color",
"fieldtype": "Data",
"label": "Background Color",
"permlevel": 0,
"fieldname": "background_color",
"fieldtype": "Data",
"label": "Background Color",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "column_break_6",
"fieldtype": "Column Break",
"permlevel": 0,
"fieldname": "column_break_6",
"fieldtype": "Column Break",
"permlevel": 0,
"precision": ""
},
},
{
"description": "If image is selected, color will be ignored.",
"fieldname": "background_image",
"fieldtype": "Attach Image",
"label": "Background Image",
"permlevel": 0,
"description": "If image is selected, color will be ignored.",
"fieldname": "background_image",
"fieldtype": "Attach Image",
"label": "Background Image",
"permlevel": 0,
"precision": ""
},
},
{
"depends_on": "",
"fieldname": "section_break_21",
"fieldtype": "Section Break",
"permlevel": 0,
"depends_on": "",
"fieldname": "section_break_21",
"fieldtype": "Section Break",
"permlevel": 0,
"precision": ""
},
},
{
"depends_on": "apply_style",
"description": "",
"fieldname": "css",
"fieldtype": "Code",
"label": "Style using CSS",
"permlevel": 0,
"depends_on": "apply_style",
"description": "",
"fieldname": "css",
"fieldtype": "Code",
"label": "Style using CSS",
"permlevel": 0,
"precision": ""
},
},
{
"fieldname": "js",
"fieldtype": "Code",
"label": "JavaScript",
"permlevel": 0,
"fieldname": "js",
"fieldtype": "Code",
"label": "JavaScript",
"permlevel": 0,
"precision": ""
}
],
"hide_heading": 0,
"hide_toolbar": 0,
"in_create": 0,
"in_dialog": 0,
"is_submittable": 0,
"issingle": 0,
"istable": 0,
"modified": "2015-07-27 01:00:32.901851",
"modified_by": "Administrator",
"module": "Website",
"name": "Website Theme",
"name_case": "",
"owner": "Administrator",
],
"hide_heading": 0,
"hide_toolbar": 0,
"in_create": 0,
"in_dialog": 0,
"is_submittable": 0,
"issingle": 0,
"istable": 0,
"modified": "2015-07-28 16:18:13.081330",
"modified_by": "Administrator",
"module": "Website",
"name": "Website Theme",
"name_case": "",
"owner": "Administrator",
"permissions": [
{
"create": 1,
"delete": 1,
"permlevel": 0,
"read": 1,
"role": "Website Manager",
"create": 1,
"delete": 1,
"permlevel": 0,
"read": 1,
"role": "Website Manager",
"write": 1
},
},
{
"amend": 0,
"apply_user_permissions": 0,
"cancel": 0,
"create": 1,
"delete": 1,
"email": 0,
"export": 1,
"import": 1,
"permlevel": 0,
"print": 0,
"read": 1,
"report": 0,
"role": "Administrator",
"set_user_permissions": 0,
"share": 0,
"submit": 0,
"amend": 0,
"apply_user_permissions": 0,
"cancel": 0,
"create": 1,
"delete": 1,
"email": 0,
"export": 1,
"import": 1,
"permlevel": 0,
"print": 0,
"read": 1,
"report": 0,
"role": "Administrator",
"set_user_permissions": 0,
"share": 0,
"submit": 0,
"write": 1
}
],
"read_only": 0,
"read_only_onload": 0,
"search_fields": "",
"sort_field": "modified",
"sort_order": "DESC",
],
"read_only": 0,
"read_only_onload": 0,
"search_fields": "",
"sort_field": "modified",
"sort_order": "DESC",
"title_field": ""
}
}

+ 76
- 76
frappe/workflow/doctype/workflow/workflow.json Datei anzeigen

@@ -1,100 +1,100 @@
{
"allow_rename": 1,
"autoname": "field:workflow_name",
"creation": "2012-12-28 10:49:55",
"description": "Defines workflow states and rules for a document.",
"docstatus": 0,
"doctype": "DocType",
"document_type": "Transaction",
"allow_rename": 1,
"autoname": "field:workflow_name",
"creation": "2012-12-28 10:49:55",
"description": "Defines workflow states and rules for a document.",
"docstatus": 0,
"doctype": "DocType",
"document_type": "Document",
"fields": [
{
"fieldname": "workflow_name",
"fieldtype": "Data",
"in_list_view": 0,
"label": "Workflow Name",
"permlevel": 0,
"read_only": 0,
"fieldname": "workflow_name",
"fieldtype": "Data",
"in_list_view": 0,
"label": "Workflow Name",
"permlevel": 0,
"read_only": 0,
"reqd": 1
},
},
{
"description": "DocType on which this Workflow is applicable.",
"fieldname": "document_type",
"fieldtype": "Link",
"in_list_view": 0,
"label": "Document Type",
"options": "DocType",
"permlevel": 0,
"description": "DocType on which this Workflow is applicable.",
"fieldname": "document_type",
"fieldtype": "Link",
"in_list_view": 0,
"label": "Document Type",
"options": "DocType",
"permlevel": 0,
"reqd": 1
},
},
{
"description": "If checked, all other workflows become inactive.",
"fieldname": "is_active",
"fieldtype": "Check",
"in_list_view": 0,
"label": "Is Active",
"description": "If checked, all other workflows become inactive.",
"fieldname": "is_active",
"fieldtype": "Check",
"in_list_view": 0,
"label": "Is Active",
"permlevel": 0
},
},
{
"description": "Different \"States\" this document can exist in. Like \"Open\", \"Pending Approval\" etc.",
"fieldname": "states_head",
"fieldtype": "Section Break",
"label": "States",
"description": "Different \"States\" this document can exist in. Like \"Open\", \"Pending Approval\" etc.",
"fieldname": "states_head",
"fieldtype": "Section Break",
"label": "States",
"permlevel": 0
},
},
{
"description": "All possible Workflow States and roles of the workflow. \nDocstatus Options: 0 is\"Saved\", 1 is \"Submitted\" and 2 is \"Cancelled\"",
"fieldname": "states",
"fieldtype": "Table",
"label": "Document States",
"options": "Workflow Document State",
"permlevel": 0,
"description": "All possible Workflow States and roles of the workflow. \nDocstatus Options: 0 is\"Saved\", 1 is \"Submitted\" and 2 is \"Cancelled\"",
"fieldname": "states",
"fieldtype": "Table",
"label": "Document States",
"options": "Workflow Document State",
"permlevel": 0,
"reqd": 1
},
},
{
"description": "Rules for how states are transitions, like next state and which role is allowed to change state etc.",
"fieldname": "transition_rules",
"fieldtype": "Section Break",
"label": "Transition Rules",
"description": "Rules for how states are transitions, like next state and which role is allowed to change state etc.",
"fieldname": "transition_rules",
"fieldtype": "Section Break",
"label": "Transition Rules",
"permlevel": 0
},
},
{
"description": "Rules defining transition of state in the workflow.",
"fieldname": "transitions",
"fieldtype": "Table",
"label": "Transitions",
"options": "Workflow Transition",
"permlevel": 0,
"description": "Rules defining transition of state in the workflow.",
"fieldname": "transitions",
"fieldtype": "Table",
"label": "Transitions",
"options": "Workflow Transition",
"permlevel": 0,
"reqd": 1
},
},
{
"default": "workflow_state",
"description": "Field that represents the Workflow State of the transaction (if field is not present, a new hidden Custom Field will be created)",
"fieldname": "workflow_state_field",
"fieldtype": "Data",
"label": "Workflow State Field",
"default": "workflow_state",
"description": "Field that represents the Workflow State of the transaction (if field is not present, a new hidden Custom Field will be created)",
"fieldname": "workflow_state_field",
"fieldtype": "Data",
"label": "Workflow State Field",
"permlevel": 0
}
],
"icon": "icon-random",
"idx": 1,
"modified": "2015-07-27 01:00:32.901851",
"modified_by": "Administrator",
"module": "Workflow",
"name": "Workflow",
"owner": "Administrator",
],
"icon": "icon-random",
"idx": 1,
"modified": "2015-07-28 16:18:13.196607",
"modified_by": "Administrator",
"module": "Workflow",
"name": "Workflow",
"owner": "Administrator",
"permissions": [
{
"cancel": 0,
"create": 1,
"delete": 1,
"email": 1,
"permlevel": 0,
"print": 1,
"read": 1,
"role": "System Manager",
"share": 1,
"submit": 0,
"cancel": 0,
"create": 1,
"delete": 1,
"email": 1,
"permlevel": 0,
"print": 1,
"read": 1,
"role": "System Manager",
"share": 1,
"submit": 0,
"write": 1
}
]
}
}

+ 59
- 59
frappe/workflow/doctype/workflow_document_state/workflow_document_state.json Datei anzeigen

@@ -1,75 +1,75 @@
{
"allow_import": 1,
"creation": "2013-02-22 01:27:36",
"description": "Represents the states allowed in one document and role assigned to change the state.",
"docstatus": 0,
"doctype": "DocType",
"document_type": "Master",
"allow_import": 1,
"creation": "2013-02-22 01:27:36",
"description": "Represents the states allowed in one document and role assigned to change the state.",
"docstatus": 0,
"doctype": "DocType",
"document_type": "Setup",
"fields": [
{
"fieldname": "state",
"fieldtype": "Link",
"in_list_view": 1,
"label": "State",
"options": "Workflow State",
"permlevel": 0,
"print_width": "160px",
"reqd": 1,
"fieldname": "state",
"fieldtype": "Link",
"in_list_view": 1,
"label": "State",
"options": "Workflow State",
"permlevel": 0,
"print_width": "160px",
"reqd": 1,
"width": "160px"
},
},
{
"description": "0 - Draft; 1 - Submitted; 2 - Cancelled",
"fieldname": "doc_status",
"fieldtype": "Select",
"in_list_view": 1,
"label": "Doc Status",
"options": "0\n1\n2",
"permlevel": 0,
"print_width": "80px",
"description": "0 - Draft; 1 - Submitted; 2 - Cancelled",
"fieldname": "doc_status",
"fieldtype": "Select",
"in_list_view": 1,
"label": "Doc Status",
"options": "0\n1\n2",
"permlevel": 0,
"print_width": "80px",
"width": "80px"
},
},
{
"fieldname": "update_field",
"fieldtype": "Select",
"in_list_view": 1,
"label": "Update Field",
"fieldname": "update_field",
"fieldtype": "Select",
"in_list_view": 1,
"label": "Update Field",
"permlevel": 0
},
},
{
"fieldname": "update_value",
"fieldtype": "Data",
"in_list_view": 1,
"label": "Update Value",
"fieldname": "update_value",
"fieldtype": "Data",
"in_list_view": 1,
"label": "Update Value",
"permlevel": 0
},
},
{
"fieldname": "allow_edit",
"fieldtype": "Link",
"in_list_view": 1,
"label": "Only Allow Edit For",
"options": "Role",
"permlevel": 0,
"print_width": "160px",
"reqd": 1,
"fieldname": "allow_edit",
"fieldtype": "Link",
"in_list_view": 1,
"label": "Only Allow Edit For",
"options": "Role",
"permlevel": 0,
"print_width": "160px",
"reqd": 1,
"width": "160px"
},
},
{
"fieldname": "message",
"fieldtype": "Text",
"in_list_view": 1,
"label": "Message",
"permlevel": 0,
"print_width": "160px",
"reqd": 0,
"fieldname": "message",
"fieldtype": "Text",
"in_list_view": 1,
"label": "Message",
"permlevel": 0,
"print_width": "160px",
"reqd": 0,
"width": "160px"
}
],
"idx": 1,
"istable": 1,
"modified": "2014-05-27 06:35:01.070158",
"modified_by": "Administrator",
"module": "Workflow",
"name": "Workflow Document State",
"owner": "Administrator",
],
"idx": 1,
"istable": 1,
"modified": "2015-07-28 16:18:13.257862",
"modified_by": "Administrator",
"module": "Workflow",
"name": "Workflow Document State",
"owner": "Administrator",
"permissions": []
}
}

+ 2
- 2
frappe/workflow/doctype/workflow_state/workflow_state.json Datei anzeigen

@@ -5,7 +5,7 @@
"description": "Workflow state represents the current state of a document.",
"docstatus": 0,
"doctype": "DocType",
"document_type": "Master",
"document_type": "Setup",
"fields": [
{
"fieldname": "workflow_state_name",
@@ -36,7 +36,7 @@
],
"icon": "icon-flag",
"idx": 1,
"modified": "2015-05-27 02:51:01.978973",
"modified": "2015-07-28 16:18:13.320514",
"modified_by": "Administrator",
"module": "Workflow",
"name": "Workflow State",


Laden…
Abbrechen
Speichern