mirror of
https://github.com/grocy/grocy.git
synced 2025-04-29 09:39:57 +00:00
Added a "clear" button above the new notes field on the shopping list page
This commit is contained in:
parent
e548caabb1
commit
dea2ffeaaf
@ -4,10 +4,13 @@
|
||||
- Fixed that after product actions (consume/purchase/etc.) on the stock overview page the highlighting of the row was maybe wrong
|
||||
- After product actions (consume/purchase/etc.) on the stock overview page on a sub product, now also the parent product (row) is refreshed
|
||||
- It's now possible to accumulate min. stock amounts on parent product level (new option per product, means the sub product will never be "missing" then, only the parent product)
|
||||
- When adding a product to the shopping list from the new context/more menu from the stock overview page and if the product is already on the shopping list, the amount of that entry will be updated acccordingly instead of adding a new (double) shopping list item
|
||||
- On the purchase page there is now an option to select that the price is the total price (for the whole amount) - below the price field, defaults to "Unit price" (as it was until now), when set to "Total price", the entered price will be divided by the amount before posting
|
||||
- "Average shelf life" on the product card now displays just "Unlimited" when the resulting value would be > 200 years (for products which never expire, as they have a best before date of 2999-12-31)
|
||||
|
||||
### Shopping list improvements
|
||||
- When adding a product to the shopping list from the new context/more menu from the stock overview page and if the product is already on the shopping list, the amount of that entry will be updated acccordingly instead of adding a new (double) shopping list item
|
||||
- Added a "clear" button above the new notes field on the shopping list page to quickly clear the notes field with one click
|
||||
|
||||
### Recipe improvements/fixes
|
||||
- Fixed a problem regarding quantity unit conversion handling for recipe ingredients of products with no unit relations, but only a different purchase/stock quantity unit
|
||||
- It's now possible to display a recipe directly from the meal plan (new "eye button") (thanks @kriddles)
|
||||
|
@ -1540,3 +1540,6 @@ msgstr ""
|
||||
|
||||
msgid "Unlimited"
|
||||
msgstr ""
|
||||
|
||||
msgid "Clear"
|
||||
msgstr ""
|
||||
|
@ -316,6 +316,15 @@ $(document).on("click", "#print-shopping-list-button", function(e)
|
||||
$("#description").on("summernote.change", function()
|
||||
{
|
||||
$("#save-description-button").removeClass("disabled");
|
||||
|
||||
if ($("#description").summernote("isEmpty"))
|
||||
{
|
||||
$("#clear-description-button").addClass("disabled");
|
||||
}
|
||||
else
|
||||
{
|
||||
$("#clear-description-button").removeClass("disabled");
|
||||
}
|
||||
});
|
||||
|
||||
$(document).on("click", "#save-description-button", function(e)
|
||||
@ -334,3 +343,15 @@ $(document).on("click", "#save-description-button", function(e)
|
||||
}
|
||||
);
|
||||
});
|
||||
|
||||
$(document).on("click", "#clear-description-button", function(e)
|
||||
{
|
||||
e.preventDefault();
|
||||
document.activeElement.blur();
|
||||
|
||||
$("#description").summernote("reset");
|
||||
$("#save-description-button").click();
|
||||
});
|
||||
|
||||
$("#description").trigger("summernote.change");
|
||||
$("#save-description-button").addClass("disabled");
|
||||
|
@ -149,7 +149,8 @@
|
||||
<div class="col-xs-12 col-md-8">
|
||||
<div class="form-group">
|
||||
<label class="text-larger font-weight-bold" for="notes">{{ $__t('Notes') }}</label>
|
||||
<a id="save-description-button" class="btn btn-success btn-sm ml-1 mb-2 disabled" href="#">{{ $__t('Save') }}</a>
|
||||
<a id="save-description-button" class="btn btn-success btn-sm ml-1 mb-2" href="#">{{ $__t('Save') }}</a>
|
||||
<a id="clear-description-button" class="btn btn-danger btn-sm ml-1 mb-2" href="#">{{ $__t('Clear') }}</a>
|
||||
<textarea class="form-control wysiwyg-editor" id="description" name="description">{{ FindObjectInArrayByPropertyValue($shoppingLists, 'id', $selectedShoppingListId)->description }}</textarea>
|
||||
</div>
|
||||
</div>
|
||||
|
Loading…
x
Reference in New Issue
Block a user