2020-09-26 11:30:15 +00:00
|
|
|
using System;
|
|
|
|
|
|
|
|
namespace BunyMuny {
|
|
|
|
public class Statement {
|
|
|
|
public DateTime Date;
|
2020-09-26 11:59:06 +00:00
|
|
|
private string _description;
|
|
|
|
public string Description {
|
|
|
|
get => string.IsNullOrWhiteSpace(_description) ? OriginalDescription : _description;
|
|
|
|
set { _description = value; }
|
|
|
|
}
|
|
|
|
|
|
|
|
public string OriginalDescription;
|
2020-09-26 11:30:15 +00:00
|
|
|
public double Value;
|
|
|
|
public string Category;
|
|
|
|
|
|
|
|
public override string ToString() {
|
2020-09-26 11:59:06 +00:00
|
|
|
return $"${Math.Abs(Value)} {(Value < 0 ? "to" : "from")} {(Description)} on {Date.ToString("MMM d yyyy")}";
|
2020-09-26 11:30:15 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|