forked from eatvio/eatvio_app
19 lines
424 B
Dart
19 lines
424 B
Dart
import 'package:freezed_annotation/freezed_annotation.dart';
|
|
|
|
part 'portion.freezed.dart';
|
|
|
|
part 'portion.g.dart';
|
|
|
|
@freezed
|
|
class Portion with _$Portion {
|
|
const factory Portion({
|
|
required int id,
|
|
required String product_name,
|
|
required int quantity,
|
|
required String portion,
|
|
required bool from_diet,
|
|
}) = _Portion;
|
|
|
|
factory Portion.fromJson(Map<String, Object?> json) => _$PortionFromJson(json);
|
|
}
|