import 'package:ambito/src/entity/entities.dart';
import 'package:isar/isar.dart';
import 'package:json_annotation/json_annotation.dart';

part 'experience_report.g.dart';

@JsonSerializable(explicitToJson: true)
@collection
class ExperienceReport extends BaseEntity with EntityWithId {
  ExperienceReport();

  @JsonKey(name: 'Kurztitel')
  String? title;
  @JsonKey(name: 'Ausführlicher Refahrungsbericht')
  String? content;
  @JsonKey(name: 'Maßnahme')
  List<IdValue>? measures;
  @JsonKey(name: 'Betrieb')
  List<IdValue>? business;

  factory ExperienceReport.fromJson(Map<String, dynamic> json) =>
      _$ExperienceReportFromJson(json);

  Map<String, dynamic> toJson() => _$ExperienceReportToJson(this);
}
