mirror of
https://github.com/inventree/inventree-app.git
synced 2025-08-30 07:45:52 +00:00
* Remove unused lib/generated/i18n.dart * Use `fvm dart format .` * Add contributing guidelines * Enforce dart format * Add `dart format off` directive to generated files
28 lines
660 B
Dart
28 lines
660 B
Dart
import "package:inventree/inventree/model.dart";
|
|
|
|
/*
|
|
* Class representing the ProjectCode database model
|
|
*/
|
|
class InvenTreeProjectCode extends InvenTreeModel {
|
|
InvenTreeProjectCode() : super();
|
|
|
|
InvenTreeProjectCode.fromJson(Map<String, dynamic> json)
|
|
: super.fromJson(json);
|
|
|
|
@override
|
|
InvenTreeModel createFromJson(Map<String, dynamic> json) =>
|
|
InvenTreeProjectCode.fromJson(json);
|
|
|
|
@override
|
|
String get URL => "project-code/";
|
|
|
|
static const String MODEL_TYPE = "projectcode";
|
|
|
|
@override
|
|
Map<String, Map<String, dynamic>> formFields() {
|
|
return {"code": {}, "description": {}};
|
|
}
|
|
|
|
String get code => getString("code");
|
|
}
|