import 'package:equatable/equatable.dart';

class Product extends Equatable {
  final String uuid;
  final String name;

  const Product({
    required this.uuid,
    required this.name,
  });

  factory Product.fromJson(Map<String, dynamic> json) {
    return Product(
      uuid: json['uuid'] as String,
      name: json['name'] as String,
    );
  }

  Map<String, dynamic> toJson() {
    return {
      'uuid': uuid,
      'name': name,
    };
  }

  @override
  List<Object?> get props => [uuid, name];
}
