Fix [2904157] - InfoBPartner cutting first character on translation

https://sourceforge.net/tracker/?func=detail&atid=955896&aid=2904157&group_id=176962
This commit is contained in:
Carlos Ruiz 2009-12-15 23:10:31 +00:00
parent a171244114
commit 420c7c2da2
5 changed files with 10 additions and 8 deletions

View File

@ -39,6 +39,7 @@ import org.compiere.util.CLogger;
import org.compiere.util.Env; import org.compiere.util.Env;
import org.compiere.util.KeyNamePair; import org.compiere.util.KeyNamePair;
import org.compiere.util.Msg; import org.compiere.util.Msg;
import org.compiere.util.Util;
import org.zkoss.zk.ui.event.EventListener; import org.zkoss.zk.ui.event.EventListener;
import org.zkoss.zk.ui.event.Events; import org.zkoss.zk.ui.event.Events;
import org.zkoss.zul.Intbox; import org.zkoss.zul.Intbox;
@ -140,9 +141,9 @@ public class InfoBPartnerPanel extends InfoPanel implements EventListener, WTabl
private void initComponents() private void initComponents()
{ {
lblValue = new Label(); lblValue = new Label();
lblValue.setValue(Msg.translate(Env.getCtx(), "Value").substring(1)); lblValue.setValue(Util.cleanAmp(Msg.translate(Env.getCtx(), "Value")));
lblName = new Label(); lblName = new Label();
lblName.setValue(Msg.translate(Env.getCtx(), "Name").substring(1)); lblName.setValue(Util.cleanAmp(Msg.translate(Env.getCtx(), "Name")));
lblContact = new Label(); lblContact = new Label();
lblContact.setValue(Msg.translate(Env.getCtx(), "Contact")); lblContact.setValue(Msg.translate(Env.getCtx(), "Contact"));
lblEMail = new Label(); lblEMail = new Label();

View File

@ -40,6 +40,7 @@ import org.compiere.util.DB;
import org.compiere.util.DisplayType; import org.compiere.util.DisplayType;
import org.compiere.util.Env; import org.compiere.util.Env;
import org.compiere.util.Msg; import org.compiere.util.Msg;
import org.compiere.util.Util;
import org.zkoss.zk.ui.event.EventListener; import org.zkoss.zk.ui.event.EventListener;
import org.zkoss.zul.Separator; import org.zkoss.zul.Separator;
@ -174,7 +175,7 @@ public class InfoGeneralPanel extends InfoPanel implements EventListener
// Set & enable Fields // Set & enable Fields
lbl1.setValue(Msg.translate(Env.getCtx(), m_queryColumns.get(0).toString()).substring(1)); lbl1.setValue(Util.cleanAmp(Msg.translate(Env.getCtx(), m_queryColumns.get(0).toString())));
if (m_queryColumns.size() > 1) if (m_queryColumns.size() > 1)
{ {

View File

@ -141,7 +141,7 @@ public class InfoInvoicePanel extends InfoPanel implements ValueChangeListener
private void initComponents() private void initComponents()
{ {
lblDocumentNo = new Label(Msg.translate(Env.getCtx(), "DocumentNo").substring(1)); lblDocumentNo = new Label(Util.cleanAmp(Msg.translate(Env.getCtx(), "DocumentNo")));
lblDescription = new Label(Msg.translate(Env.getCtx(), "Description")); lblDescription = new Label(Msg.translate(Env.getCtx(), "Description"));
lblDateInvoiced = new Label(Msg.translate(Env.getCtx(), "DateInvoiced")); lblDateInvoiced = new Label(Msg.translate(Env.getCtx(), "DateInvoiced"));
lblGrandTotal = new Label(Msg.translate(Env.getCtx(), "GrandTotal")); lblGrandTotal = new Label(Msg.translate(Env.getCtx(), "GrandTotal"));

View File

@ -135,7 +135,7 @@ public class InfoOrderPanel extends InfoPanel implements ValueChangeListener
} }
public void initComponents() public void initComponents()
{ {
lblDocumentNo = new Label(Msg.translate(Env.getCtx(), "DocumentNo").substring(1)); lblDocumentNo = new Label(Util.cleanAmp(Msg.translate(Env.getCtx(), "DocumentNo")));
lblDescription = new Label(Msg.translate(Env.getCtx(), "Description")); lblDescription = new Label(Msg.translate(Env.getCtx(), "Description"));
lblDateOrdered = new Label(Msg.translate(Env.getCtx(), "DateOrdered")); lblDateOrdered = new Label(Msg.translate(Env.getCtx(), "DateOrdered"));
lblOrderRef = new Label(Msg.translate(Env.getCtx(), "POReference")); lblOrderRef = new Label(Msg.translate(Env.getCtx(), "POReference"));

View File

@ -206,9 +206,9 @@ public class InfoProductPanel extends InfoPanel implements EventListener
private void initComponents() private void initComponents()
{ {
lblValue = new Label(); lblValue = new Label();
lblValue.setValue(Msg.translate(Env.getCtx(), "Value").substring(1)); lblValue.setValue(Util.cleanAmp(Msg.translate(Env.getCtx(), "Value")));
lblName = new Label(); lblName = new Label();
lblName.setValue(Msg.translate(Env.getCtx(), "Name").substring(1)); lblName.setValue(Util.cleanAmp(Msg.translate(Env.getCtx(), "Name")));
lblUPC = new Label(); lblUPC = new Label();
lblUPC.setValue(Msg.translate(Env.getCtx(), "UPC")); lblUPC.setValue(Msg.translate(Env.getCtx(), "UPC"));
lblSKU = new Label(); lblSKU = new Label();
@ -220,7 +220,7 @@ public class InfoProductPanel extends InfoPanel implements EventListener
lblProductCategory.setValue(Msg.translate(Env.getCtx(), "M_Product_Category_ID")); lblProductCategory.setValue(Msg.translate(Env.getCtx(), "M_Product_Category_ID"));
// //
lblWarehouse = new Label(); lblWarehouse = new Label();
lblWarehouse.setValue(Msg.getMsg(Env.getCtx(), "Warehouse").substring(1)); lblWarehouse.setValue(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "Warehouse")));
lblVendor = new Label(); lblVendor = new Label();
lblVendor.setValue(Msg.translate(Env.getCtx(), "Vendor")); lblVendor.setValue(Msg.translate(Env.getCtx(), "Vendor"));