Skip to content
Snippets Groups Projects

Issue #3264849: Show next minor or current minor updates in Update form

2 files
+ 15
5
Compare changes
  • Side-by-side
  • Inline
Files
2
+ 13
3
@@ -191,11 +191,19 @@ class UpdaterForm extends FormBase {
@@ -191,11 +191,19 @@ class UpdaterForm extends FormBase {
throw new \UnexpectedValueException('Expected project data to have a title and link.');
throw new \UnexpectedValueException('Expected project data to have a title and link.');
}
}
 
$form['title'] = [
 
'#type' => 'html_tag',
 
'#tag' => 'h2',
 
'#value' => $this->t(
 
'Update <a href=":url">Drupal core</a>',
 
[':url' => $project['link']],
 
),
 
];
$form['current'] = [
$form['current'] = [
'#type' => 'html_tag',
'#type' => 'html_tag',
'#tag' => 'h3',
'#tag' => 'p',
'#value' => $this->t(
'#value' => $this->t(
'Currently installed version: @version : @status',
'Currently installed version @version: @status',
[
[
'@version' => $project_info->getInstalledVersion(),
'@version' => $project_info->getInstalledVersion(),
'@status' => $this->getUpdateStatus($project['status']),
'@status' => $this->getUpdateStatus($project['status']),
@@ -288,7 +296,7 @@ class UpdaterForm extends FormBase {
@@ -288,7 +296,7 @@ class UpdaterForm extends FormBase {
->setInitMessage($this->t('Preparing to download updates'))
->setInitMessage($this->t('Preparing to download updates'))
->addOperation(
->addOperation(
[BatchProcessor::class, 'begin'],
[BatchProcessor::class, 'begin'],
[$button['#target_version']]
[['drupal' => $button['#target_version']]]
)
)
->addOperation([BatchProcessor::class, 'stage'])
->addOperation([BatchProcessor::class, 'stage'])
->setFinishCallback([BatchProcessor::class, 'finishStage'])
->setFinishCallback([BatchProcessor::class, 'finishStage'])
@@ -322,6 +330,8 @@ class UpdaterForm extends FormBase {
@@ -322,6 +330,8 @@ class UpdaterForm extends FormBase {
* The release description.
* The release description.
* @param \Drupal\Core\StringTranslation\TranslatableMarkup|null $caption
* @param \Drupal\Core\StringTranslation\TranslatableMarkup|null $caption
* The table caption, if any.
* The table caption, if any.
 
* @param string $update_type
 
* The update type.
* @param bool $enable_updates
* @param bool $enable_updates
* Whether updates are enabled.
* Whether updates are enabled.
*
*
Loading