createSlot method
override
Pushes a new slot
to the server.
Implementation
@override
Future<Slot> createSlot({required String token, required Slot slot}) async {
log('Creating slot $slot');
final json = slot.toJson()
..remove('id')
..remove('');
final response = await api.callFunction(
function: 'local_lbplanner_slots_create_slot',
body: json,
token: token,
);
response.assertJson();
return Slot.fromJson(response.asJson);
}