application/Espo/Core/Upgrades/Actions/Extension/Install.php
protected function storeExtension()
    {
        $entityManager = $this->getEntityManager();

        $extensionEntity = $entityManager->getEntity('Extension', $this->getProcessId());
        if (!isset($extensionEntity)) {
            $extensionEntity = $entityManager->getEntity('Extension');
        }

        $manifest = $this->getManifest();
        $fileList = $this->getCopyFileList();

        $data = array(
            'id' => $this->getProcessId(),
            'name' => trim($manifest['name']),
            'isInstalled' => true,
            'version' => $manifest['version'],
            'fileList' => $fileList,
            'description' => $manifest['description'],
        );

        if (!empty($manifest['checkVersionUrl'])) {
            $data['checkVersionUrl'] = $manifest['checkVersionUrl'];
        }

        $extensionEntity->set($data);

        return $entityManager->saveEntity($extensionEntity);
    }
protected function storeExtension()
    {
        $entityManager = $this->getEntityManager();

        $extensionEntity = $entityManager->getEntity('Extension', $this->getProcessId());
        if (!isset($extensionEntity)) {
            $extensionEntity = $entityManager->getEntity('Extension');
        }

        $manifest = $this->getManifest();
        $fileList = $this->getCopyFileList();

        $data = array(
            'id' => $this->getProcessId(),
            'name' => trim($manifest['name']),
            'isInstalled' => true,
            'version' => $manifest['version'],
            'fileList' => $fileList,
            'description' => $manifest['description'],
        );

        if (!empty($manifest['checkVersionUrl'])) {
            $data['checkVersionUrl'] = $manifest['checkVersionUrl'];
        }

        $extensionEntity->set($data);

        return $entityManager->saveEntity($extensionEntity);
    }
protected function storeExtension ( ) { $ entityManager = $ this -> getEntityManager ( ) ; $ extensionEntity = $ entityManager -> getEntity ( 'Extension' , $ this -> getProcessId ( ) ) ; if ( ! isset ( $ extensionEntity ) ) { $ extensionEntity = $ entityManager -> getEntity ( 'Extension' ) ; } $ manifest = $ this -> getManifest ( ) ; $ fileList = $ this -> getCopyFileList ( ) ; $ data = array ( 'id' => $ this -> getProcessId ( ) , 'name' => trim ( $ manifest [ 'name' ] ) , 'isInstalled' => true , 'version' => $ manifest [ 'version' ] , 'fileList' => $ fileList , 'description' => $ manifest [ 'description' ] , ) ; if ( ! empty ( $ manifest [ 'checkVersionUrl' ] ) ) { $ data [ 'checkVersionUrl' ] = $ manifest [ 'checkVersionUrl' ] ; } $ extensionEntity -> set ( $ data ) ; return $ entityManager -> saveEntity ( $ extensionEntity ) ; }
Create a record of Extension Entity

@return bool
Create a record of Extension Entity