// // Copyright (c) 2005, Michael Schwarz. (http://www.schwarz-interactive.de/) // All rights reserved. // var engAdminPort = { addNewPort:function(Controls,callback){return ajax_request(this.url + '?_method=addNewPort','Controls=' + enc(Controls),callback);}, checkPortExists:function(portName,countryID,callback){return ajax_request(this.url + '?_method=checkPortExists','portName=' + enc(portName)+ '&countryID=' + enc(countryID),callback);}, editPort:function(portID,Controls,callback){return ajax_request(this.url + '?_method=editPort','portID=' + enc(portID)+ '&Controls=' + enc(Controls),callback);}, getPortsByName:function(searchText,controlName,callback){return ajax_request(this.url + '?_method=getPortsByName','searchText=' + enc(searchText)+ '&controlName=' + enc(controlName),callback);}, getPortsForDropDowns:function(callback){return ajax_request(this.url + '?_method=getPortsForDropDowns','',callback);}, populatePortEdit:function(PortID,callback){return ajax_request(this.url + '?_method=populatePortEdit','PortID=' + enc(PortID),callback);}, url:'/ajax/StrandTravel.engAdminPort,StrandTravel.ashx' } // // IAjaxObjectConverter Client Scripts // function digi(v, c){v = v + "";var n = "0000";if(v.length < c) return n.substr(0, c-v.length) + v;return v;} function DateTime(year,month,day,hours,minutes,seconds) { if(year>9999||year<1970||month<1||month>12||day<0||day>31||hours<0||hours>23||minutes<0||minutes>59||seconds<0||seconds>59)throw("ArgumentException"); this.Year = year;this.Month = month;this.Day = day;this.Hours = hours;this.Minutes = minutes;this.Seconds = seconds; } DateTime.prototype.toString = function() { return digi(this.Year,4) + digi(this.Month,2) + digi(this.Day,2) + digi(this.Hours,2) + digi(this.Minutes,2) + digi(this.Seconds,2); }