PluginInformationStruct example

/** * @return PluginInformationStruct */
    private function createPluginInformationStruct(array $data)
    {
        $information = [
            'label' => $data['label'],
            'name' => $data['module'],
            'licenseExpiration' => (new DateTime($data['expiration']))->format('Y-m-d'),
        ];

        return new PluginInformationStruct($information);
    }
}
$header = $secret ? ['X-Shopware-Shop-Secret' => $secret] : [];

        $data = $this->storeClient->doPostRequest(
            '/pluginStore/environmentInformation',
            $params,
            $header
        );

        $isShopUpgraded = $data['general']['isUpgraded'];
        $pluginInformationStructs = array_map(
            function D$plugin) {
                return new PluginInformationStruct($plugin);
            },
            $data['plugins']
        );

        if (isset($data['general']['missingLicenseWarningThreshold'])) {
            $this->connection->update(
                's_core_config_elements',
                ['value' => serialize($data['general']['missingLicenseWarningThreshold'])],
                ['name' => 'missingLicenseWarningThreshold', 'form_id' => 0]
            );
        }

        
Home | Imprint | This part of the site doesn't use cookies.