|
@@ -16,12 +16,25 @@ openerp.eiru_payslip_payments = function(instance, local) {
|
|
|
|
|
|
init: function(parent) {
|
|
|
this._super(parent);
|
|
|
+ this.buttons = parent.$buttons;
|
|
|
},
|
|
|
start: function() {
|
|
|
var self = this;
|
|
|
this.$el.click(function(){
|
|
|
self.fectchInitial()
|
|
|
});
|
|
|
+
|
|
|
+ self.buttons.click(function(e) {
|
|
|
+ /* E (Editar) */
|
|
|
+ if (e.target.accessKey === 'E')
|
|
|
+ self.$el.css('display','none');
|
|
|
+ /* S (Guarrdar) */
|
|
|
+ if (e.target.accessKey === 'S')
|
|
|
+ self.$el.css('display','flex');
|
|
|
+ /* D (Cancelar) */
|
|
|
+ if (e.target.accessKey === 'D')
|
|
|
+ self.$el.css('display','flex');
|
|
|
+ });
|
|
|
},
|
|
|
updateId: function(id) {
|
|
|
var self = this;
|
|
@@ -328,7 +341,7 @@ openerp.eiru_payslip_payments = function(instance, local) {
|
|
|
|
|
|
local.widgetInstance.appendTo(elemento);
|
|
|
local.widgetInstance.updateId(record.id);
|
|
|
- }
|
|
|
+ },
|
|
|
});
|
|
|
}
|
|
|
|