stadtnavi / digitransit-ui

Digitransit UI Clone, especially for the city of Herrenberg ("stadtnavi.de")
https://stadtnavi.de/
Other
13 stars 14 forks source link

No name or info showed on car pool POI when displayed in the popup list #611

Closed Denis306 closed 3 years ago

Denis306 commented 3 years ago

When the map is zoomed out and you click on the car pool POI the car pool station ID is shown in the popup list and not the actual name of the car pool station: image

jpidelatorre commented 3 years ago

The information coming from the backend for car share points doesn't include the name.

This is the URL: https://api.dev.stadtnavi.eu/routing/v1/router/vectorTiles/citybikes/15/17192/11308.pbf

The only fields that come from it are the id and the networks.

image

jpidelatorre commented 3 years ago

@the-infinity Can you check this one out? I think it is also a problem in the backend.

the-infinity commented 3 years ago

I can, but I don't provide carsharing data, so I can just give you random thoughts without relevance *g

I suppose this is something for @leonardehrenfried (?).

jpidelatorre commented 3 years ago

No problem then. Let's wait for Leonard to check this.

leonardehrenfried commented 3 years ago

It's true that the map tiles don't contain the name however when you click more on an icon then more information is fetched via the GraphQL API which includes the name.

leonardehrenfried commented 3 years ago

Screenshot from 2021-06-14 09-34-57

^^ This is the request.

jpidelatorre commented 3 years ago

@leonardehrenfried That's true. However, when rendering the select row, we don't have that information yet, and calling this endpoint at this point would mean we have to call it twice if the user selects a station.

Also, other endpoints do have the name of the markers in the tile. For instance, parking lots have 15 fields, including the name.

image

leonardehrenfried commented 3 years ago

I misunderstood the original point that Denis raised and I checked the code right now. The name should actually be already sent so I will investigate.

Denis306 commented 3 years ago

@leonardehrenfried Any update on this?

leonardehrenfried commented 3 years ago

Thanks for reminding me. I'm currently testing a fix on dev and will have an update in a few minutes.

leonardehrenfried commented 3 years ago

Ok, there was a really silly bug in the backend which I fixed right now. Sorry for this taking forever!

curl https://api.dev.stadtnavi.eu/routing/v1/router/vectorTiles/citybikes/15/17192/11308.pbf | protoc --decode_raw
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   181  100   181    0     0   1371      0 --:--:-- --:--:-- --:--:--  1371
3 {
  1: "citybikes"
  2 {
    2: "\000\000\001\001\002\002"
    3: 1
    4: "\t\363\037\256R"
  }
  2 {
    2: "\000\003\001\004\002\005"
    3: 1
    4: "\t\223\013\227\007"
  }
  3: "id"
  3: "name"
  3: "networks"
  4 {
    1: "80104"
  }
  4 {
    1: "Hasenplatz"
  }
  4 {
    1: "car-sharing"
  }
  4 {
    1: "cargobike-herrenberg"
  }
  4 {
    1: "Cargobike TUG Herrenberg"
  }
  4 {
    1: "cargo-bike"
  }
  5: 4096
  15: 2
}
leonardehrenfried commented 3 years ago

You should get the proper name now.

jpidelatorre commented 3 years ago

Works like a charm.

image

leonardehrenfried commented 3 years ago

:facepalm: So sorry I didn't realise earlier. If you want to know what the problem was: https://github.com/mfdz/OpenTripPlanner/commit/247b47a8fac8881022426c5de68c88e660ee1840

The version before looks correct but isn't.

Denis306 commented 3 years ago

@leonardehrenfried can this issue be closed?

leonardehrenfried commented 3 years ago

I put it "on dev".

leonardehrenfried commented 3 years ago

QA team will close.