[longomatch] Include tags in plays description



commit 6eb63e64f4c82c72605d66db25dc6146c9c57683
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date:   Mon Aug 4 13:09:40 2014 +0200

    Include tags in plays description

 LongoMatch.Core/Store/Play.cs |    9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)
---
diff --git a/LongoMatch.Core/Store/Play.cs b/LongoMatch.Core/Store/Play.cs
index 4b62e4d..17900ff 100644
--- a/LongoMatch.Core/Store/Play.cs
+++ b/LongoMatch.Core/Store/Play.cs
@@ -151,6 +151,10 @@ namespace LongoMatch.Store
 
                #region Public methods
                
+               public string TagsDescription () {
+                       return String.Join ("-", Tags.Select (t => t.Value));
+               }
+
                public void AddDefaultPositions () {
                        if (Category.TagFieldPosition) {
                                if (FieldPosition == null) {
@@ -210,7 +214,10 @@ namespace LongoMatch.Store
                
                public override string ToString()
                {
-                       return Name + "\n" + Start.ToMSecondsString() + " - " + Stop.ToMSecondsString();
+                       return 
+                               Name + "\n" +
+                               TagsDescription () + "\n" +
+                               Start.ToMSecondsString() + " - " + Stop.ToMSecondsString();
                }
                #endregion
        }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]