Fixin translation in Opportunity.js

This commit is contained in:
Bárbara Perretti 2013-09-26 19:12:31 -03:00
parent 629a032a74
commit dc3ab5c8de

View File

@ -113,9 +113,9 @@ cur_frm.cscript.refresh = function(doc, cdt, cdn){
cur_frm.clear_custom_buttons();
if(doc.docstatus === 1 && doc.status!=="Opportunity Lost") {
cur_frm.add_custom_button('Create Quotation', cur_frm.cscript.create_quotation);
cur_frm.add_custom_button('Opportunity Lost', cur_frm.cscript['Declare Opportunity Lost']);
cur_frm.add_custom_button('Send SMS', cur_frm.cscript.send_sms);
cur_frm.add_custom_button( wn._('Create Quotation'), cur_frm.cscript.create_quotation);
cur_frm.add_custom_button(wn._('Opportunity Lost'), cur_frm.cscript['Declare Opportunity Lost']);
cur_frm.add_custom_button(wn._('Send SMS'), cur_frm.cscript.send_sms);
}
cur_frm.toggle_display("contact_info", doc.customer || doc.lead);
@ -181,11 +181,11 @@ cur_frm.cscript.lead = function(doc, cdt, cdn) {
cur_frm.cscript['Declare Opportunity Lost'] = function(){
var dialog = new wn.ui.Dialog({
title: "Set as Lost",
title: wn._("Set as Lost"),
fields: [
{"fieldtype": "Text", "label": "Reason for losing", "fieldname": "reason",
{"fieldtype": "Text", "label": wn._("Reason for losing"), "fieldname": "reason",
"reqd": 1 },
{"fieldtype": "Button", "label": "Update", "fieldname": "update"},
{"fieldtype": "Button", "label": wn._("Update"), "fieldname": "update"},
]
});
@ -198,7 +198,7 @@ cur_frm.cscript['Declare Opportunity Lost'] = function(){
args: args.reason,
callback: function(r) {
if(r.exc) {
msgprint("There were errors.");
msgprint(wn._("There were errors."));
return;
}
dialog.hide();