Openbravo Issue Tracking System - Retail Modules | |||||
View Issue Details | |||||
ID | Project | Category | View Status | Date Submitted | Last Update |
0031524 | Retail Modules | Web POS | public | 2015-11-18 14:11 | 2015-12-29 13:06 |
Reporter | malsasua | ||||
Assigned To | mario_castello | ||||
Priority | high | Severity | major | Reproducibility | always |
Status | closed | Resolution | fixed | ||
Platform | OS | 20 | OS Version | Community Appliance | |
Product Version | |||||
Target Version | Fixed in Version | RR16Q1 | |||
Merge Request Status | |||||
Review Assigned To | jorge-garcia | ||||
OBNetwork customer | OBPS | ||||
Support ticket | 39284 | ||||
Regression level | |||||
Regression date | |||||
Regression introduced in release | |||||
Regression introduced by commit | |||||
Triggers an Emergency Pack | No | ||||
Summary | 0031524: hook 'OBPOS_PreCustomerSave' is not working fine | ||||
Description | the hook OBPOS_PreCustomerSave is not working fine: . it is not possible to access to customer object . it is not possible to cancel | ||||
Steps To Reproduce | . add the next hook: OB.MobileApp.model.hookManager.registerHook('OBPOS_PreCustomerSave', function (args, callbacks) { // execute all your logic here debugger; }); | ||||
Proposed Solution | file: org.openbravo.retail.posterminal/js/pointofsale/view/subwindows/customers/components/sharedcomponents.js add propossed hooks (comments) saveCustomer: function (inSender, inEvent) { var me = this, sw = me.subWindow; function getCustomerValues(params) { me.waterfall('onSaveChange', { customer: params.customer }); } function goToViewWindow(sw, params) { if (sw.caller === 'mainSubWindow') { sw.doChangeSubWindow({ newWindow: { name: 'customerView', params: { navigateOnClose: 'mainSubWindow', businessPartner: params.customer } } }); } else { sw.doChangeSubWindow({ newWindow: { name: 'customerView', params: { navigateOnClose: 'customerAdvancedSearch', businessPartner: params.customer } } }); } } if (this.customer === undefined) { this.model.get('customer').newCustomer(); this.waterfall('onSaveChange', { customer: this.model.get('customer') }); this.adjustNames(this.model.get('customer')); //Hook here OBPOS_BeforeCustomerSave //arg1: customer: this.model.get('customer') //arg2: isNew: true //callback //if (args.cancelOperation) { // return //} var success = this.model.get('customer').saveCustomer(); if (success) { goToViewWindow(sw, { customer: OB.UTIL.clone(this.model.get('customer')) }); } } else { var that = this; this.model.get('customer').loadById(this.customer.get('id'), function (customer) { getCustomerValues({ customer: customer }); that.adjustNames(customer); //Hook here OBPOS_BeforeCustomerSave //arg1: customer: customer //arg2: isNew: false //callback //if (args.cancelOperation) { // return //} var success = customer.saveCustomer(); if (success) { goToViewWindow(sw, { customer: customer }); } }); } }, Propossed name for the hook: OBPOS_BeforeCustomerSave | ||||
Additional Information | |||||
Tags | No tags attached. | ||||
Relationships | |||||
Attached Files | |||||
Issue History | |||||
Date Modified | Username | Field | Change | ||
2015-11-18 14:11 | malsasua | New Issue | |||
2015-11-18 14:11 | malsasua | Assigned To | => Retail | ||
2015-11-18 14:11 | malsasua | OBNetwork customer | => Yes | ||
2015-11-18 14:11 | malsasua | Support ticket | => 39284 | ||
2015-11-18 14:11 | malsasua | Resolution time | => 1452121200 | ||
2015-11-18 14:11 | malsasua | Triggers an Emergency Pack | => No | ||
2015-11-18 14:12 | malsasua | Resolution time | 1452121200 => 1450566000 | ||
2015-11-18 22:34 | Orekaria | Note Added: 0081965 | |||
2015-11-18 22:34 | Orekaria | Status | new => feedback | ||
2015-11-18 22:35 | Orekaria | Note Edited: 0081965 | bug_revision_view_page.php?bugnote_id=0081965#r10274 | ||
2015-11-18 22:35 | Orekaria | Note Edited: 0081965 | bug_revision_view_page.php?bugnote_id=0081965#r10275 | ||
2015-12-07 12:27 | malsasua | Status | feedback => new | ||
2015-12-07 12:30 | Orekaria | Status | new => acknowledged | ||
2015-12-07 16:39 | guilleaer | Note Added: 0082599 | |||
2015-12-07 16:39 | guilleaer | Proposed Solution updated | |||
2015-12-12 18:07 | Orekaria | Summary | hook "OBPOS_PreCustomerSave" is not working fine => hook 'OBPOS_PreCustomerSave' is not working fine | ||
2015-12-14 16:23 | mario_castello | Assigned To | Retail => mario_castello | ||
2015-12-14 16:23 | mario_castello | Status | acknowledged => scheduled | ||
2015-12-19 02:54 | hgbot | Checkin | |||
2015-12-19 02:54 | hgbot | Note Added: 0082879 | |||
2015-12-19 06:47 | hgbot | Checkin | |||
2015-12-19 06:47 | hgbot | Note Added: 0082880 | |||
2015-12-19 06:47 | hgbot | Status | scheduled => resolved | ||
2015-12-19 06:47 | hgbot | Resolution | open => fixed | ||
2015-12-19 06:47 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/1578af5dacef7b5fa7fd1c14a3b422de55cf7a75 [^] | ||
2015-12-29 12:36 | jorge-garcia | Review Assigned To | => jorge-garcia | ||
2015-12-29 13:06 | jorge-garcia | Note Added: 0083046 | |||
2015-12-29 13:06 | jorge-garcia | Status | resolved => closed | ||
2015-12-29 13:06 | jorge-garcia | Fixed in Version | => RR16Q1 |
Notes | |||||
|
|||||
|
|
||||
|
|||||
|
|
||||
|
|||||
|
|
||||
|
|||||
|
|
||||
|
|||||
|
|