Skip to content

Commit

Permalink
Adding default checkout type as Modal and Fix for jquery ui library c… (
Browse files Browse the repository at this point in the history
#44)

* Adding default checkout type as Modal and Fix for jquery ui library changes

* Removing unused module dependency
  • Loading branch information
nandadubey authored Jul 30, 2020
1 parent d43353e commit 4776ae5
Show file tree
Hide file tree
Showing 10 changed files with 13 additions and 12 deletions.
2 changes: 1 addition & 1 deletion Block/System/Config/Form/Field/Date.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ protected function _getElementHtml(\Magento\Framework\Data\Form\Element\Abstract
$this->_coreRegistry->registry('datepicker_loaded', 1);
}
$html .= '<script type="text/javascript">
require(["jquery", "jquery/ui"], function () {
require(["jquery"], function () {
jQuery(document).ready(function () {
jQuery("#' . $element->getHtmlId() . '").datepicker( { dateFormat: "mm/dd/yy" } );
var el = document.getElementById("' . $element->getHtmlId() . '");
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "affirm/magento2",
"description": "Affirm's extension for the Magento 2 https://www.affirm.com/",
"type": "magento2-module",
"version": "3.0.3",
"version": "3.0.4",
"license": [
"BSD-3-Clause"
],
Expand Down
1 change: 1 addition & 0 deletions etc/config.xml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
<enable_checkout_button>0</enable_checkout_button>
<checkout_button_code>https://cdn-assets.affirm.com/images/buttons/30_148-white.png</checkout_button_code>
<checkout_button_width>148</checkout_button_width>
<checkout_flow_type>Modal</checkout_flow_type>
<notification>
<notification_update>1</notification_update>
</notification>
Expand Down
2 changes: 1 addition & 1 deletion etc/module.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
*/
-->
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Module/etc/module.xsd">
<module name="Astound_Affirm" setup_version="3.0.3">
<module name="Astound_Affirm" setup_version="3.0.4">
<sequence>
<module name="Magento_Checkout"/>
<module name="Magento_Sales"/>
Expand Down
4 changes: 2 additions & 2 deletions view/frontend/templates/pixel/code.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ if ($action == 'catalog_product_view' && $block->isProductViewTrackPixelEnabled(
if($block->isAddCartTrackPixelEnabled()){
?>
<script>
require(['jquery', 'jquery/ui'],function($){
require(['jquery', 'jquery-ui-modules/widget'],function($){

$('#product-addtocart-button').click(function () {

Expand Down Expand Up @@ -191,4 +191,4 @@ $serializedPixelCode = $this->helper('Magento\Framework\Json\Helper\Data')->json
}
}
</script>
<!-- END AFFIRM ANALYTICS CODE -->
<!-- END AFFIRM ANALYTICS CODE -->
4 changes: 2 additions & 2 deletions view/frontend/web/js/affirmPixel.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
define([
"jquery",
"Astound_Affirm/js/model/aslowas",
"jquery/ui"
"jquery-ui-modules/widget"
], function ($, aslowas) {
"use strict"

Expand Down Expand Up @@ -77,4 +77,4 @@ define([
});

return $.mage.affirmPixel
});;
});;
4 changes: 2 additions & 2 deletions view/frontend/web/js/affirmWidget.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
define([
"jquery",
"Astound_Affirm/js/model/aslowas",
"jquery/ui"
"jquery-ui-modules/widget"
], function ($, aslowas) {

"use strict"
Expand Down Expand Up @@ -51,4 +51,4 @@ define([
});

return $.mage.affirmWidget
});
});
2 changes: 1 addition & 1 deletion view/frontend/web/js/aslowasPDP.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
define(["jquery",
"mage/translate",
"Astound_Affirm/js/model/aslowas",
"jquery/ui"
"jquery-ui-modules/widget"
], function ($, $t, aslowas) {

"use strict"
Expand Down
2 changes: 1 addition & 1 deletion view/frontend/web/js/aslowasPLP.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
define(["jquery",
"mage/translate",
"Astound_Affirm/js/model/aslowas",
"jquery/ui"
"jquery-ui-modules/widget"
], function ($, $t, aslowas) {

"use strict"
Expand Down
2 changes: 1 addition & 1 deletion view/frontend/web/js/model/global.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
define([
"jquery",
"mage/translate",
"jquery/ui"
"jquery-ui-modules/widget"
],
function ($, $t) {
'use strict';
Expand Down

0 comments on commit 4776ae5

Please sign in to comment.