Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
Travel-Status-DE-HAFAS
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
derf
Travel-Status-DE-HAFAS
Commits
a9d52684
Unverified
Commit
a9d52684
authored
2 years ago
by
Birte Kristina Friesel
Browse files
Options
Downloads
Patches
Plain Diff
station board: parse load (tcocX) as well
parent
9317d6e3
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
bin/hafas-m
+7
-0
7 additions, 0 deletions
bin/hafas-m
lib/Travel/Status/DE/HAFAS/Journey.pm
+10
-1
10 additions, 1 deletion
lib/Travel/Status/DE/HAFAS/Journey.pm
with
17 additions
and
1 deletion
bin/hafas-m
+
7
−
0
View file @
a9d52684
...
...
@@ -293,6 +293,13 @@ for my $d ( $status->results ) {
}
}
if
(
$d
->
load
)
{
$info_line
=
display_occupancy
(
$d
->
load
->
{
FIRST
}
)
.
display_occupancy
(
$d
->
load
->
{
SECOND
}
)
.
'
'
.
$info_line
;
}
push
(
@output
,
[
...
...
This diff is collapsed.
Click to expand it.
lib/Travel/Status/DE/HAFAS/Journey.pm
+
10
−
1
View file @
a9d52684
...
...
@@ -15,7 +15,7 @@ our $VERSION = '3.01';
Travel::Status::DE::HAFAS::
Journey
->
mk_ro_accessors
(
qw(datetime sched_datetime rt_datetime is_cancelled operator delay
platform sched_platform rt_platform
id name type type_long number line
id name type type_long number line
load
route_end route_start origin destination direction)
);
...
...
@@ -216,6 +216,15 @@ sub new {
else
{
$ref
->
{
datetime
}
=
$ref
->
{
sched_datetime
};
}
my
%tco
;
for
my
$tco_id
(
@
{
$journey
->
{
stbStop
}{
dTrnCmpSX
}{
tcocX
}
//
[]
}
)
{
my
$tco_kv
=
$tcocL
[
$tco_id
];
$tco
{
$tco_kv
->
{
c
}
}
=
$tco_kv
->
{
r
};
}
if
(
%tco
)
{
$ref
->
{
load
}
=
\
%tco
;
}
}
if
(
$opt
{
polyline
}
)
{
$ref
->
{
polyline
}
=
$opt
{
polyline
};
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment