Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inject Joomla database in imports #47

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -8,118 +8,104 @@
class="form-select"
default="fs"
validate="options"
>
>
<option value="fs">COM_MIGRATETOJOOMLA_FS</option>
<!-- <option value="http">COM_MIGRATETOJOOMLA_HTTP</option>
<option value="ftp">COM_MIGRATETOJOOMLA_FTP</option> -->
</field>
<field
name="livewebsiteurl"
type="text"
label="COM_MIGRATETOJOOMLA_HTTP_LINK_LABEL"
description="COM_MIGRATETOJOOMLA_HTTP_LINK_DESC"
showon="mediaoptions:http"
/>
label="COM_MIGRATETOJOOMLA_HTTP_LINK_LABEL"
description="COM_MIGRATETOJOOMLA_HTTP_LINK_DESC"/>
<field
name="basedir"
type="text"
label="COM_MIGRATETOJOOMLA_WEBSITE_BASE_DIRECTORY_LABEL"
description="COM_MIGRATETOJOOMLA_WEBSITE_BASE_DIRECTORY_DESC"
showon="mediaoptions:fs"
/>
label="COM_MIGRATETOJOOMLA_WEBSITE_BASE_DIRECTORY_LABEL"
description="COM_MIGRATETOJOOMLA_WEBSITE_BASE_DIRECTORY_DESC"/>
<field
name="ftphost"
type="text"
label="COM_MIGRATETOJOOMLA_FTP_HOST_LABEL"
description="COM_MIGRATETOJOOMLA_FTP_HOST_DESC"
showon="mediaoptions:ftp"
/>
label="COM_MIGRATETOJOOMLA_FTP_HOST_LABEL"
description="COM_MIGRATETOJOOMLA_FTP_HOST_DESC"/>
<field
name="ftpport"
type="int"
label="COM_MIGRATETOJOOMLA_FTP_PORT_LABEL"
description="COM_MIGRATETOJOOMLA_FTP_PORT_DESC"
showon="mediaoptions:ftp"
default="21"
/>
label="COM_MIGRATETOJOOMLA_FTP_PORT_LABEL"
description="COM_MIGRATETOJOOMLA_FTP_PORT_DESC"/>
<field
name="ftpusername"
type="text"
label="COM_MIGRATETOJOOMLA_FTP_USERNAME_LABEL"
description="COM_MIGRATETOJOOMLA_FTP_USERNAME_DESC"
showon="mediaoptions:ftp"
/>
label="COM_MIGRATETOJOOMLA_FTP_USERNAME_LABEL"
description="COM_MIGRATETOJOOMLA_FTP_USERNAME_DESC"/>
<field
name="ftppassword"
type="password"
label="COM_MIGRATETOJOOMLA_FTP_PASSWORD_LABEL"
description="COM_MIGRATETOJOOMLA_FTP_PASSWORD_DESC"
showon="mediaoptions:ftp"
/>
label="COM_MIGRATETOJOOMLA_FTP_PASSWORD_LABEL"
description="COM_MIGRATETOJOOMLA_FTP_PASSWORD_DESC"/>
<field
name="ftpprotocoloptions"
type="list"
label="COM_MIGRATETOJOOMLA_FTP_PROTOCOL_LABEL"
description="COM_MIGRATETOJOOMLA_FTP_PROTOCOL_DESC"
class="form-select"
default="ftp"
showon="mediaoptions:ftp"
showon="mediaoption:ftp"
validate="options"
>
description="COM_MIGRATETOJOOMLA_FTP_PROTOCOL_DESC"
>
<option value="ftp">COM_MIGRATETOJOOMLA_FTP</option>
<option value="ftps">COM_MIGRATETOJOOMLA_FTPS</option>
<option value="sftp">COM_MIGRATETOJOOMLA_SFTP</option>
</field>
<field
name="ftpbasedir"
type="text"
label="COM_MIGRATETOJOOMLA_FTP_BASE_DIR_LABEL"
description="COM_MIGRATETOJOOMLA_FTP_BASE_DIR_DESC"
showon="mediaoptions:ftp"
/>
label="COM_MIGRATETOJOOMLA_FTP_BASE_DIR_LABEL"
description="COM_MIGRATETOJOOMLA_FTP_BASE_DIR_DESC"/>
<field
name="dbhostname"
type="text"
label="COM_MIGRATETOJOOMLA_DATABASE_HOSTNAME_LABEL"
description="COM_MIGRATETOJOOMLA_DATABASE_HOSTNAME_DESC"
/>
description="COM_MIGRATETOJOOMLA_DATABASE_HOSTNAME_DESC"/>
<field
name="dbdriver"
type="text"
label="COM_MIGRATETOJOOMLA_DATABASE_DRIVER_LABEL"
description="COM_MIGRATETOJOOMLA_DATABASE_DRIVER_DESC"
default="mysqli"
/>
label="COM_MIGRATETOJOOMLA_DATABASE_DRIVER_LABEL"
description="COM_MIGRATETOJOOMLA_DATABASE_DRIVER_DESC"/>
<field
name="dbport"
type="int"
label="COM_MIGRATETOJOOMLA_DATABASE_PORT_LABEL"
description="COM_MIGRATETOJOOMLA_DATABASE_PORT_DESC"
default='3306'
/>
label="COM_MIGRATETOJOOMLA_DATABASE_PORT_LABEL"
description="COM_MIGRATETOJOOMLA_DATABASE_PORT_DESC"/>
<field
name="dbname"
type="text"
label="COM_MIGRATETOJOOMLA_DATABASE_NAME_LABEL"
description="COM_MIGRATETOJOOMLA_DATABASE_NAME_DESC"
/>
description="COM_MIGRATETOJOOMLA_DATABASE_NAME_DESC"/>
<field
name="dbusername"
type="text"
label="COM_MIGRATETOJOOMLA_DATABASE_USERNAME_LABEL"
description="COM_MIGRATETOJOOMLA_DATABASE_USERNAME_DESC"
/>
description="COM_MIGRATETOJOOMLA_DATABASE_USERNAME_DESC"/>
<field
name="dbpassword"
type="text"
label="COM_MIGRATETOJOOMLA_DATABASE_PASSWORD_LABEL"
description="COM_MIGRATETOJOOMLA_DATABASE_PASSWORD_DESC"
default=""
/>
label="COM_MIGRATETOJOOMLA_DATABASE_PASSWORD_LABEL"
description="COM_MIGRATETOJOOMLA_DATABASE_PASSWORD_DESC"/>
<field
name="dbtableprefix"
type="text"
label="COM_MIGRATETOJOOMLA_DATABASE_TABLE_PREFIX_LABEL"
description="COM_MIGRATETOJOOMLA_DATABASE_TABLE_PREFIX_DESC"
/>
description="COM_MIGRATETOJOOMLA_DATABASE_TABLE_PREFIX_DESC"/>
</form>
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
class="form-select"
validate="options"
require="true"
>
>
<option value="wordpress">COM_MIGRATETOJOOMLA_WORDPRESS</option>
</field>
</form>
Original file line number Diff line number Diff line change
@@ -1,25 +1,22 @@
<?xml version="1.0" encoding="utf-8"?>
<form>
<field
name="mediamigratestatus"
type="radio"
label="COM_MIGRATETOJOOMLA_MEDIA_MIGRATE_STATUS_LABEL"
description="COM_MIGRATETOJOOMLA_MEDIA_MIGRATE_STATUS_DESC"
default="1"
layout="joomla.form.field.radio.switcher"
validate="options"
>
<field name="mediamigratestatus"
type="radio"
label="COM_MIGRATETOJOOMLA_MEDIA_MIGRATE_STATUS_LABEL"
description="COM_MIGRATETOJOOMLA_MEDIA_MIGRATE_STATUS_DESC"
default="1"
layout="joomla.form.field.radio.switcher"
validate="options">
<option value="0">JNO</option>
<option value="1">JYES</option>
</field>
<field name="databasemigratestatus"
type="radio"
label="COM_MIGRATETOJOOMLA_DATABASE_MIGRATE_STATUS_LABEL"
description="COM_MIGRATETOJOOMLA_DATABASE_MIGRATE_STATUS_DESC"
default="1"
layout="joomla.form.field.radio.switcher"
validate="options"
>
type="radio"
label="COM_MIGRATETOJOOMLA_DATABASE_MIGRATE_STATUS_LABEL"
description="COM_MIGRATETOJOOMLA_DATABASE_MIGRATE_STATUS_DESC"
default="1"
layout="joomla.form.field.radio.switcher"
validate="options">
<option value="0">JNO</option>
<option value="1">JYES</option>
</field>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,16 @@
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/

\defined('_JEXEC') or die;
defined('_JEXEC') or die;

use Joomla\Component\MigrateToJoomla\Administrator\Extension\MigrateToJoomlaComponent;
use Joomla\CMS\Component\Router\RouterFactoryInterface;
use Joomla\CMS\Dispatcher\ComponentDispatcherFactoryInterface;
use Joomla\CMS\Extension\ComponentInterface;
use Joomla\CMS\Extension\Service\Provider\ComponentDispatcherFactory;
use Joomla\CMS\Extension\Service\Provider\MVCFactory;
use Joomla\CMS\Extension\Service\Provider\RouterFactory;
use Joomla\CMS\MVC\Factory\MVCFactoryInterface;
use Joomla\Component\MigrateToJoomla\Administrator\Extension\MigrateToJoomlaComponent;
use Joomla\DI\Container;
use Joomla\DI\ServiceProviderInterface;

Expand All @@ -27,7 +27,8 @@
* @since 1.0
*/

return new class () implements ServiceProviderInterface {
return new class implements ServiceProviderInterface {

/**
* Registers the service provider with a DI container.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,6 @@
*
* @since 1.0
*/
class CheckController
class CheckController
{
}
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
*
* @package Joomla.Administrator
* @subpackage com_migratetojoomla
*
*
* @since 1.0
*/
class DisplayController extends BaseController
Expand Down
Loading