diff --git a/erpnext/accounts/doctype/account/account.py b/erpnext/accounts/doctype/account/account.py
index 5b034f8b23..2f60dca904 100644
--- a/erpnext/accounts/doctype/account/account.py
+++ b/erpnext/accounts/doctype/account/account.py
@@ -16,7 +16,6 @@ class Account(Document):
if not frozen_accounts_modifier or frozen_accounts_modifier in frappe.user.get_roles():
self.get("__onload").can_freeze_account = True
-
def autoname(self):
self.name = self.account_name.strip() + ' - ' + \
frappe.db.get_value("Company", self.company, "abbr")
diff --git a/erpnext/accounts/doctype/journal_voucher/journal_voucher.json b/erpnext/accounts/doctype/journal_voucher/journal_voucher.json
index ac402662b6..187c59a3fc 100644
--- a/erpnext/accounts/doctype/journal_voucher/journal_voucher.json
+++ b/erpnext/accounts/doctype/journal_voucher/journal_voucher.json
@@ -440,7 +440,7 @@
"icon": "icon-file-text",
"idx": 1,
"is_submittable": 1,
- "modified": "2014-05-27 03:49:12.326026",
+ "modified": "2014-07-31 05:05:03.294068",
"modified_by": "Administrator",
"module": "Accounts",
"name": "Journal Voucher",
diff --git a/erpnext/accounts/doctype/journal_voucher/journal_voucher_list.html b/erpnext/accounts/doctype/journal_voucher/journal_voucher_list.html
new file mode 100644
index 0000000000..aaa3854fef
--- /dev/null
+++ b/erpnext/accounts/doctype/journal_voucher/journal_voucher_list.html
@@ -0,0 +1,20 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+ {%= doc.get_formatted("posting_date") %}
+
+ {%= doc.voucher_type %}
+
+ {% if(doc.docstatus===0) { %}
+ {%= __("Draft") %}
+ {% } %}
+
+
+
+ {%= doc.get_formatted("total_debit") %}
+
+
diff --git a/erpnext/accounts/doctype/journal_voucher/journal_voucher_list.js b/erpnext/accounts/doctype/journal_voucher/journal_voucher_list.js
new file mode 100644
index 0000000000..06d578abaa
--- /dev/null
+++ b/erpnext/accounts/doctype/journal_voucher/journal_voucher_list.js
@@ -0,0 +1,3 @@
+frappe.listview_settings['Journal Voucher'] = {
+ add_fields: ["voucher_type", "posting_date", "total_debit", "company"]
+};
diff --git a/erpnext/accounts/doctype/payment_reconciliation/payment_reconciliation.json b/erpnext/accounts/doctype/payment_reconciliation/payment_reconciliation.json
index 8e675ef8b1..51cb306157 100644
--- a/erpnext/accounts/doctype/payment_reconciliation/payment_reconciliation.json
+++ b/erpnext/accounts/doctype/payment_reconciliation/payment_reconciliation.json
@@ -128,8 +128,9 @@
}
],
"hide_toolbar": 1,
+ "icon": "icon-resize-horizontal",
"issingle": 1,
- "modified": "2014-07-22 14:53:59.084438",
+ "modified": "2014-07-31 05:43:03.410832",
"modified_by": "Administrator",
"module": "Accounts",
"name": "Payment Reconciliation",
@@ -139,7 +140,7 @@
{
"cancel": 0,
"create": 1,
- "delete": 0,
+ "delete": 1,
"permlevel": 0,
"read": 1,
"role": "Accounts Manager",
@@ -149,7 +150,7 @@
{
"cancel": 0,
"create": 1,
- "delete": 0,
+ "delete": 1,
"permlevel": 0,
"read": 1,
"role": "Accounts User",
diff --git a/erpnext/accounts/doctype/purchase_invoice/purchase_invoice.py b/erpnext/accounts/doctype/purchase_invoice/purchase_invoice.py
index 74a9628209..55e3247636 100644
--- a/erpnext/accounts/doctype/purchase_invoice/purchase_invoice.py
+++ b/erpnext/accounts/doctype/purchase_invoice/purchase_invoice.py
@@ -14,6 +14,10 @@ import frappe.defaults
from erpnext.controllers.buying_controller import BuyingController
from erpnext.accounts.party import get_party_account, get_due_date
+form_grid_templates = {
+ "entries": "templates/form_grid/item_grid.html"
+}
+
class PurchaseInvoice(BuyingController):
tname = 'Purchase Invoice Item'
fname = 'entries'
diff --git a/erpnext/accounts/doctype/purchase_invoice/purchase_invoice_list.html b/erpnext/accounts/doctype/purchase_invoice/purchase_invoice_list.html
new file mode 100644
index 0000000000..cccd38a67c
--- /dev/null
+++ b/erpnext/accounts/doctype/purchase_invoice/purchase_invoice_list.html
@@ -0,0 +1,45 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+
+ {%= doc.supplier_name %}
+ {% if(doc.outstanding_amount > 0 && doc.docstatus==1) { %}
+ {% if(frappe.datetime.get_diff(doc.due_date) < 0) { %}
+
+ {%= __("Overdue: ") + comment_when(doc.due_date) %}
+
+ {% } else { %}
+
+ {%= doc.get_formatted("due_date") %}
+ {% } %}
+ {% } %}
+ {% if(doc.outstanding_amount==0 && doc.docstatus==1) { %}
+
+ {%= __("Paid") %}
+
+ {% } %}
+ {% if(doc.docstatus===0) { %}
+ {%= __("Draft") %}
+ {% } %}
+
+
+
+ {% var completed = cint((doc.grand_total - doc.outstanding_amount) * 100 / doc.grand_total), title = __("Outstanding Amount") + ": " + doc.get_formatted("outstanding_amount") %}
+ {% include "templates/form_grid/includes/progress.html" %}
+
+
+
+ {%= doc.get_formatted("grand_total_import") %}
+
+
+
diff --git a/erpnext/accounts/doctype/purchase_invoice/purchase_invoice_list.js b/erpnext/accounts/doctype/purchase_invoice/purchase_invoice_list.js
index 61d2750c3e..d72176a197 100644
--- a/erpnext/accounts/doctype/purchase_invoice/purchase_invoice_list.js
+++ b/erpnext/accounts/doctype/purchase_invoice/purchase_invoice_list.js
@@ -3,10 +3,6 @@
// render
frappe.listview_settings['Purchase Invoice'] = {
- add_fields: ["`tabPurchase Invoice`.grand_total", "`tabPurchase Invoice`.outstanding_amount"],
- add_columns: [{"content":"paid_amount", width:"10%", type:"bar-graph", label: "Paid"}],
- prepare_data: function(data) {
- data.paid_amount = flt(data.grand_total) ? (((flt(data.grand_total) -
- flt(data.outstanding_amount)) / flt(data.grand_total)) * 100) : 0;
- }
+ add_fields: ["supplier", "supplier_name", "grand_total", "outstanding_amount", "due_date", "company",
+ "currency"]
};
diff --git a/erpnext/accounts/doctype/sales_invoice/sales_invoice.py b/erpnext/accounts/doctype/sales_invoice/sales_invoice.py
index 8f82fc6284..1205646cbf 100644
--- a/erpnext/accounts/doctype/sales_invoice/sales_invoice.py
+++ b/erpnext/accounts/doctype/sales_invoice/sales_invoice.py
@@ -18,6 +18,10 @@ month_map = {'Monthly': 1, 'Quarterly': 3, 'Half-yearly': 6, 'Yearly': 12}
from erpnext.controllers.selling_controller import SellingController
+form_grid_templates = {
+ "entries": "templates/form_grid/item_grid.html"
+}
+
class SalesInvoice(SellingController):
tname = 'Sales Invoice Item'
fname = 'entries'
diff --git a/erpnext/accounts/doctype/sales_invoice/sales_invoice_list.html b/erpnext/accounts/doctype/sales_invoice/sales_invoice_list.html
new file mode 100644
index 0000000000..47fadb5420
--- /dev/null
+++ b/erpnext/accounts/doctype/sales_invoice/sales_invoice_list.html
@@ -0,0 +1,45 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+
+ {%= doc.customer_name %}
+ {% if(doc.outstanding_amount > 0 && doc.docstatus==1) { %}
+ {% if(frappe.datetime.get_diff(doc.due_date) < 0) { %}
+
+ {%= __("Overdue: ") + comment_when(doc.due_date) %}
+
+ {% } else { %}
+
+ {%= doc.get_formatted("due_date") %}
+ {% } %}
+ {% } %}
+ {% if(doc.outstanding_amount==0 && doc.docstatus==1) { %}
+
+ {%= __("Paid") %}
+
+ {% } %}
+ {% if(doc.docstatus===0) { %}
+ {%= __("Draft") %}
+ {% } %}
+
+
+
+ {% var completed = cint((doc.grand_total - doc.outstanding_amount) * 100 / doc.grand_total), title = __("Outstanding Amount") + ": " + doc.get_formatted("outstanding_amount") %}
+ {% include "templates/form_grid/includes/progress.html" %}
+
+
+
+ {%= doc.get_formatted("grand_total_export") %}
+
+
+
diff --git a/erpnext/accounts/doctype/sales_invoice/sales_invoice_list.js b/erpnext/accounts/doctype/sales_invoice/sales_invoice_list.js
index 42c80b4e26..ea2986a79f 100644
--- a/erpnext/accounts/doctype/sales_invoice/sales_invoice_list.js
+++ b/erpnext/accounts/doctype/sales_invoice/sales_invoice_list.js
@@ -3,14 +3,7 @@
// render
frappe.listview_settings['Sales Invoice'] = {
- add_fields: ["`tabSales Invoice`.grand_total", "`tabSales Invoice`.outstanding_amount"],
- add_columns: [{"content":"Percent Paid", width:"10%", type:"bar-graph",
- label: "Payment Received"}],
- prepare_data: function(data) {
- if (data.docstatus === 1) {
- data["Percent Paid"] = flt(data.grand_total)
- ? (((flt(data.grand_total) - flt(data.outstanding_amount)) / flt(data.grand_total)) * 100)
- : 100.0;
- }
- }
+ add_fields: ["customer", "customer_name", "grand_total", "outstanding_amount", "due_date", "company",
+ "currency"],
+ filters: [["outstanding_amount", ">", "0"]]
};
diff --git a/erpnext/buying/doctype/purchase_order/purchase_order.py b/erpnext/buying/doctype/purchase_order/purchase_order.py
index f9f5103726..04ad37fc72 100644
--- a/erpnext/buying/doctype/purchase_order/purchase_order.py
+++ b/erpnext/buying/doctype/purchase_order/purchase_order.py
@@ -8,6 +8,10 @@ from frappe import msgprint, _, throw
from frappe.model.mapper import get_mapped_doc
from erpnext.controllers.buying_controller import BuyingController
+form_grid_templates = {
+ "po_details": "templates/form_grid/item_grid.html"
+}
+
class PurchaseOrder(BuyingController):
tname = 'Purchase Order Item'
fname = 'po_details'
diff --git a/erpnext/buying/doctype/purchase_order/purchase_order_list.html b/erpnext/buying/doctype/purchase_order/purchase_order_list.html
new file mode 100644
index 0000000000..a2031c0bf0
--- /dev/null
+++ b/erpnext/buying/doctype/purchase_order/purchase_order_list.html
@@ -0,0 +1,39 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+
+ {%= doc.supplier_name %}
+ {% if(doc.per_received < 100 && doc.status!=="Stopped") { %}
+
+ {%= __("Pending") %}
+
+ {% } %}
+ {% if(doc.status==="Stopped" || doc.status==="Draft") { %}
+ {%= __(doc.status) %}
+ {% } %}
+ {% if(doc.per_received == 100 && doc.status!=="Stopped") { %}
+
+
+ {% } %}
+
+
+
+ {% var completed = doc.per_received, title = __("Received") %}
+ {% include "templates/form_grid/includes/progress.html" %}
+
+
+ {% var completed = doc.per_billed, title = __("Billed") %}
+ {% include "templates/form_grid/includes/progress.html" %}
+
+
+
+ {%= doc.get_formatted("grand_total_import") %}
+
+
+
diff --git a/erpnext/buying/doctype/purchase_order/purchase_order_list.js b/erpnext/buying/doctype/purchase_order/purchase_order_list.js
new file mode 100644
index 0000000000..f4e5d3de48
--- /dev/null
+++ b/erpnext/buying/doctype/purchase_order/purchase_order_list.js
@@ -0,0 +1,4 @@
+frappe.listview_settings['Purchase Order'] = {
+ add_fields: ["grand_total", "company", "currency", "supplier",
+ "supplier_name", "per_received", "per_billed"]
+};
diff --git a/erpnext/buying/doctype/supplier/supplier.json b/erpnext/buying/doctype/supplier/supplier.json
index 752f342cf2..6a34e7d35f 100644
--- a/erpnext/buying/doctype/supplier/supplier.json
+++ b/erpnext/buying/doctype/supplier/supplier.json
@@ -186,7 +186,7 @@
],
"icon": "icon-user",
"idx": 1,
- "modified": "2014-05-27 03:49:20.060872",
+ "modified": "2014-08-07 06:57:15.274795",
"modified_by": "Administrator",
"module": "Buying",
"name": "Supplier",
@@ -231,5 +231,6 @@
"role": "Accounts User"
}
],
- "search_fields": "supplier_name,supplier_type"
+ "search_fields": "supplier_name,supplier_type",
+ "title_field": "supplier_name"
}
\ No newline at end of file
diff --git a/erpnext/buying/doctype/supplier/supplier_list.html b/erpnext/buying/doctype/supplier/supplier_list.html
new file mode 100644
index 0000000000..5cab239b62
--- /dev/null
+++ b/erpnext/buying/doctype/supplier/supplier_list.html
@@ -0,0 +1,15 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+ {% if(doc.supplier_name != doc.name) { %}
+
+ {%= doc.supplier_name %}
+ {% } %}
+
+ {%= doc.supplier_type %}
+
+
+
+
diff --git a/erpnext/buying/doctype/supplier/supplier_list.js b/erpnext/buying/doctype/supplier/supplier_list.js
new file mode 100644
index 0000000000..d26932c915
--- /dev/null
+++ b/erpnext/buying/doctype/supplier/supplier_list.js
@@ -0,0 +1,3 @@
+frappe.listview_settings['Supplier'] = {
+ add_fields: ["supplier_name", "supplier_type"]
+};
diff --git a/erpnext/buying/doctype/supplier_quotation/supplier_quotation.py b/erpnext/buying/doctype/supplier_quotation/supplier_quotation.py
index 2af7bb93a6..d009bac241 100644
--- a/erpnext/buying/doctype/supplier_quotation/supplier_quotation.py
+++ b/erpnext/buying/doctype/supplier_quotation/supplier_quotation.py
@@ -6,6 +6,11 @@ import frappe
from frappe.model.mapper import get_mapped_doc
from erpnext.controllers.buying_controller import BuyingController
+
+form_grid_templates = {
+ "quotation_items": "templates/form_grid/item_grid.html"
+}
+
class SupplierQuotation(BuyingController):
tname = "Supplier Quotation Item"
fname = "quotation_items"
diff --git a/erpnext/buying/doctype/supplier_quotation/supplier_quotation_list.html b/erpnext/buying/doctype/supplier_quotation/supplier_quotation_list.html
new file mode 100644
index 0000000000..9aa9d5bef9
--- /dev/null
+++ b/erpnext/buying/doctype/supplier_quotation/supplier_quotation_list.html
@@ -0,0 +1,22 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+
+ {%= doc.supplier %}
+
+
+ {%= doc.status %}
+
+
+
+
+ {%= doc.get_formatted("grand_total_import") %}
+
+
+
diff --git a/erpnext/buying/doctype/supplier_quotation/supplier_quotation_list.js b/erpnext/buying/doctype/supplier_quotation/supplier_quotation_list.js
new file mode 100644
index 0000000000..d62a0e2435
--- /dev/null
+++ b/erpnext/buying/doctype/supplier_quotation/supplier_quotation_list.js
@@ -0,0 +1,3 @@
+frappe.listview_settings['Supplier Quotation'] = {
+ add_fields: ["supplier", "grand_total", "status", "company", "currency"]
+};
diff --git a/erpnext/config/hr.py b/erpnext/config/hr.py
index 1fac46940e..575de697ee 100644
--- a/erpnext/config/hr.py
+++ b/erpnext/config/hr.py
@@ -13,13 +13,13 @@ def get_data():
},
{
"type": "doctype",
- "name": "Salary Slip",
- "description": _("Monthly salary statement."),
+ "name": "Leave Application",
+ "description": _("Applications for leave."),
},
{
"type": "doctype",
- "name": "Leave Application",
- "description": _("Applications for leave."),
+ "name": "Expense Claim",
+ "description": _("Claims for company expense."),
},
{
"type": "doctype",
@@ -28,8 +28,8 @@ def get_data():
},
{
"type": "doctype",
- "name": "Expense Claim",
- "description": _("Claims for company expense."),
+ "name": "Salary Slip",
+ "description": _("Monthly salary statement."),
},
{
"type": "doctype",
diff --git a/erpnext/controllers/selling_controller.py b/erpnext/controllers/selling_controller.py
index 7faba41b77..dd58758546 100644
--- a/erpnext/controllers/selling_controller.py
+++ b/erpnext/controllers/selling_controller.py
@@ -6,6 +6,7 @@ import frappe
from frappe.utils import cint, flt, rounded, cstr, comma_or
from erpnext.setup.utils import get_company_currency
from frappe import _, throw
+from erpnext.stock.get_item_details import get_available_qty
from erpnext.controllers.stock_controller import StockController
@@ -17,6 +18,12 @@ class SellingController(StockController):
"other_charges": "templates/print_formats/includes/taxes.html",
}
+ def onload(self):
+ if self.doctype in ("Sales Order", "Delivery Note", "Sales Invoice"):
+ for item in self.get(self.fname):
+ item.update(get_available_qty(item.item_code,
+ item.warehouse))
+
def validate(self):
super(SellingController, self).validate()
self.validate_max_discount()
diff --git a/erpnext/hr/doctype/attendance/attendance.json b/erpnext/hr/doctype/attendance/attendance.json
index 2ca5b33172..18c39e0c63 100644
--- a/erpnext/hr/doctype/attendance/attendance.json
+++ b/erpnext/hr/doctype/attendance/attendance.json
@@ -129,7 +129,7 @@
"icon": "icon-ok",
"idx": 1,
"is_submittable": 1,
- "modified": "2014-05-27 03:49:07.580876",
+ "modified": "2014-08-05 06:52:02.226904",
"modified_by": "Administrator",
"module": "HR",
"name": "Attendance",
@@ -178,5 +178,6 @@
],
"search_fields": "employee, employee_name, att_date, status",
"sort_field": "modified",
- "sort_order": "DESC"
+ "sort_order": "DESC",
+ "title_field": "employee_name"
}
\ No newline at end of file
diff --git a/erpnext/hr/doctype/attendance/attendance_list.html b/erpnext/hr/doctype/attendance/attendance_list.html
new file mode 100644
index 0000000000..bfda7f88e9
--- /dev/null
+++ b/erpnext/hr/doctype/attendance/attendance_list.html
@@ -0,0 +1,19 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+
+ {%= doc.status %}
+
+
+
+
+
+ {%= doc.get_formatted("att_date") %}
+
+
diff --git a/erpnext/hr/doctype/attendance/attendance_list.js b/erpnext/hr/doctype/attendance/attendance_list.js
new file mode 100644
index 0000000000..87c87d76d3
--- /dev/null
+++ b/erpnext/hr/doctype/attendance/attendance_list.js
@@ -0,0 +1,3 @@
+frappe.listview_settings['Attendance'] = {
+ add_fields: ["status", "att_date"],
+};
diff --git a/erpnext/hr/doctype/attendance/test_attendance.py b/erpnext/hr/doctype/attendance/test_attendance.py
new file mode 100644
index 0000000000..e4f390b0e6
--- /dev/null
+++ b/erpnext/hr/doctype/attendance/test_attendance.py
@@ -0,0 +1,10 @@
+# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors and Contributors
+# See license.txt
+
+import frappe
+import unittest
+
+test_records = frappe.get_test_records('Attendance')
+
+class TestAttendance(unittest.TestCase):
+ pass
diff --git a/erpnext/hr/doctype/attendance/test_records.json b/erpnext/hr/doctype/attendance/test_records.json
new file mode 100644
index 0000000000..41b40ffe9a
--- /dev/null
+++ b/erpnext/hr/doctype/attendance/test_records.json
@@ -0,0 +1,11 @@
+[
+ {
+ "doctype": "Attendance",
+ "name": "_Test Attendance 1",
+ "employee": "_T-Employee-0001",
+ "status": "Present",
+ "att_date": "2014-02-01",
+ "fiscal_year": "_Test Fiscal Year 2014",
+ "company": "_Test Company"
+ }
+]
diff --git a/erpnext/hr/doctype/earning_type/earning_type.json b/erpnext/hr/doctype/earning_type/earning_type.json
index 85c6323db8..507acd9fd7 100644
--- a/erpnext/hr/doctype/earning_type/earning_type.json
+++ b/erpnext/hr/doctype/earning_type/earning_type.json
@@ -27,33 +27,11 @@
"permlevel": 0,
"reqd": 0,
"width": "300px"
- },
- {
- "fieldname": "taxable",
- "fieldtype": "Select",
- "in_list_view": 1,
- "label": "Taxable",
- "oldfieldname": "taxable",
- "oldfieldtype": "Select",
- "options": "\nYes\nNo",
- "permlevel": 0,
- "reqd": 1
- },
- {
- "depends_on": "eval:doc.taxable=='No'",
- "fieldname": "exemption_limit",
- "fieldtype": "Float",
- "hidden": 0,
- "in_list_view": 1,
- "label": "Exemption Limit",
- "oldfieldname": "exemption_limit",
- "oldfieldtype": "Currency",
- "permlevel": 0
}
],
"icon": "icon-flag",
"idx": 1,
- "modified": "2014-05-27 03:49:10.133416",
+ "modified": "2014-07-31 07:25:26.606030",
"modified_by": "Administrator",
"module": "HR",
"name": "Earning Type",
diff --git a/erpnext/hr/doctype/employee/employee_list.html b/erpnext/hr/doctype/employee/employee_list.html
new file mode 100644
index 0000000000..98b45a9c34
--- /dev/null
+++ b/erpnext/hr/doctype/employee/employee_list.html
@@ -0,0 +1,35 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+ {% if(doc.status==="Active") { %}
+
+
+
+ {% } %}
+
+ {% if(doc.designation) { %}
+
+ {%= doc.designation %}
+ {% } %}
+
+ {% if(doc.branch) { %}
+
+ {%= doc.branch %}
+
+ {% } %}
+
+ {% if(doc.department) { %}
+
+ {%= doc.department %}
+
+ {% } %}
+
+
+
diff --git a/erpnext/hr/doctype/employee/employee_list.js b/erpnext/hr/doctype/employee/employee_list.js
new file mode 100644
index 0000000000..c1b23ac43a
--- /dev/null
+++ b/erpnext/hr/doctype/employee/employee_list.js
@@ -0,0 +1,4 @@
+frappe.listview_settings['Employee'] = {
+ add_fields: ["status", "branch", "department", "designation"],
+ filters:[["status","=", "Active"]]
+};
diff --git a/erpnext/hr/doctype/expense_claim/expense_claim_list.html b/erpnext/hr/doctype/expense_claim/expense_claim_list.html
new file mode 100644
index 0000000000..dd3c78fc66
--- /dev/null
+++ b/erpnext/hr/doctype/expense_claim/expense_claim_list.html
@@ -0,0 +1,23 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+
+ {%= doc.employee_name %}
+
+
+ {%= doc.approval_status %}
+
+
+
+
+
+
+ {%= doc.get_formatted("total_claimed_amount") %}
+
+
diff --git a/erpnext/hr/doctype/expense_claim/expense_claim_list.js b/erpnext/hr/doctype/expense_claim/expense_claim_list.js
new file mode 100644
index 0000000000..34ee5c14fb
--- /dev/null
+++ b/erpnext/hr/doctype/expense_claim/expense_claim_list.js
@@ -0,0 +1,4 @@
+frappe.listview_settings['Expense Claim'] = {
+ add_fields: ["approval_status", "employee", "employee_name", "total_claimed_amount"],
+ filters:[["approval_status","!=", "Rejected"]]
+};
diff --git a/erpnext/hr/doctype/leave_application/leave_application_list.html b/erpnext/hr/doctype/leave_application/leave_application_list.html
new file mode 100644
index 0000000000..dfae4365b5
--- /dev/null
+++ b/erpnext/hr/doctype/leave_application/leave_application_list.html
@@ -0,0 +1,28 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+
+ {%= doc.employee_name %}
+
+
+ {%= __("{0} days from {1}",
+ [doc.total_leave_days, doc.get_formatted("from_date")]) %}
+
+
+ {%= doc.status %}
+
+
+
+ {%= doc.leave_type %}
+
+
+
+
diff --git a/erpnext/hr/doctype/leave_application/leave_application_list.js b/erpnext/hr/doctype/leave_application/leave_application_list.js
new file mode 100644
index 0000000000..e2a89013f7
--- /dev/null
+++ b/erpnext/hr/doctype/leave_application/leave_application_list.js
@@ -0,0 +1,4 @@
+frappe.listview_settings['Leave Application'] = {
+ add_fields: ["status", "leave_type", "employee", "employee_name", "total_leave_days", "from_date"],
+ filters:[["status","!=", "Rejected"], ["to_date", ">=", frappe.datetime.get_today()]]
+};
diff --git a/erpnext/hr/doctype/salary_slip/salary_slip_list.html b/erpnext/hr/doctype/salary_slip/salary_slip_list.html
new file mode 100644
index 0000000000..ef54450ef0
--- /dev/null
+++ b/erpnext/hr/doctype/salary_slip/salary_slip_list.html
@@ -0,0 +1,26 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+
+
+ {%= doc.employee_name %}
+
+
+
+
+
+ {%= doc.month %}
+
+
+
+ {%= doc.fiscal_year %}
+
+
+
diff --git a/erpnext/hr/doctype/salary_slip/salary_slip_list.js b/erpnext/hr/doctype/salary_slip/salary_slip_list.js
new file mode 100644
index 0000000000..17f13d6bea
--- /dev/null
+++ b/erpnext/hr/doctype/salary_slip/salary_slip_list.js
@@ -0,0 +1,3 @@
+frappe.listview_settings['Salary Slip'] = {
+ add_fields: ["employee", "employee_name", "fiscal_year", "month"],
+};
diff --git a/erpnext/hr/doctype/salary_structure/salary_structure.json b/erpnext/hr/doctype/salary_structure/salary_structure.json
index c31696cab7..2ddd95be51 100644
--- a/erpnext/hr/doctype/salary_structure/salary_structure.json
+++ b/erpnext/hr/doctype/salary_structure/salary_structure.json
@@ -227,7 +227,7 @@
],
"icon": "icon-file-text",
"idx": 1,
- "modified": "2014-05-27 03:49:17.438605",
+ "modified": "2014-08-05 06:56:27.038404",
"modified_by": "Administrator",
"module": "HR",
"name": "Salary Structure",
@@ -260,5 +260,6 @@
}
],
"sort_field": "modified",
- "sort_order": "DESC"
+ "sort_order": "DESC",
+ "title_field": "employee_name"
}
\ No newline at end of file
diff --git a/erpnext/hr/doctype/salary_structure/test_records.json b/erpnext/hr/doctype/salary_structure/test_records.json
new file mode 100644
index 0000000000..f33b65e554
--- /dev/null
+++ b/erpnext/hr/doctype/salary_structure/test_records.json
@@ -0,0 +1,8 @@
+[
+ {
+ "doctype": "Salary Structure",
+ "name": "_Test Salary Structure 1",
+ "employee": "_T-Employee-0001",
+ "from_date": "2014-02-01"
+ }
+]
diff --git a/erpnext/hr/doctype/salary_structure/test_salary_structure.py b/erpnext/hr/doctype/salary_structure/test_salary_structure.py
new file mode 100644
index 0000000000..0a1db7ed16
--- /dev/null
+++ b/erpnext/hr/doctype/salary_structure/test_salary_structure.py
@@ -0,0 +1,10 @@
+# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors and Contributors
+# See license.txt
+
+import frappe
+import unittest
+
+test_records = frappe.get_test_records('Salary Structure')
+
+class TestSalaryStructure(unittest.TestCase):
+ pass
diff --git a/erpnext/manufacturing/doctype/bom/bom_list.html b/erpnext/manufacturing/doctype/bom/bom_list.html
new file mode 100644
index 0000000000..8303f4a3d4
--- /dev/null
+++ b/erpnext/manufacturing/doctype/bom/bom_list.html
@@ -0,0 +1,20 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+ {% if(cint(doc.is_active)) { %}
+
+ {%= __("Active") %}
+ {% } %}
+ {% if(cint(doc.is_default)) { %}
+
+ {%= __("Default") %}
+ {% } %}
+
+
+
+ {%= doc.get_formatted("total_cost") %}
+
+
diff --git a/erpnext/manufacturing/doctype/bom/bom_list.js b/erpnext/manufacturing/doctype/bom/bom_list.js
new file mode 100644
index 0000000000..71d54a20dc
--- /dev/null
+++ b/erpnext/manufacturing/doctype/bom/bom_list.js
@@ -0,0 +1,3 @@
+frappe.listview_settings['BOM'] = {
+ add_fields: ["is_active", "is_default", "total_cost"]
+};
diff --git a/erpnext/manufacturing/doctype/production_order/production_order_list.html b/erpnext/manufacturing/doctype/production_order/production_order_list.html
new file mode 100644
index 0000000000..a856a0e5f1
--- /dev/null
+++ b/erpnext/manufacturing/doctype/production_order/production_order_list.html
@@ -0,0 +1,47 @@
+
+
+
+ {% var per = 100 - cint((doc.qty - doc.produced_qty) * 100 / doc.qty); %}
+ {%= list.get_avatar_and_id(doc) %}
+
+
+ {%= doc.customer_name %}
+ {% if(per < 100 && doc.status!=="Stopped") { %}
+ {% if(frappe.datetime.get_diff(doc.expected_delivery_date) < 0) { %}
+
+ {%= __("Overdue") %}
+
+ {% } else { %}
+
+ {%= doc.get_formatted("expected_delivery_date")%}
+ {% } %}
+ {% } %}
+ {% if(per == 100 && doc.status!=="Stopped") { %}
+
+
+ {% } %}
+ {% if(doc.status==="Stopped") { %}
+ {%= __("Stopped") %}
+ {% } %}
+
+ {%= doc.sales_order %}
+
+ {%= doc.bom_no %}
+
+
+
+ {% var completed = per, title = __("Completed") %}
+ {% include "templates/form_grid/includes/progress.html" %}
+
+
diff --git a/erpnext/manufacturing/doctype/production_order/production_order_list.js b/erpnext/manufacturing/doctype/production_order/production_order_list.js
new file mode 100644
index 0000000000..457e803d15
--- /dev/null
+++ b/erpnext/manufacturing/doctype/production_order/production_order_list.js
@@ -0,0 +1,5 @@
+frappe.listview_settings['Production Order'] = {
+ add_fields: ["bom_no", "status", "sales_order", "qty",
+ "produced_qty", "expected_delivery_date"],
+ filters: [["status", "!=", "Completed"], ["status", "!=", "Stopped"]]
+};
diff --git a/erpnext/patches.txt b/erpnext/patches.txt
index 1ae0a952a7..03919bc647 100644
--- a/erpnext/patches.txt
+++ b/erpnext/patches.txt
@@ -74,3 +74,4 @@ execute:frappe.delete_doc("Page", "trial-balance") #2014-07-22
erpnext.patches.v4_2.delete_old_print_formats #2014-07-29
erpnext.patches.v4_2.toggle_rounded_total #2014-07-30
erpnext.patches.v4_2.fix_account_master_type
+erpnext.patches.v4_2.update_project_milestones
diff --git a/erpnext/patches/v4_2/update_project_milestones.py b/erpnext/patches/v4_2/update_project_milestones.py
new file mode 100644
index 0000000000..24a520ecd1
--- /dev/null
+++ b/erpnext/patches/v4_2/update_project_milestones.py
@@ -0,0 +1,7 @@
+import frappe
+
+def execute():
+ for project in frappe.db.sql_list("select name from tabProject"):
+ p = frappe.get_doc("Project", project)
+ p.update_milestones_completed()
+ p.db_set("percent_milestones_completed", p.percent_milestones_completed)
diff --git a/erpnext/projects/doctype/project/project.js b/erpnext/projects/doctype/project/project.js
index 5d89986596..cdb494e7fd 100644
--- a/erpnext/projects/doctype/project/project.js
+++ b/erpnext/projects/doctype/project/project.js
@@ -4,14 +4,14 @@
// show tasks
cur_frm.cscript.refresh = function(doc) {
if(!doc.__islocal) {
- cur_frm.appframe.add_button(__("Gantt Chart"), function() {
+ cur_frm.add_custom_button(__("Gantt Chart"), function() {
frappe.route_options = {"project": doc.name}
frappe.set_route("Gantt", "Task");
- }, "icon-tasks");
+ }, "icon-tasks", true);
cur_frm.add_custom_button(__("Tasks"), function() {
frappe.route_options = {"project": doc.name}
frappe.set_route("List", "Task");
- }, "icon-list");
+ }, "icon-list", true);
}
}
@@ -19,4 +19,4 @@ cur_frm.fields_dict.customer.get_query = function(doc,cdt,cdn) {
return{
query: "erpnext.controllers.queries.customer_query"
}
-}
\ No newline at end of file
+}
diff --git a/erpnext/projects/doctype/project/project.json b/erpnext/projects/doctype/project/project.json
index c894bb8b26..b20914cdc1 100644
--- a/erpnext/projects/doctype/project/project.json
+++ b/erpnext/projects/doctype/project/project.json
@@ -136,6 +136,13 @@
"permlevel": 0,
"search_index": 0
},
+ {
+ "fieldname": "percent_milestones_completed",
+ "fieldtype": "Percent",
+ "label": "% Milestones Completed",
+ "permlevel": 0,
+ "read_only": 1
+ },
{
"fieldname": "section_break0",
"fieldtype": "Section Break",
@@ -158,7 +165,7 @@
"fieldname": "percent_complete",
"fieldtype": "Percent",
"in_list_view": 1,
- "label": "Percent Complete",
+ "label": "% Tasks Completed",
"permlevel": 0,
"read_only": 1
},
@@ -259,7 +266,7 @@
"icon": "icon-puzzle-piece",
"idx": 1,
"max_attachments": 4,
- "modified": "2014-06-24 12:44:19.530707",
+ "modified": "2014-08-04 03:22:11.416219",
"modified_by": "Administrator",
"module": "Projects",
"name": "Project",
diff --git a/erpnext/projects/doctype/project/project.py b/erpnext/projects/doctype/project/project.py
index 4a14c55c3a..547e12aebc 100644
--- a/erpnext/projects/doctype/project/project.py
+++ b/erpnext/projects/doctype/project/project.py
@@ -26,6 +26,13 @@ class Project(Document):
if getdate(self.completion_date) < getdate(self.project_start_date):
frappe.throw(_("Expected Completion Date can not be less than Project Start Date"))
+ self.update_milestones_completed()
+
+ def update_milestones_completed(self):
+ if self.project_milestones:
+ completed = filter(lambda x: x.status=="Completed", self.project_milestones)
+ self.percent_milestones_completed = len(completed) * 100 / len(self.project_milestones)
+
def on_update(self):
self.add_calendar_event()
@@ -38,6 +45,7 @@ class Project(Document):
frappe.db.set_value("Project", self.name, "percent_complete",
int(float(completed) / total * 100))
+
def add_calendar_event(self):
# delete any earlier event for this project
delete_events(self.doctype, self.name)
diff --git a/erpnext/projects/doctype/project/project_list.html b/erpnext/projects/doctype/project/project_list.html
new file mode 100644
index 0000000000..42af477561
--- /dev/null
+++ b/erpnext/projects/doctype/project/project_list.html
@@ -0,0 +1,38 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+ {%= doc.status %}
+
+
+ {%= doc.priority %}
+
+ {% if(doc.status==="Open" && doc.completion_date
+ && frappe.datetime.get_diff(doc.completion_date) <= 0) { %}
+
+ {%= __("Overdue") %}
+
+ {% } else if(doc.completion_date) { %}
+
+ {%= doc.get_formatted("completion_date") %}
+
+ {% } %}
+
+
+
+ {% var completed = doc.percent_complete, title = __("% Tasks Completed") %}
+ {% include "templates/form_grid/includes/progress.html" %}
+
+
+ {% var completed = doc.percent_milestones_completed,
+ title = __("% Milestones Achieved") %}
+ {% include "templates/form_grid/includes/progress.html" %}
+
+
diff --git a/erpnext/projects/doctype/project/project_list.js b/erpnext/projects/doctype/project/project_list.js
new file mode 100644
index 0000000000..dd0ac60958
--- /dev/null
+++ b/erpnext/projects/doctype/project/project_list.js
@@ -0,0 +1,5 @@
+frappe.listview_settings['Project'] = {
+ add_fields: ["status", "priority", "is_active", "percent_complete",
+ "percent_milestones_completed", "completion_date"],
+ filters:[["status","=", "Open"]]
+};
diff --git a/erpnext/projects/doctype/task/task.py b/erpnext/projects/doctype/task/task.py
index 6b0b237a40..8d63f12e67 100644
--- a/erpnext/projects/doctype/task/task.py
+++ b/erpnext/projects/doctype/task/task.py
@@ -62,12 +62,13 @@ def get_events(start, end, filters=None):
data = frappe.db.sql("""select name, exp_start_date, exp_end_date,
subject, status, project from `tabTask`
- where ((exp_start_date between '%(start)s' and '%(end)s') \
- or (exp_end_date between '%(start)s' and '%(end)s'))
- %(conditions)s""" % {
+ where ((ifnull(exp_start_date, '0000-00-00')!= '0000-00-00') \
+ and (exp_start_date between %(start)s and %(end)s) \
+ or ((ifnull(exp_start_date, '0000-00-00')!= '0000-00-00') \
+ and exp_end_date between %(start)s and %(end)s))
+ {conditions}""".format(conditions=conditions), {
"start": start,
- "end": end,
- "conditions": conditions
+ "end": end
}, as_dict=True, update={"allDay": 0})
return data
diff --git a/erpnext/projects/doctype/task/task_list.html b/erpnext/projects/doctype/task/task_list.html
new file mode 100644
index 0000000000..0d95055b41
--- /dev/null
+++ b/erpnext/projects/doctype/task/task_list.html
@@ -0,0 +1,34 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+ {% if(doc.project) { %}
+
+ {%= doc.project %}
+ {% } %}
+
+ {%= doc.status %}
+
+
+ {%= doc.priority %}
+
+ {% if(doc.status==="Open" && doc.exp_end_date
+ && frappe.datetime.get_diff(doc.exp_end_date) <= 0) { %}
+
+ {%= __("Overdue") %}
+
+ {% } else if(doc.exp_end_date) { %}
+
+ {%= doc.get_formatted("exp_end_date") %}
+
+ {% } %}
+
+
+
diff --git a/erpnext/projects/doctype/task/task_list.js b/erpnext/projects/doctype/task/task_list.js
new file mode 100644
index 0000000000..4406085e69
--- /dev/null
+++ b/erpnext/projects/doctype/task/task_list.js
@@ -0,0 +1,4 @@
+frappe.listview_settings['Task'] = {
+ add_fields: ["project", "status", "priority", "exp_end_date"],
+ filters:[["status","=", "Open"]]
+};
diff --git a/erpnext/projects/doctype/time_log/time_log.js b/erpnext/projects/doctype/time_log/time_log.js
index eb5fc0993b..d4d109d6f9 100644
--- a/erpnext/projects/doctype/time_log/time_log.js
+++ b/erpnext/projects/doctype/time_log/time_log.js
@@ -3,12 +3,27 @@
frappe.provide("erpnext.projects");
-erpnext.projects.TimeLog = frappe.ui.form.Controller.extend({
- onload: function() {
- this.frm.set_query("task", erpnext.queries.task);
- }
+frappe.ui.form.on("Time Log", "onload", function(frm) {
+ frm.set_query("task", erpnext.queries.task);
});
-cur_frm.cscript = new erpnext.projects.TimeLog({frm: cur_frm});
+// set to time if hours is updated
+frappe.ui.form.on("Time Log", "hours", function(frm) {
+ if(!frm.doc.from_time) {
+ frm.set_value("from_time", frappe.datetime.now_datetime());
+ }
+ var d = moment(frm.doc.from_time);
+ d.add(frm.doc.hours, "hours");
+ frm._setting_hours = true;
+ frm.set_value("to_time", d.format(moment.defaultDatetimeFormat));
+ frm._setting_hours = false;
+});
-cur_frm.add_fetch('task','project','project');
\ No newline at end of file
+// set hours if to_time is updated
+frappe.ui.form.on("Time Log", "to_time", function(frm) {
+ if(frm._setting_hours) return;
+ frm.set_value("hours", moment(cur_frm.doc.to_time).diff(moment(cur_frm.doc.from_time),
+ "hours"));
+});
+
+cur_frm.add_fetch('task','project','project');
diff --git a/erpnext/projects/doctype/time_log/time_log.json b/erpnext/projects/doctype/time_log/time_log.json
index daeddbaa3b..157be0cdd4 100644
--- a/erpnext/projects/doctype/time_log/time_log.json
+++ b/erpnext/projects/doctype/time_log/time_log.json
@@ -26,6 +26,14 @@
"read_only": 0,
"reqd": 1
},
+ {
+ "fieldname": "hours",
+ "fieldtype": "Float",
+ "in_list_view": 1,
+ "label": "Hours",
+ "permlevel": 0,
+ "read_only": 0
+ },
{
"fieldname": "to_time",
"fieldtype": "Datetime",
@@ -35,14 +43,6 @@
"read_only": 0,
"reqd": 1
},
- {
- "fieldname": "hours",
- "fieldtype": "Float",
- "in_list_view": 1,
- "label": "Hours",
- "permlevel": 0,
- "read_only": 1
- },
{
"fieldname": "column_break_3",
"fieldtype": "Column Break",
@@ -152,7 +152,7 @@
"icon": "icon-time",
"idx": 1,
"is_submittable": 1,
- "modified": "2014-05-27 03:49:21.143356",
+ "modified": "2014-08-04 05:23:15.740050",
"modified_by": "Administrator",
"module": "Projects",
"name": "Time Log",
diff --git a/erpnext/projects/doctype/time_log/time_log_list.html b/erpnext/projects/doctype/time_log/time_log_list.html
new file mode 100644
index 0000000000..ee0b96f28c
--- /dev/null
+++ b/erpnext/projects/doctype/time_log/time_log_list.html
@@ -0,0 +1,25 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+ {% if(doc.billable) { %}
+
+
+
+ {% } %}
+
+ {%= doc.activity_type %}
+
+ ({%= doc.hours + " " + __("hours") %})
+
+ {% if(doc.project) { %}
+
+ {%= doc.project %}
+ {% } %}
+
+
+
diff --git a/erpnext/projects/doctype/time_log/time_log_list.js b/erpnext/projects/doctype/time_log/time_log_list.js
index a40297fcd9..664117484d 100644
--- a/erpnext/projects/doctype/time_log/time_log_list.js
+++ b/erpnext/projects/doctype/time_log/time_log_list.js
@@ -3,10 +3,10 @@
// render
frappe.listview_settings['Time Log'] = {
- add_fields: ["`tabTime Log`.`status`", "`tabTime Log`.`billable`", "`tabTime Log`.`activity_type`"],
+ add_fields: ["status", "billable", "activity_type", "task", "project", "hours"],
selectable: true,
onload: function(me) {
- me.appframe.add_button(__("Make Time Log Batch"), function() {
+ me.appframe.add_primary_action(__("Make Time Log Batch"), function() {
var selected = me.get_checked_items() || [];
if(!selected.length) {
diff --git a/erpnext/projects/doctype/time_log_batch/time_log_batch_list.html b/erpnext/projects/doctype/time_log_batch/time_log_batch_list.html
new file mode 100644
index 0000000000..4a34f1cdb8
--- /dev/null
+++ b/erpnext/projects/doctype/time_log_batch/time_log_batch_list.html
@@ -0,0 +1,15 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+ {%= doc.status %}
+
+ ({%= doc.total_hours + " " + __("hours") %})
+
+
+
+
diff --git a/erpnext/projects/doctype/time_log_batch/time_log_batch_list.js b/erpnext/projects/doctype/time_log_batch/time_log_batch_list.js
new file mode 100644
index 0000000000..cc6746e353
--- /dev/null
+++ b/erpnext/projects/doctype/time_log_batch/time_log_batch_list.js
@@ -0,0 +1,3 @@
+frappe.listview_settings['Time Log Batch'] = {
+ add_fields: ["status", "total_hours", "rate"]
+};
diff --git a/erpnext/selling/doctype/customer/customer.json b/erpnext/selling/doctype/customer/customer.json
index 794b763090..ef71d56ad5 100644
--- a/erpnext/selling/doctype/customer/customer.json
+++ b/erpnext/selling/doctype/customer/customer.json
@@ -282,7 +282,7 @@
],
"icon": "icon-user",
"idx": 1,
- "modified": "2014-05-27 03:49:09.208254",
+ "modified": "2014-08-07 06:57:25.248707",
"modified_by": "Administrator",
"module": "Selling",
"name": "Customer",
@@ -332,5 +332,6 @@
"write": 1
}
],
- "search_fields": "customer_name,customer_group,territory"
+ "search_fields": "customer_name,customer_group,territory",
+ "title_field": "customer_name"
}
\ No newline at end of file
diff --git a/erpnext/selling/doctype/customer/customer_list.html b/erpnext/selling/doctype/customer/customer_list.html
new file mode 100644
index 0000000000..3656d106a0
--- /dev/null
+++ b/erpnext/selling/doctype/customer/customer_list.html
@@ -0,0 +1,29 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+ {% if(doc.customer_name != doc.name) { %}
+
+ {%= doc.customer_name %}
+ {% } %}
+
+ {% if(doc.customer_type==="Company") { %}
+
+ {% } else { %}
+
+ {% } %}
+
+
+ {%= doc.customer_group %}
+ {% if(doc.territory) { %}
+
+
+ {%= doc.territory %}
+ {% } %}
+
+
+
diff --git a/erpnext/selling/doctype/customer/customer_list.js b/erpnext/selling/doctype/customer/customer_list.js
new file mode 100644
index 0000000000..012d3f81dd
--- /dev/null
+++ b/erpnext/selling/doctype/customer/customer_list.js
@@ -0,0 +1,3 @@
+frappe.listview_settings['Customer'] = {
+ add_fields: ["customer_name", "territory", "customer_group", "customer_type"]
+};
diff --git a/erpnext/selling/doctype/lead/lead_list.html b/erpnext/selling/doctype/lead/lead_list.html
new file mode 100644
index 0000000000..d5799b9611
--- /dev/null
+++ b/erpnext/selling/doctype/lead/lead_list.html
@@ -0,0 +1,18 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+ {%= doc.company_name %}
+ {%= doc.status %}
+ {% if(doc.territory) { %}
+
+
+ {%= doc.territory %}
+ {% } %}
+
+
+
diff --git a/erpnext/selling/doctype/lead/lead_list.js b/erpnext/selling/doctype/lead/lead_list.js
new file mode 100644
index 0000000000..b1733710a2
--- /dev/null
+++ b/erpnext/selling/doctype/lead/lead_list.js
@@ -0,0 +1,3 @@
+frappe.listview_settings['Lead'] = {
+ add_fields: ["territory", "company_name", "status", "source"]
+};
diff --git a/erpnext/selling/doctype/opportunity/opportunity_list.html b/erpnext/selling/doctype/opportunity/opportunity_list.html
new file mode 100644
index 0000000000..c0a948340d
--- /dev/null
+++ b/erpnext/selling/doctype/opportunity/opportunity_list.html
@@ -0,0 +1,23 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+
+ {%= doc.customer_name %} ({%= doc.enquiry_from %})
+
+ {% if(doc.enquiry_type==="Sales") { %}
+
+ {% } else { %}
+
+ {% } %}
+
+ {%= doc.status %}
+
+
+
diff --git a/erpnext/selling/doctype/opportunity/opportunity_list.js b/erpnext/selling/doctype/opportunity/opportunity_list.js
new file mode 100644
index 0000000000..06fbe3443e
--- /dev/null
+++ b/erpnext/selling/doctype/opportunity/opportunity_list.js
@@ -0,0 +1,3 @@
+frappe.listview_settings['Opportunity'] = {
+ add_fields: ["customer_name", "enquiry_type", "enquiry_from", "status"]
+};
diff --git a/erpnext/selling/doctype/quotation/quotation.py b/erpnext/selling/doctype/quotation/quotation.py
index f396191a2d..ab6e4baec8 100644
--- a/erpnext/selling/doctype/quotation/quotation.py
+++ b/erpnext/selling/doctype/quotation/quotation.py
@@ -9,6 +9,10 @@ from frappe import _
from erpnext.controllers.selling_controller import SellingController
+form_grid_templates = {
+ "quotation_details": "templates/form_grid/item_grid.html"
+}
+
class Quotation(SellingController):
tname = 'Quotation Item'
fname = 'quotation_details'
diff --git a/erpnext/selling/doctype/quotation/quotation_list.html b/erpnext/selling/doctype/quotation/quotation_list.html
new file mode 100644
index 0000000000..2126b5257a
--- /dev/null
+++ b/erpnext/selling/doctype/quotation/quotation_list.html
@@ -0,0 +1,31 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+
+ {%= doc.customer_name %} ({%= doc.quotation_to %})
+
+
+
+ {% if(doc.order_type==="Service") { %}
+
+ {% } else { %}
+
+ {% } %}
+
+ {%= doc.status %}
+
+
+
+
+ {%= doc.get_formatted("grand_total_export") %}
+
+
+
diff --git a/erpnext/selling/doctype/quotation/quotation_list.js b/erpnext/selling/doctype/quotation/quotation_list.js
new file mode 100644
index 0000000000..91b65eeb9f
--- /dev/null
+++ b/erpnext/selling/doctype/quotation/quotation_list.js
@@ -0,0 +1,5 @@
+frappe.listview_settings['Quotation'] = {
+ add_fields: ["customer_name", "quotation_to", "grand_total", "status",
+ "company", "currency", "order_type", "lead", "customer"],
+ filters: [["status", "=", "Submitted"]]
+};
diff --git a/erpnext/selling/doctype/sales_order/sales_order.py b/erpnext/selling/doctype/sales_order/sales_order.py
index e0a7a1d62d..37b26fdb48 100644
--- a/erpnext/selling/doctype/sales_order/sales_order.py
+++ b/erpnext/selling/doctype/sales_order/sales_order.py
@@ -12,6 +12,10 @@ from frappe.model.mapper import get_mapped_doc
from erpnext.controllers.selling_controller import SellingController
+form_grid_templates = {
+ "sales_order_details": "templates/form_grid/item_grid.html"
+}
+
class SalesOrder(SellingController):
tname = 'Sales Order Item'
fname = 'sales_order_details'
diff --git a/erpnext/selling/doctype/sales_order/sales_order_list.html b/erpnext/selling/doctype/sales_order/sales_order_list.html
new file mode 100644
index 0000000000..4079b2a6e7
--- /dev/null
+++ b/erpnext/selling/doctype/sales_order/sales_order_list.html
@@ -0,0 +1,48 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+
+ {%= doc.customer_name %}
+ {% if(doc.per_delivered < 100 && doc.status!=="Stopped") { %}
+ {% if(frappe.datetime.get_diff(doc.delivery_date) < 0) { %}
+
+ {%= __("Overdue") %}
+
+ {% } else { %}
+
+ {%= doc.get_formatted("delivery_date")%}
+ {% } %}
+ {% } %}
+ {% if(doc.per_delivered == 100 && doc.status!=="Stopped") { %}
+
+
+ {% } %}
+ {% if(doc.status==="Stopped") { %}
+ {%= __("Stopped") %}
+ {% } %}
+
+
+
+ {% var completed = doc.per_delivered, title = __("Delivered") %}
+ {% include "templates/form_grid/includes/progress.html" %}
+
+
+ {% var completed = doc.per_billed, title = __("Billed") %}
+ {% include "templates/form_grid/includes/progress.html" %}
+
+
+
+ {%= doc.get_formatted("grand_total_export") %}
+
+
+
diff --git a/erpnext/selling/doctype/sales_order/sales_order_list.js b/erpnext/selling/doctype/sales_order/sales_order_list.js
new file mode 100644
index 0000000000..3884526e72
--- /dev/null
+++ b/erpnext/selling/doctype/sales_order/sales_order_list.js
@@ -0,0 +1,5 @@
+frappe.listview_settings['Sales Order'] = {
+ add_fields: ["grand_total", "company", "currency", "customer",
+ "customer_name", "per_delivered", "per_billed", "delivery_date"],
+ filters: [["per_delivered", "<", 100]]
+};
diff --git a/erpnext/selling/doctype/sales_order_item/sales_order_item.json b/erpnext/selling/doctype/sales_order_item/sales_order_item.json
index eb0c024723..4ea3fecfde 100644
--- a/erpnext/selling/doctype/sales_order_item/sales_order_item.json
+++ b/erpnext/selling/doctype/sales_order_item/sales_order_item.json
@@ -1,443 +1,443 @@
{
- "autoname": "SOD/.#####",
- "creation": "2013-03-07 11:42:58",
- "docstatus": 0,
- "doctype": "DocType",
+ "autoname": "SOD/.#####",
+ "creation": "2013-03-07 11:42:58",
+ "docstatus": 0,
+ "doctype": "DocType",
"fields": [
{
- "fieldname": "item_code",
- "fieldtype": "Link",
- "in_filter": 1,
- "in_list_view": 1,
- "label": "Item Code",
- "oldfieldname": "item_code",
- "oldfieldtype": "Link",
- "options": "Item",
- "permlevel": 0,
- "print_width": "150px",
- "read_only": 0,
- "reqd": 1,
- "search_index": 1,
+ "fieldname": "item_code",
+ "fieldtype": "Link",
+ "in_filter": 1,
+ "in_list_view": 1,
+ "label": "Item Code",
+ "oldfieldname": "item_code",
+ "oldfieldtype": "Link",
+ "options": "Item",
+ "permlevel": 0,
+ "print_width": "150px",
+ "read_only": 0,
+ "reqd": 1,
+ "search_index": 1,
"width": "150px"
- },
+ },
{
- "fieldname": "customer_item_code",
- "fieldtype": "Data",
- "hidden": 1,
- "in_list_view": 0,
- "label": "Customer's Item Code",
- "permlevel": 0,
- "print_hide": 1,
+ "fieldname": "customer_item_code",
+ "fieldtype": "Data",
+ "hidden": 1,
+ "in_list_view": 0,
+ "label": "Customer's Item Code",
+ "permlevel": 0,
+ "print_hide": 1,
"read_only": 1
- },
+ },
{
- "fieldname": "item_name",
- "fieldtype": "Data",
- "in_list_view": 0,
- "label": "Item Name",
- "oldfieldname": "item_name",
- "oldfieldtype": "Data",
- "permlevel": 0,
- "print_hide": 1,
- "print_width": "150",
- "read_only": 0,
- "reqd": 1,
+ "fieldname": "item_name",
+ "fieldtype": "Data",
+ "in_list_view": 0,
+ "label": "Item Name",
+ "oldfieldname": "item_name",
+ "oldfieldtype": "Data",
+ "permlevel": 0,
+ "print_hide": 1,
+ "print_width": "150",
+ "read_only": 0,
+ "reqd": 1,
"width": "150"
- },
+ },
{
- "fieldname": "col_break1",
- "fieldtype": "Column Break",
+ "fieldname": "col_break1",
+ "fieldtype": "Column Break",
"permlevel": 0
- },
+ },
{
- "fieldname": "description",
- "fieldtype": "Small Text",
- "in_filter": 1,
- "in_list_view": 1,
- "label": "Description",
- "oldfieldname": "description",
- "oldfieldtype": "Small Text",
- "permlevel": 0,
- "print_width": "300px",
- "read_only": 0,
- "reqd": 1,
- "search_index": 1,
+ "fieldname": "description",
+ "fieldtype": "Small Text",
+ "in_filter": 1,
+ "in_list_view": 1,
+ "label": "Description",
+ "oldfieldname": "description",
+ "oldfieldtype": "Small Text",
+ "permlevel": 0,
+ "print_width": "300px",
+ "read_only": 0,
+ "reqd": 1,
+ "search_index": 1,
"width": "300px"
- },
+ },
{
- "fieldname": "quantity_and_rate",
- "fieldtype": "Section Break",
- "in_list_view": 0,
- "label": "Quantity and Rate",
+ "fieldname": "quantity_and_rate",
+ "fieldtype": "Section Break",
+ "in_list_view": 0,
+ "label": "Quantity and Rate",
"permlevel": 0
- },
+ },
{
- "fieldname": "qty",
- "fieldtype": "Float",
- "in_list_view": 1,
- "label": "Quantity",
- "oldfieldname": "qty",
- "oldfieldtype": "Currency",
- "permlevel": 0,
- "print_width": "100px",
- "read_only": 0,
- "reqd": 1,
+ "fieldname": "qty",
+ "fieldtype": "Float",
+ "in_list_view": 1,
+ "label": "Quantity",
+ "oldfieldname": "qty",
+ "oldfieldtype": "Currency",
+ "permlevel": 0,
+ "print_width": "100px",
+ "read_only": 0,
+ "reqd": 1,
"width": "100px"
- },
+ },
{
- "fieldname": "price_list_rate",
- "fieldtype": "Currency",
- "in_list_view": 0,
- "label": "Price List Rate",
- "oldfieldname": "ref_rate",
- "oldfieldtype": "Currency",
- "options": "currency",
- "permlevel": 0,
- "print_hide": 1,
- "print_width": "70px",
- "read_only": 1,
- "reqd": 0,
+ "fieldname": "price_list_rate",
+ "fieldtype": "Currency",
+ "in_list_view": 0,
+ "label": "Price List Rate",
+ "oldfieldname": "ref_rate",
+ "oldfieldtype": "Currency",
+ "options": "currency",
+ "permlevel": 0,
+ "print_hide": 1,
+ "print_width": "70px",
+ "read_only": 1,
+ "reqd": 0,
"width": "70px"
- },
+ },
{
- "fieldname": "discount_percentage",
- "fieldtype": "Percent",
- "in_list_view": 0,
- "label": "Discount(%)",
- "oldfieldname": "adj_rate",
- "oldfieldtype": "Float",
- "permlevel": 0,
- "print_hide": 1,
- "print_width": "70px",
- "read_only": 0,
+ "fieldname": "discount_percentage",
+ "fieldtype": "Float",
+ "in_list_view": 0,
+ "label": "Discount(%)",
+ "oldfieldname": "adj_rate",
+ "oldfieldtype": "Float",
+ "permlevel": 0,
+ "print_hide": 1,
+ "print_width": "70px",
+ "read_only": 0,
"width": "70px"
- },
+ },
{
- "fieldname": "col_break2",
- "fieldtype": "Column Break",
+ "fieldname": "col_break2",
+ "fieldtype": "Column Break",
"permlevel": 0
- },
+ },
{
- "fieldname": "stock_uom",
- "fieldtype": "Link",
- "hidden": 0,
- "in_list_view": 0,
- "label": "UOM",
- "oldfieldname": "stock_uom",
- "oldfieldtype": "Data",
- "options": "UOM",
- "permlevel": 0,
- "print_width": "70px",
- "read_only": 1,
- "reqd": 0,
+ "fieldname": "stock_uom",
+ "fieldtype": "Link",
+ "hidden": 0,
+ "in_list_view": 0,
+ "label": "UOM",
+ "oldfieldname": "stock_uom",
+ "oldfieldtype": "Data",
+ "options": "UOM",
+ "permlevel": 0,
+ "print_width": "70px",
+ "read_only": 1,
+ "reqd": 0,
"width": "70px"
- },
+ },
{
- "fieldname": "base_price_list_rate",
- "fieldtype": "Currency",
- "in_list_view": 0,
- "label": "Price List Rate (Company Currency)",
- "oldfieldname": "base_ref_rate",
- "oldfieldtype": "Currency",
- "options": "Company:company:default_currency",
- "permlevel": 0,
- "print_hide": 1,
- "print_width": "100px",
- "read_only": 1,
+ "fieldname": "base_price_list_rate",
+ "fieldtype": "Currency",
+ "in_list_view": 0,
+ "label": "Price List Rate (Company Currency)",
+ "oldfieldname": "base_ref_rate",
+ "oldfieldtype": "Currency",
+ "options": "Company:company:default_currency",
+ "permlevel": 0,
+ "print_hide": 1,
+ "print_width": "100px",
+ "read_only": 1,
"width": "100px"
- },
+ },
{
- "fieldname": "section_break_simple1",
- "fieldtype": "Section Break",
+ "fieldname": "section_break_simple1",
+ "fieldtype": "Section Break",
"permlevel": 0
- },
+ },
{
- "fieldname": "rate",
- "fieldtype": "Currency",
- "in_list_view": 1,
- "label": "Rate",
- "oldfieldname": "export_rate",
- "oldfieldtype": "Currency",
- "options": "currency",
- "permlevel": 0,
- "print_width": "100px",
- "read_only": 0,
- "reqd": 0,
+ "fieldname": "rate",
+ "fieldtype": "Currency",
+ "in_list_view": 1,
+ "label": "Rate",
+ "oldfieldname": "export_rate",
+ "oldfieldtype": "Currency",
+ "options": "currency",
+ "permlevel": 0,
+ "print_width": "100px",
+ "read_only": 0,
+ "reqd": 0,
"width": "100px"
- },
+ },
{
- "fieldname": "amount",
- "fieldtype": "Currency",
- "in_list_view": 1,
- "label": "Amount",
- "no_copy": 0,
- "oldfieldname": "export_amount",
- "oldfieldtype": "Currency",
- "options": "currency",
- "permlevel": 0,
- "print_width": "100px",
- "read_only": 1,
- "reqd": 0,
+ "fieldname": "amount",
+ "fieldtype": "Currency",
+ "in_list_view": 1,
+ "label": "Amount",
+ "no_copy": 0,
+ "oldfieldname": "export_amount",
+ "oldfieldtype": "Currency",
+ "options": "currency",
+ "permlevel": 0,
+ "print_width": "100px",
+ "read_only": 1,
+ "reqd": 0,
"width": "100px"
- },
+ },
{
- "fieldname": "col_break3",
- "fieldtype": "Column Break",
+ "fieldname": "col_break3",
+ "fieldtype": "Column Break",
"permlevel": 0
- },
+ },
{
- "fieldname": "base_rate",
- "fieldtype": "Currency",
- "in_list_view": 0,
- "label": "Basic Rate (Company Currency)",
- "oldfieldname": "basic_rate",
- "oldfieldtype": "Currency",
- "options": "Company:company:default_currency",
- "permlevel": 0,
- "print_hide": 1,
- "print_width": "100px",
- "read_only": 1,
- "reqd": 0,
+ "fieldname": "base_rate",
+ "fieldtype": "Currency",
+ "in_list_view": 0,
+ "label": "Basic Rate (Company Currency)",
+ "oldfieldname": "basic_rate",
+ "oldfieldtype": "Currency",
+ "options": "Company:company:default_currency",
+ "permlevel": 0,
+ "print_hide": 1,
+ "print_width": "100px",
+ "read_only": 1,
+ "reqd": 0,
"width": "100px"
- },
+ },
{
- "fieldname": "base_amount",
- "fieldtype": "Currency",
- "in_list_view": 0,
- "label": "Amount (Company Currency)",
- "no_copy": 0,
- "oldfieldname": "amount",
- "oldfieldtype": "Currency",
- "options": "Company:company:default_currency",
- "permlevel": 0,
- "print_hide": 1,
- "print_width": "100px",
- "read_only": 1,
- "reqd": 0,
+ "fieldname": "base_amount",
+ "fieldtype": "Currency",
+ "in_list_view": 0,
+ "label": "Amount (Company Currency)",
+ "no_copy": 0,
+ "oldfieldname": "amount",
+ "oldfieldtype": "Currency",
+ "options": "Company:company:default_currency",
+ "permlevel": 0,
+ "print_hide": 1,
+ "print_width": "100px",
+ "read_only": 1,
+ "reqd": 0,
"width": "100px"
- },
+ },
{
- "fieldname": "pricing_rule",
- "fieldtype": "Link",
- "label": "Pricing Rule",
- "options": "Pricing Rule",
- "permlevel": 0,
+ "fieldname": "pricing_rule",
+ "fieldtype": "Link",
+ "label": "Pricing Rule",
+ "options": "Pricing Rule",
+ "permlevel": 0,
"read_only": 1
- },
+ },
{
- "fieldname": "warehouse_and_reference",
- "fieldtype": "Section Break",
- "in_list_view": 0,
- "label": "Warehouse and Reference",
+ "fieldname": "warehouse_and_reference",
+ "fieldtype": "Section Break",
+ "in_list_view": 0,
+ "label": "Warehouse and Reference",
"permlevel": 0
- },
+ },
{
- "fieldname": "warehouse",
- "fieldtype": "Link",
- "in_list_view": 0,
- "label": "Reserved Warehouse",
- "no_copy": 0,
- "oldfieldname": "reserved_warehouse",
- "oldfieldtype": "Link",
- "options": "Warehouse",
- "permlevel": 0,
- "print_hide": 1,
- "print_width": "150px",
- "read_only": 0,
- "reqd": 0,
+ "fieldname": "warehouse",
+ "fieldtype": "Link",
+ "in_list_view": 0,
+ "label": "Reserved Warehouse",
+ "no_copy": 0,
+ "oldfieldname": "reserved_warehouse",
+ "oldfieldtype": "Link",
+ "options": "Warehouse",
+ "permlevel": 0,
+ "print_hide": 1,
+ "print_width": "150px",
+ "read_only": 0,
+ "reqd": 0,
"width": "150px"
- },
+ },
{
- "fieldname": "prevdoc_docname",
- "fieldtype": "Link",
- "hidden": 0,
- "in_filter": 1,
- "in_list_view": 0,
- "label": "Quotation",
- "no_copy": 1,
- "oldfieldname": "prevdoc_docname",
- "oldfieldtype": "Link",
- "options": "Quotation",
- "permlevel": 0,
- "print_hide": 1,
- "read_only": 1,
+ "fieldname": "prevdoc_docname",
+ "fieldtype": "Link",
+ "hidden": 0,
+ "in_filter": 1,
+ "in_list_view": 0,
+ "label": "Quotation",
+ "no_copy": 1,
+ "oldfieldname": "prevdoc_docname",
+ "oldfieldtype": "Link",
+ "options": "Quotation",
+ "permlevel": 0,
+ "print_hide": 1,
+ "read_only": 1,
"search_index": 1
- },
+ },
{
- "fieldname": "brand",
- "fieldtype": "Link",
- "hidden": 1,
- "in_filter": 1,
- "in_list_view": 0,
- "label": "Brand Name",
- "oldfieldname": "brand",
- "oldfieldtype": "Link",
- "options": "Brand",
- "permlevel": 0,
- "print_hide": 1,
- "read_only": 1,
+ "fieldname": "brand",
+ "fieldtype": "Link",
+ "hidden": 1,
+ "in_filter": 1,
+ "in_list_view": 0,
+ "label": "Brand Name",
+ "oldfieldname": "brand",
+ "oldfieldtype": "Link",
+ "options": "Brand",
+ "permlevel": 0,
+ "print_hide": 1,
+ "read_only": 1,
"search_index": 1
- },
+ },
{
- "description": "Add / Edit",
- "fieldname": "item_group",
- "fieldtype": "Link",
- "hidden": 1,
- "in_filter": 1,
- "in_list_view": 0,
- "label": "Item Group",
- "oldfieldname": "item_group",
- "oldfieldtype": "Link",
- "options": "Item Group",
- "permlevel": 0,
- "print_hide": 1,
- "read_only": 1,
+ "description": "Add / Edit",
+ "fieldname": "item_group",
+ "fieldtype": "Link",
+ "hidden": 1,
+ "in_filter": 1,
+ "in_list_view": 0,
+ "label": "Item Group",
+ "oldfieldname": "item_group",
+ "oldfieldtype": "Link",
+ "options": "Item Group",
+ "permlevel": 0,
+ "print_hide": 1,
+ "read_only": 1,
"search_index": 1
- },
+ },
{
- "allow_on_submit": 1,
- "fieldname": "page_break",
- "fieldtype": "Check",
- "in_list_view": 0,
- "label": "Page Break",
- "oldfieldname": "page_break",
- "oldfieldtype": "Check",
- "permlevel": 0,
- "print_hide": 1,
- "read_only": 0,
+ "allow_on_submit": 1,
+ "fieldname": "page_break",
+ "fieldtype": "Check",
+ "in_list_view": 0,
+ "label": "Page Break",
+ "oldfieldname": "page_break",
+ "oldfieldtype": "Check",
+ "permlevel": 0,
+ "print_hide": 1,
+ "read_only": 0,
"report_hide": 1
- },
+ },
{
- "fieldname": "col_break4",
- "fieldtype": "Column Break",
+ "fieldname": "col_break4",
+ "fieldtype": "Column Break",
"permlevel": 0
- },
+ },
{
- "fieldname": "projected_qty",
- "fieldtype": "Float",
- "hidden": 1,
- "in_list_view": 0,
- "label": "Projected Qty",
- "no_copy": 1,
- "oldfieldname": "projected_qty",
- "oldfieldtype": "Currency",
- "permlevel": 0,
- "print_hide": 1,
- "print_width": "70px",
- "read_only": 1,
+ "fieldname": "projected_qty",
+ "fieldtype": "Float",
+ "hidden": 0,
+ "in_list_view": 0,
+ "label": "Projected Qty",
+ "no_copy": 1,
+ "oldfieldname": "projected_qty",
+ "oldfieldtype": "Currency",
+ "permlevel": 0,
+ "print_hide": 1,
+ "print_width": "70px",
+ "read_only": 1,
"width": "70px"
- },
+ },
{
- "fieldname": "actual_qty",
- "fieldtype": "Float",
- "in_list_view": 0,
- "label": "Actual Qty",
- "no_copy": 1,
- "permlevel": 0,
- "print_hide": 1,
- "print_width": "70px",
- "read_only": 1,
+ "fieldname": "actual_qty",
+ "fieldtype": "Float",
+ "in_list_view": 0,
+ "label": "Actual Qty",
+ "no_copy": 1,
+ "permlevel": 0,
+ "print_hide": 1,
+ "print_width": "70px",
+ "read_only": 1,
"width": "70px"
- },
+ },
{
- "fieldname": "delivered_qty",
- "fieldtype": "Float",
- "hidden": 0,
- "in_filter": 0,
- "in_list_view": 0,
- "label": "Delivered Qty",
- "no_copy": 1,
- "oldfieldname": "delivered_qty",
- "oldfieldtype": "Currency",
- "permlevel": 0,
- "print_hide": 1,
- "print_width": "100px",
- "read_only": 1,
- "search_index": 0,
+ "fieldname": "delivered_qty",
+ "fieldtype": "Float",
+ "hidden": 0,
+ "in_filter": 0,
+ "in_list_view": 0,
+ "label": "Delivered Qty",
+ "no_copy": 1,
+ "oldfieldname": "delivered_qty",
+ "oldfieldtype": "Currency",
+ "permlevel": 0,
+ "print_hide": 1,
+ "print_width": "100px",
+ "read_only": 1,
+ "search_index": 0,
"width": "100px"
- },
+ },
{
- "fieldname": "billed_amt",
- "fieldtype": "Currency",
- "in_list_view": 0,
- "label": "Billed Amt",
- "no_copy": 1,
- "options": "currency",
- "permlevel": 0,
- "print_hide": 1,
+ "fieldname": "billed_amt",
+ "fieldtype": "Currency",
+ "in_list_view": 0,
+ "label": "Billed Amt",
+ "no_copy": 1,
+ "options": "currency",
+ "permlevel": 0,
+ "print_hide": 1,
"read_only": 1
- },
+ },
{
- "description": "For Production",
- "fieldname": "planned_qty",
- "fieldtype": "Float",
- "hidden": 1,
- "in_list_view": 0,
- "label": "Planned Quantity",
- "no_copy": 1,
- "oldfieldname": "planned_qty",
- "oldfieldtype": "Currency",
- "permlevel": 0,
- "print_hide": 1,
- "print_width": "50px",
- "read_only": 1,
- "report_hide": 1,
+ "description": "For Production",
+ "fieldname": "planned_qty",
+ "fieldtype": "Float",
+ "hidden": 1,
+ "in_list_view": 0,
+ "label": "Planned Quantity",
+ "no_copy": 1,
+ "oldfieldname": "planned_qty",
+ "oldfieldtype": "Currency",
+ "permlevel": 0,
+ "print_hide": 1,
+ "print_width": "50px",
+ "read_only": 1,
+ "report_hide": 1,
"width": "50px"
- },
+ },
{
- "description": "For Production",
- "fieldname": "produced_qty",
- "fieldtype": "Float",
- "hidden": 1,
- "in_list_view": 0,
- "label": "Produced Quantity",
- "oldfieldname": "produced_qty",
- "oldfieldtype": "Currency",
- "permlevel": 0,
- "print_hide": 1,
- "print_width": "50px",
- "read_only": 1,
- "report_hide": 1,
+ "description": "For Production",
+ "fieldname": "produced_qty",
+ "fieldtype": "Float",
+ "hidden": 1,
+ "in_list_view": 0,
+ "label": "Produced Quantity",
+ "oldfieldname": "produced_qty",
+ "oldfieldtype": "Currency",
+ "permlevel": 0,
+ "print_hide": 1,
+ "print_width": "50px",
+ "read_only": 1,
+ "report_hide": 1,
"width": "50px"
- },
+ },
{
- "fieldname": "item_tax_rate",
- "fieldtype": "Small Text",
- "hidden": 1,
- "in_list_view": 0,
- "label": "Item Tax Rate",
- "oldfieldname": "item_tax_rate",
- "oldfieldtype": "Small Text",
- "permlevel": 0,
- "print_hide": 1,
- "read_only": 1,
+ "fieldname": "item_tax_rate",
+ "fieldtype": "Small Text",
+ "hidden": 1,
+ "in_list_view": 0,
+ "label": "Item Tax Rate",
+ "oldfieldname": "item_tax_rate",
+ "oldfieldtype": "Small Text",
+ "permlevel": 0,
+ "print_hide": 1,
+ "read_only": 1,
"report_hide": 1
- },
+ },
{
- "description": "Used for Production Plan",
- "fieldname": "transaction_date",
- "fieldtype": "Date",
- "hidden": 1,
- "in_filter": 0,
- "in_list_view": 0,
- "label": "Sales Order Date",
- "oldfieldname": "transaction_date",
- "oldfieldtype": "Date",
- "permlevel": 0,
- "print_hide": 1,
- "read_only": 1,
- "report_hide": 1,
+ "description": "Used for Production Plan",
+ "fieldname": "transaction_date",
+ "fieldtype": "Date",
+ "hidden": 1,
+ "in_filter": 0,
+ "in_list_view": 0,
+ "label": "Sales Order Date",
+ "oldfieldname": "transaction_date",
+ "oldfieldtype": "Date",
+ "permlevel": 0,
+ "print_hide": 1,
+ "read_only": 1,
+ "report_hide": 1,
"search_index": 0
}
- ],
- "idx": 1,
- "istable": 1,
- "modified": "2014-07-31 04:55:10.143164",
- "modified_by": "Administrator",
- "module": "Selling",
- "name": "Sales Order Item",
- "owner": "Administrator",
- "permissions": [],
- "sort_field": "modified",
+ ],
+ "idx": 1,
+ "istable": 1,
+ "modified": "2014-07-31 04:55:10.143164",
+ "modified_by": "Administrator",
+ "module": "Selling",
+ "name": "Sales Order Item",
+ "owner": "Administrator",
+ "permissions": [],
+ "sort_field": "modified",
"sort_order": "DESC"
-}
\ No newline at end of file
+}
diff --git a/erpnext/stock/doctype/batch/batch_list.html b/erpnext/stock/doctype/batch/batch_list.html
new file mode 100644
index 0000000000..dc29905dca
--- /dev/null
+++ b/erpnext/stock/doctype/batch/batch_list.html
@@ -0,0 +1,21 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+ {%= doc.item %}
+ {% if(doc.expiry_date && frappe.datetime.get_diff(doc.expiry_date) <= 0) { %}
+
+ {%= __("Expired") %}: {%= doc.get_formatted("expiry_date") %}
+
+ {% } else if(doc.expiry_date) { %}
+
+ {%= __("Expiry") %}: {%= doc.get_formatted("expiry_date") %}
+
+ {% } %}
+
+
+
diff --git a/erpnext/stock/doctype/batch/batch_list.js b/erpnext/stock/doctype/batch/batch_list.js
new file mode 100644
index 0000000000..daeb69bfa4
--- /dev/null
+++ b/erpnext/stock/doctype/batch/batch_list.js
@@ -0,0 +1,3 @@
+frappe.listview_settings['Batch'] = {
+ add_fields: ["item", "expiry_date"]
+};
diff --git a/erpnext/stock/doctype/delivery_note/delivery_note.py b/erpnext/stock/doctype/delivery_note/delivery_note.py
index 54e4fa2acb..e831c47fe7 100644
--- a/erpnext/stock/doctype/delivery_note/delivery_note.py
+++ b/erpnext/stock/doctype/delivery_note/delivery_note.py
@@ -12,6 +12,10 @@ from frappe.model.mapper import get_mapped_doc
from erpnext.stock.utils import update_bin
from erpnext.controllers.selling_controller import SellingController
+form_grid_templates = {
+ "delivery_note_details": "templates/form_grid/item_grid.html"
+}
+
class DeliveryNote(SellingController):
tname = 'Delivery Note Item'
fname = 'delivery_note_details'
diff --git a/erpnext/stock/doctype/delivery_note/delivery_note_list.html b/erpnext/stock/doctype/delivery_note/delivery_note_list.html
new file mode 100644
index 0000000000..de0af976d1
--- /dev/null
+++ b/erpnext/stock/doctype/delivery_note/delivery_note_list.html
@@ -0,0 +1,31 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+
+ {%= doc.customer_name %}
+ {% if(doc.transporter_name) { %}
+
+
+
+ {% } %}
+ {% if(doc.docstatus===0) { %}
+ {%= __("Draft") %}
+ {% } %}
+
+
+
+ {% var completed = doc.per_installed, title=__("% Installed") %}
+ {% include "templates/form_grid/includes/progress.html" %}
+
+
+
+ {%= doc.get_formatted("grand_total_export") %}
+
+
+
diff --git a/erpnext/stock/doctype/delivery_note/delivery_note_list.js b/erpnext/stock/doctype/delivery_note/delivery_note_list.js
new file mode 100644
index 0000000000..c28067d44e
--- /dev/null
+++ b/erpnext/stock/doctype/delivery_note/delivery_note_list.js
@@ -0,0 +1,4 @@
+frappe.listview_settings['Delivery Note'] = {
+ add_fields: ["customer", "customer_name", "grand_total", "per_installed",
+ "transporter_name"]
+};
diff --git a/erpnext/stock/doctype/delivery_note_item/delivery_note_item.json b/erpnext/stock/doctype/delivery_note_item/delivery_note_item.json
index 2f69bc9dc9..8c5cbb7bb5 100644
--- a/erpnext/stock/doctype/delivery_note_item/delivery_note_item.json
+++ b/erpnext/stock/doctype/delivery_note_item/delivery_note_item.json
@@ -109,7 +109,7 @@
},
{
"fieldname": "discount_percentage",
- "fieldtype": "Percent",
+ "fieldtype": "Float",
"in_list_view": 0,
"label": "Discount (%)",
"oldfieldname": "adj_rate",
@@ -365,6 +365,7 @@
"label": "Against Sales Order",
"options": "Sales Order",
"permlevel": 0,
+ "print_hide": 1,
"read_only": 1
},
{
@@ -373,6 +374,7 @@
"label": "Against Sales Invoice",
"options": "Sales Invoice",
"permlevel": 0,
+ "print_hide": 1,
"read_only": 1
},
{
@@ -429,7 +431,7 @@
],
"idx": 1,
"istable": 1,
- "modified": "2014-07-24 05:56:00.218977",
+ "modified": "2014-07-29 06:11:36.636120",
"modified_by": "Administrator",
"module": "Stock",
"name": "Delivery Note Item",
diff --git a/erpnext/stock/doctype/item/item_list.html b/erpnext/stock/doctype/item/item_list.html
new file mode 100644
index 0000000000..ebc2c7f345
--- /dev/null
+++ b/erpnext/stock/doctype/item/item_list.html
@@ -0,0 +1,53 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+ {% if(doc.item_name != doc.name) { %}
+ {%= doc.item_name %}
+ {% } %}
+ {% if(doc.is_stock_item==="Yes") { %}
+
+
+
+ {% } %}
+ {% if(doc.is_sales_item==="Yes") { %}
+
+
+
+ {% } %}
+ {% if(doc.is_purchase_item==="Yes") { %}
+
+
+
+ {% } %}
+ {% if(doc.is_manufactured_item==="Yes") { %}
+
+
+
+ {% } %}
+ {% if(doc.show_in_website) { %}
+
+
+
+ {% } %}
+
+ {%= doc.item_group %}
+
+
+
+ {% if(doc.image) { %}
+

+ {% } %}
+
+
diff --git a/erpnext/stock/doctype/item/item_list.js b/erpnext/stock/doctype/item/item_list.js
new file mode 100644
index 0000000000..330faedf62
--- /dev/null
+++ b/erpnext/stock/doctype/item/item_list.js
@@ -0,0 +1,5 @@
+frappe.listview_settings['Item'] = {
+ add_fields: ["item_name", "stock_uom", "item_group", "image",
+ "is_stock_item", "is_sales_item", "is_purchase_item",
+ "is_manufactured_item", "show_in_website"]
+};
diff --git a/erpnext/stock/doctype/material_request/material_request.py b/erpnext/stock/doctype/material_request/material_request.py
index 9951fc88c2..89121e322c 100644
--- a/erpnext/stock/doctype/material_request/material_request.py
+++ b/erpnext/stock/doctype/material_request/material_request.py
@@ -12,6 +12,11 @@ from frappe import _
from frappe.model.mapper import get_mapped_doc
from erpnext.controllers.buying_controller import BuyingController
+
+form_grid_templates = {
+ "indent_details": "templates/form_grid/material_request_grid.html"
+}
+
class MaterialRequest(BuyingController):
tname = 'Material Request Item'
fname = 'indent_details'
diff --git a/erpnext/stock/doctype/material_request/material_request_list.html b/erpnext/stock/doctype/material_request/material_request_list.html
new file mode 100644
index 0000000000..750f6506ec
--- /dev/null
+++ b/erpnext/stock/doctype/material_request/material_request_list.html
@@ -0,0 +1,28 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+ {% if(doc.material_request_type==="Purchase") { %}
+
+ {% } else { %}
+
+ {% } %}
+
+ {% if(doc.status=="Draft") { %}
+ {%= doc.status %}
+ {% } %}
+ {% if(doc.status=="Submitted" && doc.per_ordered < 100) { %}
+ {%= __("Pending") %}
+ {% } %}
+
+
+
+ {% var completed = doc.per_ordered, title = __("Ordered") %}
+ {% include "templates/form_grid/includes/progress.html" %}
+
+
diff --git a/erpnext/stock/doctype/material_request/material_request_list.js b/erpnext/stock/doctype/material_request/material_request_list.js
new file mode 100644
index 0000000000..989ca60707
--- /dev/null
+++ b/erpnext/stock/doctype/material_request/material_request_list.js
@@ -0,0 +1,4 @@
+frappe.listview_settings['Material Request'] = {
+ add_fields: ["material_request_type", "status", "per_ordered"],
+ filters: [["per_ordered", "<", 100]]
+};
diff --git a/erpnext/stock/doctype/material_request_item/material_request_item.json b/erpnext/stock/doctype/material_request_item/material_request_item.json
index 61b03f8719..56d4121868 100644
--- a/erpnext/stock/doctype/material_request_item/material_request_item.json
+++ b/erpnext/stock/doctype/material_request_item/material_request_item.json
@@ -109,7 +109,7 @@
"allow_on_submit": 0,
"fieldname": "schedule_date",
"fieldtype": "Date",
- "in_list_view": 1,
+ "in_list_view": 0,
"label": "Required Date",
"no_copy": 0,
"oldfieldname": "schedule_date",
@@ -234,7 +234,7 @@
],
"idx": 1,
"istable": 1,
- "modified": "2014-07-18 01:04:18.470761",
+ "modified": "2014-08-07 07:12:47.994668",
"modified_by": "Administrator",
"module": "Stock",
"name": "Material Request Item",
diff --git a/erpnext/stock/doctype/purchase_receipt/purchase_receipt.py b/erpnext/stock/doctype/purchase_receipt/purchase_receipt.py
index 74f1198752..5f56149607 100644
--- a/erpnext/stock/doctype/purchase_receipt/purchase_receipt.py
+++ b/erpnext/stock/doctype/purchase_receipt/purchase_receipt.py
@@ -11,6 +11,11 @@ import frappe.defaults
from erpnext.stock.utils import update_bin
from erpnext.controllers.buying_controller import BuyingController
+
+form_grid_templates = {
+ "purchase_receipt_details": "templates/form_grid/item_grid.html"
+}
+
class PurchaseReceipt(BuyingController):
tname = 'Purchase Receipt Item'
fname = 'purchase_receipt_details'
diff --git a/erpnext/stock/doctype/purchase_receipt/purchase_receipt_list.html b/erpnext/stock/doctype/purchase_receipt/purchase_receipt_list.html
new file mode 100644
index 0000000000..558b160586
--- /dev/null
+++ b/erpnext/stock/doctype/purchase_receipt/purchase_receipt_list.html
@@ -0,0 +1,34 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+
+ {%= doc.supplier_name %}
+ {% if(cint(doc.is_subcontracted)) { %}
+
+
+
+ {% } %}
+ {% if(doc.transporter_name) { %}
+
+
+
+ {% } %}
+ {% if(doc.docstatus===0) { %}
+ {%= __("Draft") %}
+ {% } %}
+
+
+
+
+ {%= doc.get_formatted("grand_total_import") %}
+
+
+
diff --git a/erpnext/stock/doctype/purchase_receipt/purchase_receipt_list.js b/erpnext/stock/doctype/purchase_receipt/purchase_receipt_list.js
new file mode 100644
index 0000000000..7869f7f7da
--- /dev/null
+++ b/erpnext/stock/doctype/purchase_receipt/purchase_receipt_list.js
@@ -0,0 +1,4 @@
+frappe.listview_settings['Purchase Receipt'] = {
+ add_fields: ["supplier", "supplier_name", "grand_total", "is_subcontracted",
+ "transporter_name"]
+};
diff --git a/erpnext/stock/doctype/serial_no/serial_no_list.html b/erpnext/stock/doctype/serial_no/serial_no_list.html
new file mode 100644
index 0000000000..d53aab1906
--- /dev/null
+++ b/erpnext/stock/doctype/serial_no/serial_no_list.html
@@ -0,0 +1,28 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+ {%= doc.item_code %}
+ {% var icon = {
+ "Available": ["icon-ok", "label-success"],
+ "Not Available": ["icon-remove", "label-danger"],
+ "Delivered": ["icon-truck", "label-success"],
+ "Purchase Returned": ["icon-retweet", "label-warning"],
+ "Sales Returned": ["icon-retweet", "label-warning"],
+ }[doc.status]; %}
+
+ {%= doc.status %}
+
+ {% if(doc.warehouse) { %}
+
+ {%= doc.warehouse %}
+
+ {% } %}
+
+
+
diff --git a/erpnext/stock/doctype/serial_no/serial_no_list.js b/erpnext/stock/doctype/serial_no/serial_no_list.js
new file mode 100644
index 0000000000..9a6513895b
--- /dev/null
+++ b/erpnext/stock/doctype/serial_no/serial_no_list.js
@@ -0,0 +1,3 @@
+frappe.listview_settings['Serial No'] = {
+ add_fields: ["status", "item_code", "warehouse"]
+};
diff --git a/erpnext/stock/doctype/stock_entry/stock_entry.py b/erpnext/stock/doctype/stock_entry/stock_entry.py
index 861d967596..1da2ad53d0 100644
--- a/erpnext/stock/doctype/stock_entry/stock_entry.py
+++ b/erpnext/stock/doctype/stock_entry/stock_entry.py
@@ -11,6 +11,7 @@ from frappe import _
from erpnext.stock.utils import get_incoming_rate
from erpnext.stock.stock_ledger import get_previous_sle
from erpnext.controllers.queries import get_match_cond
+from erpnext.stock.get_item_details import get_available_qty
class NotUpdateStockError(frappe.ValidationError): pass
class StockOverReturnError(frappe.ValidationError): pass
@@ -19,8 +20,17 @@ class DuplicateEntryForProductionOrderError(frappe.ValidationError): pass
from erpnext.controllers.stock_controller import StockController
+form_grid_templates = {
+ "mtn_details": "templates/form_grid/stock_entry_grid.html"
+}
+
class StockEntry(StockController):
fname = 'mtn_details'
+ def onload(self):
+ if self.docstatus==1:
+ for item in self.get(self.fname):
+ item.update(get_available_qty(item.item_code,
+ item.s_warehouse))
def validate(self):
self.validate_posting_time()
diff --git a/erpnext/stock/doctype/stock_entry/stock_entry_list.html b/erpnext/stock/doctype/stock_entry/stock_entry_list.html
new file mode 100644
index 0000000000..21794cfbef
--- /dev/null
+++ b/erpnext/stock/doctype/stock_entry/stock_entry_list.html
@@ -0,0 +1,50 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+ {% var icon = {
+ "Material Issue": "icon-arrow-right",
+ "Material Receipt": "icon-arrow-left",
+ "Material Transfer": "icon-resize-horizontal",
+ "Manufacture/Repack": "icon-wrench",
+ "Sales Return": "icon-warning-sign",
+ "Purchase Return": "icon-warning-sign",
+ "Subcontract": "icon-truck"
+ }[doc.purpose]; %}
+
+
+
+ {% if(doc.from_warehouse) { %}
+
+ {%= doc.from_warehouse %}
+
+ {% } %}
+ {% if(doc.from_warehouse || doc.to_warehouse) { %}
+
+ {% } %}
+ {% if(doc.to_warehouse) { %}
+
+ {%= doc.to_warehouse %}
+
+ {% } %}
+ {% if(doc.production_order) { %}
+
+
+
+ {% } %}
+ {% if(doc.bom_no) { %}
+
+
+
+ {% } %}
+
+
+
diff --git a/erpnext/stock/doctype/stock_entry/stock_entry_list.js b/erpnext/stock/doctype/stock_entry/stock_entry_list.js
new file mode 100644
index 0000000000..e6a2abcf76
--- /dev/null
+++ b/erpnext/stock/doctype/stock_entry/stock_entry_list.js
@@ -0,0 +1,3 @@
+frappe.listview_settings['Stock Entry'] = {
+ add_fields: ["from_warehouse", "to_warehouse", "purpose", "production_order", "bom_no"]
+};
diff --git a/erpnext/stock/doctype/stock_entry_detail/stock_entry_detail.json b/erpnext/stock/doctype/stock_entry_detail/stock_entry_detail.json
index 0bdc9a8e5e..e2f2c59d5b 100644
--- a/erpnext/stock/doctype/stock_entry_detail/stock_entry_detail.json
+++ b/erpnext/stock/doctype/stock_entry_detail/stock_entry_detail.json
@@ -1,6 +1,6 @@
{
"autoname": "MTND/.######",
- "creation": "2013-03-29 18:22:12.000000",
+ "creation": "2013-03-29 18:22:12",
"docstatus": 0,
"doctype": "DocType",
"fields": [
@@ -190,7 +190,7 @@
"oldfieldtype": "Link",
"options": "Batch",
"permlevel": 0,
- "print_hide": 1,
+ "print_hide": 0,
"read_only": 0
},
{
@@ -300,9 +300,10 @@
],
"idx": 1,
"istable": 1,
- "modified": "2014-02-03 12:59:27.000000",
+ "modified": "2014-07-29 05:28:21.872968",
"modified_by": "Administrator",
"module": "Stock",
"name": "Stock Entry Detail",
- "owner": "Administrator"
+ "owner": "Administrator",
+ "permissions": []
}
\ No newline at end of file
diff --git a/erpnext/stock/doctype/warehouse/warehouse.json b/erpnext/stock/doctype/warehouse/warehouse.json
index 4e016e6360..0a4c244eb1 100644
--- a/erpnext/stock/doctype/warehouse/warehouse.json
+++ b/erpnext/stock/doctype/warehouse/warehouse.json
@@ -43,6 +43,7 @@
"description": "Account for the warehouse (Perpetual Inventory) will be created under this Account.",
"fieldname": "create_account_under",
"fieldtype": "Link",
+ "in_list_view": 1,
"label": "Parent Account",
"options": "Account",
"permlevel": 0
@@ -150,7 +151,7 @@
],
"icon": "icon-building",
"idx": 1,
- "modified": "2014-05-27 03:49:22.483111",
+ "modified": "2014-08-04 02:55:16.750848",
"modified_by": "Administrator",
"module": "Stock",
"name": "Warehouse",
diff --git a/erpnext/support/doctype/customer_issue/customer_issue_list.html b/erpnext/support/doctype/customer_issue/customer_issue_list.html
new file mode 100644
index 0000000000..6a39f9f273
--- /dev/null
+++ b/erpnext/support/doctype/customer_issue/customer_issue_list.html
@@ -0,0 +1,24 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+
+ {%= doc.customer %}
+
+
+ {%= doc.status %}
+
+
+ {% if(doc.item_code) { %}
+
+ {%= doc.item_code %}
+
+ {% } %}
+
+
+
diff --git a/erpnext/support/doctype/customer_issue/customer_issue_list.js b/erpnext/support/doctype/customer_issue/customer_issue_list.js
new file mode 100644
index 0000000000..f47934ce0b
--- /dev/null
+++ b/erpnext/support/doctype/customer_issue/customer_issue_list.js
@@ -0,0 +1,4 @@
+frappe.listview_settings['Customer Issue'] = {
+ add_fields: ["status", "customer", "item_code"],
+ filters:[["status","=", "Open"]]
+};
diff --git a/erpnext/support/doctype/maintenance_visit/maintenance_visit_list.html b/erpnext/support/doctype/maintenance_visit/maintenance_visit_list.html
new file mode 100644
index 0000000000..2ddef7a974
--- /dev/null
+++ b/erpnext/support/doctype/maintenance_visit/maintenance_visit_list.html
@@ -0,0 +1,35 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+
+
+ {%= doc.customer_name %}
+
+
+ {% var style = {
+ "Scheduled": "default",
+ "Unscheduled": "default",
+ "Breakdown": "danger"
+ }[doc.maintenance_type] %}
+
+ {%= doc.maintenance_type %}
+
+ {% var style = doc.completion_status==="Partially Completed" ? "warning" : "success" %}
+
+ {%= doc.completion_status %}
+
+
+
+
+
+ {% var completed = doc.completed, title = __("Completed") %}
+ {% include "templates/form_grid/includes/progress.html" %}
+
+
diff --git a/erpnext/support/doctype/maintenance_visit/maintenance_visit_list.js b/erpnext/support/doctype/maintenance_visit/maintenance_visit_list.js
new file mode 100644
index 0000000000..77f28d7ab3
--- /dev/null
+++ b/erpnext/support/doctype/maintenance_visit/maintenance_visit_list.js
@@ -0,0 +1,3 @@
+frappe.listview_settings['Maintenance Visit'] = {
+ add_fields: ["customer", "customer_name", "completion_status", "maintenance_type"],
+};
diff --git a/erpnext/support/doctype/newsletter/newsletter.json b/erpnext/support/doctype/newsletter/newsletter.json
index 600ac3fad5..a30dc418b6 100644
--- a/erpnext/support/doctype/newsletter/newsletter.json
+++ b/erpnext/support/doctype/newsletter/newsletter.json
@@ -1,6 +1,6 @@
{
"autoname": "naming_series:",
- "creation": "2013-01-10 16:34:31.000000",
+ "creation": "2013-01-10 16:34:31",
"description": "Create and Send Newsletters",
"docstatus": 0,
"doctype": "DocType",
@@ -132,7 +132,7 @@
],
"icon": "icon-envelope",
"idx": 1,
- "modified": "2014-02-03 11:32:22.000000",
+ "modified": "2014-08-04 07:22:06.445634",
"modified_by": "Administrator",
"module": "Support",
"name": "Newsletter",
diff --git a/erpnext/support/doctype/newsletter/newsletter_list.html b/erpnext/support/doctype/newsletter/newsletter_list.html
new file mode 100644
index 0000000000..5bbe104808
--- /dev/null
+++ b/erpnext/support/doctype/newsletter/newsletter_list.html
@@ -0,0 +1,16 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+ {%= cint(doc.email_sent) ? __("Sent") : __("Not Sent") %}
+
+
+ {%= doc.send_to_type %}
+
+
+
+
diff --git a/erpnext/support/doctype/newsletter/newsletter_list.js b/erpnext/support/doctype/newsletter/newsletter_list.js
new file mode 100644
index 0000000000..096b83e4e9
--- /dev/null
+++ b/erpnext/support/doctype/newsletter/newsletter_list.js
@@ -0,0 +1,3 @@
+frappe.listview_settings['Newsletter'] = {
+ add_fields: ["subject", "send_to_type", "email_sent"]
+};
diff --git a/erpnext/support/doctype/support_ticket/support_ticket_list.html b/erpnext/support/doctype/support_ticket/support_ticket_list.html
new file mode 100644
index 0000000000..f2cf9b2603
--- /dev/null
+++ b/erpnext/support/doctype/support_ticket/support_ticket_list.html
@@ -0,0 +1,18 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+ {%= doc.status %}
+
+
+
+
+
+
+ {%= doc.raised_by %}
+
+
+
diff --git a/erpnext/support/doctype/support_ticket/support_ticket_list.js b/erpnext/support/doctype/support_ticket/support_ticket_list.js
new file mode 100644
index 0000000000..1ae4d93708
--- /dev/null
+++ b/erpnext/support/doctype/support_ticket/support_ticket_list.js
@@ -0,0 +1,4 @@
+frappe.listview_settings['Support Ticket'] = {
+ add_fields: ["subject", "status", "raised_by"],
+ filters:[["status","=", "Open"]]
+};
diff --git a/erpnext/templates/form_grid/includes/progress.html b/erpnext/templates/form_grid/includes/progress.html
new file mode 100644
index 0000000000..9cbe5abd64
--- /dev/null
+++ b/erpnext/templates/form_grid/includes/progress.html
@@ -0,0 +1,8 @@
+
diff --git a/erpnext/templates/form_grid/includes/visible_cols.html b/erpnext/templates/form_grid/includes/visible_cols.html
new file mode 100644
index 0000000000..38abdd03f3
--- /dev/null
+++ b/erpnext/templates/form_grid/includes/visible_cols.html
@@ -0,0 +1,13 @@
+{% $.each(visible_columns || [], function(i, df) { %}
+ {% var val = doc.get_formatted(df.fieldname);
+ if(val) { %}
+
+
+ {%= __(df.label) %}:
+
+
+ {%= doc.get_formatted(df.fieldname) %}
+
+
+ {% } %}
+{% }); %}
diff --git a/erpnext/templates/form_grid/item_grid.html b/erpnext/templates/form_grid/item_grid.html
new file mode 100644
index 0000000000..c2e5d56e9d
--- /dev/null
+++ b/erpnext/templates/form_grid/item_grid.html
@@ -0,0 +1,97 @@
+{% var visible_columns = row.get_visible_columns(["item_code", "item_name", "description", "qty", "rate", "amount", "stock_uom", "uom", "discount_percentage", "schedule_date", "warehouse", "against_sales_order", "sales_order"]); %}
+
+{% if(!doc) { %}
+
+
{%= __("Item") %}
+
{%= __("Qty") %}
+
{%= __("Rate") %}
+
{%= __("Amount") %}
+
+{% } else { %}
+
+
{%= doc.item_code %}
+ {% if(doc.item_name != doc.item_code) { %}
+
{%= doc.item_name %}{% } %}
+ {% if(doc.item_name != doc.description) { %}
+
{%= doc.description %}
{% } %}
+ {% if(doc.sales_order || doc.against_sales_order) { %}
+
+
+ {%= doc.sales_order || doc.against_sales_order %}
+
+ {% } %}
+ {% include "templates/form_grid/includes/visible_cols.html" %}
+ {% if(doc.schedule_date) { %}
+
+ {%= doc.get_formatted("schedule_date") %}
+
+ {% } %}
+
+
+
+
+ {%= doc.get_formatted("qty") %}
+
{%= doc.uom || doc.stock_uom %}
+ {% if(in_list(["Sales Order Item", "Purchase Order Item"],
+ doc.doctype) && frm.doc.docstatus===1) {
+ var delivered = doc.doctype==="Sales Order Item" ?
+ doc.delivered_qty : doc.received_qty,
+ completed =
+ 100 - cint((doc.qty - delivered) * 100 / doc.qty),
+ title = __("Delivered");
+ %}
+ {% include "templates/form_grid/includes/progress.html" %}
+ {% } %}
+ {% if(doc.warehouse) {
+ var label_class = "label-default",
+ title = "Warehouse",
+ actual_qty = (doc.doctype==="Sales Order"
+ ? doc.projected_qty : doc.actual_qty);
+ if(actual_qty != undefined) {
+ if(actual_qty > doc.qty) {
+ var label_class = "label-success";
+ var title = "In Stock"
+ } else {
+ var title = "Not In Stock"
+ }
+ }
+ %}
+
+
+ {%= doc.warehouse %}
+
+
+ {% } %}
+
+
+
+
+ {%= doc.get_formatted("rate") %}
+ {% if(doc.discount_percentage) { %}
+
+ {%= -1 * doc.discount_percentage %}%
+ {% }%}
+
+
+
+
+ {%= doc.get_formatted("amount") %}
+ {% if(in_list(["Sales Order Item", "Purchase Order Item"],
+ doc.doctype) && frm.doc.docstatus===1 && doc.amount) {
+ var completed =
+ 100 - cint((doc.amount - doc.billed_amt) * 100 / doc.amount),
+ title = __("Billed");
+ %}
+
+ {% include "templates/form_grid/includes/progress.html" %}
+ {% } %}
+
+
+{% } %}
diff --git a/erpnext/templates/form_grid/material_request_grid.html b/erpnext/templates/form_grid/material_request_grid.html
new file mode 100644
index 0000000000..c30cf582d0
--- /dev/null
+++ b/erpnext/templates/form_grid/material_request_grid.html
@@ -0,0 +1,45 @@
+{% var visible_columns = row.get_visible_columns(["item_code", "warehouse",
+ "item_name", "description", "amount", "stock_uom", "uom", "qty", "schedule_date"]); %}
+
+{% if(!doc) { %}
+
+
{%= __("Item") %}
+
{%= __("Qty") %}
+
+{% } else { %}
+
+
{%= doc.item_code %}
+ {% if(doc.item_name != doc.item_code) { %}
+
{%= doc.item_name %}{% } %}
+ {% if(doc.item_name != doc.description) { %}
+
{%= doc.description %}
{% } %}
+ {% include "templates/form_grid/includes/visible_cols.html" %}
+ {% if(doc.schedule_date) { %}
+
+ {%= doc.get_formatted("schedule_date") %}
+ {% } %}
+
+
+
+
+ {%= doc.get_formatted("qty") %}
+
{%= doc.uom || doc.stock_uom %}
+ {% var completed =
+ 100 - cint((doc.qty - cint(doc.ordered_qty)) * 100 / doc.qty),
+ title = __("Ordered"); %}
+ {% include "templates/form_grid/includes/progress.html" %}
+ {% if(doc.warehouse) { %}
+
+
+ {%= doc.warehouse %}
+
+
+ {% } %}
+
+
+{% } %}
diff --git a/erpnext/templates/form_grid/stock_entry_grid.html b/erpnext/templates/form_grid/stock_entry_grid.html
new file mode 100644
index 0000000000..c5f3ecd899
--- /dev/null
+++ b/erpnext/templates/form_grid/stock_entry_grid.html
@@ -0,0 +1,46 @@
+{% var visible_columns = row.get_visible_columns(["item_code",
+ "item_name", "description", "amount", "stock_uom", "uom", "qty",
+ "s_warehouse", "t_warehouse", "incoming_rate"]);
+%}
+
+{% if(!doc) { %}
+
+
{%= __("Item") %}
+
{%= __("Qty") %}
+
{%= __("Amount") %}
+
+{% } else { %}
+
+
{%= doc.item_code %}
+ {% if(doc.item_name != doc.item_code) { %}
+
{%= doc.item_name %}{% } %}
+ {% if(doc.item_name != doc.description) { %}
+
{%= doc.description %}
{% } %}
+ {% include "templates/form_grid/includes/visible_cols.html" %}
+
+ {% if(doc.s_warehouse) { %}
+ {%= doc.s_warehouse || "" %}{% } %}
+
+ {% if(doc.t_warehouse) { %}
+ {%= doc.t_warehouse || "" %}{% } %}
+
+
+
+
+
+ {%= doc.get_formatted("qty") %}
+
{%= doc.uom || doc.stock_uom %}
+
+
+
+
+ {%= doc.get_formatted("amount") %}
+
+ {%= doc.get_formatted("incoming_rate") %}
+
+
+{% } %}
diff --git a/erpnext/utilities/doctype/address/address_list.js b/erpnext/utilities/doctype/address/address_list.js
new file mode 100644
index 0000000000..5eee8cf6f6
--- /dev/null
+++ b/erpnext/utilities/doctype/address/address_list.js
@@ -0,0 +1,5 @@
+frappe.listview_settings['Address'] = {
+ set_title_left: function() {
+ frappe.set_route("Module", "Selling");
+ }
+}
diff --git a/erpnext/utilities/doctype/contact/contact.json b/erpnext/utilities/doctype/contact/contact.json
index fc5a72189b..c52cfdca51 100644
--- a/erpnext/utilities/doctype/contact/contact.json
+++ b/erpnext/utilities/doctype/contact/contact.json
@@ -16,6 +16,7 @@
{
"fieldname": "first_name",
"fieldtype": "Data",
+ "in_list_view": 0,
"label": "First Name",
"oldfieldname": "first_name",
"oldfieldtype": "Data",
@@ -25,6 +26,7 @@
{
"fieldname": "last_name",
"fieldtype": "Data",
+ "in_list_view": 0,
"label": "Last Name",
"oldfieldname": "last_name",
"oldfieldtype": "Data",
@@ -39,6 +41,7 @@
"default": "Passive",
"fieldname": "status",
"fieldtype": "Select",
+ "in_list_view": 1,
"label": "Status",
"options": "Passive\nOpen\nReplied",
"permlevel": 0
@@ -46,7 +49,7 @@
{
"fieldname": "email_id",
"fieldtype": "Data",
- "in_list_view": 1,
+ "in_list_view": 0,
"label": "Email Id",
"oldfieldname": "email_id",
"oldfieldtype": "Data",
@@ -100,7 +103,7 @@
"depends_on": "eval:!doc.supplier && !doc.sales_partner",
"fieldname": "customer_name",
"fieldtype": "Data",
- "in_list_view": 1,
+ "in_list_view": 0,
"label": "Customer Name",
"permlevel": 0,
"read_only": 1
@@ -125,7 +128,7 @@
"depends_on": "eval:!doc.customer && !doc.sales_partner",
"fieldname": "supplier_name",
"fieldtype": "Data",
- "in_list_view": 1,
+ "in_list_view": 0,
"label": "Supplier Name",
"permlevel": 0,
"read_only": 1
@@ -199,7 +202,7 @@
"idx": 1,
"in_create": 0,
"in_dialog": 0,
- "modified": "2014-05-27 03:49:08.789451",
+ "modified": "2014-07-30 05:44:25.767076",
"modified_by": "Administrator",
"module": "Utilities",
"name": "Contact",
diff --git a/erpnext/utilities/doctype/contact/contact_list.js b/erpnext/utilities/doctype/contact/contact_list.js
new file mode 100644
index 0000000000..5eee8cf6f6
--- /dev/null
+++ b/erpnext/utilities/doctype/contact/contact_list.js
@@ -0,0 +1,5 @@
+frappe.listview_settings['Address'] = {
+ set_title_left: function() {
+ frappe.set_route("Module", "Selling");
+ }
+}
diff --git a/erpnext/utilities/doctype/note/note.json b/erpnext/utilities/doctype/note/note.json
index 6cf756c3aa..66d99f4cd3 100644
--- a/erpnext/utilities/doctype/note/note.json
+++ b/erpnext/utilities/doctype/note/note.json
@@ -9,7 +9,7 @@
{
"fieldname": "title",
"fieldtype": "Data",
- "in_list_view": 1,
+ "in_list_view": 0,
"label": "Title",
"permlevel": 0,
"print_hide": 1,
@@ -19,7 +19,7 @@
"description": "Help: To link to another record in the system, use \"#Form/Note/[Note Name]\" as the Link URL. (don't use \"http://\")",
"fieldname": "content",
"fieldtype": "Text Editor",
- "in_list_view": 1,
+ "in_list_view": 0,
"label": "Content",
"permlevel": 0
},
@@ -49,7 +49,7 @@
],
"icon": "icon-file-text",
"idx": 1,
- "modified": "2014-07-09 12:54:11.897597",
+ "modified": "2014-07-30 03:24:38.302928",
"modified_by": "Administrator",
"module": "Utilities",
"name": "Note",
diff --git a/erpnext/utilities/doctype/note/note_list.html b/erpnext/utilities/doctype/note/note_list.html
new file mode 100644
index 0000000000..e106dd40f6
--- /dev/null
+++ b/erpnext/utilities/doctype/note/note_list.html
@@ -0,0 +1,16 @@
+
+
+
+ {%= list.get_avatar_and_id(doc) %}
+
+ {% if(doc.public) { %}
+
+
+
+ {% } %}
+
+
+
+
diff --git a/erpnext/utilities/doctype/note/note_list.js b/erpnext/utilities/doctype/note/note_list.js
index b188941bc4..a713aca842 100644
--- a/erpnext/utilities/doctype/note/note_list.js
+++ b/erpnext/utilities/doctype/note/note_list.js
@@ -1,4 +1,5 @@
frappe.listview_settings['Note'] = {
+ add_fields: ["title", "public"],
set_title_left: function() {
frappe.set_route();
}
diff --git a/erpnext/utilities/doctype/note/test_note.py b/erpnext/utilities/doctype/note/test_note.py
new file mode 100644
index 0000000000..997c57be17
--- /dev/null
+++ b/erpnext/utilities/doctype/note/test_note.py
@@ -0,0 +1,10 @@
+# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors and Contributors
+# See license.txt
+
+import frappe
+import unittest
+
+test_records = frappe.get_test_records('Note')
+
+class TestNote(unittest.TestCase):
+ pass
diff --git a/erpnext/utilities/doctype/note/test_records.json b/erpnext/utilities/doctype/note/test_records.json
new file mode 100644
index 0000000000..f3d7cff22b
--- /dev/null
+++ b/erpnext/utilities/doctype/note/test_records.json
@@ -0,0 +1,7 @@
+[
+ {
+ "doctype": "Note",
+ "name": "_Test Note 1",
+ "title": "Test Note Title"
+ }
+]