summaryrefslogtreecommitdiff
path: root/lib/Travel/Status/DE/DBWagenreihung/Group.pm
diff options
context:
space:
mode:
authorBirte Kristina Friesel <derf@finalrewind.org>2024-07-30 11:22:00 +0200
committerBirte Kristina Friesel <derf@finalrewind.org>2024-07-30 11:22:00 +0200
commitefb13e90e8352c54741832a6f5d950b011c79998 (patch)
tree57459a019ab9e032b58e254be50d15cb9430560d /lib/Travel/Status/DE/DBWagenreihung/Group.pm
parentd3b0c61cc20facb45b52533459ed139cea8df9a9 (diff)
sort carriages and groups
Diffstat (limited to 'lib/Travel/Status/DE/DBWagenreihung/Group.pm')
-rw-r--r--lib/Travel/Status/DE/DBWagenreihung/Group.pm5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/Travel/Status/DE/DBWagenreihung/Group.pm b/lib/Travel/Status/DE/DBWagenreihung/Group.pm
index 5cd2b24..b6848ab 100644
--- a/lib/Travel/Status/DE/DBWagenreihung/Group.pm
+++ b/lib/Travel/Status/DE/DBWagenreihung/Group.pm
@@ -11,7 +11,7 @@ use List::Util qw(uniq);
our $VERSION = '0.14';
Travel::Status::DE::DBWagenreihung::Group->mk_ro_accessors(
- qw(train_no train_type description desc_short destination has_sectors model series)
+ qw(train_no train_type description desc_short destination has_sectors model series start_percent end_percent)
);
# {{{ Rolling Stock Models
@@ -97,6 +97,9 @@ sub new {
$ref->{has_sectors} = 1;
}
+ $ref->{start_percent} = $ref->{carriages}[0]->start_percent;
+ $ref->{end_percent} = $ref->{carriages}[-1]->end_percent;
+
bless( $ref, $obj );
$ref->parse_description;