Skip to content

Commit 0adff35

Browse files
[Magento Community Engineering] Community Contributions - 2.3-develop
- merged latest code from mainline branch
2 parents 7b6ec93 + 8441cf4 commit 0adff35

File tree

13 files changed

+187
-3
lines changed

13 files changed

+187
-3
lines changed

app/code/Magento/CatalogGraphQl/Model/Resolver/Category/DataProvider/Breadcrumbs.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,11 @@ public function __construct(
2929
}
3030

3131
/**
32+
* Get breadcrumbs data
33+
*
3234
* @param string $categoryPath
3335
* @return array
36+
* @throws \Magento\Framework\Exception\LocalizedException
3437
*/
3538
public function getData(string $categoryPath): array
3639
{
@@ -41,7 +44,7 @@ public function getData(string $categoryPath): array
4144

4245
if (count($parentCategoryIds)) {
4346
$collection = $this->collectionFactory->create();
44-
$collection->addAttributeToSelect(['name', 'url_key']);
47+
$collection->addAttributeToSelect(['name', 'url_key', 'url_path']);
4548
$collection->addAttributeToFilter('entity_id', $parentCategoryIds);
4649

4750
foreach ($collection as $category) {
@@ -50,6 +53,7 @@ public function getData(string $categoryPath): array
5053
'category_name' => $category->getName(),
5154
'category_level' => $category->getLevel(),
5255
'category_url_key' => $category->getUrlKey(),
56+
'category_url_path' => $category->getUrlPath(),
5357
];
5458
}
5559
}

app/code/Magento/CatalogGraphQl/etc/schema.graphqls

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -223,6 +223,7 @@ type Breadcrumb @doc(description: "Breadcrumb item."){
223223
category_name: String @doc(description: "Category name.")
224224
category_level: Int @doc(description: "Category level.")
225225
category_url_key: String @doc(description: "Category URL key.")
226+
category_url_path: String @doc(description: "Category URL path.")
226227
}
227228

228229
type CustomizableRadioOption implements CustomizableOptionInterface @doc(description: "CustomizableRadioOption contains information about a set of radio buttons that are defined as part of a customizable option.") {

app/code/Magento/CatalogRule/Test/Mftf/ActionGroup/CatalogPriceRuleActionGroup.xml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,10 @@
5757
<scrollToTopOfPage stepKey="scrollToTop"/>
5858
<waitForPageLoad stepKey="waitForApplied"/>
5959
</actionGroup>
60-
60+
<actionGroup name="AdminCreateMultipleWebsiteCatalogPriceRule" extends="createCatalogPriceRule">
61+
<remove keyForRemoval="selectSite"/>
62+
<selectOption selector="{{AdminNewCatalogPriceRule.websites}}" parameterArray="['FirstWebsite', 'SecondWebsite']" stepKey="selectWebsite"/>
63+
</actionGroup>
6164
<actionGroup name="CreateCatalogPriceRuleViaTheUi">
6265
<arguments>
6366
<argument name="catalogRule" defaultValue="_defaultCatalogRule"/>

app/code/Magento/Checkout/Test/Mftf/ActionGroup/GuestCheckoutFillNewBillingAddressActionGroup.xml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,10 @@
2828
<fillField selector="{{CheckoutPaymentSection.guestPostcode}}" userInput="{{customerAddressVar.postcode}}" stepKey="enterPostcode"/>
2929
<fillField selector="{{CheckoutPaymentSection.guestTelephone}}" userInput="{{customerAddressVar.telephone}}" stepKey="enterTelephone"/>
3030
</actionGroup>
31+
<actionGroup name="StorefrontCheckoutFillNewBillingAddressActionGroup" extends="GuestCheckoutFillNewBillingAddressActionGroup">
32+
<remove keyForRemoval="enterEmail"/>
33+
<remove keyForRemoval="waitForLoading3"/>
34+
</actionGroup>
3135

3236
<actionGroup name="LoggedInCheckoutFillNewBillingAddressActionGroup">
3337
<annotations>

app/code/Magento/Checkout/Test/Mftf/Page/CheckoutPage.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,6 @@
1414
<section name="CheckoutOrderSummarySection"/>
1515
<section name="CheckoutSuccessMainSection"/>
1616
<section name="CheckoutPaymentSection"/>
17+
<section name="SelectShippingBillingPopupSection"/>
1718
</page>
1819
</pages>

app/code/Magento/Checkout/Test/Mftf/Section/CheckoutPaymentSection.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@
4242
<element name="ProductOptionLinkActiveByProductItemName" type="text" selector="//div[@class='product-item-details']//strong[@class='product-item-name'][text()='{{var1}}']//ancestor::div[@class='product-item-details']//div[@class='product options active']//a[text() = '{{var2}}']" parameterized="true" />
4343
<element name="shipToInformation" type="text" selector="//div[@class='ship-to']//div[@class='shipping-information-content']" />
4444
<element name="shippingMethodInformation" type="text" selector="//div[@class='ship-via']//div[@class='shipping-information-content']" />
45+
<element name="shippingInformationSection" type="text" selector=".ship-to .shipping-information-content" />
4546
<element name="paymentMethodTitle" type="text" selector=".payment-method-title span" />
4647
<element name="productOptionsByProductItemPrice" type="text" selector="//div[@class='product-item-inner']//div[@class='subtotal']//span[@class='price'][contains(.,'{{price}}')]//ancestor::div[@class='product-item-details']//div[@class='product options']" parameterized="true"/>
4748
<element name="productOptionsActiveByProductItemPrice" type="text" selector="//div[@class='subtotal']//span[@class='price'][contains(.,'{{price}}')]//ancestor::div[@class='product-item-details']//div[@class='product options active']" parameterized="true"/>

app/code/Magento/Checkout/view/frontend/web/js/view/shipping.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -249,6 +249,16 @@ define([
249249
if (this.validateShippingInformation()) {
250250
quote.billingAddress(null);
251251
checkoutDataResolver.resolveBillingAddress();
252+
registry.async('checkoutProvider')(function (checkoutProvider) {
253+
var shippingAddressData = checkoutData.getShippingAddressFromData();
254+
255+
if (shippingAddressData) {
256+
checkoutProvider.set(
257+
'shippingAddress',
258+
$.extend(true, {}, checkoutProvider.get('shippingAddress'), shippingAddressData)
259+
);
260+
}
261+
});
252262
setShippingInformationAction().done(
253263
function () {
254264
stepNavigator.next();

app/code/Magento/Customer/Test/Mftf/Data/AddressData.xml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,21 @@
5151
<data key="default_shipping">Yes</data>
5252
<requiredEntity type="region">RegionTX</requiredEntity>
5353
</entity>
54+
<entity name="US_Address_TX_Without_Default" type="address">
55+
<data key="firstname">John</data>
56+
<data key="lastname">Doe</data>
57+
<data key="company">Magento</data>
58+
<array key="street">
59+
<item>7700 West Parmer Lane</item>
60+
</array>
61+
<data key="city">Austin</data>
62+
<data key="state">Texas</data>
63+
<data key="country_id">US</data>
64+
<data key="country">United States</data>
65+
<data key="postcode">78729</data>
66+
<data key="telephone">512-345-6789</data>
67+
<requiredEntity type="region">RegionTX</requiredEntity>
68+
</entity>
5469
<entity name="US_Address_TX_Default_Billing" type="address">
5570
<data key="firstname">John</data>
5671
<data key="lastname">Doe</data>

app/code/Magento/Customer/Test/Mftf/Data/CustomerData.xml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,20 @@
4747
<data key="group">General</data>
4848
<requiredEntity type="address">US_Address_TX</requiredEntity>
4949
</entity>
50+
<entity name="Simple_US_Customer_Without_Default_Address" type="customer">
51+
<data key="group_id">1</data>
52+
<data key="default_billing">true</data>
53+
<data key="default_shipping">true</data>
54+
<data key="email" unique="prefix">John.Doe@example.com</data>
55+
<data key="firstname">John</data>
56+
<data key="lastname">Doe</data>
57+
<data key="fullname">John Doe</data>
58+
<data key="password">pwdTest123!</data>
59+
<data key="store_id">0</data>
60+
<data key="website_id">0</data>
61+
<data key="group">General</data>
62+
<requiredEntity type="address">US_Address_TX_Without_Default</requiredEntity>
63+
</entity>
5064
<entity name="SimpleUsCustomerWithNewCustomerGroup" type="customer">
5165
<data key="default_billing">true</data>
5266
<data key="default_shipping">true</data>

app/code/Magento/SalesRule/Test/Mftf/ActionGroup/AdminCreateCartPriceRuleActionGroup.xml

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,18 @@
105105
<waitForElementVisible selector="{{AdminCartPriceRulesFormSection.categoryCheckbox(categoryName)}}" stepKey="waitForCategoryVisible" after="openChooser"/>
106106
<checkOption selector="{{AdminCartPriceRulesFormSection.categoryCheckbox(categoryName)}}" stepKey="checkCategoryName" after="waitForCategoryVisible"/>
107107
</actionGroup>
108-
108+
<actionGroup name="AdminCreateMultiWebsiteCartPriceRuleActionGroup" extends="AdminCreateCartPriceRuleActionGroup">
109+
<annotations>
110+
<description>EXTENDS: AdminCreateCartPriceRuleActionGroup. Removes 'clickSaveButton' for the next data changing. Assign cart price rule to 2 websites instead of 1.</description>
111+
</annotations>
112+
<arguments>
113+
<argument name="ruleName"/>
114+
</arguments>
115+
<remove keyForRemoval="clickSaveButton"/>
116+
<remove keyForRemoval="seeSuccessMessage"/>
117+
<remove keyForRemoval="selectWebsites"/>
118+
<selectOption selector="{{AdminCartPriceRulesFormSection.websites}}" parameterArray="['FirstWebsite', 'SecondWebsite']" stepKey="selectWebsites" after="fillRuleName"/>
119+
</actionGroup>
109120
<actionGroup name="CreateCartPriceRuleSecondWebsiteActionGroup">
110121
<annotations>
111122
<description>Goes to the Admin Cart Price Rule grid page. Clicks on Add New Rule. Fills the provided Rule (Name). Selects 'Second Website' from the 'Websites' menu.</description>

0 commit comments

Comments
 (0)