hg merge release-2.0 (merge release2 into development)

This commit is contained in:
Carlos Ruiz 2014-07-01 21:15:22 -05:00
commit b6b04612ad
4 changed files with 10 additions and 36 deletions

View File

@ -423,17 +423,17 @@ public class GridField
|| (m_vo.ColumnName.equals("Record_ID") && m_vo.displayType == DisplayType.Button)) // Zoom || (m_vo.ColumnName.equals("Record_ID") && m_vo.displayType == DisplayType.Button)) // Zoom
return true; return true;
// Fields always updareable
if (m_vo.IsAlwaysUpdateable) // Zoom
return true;
// Tab or field is R/O // Tab or field is R/O
if (m_vo.tabReadOnly || m_vo.IsReadOnly) if (m_vo.tabReadOnly || m_vo.IsReadOnly)
{ {
if (log.isLoggable(Level.FINEST)) log.finest(m_vo.ColumnName + " NO - TabRO=" + m_vo.tabReadOnly + ", FieldRO=" + m_vo.IsReadOnly); if (log.isLoggable(Level.FINEST)) log.finest(m_vo.ColumnName + " NO - TabRO=" + m_vo.tabReadOnly + ", FieldRO=" + m_vo.IsReadOnly);
return false; return false;
} }
// Fields always updateable
if (m_vo.IsAlwaysUpdateable) // Zoom
return true;
//check tab context //check tab context
if (checkContext && getGridTab() != null && if (checkContext && getGridTab() != null &&
! "Y".equals(Env.getContext(Env.getCtx(), getWindowNo(), "_QUICK_ENTRY_MODE_"))) ! "Y".equals(Env.getContext(Env.getCtx(), getWindowNo(), "_QUICK_ENTRY_MODE_")))

View File

@ -113,7 +113,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
/** /**
* *
*/ */
private static final long serialVersionUID = 1583164211079643636L; private static final long serialVersionUID = 1377113168185797983L;
public static final String DEFAULT_STATUS_MESSAGE = "NavigateOrUpdate"; public static final String DEFAULT_STATUS_MESSAGE = "NavigateOrUpdate";
@ -210,8 +210,6 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
private DataStatusEvent m_lastDataStatusEvent; private DataStatusEvent m_lastDataStatusEvent;
private String m_parsedWhere;
//Contains currently selected rows //Contains currently selected rows
private ArrayList<Integer> selection = null; private ArrayList<Integer> selection = null;
@ -626,9 +624,6 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo
+ " - Only Current Rows=" + onlyCurrentRows + " - Only Current Rows=" + onlyCurrentRows
+ ", Days=" + onlyCurrentDays + ", Detail=" + isDetail()); + ", Days=" + onlyCurrentDays + ", Detail=" + isDetail());
// is it same query?
boolean refresh = m_oldQuery.equals(m_query.getWhereClause())
&& m_vo.onlyCurrentRows == onlyCurrentRows && m_vo.onlyCurrentDays == onlyCurrentDays;
m_oldQuery = m_query.getWhereClause(); m_oldQuery = m_query.getWhereClause();
m_vo.onlyCurrentRows = onlyCurrentRows; m_vo.onlyCurrentRows = onlyCurrentRows;
m_vo.onlyCurrentDays = onlyCurrentDays; m_vo.onlyCurrentDays = onlyCurrentDays;
@ -670,8 +665,6 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
} }
// Same link value? // Same link value?
if (refresh)
refresh = m_linkValue.equals(value);
if (! m_linkValue.equals(value)) if (! m_linkValue.equals(value))
setQuery(null); setQuery(null);
m_linkValue = value; m_linkValue = value;
@ -704,23 +697,6 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
m_extendedWhere = where.toString(); m_extendedWhere = where.toString();
if (m_extendedWhere.indexOf("@") > 1)
{
String s = Env.parseContext(Env.getCtx(), getWindowNo(), m_extendedWhere, false);
if (s != null)
{
if (!(s.equals(m_parsedWhere)))
{
refresh = false;
}
}
else
{
refresh = false;
}
m_parsedWhere = s;
}
// Final Query // Final Query
if (m_query.isActive()) if (m_query.isActive())
{ {
@ -740,10 +716,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo + " - " + where); if (log.isLoggable(Level.FINE)) log.fine("#" + m_vo.TabNo + " - " + where);
if (m_mTable.isOpen()) if (m_mTable.isOpen())
{ {
if (refresh) m_mTable.dataRequery(where.toString(), m_vo.onlyCurrentRows && !isDetail(), onlyCurrentDays);
m_mTable.dataRefreshAll();
else
m_mTable.dataRequery(where.toString(), m_vo.onlyCurrentRows && !isDetail(), onlyCurrentDays);
} }
else else
{ {

View File

@ -42,6 +42,7 @@ import org.compiere.util.Env;
import org.compiere.util.Msg; import org.compiere.util.Msg;
import org.compiere.util.Secure; import org.compiere.util.Secure;
import org.compiere.util.SecureEngine; import org.compiere.util.SecureEngine;
import org.compiere.util.Util;
/** /**
* User Model * User Model
@ -899,7 +900,7 @@ public class MUser extends X_AD_User
setEMailVerifyDate(null); setEMailVerifyDate(null);
// IDEMPIERE-1409 // IDEMPIERE-1409
if (getEMail() != null && (newRecord || is_ValueChanged("EMail"))) { if (!Util.isEmpty(getEMail()) && (newRecord || is_ValueChanged("EMail"))) {
if (! EMail.validate(getEMail())) { if (! EMail.validate(getEMail())) {
log.saveError("SaveError", Msg.getMsg(getCtx(), "InvalidEMailFormat") + Msg.getElement(getCtx(), COLUMNNAME_EMail) + " - [" + getEMail() + "]"); log.saveError("SaveError", Msg.getMsg(getCtx(), "InvalidEMailFormat") + Msg.getElement(getCtx(), COLUMNNAME_EMail) + " - [" + getEMail() + "]");
return false; return false;

View File

@ -123,7 +123,7 @@ public class WEditorPopupMenu extends Menupopup implements EventListener<Event>
int winID = lookup.getZoom(); int winID = lookup.getZoom();
int winIDPO = lookup.getZoom(false) ; int winIDPO = lookup.getZoom(false) ;
Boolean canAccess = MRole.getDefault().getWindowAccess(winID); Boolean canAccess = MRole.getDefault().getWindowAccess(winID);
if (winID <= 0 || canAccess == null || ! canAccess) { if (winID <= 0 || canAccess == null) {
this.zoomEnabled = false; this.zoomEnabled = false;
this.newEnabled = false; this.newEnabled = false;
this.updateEnabled = false; this.updateEnabled = false;