Skip to content

Commit 37677f8

Browse files
🔃 [EngCom] Public Pull Requests - 2.3-develop
Accepted Public Pull Requests: - #22287: #222249 configurable product images wrong sorting fix (by @Wirson) - #22532: fixed issue 22527 wishlist and compare icon alignment (by @sanjaychouhan-webkul) - #22020: Non existing file, when adding image to gallery with move option. Fix for #21978 (by @dudzio12) - #22526: code cleanup (http to https) (by @ravi-chandra3197) - #22260: Disabling "Display on Product Details Page" the button is shown anyway. (by @Nazar65) - #20135: issue fixed #20124 Sort By label is hidden by Shop By Menu on listing� (by @cedarvinda) Fixed GitHub Issues: - #22249: Configurable Product Gallery Images Out of Order when More than 10 images (reported by @sjb9774) has been fixed in #22287 by @Wirson in 2.3-develop branch Related commits: 1. 700a153 - #22527: Wishlist and compare icon align issue in product listing page (reported by @bhavik43) has been fixed in #22532 by @sanjaychouhan-webkul in 2.3-develop branch Related commits: 1. e161862 - #21978: Adding product image: File doesn't exist (reported by @WalterSmulders) has been fixed in #22020 by @dudzio12 in 2.3-develop branch Related commits: 1. 103c28b 2. 74ef0c0 - #22045: Instant Purchase on product page not working properly. (reported by @afavata) has been fixed in #22260 by @Nazar65 in 2.3-develop branch Related commits: 1. 233e4c5 - #22134: Paypal buttons disable issue - Magento 2.3.1 (reported by @Userr017) has been fixed in #22260 by @Nazar65 in 2.3-develop branch Related commits: 1. 233e4c5 - #20124: Sort By label is hidden by Shop By Menu on listing page in iphone5 device (reported by @dipti2jcommerce) has been fixed in #20135 by @cedarvinda in 2.3-develop branch Related commits: 1. 11af877 2. 42b81c0
2 parents 93a8162 + 5523461 commit 37677f8

File tree

25 files changed

+96
-38
lines changed

25 files changed

+96
-38
lines changed

app/code/Magento/Backend/Block/Store/Switcher.php

Lines changed: 46 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ class Switcher extends \Magento\Backend\Block\Template
1717
/**
1818
* URL for store switcher hint
1919
*/
20-
const HINT_URL = 'http://docs.magento.com/m2/ce/user_guide/configuration/scope.html';
20+
const HINT_URL = 'https://docs.magento.com/m2/ce/user_guide/configuration/scope.html';
2121

2222
/**
2323
* Name of website variable
@@ -86,6 +86,8 @@ class Switcher extends \Magento\Backend\Block\Template
8686
protected $_storeFactory;
8787

8888
/**
89+
* Switcher constructor.
90+
*
8991
* @param \Magento\Backend\Block\Template\Context $context
9092
* @param \Magento\Store\Model\WebsiteFactory $websiteFactory
9193
* @param \Magento\Store\Model\GroupFactory $storeGroupFactory
@@ -106,7 +108,7 @@ public function __construct(
106108
}
107109

108110
/**
109-
* @return void
111+
* @inheritdoc
110112
*/
111113
protected function _construct()
112114
{
@@ -130,6 +132,8 @@ protected function _construct()
130132
}
131133

132134
/**
135+
* Get website collection.
136+
*
133137
* @return \Magento\Store\Model\ResourceModel\Website\Collection
134138
*/
135139
public function getWebsiteCollection()
@@ -169,6 +173,8 @@ public function isWebsiteSwitchEnabled()
169173
}
170174

171175
/**
176+
* Set website variable name.
177+
*
172178
* @param string $varName
173179
* @return $this
174180
*/
@@ -179,6 +185,8 @@ public function setWebsiteVarName($varName)
179185
}
180186

181187
/**
188+
* Get website variable name.
189+
*
182190
* @return string
183191
*/
184192
public function getWebsiteVarName()
@@ -191,6 +199,8 @@ public function getWebsiteVarName()
191199
}
192200

193201
/**
202+
* Check if current website selected.
203+
*
194204
* @param \Magento\Store\Model\Website $website
195205
* @return bool
196206
*/
@@ -200,6 +210,8 @@ public function isWebsiteSelected(\Magento\Store\Model\Website $website)
200210
}
201211

202212
/**
213+
* Return website Id.
214+
*
203215
* @return int|null
204216
*/
205217
public function getWebsiteId()
@@ -211,6 +223,8 @@ public function getWebsiteId()
211223
}
212224

213225
/**
226+
* Return group collection provided website.
227+
*
214228
* @param int|\Magento\Store\Model\Website $website
215229
* @return \Magento\Store\Model\ResourceModel\Group\Collection
216230
*/
@@ -247,6 +261,8 @@ public function isStoreGroupSwitchEnabled()
247261
}
248262

249263
/**
264+
* Sets store group variable name.
265+
*
250266
* @param string $varName
251267
* @return $this
252268
*/
@@ -257,6 +273,8 @@ public function setStoreGroupVarName($varName)
257273
}
258274

259275
/**
276+
* Return store group variable name.
277+
*
260278
* @return string
261279
*/
262280
public function getStoreGroupVarName()
@@ -269,6 +287,8 @@ public function getStoreGroupVarName()
269287
}
270288

271289
/**
290+
* Is provided group selected.
291+
*
272292
* @param \Magento\Store\Model\Group $group
273293
* @return bool
274294
*/
@@ -278,6 +298,8 @@ public function isStoreGroupSelected(\Magento\Store\Model\Group $group)
278298
}
279299

280300
/**
301+
* Return store group Id.
302+
*
281303
* @return int|null
282304
*/
283305
public function getStoreGroupId()
@@ -289,6 +311,8 @@ public function getStoreGroupId()
289311
}
290312

291313
/**
314+
* Return store collection.
315+
*
292316
* @param \Magento\Store\Model\Group|int $group
293317
* @return \Magento\Store\Model\ResourceModel\Store\Collection
294318
*/
@@ -328,6 +352,8 @@ public function getStores($group)
328352
}
329353

330354
/**
355+
* Return store Id.
356+
*
331357
* @return int|null
332358
*/
333359
public function getStoreId()
@@ -339,6 +365,8 @@ public function getStoreId()
339365
}
340366

341367
/**
368+
* Check is provided store selected.
369+
*
342370
* @param \Magento\Store\Model\Store $store
343371
* @return bool
344372
*/
@@ -358,6 +386,8 @@ public function isStoreSwitchEnabled()
358386
}
359387

360388
/**
389+
* Sets store variable name.
390+
*
361391
* @param string $varName
362392
* @return $this
363393
*/
@@ -368,6 +398,8 @@ public function setStoreVarName($varName)
368398
}
369399

370400
/**
401+
* Return store variable name.
402+
*
371403
* @return mixed|string
372404
*/
373405
public function getStoreVarName()
@@ -380,6 +412,8 @@ public function getStoreVarName()
380412
}
381413

382414
/**
415+
* Return switch url.
416+
*
383417
* @return string
384418
*/
385419
public function getSwitchUrl()
@@ -399,6 +433,8 @@ public function getSwitchUrl()
399433
}
400434

401435
/**
436+
* Checks if scope selected.
437+
*
402438
* @return bool
403439
*/
404440
public function hasScopeSelected()
@@ -472,6 +508,8 @@ public function getCurrentStoreName()
472508
}
473509

474510
/**
511+
* Sets store ids.
512+
*
475513
* @param array $storeIds
476514
* @return $this
477515
*/
@@ -482,6 +520,8 @@ public function setStoreIds($storeIds)
482520
}
483521

484522
/**
523+
* Return store ids.
524+
*
485525
* @return array
486526
*/
487527
public function getStoreIds()
@@ -490,6 +530,8 @@ public function getStoreIds()
490530
}
491531

492532
/**
533+
* Check if system is run in the single store mode.
534+
*
493535
* @return bool
494536
*/
495537
public function isShow()
@@ -498,6 +540,8 @@ public function isShow()
498540
}
499541

500542
/**
543+
* Render block.
544+
*
501545
* @return string
502546
*/
503547
protected function _toHtml()

app/code/Magento/Braintree/etc/adminhtml/system.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
</requires>
4242
</field>
4343
<group id="configuration_details" showInDefault="1" showInWebsite="1" showInStore="1" sortOrder="4">
44-
<comment>http://docs.magento.com/m2/ce/user_guide/payment/braintree.html</comment>
44+
<comment>https://docs.magento.com/m2/ce/user_guide/payment/braintree.html</comment>
4545
<frontend_model>Magento\Paypal\Block\Adminhtml\System\Config\Fieldset\Hint</frontend_model>
4646
</group>
4747
<group id="braintree_required" translate="label" showInDefault="1" showInWebsite="1" showInStore="1" sortOrder="5">

app/code/Magento/Catalog/Model/Product/Gallery/Processor.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,7 @@ public function addImage(
157157
throw new LocalizedException(__("The image doesn't exist."));
158158
}
159159

160+
// phpcs:ignore Magento2.Functions.DiscouragedFunction
160161
$pathinfo = pathinfo($file);
161162
$imgExtensions = ['jpg', 'jpeg', 'gif', 'png'];
162163
if (!isset($pathinfo['extension']) || !in_array(strtolower($pathinfo['extension']), $imgExtensions)) {
@@ -196,7 +197,7 @@ public function addImage(
196197
$mediaGalleryData = $product->getData($attrCode);
197198
$position = 0;
198199

199-
$absoluteFilePath = $this->mediaDirectory->getAbsolutePath($file);
200+
$absoluteFilePath = $this->mediaDirectory->getAbsolutePath($destinationFile);
200201
$imageMimeType = $this->mime->getMimeType($absoluteFilePath);
201202
$imageContent = $this->mediaDirectory->readFile($absoluteFilePath);
202203
$imageBase64 = base64_encode($imageContent);
@@ -452,6 +453,7 @@ protected function getUniqueFileName($file, $forTmp = false)
452453
$destinationFile = $forTmp
453454
? $this->mediaDirectory->getAbsolutePath($this->mediaConfig->getTmpMediaPath($file))
454455
: $this->mediaDirectory->getAbsolutePath($this->mediaConfig->getMediaPath($file));
456+
// phpcs:ignore Magento2.Functions.DiscouragedFunction
455457
$destFile = dirname($file) . '/'
456458
. \Magento\MediaStorage\Model\File\Uploader::getNewFileName($destinationFile);
457459
}
@@ -494,7 +496,7 @@ protected function getNotDuplicatedFilename($fileName, $dispretionPath)
494496
/**
495497
* Retrieve data for update attribute
496498
*
497-
* @param \Magento\Catalog\Model\Product $object
499+
* @param \Magento\Catalog\Model\Product $object
498500
* @return array
499501
* @since 101.0.0
500502
*/

app/code/Magento/Catalog/Ui/DataProvider/Product/Form/Modifier/Websites.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ protected function getFieldsForFieldset()
165165
$websitesList = $this->getWebsitesList();
166166
$isNewProduct = !$this->locator->getProduct()->getId();
167167
$tooltip = [
168-
'link' => 'http://docs.magento.com/m2/ce/user_guide/configuration/scope.html',
168+
'link' => 'https://docs.magento.com/m2/ce/user_guide/configuration/scope.html',
169169
'description' => __(
170170
'If your Magento installation has multiple websites, ' .
171171
'you can edit the scope to use the product on specific sites.'

app/code/Magento/CatalogRule/view/adminhtml/ui_component/catalog_rule_form.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@
136136
</validation>
137137
<dataType>number</dataType>
138138
<tooltip>
139-
<link>http://docs.magento.com/m2/ce/user_guide/configuration/scope.html</link>
139+
<link>https://docs.magento.com/m2/ce/user_guide/configuration/scope.html</link>
140140
<description>What is this?</description>
141141
</tooltip>
142142
<label translate="true">Websites</label>

app/code/Magento/Customer/Model/ResourceModel/CustomerRepository.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -343,7 +343,7 @@ public function getById($customerId)
343343
* Retrieve customers which match a specified criteria.
344344
*
345345
* This call returns an array of objects, but detailed information about each object’s attributes might not be
346-
* included. See http://devdocs.magento.com/codelinks/attributes.html#CustomerRepositoryInterface to determine
346+
* included. See https://devdocs.magento.com/codelinks/attributes.html#CustomerRepositoryInterface to determine
347347
* which call to use to get detailed information about all attributes for an object.
348348
*
349349
* @param \Magento\Framework\Api\SearchCriteriaInterface $searchCriteria

app/code/Magento/Customer/view/base/ui_component/customer_form.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@
129129
</validation>
130130
<dataType>number</dataType>
131131
<tooltip>
132-
<link>http://docs.magento.com/m2/ce/user_guide/configuration/scope.html</link>
132+
<link>https://docs.magento.com/m2/ce/user_guide/configuration/scope.html</link>
133133
<description translate="true">If your Magento installation has multiple websites, you can edit the scope to associate the customer with a specific site.</description>
134134
</tooltip>
135135
<imports>

app/code/Magento/Paypal/Model/SmartButtonConfig.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,8 @@ public function getConfig(string $page): array
6767
'locale' => $this->localeResolver->getLocale(),
6868
'allowedFunding' => $this->getAllowedFunding($page),
6969
'disallowedFunding' => $this->getDisallowedFunding(),
70-
'styles' => $this->getButtonStyles($page)
70+
'styles' => $this->getButtonStyles($page),
71+
'isVisibleOnProductPage' => (int)$this->config->getValue('visible_on_product')
7172
];
7273
}
7374

app/code/Magento/Paypal/Test/Unit/Model/_files/expected_config.php

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@
3131
'shape' => 'pillow',
3232
'label' => 'installment',
3333
'installmentperiod' => 0
34-
]
34+
],
35+
'isVisibleOnProductPage' => 0
3536
]
3637
],
3738
'checkout' => [
@@ -59,7 +60,8 @@
5960
'shape' => 'pillow',
6061
'label' => 'installment',
6162
'installmentperiod' => 0
62-
]
63+
],
64+
'isVisibleOnProductPage' => 0
6365
]
6466
],
6567
'mini_cart' => [
@@ -86,7 +88,8 @@
8688
'color' => 'gold',
8789
'shape' => 'rect',
8890
'label' => 'paypal'
89-
]
91+
],
92+
'isVisibleOnProductPage' => 0
9093
]
9194
],
9295
'mini_cart' => [
@@ -113,7 +116,8 @@
113116
'color' => 'gold',
114117
'shape' => 'rect',
115118
'label' => 'paypal'
116-
]
119+
],
120+
'isVisibleOnProductPage' => 0
117121
]
118122
],
119123
'product' => [
@@ -140,7 +144,8 @@
140144
'color' => 'gold',
141145
'shape' => 'rect',
142146
'label' => 'paypal',
143-
]
147+
],
148+
'isVisibleOnProductPage' => 0
144149
]
145150
]
146151
];

app/code/Magento/Paypal/etc/adminhtml/system.xml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@
7575
<label>Payments Pro</label>
7676
<attribute type="activity_path">payment/paypal_payment_pro/active</attribute>
7777
<group id="configuration_details">
78-
<comment>http://docs.magento.com/m2/ce/user_guide/payment/paypal-payments-pro.html</comment>
78+
<comment>https://docs.magento.com/m2/ce/user_guide/payment/paypal-payments-pro.html</comment>
7979
</group>
8080
<group id="paypal_payflow_required" showInDefault="1" showInWebsite="1" sortOrder="10">
8181
<field id="enable_paypal_payflow">
@@ -95,7 +95,7 @@
9595
<comment>Accept credit card and PayPal payments securely.</comment>
9696
<attribute type="activity_path">payment/wps_express/active</attribute>
9797
<group id="configuration_details">
98-
<comment>http://docs.magento.com/m2/ce/user_guide/payment/paypal-payments-standard.html</comment>
98+
<comment>https://docs.magento.com/m2/ce/user_guide/payment/paypal-payments-standard.html</comment>
9999
</group>
100100
<group id="express_checkout_required">
101101
<group id="express_checkout_required_express_checkout">
@@ -174,7 +174,7 @@
174174
<comment>Accept credit card and PayPal payments securely.</comment>
175175
<attribute type="activity_path">payment/wps_express/active</attribute>
176176
<group id="configuration_details">
177-
<comment>http://docs.magento.com/m2/ce/user_guide/payment/paypal-payments-standard.html</comment>
177+
<comment>https://docs.magento.com/m2/ce/user_guide/payment/paypal-payments-standard.html</comment>
178178
</group>
179179
<group id="express_checkout_required">
180180
<group id="express_checkout_required_express_checkout" translate="label">
@@ -245,7 +245,7 @@
245245
<comment>Accept credit card and PayPal payments securely.</comment>
246246
<attribute type="activity_path">payment/wps_express/active</attribute>
247247
<group id="configuration_details">
248-
<comment>http://docs.magento.com/m2/ce/user_guide/payment/paypal-payments-standard.html</comment>
248+
<comment>https://docs.magento.com/m2/ce/user_guide/payment/paypal-payments-standard.html</comment>
249249
</group>
250250
<group id="express_checkout_required">
251251
<group id="express_checkout_required_express_checkout" translate="label">
@@ -290,7 +290,7 @@
290290
<label>Website Payments Pro</label>
291291
<attribute type="activity_path">payment/paypal_payment_pro/active</attribute>
292292
<group id="configuration_details">
293-
<comment>http://docs.magento.com/m2/ce/user_guide/payment/paypal-payments-pro.html</comment>
293+
<comment>https://docs.magento.com/m2/ce/user_guide/payment/paypal-payments-pro.html</comment>
294294
</group>
295295
<group id="paypal_payflow_required" translate="label" showInDefault="1" showInWebsite="1" sortOrder="10">
296296
<group id="paypal_payflow_api_settings">

0 commit comments

Comments
 (0)