PMJBY/SBY enquiry created
This commit is contained in:
@@ -175,4 +175,39 @@ String? policystatus,
|
||||
);
|
||||
return response.toString();
|
||||
}
|
||||
|
||||
Future<dynamic> enquiry({
|
||||
required String scheme,
|
||||
required String action,
|
||||
required String financialyear,
|
||||
String? customerno,
|
||||
}) async {
|
||||
try {
|
||||
final response = await _dio.get(
|
||||
"/api/gov-scheme/enquiry/PMJBY",
|
||||
queryParameters: {
|
||||
'scheme': scheme,
|
||||
'action': action,
|
||||
'financialyear': financialyear,
|
||||
'customerno': customerno,
|
||||
},
|
||||
options: Options(
|
||||
headers: {
|
||||
"Content-Type": "application/json",
|
||||
},
|
||||
),
|
||||
);
|
||||
|
||||
log("PMY Details Response: ${response.data}");
|
||||
|
||||
if (response.statusCode == 200) {
|
||||
return response.data;
|
||||
} else {
|
||||
throw Exception("INTERNAL SERVER ERROR");
|
||||
}
|
||||
} catch (e) {
|
||||
log("Error fetching PMY details: $e");
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user