diff --git a/foundation/erpnext_foundation/doctype/foundation_fellowship/foundation_fellowship.json b/foundation/erpnext_foundation/doctype/foundation_fellowship/foundation_fellowship.json index 97510c3a..b74cfafc 100644 --- a/foundation/erpnext_foundation/doctype/foundation_fellowship/foundation_fellowship.json +++ b/foundation/erpnext_foundation/doctype/foundation_fellowship/foundation_fellowship.json @@ -377,8 +377,8 @@ "bold": 0, "collapsible": 0, "columns": 0, - "fieldname": "discuss_ids", - "fieldtype": "Small Text", + "fieldname": "discuss_id", + "fieldtype": "Data", "hidden": 0, "ignore_user_permissions": 0, "ignore_xss_filter": 0, @@ -386,7 +386,7 @@ "in_global_search": 0, "in_list_view": 0, "in_standard_filter": 0, - "label": "Discuss IDs", + "label": "Discuss ID", "length": 0, "no_copy": 0, "permlevel": 0, @@ -504,7 +504,7 @@ "issingle": 0, "istable": 0, "max_attachments": 0, - "modified": "2017-10-27 05:04:34.941231", + "modified": "2017-10-27 05:14:36.189151", "modified_by": "Administrator", "module": "ERPNext Foundation", "name": "Foundation Fellowship", diff --git a/foundation/erpnext_foundation/doctype/foundation_fellowship/foundation_fellowship.py b/foundation/erpnext_foundation/doctype/foundation_fellowship/foundation_fellowship.py index d0522229..52019838 100644 --- a/foundation/erpnext_foundation/doctype/foundation_fellowship/foundation_fellowship.py +++ b/foundation/erpnext_foundation/doctype/foundation_fellowship/foundation_fellowship.py @@ -7,4 +7,23 @@ import frappe from frappe.website.website_generator import WebsiteGenerator class FoundationFellowship(WebsiteGenerator): - pass + _website = frappe._dict( + condition_field = "show_in_website", + ) + def validate(self): + if not self.route: + self.route = 'foundation-fellow/' + self.scrub(self.name) + + def get_context(self, context): + context.no_cache = True + context.parents = [dict(label='View All Foundation Fellows', + route='foundation-fellow', title='View All foundation fellows')] + + + +def get_list_context(context): + context.allow_guest = True + context.no_cache = True + context.no_breadcrumbs = True + context.order_by = 'creation desc' + context.introduction = '

Following are the Foundation Fellows

' \ No newline at end of file diff --git a/foundation/erpnext_foundation/doctype/foundation_fellowship/templates/foundation_fellowship.html b/foundation/erpnext_foundation/doctype/foundation_fellowship/templates/foundation_fellowship.html index db123090..c733dd1b 100644 --- a/foundation/erpnext_foundation/doctype/foundation_fellowship/templates/foundation_fellowship.html +++ b/foundation/erpnext_foundation/doctype/foundation_fellowship/templates/foundation_fellowship.html @@ -1,7 +1,61 @@ {% extends "templates/web.html" %} -{% block page_content %} -

{{ title }}

-{% endblock %} +{% from "foundation/templates/includes/macros.html" import media %} - \ No newline at end of file +{% block page_content %} +

{{ title }}

+
+
+
+ + + +
+
+ {{ introduction }} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Country{{ country }}
Address{{ (address or '').replace('\n', '
') }}
Phone{{ phone }}
Email + {{ email }}
Disscuss Id{{ discuss_id }}
Github Id{{ github_id }}
Website{{ website }}
+ +
+
+
+
+ {{ details }} +
+
+

Contact {{ title }}

+
+ +{% endblock %} diff --git a/foundation/erpnext_foundation/doctype/foundation_fellowship/templates/foundation_fellowship_row.html b/foundation/erpnext_foundation/doctype/foundation_fellowship/templates/foundation_fellowship_row.html index 2b999819..049a778b 100644 --- a/foundation/erpnext_foundation/doctype/foundation_fellowship/templates/foundation_fellowship_row.html +++ b/foundation/erpnext_foundation/doctype/foundation_fellowship/templates/foundation_fellowship_row.html @@ -1,4 +1,11 @@ -
- {{ title }} +
+ +

{{ doc.title }}

+

+ {{ frappe.format_date(doc.creation) }} + {{ doc.country }} + +

+
- \ No newline at end of file diff --git a/foundation/hooks.py b/foundation/hooks.py index bb3156d0..b663c621 100644 --- a/foundation/hooks.py +++ b/foundation/hooks.py @@ -43,15 +43,18 @@ website_context = { "copyright": "ERPNext Open Source Software Foundation", "footer_address": "
ERPNext is and will always be 100% Open Source", "top_bar_items": [ - {"label": "Docs", "url": "/docs", "right": 1}, - {"label": "Services", "url": "/service-providers", "right": 1}, - {"label": "Jobs", "url": "/erpnext-jobs", "right": 1}, - {"label": "Chapters", "url": "/chapters", "right": 1}, - {"label": "Bounties", "url": "/bounties", "right": 1}, - {"label": 'Conference', "url": "/conf/2017", "right": 1}, + {"label": "User Manual", "url": "/docs", "right": 1}, + {"label": "Foundation", "child_items":[ + {"label": "Chapter", "url": "/chapters","right": 1}, + {"label": "Foundation Fellow", "url": "/foundation-fellow","right": 1} + ], "right":1}, + {"label": "Services", "child_items":[ + {"label": "Service Providers", "url": "/service-providers","right": 1}, + {"label": "Freelancer Jobs", "url": "/erpnext-jobs", "right": 1}, + ], "right":1}, {"label": "About", "url": "/about", "right": 1}, ], - "hide_login": 1, + "hide_login": 0, "favicon": "/assets/frappe_theme/img/favicon.ico" } # website user home page (by Role) @@ -70,6 +73,7 @@ website_context = { portal_menu_items = [ {'label': 'My Profile', 'route': '/service-provider-settings'}, + {'label': 'Module Leader', 'route': '/module-leader-settings'}, {'label': 'Membership', 'route': '/members/details'}, {'label': 'Conference Talks', 'route': '/conference-talk-proposal'}, {'label': 'Jobs', 'route': '/my-jobs'},