[email] remove communicationlist #561
This commit is contained in:
parent
ce00772ac0
commit
e10cf021d9
@ -10,6 +10,8 @@ frappe.provide("erpnext.buying");
|
||||
frappe.require("assets/erpnext/js/transaction.js");
|
||||
{% include "public/js/controllers/accounts.js" %}
|
||||
|
||||
cur_frm.email_field = "contact_email";
|
||||
|
||||
erpnext.buying.BuyingController = erpnext.TransactionController.extend({
|
||||
onload: function() {
|
||||
this.setup_queries();
|
||||
|
@ -20,12 +20,6 @@ cur_frm.cscript.refresh = function(doc, dt, dn) {
|
||||
// make lists
|
||||
cur_frm.cscript.make_address(doc,dt,dn);
|
||||
cur_frm.cscript.make_contact(doc,dt,dn);
|
||||
|
||||
cur_frm.communication_view = new frappe.views.CommunicationList({
|
||||
list: frappe.get_list("Communication", {"supplier": doc.name}),
|
||||
parent: cur_frm.fields_dict.communication_html.wrapper,
|
||||
doc: doc
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -83,22 +83,6 @@
|
||||
"permlevel": 0,
|
||||
"read_only": 1
|
||||
},
|
||||
{
|
||||
"depends_on": "eval:!doc.__islocal",
|
||||
"fieldname": "communication_history",
|
||||
"fieldtype": "Section Break",
|
||||
"label": "Communication History",
|
||||
"options": "icon-comments",
|
||||
"permlevel": 0,
|
||||
"print_hide": 1
|
||||
},
|
||||
{
|
||||
"fieldname": "communication_html",
|
||||
"fieldtype": "HTML",
|
||||
"label": "Communication HTML",
|
||||
"permlevel": 0,
|
||||
"print_hide": 1
|
||||
},
|
||||
{
|
||||
"fieldname": "more_info",
|
||||
"fieldtype": "Section Break",
|
||||
@ -186,7 +170,7 @@
|
||||
],
|
||||
"icon": "icon-user",
|
||||
"idx": 1,
|
||||
"modified": "2014-09-10 17:53:09.286715",
|
||||
"modified": "2014-09-12 12:26:37.606976",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Buying",
|
||||
"name": "Supplier",
|
||||
|
@ -3,16 +3,9 @@
|
||||
|
||||
// For license information, please see license.txt
|
||||
|
||||
// for communication
|
||||
cur_frm.email_field = "email_id";
|
||||
cur_frm.cscript = {
|
||||
refresh: function(doc) {
|
||||
cur_frm.cscript.make_listing(doc);
|
||||
},
|
||||
make_listing: function(doc) {
|
||||
cur_frm.communication_view = new frappe.views.CommunicationList({
|
||||
list: frappe.get_list("Communication", {"parent": doc.name, "parenttype": "Job Applicant"}),
|
||||
parent: cur_frm.fields_dict['thread_html'].wrapper,
|
||||
doc: doc,
|
||||
recipients: doc.email_id
|
||||
})
|
||||
},
|
||||
}
|
||||
|
@ -34,11 +34,6 @@ cur_frm.cscript.refresh = function(doc, dt, dn) {
|
||||
// make lists
|
||||
cur_frm.cscript.make_address(doc, dt, dn);
|
||||
cur_frm.cscript.make_contact(doc, dt, dn);
|
||||
|
||||
cur_frm.communication_view = new frappe.views.CommunicationList({
|
||||
parent: cur_frm.fields_dict.communication_html.wrapper,
|
||||
doc: doc,
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -129,22 +129,6 @@
|
||||
"permlevel": 0,
|
||||
"read_only": 1
|
||||
},
|
||||
{
|
||||
"depends_on": "eval:!doc.__islocal",
|
||||
"fieldname": "communication_history",
|
||||
"fieldtype": "Section Break",
|
||||
"label": "Communication History",
|
||||
"options": "icon-comments",
|
||||
"permlevel": 0,
|
||||
"print_hide": 1
|
||||
},
|
||||
{
|
||||
"fieldname": "communication_html",
|
||||
"fieldtype": "HTML",
|
||||
"label": "Communication HTML",
|
||||
"permlevel": 0,
|
||||
"print_hide": 1
|
||||
},
|
||||
{
|
||||
"fieldname": "more_info",
|
||||
"fieldtype": "Section Break",
|
||||
@ -282,7 +266,7 @@
|
||||
],
|
||||
"icon": "icon-user",
|
||||
"idx": 1,
|
||||
"modified": "2014-09-10 16:41:07.553182",
|
||||
"modified": "2014-09-12 12:26:47.480965",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Selling",
|
||||
"name": "Customer",
|
||||
|
@ -4,6 +4,8 @@
|
||||
{% include 'setup/doctype/contact_control/contact_control.js' %};
|
||||
|
||||
frappe.provide("erpnext");
|
||||
cur_frm.email_field = "email_id";
|
||||
|
||||
erpnext.LeadController = frappe.ui.form.Controller.extend({
|
||||
setup: function() {
|
||||
this.frm.fields_dict.customer.get_query = function(doc, cdt, cdn) {
|
||||
|
@ -8,6 +8,8 @@ frappe.ui.form.on_change("Opportunity", "contact_person", erpnext.utils.get_cont
|
||||
|
||||
|
||||
frappe.provide("erpnext.selling");
|
||||
cur_frm.email_field = "contact_email";
|
||||
|
||||
// TODO commonify this code
|
||||
erpnext.selling.Opportunity = frappe.ui.form.Controller.extend({
|
||||
onload: function() {
|
||||
@ -26,15 +28,6 @@ erpnext.selling.Opportunity = frappe.ui.form.Controller.extend({
|
||||
set_multiple(cdt, cdn, { fiscal_year:sys_defaults.fiscal_year });
|
||||
|
||||
|
||||
if(!this.frm.doc.__islocal) {
|
||||
cur_frm.communication_view = new frappe.views.CommunicationList({
|
||||
list: frappe.get_list("Communication", {"parent": this.frm.doc.name, "parenttype": "Opportunity"}),
|
||||
parent: cur_frm.fields_dict.communication_html.wrapper,
|
||||
doc: this.frm.doc,
|
||||
recipients: this.frm.doc.contact_email
|
||||
});
|
||||
}
|
||||
|
||||
if(this.frm.doc.customer && !this.frm.doc.customer_name) cur_frm.cscript.customer(this.frm.doc);
|
||||
|
||||
this.setup_queries();
|
||||
|
@ -53,15 +53,6 @@ erpnext.selling.QuotationController = erpnext.selling.SellingController.extend({
|
||||
}, "icon-download", "btn-default");
|
||||
}
|
||||
|
||||
if (!doc.__islocal) {
|
||||
cur_frm.communication_view = new frappe.views.CommunicationList({
|
||||
list: frappe.get_list("Communication", {"parent": doc.name, "parenttype": "Quotation"}),
|
||||
parent: cur_frm.fields_dict.communication_html.wrapper,
|
||||
doc: doc,
|
||||
recipients: doc.contact_email
|
||||
});
|
||||
}
|
||||
|
||||
this.toggle_reqd_lead_customer();
|
||||
},
|
||||
|
||||
|
@ -13,6 +13,8 @@ frappe.require("assets/erpnext/js/transaction.js");
|
||||
|
||||
{% include "public/js/controllers/accounts.js" %}
|
||||
|
||||
cur_frm.email_field = "contact_email";
|
||||
|
||||
erpnext.selling.SellingController = erpnext.TransactionController.extend({
|
||||
onload: function() {
|
||||
this._super();
|
||||
|
@ -7,6 +7,7 @@ cur_frm.fields_dict.customer.get_query = function(doc,cdt,cdn) {
|
||||
frappe.provide("erpnext.support");
|
||||
|
||||
cur_frm.add_fetch("customer", "customer_name", "customer_name")
|
||||
cur_frm.email_field = "raised_by";
|
||||
|
||||
$.extend(cur_frm.cscript, {
|
||||
refresh: function(doc) {
|
||||
|
@ -3,15 +3,7 @@
|
||||
|
||||
{% include 'controllers/js/contact_address_common.js' %};
|
||||
|
||||
cur_frm.cscript.refresh = function(doc) {
|
||||
cur_frm.communication_view = new frappe.views.CommunicationList({
|
||||
list: frappe.get_list("Communication", {"parent": doc.name, "parenttype": "Contact"}),
|
||||
parent: cur_frm.fields_dict.communication_html.wrapper,
|
||||
doc: doc,
|
||||
recipients: doc.email_id
|
||||
});
|
||||
}
|
||||
|
||||
cur_frm.email_field = "email_id";
|
||||
cur_frm.cscript.hide_dialog = function() {
|
||||
if(cur_frm.contact_list)
|
||||
cur_frm.contact_list.run();
|
||||
|
Loading…
x
Reference in New Issue
Block a user