diff --git a/cookbook/integration/mealie1.py b/cookbook/integration/mealie1.py index db91bd0a6..5198d9ec0 100644 --- a/cookbook/integration/mealie1.py +++ b/cookbook/integration/mealie1.py @@ -109,7 +109,7 @@ class Mealie1(Integration): name=r['name'], source_url=r['org_url'], servings=servings, - servings_text=r['recipe_yield'].strip() if r['recipe_yield'] else "", + servings_text=r['recipe_yield'].strip()[:32] if r['recipe_yield'] else "", internal=True, created_at=r['created_at'], space=self.request.space, @@ -159,7 +159,7 @@ class Mealie1(Integration): for n in mealie_database['notes']: if n['recipe_id'] in recipes_dict: step = Step.objects.create(instruction=n['text'], - name=n['title'], + name=n['title'][:128] if n['title'] else "", order=100, space=self.request.space) steps_relation.append(Recipe.steps.through(recipe_id=recipes_dict[n['recipe_id']], step_id=step.pk)) diff --git a/cookbook/integration/mealmaster.py b/cookbook/integration/mealmaster.py index 786103b48..41e306b99 100644 --- a/cookbook/integration/mealmaster.py +++ b/cookbook/integration/mealmaster.py @@ -63,7 +63,15 @@ class MealMaster(Integration): current_recipe = '' for fl in file.readlines(): - line = fl.decode("windows-1250") + line = "" + try: + line = fl.decode("UTF-8") + except UnicodeDecodeError: + try: + line = fl.decode("windows-1250") + except Exception as e: + line = "ERROR DECODING LINE" + if (line.startswith('MMMMM') or line.startswith('-----')) and 'meal-master' in line.lower(): if current_recipe != '': recipe_list.append(current_recipe) diff --git a/cookbook/locale/uk/LC_MESSAGES/django.po b/cookbook/locale/uk/LC_MESSAGES/django.po index bece8d0a3..f4897fbcb 100644 --- a/cookbook/locale/uk/LC_MESSAGES/django.po +++ b/cookbook/locale/uk/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2024-08-01 15:04+0200\n" -"PO-Revision-Date: 2025-11-18 07:01+0000\n" +"PO-Revision-Date: 2025-11-22 20:03+0000\n" "Last-Translator: SerhiiOS \n" "Language-Team: Ukrainian \n" @@ -1085,7 +1085,7 @@ msgstr "Ви використовуєте безкоштовну версію Ta #: .\cookbook\templates\base.html:407 msgid "Upgrade Now" -msgstr "Оновити зараз" +msgstr "Оновити Зараз" #: .\cookbook\templates\batch\edit.html:6 msgid "Batch edit Category" @@ -1447,7 +1447,7 @@ msgstr "Таблиця" #: .\cookbook\templates\markdown_info.html:155 #: .\cookbook\templates\markdown_info.html:172 msgid "Header" -msgstr "Заголовок" +msgstr "Шапка" #: .\cookbook\templates\markdown_info.html:157 #: .\cookbook\templates\markdown_info.html:178 @@ -2639,7 +2639,7 @@ msgstr "Конфігурація коннектора для бекенду" #: .\cookbook\views\lists.py:91 msgid "Invite Links" -msgstr "Посилання для запрошення" +msgstr "Посилання для запрошеннь" #: .\cookbook\views\lists.py:154 msgid "Supermarkets" diff --git a/cookbook/views/views.py b/cookbook/views/views.py index 89343e264..3cb13b246 100644 --- a/cookbook/views/views.py +++ b/cookbook/views/views.py @@ -43,7 +43,10 @@ def index(request, path=None, resource=None): return HttpResponseRedirect(reverse_lazy('view_setup')) if 'signup_token' in request.session: - return HttpResponseRedirect(reverse('view_invite', args=[request.session.pop('signup_token', '')])) + value = request.session['signup_token'] + del request.session['signup_token'] + request.session.modified = True + return HttpResponseRedirect(reverse('view_invite', args=[value])) if request.user.is_authenticated or re.search(r'/recipe/\d+/', request.path[:512]) and request.GET.get('share'): return render(request, 'frontend/tandoor.html', {}) diff --git a/vue3/src/components/display/HorizontalMealPlanWindow.vue b/vue3/src/components/display/HorizontalMealPlanWindow.vue index 4b1ee0db7..ac38011c6 100644 --- a/vue3/src/components/display/HorizontalMealPlanWindow.vue +++ b/vue3/src/components/display/HorizontalMealPlanWindow.vue @@ -146,7 +146,11 @@ onMounted(() => { function clickMealPlan(plan: MealPlan) { if (plan.recipe) { - router.push({name: 'RecipeViewPage', params: {id: plan.recipe.id}}) + router.push({ + name: 'RecipeViewPage', + params: { id: String(plan.recipe.id) }, // keep id in params + query: { servings: String(plan.servings ?? '') } // pass servings as query + }) } } diff --git a/vue3/src/components/display/RecipeActivity.vue b/vue3/src/components/display/RecipeActivity.vue index b8ceae19f..c31f1d30d 100644 --- a/vue3/src/components/display/RecipeActivity.vue +++ b/vue3/src/components/display/RecipeActivity.vue @@ -69,7 +69,7 @@