cfmgrv4 init...2
This commit is contained in:
parent
f051e0ae11
commit
a7ff8e6ebd
@ -13,7 +13,6 @@ use Psr\Log\LoggerInterface;
|
|||||||
|
|
||||||
class AccountController extends CloudflareController
|
class AccountController extends CloudflareController
|
||||||
{
|
{
|
||||||
private $_myLibrary = null;
|
|
||||||
private $_model = null;
|
private $_model = null;
|
||||||
private $_auth_entity = null;
|
private $_auth_entity = null;
|
||||||
public function initController(RequestInterface $request, ResponseInterface $response, LoggerInterface $logger)
|
public function initController(RequestInterface $request, ResponseInterface $response, LoggerInterface $logger)
|
||||||
@ -33,10 +32,7 @@ class AccountController extends CloudflareController
|
|||||||
}
|
}
|
||||||
final protected function getMyLibrary(): Account
|
final protected function getMyLibrary(): Account
|
||||||
{
|
{
|
||||||
if ($this->_myLibrary === null) {
|
return new Account($this->_auth_entity);
|
||||||
$this->_myLibrary = new Account($this->_auth_entity);
|
|
||||||
}
|
|
||||||
return $this->_myLibrary;
|
|
||||||
}
|
}
|
||||||
protected function getFormFieldOption(string $field, array $options = []): array
|
protected function getFormFieldOption(string $field, array $options = []): array
|
||||||
{
|
{
|
||||||
|
|||||||
@ -13,7 +13,6 @@ use Psr\Log\LoggerInterface;
|
|||||||
|
|
||||||
class RecordController extends CloudflareController
|
class RecordController extends CloudflareController
|
||||||
{
|
{
|
||||||
private $_myLibrary = null;
|
|
||||||
private $_zone_entity = null;
|
private $_zone_entity = null;
|
||||||
public function initController(RequestInterface $request, ResponseInterface $response, LoggerInterface $logger)
|
public function initController(RequestInterface $request, ResponseInterface $response, LoggerInterface $logger)
|
||||||
{
|
{
|
||||||
@ -32,10 +31,7 @@ class RecordController extends CloudflareController
|
|||||||
}
|
}
|
||||||
final protected function getMyLibrary(): Record
|
final protected function getMyLibrary(): Record
|
||||||
{
|
{
|
||||||
if ($this->_myLibrary === null) {
|
return new Record($this->_zone_entity);
|
||||||
$this->_myLibrary = new Record($this->_zone_entity);
|
|
||||||
}
|
|
||||||
return $this->_myLibrary;
|
|
||||||
}
|
}
|
||||||
protected function getFormFieldOption(string $field, array $options = []): array
|
protected function getFormFieldOption(string $field, array $options = []): array
|
||||||
{
|
{
|
||||||
|
|||||||
@ -2,7 +2,6 @@
|
|||||||
|
|
||||||
namespace App\Controllers\Admin\Cloudflare;
|
namespace App\Controllers\Admin\Cloudflare;
|
||||||
|
|
||||||
use App\Entities\Cloudflare\RecordEntity;
|
|
||||||
use App\Helpers\Cloudflare\ZoneHelper;
|
use App\Helpers\Cloudflare\ZoneHelper;
|
||||||
use App\Libraries\Cloudflare\Record;
|
use App\Libraries\Cloudflare\Record;
|
||||||
use App\Libraries\Cloudflare\Zone;
|
use App\Libraries\Cloudflare\Zone;
|
||||||
@ -15,7 +14,6 @@ use Psr\Log\LoggerInterface;
|
|||||||
|
|
||||||
class ZoneController extends CloudflareController
|
class ZoneController extends CloudflareController
|
||||||
{
|
{
|
||||||
private $_myLibrary = null;
|
|
||||||
private $_account_entity = null;
|
private $_account_entity = null;
|
||||||
private $_model = null;
|
private $_model = null;
|
||||||
public function initController(RequestInterface $request, ResponseInterface $response, LoggerInterface $logger)
|
public function initController(RequestInterface $request, ResponseInterface $response, LoggerInterface $logger)
|
||||||
@ -35,10 +33,7 @@ class ZoneController extends CloudflareController
|
|||||||
}
|
}
|
||||||
final protected function getMyLibrary(): Zone
|
final protected function getMyLibrary(): Zone
|
||||||
{
|
{
|
||||||
if ($this->_myLibrary === null) {
|
return new Zone($this->_account_entity);
|
||||||
$this->_myLibrary = new Zone($this->_account_entity);
|
|
||||||
}
|
|
||||||
return $this->_myLibrary;
|
|
||||||
}
|
}
|
||||||
protected function getFormFieldOption(string $field, array $options = []): array
|
protected function getFormFieldOption(string $field, array $options = []): array
|
||||||
{
|
{
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user