address now not in dialog, added slideshows in products and groups and removed transaction history from customer / supplier / sales partner

This commit is contained in:
Rushabh Mehta
2012-12-27 14:05:02 +05:30
parent 7285a720a0
commit 5f1d57ecb7
30 changed files with 528 additions and 764 deletions

View File

@@ -20,26 +20,4 @@ cur_frm.cscript.onload = function(doc, cdt, cdn) {
cur_frm.fields_dict.customer.get_query = erpnext.utils.customer_query;
cur_frm.fields_dict.supplier.get_query = erpnext.utils.supplier_query;
var route = wn.get_route();
if(route[1]=='Supplier') {
var supplier = wn.container.page.frm.doc;
doc.supplier = supplier.name;
doc.supplier_name = supplier.supplier_name;
doc.address_type = 'Office';
} else if(route[1]=='Customer') {
var customer = wn.container.page.frm.doc;
doc.customer = customer.name;
doc.customer_name = customer.customer_name;
doc.address_type = 'Office';
} else if(route[1]=='Sales Partner') {
var sp = wn.container.page.frm.doc;
doc.sales_partner = sp.name;
doc.address_type = 'Office';
}
}
cur_frm.cscript.hide_dialog = function() {
if(cur_frm.address_list)
cur_frm.address_list.run();
}

View File

@@ -2,23 +2,17 @@
{
"owner": "Administrator",
"docstatus": 0,
"creation": "2012-07-02 19:57:47",
"creation": "2012-07-03 13:30:41",
"modified_by": "Administrator",
"modified": "2012-07-02 20:24:15"
"modified": "2012-12-27 11:31:37"
},
{
"section_style": "Simple",
"name": "__common__",
"search_fields": "customer, supplier, sales_partner, country, state",
"module": "Utilities",
"_last_update": "1319016431",
"allow_trash": 1,
"in_dialog": 1,
"document_type": "Master",
"name": "__common__",
"colour": "White:FFF",
"doctype": "DocType",
"show_in_menu": 0,
"version": 1
"in_dialog": 0,
"document_type": "Master"
},
{
"name": "__common__",
@@ -39,6 +33,187 @@
"name": "Address",
"doctype": "DocType"
},
{
"doctype": "DocField",
"label": "Address Details",
"fieldname": "address_details",
"fieldtype": "Section Break",
"permlevel": 0
},
{
"description": "e.g. Office, Billing, Shipping",
"doctype": "DocField",
"label": "Address Type",
"fieldname": "address_type",
"fieldtype": "Data",
"reqd": 1,
"permlevel": 0
},
{
"description": "Name of person or organization that this address belongs to.",
"doctype": "DocField",
"label": "Address Title",
"fieldname": "address_title",
"fieldtype": "Data",
"permlevel": 0
},
{
"doctype": "DocField",
"label": "Address Line1",
"fieldname": "address_line1",
"fieldtype": "Data",
"reqd": 1,
"permlevel": 0
},
{
"doctype": "DocField",
"label": "Address Line2",
"fieldname": "address_line2",
"fieldtype": "Data",
"permlevel": 0
},
{
"search_index": 1,
"doctype": "DocField",
"label": "City/Town",
"fieldname": "city",
"fieldtype": "Data",
"reqd": 1,
"permlevel": 0,
"in_filter": 1
},
{
"search_index": 1,
"doctype": "DocField",
"label": "Pincode",
"fieldname": "pincode",
"fieldtype": "Data",
"permlevel": 0,
"in_filter": 1
},
{
"search_index": 1,
"doctype": "DocField",
"label": "Country",
"options": "link:Country",
"fieldname": "country",
"fieldtype": "Select",
"reqd": 1,
"permlevel": 0,
"in_filter": 1
},
{
"search_index": 0,
"doctype": "DocField",
"label": "State",
"options": "Suggest",
"fieldname": "state",
"fieldtype": "Data",
"permlevel": 0,
"in_filter": 1
},
{
"print_hide": 0,
"doctype": "DocField",
"width": "50%",
"fieldname": "column_break0",
"fieldtype": "Column Break",
"permlevel": 0
},
{
"doctype": "DocField",
"label": "Phone",
"fieldname": "phone",
"fieldtype": "Data",
"reqd": 1,
"permlevel": 0
},
{
"doctype": "DocField",
"label": "Email Id",
"fieldname": "email_id",
"fieldtype": "Data",
"permlevel": 0
},
{
"doctype": "DocField",
"label": "Fax",
"fieldname": "fax",
"fieldtype": "Data",
"permlevel": 0,
"in_filter": 1
},
{
"description": "Check to make primary address",
"default": "0",
"doctype": "DocField",
"label": "Is Primary Address",
"fieldname": "is_primary_address",
"fieldtype": "Check",
"permlevel": 0
},
{
"description": "Check to make Shipping Address",
"default": "0",
"doctype": "DocField",
"label": "Is Shipping Address",
"fieldname": "is_shipping_address",
"fieldtype": "Check",
"permlevel": 0
},
{
"doctype": "DocField",
"label": "Linked With",
"fieldname": "linked_with",
"fieldtype": "Section Break",
"permlevel": 0
},
{
"depends_on": "eval:!doc.supplier && !doc.sales_partner",
"doctype": "DocField",
"label": "Customer",
"options": "Customer",
"fieldname": "customer",
"fieldtype": "Link",
"permlevel": 0
},
{
"depends_on": "eval:!doc.supplier && !doc.sales_partner",
"doctype": "DocField",
"label": "Customer Name",
"fieldname": "customer_name",
"fieldtype": "Data",
"permlevel": 1,
"in_filter": 1
},
{
"depends_on": "eval:!doc.customer && !doc.sales_partner",
"doctype": "DocField",
"label": "Supplier",
"options": "Supplier",
"fieldname": "supplier",
"fieldtype": "Link",
"permlevel": 0
},
{
"depends_on": "eval:!doc.customer && !doc.sales_partner",
"doctype": "DocField",
"label": "Supplier Name",
"fieldname": "supplier_name",
"fieldtype": "Data",
"search_index": 0,
"permlevel": 1,
"in_filter": 1
},
{
"depends_on": "eval:!doc.customer && !doc.supplier",
"doctype": "DocField",
"label": "Sales Partner",
"options": "Sales Partner",
"fieldname": "sales_partner",
"fieldtype": "Link",
"permlevel": 0
},
{
"create": 1,
"doctype": "DocPerm",
@@ -128,192 +303,5 @@
"role": "All",
"cancel": 0,
"permlevel": 1
},
{
"colour": "White:FFF",
"doctype": "DocField",
"label": "Address Details",
"fieldname": "address_details",
"fieldtype": "Section Break",
"permlevel": 0
},
{
"description": "<em>e.g. Office, Billing, Shipping</em>",
"colour": "White:FFF",
"doctype": "DocField",
"label": "Address Type",
"fieldname": "address_type",
"fieldtype": "Data",
"reqd": 1,
"permlevel": 0
},
{
"colour": "White:FFF",
"doctype": "DocField",
"label": "Address Line1",
"fieldname": "address_line1",
"fieldtype": "Data",
"reqd": 1,
"permlevel": 0
},
{
"doctype": "DocField",
"label": "Address Line2",
"fieldname": "address_line2",
"fieldtype": "Data",
"permlevel": 0
},
{
"search_index": 1,
"colour": "White:FFF",
"doctype": "DocField",
"label": "City/Town",
"fieldname": "city",
"fieldtype": "Data",
"reqd": 1,
"permlevel": 0,
"in_filter": 1
},
{
"search_index": 1,
"doctype": "DocField",
"label": "Pincode",
"fieldname": "pincode",
"fieldtype": "Data",
"permlevel": 0,
"in_filter": 1
},
{
"search_index": 1,
"colour": "White:FFF",
"doctype": "DocField",
"label": "Country",
"trigger": "Client",
"fieldname": "country",
"fieldtype": "Select",
"reqd": 1,
"options": "link:Country",
"permlevel": 0,
"in_filter": 1
},
{
"search_index": 0,
"colour": "White:FFF",
"doctype": "DocField",
"label": "State",
"permlevel": 0,
"fieldname": "state",
"fieldtype": "Data",
"options": "Suggest",
"in_filter": 1
},
{
"print_hide": 0,
"doctype": "DocField",
"width": "50%",
"fieldname": "column_break0",
"fieldtype": "Column Break",
"permlevel": 0
},
{
"doctype": "DocField",
"label": "Phone",
"fieldname": "phone",
"fieldtype": "Data",
"reqd": 1,
"permlevel": 0
},
{
"doctype": "DocField",
"label": "Email Id",
"fieldname": "email_id",
"fieldtype": "Data",
"permlevel": 0
},
{
"doctype": "DocField",
"label": "Fax",
"fieldname": "fax",
"fieldtype": "Data",
"permlevel": 0,
"in_filter": 1
},
{
"depends_on": "eval:!doc.supplier && !doc.sales_partner",
"colour": "White:FFF",
"doctype": "DocField",
"label": "Customer",
"permlevel": 0,
"fieldname": "customer",
"fieldtype": "Link",
"options": "Customer"
},
{
"depends_on": "eval:!doc.supplier && !doc.sales_partner",
"colour": "White:FFF",
"doctype": "DocField",
"label": "Customer Name",
"fieldname": "customer_name",
"fieldtype": "Data",
"permlevel": 1,
"in_filter": 1
},
{
"depends_on": "eval:!doc.customer && !doc.sales_partner",
"colour": "White:FFF",
"doctype": "DocField",
"label": "Supplier",
"permlevel": 0,
"fieldname": "supplier",
"fieldtype": "Link",
"options": "Supplier"
},
{
"search_index": 0,
"colour": "White:FFF",
"doctype": "DocField",
"label": "Supplier Name",
"fieldname": "supplier_name",
"fieldtype": "Data",
"depends_on": "eval:!doc.customer && !doc.sales_partner",
"permlevel": 1,
"in_filter": 1
},
{
"depends_on": "eval:!doc.customer && !doc.supplier",
"colour": "White:FFF",
"doctype": "DocField",
"label": "Sales Partner",
"permlevel": 0,
"fieldname": "sales_partner",
"fieldtype": "Link",
"options": "Sales Partner"
},
{
"description": "Check to make primary address",
"default": "0",
"colour": "White:FFF",
"doctype": "DocField",
"label": "Is Primary Address",
"fieldname": "is_primary_address",
"fieldtype": "Check",
"permlevel": 0
},
{
"description": "Check to make Shipping Address",
"default": "0",
"colour": "White:FFF",
"doctype": "DocField",
"label": "Is Shipping Address",
"fieldname": "is_shipping_address",
"fieldtype": "Check",
"permlevel": 0
},
{
"doctype": "DocField",
"label": "Trash Reason",
"fieldname": "trash_reason",
"fieldtype": "Small Text",
"permlevel": 0
}
]