manager-app/lib/Models/menuSection.dart

31 lines
580 B
Dart

import 'dart:io';
import 'dart:ui' as ui;
class MenuSection {
String name;
String type;
int order;
MenuSection({this.name, this.type, this.order});
factory MenuSection.fromJson(Map<String, dynamic> json) {
return new MenuSection(
name: json['name'] as String,
type: json['type'] as String,
order: json['order'] as int,
);
}
Map<String, dynamic> toMap() {
return {
'name': name,
'type': type,
'order': order
};
}
@override
String toString() {
return '{name: $name, type: $type, order: $order}';
}
}