[fix] [minor] show stock ledger, general ledger, fixes post changes in script manager trigger [issue] webnotes/wnframework#228

This commit is contained in:
Anand Doshi
2013-07-30 14:42:15 +05:30
parent 7180eb6f20
commit a648f46d4e
16 changed files with 106 additions and 103 deletions

View File

@@ -86,15 +86,15 @@ erpnext.selling.Opportunity = wn.ui.form.Controller.extend({
customer: function() {
var me = this;
if(this.frm.doc.customer) {
return this.frm.call({
doc: this.frm.doc,
method: "set_customer_defaults",
});
// TODO shift this to depends_on
unhide_field(['customer_address', 'contact_person', 'customer_name',
'address_display', 'contact_display', 'contact_mobile', 'contact_email',
'territory', 'customer_group']);
return this.frm.call({
doc: this.frm.doc,
method: "set_customer_defaults",
});
}
},

View File

@@ -114,6 +114,7 @@ cur_frm.fields_dict.lead.get_query = function(doc,cdt,cdn) {
cur_frm.cscript.lead = function(doc, cdt, cdn) {
if(doc.lead) {
unhide_field('territory');
return cur_frm.call({
doc: cur_frm.doc,
method: "set_lead_defaults",
@@ -123,7 +124,6 @@ cur_frm.cscript.lead = function(doc, cdt, cdn) {
}
}
});
unhide_field('territory');
}
}