push delete automation

This commit is contained in:
ashrafzarkanisala
2024-07-25 00:34:00 +03:00
parent 8a4c5af2e7
commit 3e20ba8f42
6 changed files with 46 additions and 8 deletions

View File

@ -183,4 +183,21 @@ class SceneApi {
rethrow;
}
}
// delete automation
static Future<bool> deleteAutomation(
{required String unitUuid, required String automationId}) async {
try {
final response = await _httpService.delete(
path: ApiEndpoints.deleteAutomation
.replaceAll('{automationId}', automationId)
.replaceAll('{unitUuid}', unitUuid),
showServerMessage: false,
expectedResponseModel: (json) => json['statusCode'] == 200,
);
return response;
} catch (e) {
rethrow;
}
}
}