20 lines
514 B
Dart
20 lines
514 B
Dart
import 'package:medcify/models/banner_item.dart';
|
|
import 'package:medcify/models/store_item.dart';
|
|
|
|
class StoreResponse{
|
|
bool? status;
|
|
String? message;
|
|
StoreItem? store;
|
|
|
|
StoreResponse.fromJson(Map<String, dynamic> json){
|
|
status = (json["Code"] ?? "0") != "0";
|
|
store = (json["Data"] != null) ? StoreItem.fromJson(json["Data"]) : null;
|
|
message = json["Message"] ?? "Something went wrong";
|
|
}
|
|
|
|
StoreResponse.withError(String err){
|
|
status = false;
|
|
store = null;
|
|
message = err;
|
|
}
|
|
} |