Browse Source

[minor] list is extensible

version-14
Rushabh Mehta 8 years ago
parent
commit
8bc72a1255
3 changed files with 6 additions and 2 deletions
  1. +1
    -0
      frappe/docs/user/en/bench/index.md
  2. +3
    -1
      frappe/www/list.html
  3. +2
    -1
      frappe/www/list.py

+ 1
- 0
frappe/docs/user/en/bench/index.md View File

@@ -1,2 +1,3 @@
# Bench

{index}

+ 3
- 1
frappe/www/list.html View File

@@ -1,6 +1,8 @@
{% extends "templates/web.html" %}

{% block title %}{{ title or (_("{0} List").format(_(doctype))) }}{% endblock %}
{% block title %}
{{ title or (_("{0} List").format(_(doctype))) }}
{% endblock %}

{% block header %}
<h1>{{ title or (_("{0} List").format(_(doctype))) }}</h1>


+ 2
- 1
frappe/www/list.py View File

@@ -11,9 +11,10 @@ from frappe import _
no_cache = 1
no_sitemap = 1

def get_context(context):
def get_context(context, **dict_params):
"""Returns context for a list standard list page.
Will also update `get_list_context` from the doctype module file"""
frappe.local.form_dict.update(dict_params)
doctype = frappe.local.form_dict.doctype
context.parents = [{"route":"me", "title":_("My Account")}]
context.update(get_list_context(context, doctype) or {})


Loading…
Cancel
Save