mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-31 10:49:09 +00:00
[enhance] Search customer using primary contact mobile number (#11998)
* [enhance] Search customer using primary contact mobile number * Update build.json
This commit is contained in:
committed by
Nabin Hait
parent
a2cfd97cd7
commit
24e5265281
80
erpnext/public/js/utils/customer_quick_entry.js
Normal file
80
erpnext/public/js/utils/customer_quick_entry.js
Normal file
@@ -0,0 +1,80 @@
|
||||
frappe.provide('frappe.ui.form');
|
||||
|
||||
frappe.ui.form.CustomerQuickEntryForm = frappe.ui.form.QuickEntryForm.extend({
|
||||
init: function(doctype, after_insert) {
|
||||
this._super(doctype, after_insert);
|
||||
},
|
||||
|
||||
render_dialog: function() {
|
||||
this.mandatory = this.mandatory.concat(this.get_variant_fields());
|
||||
this._super();
|
||||
},
|
||||
|
||||
get_variant_fields: function() {
|
||||
var variant_fields = [{
|
||||
fieldtype: "Section Break",
|
||||
label: __("Primary Contact Details"),
|
||||
collapsible: 1
|
||||
},
|
||||
{
|
||||
label: __("Email Id"),
|
||||
fieldname: "email_id",
|
||||
fieldtype: "Data"
|
||||
},
|
||||
{
|
||||
fieldtype: "Column Break"
|
||||
},
|
||||
{
|
||||
label: __("Mobile Number"),
|
||||
fieldname: "mobile_no",
|
||||
fieldtype: "Data"
|
||||
},
|
||||
{
|
||||
fieldtype: "Section Break",
|
||||
label: __("Primary Address Details"),
|
||||
collapsible: 1
|
||||
},
|
||||
{
|
||||
label: __("Address Line 1"),
|
||||
fieldname: "address_line1",
|
||||
fieldtype: "Data"
|
||||
},
|
||||
{
|
||||
label: __("Address Line 2"),
|
||||
fieldname: "address_line2",
|
||||
fieldtype: "Data"
|
||||
},
|
||||
{
|
||||
label: __("ZIP Code"),
|
||||
fieldname: "pincode",
|
||||
fieldtype: "Data"
|
||||
},
|
||||
{
|
||||
fieldtype: "Column Break"
|
||||
},
|
||||
{
|
||||
label: __("City"),
|
||||
fieldname: "city",
|
||||
fieldtype: "Data"
|
||||
},
|
||||
{
|
||||
label: __("State"),
|
||||
fieldname: "state",
|
||||
fieldtype: "Data"
|
||||
},
|
||||
{
|
||||
label: __("Country"),
|
||||
fieldname: "country",
|
||||
fieldtype: "Link",
|
||||
options: "Country"
|
||||
},
|
||||
{
|
||||
label: __("Customer POS Id"),
|
||||
fieldname: "customer_pos_id",
|
||||
fieldtype: "Data",
|
||||
hidden: 1
|
||||
}];
|
||||
|
||||
return variant_fields;
|
||||
},
|
||||
})
|
||||
Reference in New Issue
Block a user