diff --git a/ajax/corp-mem.php b/ajax/corp-mem.php index 2e00dd9..a5f58d9 100644 --- a/ajax/corp-mem.php +++ b/ajax/corp-mem.php @@ -1,25 +1,27 @@ getCorporationsCorporationIdMembers(corpid(),$datasource); - $split_ids=array_chunk($corpmem,100); + $split_ids=array_chunk($corpmem,1000); $chars=array(); - + foreach ($split_ids as $value){ - $chars=array_merge($chars,$api_character->getCharactersNames(implode(",", array_values($value)), $datasource)); + $chars=array_merge($chars,$api_universe->postUniverseNames(json_encode($value), $datasource)); } + $json=array(); foreach ($chars as $value){ - $json[$value['character_id']] = $value['character_name']; + $json[$value['id']] = $value['name']; } + $_SESSION['corpmem']=$json;//save in ses for caching echo json_encode($_SESSION['corpmem']); } else { diff --git a/ajax/get_contracts.php b/ajax/get_contracts.php index 1b5784e..f510800 100644 --- a/ajax/get_contracts.php +++ b/ajax/get_contracts.php @@ -1,5 +1,5 @@ getCharactersCharacterIdContracts: '+$e->getMessage()); diff --git a/ajax/get_contracts_finished.php b/ajax/get_contracts_finished.php index a8b8ee3..1a572c8 100644 --- a/ajax/get_contracts_finished.php +++ b/ajax/get_contracts_finished.php @@ -1,5 +1,5 @@ getCorporationsCorporationIdWalletsDivisionJournalWithHttpInfo(corpid(), $corpwallet_id, $datasource); foreach ($result[0] as $row) { - if (($row->getDate()->getTimestamp()>strtotime('-6 hour'))&&$row->getRefType()=="corporation_account_withdrawal"&&$row->getContextIdType()=="character_id"&&$row->getContextId()==charid()&&$row->getFirstPartyId()!=$row->getSecondPartyId()&&$row->getAmount()<=0) { array_unshift($json,json_decode(strval($row)));//avoids protected property problems } } - print_r(json_encode(array($json,$result[2]['Expires'][0]))); + print_r(json_encode(array($json,$result[2]['Expires']))); } catch (Exception $e) { echo 'Exception when calling WalletApi->getCorporationsCorporationIdWalletsDivisionJournal: ', $e->getMessage(), PHP_EOL; diff --git a/ajax/get_payments_finished.php b/ajax/get_payments_finished.php index 9dab364..ea19010 100644 --- a/ajax/get_payments_finished.php +++ b/ajax/get_payments_finished.php @@ -1,5 +1,5 @@ getUniverseStationsStationId($_GET["station"], $datasource);', @@ -51,7 +50,7 @@ I have reviewed and approved your SRP requests. You have been paid for the following losses: -".$_GET["reason"]." ".$_GET["value"]." Million +".(isset($_GET["reason"])?$var:\'[No loss recorded]\').": ".$_GET["value"]." Million Please check your wallet. diff --git a/ajax/mailform.php b/ajax/mailform.php index ed1551b..6718155 100644 --- a/ajax/mailform.php +++ b/ajax/mailform.php @@ -1,6 +1,6 @@ 'demoapp', // The client ID assigned to you by the provider diff --git a/header.php b/header.php index dd60272..e63213b 100644 --- a/header.php +++ b/header.php @@ -2,9 +2,9 @@ if(session_status() == PHP_SESSION_NONE){ session_start(); } -require_once('vendor/autoload.php'); -require_once('config.php'); -require_once('func.php'); +require_once(__DIR__.'/vendor/autoload.php'); +require_once(__DIR__.'/config.php'); +require_once(__DIR__.'/func.php'); $datasource = "tranquility"; // string | The server name you would like data from diff --git a/index.php b/index.php index 105dfc8..72c7d63 100644 --- a/index.php +++ b/index.php @@ -1,5 +1,5 @@
  • One of these roles is required for this feature: Accountant/Junior Accountant +
  • +
  • + The cache timer for wallets is 1 hour. This means it is best to first make all payments ingame and then refresh the isk srp page.
  • Messages (indev):