c-form fixes
This commit is contained in:
parent
4860754407
commit
bcbc2f6ce5
@ -26,6 +26,10 @@ cur_frm.fields_dict.invoice_details.grid.get_field("invoice_no").get_query = fun
|
||||
}
|
||||
}
|
||||
|
||||
cur_frm.fields_dict.state.get_query = function(doc) {
|
||||
return {filters: { country: "India"}}
|
||||
}
|
||||
|
||||
cur_frm.cscript.invoice_no = function(doc, cdt, cdn) {
|
||||
var d = locals[cdt][cdn];
|
||||
get_server_fields('get_invoice_details', d.invoice_no, 'invoice_details', doc, cdt, cdn, 1);
|
||||
|
@ -68,7 +68,7 @@ class DocType:
|
||||
self.set_total_invoiced_amount()
|
||||
|
||||
def set_total_invoiced_amount(self):
|
||||
total = sum([flt(d.total) for d in getlist(self.doclist, 'invoice_details')])
|
||||
total = sum([flt(d.grand_total) for d in getlist(self.doclist, 'invoice_details')])
|
||||
webnotes.conn.set(self.doc, 'total_invoiced_amount', total)
|
||||
|
||||
def get_invoice_details(self, invoice_no):
|
||||
|
@ -1,8 +1,8 @@
|
||||
[
|
||||
{
|
||||
"creation": "2013-01-19 10:23:34",
|
||||
"creation": "2013-01-30 12:49:46",
|
||||
"docstatus": 0,
|
||||
"modified": "2013-01-29 16:27:57",
|
||||
"modified": "2013-02-13 11:29:18",
|
||||
"modified_by": "Administrator",
|
||||
"owner": "Administrator"
|
||||
},
|
||||
@ -127,9 +127,9 @@
|
||||
{
|
||||
"doctype": "DocField",
|
||||
"fieldname": "state",
|
||||
"fieldtype": "Select",
|
||||
"fieldtype": "Link",
|
||||
"label": "State",
|
||||
"options": "link:State\ncountry='India'",
|
||||
"options": "State",
|
||||
"read_only": 0,
|
||||
"reqd": 1
|
||||
},
|
||||
@ -171,7 +171,7 @@
|
||||
"fieldtype": "Link",
|
||||
"label": "Amended From",
|
||||
"no_copy": 1,
|
||||
"options": "Sales Invoice",
|
||||
"options": "C-Form",
|
||||
"print_hide": 1,
|
||||
"read_only": 1
|
||||
},
|
||||
|
Loading…
x
Reference in New Issue
Block a user