createInvoice method
Implementation
@override
Future<dynamic> createInvoice(
{required final invoices, required final token}) async {
_dio.options.headers['Authorization'] = 'Bearer $token';
try {
final response = await _dio.post('/Invoice/insert', data: invoices);
return response.data;
} on DioException catch (e) {
if (e.response != null) {
return e.response;
} else {
throw e.message.toString();
}
}
}