private EntryViewerModel([NotNull] DreamEntry entry, int entryNumber, [NotNull] IDreamDiaryBus bus) { _entry = entry ?? throw new ArgumentNullException(nameof(entry)); _entryNumber = entryNumber; _dreamDiaryBus = bus ?? throw new ArgumentNullException(nameof(bus)); DreamDate = entry.Date.ToShortDateString(); DreamText = entry.Text; DreamTags = entry.GetTagString(); }
private void LoadEditEntry() { DreamTextBox.Text = _editEntry.Text; TagsBox.Text = _editEntry.GetTagString(); DreamDatePicker.Text = _editEntry.GetDateAsStr(); }