rawFilterPatientsByWithHttpInfo method
Future<Response>
rawFilterPatientsByWithHttpInfo(
- FilterChain<
PatientDto> filterChainPatient, { - String? startKey,
- String? startDocumentId,
- int? limit,
- int? skip,
- String? sort,
- bool? desc,
Filter patients for the current user (HcParty)
Returns a list of patients along with next start keys and Document ID. If the nextStartKey is Null it means that this is the last page.
Note: This method returns the HTTP Response
.
Parameters:
Implementation
Future<Response> rawFilterPatientsByWithHttpInfo(FilterChain<PatientDto> filterChainPatient, { String? startKey, String? startDocumentId, int? limit, int? skip, String? sort, bool? desc, }) async {
// ignore: prefer_const_declarations
final path = r'/rest/v1/patient/filter';
// ignore: prefer_final_locals
Object? postBody = filterChainPatient;
final queryParams = <QueryParam>[];
final headerParams = <String, String>{};
final formParams = <String, String>{};
if (startKey != null) {
queryParams.addAll(_queryParams('', 'startKey', startKey));
}
if (startDocumentId != null) {
queryParams.addAll(_queryParams('', 'startDocumentId', startDocumentId));
}
if (limit != null) {
queryParams.addAll(_queryParams('', 'limit', limit));
}
if (skip != null) {
queryParams.addAll(_queryParams('', 'skip', skip));
}
if (sort != null) {
queryParams.addAll(_queryParams('', 'sort', sort));
}
if (desc != null) {
queryParams.addAll(_queryParams('', 'desc', desc));
}
const authNames = <String>[r'basicSchema'];
const contentTypes = <String>['application/json'];
return apiClient.invokeAPI(
path,
'POST',
queryParams,
postBody,
headerParams,
formParams,
contentTypes.isEmpty ? null : contentTypes.first,
authNames,
);
}