Scheduler Hotel Tutorial

Greetings,

I have been going through the scheduler hotel tutorial

http://scheduler-net.com/docs/hotel-room-booking-tutorial.html

I am having difficulties reducing the timespan of the view to 7 days. It is my understanding that i must change the value of timeline.X_size = 7

But whatever value i put in it always results in the view showing a full month of days.

Any help would be greatly appreciated

Hi,
in this demo number of columns in timeline is dynamically overriden by a client-side code, since months have different number of days.
So in order to disable it and use X_Size config in regular way, you need to rid of this code block screencast.com/t/7Fqyc06Rz

thanks for your reply.

i removed the code block and tested again but it is still showing a full month regardless of x_size

Please attach a demo. Timeline scale configuration may come either from server side config (X_Size, etc) or from client side (scheduler.matrix.Timeline.x_size), seems like one of these is overriden somewhere in your project

here is a link to a demo

https://www.dropbox.com/s/cji9nrfyh31ckgd/HotelRoomBooking.zip?dl=0

it is exactly the same as the tutorial downloaded, except x_size is changed and the other method you refered to earlier has also been commented out.

thanks

Hi,
make sure that JS file is not cached in browser, the simplest way is to add some parameter to script url:[code]

[/code]
When I run it locally the timeline shows 7 days as expected.
One thing you may want to change, is to make sure that timeline shows days starting from Monday,
js:scheduler.date.Timeline_start = scheduler.date.week_start;

Thanks alot Aliaksandr, that was the problem all along hehe