Commit 64eeb1b7 authored by Gábor Hojtsy's avatar Gábor Hojtsy
Browse files

Issue #3258839 by hmendes, Gábor Hojtsy, Kristen Pol: Include extension type in TYPE column

parent 4e0ecd02
Loading
Loading
Loading
Loading
+24 −1
Changes for src/Form/UpgradeStatusForm.php: 24 added lines, 1 removed line.
Original line number Diff line number Diff line
@@ -356,11 +356,34 @@ class UpgradeStatusForm extends FormBase {
        ],
        'class' => 'project-label',
      ];
      $type = '';
      if ($extension->info['upgrade_status_type'] == ProjectCollector::TYPE_CUSTOM) {
        if ($extension->getType() == 'module') {
          $type = $this->t('Custom module');
        }
        elseif ($extension->getType() == 'theme') {
          $type = $this->t('Custom theme');
        }
        elseif ($extension->getType() == 'profile') {
          $type = $this->t('Custom profile');
        }
      }
      else {
        if ($extension->getType() == 'module') {
          $type = $this->t('Contributed module');
        }
        elseif ($extension->getType() == 'theme') {
          $type = $this->t('Contributed theme');
        }
        elseif ($extension->getType() == 'profile') {
          $type = $this->t('Contributed profile');
        }
      }
      $option['type'] = [
        'data' => [
          'label' => [
            '#type' => 'markup',
            '#markup' => $extension->info['upgrade_status_type'] == ProjectCollector::TYPE_CUSTOM ? $this->t('Custom') : $this->t('Contributed'),
            '#markup' => $type,
          ],
        ]
      ];