Page 1 of 1

Apply service time only on start and end locations

Posted: Fri Jun 03, 2022 1:19 pm
by CAPcargo
Hi,

I`m using the xServer2 xTourClient.planTours method to get optimized tours based on my orders.

I have a scenario where I would like to have a fixed service time but only on the start and end location of the tour.
If the same location is visited again in the middle of the tour, that service time should not be considered to that location.
Because of this I cannot simply use the ServiceTimePerStop property on the Site object because it would add that time on every tour stop that happens on the same location.

I`ve tried to add a 'fake' start&end locations that has the same coordinates as my actual tour start but just having a different ID and set the ServiceTimePerStop on it, and then set those locations as the start and end locations on ALL vehicles, hoping that like this it will apply the ServiceTimeOnTourStop value, but the response that I get the tour action duration is 0 for the 'fake' start/end locations.


This is part of my response object:

"tours": [
{
"vehicleId": "5637187371",
"vehicleStartLocationId": "111111", // this is my 'fake' start location that i set on each vehicle
"vehicleEndLocationId": "222222", // this is my 'fake' end location that i set on each vehicle
.
.
]
}


"tourEvents": [
{
"startTime": "2019-03-02T10:38:15Z",
"tripId": "",
"locationId": "111111", // the 'fake' start location
"orderId": null,
"eventTypes": [
7
],
"tourViolations": null,
"duration": 0.0 // the durations on the action on the '111111' location is 0
},
{
"startTime": "2019-03-02T10:38:15Z",
"tripId": "1d0be59f-fc7d-48aa-bd5e-4f53e5a34275",
"locationId": "111111", // the 'fake' start location
"orderId": null,
"eventTypes": [
5
],
"tourViolations": null,
"duration": 0.0 // the durations on the action on the '111111' location is 0
},



I have also tried to use the ptv2.26 AdditionalServiceTimePerStop property on the Depot site object but it only gets added if on that location we do a load or unload, else it`s get ignored (in our case it can happen that no load or unload is done on the start/end location).

Any suggestions how can I achieve my requirement?

Thanks,
Marko

Re: Apply service time only on start and end locations

Posted: Wed Jun 08, 2022 12:59 pm
by Bernd Welter
Hi Marko,

we discussed this among DEV and me. Here's what we can return - maybe you can give us more insights into the story itself, so we can check whether we can find a technical approach for the usecase requirement:
  • First of all you are right: the service period at the vehicle start and vehicle end location is not considered.
  • There's no explizit feature for what you described so far.
  • If you are 100% sure that the service periods should only be taken into consideration for the first/last stop on the tours (or do you mean trips, by the way?) you could predefine some dummy orders and set these order's customer site's properties in a meaningful way, e.g. the PositionInTrip (Attention: this also has to consider that there are no depots before the dummy pickup)
If needed let's set up a 1:1 session with me and one member from our DEV team,

Bernd

Re: Apply service time only on start and end locations

Posted: Sat Jun 11, 2022 9:36 am
by CAPcargo
Hi
To have a fix time on vehicle start and end is related to mandatory departure check and final control all drivers of LKW need to perform. As a general duration 15 min are to apply.
see in DE: https://www.wedolo.de/blog/huerden-bei- ... skontrolle

Beat

Re: Apply service time only on start and end locations

Posted: Tue Jun 14, 2022 10:59 am
by Bernd Welter
Oh, the chefe himself!

Well - here's another feedback from Christian - which also raised the question whether you deal with single trip structures or not (I remember that you modelled some pickups as DepotSites though a CustomerSite would have been sufficient):
There's no dedicated feature available for this. If you deal with a single trip and you don'tr need further restrictions of the working time we recommend to reduce the operating interval by 15minutes and to re-add them manually afterwards. As you tried to approach this by adding a service time to the VehicleSartLocation this sounds like a single trip scenario. If there's exact ONE depot which occurs at the beginning and the end of each trip you could also add 15minutes to the depot's service period. For all other cases: not implemented so far...
Bernd

Here's Christian's original answer:
Wir haben wie gesagt kein Feature für diese Anforderung.Wenn sie SingleTrip verwenden und keine Beschränkung der Arbeitszeit besteht, dann sollte Danielas Vorschlag funktionieren. Da sie ja versucht haben, der VehicleStartLocation eine Servicezeit zu geben, könnte singleTrip ja sogar der Fall sein.Falls sie genau ein Depot haben, das am Anfang und am Ende eines jeden Trips auftaucht, dann kann man die 15 Minuten zu der Stopservicezeit des Depots dazunehmen.Für andere Fälle: geht nicht ohne Weiteres.

Re: Apply service time only on start and end locations

Posted: Mon Jun 27, 2022 12:34 pm
by CAPcargo
Hi Bernd,

I was actually on vacation and couldn`t reply sooner :)

Now I`m back at the topic again:

So, yes we use the single trip scenario only.

We currently still use Depot site and Customer site, but we will soon get rid of the Depot site usage.
(The only way we would accept to use the multi trip scenario is if the Depot site has some specific property that would be beneficial to us. In this way we would then try to adapt/convert the way we generate our tours.)

Some more clarifications based on our needs:
1. Our tour can start on one location but can also end on another one.
2. The start and the end location can also appear on some in between stop (so it`s not that they`re visited only once on the beginning and the end of the tour).


Can you explain in more detail what Christian meant by 'reduce the operating interval by 15minutes and to re-add them manually afterwards'?
I can see that the drivers have an operatingIntervals property, was that what he meant?

Re: Apply service time only on start and end locations

Posted: Fri Jul 01, 2022 3:09 pm
by Bernd Welter
What Christian recommended was:
- Imagine you want to consider a 15min "preparation period" at the beginning of a drivers work day, e.g. availability "08:00-17:00", with an initial task of 15mins (hard restriction as "first on the tour?"

Christian is on vacation - I'll let him know that you came back to the thread