session = $this->session_AuthTrait(); $this->class_name = 'Account'; helper($this->class_name); } final protected function getMySocket(): CloudflareSocket { if ($this->_mySocket === null) { $this->_mySocket = new CloudflareSocket(); } return $this->_mySocket; } final protected function getModel(): AccountModel { if ($this->_model === null) { $this->_model = new AccountModel(); } return $this->_model; } protected function create_init(): void { $this->fields = ['id', 'apikey']; $this->filter_fields = ['status']; $this->action = DB_ACTION["CREATE"]; $this->getModel()->setAction($this->action); } public function create_form(): RedirectResponse|string { return $this->create_form_process(); } protected function create_process_submit(): AccountEntity { $account = new Account($this->getMySocket(), $this->getModel()); return $account->create($this->formDatas); } public function create(): RedirectResponse { return parent::create_process(); } }