mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-26 00:14:50 +00:00
Merge branch 'master' of github.com:webnotes/erpnext
This commit is contained in:
@@ -1,49 +0,0 @@
|
||||
[
|
||||
{
|
||||
"owner": "ashwini@webnotestech.com",
|
||||
"docstatus": 0,
|
||||
"creation": "2010-09-01 15:47:59",
|
||||
"modified_by": "Administrator",
|
||||
"modified": "2012-04-03 12:49:50"
|
||||
},
|
||||
{
|
||||
"match_id": 0,
|
||||
"parent": "Project-Sales Invoice",
|
||||
"name": "__common__",
|
||||
"doctype": "Table Mapper Detail",
|
||||
"parenttype": "DocType Mapper",
|
||||
"from_table": "Project",
|
||||
"to_table": "Sales Invoice",
|
||||
"validation_logic": "name is not null",
|
||||
"parentfield": "table_mapper_details"
|
||||
},
|
||||
{
|
||||
"map": "Yes",
|
||||
"match_id": 0,
|
||||
"parent": "Project-Sales Invoice",
|
||||
"name": "__common__",
|
||||
"to_field": "customer",
|
||||
"doctype": "Field Mapper Detail",
|
||||
"parenttype": "DocType Mapper",
|
||||
"checking_operator": "=",
|
||||
"from_field": "customer",
|
||||
"parentfield": "field_mapper_details"
|
||||
},
|
||||
{
|
||||
"name": "__common__",
|
||||
"to_doctype": "Sales Invoice",
|
||||
"module": "Accounts",
|
||||
"doctype": "DocType Mapper",
|
||||
"from_doctype": "Project"
|
||||
},
|
||||
{
|
||||
"name": "Project-Sales Invoice",
|
||||
"doctype": "DocType Mapper"
|
||||
},
|
||||
{
|
||||
"doctype": "Field Mapper Detail"
|
||||
},
|
||||
{
|
||||
"doctype": "Table Mapper Detail"
|
||||
}
|
||||
]
|
||||
@@ -264,13 +264,6 @@ cur_frm.cscript.write_off_amount = function(doc) {
|
||||
}
|
||||
|
||||
|
||||
//---- get customer details ----------------------------
|
||||
cur_frm.cscript.project_name = function(doc,cdt,cdn){
|
||||
$c_obj(make_doclist(doc.doctype, doc.name),'pull_project_customer','', function(r,rt){
|
||||
refresh_many(['customer', 'customer_name','customer_address', 'territory']);
|
||||
});
|
||||
}
|
||||
|
||||
//Set debit and credit to zero on adding new row
|
||||
//----------------------------------------------
|
||||
cur_frm.fields_dict['entries'].grid.onrowadd = function(doc, cdt, cdn){
|
||||
|
||||
@@ -320,13 +320,6 @@ class DocType(TransactionBase):
|
||||
def get_advances(self):
|
||||
self.doclist = get_obj('GL Control').get_advances(self, self.doc.debit_to, 'Sales Invoice Advance', 'advance_adjustment_details', 'credit')
|
||||
|
||||
|
||||
def pull_project_customer(self):
|
||||
res = webnotes.conn.sql("select customer from `tabProject` where name = '%s'" %
|
||||
self.doc.project_name)
|
||||
if res and res[0][0]:
|
||||
get_obj('DocType Mapper', 'Project-Sales Invoice').dt_map('Project', 'Sales Invoice', self.doc.project_name, self.doc, self.doclist, "[['Project', 'Sales Invoice']]")
|
||||
|
||||
def get_company_abbr(self):
|
||||
return webnotes.conn.sql("select abbr from tabCompany where name=%s", self.doc.company)[0][0]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user