Fix some form validation problems (closes #36)

This commit is contained in:
Bernd Bestel
2018-08-04 07:45:24 +02:00
parent 7eef4acd81
commit 6081b8ee67
8 changed files with 27 additions and 8 deletions

View File

@@ -44,6 +44,7 @@ $('#battery_id').on('change', function(e)
{
Grocy.Components.BatteryCard.Refresh(batteryId);
$('#tracked_time').find('input').focus();
Grocy.FrontendHelpers.ValidateForm('batterytracking-form');
}
});

View File

@@ -43,6 +43,7 @@ $('#habit_id').on('change', function(e)
{
Grocy.Components.HabitCard.Refresh(habitId);
Grocy.Components.DateTimePicker.GetInputElement().focus();
Grocy.FrontendHelpers.ValidateForm('habittracking-form');
}
});