From 96dc429d261eb64f124b44fc4d9bab7cc80ecf74 Mon Sep 17 00:00:00 2001 From: Carlos Ruiz Date: Fri, 27 Jan 2012 16:47:39 -0500 Subject: [PATCH] IDEMPIERE-127 Implement Recent Items dashboard http://jira.idempiere.com/browse/IDEMPIERE-127 --- .../src/org/compiere/model/MRecentItem.java | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/org.adempiere.base/src/org/compiere/model/MRecentItem.java b/org.adempiere.base/src/org/compiere/model/MRecentItem.java index 65010658b5..34fee60431 100644 --- a/org.adempiere.base/src/org/compiere/model/MRecentItem.java +++ b/org.adempiere.base/src/org/compiere/model/MRecentItem.java @@ -247,7 +247,13 @@ public class MRecentItem extends X_AD_RecentItem recordIdentifier = recordIdentifier + "_" + po.get_ValueAsString("Value"); if (po.get_ColumnIndex("Name") > 0) recordIdentifier = recordIdentifier + "_" + po.get_ValueAsString("Name"); - + if (recordIdentifier.length() == 0) + recordIdentifier = "_" + po.toString(); + if (recordIdentifier.length() == 0) + recordIdentifier = "_[" + po.get_ID() + "]"; + if (recordIdentifier.length() == 0) + recordIdentifier = "_[no identifier]"; + return windowName + ": " + recordIdentifier.substring(1); }