From: Tim Düsterhus Date: Mon, 5 Jul 2021 14:09:47 +0000 (+0200) Subject: Remove support for the API compatibility tags from dev tools X-Git-Tag: 5.5.0_Alpha_1~551^2 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=e0a019d50d09da375adb725e5f3c23a0891c02de;p=GitHub%2FWoltLab%2FWCF.git Remove support for the API compatibility tags from dev tools --- diff --git a/wcfsetup/install/files/lib/acp/form/DevtoolsProjectAddForm.class.php b/wcfsetup/install/files/lib/acp/form/DevtoolsProjectAddForm.class.php index 947261e82d..b9466f2cfb 100644 --- a/wcfsetup/install/files/lib/acp/form/DevtoolsProjectAddForm.class.php +++ b/wcfsetup/install/files/lib/acp/form/DevtoolsProjectAddForm.class.php @@ -23,7 +23,6 @@ use wcf\system\form\builder\field\devtools\project\DevtoolsProjectExcludedPackag use wcf\system\form\builder\field\devtools\project\DevtoolsProjectInstructionsFormField; use wcf\system\form\builder\field\devtools\project\DevtoolsProjectOptionalPackagesFormField; use wcf\system\form\builder\field\devtools\project\DevtoolsProjectRequiredPackagesFormField; -use wcf\system\form\builder\field\MultipleSelectionFormField; use wcf\system\form\builder\field\RadioButtonFormField; use wcf\system\form\builder\field\TextFormField; use wcf\system\form\builder\field\UrlFormField; @@ -330,33 +329,6 @@ class DevtoolsProjectAddForm extends AbstractFormBuilderForm ); $dataTab->appendChild($authorInformation); - $compatibility = FormContainer::create('compatibility') - ->label('wcf.acp.devtools.project.compatibility') - ->appendChildren([ - MultipleSelectionFormField::create('apiVersions') - ->label('wcf.acp.devtools.project.apiVersions') - ->description('wcf.acp.devtools.project.apiVersions.description') - ->options(static function () { - $apiVersions = \array_filter(\array_merge( - WCF::getSupportedLegacyApiVersions(), - [WSC_API_VERSION] - ), static function ($value) { - return $value !== 2017; - }); - - \sort($apiVersions); - - return \array_combine($apiVersions, $apiVersions); - }) - ->available($this->formObject === null || !$this->formObject->isCore()), - ]) - ->addDependency( - ValueFormFieldDependency::create('mode') - ->field($mode) - ->values(['edit', 'setup']) - ); - $dataTab->appendChild($compatibility); - $requiredPackages = FormContainer::create('requiredPackagesContainer') ->label('wcf.acp.devtools.project.requiredPackages') ->description('wcf.acp.devtools.project.requiredPackages.description') diff --git a/wcfsetup/install/files/lib/acp/form/DevtoolsProjectEditForm.class.php b/wcfsetup/install/files/lib/acp/form/DevtoolsProjectEditForm.class.php index a759cb4d24..0d9e1aac0e 100644 --- a/wcfsetup/install/files/lib/acp/form/DevtoolsProjectEditForm.class.php +++ b/wcfsetup/install/files/lib/acp/form/DevtoolsProjectEditForm.class.php @@ -12,7 +12,6 @@ use wcf\system\form\builder\field\devtools\project\DevtoolsProjectExcludedPackag use wcf\system\form\builder\field\devtools\project\DevtoolsProjectInstructionsFormField; use wcf\system\form\builder\field\devtools\project\DevtoolsProjectOptionalPackagesFormField; use wcf\system\form\builder\field\devtools\project\DevtoolsProjectRequiredPackagesFormField; -use wcf\system\form\builder\field\MultipleSelectionFormField; use wcf\system\form\builder\field\TextFormField; use wcf\system\language\LanguageFactory; use wcf\system\WCF; @@ -251,10 +250,6 @@ class DevtoolsProjectEditForm extends DevtoolsProjectAddForm $authorUrl->value($packageArchive->getAuthorInfo('authorURL')); } - /** @var MultipleSelectionFormField $apiVersions */ - $apiVersions = $this->form->getNodeById('apiVersions'); - $apiVersions->value($packageArchive->getCompatibleVersions()); - $requirements = $packageArchive->getRequirements(); if (!empty($requirements)) { $requirementData = []; diff --git a/wcfsetup/install/files/lib/system/devtools/package/DevtoolsPackageXmlWriter.class.php b/wcfsetup/install/files/lib/system/devtools/package/DevtoolsPackageXmlWriter.class.php index 7ca02fba80..4743a3273f 100644 --- a/wcfsetup/install/files/lib/system/devtools/package/DevtoolsPackageXmlWriter.class.php +++ b/wcfsetup/install/files/lib/system/devtools/package/DevtoolsPackageXmlWriter.class.php @@ -79,7 +79,6 @@ class DevtoolsPackageXmlWriter $this->writeRequiredPackages(); $this->writeOptionalPackages(); $this->writeExcludedPackages(); - $this->writeCompatibility(); $this->writeInstructions(); $this->xmlWriter->endDocument($this->project->getPackageXmlPath()); @@ -110,24 +109,6 @@ class DevtoolsPackageXmlWriter $this->xmlWriter->endElement(); } - /** - * Writes the `compatibility` element. - */ - protected function writeCompatibility() - { - if (empty($this->packageXmlData['apiVersions'])) { - return; - } - - $this->xmlWriter->startElement('compatibility'); - - foreach ($this->packageXmlData['apiVersions'] as $apiVersion) { - $this->xmlWriter->writeElement('api', '', ['version' => $apiVersion]); - } - - $this->xmlWriter->endElement(); - } - /** * Writes the `optionalpackages` element. */ diff --git a/wcfsetup/install/lang/de.xml b/wcfsetup/install/lang/de.xml index dd50f8c730..008c4ef106 100644 --- a/wcfsetup/install/lang/de.xml +++ b/wcfsetup/install/lang/de.xml @@ -513,7 +513,6 @@ oder neueren Version) bereits installiert ist.]]> - {$packageIdentifier} {if $version}
@@ -528,8 +527,6 @@ optionals/{literal}{$packageIdentifier}{/literal}.tar lauten.]]> - - @@ -5555,5 +5552,8 @@ Benachrichtigungen auf {PAGE_TITLE|lang + + + diff --git a/wcfsetup/install/lang/en.xml b/wcfsetup/install/lang/en.xml index 3a739d372f..aedfc01b92 100644 --- a/wcfsetup/install/lang/en.xml +++ b/wcfsetup/install/lang/en.xml @@ -490,7 +490,6 @@ or new version).]]> - {$packageIdentifier} {if $version}
@@ -505,8 +504,6 @@ optionals/{literal}{$packageIdentifier}{/literal}.tar.]]> - - @@ -5556,5 +5553,8 @@ your notifications on {PAGE_TITLE|langu + + +