Files
flutter/test_data/measurements.dart
2026-05-01 19:03:28 +02:00

107 lines
2.5 KiB
Dart

/*
* This file is part of wger Workout Manager <https://github.com/wger-project>.
* Copyright (c) 2026 wger Team
*
* wger Workout Manager is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
import 'package:wger/models/measurements/measurement_category.dart';
import 'package:wger/models/measurements/measurement_entry.dart';
final testMeasurementEntry1 = MeasurementEntry(
id: '1',
categoryId: '1',
date: DateTime(2022, 9, 10),
value: 30,
notes: '',
);
final testMeasurementEntry2 = MeasurementEntry(
id: '2',
categoryId: '1',
date: DateTime(2022, 10, 5),
value: 25,
notes: '',
);
final testMeasurementEntry3 = MeasurementEntry(
id: '3',
categoryId: '1',
date: DateTime(2022, 10, 10),
value: 17,
notes: '',
);
final testMeasurementEntry4 = MeasurementEntry(
id: '4',
categoryId: '1',
date: DateTime(2022, 11, 1),
value: 17,
notes: '',
);
final testMeasurementEntry5 = MeasurementEntry(
id: '5',
categoryId: '1',
date: DateTime(2022, 11, 10),
value: 20,
notes: '',
);
final testMeasurementEntry6 = MeasurementEntry(
id: '6',
categoryId: '1',
date: DateTime(2022, 11, 15),
value: 23,
notes: '',
);
final testMeasurementEntry7 = MeasurementEntry(
id: '7',
categoryId: '2',
date: DateTime(2026, 02, 1),
value: 40,
notes: '',
);
final testMeasurementEntry8 = MeasurementEntry(
id: '8',
categoryId: '2',
date: DateTime(2026, 03, 14),
value: 45,
notes: '',
);
List<MeasurementCategory> getMeasurementCategories() {
return [
MeasurementCategory(
id: '1',
name: 'Body fat',
unit: '%',
entries: [
testMeasurementEntry1,
testMeasurementEntry2,
testMeasurementEntry3,
testMeasurementEntry4,
testMeasurementEntry5,
testMeasurementEntry6,
],
),
MeasurementCategory(
id: '2',
name: 'Biceps',
unit: 'cm',
entries: [
testMeasurementEntry7,
testMeasurementEntry8,
],
),
];
}