You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
PatientApp-KKUMC/lib/core/service/er/am_service.dart

26 lines
906 B
Dart

import 'package:diplomaticquarterapp/config/config.dart';
import 'package:diplomaticquarterapp/config/shared_pref_kay.dart';
import 'package:diplomaticquarterapp/core/model/er/get_all_transportation_method_list_model.dart';
import '../base_service.dart';
class AmService extends BaseService {
List<PatientER_RRT_GetAllTransportationMethodListModel> AmModelList = List();
Map<String, dynamic> body = Map();
Future getAllTransportationOrders() async {
hasError = false;
await baseAppClient.post(GET_AMBULANCE_REQUEST,
onSuccess: (dynamic response, int statusCode) {
AmModelList.clear();
response['AmModelList'].forEach((vital) {
AmModelList.add(
PatientER_RRT_GetAllTransportationMethodListModel.fromJson(vital));
});
}, onFailure: (String error, int statusCode) {
hasError = true;
super.error = error;
}, body: body);
}
}