|
@@ -11,7 +11,6 @@ openerp.eiru_purchase_to_sale = function (instance, local) {
|
|
init:function(parent){
|
|
init:function(parent){
|
|
this._super(parent);
|
|
this._super(parent);
|
|
this.buttons = parent.$buttons;
|
|
this.buttons = parent.$buttons;
|
|
-
|
|
|
|
},
|
|
},
|
|
|
|
|
|
updateId : function(id){
|
|
updateId : function(id){
|
|
@@ -25,9 +24,26 @@ openerp.eiru_purchase_to_sale = function (instance, local) {
|
|
|
|
|
|
start: function () {
|
|
start: function () {
|
|
var self = this;
|
|
var self = this;
|
|
|
|
+
|
|
this.$el.click(function () {
|
|
this.$el.click(function () {
|
|
self.fecthInitial();
|
|
self.fecthInitial();
|
|
});
|
|
});
|
|
|
|
+
|
|
|
|
+ self.buttons.click(function(e) {
|
|
|
|
+ /* C (Crear) */
|
|
|
|
+ if (e.target.accessKey === 'C'){
|
|
|
|
+ self.$el.css('display','none');
|
|
|
|
+ }
|
|
|
|
+ /* E (Editar) */
|
|
|
|
+ if (e.target.accessKey === 'E')
|
|
|
|
+ self.$el.css('display','none');
|
|
|
|
+ /* S (Guardar) */
|
|
|
|
+ if (e.target.accessKey === 'S')
|
|
|
|
+ self.$el.css('display','flex');
|
|
|
|
+ /* D (Cancelar) */
|
|
|
|
+ if (e.target.accessKey === 'D')
|
|
|
|
+ self.$el.css('display','flex');
|
|
|
|
+ });
|
|
},
|
|
},
|
|
|
|
|
|
fecthInitial: function(){
|
|
fecthInitial: function(){
|
|
@@ -161,7 +177,6 @@ openerp.eiru_purchase_to_sale = function (instance, local) {
|
|
self.reloadLine();
|
|
self.reloadLine();
|
|
});
|
|
});
|
|
}
|
|
}
|
|
- // console.log(data);
|
|
|
|
},
|
|
},
|
|
|
|
|
|
joinSaleLine: function(data) {
|
|
joinSaleLine: function(data) {
|