Initial draft
This commit is contained in:
16
lib/dto/basic_response.dart
Normal file
16
lib/dto/basic_response.dart
Normal file
@ -0,0 +1,16 @@
|
||||
import 'package:json_annotation/json_annotation.dart';
|
||||
|
||||
part 'basic_response.g.dart';
|
||||
|
||||
@JsonSerializable(fieldRename: FieldRename.snake)
|
||||
class BasicResponseDTO {
|
||||
BasicResponseDTO(
|
||||
{required this.succeeded,
|
||||
required this.message});
|
||||
|
||||
final bool succeeded;
|
||||
final String message;
|
||||
|
||||
factory BasicResponseDTO.fromJson(Map<String, dynamic> json) => _$BasicResponseDTOFromJson(json);
|
||||
Map<dynamic, dynamic> toJson() => _$BasicResponseDTOToJson(this);
|
||||
}
|
||||
Reference in New Issue
Block a user