Skip to content

Commit

Permalink
Merge pull request #3839 from devlab-oy/satu/mh_seuranta
Browse files Browse the repository at this point in the history
Matkahuollon seurantalinkki
  • Loading branch information
tomit authored Mar 6, 2018
2 parents 6580239 + 996abd5 commit 92e77a9
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions inc/functions.inc
Original file line number Diff line number Diff line change
Expand Up @@ -34857,6 +34857,7 @@ if (!function_exists("tilauksen_seurantalinkit")) {
$unifaun = (stripos($rahtikirja, "unifaun") !== false and !empty($unifaun_url_key));
$ups = (stripos($rahtikirjanro, 'ups') !== false);
$kaukokiito = (strtoupper($virallinen_selite) == "KKSTD");
$matkahuolto = (stripos($virallinen_selite, "MH") !== false);

// dpd unifaunin kautta
if ($dpd and $unifaun) {
Expand Down Expand Up @@ -34948,6 +34949,20 @@ if (!function_exists("tilauksen_seurantalinkit")) {
);
}
}
elseif ($matkahuolto) {
$_i = 0;
foreach (explode("\n", $row['rahtikirjanro']) as $nro) {

$_i++;
// skipataan ensimm�inen (Pupen generoima numero)
if ($_i == 1) continue;

$seurantakoodit[] = array(
"id" => $nro,
"link" => "http://mhhkiweb1.matkahuolto.fi/scripts/loginetyleinen.wsc/002tapahtuma_new?spacketnum={$nro}"
);
}
}
// unifaun ja mittoihin perustuvat ker�yser�t ei ole k�yt�ss�
elseif ($unifaun and $yhtiorow['kerayserat'] != 'K') {

Expand Down

0 comments on commit 92e77a9

Please sign in to comment.