Skip to content

Commit 7b831ff

Browse files
author
Momotenko,Natalia(nmomotenko)
committed
Merge pull request #226 from magento-webdev/PR
[WebDev] Bugfixes
2 parents bf4e733 + 00e4628 commit 7b831ff

File tree

10 files changed

+928
-899
lines changed

10 files changed

+928
-899
lines changed

app/code/Magento/Checkout/view/frontend/web/js/view/cart/totals.js

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,18 +2,31 @@
22
* Copyright © 2015 Magento. All rights reserved.
33
* See COPYING.txt for license details.
44
*/
5-
/*global define*/
65
define(
76
[
87
'uiComponent',
9-
'Magento_Checkout/js/model/totals'
8+
'Magento_Checkout/js/model/totals',
9+
'Magento_Checkout/js/model/shipping-service'
1010
],
11-
function (Component, totalsService) {
11+
function (Component, totalsService, shippingService) {
1212
'use strict';
1313

1414
return Component.extend({
1515

16-
isLoading: totalsService.isLoading
16+
isLoading: totalsService.isLoading,
17+
18+
/**
19+
* @override
20+
*/
21+
initialize: function () {
22+
this._super();
23+
totalsService.totals.subscribe(function () {
24+
window.dispatchEvent(new Event('resize'));
25+
});
26+
shippingService.getShippingRates().subscribe(function () {
27+
window.dispatchEvent(new Event('resize'));
28+
});
29+
}
1730
});
1831
}
1932
);

0 commit comments

Comments
 (0)