mirror of
https://github.com/nextcloud/ocsms.git
synced 2026-08-11 16:32:55 +00:00
Load the country settings at app load
This commit is contained in:
@@ -314,4 +314,15 @@ class SmsController extends Controller {
|
||||
$this->configMapper->set("country", $country);
|
||||
return new JSONResponse(array("status" => true, "msg" => "OK"));
|
||||
}
|
||||
|
||||
/**
|
||||
* @NoAdminRequired
|
||||
*/
|
||||
function getCountry() {
|
||||
$country = $this->configMapper->getKey("country");
|
||||
if ($country === false) {
|
||||
return new JSONResponse(array("status" => false));
|
||||
}
|
||||
return new JSONResponse(array("status" => true, "country" => $country));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user