[DEV] Board Service, Wizard refact, hotes services configuration, services lines by day

This commit is contained in:
Dario Lodeiros
2018-11-06 10:18:23 +01:00
parent 15a7e3ae7e
commit d485968d78
27 changed files with 326 additions and 99 deletions

View File

@@ -0,0 +1,28 @@
// Copyright 2018 Alexandre Díaz <dev@redneboa.es>
// License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
odoo.define('hotel_calendar.listview_button_open_reservation_wizard', function(require) {
'use strict';
var ListView = require('web.ListView'),
Core = require('web.core'),
_t = Core._t;
ListView.include({
render_buttons: function () {
var self = this;
this._super.apply(this, arguments); // Sets this.$buttons
if (this.dataset.model == 'hotel.reservation') {
this.$buttons.append("<button class='oe_button oe_open_reservation_wizard oe_highlight' type='button'>"+_t('Open Wizard')+"</button>");
this.$buttons.find('.oe_open_reservation_wizard').on('click', function(){
self.do_action('hotel_calendar.open_wizard_reservations');
});
}
}
});
return ListView;
});