diff options
author | Bent Bisballe Nyeng <deva@aasimon.org> | 2022-04-30 21:12:44 +0200 |
---|---|---|
committer | Bent Bisballe Nyeng <deva@aasimon.org> | 2022-05-26 18:41:21 +0200 |
commit | 0dea7c3dad15f397600458ae9a81af29e95752fa (patch) | |
tree | b6b17f93f907e139274b967c02ac356b56422b20 /src/database_krecipes.cc | |
parent | 0ae26aded59f09b969592c2e600dba176954c619 (diff) |
Make 'super' database, encapsulating both the krecipes one and the gourmet one. Add small vignettes to the recipe list images to indicate from which soucre each item is coming from.
Diffstat (limited to 'src/database_krecipes.cc')
-rw-r--r-- | src/database_krecipes.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/database_krecipes.cc b/src/database_krecipes.cc index fceb59c..bf764b2 100644 --- a/src/database_krecipes.cc +++ b/src/database_krecipes.cc @@ -81,6 +81,7 @@ std::deque<RecipeItem> DatabaseKrecipes::getRecipes() if(result == SQLITE_ROW) { + item.db = DatabaseSource::KRecipes; item.id = sqlite3_column_int(statement, 0); item.title = getString(statement, 1); @@ -96,7 +97,7 @@ std::deque<RecipeItem> DatabaseKrecipes::getRecipes() return items; } -Recipe DatabaseKrecipes::getRecipe(std::uint64_t id) +Recipe DatabaseKrecipes::getRecipe(int id) { bool found{false}; Recipe recipe; @@ -119,6 +120,7 @@ Recipe DatabaseKrecipes::getRecipe(std::uint64_t id) if(result == SQLITE_ROW) { + recipe.db = DatabaseSource::KRecipes; recipe.id = sqlite3_column_int(statement, 0); recipe.title = getString(statement, 1); recipe.description = {}; // not used by krecipes |