fix: sider issues

This commit is contained in:
Anupam 2021-08-25 16:35:34 +05:30
parent dfcac64b44
commit c644fbb102
3 changed files with 23 additions and 14 deletions

View File

@ -40,9 +40,7 @@ erpnext.LeadController = class LeadController extends frappe.ui.form.Controller
this.frm.add_custom_button(__("Opportunity"), this.make_opportunity, __("Create"));
this.frm.add_custom_button(__("Quotation"), this.make_quotation, __("Create"));
this.frm.add_custom_button(__("Prospect"), this.make_prospect, __("Create"));
this.frm.add_custom_button(__('Add to Prospect'), function() {
cur_frm.trigger('add_lead_to_prospect')
}, __('Action'));
this.frm.add_custom_button(__('Add to Prospect'), this.add_lead_to_prospect, __('Action'));
}
if (!this.frm.is_new()) {
@ -77,7 +75,7 @@ erpnext.LeadController = class LeadController extends frappe.ui.form.Controller
},
freeze: true,
freeze_message: __('...Adding Lead to Prospect')
})
});
}, __('Add Lead to Prospect'), __('Add'));
}

View File

@ -8,7 +8,7 @@ frappe.ui.form.on('Prospect', {
frappe.model.open_mapped_doc({
method: "erpnext.crm.doctype.prospect.prospect.make_customer",
frm: cur_frm
})
});
}, __("Create"));
}
if (!cur_frm.is_new() && frappe.boot.user.can_create.includes("Opportunity")) {
@ -16,7 +16,7 @@ frappe.ui.form.on('Prospect', {
frappe.model.open_mapped_doc({
method: "erpnext.crm.doctype.prospect.prospect.make_opportunity",
frm: cur_frm
})
});
}, __("Create"));
}

View File

@ -15,12 +15,14 @@
"no_of_employees",
"currency",
"annual_revenue",
"more_details_section",
"fax",
"website",
"column_break_13",
"prospect_owner",
"leads_section",
"prospect_lead",
"addresses_and_contacts_section",
"address_and_contact_section",
"address_html",
"column_break_17",
"contact_html",
@ -107,12 +109,6 @@
"fieldtype": "Table",
"options": "Prospect Lead"
},
{
"depends_on": "eval: !doc.__islocal",
"fieldname": "addresses_and_contacts_section",
"fieldtype": "Section Break",
"label": "Addresses and Contacts"
},
{
"fieldname": "address_html",
"fieldtype": "HTML",
@ -136,11 +132,26 @@
{
"fieldname": "notes",
"fieldtype": "Text Editor"
},
{
"fieldname": "more_details_section",
"fieldtype": "Section Break",
"label": "More Details"
},
{
"fieldname": "column_break_13",
"fieldtype": "Column Break"
},
{
"depends_on": "eval: !doc.__islocal",
"fieldname": "address_and_contact_section",
"fieldtype": "Section Break",
"label": "Address and Contact"
}
],
"index_web_pages_for_search": 1,
"links": [],
"modified": "2021-08-19 00:29:00.767038",
"modified": "2021-08-25 12:35:00.759909",
"modified_by": "Administrator",
"module": "CRM",
"name": "Prospect",