cfmgrv4 init...1
This commit is contained in:
parent
95b8a0a4e6
commit
c958bf7fe6
@ -63,7 +63,7 @@ class ZoneController extends CloudflareController
|
||||
}
|
||||
break;
|
||||
case 'hosts':
|
||||
$formDatas[$field] = $this->request->getVar($field);
|
||||
$formDatas[$field] = explode("\n", $this->request->getVar($field));
|
||||
if (!is_array($formDatas[$field]) || !count($formDatas[$field])) {
|
||||
throw new \Exception("호스트명이 정의되지 않았습니다");
|
||||
}
|
||||
|
||||
@ -19,7 +19,7 @@ class Account extends MyCloudflare
|
||||
{
|
||||
return $this->getMySocket()->request($this->_authkey);
|
||||
}
|
||||
final public function getMyStorage(): AccountModel
|
||||
final protected function getMyStorage(): AccountModel
|
||||
{
|
||||
if ($this->_myStorage === null) {
|
||||
$this->_myStorage = new AccountModel();
|
||||
|
||||
@ -15,7 +15,7 @@ abstract class MyCloudflare extends CommonLibrary
|
||||
}
|
||||
abstract protected function getArrayByResult($result, array $formDatas = []): array;
|
||||
abstract protected function reload_entity($cf): mixed;
|
||||
abstract public function getMyStorage(): mixed;
|
||||
abstract protected function getMyStorage(): mixed;
|
||||
final protected function getMySocket(): CloudflareSocket
|
||||
{
|
||||
if ($this->_mySocket === null) {
|
||||
|
||||
@ -24,7 +24,7 @@ class Record extends MyCloudflare
|
||||
{
|
||||
return $this->getMySocket()->request($this->_account_entity->getAuthKey());
|
||||
}
|
||||
final public function getMyStorage(): RecordModel
|
||||
final protected function getMyStorage(): RecordModel
|
||||
{
|
||||
if ($this->_myStorage === null) {
|
||||
$this->_myStorage = new RecordModel();
|
||||
|
||||
@ -22,7 +22,7 @@ class Zone extends MyCloudflare
|
||||
{
|
||||
return $this->getMySocket()->request($this->_account_entity->getAuthKey());
|
||||
}
|
||||
final public function getMyStorage(): ZoneModel
|
||||
final protected function getMyStorage(): ZoneModel
|
||||
{
|
||||
if ($this->_myStorage === null) {
|
||||
$this->_myStorage = new ZoneModel();
|
||||
|
||||
@ -35,7 +35,7 @@ class UserModel extends CommonModel
|
||||
{
|
||||
switch ($field) {
|
||||
case "id":
|
||||
if ($this->getAction() == DB_ACTION["CREATE"]) {
|
||||
if ($this->getAction() == 'create') {
|
||||
$rules[$field] = "required|trim|min_length[4]|max_length[20]|is_unique[{$this->table}.{$field}]";
|
||||
} else {
|
||||
$rules[$field] = "required|trim|min_length[4]|max_length[20]";
|
||||
|
||||
Loading…
Reference in New Issue
Block a user