Answer the question
In order to leave comments, you need to log in
How to make custom error handler in sale.order.ajax.js?
Hello. I'm doing checkbox processing in checkout. sale.order.ajax.
I use the article
https://mit24.ru/articles/gotovim-shtatnoe-oformle...
Only I have a little different
initAdditionalOptions: function() {
var fz = BX('mitFZ');
this.controlAdditionalOptions();
BX.bind(fz, 'change', BX.proxy(this.controlAdditionalOptions, this));
},
controlAdditionalOptions: function() {
var fz = BX('mitFZ');
if (fz.checked == true) {
BX.bind(this.orderSaveBlockNode.querySelector('a'), 'click', BX.proxy(this.clickOrderSaveAction, this));
BX.bind(this.totalBlockNode.querySelector('a'), 'click', BX.proxy(this.clickOrderSaveAction, this));
BX.bind(this.mobileTotalBlockNode.querySelector('a'), 'click', BX.proxy(this.clickOrderSaveAction, this));
BX.bind(this.totalInfoBlockNode.querySelector('a'), 'click', BX.proxy(this.clickOrderSaveAction, this));
}
else {
BX.unbind(this.orderSaveBlockNode.querySelector('a'), 'click', BX.proxy(this.clickOrderSaveAction, this));
BX.unbind(this.totalBlockNode.querySelector('a'), 'click', BX.proxy(this.clickOrderSaveAction, this));
BX.unbind(this.mobileTotalBlockNode.querySelector('a'), 'click', BX.proxy(this.clickOrderSaveAction, this));
BX.unbind(this.totalInfoBlockNode.querySelector('a'), 'click', BX.proxy(this.clickOrderSaveAction, this));
}
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question