mirror of
https://github.com/grocy/grocy.git
synced 2025-08-17 11:06:36 +00:00
Rework API to be more RESTful (references #139)
This commit is contained in:
@@ -66,7 +66,7 @@ $(document).on('click', '.track-charge-cycle-button', function(e)
|
||||
var batteryName = $(e.currentTarget).attr('data-battery-name');
|
||||
var trackedTime = moment().format('YYYY-MM-DD HH:mm:ss');
|
||||
|
||||
Grocy.Api.Post('batteries/' + batteryId + '/charged?tracked_time=' + trackedTime,
|
||||
Grocy.Api.Post('batteries/' + batteryId + '/charge', { 'tracked_time': trackedTime },
|
||||
function()
|
||||
{
|
||||
Grocy.Api.Get('batteries/' + batteryId,
|
||||
|
Reference in New Issue
Block a user