Units view custom y-axis


I have a scheduler page with units view enabled .
If I need to customize the units view Y-axis like attached image (please find the attached image unitsview.png ). ( in y axis instead of time I have to make serial numbering )

I tried this code , but its regenerating the serial numbers automatically.

intTockenNumber = 10;
        scheduler.templates.hour_scale = function(date){
                for (var i=0; i<60/timIntervel; i++){
                        html+="<div style='height:44px;line-height:44px;'>"+intTockenNumber++ +"</div>";
                        date = scheduler.date.add(date,timIntervel,"minute");
                return html;

please suggest me how put serial numbers in units view Y-axis (units view itself) .

Any suggestion will be helpful :slight_smile:

Thank you :slight_smile:


Try using this sample:

Hi Polina ,

Thanks for the suggestion :slight_smile: , but unfortunately its not working :frowning:

Please open firebug or any inspect tool and close it from the example that you have provided , it will change the hour scale to default(time in y-axis) . its automatically resetting in many other cases .
can you suggest me the event that when its changing , if I know that event i can reset the global variable intTockenNumber to 1 form that event .
ie - >

scheduler.attachEvent("onBeforeViewChange", function(old_mode,old_date,mode,date){ intTockenNumber = 1; alert("gg"); return true; });

some other event other than “onBeforeViewChange” is happening when we resize the window or opening the inspect toll from the browser , can you please suggest me that event .

Thank you :slight_smile:


scheduler.config.update_render = true;

I saw this in your documentation , is there any event to detect the scheduler repainting the view . am I going through the right path based on my issue ?

Please suggest me regarding this .

thank you :slight_smile:


This sample could help to solve your problem:


That code worked for me :slight_smile: thank you for your advice .

But the same code does not working in the code snippet that you have provided.
I’m getting an issues while opening the firebug or any other inspect tool . when its opened, suddenly the custom y-axis changing to the default view (Time in y-axis) .

please check this issue :wink:

Thank you :slight_smile:


Code in snippet is working correctly. Next line changes time view in y-axis:

return scheduler.date.date_to_str(scheduler.config.hour_date)(date);

You could set any other view, that you need.