following method
Gets the list of companies a follower is following.
id is the ID of the follower.
Returns a list of CompanyFollowedModel instances.
Implementation
Future<ApiResponseModel<List<CompanyFollowedModel>>> following({
required String id,
}) async {
final url = "$_baseUrl/follower/$id/following";
final payload = {};
debugPrint("flutter_mon_sms_pro/follower/following/payload: $payload");
final r = await _dio.post(url, data: payload);
debugPrint("flutter_mon_sms_pro/follower/following/data: ${r.data}");
final response = ApiResponseModel.fromJson(
r.data,
(data) => (data as List<dynamic>)
.map((e) => CompanyFollowedModel.fromJson(e as Map<String, dynamic>))
.toList(),
);
return response;
}