hg merge release-1.0c (merge release1 into release2)

This commit is contained in:
Carlos Ruiz 2013-11-21 16:35:43 -05:00
commit 499cb715bd
8 changed files with 58 additions and 16 deletions

View File

@ -0,0 +1,10 @@
SET SQLBLANKLINES ON
SET DEFINE OFF
-- Nov 20, 2013 2:41:50 PM CET
-- IDEMPIERE-1553
UPDATE AD_Column SET DefaultValue=NULL, ValueMax=NULL, ValueMin=NULL,Updated=TO_DATE('2013-11-20 14:41:50','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=200484
;
SELECT register_migration_script('201311201442_IDEMPIERE-1553.sql') FROM dual
;

View File

@ -0,0 +1,7 @@
-- Nov 20, 2013 2:41:50 PM CET
-- IDEMPIERE-1553
UPDATE AD_Column SET DefaultValue=NULL, ValueMax=NULL, ValueMin=NULL,Updated=TO_TIMESTAMP('2013-11-20 14:41:50','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=200484
;
SELECT register_migration_script('201311201442_IDEMPIERE-1553.sql') FROM dual
;

View File

@ -34,6 +34,8 @@ import javax.swing.table.DefaultTableModel;
import org.compiere.grid.VTable;
import org.compiere.model.DataStatusEvent;
import org.compiere.model.GridTab;
import org.compiere.model.GridTable;
import org.compiere.model.MChangeLog;
import org.compiere.model.MColumn;
import org.compiere.model.MLookup;
@ -41,6 +43,7 @@ import org.compiere.model.MLookupFactory;
import org.compiere.model.MRole;
import org.compiere.model.MTable;
import org.compiere.model.MUser;
import org.compiere.model.PO;
import org.compiere.swing.CDialog;
import org.compiere.swing.CPanel;
import org.compiere.swing.CScrollPane;
@ -51,6 +54,7 @@ import org.compiere.util.DisplayType;
import org.compiere.util.Env;
import org.compiere.util.Msg;
import org.compiere.util.NamePair;
import org.compiere.util.Util;
/**
* Record Info (Who) With Change History
@ -182,7 +186,29 @@ public class RecordInfo extends CDialog
.append(" - ").append(m_dateTimeFormat.format(dse.Updated)).append("\n");
}
if (dse.Info != null && dse.Info.length() > 0)
m_info.append("\n (").append(dse.Info).append(")");
m_info.append("\n ").append(dse.Info).append("");
//get uuid
GridTable gridTable = null;
if (dse.getSource() instanceof GridTab)
{
GridTab gridTab = (GridTab) dse.getSource();
gridTable = gridTab.getTableModel();
}
else if (dse.getSource() instanceof GridTable)
{
gridTable = (GridTable) dse.getSource();
}
if (gridTable != null && dse.getCurrentRow() >= 0 && dse.getCurrentRow() < gridTable.getRowCount())
{
PO po = gridTable.getPO(dse.getCurrentRow());
if (po != null) {
String uuidcol = po.getUUIDColumnName();
String uuid = po.get_ValueAsString(uuidcol);
if (!Util.isEmpty(uuid))
m_info.append("\n ").append(uuidcol).append("=").append(uuid);
}
}
// Title
if (dse.AD_Table_ID != 0)

View File

@ -135,7 +135,7 @@ public class DefaultInfoFactory implements IInfoFactory {
if (col.equals("M_Product_ID"))
{
InfoWindow infoWindow = new InfoProductWindow(lookup.getWindowNo(), tableName, keyColumn, queryValue, multiSelection, whereClause, AD_InfoWindow_ID);
InfoWindow infoWindow = new InfoProductWindow(lookup.getWindowNo(), tableName, keyColumn, queryValue, true, whereClause, AD_InfoWindow_ID);
if (infoWindow.loadedOK())
return infoWindow;

View File

@ -163,7 +163,7 @@ public class InfoProductWindow extends InfoWindow {
warehouseTbl.setMultiSelection(false);
warehouseTbl.setShowTotals(true);
warehouseTbl.autoSize();
warehouseTbl.getModel().addTableModelListener(this);
// warehouseTbl.getModel().addTableModelListener(this);
ColumnInfo[] s_layoutSubstitute = new ColumnInfo[]{
new ColumnInfo(Msg.translate(Env.getCtx(), "Warehouse"), "orgname", String.class),
@ -182,7 +182,7 @@ public class InfoProductWindow extends InfoWindow {
m_sqlSubstitute = substituteTbl.prepareTable(s_layoutSubstitute, s_sqlFrom, s_sqlWhere, false, "M_PRODUCT_SUBSTITUTERELATED_V");
substituteTbl.setMultiSelection(false);
substituteTbl.autoSize();
substituteTbl.getModel().addTableModelListener(this);
// substituteTbl.getModel().addTableModelListener(this);
ColumnInfo[] s_layoutRelated = new ColumnInfo[]{
new ColumnInfo(Msg.translate(Env.getCtx(), "Warehouse"), "orgname", String.class),
@ -201,7 +201,7 @@ public class InfoProductWindow extends InfoWindow {
m_sqlRelated = relatedTbl.prepareTable(s_layoutRelated, s_sqlFrom, s_sqlWhere, false, "M_PRODUCT_SUBSTITUTERELATED_V");
relatedTbl.setMultiSelection(false);
relatedTbl.autoSize();
relatedTbl.getModel().addTableModelListener(this);
// relatedTbl.getModel().addTableModelListener(this);
//Available to Promise Tab
m_tableAtp = ListboxFactory.newDataTable();
@ -227,7 +227,7 @@ public class InfoProductWindow extends InfoWindow {
m_sqlProductprice = productpriceTbl.prepareTable(s_layoutProductPrice, s_sqlFrom, s_sqlWhere, false, "pp") + " ORDER BY plv.ValidFrom DESC";
productpriceTbl.setMultiSelection(false);
productpriceTbl.autoSize();
productpriceTbl.getModel().addTableModelListener(this);
// productpriceTbl.getModel().addTableModelListener(this);
tabbedPane = new Tabbox();
tabbedPane.setHeight("100%");

View File

@ -822,7 +822,7 @@ public class InfoWindow extends InfoPanel implements ValueChangeListener, EventL
@Override
protected boolean hasZoom() {
return !isLookup() && infoWindow != null && !infoWindow.getAD_Table().isView();
return !isLookup() && infoWindow != null && !MTable.get(Env.getCtx(), infoWindow.getAD_Table_ID()).isView();
}
@Override

View File

@ -557,6 +557,7 @@ public abstract class InfoPanel extends Window implements EventListener<Event>,
model = new ListModelTable(subList);
model.setSorter(this);
model.addTableModelListener(this);
model.setMultiple(p_multipleSelection);
contentPanel.setData(model, null);
pageNo = 0;
@ -572,6 +573,7 @@ public abstract class InfoPanel extends Window implements EventListener<Event>,
model = new ListModelTable(readLine(0, -1));
model.setSorter(this);
model.addTableModelListener(this);
model.setMultiple(p_multipleSelection);
contentPanel.setData(model, null);
}
}
@ -586,6 +588,7 @@ public abstract class InfoPanel extends Window implements EventListener<Event>,
model = new ListModelTable(new ArrayList<Object>());
model.setSorter(this);
model.addTableModelListener(this);
model.setMultiple(p_multipleSelection);
contentPanel.setData(model, null);
}
int no = m_count;
@ -1177,6 +1180,7 @@ public abstract class InfoPanel extends Window implements EventListener<Event>,
model = new ListModelTable(subList);
model.setSorter(this);
model.addTableModelListener(this);
model.setMultiple(p_multipleSelection);
contentPanel.setData(model, null);
contentPanel.setSelectedIndex(0);

View File

@ -48,12 +48,7 @@ public abstract class CreateFromRMA extends CreateFrom {
public boolean dynInit() throws Exception
{
log.config("");
boolean isSOTrx = true;
String value = Env.getContext(Env.getCtx(), getGridTab().getWindowNo(), MRMA.COLUMNNAME_IsSOTrx);
if (value != null && value.equalsIgnoreCase("N"))
isSOTrx = false;
setTitle(isSOTrx ? "Customer" : "Vendor" + " RMA - Create Lines From");
setTitle(Msg.getElement(Env.getCtx(), "M_RMA_ID") + " .. " + Msg.translate(Env.getCtx(), "CreateFrom"));
return true;
}
@ -187,9 +182,9 @@ public abstract class CreateFromRMA extends CreateFrom {
// Header Info
Vector<String> columnNames = new Vector<String>(7);
columnNames.add(Msg.getMsg(Env.getCtx(), "Select"));
columnNames.add("Line");
columnNames.add(Msg.translate(Env.getCtx(), "Line"));
columnNames.add(Msg.translate(Env.getCtx(), "M_Product_ID"));
columnNames.add("ASI");
columnNames.add(Msg.translate(Env.getCtx(), "SerNo"));
columnNames.add(Msg.translate(Env.getCtx(), "Quantity"));
columnNames.add(Msg.getElement(Env.getCtx(), "QtyDelivered", false));