From 51153689fdae1401afd2e70b3064654b852bad25 Mon Sep 17 00:00:00 2001 From: maxo Date: Fri, 29 Jan 2021 18:17:30 +0200 Subject: [PATCH 1/7] remove samples link product downloadable --- .../Model/Sample/UpdateHandler.php | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/app/code/Magento/Downloadable/Model/Sample/UpdateHandler.php b/app/code/Magento/Downloadable/Model/Sample/UpdateHandler.php index cb7ff725a21d3..0e3b31bad39a8 100644 --- a/app/code/Magento/Downloadable/Model/Sample/UpdateHandler.php +++ b/app/code/Magento/Downloadable/Model/Sample/UpdateHandler.php @@ -43,10 +43,8 @@ public function __construct(SampleRepository $sampleRepository) */ public function execute($entity, $arguments = []): ProductInterface { - $samples = $entity->getExtensionAttributes()->getDownloadableProductSamples(); - - if ($samples && $entity->getTypeId() === Type::TYPE_DOWNLOADABLE) { - $this->updateSamples($entity, $samples); + if ($entity->getTypeId() === Type::TYPE_DOWNLOADABLE) { + $this->updateSamples($entity); } return $entity; @@ -62,14 +60,17 @@ public function execute($entity, $arguments = []): ProductInterface private function updateSamples(ProductInterface $entity, array $samples): void { $isGlobalScope = (int) $entity->getStoreId() === self::GLOBAL_SCOPE_ID; + $samples = $entity->getExtensionAttributes()->getDownloadableProductSamples(); $oldSamples = $this->sampleRepository->getList($entity->getSku()); - $updatedSamples = []; - foreach ($samples as $sample) { - if ($sample->getId()) { - $updatedSamples[$sample->getId()] = true; + if (!empty($samples)) { + $updatedSamples = []; + foreach ($samples as $sample) { + if ($sample->getId()) { + $updatedSamples[$sample->getId()] = true; + } + $this->sampleRepository->save($entity->getSku(), $sample, $isGlobalScope); } - $this->sampleRepository->save($entity->getSku(), $sample, $isGlobalScope); } foreach ($oldSamples as $sample) { From eb9bcc1dccfd06f57042c6f5839caea37f554cdf Mon Sep 17 00:00:00 2001 From: maxo Date: Fri, 29 Jan 2021 18:22:30 +0200 Subject: [PATCH 2/7] remove variable --- app/code/Magento/Downloadable/Model/Sample/UpdateHandler.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/app/code/Magento/Downloadable/Model/Sample/UpdateHandler.php b/app/code/Magento/Downloadable/Model/Sample/UpdateHandler.php index 0e3b31bad39a8..779f3caa2f6d2 100644 --- a/app/code/Magento/Downloadable/Model/Sample/UpdateHandler.php +++ b/app/code/Magento/Downloadable/Model/Sample/UpdateHandler.php @@ -54,10 +54,9 @@ public function execute($entity, $arguments = []): ProductInterface * Update product samples * * @param ProductInterface $entity - * @param array $samples * @return void */ - private function updateSamples(ProductInterface $entity, array $samples): void + private function updateSamples(ProductInterface $entity): void { $isGlobalScope = (int) $entity->getStoreId() === self::GLOBAL_SCOPE_ID; $samples = $entity->getExtensionAttributes()->getDownloadableProductSamples(); From 9e0e86e2afe45dec3e1dc28c495580c9fcd4ab8c Mon Sep 17 00:00:00 2001 From: "taras.gamanov" Date: Mon, 1 Feb 2021 15:12:52 +0200 Subject: [PATCH 3/7] Unit test fix --- .../Downloadable/Test/Unit/Model/Sample/UpdateHandlerTest.php | 3 --- 1 file changed, 3 deletions(-) diff --git a/app/code/Magento/Downloadable/Test/Unit/Model/Sample/UpdateHandlerTest.php b/app/code/Magento/Downloadable/Test/Unit/Model/Sample/UpdateHandlerTest.php index cc0427808ebc0..08b974bf11fd7 100644 --- a/app/code/Magento/Downloadable/Test/Unit/Model/Sample/UpdateHandlerTest.php +++ b/app/code/Magento/Downloadable/Test/Unit/Model/Sample/UpdateHandlerTest.php @@ -129,9 +129,6 @@ public function testExecuteNonDownloadable(): void $this->entityMock->expects($this->once()) ->method('getTypeId') ->willReturn(Type::TYPE_DOWNLOADABLE . 'some'); - $this->entityMock->expects($this->once()) - ->method('getExtensionAttributes') - ->willReturn($this->productExtensionMock); $this->entityMock->expects($this->never()) ->method('getSku'); $this->entityMock->expects($this->never()) From d13aa482b21f28621c2fc59d3dd8876560eaad72 Mon Sep 17 00:00:00 2001 From: "taras.gamanov" Date: Mon, 1 Feb 2021 17:49:07 +0200 Subject: [PATCH 4/7] API test fix --- .../Magento/Downloadable/Api/ProductRepositoryTest.php | 2 -- 1 file changed, 2 deletions(-) diff --git a/dev/tests/api-functional/testsuite/Magento/Downloadable/Api/ProductRepositoryTest.php b/dev/tests/api-functional/testsuite/Magento/Downloadable/Api/ProductRepositoryTest.php index 00bbb3f435cae..f8245d934db1b 100644 --- a/dev/tests/api-functional/testsuite/Magento/Downloadable/Api/ProductRepositoryTest.php +++ b/dev/tests/api-functional/testsuite/Magento/Downloadable/Api/ProductRepositoryTest.php @@ -326,10 +326,8 @@ public function testUpdateDownloadableProductData(): void $response = $this->saveProduct($productData); $this->assertArrayHasKey(ProductInterface::EXTENSION_ATTRIBUTES_KEY, $response); - $this->assertArrayHasKey(self::PRODUCT_SAMPLES, $response[ProductInterface::EXTENSION_ATTRIBUTES_KEY]); $this->assertArrayHasKey(self::PRODUCT_LINKS, $response[ProductInterface::EXTENSION_ATTRIBUTES_KEY]); - $this->assertCount(2, $response[ProductInterface::EXTENSION_ATTRIBUTES_KEY][self::PRODUCT_SAMPLES]); $this->assertCount(2, $response[ProductInterface::EXTENSION_ATTRIBUTES_KEY][self::PRODUCT_LINKS]); } From 8f7773ce9423aa97903ccfa185252e972f7d5fef Mon Sep 17 00:00:00 2001 From: Pavel Bystritsky Date: Mon, 1 Mar 2021 20:07:26 +0200 Subject: [PATCH 5/7] magento/magento2#31887: fix Can't remove samples link product downloadable - MFTF coverage. --- .../ActionGroup/RemoveSampleActionGroup.xml | 22 ++++ .../VerifySampleAbsentActionGroup.xml | 21 ++++ .../VerifySamplePresentActionGroup.xml | 23 ++++ .../AdminProductDownloadableSection.xml | 4 +- ...minDeleteDownloadableProductSampleTest.xml | 107 ++++++++++++++++++ 5 files changed, 175 insertions(+), 2 deletions(-) create mode 100644 app/code/Magento/Downloadable/Test/Mftf/ActionGroup/RemoveSampleActionGroup.xml create mode 100644 app/code/Magento/Downloadable/Test/Mftf/ActionGroup/VerifySampleAbsentActionGroup.xml create mode 100644 app/code/Magento/Downloadable/Test/Mftf/ActionGroup/VerifySamplePresentActionGroup.xml create mode 100644 app/code/Magento/Downloadable/Test/Mftf/Test/AdminDeleteDownloadableProductSampleTest.xml diff --git a/app/code/Magento/Downloadable/Test/Mftf/ActionGroup/RemoveSampleActionGroup.xml b/app/code/Magento/Downloadable/Test/Mftf/ActionGroup/RemoveSampleActionGroup.xml new file mode 100644 index 0000000000000..2948300063abc --- /dev/null +++ b/app/code/Magento/Downloadable/Test/Mftf/ActionGroup/RemoveSampleActionGroup.xml @@ -0,0 +1,22 @@ + + + + + + + Delete Downloadable Product Sample by row id. + + + + + + + + + diff --git a/app/code/Magento/Downloadable/Test/Mftf/ActionGroup/VerifySampleAbsentActionGroup.xml b/app/code/Magento/Downloadable/Test/Mftf/ActionGroup/VerifySampleAbsentActionGroup.xml new file mode 100644 index 0000000000000..7b5b7701c0b0b --- /dev/null +++ b/app/code/Magento/Downloadable/Test/Mftf/ActionGroup/VerifySampleAbsentActionGroup.xml @@ -0,0 +1,21 @@ + + + + + + + Verify Sample is absent on Downloadable Product page. + + + + + + + + diff --git a/app/code/Magento/Downloadable/Test/Mftf/ActionGroup/VerifySamplePresentActionGroup.xml b/app/code/Magento/Downloadable/Test/Mftf/ActionGroup/VerifySamplePresentActionGroup.xml new file mode 100644 index 0000000000000..697538d715b34 --- /dev/null +++ b/app/code/Magento/Downloadable/Test/Mftf/ActionGroup/VerifySamplePresentActionGroup.xml @@ -0,0 +1,23 @@ + + + + + + + Verify Sample is present on Downloadable Product page. + + + + + + + + + + diff --git a/app/code/Magento/Downloadable/Test/Mftf/Section/AdminProductDownloadableSection.xml b/app/code/Magento/Downloadable/Test/Mftf/Section/AdminProductDownloadableSection.xml index 074ed55781103..f6b8092a05911 100644 --- a/app/code/Magento/Downloadable/Test/Mftf/Section/AdminProductDownloadableSection.xml +++ b/app/code/Magento/Downloadable/Test/Mftf/Section/AdminProductDownloadableSection.xml @@ -31,14 +31,14 @@ - + - + diff --git a/app/code/Magento/Downloadable/Test/Mftf/Test/AdminDeleteDownloadableProductSampleTest.xml b/app/code/Magento/Downloadable/Test/Mftf/Test/AdminDeleteDownloadableProductSampleTest.xml new file mode 100644 index 0000000000000..b5f8e8aaa5355 --- /dev/null +++ b/app/code/Magento/Downloadable/Test/Mftf/Test/AdminDeleteDownloadableProductSampleTest.xml @@ -0,0 +1,107 @@ + + + + + + + + + <title value="Delete Downloadable Product Samples"/> + <description value="Admin should be able to delete downloadable product samples"/> + <severity value="MAJOR"/> + <group value="Downloadable"/> + </annotations> + <before> + <!-- Create category --> + <createData entity="SimpleSubCategory" stepKey="createCategory"/> + + <!-- Login as admin --> + <actionGroup ref="AdminLoginActionGroup" stepKey="LoginAsAdmin"/> + </before> + <after> + <!-- Delete category --> + <deleteData createDataKey="createCategory" stepKey="deleteCategory"/> + + <!-- Delete created downloadable product --> + <actionGroup ref="DeleteProductUsingProductGridActionGroup" stepKey="deleteProduct"> + <argument name="product" value="DownloadableProduct"/> + </actionGroup> + + <!-- Log out --> + <actionGroup ref="AdminLogoutActionGroup" stepKey="logout"/> + </after> + + <!-- Create downloadable product --> + <actionGroup ref="AdminOpenProductIndexPageActionGroup" stepKey="amOnProductGridPage"/> + <actionGroup ref="GoToSpecifiedCreateProductPageActionGroup" stepKey="createProduct"> + <argument name="productType" value="downloadable"/> + </actionGroup> + + <!-- Fill downloadable product values --> + <actionGroup ref="FillMainProductFormNoWeightActionGroup" stepKey="fillDownloadableProductForm"> + <argument name="product" value="DownloadableProduct"/> + </actionGroup> + + <!-- Add downloadable product to category --> + <searchAndMultiSelectOption selector="{{AdminProductFormSection.categoriesDropdown}}" + parameterArray="[$$createCategory.name$$]" stepKey="fillCategory"/> + + <!-- Fill downloadable link information before the creation link --> + <actionGroup ref="AdminAddDownloadableLinkInformationActionGroup" stepKey="addDownloadableLinkInformation"/> + + <!-- Links can be purchased separately --> + <checkOption selector="{{AdminProductDownloadableSection.isLinksPurchasedSeparately}}" + stepKey="checkOptionPurchaseSeparately"/> + + <!-- Add downloadable link --> + <actionGroup ref="AddDownloadableProductLinkWithMaxDownloadsActionGroup" stepKey="addDownloadableProductLink"> + <argument name="link" value="downloadableLinkWithMaxDownloads"/> + </actionGroup> + + <!-- Add Sample File --> + <actionGroup ref="AddDownloadableSampleFileActionGroup" stepKey="addDownloadSampleFile"> + <argument name="sample" value="downloadableSampleFile"/> + </actionGroup> + + <!-- Add Sample Url --> + <actionGroup ref="AddDownloadableSampleUrlActionGroup" stepKey="addDownloadableSampleUrl"> + <argument name="sample" value="downloadableSampleUrl"/> + </actionGroup> + + <!-- Save product --> + <actionGroup ref="SaveProductFormActionGroup" stepKey="saveProduct"/> + + <!-- Check if Samples are present --> + <actionGroup ref="VerifySamplePresentActionGroup" stepKey="verifySampleFilePresent"> + <argument name="index" value="0"/> + <argument name="title" value="{{downloadableSampleFile.title}}"/> + </actionGroup> + <actionGroup ref="VerifySamplePresentActionGroup" stepKey="verifySampleUrlPresent"> + <argument name="index" value="1"/> + <argument name="title" value="{{downloadableSampleUrl.title}}"/> + </actionGroup> + + <!-- Remove Samples --> + <actionGroup ref="RemoveSampleActionGroup" stepKey="removeSampleUrl"> + <argument name="index" value="1"/> + </actionGroup> + <actionGroup ref="RemoveSampleActionGroup" stepKey="removeSampleFile"> + <argument name="index" value="0"/> + </actionGroup> + <actionGroup ref="SaveProductFormActionGroup" stepKey="saveProductAfterSamplesRemoved"/> + + <!-- Check if Samples are absent --> + <actionGroup ref="VerifySampleAbsentActionGroup" stepKey="verifySampleFileAbsent"> + <argument name="title" value="{{downloadableSampleFile.title}}"/> + </actionGroup> + <actionGroup ref="VerifySampleAbsentActionGroup" stepKey="verifySampleUrlAbsent"> + <argument name="title" value="{{downloadableSampleUrl.title}}"/> + </actionGroup> + </test> +</tests> From 7651b1af3b6963a2e9f7bf9d699b4c23c5dd1522 Mon Sep 17 00:00:00 2001 From: Pavel Bystritsky <engcom-vendorworker-foxtrot@adobe.com> Date: Tue, 2 Mar 2021 12:24:38 +0200 Subject: [PATCH 6/7] magento/magento2#32100: Admin login issue fix - MFTF update. --- .../VerifySampleAbsentActionGroup.xml | 6 +++--- .../VerifySamplePresentActionGroup.xml | 4 +--- ...minDeleteDownloadableProductSampleTest.xml | 21 +++++-------------- 3 files changed, 9 insertions(+), 22 deletions(-) diff --git a/app/code/Magento/Downloadable/Test/Mftf/ActionGroup/VerifySampleAbsentActionGroup.xml b/app/code/Magento/Downloadable/Test/Mftf/ActionGroup/VerifySampleAbsentActionGroup.xml index 7b5b7701c0b0b..4755be327384a 100644 --- a/app/code/Magento/Downloadable/Test/Mftf/ActionGroup/VerifySampleAbsentActionGroup.xml +++ b/app/code/Magento/Downloadable/Test/Mftf/ActionGroup/VerifySampleAbsentActionGroup.xml @@ -10,12 +10,12 @@ xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd"> <actionGroup name="VerifySampleAbsentActionGroup"> <annotations> - <description>Verify Sample is absent on Downloadable Product page.</description> + <description>Verify Samples are absent on Downloadable Product page.</description> </annotations> <arguments> - <argument name="title" type="string" defaultValue=""/> + <argument name="index" type="string" defaultValue="0"/> </arguments> - <dontSee userInput="{{title}}" stepKey="verifySampleTitleAbsent"/> + <dontSeeElement selector="{{AdminProductDownloadableSection.addSampleTitleInput(index)}}" stepKey="verifySamplesAbsent"/> </actionGroup> </actionGroups> diff --git a/app/code/Magento/Downloadable/Test/Mftf/ActionGroup/VerifySamplePresentActionGroup.xml b/app/code/Magento/Downloadable/Test/Mftf/ActionGroup/VerifySamplePresentActionGroup.xml index 697538d715b34..9c0c64b86b412 100644 --- a/app/code/Magento/Downloadable/Test/Mftf/ActionGroup/VerifySamplePresentActionGroup.xml +++ b/app/code/Magento/Downloadable/Test/Mftf/ActionGroup/VerifySamplePresentActionGroup.xml @@ -14,10 +14,8 @@ </annotations> <arguments> <argument name="index" type="string" defaultValue="0"/> - <argument name="title" type="string" defaultValue=""/> </arguments> - <waitForElementVisible selector="{{AdminProductDownloadableSection.addSampleTitleInput(index)}}" stepKey="waitForSample"/> - <see selector="{{AdminProductDownloadableSection.addSampleTitleInput(index)}}" userInput="{{title}}" stepKey="verifySampleTitle"/> + <seeElement selector="{{AdminProductDownloadableSection.addSampleTitleInput(index)}}" stepKey="verifySampleVisible"/> </actionGroup> </actionGroups> diff --git a/app/code/Magento/Downloadable/Test/Mftf/Test/AdminDeleteDownloadableProductSampleTest.xml b/app/code/Magento/Downloadable/Test/Mftf/Test/AdminDeleteDownloadableProductSampleTest.xml index b5f8e8aaa5355..7d5586bbe8956 100644 --- a/app/code/Magento/Downloadable/Test/Mftf/Test/AdminDeleteDownloadableProductSampleTest.xml +++ b/app/code/Magento/Downloadable/Test/Mftf/Test/AdminDeleteDownloadableProductSampleTest.xml @@ -11,30 +11,24 @@ <test name="AdminDeleteDownloadableProductSampleTest"> <annotations> <features value="Catalog"/> - <title value="Delete Downloadable Product"/> + <stories value="Delete Downloadable Product"/> <title value="Delete Downloadable Product Samples"/> <description value="Admin should be able to delete downloadable product samples"/> <severity value="MAJOR"/> <group value="Downloadable"/> </annotations> <before> - <!-- Create category --> + <magentoCLI command="downloadable:domains:add static.magento.com" stepKey="addDownloadableDomain"/> <createData entity="SimpleSubCategory" stepKey="createCategory"/> - - <!-- Login as admin --> <actionGroup ref="AdminLoginActionGroup" stepKey="LoginAsAdmin"/> </before> <after> - <!-- Delete category --> <deleteData createDataKey="createCategory" stepKey="deleteCategory"/> - - <!-- Delete created downloadable product --> <actionGroup ref="DeleteProductUsingProductGridActionGroup" stepKey="deleteProduct"> <argument name="product" value="DownloadableProduct"/> </actionGroup> - - <!-- Log out --> <actionGroup ref="AdminLogoutActionGroup" stepKey="logout"/> + <magentoCLI command="downloadable:domains:remove static.magento.com" stepKey="removeDownloadableDomain"/> </after> <!-- Create downloadable product --> @@ -80,11 +74,9 @@ <!-- Check if Samples are present --> <actionGroup ref="VerifySamplePresentActionGroup" stepKey="verifySampleFilePresent"> <argument name="index" value="0"/> - <argument name="title" value="{{downloadableSampleFile.title}}"/> </actionGroup> <actionGroup ref="VerifySamplePresentActionGroup" stepKey="verifySampleUrlPresent"> <argument name="index" value="1"/> - <argument name="title" value="{{downloadableSampleUrl.title}}"/> </actionGroup> <!-- Remove Samples --> @@ -97,11 +89,8 @@ <actionGroup ref="SaveProductFormActionGroup" stepKey="saveProductAfterSamplesRemoved"/> <!-- Check if Samples are absent --> - <actionGroup ref="VerifySampleAbsentActionGroup" stepKey="verifySampleFileAbsent"> - <argument name="title" value="{{downloadableSampleFile.title}}"/> - </actionGroup> - <actionGroup ref="VerifySampleAbsentActionGroup" stepKey="verifySampleUrlAbsent"> - <argument name="title" value="{{downloadableSampleUrl.title}}"/> + <actionGroup ref="VerifySampleAbsentActionGroup" stepKey="verifySamplesAbsent"> + <argument name="index" value="0"/> </actionGroup> </test> </tests> From 1abd820230a510b447f24e11ef6ecadabd148e30 Mon Sep 17 00:00:00 2001 From: Gabriel da Gama <gabriel@gabrielgama.com.br> Date: Wed, 7 Apr 2021 14:28:42 +0100 Subject: [PATCH 7/7] Apply suggestions from code review --- ...minDeleteDownloadableProductSampleTest.xml | 24 ------------------- 1 file changed, 24 deletions(-) diff --git a/app/code/Magento/Downloadable/Test/Mftf/Test/AdminDeleteDownloadableProductSampleTest.xml b/app/code/Magento/Downloadable/Test/Mftf/Test/AdminDeleteDownloadableProductSampleTest.xml index 7d5586bbe8956..e575d86b7bed0 100644 --- a/app/code/Magento/Downloadable/Test/Mftf/Test/AdminDeleteDownloadableProductSampleTest.xml +++ b/app/code/Magento/Downloadable/Test/Mftf/Test/AdminDeleteDownloadableProductSampleTest.xml @@ -30,56 +30,34 @@ <actionGroup ref="AdminLogoutActionGroup" stepKey="logout"/> <magentoCLI command="downloadable:domains:remove static.magento.com" stepKey="removeDownloadableDomain"/> </after> - - <!-- Create downloadable product --> <actionGroup ref="AdminOpenProductIndexPageActionGroup" stepKey="amOnProductGridPage"/> <actionGroup ref="GoToSpecifiedCreateProductPageActionGroup" stepKey="createProduct"> <argument name="productType" value="downloadable"/> </actionGroup> - - <!-- Fill downloadable product values --> <actionGroup ref="FillMainProductFormNoWeightActionGroup" stepKey="fillDownloadableProductForm"> <argument name="product" value="DownloadableProduct"/> </actionGroup> - - <!-- Add downloadable product to category --> <searchAndMultiSelectOption selector="{{AdminProductFormSection.categoriesDropdown}}" parameterArray="[$$createCategory.name$$]" stepKey="fillCategory"/> - - <!-- Fill downloadable link information before the creation link --> <actionGroup ref="AdminAddDownloadableLinkInformationActionGroup" stepKey="addDownloadableLinkInformation"/> - - <!-- Links can be purchased separately --> <checkOption selector="{{AdminProductDownloadableSection.isLinksPurchasedSeparately}}" stepKey="checkOptionPurchaseSeparately"/> - - <!-- Add downloadable link --> <actionGroup ref="AddDownloadableProductLinkWithMaxDownloadsActionGroup" stepKey="addDownloadableProductLink"> <argument name="link" value="downloadableLinkWithMaxDownloads"/> </actionGroup> - - <!-- Add Sample File --> <actionGroup ref="AddDownloadableSampleFileActionGroup" stepKey="addDownloadSampleFile"> <argument name="sample" value="downloadableSampleFile"/> </actionGroup> - - <!-- Add Sample Url --> <actionGroup ref="AddDownloadableSampleUrlActionGroup" stepKey="addDownloadableSampleUrl"> <argument name="sample" value="downloadableSampleUrl"/> </actionGroup> - - <!-- Save product --> <actionGroup ref="SaveProductFormActionGroup" stepKey="saveProduct"/> - - <!-- Check if Samples are present --> <actionGroup ref="VerifySamplePresentActionGroup" stepKey="verifySampleFilePresent"> <argument name="index" value="0"/> </actionGroup> <actionGroup ref="VerifySamplePresentActionGroup" stepKey="verifySampleUrlPresent"> <argument name="index" value="1"/> </actionGroup> - - <!-- Remove Samples --> <actionGroup ref="RemoveSampleActionGroup" stepKey="removeSampleUrl"> <argument name="index" value="1"/> </actionGroup> @@ -87,8 +65,6 @@ <argument name="index" value="0"/> </actionGroup> <actionGroup ref="SaveProductFormActionGroup" stepKey="saveProductAfterSamplesRemoved"/> - - <!-- Check if Samples are absent --> <actionGroup ref="VerifySampleAbsentActionGroup" stepKey="verifySamplesAbsent"> <argument name="index" value="0"/> </actionGroup>