mirror of
https://github.com/grocy/grocy.git
synced 2025-04-29 09:39:57 +00:00
Optimized datetime Userfields handling (fixes #2108)
This commit is contained in:
parent
b18bd2ff87
commit
c9c0baefeb
@ -73,6 +73,7 @@
|
|||||||
### Userfields
|
### Userfields
|
||||||
|
|
||||||
- Product group Userfields are now also rendered on the shopping list
|
- Product group Userfields are now also rendered on the shopping list
|
||||||
|
- Fixed that when having e.g. a Userfield for the `stock` entity and using the "Never overdue" shortcut checkbox for the due date on purchase, this Userfield would also be set to the corresponding "never overdue date"
|
||||||
|
|
||||||
### General
|
### General
|
||||||
|
|
||||||
|
@ -76,7 +76,7 @@ $(document).on('click', '.userfield-delete-button', function(e)
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
if (GetUriParam("entity")
|
if (GetUriParam("entity"))
|
||||||
{
|
{
|
||||||
$("#entity-filter").val(GetUriParam("entity"));
|
$("#entity-filter").val(GetUriParam("entity"));
|
||||||
$("#entity-filter").trigger("change");
|
$("#entity-filter").trigger("change");
|
||||||
|
@ -56,7 +56,7 @@
|
|||||||
'value' => ''
|
'value' => ''
|
||||||
))
|
))
|
||||||
@elseif($userfield->type == \Grocy\Services\UserfieldsService::USERFIELD_TYPE_DATE)
|
@elseif($userfield->type == \Grocy\Services\UserfieldsService::USERFIELD_TYPE_DATE)
|
||||||
@include('components.datetimepicker', array(
|
@include('components.datetimepicker2', array(
|
||||||
'id' => $userfield->name,
|
'id' => $userfield->name,
|
||||||
'label' => $userfield->caption,
|
'label' => $userfield->caption,
|
||||||
'noNameAttribute' => true,
|
'noNameAttribute' => true,
|
||||||
@ -64,13 +64,13 @@
|
|||||||
'initWithNow' => false,
|
'initWithNow' => false,
|
||||||
'limitEndToNow' => false,
|
'limitEndToNow' => false,
|
||||||
'limitStartToNow' => false,
|
'limitStartToNow' => false,
|
||||||
'additionalGroupCssClasses' => 'date-only-datetimepicker',
|
'additionalGroupCssClasses' => 'date-only-datetimepicker2',
|
||||||
'isRequired' => $userfield->input_required == 1,
|
'isRequired' => $userfield->input_required == 1,
|
||||||
'additionalCssClasses' => 'userfield-input',
|
'additionalCssClasses' => 'userfield-input',
|
||||||
'additionalAttributes' => 'data-userfield-name="' . $userfield->name . '"'
|
'additionalAttributes' => 'data-userfield-name="' . $userfield->name . '"'
|
||||||
))
|
))
|
||||||
@elseif($userfield->type == \Grocy\Services\UserfieldsService::USERFIELD_TYPE_DATETIME)
|
@elseif($userfield->type == \Grocy\Services\UserfieldsService::USERFIELD_TYPE_DATETIME)
|
||||||
@include('components.datetimepicker', array(
|
@include('components.datetimepicker2', array(
|
||||||
'id' => $userfield->name,
|
'id' => $userfield->name,
|
||||||
'label' => $userfield->caption,
|
'label' => $userfield->caption,
|
||||||
'noNameAttribute' => true,
|
'noNameAttribute' => true,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user