23 lines
593 B
Dart
23 lines
593 B
Dart
import 'package:lamiter/Class/Entity/entity.dart';
|
|
|
|
class BodyIssue extends Entity {
|
|
final List<String> relatedAcupointsIds;
|
|
|
|
BodyIssue({
|
|
required super.id,
|
|
required super.name,
|
|
required this.relatedAcupointsIds,
|
|
});
|
|
|
|
// Named constructor from JSON
|
|
BodyIssue.fromJson(Map<String, dynamic> json)
|
|
: relatedAcupointsIds = (json['relatedAcupointsIds'] as List<dynamic>?)
|
|
?.map((item) => item as String)
|
|
.toList() ??
|
|
[],
|
|
super(
|
|
id: json['_id'] as String,
|
|
name: json['name'] as String,
|
|
);
|
|
}
|