public void NotifyAbout(IViewElement message) { ViewExpensesInfo expensesInfo = (ViewExpensesInfo)message; NewExpensesId = expensesInfo.Id; NewExpensesValue = expensesInfo.Expenditure; NewExpensesType = EnumWorker.GetValueFromDescription(expensesInfo.ExpensesType); NewExpensesDate = DateTime.Parse(expensesInfo.CostsDate); NewExpensesComment = expensesInfo.Comment; oldMoneyElement = (ExpensesInfo)message.ConvertToBO(); }
public void Send(IConnectedViewModel to, IViewElement message) { if (message != null) { _jsonWorker.AddElement((ExpensesInfo)message.ConvertToBO()); } VVM.SendTo(to, message); Reset(); }