Skip to content

Commit

Permalink
🔃 [EngCom] Public Pull Requests - 2.3-develop
Browse files Browse the repository at this point in the history
Accepted Public Pull Requests:
 - magento#15764: [Forwardport] [Resolved : Menu widget submenu alignment] (by @hitesh-wagento)
 - magento#15763: [Forwardport] Function unnecessarily called multiple time (by @vgelani)
 - magento#15752: [Forwardport] Refactor JavsScript for customer logout (by @vijay-wagento)
 - magento#15757: [Forwardport] Move buttons definition to separate file (by @vijay-wagento)
 - magento#15750: [Forwardport] Added language translation in template files (by @vijay-wagento)
 - magento#15747: [Forwardport] Refactor JavsScript for UrlRewrite module edit page (by @vijay-wagento)
 - magento#15696: [Forwardport] fixed Submitting search form (mini) with enter key fires event handle� (by @vgelani)
 - magento#15705: [Forwardport] Fix magento#13415 : Duplicated elements id (by @julienanquetil)
 - magento#15731: [Forwardport] Refactor javascript code of  button split widget (by @vijay-wagento)
 - magento#15738: [Forwardport] fix: support multiple minisearch widget instances (by @vijay-wagento)
 - magento#15717: Fixed return type of wishlist's getImageData in DocBlock (by @rogyar)
 - magento#15709: [Forwardport] [Resolved : Menu widget submenu alignment magento#7897] (by @dmytro-ch)
 - magento#15707: [Forwardport] Typo correction (by @dmytro-ch)
 - magento#15706: [Forwardport] Use stored value of method instead of calling same method again. (by @dmytro-ch)
 - magento#15703: [Forwardport] Remove extra space and format the code in translation file (by @dmytro-ch)
 - magento#15701: [Forwardport] Fix HTML syntax in report.phtml error template (by @dmytro-ch)
 - magento#15665: [Forwardport] Wrong invoice prefix in multistore setup due to default store (by @vgelani)


Fixed GitHub Issues:
 - magento#7897: Menu widget submenu alignment (reported by @slackerzz) has been fixed in magento#15764 by @hitesh-wagento in 2.3-develop branch
   Related commits:
     1. ecc5f7b

 - magento#15355: Function is unnecessarily called multiple time (reported by @saurabh-aureate) has been fixed in magento#15763 by @vgelani in 2.3-develop branch
   Related commits:
     1. bcdd8f2

 - magento#15356: Refactore javascript for module URL rewrite (reported by @vgelani) has been fixed in magento#15747 by @vijay-wagento in 2.3-develop branch
   Related commits:
     1. 6711694

 - magento#13793: Submitting search form (mini) with enter key fires event handlers bound by jquery twice (reported by @koenner01) has been fixed in magento#15696 by @vgelani in 2.3-develop branch
   Related commits:
     1. 04583ac

 - magento#13415: Duplicated elements id in checkout page (reported by @angelo983) has been fixed in magento#15705 by @julienanquetil in 2.3-develop branch
   Related commits:
     1. 82d0491
     2. fbb81c9
     3. 6301ed4

 - magento#15354: Refactor javascript code of button split widget call js component (reported by @amittiwari024) has been fixed in magento#15731 by @vijay-wagento in 2.3-develop branch
   Related commits:
     1. eaa585d

 - magento#7897: Menu widget submenu alignment (reported by @slackerzz) has been fixed in magento#15709 by @dmytro-ch in 2.3-develop branch
   Related commits:
     1. 14bf8af

 - magento#14063: Wrong invoice prefix in multistore setup due to default store id (reported by @shinesoftware) has been fixed in magento#15665 by @vgelani in 2.3-develop branch
   Related commits:
     1. d5c3952
  • Loading branch information
Stanislav Idolov authored Jun 5, 2018
2 parents 66abad2 + 3409fba commit 0ad656d
Show file tree
Hide file tree
Showing 22 changed files with 110 additions and 62 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,11 @@
<?php endif; ?>
</div>

<script>
require(['jquery'], function($){
$('.actions-split')
.on('click.splitDefault', '.action-default', function() {
$(this).siblings('.dropdown-menu').find('.item-default').trigger('click');
});
});
<script type="text/x-magento-init">
{
".actions-split": {
"Magento_Ui/js/grid/controls/button/split": {}
}
}
</script>

Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ $ccType = $block->getInfoData('cc_type');
name="payment[is_active_payment_token_enabler]"
class="admin__control-checkbox"/>
<label class="label" for="<?= /* @noEscape */ $code ?>_vault">
<span><?= $block->escapeHtml('Save for later use.') ?></span>
<span><?= $block->escapeHtml(__('Save for later use.')) ?></span>
</label>
</div>
<?php endif; ?>
Expand Down
6 changes: 1 addition & 5 deletions app/code/Magento/Captcha/i18n/en_US.csv
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,7 @@ Forms,Forms
"Number of Symbols","Number of Symbols"
"Please specify 8 symbols at the most. Range allowed (e.g. 3-5)","Please specify 8 symbols at the most. Range allowed (e.g. 3-5)"
"Symbols Used in CAPTCHA","Symbols Used in CAPTCHA"
"
Please use only letters (a-z or A-Z) or numbers (0-9) in this field. No spaces or other characters are allowed.<br />Similar looking characters (e.g. ""i"", ""l"", ""1"") decrease chance of correct recognition by customer.
","
Please use only letters (a-z or A-Z) or numbers (0-9) in this field. No spaces or other characters are allowed.<br />Similar looking characters (e.g. ""i"", ""l"", ""1"") decrease chance of correct recognition by customer.
"
"Please use only letters (a-z or A-Z) or numbers (0-9) in this field. No spaces or other characters are allowed.<br />Similar looking characters (e.g. ""i"", ""l"", ""1"") decrease chance of correct recognition by customer.","Please use only letters (a-z or A-Z) or numbers (0-9) in this field. No spaces or other characters are allowed.<br />Similar looking characters (e.g. ""i"", ""l"", ""1"") decrease chance of correct recognition by customer."
"Case Sensitive","Case Sensitive"
"Enable CAPTCHA on Storefront","Enable CAPTCHA on Storefront"
"CAPTCHA for ""Create user"" and ""Forgot password"" forms is always enabled if chosen.","CAPTCHA for ""Create user"" and ""Forgot password"" forms is always enabled if chosen."
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ public function getChildrenIds($parentId, $required = true)
}

/**
* Retrieve parent ids array by requered child
* Retrieve parent ids array by required child
*
* @param int|array $childId
* @return array
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@
*/
?>

<?php $block->getCurrencySymbolsData();?>

<form id="currency-symbols-form" action="<?= /* @escapeNotVerified */ $block->getFormActionUrl() ?>" method="post">
<input name="form_key" type="hidden" value="<?= /* @escapeNotVerified */ $block->getFormKey() ?>" />
<fieldset class="admin__fieldset">
Expand Down
17 changes: 8 additions & 9 deletions app/code/Magento/Customer/view/frontend/templates/logout.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,12 @@
/** @var \Magento\Framework\View\Element\Template $block */
?>
<p><?= $block->escapeHtml(__('You have signed out and will go to our homepage in 5 seconds.')) ?></p>
<script>
require([
"jquery",
"mage/mage"
], function($){

$($.mage.redirect("<?= $block->escapeJs($block->escapeUrl($block->getUrl())) ?>", "assign", 5000));

});
<script type="text/x-magento-init">
{
"*": {
"Magento_Customer/js/logout-redirect": {
"url": "<?= $block->escapeJs($block->escapeUrl($block->getUrl())) ?>"
}
}
}
</script>
15 changes: 15 additions & 0 deletions app/code/Magento/Customer/view/frontend/web/js/logout-redirect.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/

define([
'jquery',
'mage/mage'
], function ($) {
'use strict';

return function (data) {
$($.mage.redirect(data.url, 'assign', 5000));
};
});
Original file line number Diff line number Diff line change
Expand Up @@ -12,26 +12,24 @@
<div class="gift-options-content">
<fieldset class="fieldset">
<div class="field field-to">
<label for="gift-message-whole-to" class="label">
<label data-bind="attr: {for: 'gift-message-whole-to-' + index }" class="label">
<span data-bind="i18n: 'To:'"></span>
</label>
<div class="control">
<input type="text"
id="gift-message-whole-to"
class="input-text"
data-bind="value: getObservable('recipient')">
data-bind="value: getObservable('recipient'), attr: { id: 'gift-message-whole-to-' + index }">
</div>
</div>

<div class="field field-from">
<label for="gift-message-whole-from" class="label">
<label data-bind="attr: {for: 'gift-message-whole-from-' + index }" class="label">
<span data-bind="i18n: 'From:'"></span>
</label>
<div class="control">
<input type="text"
id="gift-message-whole-from"
class="input-text"
data-bind="value: getObservable('sender')">
data-bind="value: getObservable('sender'), attr: { id: 'gift-message-whole-from-' + index }">
</div>
</div>
<div class="field text">
Expand All @@ -46,7 +44,6 @@
</div>
</div>
</fieldset>

</div>
</div>
<!-- /ko -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
$partners = $block->getPartners();
?>
<?php if ($partners) : ?>
<?php foreach ($block->getPartners() as $partner) : ?>
<?php foreach ($partners as $partner) : ?>
<div class="partner">
<img
class="partner-image"
Expand Down
2 changes: 2 additions & 0 deletions app/code/Magento/Multishipping/i18n/en_US.csv
Original file line number Diff line number Diff line change
Expand Up @@ -88,3 +88,5 @@ Options,Options
"Review Order","Review Order"
"Select Shipping Method","Select Shipping Method"
"We received your order!","We received your order!"
"Ship to:","Ship to:"
"Error:","Error:"
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ $orderIds = $block->getOrderIds();
<?php $shippingAddress = $block->getOrderShippingAddress($orderId); ?>
<div class="shipping-item">
<?php if ($shippingAddress) : ?>
<span class="shipping-label"><?= $block->escapeHtml('Ship to:'); ?></span>
<span class="shipping-label"><?= $block->escapeHtml(__('Ship to:')); ?></span>
<span class="shipping-address">
<?= $block->escapeHtml($block->formatOrderShippingAddress($shippingAddress)); ?>
</span>
Expand Down Expand Up @@ -65,7 +65,7 @@ $orderIds = $block->getOrderIds();
<dl class="shipping-item">
<dt class="shipping-block">
<?php if ($block->isShippingAddress($address)) : ?>
<span class="shipping-label"><?= $block->escapeHtml('Ship to:'); ?></span>
<span class="shipping-label"><?= $block->escapeHtml(__('Ship to:')); ?></span>
<span class="shipping-address">
<?= $block->escapeHtml($block->formatQuoteShippingAddress($address)); ?>
</span>
Expand All @@ -76,7 +76,7 @@ $orderIds = $block->getOrderIds();
<?php endif; ?>
</dt>
<dd class="error-block">
<span class="error-label"><?= $block->escapeHtml('Error:'); ?></span>
<span class="error-label"><?= $block->escapeHtml(__('Error:')); ?></span>
<span class="error-description">
<?= /* @noEscape */ $block->getAddressError($address); ?>
</span>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
<?php $shippingAddress = $block->getCheckoutData()->getOrderShippingAddress($orderId); ?>
<div class="shipping-item">
<?php if ($shippingAddress) : ?>
<span class="shipping-label"><?= $block->escapeHtml('Ship to:'); ?></span>
<span class="shipping-label"><?= $block->escapeHtml(__('Ship to:')); ?></span>
<span class="shipping-address">
<?= $block->escapeHtml(
$block->getCheckoutData()->formatOrderShippingAddress($shippingAddress)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ $ccExpMonth = $block->getInfoData('cc_exp_month');
name="payment[is_active_payment_token_enabler]"
class="admin__control-checkbox"/>
<label class="admin__field-label" for="<?= /* @noEscape */ $code ?>_vault">
<span><?= $block->escapeHtml('Save for later use.') ?></span>
<span><?= $block->escapeHtml(__('Save for later use.')) ?></span>
</label>
</div>
<?php endif; ?>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -123,10 +123,15 @@ protected function _beforeSave(\Magento\Framework\Model\AbstractModel $object)
{
/** @var \Magento\Sales\Model\AbstractModel $object */
if ($object instanceof EntityInterface && $object->getIncrementId() == null) {
$store = $object->getStore();
$storeId = $store->getId();
if ($storeId === null) {
$storeId = $store->getGroup()->getDefaultStoreId();
}
$object->setIncrementId(
$this->sequenceManager->getSequence(
$object->getEntityType(),
$object->getStore()->getGroup()->getDefaultStoreId()
$storeId
)->getNextValue()
);
}
Expand Down
3 changes: 2 additions & 1 deletion app/code/Magento/Search/view/frontend/web/form-mini.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ define([
this.autoComplete = $(this.options.destinationSelector);
this.searchForm = $(this.options.formSelector);
this.submitBtn = this.searchForm.find(this.options.submitBtn)[0];
this.searchLabel = $(this.options.searchLabel);
this.searchLabel = this.searchForm.find(this.options.searchLabel);
this.isExpandable = this.options.isExpandable;

_.bindAll(this, '_onKeyDown', '_onPropertyChange', '_onSubmit');
Expand Down Expand Up @@ -226,6 +226,7 @@ define([

case $.ui.keyCode.ENTER:
this.searchForm.trigger('submit');
e.preventDefault();
break;

case $.ui.keyCode.DOWN:
Expand Down
12 changes: 4 additions & 8 deletions app/code/Magento/Ui/view/base/web/js/form/adapter.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,12 @@
*/
define([
'jquery',
'underscore'
], function ($, _) {
'underscore',
'Magento_Ui/js/form/adapter/buttons'
], function ($, _, buttons) {
'use strict';

var buttons = {
'reset': '#reset',
'save': '#save',
'saveAndContinue': '#save_and_continue'
},
selectorPrefix = '',
var selectorPrefix = '',
eventPrefix;

/**
Expand Down
17 changes: 17 additions & 0 deletions app/code/Magento/Ui/view/base/web/js/form/adapter/buttons.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/

/**
* @api
*/
define(function () {
'use strict';

return {
'reset': '#reset',
'save': '#save',
'saveAndContinue': '#save_and_continue'
};
});
17 changes: 8 additions & 9 deletions app/code/Magento/UrlRewrite/view/adminhtml/templates/edit.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,13 @@
?>
<?= $block->getChildHtml() ?>
<?php if ($block->getChildBlock('form')): ?>
<script>
require([
'jquery',
'mage/backend/form',
'mage/backend/validation'
], function($){
$('#edit_form').form()
.validation({validationUrl: '<?= $block->escapeUrl($block->getValidationUrl()) ?>'});
});
<script type="text/x-magento-init">
{
"#edit_form": {
"Magento_UrlRewrite/js/url-rewrite-validation" : {
"url": "<?= $block->escapeUrl($block->getValidationUrl()) ?>"
}
}
}
</script>
<?php endif; ?>
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/

define([
'jquery',
'mage/backend/form',
'mage/backend/validation'
], function ($) {
'use strict';

return function (data, element) {

$(element).form().validation({
validationUrl: data.url
});
};
});
2 changes: 1 addition & 1 deletion app/code/Magento/Wishlist/CustomerData/Wishlist.php
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ protected function getItemData(\Magento\Wishlist\Model\Item $wishlistItem)
* Retrieve product image data
*
* @param \Magento\Catalog\Model\Product $product
* @return \Magento\Catalog\Block\Product\Image
* @return array
* @SuppressWarnings(PHPMD.NPathComplexity)
*/
protected function getImageData($product)
Expand Down
4 changes: 4 additions & 0 deletions lib/web/css/source/lib/_navigation.less
Original file line number Diff line number Diff line change
Expand Up @@ -305,6 +305,10 @@
.lib-css(border-top, none);
}

li.level1 {
position: relative;
}

.level0 {
.lib-css(margin, @_nav-level0-item-margin);
display: inline-block;
Expand Down
8 changes: 4 additions & 4 deletions pub/errors/default/report.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -36,25 +36,25 @@
</div>
<div class="field lastname required">
<label for="lastname" class="label">Last Name</label>
<div class=control">
<div class="control">
<input type="text" name="lastname" id="lastname" value="<?= $this->postData['lastName'] ?>" title="Last Name" class="required-entry input-text" />
</div>
</div>
<div class="field email required">
<label for="email_address" class="label">Email Address</label>
<div class=control">
<div class="control">
<input type="text" name="email" id="email_address" value="<?= $this->postData['email'] ?>" title="Email Address" class="validate-email required-entry input-text" />
</div>
</div>
<div class="field telephone">
<label for="telephone" class="label">Telephone</label>
<div class=control">
<div class="control">
<input type="text" name="telephone" id="telephone" value="<?= $this->postData['telephone'] ?>" title="Telephone" class="input-text" />
</div>
</div>
<div class="field comment">
<label for="comment" class="label">Comment</label>
<div class=control">
<div class="control">
<textarea name="comment" cols="5" rows="3" class="textarea"><?= $this->postData['comment'] ?></textarea>
</div>
</div>
Expand Down

0 comments on commit 0ad656d

Please sign in to comment.