Field renamed in sms center

This commit is contained in:
Nabin Hait 2014-06-18 09:02:21 +05:30
parent b73d3f925d
commit ac1a4ed576
2 changed files with 106 additions and 106 deletions

View File

@ -3,15 +3,15 @@
$.extend(cur_frm.cscript, { $.extend(cur_frm.cscript, {
message: function () { message: function () {
var total_words = this.frm.doc.message.length; var total_characters = this.frm.doc.message.length;
var total_msg = 1; var total_msg = 1;
if (total_words > 160) { if (total_characters > 160) {
total_msg = cint(total_words / 160); total_msg = cint(total_characters / 160);
total_msg = (total_words % 160 == 0 ? total_msg : total_msg + 1); total_msg = (total_characters % 160 == 0 ? total_msg : total_msg + 1);
} }
this.frm.set_value("total_words", total_words); this.frm.set_value("total_characters", total_characters);
this.frm.set_value("total_messages", this.frm.doc.message ? total_msg : 0); this.frm.set_value("total_messages", this.frm.doc.message ? total_msg : 0);
} }
}); });

View File

@ -1,135 +1,135 @@
{ {
"allow_attach": 0, "allow_attach": 0,
"allow_copy": 1, "allow_copy": 1,
"creation": "2013-01-10 16:34:22", "creation": "2013-01-10 16:34:22",
"docstatus": 0, "docstatus": 0,
"doctype": "DocType", "doctype": "DocType",
"fields": [ "fields": [
{ {
"fieldname": "column_break1", "fieldname": "column_break1",
"fieldtype": "Column Break", "fieldtype": "Column Break",
"permlevel": 0, "permlevel": 0,
"width": "50%" "width": "50%"
}, },
{ {
"fieldname": "send_to", "fieldname": "send_to",
"fieldtype": "Select", "fieldtype": "Select",
"in_list_view": 1, "in_list_view": 1,
"label": "Send To", "label": "Send To",
"options": "\nAll Contact\nAll Customer Contact\nAll Supplier Contact\nAll Sales Partner Contact\nAll Lead (Open)\nAll Employee (Active)\nAll Sales Person", "options": "\nAll Contact\nAll Customer Contact\nAll Supplier Contact\nAll Sales Partner Contact\nAll Lead (Open)\nAll Employee (Active)\nAll Sales Person",
"permlevel": 0 "permlevel": 0
}, },
{ {
"depends_on": "eval:doc.send_to=='All Customer Contact'", "depends_on": "eval:doc.send_to=='All Customer Contact'",
"fieldname": "customer", "fieldname": "customer",
"fieldtype": "Link", "fieldtype": "Link",
"in_list_view": 1, "in_list_view": 1,
"label": "Customer", "label": "Customer",
"options": "Customer", "options": "Customer",
"permlevel": 0 "permlevel": 0
}, },
{ {
"depends_on": "eval:doc.send_to=='All Supplier Contact'", "depends_on": "eval:doc.send_to=='All Supplier Contact'",
"fieldname": "supplier", "fieldname": "supplier",
"fieldtype": "Link", "fieldtype": "Link",
"in_list_view": 1, "in_list_view": 1,
"label": "Supplier", "label": "Supplier",
"options": "Supplier", "options": "Supplier",
"permlevel": 0 "permlevel": 0
}, },
{ {
"depends_on": "eval:doc.send_to=='All Employee (Active)'", "depends_on": "eval:doc.send_to=='All Employee (Active)'",
"fieldname": "department", "fieldname": "department",
"fieldtype": "Link", "fieldtype": "Link",
"in_list_view": 1, "in_list_view": 1,
"label": "Department", "label": "Department",
"options": "Department", "options": "Department",
"permlevel": 0 "permlevel": 0
}, },
{ {
"depends_on": "eval:doc.send_to=='All Employee (Active)'", "depends_on": "eval:doc.send_to=='All Employee (Active)'",
"fieldname": "branch", "fieldname": "branch",
"fieldtype": "Link", "fieldtype": "Link",
"label": "Branch", "label": "Branch",
"options": "Branch", "options": "Branch",
"permlevel": 0 "permlevel": 0
}, },
{ {
"fieldname": "create_receiver_list", "fieldname": "create_receiver_list",
"fieldtype": "Button", "fieldtype": "Button",
"label": "Create Receiver List", "label": "Create Receiver List",
"options": "create_receiver_list", "options": "create_receiver_list",
"permlevel": 0 "permlevel": 0
}, },
{ {
"fieldname": "receiver_list", "fieldname": "receiver_list",
"fieldtype": "Code", "fieldtype": "Code",
"label": "Receiver List", "label": "Receiver List",
"permlevel": 0 "permlevel": 0
}, },
{ {
"fieldname": "column_break9", "fieldname": "column_break9",
"fieldtype": "Column Break", "fieldtype": "Column Break",
"permlevel": 0, "permlevel": 0,
"width": "50%" "width": "50%"
}, },
{ {
"description": "Messages greater than 160 characters will be split into multiple messages", "description": "Messages greater than 160 characters will be split into multiple messages",
"fieldname": "message", "fieldname": "message",
"fieldtype": "Text", "fieldtype": "Text",
"label": "Message", "label": "Message",
"permlevel": 0, "permlevel": 0,
"reqd": 1 "reqd": 1
}, },
{ {
"fieldname": "total_words", "fieldname": "total_characters",
"fieldtype": "Int", "fieldtype": "Int",
"label": "Total Characters", "label": "Total Characters",
"permlevel": 0, "permlevel": 0,
"read_only": 1 "read_only": 1
}, },
{ {
"fieldname": "total_messages", "fieldname": "total_messages",
"fieldtype": "Int", "fieldtype": "Int",
"label": "Total Message(s)", "label": "Total Message(s)",
"permlevel": 0, "permlevel": 0,
"read_only": 1 "read_only": 1
}, },
{ {
"fieldname": "send_sms", "fieldname": "send_sms",
"fieldtype": "Button", "fieldtype": "Button",
"label": "Send SMS", "label": "Send SMS",
"options": "send_sms", "options": "send_sms",
"permlevel": 0 "permlevel": 0
} }
], ],
"hide_heading": 0, "hide_heading": 0,
"hide_toolbar": 0, "hide_toolbar": 0,
"icon": "icon-mobile-phone", "icon": "icon-mobile-phone",
"idx": 1, "idx": 1,
"in_create": 0, "in_create": 0,
"issingle": 1, "issingle": 1,
"modified": "2014-05-09 02:17:41.375945", "modified": "2014-06-18 08:59:51.755566",
"modified_by": "Administrator", "modified_by": "Administrator",
"module": "Selling", "module": "Selling",
"name": "SMS Center", "name": "SMS Center",
"owner": "Administrator", "owner": "Administrator",
"permissions": [ "permissions": [
{ {
"cancel": 0, "cancel": 0,
"create": 1, "create": 1,
"delete": 0, "delete": 0,
"export": 0, "export": 0,
"import": 0, "import": 0,
"permlevel": 0, "permlevel": 0,
"read": 1, "read": 1,
"report": 0, "report": 0,
"role": "System Manager", "role": "System Manager",
"submit": 0, "submit": 0,
"write": 1 "write": 1
} }
], ],
"read_only": 1, "read_only": 1,
"sort_field": "modified", "sort_field": "modified",
"sort_order": "DESC" "sort_order": "DESC"
} }