/** * Get code for install * @return string */ private function getCodeForInstall() { $Factory = new PluginFactory(); $Plugins = $Factory->notInstalledPlugins(); if (empty($Plugins)) { return HTML::fileBlock(__('There are no new plugins to install.')); } $Code = ' <table class="fullwidth zebra-style more-padding"> <thead> <tr class="b"> <th colspan="3">' . __('Plugin') . '</th> <th colspan="2">' . __('Type') . '</th> </tr> </thead> <tbody>'; foreach ($Plugins as $Data) { $Plugin = $Factory->newInstallerInstance($Data['key']); $Code .= ' <tr> <td>' . Icon::$ADD . '</td> <td class="b">' . PluginInstaller::link($Plugin->key(), $Plugin->name()) . '</td> <td>' . $Plugin->description() . '</td> <td colspan="2">' . PluginType::readableString($Plugin->type()) . '</td> </tr>'; } $Code .= ' </tbody> </table>'; return $Code; }