Initial commit

This commit is contained in:
2023-07-23 13:34:00 +01:00
commit 967c16b6bf
65 changed files with 2868 additions and 0 deletions

View File

@ -0,0 +1,20 @@
namespace Groceries.Data;
public class List
{
public List(Guid id, string name)
{
Id = id;
Name = name;
}
public List(string name) : this(default, name)
{
}
public Guid Id { get; init; }
public DateTime UpdatedAt { get; set; }
public string Name { get; set; }
public ICollection<ListItem>? Items { get; init; }
}

View File

@ -0,0 +1,20 @@
namespace Groceries.Data;
public class ListItem
{
public ListItem(Guid id, Guid listId, string name)
{
Id = id;
ListId = listId;
Name = name;
}
public ListItem(Guid listId, string name) : this(default, listId, name)
{
}
public Guid Id { get; init; }
public Guid ListId { get; init; }
public string Name { get; set; }
public bool Completed { get; set; }
}