How to add parameter in scheduler._on_mouse_up=function(e){

Hi all,
i want to add parameter, exactly a field on database. Ex : i have a database named “rent_car” with table name : “car_detail” and there is a field named “manufacturer”

Here is the code : (file name : dhtmlxscheduler.js)

[code]scheduler._on_mouse_up=function(e){
if (e && e.button == 2 && scheduler.config.touch) return; //Asal nge-lepas Klik

	if (this._drag_mode && this._drag_id){    //Lepas Klik setelah drag drop
		this._els["dhx_cal_data"][0].style.cursor="default";
		var ev=this.getEvent(this._drag_id);
		var resourceId = ev.resource_id;

			if (this._drag_event._dhx_changed || !this._drag_event.start_date || ev.start_date.valueOf()!=this._drag_event.start_date.valueOf() || ev.end_date.valueOf()!=this._drag_event.end_date.valueOf()){
				var is_new = (this._drag_mode=="new-size");
				var ababa = (this._drag_event.id == 8);
				alert("akkak")

// onBeforeEventChanged is fires when the event has been changed by drag-n-drop, but the changes aren’t saved yet.
if (!this.callEvent(“onBeforeEventChanged”,[ev, e, is_new, ababa])) {
alert(“Maaf. resource untuk waktu yang anda pilih tidak bisa dipesan.”)
if (is_new)
this.deleteEvent(ev.id, true);
else {
this._drag_event._dhx_changed = false;
scheduler._lame_copy(ev, this._drag_event);
this.updateEvent(ev.id);
}
} else {
var drag_id = this._drag_id;
this._drag_id = this._drag_mode = null;
if (is_new && this.config.edit_on_create){
this.unselect();
this._new_event=new Date();//timestamp of creation
//if selection disabled - force lightbox usage
if (this._table_view || this.config.details_on_create || !this.config.select) {
return this.showLightbox(drag_id);
}
this._drag_pos = true; //set flag to trigger full redraw
this._select_id = this._edit_id = drag_id;
} else {
if (!this._new_event)
this.callEvent(is_new?“onEventAdded”:“onEventChanged”,[drag_id,this.getEvent(drag_id)]);
}
}
}
if (this._drag_pos) this.render_view_data(); //redraw even if there is no real changes - necessary for correct positioning item after drag
}
this._drag_id = null;
this._drag_mode=null;
this._drag_pos=null;
};[/code]

any help and solution would be greatly appreciated.

i want to add a parameter in that code.
like : if (car name = toyota)
alert “You cant Book Toyota”

Hello,
if you want to add some validation for user actions, you don’t need to overwrite inner methods for this.
Please check these API events,
docs.dhtmlx.com/scheduler/api__s … event.html
docs.dhtmlx.com/scheduler/api__s … event.html
docs.dhtmlx.com/scheduler/api__r … duler.html