creazione primi repository e interfacce

This commit is contained in:
Riccardo Usardi committed 2025-07-04 19:12:25 +02:00
1 parent b7983dae8e
commit 0a6744e8b0
19 files changed
+644 -39

No files matched your search

+14 -1
View File
@@ -12,5 +12,18 @@
public List<Contact> Contacts { get; set; }
public List<Vineyard> Vineyards { get; set; }
public List<Address> Addresses { get; set; }
}
public static Owner FromRecord(MySqlConnector.MySqlDataReader reader)
{
return new Owner
{
Id = reader.GetInt32("id"),
Name = reader.GetString("first_name"),
Surname = reader.GetString("last_name"),
CompanyName = reader.GetString("company_name"),
IsActive = reader.GetBoolean("active"),
CreationDate = reader.GetDateTime("creation_date"),
Note = reader.GetString("note")
};
}
}