mirror of
https://github.com/mealie-recipes/mealie.git
synced 2025-11-30 07:34:10 -05:00
fix: sort recent recipes by created_at instead of date_added (#1417)
* added staticmethod decorators to avoid mypy error * exposed created and updated timestamps to schema * changed default sort from date_added to created_at * explicitely sort recent recipes by created_at * removed static method and replaced w/ type: ignore
This commit is contained in:
@@ -97,7 +97,7 @@ export const useRecipes = (all = false, fetchRecipes = true) => {
|
||||
})();
|
||||
|
||||
async function refreshRecipes() {
|
||||
const { data } = await api.recipes.getAll(start, end, { loadFood: true });
|
||||
const { data } = await api.recipes.getAll(start, end, { loadFood: true, orderBy: "created_at" });
|
||||
if (data) {
|
||||
recipes.value = data;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user