mirror of
https://github.com/flarum/framework.git
synced 2024-11-30 05:13:37 +08:00
Fixes #825
This commit is contained in:
parent
08aaba6426
commit
05c9ce335e
|
@ -19,6 +19,7 @@ class DefaultsDataProvider implements DataProviderInterface
|
||||||
'username' => 'root',
|
'username' => 'root',
|
||||||
'password' => 'root',
|
'password' => 'root',
|
||||||
'prefix' => '',
|
'prefix' => '',
|
||||||
|
'port' => '3306',
|
||||||
];
|
];
|
||||||
|
|
||||||
protected $baseUrl = 'http://flarum.dev';
|
protected $baseUrl = 'http://flarum.dev';
|
||||||
|
|
|
@ -133,7 +133,8 @@ class InstallCommand extends AbstractCommand
|
||||||
'host' => 'required',
|
'host' => 'required',
|
||||||
'database' => 'required|string',
|
'database' => 'required|string',
|
||||||
'username' => 'required|string',
|
'username' => 'required|string',
|
||||||
'prefix' => 'alpha_dash|max:10'
|
'prefix' => 'alpha_dash|max:10',
|
||||||
|
'port' => 'required|integer|min:1|max:65535',
|
||||||
]
|
]
|
||||||
);
|
);
|
||||||
|
|
||||||
|
@ -203,6 +204,7 @@ class InstallCommand extends AbstractCommand
|
||||||
'charset' => 'utf8mb4',
|
'charset' => 'utf8mb4',
|
||||||
'collation' => 'utf8mb4_unicode_ci',
|
'collation' => 'utf8mb4_unicode_ci',
|
||||||
'prefix' => $dbConfig['prefix'],
|
'prefix' => $dbConfig['prefix'],
|
||||||
|
'port' => $dbConfig['port'],
|
||||||
'strict' => false
|
'strict' => false
|
||||||
],
|
],
|
||||||
'url' => $this->baseUrl,
|
'url' => $this->baseUrl,
|
||||||
|
|
|
@ -58,6 +58,7 @@ class InstallController implements ControllerInterface
|
||||||
'username' => array_get($input, 'mysqlUsername'),
|
'username' => array_get($input, 'mysqlUsername'),
|
||||||
'password' => array_get($input, 'mysqlPassword'),
|
'password' => array_get($input, 'mysqlPassword'),
|
||||||
'prefix' => array_get($input, 'tablePrefix'),
|
'prefix' => array_get($input, 'tablePrefix'),
|
||||||
|
'port' => array_get($input, 'mysqlPort'),
|
||||||
]);
|
]);
|
||||||
|
|
||||||
$data->setAdminUser([
|
$data->setAdminUser([
|
||||||
|
|
|
@ -33,6 +33,11 @@
|
||||||
<input type="password" name="mysqlPassword">
|
<input type="password" name="mysqlPassword">
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="FormField">
|
||||||
|
<label>MySQL Port</label>
|
||||||
|
<input type="number" name="mysqlPort">
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="FormField">
|
<div class="FormField">
|
||||||
<label>Table Prefix</label>
|
<label>Table Prefix</label>
|
||||||
<input type="text" name="tablePrefix">
|
<input type="text" name="tablePrefix">
|
||||||
|
|
Loading…
Reference in New Issue
Block a user