feat!: convert projects to .net 5 wip

This commit is contained in:
2021-06-28 18:59:25 -04:00
parent d89739016a
commit a953521992
12 changed files with 256 additions and 0 deletions

33
Habittodo.Model/Item.cs Normal file
View File

@@ -0,0 +1,33 @@
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Linq;
namespace Habittodo.Model
{
public class Item
{
[JsonProperty("id")]
public string Id { get; set; }
[JsonProperty("content")]
public string Content { get; set; }
[JsonProperty("due")]
public Due Due { get; set; }
[JsonProperty("priority")]
public int Priority { get; set; }
[JsonProperty("parent_id")]
public string Parent_Id { get; set; }
[JsonProperty("is_deleted")]
public int Is_deleted { get; set; }
[JsonProperty("project_id")]
public string Project_id { get; set; }
[JsonProperty("date_completed")]
public string Date_completed { get; set; }
/// <summary>
/// This field will always be false when an item is marked as deleted
/// </summary>
[JsonIgnore]
public bool IsChild => !string.IsNullOrEmpty(Parent_Id);
}
}