2020-05-24 02:12:37 +01:00
|
|
|
|
/******************************************************************************
|
2020-05-21 17:23:46 +01:00
|
|
|
|
// MARECHAI: Master repository of computing history artifacts information
|
|
|
|
|
|
// ----------------------------------------------------------------------------
|
|
|
|
|
|
//
|
|
|
|
|
|
// Author(s) : Natalia Portillo <claunia@claunia.com>
|
|
|
|
|
|
//
|
|
|
|
|
|
// --[ License ] --------------------------------------------------------------
|
|
|
|
|
|
//
|
|
|
|
|
|
// This program is free software: you can redistribute it and/or modify
|
|
|
|
|
|
// it under the terms of the GNU General Public License as
|
|
|
|
|
|
// published by the Free Software Foundation, either version 3 of the
|
|
|
|
|
|
// License, or (at your option) any later version.
|
|
|
|
|
|
//
|
|
|
|
|
|
// This program is distributed in the hope that it will be useful,
|
|
|
|
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
|
|
// GNU General Public License for more details.
|
|
|
|
|
|
//
|
|
|
|
|
|
// You should have received a copy of the GNU General Public License
|
|
|
|
|
|
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
|
|
//
|
|
|
|
|
|
// ----------------------------------------------------------------------------
|
|
|
|
|
|
// Copyright © 2003-2020 Natalia Portillo
|
|
|
|
|
|
*******************************************************************************/
|
|
|
|
|
|
|
|
|
|
|
|
using System;
|
2020-05-24 17:39:37 +01:00
|
|
|
|
using Marechai.Database;
|
2020-05-21 17:23:46 +01:00
|
|
|
|
|
|
|
|
|
|
namespace Marechai.ViewModels
|
|
|
|
|
|
{
|
2020-05-24 17:39:37 +01:00
|
|
|
|
public sealed class NewsViewModel : BaseViewModel<int>
|
2020-05-21 17:23:46 +01:00
|
|
|
|
{
|
2020-08-05 21:00:35 +01:00
|
|
|
|
public NewsViewModel() {}
|
2020-05-24 17:39:37 +01:00
|
|
|
|
|
2020-05-21 17:23:46 +01:00
|
|
|
|
public NewsViewModel(int affectedId, string text, DateTime timestamp, string controller, string itemName)
|
|
|
|
|
|
{
|
|
|
|
|
|
AffectedId = affectedId;
|
|
|
|
|
|
Text = text;
|
|
|
|
|
|
Timestamp = timestamp;
|
|
|
|
|
|
Controller = controller;
|
|
|
|
|
|
ItemName = itemName;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2020-05-24 17:39:37 +01:00
|
|
|
|
public NewsType Type { get; set; }
|
|
|
|
|
|
public int AffectedId { get; set; }
|
2020-05-21 17:23:46 +01:00
|
|
|
|
public string Controller { get; }
|
|
|
|
|
|
public string ItemName { get; }
|
|
|
|
|
|
public string Text { get; }
|
2020-05-24 17:39:37 +01:00
|
|
|
|
public DateTime Timestamp { get; set; }
|
2020-05-21 17:23:46 +01:00
|
|
|
|
}
|
|
|
|
|
|
}
|