-
-
Notifications
You must be signed in to change notification settings - Fork 256
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: rewrite of the update script using Twig (#2492)
- Loading branch information
Showing
13 changed files
with
357 additions
and
207 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,11 @@ | ||
import { handleUpdateNextStepButton } from './configuration'; | ||
import { | ||
handleConfigBackup, | ||
handleDatabaseUpdate, | ||
handleUpdateInformation, | ||
handleUpdateNextStepButton, | ||
} from './configuration'; | ||
|
||
handleUpdateNextStepButton(); | ||
handleUpdateInformation(); | ||
handleConfigBackup(); | ||
handleDatabaseUpdate(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
<form action="#" method="post" name="phpmyfaq-update-form" id="phpmyfaq-update-form"> | ||
<input name="installed-version" id="phpmyfaq-update-installed-version" type="hidden" value="{{ installedVersion }}"> | ||
<input name="next-step" id="phpmyfaq-update-next-step" type="hidden" value="3"> | ||
|
||
<div class="row"> | ||
<div class="col mt-5"> | ||
|
||
<div class="alert alert-success"> | ||
<h4 class="alert-heading">Backup</h4> | ||
<p> | ||
Before we start the database update process, we created a backup of your current phpMyFAQ configuration files. | ||
This is a safety measure in case something goes wrong during the update process. | ||
</p> | ||
<p> | ||
<strong>Important:</strong> Please make sure that you have a copy of your | ||
<a href="" id="phpmyfaq-update-backup-download-link">configuration.</a> | ||
</p> | ||
</div> | ||
|
||
</div> | ||
</div> | ||
|
||
<div class="row"> | ||
<div class="col d-flex justify-content-end"> | ||
<button class="btn btn-primary btn-next btn-lg {{ nextStepButtonEnabled }}" type="button" | ||
id="phpmyfaq-update-next-step-button" {{ nextStepButtonEnabled }}> | ||
Next update step | ||
</button> | ||
</div> | ||
</div> | ||
</form> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
<form action="#" method="post" name="phpmyfaq-update-form" id="phpmyfaq-update-form"> | ||
<input name="installed-version" id="phpmyfaq-update-installed-version" type="hidden" value="{{ installedVersion }}"> | ||
|
||
<div class="row"> | ||
<div class="col mt-5"> | ||
|
||
<div class="alert alert-success d-none" id="phpmyfaq-update-database-success"> | ||
<h4 class="alert-heading">Hooray!</h4> | ||
The database was updated successfully. Thank you very much for updating. | ||
</div> | ||
|
||
<div class="alert alert-danger d-none" id="phpmyfaq-update-database-error"> | ||
<h4 class="alert-heading">Oh no!</h4> | ||
<p> | ||
The database could not be updated. Please check the following error message(s): | ||
</p> | ||
<ul class="list-unstyled" id="error-messages"></ul> | ||
</div> | ||
|
||
</div> | ||
</div> | ||
|
||
<div class="row"> | ||
<div class="col d-flex justify-content-end"> | ||
<a href="../index.php" class="btn btn-primary btn-next btn-lg" type="button"> | ||
Return to your updated phpMyFAQ installation | ||
</a> | ||
</div> | ||
</div> | ||
</form> |
Oops, something went wrong.