- Issue created by @Anybody
- First commit to issue fork.
- Status changed to Closed: won't fix
about 1 year ago 9:57am 5 February 2024 - 🇩🇪Germany Anybody Porta Westfalica
Canceled. See 📌 Set back to state if alpha2 Active for details.
The variable name
$settings['subman.settings']['service_url']
is confusing. From the name "service_url" you'd expect it has to be a URL
The example in the README.md uses the string "production" or "sandbox", but I thought that was just a placeholder for the URL like https://sandbox.billwerk.com/
but it's expected to be one of the mentioned strings and then converted in the module:
/**
* Returns the remote service URL of the SaaS with an optional specific
* service stub.
*
* @param string $service
* The additional uri part of the specific service endpoint stub.
* @param string $system
* The additional uri part of the specific service endpoint stub.
*
* @return string
* The generated remote service url.
*/
public function serviceUrl($service = '', $system = 'main') {
$url = $this->utils->config('service_url', 'sandbox');
switch ($url) {
case 'production':
$url = [
'main' => 'https://app.billwerk.com/',
'selfservice' => 'https://selfservice.billwerk.com/',
];
break;
case 'sandbox':
$url = [
'main' => 'https://sandbox.billwerk.com/',
'selfservice' => 'https://selfservice.sandbox.billwerk.com/',
];
break;
}
return $url[$system] . $service;
}
Typically, you would call this parameter "environment", not "service_url". This should be renamed on all levels and the old variable should be deprecated.
Of course it still has to work as fallback for existing installations!
Closed: won't fix
1.0
Code
Canceled. See 📌 Set back to state if alpha2 Active for details.