CMXX - BUGFIX

This commit is contained in:
“VeLiTi”
2024-11-11 19:45:41 +01:00
parent a20e9440d0
commit 1c2d0d0496
3 changed files with 8 additions and 7 deletions

View File

@@ -134,7 +134,7 @@ if (!isset($criterias['productrowid']) && isset($criterias['productcode']) && $c
"latest"=> "", "latest"=> "",
"software"=> "", "software"=> "",
"source" => "", "source" => "",
"source_type" => "", "source_type" => ""
); );
//CHECK IF VERSION IS LATEST //CHECK IF VERSION IS LATEST

View File

@@ -137,7 +137,7 @@ if (!isset($criterias['productrowid']) && isset($criterias['productcode']) && $c
"latest"=> "", "latest"=> "",
"software"=> "", "software"=> "",
"source" => "", "source" => "",
"source_type" => "", "source_type" => ""
); );
//CHECK IF VERSION IS LATEST //CHECK IF VERSION IS LATEST

View File

@@ -2808,11 +2808,12 @@ function dateInRange($start_date, $end_date, $date_check)
function getLatestVersion($productcode,$token){ function getLatestVersion($productcode,$token){
//BUILD POST DATA //CALL TO API TO GET ALL ACTIVE CONTRACTS
$data = json_encode(array("productcode" => $productcode), JSON_UNESCAPED_UNICODE); $api_url = '/v2/products_software/productcode='.$productcode;
//API call $responses = ioAPIv2($api_url,'',$token);
$responses = ioAPIv2('/v2/products_software', $data, $token);
echo 'test';
//Decode Payload
if (!empty($responses)){$responses = json_decode($responses,true);}else{$responses = null;} if (!empty($responses)){$responses = json_decode($responses,true);}else{$responses = null;}
//DEFAULT OUTPUT //DEFAULT OUTPUT
@@ -2823,7 +2824,7 @@ function getLatestVersion($productcode,$token){
"latest"=> "", "latest"=> "",
"software"=> "", "software"=> "",
"source" => "", "source" => "",
"source_type" => "", "source_type" => ""
); );
if(!empty($responses)) { if(!empty($responses)) {