Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

generar 2 mapas de asientos sin separar #82

Open
criszalo1997 opened this issue Nov 19, 2019 · 0 comments
Open

generar 2 mapas de asientos sin separar #82

criszalo1997 opened this issue Nov 19, 2019 · 0 comments

Comments

@criszalo1997
Copy link

criszalo1997 commented Nov 19, 2019

hola estoy intentando hacer un sistema de boletaje para buses utlize su librería para los asientos de los buses enserio es genial

funciona bien pero no puedo generar dos mapas de asientos separados para los buses de 2 pisos similar a esta imagen
https://i.stack.imgur.com/jF1Uv.jpg

quisiera generar dos mapas de asientos sin inicializar 2 veces la funcion seatCharts()

var sc = $('#seat-map').seatCharts({
    map: [
        'aaaaaaaaaaaa',
        'aaaaaaaaaaaa',
        'bbbbbbbbbb__',
        'bbbbbbbbbb__',
        'bbbbbbbbbbbb',
        'cccccccccccc'
    ],
    seats: {
        a: {
            price   : 99.99,
            classes : 'front-seat' //your custom CSS class
        }

    },
    click: function () {
        if (this.status() == 'available') {
            //do some stuff, i.e. add to the cart
            return 'selected';
        } else if (this.status() == 'selected') {
            //seat has been vacated
            return 'available';
        } else if (this.status() == 'unavailable') {
            //seat has been already booked
            return 'unavailable';
        } else {
            return this.style();
        }
    }
});

espero su ayuda y de antemano gracias!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant