diff --git a/GanttChartHyperLibraryDemos/Demos/Demos.csproj b/GanttChartHyperLibraryDemos/Demos/Demos.csproj
index 5edcc4f4e..51bb60e1f 100644
--- a/GanttChartHyperLibraryDemos/Demos/Demos.csproj
+++ b/GanttChartHyperLibraryDemos/Demos/Demos.csproj
@@ -454,6 +454,46 @@
j&&(j=Math[_0x5c25[15]](2,32)-j);q=j.toString(16)[_0x5c25[16]]();r=o[_0x5c25[12]](r+1);if(q==r)return!0}return!1},x=function(g,o,r,q,j){var s=_0x5c25[17],k=_0x5c25[18],p=typeof ComponentSource===l||!ComponentSource?k+_0x5c25[19]+q+_0x5c25[20]+j:_0x5c25[21],c=q+_0x5c25[22]+j+_0x5c25[23],a=_0x5c25[24],b=_0x5c25[25],d=_0x5c25[26];setTimeout(function(){var f=g[_0x5c25[27]],e=f[_0x5c25[29]](_0x5c25[28]);e[_0x5c25[32]](_0x5c25[30],_0x5c25[31]);var h=f[_0x5c25[29]](_0x5c25[28]);h[_0x5c25[32]](_0x5c25[30], +_0x5c25[33]);var m=f[_0x5c25[29]](_0x5c25[28]);m[_0x5c25[32]](_0x5c25[30],_0x5c25[34]);h[_0x5c25[35]](m);m[_0x5c25[35]](f[_0x5c25[36]](s));h[_0x5c25[35]](f[_0x5c25[36]](a+_0x5c25[10]));m=f[_0x5c25[29]](_0x5c25[28]);m[_0x5c25[32]](_0x5c25[30],_0x5c25[37]);m[_0x5c25[35]](f[_0x5c25[36]](o));h[_0x5c25[35]](m);h[_0x5c25[35]](f[_0x5c25[36]](b+_0x5c25[10]));m=f[_0x5c25[29]](_0x5c25[28]);m[_0x5c25[32]](_0x5c25[30],_0x5c25[37]);m[_0x5c25[35]](f[_0x5c25[36]](c));h[_0x5c25[35]](m);h[_0x5c25[35]](f[_0x5c25[36]](d+ +_0x5c25[10]));m=f[_0x5c25[29]](_0x5c25[28]);m[_0x5c25[32]](_0x5c25[30],_0x5c25[38]);var n=f[_0x5c25[29]](_0x5c25[39]);n[_0x5c25[32]](_0x5c25[30],_0x5c25[40]);n[_0x5c25[32]](_0x5c25[41],p);n[_0x5c25[32]](_0x5c25[42],_0x5c25[43]);n[_0x5c25[35]](f[_0x5c25[36]](_0x5c25[44]));m[_0x5c25[35]](n);n=f[_0x5c25[29]](_0x5c25[39]);n[_0x5c25[32]](_0x5c25[30],_0x5c25[45]);n[_0x5c25[32]](_0x5c25[41],_0x5c25[46]);n[_0x5c25[35]](f[_0x5c25[36]](_0x5c25[47]));n[_0x5c25[50]](_0x5c25[48],function(){g[_0x5c25[49]](e);u[_0x5c25[7]](r)}, +!1);m[_0x5c25[35]](n);h[_0x5c25[35]](m);e[_0x5c25[35]](h);g[_0x5c25[35]](e)},0);setTimeout(function(){alert(s+_0x5c25[51]+a+_0x5c25[52]+o+_0x5c25[51]+b+_0x5c25[53]+c+_0x5c25[51]+d+_0x5c25[4])},6E5)};return{setLicense:function(g,l){t[_0x5c25[7]]({type:g,content:l})},validate:function(v,o,r,q,j,s,k){for(var o=o+_0x5c25[4]+r,p=0;pDlhSoft.buildReleaseDate?l:DlhSoft.buildReleaseDate}(2015,5,8);_0x5c25="Licensing{undefined{string{DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.{.{length{license{push{type{content{:{lastIndexOf{substr{buildReleaseDate{charCodeAt{pow{toUpperCase{DlhSoft Component Licensing Warning{http://DlhSoft.com/Purchase.aspx{?Assemblies={,{http://www.componentsource.com/features/dlhsoft{ (version {){This component is currently licensed to be used for testing purposes only{The component is part of this assembly{To purchase a standard license for a product that includes this assembly you can use the Purchase page{ownerDocument{div{createElement{style{position: absolute; left: 24px; top: 24px; width: 480px; display: block; z-index: 1; color: Black; background-color: #ffffc0; border: solid 1px Blue; overflow: auto{setAttribute{padding: 6px; padding-top: 8px; font-family: Arial; font-size: small{font-weight: bold; margin-bottom: 4px{appendChild{createTextNode{color: Red; margin-top: 2px; margin-bottom: 2px{margin-top: 4px{a{color: Blue; text-decoration: underline{href{target{_blank{Purchase license{margin-left: 4px; color: Blue; text-decoration: underline{javascript://{Continue trial{click{removeChild{addEventListener{\n\n{: {:\n".split("{"); +void 0==DlhSoft[_0x5c25[0]]&&(DlhSoft[_0x5c25[0]]=function(){var l=_0x5c25[1],g=_0x5c25[2],t=[],u=[],A=_0x5c25[3],z=function(v,o){if(typeof v!==g||typeof o!==g)return!1;if(o==A)return!0;var r=o[_0x5c25[11]](_0x5c25[10]);if(0<=r){var q=o[_0x5c25[12]](0,r),j,s=q[_0x5c25[11]](_0x5c25[10]);if(0<=s)try{j=new Date(parseInt(q[_0x5c25[12]](s+1)))}catch(k){}typeof j===l&&(j=new Date(2013,11,31));if(DlhSoft[_0x5c25[13]]>j)return!1;q=q+_0x5c25[10]+v;for(i=j=0;ij&&(j=Math[_0x5c25[15]](2,32)-j);q=j.toString(16)[_0x5c25[16]]();r=o[_0x5c25[12]](r+1);if(q==r)return!0}return!1},x=function(g,o,r,q,j){var s=_0x5c25[17],k=_0x5c25[18],p=typeof ComponentSource===l||!ComponentSource?k+_0x5c25[19]+q+_0x5c25[20]+j:_0x5c25[21],c=q+_0x5c25[22]+j+_0x5c25[23],a=_0x5c25[24],b=_0x5c25[25],d=_0x5c25[26];setTimeout(function(){var f=g[_0x5c25[27]],e=f[_0x5c25[29]](_0x5c25[28]);e[_0x5c25[32]](_0x5c25[30],_0x5c25[31]);var h=f[_0x5c25[29]](_0x5c25[28]);h[_0x5c25[32]](_0x5c25[30], +_0x5c25[33]);var m=f[_0x5c25[29]](_0x5c25[28]);m[_0x5c25[32]](_0x5c25[30],_0x5c25[34]);h[_0x5c25[35]](m);m[_0x5c25[35]](f[_0x5c25[36]](s));h[_0x5c25[35]](f[_0x5c25[36]](a+_0x5c25[10]));m=f[_0x5c25[29]](_0x5c25[28]);m[_0x5c25[32]](_0x5c25[30],_0x5c25[37]);m[_0x5c25[35]](f[_0x5c25[36]](o));h[_0x5c25[35]](m);h[_0x5c25[35]](f[_0x5c25[36]](b+_0x5c25[10]));m=f[_0x5c25[29]](_0x5c25[28]);m[_0x5c25[32]](_0x5c25[30],_0x5c25[37]);m[_0x5c25[35]](f[_0x5c25[36]](c));h[_0x5c25[35]](m);h[_0x5c25[35]](f[_0x5c25[36]](d+ +_0x5c25[10]));m=f[_0x5c25[29]](_0x5c25[28]);m[_0x5c25[32]](_0x5c25[30],_0x5c25[38]);var n=f[_0x5c25[29]](_0x5c25[39]);n[_0x5c25[32]](_0x5c25[30],_0x5c25[40]);n[_0x5c25[32]](_0x5c25[41],p);n[_0x5c25[32]](_0x5c25[42],_0x5c25[43]);n[_0x5c25[35]](f[_0x5c25[36]](_0x5c25[44]));m[_0x5c25[35]](n);n=f[_0x5c25[29]](_0x5c25[39]);n[_0x5c25[32]](_0x5c25[30],_0x5c25[45]);n[_0x5c25[32]](_0x5c25[41],_0x5c25[46]);n[_0x5c25[35]](f[_0x5c25[36]](_0x5c25[47]));n[_0x5c25[50]](_0x5c25[48],function(){g[_0x5c25[49]](e);u[_0x5c25[7]](r)}, +!1);m[_0x5c25[35]](n);h[_0x5c25[35]](m);e[_0x5c25[35]](h);g[_0x5c25[35]](e)},0);setTimeout(function(){alert(s+_0x5c25[51]+a+_0x5c25[52]+o+_0x5c25[51]+b+_0x5c25[53]+c+_0x5c25[51]+d+_0x5c25[4])},6E5)};return{setLicense:function(g,l){t[_0x5c25[7]]({type:g,content:l})},validate:function(v,o,r,q,j,s,k){for(var o=o+_0x5c25[4]+r,p=0;p=a.rows&&(a.rows=1);"undefined"=== +typeof a.columns?a.columns=3:0>=a.columns&&(a.columns=1);"undefined"===typeof a.headerProvider&&(a.headerProvider=function(b,d){return b.createTextNode(d!=null?d.toString()+" - "+(d+a.rows*a.columns-1).toString():"?")});"undefined"===typeof a.headerStyle&&(a.headerStyle="color: "+("Modern"==a.theme?"#505050":"Black")+"; background-color: #f0f0f0; padding: 8px; font-size: "+("Modern"==a.theme?"12px":"small")+"; text-align: center; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; cursor: default"); +"undefined"===typeof a.timeStyle&&(a.timeStyle="color: "+("Modern"==a.theme?"#505050":"Black")+"; min-width: "+Math.max(128/a.columns,64)+"px; height: "+Math.max(80/a.rows,20)+"px; padding: 2px; text-align: center; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; cursor: default; font-size: "+("Modern"==a.theme?"12px":"small"));"undefined"===typeof a.selectedTimeStyle&&(a.selectedTimeStyle="background-color: #3399ff; color: White; padding: 2px");"undefined"=== +typeof a.timeFormatter&&(a.timeFormatter=function(a){return a.toString()});"undefined"===typeof a.invertMatrix&&(a.invertMatrix=!1);"undefined"===typeof a.minValue&&(a.minValue=0);"undefined"===typeof a.scrollingHeight&&(a.scrollingHeight="auto")};c.prototype.refresh=function(){for(var a=this,b=this.host.ownerDocument,d=this.host.childNodes.length;0a.monthRows&&(a.monthRows=1);"undefined"===typeof a.monthColumns&&(a.monthColumns=1);1>a.monthColumns&&(a.monthColumns=1);"undefined"===typeof a.monthCellSpacing&&(a.monthCellSpacing="0");"undefined"=== +typeof a.applyMonthStyleForSingleCell&&(a.applyMonthStyleForSingleCell=!1);"undefined"===typeof a.applyNextMonthButtonToLastColumn&&(a.applyNextMonthButtonToLastColumn=!0);"undefined"===typeof a.applyNextMonthButtonToLastRow&&(a.applyNextMonthButtonToLastRow=!1);"undefined"===typeof a.containerStyle&&(a.containerStyle=("Modern"==a.theme?"":"border: 1px solid #707070; ")+"font-family: Arial"+("undefined"===typeof a.monthCellStyle&&(1 =c.dayDuration&&(h=c.subtractDay(h));f=h;for(var m=0;m this.settings.calendarSelectorLevels|| +0 a.settings.calendarSelectorLevels)return c;var e=b.createElement("a");e.setAttribute("href","javascript://");e.setAttribute("style","text-decoration: none; display: inline-block; cursor: pointer; color: inherit"); +e.appendChild(c);var h=b.createElement("div");h.setAttribute("style","display: none; position: absolute; margin-left: -10px");e.appendChild(h);var m=b.createElement("div");m.setAttribute("style",a.settings.calendarSelectorPopupStyle);a.settings.calendarSelectorPopupClass&&m.setAttribute("class",a.settings.calendarSelectorPopupClass);h.appendChild(m);e.onclick=function(b){if((b.target||b.srcElement)==e){if("none"!=h.style.display)h.style.display="none";else{var c=Math.floor(d/12)-1;h.style.display= +"block";var g=z.initialize(m,c,{rows:5,columns:2,invertMatrix:!0,headerProvider:function(b,d){var c=b.createTextNode((d+1).toString()+" - "+(d+10).toString());if(3>a.settings.calendarSelectorLevels)return c;var e=b.createElement("a");e.setAttribute("href","javascript://");e.setAttribute("style","text-decoration: none; display: inline-block; cursor: pointer; color: inherit");e.appendChild(c);var f=b.createElement("div");f.setAttribute("style","display: none; position: absolute; margin-left: -10px"); +e.appendChild(f);var h=b.createElement("div");h.setAttribute("style",a.settings.calendarSelectorPopupStyle);a.settings.calendarSelectorPopupClass&&h.setAttribute("class",a.settings.calendarSelectorPopupClass);f.appendChild(h);e.onclick=function(a){if((a.target||a.srcElement)==e){if("none"!=f.style.display)f.style.display="none";else{var b=Math.floor(d/10);f.style.display="block";z.initialize(h,b,{rows:5,columns:2,invertMatrix:!0,headerProvider:function(a,b){return a.createTextNode((10*b+1).toString()+ +" - "+(10*(b+10)).toString())},timeFormatter:function(a){return(10*a+1).toString()+"-"+(10*a+10).toString().substr((10*a+10).toString().length-2)},minValue:10},"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.").settings.selectedTimeChangeHandler=function(a){g.setDisplayedValue(10*a)}}a.stopPropagation()}};return e},timeFormatter:function(a){return(a+1).toString()},minValue:100},"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase."); +g.settings.selectedTimeChangeHandler=function(a){f.setDisplayedValue(12*(a+1))}}b.stopPropagation()}};return e},timeFormatter:function(b){return a.settings.months[b-12*Math.floor(b/12)]},minValue:1212};q.style.display="block";var f=z.initialize(s,d,c,"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.");f.settings.selectedTimeChangeHandler=function(b){a.setDisplayedValue(new Date(Math.floor(b/12),b-12*Math.floor(b/ +12),1))}}b.stopPropagation()}}}l.appendChild(j);e.appendChild(l);l=b.createElement("td");l.setAttribute("style","text-align: right; padding-right: 4px");if((!this.settings.applyNextMonthButtonToLastRow?0==m:m==this.settings.monthRows-1)&&(this.settings.applyNextMonthButtonToLastColumn?g==this.settings.monthColumns-1:0==g))j=b.createElement("a"),j.setAttribute("href","javascript://"),j.setAttribute("style","text-decoration: none; color: Gray; font-size: "+("Modern"==this.settings.theme?"10px":"x-small")+ +"; cursor: pointer"),j.appendChild(b.createTextNode("\u25ba")),j.onclick=function(b){for(var d=h;d.getMonth()==h.getMonth();)d=c.addDay(d);a.setDisplayedValue(d);b.stopPropagation()},l.appendChild(j);e.appendChild(l);k.appendChild(e);l=b.createElement("tr");for(e=0;7>e;e++)j=b.createElement("td"),j.setAttribute("style",this.settings.dayOfWeekHeaderStyle),j.setAttribute("class",this.settings.dayOfWeekHeaderClass),j.appendChild(b.createTextNode(this.settings.daysOfWeek[e])),l.appendChild(j);k.appendChild(l); +l=null!=this.selectedDate?c.getDate(this.selectedDate):null;null!=l&&this.settings.defaultTimeOfDay>=c.dayDuration&&(l=c.subtractDay(l));j=f.getMonth();e=c.getFirstDayOfMonth(f);p=c.getPreviousWeekStart(e);for(f=0;6>f;f++){var r=b.createElement("tr");for(e=0;7>e;e++){var t=b.createElement("td");t.setAttribute("style",this.settings.dayStyle);t.setAttribute("class",this.settings.dayClass);var u=p.getDate().toString(),w=b.createElement("span");t.appendChild(w);var v=b.createElement("span");w.appendChild(v); +var B="undefined"!==typeof this.settings.disabledDateSelector&&this.settings.disabledDateSelector(p),x=p.getMonth()==j,y=b.createElement("a");y.setAttribute("href","javascript://");y.setAttribute("style","text-decoration: none; display: inline-block; cursor: "+(this.settings.isReadOnly||B||!x&&(this.settings.allowRangeSelection||this.settings.allowMultipleSelection)?"default":"pointer")+"; color: inherit; width: 20px");y.appendChild(b.createTextNode(u));v.appendChild(y);if(B)w.setAttribute("style", +this.settings.disabledDayStyle),w.setAttribute("class",this.settings.disabledDayClass);else if(x){if(u=l&&Math.abs(p.valueOf()-l.valueOf())<=c.hourDuration||this.isValueSelected(p))w.setAttribute("style",this.settings.selectedDayStyle),w.setAttribute("class",this.settings.selectedDayClass);this.settings.highlightingStyleSelector&&(w=this.settings.highlightingStyleSelector(p,u))&&v.setAttribute("style",w);this.settings.highlightingClassSelector&&(w=this.settings.highlightingClassSelector(p,u))&&v.setAttribute("class", +w)}else v.setAttribute("style",this.settings.otherMonthDayStyle),v.setAttribute("class",this.settings.otherMonthDayClass);!this.settings.isReadOnly&&!B&&(y.value=c.addTimeOfDay(p,this.settings.defaultTimeOfDay),!this.settings.allowMultipleSelection&&!this.settings.allowRangeSelection?y.onclick=function(b){var d=b.currentTarget.value;a.setDisplayedValue(d);a.setValue(d);b.stopPropagation()}:this.settings.allowRangeSelection?x&&(y.onmousedown=function(b){var d=b.currentTarget.value;a.draggingFromDate= +d;a.setValue(d);b.preventDefault()},y.onmouseover=function(b){if(a.draggingFromDate&&(b=b.currentTarget.value,!a.draggingToDate||b.valueOf()!=a.draggingToDate.valueOf()))a.draggingToDate=b,a.setValueRange({start:a.draggingFromDate,finish:a.draggingToDate})}):x&&(y.onclick=function(b){a.invertValueSelection(b.currentTarget.value);b.stopPropagation()}));r.appendChild(t);p=c.addDay(p)}k.appendChild(r)}f=p}}!this.settings.isReadOnly&&this.settings.isTodayLinkVisible&&(m=b.createElement("tr"),n=b.createElement("td"), +n.colSpan=7,n.setAttribute("style",this.settings.todayLinkStyle),n.setAttribute("class",this.settings.todayLinkClass),g=b.createElement("a"),g.setAttribute("href","javascript://"),g.setAttribute("style","text-decoration: none; color: inherit; cursor: pointer"),g.appendChild(b.createTextNode(this.settings.todayString)),n.appendChild(g),g.value=c.addTimeOfDay(c.getDate(new Date),this.settings.defaultTimeOfDay),g.onclick=function(b){var d=b.currentTarget.value;a.setDisplayedValue(d);a.setValue(d);b.stopPropagation()}, +m.appendChild(n),d.appendChild(m));this.host.appendChild(d);this.isInitialized||b.addEventListener("mouseup",function(){a.draggingToDate&&delete a.draggingToDate;a.draggingFromDate&&delete a.draggingFromDate},!0)};c.prototype.getValue=function(){return this.selectedDate};c.prototype.setValue=function(a){null!=a&&a 6.5*c.dayDuration)for(b=0;7>b;b++)a=c.addDay(a);return a};c.addDay=function(a){var b=a.getTimezoneOffset()*c.minuteDuration,a=new Date(a.valueOf()-b+c.dayDuration),b=a.getTimezoneOffset()*c.minuteDuration;return new Date(a.valueOf()+b)};c.subtractDay=function(a){return c.getDate(new Date(a.valueOf()-c.dayDuration))};c.addTimeOfDay=function(a,b){var d= +a.getTimezoneOffset()*c.minuteDuration,a=new Date(a.valueOf()-d+b),d=a.getTimezoneOffset()*c.minuteDuration;return new Date(a.valueOf()+d)};c.getFirstDayOfMonth=function(a){for(a=c.getDate(a);1 "); +"undefined"===typeof a.inputStyle&&"Modern"==a.theme&&(a.inputStyle="border: 1px solid #e0e0e0; background-color: White; color: #505050; font-family: Arial; font-size: 12px; padding: 4px")};c.prototype.refresh=function(){for(var a=this,b=this.host.ownerDocument,d=this.host.childNodes.length;0 a.popupElement.ownerDocument.documentElement.clientHeight&&b.top>=d.height&&(a.popupElement.style.top=b.top-d.height+2+"px");d.right>a.popupElement.ownerDocument.documentElement.clientWidth&& +a.popupElement.ownerDocument.documentElement.clientWidth>=d.width&&(a.popupElement.style.left=a.popupElement.ownerDocument.documentElement.clientWidth-d.width+"px")};b();this.isOpen&&this.settings.dropDownOpenedHandler?this.settings.dropDownOpenedHandler():!this.isOpen&&this.settings.dropDownClosedHandler&&this.settings.dropDownClosedHandler();if(this.isOpen){var d=this.host.ownerDocument.documentElement.clientWidth,c=this.host.ownerDocument.documentElement.clientHeight,e=this.host.getBoundingClientRect(); +this.positionChangeHandlerTimer=setInterval(function(){var h=a.host.ownerDocument.documentElement.clientWidth,m=a.host.ownerDocument.documentElement.clientHeight,g=a.host.getBoundingClientRect();h!=d||m!=c?a.closeDropDown():(g.left!=e.left||g.top!=e.top||g.width!=e.width||g.height!=e.height)&&b();d=h;c=m;e=g},100)}else this.positionChangeHandlerTimer&&(clearInterval(this.positionChangeHandlerTimer),delete this.positionChangeHandlerTimer)};return c}();g.Element=j})(v=g.DatePicker||(g.DatePicker={})); +var o;(function(g){var j=function(){function c(a,b,d,f,e){this.host=a;this.selectedTime=b;this.header=d;this.settings=f;this.isInitialized=!1;var h="DlhSoft.Controls CalendarDay DlhSoft.Data.HTML.Controls 5 validate Licensing".split(" ");l[h[5]][h[4]](a,h[0],h[1],h[2],h[3],e,f);this.host.component=this;"undefined"===typeof f&&(f={});"undefined"!==typeof d&&"undefined"===typeof f.header&&(f.header=d);this.settings=f;c.initializeSettings(this.settings);"undefined"===typeof b&&(a=new Date,b=(new Date(a.valueOf()- +a.getTimezoneOffset()*c.minuteDuration)).getTime(),b-=Math.floor(b/c.dayDuration)*c.dayDuration);this.selectedTime=b;this.refresh();this.isInitialized=!0}c.initializeSettings=function(a){"undefined"===typeof a.theme&&(a.theme="Modern");"undefined"===typeof a.isReadOnly&&(a.isReadOnly=!1);"undefined"===typeof a.isNowLinkVisible&&(a.isNowLinkVisible=!1);"undefined"===typeof a.header&&(a.header="Time of day");"undefined"===typeof a.isHeaderVisible&&(a.isHeaderVisible=!0);"undefined"===typeof a.headerStyle&& +(a.headerStyle="color: "+("Modern"==a.theme?"#505050":"Black")+"; background-color: #f0f0f0; padding: 8px; font-size: "+("Modern"==a.theme?"12px":"small")+"; text-align: center; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; cursor: default");"undefined"===typeof a.timeStyle&&(a.timeStyle="color: "+("Modern"==a.theme?"#505050":"Black")+"; min-width: 24px; padding: 2px; text-align: center; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; cursor: default; font-size: "+ +("Modern"==a.theme?"12px":"small"));"undefined"===typeof a.selectedTimeStyle&&(a.selectedTimeStyle="background-color: #3399ff; color: White; padding: 2px");"undefined"===typeof a.disabledTimeStyle&&(a.disabledTimeStyle="color: "+("Modern"==a.theme?"#c0c0c0":"Silver"));"undefined"===typeof a.nowLinkStyle&&(a.nowLinkStyle="color: "+("Modern"==a.theme?"#505050":"Black")+"; padding: 4px; border-top: 1px solid "+("Modern"==a.theme?"#e0e0e0":"Silver")+"; font-size: "+("Modern"==a.theme?"12px":"small")+ +"; text-align: center; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; cursor: default");"undefined"===typeof a.nowString&&(a.nowString="Now");"undefined"===typeof a.hourDivisions?a.hourDivisions=2:0>=a.hourDivisions&&(a.hourDivisions=1);"undefined"===typeof a.timeFormatter&&(a.timeFormatter=function(a){var d=Math.floor(a/c.hourDuration),a=Math.floor((a-d*c.hourDuration)/c.minuteDuration),f=function(a,b){b===void 0&&(b=2);for(var d=a.toString();d.length< +b;)d="0"+d;return d};return f(d)+":"+f(a)});"undefined"===typeof a.hourColumns?a.hourColumns=4:0>=a.hourColumns&&(a.hourColumns=1);"undefined"===typeof a.scrollingHeight&&(a.scrollingHeight="auto")};c.prototype.refresh=function(){for(var a=this,b=this.host.ownerDocument,d=this.host.childNodes.length;0 d&&(d=new Date,d=(new Date(d.valueOf()-d.getTimezoneOffset()*c.minuteDuration)).getTime(),d-=Math.floor(d/c.dayDuration)*c.dayDuration);a.setValue(d);b.stopPropagation()}, +q.appendChild(f),d.appendChild(q));this.host.appendChild(d)};c.prototype.getValue=function(){return this.selectedTime};c.prototype.setValue=function(a){null!=a&&0>a&&(a=0);if(a!=this.selectedTime||this.settings.forceSetOnClick)this.selectedTime=a,this.refresh(),this.settings.selectedTimeChangeHandler&&this.settings.selectedTimeChangeHandler(a)};c.getTime=function(a,b){var d=c.hourDuration/b;return Math.floor(a/d)*d};c.secondDuration=1E3;c.minuteDuration=60*c.secondDuration;c.hourDuration=60*c.minuteDuration; +c.dayDuration=24*c.hourDuration;return c}();g.Element=j})(o=g.CalendarDay||(g.CalendarDay={}));var r;(function(g){g.initialize=function(c,a,b,d,f){return new j(c,a,b,d,f)};g.get=function(c){return c.component};var j=function(){function c(a,b,d,f,e){this.host=a;this.value=b;this.header=d;this.settings=f;this.isInitialized=!1;this.dropDownButtonElement=null;var h="DlhSoft.Controls TimePicker DlhSoft.Data.HTML.Controls 5 validate Licensing".split(" ");l[h[5]][h[4]](a,h[0],h[1],h[2],h[3],e,f);this.host.component= +this;"undefined"===typeof f&&(f={});"undefined"!==typeof d&&"undefined"===typeof f.header&&(f.header=d);this.settings=f;c.initializeSettings(this.settings);d=this.host.ownerDocument;if(this.inputHost=a instanceof HTMLInputElement?a:null){if(null==b)try{b=this.settings.timeParser(this.inputHost.value)}catch(m){}a=d.createElement("span");this.inputHost.parentElement&&this.inputHost.parentElement.insertBefore(a,this.inputHost);this.host=a;l[h[5]][h[4]](a,h[0],h[1],h[2],h[3],e,f);this.host.component= +this}"undefined"===typeof b&&(f.isNullValueAccepted?b=null:(b=new Date,b=(new Date(b.valueOf()-b.getTimezoneOffset()*c.minuteDuration)).getTime(),b-=Math.floor(b/c.dayDuration)*c.dayDuration));this.value=b;this.refresh();this.isInitialized=!0}c.initializeSettings=function(a){"undefined"===typeof a.isNowLinkVisible&&(a.isNowLinkVisible=!0);"undefined"===typeof a.timeFormatter&&(a.timeFormatter=function(b){if(b==null&&a.isNullValueAccepted)return"";var d=Math.floor(b/c.hourDuration),b=Math.floor((b- +d*c.hourDuration)/c.minuteDuration),f=function(a,b){b===void 0&&(b=2);for(var d=a.toString();d.length=0&&(b=b.substr(d+1));b=new Date("01/01/1970 "+b);if(isNaN(b.valueOf())|| +b.getFullYear()<=0||b.getFullYear()!=1970||b.getMonth()!=0||b.getDate()!=1){b=new Date;b=(new Date(b.valueOf()-b.getTimezoneOffset()*c.minuteDuration)).getTime();return b=b-Math.floor(b/c.dayDuration)*c.dayDuration}return b.getTime()-b.getTimezoneOffset()*c.minuteDuration});"undefined"===typeof a.isNullValueAccepted&&(a.isNullValueAccepted=!0);"undefined"===typeof a.isDropDownButtonVisible&&(a.isDropDownButtonVisible=!1);"undefined"===typeof a.dropDownButtonDefinition&&(a.dropDownButtonDefinition= +"");"undefined"===typeof a.popupStyle&&(a.popupStyle="background-color: White; border: 1px solid "+("Modern"==a.theme?"#e0e0e0":"#707070")+ +"; font-family: Arial");"undefined"===typeof a.inputStyle&&"Modern"==a.theme&&(a.inputStyle="border: 1px solid #e0e0e0; background-color: White; color: #505050; font-family: Arial; font-size: 12px; padding: 4px");"undefined"===typeof a.defaultPrefix&&(a.defaultPrefix="")};c.prototype.refresh=function(){for(var a=this,b=this.host.ownerDocument,d=this.host.childNodes.length;0 =a.scrollTop&&0= +a.scrollHeight-a.clientHeight-1&&0>b))d=!0;if(a==this.popupElement)return d;a=a.parentElement}return!1};c.prototype.getValue=function(){return this.value};c.prototype.setValue=function(a){this.resetValue(a)};c.prototype.refreshValue=function(){this.resetValue()};c.prototype.resetValue=function(a){if(!this.isDuringInternalSetValue){this.isDuringInternalSetValue=!0;this.closeDropDown();var b=this.value;try{this.value=null!=a?a:this.settings.timeParser(this.inputElement.value)}catch(d){}this.settings.disabledTimeSelector&& +(null!=this.value&&this.settings.disabledTimeSelector(this.value))&&(this.settings.isNullValueAccepted?this.value=null:(a=new Date,this.value=(new Date(a.valueOf()-a.getTimezoneOffset()*c.minuteDuration)).getTime(),this.value-=Math.floor(this.value/c.dayDuration)*c.dayDuration));a=this.inputElement.value?this.inputElement.value.lastIndexOf(" "):-1;a=0<=a?this.inputElement.value.substr(0,a):this.settings.defaultPrefix;0 a.popupElement.ownerDocument.documentElement.clientHeight&&b.top>=d.height&&(a.popupElement.style.top=b.top-d.height+2+"px");d.right>a.popupElement.ownerDocument.documentElement.clientWidth&&a.popupElement.ownerDocument.documentElement.clientWidth>=d.width&&(a.popupElement.style.left=a.popupElement.ownerDocument.documentElement.clientWidth-d.width+"px")};b();this.isOpen&&this.settings.dropDownOpenedHandler?this.settings.dropDownOpenedHandler():!this.isOpen&&this.settings.dropDownClosedHandler&& +this.settings.dropDownClosedHandler();if(this.isOpen){this.calendarDay.selectedElement&&this.calendarDay.selectedElement.scrollIntoView();var d=this.host.ownerDocument.documentElement.clientWidth,c=this.host.ownerDocument.documentElement.clientHeight,e=this.host.getBoundingClientRect();this.positionChangeHandlerTimer=setInterval(function(){var h=a.host.ownerDocument.documentElement.clientWidth,g=a.host.ownerDocument.documentElement.clientHeight,k=a.host.getBoundingClientRect();h!=d||g!=c?a.closeDropDown(): +(k.left!=e.left||k.top!=e.top||k.width!=e.width||k.height!=e.height)&&b();d=h;c=g;e=k},100)}else this.positionChangeHandlerTimer&&(clearInterval(this.positionChangeHandlerTimer),delete this.positionChangeHandlerTimer)};c.secondDuration=1E3;c.minuteDuration=60*c.secondDuration;c.hourDuration=60*c.minuteDuration;c.dayDuration=24*c.hourDuration;return c}();g.Element=j})(r=g.TimePicker||(g.TimePicker={}));(function(g){g.initialize=function(c,a,b,d){return new j(c,a,b,d)};g.get=function(c){return c["DateTimePicker.component"]}; +var j=function(){function c(a,b,d,f){var e=this;this.host=a;this.value=b;this.settings=d;this.isInitialized=!1;this.host["DateTimePicker.component"]=this;"undefined"===typeof d&&(d={});"undefined"!==typeof d.license&&"undefined"!==typeof d.datePickerSettings&&(d.datePickerSettings.license=d.license);this.settings=d;c.initializeSettings(this.settings);"undefined"===typeof b&&(b=d.datePickerSettings.isNullValueAccepted?null:new Date);this.value=b;this.timePicker=r.initialize(a,void 0,void 0,this.settings.timePickerSettings, +"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.");this.inputElement=this.timePicker.inputElement;this.inputElement["DateTimePicker.component"]=this;this.datePicker=v.initialize(this.inputElement,this.value,this.settings.datePickerSettings,f);this.value=this.datePicker.value;var h;try{h=b?this.datePicker.settings.dateTimeFormatter(b):""}catch(g){h=""}a=h.lastIndexOf(" ");0<=a&&(h=h.substr(0,a));this.timePicker.settings.defaultPrefix= +h;var k=this.datePicker.settings.dropDownOpenedHandler;this.datePicker.settings.dropDownOpenedHandler=function(){e.datePicker.isOpen&&e.timePicker.isOpen&&e.timePicker.closeDropDown();e.isOpen=e.datePicker.isOpen;k&&k()};var j=this.datePicker.settings.dropDownClosedHandler;this.datePicker.settings.dropDownClosedHandler=function(){e.isOpen=e.datePicker.isOpen;j&&j()};var l=this.timePicker.settings.dropDownOpenedHandler;this.timePicker.settings.dropDownOpenedHandler=function(){e.timePicker.isOpen&& +!e.value?e.timePicker.closeDropDown():(e.timePicker.isOpen&&e.datePicker.isOpen&&e.datePicker.closeDropDown(),e.isTimeOpen=e.timePicker.isOpen,l&&l())};var p=this.timePicker.settings.dropDownClosedHandler;this.timePicker.settings.dropDownClosedHandler=function(){e.isTimeOpen=e.timePicker.isOpen;p&&p()};var o=this.datePicker.settings.valueChangeHandler;this.datePicker.settings.valueChangeHandler=function(a){e.value=a;o&&o(a)};this.inputElement&&(this.inputElement.addEventListener("focus",function(){if(e.settings.openDropDownOnInputClick){switch(e.getCurrentValuePart()){default:e.openDropDown(); +break;case "Time":e.timePicker.refreshValue(),e.openTimeDropDown()}e.focusValue=e.inputElement.value}},!0),this.inputElement.addEventListener("blur",function(){e.settings.openDropDownOnInputClick&&"undefined"!==typeof e.focusValue&&delete e.focusValue},!0),this.inputElement.addEventListener("keydown",function(a){13==a.keyCode?e.settings.openDropDownOnInputClick&&e.refreshValue():e.closeDropDown()},!0),this.inputElement.addEventListener("mousedown",function(){setTimeout(function(){if(e.settings.openDropDownOnInputClick&& +!("undefined"!==typeof e.focusValue&&e.inputElement.value!=e.focusValue))switch(e.getCurrentValuePart()){default:e.datePicker.refreshValue();e.openDropDown();break;case "Time":e.timePicker.refreshValue(),e.openTimeDropDown()}},0)},!0));this.isInitialized=!0}c.initializeSettings=function(a){"undefined"===typeof a.theme&&(a.theme="Modern");"undefined"===typeof a.isReadOnly&&(a.isReadOnly=!1);"undefined"===typeof a.isNullValueAccepted&&(a.isNullValueAccepted=!0);"undefined"===typeof a.openDropDownOnInputClick&& +(a.openDropDownOnInputClick=!0);"undefined"===typeof a.datePickerSettings&&(a.datePickerSettings={});a.datePickerSettings.isReadOnly=a.isReadOnly;a.datePickerSettings.theme=a.theme;"undefined"===typeof a.datePickerSettings.isTodayLinkVisible&&(a.datePickerSettings.isTodayLinkVisible=a.areCurrentLinksVisible);"undefined"===typeof a.datePickerSettings.defaultTimeOfDay&&(a.datePickerSettings.defaultTimeOfDay=a.defaultTimeOfDay);a.datePickerSettings.openDropDownOnInputClick=!1;"undefined"===typeof a.datePickerSettings.isDropDownButtonVisible&& +(a.datePickerSettings.isDropDownButtonVisible=a.areDropDownButtonsVisible);a.datePickerSettings.allowMultipleSelection=!1;a.datePickerSettings.allowRangeSelection=!1;"undefined"===typeof a.datePickerSettings.dateTimeFormatter&&(a.datePickerSettings.dateTimeFormatter=a.dateTimeFormatter);"undefined"===typeof a.datePickerSettings.dateTimeParser&&(a.datePickerSettings.dateTimeParser=a.dateTimeParser);a.datePickerSettings.isNullValueAccepted=a.isNullValueAccepted;"undefined"===typeof a.datePickerSettings.valueChangeHandler&& +(a.datePickerSettings.valueChangeHandler=a.valueChangeHandler);"undefined"===typeof a.datePickerSettings.popupClass&&(a.datePickerSettings.popupClass=a.popupClass);"undefined"===typeof a.datePickerSettings.popupStyle&&(a.datePickerSettings.popupStyle=a.popupStyle);"undefined"===typeof a.datePickerSettings.inputClass&&(a.datePickerSettings.inputClass=a.inputClass);"undefined"===typeof a.datePickerSettings.inputStyle&&(a.datePickerSettings.inputStyle=a.inputStyle);"undefined"===typeof a.datePickerSettings.disabledDateSelector&& +(a.datePickerSettings.disabledDateSelector=a.disabledDateSelector);"undefined"===typeof a.datePickerSettings.calendarSelectorLevels&&(a.datePickerSettings.calendarSelectorLevels=a.calendarSelectorLevels);"undefined"===typeof a.datePickerSettings.months&&(a.datePickerSettings.months=a.months);"undefined"===typeof a.datePickerSettings.daysOfWeek&&(a.datePickerSettings.daysOfWeek=a.daysOfWeek);"undefined"===typeof a.timePickerSettings&&(a.timePickerSettings={});a.timePickerSettings.theme=a.theme;a.timePickerSettings.isReadOnly= +a.isReadOnly;"undefined"===typeof a.timePickerSettings.isNowLinkVisible&&(a.timePickerSettings.isNowLinkVisible=a.areCurrentLinksVisible);"undefined"===typeof a.timePickerSettings.nowString&&(a.timePickerSettings.nowString="Current");a.timePickerSettings.openDropDownOnInputClick=!1;"undefined"===typeof a.timePickerSettings.isDropDownButtonVisible&&(a.timePickerSettings.isDropDownButtonVisible=a.areDropDownButtonsVisible);"undefined"===typeof a.timePickerSettings.timeFormatter&&"undefined"!==typeof a.datePickerSettings.dateTimeFormatter&& +(a.timePickerSettings.timeFormatter=function(b){var c=new Date(1970,0,1),b=b!=null?a.datePickerSettings.dateTimeFormatter(new Date(c.valueOf()+b)):"",c=b.lastIndexOf(" ");return c<0?"":b.substr(c+1)});"undefined"===typeof a.timePickerSettings.timeParser&&("undefined"!==typeof a.datePickerSettings.dateTimeParser&&"undefined"!==typeof a.datePickerSettings.dateTimeFormatter)&&(a.timePickerSettings.timeParser=function(b){var f=b.lastIndexOf(" ");if(f<0){if(a.isNullValueAccepted)return null;b=new Date; +b=(new Date(b.valueOf()-b.getTimezoneOffset()*c.minuteDuration)).getTime();return b-Math.floor(b/c.dayDuration)*c.dayDuration}var b=b.substr(f+1),e=a.datePickerSettings.dateTimeFormatter(new Date(1970,0,1)),f=e.indexOf(" ");f>=0&&(e=e.substr(0,f+1));b=a.datePickerSettings.dateTimeParser(e+b);if(isNaN(b.valueOf())||b.getFullYear()<=0||b.getFullYear()!=1970||b.getMonth()!=0||b.getDate()!=1){b=new Date;b=(new Date(b.valueOf()-b.getTimezoneOffset()*c.minuteDuration)).getTime();return b=b-Math.floor(b/ +c.dayDuration)*c.dayDuration}return b.getTime()-b.getTimezoneOffset()*c.minuteDuration});a.timePickerSettings.isNullValueAccepted=a.isNullValueAccepted;if("undefined"!==typeof a.timePickerSettings.disabledTimeSelector){var b=a.datePickerSettings.disabledDateSelector;a.datePickerSettings.disabledDateSelector=function(d){var f=false;b&&(f=b(d));if(f)return true;d=(new Date(d.valueOf()-d.getTimezoneOffset()*c.minuteDuration)).getTime();d=d-Math.floor(d/c.dayDuration)*c.dayDuration;return a.timePickerSettings.disabledTimeSelector(d)}}"undefined"=== +typeof a.timePickerSettings.popupClass&&(a.timePickerSettings.popupClass=a.popupClass);"undefined"===typeof a.timePickerSettings.popupStyle&&(a.timePickerSettings.popupStyle=a.popupStyle);a.timePickerSettings.inputClass=void 0;a.timePickerSettings.inputStyle=null;"undefined"===typeof a.timePickerSettings.disabledTimeSelector&&(a.timePickerSettings.disabledTimeSelector=a.disabledTimeSelector)};c.prototype.refreshValue=function(){this.datePicker.refreshValue();this.timePicker.refreshValue()};c.prototype.getValue= +function(){return this.datePicker.getValue()};c.prototype.setValue=function(a){this.datePicker.setValue(a)};c.prototype.getTimeValue=function(){return this.timePicker.getValue()};c.prototype.setTimeValue=function(a){this.timePicker.setValue(a)};c.prototype.openDropDown=function(){this.datePicker.openDropDown()};c.prototype.closeDropDown=function(){this.datePicker.closeDropDown()};c.prototype.openTimeDropDown=function(){this.timePicker.openDropDown()};c.prototype.closeTimeDropDown=function(){this.timePicker.closeDropDown()}; +c.prototype.getCurrentValuePart=function(){if(!this.inputElement||!this.inputElement.value)return null;var a=this.inputElement.value.lastIndexOf(" ");return 0>a?"Date":this.inputElement.selectionStart>a?"Time":"Date"};c.secondDuration=1E3;c.minuteDuration=60*c.secondDuration;c.hourDuration=60*c.minuteDuration;c.dayDuration=24*c.hourDuration;return c}();g.Element=j})(g.DateTimePicker||(g.DateTimePicker={}));var q;(function(g){g.initialize=function(c,a,b,d,f){return new p(c,a,b,d,f)};g.get=function(c){return c.component}; +var p=function(){function c(a,b,d,f,e){this.host=a;this.availableChoices=b;this.value=d;this.settings=f;this.isInitialized=!1;this.dropDownButtonElement=null;var h="DlhSoft.Controls MultiSelectorComboBox DlhSoft.Data.HTML.Controls 5 validate Licensing".split(" ");l[h[5]][h[4]](a,h[0],h[1],h[2],h[3],e,f);this.host.component=this;"undefined"===typeof f&&(f={});this.settings=f;c.initializeSettings(this.settings);"undefined"===typeof this.settings.choiceStyle&&!(this instanceof j.Element)&&(this.settings.choiceStyle= +"cursor: pointer");var g=this.host.ownerDocument;if(this.inputHost=a instanceof HTMLInputElement?a:null)null==d&&(d=this.inputHost.value),a=g.createElement("span"),this.inputHost.parentElement&&this.inputHost.parentElement.insertBefore(a,this.inputHost),this.host=a,l[h[5]][h[4]](a,h[0],h[1],h[2],h[3],e,f),this.host.component=this;if("undefined"===typeof b||null==b)b=[];this.availableChoices=b;if("undefined"===typeof d||null==d)d="";this.value=d;this.refresh();this.isInitialized=!0}c.initializeSettings= +function(a){"undefined"===typeof a.theme&&(a.theme="Modern");"undefined"===typeof a.isReadOnly&&(a.isReadOnly=!1);"undefined"===typeof a.autoAppendAvailableChoices&&(a.autoAppendAvailableChoices=!1);"undefined"===typeof a.openDropDownOnInputClick&&(a.openDropDownOnInputClick=!0);"undefined"===typeof a.isDropDownButtonVisible&&(a.isDropDownButtonVisible=!1);"undefined"===typeof a.dropDownButtonDefinition&&(a.dropDownButtonDefinition="\u25bc");"undefined"===typeof a.separator&&(a.separator=",");"undefined"===typeof a.isSpaceSeparated&&(a.isSpaceSeparated=!0);"undefined"===typeof a.delimiters&&(a.delimiters=["["]);"undefined"===typeof a.areCheckBoxesVisible&&(a.areCheckBoxesVisible=!0);"undefined"=== +typeof a.popupStyle&&(a.popupStyle="background-color: White; color: "+("Modern"==a.theme?"#505050":"Black")+"; border: 1px solid "+("Modern"==a.theme?"#e0e0e0":"#707070")+"; font-family: Arial; font-size: "+("Modern"==a.theme?"12px":"small")+"; max-height: 188px; overflow-y: auto");"undefined"===typeof a.inputStyle&&"Modern"==a.theme&&(a.inputStyle="border: 1px solid #e0e0e0; background-color: White; color: #505050; font-family: Arial; font-size: 12px; padding: 4px")};c.prototype.refresh=function(){for(var a= +this,b=this.host.ownerDocument,d=this.host.childNodes.length;0 =a.scrollTop&&0=a.scrollHeight-a.clientHeight-1&&0>b))d=!0;if(a==this.popupElement)return d;a=a.parentElement}return!1};c.prototype.getValue=function(){return this.value};c.prototype.setValue=function(a){this.resetValue(a)};c.prototype.refreshValue=function(){this.resetValue()};c.prototype.resetValue= +function(a){this.isDuringInternalSetValue||(this.closeDropDown(),this.setValueInternal(a))};c.prototype.setValueInternal=function(a,b){if(!this.isDuringInternalSetValue){this.isDuringInternalSetValue=!0;"undefined"===typeof b&&(b=!0);var d=this.value,c=this.value="undefined"!==typeof a&&null!=a?a:this.inputElement.value;if(c!=this.inputElement.value&&(this.inputElement.value=c,this.isInitialized))try{var e=this.inputElement.ownerDocument.createEvent("HTMLEvents");e.initEvent("change",!0,!0);this.inputElement.dispatchEvent(e)}catch(h){}if(this.value&& +!d||!this.value&&d||this.value&&d&&this.value.valueOf()!=d.valueOf())b&&this.refreshSelectedChoices(),this.settings.valueChangeHandler&&this.settings.valueChangeHandler(this.value);delete this.isDuringInternalSetValue}};c.prototype.refreshAvailableChoices=function(){if(this.settings.autoAppendAvailableChoices){for(var a=this.getSelectedChoices(!1),b=0;b this.availableChoices.indexOf(d)&&this.availableChoices.push(d)}this.refreshSelectedChoices()}};c.prototype.getSelectedChoice= +function(a){return this.getSelectedChoices(a)[0]};c.prototype.getSelectedChoices=function(a){"undefined"===typeof a&&(a=!0);for(var b=[],d=this.value.trim(),c=d.split(this.settings.separator),e=0;e =this.availableChoices.length))){(this.isOpen=!this.isOpen)&&this.refreshAvailableChoices();var b= +function(){var b=a.inputElement.getBoundingClientRect();a.popupElement.style.position="fixed";a.popupElement.style.zIndex="1";a.popupElement.style.left=b.left+"px";a.popupElement.style.top=b.top+b.height+"px";a.popupElement.style.minWidth=a.inputElement.offsetWidth+"px";a.popupElement.style.display=a.isOpen?"block":"none";var c=a.popupElement.getBoundingClientRect();c.bottom>a.popupElement.ownerDocument.documentElement.clientHeight&&b.top>=c.height&&(a.popupElement.style.top=b.top-c.height+2+"px"); +c.right>a.popupElement.ownerDocument.documentElement.clientWidth&&a.popupElement.ownerDocument.documentElement.clientWidth>=c.width&&(a.popupElement.style.left=a.popupElement.ownerDocument.documentElement.clientWidth-c.width+"px")};b();this.isOpen&&this.settings.dropDownOpenedHandler?this.settings.dropDownOpenedHandler():!this.isOpen&&this.settings.dropDownClosedHandler&&this.settings.dropDownClosedHandler();if(this.isOpen){var c=this.host.ownerDocument.documentElement.clientWidth,f=this.host.ownerDocument.documentElement.clientHeight, +e=this.host.getBoundingClientRect();this.positionChangeHandlerTimer=setInterval(function(){var h=a.host.ownerDocument.documentElement.clientWidth,g=a.host.ownerDocument.documentElement.clientHeight,k=a.host.getBoundingClientRect();h!=c||g!=f?a.closeDropDown():(k.left!=e.left||k.top!=e.top||k.width!=e.width||k.height!=e.height)&&b();c=h;f=g;e=k},100)}else this.positionChangeHandlerTimer&&(clearInterval(this.positionChangeHandlerTimer),delete this.positionChangeHandlerTimer)}};return c}();g.Element= +p})(q=g.MultiSelectorComboBox||(g.MultiSelectorComboBox={}));var j;(function(g){g.initialize=function(c,a,b,d,f){return new j(c,a,b,d,f)};g.get=function(c){return c.component};var j=function(c){function a(a,d,f,e,h){c.call(this,a,d,f,e,h);this.isInitialized=!1;this.settings.areCheckBoxesVisible=!1;"undefined"===typeof e.choiceStyle&&(e.choiceStyle="padding: 2px; margin-right: -4px; cursor: pointer");"undefined"===typeof e.selectedChoiceStyle&&(e.selectedChoiceStyle="background-color: #3399ff; color: White; margin: -3px; padding: 2px"); +this.refresh();this.isInitialized=!0}__extends(a,c);return a}(q.Element);g.Element=j})(j=g.ComboBox||(g.ComboBox={}));var s;(function(g){g.initialize=function(c,a,b,d,f){return new l(c,a,b,d,f)};g.get=function(c){return c.component};var l=function(c){function a(){c.apply(this,arguments)}__extends(a,c);return a}(j.Element);g.Element=l})(s=g.DropDownList||(g.DropDownList={}));(function(g){g.initialize=function(c,a,b,d){return new j(c,a,b,d)};g.get=function(c){return c["ToolTip.component"]};var j=function(){function c(a, +b,d,f){var e=this;this.content=a;this.targetElement=b;this.settings=d;this.isInitialized=!1;this.isEnabled=!0;this.isVisible=!1;var b=b.ownerDocument,g=b.createElement("span");b.body.appendChild(g);var j="DlhSoft.Controls ToolTip DlhSoft.Data.HTML.Controls 5 validate Licensing".split(" ");l[j[5]][j[4]](g,j[0],j[1],j[2],j[3],f,d);a&&a instanceof HTMLElement?(a.parentNode&&a.parentNode.removeChild(a),f=a):(f=b.createElement("span"),f.innerHTML=a);g.appendChild(f);this.host=g;this.contentContainer=f; +this.host["ToolTip.component"]=this;this.contentContainer["ToolTip.component"]=this;this.targetElement["ToolTip.component"]=this;"undefined"===typeof d&&(d={});this.settings=d;c.initializeSettings(this.settings);this.contentContainer.setAttribute("style",this.settings.containerStyle);this.settings.containerClass&&this.contentContainer.setAttribute("class",this.settings.containerClass);this.isEnabled=this.settings.isEnabled;(this.isVisible=this.settings.isVisible)?this.show():this.hide();this.refresh(); +var k=!1;this.targetElement.addEventListener("mouseenter",function(){if(e.isEnabled){e.show();k=true}});this.targetElement.addEventListener("mouseleave",function(){if(e.isEnabled){k=false;isNaN(e.settings.duration)||setTimeout(function(){k||e.hide()},e.settings.duration)}});this.contentContainer.addEventListener("mouseenter",function(){e.isEnabled&&(k=true)});this.contentContainer.addEventListener("mouseleave",function(){if(e.isEnabled){k=false;isNaN(e.settings.duration)||setTimeout(function(){k|| +e.hide()},e.settings.duration)}});this.targetElement.addEventListener("mouseup",function(){e.isEnabled&&e.hide()},!0);b.addEventListener("mousedown",function(){e.isEnabled&&(k||e.hide())},!0);b.addEventListener("mousewheel",function(){e.isEnabled&&e.hide()},!0);b.addEventListener("DOMMouseScroll",function(){e.isEnabled&&e.hide()},!0);this.isInitialized=!0}c.initializeSettings=function(a){"undefined"===typeof a.theme&&(a.theme="Modern");"undefined"===typeof a.isEnabled&&(a.isEnabled=!0);"undefined"=== +typeof a.duration&&(a.duration=0);"undefined"===typeof a.isVisible&&(a.isVisible=!1);"undefined"===typeof a.containerStyle&&(a.containerStyle="cursor: default; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; border: 1px solid "+("Modern"==a.theme?"#e0e0e0":"#707070")+"; background-color: "+("Modern"==a.theme?"White":"#ffffc0")+"; color: "+("Modern"==a.theme?"#505050":"Black")+"; font-family: Arial; font-size: "+("Modern"==a.theme?"12px":"small")+"; padding: 4px")}; +c.prototype.refresh=function(){var a=this.targetElement.getBoundingClientRect();this.x=a.left;this.y=a.top+a.height;this.contentContainer.style.position="fixed";this.contentContainer.style.zIndex="1";this.contentContainer.style.left=this.x+"px";this.contentContainer.style.top=this.y+"px";this.contentContainer.style.display=this.settings.isVisible?"inline-block":"none";var b=this.contentContainer.getBoundingClientRect();b.bottom>this.contentContainer.ownerDocument.documentElement.clientHeight&&a.top>= +b.height&&(this.contentContainer.style.top=a.top-b.height+2+"px");b.right>this.contentContainer.ownerDocument.documentElement.clientWidth&&this.contentContainer.ownerDocument.documentElement.clientWidth>=b.width&&(this.contentContainer.style.left=this.contentContainer.ownerDocument.documentElement.clientWidth-b.width+"px")};c.prototype.setPosition=function(a,b){this.setHorizontalPosition(a);this.setVerticalPosition(b)};c.prototype.setHorizontalPosition=function(a){this.x=a;this.contentContainer.style.left= +this.x+"px"};c.prototype.setVerticalPosition=function(a){this.y=a;this.contentContainer.style.top=this.y+"px"};c.prototype.enable=function(){this.isEnabled||(this.settings.isEnabled=this.isEnabled=!0)};c.prototype.disable=function(){this.isEnabled&&(this.settings.isEnabled=this.isEnabled=!1)};c.prototype.show=function(){c.previouslyShown&&c.previouslyShown.hide();c.previouslyShown=this;this.isVisible||(this.settings.isVisible=this.isVisible=!0,this.refresh(),this.settings.shownHandler&&this.settings.shownHandler())}; +c.prototype.hide=function(){this.isVisible&&(this.settings.isVisible=this.isVisible=!1,this.refresh(),this.settings.hiddenHandler&&this.settings.hiddenHandler())};c.prototype.setContent=function(a){a&&a instanceof HTMLElement?(a.parentNode&&a.parentNode.removeChild(a),this.host.replaceChild(a,this.contentContainer),this.contentContainer=a):this.contentContainer.innerHTML=a};return c}();g.Element=j})(g.ToolTip||(g.ToolTip={}));(function(k){function j(c,a){for(var b=g.TreeGrid.getDefaultColumns(c,a), +d=0;d +*/ + +declare module DlhSoft.Controls { + /** Represents a control that presents hierarchical data items using a tree-grid. */ + module TreeGrid { + /** + * Initializes a TreeGrid component instance. + * @param element The HTMLElement that would host the user interface of the component. + * @param items Node data objects to be managed and presented by the component. + * @param settings Configuration settings for the component behavior and appearance. + */ + function initialize(element: HTMLElement, items: Item[], settings?: Settings, license?: String): Element; + + /** Returns an array of default definitions that you can further customize and use as value for the columns property of the control settings used at initialization time. */ + function getDefaultColumns(items: Item[], settings: Settings): Column[]; + + function getDefaultCollapsedToggleButtonTemplate(controlElement: Element, settings: Settings): () => SVGElement; + function getDefaultExpandedToggleButtonTemplate(controlElement: Element, settings: Settings): () => SVGElement; + + function textColumnTemplateBase(document: HTMLDocument, valueGetter: () => any, isVisibleGetter?: () => boolean): HTMLElement; + function textInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean): HTMLElement; + function optionSelectColumnTemplateBase(document: HTMLDocument, width: number, optionCollectionGetter: () => any[], valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean): HTMLElement; + function numberInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean): HTMLElement; + function percentInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean): HTMLElement; + function timeSpanInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, scale?: number, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean): HTMLElement; + function dateTimeInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean): HTMLElement; + + function datePickerInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean, defaultTimeOfDay?: number, calendarSelectorLevels?: number, months?: string[], daysOfWeek?: string[], dateTimeFormatter?: (Date) => string, dateTimeParser?: (string) => Date): HTMLElement; + function dateTimePickerInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean, defaultTimeOfDay?: number, calendarSelectorLevels?: number, months?: string[], daysOfWeek?: string[], dateTimeFormatter?: (Date) => string, dateTimeParser?: (string) => Date): HTMLElement; + function multiSelectorComboBoxInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean): HTMLElement; + + function getIconColumnTemplate(imageSource: string, imageClass: string, imageStyle: string, isMovingEnabled?: boolean, isMovingToEnabledGetter?: (index: number, hoveringItem: Item) => boolean, movingTargetHoveringClass?: string, movingTargetHoveringStyle?: string, disabledMovingTargetHoveringClass?: string, disabledMovingTargetHoveringStyle?: string): (item: Item) => HTMLElement; + function getIconColumnTemplate(imageSourceGetter: (item: Item) => string, imageClass: string, imageStyle: string, isMovingEnabled?: boolean, isMovingToEnabledGetter?: (index: number, hoveringItem: Item) => boolean, movingTargetHoveringClass?: string, movingTargetHoveringStyle?: string, disabledMovingTargetHoveringClass?: string, disabledMovingTargetHoveringStyle?: string): (item: Item) => HTMLElement; + function getIconColumnTemplate(imageSource: string, imageClass: string, imageStyle: string, isMovingEnabledGetter: (item: Item) => boolean, isMovingToEnabledGetter?: (index: number, hoveringItem: Item) => boolean, movingTargetHoveringClass?: string, movingTargetHoveringStyle?: string, disabledMovingTargetHoveringClass?: string, disabledMovingTargetHoveringStyle?: string): (item: Item) => HTMLElement; + function getIconColumnTemplate(imageSourceGetter: (item: Item) => string, imageClass: string, imageStyle: string, isMovingEnabledGetter: (item: Item) => boolean, isMovingToEnabledGetter?: (index: number, hoveringItem: Item) => boolean, movingTargetHoveringClass?: string, movingTargetHoveringStyle?: string, disabledMovingTargetHoveringClass?: string, disabledMovingTargetHoveringStyle?: string): (item: Item) => HTMLElement; + function getIndexColumnTemplate(zeroBased?: boolean): (item: Item) => HTMLElement; + function getWbsColumnTemplate(zeroBased?: boolean): (item: Item) => HTMLElement; + + /** Represents an HTML element that supplementary provides TreeGrid component services. */ + interface Element extends HTMLElement { + items: Item[]; + settings: Settings; + + /** Updates the user interface considering all external item and settings changes. */ + refresh(): void; + + refreshGridItems(): void; refreshItems(): void; refreshGridItem(item: Item): void; refreshItem(item: Item): void; refreshItemPath(item: Item): void; refreshItemNeighbourhood(item: Item): void; + + insertItem(index: number, item: Item): void; addItem(item: Item): void; insertItems(index: number, items: Item[]): void; addItems(items: Item[]): void; + removeItem(item: Item): void; removeItems(items: Item[]): void; + moveRange(fromIndex: number, count: number, toIndex: number): void; + moveItem(item: Item, toIndex: number): void; + moveItemHierarchy(item: Item, toIndex: number): void; + moveItemUp(item: Item): void; moveItemDown(item: Item): void; + moveItemHierarchyUp(item: Item): void; moveItemHierarchyDown(item: Item): void; + + increaseItemIndentation(item: Item): void; decreaseItemIndentation(item: Item): void; + + setItemContent(item: Item, value: any): void; + getItemIndexString(item: Item, zeroBased?: boolean): string; + getCurrentItem(): Item; + getSelectedItem(): Item; getSelectedItems(): Item[]; + selectItem(item: Item): void; unselectItem(item: Item): void; + expandItem(item: Item): void; collapseItem(item: Item): void; + scrollToItem(item: Item): void; scrollToBottom(): void; + + getItemsHeight(): number; + getItemTop(item: Item): number; + + /** Calls itemPropertyChangeHandler function specified within the settings collection using the specified item, property name, and Boolean indicators for direct user actions and completed actions as arguments. */ + onItemPropertyChanged(item: Item, propertyName: string, isDirect: boolean, isFinal: boolean): void; + + /** Exports the content to the specified output document. */ + exportContent(exportSettings: ExportSettings, output: HTMLDocument): void; + /** Exports the content to the document of the specified output window. */ + exportContent(exportSettings: ExportSettings, output: Window): void; + /** Exports the content to the specified target or using a temporary document and window. */ + exportContent(exportSettings?: ExportSettings, output?: string): void; + /** Prints the content using a temporary document and window. */ + print(exportSettings?: ExportSettings): void; + + getRootItems(): Item[]; getLeafItems(): Item[]; + + isInitializing: boolean; isInitialized: boolean; + + /** Copies the common settings of the current component instance to the specified target settings collection; a secondary component instance may be initialized using the output collection. */ + copyCommonSettings(targetSettings: Settings): void; + } + + /** Represents a hierarchical data item and its tree-grid node representation. */ + interface Item { + /** The object that is displayed to represent the node item in the grid, usually the node name. */ + content: any; + + /** The hierarchy is based on the indentation level values of the nodes, so that a node with a lower index in the collection and having a specific indentation level will become the node for the nodes with a higher index in the collection and having an increased indentation level. */ + indentation?: number; + + /** If a parent node is expanded its child nodes become visible. If a parent node is collapsed its child nodes become invisible. */ + isExpanded?: boolean; + + isReadOnly?: boolean; + isHidden?: boolean; + isSummaryEnabled?: boolean; + + "class"?: string; style?: string; + + isSelected?: boolean; + + /** The index of the item in the managed hierarchy. */ + index?: number; + + /** The summary item that includes this node considering indentation values, or null when there is no such parent summary item. */ + parent?: Item; + + /** Indicates whether the node is a summary item. */ + hasChildren?: boolean; + + /** When this node is a summary item (i.e. hasChildren is set to true), returns an array of its child items. */ + children?: Item[]; + + /** Indicates whether the node is visible within the hierarchy, i.e. it is not a descendent of a collapsed summary item. */ + isVisible?: boolean; + + /** Indicates whether the node is visible in the scrolling viewport of the control when virtualization is enabled. */ + isVirtuallyVisible?: boolean; + } + + /** Represents settings for a TreeGrid component. */ + interface Settings { + /** Name of the target to generically apply to the control; Standard, and Phone targets are supported; by default it is Standard. */ + target?: string; + + /** Name of the interaction mode to generically apply to the control; Standard, and TouchEnabled interaction modes are supported; by default it is Standard. */ + interaction?: string; + + /** Name of the theme to generically apply to the control; Modern, ModernBordered, and Aero themes are supported; by default it is Modern. */ + theme?: string; + + border?: string; + containerClass?: string; containerStyle?: string; + + gridWidth?: string; + splitterWidth?: number; + + isReadOnly?: boolean; isContentReadOnly?: boolean; + + headerBackground?: string; headerHeight?: number; + itemHeight?: number; + + /** Collection of objects indicating the columns to be presented in the grid. */ + columns?: Column[]; + + itemClass?: string; itemStyle?: string; + standardItemClass?: string; summaryItemClass?: string; standardItemStyle?: string; summaryItemStyle?: string; + + selectedItemClass?: string; selectedItemStyle?: string; + + /** Indicates the selection behavior; support values are None (not allowed), Focus (single item selected triggered by focus), Single (single item selection using check box), Extended (multiple item selection using check boxes), and ExtendedFocus (multiple item selection using check boxes or triggered by focus); by default it is set to Focus. */ + selectionMode?: string; + + indentationLevelWidth?: number; + + cellClass?: string; cellStyle?: string; + toggleButtonClass?: string; toggleButtonHoveringClass?: string; toggleButtonStyle?: string; toggleButtonHoveringStyle?: string; + collapsedToggleButtonTemplate? (): HTMLElement; expandedToggleButtonTemplate? (): HTMLElement; + + visibilityFilter? (item: Item): boolean; + + allowUserToResizeColumns?: boolean; + minColumnWidth?: number; + maxColumnWidth?: number; + + alternativeItemClass?: string; alternativeItemStyle?: string; + + gridLines?: string; horizontalGridLines?: string; verticalGridLines?: string; + + /** Indicates whether the control will populate grid rows only when they need to be presented (such as only when scrolling the view to their positions); by default it is set to true for optimization purposes. */ + isVirtualizing?: boolean; + + /** Function called whenever the end user resizes a grid column, changing its width (column.width). */ + columnWidthChangeHandler? (column: Column, width: number): void; + + /** Function called whenever item properties change within the control, providing the changed item, relevant property name, and Boolean values indicating whether this change was directly triggered by the user, and whether this is the final change in a periodic operation such as a drag and drop action, specified as parameters; a custom function may be provided by the developer in order to receive notifications whenever data changes occur within the control, when using the default grid columns. */ + itemPropertyChangeHandler? (item: Item, propertyName: string, isDirect: boolean, isFinal: boolean): void; + /** Function called whenever summary item expansion state changes within the control, providing the expanded or collapsed item, and a Boolean value indicating the updated expansion state, specified as parameters. */ + itemExpansionChangeHandler? (item: Item, isExpanded: boolean): void; + /** Function called whenever item selection changes within the control, providing the selected or unselected item, a Boolean value indicating the updated selection state, and a Boolean value indicating whether this change was directly triggered by the user, specified as parameters. */ + itemSelectionChangeHandler? (item: Item, isSelected: boolean, isDirect: boolean): void; + + /** Function called whenever an item is moved in the managed list of the control, providing the item, source and target positions of the item, specified as parameters. */ + itemMoveHandler? (item: Item, fromIndex: number, toIndex: number): void; + } + + /** Represents a grid column displayed by the TreeGrid component. */ + interface Column { + isTreeView?: boolean; + + header: any; + width: number; minWidth?: number; maxWidth?: number; + + isReadOnly?: boolean; allowUserToResize?: boolean; + isSelection?: boolean; + + headerClass?: string; headerStyle?: string; + cellClass?: string; cellStyle?: string; + + /** Function that returns the output (document node) to be presented within the grid cell of this column in the standard view, for a specific item received as parameter. */ + cellTemplate(item: Item): HTMLElement; + + exportCellTemplate? (item: Item): HTMLElement; + } + + /** Represents export settings for a TreeGrid component. */ + interface ExportSettings { + title?: string; preparingMessage?: string; + columnIndexes?: number[]; + startRowIndex?: number; endRowIndex?: number; + rotate?: boolean; + autoClose?: boolean; + } + } +} diff --git a/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.HierarchicalData.HTML.Controls.js b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.HierarchicalData.HTML.Controls.js new file mode 100644 index 000000000..9736168c3 --- /dev/null +++ b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.HierarchicalData.HTML.Controls.js @@ -0,0 +1,116 @@ +var DlhSoft;"undefined"===typeof DlhSoft&&(DlhSoft={assemblies:[],buildReleaseDate:new Date(1,0,1)});DlhSoft.assemblies.push({assembly:"DlhSoft.HierarchicalData.HTML.Controls",company:"DlhSoft",product:"Hierarchical Data Modern Library",version:"5.3.6.0",copyright:"Copyright \u00a9 2012-2015 DlhSoft",title:"Hierarchical Data HTML Controls",description:"Hierarchical Data related HTML client components"}); +DlhSoft.buildReleaseDate=function(y,u,A){y=new Date(y,u-1,A);return y>DlhSoft.buildReleaseDate?y:DlhSoft.buildReleaseDate}(2015,9,22);var _0x5c25="Licensing{undefined{string{DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.{.{length{license{push{type{content{:{lastIndexOf{substr{buildReleaseDate{charCodeAt{pow{toUpperCase{DlhSoft Component Licensing Warning{http://DlhSoft.com/Purchase.aspx{?Assemblies={,{http://www.componentsource.com/features/dlhsoft{ (version {){This component is currently licensed to be used for testing purposes only{The component is part of this assembly{To purchase a standard license for a product that includes this assembly you can use the Purchase page{ownerDocument{div{createElement{style{position: absolute; left: 24px; top: 24px; width: 480px; display: block; z-index: 1; color: Black; background-color: #ffffc0; border: solid 1px Blue; overflow: auto{setAttribute{padding: 6px; padding-top: 8px; font-family: Arial; font-size: small{font-weight: bold; margin-bottom: 4px{appendChild{createTextNode{color: Red; margin-top: 2px; margin-bottom: 2px{margin-top: 4px{a{color: Blue; text-decoration: underline{href{target{_blank{Purchase license{margin-left: 4px; color: Blue; text-decoration: underline{javascript://{Continue trial{click{removeChild{addEventListener{\n\n{: {:\n".split("{"); +void 0==DlhSoft[_0x5c25[0]]&&(DlhSoft[_0x5c25[0]]=function(){var y=_0x5c25[1],u=_0x5c25[2],A=[],K=[],E=_0x5c25[3],G=function(x,s){if(typeof x!==u||typeof s!==u)return!1;if(s==E)return!0;var B=s[_0x5c25[11]](_0x5c25[10]);if(0<=B){var q=s[_0x5c25[12]](0,B),n,t=q[_0x5c25[11]](_0x5c25[10]);if(0<=t)try{n=new Date(parseInt(q[_0x5c25[12]](t+1)))}catch(p){}typeof n===y&&(n=new Date(2013,11,31));if(DlhSoft[_0x5c25[13]]>n)return!1;q=q+_0x5c25[10]+x;for(i=n=0;i n&&(n=Math[_0x5c25[15]](2,32)-n);q=n.toString(16)[_0x5c25[16]]();B=s[_0x5c25[12]](B+1);if(q==B)return!0}return!1},H=function(x,s,u,q,n){var t=_0x5c25[17],p=_0x5c25[18],z=typeof ComponentSource===y||!ComponentSource?p+_0x5c25[19]+q+_0x5c25[20]+n:_0x5c25[21],A=q+_0x5c25[22]+n+_0x5c25[23],E=_0x5c25[24],G=_0x5c25[25],H=_0x5c25[26];setTimeout(function(){var n=x[_0x5c25[27]],p=n[_0x5c25[29]](_0x5c25[28]);p[_0x5c25[32]](_0x5c25[30],_0x5c25[31]);var q=n[_0x5c25[29]](_0x5c25[28]);q[_0x5c25[32]](_0x5c25[30], +_0x5c25[33]);var r=n[_0x5c25[29]](_0x5c25[28]);r[_0x5c25[32]](_0x5c25[30],_0x5c25[34]);q[_0x5c25[35]](r);r[_0x5c25[35]](n[_0x5c25[36]](t));q[_0x5c25[35]](n[_0x5c25[36]](E+_0x5c25[10]));r=n[_0x5c25[29]](_0x5c25[28]);r[_0x5c25[32]](_0x5c25[30],_0x5c25[37]);r[_0x5c25[35]](n[_0x5c25[36]](s));q[_0x5c25[35]](r);q[_0x5c25[35]](n[_0x5c25[36]](G+_0x5c25[10]));r=n[_0x5c25[29]](_0x5c25[28]);r[_0x5c25[32]](_0x5c25[30],_0x5c25[37]);r[_0x5c25[35]](n[_0x5c25[36]](A));q[_0x5c25[35]](r);q[_0x5c25[35]](n[_0x5c25[36]](H+ +_0x5c25[10]));r=n[_0x5c25[29]](_0x5c25[28]);r[_0x5c25[32]](_0x5c25[30],_0x5c25[38]);var w=n[_0x5c25[29]](_0x5c25[39]);w[_0x5c25[32]](_0x5c25[30],_0x5c25[40]);w[_0x5c25[32]](_0x5c25[41],z);w[_0x5c25[32]](_0x5c25[42],_0x5c25[43]);w[_0x5c25[35]](n[_0x5c25[36]](_0x5c25[44]));r[_0x5c25[35]](w);w=n[_0x5c25[29]](_0x5c25[39]);w[_0x5c25[32]](_0x5c25[30],_0x5c25[45]);w[_0x5c25[32]](_0x5c25[41],_0x5c25[46]);w[_0x5c25[35]](n[_0x5c25[36]](_0x5c25[47]));w[_0x5c25[50]](_0x5c25[48],function(){x[_0x5c25[49]](p);K[_0x5c25[7]](u)}, +!1);r[_0x5c25[35]](w);q[_0x5c25[35]](r);p[_0x5c25[35]](q);x[_0x5c25[35]](p)},0);setTimeout(function(){alert(t+_0x5c25[51]+E+_0x5c25[52]+s+_0x5c25[51]+G+_0x5c25[53]+A+_0x5c25[51]+H+_0x5c25[4])},6E5)};return{setLicense:function(u,s){A[_0x5c25[7]]({type:u,content:s})},validate:function(x,s,B,q,n,t,p){for(var s=s+_0x5c25[4]+B,z=0;z0?"auto":c.itemHeight+"px";else{var e=a.clientHeight- +c.headerHeight-2;e<0&&(e=0);d=e+"px";if(e 0?"auto":c.itemHeight+"px"}a.isContentHeightInitialized=true}return d},H=function(a,b){if(typeof b.toggleButtonAreaWidth!=="undefined")return b.toggleButtonAreaWidth;for(var c=0,d=0;d 0){c=16;break}return b.toggleButtonAreaWidth=c},x=function(a,b){var c=a.createElement("span");c.innerHTML=b;return c},s=function(a,b){var c=a.ownerDocument,d= +c.createElementNS("http://www.w3.org/2000/svg","svg");d.setAttribute("style","width: 12px; height: 12px");d.setAttribute("focusable","false");c=c.createElementNS("http://www.w3.org/2000/svg","rect");c.setAttribute("id","PART_Border");c.setAttribute("width","12");c.setAttribute("height","12");c.setAttribute("style","fill: White; fill-opacity: 0");d.appendChild(c);a.setAttribute("id","PART_Button");typeof b.toggleButtonClass!=="undefined"&&a.setAttribute("class",b.toggleButtonClass);typeof b.toggleButtonStyle!== +"undefined"&&a.setAttribute("style",b.toggleButtonStyle);d.appendChild(a);return d},B=function(a,b){typeof b!=="object"&&(b={});A(b);var c=[{header:"",width:32,isSelection:true},{header:"Item",width:280,isTreeView:true}];c[0].cellTemplate=q(b,c[0],a);c[1].cellTemplate=z(b,c[1],a);c[1].exportCellTemplate=z(b,c[1],a,false);b.selectionMode!="Single"&&(b.selectionMode!="Extended"&&b.selectionMode!="ExtendedFocus")&&c.splice(0,1);return c},q=function(a,b,c){return function(d){return!b.isReadOnly?n(d,a, +c):getBooleanNode(d.treeGrid.ownerDocument,d.isSelected)}},n=function(a,b){var c=a.treeGrid.ownerDocument,d;if(typeof a.selectionInput==="undefined"){d=c.createElement("input");a.selectionInput=d;d.type="checkbox";d.setAttribute("style","margin: 0px")}else d=a.selectionInput;if(a.isSelected){d.setAttribute("checked","checked");if(!d.checked)d.checked=true}else if(d.checked)d.checked=false;var e=function(){d.checked?t(a,true,b.selectionMode):t(a,false,b.selectionMode)};typeof d.changeEventListener!== +"undefined"&&d.removeEventListener("change",d.changeEventListener,true);d.addEventListener("change",e,true);d.changeEventListener=e;c=function(a){if(a.keyCode==13){a.preventDefault();a.stopPropagation();e(a)}};typeof d.keyPressEventListener!=="undefined"&&d.removeEventListener("keypress",d.keyPressEventListener,true);d.addEventListener("keypress",c,true);d.keyPressEventListener=c;return d},t=function(a,b,c){a.isSelected=b;v(a,"isSelected",true,true);aa(a);if(typeof a.treeGrid!=null){a.treeGrid.selectedItem= +a;if(c!="Extended"&&c!="ExtendedFocus")a.treeGrid.selectedItems=[a];var d;if(c!="Extended"&&c!="ExtendedFocus")for(d=0;d =1&&(typeof c.allowUserToResizeColumns=== +"undefined"||c.allowUserToResizeColumns)&&(typeof b.allowUserToResize==="undefined"||b.allowUserToResize)){d.isGripperVisible=false;var h=b.treeGrid,g=function(a){d.isGripperVisible=a;d.style.cursor=a?"e-resize":"default";d.style.borderRight=a?"solid 1px "+c.border:"";e.style.width=b.width-(a?1:0)+"px"},j=c.splitterWidth;d.addEventListener("mouseover",function(a){if(!DlhSoft.Controls.TreeGrid.isGripperDragging&&!(d.isGripperDragging||typeof a.offsetX==="undefined"&&a.currentTarget!=d))g((typeof a.offsetX!== +"undefined"?a.offsetX:a.layerX-a.currentTarget.offsetLeft)>=b.width-j)},true);d.addEventListener("mousemove",function(a){if(!DlhSoft.Controls.TreeGrid.isGripperDragging&&!(d.isGripperDragging||typeof a.offsetX==="undefined"&&a.currentTarget!=d))g((typeof a.offsetX!=="undefined"?a.offsetX:a.layerX-a.currentTarget.offsetLeft)>=b.width-j)},true);e.addEventListener("mouseover",function(a){!DlhSoft.Controls.TreeGrid.isGripperDragging&&(!d.isGripperDragging&&!(typeof a.offsetX!=="undefined"||a.currentTarget!= +e))&&g(a.layerX-a.currentTarget.offsetLeft>=b.width-j)},false);e.addEventListener("mousemove",function(a){!DlhSoft.Controls.TreeGrid.isGripperDragging&&(!d.isGripperDragging&&!(typeof a.offsetX!=="undefined"||a.currentTarget!=e))&&g(a.layerX-a.currentTarget.offsetLeft>=b.width-j)},false);d.addEventListener("mousedown",function(a){if(!(a.button!=0||!d.isGripperVisible||DlhSoft.Controls.TreeGrid.isGripperDragging)){DlhSoft.Controls.TreeGrid.isGripperDragging=true;d.isGripperDragging=true;d.initialGripperDraggingX= +a.clientX;d.initialColumnWidth=b.width}},true);a.addEventListener("mousemove",function(a){if(d.isGripperDragging){b.width=Math.max(b.minWidth,d.initialColumnWidth+(a.clientX-d.initialGripperDraggingX));if(typeof b.maxWidth!=="undefined"&&b.width>b.maxWidth)b.width=b.maxWidth;e.style.width=b.width-1+"px";typeof c.columnWidthChangeHandler!=="undefined"&&setTimeout(function(){c.columnWidthChangeHandler(b,b.width)},0);if(!h.isWaitingToRefreshColumns){h.isWaitingToRefreshColumns=true;setTimeout(function(){var a= +U(c.columns);h.gridHeader.style.width=a+"px";h.gridContent.style.width=a+"px";delete h.isWaitingToRefreshColumns;h.refreshGridItems()},0)}}},true);a.addEventListener("mouseup",function(){if(d.isGripperDragging){delete d.isGripperDragging;delete d.initialGripperDraggingX;delete d.initialColumnWidth;g(false);delete DlhSoft.Controls.TreeGrid.isGripperDragging}},true);d.addEventListener("mouseout",function(){d.isGripperDragging||g(false)},false)}return d},N=function(a,b){for(var c=-1,d=null,e=null,f= +[],h=0;h j){g.indentation=j;v(g,"indentation",false,true)}d.hasChildren=g.indentation>d.indentation;if(d.hasChildren&&typeof d.isMilestone!=="undefined"&& +d.isMilestone){d.isMilestone=false;v(d,"isMilestone",false,true)}}g.isVisible=c<0||g.indentation<=c;if(g.isVisible&&!g.isExpanded)c=g.indentation;g.isExpanded&&g.indentation==c&&(c=-1);d=g}if(d!=null)d.hasChildren=false;b.selectedItem=e;b.selectedItems=f},O=function(a,b,c){c.isHierarchicalInformationInitialized=false;var b=[],d,e;for(e=0;e 0&&(f=b[b.length-1]);f!=null&&d.indentation<=f.indentation;){b.pop();f=b[b.length-1]}d.parent=f;d.children= +[];f!=null&&f.children.push(d);(f==null||d.indentation>f.indentation)&&b.push(d)}c.isHierarchicalInformationInitialized=true},r=function(a,b,c,d,e){for(var f=0,h=0;h 0;)if(g.indexOf(a.childNodes[m])>=0){o=m;break}for(m=a.childNodes.length;m-- > +0;)a.removeChild(a.childNodes[m]);for(m=0;m =0&&setTimeout(function(){try{for(var b=a.childNodes[o];b.nodeName!="input"&&b.nodeName!="textarea"&&b.nodeName!="label"&&b.nodeName!="select"&&b.nodeName!="button"&&b.childNodes.length>0;)b=b.childNodes[0];b&&b.dontAutoFocus?delete b.dontAutoFocus:setTimeout(function(){try{b.focus()}catch(a){}},0)}catch(c){}},0)};if(b.wasGridItemContentLoaded)setTimeout(g,0);else{g(); +b.wasGridItemContentLoaded=true}}},W=function(a){if(typeof a.isWaitingToRefreshGridItem==="undefined"){a.isWaitingToRefreshGridItem=true;setTimeout(function(){typeof a.gridItem!=="undefined"&&Q(a.gridItem,a,a.treeGrid.items,a.treeGrid.settings.columns,a.treeGrid.settings.toggleButtonAreaWidth,a.treeGrid.settings);V(a,a.treeGrid.items,a.treeGrid.settings);delete a.isWaitingToRefreshGridItem},0)}},ta=function(a,b,c,d,e,f){var h=b.treeGrid.ownerDocument;(!f.isVirtualizing||typeof b.isVirtuallyVisible!== +"undefined"&&b.isVirtuallyVisible)&&setTimeout(function(){if(typeof b.gridItemSelectionContainer!=="undefined"){var g=b.gridItemSelectionContainer;typeof f.selectedItemClass!=="undefined"&&g.setAttribute("class",b.isSelected?f.selectedItemClass:null);typeof f.selectedItemStyle!=="undefined"&&g.setAttribute("style",b.isSelected?f.selectedItemStyle:null)}var g=[],j=null;try{j=h.activeElement}catch(m){}for(;j!=null&&j!=b.gridItem;){g.push(j);j=j.parentNode}for(var k=-1,j=a.childNodes.length;j-- >0;)if(a.childNodes[j].isSelection&& +g.indexOf(a.childNodes[j])>=0){k=j;break}for(j=a.childNodes.length;j-- >0;)a.childNodes[j].isSelection&&a.removeChild(a.childNodes[j]);for(j=0;j =0&&setTimeout(function(){try{for(var b=a.childNodes[k];b.nodeName!="input"&&b.nodeName!="textarea"&&b.nodeName!="label"&&b.nodeName!="select"&&b.nodeName!="button"&&b.childNodes.length>0;)b=b.childNodes[0]; +b&&b.dontAutoFocus?delete b.dontAutoFocus:setTimeout(function(){try{b.focus()}catch(a){}},0)}catch(c){}},0)},0)},aa=function(a){typeof a.gridItem!=="undefined"&&ta(a.gridItem,a,a.treeGrid.items,a.treeGrid.settings.columns,a.treeGrid.settings.toggleButtonAreaWidth,a.treeGrid.settings)},ca=function(a,b,c,d,e){var f=a.treeGrid.ownerDocument,h=f.createElement("div"),g=0;c.isTreeView==true&&(g=e.indentationLevelWidth*a.indentation);h.setAttribute("style","overflow: hidden; vertical-align: middle; display: table-cell; -webkit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing; margin: 0px; padding: 0px; width: "+ +c.width+"px; height: "+e.itemHeight+"px; padding-left: "+g+"px");var j=f.createElement("div");typeof c.cellClass!=="undefined"?j.setAttribute("class",c.cellClass):typeof e.cellClass!=="undefined"&&j.setAttribute("class",e.cellClass);typeof c.cellStyle!=="undefined"?j.setAttribute("style",c.cellStyle):typeof e.cellStyle!=="undefined"&&j.setAttribute("style",e.cellStyle);var m=f.createElement("div");m.setAttribute("style","white-space: nowrap; overflow: hidden; margin: 0px; padding: 0px; width: "+(c.width- +g-16)+"px");if(c.isTreeView==true){g=f.createElement("div");g.setAttribute("style","display: inline-block; width: "+d+"px");if(a.hasChildren){d=f.createElement("div");d.setAttribute("style","cursor: default; padding-left: 1px; font-size: 12px; display: inline-block");f=e.collapsedToggleButtonTemplate;if(a.isExpanded)f=e.expandedToggleButtonTemplate;f=f();d.appendChild(f);da(d,a,b,f,null,null,e);g.appendChild(d)}m.appendChild(g)}a=c.cellTemplate(a);m.appendChild(a);j.appendChild(m);h.appendChild(j); +h.isSelection=c.isSelection;return h},Z=function(a,b){return function(){var c=a.ownerDocument.createElementNS("http://www.w3.org/2000/svg","polygon");c.setAttribute("points","3.5,2.5 3.5,11.5 10.5,6.5");return s(c,b)}},$=function(a,b){return function(){var c=a.ownerDocument.createElementNS("http://www.w3.org/2000/svg","polygon");c.setAttribute("points","2.5,3.5 11.5,3.5 6.5,10.5");return s(c,b)}},da=function(a,b,c,d,e,f,h){if(typeof e==="undefined"||e==null)e=d.querySelector("#PART_Button");e!=null&& +ea(e,e,h);if(typeof f==="undefined"||f==null)f=d.querySelector("#PART_Border");f!=null&&ea(f,e,h);c={toggleButton:a,item:b,items:c,content:d,settings:h};if(e!=null){e.tag=c;(typeof h.isExport==="undefined"||!h.isExport)&&e.addEventListener("mouseup",X,true)}if(f!=null){f.tag=c;(typeof h.isExport==="undefined"||!h.isExport)&&f.addEventListener("mouseup",X,true)}a.tag=c;e==null&&(f==null&&(typeof h.isExport==="undefined"||!h.isExport))&&a.addEventListener("mouseup",X,true);d.addEventListener("keypress", +function(a){if(a.keyCode==32){a.preventDefault();a.stopPropagation();C(b,!b.isExpanded,true)}},true);b.toggleButton=a},ea=function(a,b,c){if(!(typeof c.isExport!=="undefined"&&c.isExport)){a.addEventListener("mouseover",function(){typeof c.toggleButtonHoveringClass!=="undefined"&&b.setAttribute("class",c.toggleButtonHoveringClass);typeof c.toggleButtonHoveringStyle!=="undefined"&&b.setAttribute("style",c.toggleButtonHoveringStyle)},true);a.addEventListener("mouseout",function(){b.setAttribute("class", +c.toggleButtonClass);b.setAttribute("style",c.toggleButtonStyle)},true)}},X=function(a){a.stopPropagation();a=a.target.tag.item;C(a,!a.isExpanded,true)},C=function(a,b,c,d){if(a.isExpanded!=b){a.isExpanded=b;(typeof d==="undefined"||d)&&v(a,"isExpanded",c,true);fa(a)}},fa=function(a,b){if(typeof a.toggleButton==="undefined")(typeof b==="undefined"||b)&&setTimeout(function(){fa(a,false)},0);else{var c=a.toggleButton,d=c.tag,e=d.settings,f=e.expandedToggleButtonTemplate,h=e.collapsedToggleButtonTemplate; +a.isExpanded&&(h=f);var f=h(),h=f.querySelector("#PART_Button"),g=f.querySelector("#PART_Border");c.replaceChild(f,d.content);d.content=f;d=d.items;da(c,a,d,f,h,g,e);a.isVisible&&!(typeof a.isHidden!=="undefined"&&a.isHidden)&&ua(d,a,e);P(d,e)}},ua=function(a,b,c){var d=-1,e=false,f=false,h=false,g=0,j,m,k;for(m=0;m =0&&R(b[c]);R(a);c=a.index+ +1;c =b.gridHeaderContainer.clientHeight+b.gridContentContainer.clientHeight-24){c=b.gridContentContainer.scrollTop;b.gridContentContainer.scrollTop=b.gridContentContainer.scrollTop+20;if(typeof b.isDuringVerticalScrolling=== +"undefined"){b.isDuringVerticalScrolling=true;setTimeout(function(){d=b.gridContentContainer.scrollTop-c;b.draggingInitialThumbPosition=b.draggingInitialThumbPosition+d;delete b.isDuringVerticalScrolling},0)}}}},ga=function(a){var b=a.itemTop-a.treeGrid.gridContentContainer.scrollTop;if(b<0)a.treeGrid.gridContentContainer.scrollTop=a.itemTop;else if(b>a.treeGrid.gridContentContainer.clientHeight-a.treeGrid.settings.itemHeight)a.treeGrid.gridContentContainer.scrollTop=a.itemTop-(a.treeGrid.gridContentContainer.clientHeight- +a.treeGrid.settings.itemHeight)},sa=function(a,b,c,d,e,f,h,g){b.addEventListener("scroll",function(){if(d.scrollLeft!=b.scrollLeft)d.scrollLeft=b.scrollLeft;I(h,b,g)},true);ha(b,c,e,g);typeof a.updateGridHeaderTimer!=="undefined"&&clearInterval(a.updateGridHeaderTimer);a.updateGridHeaderTimer=setInterval(function(){try{ha(b,c,e,g)}catch(d){try{clearInterval(a.updateGridHeaderTimer)}catch(f){}}},100);window.addEventListener("mousewheel",function(){try{a.cancelDrag=true}catch(b){}},true)},ha=function(a, +b,c,d){setTimeout(function(){try{var e=b.clientWidth-a.clientWidth;e<0&&(e=0);var f=e+"px";if(c.style.width!=f){c.style.width=f;if(e>0){c.style.boxSizing="border-box";c.style.MozBoxSizing="border-box";c.style.border="solid 1px "+d.border;c.style.borderTop="none";c.style.borderRight="none"}else{c.style.border="";c.style.borderTop="";c.style.borderRight="";c.style.boxSizing="";c.style.MozBoxSizing=""}}}catch(h){}},0)},I=function(a,b,c){if(c.isVirtualizing)for(var d=b.scrollTop-c.itemHeight,b=d+b.clientHeight+ +2*c.itemHeight,e=0;e =d&&f.itemTop=b))&&delete f.isVirtuallyVisible}},ra=function(a,b){for(var c=a.childNodes.length;c-- >0;)a.removeChild(a.childNodes[c]);a.appendChild(b)},Y=function(a,b,c,d){var e=d.indexOf(a);if(!(e<0||b<0||b==e||b>=d.length)){d.splice(e,1);d.splice(b,0,a);ia(d);u(c);typeof c.settings.itemMoveHandler!=="undefined"&&c.settings.itemMoveHandler(a,e,b)}},T=function(a,b,c,d,e){if(!(a<0||c<0||c==a||c>e.length-b)){var f=[],h;for(h=a;h< +a+b;h++)f.push(e[h]);e.splice(a,b);for(h=0;h b){d.indentation=b;v(d,"indentation",false,true)}b=d.indentation+1}},xa=function(a,b,c,d,e,f,h,g,j,m){a.addEventListener("mousedown",function(c){if(c.button==0){delete d.cancelDrag;d.draggingItem=b;d.dragType="Ordering"; +d.style.cursor=a.style.cursor;d.draggingInitialY=c.clientY;d.draggingInitialThumbPosition=0;c.preventDefault()}},true);if(typeof d.draggableOrderingItems==="undefined")d.draggableOrderingItems=[];for(var k=false,o=0;o e+1)){n={content:f.content,indentation:f.indentation,"class":f["class"],style:f.style,isSummaryEnabled:f.isSummaryEnabled,isHidden:f.isHidden,isExported:true,tag:f};ya(n,f);a.push(n);f.exportItem=n}}var s=D.createElement("p");s.innerHTML=typeof b!=="undefined"? +b:"";D.body.appendChild(s);var r=D.createElement("div");r.setAttribute("style","width: "+q+"px");try{DlhSoft.Controls.TreeGrid.initialize(r,a,k,"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.")}catch(u){}setTimeout(function(){t&&D.body.setAttribute("style","margin: 0px");var a=D.createElement("div");a.appendChild(r);D.body.replaceChild(a,s);if(g){a.setAttribute("style","width: "+r.offsetHeight+"px; height: "+ +q+"px; overflow: hidden");a=Math.round((r.offsetWidth-r.offsetHeight)/2);r.setAttribute("style","width: "+q+"px; transform: rotate(90deg) translateX("+a+"px) translateY("+a+"px); -webkit-transform: rotate(90deg) translateX("+a+"px) translateY("+a+"px)")}D.close();if(typeof p!==void 0){p.focus();if(typeof h!=="undefined"&&h){p.print();(typeof j==="undefined"||j)&&p.close()}}},0)},ka=function(a,b,c){typeof c==="undefined"&&(c=false);var d=a.parent,e=a.index;if(d==null){for(d=0;e-- >0;){a=b[e];a.indentation== +0&&d++}return d+(!c?1:0)}return ka(d,b)+"."+(d.children.indexOf(a)+(!c?1:0))},pa=function(a,b,c){var d;for(d=0;d 0?b[e-1]:null;h=h!=null?h.indentation+1:0;if(d.indentation>h)d.indentation=h}else if(typeof d.indentation==="undefined"||d.indentation h.indentation)d.indentation=h.indentation;E([d],c);b.splice(e,0,d);N(b,a);O(b,c,a);var g,j=null;if(e 0){for(g=b[f-1];g.parent!=null;)g=g.parent;j=g.isExpanded;d.hasChildren&&C(g,d.isExpanded,false,true);g.indentation>=d.indentation&&(g=null)}else b[0].isExpanded||C(b[0],true,false,true);var m=f+1 d.indentation)&&C(m,true,false,true);var k=m!=null?m.indentation:null;b.splice(f,1);N(b,a);O(b,c,a);typeof d.gridItemContainer!=="undefined"&&a.gridContent.removeChild(d.gridItemContainer); +m=f =b.length&&(f=b.length-1);f>=0&&M(b[f],b,a,c);I(b,a.gridContentContainer,c)};a.removeItems=function(b){for(var c=0;c 0?a.items[d.index-1]:null;if(!(f==null||d.indentation>f.indentation)){C(d,true,false,true);d.indentation++;v(d,"indentation",true,true);S(b,c)&&L(b);for(M(d,b,a,c);d!=null;){d.isExpanded||C(d,true,false);d=d.parent}}};a.decreaseItemIndentation=function(d){var f=d.index =b.length-1||Y(c,d+1,a,b)};a.moveItemHierarchy= +function(c,d){for(var h=b.indexOf(c),g=h+1;g 0;){if(b[g].indentation 100&&(a=100);d(a)},e,f,h)},timeSpanInputColumnTemplateBase:function(a,b,c,d,e,f,h,g){typeof e==="undefined"&& +(e=1);return DlhSoft.Controls.TreeGrid.numberInputColumnTemplateBase(a,b,function(){var a=c()/(hourDuration*e);return Math.round(a*100)/100},function(a){a=parseFloat(a);a<0&&(a=0);d(a*hourDuration*e)},f,h,g)},datePickerInputColumnTemplateBase:function(a,b,c,d,e,f,h,g,j,m,k,o,n){k||(k=["Su","Mo","Tu","We","Th","Fr","Sa"]);o||(o=function(a){return a.toString()});n||(n=function(a){return new Date(a)});var l=a.createElement("input");l.setAttribute("type","text");c=c();typeof c==="undefined"?c="":c!=null&& +(c=o(c));l.setAttribute("value",c);DlhSoft.Controls.DatePicker&&l.addEventListener("focus",function(){var b=DlhSoft.Controls.DatePicker.get(l);if(!b||!b.isOpen){var c=0,d=0;try{c=l.selectionStart;d=l.selectionEnd}catch(e){}b=DlhSoft.Controls.DatePicker.initialize(l,void 0,{inputStyle:null,defaultTimeOfDay:g,isDropDownButtonVisible:false,popupStyle:"margin-top: 1px; background-color: White; border: 1px solid #e0e0e0",calendarSelectorLevels:j,months:m,daysOfWeek:getAbbreviations(k),dateTimeFormatter:o, +dateTimeParser:n},"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.");b.openDropDown();setTimeout(function(){try{l.selectionStart=c;l.selectionEnd=d}catch(a){}},100);navigator.userAgent.match(/(Android)|(IPad)|(IPhone)/i)==null?setTimeout(function(){try{l.focus()}catch(a){}},100):a.createEvent&&setTimeout(function(){var b=a.createEvent("MouseEvents");b.initEvent("blur",true,false);l.dispatchEvent(b)})}},true);c= +"";typeof f!=="undefined"&&!f()&&(c="; display: none");f="";typeof h!=="undefined"&&h()&&(f="; font-weight: bold");l.setAttribute("style","background-color: Transparent; width: "+b+"px; border-width: 0px; padding: 0px"+c+f);typeof e!=="undefined"&&!e()&&l.setAttribute("disabled","true");var p=function(){var a=l.value,a=a!=""?n(a):null;d(a)};l.addEventListener("change",function(){p()},true);l.addEventListener("keypress",function(a){if(a.keyCode==13){a.preventDefault();a.stopPropagation();p()}},true); +l.addEventListener("focus",function(){l.style.backgroundColor="White"},true);l.addEventListener("blur",function(){l.style.backgroundColor="Transparent"},true);return l},dateTimePickerInputColumnTemplateBase:function(a,b,c,d,e,f,h,g,j,m,k,o,n){k||(k=["Su","Mo","Tu","We","Th","Fr","Sa"]);o||(o=function(a){return a.toString()});n||(n=function(a){return new Date(a)});var l=a.createElement("input");l.setAttribute("type","text");c=c();typeof c==="undefined"?c="":c!=null&&(c=o(c));l.setAttribute("value", +c);(DlhSoft.Controls.DateTimePicker||DlhSoft.Controls.DatePicker)&&l.addEventListener("focus",function(){var b=(DlhSoft.Controls.DateTimePicker?DlhSoft.Controls.DateTimePicker:DlhSoft.Controls.DatePicker).get(l);if(!b||!b.isOpen){var c=0,d=0;try{c=l.selectionStart;d=l.selectionEnd}catch(e){}b=(DlhSoft.Controls.DateTimePicker?DlhSoft.Controls.DateTimePicker:DlhSoft.Controls.DatePicker).initialize(l,void 0,{inputStyle:null,defaultTimeOfDay:g,isDropDownButtonVisible:false,popupStyle:"margin-top: 1px; background-color: White; border: 1px solid #e0e0e0", +calendarSelectorLevels:j,months:m,daysOfWeek:getAbbreviations(k),dateTimeFormatter:o,dateTimeParser:n},"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.");b.openDropDown();setTimeout(function(){try{l.selectionStart=c;l.selectionEnd=d}catch(a){}},100);navigator.userAgent.match(/(Android)|(IPad)|(IPhone)/i)==null?setTimeout(function(){try{l.focus()}catch(a){}},100):a.createEvent&&setTimeout(function(){var b=a.createEvent("MouseEvents"); +b.initEvent("blur",true,false);l.dispatchEvent(b)})}},true);c="";typeof f!=="undefined"&&!f()&&(c="; display: none");f="";typeof h!=="undefined"&&h()&&(f="; font-weight: bold");l.setAttribute("style","background-color: Transparent; width: "+b+"px; border-width: 0px; padding: 0px"+c+f);typeof e!=="undefined"&&!e()&&l.setAttribute("disabled","true");var p=function(){var a=l.value,a=a!=""?n(a):null;d(a)};l.addEventListener("change",function(){p()},true);l.addEventListener("keypress",function(a){if(a.keyCode== +13){a.preventDefault();a.stopPropagation();p()}},true);l.addEventListener("focus",function(){l.style.backgroundColor="White"},true);l.addEventListener("blur",function(){l.style.backgroundColor="Transparent"},true);return l},multiSelectorComboBoxInputColumnTemplateBase:function(a,b,c,d,e,f,h,g){var j=a.createElement("input");j.setAttribute("type","text");d=d();typeof d==="undefined"&&(d="");j.setAttribute("value",d);DlhSoft.Controls.MultiSelectorComboBox&&j.addEventListener("focus",function(){var b= +DlhSoft.Controls.MultiSelectorComboBox.get(j);if(!b||!b.isOpen&&b.availableChoices.length>0){var b=c(),d=0,e=0;try{d=j.selectionStart;e=j.selectionEnd}catch(f){}b=DlhSoft.Controls.MultiSelectorComboBox.initialize(j,b,void 0,{inputStyle:null,autoAppendAvailableChoices:false,isDropDownButtonVisible:false,popupStyle:"margin-top: 1px; background-color: White; border: 1px solid #e0e0e0; color: Black; font-size: small; max-height: 188px; overflow-y: auto"},"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase."); +b.openDropDown();setTimeout(function(){try{j.selectionStart=d;j.selectionEnd=e}catch(a){}},100);navigator.userAgent.match(/(Android)|(IPad)|(IPhone)/i)==null?setTimeout(function(){try{j.focus()}catch(a){}},100):a.createEvent&&setTimeout(function(){var b=a.createEvent("MouseEvents");b.initEvent("blur",true,false);j.dispatchEvent(b)})}},true);d="";typeof h!=="undefined"&&!h()&&(d="; display: none");h="";typeof g!=="undefined"&&g()&&(h="; font-weight: bold");j.setAttribute("style","background-color: Transparent; width: "+ +b+"px; border-width: 0px; padding: 0px"+d+h);typeof f!=="undefined"&&!f()&&j.setAttribute("disabled","true");j.addEventListener("change",function(){e(j.value)},true);j.addEventListener("keypress",function(a){if(a.keyCode==13){a.preventDefault();a.stopPropagation();e(j.value)}},true);j.addEventListener("focus",function(){j.style.backgroundColor="White"},true);j.addEventListener("blur",function(){j.style.backgroundColor="Transparent"},true);return j},dateTimeInputColumnTemplateBase:function(a,b,c,d, +e,f,h){return DlhSoft.Controls.TreeGrid.textInputColumnTemplateBase(a,b,function(){var a=c();return a!=null?a.toString():""},function(a){a=a!=""?new Date(a):null;d(a)},e,f,h)},getIndexColumnTemplate:function(){return function(a){var b=a.treeGrid;return DlhSoft.Controls.TreeGrid.textColumnTemplateBase(b.ownerDocument,function(){return b.getItemIndexString(a)})}},getWbsColumnTemplate:function(a){return function(b){var c=b.treeGrid;return DlhSoft.Controls.TreeGrid.textColumnTemplateBase(c.ownerDocument, +function(){return c.getItemWbsIndexString(b,a)})}},getIconColumnTemplate:function(a,b,c,d,e,f,h,g,j){if(typeof a==="string")var m=a,a=function(){return m};typeof d==="undefined"||d==false?d=function(){return false}:d==true&&(d=function(){return true});return function(k){var m=k.treeGrid,n=m.ownerDocument.createElement("img");n.setAttribute("src",a(k));typeof b!=="undefined"&&n.setAttribute("class",b);typeof c!=="undefined"&&n.setAttribute("style",c);if(!m.settings.isReadOnly&&d(k)){n.style.cursor= +"move";xa(n,k,m.items,m,m.settings,e,f,h,g,j)}return n}}}}()); diff --git a/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.Angular.Components.ts b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.Angular.Components.ts new file mode 100644 index 000000000..3b388a74d --- /dev/null +++ b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.Angular.Components.ts @@ -0,0 +1,94 @@ +import { Component, OnInit, ElementRef, Input } from '@angular/core'; +import GanttChartItem = DlhSoft.Controls.GanttChartView.Item; +import GanttChartSettings = DlhSoft.Controls.GanttChartView.Settings; +import ScheduleChartItem = DlhSoft.Controls.ScheduleChartView.Item; +import ScheduleChartSettings = DlhSoft.Controls.ScheduleChartView.Settings; +import LoadChartItem = DlhSoft.Controls.LoadChartView.Item; +import LoadChartSettings = DlhSoft.Controls.LoadChartView.Settings; + +@Component({ + selector: 'ganttchartview', + template: ' ' +}) +export class GanttChartView implements OnInit { + rootElement: HTMLElement; + @Input() style: string = ""; + @Input() items: GanttChartItem[] = []; + @Input() settings: GanttChartSettings = {}; + @Input() license: string; + @Input() change: (item: GanttChartItem, propertyName: string, isDirect: boolean, isFinal: boolean) => void; + constructor(elementRef: ElementRef) { + this.rootElement =elementRef.nativeElement; + } + ngOnInit() { + var element = this.rootElement.firstChild; + element.setAttribute('style', this.style); + var changeHandler = this.settings.itemPropertyChangeHandler; + DlhSoft.Controls.GanttChartView.initialize(element, this.items, this.settings, this.license); + if (this.change) { + this.settings.itemPropertyChangeHandler = (item, propertyName, isDirect, isFinal) => { + if (changeHandler) + changeHandler(item, propertyName, isDirect, isFinal); + this.change(item, propertyName, isDirect, isFinal); + } + } + } +} + +@Component({ + selector: 'schedulechartview', + template: ' ' +}) +export class ScheduleChartView implements OnInit { + rootElement: HTMLElement; + @Input() style: string = ""; + @Input() items: ScheduleChartItem[] = []; + @Input() settings: ScheduleChartSettings = {}; + @Input() license: string; + @Input() change: (item: GanttChartItem, propertyName: string, isDirect: boolean, isFinal: boolean) => void; + constructor(elementRef: ElementRef) { + this.rootElement =elementRef.nativeElement; + } + ngOnInit() { + var element = this.rootElement.firstChild; + element.setAttribute('style', this.style); + var changeHandler = this.settings.itemPropertyChangeHandler; + DlhSoft.Controls.ScheduleChartView.initialize(element, this.items, this.settings, this.license); + if (this.change) { + this.settings.itemPropertyChangeHandler = (item, propertyName, isDirect, isFinal) => { + if (changeHandler) + changeHandler(item, propertyName, isDirect, isFinal); + this.change(item, propertyName, isDirect, isFinal); + } + } + } +} + +@Component({ + selector: 'loadchartview', + template: ' ' +}) +export class LoadChartView implements OnInit { + rootElement: HTMLElement; + @Input() style: string = ""; + @Input() items: LoadChartItem[] = []; + @Input() settings: LoadChartSettings = {}; + @Input() license: string; + @Input() change: (item: GanttChartItem, propertyName: string, isDirect: boolean, isFinal: boolean) => void; + constructor(elementRef: ElementRef) { + this.rootElement =elementRef.nativeElement; + } + ngOnInit() { + var element = this.rootElement.firstChild; + element.setAttribute('style', this.style); + var changeHandler = this.settings.itemPropertyChangeHandler; + DlhSoft.Controls.LoadChartView.initialize(element, this.items, this.settings, this.license); + if (this.change) { + this.settings.itemPropertyChangeHandler = (item, propertyName, isDirect, isFinal) => { + if (changeHandler) + changeHandler(item, propertyName, isDirect, isFinal); + this.change(item, propertyName, isDirect, isFinal); + } + } + } +} diff --git a/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.Angular.Directives.js b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.Angular.Directives.js new file mode 100644 index 000000000..e628d44a8 --- /dev/null +++ b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.Angular.Directives.js @@ -0,0 +1,60 @@ +// Version 1.0.0.0. +var module = angular.module("DlhSoft.ProjectData.GanttChart.Directives", []); +dsDefinePDGCDirective(module, "GanttChart"); +dsDefinePDGCDirective(module, "ScheduleChart"); +dsDefinePDGCDirective(module, "LoadChart"); +function dsDefinePDGCDirective(module, directiveName, controlName) { + module.directive("ds" + directiveName, function () { + return { + restrict: "EAC", + replace: true, + transclude: true, + scope: { + items: "=", + settings: "=", + change: "=", + autoRefresh: "@", + license: "=" + }, + template: " ", + link: function (scope, element) { + var controlElement = element[0]; + var initialization = function () { + var items = scope.items; + if (!items) + items = []; + var settings = scope.settings; + if (!settings) + settings = {}; + var license = scope.license; + var changeHandler = settings.itemPropertyChangeHandler; + DlhSoft.Controls[controlName ? controlName : directiveName + "View"].initialize(controlElement, items, settings, license); + if (scope.change) { + settings.itemPropertyChangeHandler = function (item, propertyName, isDirect, isFinal) { + if (changeHandler) + changeHandler(item, propertyName, isDirect, isFinal); + scope.change(item, propertyName, isDirect, isFinal); + } + } + } + initialization(); + var isWaitingToRefresh = false; + var refresh = function() { + if (isWaitingToRefresh) + return; + isWaitingToRefresh = true; + setTimeout(function () { + initialization(); + isWaitingToRefresh = false; + }); + } + setTimeout(function () { + scope.$watch("items", refresh); + scope.$watch("settings", refresh); + if (scope.autoRefresh == "true") + scope.$watch(refresh); + }, 0); + } + }; + }); +} diff --git a/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.HTML.Controls.Extras.d.ts b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.HTML.Controls.Extras.d.ts new file mode 100644 index 000000000..4614e1c4f --- /dev/null +++ b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.HTML.Controls.Extras.d.ts @@ -0,0 +1,86 @@ +///+declare module DlhSoft.Controls.GanttChartView.ProjectSerializer { + function initialize(control: GanttChartView.Element, settings?: Settings): Service; + class Service { + public control: GanttChartView.Element; + public settings: Settings; + constructor(control: GanttChartView.Element, settings?: Settings); + private static secondDuration; + private static minuteDuration; + private static hourDuration; + private static dayDuration; + private static weekDuration; + public loadXml(xml: string): void; + public importXml(input: any): void; + private static parseXmlToTimeSpan(value); + private static parseXmlToDateTime(value); + private static indexOfKey(dictionary, key); + static projectXmlTemplate: string; + static scheduleWeekDayXmlTemplate: string; + static scheduleDayWorkingTimesXmlTemplate: string; + static taskXmlTemplate: string; + static predecessorXmlTemplate: string; + static resourceXmlTemplate: string; + static assignmentXmlTemplate: string; + public getXml(): string; + private getXmlInternal(compact?); + private saveProjectInfo(template, values); + private saveGanttChartItem(item, template, values); + private savePredecessorItem(item, predecessorItem, template, values); + private saveResourceInfo(resource, template, values); + private saveAssignmentInfo(item, resource, allocationUnits, template, values); + private static applyStringTemplateValues(template, values); + private static convertDateToXml(dateTime); + private static convertDayTimeToXml(dayTime); + private static convertTimeSpanToXml(timeSpan); + public exportXml(output?: any): any; + static initializeSettings(settings: Settings): void; + } + interface Settings { + assignableResources?: string[]; + projectInfoLoadingHandler? (e: ElementLoadingEventArgs): void; + ganttChartItemLoadingHandler? (e: GanttChartItemLoadingEventArgs): void; + assignmentInfoLoadingHandler? (e: AssignmentInfoLoadingEventArgs): void; + predecessorItemLoadingHandler? (e: PredecessorItemLoadingEventArgs): void; + assignableResourceInfoLoadingHandler? (e: AssignableResourceInfoLoadingEventArgs): void; + projectInfoSavingHandler? (e: ElementSavingEventArgs): void; + ganttChartItemSavingHandler? (e: GanttChartItemSavingEventArgs): void; + predecessorItemSavingHandler? (e: PredecessorItemSavingEventArgs): void; + resourceInfoSavingHandler? (e: ResourceInfoSavingEventArgs): void; + assignmentInfoSavingHandler? (e: AssignmentInfoSavingEventArgs): void; + compact?: boolean; + spaceSeparated?: boolean; + } + interface ElementLoadingEventArgs { + sourceElement: GanttChartView.Element; + } + interface GanttChartItemLoadingEventArgs extends ElementLoadingEventArgs { + ganttChartItem: GanttChartView.Item; + } + interface AssignmentInfoLoadingEventArgs extends GanttChartItemLoadingEventArgs { + resource: string; + allocationUnits: number; + } + interface PredecessorItemLoadingEventArgs extends GanttChartItemLoadingEventArgs { + predecessorItem: GanttChartView.PredecessorItem; + } + interface AssignableResourceInfoLoadingEventArgs extends ElementLoadingEventArgs { + resource: string; + } + interface ElementSavingEventArgs { + outputXml: string; + } + interface GanttChartItemSavingEventArgs extends ElementSavingEventArgs { + ganttChartItem: GanttChartView.Item; + } + interface PredecessorItemSavingEventArgs extends GanttChartItemSavingEventArgs { + predecessorItem: GanttChartView.PredecessorItem; + } + interface ResourceInfoSavingEventArgs extends ElementSavingEventArgs { + resource: string; + } + interface AssignmentInfoSavingEventArgs extends GanttChartItemSavingEventArgs { + resource: string; + allocationUnits: number; + } +} diff --git a/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.HTML.Controls.Extras.js b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.HTML.Controls.Extras.js new file mode 100644 index 000000000..217f29dcd --- /dev/null +++ b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.HTML.Controls.Extras.js @@ -0,0 +1,34 @@ +"undefined"===typeof DlhSoft&&(DlhSoft={assemblies:[],buildReleaseDate:new Date(1,0,1)});DlhSoft.assemblies.push({assembly:"DlhSoft.ProjectData.GanttChart.HTML.Controls.Extras",company:"DlhSoft",product:"Project Data Modern Library",version:"5.1.10.5",copyright:"Copyright \ufffd 2013-2019 DlhSoft",title:"Project Data Gantt Chart HTML Controls Extras",description:"Project Data Gantt Chart related HTML client extra components"}); +DlhSoft.buildReleaseDate=function(i,C,p){i=new Date(i,C-1,p);return i>DlhSoft.buildReleaseDate?i:DlhSoft.buildReleaseDate}(2014,1,15);var DlhSoft; +(function(i){(function(i){(function(p){(function(i){i.initialize=function(a,b){return new J(a,b)};var J=function(){function a(b,c){this.control=b;this.settings=c;"undefined"===typeof c&&(c={});this.settings=c;a.initializeSettings(this.settings)}a.prototype.loadXml=function(b){this.importXml(b)};a.prototype.importXml=function(b){var c=this.control,e=c.items,g=c.settings,d=null;if("undefined"!==typeof b&&("undefined"!==typeof b.document&&(b=b.document),"undefined"!==typeof b.getElementsByTagName))d= +b,1!=d.getElementsByTagName("Project").length&&(b=d.body.innerHTML,b=b.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/
/g,"\n"),d=null);null==d&&(d=(new DOMParser).parseFromString(b.toString(),"text/xml"));var b=[],W=[],i=[],q=[];"undefined"!==typeof this.settings.assignableResources&&this.settings.assignableResources.splice(0,this.settings.assignableResources.length);d=d.getElementsByTagName("Project")[0];if("undefined"!==typeof d){var k,l,s,h;try{var n=d.getElementsByTagName("CalendarUID")[0].childNodes[0].nodeValue, +r,f,y=d.getElementsByTagName("Calendars")[0].getElementsByTagName("Calendar");for(f=0;fd?1:-1});var z=n[0];k=parseInt(z.getElementsByTagName("DayType")[0].childNodes[0].nodeValue)-1;l=parseInt(n[n.length-1].getElementsByTagName("DayType")[0].childNodes[0].nodeValue)-1;var m=z.getElementsByTagName("WorkingTimes")[0].getElementsByTagName("WorkingTime");s=a.parseXmlToTimeSpan(m[0].getElementsByTagName("FromTime")[0].childNodes[0].nodeValue);for(f=h=0;f =t.getElementsByTagName("Name").length)){var M=parseInt(t.getElementsByTagName("OutlineLevel")[0].childNodes[0].nodeValue)-1;if(!(0>M)){E=t.getElementsByTagName("UID")[0].childNodes[0].nodeValue;K=t.getElementsByTagName("Name")[0].childNodes[0].nodeValue;var N=a.parseXmlToDateTime(t.getElementsByTagName("Start")[0].childNodes[0].nodeValue),O=a.parseXmlToDateTime(t.getElementsByTagName("Finish")[0].childNodes[0].nodeValue),C=parseInt(t.getElementsByTagName("PercentComplete")[0].childNodes[0].nodeValue), +X=p.getOutputDate(c.getCompletedFinish(p.getInputDate(N),C/100,p.getInputDate(O))),Y="1"==t.getElementsByTagName("Milestone")[0].childNodes[0].nodeValue?!0:!1;o={content:K,indentation:M,isExpanded:!0,start:N,finish:O,completedFinish:X,isMilestone:Y};"undefined"!==typeof this.settings.ganttChartItemLoadingHandler&&(j={sourceElement:t,ganttChartItem:o},this.settings.ganttChartItemLoadingHandler(j),o=j.ganttChartItem);b.push(o);i.push({key:E,value:o})}}}var P=d.getElementsByTagName("Resources")[0].getElementsByTagName("Resource"); +for(f=0;f =G.getElementsByTagName("Name").length)){E=G.getElementsByTagName("UID")[0].childNodes[0].nodeValue;var w=K=G.getElementsByTagName("Name")[0].childNodes[0].nodeValue;"undefined"!==typeof this.settings.assignableResourceInfoLoadingHandler&&(j={sourceElement:G,resource:w},this.settings.assignableResourceInfoLoadingHandler(j),w=j.resource);W.push(w);q.push({key:E,value:w});"undefined"!==typeof this.settings.assignableResources&&this.settings.assignableResources.push(w)}}var Q= +d.getElementsByTagName("Assignments")[0].getElementsByTagName("Assignment");for(f=0;f B)){o=i[B].value;var Z=H.getElementsByTagName("ResourceUID")[0].childNodes[0].nodeValue,R=a.indexOfKey(q,Z);if(!(0>R)){var w=q[R].value,S=H.getElementsByTagName("Units")[0].childNodes[0].nodeValue,A="undefined"!==typeof S?parseFloat(S):1,L=w+(1!=A?" ":"")+(1!=A?"["+Math.round(1E4*A)/100+"%]":"");"undefined"!== +typeof this.settings.assignmentInfoLoadingHandler&&(j={sourceElement:H,ganttChartItem:o,resource:w,allocationUnits:A},this.settings.assignmentInfoLoadingHandler(j),w=j.resource,A=j.allocationUnits,L=w+(1!=A?" ":"")+(1!=A?"["+Math.round(1E4*A)/100+"%]":""));o.assignmentsContent="undefined"===typeof o.assignmentsContent||0==o.assignmentsContent.length?L:o.assignmentsContent+", "+L}}}D=d.getElementsByTagName("Tasks")[0].getElementsByTagName("Task");for(f=0;f B)){o=i[B].value;var T=t.getElementsByTagName("PredecessorLink");for(k=0;k U)){var aa=i[U].value,I=x.getElementsByTagName("Type")&&x.getElementsByTagName("Type")[0]&&x.getElementsByTagName("Type")[0].childNodes?parseInt(x.getElementsByTagName("Type")[0].childNodes[0].nodeValue):1;l=1==I?"":3==I?"SS":0==I?"FF":2==I?"SF":"";var V=x.getElementsByTagName("LinkLag")&& +x.getElementsByTagName("LinkLag")[0]&&x.getElementsByTagName("LinkLag")[0].childNodes?x.getElementsByTagName("LinkLag")[0].childNodes[0].nodeValue:null,ba=(null!=V?parseInt(V):0)/10*a.minuteDuration;l={item:aa,dependencyType:l,lag:ba};"undefined"!==typeof this.settings.predecessorItemLoadingHandler&&(j={sourceElement:x,ganttChartItem:o,predecessorItem:l},this.settings.predecessorItemLoadingHandler(j),l=j.predecessorItem,o=j.ganttChartItem);"undefined"===typeof o.predecessors&&(o.predecessors=[]); +o.predecessors.push(l)}}}for(f=0;f f&&(e=f);g.timelineStart=new Date(e.valueOf()-1*a.weekDuration);g.timelineFinish=new Date(e.valueOf()+52*a.weekDuration);g.displayedTime=e;c.refresh()};a.parseXmlToTimeSpan=function(b){var a,e,g,d,i;d=b.indexOf(":");i=b.lastIndexOf(":");0 d&&b.length>i)&&(a=parseInt(b.substr(0,d)),e=parseInt(b.substr(d+1,i)),g=parseInt(b.substr(i+1,b.length)));return 1E3*(3600*a+60*e+g)};a.parseXmlToDateTime= +function(b){var a,e,g,d,i,p,q,k,l=b.indexOf("T");q=b.indexOf("-");0 q&&(e=parseInt(b.substring(q+1,k)),l>k&&(g=parseInt(b.substring(k+1,l)))));q=b.indexOf(":");0 k&&(p=parseInt(b.substring(k+1,b.length)))));return new Date(a,e-1,g,d,i,p)};a.indexOfKey=function(b,a){for(var e=0;e this.settings.assignableResources.indexOf(k[d])&&this.settings.assignableResources.push(k[d]); +var k=this.settings.assignableResources,l="";for(d=0;7>d;d++){var s=g.workingWeekStart<=d&&g.workingWeekFinish>=d;0 /g,">")},{key:"Indentation",value:(h.indentation+1).toString()},{key:"Start",value:a.convertDateToXml(p.getOutputDate(f))},{key:"Finish",value:a.convertDateToXml(p.getOutputDate(y))},{key:"Duration",value:a.convertTimeSpanToXml(u)},{key:"CompletedDuration",value:a.convertTimeSpanToXml(n)},{key:"Effort",value:a.convertTimeSpanToXml(r)},{key:"CompletedEffort",value:a.convertTimeSpanToXml(z)}, +{key:"RemainingEffort",value:a.convertTimeSpanToXml(r-z)},{key:"IsMilestone",value:h.isMilestone?1:0},{key:"IsSummary",value:h.hasChildren?1:0},{key:"Cost",value:c.getItemCost(h)},{key:"Completion",value:!h.isMilestone&&0q&&!h.hasChildren?" "+a.convertDateToXml(p.getOutputDate(f))+" ":""},{key:"PredecessorLinks",value:m}];s+=this.saveGanttChartItem(h,a.taskXmlTemplate,r)}n="";for(d=0;d< +k.length;d++)0/g,">")}],n+=this.saveResourceInfo(h,a.resourceXmlTemplate,r);f="";for(d=0;d /g,">").replace(/\n/g,"
");a.write(e);a.close();return c};a.initializeSettings=function(){};a.secondDuration=1E3;a.minuteDuration=60*a.secondDuration;a.hourDuration=60*a.minuteDuration;a.dayDuration=24*a.hourDuration;a.weekDuration=7*a.dayDuration;a.projectXmlTemplate="\n\n "; +a.scheduleWeekDayXmlTemplate="14 \n1 \n{ProjectStart} \n{DayStart} \n{DayFinish} \n{MinutesPerDay} \n{MinutesPerWeek} \n7 \n2 \n1 \n\n \n\n \n1 \nStandard \n1 \n-1 \n\n{ScheduleWeekDays}\n \n\n{Tasks}\n \n\n{Resources}\n \n\n{Assignments}\n \n\n ";a.scheduleDayWorkingTimesXmlTemplate="{DayNumber} \n{IsWorkingDay} \n{WorkingTimes}\n\n ";a.taskXmlTemplate="\n \n{FromTime} \n{ToTime} \n\n "; +a.predecessorXmlTemplate="{Index} \n{Index} \n1 \n{Content} \n0 \n0 \n{Indentation} \n500 \n{Start} \n{Finish} \n{Duration} \n7 \n{Effort} \n{CompletedDuration} \n{CompletedEffort} \n{RemainingEffort} \n{IsMilestone} \n{IsSummary} \n0 \n3 \n{Completion} \n{Cost} \n0 \n{ConstraintDefinition}\n-1 \n0 \n{PredecessorLinks}\n\n ";a.resourceXmlTemplate="{PredecessorIndex} \n{DependencyType} \n{Lag} \n5 \n\n ";a.assignmentXmlTemplate="{Index} \n{Index} \n{Name} \n1 \n0 \n1 \n\n "; +return a}();i.Service=J})(p.ProjectSerializer||(p.ProjectSerializer={}))})(i.GanttChartView||(i.GanttChartView={}))})(i.Controls||(i.Controls={}))})(DlhSoft||(DlhSoft={})); diff --git a/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.HTML.Controls.d.ts b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.HTML.Controls.d.ts new file mode 100644 index 000000000..e93848041 --- /dev/null +++ b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.HTML.Controls.d.ts @@ -0,0 +1,861 @@ +/* Assembly: DlhSoft.ProjectData.GanttChart.HTML.Controls, + Company: DlhSoft, + Product: Project Data Modern Library, + Version: 5.3.17.0, + Copyright: Copyright © 2012-2020 DlhSoft, + Title: Project Data Gantt Chart HTML Controls, + Description: Project Data Gantt Chart related HTML client components */ + +/* +///{Indexes} \n{TaskIndex} \n{ResourceIndex} \n{AllocationUnits} \n{Completion} \n{Start} \n{Finish} \n{Effort} \n{CompletedEffort} \n{RemainingEffort} \n+*/ + +/// + +declare module DlhSoft.Controls { + /** Represents a control that presents task data items using a Gantt Chart and an associated tree-grid. */ + module GanttChartView { + /** + * Initializes a GanttChartView component instance. + * @param element The HTMLElement that would host the user interface of the component. + * @param items Task data objects to be managed and presented by the component. + * @param settings Configuration settings for the component behavior and appearance. + */ + function initialize(element: HTMLElement, items: Item[], settings?: Settings, license?: String): Element; + + /** Returns an array of default definitions that you can further customize and use as value for the columns property of the control settings used at initialization time. */ + function getDefaultColumns(items: Item[], settings: Settings): Column[]; + + function getDefaultCollapsedToggleButtonTemplate(controlElement: Element, settings: Settings): () => SVGElement; + function getDefaultExpandedToggleButtonTemplate(controlElement: Element, settings: Settings): () => SVGElement; + + /** Returns an array of default definitions that you can further customize and use as value for the scales property of the control settings used at initialization time. */ + function getDefaultScales(settings: Settings): Scale[]; + + function getDefaultStyleDefinitionTemplate(controlElement: Element, settings: Settings): () => SVGDefsElement; + function getDefaultStandardTaskTemplate(items: Item[], controlElement: Element, settings: Settings): (item: Item) => SVGElement; + function getDefaultSummaryTaskTemplate(items: Item[], controlElement: Element, settings: Settings): (item: Item) => SVGElement; + function getDefaultMilestoneTaskTemplate(items: Item[], controlElement: Element, settings: Settings): (item: Item) => SVGElement; + function getDefaultItemTemplate(settings: Settings): (item: Item) => SVGElement; + function getDefaultAssignmentsTemplate(settings: Settings): (item: Item) => SVGElement; + function getDefaultDependencyLineTemplate(items: Item[], settings: Settings): (item: Item, predecessorItem: PredecessorItem) => SVGElement; + function getDefaultPredecessorItemTemplate(settings: Settings): (item: Item, predecessorItem: PredecessorItem) => SVGElement; + + /** Inside task template functions, sets up task drag and drop behavior for the non-null SVG elements specified to be designed as thumbs, considering the specified item and item positioning in the chart. */ + function initializeTaskDraggingThumbs(startThumb: SVGElement, startOnlyThumb: SVGElement, finishThumb: SVGElement, completedFinishThumb: SVGElement, item: Item, itemLeft: number, itemRight: number, itemCompletedRight: number): void; + + /** Inside task template functions, sets up dependency creation drag and drop behavior for the non-null SVG elements specified to be designed as thumbs inside its specified container group that would be used to supplementary present temporary dependency lines during drag and drop operations, considering the specified item and item positioning in the chart. */ + function initializeDependencyDraggingThumbs(thumb: SVGElement, startThumb: SVGElement, containerGroup: SVGGElement, item: Item, itemTop: number, itemRight: number, itemLeft: number): void; + + function getWorkingTime(dateTime: Date, settings: Settings, schedule?: Schedule): Date; + function getEffort(start: Date, finish: Date, settings: Settings, schedule?: Schedule): number; + function getFinish(start: Date, effort: number, settings: Settings, schedule?: Schedule): Date; + function getStart(effort: Date, finish: number, settings: Settings, schedule?: Schedule): Date; + function getCompletion(start: Date, completedFinish: Date, finish: Date, settings: Settings, schedule?: Schedule): number; + function getCompletedFinish(start: Date, completion: number, finish: Date, settings: Settings, schedule?: Schedule): number; + function getWeekStart(dateTime: Date, weekStartDay: number): Date; + function getWeekFinish(dateTime: Date, weekStartDay: number): Date; + + function defaultDateTimeFormatter(date: Date): string; + function defaultDateFormatter(date: Date): string; + function defaultDateTimeParser(value: string): Date; + + function textColumnTemplateBase(document: HTMLDocument, valueGetter: () => any, isVisibleGetter?: () => boolean): HTMLElement; + function textInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean): HTMLElement; + function optionSelectColumnTemplateBase(document: HTMLDocument, width: number, optionCollectionGetter: () => any[], valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean): HTMLElement; + function numberInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean): HTMLElement; + function percentInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean): HTMLElement; + function timeSpanInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, scale?: number, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean): HTMLElement; + function dateTimeInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean): HTMLElement; + + function datePickerInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean, defaultTimeOfDay?: number, calendarSelectorLevels?: number, months?: string[], daysOfWeek?: string[], dateTimeFormatter?: (Date) => string, dateTimeParser?: (string) => Date): HTMLElement; + function dateTimePickerInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean, defaultTimeOfDay?: number, calendarSelectorLevels?: number, months?: string[], daysOfWeek?: string[], dateTimeFormatter?: (Date) => string, dateTimeParser?: (string) => Date): HTMLElement; + function multiSelectorComboBoxInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean): HTMLElement; + + function getIconColumnTemplate(imageSource: string, imageClass: string, imageStyle: string, isMovingEnabled?: boolean, isMovingToEnabledGetter?: (index: number, hoveringItem: Item) => boolean, movingTargetHoveringClass?: string, movingTargetHoveringStyle?: string, disabledMovingTargetHoveringClass?: string, disabledMovingTargetHoveringStyle?: string): (item: Item) => HTMLElement; + function getIconColumnTemplate(imageSourceGetter: (item: Item) => string, imageClass: string, imageStyle: string, isMovingEnabled?: boolean, isMovingToEnabledGetter?: (index: number, hoveringItem: Item) => boolean, movingTargetHoveringClass?: string, movingTargetHoveringStyle?: string, disabledMovingTargetHoveringClass?: string, disabledMovingTargetHoveringStyle?: string): (item: Item) => HTMLElement; + function getIconColumnTemplate(imageSource: string, imageClass: string, imageStyle: string, isMovingEnabledGetter: (item: Item) => boolean, isMovingToEnabledGetter?: (index: number, hoveringItem: Item) => boolean, movingTargetHoveringClass?: string, movingTargetHoveringStyle?: string, disabledMovingTargetHoveringClass?: string, disabledMovingTargetHoveringStyle?: string): (item: Item) => HTMLElement; + function getIconColumnTemplate(imageSourceGetter: (item: Item) => string, imageClass: string, imageStyle: string, isMovingEnabledGetter: (item: Item) => boolean, isMovingToEnabledGetter?: (index: number, hoveringItem: Item) => boolean, movingTargetHoveringClass?: string, movingTargetHoveringStyle?: string, disabledMovingTargetHoveringClass?: string, disabledMovingTargetHoveringStyle?: string): (item: Item) => HTMLElement; + function getIndexColumnTemplate(zeroBased?: boolean): (item: Item) => HTMLElement; + function getWbsColumnTemplate(zeroBased?: boolean): (item: Item) => HTMLElement; + function getEffortColumnTemplate(inputWidth: number, scale?: number, isInputDisabled?: boolean): (item: Item) => HTMLElement; + function getTotalEffortColumnTemplate(inputWidth: number, scale?: number, isInputDisabled?: boolean): (item: Item) => HTMLElement; + function getDurationColumnTemplate(inputWidth: number, scale?: number, isInputDisabled?: boolean): (item: Item) => HTMLElement; + function getCompletedEffortColumnTemplate(inputWidth: number, scale?: number, isInputDisabled?: boolean): (item: Item) => HTMLElement; + function getTotalCompletedEffortColumnTemplate(inputWidth: number, scale?: number, isInputDisabled?: boolean): (item: Item) => HTMLElement; + function getCompletionColumnTemplate(inputWidth: number, isInputDisabled?: boolean): (item: Item) => HTMLElement; + function getPredecessorsColumnTemplate(inputWidth: number, isInputDisabled?: boolean, zeroBased?: boolean): (item: Item) => HTMLElement; + function getAssignmentSelectorColumnTemplate(selectWidth: number, assignableResourcesCollection: any[], isInputDisabled?: boolean, useMultiSelectorComboBox?: boolean): (item: Item) => HTMLElement; + function getAssignmentSelectorColumnTemplate(selectWidth: number, assignableResourcesCollectionGetter: (item: Item) => any[], isInputDisabled?: boolean, useMultiSelectorComboBox?: boolean): (item: Item) => HTMLElement; + function getCostColumnTemplate(inputWidth: number, isInputDisabled?: boolean): (item: Item) => HTMLElement; + function getBaselineStartColumnTemplate(inputWidth: number, useDatePicker?: boolean, useTimePicker?: boolean, defaultTimeOfDay?: number, calendarSelectorLevels?: number, months?: string[], daysOfWeek?: string[], isInputDisabled?: boolean): (item: Item) => HTMLElement; + function getBaselineFinishColumnTemplate(inputWidth: number, useDatePicker?: boolean, useTimePicker?: boolean, defaultTimeOfDay?: number, calendarSelectorLevels?: number, months?: string[], daysOfWeek?: string[], isInputDisabled?: boolean): (item: Item) => HTMLElement; + function getMinStartColumnTemplate(inputWidth: number, useDatePicker?: boolean, useTimePicker?: boolean, defaultTimeOfDay?: number, calendarSelectorLevels?: number, months?: string[], daysOfWeek?: string[], isInputDisabled?: boolean): (item: Item) => HTMLElement; + function getMaxStartColumnTemplate(inputWidth: number, useDatePicker?: boolean, useTimePicker?: boolean, defaultTimeOfDay?: number, calendarSelectorLevels?: number, months?: string[], daysOfWeek?: string[], isInputDisabled?: boolean): (item: Item) => HTMLElement; + function getMinFinishColumnTemplate(inputWidth: number, useDatePicker?: boolean, useTimePicker?: boolean, defaultTimeOfDay?: number, calendarSelectorLevels?: number, months?: string[], daysOfWeek?: string[], isInputDisabled?: boolean): (item: Item) => HTMLElement; + function getMaxFinishColumnTemplate(inputWidth: number, useDatePicker?: boolean, useTimePicker?: boolean, defaultTimeOfDay?: number, calendarSelectorLevels?: number, months?: string[], daysOfWeek?: string[], isInputDisabled?: boolean): (item: Item) => HTMLElement; + + /** Prepares the specified date values to be used for component method input, considering that after initialization the component uses UTC date and time values internally; this method may also be called using a component instance object. */ + function getInputDate(date: Date): Date; + /** Prepares the specified date values to be used for component method result or field output, considering that after initialization the component uses UTC date and time values internally; this method may also be called using a component instance object. */ + function getOutputDate(date: Date): Date; + + /** Represents an HTML element that supplementary provides GanttChartView component services. */ + interface Element extends HTMLElement { + items: Item[]; + settings: Settings; + + /** Updates the user interface considering all external item and settings changes. */ + refresh(): void; + + refreshGridItems(): void; refreshChartItems(): void; refreshItems(): void; refreshGridItem(item: Item): void; refreshChartItem(item: Item): void; refreshItem(item: Item): void; refreshPredecessorItems(item: Item): void; refreshItemGraph(item: Item): void; refreshItemPath(item: Item): void; refreshItemNeighbourhood(item: Item): void; + refreshCurrentTime(): void; setCurrentTime(currentTime: Date): void; updateCurrentTime(): void; + + insertItem(index: number, item: Item): void; addItem(item: Item): void; insertItems(index: number, items: Item[]): void; addItems(items: Item[]): void; + removeItem(item: Item): void; removeItems(items: Item[]): void; + moveRange(fromIndex: number, count: number, toIndex: number): void; + moveItem(item: Item, toIndex: number): void; + moveItemHierarchy(item: Item, toIndex: number): void; + moveItemUp(item: Item): void; moveItemDown(item: Item): void; + moveItemHierarchyUp(item: Item): void; moveItemHierarchyDown(item: Item): void; + + increaseItemIndentation(item: Item): void; decreaseItemIndentation(item: Item): void; + + setItemContent(item: Item, value: any): void; + setItemStart(item: Item, value: Date): void; setItemFinish(item: Item, value: Date): void; + setItemIsMilestone(item: Item, value: boolean): void; + getItemEffort(item: Item): number; setItemEffort(item: Item, value: number): void; getItemCompletedEffort(item: Item): number; setItemCompletedEffort(item: Item, value: number): void; + getItemTotalEffort(item: Item): number; getItemTotalCompletedEffort(item: Item): number; + setItemTotalEffort(item: Item, value: number): void; setItemTotalCompletedEffort(item: Item, value: number): void; + setItemHasFixedEffort(item: Item, value: boolean): void; + getItemDuration(item: Item): number; setItemDuration(item: Item, value: number): void; + getItemCompletion(item: Item): number; setItemCompletion(item: Item, value: number): void; + isItemCompleted(item: Item): boolean; setItemAsCompleted(item: Item): void; + hasItemStarted(item: Item): boolean; setItemAsNotStarted(item: Item): void; isItemOnSchedule(item: Item): boolean; + setItemAssignmentsContent(item: Item, value: any): void; + getItemIndexString(item: Item, zeroBased?: boolean): string; + getItemPredecessorsString(item: Item, zeroBased?: boolean): string; setItemPredecessorsString(item: Item, value: string, zeroBased?: boolean): void; + getCurrentItem(): Item; + getSelectedItem(): Item; getSelectedItems(): Item[]; + selectItem(item: Item): void; unselectItem(item: Item): void; + expandItem(item: Item): void; collapseItem(item: Item): void; + scrollToItem(item: Item): void; scrollToBottom(): void; scrollToDateTime(dateTime: Date): void; + increaseTimelinePage(timeAmount: number): void; decreaseTimelinePage(timeAmount: number): void; + setHourWidth(hourWidth: number): void; + setSplitterPosition(gridWidth: number, chartWidth: number); + + /** Returns the X coordinate of a specific date and time in the chart area. */ + getChartPosition(dateTime: Date): number; + /** Returns the actual width of the chart area. */ + getChartWidth(): number; + + /** Returns the date and time of a specific X coordinate in the chart area. */ + getDateTime(chartPosition: number): Date; + + /** Returns the next available working time in the schedule based on the specified date and time. */ + getWorkingTime(dateTime: Date): Date; + + getStartWorkingTime(dateTime: Date): Date; getFinishWorkingTime(dateTime: Date): Date; + + /** Returns the actual working effort (in milliseconds) required to complete a task that starts and finishes on the specified date and times. */ + getEffort(start: Date, finish: Date): number; + + /** Returns the actual finish date and time of a task that starts on the specified date and time and completes after the specified working effort (in milliseconds). */ + getFinish(start: Date, effort: number): Date; + + /** Returns the actual start date and time of a task that has completed after the specified working effort (in milliseconds) and finishes on the specified date and time. */ + getStart(effort: number, finish: Date): Date; + + /** Returns the completion rate (between 0 and 1) of a task that is scheduled between the specified start and finish date and times and has been completed up to the specified completed finish date and time. */ + getCompletion(start: Date, completedFinish: Date, finish: Date): number; + + /** Returns the completed finish date and time of a task that is scheduled between the specified start and finish date and times and has the specified completion rate (between 0 and 1). */ + getCompletedFinish(start: Date, completion: number, finish: Date): Date; + + getItemsHeight(): number; + getItemTop(item: Item): number; + + /** Calls itemPropertyChangeHandler function specified within the settings collection using the specified item, property name, and Boolean indicators for direct user actions and completed actions as arguments. */ + onItemPropertyChanged(item: Item, propertyName: string, isDirect: boolean, isFinal: boolean): void; + + /** Exports the content to the specified output document. */ + exportContent(exportSettings: ExportSettings, output: HTMLDocument): void; + /** Exports the content to the document of the specified output window. */ + exportContent(exportSettings: ExportSettings, output: Window): void; + /** Exports the content to the specified target or using a temporary document and window. */ + exportContent(exportSettings?: ExportSettings, output?: string): void; + /** Prints the content using a temporary document and window. */ + print(exportSettings?: ExportSettings): void; + + getRootItems(): Item[]; getLeafItems(): Item[]; getSummaryItems(): Item[]; + getProjectStart(): Date; getProjectFinish(): Date; + getProjectEffort(): number; getProjectCompletedEffort(): number; + getProjectTotalEffort(): number; getProjectTotalCompletedEffort(): number; + getProjectCompletion(): number; + + isItemCritical(item: Item): boolean; getCriticalItems(criticalDelay?: number): Item[]; + getPertCriticalItems(maxIndentation?: number): Item[]; + + ensureDependencyConstraints(): void; + + /** Sets up baseline start and baseline finish properties of standard and milestone task items based on their actual start and finish values; used as preparation for rescheduling the remaining work effort of a task item. */ + setupBaseline(): void; + + rescheduleItemToStart(item: Item, start: Date): void; + rescheduleItemToFinish(item: Item, finish: Date): void; + + /** Creates and inserts a partial copy of the specified task item considering its remaining work effort into the managed hierarchy, and updates the finish date and time of the original task item to its completion point. */ + splitRemainingWork(item: Item): void; + + /** Optimizes schedule times of all managed items in order to optimize the project finish date without leveling resources (optionally using single pass task leveling), respecting dependency constraints. */ + optimizeWork(dependenciesOnly?: boolean, includeStartedTasks?: boolean, start?: Date, singlePassTaskLeveling?: boolean): void; + + /** Levels the assigned allocation units assuming that all or the specified tasks within the control are fixed duration and effort driven; requires that assignmentsContent property of the task items is of type string, formatted as a list of resource names separated by commas, optionally having associated allocation percents declared between square brackets (e.g.: "John, Mary [50%], Diane [12.5%]"). */ + levelAllocations(items?: Item[]): void; + + /** Levels the assigned resources from all standard tasks within the control in order to avoid over allocation, by updating task timing values accordingly; requires that assignmentsContent property of the task items is of type string, formatted as a list of resource names separated by commas, optionally having associated allocation percents declared between square brackets (e.g.: "John, Mary [50%], Diane [12.5%]"); includeStartedTasks parameter indicates whether or not to consider already started tasks (i.e. having completion > 0), and start parameter specifies the date and time to consider for resource leveling algorithm. */ + levelResources(includeStartedTasks?: boolean, start?: Date): void; + + getItemSuccessors(item: Item): Item[]; + getItemSuccessorPredecessorItems(item: Item): PredecessorItem[]; + getItemAllocationUnits(item: Item): number; + getItemAssignments(item: Item): { key: any; value: number; }[]; + + /** Determines the list of the assignments of a specific task item, as strings indicating the assigned resource names. */ + getItemAssignedResources(item: Item): any[]; + + getResourceAssignments(resourceName: any): { key: Item; value: number; }[]; + + /** Determines the list of the assignments of a specific resource, as objects indicating the assigned task items. */ + getResourceAssignedItems(resourceName: any): Item[]; + + /** Determines the list of all assigned resources within the current project, as strings indicating their names. */ + getAssignedResources(): any[]; + + /** Returns a list of Schedule Chart items for the current project, optionally considering the minimum set of assignable resources specified as parameter; the Schedule Chart items may be displayed using a separate ScheduleChartView component instance. */ + getScheduleChartItems(assignableResources?: any[]): ScheduleChartView.Item[]; + + getItemAssignmentsCost(item: Item): number; getItemExtraCost(item: Item): number; + getItemCost(item: Item): number; setItemCost(item: Item, value: number): void; + getResourceCost(resourceName: string): number; + getProjectCost(): number; + + getAllocations(resourceName: any): { key: { start: Date; finish: Date }; value: number }[]; + + /** Returns a list of Load Chart items for the current project, optionally considering the set of resources specified as parameter; the Schedule Chart items may be displayed using a separate LoadChartView component instance. */ + getLoadChartItems(resources?: any[]): LoadChartView.Item[]; + + /** Returns a list of Load Chart items for the current project, considering the resource specified as parameter; the Schedule Chart items may be displayed using a separate LoadChartView component instance. */ + getLoadChartItems(resource: any): LoadChartView.Item[]; + + /** Returns a list of filtered read only Gantt Chart items for the current project, considering the set of resources specified as parameter; the read only Gantt Chart items may be displayed using a separate GanttChartView component instance. */ + getFilteredGanttChartItems(resources: any[]): Item[]; + + /** Returns a list of filtered read only Gantt Chart items for the current project, considering the resource specified as parameter; the read only Gantt Chart items may be displayed using a separate GanttChartView component instance. */ + getFilteredGanttChartItems(resource: any): Item[]; + + /** Returns a list of PERT Chart items for the current project, optionally considering the maximum indentation, and start, finish, and link content and suffixes values specified as parameters; the PERT Chart items may be displayed using a separate PertChartView component instance. */ + getPertChartItems(maxIndentation?: number, startContent?: string, finishContent?: string, linkContent?: string, completedContentSuffix?: string, startingContentSuffix?: string): Pert.PertChartView.Item[]; + + /** Returns a list of Network Diagram items for the current project, optionally considering the maximum indentation, and start and finish content values specified as parameters; the Network Diagram items may be displayed using a separate NetworkDiagramView component instance. */ + getNetworkDiagramItems(maxIndentation?: number, startContent?: string, finishContent?: string): Pert.NetworkDiagramView.Item[]; + + isInitializing: boolean; isInitialized: boolean; + + /** Copies the common settings of the current component instance to the specified target settings collection; a secondary component instance may be initialized using the output collection. */ + copyCommonSettings(targetSettings: Settings): void; + + /** Determines whether an item depends of another item by checking the hierarchy and predecessor items. */ + itemDependsOf(item: Item, otherItem: Item): boolean; + } + + /** Represents a task data item and its Gantt Chart representation. */ + interface Item { + /** The object that is displayed to represent the task item in the grid and in task bar tool tips, usually the task name. */ + content: any; + + /** The hierarchy is based on the indentation level values of the tasks, so that a task with a lower index in the collection and having a specific indentation level will become the parent task for the tasks with a higher index in the collection and having an increased indentation level. */ + indentation?: number; + + /** If a parent task is expanded its child tasks become visible. If a parent task is collapsed its child tasks become invisible. */ + isExpanded?: boolean; + + start: Date; finish?: Date; completedFinish?: Date; + + /** A milestone task is displayed in the Gantt Chart view using a different task bar template. */ + isMilestone?: boolean; + + /** Optionally defines specific working week and day intervals and special nonworking days to consider for scheduling purposes. */ + schedule?: Schedule; + + baselineStart?: Date; baselineFinish?: Date; + minStart?: Date; maxStart?: Date; minFinish?: Date; maxFinish?: Date; + isRelativeToTimezone?: boolean; + + /** The assignments content to be displayed in the Gantt Chart view next to the associated task bar, but it is not used internally for computing/updating task finish date and time (generating duration) based on any updated assignments. */ + assignmentsContent?: any; + + isReadOnly?: boolean; + isHidden?: boolean; + isBarVisible?: boolean; + isBarReadOnly?: boolean; + isSummaryEnabled?: boolean; + isParentSummarizationEnabled?: boolean; + + /** When set to true it would ensure that the original item's total effort is preserved when duration is updated by updating assignment allocation units, assuming that the item has resources assigned. */ + hasFixedEffort?: boolean; + + /** When specifically set to false, overrides GanttChartView.areTaskDependencyConstraintsEnabled = true (auto-scheduling) for an item, setting up manual scheduling. */ + areDependencyConstraintsEnabled?: boolean; + + displayRowIndex?: number; + + /** Optional array of parts to be represented for this group item in the chart area. */ + parts?: Item[]; + + "class"?: string; style?: string; + barClass?: string; standardBarClass?: string; completedBarClass?: string; summaryBarClass?: string; summaryCompletedBarClass?: string; milestoneBarClass?: string; baselineBarClass?: string; barStyle?: string; standardBarStyle?: string; completedBarStyle?: string; summaryBarStyle?: string; summaryCompletedBarStyle?: string; milestoneBarStyle?: string; baselineBarStyle?: string; + taskTemplate? (item: Item): SVGElement; + template? (item: Item): SVGElement; + + isSelected?: boolean; + + /** The predecessors collection defines predecessor items referring the task items that the current item depends of, and having the relations displayed in the Gantt Chart view as dependency lines, but it is not used internally for computing/updating task start and finish date and times (generating work time intervals) based on its defined dependencies. */ + predecessors?: PredecessorItem[]; + + executionCost?: number; + + /** The index of the item in the managed hierarchy. */ + index?: number; + + /** The summary item that includes this task considering indentation values, or null when there is no such parent summary item. */ + parent?: Item; + + /** Indicates whether the task is a summary item. */ + hasChildren?: boolean; + + /** When this task is a summary item (i.e. hasChildren is set to true), returns an array of its child items. */ + children?: Item[]; + + /** Indicates whether the task is visible within the hierarchy, i.e. it is not a descendent of a collapsed summary item. */ + isVisible?: boolean; + + /** Indicates whether the task is visible in the scrolling viewport of the control when virtualization is enabled. */ + isVirtuallyVisible?: boolean; + } + + /** Represents a depdendency between two task data items and its Gantt Chart representation. */ + interface PredecessorItem { + /** Task item that precedes the owner of the predecessor item (the item that the current item depends of). */ + item: Item; + + /** Indicates the type of the dependency; supported values are: FinishStart (default value), StartStart, FinishFinish, or StartFinish. */ + dependencyType?: string; + + /** Indicates an optional lag of the dependency (in milliseconds). */ + lag?: number; + + dependencyLineClass?: string; dependencyLineStyle?: string; + template? (item: Item, predecessorItem: PredecessorItem): SVGElement; + } + + /** Represents an object that defines working week and day intervals and special nonworking days either for an entire Gantt Chart or specific tasks. */ + interface Schedule { + /** The start day of the working week interval, used when computing task effort values and when dragging and dropping task bars; by default it is set to Monday (1); previous days of the week are considered nonworking time and by default they are highlighted in the chart area. */ + workingWeekStart?: number; + /** The finish day of the working week interval, used when computing task effort values and when dragging and dropping task bars; by default it is set to Friday (5); next days of the week are considered nonworking time and by default they are highlighted in the chart area. */ + workingWeekFinish?: number; + + /** The start time of the working day interval, in milliseconds passed since midnight; by default it is set to 8 AM; the start of the visible time interval of the day is also defined using the same value. */ + workingDayStart?: number; + /** The finish time of the working day interval, in milliseconds passed since midnight; by default it is set to 4 PM; the finish of the visible time interval of the day is also defined using the same value. */ + workingDayFinish?: number; + + /** Optional collection of special nonworking days, such as holidays. */ + specialNonworkingDays?: Date[]; + } + + /** Represents settings for a GanttChartView component. */ + interface Settings { + /** Name of the target to generically apply to the control; Standard, and Phone targets are supported; by default it is Standard. */ + target?: string; + + /** Name of the interaction mode to generically apply to the control; Standard, and TouchEnabled interaction modes are supported; by default it is Standard. */ + interaction?: string; + + /** Name of the theme to generically apply to the control; Modern, ModernBordered, and Aero themes are supported; by default it is Modern. */ + theme?: string; + + border?: string; + containerClass?: string; containerStyle?: string; + + isGridVisible?: boolean; gridWidth?: string; chartWidth?: string; + isSplitterEnabled?: boolean; splitterWidth?: number; splitterBackground?: string; + minGridWidth?: number; minChartWidth?: number; + + isReadOnly?: boolean; isGridReadOnly?: boolean; isChartReadOnly?: boolean; isContentReadOnly?: boolean; isAssignmentsContentReadOnly?: boolean; isTaskStartReadOnly?: boolean; isTaskEffortReadOnly?: boolean; isTaskCompletionReadOnly?: boolean; areTaskPredecessorsReadOnly?: boolean; + + /** Indicates whether effort is preserved for tasks when end users change their start value from the default Start column in the grid; by default it is set to false. */ + isTaskEffortPreservedWhenStartChangesInGrid?: boolean; + + headerBackground?: string; headerHeight?: number; + itemHeight?: number; + + /** Collection of objects indicating the columns to be presented in the grid. */ + columns?: Column[]; + + itemClass?: string; itemStyle?: string; + standardItemClass?: string; summaryItemClass?: string; milestoneItemClass?: string; standardItemStyle?: string; summaryItemStyle?: string; milestoneItemStyle?: string; + + selectedItemClass?: string; selectedItemStyle?: string; + + /** Indicates the selection behavior; support values are None (not allowed), Focus (single item selected triggered by focus), Single (single item selection using check box), Extended (multiple item selection using check boxes), and ExtendedFocus (multiple item selection using check boxes or triggered by focus); by default it is set to Focus. */ + selectionMode?: string; + + indentationLevelWidth?: number; + + cellClass?: string; cellStyle?: string; + toggleButtonClass?: string; toggleButtonHoveringClass?: string; toggleButtonStyle?: string; toggleButtonHoveringStyle?: string; + collapsedToggleButtonTemplate? (): HTMLElement; expandedToggleButtonTemplate? (): HTMLElement; + + /** Date and time to scroll to within the chart view. */ + displayedTime?: Date; + + /** Date and time to highlight (using a vertical bar) within the chart view. */ + currentTime?: Date; + + /** Start date and time of the scrollable chart area. */ + timelineStart?: Date; + + /** Start date and time of the scrollable chart area. */ + timelineFinish?: Date; + + isRelativeToTimezone?: boolean; + + /** Collection of objects indicating the scales to be presented in the chart. */ + scales?: Scale[]; + + /** Time interval length (in milliseconds) to be used to dynamically round date and time during drag and drop update operations; by default it is set to quarter-hour (15 minutes). */ + updateScale?: number; + + /** Indicates the zoom level to be used for the chart area, and represents the actual number of pixels each hour in the timeline gets available; to zoom in, increase this value; to zoom out, decrease it; by default it is set to 2.5. */ + hourWidth?: number; + + /** The start day of the visible week interval; by default it is set to Sunday (0). */ + visibleWeekStart?: number; + /** The finish day of the visible week interval; by default it is set to Saturday (6). */ + visibleWeekFinish?: number; + + /** The start day of the working week interval, used when computing task effort values and when dragging and dropping task bars; by default it is set to Monday (1); previous days of the week are considered nonworking time and by default they are highlighted in the chart area. */ + workingWeekStart?: number; + /** The finish day of the working week interval, used when computing task effort values and when dragging and dropping task bars; by default it is set to Friday (5); next days of the week are considered nonworking time and by default they are highlighted in the chart area. */ + workingWeekFinish?: number; + + /** The start time of the visible day interval, in milliseconds passed since midnight; by default it is set to 8 AM; the start of the working time interval of the day is also defined using the same value. */ + visibleDayStart?: number; + /** The finish time of the visible day interval, in milliseconds passed since midnight; by default it is set to 4 PM; the finish of the working time interval of the day is also defined using the same value. */ + visibleDayFinish?: number; + + /** Optional collection of special nonworking days, such as holidays. */ + specialNonworkingDays?: Date[]; + + /** Allows initializing working week and day intervals and special nonworking days to consider for scheduling purposes using an alternative definition object. */ + schedule?: Schedule; + + barMargin?: number; barHeight?: number; barCornerRadius?: number; + completedBarMargin?: number; completedBarHeight?: number; completedBarCornerRadius?: number; + + styleDefinitionTemplate? (ganttChartView?: Element): SVGDefsElement; + standardBarClass?: string; summaryBarClass?: string; milestoneBarClass?: string; standardBarStyle?: string; summaryBarStyle?: string; milestoneBarStyle?: string; + standardCompletedBarClass?: string; standardCompletedBarStyle?: string; + summaryCompletedBarClass?: string; summaryCompletedBarStyle?: string; + collapsedSummaryLineClass?: string; collapsedSummaryLineStyle?: string; + dependencyPointerClass?: string; dependencyPointerStyle?: string; + dependencyLineClass?: string; dependencyLineStyle?: string; + temporaryDependencyLineClass?: string; temporaryDependencyLineStyle?: string; + assignmentsClass?: string; assignmentsStyle?: string; + standardTaskTemplate? (item: Item): SVGElement; summaryTaskTemplate? (item: Item): SVGElement; milestoneTaskTemplate? (item: Item): SVGElement; + extraTaskTemplate? (item: Item): SVGElement; + + isTaskToolTipVisible?: boolean; + itemTemplate? (item: Item): SVGElement; + + areTaskAssignmentsVisible?: boolean; + assignmentsTemplate? (item: Item): SVGElement; + + isTaskCompletedEffortVisible?: boolean; + isSummaryTaskCompletedEffortVisible?: boolean; + + isIndividualItemNonworkingTimeHighlighted?: boolean; areTaskInterruptionsHighlighted?: boolean; + + areTaskDependenciesVisible?: boolean; + allowCreatingStartDependencies?: boolean; allowCreatingToFinishDependencies?: boolean; + dependencyLineTemplate? (item: Item, predecessorItem: PredecessorItem): SVGElement; + + isDependencyToolTipVisible?: boolean; + predecessorItemTemplate? (item: Item, predecessorItem: PredecessorItem): SVGElement; + + areToolTipsSimplified?: boolean; + + isDraggingTaskStartEndsEnabled?: boolean; + + visibilityFilter? (item: Item): boolean; + + /** Determines whether dependency constraints are enabled in the chart, providing auto-scheduling features for dependent tasks; by default is it set to false for optimization purposes. */ + areTaskDependencyConstraintsEnabled?: boolean; + + /** Determines whether dependency constraints are automatically ensured even while dragging task bars in the control (or only when the operation completes), when areTaskDependencyConstraintsEnabled property is set to true; by default it is set to false. */ + areTaskDependencyConstraintsEnabledWhileDragging?: boolean; + + /** Determines whether dependency constraints are disabled when the predecessor item is created using drag and drop operations in the chart, when areTaskDependencyConstraintsEnabled is set to false; by default it is set to false. */ + areTaskDependencyConstraintsDisabledWhenDropping?: boolean; + + areDependencyConstraintsAppliedOnStartedTasks?: boolean; + areDependencyConstraintsAppliedOnMilestones?: boolean; + + isBaselineVisible?: boolean; + + allowUserToResizeColumns?: boolean; + minColumnWidth?: number; + maxColumnWidth?: number; + + isGridRowClickTimeScrollingEnabled?: boolean; + + isMouseWheelZoomEnabled?: boolean; + isMouseWheelZoomEnabledMinHourWidth?: number; + isMouseWheelZoomEnabledMaxHourWidth?: number; + + /** The collection of resource names available for task assignments */ + assignableResources?: string[]; + autoAppendAssignableResources?: boolean; + + /** Quantity values to consider when leveling resources, indicating maximum amounts of materials available for use at the same time. */ + resourceQuantities?: { key: string; value: number }[]; + maxLoadChartDisplayedResourceQuantity?: number; + + /** Resource schedules */ + resourceSchedules?: { key: string; value: Schedule }[]; + + taskInitiationCost?: number; + defaultResourceUsageCost?: number; + specificResourceUsageCosts?: { key: string; value: number }[]; + defaultResourceHourCost?: number; + specificResourceHourCosts?: { key: string; value: number }[]; + + alternativeItemClass?: string; alternativeChartItemClass?: string; alternativeItemStyle?: string; alternativeChartItemStyle?: string; + + gridLines?: string; horizontalGridLines?: string; verticalGridLines?: string; horizontalChartLines?: string; + + /** Indicates whether the control will create task bars only when they need to be presented (such as only when scrolling the view to their positions); by default it is set to true for optimization purposes. */ + isVirtualizing?: boolean; + + /** The input type to use for the default start and finish cell value editors in the grid; "text" by default. */ + dateTimePickerType?: string; + + /** Indicates whether to use date picker controls for start and finish date cells in the grid when date time picker type is set to "text" and the required data control library is available. */ + useDatePicker?: boolean; + + /** Indicates the number of calendar selector levels that may be displayed on date picker controls; supported values: 1: months, 2: + years, 3: + decades. */ + calendarSelectorLevels?: number; + + /** Indicates whether to use time picker besides date picker controls (when useDatePicker is set to true) for start and finish date cells when the required data control library is available. */ + useTimePicker?: boolean; + + /** Indicates whether to use multi-selector combo box controls for assignment cells in the grid when the required data control library is available. */ + useResourceSelector?: boolean; + + /** Indicates whether to use tool tip controls for updating task start, finish, completion, dependencies, and/or assignments in the chart using drag and drop operations when the required data control library is available. */ + useUpdatingToolTips?: boolean; + + /** Names of the months to use at presentation time. */ + months?: string[]; + /** Names of the days of the week to use at presentation time. */ + daysOfWeek?: string[]; + + /** Day of the week to consider as week start; by default it is set to Sunday (0); to set it to Monday use one (1). */ + weekStartDay?: number; + + /** Converts date values to text values whenever needed within the control; the function may be provided by the developer for further customization and/or localization purposes. */ + dateFormatter? (date: Date): string; + /** Converts date and time values to text values whenever needed within the control; the function may be provided by the developer for further customization and/or localization purposes. */ + dateTimeFormatter? (dateTime: Date): string; + /** Converts text values to date and time values whenever needed within the control; the function may be provided by the developer for further customization and/or localization purposes. */ + dateTimeParser? (text: string): Date; + + /** Function called whenever the end user scrolls the chart area horizontally, changing the left most displayed time (settings.displayedTime). */ + displayedTimeChangeHandler? (displayedTime: Date): void; + /** Function called whenever the end user performs mouse wheel zooming on the chart area, changing the zoom level (settings.hourWidth). */ + hourWidthChangeHandler? (hourWidth: number): void; + /** Function called whenever the end user resizes the grid and chart areas horizontally, changing the splitter position (settings.gridWidth and settings.chartWidth). */ + splitterPositionChangeHandler? (gridWidth: number, chartWidth: number): void; + /** Function called whenever the end user resizes a grid column, changing its width (column.width). */ + columnWidthChangeHandler? (column: Column, width: number): void; + + /** Function called whenever item properties change within the control, providing the changed item, relevant property name, and Boolean values indicating whether this change was directly triggered by the user, and whether this is the final change in a periodic operation such as a drag and drop action, specified as parameters; a custom function may be provided by the developer in order to receive notifications whenever data changes occur within the control, when using the default grid columns and task template functions. */ + itemPropertyChangeHandler? (item: Item, propertyName: string, isDirect: boolean, isFinal: boolean): void; + /** Function called whenever summary item expansion state changes within the control, providing the expanded or collapsed item, and a Boolean value indicating the updated expansion state, specified as parameters. */ + itemExpansionChangeHandler? (item: Item, isExpanded: boolean): void; + /** Function called whenever item selection changes within the control, providing the selected or unselected item, a Boolean value indicating the updated selection state, and a Boolean value indicating whether this change was directly triggered by the user, specified as parameters. */ + itemSelectionChangeHandler? (item: Item, isSelected: boolean, isDirect: boolean): void; + + /** Function called whenever an item is moved in the managed list of the control, providing the item, source and target positions of the item, specified as parameters. */ + itemMoveHandler? (item: Item, fromIndex: number, toIndex: number): void; + + itemContextMenuHandler? (e: Event, item: Item): void; + predecessorItemContextMenuHandler? (e: Event, predecessorItem: PredecessorItem, targetItem: Item): void; + + mouseHandler? (eventName: string, isOnItemsArea: boolean, isOnChart: boolean, row: Item|Scale, column: Column|Date, button: number, clickCount: number, e: MouseEvent): void; + mouseMoveHandler? (isOnItemsArea: boolean, isOnChart: boolean, row: Item|Scale, column: Column|Date): void; + mouseDownHandler? (isOnItemsArea: boolean, isOnChart: boolean, row: Item|Scale, column: Column|Date, button: number): void; + clickHandler? (isOnItemsArea: boolean, isOnChart: boolean, row: Item|Scale, column: Column|Date): void; + doubleClickHandler? (isOnItemsArea: boolean, isOnChart: boolean, row: Item|Scale, column: Column|Date): void; + itemClickHandler? (isOnChart: boolean, item: Item, column: Column|Date): void; + itemDoubleClickHandler? (isOnChart: boolean, item: Item, column: Column|Date): void; + chartClickHandler? (isOnItemsArea: boolean, row: Item|Scale, dateTime: Date): void; + chartDoubleClickHandler? (isOnItemsArea: boolean, row: Item|Scale, dateTime: Date): void; + chartItemClickHandler? (item: Item, dateTime: Date): void; + chartItemDoubleClickHandler? (item: Item, dateTime: Date): void; + dependencyLineClickHandler? (predecessorItem: PredecessorItem, targetItem: Item, e: MouseEvent): void; + dependencyLineDoubleClickHandler?(predecessorItem: PredecessorItem, targetItem: Item, e: MouseEvent): void; + + invalidPredecessorDetectionHandler?(predecessorItem: PredecessorItem, targetitem: Item, sourceItem: Item): void; + } + + /** Represents a grid column displayed by the GanttChartView component. */ + interface Column { + isTreeView?: boolean; + + header: any; + width: number; minWidth?: number; maxWidth?: number; + + isReadOnly?: boolean; allowUserToResize?: boolean; + isSelection?: boolean; + + headerClass?: string; headerStyle?: string; + cellClass?: string; cellStyle?: string; + + /** Function that returns the output (document node) to be presented within the grid cell of this column in the standard view, for a specific item received as parameter. */ + cellTemplate(item: Item): HTMLElement; + + exportCellTemplate? (item: Item): HTMLElement; + } + + /** Represents a chart scale displayed by the GanttChartView component. */ + interface Scale { + /** Type of the scale; supported values are: Years, Months, Weeks, Days, Hours, NonworkingTime (highlighting weekends), CurrentTime (current time vertical bar), FutureTime (current time vertical bar with future highlighting support), and Custom (the developer needs to also set the intervals collection in this case, using time interval objects defined by start and finish properties). */ + scaleType: string; + + isHeaderVisible?: boolean; headerHeight?: number; + + /** Format to use for scale header texts; supported values are: DateTime, Date, Hour, DayOfWeek, DayOfWeekAbbreviation, Day, Month, MonthAbbreviation, Year, MonthYear, Localized, and Custom (the developer needs to also set the headerText property of each interval object within the intervals collection of the scale object in this case), or a function that converts a Date parameter to a presentation string. */ + headerTextFormat?: any; + + headerClass?: string; headerStyle?: string; + + isHighlightingVisible?: boolean; + highlightingClass?: string; highlightingStyle?: string; + + isSeparatorVisible?: boolean; + separatorClass?: string; separatorStyle?: string; + + intervals?: ScaleInterval[]; + } + + /** Represents an interval for a custom scale displayed by the GanttChartView component. */ + interface ScaleInterval { + start: Date; finish: Date; + headerText?: string; + } + + /** Represents export settings for a GanttChartView component. */ + interface ExportSettings { + title?: string; preparingMessage?: string; + isGridVisible?: boolean; + columnIndexes?: number[]; + timelineStart?: Date; timelineFinish?: Date; + hourWidth?: number; + startRowIndex?: number; endRowIndex?: number; + rotate?: boolean; + autoClose?: boolean; + } + } + + /** Represents a control that presents resource and assigned task data items using a Schedule Chart and an associated grid. */ + module ScheduleChartView { + /** + * Initializes a ScheduleChartView component instance. + * @param element The HTMLElement that would host the user interface of the component. + * @param items resource data objects to be managed and presented by the component. + * @param settings Configuration settings for the component behavior and appearance. + */ + function initialize(element: HTMLElement, items: Item[], settings?: Settings, license?: String): Element; + + /** Returns an array of default definitions that you can further customize and use as value for the columns property of the control settings used at initialization time. */ + function getDefaultColumns(items: Item[], settings: Settings): GanttChartView.Column[]; + + /** Returns an array of default definitions that you can further customize and use as value for the scales property of the control settings used at initialization time. */ + function getDefaultScales(settings: Settings): GanttChartView.Scale[]; + + function getDefaultStyleDefinitionTemplate(controlElement: Element, settings: Settings): () => SVGDefsElement; + function getDefaultStandardTaskTemplate(items: GanttChartView.Item[], controlElement: Element, settings: Settings): (item: GanttChartView.Item) => SVGElement; + function getDefaultMilestoneTaskTemplate(items: GanttChartView.Item[], controlElement: Element, settings: Settings): (item: GanttChartView.Item) => SVGElement; + function getDefaultItemTemplate(settings: Settings): (item: GanttChartView.Item) => SVGElement; + function getDefaultAssignmentsTemplate(settings: Settings): (item: GanttChartView.Item) => SVGElement; + + /** Inside task template functions, sets up task drag and drop behavior for the non-null SVG elements specified to be designed as thumbs, considering the specified item and item positioning in the chart. */ + function initializeTaskDraggingThumbs(startThumb: SVGElement, startOnlyThumb: SVGElement, finishThumb: SVGElement, completedFinishThumb: SVGElement, item: GanttChartView.Item, itemLeft: number, itemRight: number, itemCompletedRight: number): void; + + /** Inside task template functions, sets up assignment update drag and drop behavior for the non-null SVG element specified to be designed as a thumb inside its specified container group that would be used to supplementary present temporary assignment target rectangles during drag and drop operations, considering the specified item and item positioning in the chart. */ + function initializeAssignmentDraggingThumb(thumb: SVGElement, containerGroup: SVGGElement, item: GanttChartView.Item, itemTop: number, itemRight: number): void; + + function getWorkingTime(dateTime: Date, settings: Settings): Date; + function getEffort(start: Date, finish: Date, settings: Settings): number; + function getFinish(start: Date, effort: number, settings: Settings): Date; + function getStart(effort: Date, finish: number, settings: Settings): Date; + function getCompletion(start: Date, completedFinish: Date, finish: Date, settings: Settings): number; + function getCompletedFinish(start: Date, completion: number, finish: Date, settings: Settings): number; + + function textColumnTemplateBase(document: HTMLDocument, valueGetter: () => any, isVisibleGetter?: () => boolean): HTMLElement; + function textInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean): HTMLElement; + + /** Prepares the specified date values to be used for component method input, considering that after initialization the component uses UTC date and time values internally; this method may also be called using a component instance object. */ + function getInputDate(date: Date): Date; + /** Prepares the specified date values to be used for component method result or field output, considering that after initialization the component uses UTC date and time values internally; this method may also be called using a component instance object. */ + function getOutputDate(date: Date): Date; + + /** Represents an HTML element that supplementary provides ScheduleChartView component services. */ + interface Element extends GanttChartView.Element { + scheduleChartItems: Item[]; + settings: Settings; + + refreshScheduleChartItem(item: Item): void; + + insertScheduleChartItem(index: number, item: Item): void; addScheduleChartItem(item: Item): void; insertScheduleChartItems(index: number, items: Item[]): void; addScheduleChartItems(items: Item[]): void; + removeScheduleChartItem(item: Item): void; removeScheduleChartItems(items: Item[]): void; + moveScheduleChartRange(fromIndex: number, count: number, toIndex: number): void; + moveScheduleChartItem(item: Item, toIndex: number); + moveScheduleChartItemUp(item: Item): void; moveScheduleChartItemDown(item: Item): void; + + setItemContent(item: Item, value: any): void; + + getCurrentItem(): Item; + getSelectedItem(): Item; getSelectedItems(): Item[]; + selectItem(item: Item): void; unselectItem(item: Item): void; + + scrollToItem(item: Item): void; + + getItemTop(item: Item): number; + + /** Calls itemPropertyChangeHandler function specified within the settings collection using the specified item, property name, and Boolean indicators for direct user actions and completed actions as arguments. */ + onItemPropertyChanged(item: Item, propertyName: string, isDirect: boolean, isFinal: boolean): void; + + isScheduleChartInitializing: boolean; isScheduleChartInitialized: boolean; + } + + /** Represents a resource data item and its Schedule Chart representation. */ + interface Item extends GanttChartView.Item { + /** The object that is displayed to represent the resource item in the grid, usually the resource name. */ + content: any; + + /** Task data items assigned to the current resource. */ + ganttChartItems: GanttChartView.Item[]; + + /** The index of the item in the Schedule Chart item collection. */ + scheduleChartIndex?: number; + } + + /** Represents settings for a ScheduleChartView component. */ + interface Settings extends GanttChartView.Settings { + areAssignmentsReadOnly?: boolean; + + assignmentThumbClass?: string; assignmentThumbStyle?: string; + temporaryAssignmentThumbClass?: string; temporaryAssignmentThumbStyle?: string; + + assignmentThumbTemplate? (item: GanttChartView.Item): SVGElement; + temporaryAssignmentThumbTemplate? (document: HTMLDocument, x: number, y: number, width: number, height: number): SVGElement; + } + } + + /** Represents a control that presents resource and allocation data items using a Load Chart and an associated grid. */ + module LoadChartView { + /** + * Initializes a LoadChartView component instance. + * @param element The HTMLElement that would host the user interface of the component. + * @param items resource data objects to be managed and presented by the component. + * @param settings Configuration settings for the component behavior and appearance. + */ + function initialize(element: HTMLElement, items: Item[], settings?: Settings, license?: String): Element; + + /** Returns an array of default definitions that you can further customize and use as value for the columns property of the control settings used at initialization time. */ + function getDefaultColumns(items: Item[], settings: Settings): GanttChartView.Column[]; + + /** Returns an array of default definitions that you can further customize and use as value for the scales property of the control settings used at initialization time. */ + function getDefaultScales(settings: Settings): GanttChartView.Scale[]; + + function getDefaultAllocationTemplate(items: GanttChartView.Item[], controlElement: Element, settings: Settings): (item: AllocationItem) => SVGElement; + + function getWorkingTime(dateTime: Date, settings: Settings): Date; + + function textColumnTemplateBase(document: HTMLDocument, valueGetter: () => any, isVisibleGetter?: () => boolean): HTMLElement; + function textInputColumnTemplateBase(document: HTMLDocument, width: number, valueGetter: () => any, valueSetter: (value: any) => void, isEnabledGetter?: () => boolean, isVisibleGetter?: () => boolean, isBoldGetter?: () => boolean): HTMLElement; + + /** Prepares the specified date values to be used for component method input, considering that after initialization the component uses UTC date and time values internally; this method may also be called using a component instance object. */ + function getInputDate(date: Date): Date; + /** Prepares the specified date values to be used for component method result or field output, considering that after initialization the component uses UTC date and time values internally; this method may also be called using a component instance object. */ + function getOutputDate(date: Date): Date; + + /** Represents an HTML element that supplementary provides LoadChartView component services. */ + interface Element extends ScheduleChartView.Element { + loadChartItems: Item[]; + settings: Settings; + + refreshLoadChartItem(item: Item): void; + + insertLoadChartItem(index: number, item: Item): void; addLoadChartItem(item: Item): void; insertLoadChartItems(index: number, items: Item[]): void; addLoadChartItems(items: Item[]): void; + removeLoadChartItem(item: Item): void; removeLoadChartItems(items: Item[]): void; + moveLoadChartRange(fromIndex: number, count: number, toIndex: number): void; + moveLoadChartItem(item: Item, toIndex: number); + moveLoadChartItemUp(item: Item): void; moveLoadChartItemDown(item: Item): void; + + setItemContent(item: Item, value: any): void; + + getCurrentItem(): Item; + getSelectedItem(): Item; getSelectedItems(): Item[]; + selectItem(item: Item): void; unselectItem(item: Item): void; + + scrollToItem(item: Item): void; + + getItemTop(item: Item): number; + + /** Calls itemPropertyChangeHandler function specified within the settings collection using the specified item, property name, and Boolean indicators for direct user actions and completed actions as arguments. */ + onItemPropertyChanged(item: Item, propertyName: string, isDirect: boolean, isFinal: boolean): void; + + isLoadChartInitializing: boolean; isLoadChartInitialized: boolean; + } + + /** Represents a resource data item and its Load Chart representation. */ + interface Item extends ScheduleChartView.Item { + /** Allocation data items assigned to the current resource. */ + ganttChartItems: AllocationItem[]; + + /** The index of the item in the Load Chart item collection. */ + loadChartIndex?: number; + } + + interface AllocationItem extends GanttChartView.Item { + finish: Date; + + /** Indicates the capacity used from the assigned resource item during the time interval represented by the current allocation item. */ + units: number; + } + + /** Represents settings for a LoadChartView component. */ + interface Settings extends ScheduleChartView.Settings { + /** The maximum allocation units that are to be displayed as a full height bar in in the chart. */ + maxDisplayedUnits?: number; + + normalAllocationBarClass?: string; underAllocationBarClass?: string; overAllocationBarClass?: string; normalAllocationBarStyle?: string; underAllocationBarStyle?: string; overAllocationBarStyle?: string; + allocationTemplate? (item: AllocationItem): SVGElement; + } + } +} diff --git a/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.HTML.Controls.js b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.HTML.Controls.js new file mode 100644 index 000000000..6c5395a1c --- /dev/null +++ b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.HTML.Controls.js @@ -0,0 +1,531 @@ +var DlhSoft;"undefined"===typeof DlhSoft&&(DlhSoft={assemblies:[],buildReleaseDate:new Date(1,0,1)});DlhSoft.assemblies.push({assembly:"DlhSoft.ProjectData.GanttChart.HTML.Controls",company:"DlhSoft",product:"Project Data Modern Library",version:"5.3.17.0",copyright:"Copyright \u00a9 2012-2020 DlhSoft",title:"Project Data Gantt Chart HTML Controls",description:"Project Data Gantt Chart related HTML client components"}); +DlhSoft.buildReleaseDate=function(c,N,P){c=new Date(c,N-1,P);return c>DlhSoft.buildReleaseDate?c:DlhSoft.buildReleaseDate}(2020,11,25);var _0x5c25="Licensing{undefined{string{DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.{.{length{license{push{type{content{:{lastIndexOf{substr{buildReleaseDate{charCodeAt{pow{toUpperCase{DlhSoft Component Licensing Warning{http://DlhSoft.com/Purchase.aspx{?Assemblies={,{http://www.componentsource.com/features/dlhsoft{ (version {){This component is currently licensed to be used for testing purposes only{The component is part of this assembly{To purchase a standard license for a product that includes this assembly you can use the Purchase page{ownerDocument{div{createElement{style{position: absolute; left: 24px; top: 24px; width: 480px; display: block; z-index: 1; color: Black; background-color: #ffffc0; border: solid 1px Blue; overflow: auto{setAttribute{padding: 6px; padding-top: 8px; font-family: Arial; font-size: small{font-weight: bold; margin-bottom: 4px{appendChild{createTextNode{color: Red; margin-top: 2px; margin-bottom: 2px{margin-top: 4px{a{color: Blue; text-decoration: underline{href{target{_blank{Purchase license{margin-left: 4px; color: Blue; text-decoration: underline{javascript://{Continue trial{click{removeChild{addEventListener{\n\n{: {:\n".split("{"); +void 0==DlhSoft[_0x5c25[0]]&&(DlhSoft[_0x5c25[0]]=function(){var c=_0x5c25[1],N=_0x5c25[2],P=[],aa=[],ha=_0x5c25[3],ia=function(T,K){if(typeof T!==N||typeof K!==N)return!1;if(K==ha)return!0;var ba=K[_0x5c25[11]](_0x5c25[10]);if(0<=ba){var M=K[_0x5c25[12]](0,ba),I,L=M[_0x5c25[11]](_0x5c25[10]);if(0<=L)try{I=new Date(parseInt(M[_0x5c25[12]](L+1)))}catch(Q){}typeof I===c&&(I=new Date(2013,11,31));if(DlhSoft[_0x5c25[13]]>I)return!1;M=M+_0x5c25[10]+T;for(i=I=0;i I&&(I=Math[_0x5c25[15]](2,32)-I);M=I.toString(16)[_0x5c25[16]]();ba=K[_0x5c25[12]](ba+1);if(M==ba)return!0}return!1},W=function(T,K,N,M,I){var L=_0x5c25[17],Q=_0x5c25[18],V=typeof ComponentSource===c||!ComponentSource?Q+_0x5c25[19]+M+_0x5c25[20]+I:_0x5c25[21],P=M+_0x5c25[22]+I+_0x5c25[23],W=_0x5c25[24],x=_0x5c25[25],o=_0x5c25[26];setTimeout(function(){var c=T[_0x5c25[27]],s=c[_0x5c25[29]](_0x5c25[28]);s[_0x5c25[32]](_0x5c25[30],_0x5c25[31]);var q=c[_0x5c25[29]](_0x5c25[28]);q[_0x5c25[32]](_0x5c25[30], +_0x5c25[33]);var v=c[_0x5c25[29]](_0x5c25[28]);v[_0x5c25[32]](_0x5c25[30],_0x5c25[34]);q[_0x5c25[35]](v);v[_0x5c25[35]](c[_0x5c25[36]](L));q[_0x5c25[35]](c[_0x5c25[36]](W+_0x5c25[10]));v=c[_0x5c25[29]](_0x5c25[28]);v[_0x5c25[32]](_0x5c25[30],_0x5c25[37]);v[_0x5c25[35]](c[_0x5c25[36]](K));q[_0x5c25[35]](v);q[_0x5c25[35]](c[_0x5c25[36]](x+_0x5c25[10]));v=c[_0x5c25[29]](_0x5c25[28]);v[_0x5c25[32]](_0x5c25[30],_0x5c25[37]);v[_0x5c25[35]](c[_0x5c25[36]](P));q[_0x5c25[35]](v);q[_0x5c25[35]](c[_0x5c25[36]](o+ +_0x5c25[10]));v=c[_0x5c25[29]](_0x5c25[28]);v[_0x5c25[32]](_0x5c25[30],_0x5c25[38]);var C=c[_0x5c25[29]](_0x5c25[39]);C[_0x5c25[32]](_0x5c25[30],_0x5c25[40]);C[_0x5c25[32]](_0x5c25[41],V);C[_0x5c25[32]](_0x5c25[42],_0x5c25[43]);C[_0x5c25[35]](c[_0x5c25[36]](_0x5c25[44]));v[_0x5c25[35]](C);C=c[_0x5c25[29]](_0x5c25[39]);C[_0x5c25[32]](_0x5c25[30],_0x5c25[45]);C[_0x5c25[32]](_0x5c25[41],_0x5c25[46]);C[_0x5c25[35]](c[_0x5c25[36]](_0x5c25[47]));C[_0x5c25[50]](_0x5c25[48],function(){T[_0x5c25[49]](s);aa[_0x5c25[7]](N)}, +!1);v[_0x5c25[35]](C);q[_0x5c25[35]](v);s[_0x5c25[35]](q);T[_0x5c25[35]](s)},0);setTimeout(function(){alert(L+_0x5c25[51]+W+_0x5c25[52]+K+_0x5c25[51]+x+_0x5c25[53]+P+_0x5c25[51]+o+_0x5c25[4])},6E5)};return{setLicense:function(c,K){P[_0x5c25[7]]({type:c,content:K})},validate:function(T,K,ba,M,I,L,Q){for(var K=K+_0x5c25[4]+ba,V=0;V 0?a.insertBefore(b,a.childNodes[0]):a.appendChild(b)}catch(d){}},0)};C.addEventListener("mousedown",w,true);u.addEventListener("mouseup",w,true);a.resetChartAreaDefinitions=w;r.appendChild(C);r.chartArea=C;if(typeof e.extraSpaceHeight!==c){w=u.createElement("div");w.setAttribute("style","overflow: hidden; width: "+q+"px; height: "+e.extraSpaceHeight+"px");F.appendChild(w);F.chartExtraSpace=w}var x,z,y;setTimeout(function(){x=a.offsetWidth;z=a.offsetHeight;y=J.offsetHeight},0); +typeof a.splitterUpdateTimer!==c&&clearInterval(a.splitterUpdateTimer);a.splitterUpdateTimer=setInterval(function(){try{if(typeof p.x===c&&!(a.offsetWidth<=0)){var b=a.offsetWidth,d=J.offsetHeight,g=screen.deviceXDPI;if(b!=x||g!=screen.deviceXDPI){var m=typeof t.percent!==c?t.percent*b:t.offsetWidth,j=J.offsetWidth,f=Math.max(1,e.minGridWidth),l=Math.max(1,e.minChartWidth);if(m 0&&u>0&&setTimeout(function(){e.splitterPositionChangeHandler(h,u)},0)}x=b;z=d}else if(d!=y){Ba(p,t,e);y=d}}}catch(w){try{clearInterval(a.splitterUpdateTimer)}catch(F){}}},100);typeof a.heightUpdateTimer!==c&&clearInterval(a.heightUpdateTimer);a.heightUpdateTimer=setInterval(function(){try{if(!(a.clientHeight<=0)){var b= +a.clientHeight;if(b!=z){var c=I(a,d,e);o.style.height=c;F.style.height=c;Ba(p,t,e);if(F.style.height!="auto")r.availableHeight=F.clientHeight;ta(r,ua(d,e));va(d,F,e);z=b}}}catch(g){try{clearInterval(a.heightUpdateTimer)}catch(m){}}},100);var A=function(a,b,g,m,j,f){var l;if(e.mouseHandler||e.mouseMoveHandler&&f=="mousemove"||e.mouseDownHandler&&f=="mousedown"||(e.clickHandler||e.itemClickHandler||e.chartClickHandler||e.chartItemClickHandler)&&f=="click"||(e.doubleClickHandler||e.itemDoubleClickHandler|| +e.chartDoubleClickHandler||e.chartItemDoubleClickHandler)&&f=="dblclick"){var n=a.which;!n&&a.button&&(a.button&1?n=1:a.button&4?n=2:a.button&2&&(n=3));l=j.getBoundingClientRect();var h=u.body,p=u.documentElement,j=l.left+(window.pageXOffset||p.scrollLeft||h.scrollLeft)-(p.clientLeft||h.clientLeft||0);l=Math.round(l.top+(window.pageYOffset||p.scrollTop||h.scrollTop)-(p.clientTop||h.clientTop||0));var j=Math.round(j),j=a.pageX-j,p=a.pageY-l,t=l=0,w,F;if(g)for(h=0;h 0&&(ka=e.headerHeight/o);for(h=0;h 0;)v.removeChild(v.childNodes[f]);var l= +[];for(f=C.childNodes.length;f-- >1;){var n=C.childNodes[f];if(n!=r.chartAreaAlternativeRows){n.tag!="Scale-Highlighting"&&(n.tag!="Scale-Highlighting-CurrentTime"&&n.tag!="Scale-Separator"&&n.tag!="Scale-Separator-CurrentTime")&&l.push(n);C.removeChild(n)}}hb(v,C,e.scales,e);for(f=0;f 0;)C.appendChild(l[f]);ta(r,ua(d,e));F.scrollLeft=m*(a/j)-(m-g);setTimeout(function(){B= +false},200)}};a.setHourWidth=D;if(typeof e.isMouseWheelZoomEnabled===c||e.isMouseWheelZoomEnabled){b=function(b){b.preventDefault();b.stopPropagation();if(!B){var d=typeof b.wheelDelta!==c?b.wheelDelta>=0?1:-1:typeof b.detail!==c?-b.detail>=0?1:-1:0,e=a.settings,g=e.hourWidth,m=typeof e.isMouseWheelZoomEnabledMinHourWidth!==c?e.isMouseWheelZoomEnabledMinHourWidth:1;if(d<0)g=g/(1.2*-d);else if(d>0){g=g*1.2*d;d=typeof e.isMouseWheelZoomEnabledMaxHourWidth!==c?e.isMouseWheelZoomEnabledMaxHourWidth:20; +g>d&&(g=d)}g =a.visibleDayFinish){a.visibleWeekStart=0;a.visibleWeekFinish= +864E5}if(typeof a.visibleWeekStart===c)a.visibleWeekStart=0;if(typeof a.visibleWeekFinish===c)a.visibleWeekFinish=6;if(a.visibleWeekStart>a.visibleWeekFinish)if(a.visibleWeekStart==a.visibleWeekFinish+1){a.visibleWeekStart=0;a.visibleWeekFinish=6}else a.visibleWeekFinish=a.visibleWeekStart;if(typeof a.workingWeekStart===c)a.workingWeekStart=1;if(typeof a.workingWeekFinish===c)a.workingWeekFinish=5;if(a.workingWeekStart>a.workingWeekFinish)if(a.workingWeekStart==a.workingWeekFinish+1){a.workingWeekStart= +0;a.workingWeekFinish=6}else a.workingWeekFinish=a.workingWeekStart;a.workingDayStart=a.visibleDayStart;a.workingDayFinish=a.visibleDayFinish;if(typeof a.barMargin===c)a.barMargin=a.itemHeight/4;if(typeof a.barHeight===c)a.barHeight=a.itemHeight-a.barMargin*2;if(typeof a.barCornerRadius===c)switch(a.theme){default:a.barCornerRadius=0;break;case "Aero":a.barCornerRadius=3}if(typeof a.completedBarMargin===c)a.completedBarMargin=a.barHeight/2.5;if(typeof a.completedBarHeight===c)a.completedBarHeight= +a.barHeight-a.completedBarMargin*2;if(typeof completedBarCornerRadius===c)a.completedBarCornerRadius=0;if(typeof a.styleDefinitionTemplate===c)a.styleDefinitionTemplate=Fb(e,a);if(typeof a.standardBarStyle===c&&a.standardBarClass==null)switch(a.theme){default:a.standardBarStyle="fill: #8abbed; fill-opacity: 0.8; stroke: #8abbed; stroke-width: 0.65px";break;case "ModernBordered":a.standardBarStyle="fill: #8abbed; fill-opacity: 0.8; stroke: Blue; stroke-width: 0.65px";break;case "Aero":a.standardBarStyle= +"fill: url(#BlueGradient); fill-opacity: 0.8; stroke: Blue"}if(typeof a.standardCompletedBarStyle===c&&a.standardCompletedBarClass==null)switch(a.theme){default:a.standardCompletedBarStyle="fill: #3b87d9; stroke: #3b87d9; stroke-width: 0.65px";break;case "Aero":a.standardCompletedBarStyle="fill: #808080; stroke: #202020; stroke-width: 0.65px"}if(typeof a.summaryBarStyle===c&&a.summaryBarClass==null)switch(a.theme){default:a.summaryBarStyle="fill: #607080; stroke: #607080; stroke-width: 0.65px";break; +case "ModernBordered":a.summaryBarStyle="fill: #607080; stroke: #202020; stroke-width: 0.65px";break;case "Aero":a.summaryBarStyle="fill: url(#BlackGradient); stroke: Black"}if(typeof a.summaryCompletedBarStyle===c&&a.summaryCompletedBarClass==null)switch(a.theme){default:a.summaryCompletedBarStyle="fill: #404040; stroke: #404040; stroke-width: 0.65px";break;case "Aero":a.summaryCompletedBarStyle="fill: #a0a0a0; stroke: #303030; stroke-width: 0.65px"}if(typeof a.collapsedSummaryLineStyle===c&&a.collapsedSummaryLineClass== +null)a.collapsedSummaryLineStyle="stroke: #3b87d9; stroke-width: 0.65px; stroke-dasharray: 2 2";if(typeof a.milestoneBarStyle===c&&a.milestoneBarClass==null)switch(a.theme){default:a.milestoneBarStyle="fill: #607080; stroke: #607080; stroke-width: 0.65px";break;case "ModernBordered":a.milestoneBarStyle="fill: #607080; stroke: #202020; stroke-width: 0.65px";break;case "Aero":a.milestoneBarStyle="fill: url(#BlackGradient); stroke: Black"}if(typeof a.baselineBarStyle===c&&a.baselineBarClass==null)switch(a.theme){default:a.baselineBarStyle= +"fill: none; stroke: #3b87d9; stroke-width: 0.65px; stroke-dasharray: 2, 2";break;case "Aero":a.baselineBarStyle="fill: none; stroke: Blue; stroke-dasharray: 2, 2"}if(typeof a.dependencyPointerStyle===c&&a.dependencyPointerClass==null)switch(a.theme){default:a.dependencyPointerStyle="fill: #3b87d9; stroke: #3b87d9; stroke-width: 0.65px";break;case "Aero":a.dependencyPointerStyle="fill: Blue; stroke: Blue"}if(typeof a.dependencyLineStyle===c&&a.dependencyLineClass==null)switch(a.theme){default:a.dependencyLineStyle= +"stroke: #3b87d9; stroke-width: 0.65px; fill: none; marker-end: url(#ArrowMarker)";break;case "Aero":a.dependencyLineStyle="stroke: Blue; stroke-width: 0.65px; fill: none; marker-end: url(#ArrowMarker)"}if(typeof a.dependencyLineZoneStyle===c&&a.dependencyLineZoneClass==null)a.dependencyLineZoneStyle="stroke: White; stroke-opacity: 0; stroke-width: 4px; fill: none";if(typeof a.temporaryDependencyLineStyle===c&&a.temporaryDependencyLineClass==null)switch(a.theme){default:a.temporaryDependencyLineStyle= +"stroke: #3b87d9; stroke-width: 0.65px; stroke-dasharray: 2, 2; fill: none; marker-end: url(#ArrowMarker)";break;case "Aero":a.temporaryDependencyLineStyle="stroke: Blue; stroke-width: 0.65px; stroke-dasharray: 2, 2; fill: none; marker-end: url(#ArrowMarker)"}if(typeof a.assignmentsStyle===c&&a.assignmentsClass==null)a.assignmentsStyle="stroke-width: 0.25px; font-size: x-small";if(typeof a.standardTaskTemplate===c)a.standardTaskTemplate=Gb();if(typeof a.summaryTaskTemplate===c)a.summaryTaskTemplate= +Hb();if(typeof a.milestoneTaskTemplate===c)a.milestoneTaskTemplate=Ib();if(typeof a.horizontalChartLines!==c){var n=a.internalPreTaskTemplate;a.internalPreTaskTemplate=function(b){if(typeof b.scheduleChartItem!==c)return typeof n!==c?n(b):null;var d=b.ganttChartView.ownerDocument,e=d.createElementNS("http://www.w3.org/2000/svg","g");typeof n!==c&&e.appendChild(n(b));var g=d.createElementNS("http://www.w3.org/2000/svg","line");g.setAttribute("x1",0);g.setAttribute("y1",-0.5);g.setAttribute("x2",H(a.timelineFinish, +a));g.setAttribute("y2",-0.5);g.setAttribute("style","stroke: "+a.horizontalChartLines+"; stroke-width: 0.5px");e.appendChild(g);if(b.index==b.ganttChartView.items.length-1){g=d.createElementNS("http://www.w3.org/2000/svg","line");g.setAttribute("x1",0);g.setAttribute("y1",a.itemHeight+0.5);g.setAttribute("x2",H(a.timelineFinish,a));g.setAttribute("y2",a.itemHeight+0.5);g.setAttribute("style","stroke: "+a.horizontalChartLines+"; stroke-width: 0.5px");e.appendChild(g)}return e}}if(typeof a.isTaskToolTipVisible=== +c)switch(a.target){default:a.isTaskToolTipVisible=true;break;case "Phone":a.isTaskToolTipVisible=false}if(typeof a.itemTemplate===c)a.itemTemplate=Jb(a);if(typeof a.areTaskAssignmentsVisible===c)a.areTaskAssignmentsVisible=true;if(typeof a.assignmentsTemplate===c)a.assignmentsTemplate=Kb();if(typeof a.isTaskCompletedEffortVisible===c)a.isTaskCompletedEffortVisible=true;if(typeof a.areTaskDependenciesVisible===c)a.areTaskDependenciesVisible=true;if(typeof a.dependencyLineTemplate===c)a.dependencyLineTemplate= +Lb();if(typeof a.isDependencyToolTipVisible===c)a.isDependencyToolTipVisible=a.isTaskToolTipVisible;if(typeof a.predecessorItemTemplate===c)a.predecessorItemTemplate=Mb(a);if(typeof a.isDraggingTaskStartEndsEnabled===c)a.isDraggingTaskStartEndsEnabled=true;if(typeof a.areTaskDependencyConstraintsEnabledWhileDragging===c)a.areTaskDependencyConstraintsEnabledWhileDragging=false;if(typeof a.isTaskStartReadOnly===c)a.isTaskStartReadOnly=false;if(typeof a.isTaskEffortReadOnly===c)a.isTaskEffortReadOnly= +false;if(typeof a.isTaskCompletionReadOnly===c)a.isTaskCompletionReadOnly=false;if(typeof a.areTaskPredecessorsReadOnly===c)a.areTaskPredecessorsReadOnly=false;if(typeof a.isBaselineVisible===c)a.isBaselineVisible=true;if(typeof a.isSummaryTaskCompletedEffortVisible===c)a.isSummaryTaskCompletedEffortVisible=false;var w=null;if(a.isIndividualItemNonworkingTimeHighlighted||a.areTaskInterruptionsHighlighted)for(d=0;d =b.start?g:b.start,finish:m<=b.finish?m:b.finish});e=typeof e!==c&&typeof e.specialNonworkingDays!==c?e.specialNonworkingDays:a.specialNonworkingDays;if(typeof e!==c)for(var f=0;f =b.start&&m<=b.finish&&d.push({start:g,finish:m})}}if(d==null||d.length==0)return typeof t!== +c?t(b):null;g=b.ganttChartView.ownerDocument;m=g.createElementNS("http://www.w3.org/2000/svg","g");for(e=0;e =0&&p 0?"auto":e.itemHeight+"px";else{var c=a.clientHeight-e.headerHeight-2;c<0&&(c=0);b=c+"px";if(c 0?"auto":e.itemHeight+"px"}a.isContentHeightInitialized=true}return b},L=function(a,d){if(typeof d.toggleButtonAreaWidth!==c)return d.toggleButtonAreaWidth;var e=0;if(d.isGridVisible)for(var b=0;b 0){e=16;break}return d.toggleButtonAreaWidth=e},Q=function(a, +d){var e=a.createElement("span");e.innerHTML=d;return e},V=function(a,d){return d==true?a.createTextNode("\u2713"):a.createTextNode("")},Z=function(a){var d=a.getFullYear(),e=a.getMonth()+1;e<10&&(e="0"+e);a=a.getDate();a<10&&(a="0"+a);return e+"/"+a+"/"+d},sa=function(a){var d=Z(a),e=a.getHours();e<10&&(e="0"+e.toString());a=a.getMinutes();a<10&&(a="0"+a.toString());return d+" "+e+":"+a},x=function(a){return new Date(a.valueOf()+a.getTimezoneOffset()*6E4)},o=function(a){var d=new Date;if(a==null|| +a=="")return d;var e,b,c,f;c=a.indexOf(" ");if(c>=0){e=a.substr(0,c);f=a.substr(c+1)}else{e=a;f="0"}c=e.indexOf("/");if(c>=0){for(a=e.substr(0,c);a.length>0&&a.substr(0,1)=="0";)a=a.substr(1);a=parseInt(a)-1;e=e.substr(c+1);c=e.indexOf("/");if(c>=0){b=e.substr(0,c);for(c=e.substr(c+1);c.length>0&&c.substr(0,1)=="0";)c=c.substr(1);e=parseInt(c)}else{b=e;e=d.getFullYear()}for(;b.length>0&&b.substr(0,1)=="0";)b=b.substr(1);b=parseInt(b)}else{for(;e.length>0&&e.substr(0,1)=="0";)e=e.substr(1);b=parseInt(e); +a=d.getMonth();e=d.getFullYear()}var h;c=f.indexOf(":");if(c>=0){h=f.substr(0,c);f=f.substr(c+1)}else{h=f;f="0"}for(;h.length>1&&h.substr(0,1)=="0";)h=h.substr(1);for(c=parseInt(h);f.length>1&&f.substr(0,1)=="0";)f=f.substr(1);f=parseInt(f);return isNaN(e)||isNaN(a)||isNaN(b)||e<=0||a<0||a>=12||b<1||b>aa[a]+(a!=1||!(e%400==0||(e%100==0?0:e%4==0))?0:1)?isNaN(c)||isNaN(f)||c<0||c>=24||f<0||f>=60?d:new Date(d.getFullYear(),d.getMonth(),d.getDate(),c,f,0,0):isNaN(c)||isNaN(f)||c<0||c>=24||f<0||f>=60? +new Date(e,a,b,0,0,0,0):new Date(e,a,b,c,f,0,0)},k=function(a){return new Date(a.valueOf()-a.getTimezoneOffset()*6E4)},s=function(a,d){var e=a.ownerDocument,b=e.createElementNS("http://www.w3.org/2000/svg","svg");b.setAttribute("style","width: 12px; height: 12px; vertical-align: initial");b.setAttribute("focusable","false");e=e.createElementNS("http://www.w3.org/2000/svg","rect");e.setAttribute("id","PART_Border");e.setAttribute("width","12");e.setAttribute("height","12");e.setAttribute("style","fill: White; fill-opacity: 0"); +b.appendChild(e);a.setAttribute("id","PART_Button");typeof d.toggleButtonClass!==c&&a.setAttribute("class",d.toggleButtonClass);typeof d.toggleButtonStyle!==c&&a.setAttribute("style",d.toggleButtonStyle);b.appendChild(a);return b},q=function(a,d){typeof d!=="object"&&(d={});K(d);var e=[{header:"",width:32,isSelection:true},{header:"Task",width:140,isTreeView:true},{header:"Start",width:140},{header:"Finish",width:140},{header:"Milestone",width:80},{header:"Completed",width:80},{header:"Assignments", +width:200}];e[0].cellTemplate=v(d,e[0],a);e[1].cellTemplate=A(d,e[1],a);e[1].exportCellTemplate=A(d,e[1],a,false);e[2].cellTemplate=Nb(d,e[2]);e[2].exportCellTemplate=Nb(d,e[2],false);e[3].cellTemplate=Ob(d,e[3]);e[3].exportCellTemplate=Ob(d,e[3],false);e[4].cellTemplate=G(d,e[4]);e[4].exportCellTemplate=G(d,e[4],false);e[5].cellTemplate=Pb(d,e[5]);e[5].exportCellTemplate=Pb(d,e[5],false);e[6].cellTemplate=Qb(d,e[6]);e[6].exportCellTemplate=Qb(d,e[6],false);d.selectionMode!="Single"&&(d.selectionMode!= +"Extended"&&d.selectionMode!="ExtendedFocus")&&e.splice(0,1);return e},v=function(a,d,e){return function(b){return!d.isReadOnly?C(b,a,e):V(b.ganttChartView.ownerDocument,b.isSelected)}},C=function(a,d){var e=a.ganttChartView.ownerDocument,b;if(typeof a.selectionInput===c){b=e.createElement("input");a.selectionInput=b;b.type="checkbox";b.setAttribute("style","margin: 0px")}else b=a.selectionInput;if(a.isSelected){b.setAttribute("checked","checked");if(!b.checked)b.checked=true}else if(b.checked)b.checked= +false;var g=function(){b.checked?r(a,true,d.selectionMode):r(a,false,d.selectionMode)};typeof b.changeEventListener!==c&&b.removeEventListener("change",b.changeEventListener,true);b.addEventListener("change",g,true);b.changeEventListener=g;e=function(a){if(a.keyCode==13){a.preventDefault();a.stopPropagation();g(a)}};typeof b.keyPressEventListener!==c&&b.removeEventListener("keypress",b.keyPressEventListener,true);b.addEventListener("keypress",e,true);b.keyPressEventListener=e;return b},r=function(a, +d,e){a.isSelected=d;y(a,"isSelected",true,true);Rb(a);if(typeof a.ganttChartView!==c){a.ganttChartView.selectedItem=a;if(e!="Extended"&&e!="ExtendedFocus")a.ganttChartView.selectedItems=[a];var b;if(e!="Extended"&&e!="ExtendedFocus")for(b=0;b +a.start,d,m;if(e.isTaskEffortPreservedWhenStartChangesInGrid){d=da(a,e);m=ya(a,e)}a.start=R(k(e.dateTimeParser(g.value)),e,true,a.isMilestone,D(a));a.preferredStart=a.start;if(a.isMilestone)a.finish=a.start;y(a,"start",true,true);if(a.finish a.finish){a.completedFinish=a.finish;y(a,"completedFinish",false,true)}if(typeof a.completedInput!== +c){b=a.completedInput;typeof b.changeEventListener!==c&&b.removeEventListener("change",b.changeEventListener,true);delete a.completedInput}if(e.isTaskEffortPreservedWhenStartChangesInGrid){Wa(a,d,e);Xa(a,m,e)}}Y(a)};typeof g.changeEventListener!==c&&g.removeEventListener("change",g.changeEventListener,true);g.addEventListener("change",m,true);g.changeEventListener=m;d=function(a){if(a.keyCode==13){a.preventDefault();a.stopPropagation();m(a)}};typeof g.keyPressEventListener!==c&&g.removeEventListener("keypress", +g.keyPressEventListener,true);g.addEventListener("keypress",d,true);g.keyPressEventListener=d;return g},Ob=function(a,d,e){var b=function(b){return typeof b.finish===c||typeof b.isMilestone!==c&&b.isMilestone==true&&typeof b.start!==c&&b.finish.valueOf()==b.start.valueOf()||typeof b.isSummaryEnabled!==c&&!b.isSummaryEnabled&&typeof b.isBarVisible!==c&&!b.isBarVisible?b.ganttChartView.ownerDocument.createTextNode(""):b.ganttChartView.ownerDocument.createTextNode(a.dateTimeFormatter(x(b.finish)))}; +return(typeof e===c||e)&&!a.isReadOnly&&!a.isGridReadOnly?function(e){return!d.isReadOnly&&(typeof e.isReadOnly===c||!e.isReadOnly)&&!(typeof e.isSummaryEnabled!==c&&!e.isSummaryEnabled&&typeof e.isBarVisible!==c&&!e.isBarVisible)?Dc(e,Math.max(0,d.width-16),a):b(e)}:b},Dc=function(a,d,e){var b=a.ganttChartView.ownerDocument,g;if(typeof a.finishInput===c){g=b.createElement("input");a.finishInput=g;try{g.type=e.dateTimePickerType}catch(f){g.type="text"}g.addEventListener("focus",function(){z(a,e)}, +false);g.addEventListener("focus",function(){g.style.backgroundColor="White"},false);g.addEventListener("blur",function(){g.style.backgroundColor="Transparent"},false)}else g=a.finishInput;if(typeof a.finish!==c)g.value=e.dateTimeFormatter(x(a.finish));DlhSoft.Controls.DatePicker&&(e.dateTimePickerType=="text"&&e.useDatePicker)&&g.addEventListener("focus",function(){if(!a.isWaitingToRefreshGridItem){var d=(e.useTimePicker&&DlhSoft.Controls.DateTimePicker?DlhSoft.Controls.DateTimePicker:DlhSoft.Controls.DatePicker).get(g); +if(!d||!d.isOpen){var c=0,m=0;try{c=g.selectionStart;m=g.selectionEnd}catch(f){}d=(e.useTimePicker&&DlhSoft.Controls.DateTimePicker?DlhSoft.Controls.DateTimePicker:DlhSoft.Controls.DatePicker).initialize(g,void 0,{inputStyle:null,isDropDownButtonVisible:false,defaultTimeOfDay:e.workingDayFinish,dateTimeFormatter:e.dateTimeFormatter,dateTimeParser:e.dateTimeParser,popupStyle:"margin-top: 1px; background-color: White; border: 1px solid "+e.border,disabledDateSelector:Sb(e),disabledTimeSelector:U(e, +a),calendarSelectorLevels:e.calendarSelectorLevels,months:e.months,daysOfWeek:Va(e.daysOfWeek)},"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.");d.openDropDown();setTimeout(function(){try{g.selectionStart=c;g.selectionEnd=m}catch(a){}},100);navigator.userAgent.match(/(Android)|(IPad)|(IPhone)/i)==null?setTimeout(function(){try{g.focus()}catch(a){}},100):b.createEvent&&setTimeout(function(){var a=b.createEvent("MouseEvents"); +a.initEvent("blur",true,false);g.dispatchEvent(a)})}}},true);var h="";typeof a.isMilestone!==c&&a.isMilestone==true&&(h="; visibility: hidden");var m="";if(a.hasChildren&&(typeof a.isSummaryEnabled===c||a.isSummaryEnabled))m="; font-weight: bold";g.setAttribute("style","background-color: Transparent; width: "+d+"px; border-width: 0px; padding: 0px"+h+m);a.hasChildren&&(typeof a.isSummaryEnabled===c||a.isSummaryEnabled)?g.setAttribute("disabled","true"):g.removeAttribute("disabled");var j=function(){if(!a.hasChildren|| +!(typeof a.isSummaryEnabled===c||a.isSummaryEnabled)){var b=k(e.dateTimeParser(g.value));g.value.length>0&&(g.value.indexOf(" ")<0&&ja(b)==0)&&(b=$(b));a.finish=R(b,e,a.isMilestone,true,D(a));if(a.finish a.finish){a.completedFinish=a.finish;y(a,"completedFinish",false,true)}if(typeof a.completedInput!==c){b=a.completedInput;typeof b.changeEventListener!== +c&&b.removeEventListener("change",b.changeEventListener,true);delete a.completedInput}}Y(a)};typeof g.changeEventListener!==c&&g.removeEventListener("change",g.changeEventListener,true);g.addEventListener("change",j,true);g.changeEventListener=j;d=function(a){if(a.keyCode==13){a.preventDefault();a.stopPropagation();j(a)}};typeof g.keyPressEventListener!==c&&g.removeEventListener("keypress",g.keyPressEventListener,true);g.addEventListener("keypress",d,true);g.keyPressEventListener=d;return g},Sb=function(a){return function(d){if(d.getDay()< +a.workingWeekStart||d.getDay()>a.workingWeekFinish)return true;d=k(d).valueOf();if(a.specialNonworkingDays)for(var e=0;e =a.visibleDayFinish}},U=function(a,d){return function(e){return(X(d.start) a.visibleDayFinish}},Va=function(a){if(a){for(var d=[],e=0;e 0?b[0].toUpperCase()+(b.length>1?b[1]:""):"";d.push(b)}return d}},G=function(a,d,e){var b=function(a){return typeof a.isMilestone===c||typeof a.isSummaryEnabled!==c&&!a.isSummaryEnabled&&typeof a.isBarVisible!==c&&!a.isBarVisible?a.ganttChartView.ownerDocument.createTextNode(""):V(a.ganttChartView.ownerDocument,a.isMilestone)};return(typeof e===c||e)&&!a.isReadOnly&&!a.isGridReadOnly?function(e){return!d.isReadOnly&&(typeof e.isReadOnly===c||!e.isReadOnly)&&!(typeof e.isSummaryEnabled!== +c&&!e.isSummaryEnabled&&typeof e.isBarVisible!==c&&!e.isBarVisible)?Ec(e,a):b(e)}:b},Ec=function(a,d){var e=a.ganttChartView.ownerDocument,b;if(typeof a.milestoneInput===c){b=e.createElement("input");a.milestoneInput=b;b.type="checkbox";b.setAttribute("style","margin: 0px; margin-left: 2px; margin-right: 2px");b.addEventListener("focus",function(){z(a,d)},false)}else b=a.milestoneInput;(!a.hasChildren||!(typeof a.isSummaryEnabled===c||a.isSummaryEnabled))&&typeof a.isMilestone!==c&&a.isMilestone? +b.setAttribute("checked",true):b.removeAttribute("checked");if(!a.hasChildren||!(typeof a.isSummaryEnabled===c||a.isSummaryEnabled)){var g=function(){if(b.checked){a.isMilestone=true;y(a,"isMilestone",true,true);if(a.finish>a.start){a.finish=a.start;y(a,"finish",false,true)}if(a.completedFinish>a.start){a.completedFinish=a.start;y(a,"completedFinish",false,true)}}else{a.isMilestone=false;y(a,"isMilestone",true,true)}Y(a)};typeof b.changeEventListener!==c&&b.removeEventListener("change",b.changeEventListener, +true);b.addEventListener("change",g,true);b.changeEventListener=g;e=function(a){if(a.keyCode==13){a.preventDefault();a.stopPropagation();g(a)}};typeof b.keyPressEventListener!==c&&b.removeEventListener("keypress",b.keyPressEventListener,true);b.addEventListener("keypress",e,true);b.keyPressEventListener=e}else b.setAttribute("style","visibility: hidden");return b},Qb=function(a,d,e){var b=function(a){return typeof a.assignmentsContent===c||typeof a.isSummaryEnabled!==c&&!a.isSummaryEnabled&&typeof a.isBarVisible!== +c&&!a.isBarVisible?a.ganttChartView.ownerDocument.createTextNode(""):Q(a.ganttChartView.ownerDocument,a.assignmentsContent)};return(typeof e===c||e)&&!a.isReadOnly&&!a.isGridReadOnly&&!a.isAssignmentsContentReadOnly?function(e){return!d.isReadOnly&&(typeof e.isReadOnly===c||!e.isReadOnly)&&!(typeof e.isSummaryEnabled!==c&&!e.isSummaryEnabled&&typeof e.isBarVisible!==c&&!e.isBarVisible)?Fc(e,Math.max(0,d.width-16),a):b(e)}:b},Fc=function(a,d,e){var b=a.ganttChartView,g=b.ownerDocument,f;if(typeof a.assignmentsContentInput=== +c){f=g.createElement("input");a.assignmentsContentInput=f;f.type="text";f.addEventListener("focus",function(){z(a,e)},false);var h=function(){a.assignmentsContent=f.value;y(a,"assignmentsContent",true,true);if(!a.hasChildren&&a.hasFixedEffort){a.fixedEffort=da(a,e);a.fixedEffortAssignments=fa(a)}na(a);var b=null;DlhSoft.Controls.MultiSelectorComboBox&&(b=DlhSoft.Controls.MultiSelectorComboBox.get(f));if(b!=null&&b.availableChoices.length>0)var d=setInterval(function(){if(!b.isOpen&&g.activeElement!= +a.assignmentsContentInput){clearInterval(d);Y(a)}},100);else Y(a)};typeof f.changeEventListener!==c&&f.removeEventListener("change",f.changeEventListener,true);f.addEventListener("change",function(a){f.dontAutoFocus=true;h(a)},true);f.changeEventListener=h;var m=function(a){if(a.keyCode==13){a.preventDefault();a.stopPropagation();typeof f.dontAutoFocus!==c&&delete f.dontAutoFocus;h(a)}};typeof f.keyPressEventListener!==c&&f.removeEventListener("keypress",f.keyPressEventListener,true);f.addEventListener("keypress", +m,true);f.keyPressEventListener=m;f.addEventListener("focus",function(){f.style.backgroundColor="White"},false);f.addEventListener("blur",function(){f.style.backgroundColor="Transparent"},false)}else f=a.assignmentsContentInput;if(typeof a.assignmentsContent!==c)f.value=a.assignmentsContent;DlhSoft.Controls.MultiSelectorComboBox&&e.useResourceSelector&&f.addEventListener("focus",function(){if(!a.isWaitingToRefreshGridItem){var d=DlhSoft.Controls.MultiSelectorComboBox.get(f);if(!d||!d.isOpen&&d.availableChoices.length> +0){d=e.assignableResources;if(typeof d===c){d=Ia(b.items);e.assignableResources=d}var m=0,n=0;try{m=f.selectionStart;n=f.selectionEnd}catch(h){}d=DlhSoft.Controls.MultiSelectorComboBox.initialize(f,d,void 0,{inputStyle:null,autoAppendAvailableChoices:e.autoAppendAssignableResources,isDropDownButtonVisible:false,popupStyle:"margin-top: 1px; background-color: White; color: Black; border: 1px solid "+e.border+"; font-size: small; max-height: 188px; overflow-y: auto"},"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase."); +d.openDropDown();setTimeout(function(){try{f.selectionStart=m;f.selectionEnd=n}catch(a){}},100);navigator.userAgent.match(/(Android)|(IPad)|(IPhone)/i)==null?setTimeout(function(){try{f.focus()}catch(a){}},100):g.createEvent&&setTimeout(function(){var a=g.createEvent("MouseEvents");a.initEvent("blur",true,false);f.dispatchEvent(a)})}}},true);m="";if(a.hasChildren&&(typeof a.isSummaryEnabled===c||a.isSummaryEnabled))m="; font-weight: bold";f.setAttribute("style","background-color: Transparent; width: "+ +d+"px; border-width: 0px; padding: 0px"+m);return f},Pb=function(a,d,e){var b=function(a){return typeof a.start===c||typeof a.finish===c||a.finish.valueOf()==a.start.valueOf()||typeof a.isSummaryEnabled!==c&&!a.isSummaryEnabled&&typeof a.isBarVisible!==c&&!a.isBarVisible?a.ganttChartView.ownerDocument.createTextNode(""):V(a.ganttChartView.ownerDocument,a.ganttChartView.isItemCompleted(a))};return(typeof e===c||e)&&!a.isReadOnly&&!a.isGridReadOnly?function(e){return!d.isReadOnly&&(typeof e.isReadOnly=== +c||!e.isReadOnly)&&(!e.hasChildren||!(typeof e.isSummaryEnabled===c||e.isSummaryEnabled))&&!(typeof e.isSummaryEnabled!==c&&!e.isSummaryEnabled&&typeof e.isBarVisible!==c&&!e.isBarVisible)?Gc(e,a):b(e)}:b},Gc=function(a,d){var e=a.ganttChartView.ownerDocument,b;if(typeof a.completedInput===c){b=e.createElement("input");a.completedInput=b;b.type="checkbox";b.setAttribute("style","margin: 0px; margin-left: 2px; margin-right: 2px");b.addEventListener("focus",function(){z(a,d)},false)}else b=a.completedInput; +a.isSetAsCompleted||(!a.hasChildren||!(typeof a.isSummaryEnabled===c||a.isSummaryEnabled))&&a.completedFinish>=a.finish&&a.finish>a.start&&(typeof a.isMilestone===c||!a.isMilestone)?b.setAttribute("checked",true):b.removeAttribute("checked");a.hasChildren&&(typeof a.isSummaryEnabled===c||a.isSummaryEnabled)&&b.setAttribute("style","visibility: hidden");var g=function(){if(b.checked){if(a.completedFinish a.start){a.completedFinish=a.start;y(a,"completedFinish",true,true)}if(a.isMilestone||a.finish.valueOf()<=a.start.valueOf())a.isSetAsCompleted=false}Y(a)};typeof b.changeEventListener!==c&&b.removeEventListener("change",b.changeEventListener,true);b.addEventListener("change",g,true);b.changeEventListener=g;e=function(a){if(a.keyCode==13){a.preventDefault();a.stopPropagation();g(a)}};typeof b.keyPressEventListener!==c&&b.removeEventListener("keypress", +b.keyPressEventListener,true);b.addEventListener("keypress",e,true);b.keyPressEventListener=e;return b},gb=function(a){for(var d=0,e=0;e =4?2:d.width/2;g.setAttribute("style","padding-left: "+f+"px; padding-right: "+f+"px; overflow-x: hidden; -wekbit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing: border-box; width: "+d.width+"px");f=a.createElement("div");typeof d.headerClass!==c&&f.setAttribute("class",d.headerClass);typeof d.headerStyle!==c&&f.setAttribute("style",d.headerStyle);f.appendChild(Q(a,d.header));g.appendChild(f);b.appendChild(g);if(d.width>= +1&&(typeof e.allowUserToResizeColumns===c||e.allowUserToResizeColumns)&&(typeof d.allowUserToResize===c||d.allowUserToResize)){b.isGripperVisible=false;var h=d.ganttChartView,m=function(a){b.isGripperVisible=a;b.style.cursor=a?"e-resize":"default";b.style.borderRight=a?"solid 1px "+e.border:e.verticalGridLines?"solid 1px "+e.verticalGridLines:"";g.style.width=d.width-(b.style.borderRight?1:0)+"px"};e.verticalGridLines&&m();var j=e.splitterWidth;b.addEventListener("mouseover",function(a){if(!DlhSoft.Controls.GanttChartView.isGripperDragging&& +!(b.isGripperDragging||typeof a.offsetX===c&&a.currentTarget!=b))m((typeof a.offsetX!==c?a.offsetX:a.layerX-a.currentTarget.offsetLeft)>=d.width-j)},true);b.addEventListener("mousemove",function(a){if(!DlhSoft.Controls.GanttChartView.isGripperDragging&&!(b.isGripperDragging||typeof a.offsetX===c&&a.currentTarget!=b))m((typeof a.offsetX!==c?a.offsetX:a.layerX-a.currentTarget.offsetLeft)>=d.width-j)},true);g.addEventListener("mouseover",function(a){!DlhSoft.Controls.GanttChartView.isGripperDragging&& +(!b.isGripperDragging&&!(typeof a.offsetX!==c||a.currentTarget!=g))&&m(a.layerX-a.currentTarget.offsetLeft>=d.width-j)},false);g.addEventListener("mousemove",function(a){!DlhSoft.Controls.GanttChartView.isGripperDragging&&(!b.isGripperDragging&&!(typeof a.offsetX!==c||a.currentTarget!=g))&&m(a.layerX-a.currentTarget.offsetLeft>=d.width-j)},false);b.addEventListener("mousedown",function(a){if(!(a.button!=0||!b.isGripperVisible||DlhSoft.Controls.GanttChartView.isGripperDragging)){DlhSoft.Controls.GanttChartView.isGripperDragging= +true;b.isGripperDragging=true;b.initialGripperDraggingX=a.clientX;b.initialColumnWidth=d.width}},true);a.addEventListener("mousemove",function(a){if(b.isGripperDragging){d.width=Math.max(d.minWidth,b.initialColumnWidth+(a.clientX-b.initialGripperDraggingX));if(typeof d.maxWidth!==c&&d.width>d.maxWidth)d.width=d.maxWidth;g.style.width=d.width-1+"px";typeof e.columnWidthChangeHandler!==c&&setTimeout(function(){e.columnWidthChangeHandler(d,d.width)},0);if(!h.isWaitingToRefreshColumns){h.isWaitingToRefreshColumns= +true;setTimeout(function(){var a=gb(e.columns);h.gridHeader.style.width=a+"px";h.gridContent.style.width=a+"px";delete h.isWaitingToRefreshColumns;h.refreshGridItems()},0)}}},true);a.addEventListener("mouseup",function(){if(b.isGripperDragging){delete b.isGripperDragging;delete b.initialGripperDraggingX;delete b.initialColumnWidth;m(false);delete DlhSoft.Controls.GanttChartView.isGripperDragging}},true);b.addEventListener("mouseout",function(){b.isGripperDragging||m(false)},false)}return b},ca=function(a, +d){for(var e=-1,b=null,g=null,f=[],h=0;h j){m.indentation=j;y(m,"indentation",false,true)}b.hasChildren=m.indentation>b.indentation;if(b.hasChildren&& +typeof b.isMilestone!==c&&b.isMilestone){b.isMilestone=false;y(b,"isMilestone",false,true)}}}m.isVisible=e<0||m.indentation<=e;if(typeof m.scheduleChartItem===c){if(m.isVisible&&!m.isExpanded)e=m.indentation;m.isExpanded&&m.indentation==e&&(e=-1);b=m}}if(b!=null)b.hasChildren=false;d.selectedItem=g;d.selectedItems=f},Ha=function(a,d,e){e.isTimingInformationInitialized=false;e.isBasicTimingInformationInitialized=false;var b=X(d.currentTime),g=[],f,h,m;for(h=0;h 0&&(j=g[g.length-1]);j!=null&&f.indentation<=j.indentation;){g.pop();j=g[g.length-1]}f.parent=j;f.children=[];j!=null&&j.children.push(f);if(!f.hasChildren||!(typeof f.isSummaryEnabled===c||f.isSummaryEnabled)){m=f.start;var l=f.finish,n=f.completedFinish;if(typeof f.start===c){f.start=b;f.preferredStart=f.start}if(typeof f.finish===c)f.finish=typeof f.isMilestone===c||!f.isMilestone?$(b):f.start;if(typeof f.isSetAsCompleted===c)f.isSetAsCompleted=typeof f.completedFinish!==c&&f.completedFinish.valueOf()== +f.finish.valueOf();if(typeof f.completedFinish===c)f.completedFinish=f.start;if(typeof f.isRelativeToTimezone===c||f.isRelativeToTimezone){f.start=new Date(f.start.valueOf()-f.start.getTimezoneOffset()*6E4);f.ftart=f.start;f.finish=new Date(f.finish.valueOf()-f.finish.getTimezoneOffset()*6E4);f.completedFinish=typeof f.completedFinish==="number"?S(f.start,f.completedFinish*O(f.start,f.finish,d,D(f)),d,D(f)):new Date(f.completedFinish.valueOf()-f.completedFinish.getTimezoneOffset()*6E4);if(typeof f.baselineStart!== +c)f.baselineStart=new Date(f.baselineStart.valueOf()-f.baselineStart.getTimezoneOffset()*6E4);if(typeof f.baselineFinish!==c)f.baselineFinish=new Date(f.baselineFinish.valueOf()-f.baselineFinish.getTimezoneOffset()*6E4);if(typeof f.minStart!==c)f.minStart=new Date(f.minStart.valueOf()-f.minStart.getTimezoneOffset()*6E4);if(typeof f.maxStart!==c)f.maxStart=new Date(f.maxStart.valueOf()-f.maxStart.getTimezoneOffset()*6E4);if(typeof f.minFinish!==c)f.minFinish=new Date(f.minFinish.valueOf()-f.minFinish.getTimezoneOffset()* +6E4);if(typeof f.maxFinish!==c)f.maxFinish=new Date(f.maxFinish.valueOf()-f.maxFinish.getTimezoneOffset()*6E4);f.isRelativeToTimezone=false}else if(typeof f.completedFinish==="number")f.completedFinish=S(f.start,f.completedFinish*O(f.start,f.finish,d,D(f)),d,D(f));if(typeof f.minStart!==c&&f.start f.maxStart)f.start=f.maxStart;if(typeof f.maxFinish!==c&&f.finish>f.maxFinish)f.finish=f.maxFinish;else if(typeof f.minFinish!==c&&f.finish< +f.minFinish)f.finish=f.minFinish;if(f.finish f.finish)f.completedFinish=f.finish;if(typeof f.loadChartItem===c)f.start=R(f.start,d,true,typeof f.isMilestone!==c&&f.isMilestone,D(f));typeof f.dependsOf!==c&&delete f.dependsOf;f.preferredStart=f.start;if(typeof f.loadChartItem===c){f.finish=R(f.finish,d,typeof f.isMilestone!==c&&f.isMilestone,true,D(f));f.completedFinish=R(f.completedFinish,d,typeof f.isMilestone!== +c&&f.isMilestone,true,D(f))}if(f.finish f.finish)f.completedFinish=f.finish;if(typeof f.isSetAsCompleted!==c&&(!f.isMilestone||f.completedFinish.valueOf() f.start){l.start=f.start;y(l,"start",false,true)}if(typeof l.finish===c||l.finish j.indentation)&&g.push(f)}e.isBasicTimingInformationInitialized=true;for(h=a.length;h-- >0;){f=a[h];f.hasChildren&&(typeof f.isSummaryEnabled===c||f.isSummaryEnabled)&&Ya(f)}if(d.areTaskDependencyConstraintsEnabled)for(h=0;h 0)&&Ka(f,a,d,e)}for(h=0;h m.start)a.start=m.start;if(typeof a.finish=== +c||a.finish d.visibleWeekFinish?c+(d.visibleWeekFinish-d.visibleWeekStart+1)*e:c+(b-d.visibleWeekStart)*e,e=ja(a);b>=d.visibleWeekStart&& +b<=d.visibleWeekFinish&&(c=e<=d.visibleDayStart?c+0:e>=d.visibleDayFinish?c+(d.visibleDayFinish-d.visibleDayStart)/36E5*d.hourWidth:c+(e-d.visibleDayStart)/36E5*d.hourWidth);return c},Ca=function(a,d){for(var e=d.timelineStart.valueOf(),b=Za(d),c=Za(d)*(d.visibleWeekFinish-d.visibleWeekStart+1);a>c;){e=e+6048E5;a=a-c}for(e=e+Math.max(0,d.visibleWeekStart-d.weekStartDay)*864E5;a>b;){e=e+864E5;a=a-b}e=e+d.visibleDayStart;e=e+a/d.hourWidth*36E5;return new Date(e)},Eb=function(a){switch(a.theme){default:return[{scaleType:"NonworkingTime", +isHeaderVisible:false,isHighlightingVisible:true,highlightingStyle:"stroke-width: 0; fill: #f4f4f4; fill-opacity: 0.65"},{scaleType:"Weeks",headerTextFormat:"Date",headerStyle:"padding: 2.25px"},{scaleType:"Days",headerTextFormat:"DayOfWeekAbbreviation",headerStyle:"padding: 2.25px"},{scaleType:"CurrentTime",isHeaderVisible:false,isSeparatorVisible:true,separatorStyle:"stroke: #8bbf8a; stroke-width: 0.5px"}];case "ModernBordered":return[{scaleType:"NonworkingTime",isHeaderVisible:false,isHighlightingVisible:true, +highlightingStyle:"stroke-width: 0; fill: #f4f4f4; fill-opacity: 0.65"},{scaleType:"Weeks",headerTextFormat:"Date",headerStyle:"padding: 2.25px; border-right: solid 1px White; border-bottom: solid 1px White",isSeparatorVisible:true,separatorStyle:"stroke: #c8bfe7; stroke-width: 0.5px"},{scaleType:"Days",headerTextFormat:"DayOfWeekAbbreviation",headerStyle:"padding: 2.25px; border-right: solid 1px White"},{scaleType:"CurrentTime",isHeaderVisible:false,isSeparatorVisible:true,separatorStyle:"stroke: #8bbf8a; stroke-width: 1px"}]; +case "Aero":return[{scaleType:"NonworkingTime",isHeaderVisible:false,isHighlightingVisible:true,highlightingStyle:"stroke-width: 0; fill: #f4f4f4; fill-opacity: 0.65"},{scaleType:"Weeks",headerTextFormat:"Date",headerStyle:"padding: 2.25px; border-right: solid 1px #c8bfe7; border-bottom: solid 1px #c8bfe7",isSeparatorVisible:true,separatorStyle:"stroke: #c8bfe7; stroke-width: 0.5px"},{scaleType:"Days",headerTextFormat:"DayOfWeekAbbreviation",headerStyle:"padding: 2.25px; border-right: solid 1px #c8bfe7"}, +{scaleType:"CurrentTime",isHeaderVisible:false,isSeparatorVisible:true,separatorStyle:"stroke: Black; stroke-width: 1px"}]}},oa=function(a,d){return new Date(Math.floor((a-2592E5).valueOf()/d.updateScale)*d.updateScale+2592E5)},hb=function(a,d,e,b,g){typeof g===c&&(g=false);var f=a.ownerDocument,h=0,m,j;for(m=0;m 0&&(l=b.headerHeight/h);for(m=0;m w&&(typeof j.isHeaderVisible===c||j.isHeaderVisible))J=w;J b.timelineFinish)p=b.timelineFinish;p 0?864E5:0));g=Jc(b),b 0?864E5: +0));g=Kc(b),b d){a=$(a);return new Date(X(a).valueOf()+ +e)}return new Date(a.valueOf())},$=function(a){return new Date(a.valueOf()+864E5)},La=function(a){return new Date(a.valueOf()-864E5)},xa=function(a){return new Date(a.valueOf()+6048E5)},Kc=function(a){var d=a.getTimezoneOffset(),a=new Date(a.valueOf()+(d>0?864E5:0)),e=a.getMonth()+1;if(e>=12){e=0;a.setFullYear(a.getFullYear()+1)}a.setMonth(e,1);e=a.getTimezoneOffset();return new Date(a.valueOf()-(e-d)*6E4-(e>0?864E5:0))},Jc=function(a){var d=a.getTimezoneOffset(),a=new Date(a.valueOf()+(d>0?864E5: +0));a.setFullYear(a.getFullYear()+1);a.setMonth(0,1);var e=a.getTimezoneOffset();return new Date(a.valueOf()-(e-d)*6E4-(e>0?864E5:0))},Tb=function(a,d){if(typeof d===c)return false;for(var e=a.valueOf(),b=0;b 0?d[0].toUpperCase():"";case "Day":a=new Date(a.valueOf()+a.getTimezoneOffset()*6E4);return(a.getDate()< +10?"0":"")+a.getDate();case "Month":return e.months[(new Date(a.valueOf()+(a.getTimezoneOffset()+720)*6E4)).getMonth()];case "MonthAbbreviation":d=e.months[(new Date(a.valueOf()+(a.getTimezoneOffset()+720)*6E4)).getMonth()];return d.length<=0?"":d[0].toUpperCase()+(d.length>1?d.substr(1,Math.min(3,d.length)-1):"");case "Year":return(new Date(a.valueOf()+(a.getTimezoneOffset()+720)*6E4)).getFullYear();case "MonthYear":return e.months[(new Date(a.valueOf()+(a.getTimezoneOffset()+720)*6E4)).getMonth()]+ +" "+(new Date(a.valueOf()+(a.getTimezoneOffset()+720)*6E4)).getFullYear();default:return d.headerText?d.headerText:a.toString()}},Ac=function(a,d,e,b,g,f,h){for(var m=0,j=0;j g){e=e+d.itemHeight;g=b++}else{e=Math.max(e,h.itemTop+d.itemHeight);g=h.displayRowIndex}}return e},za=function(a,d,e){if(a.isPart)return za(a.ganttChartItem,d,e);var b;if(typeof a.displayRowIndex!==c){b=a.displayRowIndex*e.itemHeight;return a.itemTop=b}for(var g=b=0;g b.count){m=document.createElementNS("http://www.w3.org/2000/svg","rect");m.setAttribute("x",0);m.setAttribute("y",f*e.itemHeight);m.setAttribute("width",d.clientWidth); +m.setAttribute("height",e.itemHeight);typeof e.alternativeChartItemClass!==c&&m.setAttribute("class",e.alternativeChartItemClass);typeof e.alternativeChartItemStyle!==c&&m.setAttribute("style",e.alternativeChartItemStyle);m.index=f;b.appendChild(m)}}b.count=f}else{j.setAttribute("class","");j.setAttribute("style","")}f++}}for(g=b.childNodes.length;g-- >0;){a=b.childNodes[g];a.index>b.count&&b.removeChild(a)}}},Ub=function(a,d,e,b,g,f){var h=a.ganttChartView.ownerDocument,m=h.createElement("div"); +typeof f.itemClass!==c&&m.setAttribute("class",f.itemClass);typeof f.itemStyle!==c&&m.setAttribute("style",f.itemStyle);var j=h.createElement("div");a.alternativeContentContainer=j;var l=h.createElement("div");try{l.addEventListener("mousedown",function(b){b.target!=a.selectionInput&&z(a,f)},false);l.addEventListener("mouseup",function(b){b.target!=a.selectionInput&&z(a,f)},false)}catch(n){}if(a.isSelected){typeof f.selectedItemClass!==c&&l.setAttribute("class",f.selectedItemClass);typeof f.selectedItemStyle!== +c&&l.setAttribute("style",f.selectedItemStyle)}var w=h.createElement("div");typeof a["class"]!==c&&w.setAttribute("class",a["class"]);typeof a.style!==c&&w.setAttribute("style",a.style);var u=h.createElement("div");if(a.hasChildren&&(typeof a.isSummaryEnabled===c||a.isSummaryEnabled)){typeof f.summaryItemClass!==c&&u.setAttribute("class",f.summaryItemClass);typeof f.summaryItemStyle!==c&&u.setAttribute("style",f.summaryItemStyle)}else if(a.isMilestone){typeof f.milestoneItemClass!==c&&u.setAttribute("class", +f.milestoneItemClass);typeof f.milestoneItemStyle!==c&&u.setAttribute("style",f.milestoneItemStyle)}else{typeof f.standardItemClass!==c&&u.setAttribute("class",f.standardItemClass);typeof f.standardItemStyle!==c&&u.setAttribute("style",f.standardItemStyle)}h=h.createElement("div");a.gridItem=h;a.gridItemContent=u;a.gridItemSelectionContainer=l;var t=f.itemHeight;if(!a.isVisible||typeof a.isHidden!==c&&a.isHidden)t=0;h.setAttribute("style","overflow: hidden; height: "+t+"px");Aa(h,a,d,e,b,g,f);u.appendChild(h); +w.appendChild(u);l.appendChild(w);j.appendChild(l);m.appendChild(j);a.gridItemContainer=m;(typeof f.isGridRowClickTimeScrollingEnabled===c||f.isGridRowClickTimeScrollingEnabled)&&m.addEventListener("mouseup",function(){var d;if(typeof a.ganttChartItems===c)d=a.start;else{d=null;for(var e=0;e =b.container.clientWidth/2.5&&(e=d);b.container.scrollLeft= +Math.max(0,e)},true);return m},Aa=function(a,d,e,b,g,f,h){var m=d.ganttChartView.ownerDocument;if(!h.isVirtualizing||typeof d.isVirtuallyVisible!==c&&d.isVirtuallyVisible){var j=function(){if(typeof d.gridItemSelectionContainer!==c){var j=d.gridItemSelectionContainer;typeof h.selectedItemClass!==c&&j.setAttribute("class",d.isSelected?h.selectedItemClass:null);typeof h.selectedItemStyle!==c&&j.setAttribute("style",d.isSelected?h.selectedItemStyle:null)}if(typeof d.gridItemContent!==c){j=d.gridItemContent; +j.setAttribute("class","");j.setAttribute("style","");if(d.hasChildren&&(typeof d.isSummaryEnabled===c||d.isSummaryEnabled)){typeof h.summaryItemClass!==c&&j.setAttribute("class",h.summaryItemClass);typeof h.summaryItemStyle!==c&&j.setAttribute("style",h.summaryItemStyle)}else if(d.isMilestone){typeof h.milestoneItemClass!==c&&j.setAttribute("class",h.milestoneItemClass);typeof h.milestoneItemStyle!==c&&j.setAttribute("style",h.milestoneItemStyle)}else{typeof h.standardItemClass!==c&&j.setAttribute("class", +h.standardItemClass);typeof h.standardItemStyle!==c&&j.setAttribute("style",h.standardItemStyle)}}var j=[],n=null;try{n=m.activeElement}catch(w){}for(;n!=null&&n!=d.gridItem;){j.push(n);n=n.parentNode}for(var u=-1,n=a.childNodes.length;n-- >0;)if(j.indexOf(a.childNodes[n])>=0){u=n;break}for(n=a.childNodes.length;n-- >0;)a.removeChild(a.childNodes[n]);for(n=0;n =0&&setTimeout(function(){try{for(var b=a.childNodes[u];b.nodeName!= +"input"&&b.nodeName!="textarea"&&b.nodeName!="label"&&b.nodeName!="select"&&b.nodeName!="button"&&b.childNodes.length>0;)b=b.childNodes[0];b&&b.dontAutoFocus?delete b.dontAutoFocus:setTimeout(function(){try{b.focus()}catch(a){}},0)}catch(d){}},0)};if(d.wasGridItemContentLoaded)setTimeout(j,0);else{j();d.wasGridItemContentLoaded=true}}},Na=function(a){if(typeof a.isWaitingToRefreshGridItem===c){a.isWaitingToRefreshGridItem=true;setTimeout(function(){typeof a.gridItem!==c&&Aa(a.gridItem,a,a.ganttChartView.items, +a.ganttChartView.settings.columns,a.ganttChartView.chartContent,a.ganttChartView.settings.toggleButtonAreaWidth,a.ganttChartView.settings);delete a.isWaitingToRefreshGridItem},0)}},Mc=function(a,d,e,b,g,f,h){var m=d.ganttChartView.ownerDocument;(!h.isVirtualizing||typeof d.isVirtuallyVisible!==c&&d.isVirtuallyVisible)&&setTimeout(function(){if(typeof d.gridItemSelectionContainer!==c){var j=d.gridItemSelectionContainer;typeof h.selectedItemClass!==c&&j.setAttribute("class",d.isSelected?h.selectedItemClass: +null);typeof h.selectedItemStyle!==c&&j.setAttribute("style",d.isSelected?h.selectedItemStyle:null)}var j=[],l=null;try{l=m.activeElement}catch(n){}for(;l!=null&&l!=d.gridItem;){j.push(l);l=l.parentNode}for(var w=-1,l=a.childNodes.length;l-- >0;)if(a.childNodes[l].isSelection&&j.indexOf(a.childNodes[l])>=0){w=l;break}for(l=a.childNodes.length;l-- >0;)a.childNodes[l].isSelection&&a.removeChild(a.childNodes[l]);for(l=0;l =0&&setTimeout(function(){try{for(var b=a.childNodes[w];b.nodeName!="input"&&b.nodeName!="textarea"&&b.nodeName!="label"&&b.nodeName!="select"&&b.nodeName!="button"&&b.childNodes.length>0;)b=b.childNodes[0];b&&b.dontAutoFocus?delete b.dontAutoFocus:setTimeout(function(){try{b.focus()}catch(a){}},0)}catch(d){}},0)},0)},Rb=function(a){typeof a.gridItem!==c&&Mc(a.gridItem,a,a.ganttChartView.items,a.ganttChartView.settings.columns,a.ganttChartView.chartContent, +a.ganttChartView.settings.toggleButtonAreaWidth,a.ganttChartView.settings)},Vb=function(a,d,e,b,g,f){var h=a.ganttChartView.ownerDocument,m=h.createElement("div"),j=0;e.isTreeView==true&&(j=f.indentationLevelWidth*a.indentation);m.setAttribute("style","overflow: hidden; vertical-align: middle; display: table-cell; -webkit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing: border-box; margin: 0px; padding: 0px; width: "+e.width+"px; height: "+f.itemHeight+"px; padding-left: "+j+"px"); +var l=h.createElement("div");typeof e.cellClass!==c?l.setAttribute("class",e.cellClass):typeof f.cellClass!==c&&l.setAttribute("class",f.cellClass);typeof e.cellStyle!==c?l.setAttribute("style",e.cellStyle):typeof f.cellStyle!==c&&l.setAttribute("style",f.cellStyle);var n=h.createElement("div");n.setAttribute("style","white-space: nowrap; overflow: hidden; margin: 0px; padding: 0px; width: "+(e.width-j-16)+"px");if(e.isTreeView==true){j=h.createElement("div");j.setAttribute("style","display: inline-block; width: "+ +g+"px");if(a.hasChildren){g=h.createElement("div");g.setAttribute("style","cursor: default; padding-left: 1px; font-size: 12px; display: inline-block");h=f.collapsedToggleButtonTemplate;if(a.isExpanded)h=f.expandedToggleButtonTemplate;h=h();g.appendChild(h);Wb(g,a,d,h,b,null,null,f);j.appendChild(g)}n.appendChild(j)}a=e.cellTemplate(a);n.appendChild(a);l.appendChild(n);m.appendChild(l);m.isSelection=e.isSelection;return m},Cb=function(a,d){return function(){var e=a.ownerDocument.createElementNS("http://www.w3.org/2000/svg", +"polygon");e.setAttribute("points","3.5,2.5 3.5,11.5 10.5,6.5");return s(e,d)}},Db=function(a,d){return function(){var e=a.ownerDocument.createElementNS("http://www.w3.org/2000/svg","polygon");e.setAttribute("points","2.5,3.5 11.5,3.5 6.5,10.5");return s(e,d)}},Wb=function(a,d,e,b,g,f,h,m){if(typeof f===c||f==null)f=b.querySelector("#PART_Button");f!=null&&Xb(f,f,m);if(typeof h===c||h==null)h=b.querySelector("#PART_Border");h!=null&&Xb(h,f,m);e={toggleButton:a,item:d,items:e,content:b,chartContent:g, +settings:m};if(f!=null){f.tag=e;(typeof m.isExport===c||!m.isExport)&&f.addEventListener("mouseup",ob,true)}if(h!=null){h.tag=e;(typeof m.isExport===c||!m.isExport)&&h.addEventListener("mouseup",ob,true)}a.tag=e;f==null&&(h==null&&(typeof m.isExport===c||!m.isExport))&&a.addEventListener("mouseup",ob,true);b.addEventListener("keypress",function(a){if(a.keyCode==32){a.preventDefault();a.stopPropagation();ga(d,!d.isExpanded,true)}},true);d.toggleButton=a},Xb=function(a,d,e){if(!(typeof e.isExport!== +c&&e.isExport)){a.addEventListener("mouseover",function(){typeof e.toggleButtonHoveringClass!==c&&d.setAttribute("class",e.toggleButtonHoveringClass);typeof e.toggleButtonHoveringStyle!==c&&d.setAttribute("style",e.toggleButtonHoveringStyle)},true);a.addEventListener("mouseout",function(){d.setAttribute("class",e.toggleButtonClass);d.setAttribute("style",e.toggleButtonStyle)},true)}},ob=function(a){a.stopPropagation();a=a.target.tag.item;ga(a,!a.isExpanded,true)},ga=function(a,d,e,b){if(a.isExpanded!= +d){a.isExpanded=d;(typeof b===c||b)&&y(a,"isExpanded",e,true);Yb(a)}},Yb=function(a,d){if(typeof a.toggleButton===c)(typeof d===c||d)&&setTimeout(function(){Yb(a,false)},0);else{var e=a.toggleButton,b=e.tag,g=b.settings,f=g.expandedToggleButtonTemplate,h=g.collapsedToggleButtonTemplate;a.isExpanded&&(h=f);var f=h(),h=f.querySelector("#PART_Button"),m=f.querySelector("#PART_Border");e.replaceChild(f,b.content);b.content=f;var j=b.items,b=b.chartContent;Wb(e,a,j,f,b,h,m,g);a.isVisible&&!(typeof a.isHidden!== +c&&a.isHidden)&&Nc(j,a,b,g);na(a);Ma(j,b,g);e=a.scheduleChartView;if(typeof e!==c)for(g=a.scheduleChartIndex;g 0&&u.indexOf(w)<0){u.push(w);for(t=0;t 0)for(f=0;f 0){b=true;for(h=0;h 0;)a.removeChild(a.childNodes[b]);if(!(e.isVirtualizing&&(typeof d.isVirtuallyVisible===c||!d.isVirtuallyVisible)||typeof d.isBarVisible!==c&&!d.isBarVisible)){b=e.standardTaskTemplate;if(typeof d.standardTaskTemplate!==c)b=d.standardTaskTemplate;if(d.hasChildren&&(typeof d.isSummaryEnabled===c||d.isSummaryEnabled)){b=e.summaryTaskTemplate;if(typeof d.summaryTaskTemplate!==c)b=d.summaryTaskTemplate}else if(d.isMilestone){b= +e.milestoneTaskTemplate;if(typeof d.milestoneTaskTemplate!==c)b=d.milestoneTaskTemplate}if(typeof d.taskTemplate!==c)b=d.taskTemplate;if(typeof e.internalPreTaskTemplate!==c){var g=e.internalPreTaskTemplate(d);g!=null&&a.appendChild(g)}b=b(d);b.addEventListener("contextmenu",function(a){typeof e.itemContextMenuHandler!==c?e.itemContextMenuHandler(a,d):a.preventDefault()},false);a.appendChild(b);if(typeof e.internalExtraTaskTemplate!==c){g=e.internalExtraTaskTemplate(d);g!=null&&a.appendChild(g)}if(typeof e.extraTaskTemplate!== +c){g=e.extraTaskTemplate(d);g!=null&&a.appendChild(g)}if(e.areTaskAssignmentsVisible){g=e.assignmentsTemplate(d);b.appendChild(g)}if(e.isTaskToolTipVisible){g=e.itemTemplate;if(typeof d.template!==c)g=d.template;b.appendChild(g(d))}if(e.areTaskDependenciesVisible&&typeof d.predecessors!==c)for(b=0;b =0&&Y(d[e]);Y(a);e=a.index+1;e 0&&b[a-1].isPart;)a--;for(var f=0;f =0){d.isPart=true;d.ganttChartItem=b[f];break}var h=a 0?b[a-1]:null;h=h!=null?h.indentation+1:0;if(d.indentation>h)d.indentation=h}else if(typeof d.indentation===c||d.indentation h.indentation)d.indentation= +h.indentation;M([d],g);b.splice(a,0,d);ca(b,e);if(typeof d.parts!==c){if(typeof d.isGroup===c){d.isGroup=true;d.isSummaryEnabled=false}M(d.parts,g);if(d.isGroup||typeof d.isBarVisible===c)d.isBarVisible=false;for(f=0;f = +0||b.splice(b.length,0,m)}}Ha(b,g,e);var j;if(g.isGridVisible&&!d.isPart&&typeof d.displayRowIndex===c){f=null;if(a 0){for(f=e[g-1];f.parent!=null;)f=f.parent;h=f.isExpanded;a.hasChildren&&ga(f,a.isExpanded,false,true);f.indentation>=a.indentation&&(f=null)}else e[0].isExpanded||ga(e[0],true,false,true);var m=g+1 a.indentation)&&ga(m,true,false,true);var j=m!=null?m.indentation:null,l,n,w;for(n=0;n 0;)if(l.predecessors[w].item==a){l.predecessors.splice(w,1);y(l,"predecessors",false,true);ma(l);qa(l)}}var u=a.itemTop;e.splice(g,1);ca(e,d);Ha(e,b,d);b.isGridVisible&&typeof a.displayRowIndex===c&&typeof a.gridItemContainer!==c&&d.gridContent.removeChild(a.gridItemContainer);n=d.chartContent.chartArea; +typeof a.chartItem!==c&&n.removeChild(a.chartItem);m=g =e.length&&(g=e.length-1);if(g>=0){for(n=0;n 0){g.appendChild(b.createTextNode("\n")); +for(var e="",f=0;f 0&&(e=e+", ");e=e+h.item.content;h.dependencyType&&(e=e+(" ("+ac(h.dependencyType)+")"))}}g.appendChild(b.createTextNode("Predecessors: "+e))}}else if(!isNaN(d.units)){g.appendChild(b.createTextNode("\n"));g.appendChild(b.createTextNode("Allocation: "+Math.round(d.units*1E4)/100+"%"))}return g}},Kb=function(a){return function(d){var e=d.ganttChartView,b=typeof a!==c?a:e.settings,e=e.ownerDocument,g=e.createElementNS("http://www.w3.org/2000/svg", +"text"),f=H(d.finish,b);if(d.isMilestone||d.hasChildren&&(typeof d.isSummaryEnabled===c||d.isSummaryEnabled))f=f+b.barHeight/2;g.setAttribute("x",f+7);g.setAttribute("y",b.barMargin+b.barHeight-1);d=b.target!="Phone"?d.assignmentsContent:d.content;typeof d===c&&(d="");g.appendChild(e.createTextNode(d));typeof b.assignmentsClass!==c?g.setAttribute("class",b.assignmentsClass):typeof b.assignmentsStyle!==c&&g.setAttribute("style",b.assignmentsStyle);return g}},pb=function(a){var d=a.ganttChartView.ownerDocument; +if(typeof a.chartItemArea===c)a.chartItemArea=d.createElementNS("http://www.w3.org/2000/svg","g");for(d=a.chartItemArea.childNodes.length;d-- >0;)a.chartItemArea.removeChild(a.chartItemArea.childNodes[d]);return a.chartItemArea},Gb=function(a,d,e){return function(b){var g=typeof d!==c?d:b.ganttChartView,f=typeof e!==c?e:g.settings,h=typeof a!==c?a:g.items,m=g.ownerDocument,j=pb(b);if(f.isBaselineVisible&&typeof b.baselineStart!==c&&typeof b.baselineFinish!==c){var l=H(b.baselineStart,f),n=Math.max(H(b.baselineFinish, +f),l+4),w=m.createElementNS("http://www.w3.org/2000/svg","rect");w.setAttribute("x",l);w.setAttribute("y",f.barMargin/2);w.setAttribute("width",Math.max(0,n-l-1));w.setAttribute("height",f.barHeight);w.setAttribute("rx",f.barCornerRadius);w.setAttribute("ry",f.barCornerRadius);l=f.baselineBarClass;if(typeof b.baselineBarClass!==c)l=b.baselineBarClass;if(typeof l!==c)w.setAttribute("class",l);else{l=f.baselineBarStyle;if(typeof b.baselineBarStyle!==c)l=b.baselineBarStyle;typeof l!==c&&w.setAttribute("style", +l)}j.appendChild(w)}var w=H(b.start,f),l=Math.max(H(b.finish,f),w+4),n=H(b.completedFinish,f),u=m.createElementNS("http://www.w3.org/2000/svg","rect");u.setAttribute("x",w);u.setAttribute("y",f.barMargin);u.setAttribute("width",Math.max(0,l-w-1));u.setAttribute("height",f.barHeight);u.setAttribute("rx",f.barCornerRadius);u.setAttribute("ry",f.barCornerRadius);var t=f.standardBarClass;if(typeof b.standardBarClass!==c)t=b.standardBarClass;if(typeof b.barClass!==c)t=b.barClass;if(typeof t!==c)u.setAttribute("class", +t);else{t=f.standardBarStyle;if(typeof b.standardBarStyle!==c)t=b.standardBarStyle;if(typeof b.barStyle!==c)t=b.barStyle;typeof t!==c&&u.setAttribute("style",t)}j.appendChild(u);if(f.isTaskCompletedEffortVisible){u=m.createElementNS("http://www.w3.org/2000/svg","rect");u.setAttribute("x",w);u.setAttribute("y",f.barMargin+f.completedBarMargin);u.setAttribute("width",Math.max(0,n-w-1));u.setAttribute("height",f.completedBarHeight);u.setAttribute("rx",f.completedBarCornerRadius);u.setAttribute("ry", +f.completedBarCornerRadius);t=f.standardCompletedBarClass;if(typeof b.standardCompletedBarClass!==c)t=b.standardCompletedBarClass;if(typeof b.completedBarClass!==c)t=b.completedBarClass;if(typeof t!==c)u.setAttribute("class",t);else{t=f.standardCompletedBarStyle;if(typeof b.standardCompletedBarStyle!==c)t=b.standardCompletedBarStyle;if(typeof b.completedBarStyle!==c)t=b.completedBarStyle;typeof t!==c&&u.setAttribute("style",t)}j.appendChild(u)}if(!f.isReadOnly&&!f.isChartReadOnly&&(typeof b.isReadOnly=== +c||!b.isReadOnly)&&(typeof b.isBarReadOnly===c||!b.isBarReadOnly)){u=m.createElementNS("http://www.w3.org/2000/svg","rect");u.setAttribute("x",w);u.setAttribute("y",f.barMargin);u.setAttribute("width",Math.max(0,l-w-1));u.setAttribute("height",f.barHeight);u.setAttribute("style","fill: White; fill-opacity: 0; cursor: pointer");f.isTaskStartReadOnly||j.appendChild(u);t=m.createElementNS("http://www.w3.org/2000/svg","rect");t.setAttribute("x",w-4);t.setAttribute("y",f.barMargin);t.setAttribute("width", +4);t.setAttribute("height",f.barHeight);t.setAttribute("style","fill: White; fill-opacity: 0; cursor: w-resize");f.isDraggingTaskStartEndsEnabled&&(!f.isTaskStartReadOnly&&f.interaction!="TouchEnabled")&&j.appendChild(t);var o=m.createElementNS("http://www.w3.org/2000/svg","rect");o.setAttribute("x",l-4);o.setAttribute("y",f.barMargin);o.setAttribute("width",8);o.setAttribute("height",f.barHeight);o.setAttribute("style","fill: White; fill-opacity: 0; cursor: e-resize");!f.isTaskEffortReadOnly&&f.interaction!= +"TouchEnabled"&&j.appendChild(o);var p=m.createElementNS("http://www.w3.org/2000/svg","rect");p.setAttribute("x",n-2);p.setAttribute("y",f.barMargin);p.setAttribute("width",6);p.setAttribute("height",f.barHeight);p.setAttribute("style","fill: White; fill-opacity: 0; cursor: ew-resize");if(!f.isTaskCompletionReadOnly&&f.isTaskCompletedEffortVisible&&f.interaction!="TouchEnabled"){j.appendChild(p);var k=m.createElementNS("http://www.w3.org/2000/svg","title"),F=typeof f.areToolTipsSimplified===c||!f.areToolTipsSimplified? +g.getItemCompletion(b):NaN;k.appendChild(Q(m,!isNaN(F)?Math.round(F*1E4)/100+"%":""));p.appendChild(k)}qb(u,t,o,p,b,w,l,n,h,g,f);if(f.areTaskDependenciesVisible&&!f.areTaskPredecessorsReadOnly&&!b.isPart){n=null;if(typeof f.allowCreatingStartDependencies===c||f.allowCreatingStartDependencies){n=m.createElementNS("http://www.w3.org/2000/svg","circle");n.setAttribute("cx",w);n.setAttribute("cy",f.barMargin+f.barHeight/2);n.setAttribute("r",f.barHeight/4);n.setAttribute("style","fill: White; fill-opacity: 0; cursor: pointer"); +j.appendChild(n)}m=m.createElementNS("http://www.w3.org/2000/svg","circle");m.setAttribute("cx",l-2);m.setAttribute("cy",f.barMargin+f.barHeight/2);m.setAttribute("r",f.barHeight/4);m.setAttribute("style","fill: White; fill-opacity: 0; cursor: pointer");j.appendChild(m);ab(m,n,j,b,f.barMargin+f.barHeight/2,l-2,w,h,g,f)}}return j}},Hb=function(a,d,e){return function(b){var g=typeof d!==c?d:b.ganttChartView,f=typeof e!==c?e:g.settings,h=typeof a!==c?a:g.items,m=g.ownerDocument,j=pb(b),l=H(b.start,f), +n=H(b.finish,f),w=f.barHeight*2.15/3,u=m.createElementNS("http://www.w3.org/2000/svg","rect");u.setAttribute("x",l);u.setAttribute("y",f.barMargin);u.setAttribute("width",Math.max(0,n-l-1));u.setAttribute("height",w);var t=f.summaryBarClass;if(typeof b.summaryBarClass!==c)t=b.summaryBarClass;if(typeof b.barClass!==c)t=b.barClass;if(typeof t!==c)u.setAttribute("class",t);else{var o=f.summaryBarStyle;if(typeof b.summaryBarStyle!==c)o=b.summaryBarStyle;if(typeof b.barStyle!==c)o=b.barStyle;typeof o!== +c&&u.setAttribute("style",o)}j.appendChild(u);if(f.isTaskCompletedEffortVisible&&f.isSummaryTaskCompletedEffortVisible){u=m.createElementNS("http://www.w3.org/2000/svg","rect");u.setAttribute("x",l);u.setAttribute("y",f.barMargin+f.completedBarMargin*2.15/3);u.setAttribute("width",Math.max(0,n-l-1)*g.getItemCompletion(b));u.setAttribute("height",f.completedBarHeight*2.15/3);u.setAttribute("rx",f.completedBarCornerRadius);u.setAttribute("ry",f.completedBarCornerRadius);var p=f.summaryCompletedBarClass; +if(typeof b.summaryCompletedBarClass!==c)p=b.summaryCompletedBarClass;if(typeof b.completedBarClass!==c)p=b.completedBarClass;if(typeof p!==c)u.setAttribute("class",p);else{p=f.summaryCompletedBarStyle;if(typeof b.summaryCompletedBarStyle!==c)p=b.summaryCompletedBarStyle;if(typeof b.completedBarStyle!==c)p=b.completedBarStyle;typeof p!==c&&u.setAttribute("style",p)}j.appendChild(u)}if(!b.isExpanded){u=m.createElementNS("http://www.w3.org/2000/svg","line");u.setAttribute("x1",l);u.setAttribute("y1", +f.barMargin+w+2.5);u.setAttribute("x2",n-1);u.setAttribute("y2",f.barMargin+w+2.5);p=f.collapsedSummaryLineClass;if(typeof b.collapsedSummaryLineClass!==c)p=b.collapsedSummaryLineClass;if(typeof p!==c)u.setAttribute("class",p);else{p=f.collapsedSummaryLineStyle;if(typeof b.collapsedSummaryLineStyle!==c)p=b.collapsedSummaryLineStyle;typeof p!==c&&u.setAttribute("style",p)}j.appendChild(u)}var p=m.createElementNS("http://www.w3.org/2000/svg","polygon"),u=f.barMargin-0.25,k=w+1.5,F=f.barHeight*3/4,s= +f.barHeight/4,w=l-1-f.barHeight/3;p.setAttribute("points",w+","+u+" "+w+","+(u+k)+" "+(w+F/2)+","+(u+k+s)+" "+(w+F)+","+(u+k)+" "+(w+F)+","+u);typeof t!==c&&p.setAttribute("class",t);typeof o!==c&&p.setAttribute("style",o);j.appendChild(p);p=m.createElementNS("http://www.w3.org/2000/svg","polygon");w=n+f.barHeight/3;p.setAttribute("points",w+","+u+" "+w+","+(u+k)+" "+(w-F/2)+","+(u+k+s)+" "+(w-F)+","+(u+k)+" "+(w-F)+","+u);typeof t!==c&&p.setAttribute("class",t);typeof o!==c&&p.setAttribute("style", +o);j.appendChild(p);if(!f.isReadOnly&&!f.isChartReadOnly&&(typeof b.isReadOnly===c||!b.isReadOnly)&&(typeof b.isBarReadOnly===c||!b.isBarReadOnly)&&f.areTaskDependenciesVisible&&!f.areTaskPredecessorsReadOnly&&!b.isPart){t=null;if(typeof f.allowCreatingStartDependencies===c||f.allowCreatingStartDependencies){t=m.createElementNS("http://www.w3.org/2000/svg","circle");t.setAttribute("cx",l-0.5);t.setAttribute("cy",f.barMargin+f.barHeight/2);t.setAttribute("r",f.barHeight/4);t.setAttribute("style","fill: White; fill-opacity: 0; cursor: pointer"); +j.appendChild(t)}m=m.createElementNS("http://www.w3.org/2000/svg","circle");m.setAttribute("cx",n-0.5);m.setAttribute("cy",f.barMargin+f.barHeight/2);m.setAttribute("r",2.5);m.setAttribute("style","fill: White; fill-opacity: 0; cursor: pointer");j.appendChild(m);ab(m,t,j,b,f.barMargin+f.barHeight/2,n-1.5,l,h,g,f)}return j}},Ib=function(a,d,e){return function(b){var g=typeof d!==c?d:b.ganttChartView,f=typeof e!==c?e:g.settings,h=typeof a!==c?a:g.items,m=g.ownerDocument,j=pb(b);if(f.isBaselineVisible&& +typeof b.baselineStart!==c){var l=H(b.baselineStart,f),n=m.createElementNS("http://www.w3.org/2000/svg","polygon"),w=f.barMargin-1,u=f.barHeight+1;n.setAttribute("points",l+","+w+" "+(l-u/2)+","+(w+u/2)+" "+l+","+(w+u)+" "+(l+u/2)+","+(w+u/2));l=f.baselineBarClass;if(typeof b.baselineBarClass!==c)l=b.baselineBarClass;if(typeof l!==c)n.setAttribute("class",l);else{var t=f.baselineBarStyle;if(typeof b.baselineBarStyle!==c)t=b.baselineBarStyle}n.setAttribute("style",t);j.appendChild(n)}n=H(b.start,f); +t=m.createElementNS("http://www.w3.org/2000/svg","polygon");n=n-1;w=f.barMargin;l=f.barHeight+1;t.setAttribute("points",n+","+w+" "+(n-l/2)+","+(w+l/2)+" "+n+","+(w+l)+" "+(n+l/2)+","+(w+l/2));w=f.milestoneBarClass;if(typeof b.milestoneBarClass!==c)w=b.milestoneBarClass;if(typeof b.barClass!==c)w=b.barClass;if(typeof w!==c)t.setAttribute("class",w);else{w=f.milestoneBarStyle;if(typeof b.milestoneBarStyle!==c)w=b.milestoneBarStyle;if(typeof b.barStyle!==c)w=b.barStyle;typeof w!==c&&t.setAttribute("style", +w)}j.appendChild(t);if(!f.isReadOnly&&!f.isChartReadOnly&&(typeof b.isReadOnly===c||!b.isReadOnly)&&(typeof b.isBarReadOnly===c||!b.isBarReadOnly)){t=m.createElementNS("http://www.w3.org/2000/svg","rect");t.setAttribute("x",n-l/2);t.setAttribute("y",f.barMargin);t.setAttribute("width",l);t.setAttribute("height",l);t.setAttribute("style","fill: White; fill-opacity: 0; cursor: pointer");j.appendChild(t);qb(t,null,null,null,b,n,n,n,h,g,f);if(f.areTaskDependenciesVisible&&!f.areTaskPredecessorsReadOnly&& +!b.isPart){m=m.createElementNS("http://www.w3.org/2000/svg","circle");m.setAttribute("cx",n);m.setAttribute("cy",f.barMargin+f.barHeight/2);m.setAttribute("r",f.barHeight/4);m.setAttribute("style","fill: White; fill-opacity: 0; cursor: pointer");j.appendChild(m);ab(m,null,j,b,f.barMargin+f.barHeight/2,n,n,h,g,f)}}return j}},Lb=function(a,d){return function(e,b){var g=e.ganttChartView,f=typeof d!==c?d:g.settings,h=typeof a!==c?a:g.items,m=g.ownerDocument,g=m.createElementNS("http://www.w3.org/2000/svg", +"g"),j;j=za(b.item,h,f);var l=za(e,h,f),h="M ",n,w,u=f.itemHeight,t=u/2,o=u/3.5,p=2,k=false,F;if(j==l&&(typeof b.dependencyType===c||b.dependencyType=="FinishStart"||b.dependencyType=="FS"||b.dependencyType=="StartFinish"||b.dependencyType=="SF")){if(typeof b.dependencyType===c||b.dependencyType=="FinishStart"||b.dependencyType=="FS"){n=H(b.item.finish,f);w=H(e.start,f)}else{n=H(b.item.start,f);w=H(e.finish,f)}j=j-l+0.5;h=h+(n+" "+(j+t)+" L "+(w+(w>n?-1:1)*(u/5-1))+" "+(j+t))}else{if(typeof b.dependencyType!== +c&&(b.dependencyType=="StartStart"||b.dependencyType=="SS"||b.dependencyType=="StartFinish"||b.dependencyType=="SF")){n=H(b.item.start,f);b.item.hasChildren&&(typeof b.item.isSummaryEnabled===c||b.item.isSummaryEnabled)?n=n-(f.barHeight/3+0.25):b.item.isMilestone&&(n=n-u/4);w=n-o}else{n=H(b.item.finish,f)-1;if(b.item.hasChildren&&(typeof b.item.isSummaryEnabled===c||b.item.isSummaryEnabled))n=n+(f.barHeight/3+0.25);else if(b.item.isMilestone)n=n+u/4;else{F=H(b.item.start,f)+4-1;n o*2&&e.start>=b.item.finish)&&(l=w)}}if(typeof b.dependencyType!==c&&(b.dependencyType=="StartStart"||b.dependencyType=="SS"||b.dependencyType=="StartFinish"|| +b.dependencyType=="SF")){if(l>w){j=j-o/6;j=j<=0?j+t:j-t;h=h+(" "+w+" "+(j+t))}}else if(l n-p&&(p=-p);n=n-p}h=h+(" "+l+" "+j);k&&(h=h+(" "+n+" "+j))}j=h;h=m.createElementNS("http://www.w3.org/2000/svg","path");h.setAttribute("d",j);typeof f.dependencyLineZoneClass!==c&&h.setAttribute("class",f.dependencyLineZoneClass);typeof f.dependencyLineZoneStyle!==c&&h.setAttribute("style", +f.dependencyLineZoneStyle);g.appendChild(h);m=m.createElementNS("http://www.w3.org/2000/svg","path");m.setAttribute("d",j);j=f.dependencyLineClass;if(typeof b.dependencyLineClass!==c)j=b.dependencyLineClass;if(typeof j!==c)m.setAttribute("class",j);else{f=f.dependencyLineStyle;if(typeof b.dependencyLineStyle!==c)f=b.dependencyLineStyle;typeof f!==c&&m.setAttribute("style",f)}g.appendChild(m);return g}},Mb=function(a){return function(d,e){var b=d.ganttChartView.ownerDocument,g=b.createElementNS("http://www.w3.org/2000/svg", +"title");g.appendChild(Q(b,e.item.content+" - "+d.content));if(typeof a.areToolTipsSimplified===c||!a.areToolTipsSimplified){if(e.dependencyType){g.appendChild(b.createTextNode("\n"));g.appendChild(Q(b,"Type: "+ac(e.dependencyType)))}if(e.lag){g.appendChild(b.createTextNode("\n"));g.appendChild(Q(b,"Lag: "+e.lag/36E5+"h"))}}return g}},ac=function(a){switch(a){case "StartStart":case "SS":return"SS";case "FinishFinish":case "FF":return"FF";case "StartFinish":case "SF":return"SF";default:return"FS"}}, +y=function(a,d,e,b){if(typeof a.ganttChartView!==c){var g=a.ganttChartView,f=g.settings;if(d=="start"||d=="minStart"||d=="maxStart"){if(typeof a.minStart!==c&&a.start a.maxStart){a.start=a.maxStart;if(typeof a.loadChartItem===c)a.start=R(a.start,f,true,typeof a.isMilestone!==c&&a.isMilestone,D(a));if(e)a.preferredStart= +a.start}if(a.finish a.finish){a.completedFinish=a.finish;y(a,"completedFinish",false,true)}}else if(d=="finish"||d=="minFinish"||d=="maxFinish"){if(typeof a.maxFinish!==c&&a.finish>a.maxFinish){a.finish=a.maxFinish;if(typeof a.loadChartItem===c)a.finish=R(a.finish,f,typeof a.isMilestone!==c&&a.isMilestone,true,D(a))}else if(typeof a.minFinish!== +c&&a.finish a.finish){a.completedFinish=a.finish;y(a,"completedFinish",false,true)}}if(g.isTimingInformationInitialized){var h=g.items,m,j;if(d=="indentation"||d=="predecessors")for(m=0;m< +h.length;m++){j=h[m];typeof j.dependsOf!==c&&delete j.dependsOf}if((d=="predecessors"||d=="start"||d=="finish")&&typeof a.isDuringPropertyChangeTaskDependencyConstraintsEnsuring===c&&f.areTaskDependencyConstraintsEnabled&&(f.areTaskDependencyConstraintsEnabledWhileDragging||typeof g.isDuringTimeDragOperation===c)){a.isDuringPropertyChangeTaskDependencyConstraintsEnsuring=true;for(j=a.parent;j!=null;){typeof j.predecessors!==c&&j.predecessors.length>0&&Ka(j,h,f,g);j=j.parent}j=a;for(typeof j.predecessors!== +c&&j.predecessors.length>0?Ka(j,h,f,g):rb(j,f);j!=null;){if(typeof j.successors===c){j.successors=[];for(m=0;m 0&&(j=j+", ");n=Math.floor(l.value/h*1E6)/1E6;j=j+(l.key+(n!=1?" ["+n*100+"%]":""))}g.setItemAssignmentsContent(a,j)}f.itemPropertyChangeHandler(a,d,e,b);d=="isExpanded"?typeof a.ganttChartView!==c&&typeof a.ganttChartView.settings.itemExpansionChangeHandler!== +c&&a.ganttChartView.settings.itemExpansionChangeHandler(a,a.isExpanded):d=="isSelected"&&typeof a.ganttChartView!==c&&typeof a.ganttChartView.settings.itemSelectionChangeHandler!==c&&a.ganttChartView.settings.itemSelectionChangeHandler(a,a.isSelected,e);typeof a.scheduleChartView!==c&&d=="content"&&a.scheduleChartView.refreshScheduleChartItem(a)}},rb=function(a,d){if(typeof a.isAwaitingPreferredStartUpdates===c)if(a.hasChildren&&(typeof a.isSummaryEnabled===c||a.isSummaryEnabled))for(var e=0;e f&&(!a.hasChildren||!(typeof a.isSummaryEnabled===c||a.isSummaryEnabled))){a.finish= +R(oa(f,b),b,a.isMilestone,true,D(a));if(a.finish a.finish){a.completedFinish=a.finish;y(a,"completedFinish",false,true)}e=true}}else if(d.dependencyType=="StartFinish"||d.dependencyType=="SF"){f=f.start;typeof d.lag!==c&&d.lag!=0&&(f=S(f,d.lag,b,D(a)));if(a.finish>f&&(!a.hasChildren||!(typeof a.isSummaryEnabled=== +c||a.isSummaryEnabled))){a.finish=R(oa(f,b),b,a.isMilestone,true,D(a));if(a.finish a.finish){a.completedFinish=a.finish;y(a,"completedFinish",false,true)}e=true}}if(e&&!(typeof a.ganttChartView===c||typeof a.isAwaitingEnsureItemDependencyConstraintsUpdates!==c))if(typeof a.ganttChartView!==c&&!a.ganttChartView.isTimingInformationInitialized)Y(a); +else{a.isAwaitingEnsureItemDependencyConstraintsUpdates=true;setTimeout(function(){Y(a);delete a.isAwaitingEnsureItemDependencyConstraintsUpdates},0)}}},Ra=function(a,d){if(typeof a.dependsOf!==c&&typeof a.dependsOf[a]!==c)return a.dependsOf[d];try{if(a==d)return true;var e=cc(a);if(e.indexOf(d)>=0)return true;var b=cc(d);if(b.indexOf(a)>=0)return true;var g=sb(a),f,h;for(f=0;f =0||b.indexOf(h)>=0||Ra(h,d))return true}for(g=0;g =0||b.indexOf(h)>=0||Ra(h,d))return true}}var j=a.children;for(f=0;f 0&&Ra(l,d))return true}}finally{if(typeof a.dependsOf===c)a.dependsOf={};a.dependsOf[d]=true}return a.dependsOf[d]=false},cc=function(a){for(var d=[];typeof a.parent!==c&&a.parent!=null;){(typeof a.isSummaryEnabled===c||a.isSummaryEnabled)&&d.push(a.parent);a=a.parent}return d},sb=function(a){var d= +[];if(typeof a.predecessors!==c&&a.predecessors!=null)for(var e=0;e h||!b&&a==h)if(b)a=h;else{g=$(g);a=f}for(b=la(g);b j||Tb(g,d);){if(e){b++;g=$(g); +a=f}else{b--;g=La(g);a=h}for(;b<0;)b=b+7;for(;b>=7;)b=b-7}return new Date(g.valueOf()+a)},O=function(a,d,e,b){if(d.valueOf() =f){j=$(j);a=g}for(var l=X(d);j =h&&(n<=m&&!Tb(j,b))&&(e=e+(f-a));j=$(j);a=g}d=ja(d);d f&&(d=f);d>a&&(e=e+(d-a));return e},S=function(a,d,e,b){if(d<0)return Sa(-d,a,e,b);a=R(a,e,true,false,b);if(d==0)return a;var g=typeof b!==c&&typeof b.workingDayStart!==c?b.workingDayStart:e.visibleDayStart,f=typeof b!==c&&typeof b.workingDayFinish!== +c?b.workingDayFinish:e.visibleDayFinish,h=ja(a);if(h+d 0;){a=ja(a)>0?R($(X(a)),e,true,false,b):R(X(a),e,true,false,b);if(g+d g)return new Date(d.valueOf()-a);h=h-g;d=new Date(d.valueOf()-h);for(a=a-h;a>0;){d=ja(d)<864E5?R(X(d),e,false,true,b):R(La(X(d)),e,false,true,b);if(f-a>g)return new Date(d.valueOf()-a);h=f-g;d=new Date(d.valueOf()-h);a=a-h}return new Date(d.valueOf())},bb=function(a,d,e,b,c){return O(a,d,b,c)/O(a,e,b,c)},ec=function(a,d,e,b,c){return S(a,d*O(a,e,b,c),b,c)},Ta=function(a){for(var d=0,a=fa(a),e=0;e e){b=f.key;e=f.value}}if((a=a.ganttChartView)&&a.settings&&a.settings.resourceSchedules){b=indexOfKey(a.settings.resourceSchedules,b);return b<0||!a.settings.resourceSchedules[b]?void 0:a.settings.resourceSchedules[b].value}}},qb=function(a,d,e,b,g,f,h,m,j,l,n){function w(b,d){l.isDuringTimeDragOperation=true;l.draggingItem=g;l.dragType="Start";l.style.cursor=a.style.cursor;l.draggingInitialX=b.clientX;l.draggingInitialStartPosition= +f;l.draggingInitialFinishPosition=h;l.draggingInitialCompletedFinishPosition=m;if(DlhSoft.Controls.ToolTip&&n.useUpdatingToolTips&&!d){(u=DlhSoft.Controls.ToolTip.get(a))||(u=DlhSoft.Controls.ToolTip.initialize(void 0,a,{duration:NaN,containerStyle:"cursor: default; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; border: 1px solid "+n.border+"; background-color: White; color: Black; font-family: Arial; font-size: 12px; padding: 4px; margin-top: 1px"},"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.")); +u.setContent(n.dateTimeFormatter(x(g.start))+" \u2013 "+n.dateTimeFormatter(x(g.finish)));u.show();u.originalX=u.x;l.toolTip=u}}var u;a.addEventListener("mousedown",function(a){if(a.button==0){w(a);a.preventDefault()}},true);a.addEventListener("touchstart",function(a){w(a.touches[0],true);a.preventDefault();a.target.addEventListener("touchmove",g.touchMoveHandler);a.target.addEventListener("touchend",g.touchEndHandler)},true);if(d!=null){var t=function(b,e){l.isDuringTimeDragOperation=true;l.draggingItem= +g;l.dragType="StartOnly";l.style.cursor=a.style.cursor;l.draggingInitialX=b.clientX;l.draggingInitialStartPosition=f;if(DlhSoft.Controls.ToolTip&&n.useUpdatingToolTips&&!e){(u=DlhSoft.Controls.ToolTip.get(d))||(u=DlhSoft.Controls.ToolTip.initialize(void 0,d,{duration:NaN,containerStyle:"cursor: default; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; border: 1px solid "+n.border+"; background-color: White; color: Black; font-family: Arial; font-size: 12px; padding: 4px; margin-top: 1px"}, +"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase."));u.setContent(n.dateTimeFormatter(x(g.start))+" \u2013");u.show();u.setHorizontalPosition(u.x+4);u.originalX=u.x;l.toolTip=u}};d.addEventListener("mousedown",function(a){if(a.button==0){t(a);a.preventDefault()}},true);d.addEventListener("touchstart",function(a){t(a.touches[0],true);a.preventDefault();a.target.addEventListener("touchmove",g.touchMoveHandler);a.target.addEventListener("touchend", +g.touchEndHandler)},true)}if(e!=null){var o=function(a,b){l.isDuringTimeDragOperation=true;l.draggingItem=g;l.dragType="Finish";l.style.cursor=e.style.cursor;l.draggingInitialX=a.clientX;l.draggingInitialFinishPosition=h;if(DlhSoft.Controls.ToolTip&&n.useUpdatingToolTips&&!b){(u=DlhSoft.Controls.ToolTip.get(e))||(u=DlhSoft.Controls.ToolTip.initialize(void 0,e,{duration:NaN,containerStyle:"cursor: default; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; border: 1px solid "+ +n.border+"; background-color: White; color: Black; font-family: Arial; font-size: 12px; padding: 4px; margin-top: 1px"},"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase."));u.setContent("\u2013 "+n.dateTimeFormatter(x(g.finish)));u.show();u.setHorizontalPosition(u.x-u.contentContainer.clientWidth);u.originalX=u.x;l.toolTip=u}};e.addEventListener("mousedown",function(a){if(a.button==0){o(a);a.preventDefault()}}, +true);e.addEventListener("touchstart",function(a){o(a.touches[0],true);a.preventDefault();a.target.addEventListener("touchmove",g.touchMoveHandler);a.target.addEventListener("touchend",g.touchEndHandler)},true)}if(b!=null){var p=function(a,d){l.isDuringTimeDragOperation=true;l.draggingItem=g;l.dragType="CompletedFinish";l.style.cursor=b.style.cursor;l.draggingInitialX=a.clientX;l.draggingInitialCompletedFinishPosition=m;if(DlhSoft.Controls.ToolTip&&n.useUpdatingToolTips&&!d){(u=DlhSoft.Controls.ToolTip.get(b))|| +(u=DlhSoft.Controls.ToolTip.initialize(void 0,b,{duration:NaN,containerStyle:"cursor: default; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; border: 1px solid "+n.border+"; background-color: White; color: Black; font-family: Arial; font-size: 12px; padding: 4px; margin-top: 1px"},"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase."));var e=bb(g.start,g.completedFinish, +g.finish,n,D(g));if(!isNaN(e)){u.setContent(Math.round(e*1E4)/100+"%");u.show();u.setHorizontalPosition(u.x+2);u.originalX=u.x;l.toolTip=u}}};b.addEventListener("mousedown",function(a){if(a.button==0){p(a);a.preventDefault()}},true);b.addEventListener("touchstart",function(a){p(a.touches[0],true);a.preventDefault();a.target.addEventListener("touchmove",g.touchMoveHandler);a.target.addEventListener("touchend",g.touchEndHandler)},true)}if(typeof l.draggableItems===c)l.draggableItems=[];for(var k=false, +F=0;F g.finish)d=g.finish;g.start=d;g.preferredStart=g.start;y(g,"start",true,false);if(l.dragType!="StartOnly"){if(g.isMilestone){g.finish=g.start;y(g,"finish",false,false);g.completedFinish=g.start}else{g.finish=S(g.start,e,n,D(g));y(g,"finish",false,false);g.completedFinish=S(g.start,m,n,D(g))}y(g,"completedFinish",false,false);if(DlhSoft.Controls.ToolTip&& +n.useUpdatingToolTips&&!b){u=l.toolTip;u.setContent(n.dateTimeFormatter(x(g.start))+" \u2013 "+n.dateTimeFormatter(x(g.finish)));u.setHorizontalPosition(u.originalX+(H(g.start,n)-l.draggingInitialStartPosition))}}else{if(g.finish e){g.completedFinish=e;y(g,"completedFinish",false,false)}if(DlhSoft.Controls.ToolTip&&n.useUpdatingToolTips&&!b){u=l.toolTip;u.setContent("\u2013 "+n.dateTimeFormatter(x(g.finish))); +u.setHorizontalPosition(u.originalX+(H(g.finish,n)-l.draggingInitialFinishPosition))}Ua(g,j,l.chartContent,n)}else if(l.dragType=="CompletedFinish"){e=R(oa(Ca(l.draggingInitialCompletedFinishPosition+d,n),n),n,g.isMilestone,true,D(g));if(e g.finish)e=g.finish;if(e.valueOf()!=g.completedFinish.valueOf()){g.completedFinish=e;y(g,"completedFinish",true,false)}if(DlhSoft.Controls.ToolTip&&n.useUpdatingToolTips&&!b){u=l.toolTip;e=bb(g.start,g.completedFinish,g.finish,n,D(g));if(!isNaN(e)){u.setContent(Math.round(e* +1E4)/100+"%");u.setHorizontalPosition(u.originalX+(H(g.completedFinish,n)-l.draggingInitialCompletedFinishPosition))}}Ua(g,j,l.chartContent,n)}l.draggingItem=g;l.draggingPerformed=true}};l.addEventListener("mousemove",function(a){s(a)},true);l.addEventListener("touchmove",function(a){s(a.touches[0],true)},true);g.touchMoveHandler=function(a){s(a.touches[0],true)};var r=function(){if(!(typeof l.draggingItem===c||l.draggingItem!=g||l.dragType!="Start"&&l.dragType!="StartOnly"&&l.dragType!="Finish"&& +l.dragType!="CompletedFinish")){delete l.isDuringTimeDragOperation;var a=l.draggingItem;l.style.cursor="default";if(l.draggingPerformed){if(l.dragType=="Start"||l.dragType=="StartOnly"){y(a,"start",true,true);y(a,"finish",false,true);y(a,"completedFinish",false,true)}else if(l.dragType=="Finish"){y(a,"finish",true,true);y(a,"completedFinish",false,true)}else l.dragType=="CompletedFinish"&&y(a,"completedFinish",true,true);delete l.draggingPerformed}delete l.draggingItem}};document.addEventListener("mouseup", +function(a){a.button==0&&r()},true);document.addEventListener("touchend",function(){r()},true);g.touchEndHandler=function(){r()};l.draggableItems.push(g)}},ab=function(a,d,e,b,g,f,h,m,j,l){function n(d,e){delete j.cancelDrag;j.draggingItem=b;j.dragType="Dependency";j.dragDependencyType="Finish";j.style.cursor=a.style.cursor;j.draggingInitialX=d.clientX;j.draggingInitialY=d.clientY;j.draggingInitialRightPosition=f;j.draggingInitialTopPosition=g;j.draggingInitialFinishPosition=f;j.draggingInitialThumbPosition= +g;if(DlhSoft.Controls.ToolTip&&l.useUpdatingToolTips&&!e){(toolTip=DlhSoft.Controls.ToolTip.get(a))||(toolTip=DlhSoft.Controls.ToolTip.initialize(void 0,a,{duration:NaN,containerStyle:"cursor: default; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; border: 1px solid "+l.border+"; background-color: White; color: Black; font-family: Arial; font-size: 12px; padding: 4px; margin-top: 1px"},"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.")); +toolTip.setContent(b.content+" \u2013");toolTip.show();toolTip.setPosition(toolTip.x+16,toolTip.y-8);toolTip.originalX=toolTip.x;toolTip.originalY=toolTip.y;j.toolTip=toolTip}}var w=b.ganttChartView.ownerDocument;a.addEventListener("mousedown",function(a){if(a.button==0){n(a);a.preventDefault()}},true);a.addEventListener("touchstart",function(a){n(a.touches[0],true);a.preventDefault()},true);if(d!=null){var u=function(e,c){delete j.cancelDrag;j.draggingItem=b;j.dragType="Dependency";j.dragDependencyType= +"Start";j.style.cursor=a.style.cursor;j.draggingInitialX=e.clientX;j.draggingInitialY=e.clientY;j.draggingInitialRightPosition=h;j.draggingInitialTopPosition=g;j.draggingInitialFinishPosition=h;j.draggingInitialThumbPosition=g;e.preventDefault();if(DlhSoft.Controls.ToolTip&&l.useUpdatingToolTips&&!c){(toolTip=DlhSoft.Controls.ToolTip.get(d))||(toolTip=DlhSoft.Controls.ToolTip.initialize(void 0,d,{duration:NaN,containerStyle:"cursor: default; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; border: 1px solid "+ +l.border+"; background-color: White; color: Black; font-family: Arial; font-size: 12px; padding: 4px; margin-top: 1px"},"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase."));toolTip.setContent(b.content+" \u2013");toolTip.show();toolTip.setPosition(toolTip.x+16,toolTip.y-8);toolTip.originalX=toolTip.x;toolTip.originalY=toolTip.y;j.toolTip=toolTip}};d.addEventListener("mousedown",function(a){if(a.button==0){u(a); +a.preventDefault()}},true);d.addEventListener("touchstart",function(a){u(a.touches[0],true);a.preventDefault()},true)}a.addEventListener("mouseover",function(){if(typeof j.temporaryHoveringThumb!==c){var b=j.temporaryHoveringThumb;delete j.temporaryHoveringThumb;if(typeof b.originalStyle===c)return;b.setAttribute("style",b.originalStyle);delete b.originalStyle}if(typeof j.temporaryDependencyLine===c){a.mouseOver=true;j.temporaryHoveringThumb=a;a.originalStyle=a.getAttribute("style");typeof l.dependencyPointerClass!== +c&&a.setAttribute("class",l.dependencyPointerClass);typeof l.dependencyPointerStyle!==c&&a.setAttribute("style",l.dependencyPointerStyle);a.style.cursor="pointer"}},true);d!=null&&d.addEventListener("mouseover",function(){if(typeof j.temporaryHoveringThumb!==c){var a=j.temporaryHoveringThumb;delete j.temporaryHoveringThumb;if(typeof a.originalStyle===c)return;a.setAttribute("style",a.originalStyle);delete a.originalStyle}if(typeof j.temporaryDependencyLine===c){d.mouseOver=true;j.temporaryHoveringThumb= +d;d.originalStyle=d.getAttribute("style");typeof l.dependencyPointerClass!==c&&d.setAttribute("class",l.dependencyPointerClass);typeof l.dependencyPointerStyle!==c&&d.setAttribute("style",l.dependencyPointerStyle);d.style.cursor="pointer"}},true);a.addEventListener("mouseout",function(){delete a.mouseOver;setTimeout(function(){if(!(typeof a.originalStyle===c||a.mouseOver)){a.setAttribute("style",a.originalStyle);delete a.originalStyle}},250)},true);d!=null&&d.addEventListener("mouseout",function(){delete d.mouseOver; +setTimeout(function(){if(!(typeof d.originalStyle===c||d.mouseOver)){d.setAttribute("style",d.originalStyle);delete d.originalStyle}},250)},true);if(typeof j.draggableDependencyItems===c)j.draggableDependencyItems=[];for(var t=false,o=0;o o||mb(h,b)||Da(h,b)||Da(b,h))h=null;if(h!=null&&(typeof l.allowCreatingToFinishDependencies===c||l.allowCreatingToFinishDependencies)&& +!h.isMilestone&&u>t+(o-t)*3/4)p="Finish"}toolTip.setContent(b.content+" \u2013"+(h!=null?" "+h.content+(p!="Finish"?"":" \u2022"):""));toolTip.setPosition(toolTip.originalX+f,toolTip.originalY+g)}}}};j.addEventListener("mousemove",function(a){p(a)},true);j.addEventListener("touchmove",function(a){p(a.touches[0],true)},true);var k=function(a){if(!(typeof j.draggingItem===c||j.draggingItem!=b||j.dragType!="Dependency")){if(typeof j.temporaryDependencyLine!==c){try{e.removeChild(j.temporaryDependencyLine)}catch(d){}delete j.temporaryDependencyLine}for(var f= +Math.floor((b.itemTop+j.draggingInitialThumbPosition+(a.clientY-j.draggingInitialY))/l.itemHeight),g=null,n=0,h=0;h = +f&&a<=n&&!mb(g,b)&&!Da(g,b)&&!Da(b,g)){a=g==null||typeof l.allowCreatingToFinishDependencies!==c&&!l.allowCreatingToFinishDependencies||g.isMilestone||a<=f+(n-f)*3/4?"Start":"Finish";delete b.successors;if(typeof g.predecessors===c)g.predecessors=[];f={item:b};if(j.dragDependencyType!="Start"){if(a=="Finish")f.dependencyType="FF"}else f.dependencyType=a!="Finish"?"SS":"SF";g.predecessors.push(f);y(g,"predecessors",true,true);if(g.start =d.gridContentContainer.offsetWidth+d.chartContentContainer.clientWidth-24){e=d.chartContentContainer.scrollLeft;d.chartContentContainer.scrollLeft=d.chartContentContainer.scrollLeft+20;e=d.chartContentContainer.scrollLeft-e;if(typeof d.draggingInitialStartPosition!==c)d.draggingInitialStartPosition=d.draggingInitialStartPosition+e;if(typeof d.draggingInitialFinishPosition!==c)d.draggingInitialFinishPosition=d.draggingInitialFinishPosition+e;if(typeof d.draggingInitialCompletedFinishPosition!== +c)d.draggingInitialCompletedFinishPosition=d.draggingInitialCompletedFinishPosition+e}}},Oc=function(a){var d=0;if(a.offsetParent){do{d=d+a.offsetTop;a=a.offsetParent}while(a)}return d},gc=function(a,d){if(typeof d.draggingItem!==c){var a=a-Oc(d),e,b;if(a =d.chartHeaderContainer.clientHeight+d.chartContentContainer.clientHeight-24){e=d.chartContentContainer.scrollTop;d.chartContentContainer.scrollTop=d.chartContentContainer.scrollTop+20;if(typeof d.isDuringVerticalScrolling===c){d.isDuringVerticalScrolling=true;setTimeout(function(){b=d.chartContentContainer.scrollTop-e;d.draggingInitialThumbPosition= +d.draggingInitialThumbPosition+b;delete d.isDuringVerticalScrolling},0)}}}},Ua=function(a,d,e,b){ea(a.chartItem,a,b);pa(d,a);setTimeout(function(){if(typeof a.gridItem!==c){if(typeof a.completedInput!==c){var g=a.completedInput;typeof g.changeEventListener!==c&&g.removeEventListener("change",g.changeEventListener,true);delete a.completedInput}Aa(a.gridItem,a,d,b.columns,e,b.toggleButtonAreaWidth,b)}for(g=a.parent;g!=null;){Ya(g,false);a=g;ea(a.chartItem,a,b);pa(d,a);typeof a.gridItem!==c&&Aa(a.gridItem, +a,d,b.columns,e,b.toggleButtonAreaWidth,b);g=a.parent}},0)},hc=function(a){var d=a.itemTop-a.ganttChartView.chartContentContainer.scrollTop;if(d<0)a.ganttChartView.chartContentContainer.scrollTop=a.itemTop;else if(d>a.ganttChartView.chartContentContainer.clientHeight-a.ganttChartView.settings.itemHeight)a.ganttChartView.chartContentContainer.scrollTop=a.itemTop-(a.ganttChartView.chartContentContainer.clientHeight-a.ganttChartView.settings.itemHeight)},Bc=function(a,d,e,b,g,f,h,m,j,l,n,w,u,t){var o, +p;d.addEventListener("scroll",function(){if(h.scrollTop!=d.scrollTop&&!p){o=true;setTimeout(function(){h.scrollTop=d.scrollTop;setTimeout(function(){o=false},100)},200)}if(b.scrollLeft!=d.scrollLeft)b.scrollLeft=d.scrollLeft},true);cb(d,e,g,t);typeof a.updateGridHeaderTimer!==c&&clearInterval(a.updateGridHeaderTimer);a.updateGridHeaderTimer=setInterval(function(){try{cb(d,e,g,t)}catch(b){try{clearInterval(a.updateGridHeaderTimer)}catch(c){}}},100);h.addEventListener("scroll",function(){if(d.scrollTop!= +h.scrollTop&&!o){p=true;setTimeout(function(){d.scrollTop=h.scrollTop;setTimeout(function(){p=false},100)},200)}if(m.scrollLeft!=h.scrollLeft)m.scrollLeft=h.scrollLeft;va(u,h,t);Ma(u,n,t);t.displayedTime=Ca(h.scrollLeft,t);(typeof a.isDuringScrollToDateTime===c||!a.isDuringScrollToDateTime)&&typeof t.displayedTimeChangeHandler!==c&&setTimeout(function(){t.displayedTimeChangeHandler(t.displayedTime)},0);typeof a.isDuringScrollToDateTime!==c&&delete a.isDuringScrollToDateTime},true);setTimeout(function(){if(m.scrollLeft!= +h.scrollLeft)m.scrollLeft=h.scrollLeft;va(u,h,t)},1);cb(h,j,l,t);typeof a.updateChartHeaderTimer!==c&&clearInterval(a.updateChartHeaderTimer);a.updateChartHeaderTimer=setInterval(function(){try{cb(h,j,l,t)}catch(b){try{clearInterval(a.updateChartHeaderTimer)}catch(d){}}},100);window.addEventListener("mousewheel",function(){try{a.cancelDrag=true}catch(b){}},true)},cb=function(a,d,e,b){setTimeout(function(){try{var c=d.clientWidth-a.clientWidth;c<0&&(c=0);var f=c+"px";if(e.style.width!=f){e.style.width= +f;if(c>0){e.style.boxSizing="border-box";e.style.MozBoxSizing="border-box";e.style.border="solid 1px "+b.border;e.style.borderTop="none";e.style.borderRight="none"}else{e.style.border="";e.style.borderTop="";e.style.borderRight="";e.style.boxSizing="";e.style.MozBoxSizing=""}}}catch(h){}},0)},Ba=function(a,d,e){if(e.isSplitterEnabled){a.style.height=d.clientHeight+"px";a.style.left=Math.max(0,d.offsetWidth-1)+"px"}},va=function(a,d,e){if(!(typeof d.isInitializing!==c&&d.isInitializing)&&e.isVirtualizing)for(var b= +d.scrollTop-e.itemHeight,d=b+d.clientHeight+2*e.itemHeight,g=0;g =b&&f.itemTop =d))&&delete f.isVirtuallyVisible}},yc=function(a,d){for(var e=a.childNodes.length;e-- >0;)a.removeChild(a.childNodes[e]);a.appendChild(d)},vb=function(a,d,e,b){var g=b.indexOf(a);if(!(g<0||d<0||d==g||d>=b.length)){b.splice(g,1);b.splice(d,0,a);ic(b);T(e);typeof e.settings.itemMoveHandler!==c&&e.settings.itemMoveHandler(a, +g,d)}},db=function(a,d,e,b,g){if(!(a<0||e<0||e==a||e>g.length-d)){var f=[],h;for(h=a;hd){b.indentation=d;y(b,"indentation",false,true)}d=b.indentation+1}},Pc=function(a,d,e,b,g,f,h,m,j,l){function n(e){delete b.cancelDrag;b.draggingItem= +d;b.dragType="Ordering";b.style.cursor=a.style.cursor;b.draggingInitialY=e.clientY;b.draggingInitialThumbPosition=0;b.resetChartAreaDefinitions()}a.addEventListener("mousedown",function(a){if(a.button==0){n(a);a.preventDefault()}},true);a.addEventListener("touchstart",function(a){n(a.touches[0]);a.preventDefault()},true);if(typeof b.draggableOrderingItems===c)b.draggableOrderingItems=[];for(var w=false,u=0;u l)||typeof n.displayRowIndex===c&&(z++ l+1))){p={content:n.content,indentation:n.indentation,start:n.start,finish:n.finish,completedFinish:n.completedFinish,isMilestone:n.isMilestone,schedule:D(n),assignmentsContent:n.assignmentsContent,baselineStart:n.baselineStart,baselineFinish:n.baselineFinish,isBarVisible:n.isBarVisible,isRelativeToTimezone:n.isRelativeToTimezone,"class":n["class"],style:n.style,barClass:n.barClass,standardBarClass:n.standardBarClass,completedStandardBarClass:n.completedStandardBarClass, +summaryBarClass:n.summaryBarClass,milestoneBarClass:n.milestoneBarClass,baselineBarClass:n.baselineBarClass,barStyle:n.barStyle,standardBarStyle:n.standardBarStyle,completedStandardBarStyle:n.completedStandardBarStyle,summaryBarStyle:n.summaryBarStyle,milestoneBarStyle:n.milestoneBarStyle,baselineBarStyle:n.baselineBarStyle,isSummaryEnabled:n.isSummaryEnabled,isParentSummarizationEnabled:n.isParentSummarizationEnabled,isHidden:n.isHidden,isExported:true,tag:n};if(typeof n.displayRowIndex!==c)p.displayRowIndex= +n.displayRowIndex-j;Qc(p,n);a.push(p);n.exportItem=p}}for(k=0;k l))){p=n.exportItem;if(typeof n.predecessors!==c){p.predecessors=[];for(z=0;z l)||p.predecessors.push({item:y.item.exportItem,dependencyType:y.dependencyType,lag:y.lag,dependencyLineClass:y.dependencyLineClass, +dependencyLineStyle:y.dependencyLineStyle})}}}}var E=q.createElement("p");E.innerHTML=typeof d!==c?d:"";q.body.appendChild(E);var G=q.createElement("div");G.setAttribute("style","width: "+v+"px");try{DlhSoft.Controls.GanttChartView.initialize(G,a,g,"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.")}catch(U){}setTimeout(function(){x&&q.body.setAttribute("style","margin: 0px");var a=q.createElement("div");a.appendChild(G); +q.body.replaceChild(a,E);if(u){a.setAttribute("style","width: "+G.offsetHeight+"px; height: "+v+"px; overflow: hidden");a=Math.round((G.offsetWidth-G.offsetHeight)/2);G.setAttribute("style","width: "+v+"px; transform: rotate(90deg) translateX("+a+"px) translateY("+a+"px); -webkit-transform: rotate(90deg) translateX("+a+"px) translateY("+a+"px)")}q.close();if(typeof C!==void 0){C.focus();if(typeof w!==c&&w){C.print();(typeof t===c||t)&&setTimeout(function(){C.close()})}}},0)},kc=function(a){var d= +ia;if(typeof a===c)return d;for(var e=0;e d)d=b.finish}else if(b.start>d)d=b.start}return new Date(d.valueOf())},lc=function(a,d){for(var e= +0,b=0;b =g)return true;var f;if(!a.hasChildren||!(typeof a.isSummaryEnabled===c||a.isSummaryEnabled)){var h=a.successorPredecessors?a.successorPredecessors:eb(a,e);for(f=0;f 0)&&Ka(g,a,d,e)}},oc=function(a,d,e,b){var d=new Date(d.valueOf()-d.getTimezoneOffset()*6E4),d=ra(d,b,D(a)),e=da(a,b),c=ya(a,b);yb(a,d);Wa(a,e,b);Xa(a,c,b);Y(a)},pc=function(a,d){for(var e=0,b=fa(a),g=0;g =0?e=e+d.specificResourceUsageCosts[m].value*f.value:typeof d.defaultResourceUsageCost!==c&&(e=e+d.defaultResourceUsageCost*f.value);if(!a.hasChildren||!(typeof a.isSummaryEnabled===c||a.isSummaryEnabled)){var j=da(a,d)/36E5;typeof d.specificResourceHourCosts!==c&&(m=indexOfKey(d.specificResourceHourCosts,h))>=0?e=e+d.specificResourceHourCosts[m].value*j*f.value:typeof d.defaultResourceHourCost!==c&&(e=e+d.defaultResourceHourCost*j*f.value)}}return e},Ab=function(a,d){var e=typeof d.taskInitiationCost!== +c?d.taskInitiationCost:0,e=e+pc(a,d);if(a.hasChildren&&(typeof a.isSummaryEnabled===c||a.isSummaryEnabled))for(var b=0;b 0){n=true;break}u=u.parent}if(!n)continue}g.push({key:j,value:Sc(j)});var u=!f?fa(j):[],t=[];for(n=0;n 0&&t.push(o)}m.push({key:j,value:t});w.push(j)}}e=[];for(f=g.length;f>0;){h=[];for(l=0;l =0&&h.indexOf(o)<0){n=false;break}}if(n){t=j;n=d;u=b;if(typeof t.minStart!== +c&&n n&&(n=p);break;case "StartStart":case "SS":p=S(p.item.start,typeof p.lag===c?0:p.lag,u,D(p.item));p>n&&(n=p)}}}for(t=t.parent;t!=null&&typeof t.isSummaryEnabled!==c&&!t.isSummaryEnabled;)t= +t.parent}u=n;n=indexOfKey(m,j);var t=m[n].value,r;for(n=0;n =0){p=1;if(typeof b.resourceQuantities!==c){var s=indexOfKey(b.resourceQuantities,r);if(s>=0)p=b.resourceQuantities[s].value}previousAllocations=e[k].value;for(k=0;k u&&(u=s)}}}}if((a||!Fa(j))&&(u=ra(u,b,D(j)))!=j.start){n=da(j,b);o=ya(j,b);yb(j,u);Wa(j,n,b);Xa(j,o,b)}p=j.finish; +for(n=0;n u){C=r+o;x=z q[C])q[v].value=x;z
s[v].value)s[v].value=x}}h.push(j)}}for(l= +0;l
+a.start},da=function(a,d){if(a.hasChildren&&(typeof a.isSummaryEnabled===c||a.isSummaryEnabled)){for(var e=0,b=a.children,g=0;g 0;){a=d[g];a.indentation==0&&b++}return b+(!e?1:0)}return tc(b,d)+"."+(b.children.indexOf(a)+(!e?1:0))},fa=function(a){var d;a=a.assignmentsContent;if(typeof a===c)d=[];else{for(var a= +a.split(","),e=[],b=0;b =0&&m>=0){m=trim(g.substr(h+1,m-h-1));g=trim(g.substr(0,h));h=m.indexOf("%");h>=0&&(m=trim(m.substr(0,h)));try{d=parseFloat(m);f=d/100}catch(j){f=1}}if(!(g.length<=0)){h=indexOfKey(e,g);h<0?e.push({key:g,value:f}):e[h].value=e[h].value+f}}d=e}return d},uc=function(a){for(var d=[],a=fa(a),e=0;e 0;){var m=dequeue(h);if(!(m.finish<=m.start))if(e.length==0)e.push({key:m,value:f.value});else{kc(d);for(var j=false,l=0;l =n.finish))if(m.finish<=n.start){for(j=0;j<=l;j++)if(e[j].key.start>=m.start){e.splice(j,0,{key:m,value:f.value});break}j=true;break}else if(m.start<=n.start&&m.finish>=n.finish){e[l].value=w+f.value;m.start< +n.start&&h.push({start:m.start,finish:n.start});m.finish>n.finish&&h.push({start:n.finish,finish:m.finish});j=true;break}else if(m.start>=n.start&&m.finish<=n.finish){e.splice(l,1);m.start>n.start&&e.splice(l++,0,{key:{start:n.start,finish:m.start},value:w});e.splice(l++,0,{key:m,value:w+f.value});m.finish =n.start&&m.finish>=n.finish){e.splice(l,1);m.start>n.start&&e.splice(l++,0,{key:{start:n.start, +finish:m.start},value:w});e.splice(l++,0,{key:{start:m.start,finish:n.finish},value:w+f.value});m.finish>n.finish&&h.push({start:n.finish,finish:m.finish});j=true;break}else if(m.start<=n.start&&m.finish<=n.finish){e.splice(l,1);m.start =0)return true;for(var f=0;f =0||d.splice(d.length,0,h)}}}a.items=d;a.settings=e;a.refresh=function(){T(a)};a.refreshItems=function(){Pa(d)};a.refreshGridItems=function(){for(var a=0;a 1;){var u=f.childNodes[g];u.tag!="Scale-Highlighting-CurrentTime"&&u.tag!="Scale-Separator-CurrentTime"&&h.push(u);f.removeChild(u)}hb(b,f,e.scales,e,true);for(g=h.length;g-- >0;)f.appendChild(h[g]);ta(c,ua(d,e))}; +a.setCurrentTime=function(b){e.currentTime=b;a.refreshCurrentTimeLine()};a.updateCurrentTime=function(){var b=new Date,b=new Date(b.valueOf()-b.getTimezoneOffset()*6E4);a.setCurrentTime(b)};a.getCurrentItem=function(){return a.currentItem};a.getSelectedItem=function(){return a.selectedItem};a.getSelectedItems=function(){return a.selectedItems};a.selectItem=function(a){r(a,true,e.selectionMode)};a.unselectItem=function(a){r(a,false,e.selectionMode)};a.expandItem=function(a){ga(a,true,true)};a.collapseItem= +function(a){ga(a,false,true)};a.scrollToItem=hc;a.scrollToBottom=function(){a.chartContentContainer.scrollTop=a.chartContent.clientHeight};a.scrollToDateTime=function(b){a.isDuringScrollToDateTime=true;a.chartContentContainer.scrollLeft=H(b,a.settings)};a.increaseTimelinePage=function(b){e.timelineStart=new Date(e.timelineStart.valueOf()+b);e.timelineFinish=new Date(e.timelineFinish.valueOf()+b);T(a)};a.decreaseTimelinePage=function(b){e.timelineStart=new Date(e.timelineStart.valueOf()-b);e.timelineFinish= +new Date(e.timelineFinish.valueOf()-b);T(a)};a.setSplitterPosition=function(b){var d=a.gridContainer,f=a.chartContainer,g=a.splitter,b=Math.floor(b*1E6/a.offsetWidth)/1E4;typeof d.percent!==c&&delete d.percent;d.style.width=b+"%";f.style.width=100-b+"%";Ba(g,d,e)};a.getChartPosition=function(a){return H(a,e)};a.getChartWidth=function(){return H(e.timelineFinish,e)};a.getDateTime=function(a){return Ca(a,e)};a.getWorkingTime=function(a){return dc(a,e)};a.getStartWorkingTime=function(a){return ra(a, +e)};a.getFinishWorkingTime=function(a){return R(a,e,false,true,void 0)};a.getEffort=function(a,b){return O(a,b,e)};a.getFinish=function(a,b){return S(a,b,e)};a.getStart=function(a,b){return Sa(a,b,e)};a.getCompletion=function(a,b,d){return bb(a,b,d,e)};a.getCompletedFinish=function(a,b,d){return ec(a,b,d,e)};a.getItemsHeight=function(){return ua(d,e)};a.getItemTop=function(a){return za(a,d,e)};a.onItemPropertyChanged=y;a.initializeTaskDraggingThumbs=function(b,d,e,c,f,g,h,o){qb(b,d,e,c,f,g,h,o,a.items, +a,a.settings)};a.initializeDependencyDraggingThumbs=function(b,d,e,c,f,g,h){ab(b,d,e,c,f,g,h,a.items,a,a.settings)};a.insertItem=function(b,c){Zb(b,c,a,d,e)};a.addItem=function(b){a.insertItem(d.length,b)};a.insertItems=function(b,d){for(var e=0;e 0?a.items[b.index-1]:null;if(!(f==null||b.indentation>f.indentation)){ga(b,true,false,true);b.indentation++;y(b,"indentation",true,true);if(b.predecessors&&b.predecessors.length>0){for(var g=false,n=0;n f.indentation){b.predecessors.splice(n--,1);g=true}g&&y(b,"predecessors",false,true)}for(g=0;g n.predecessors[h].item.indentation){n.predecessors.splice(h--,1);y(n,"predecessors",false,true);ma(n);qa(n)}}$a(d,e)&&Pa(d);for(Qa(b,d,a,e);b!=null;){b.isExpanded||ga(b,true,false);b=b.parent}}};a.decreaseItemIndentation=function(b){var f=b.index 0){for(var g=false,n=0;n a.finish){a.completedFinish=a.finish;y(a,"completedFinish",false,true)}};a.setItemIsMilestone=function(a,b){a.isMilestone=b;y(a,"isMilestone",true,true)}; +a.getItemEffort=function(a){return da(a,e)};a.setItemEffort=function(a,b){a.finish=S(a.start,b,e,D(a));y(a,"finish",true,true);if(a.completedFinish>a.finish){a.completedFinish=a.finish;y(a,"completedFinish",false,true)}};a.getItemTotalEffort=function(a){return tb(a)};a.setItemTotalEffort=function(a,b){a.ganttChartView.setItemEffort(a,b/Ta(a))};a.setItemHasFixedEffort=function(a,b){a.hasFixedEffort=b;if(!a.hasChildren&&a.hasFixedEffort){a.fixedEffort=da(a,e);a.fixedEffortAssignments=fa(a)}};a.getItemDuration= +function(a){return O(a.start,a.finish,e,D(a))};a.setItemDuration=a.setItemEffort;a.getItemCompletedEffort=function(a){return ya(a,e)};a.setItemCompletedEffort=function(a,b){a.completedFinish=S(a.start,b,e,D(a));if(a.completedFinish>a.finish)a.completedFinish=a.finish;y(a,"completedFinish",true,true)};a.getItemTotalCompletedEffort=function(a){return ub(a)};a.setItemTotalCompletedEffort=function(a,b){a.ganttChartView.setItemCompletedEffort(a,b/Ta(a))};a.getItemCompletion=function(b){return a.getItemCompletedEffort(b)/ +a.getItemEffort(b)};a.setItemCompletion=function(b,d){a.setItemCompletedEffort(b,d*a.getItemEffort(b))};a.isItemCompleted=function(b){return a.getItemCompletion(b)>=1||(b.isMilestone||b.finish.valueOf()<=b.start.valueOf())&&typeof b.isSetAsCompleted!==c&&b.isSetAsCompleted};a.setItemAsCompleted=function(b){if(b.isMilestone||b.finish.valueOf()<=b.start.valueOf())b.isSetAsCompleted=true;a.setItemCompletion(b,1)};a.hasItemStarted=function(a){return Fa(a)};a.setItemAsNotStarted=function(b){if(b.isMilestone|| +b.finish.valueOf()<=b.start.valueOf())b.isSetAsCompleted=false;a.setItemCompletion(b,0)};a.isItemOnSchedule=function(a){var b=new Date,b=new Date(b.valueOf()-b.getTimezoneOffset()*6E4);return a.completedFinish>=b};a.setItemAssignmentsContent=function(a,b){a.assignmentsContent=b;y(a,"assignmentsContent",true,true)};a.getItemPredecessorsString=function(a,b){var e=b;typeof e===c&&(e=false);var f="";if(!(typeof a.predecessors===c||a.predecessors.length==0))for(var g=0;g 0&&(f=f+", ");f=f+(t+(!e?1:0));if(typeof h.dependencyType!==c&&h.dependencyType!=""&&h.dependencyType!="FinishStart"&&h.dependencyType!="FS")if(h.dependencyType=="StartStart"||h.dependencyType=="SS")f=f+"SS";else if(h.dependencyType=="FinishFinish"||h.dependencyType=="FF")f=f+"FF";else if(h.dependencyType=="StartFinish"||h.dependencyType=="SF")f=f+"SF";if(typeof h.lag!==c&&h.lag!=0){h.lag>0&&(f=f+"+");f=f+h.lag/36E5}}}return f};a.setItemPredecessorsString= +function(a,b,e){typeof e===c&&(e=false);var f=[];a.predecessors=f;for(var b=b.split(","),g=0;g =48&&h.charCodeAt(t)<=57;)t++;var o=h.substr(0,t),o=parseInt(o)-(!e?1:0);if(!isNaN(o)&&!(o<0||o>=d.length)){o=d[o];if(!mb(a,o)&&!Da(a,o)&&!Da(o,a)){var h=h.substr(t),t=h.indexOf("+"),p=h.indexOf("-"),k=t>=0?t:p>=0?p:-1,p=0;if(k>=0){var r=parseFloat(h.substr(k+1));isNaN(r)||(p=r*(t>=0?1:-1)*36E5)}h=(k<0?h:h.substr(0, +k)).toUpperCase();f.push({item:o,dependencyType:h,lag:p})}}}}for(e=0;e =d.length-1||vb(b,e+1,a,d)};a.moveItemHierarchy=function(b,e){for(var c=d.indexOf(b),f=c+1;f 0;){if(d[f].indentation =b.finish)b=null;else{var h=d.indexOf(b);if(h<0)b=null;else{f={content:typeof f===c?b.content:b.content+f,indentation:b.indentation,isExpanded:b.isExpanded,start:b.completedFinish,finish:b.finish,assignmentsContent:b.assignmentsContent,isReadOnly:b.isReadOnly,isHidden:b.isHidden,isBarVisible:b.isBarVisible,isBarReadOnly:b.isBarReadOnly,isSummaryEnabled:b.isSummaryEnabled,isParentSummarizationEnabled:b.isParentSummarizationEnabled, +displayRowIndex:b.displayRowIndex,"class":b["class"],style:b.style,barClass:b.barClass,standardBarClass:b.standardBarClass,summaryBarClass:b.summaryBarClass,milestoneBarClass:b.milestoneBarClass,baselineBarClass:b.baselineBarClass,barStyle:b.barStyle,standardBarStyle:b.standardBarStyle,summaryBarStyle:b.summaryBarStyle,milestoneBarStyle:b.milestoneBarStyle,baselineBarStyle:b.baselineBarStyle,taskTemplate:b.taskTemplate,template:b.template,tag:b.tag};if(typeof g!==c)b.content=b.content+g;b.finish= +b.completedFinish;Zb(h+1,f,a,d,e);g=eb(b,d);for(h=0;h 0){t=true;break}k=k.parent}if(!t)continue}oc(u,g,d,e);o.push(u)}}xb(d,e,a);for(h=0;h 0){var h=0;for(c=0;c 0){for(c=0;c 0&&(f=f+", ");f=f+(g[c].key+(g.length>1?" ["+Math.round(g[c].value/h*1E4)/100+"%]":""))}e.assignmentsContent=f;y(e,"assignmentsContent",false,true);Y(e)}}}};a.levelResources=function(b,c){return qc(b,c,d,e,a)};a.getItemSuccessors=function(a){return nc(a,d)};a.getItemSuccessorPredecessorItems=function(a){return eb(a,d)};a.getItemAllocationUnits= +Ta;a.getItemAssignments=fa;a.getItemAssignedResources=uc;a.getResourceAssignments=function(a){return Ga(a,d)};a.getResourceAssignedItems=function(a){for(var b=[],a=Ga(a,d),e=0;e =0?b=b+e.specificResourceUsageCosts[h].value*g.value:typeof e.defaultResourceUsageCost!==c&&(b=b+e.defaultResourceUsageCost*g.value);var o=g.key;if(!o.hasChildren||!(typeof o.isSummaryEnabled===c||o.isSummaryEnabled)){o=da(o,e)/36E5;typeof e.specificResourceHourCosts!==c&&(h=indexOfKey(e.specificResourceHourCosts,resource))>=0?b=b+e.specificResourceHourCosts[h].value* +o*g.value:typeof e.defaultResourceHourCost!==c&&(b=b+e.defaultResourceHourCost*o*g.value)}}return b};a.getProjectCost=function(){for(var a=0,b=0;b =0)p=e.resourceQuantities[r].value}r=e.maxLoadChartDisplayedResourceQuantity;typeof r===c&&(r=100);p>r&&(p=r);h.ganttChartItems.push({start:k.key.start,finish:k.key.finish, +units:k.value/p,content:Math.round(k.value*1E4)/100+"%",isRelativeToTimezone:false})}b.push(h)}return b};a.getFilteredGanttChartItems=function(a){for(var a=[a],b=[],e=0;e =0)){g.push({tag:o,content:o.content,start:o.start,finish:o.finish,completedFinish:o.completedFinish,isMilestone:o.isMilestone, +assignmentsContent:a.length>1?o.assignmentsContent:h[f].value!=1?Math.round(h[f].value*1E4)/100+"%":"",minStart:o.minStart,maxStart:o.maxStart,minFinish:o.minFinish,maxFinish:o.maxFinish,isHidden:o.isHidden,isBarVisible:o.isBarVisible,isBarReadOnly:o.isBarReadOnly,isReadOnly:true,isRelativeToTimezone:o.isRelativeToTimezone});b.push(o)}}}return g};a.copyCommonSettings=function(a){copyCommonSettings(a,e)};a.getPertChartItems=function(a,b,f,g,h,o){var k=a,r=b,p=f,s=h,f=o;if(typeof k===c||k<0)k=Number.MAX_VALUE; +typeof r===c&&(r="Start");typeof p===c&&(p="Finish");typeof s===c&&(s=" completed");typeof f===c&&(f=" starting");for(var q=new Date((new Date(1E4,0,1)).valueOf()-1),o=[],v,C,x,z,y,h=[],a=0;a x)x=b.finish}v==null&&(v=q);r={content:r,displayedText:(k++).toString(),displayedRowIndex:0,displayedColumnIndex:0};o.push(r);A=[r];q=[];for(a=0;a 0){A=[];for(a=0;a v){x={content:b.content!=null?b.content.toString()+f:null,displayedText:z,predecessors:[]};o.push(x);x.predecessors.push({item:r,content:g,isEffortVirtual:true})}z={content:b.content+s,displayedText:z+(x!=r?"'":""),predecessors:[],tag:b};A.push(z);o.push(z);z.predecessors.push({item:x,content:getContentPath(b),displayedText:b.content!=null?b.content.toString():null,effort:O(b.start,b.finish,e, +D(b)),tag:b})}do{B=[];for(a=0;a =0&&E.push(h[v].key);if(E.length>0){B.splice(B.indexOf(q),1);for(v=0;v 1){s={content:b.content!=null?b.content.toString()+ +f:null,displayedText:q.displayedText,predecessors:[]};o.splice(o.indexOf(q),0,s);k=s.predecessors;for(x=0;x ra(a.finish,e)){x={content:b.content!= +null?b.content.toString()+f:null,displayedText:q.displayedText,predecessors:[]};o.splice(o.indexOf(q),0,x);x.predecessors.push({item:p.item,content:g,isEffortVirtual:true});q.predecessors.splice(0,q.predecessors.length);q.predecessors.push({item:x,content:getContentPath(b),displayedText:b.content!=null?b.content.toString():null,effort:O(b.start,b.finish,e,D(b)),tag:b});q.displayedText=q.displayedText+"'"}}}}for(a=0;a C)C=r.finish}p==null&&(p=b);C==null&&(C=f);h={content:h,displayedText:h,earlyStart:p,earlyFinish:p,lateStart:b,lateFinish:b,isMilestone:true,effort:0,displayedRowIndex:0,displayedColumnIndex:0};a.push(h); +g=[h];p=[];for(k=0;k 0){g=[];for(k=0;k =0&&A.push(z[p].key);if(A.length>0){y.splice(y.indexOf(v),1);for(p=0;p x.earlyStart){x.earlyStart= +s;x.earlyFinish=S(x.earlyStart,x.effort,e)}x.predecessors.push({item:v,tag:r})}s=true}}g=y}while(s)}o={content:o,displayedText:o,earlyStart:f,earlyFinish:f,lateStart:C,lateFinish:C,isMilestone:true,effort:0,predecessors:[],displayedRowIndex:0};a.push(o);p=o.predecessors;for(k=0;k o.earlyStart){o.earlyStart=s;o.earlyFinish=o.earlyStart}p.push({item:z})}for(g=[o];g.length>0;){z=[];for(k=0;k 0?R(r,e,false,true,void 0):r;x.lateStart=Sa(x.effort,x.lateFinish,e)}}}g=z}if(a.length>2)for(k=0;k 100&&(a=100);b(a)},c,f,h)},timeSpanInputColumnTemplateBase:function(a,d,e,b,g,f,h,m){typeof g===c&&(g=1);return DlhSoft.Controls.GanttChartView.numberInputColumnTemplateBase(a,d,function(){var a=e()/(36E5*g);return Math.round(a*100)/100},function(a){a=parseFloat(a);a<0&&(a=0);b(a*36E5*g)},f,h,m)},datePickerInputColumnTemplateBase:function(a,d,e,b,g,f,h,m,j,l,n,o,k){n||(n=["Su","Mo","Tu", +"We","Th","Fr","Sa"]);var r=o,s=k;if(!o)o=DlhSoft.Controls.GanttChartView.defaultDateTimeFormatter;if(!k)k=DlhSoft.Controls.GanttChartView.defaultDateTimeParser;var p=a.createElement("input");p.setAttribute("type","text");e=e();typeof e===c?e="":e!=null&&(e=o(e));p.setAttribute("value",e);DlhSoft.Controls.DatePicker&&p.addEventListener("focus",function(){var b=DlhSoft.Controls.DatePicker.get(p);if(!b||!b.isOpen){var e=0,d=0;try{e=p.selectionStart;d=p.selectionEnd}catch(c){}b=DlhSoft.Controls.DatePicker.initialize(p, +void 0,{inputStyle:null,defaultTimeOfDay:m,isDropDownButtonVisible:false,popupStyle:"margin-top: 1px; background-color: White; border: 1px solid #e0e0e0",calendarSelectorLevels:j,months:l,daysOfWeek:Va(n),dateTimeFormatter:r,dateTimeParser:s},"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.");b.openDropDown();setTimeout(function(){try{p.selectionStart=e;p.selectionEnd=d}catch(a){}},100);navigator.userAgent.match(/(Android)|(IPad)|(IPhone)/i)== +null?setTimeout(function(){try{p.focus()}catch(a){}},100):a.createEvent&&setTimeout(function(){var b=a.createEvent("MouseEvents");b.initEvent("blur",true,false);p.dispatchEvent(b)})}},true);o="";typeof f!==c&&!f()&&(o="; display: none");f="";typeof h!==c&&h()&&(f="; font-weight: bold");p.setAttribute("style","background-color: Transparent; width: "+d+"px; border-width: 0px; padding: 0px"+o+f);typeof g!==c&&!g()&&p.setAttribute("disabled","true");var q=function(){var a=p.value,a=a!=""?k(a):null;b(a)}; +p.addEventListener("change",function(){q()},true);p.addEventListener("keypress",function(a){if(a.keyCode==13){a.preventDefault();a.stopPropagation();q()}},true);p.addEventListener("focus",function(){p.style.backgroundColor="White"},true);p.addEventListener("blur",function(){p.style.backgroundColor="Transparent"},true);return p},dateTimePickerInputColumnTemplateBase:function(a,d,e,b,g,f,h,m,j,l,n,o,k){n||(n=["Su","Mo","Tu","We","Th","Fr","Sa"]);var r=o,s=k;if(!o)o=DlhSoft.Controls.GanttChartView.defaultDateTimeFormatter; +if(!k)k=DlhSoft.Controls.GanttChartView.defaultDateTimeParser;var p=a.createElement("input");p.setAttribute("type","text");e=e();typeof e===c?e="":e!=null&&(e=o(e));p.setAttribute("value",e);(DlhSoft.Controls.DateTimePicker||DlhSoft.Controls.DatePicker)&&p.addEventListener("focus",function(){var b=(DlhSoft.Controls.DateTimePicker?DlhSoft.Controls.DateTimePicker:DlhSoft.Controls.DatePicker).get(p);if(!b||!b.isOpen){var e=0,d=0;try{e=p.selectionStart;d=p.selectionEnd}catch(c){}b=(DlhSoft.Controls.DateTimePicker? +DlhSoft.Controls.DateTimePicker:DlhSoft.Controls.DatePicker).initialize(p,void 0,{inputStyle:null,defaultTimeOfDay:m,isDropDownButtonVisible:false,popupStyle:"margin-top: 1px; background-color: White; border: 1px solid #e0e0e0",calendarSelectorLevels:j,months:l,daysOfWeek:Va(n),dateTimeFormatter:r,dateTimeParser:s},"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.");b.openDropDown();setTimeout(function(){try{p.selectionStart= +e;p.selectionEnd=d}catch(a){}},100);navigator.userAgent.match(/(Android)|(IPad)|(IPhone)/i)==null?setTimeout(function(){try{p.focus()}catch(a){}},100):a.createEvent&&setTimeout(function(){var b=a.createEvent("MouseEvents");b.initEvent("blur",true,false);p.dispatchEvent(b)})}},true);o="";typeof f!==c&&!f()&&(o="; display: none");f="";typeof h!==c&&h()&&(f="; font-weight: bold");p.setAttribute("style","background-color: Transparent; width: "+d+"px; border-width: 0px; padding: 0px"+o+f);typeof g!==c&& +!g()&&p.setAttribute("disabled","true");var q=function(){var a=p.value,a=a!=""?k(a):null;b(a)};p.addEventListener("change",function(){q()},true);p.addEventListener("keypress",function(a){if(a.keyCode==13){a.preventDefault();a.stopPropagation();q()}},true);p.addEventListener("focus",function(){p.style.backgroundColor="White"},true);p.addEventListener("blur",function(){p.style.backgroundColor="Transparent"},true);return p},multiSelectorComboBoxInputColumnTemplateBase:function(a,d,e,b,g,f,h,m){var j= +a.createElement("input");j.setAttribute("type","text");b=b();typeof b===c&&(b="");j.setAttribute("value",b);DlhSoft.Controls.MultiSelectorComboBox&&j.addEventListener("focus",function(){var b=DlhSoft.Controls.MultiSelectorComboBox.get(j);if(!b||!b.isOpen&&b.availableChoices.length>0){var b=e(),d=0,c=0;try{d=j.selectionStart;c=j.selectionEnd}catch(f){}b=DlhSoft.Controls.MultiSelectorComboBox.initialize(j,b,void 0,{inputStyle:null,autoAppendAvailableChoices:false,isDropDownButtonVisible:false,popupStyle:"margin-top: 1px; background-color: White; border: 1px solid #e0e0e0; color: Black; font-size: small; max-height: 188px; overflow-y: auto"}, +"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.");b.openDropDown();setTimeout(function(){try{j.selectionStart=d;j.selectionEnd=c}catch(a){}},100);navigator.userAgent.match(/(Android)|(IPad)|(IPhone)/i)==null?setTimeout(function(){try{j.focus()}catch(a){}},100):a.createEvent&&setTimeout(function(){var b=a.createEvent("MouseEvents");b.initEvent("blur",true,false);j.dispatchEvent(b)})}},true);b="";typeof h!==c&& +!h()&&(b="; display: none");h="";typeof m!==c&&m()&&(h="; font-weight: bold");j.setAttribute("style","background-color: Transparent; width: "+d+"px; border-width: 0px; padding: 0px"+b+h);typeof f!==c&&!f()&&j.setAttribute("disabled","true");j.addEventListener("change",function(){g(j.value)},true);j.addEventListener("keypress",function(a){if(a.keyCode==13){a.preventDefault();a.stopPropagation();g(j.value)}},true);j.addEventListener("focus",function(){j.style.backgroundColor="White"},true);j.addEventListener("blur", +function(){j.style.backgroundColor="Transparent"},true);return j},dateTimeInputColumnTemplateBase:function(a,d,e,b,c,f,h){return DlhSoft.Controls.GanttChartView.textInputColumnTemplateBase(a,d,function(){var a=e();return a!=null?DlhSoft.Controls.GanttChartView.defaultDateTimeFormatter(a):""},function(a){a=a!=""?DlhSoft.Controls.GanttChartView.defaultDateTimeParser(a):null;b(a)},c,f,h)},getIndexColumnTemplate:function(){return function(a){var d=a.ganttChartView;return DlhSoft.Controls.GanttChartView.textColumnTemplateBase(d.ownerDocument, +function(){return d.getItemIndexString(a)})}},getWbsColumnTemplate:function(a){return function(d){var e=d.ganttChartView;return DlhSoft.Controls.GanttChartView.textColumnTemplateBase(e.ownerDocument,function(){return e.getItemWbsIndexString(d,a)})}},getEffortColumnTemplate:function(a,d,e){typeof d===c&&(d=1);return function(b){var g=b.ganttChartView;return DlhSoft.Controls.GanttChartView.timeSpanInputColumnTemplateBase(g.ownerDocument,a,function(){return g.getItemEffort(b)},function(a){g.setItemEffort(b, +a);g.refreshItemPath(b)},d,function(){return!(b.isReadOnly||e||typeof b.ganttChartView!==c&&typeof b.ganttChartView.settings!==c&&(b.ganttChartView.settings.isReadOnly||b.ganttChartView.settings.isGridReadOnly))&&!(b.hasChildren&&(typeof b.isSummaryEnabled===c||b.isSummaryEnabled))},function(){return!(b.isMilestone||typeof b.isBarVisible!==c&&!b.isBarVisible)},function(){return b.hasChildren&&(typeof b.isSummaryEnabled===c||b.isSummaryEnabled)})}},getDurationColumnTemplate:function(a,d,e){typeof d=== +c&&(d=1);return function(b){var g=b.ganttChartView;return DlhSoft.Controls.GanttChartView.timeSpanInputColumnTemplateBase(g.ownerDocument,a,function(){return g.getItemDuration(b)},function(a){g.setItemDuration(b,a);g.refreshItemPath(b)},d,function(){return!(b.isReadOnly||e||typeof b.ganttChartView!==c&&typeof b.ganttChartView.settings!==c&&(b.ganttChartView.settings.isReadOnly||b.ganttChartView.settings.isGridReadOnly))&&!(b.hasChildren&&(typeof b.isSummaryEnabled===c||b.isSummaryEnabled))},function(){return!(b.isMilestone|| +typeof b.isBarVisible!==c&&!b.isBarVisible)},function(){return b.hasChildren&&(typeof b.isSummaryEnabled===c||b.isSummaryEnabled)})}},getTotalEffortColumnTemplate:function(a,d,e){typeof d===c&&(d=1);return function(b){var g=b.ganttChartView;return DlhSoft.Controls.GanttChartView.timeSpanInputColumnTemplateBase(g.ownerDocument,a,function(){return g.getItemTotalEffort(b)},function(a){g.setItemTotalEffort(b,a);g.refreshItemPath(b)},d,function(){return!(b.isReadOnly||e||typeof b.ganttChartView!==c&&typeof b.ganttChartView.settings!== +c&&(b.ganttChartView.settings.isReadOnly||b.ganttChartView.settings.isGridReadOnly))&&!(b.hasChildren&&(typeof b.isSummaryEnabled===c||b.isSummaryEnabled))},function(){return!(b.isMilestone||typeof b.isBarVisible!==c&&!b.isBarVisible)},function(){return b.hasChildren&&(typeof b.isSummaryEnabled===c||b.isSummaryEnabled)})}},getCompletedEffortColumnTemplate:function(a,d,e){typeof d===c&&(d=1);return function(b){var g=b.ganttChartView;return DlhSoft.Controls.GanttChartView.timeSpanInputColumnTemplateBase(g.ownerDocument, +a,function(){return g.getItemCompletedEffort(b)},function(a){g.setItemCompletedEffort(b,a);g.refreshItemPath(b)},d,function(){return!(b.isReadOnly||e||typeof b.ganttChartView!==c&&typeof b.ganttChartView.settings!==c&&(b.ganttChartView.settings.isReadOnly||b.ganttChartView.settings.isGridReadOnly))&&!(b.hasChildren&&(typeof b.isSummaryEnabled===c||b.isSummaryEnabled))},function(){return!(b.isMilestone||typeof b.isBarVisible!==c&&!b.isBarVisible)},function(){return b.hasChildren&&(typeof b.isSummaryEnabled=== +c||b.isSummaryEnabled)})}},getTotalCompletedEffortColumnTemplate:function(a,d,e){typeof d===c&&(d=1);return function(b){var g=b.ganttChartView;return DlhSoft.Controls.GanttChartView.timeSpanInputColumnTemplateBase(g.ownerDocument,a,function(){return g.getItemTotalCompletedEffort(b)},function(a){g.setItemTotalCompletedEffort(b,a);g.refreshItemPath(b)},d,function(){return!(b.isReadOnly||e||typeof b.ganttChartView!==c&&typeof b.ganttChartView.settings!==c&&(b.ganttChartView.settings.isReadOnly||b.ganttChartView.settings.isGridReadOnly))&& +!(b.hasChildren&&(typeof b.isSummaryEnabled===c||b.isSummaryEnabled))},function(){return!(b.isMilestone||typeof b.isBarVisible!==c&&!b.isBarVisible)},function(){return b.hasChildren&&(typeof b.isSummaryEnabled===c||b.isSummaryEnabled)})}},getCompletionColumnTemplate:function(a,d){return function(e){var b=e.ganttChartView;return DlhSoft.Controls.GanttChartView.percentInputColumnTemplateBase(b.ownerDocument,a,function(){var a=b.getItemCompletion(e)*100;return Math.round(a*100)/100},function(a){if(typeof e.gridItem!== +c&&typeof e.completedInput!==c){var d=e.completedInput;typeof d.changeEventListener!==c&&d.removeEventListener("change",d.changeEventListener,true);delete e.completedInput}a=parseFloat(a)/100;b.setItemCompletion(e,a);b.refreshItemPath(e)},function(){return!(e.isReadOnly||d||typeof e.ganttChartView!==c&&typeof e.ganttChartView.settings!==c&&(e.ganttChartView.settings.isReadOnly||e.ganttChartView.settings.isGridReadOnly))&&!(e.hasChildren&&(typeof e.isSummaryEnabled===c||e.isSummaryEnabled))},function(){return!(e.isMilestone|| +typeof e.isBarVisible!==c&&!e.isBarVisible)},function(){return e.hasChildren&&(typeof e.isSummaryEnabled===c||e.isSummaryEnabled)})}},getCostColumnTemplate:function(a,d){return function(e){var b=e.ganttChartView;return DlhSoft.Controls.GanttChartView.numberInputColumnTemplateBase(b.ownerDocument,a,function(){return b.getItemCost(e)},function(a){b.setItemCost(e,a);b.refreshItemPath(e)},function(){return!(e.isReadOnly||d||typeof e.ganttChartView!==c&&typeof e.ganttChartView.settings!==c&&(e.ganttChartView.settings.isReadOnly|| +e.ganttChartView.settings.isGridReadOnly))},void 0,function(){return e.hasChildren&&(typeof e.isSummaryEnabled===c||e.isSummaryEnabled)})}},getPredecessorsColumnTemplate:function(a,d,e){return function(b){var g=b.ganttChartView;return DlhSoft.Controls.GanttChartView.textInputColumnTemplateBase(g.ownerDocument,a,function(){return g.getItemPredecessorsString(b,e)},function(a){g.setItemPredecessorsString(b,a,e);g.refreshItemGraph(b)},function(){return!(b.isReadOnly||d||typeof b.ganttChartView!==c&&typeof b.ganttChartView.settings!== +c&&(b.ganttChartView.settings.isReadOnly||b.ganttChartView.settings.isGridReadOnly))},function(){return!(typeof b.isBarVisible!==c&&!b.isBarVisible)},function(){return b.hasChildren&&(typeof b.isSummaryEnabled===c||b.isSummaryEnabled)})}},getAssignmentSelectorColumnTemplate:function(a,d,e){return function(b){var g=b.ganttChartView;return DlhSoft.Controls.GanttChartView.optionSelectColumnTemplateBase(g.ownerDocument,a,function(){return typeof d==="array"?d:d(b)},function(){return b.assignmentsContent}, +function(a){b.assignmentsContent=a;g.onItemPropertyChanged(b,"assignmentsContent",true,true);g.refreshItem(b)},function(){return!(b.isReadOnly||e||typeof b.ganttChartView!==c&&typeof b.ganttChartView.settings!==c&&(b.ganttChartView.settings.isReadOnly||b.ganttChartView.settings.isGridReadOnly))},function(){return!(typeof b.isBarVisible!==c&&!b.isBarVisible)},function(){return b.hasChildren&&(typeof b.isSummaryEnabled===c||b.isSummaryEnabled)})}},getBaselineStartColumnTemplate:function(a,d,e,b,g,f, +h,o){typeof d===c&&(d=true);typeof e===c&&(e=true);return function(j){var l=j.ganttChartView;return(d?e?DlhSoft.Controls.GanttChartView.dateTimePickerInputColumnTemplateBase:DlhSoft.Controls.GanttChartView.datePickerInputColumnTemplateBase:DlhSoft.Controls.GanttChartView.dateTimeInputColumnTemplateBase)(l.ownerDocument,a,function(){return j.baselineStart},function(a){a!=null?j.baselineStart=a:delete j.baselineStart;l.onItemPropertyChanged(j,"baselineStart",true,true);l.refreshItem(j)},function(){return!(j.isReadOnly|| +o||typeof j.ganttChartView!==c&&typeof j.ganttChartView.settings!==c&&(j.ganttChartView.settings.isReadOnly||j.ganttChartView.settings.isGridReadOnly))},function(){return!(typeof j.isBarVisible!==c&&!j.isBarVisible)},function(){return j.hasChildren&&(typeof j.isSummaryEnabled===c||j.isSummaryEnabled)},b,g,f,h)}},getBaselineFinishColumnTemplate:function(a,d,e,b,g,f,h,o){typeof d===c&&(d=true);typeof e===c&&(e=true);return function(j){var l=j.ganttChartView;return(d?e?DlhSoft.Controls.GanttChartView.dateTimePickerInputColumnTemplateBase: +DlhSoft.Controls.GanttChartView.datePickerInputColumnTemplateBase:DlhSoft.Controls.GanttChartView.dateTimeInputColumnTemplateBase)(l.ownerDocument,a,function(){return j.baselineFinish},function(a){a!=null?j.baselineFinish=a:delete j.baselineFinish;l.onItemPropertyChanged(j,"baselineFinish",true,true);l.refreshItem(j)},function(){return!(j.isReadOnly||o||typeof j.ganttChartView!==c&&typeof j.ganttChartView.settings!==c&&(j.ganttChartView.settings.isReadOnly||j.ganttChartView.settings.isGridReadOnly))}, +function(){return!(j.isMilestone||typeof j.isBarVisible!==c&&!j.isBarVisible)},function(){return j.hasChildren&&(typeof j.isSummaryEnabled===c||j.isSummaryEnabled)},b?b:864E5,g,f,h)}},getMinStartColumnTemplate:function(a,d,e,b,g,f,h,o){typeof d===c&&(d=true);typeof e===c&&(e=true);return function(j){var l=j.ganttChartView;return(d?e?DlhSoft.Controls.GanttChartView.dateTimePickerInputColumnTemplateBase:DlhSoft.Controls.GanttChartView.datePickerInputColumnTemplateBase:DlhSoft.Controls.GanttChartView.dateTimeInputColumnTemplateBase)(l.ownerDocument, +a,function(){return j.minStart},function(a){a!=null?j.minStart=a:delete j.minStart;l.onItemPropertyChanged(j,"minStart",true,true);l.refreshItem(j)},function(){return!(j.isReadOnly||o||typeof j.ganttChartView!==c&&typeof j.ganttChartView.settings!==c&&(j.ganttChartView.settings.isReadOnly||j.ganttChartView.settings.isGridReadOnly))&&!(j.hasChildren&&(typeof j.isSummaryEnabled===c||j.isSummaryEnabled))},function(){return!(typeof j.isBarVisible!==c&&!j.isBarVisible)},function(){return j.hasChildren&& +(typeof j.isSummaryEnabled===c||j.isSummaryEnabled)},b,g,f,h)}},getMaxStartColumnTemplate:function(a,d,e,b,g,f,h,o){typeof d===c&&(d=true);typeof e===c&&(e=true);return function(j){var l=j.ganttChartView;return(d?e?DlhSoft.Controls.GanttChartView.dateTimePickerInputColumnTemplateBase:DlhSoft.Controls.GanttChartView.datePickerInputColumnTemplateBase:DlhSoft.Controls.GanttChartView.dateTimeInputColumnTemplateBase)(l.ownerDocument,a,function(){return j.maxStart},function(a){a!=null?j.maxStart=a:delete j.maxStart; +l.onItemPropertyChanged(j,"maxStart",true,true);l.refreshItem(j)},function(){return!(j.isReadOnly||o||typeof j.ganttChartView!==c&&typeof j.ganttChartView.settings!==c&&(j.ganttChartView.settings.isReadOnly||j.ganttChartView.settings.isGridReadOnly))&&!(j.hasChildren&&(typeof j.isSummaryEnabled===c||j.isSummaryEnabled))},function(){return!(typeof j.isBarVisible!==c&&!j.isBarVisible)},function(){return j.hasChildren&&(typeof j.isSummaryEnabled===c||j.isSummaryEnabled)},b?b:864E5,g,f,h)}},getMinFinishColumnTemplate:function(a, +d,e,b,g,f,h,o){typeof d===c&&(d=true);typeof e===c&&(e=true);return function(j){var l=j.ganttChartView;return(d?e?DlhSoft.Controls.GanttChartView.dateTimePickerInputColumnTemplateBase:DlhSoft.Controls.GanttChartView.datePickerInputColumnTemplateBase:DlhSoft.Controls.GanttChartView.dateTimeInputColumnTemplateBase)(l.ownerDocument,a,function(){return j.minFinish},function(a){a!=null?j.minFinish=a:delete j.minFinish;l.onItemPropertyChanged(j,"minFinish",true,true);l.refreshItem(j)},function(){return!(j.isReadOnly|| +o||typeof j.ganttChartView!==c&&typeof j.ganttChartView.settings!==c&&(j.ganttChartView.settings.isReadOnly||j.ganttChartView.settings.isGridReadOnly))&&!(j.hasChildren&&(typeof j.isSummaryEnabled===c||j.isSummaryEnabled))},function(){return!(j.isMilestone||typeof j.isBarVisible!==c&&!j.isBarVisible)},function(){return j.hasChildren&&(typeof j.isSummaryEnabled===c||j.isSummaryEnabled)},b,g,f,h)}},getMaxFinishColumnTemplate:function(a,d,e,b,g,f,h,o){typeof d===c&&(d=true);typeof e===c&&(e=true);return function(j){var l= +j.ganttChartView;return(d?e?DlhSoft.Controls.GanttChartView.dateTimePickerInputColumnTemplateBase:DlhSoft.Controls.GanttChartView.datePickerInputColumnTemplateBase:DlhSoft.Controls.GanttChartView.dateTimeInputColumnTemplateBase)(l.ownerDocument,a,function(){return j.maxFinish},function(a){a!=null?j.maxFinish=a:delete j.maxFinish;l.onItemPropertyChanged(j,"maxFinish",true,true);l.refreshItem(j)},function(){return!(j.isReadOnly||o||typeof j.ganttChartView!==c&&typeof j.ganttChartView.settings!==c&& +(j.ganttChartView.settings.isReadOnly||j.ganttChartView.settings.isGridReadOnly))&&!(j.hasChildren&&(typeof j.isSummaryEnabled===c||j.isSummaryEnabled))},function(){return!(j.isMilestone||typeof j.isBarVisible!==c&&!j.isBarVisible)},function(){return j.hasChildren&&(typeof j.isSummaryEnabled===c||j.isSummaryEnabled)},b?b:864E5,g,f,h)}},getIconColumnTemplate:function(a,d,e,b,g,f,h,o,j){if(typeof a==="string")var l=a,a=function(){return l};typeof b===c||b==false?b=function(){return false}:b==true&& +(b=function(){return true});return function(l){var k=l.ganttChartView,r=k.ownerDocument.createElement("img");r.setAttribute("src",a(l));typeof d!==c&&r.setAttribute("class",d);typeof e!==c&&r.setAttribute("style",e);if(!k.settings.isReadOnly&&!k.settings.isGridReadOnly&&b(l)){r.style.cursor="move";Pc(r,l,k.items,k,k.settings,g,f,h,o,j)}return r}},getOutputDate:convertToLocalTimezone,getInputDate:convertToUTC}}()); +void 0==DlhSoft.Controls.ScheduleChartView&&(DlhSoft.Controls.ScheduleChartView=function(){var c=function(c,k,s,q){var v=["DlhSoft.Controls","ScheduleChartView","DlhSoft.ProjectData.GanttChart.HTML.Controls","5","validate","Licensing"];DlhSoft[v[5]][v[4]](c,v[0],v[1],v[2],v[3],q,s);c.isScheduleChartInitializing=true;for(var q=k,k=[],C=v=0,r=0;r =k.chartHeaderContainer.clientHeight+k.chartContentContainer.clientHeight-24){s=k.chartContentContainer.scrollTop;k.chartContentContainer.scrollTop=k.chartContentContainer.scrollTop+20;if(typeof k.isDuringVerticalScrolling==="undefined"){k.isDuringVerticalScrolling=true;setTimeout(function(){q=k.chartContentContainer.scrollTop- +s;k.draggingInitialThumbPosition=k.draggingInitialThumbPosition+q;delete k.isDuringVerticalScrolling},0)}}}},Z=function(c,k,s,q){var v=q.indexOf(c);if(!(v<0||k<0||k==v||k>=q.length)){q.splice(v,1);q.splice(k,0,c);N(s);typeof s.settings.itemMoveHandler!=="undefined"&&s.settings.itemMoveHandler(c,v,k)}},sa=function(c,k,s,q){for(var v=0;v s.length-r)){var v=[],x;for(x=k;x =s.length-1||Z(k,r+1,c,s)}},x=function(c,k){c.items=k;c.refresh=function(){N(c)}};return{initialize:c,refresh:N,getDefaultColumns:aa,getDefaultScales:DlhSoft.Controls.GanttChartView.getDefaultScales,getDefaultStyleDefinitionTemplate:DlhSoft.Controls.GanttChartView.getDefaultStyleDefinitionTemplate, +getDefaultStandardTaskTemplate:DlhSoft.Controls.GanttChartView.getDefaultStandardTaskTemplate,getDefaultMilestoneTaskTemplate:DlhSoft.Controls.GanttChartView.getDefaultMilestoneTaskTemplate,getDefaultItemTemplate:DlhSoft.Controls.GanttChartView.getDefaultItemTemplate,getDefaultAssignmentsTemplate:DlhSoft.Controls.GanttChartView.getDefaultAssignmentsTemplate,initializeTaskDraggingThumbs:DlhSoft.Controls.GanttChartView.initializeTaskDraggingThumbs,initializeDependencyDraggingThumb:DlhSoft.Controls.GanttChartView.initializeDependencyDraggingThumb, +initializeAssignmentDraggingThumb:function(c,k,s,q,v){s.scheduleChartView.initializeAssignmentDraggingThumb(c,k,s,q,v)},getWorkingTime:DlhSoft.Controls.GanttChartView.getWorkingTime,getEffort:DlhSoft.Controls.GanttChartView.getEffort,getFinish:DlhSoft.Controls.GanttChartView.getFinish,getStart:DlhSoft.Controls.GanttChartView.getStart,getCompletion:DlhSoft.Controls.GanttChartView.getCompletion,getCompletedFinish:DlhSoft.Controls.GanttChartView.getCompletedFinish,textColumnTemplateBase:DlhSoft.Controls.GanttChartView.textColumnTemplateBase, +textInputColumnTemplateBase:DlhSoft.Controls.GanttChartView.textInputColumnTemplateBase,getOutputDate:DlhSoft.Controls.GanttChartView.getOutputDate,getInputDate:DlhSoft.Controls.GanttChartView.getInputDate}}()); +void 0==DlhSoft.Controls.LoadChartView&&(DlhSoft.Controls.LoadChartView=function(){var c=function(c,o,k,s){var q=["DlhSoft.Controls","LoadChartView","DlhSoft.ProjectData.GanttChart.HTML.Controls","5","validate","Licensing"];DlhSoft[q[5]][q[4]](c,q[0],q[1],q[2],q[3],s,k);c.isLoadChartInitializing=true;for(var s=o,o=[],v=q=0,C=0;C 0;)c.chartItemArea.removeChild(c.chartItemArea.childNodes[r]);r=c.chartItemArea;var z=q.getChartPosition(c.start,v),q=Math.max(q.getChartPosition(c.finish,v),z+4),x=x.createElementNS("http://www.w3.org/2000/svg","rect"),A=typeof c.units!=="undefined"?c.units:1,B=Math.min(A,v.maxDisplayedUnits)/v.maxDisplayedUnits*v.barHeight;x.setAttribute("x",z);x.setAttribute("y",v.barMargin+(v.barHeight-B));x.setAttribute("width",Math.max(0,q-z-1));x.setAttribute("height", +B);z=A==1?v.normalAllocationBarClass:A<1?v.underAllocationBarClass:v.overAllocationBarClass;if(typeof c.allocationBarClass!=="undefined")z=c.allocationBarClass;if(typeof z!=="undefined")x.setAttribute("class",z);else{v=A==1?v.normalAllocationBarStyle:A<1?v.underAllocationBarStyle:v.overAllocationBarStyle;if(typeof c.allocationBarStyle!=="undefined")v=c.allocationBarStyle;typeof v!=="undefined"&&x.setAttribute("style",v)}r.appendChild(x);return r}},L=function(c,o,k,s){var q=s.indexOf(c);if(!(q<0|| +o<0||o==q||o>=s.length)){s.splice(q,1);s.splice(o,0,c);N(k);typeof k.settings.itemMoveHandler!=="undefined"&&k.settings.itemMoveHandler(c,q,o)}},Q=function(c,o){for(var k in o)k.indexOf("custom")!=0&&k.indexOf("description")!=0||typeof c[k]==="undefined"&&(c[k]=o[k])},V=function(c,o,k,s,q,v,C,r,z,A,B,I,M,K,L,N,E){var U,T=[],G;if(typeof s!=="undefined")for(U=0;U A)||typeof B.displayRowIndex==="undefined"&&(Z++ A+1))){E={content:B.content,indentation:B.indentation,start:B.start,finish:B.finish,units:B.units,isBarVisible:B.isBarVisible, +isRelativeToTimezone:B.isRelativeToTimezone,"class":B["class"],style:B.style,barClass:B.barClass,barStyle:B.barStyle,isSummaryEnabled:B.isSummaryEnabled,isParentSummarizationEnabled:B.isParentSummarizationEnabled,isHidden:B.isHidden,isExported:true,tag:B};if(typeof B.displayRowIndex!=="undefined")E.displayRowIndex=B.displayRowIndex-z;Q(E,B);c.push(E);B.exportItem=E}}var Ja=P.createElement("p");Ja.innerHTML=typeof o!=="undefined"?o:"";P.body.appendChild(Ja);var ca=P.createElement("div");ca.setAttribute("style", +"width: "+V+"px");try{DlhSoft.Controls.LoadChartView.initialize(ca,c,q,"DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.")}catch(Ha){}setTimeout(function(){aa&&P.body.setAttribute("style","margin: 0px");var c=P.createElement("div");c.appendChild(ca);P.body.replaceChild(c,Ja);if(M){c.setAttribute("style","width: "+ca.offsetHeight+"px; height: "+V+"px; overflow: hidden");c=Math.round((ca.offsetWidth-ca.offsetHeight)/ +2);ca.setAttribute("style","width: "+V+"px; transform: rotate(90deg) translateX("+c+"px) translateY("+c+"px); -webkit-transform: rotate(90deg) translateX("+c+"px) translateY("+c+"px)")}P.close();if(typeof W!==void 0){W.focus();if(typeof I!=="undefined"&&I){W.print();(typeof K==="undefined"||K)&&setTimeout(function(){W.close()})}}},0)},Z=function(c,o,k,s){for(var q=0;q k.length-q)){var s=[],A;for(A=o;A =k.length-1||L(o,q+1,c,k)}},sa=function(c,o,k){c.items=o;c.refresh=function(){N(c)};c.exportContent=function(s,q){typeof s==="undefined"&&(s={});V(s.title,s.preparingMessage,s.isGridVisible,s.columnIndexes,s.timelineStart,s.timelineFinish,s.isRelativeToTimezone, +s.hourWidth,s.startRowIndex,s.endRowIndex,q,false,s.rotate,false,c,o,k)};c.print=function(s){typeof s==="undefined"&&(s={});V(s.title,s.preparingMessage,s.isGridVisible,s.columnIndexes,s.timelineStart,s.timelineFinish,s.isRelativeToTimezone,s.hourWidth,s.startRowIndex,s.endRowIndex,null,true,s.rotate,s.autoClose,c,o,k)}};return{initialize:c,refresh:N,getDefaultColumns:aa,getDefaultScales:DlhSoft.Controls.GanttChartView.getDefaultScales,getDefaultAllocationTemplate:I,getDefaultItemTemplate:DlhSoft.Controls.GanttChartView.getDefaultItemTemplate, +getWorkingTime:DlhSoft.Controls.GanttChartView.getWorkingTime,textColumnTemplateBase:DlhSoft.Controls.GanttChartView.textColumnTemplateBase,textInputColumnTemplateBase:DlhSoft.Controls.GanttChartView.textInputColumnTemplateBase,getOutputDate:DlhSoft.Controls.GanttChartView.getOutputDate,getInputDate:DlhSoft.Controls.GanttChartView.getInputDate}}()); diff --git a/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.React.Components.jsx b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.React.Components.jsx new file mode 100644 index 000000000..c4d92b593 --- /dev/null +++ b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.React.Components.jsx @@ -0,0 +1,53 @@ +import React from 'react'; +const DlhSoft = window.DlhSoft; + +export var GanttChartView = React.forwardRef(function(props, ref) { + if (!ref) ref = React.createRef(); + var element = {props.children}; + var changeHandler = props.settings.itemPropertyChangeHandler; + setTimeout(function() { + DlhSoft.Controls.GanttChartView.initialize(ref.current, props.items, props.settings, props.license); + if (props.change) { + props.settings.itemPropertyChangeHandler = function(item, propertyName, isDirect, isFinal) { + if (changeHandler) + changeHandler(item, propertyName, isDirect, isFinal); + props.change(item, propertyName, isDirect, isFinal); + } + } + }); + return element; +}); + +export var ScheduleChartView = React.forwardRef(function(props, ref) { + if (!ref) ref = React.createRef(); + var element ={props.children}; + var changeHandler = props.settings.itemPropertyChangeHandler; + setTimeout(function() { + DlhSoft.Controls.ScheduleChartView.initialize(ref.current, props.items, props.settings, props.license); + if (props.change) { + props.settings.itemPropertyChangeHandler = function(item, propertyName, isDirect, isFinal) { + if (changeHandler) + changeHandler(item, propertyName, isDirect, isFinal); + props.change(item, propertyName, isDirect, isFinal); + } + } + }); + return element; +}); + +export var LoadChartView = React.forwardRef(function(props, ref) { + if (!ref) ref = React.createRef(); + var element ={props.children}; + var changeHandler = props.settings.itemPropertyChangeHandler; + setTimeout(function() { + DlhSoft.Controls.LoadChartView.initialize(ref.current, props.items, props.settings, props.license); + if (props.change) { + props.settings.itemPropertyChangeHandler = function(item, propertyName, isDirect, isFinal) { + if (changeHandler) + changeHandler(item, propertyName, isDirect, isFinal); + props.change(item, propertyName, isDirect, isFinal); + } + } + }); + return element; +}); diff --git a/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.Vue.Components.js b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.Vue.Components.js new file mode 100644 index 000000000..1bc21f052 --- /dev/null +++ b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.GanttChart.Vue.Components.js @@ -0,0 +1,44 @@ +Vue.component('gantt-chart', { + template: '', + props: ['items', 'settings', 'license'], + mounted: function() { + var vm = this; + var changeHandler = vm.settings.itemPropertyChangeHandler; + DlhSoft.Controls.GanttChartView.initialize(vm.$el, vm.items, vm.settings, vm.license); + vm.settings.itemPropertyChangeHandler = function(item, propertyName, isDirect, isFinal) { + if (changeHandler) + changeHandler(item, propertyName, isDirect, isFinal); + vm.$emit('change', {item: item, propertyName: propertyName, isDirect: isDirect, isFinal: isFinal}); + } + } +}); + +Vue.component('schedule-chart', { + template: '', + props: ['items', 'settings', 'license'], + mounted: function() { + var vm = this; + var changeHandler = vm.settings.itemPropertyChangeHandler; + DlhSoft.Controls.ScheduleChartView.initialize(vm.$el, vm.items, vm.settings, vm.license); + vm.settings.itemPropertyChangeHandler = function(item, propertyName, isDirect, isFinal) { + if (changeHandler) + changeHandler(item, propertyName, isDirect, isFinal); + vm.$emit('change', {item: item, propertyName: propertyName, isDirect: isDirect, isFinal: isFinal}); + } + } +}); + +Vue.component('load-chart', { + template: '', + props: ['items', 'settings', 'license'], + mounted: function() { + var vm = this; + var changeHandler = vm.settings.itemPropertyChangeHandler; + DlhSoft.Controls.LoadChartView.initialize(vm.$el, vm.items, vm.settings, vm.license); + vm.settings.itemPropertyChangeHandler = function(item, propertyName, isDirect, isFinal) { + if (changeHandler) + changeHandler(item, propertyName, isDirect, isFinal); + vm.$emit('change', {item: item, propertyName: propertyName, isDirect: isDirect, isFinal: isFinal}); + } + } +}); diff --git a/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.PertChart.Angular.Components.ts b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.PertChart.Angular.Components.ts new file mode 100644 index 000000000..2b82c0a26 --- /dev/null +++ b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.PertChart.Angular.Components.ts @@ -0,0 +1,63 @@ +import { Component, OnInit, ElementRef, Input } from '@angular/core'; +import PertChartItem = DlhSoft.Controls.Pert.PertChartView.Item; +import PertChartSettings = DlhSoft.Controls.Pert.PertChartView.Settings; +import NetworkDiagramItem = DlhSoft.Controls.Pert.NetworkDiagramView.Item; +import NetworkDiagramSettings = DlhSoft.Controls.Pert.NetworkDiagramView.Settings; + +@Component({ + selector: 'pertchartview', + template: '' +}) +export class PertChartView implements OnInit { + rootElement: HTMLElement; + @Input() style: string = ""; + @Input() items: PertChartItem[] = []; + @Input() settings: PertChartSettings = {}; + @Input() license: string; + @Input() change: (item: PertChartItem, propertyName: string, isDirect: boolean, isFinal: boolean) => void; + constructor(elementRef: ElementRef) { + this.rootElement =elementRef.nativeElement; + } + ngOnInit() { + var element = this.rootElement.firstChild; + element.setAttribute('style', this.style); + var changeHandler = this.settings.itemPropertyChangeHandler; + DlhSoft.Controls.Pert.PertChartView.initialize(element, this.items, this.settings, this.license); + if (this.change) { + this.settings.itemPropertyChangeHandler = (item, propertyName, isDirect, isFinal) => { + if (changeHandler) + changeHandler(item, propertyName, isDirect, isFinal); + this.change(item, propertyName, isDirect, isFinal); + } + } + } +} + +@Component({ + selector: 'networkdiagramview', + template: ' ' + }) + export class NetworkDiagramView implements OnInit { + rootElement: HTMLElement; + @Input() style: string = ""; + @Input() items: NetworkDiagramItem[] = []; + @Input() settings: NetworkDiagramSettings = {}; + @Input() license: string; + @Input() change: (item: NetworkDiagramItem, propertyName: string, isDirect: boolean, isFinal: boolean) => void; + constructor(elementRef: ElementRef) { + this.rootElement =elementRef.nativeElement; + } + ngOnInit() { + var element = this.rootElement.firstChild; + element.setAttribute('style', this.style); + var changeHandler = this.settings.itemPropertyChangeHandler; + DlhSoft.Controls.Pert.NetworkDiagramView.initialize(element, this.items, this.settings, this.license); + if (this.change) { + this.settings.itemPropertyChangeHandler = (item, propertyName, isDirect, isFinal) => { + if (changeHandler) + changeHandler(item, propertyName, isDirect, isFinal); + this.change(item, propertyName, isDirect, isFinal); + } + } + } + } diff --git a/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.PertChart.Angular.Directives.js b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.PertChart.Angular.Directives.js new file mode 100644 index 000000000..74e85667a --- /dev/null +++ b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.PertChart.Angular.Directives.js @@ -0,0 +1,59 @@ +// Version 1.0.0.0. +var module = angular.module("DlhSoft.ProjectData.PertChart.Directives", []); +dsDefinePDPCDirective(module, "PertChart"); +dsDefinePDPCDirective(module, "NetworkDiagram"); +function dsDefinePDPCDirective(module, directiveName, controlName) { + module.directive("ds" + directiveName, function () { + return { + restrict: "EAC", + replace: true, + transclude: true, + scope: { + items: "=", + settings: "=", + change: "=", + autoRefresh: "@", + license: "=" + }, + template: " ", + link: function (scope, element) { + var controlElement = element[0]; + var initialization = function () { + var items = scope.items; + if (!items) + items = []; + var settings = scope.settings; + if (!settings) + settings = {}; + var license = scope.license; + var changeHandler = settings.itemPropertyChangeHandler; + DlhSoft.Controls.Pert[controlName ? controlName : directiveName + "View"].initialize(controlElement, items, settings, license); + if (scope.change) { + settings.itemPropertyChangeHandler = function (item, propertyName, isDirect, isFinal) { + if (changeHandler) + changeHandler(item, propertyName, isDirect, isFinal); + scope.change(item, propertyName, isDirect, isFinal); + } + } + } + initialization(); + var isWaitingToRefresh = false; + var refresh = function () { + if (isWaitingToRefresh) + return; + isWaitingToRefresh = true; + setTimeout(function () { + initialization(); + isWaitingToRefresh = false; + }); + } + setTimeout(function () { + scope.$watch("items", refresh); + scope.$watch("settings", refresh); + if (scope.autoRefresh == "true") + scope.$watch(refresh); + }, 0); + } + }; + }); +} diff --git a/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.PertChart.HTML.Controls.d.ts b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.PertChart.HTML.Controls.d.ts new file mode 100644 index 000000000..74174483f --- /dev/null +++ b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.PertChart.HTML.Controls.d.ts @@ -0,0 +1,351 @@ +/* Assembly: DlhSoft.ProjectData.PertChart.HTML.Controls, + Company: DlhSoft, + Product: Project Data Modern Library, + Version: 5.3.1.0, + Copyright: Copyright © 2012-2016 DlhSoft, + Title: Project Data PERT Chart HTML Controls, + Description: Project Data PERT Chart related HTML client components */ + +/* +///+*/ + +declare module DlhSoft.Controls.Pert { + /** Represents a control that presents task event data items using a PERT Chart. */ + module PertChartView { + /** + * Initializes a PertChartView component instance. + * @param element The HTMLElement that would host the user interface of the component. + * @param items Task event data objects to be managed and presented by the component. + * @param settings Configuration settings for the component behavior and appearance. + */ + function initialize(element: HTMLElement, items: Item[], settings?: Settings, license?: String): Element; + + function getDefaultStyleDefinitionTemplate(controlElement: Element, settings: Settings): () => SVGDefsElement; + function getDefaultTaskEventTemplate(items: Item[], controlElement: Element, settings: Settings): (item: Item) => SVGElement; + function getDefaultItemTemplate(settings: Settings): (item: Item) => SVGElement; + function getDefaultDependencyLineTemplate(items: Item[], settings: Settings): (item: Item, predecessorItem: PredecessorItem) => SVGElement; + function getDefaultPredecessorItemTemplate(settings: Settings): (item: Item, predecessorItem: PredecessorItem) => SVGElement; + + /** Inside task event template functions, sets up task event drag and drop behavior for the non-null SVG element specified to be designed as thumb, considering the specified item and item positioning in the chart. */ + function initializeTaskEventDraggingThumbs(thumb: SVGElement, item: Item, itemLeft: number, itemTop: number): void; + + function defaultTimeSpanFormatter(timeSpan: number): string; + + /** Represents an HTML element that supplementary provides PertChartView component services. */ + interface Element extends HTMLElement { + items: Item[]; + settings: Settings; + + /** Updates the user interface considering all external item and settings changes. */ + refresh(): void; + + refreshItems(): void; refreshItem(item: Item): void; refreshPredecessorItems(item: Item): void; refreshItemGraph(item: Item): void; + + scrollToItem(item: Item): void; scrollToLeft(): void; scrollToTop(): void; scrollToRight(): void; scrollToBottom(): void; + + /** Returns the actual width of the chart area. */ + getChartWidth(): number; + /** Returns the actual height of the chart area. */ + getChartHeight(): number; + + getItemLeft(item: Item): number; + getItemTop(item: Item): number; + + /** Calls itemPropertyChangeHandler function specified within the settings collection using the specified item, property name, and Boolean indicators for direct user actions and completed actions as arguments. */ + onItemPropertyChanged(item: Item, propertyName: string, isDirect: boolean, isFinal: boolean): void; + + /** Exports the content to the specified output document. */ + exportContent(exportSettings: ExportSettings, output: HTMLDocument): void; + /** Exports the content to the document of the specified output window. */ + exportContent(exportSettings: ExportSettings, output: Window): void; + /** Exports the content to the specified target or using a temporary document and window. */ + exportContent(exportSettings?: ExportSettings, output?: string): void; + /** Prints the content using a temporary document and window. */ + print(exportSettings?: ExportSettings): void; + + isItemCritical(item: Item): boolean; getCriticalItems(): Item[]; + isDependencyCritical(predecessorItem: PredecessorItem): boolean; getCriticalDependencies(): PredecessorItem[]; + + /** Updates the vertical position of start and finish nodes, assuming they are the first and the last items in the collection, to the first or between the first and second row in the view (when there is at least one item with two or more successors in the collection). */ + repositionEnds(): void; + + isInitializing: boolean; isInitialized: boolean; + } + + /** Represents a task event data item and its PERT Chart representation. */ + interface Item { + /** The object that is displayed to represent the task event item in the task event shape tool tips, usually the task event name. */ + content: any; + + /** The object that is displayed to represent the task event item in the task event shape, usually a short task event name or identifier. */ + displayedText: any; + + isShapeVisible?: boolean; + + displayRowIndex?: number; displayColumnIndex?: number; + + shapeClass?: string; shapeStyle?: string; + taskEventTemplate? (item: Item): SVGElement; + template? (item: Item): SVGElement; + + /** The predecessors collection defines predecessor items (objects) representing the tasks displayed in the PERT Chart view as dependency lines. */ + predecessors?: PredecessorItem[]; + } + + /** Represents a depdendency between two task event data items and its PERT Chart representation. */ + interface PredecessorItem { + /** Task event item that precedes the owner of the predecessor item (the item that the current item depends of). */ + item: Item; + + /** The object that is displayed to represent the task item in the dependency line tool tips, usually the task name. */ + content?: any; + + /** The object that is displayed to represent the task item on the dependency line, usually a short task name or identifier. */ + displayedText?: any; + + effort?: number; isEffortVirtual?: boolean; + + dependencyLineClass?: string; dependencyLineStyle?: string; dependencyTextClass?: string; dependencyTextStyle?: string; + template? (item: Item, predecessorItem: PredecessorItem): SVGElement; + } + + /** Represents settings for a PertChartView component. */ + interface Settings { + /** Name of the target to generically apply to the control; Standard, and Phone targets are supported; by default it is Standard. */ + target?: string; + + /** Name of the theme to generically apply to the control; Modern, ModernBordered, and Aero themes are supported; by default it is Modern. */ + theme?: string; + + border?: string; + containerClass?: string; containerStyle?: string; + + /** Indicates whether the user can change the canvas positions of task event items in the control by drag and drop operations (by default it is set to true). */ + canUserRearrangeItems?: boolean; + + /** Indicates whether the task event item shapes are snapping to row and column based guidelines in the control during drag and drop based rearrange operations (by default it is set to true). */ + snapRearrangedItemsToGuidelines?: boolean; + + chartMargin?: number; + itemWidth?: number; itemHeight?: number; + + /** The aspect ratio of the chart, indicating the rate between horizontal and vertical item layout positioning. */ + aspectRatio?: number; + + shapeWidth?: number; shapeHeight?: number; + dependencyTextBlockWidth?: number; + + styleDefinitionTemplate? (): SVGDefsElement; + shapeClass?: string; shapeStyle?: string; dependencyTextClass?: string; dependencyTextStyle?: string; + temporaryThumbClass?: string; temporaryThumbStyle?: string; + dependencyLineClass?: string; dependencyLineStyle?: string; + + taskEventTemplate? (item: Item): SVGElement; + extraTaskEventTemplate? (item: Item): SVGElement; + + isTaskEventToolTipVisible?: boolean; + itemTemplate? (item: Item): SVGElement; + + dependencyLineTemplate? (item: Item, predecessorItem: PredecessorItem): SVGElement; + + isDependencyToolTipVisible?: boolean; + predecessorItemTemplate? (item: Item, predecessorItem: PredecessorItem): SVGElement; + + /** Converts time span values to text values whenever needed within the control; the function may be provided by the developer for further customization and/or localization purposes. */ + timeSpanFormatter? (timeSpan: number): string; + + /** Function called whenever item properties change within the control, providing the changed item, relevant property name, and Boolean values indicating whether this change was directly triggered by the user, and whether this is the final change in a periodic operation such as a drag and drop action, specified as parameters; a custom function may be provided by the developer in order to receive notifications whenever data changes occur within the control. */ + itemPropertyChangeHandler? (item: Item, propertyName: string, isDirect: boolean, isFinal: boolean): void; + + mouseHandler? (eventName: string, item: Item, button: number, clickCount: number, e: MouseEvent): void; + mouseMoveHandler? (item: Item): void; + mouseDownHandler? (item: Item, button: number): void; + itemClickHandler? (item: Item): void; + itemDoubleClickHandler? (item: Item): void; + dependencyLineClickHandler? (predecessorItem: PredecessorItem, targetItem: Item, e: MouseEvent): void; + dependencyLineDoubleClickHandler?(predecessorItem: PredecessorItem, targetItem: Item, e: MouseEvent): void; + } + + /** Represents export settings for a PertChartView component. */ + interface ExportSettings { + title?: string; preparingMessage?: string; + rotate?: boolean; + autoClose?: boolean; + } + } + + /** Represents a control that presents task data items using a Network Diagram. */ + module NetworkDiagramView { + /** + * Initializes a NetworkDiagramView component instance. + * @param element The HTMLElement that would host the user interface of the component. + * @param items Task data objects to be managed and presented by the component. + * @param settings Configuration settings for the component behavior and appearance. + */ + function initialize(element: HTMLElement, items: Item[], settings?: Settings, license?: String): Element; + + function getDefaultStyleDefinitionTemplate(controlElement: Element, settings: Settings): () => SVGDefsElement; + function getDefaultTaskTemplate(items: Item[], controlElement: Element, settings: Settings): (item: Item) => SVGElement; + function getDefaultItemTemplate(settings: Settings): (item: Item) => SVGElement; + function getDefaultDependencyLineTemplate(items: Item[], settings: Settings): (item: Item, predecessorItem: PredecessorItem) => SVGElement; + function getDefaultPredecessorItemTemplate(settings: Settings): (item: Item, predecessorItem: PredecessorItem) => SVGElement; + + /** Inside task template functions, sets up task drag and drop behavior for the non-null SVG element specified to be designed as thumb, considering the specified item and item positioning in the diagram. */ + function initializeTaskDraggingThumbs(thumb: SVGElement, item: Item, itemLeft: number, itemTop: number): void; + + function defaultDateTimeFormatter(date: Date): string; + function defaultTimeSpanFormatter(timeSpan: number): string; + + /** Prepares the specified date values to be used for component method input, considering that after initialization the component uses UTC date and time values internally; this method may also be called using a component instance object. */ + function getInputDate(date: Date): Date; + /** Prepares the specified date values to be used for component method result or field output, considering that after initialization the component uses UTC date and time values internally; this method may also be called using a component instance object. */ + function getOutputDate(date: Date): Date; + + /** Represents an HTML element that supplementary provides NetworkDiagramView component services. */ + interface Element extends HTMLElement { + items: Item[]; + settings: Settings; + + /** Updates the user interface considering all external item and settings changes. */ + refresh(): void; + + refreshItems(): void; refreshItem(item: Item): void; refreshPredecessorItems(item: Item): void; refreshItemGraph(item: Item): void; + + scrollToItem(item: Item): void; scrollToLeft(): void; scrollToTop(): void; scrollToRight(): void; scrollToBottom(): void; + + /** Returns the actual width of the diagram area. */ + getChartWidth(): number; + /** Returns the actual height of the diagram area. */ + getChartHeight(): number; + + getItemLeft(item: Item): number; + getItemTop(item: Item): number; + + /** Calls itemPropertyChangeHandler function specified within the settings collection using the specified item, property name, and Boolean indicators for direct user actions and completed actions as arguments. */ + onItemPropertyChanged(item: Item, propertyName: string, isDirect: boolean, isFinal: boolean): void; + + /** Exports the content to the specified output document. */ + exportContent(exportSettings: ExportSettings, output: HTMLDocument): void; + /** Exports the content to the document of the specified output window. */ + exportContent(exportSettings: ExportSettings, output: Window): void; + /** Exports the content to the specified target or using a temporary document and window. */ + exportContent(exportSettings?: ExportSettings, output?: string): void; + /** Prints the content using a temporary document and window. */ + print(exportSettings?: ExportSettings): void; + + isItemCritical(item: Item): boolean; getCriticalItems(): Item[]; + isDependencyCritical(predecessorItem: PredecessorItem): boolean; getCriticalDependencies(): PredecessorItem[]; + + /** Updates the vertical position of start and finish nodes, assuming they are the first and the last items in the collection, to the first or between the first and second row in the view (when there is at least one item with two or more successors in the collection). */ + repositionEnds(): void; + + isInitializing: boolean; isInitialized: boolean; + } + + /** Represents a task data item and its Network Diagram representation. */ + interface Item { + /** The object that is displayed to represent the task item in the task shape tool tips, usually the full task name and path. */ + content: any; + + /** The object that is displayed to represent the task item in the task shape, usually a short task name or identifier. */ + displayedText: any; + + effort: number; earlyStart: Date; earlyFinish: Date; lateStart: Date; lateFinish: Date; + + /** A milestone task is displayed in the Network Diagram view using a supplemental task shape template. */ + isMilestone?: boolean; + + slack: number; + + isRelativeToTimezone?: boolean; + + isShapeVisible?: boolean; + + displayRowIndex?: number; displayColumnIndex?: number; + + shapeClass?: string; milestoneClass?: string; shapeStyle?: string; milestoneStyle?: string; + taskTemplate? (item: Item): SVGElement; + template? (item: Item): SVGElement; + + /** The predecessors collection defines predecessor items (objects) referring the task items that the current item depends of, and having the relations displayed in the Network Diagram view as dependency lines. */ + predecessors?: PredecessorItem[]; + } + + /** Represents a depdendency between two task data items and its Network Diagram representation. */ + interface PredecessorItem { + /** Task item that precedes the owner of the predecessor item (the item that the current item depends of). */ + item: Item; + + dependencyLineClass?: string; dependencyLineStyle?: string; + template? (item: Item, predecessorItem: PredecessorItem): SVGElement; + } + + /** Represents settings for a NetworkDiagramView component. */ + interface Settings { + /** Name of the target to generically apply to the control; Standard, and Phone targets are supported; by default it is Standard. */ + target?: string; + + /** Name of the theme to generically apply to the control; Modern, ModernBordered, and Aero themes are supported; by default it is Modern. */ + theme?: string; + + border?: string; + containerClass?: string; containerStyle?: string; + + /** Indicates whether the user can change the canvas positions of task items in the control by drag and drop operations (by default it is set to true). */ + canUserRearrangeItems?: boolean; + + /** Indicates whether the task item shapes are snapping to row and column based guidelines in the control during drag and drop based rearrange operations (by default it is set to true). */ + snapRearrangedItemsToGuidelines?: boolean; + + diagramMargin?: number; + itemWidth?: number; itemHeight?: number; + + /** The aspect ratio of the diagram, indicating the rate between horizontal and vertical item layout positioning. */ + aspectRatio?: number; + + shapeWidth?: number; shapeHeight?: number; + minDependencyLineLength?: number; + + styleDefinitionTemplate? (): SVGDefsElement; + shapeClass?: string; milestoneClass?: string; shapeStyle?: string; milestoneStyle?: string; + temporaryThumbClass?: string; temporaryThumbStyle?: string; + dependencyLineClass?: string; dependencyLineStyle?: string; + + taskTemplate? (item: Item): SVGElement; + extraTaskTemplate? (item: Item): SVGElement; + + isTaskToolTipVisible?: boolean; + itemTemplate? (item: Item): SVGElement; + + dependencyLineTemplate? (item: Item, predecessorItem: PredecessorItem): SVGElement; + + isDependencyToolTipVisible?: boolean; + predecessorItemTemplate? (item: Item, predecessorItem: PredecessorItem): SVGElement; + + /** Converts date and time values to text values whenever needed within the control; the function may be provided by the developer for further customization and/or localization purposes. */ + dateTimeFormatter? (dateTime: Date): string; + + /** Converts time span values to text values whenever needed within the control; the function may be provided by the developer for further customization and/or localization purposes. */ + timeSpanFormatter? (timeSpan: number): string; + + /** Function called whenever item properties change within the control, providing the changed item, relevant property name, and Boolean values indicating whether this change was directly triggered by the user, and whether this is the final change in a periodic operation such as a drag and drop action, specified as parameters; a custom function may be provided by the developer in order to receive notifications whenever data changes occur within the control. */ + itemPropertyChangeHandler? (item: Item, propertyName: string, isDirect: boolean, isFinal: boolean): void; + + mouseHandler? (eventName: string, item: Item, button: number, clickCount: number, e: MouseEvent): void; + mouseMoveHandler? (item: Item): void; + mouseDownHandler? (item: Item, button: number): void; + itemClickHandler? (item: Item): void; + itemDoubleClickHandler? (item: Item): void; + dependencyLineClickHandler? (predecessorItem: PredecessorItem, targetItem: Item, e: MouseEvent): void; + dependencyLineDoubleClickHandler?(predecessorItem: PredecessorItem, targetItem: Item, e: MouseEvent): void; + } + + /** Represents export settings for a NetworkDiagramView component. */ + interface ExportSettings { + title?: string; preparingMessage?: string; + rotate?: boolean; + autoClose?: boolean; + } + } +} diff --git a/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.PertChart.HTML.Controls.js b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.PertChart.HTML.Controls.js new file mode 100644 index 000000000..2ef8f5e8b --- /dev/null +++ b/GanttChartHyperLibraryDemos/Demos/Samples/JavaScript/GanttChartView/SummaryBackgroundColors/Scripts/DlhSoft.ProjectData.PertChart.HTML.Controls.js @@ -0,0 +1,150 @@ +var DlhSoft;"undefined"===typeof DlhSoft&&(DlhSoft={assemblies:[],buildReleaseDate:new Date(1,0,1)});DlhSoft.assemblies.push({assembly:"DlhSoft.ProjectData.PertChart.HTML.Controls",company:"DlhSoft",product:"Project Data Modern Library",version:"5.3.17.0",copyright:"Copyright \u00a9 2012-2020 DlhSoft",title:"Project Data PERT Chart HTML Controls",description:"Project Data PERT Chart related HTML client components"}); +DlhSoft.buildReleaseDate=function(L,M,O){L=new Date(L,M-1,O);return L>DlhSoft.buildReleaseDate?L:DlhSoft.buildReleaseDate}(2020,11,25);var _0x5c25="Licensing{undefined{string{DlhSoft.Controls: DlhSoft internal usage only. Customers may purchase standard product usage licenses from http://DlhSoft.com/Purchase.{.{length{license{push{type{content{:{lastIndexOf{substr{buildReleaseDate{charCodeAt{pow{toUpperCase{DlhSoft Component Licensing Warning{http://DlhSoft.com/Purchase.aspx{?Assemblies={,{http://www.componentsource.com/features/dlhsoft{ (version {){This component is currently licensed to be used for testing purposes only{The component is part of this assembly{To purchase a standard license for a product that includes this assembly you can use the Purchase page{ownerDocument{div{createElement{style{position: absolute; left: 24px; top: 24px; width: 480px; display: block; z-index: 1; color: Black; background-color: #ffffc0; border: solid 1px Blue; overflow: auto{setAttribute{padding: 6px; padding-top: 8px; font-family: Arial; font-size: small{font-weight: bold; margin-bottom: 4px{appendChild{createTextNode{color: Red; margin-top: 2px; margin-bottom: 2px{margin-top: 4px{a{color: Blue; text-decoration: underline{href{target{_blank{Purchase license{margin-left: 4px; color: Blue; text-decoration: underline{javascript://{Continue trial{click{removeChild{addEventListener{\n\n{: {:\n".split("{"); +void 0==DlhSoft[_0x5c25[0]]&&(DlhSoft[_0x5c25[0]]=function(){var L=_0x5c25[1],M=_0x5c25[2],O=[],T=[],U=_0x5c25[3],Z=function(I,D){if(typeof I!==M||typeof D!==M)return!1;if(D==U)return!0;var J=D[_0x5c25[11]](_0x5c25[10]);if(0<=J){var w=D[_0x5c25[12]](0,J),y,C=w[_0x5c25[11]](_0x5c25[10]);if(0<=C)try{y=new Date(parseInt(w[_0x5c25[12]](C+1)))}catch(x){}typeof y===L&&(y=new Date(2013,11,31));if(DlhSoft[_0x5c25[13]]>y)return!1;w=w+_0x5c25[10]+I;for(i=y=0;i y&&(y=Math[_0x5c25[15]](2,32)-y);w=y.toString(16)[_0x5c25[16]]();J=D[_0x5c25[12]](J+1);if(w==J)return!0}return!1},P=function(I,D,J,w,y){var C=_0x5c25[17],x=_0x5c25[18],K=typeof ComponentSource===L||!ComponentSource?x+_0x5c25[19]+w+_0x5c25[20]+y:_0x5c25[21],E=w+_0x5c25[22]+y+_0x5c25[23],G=_0x5c25[24],F=_0x5c25[25],H=_0x5c25[26];setTimeout(function(){var A=I[_0x5c25[27]],y=A[_0x5c25[29]](_0x5c25[28]);y[_0x5c25[32]](_0x5c25[30],_0x5c25[31]);var w=A[_0x5c25[29]](_0x5c25[28]);w[_0x5c25[32]](_0x5c25[30], +_0x5c25[33]);var B=A[_0x5c25[29]](_0x5c25[28]);B[_0x5c25[32]](_0x5c25[30],_0x5c25[34]);w[_0x5c25[35]](B);B[_0x5c25[35]](A[_0x5c25[36]](C));w[_0x5c25[35]](A[_0x5c25[36]](G+_0x5c25[10]));B=A[_0x5c25[29]](_0x5c25[28]);B[_0x5c25[32]](_0x5c25[30],_0x5c25[37]);B[_0x5c25[35]](A[_0x5c25[36]](D));w[_0x5c25[35]](B);w[_0x5c25[35]](A[_0x5c25[36]](F+_0x5c25[10]));B=A[_0x5c25[29]](_0x5c25[28]);B[_0x5c25[32]](_0x5c25[30],_0x5c25[37]);B[_0x5c25[35]](A[_0x5c25[36]](E));w[_0x5c25[35]](B);w[_0x5c25[35]](A[_0x5c25[36]](H+ +_0x5c25[10]));B=A[_0x5c25[29]](_0x5c25[28]);B[_0x5c25[32]](_0x5c25[30],_0x5c25[38]);var x=A[_0x5c25[29]](_0x5c25[39]);x[_0x5c25[32]](_0x5c25[30],_0x5c25[40]);x[_0x5c25[32]](_0x5c25[41],K);x[_0x5c25[32]](_0x5c25[42],_0x5c25[43]);x[_0x5c25[35]](A[_0x5c25[36]](_0x5c25[44]));B[_0x5c25[35]](x);x=A[_0x5c25[29]](_0x5c25[39]);x[_0x5c25[32]](_0x5c25[30],_0x5c25[45]);x[_0x5c25[32]](_0x5c25[41],_0x5c25[46]);x[_0x5c25[35]](A[_0x5c25[36]](_0x5c25[47]));x[_0x5c25[50]](_0x5c25[48],function(){I[_0x5c25[49]](y);T[_0x5c25[7]](J)}, +!1);B[_0x5c25[35]](x);w[_0x5c25[35]](B);y[_0x5c25[35]](w);I[_0x5c25[35]](y)},0);setTimeout(function(){alert(C+_0x5c25[51]+G+_0x5c25[52]+D+_0x5c25[51]+F+_0x5c25[53]+E+_0x5c25[51]+H+_0x5c25[4])},6E5)};return{setLicense:function(I,D){O[_0x5c25[7]]({type:I,content:D})},validate:function(I,D,J,w,y,C,x){for(var D=D+_0x5c25[4]+J,K=0;K 0?a.insertBefore(h,a.childNodes[0]):a.appendChild(h)}catch(c){}},0)};h.addEventListener("mousedown",c,true);l.addEventListener("mouseup",c,true);s.appendChild(h);s.chartArea=h;var u;setTimeout(function(){u=b.clientHeight},0);typeof b.heightUpdateTimer!=="undefined"&&clearInterval(b.heightUpdateTimer); +b.heightUpdateTimer=setInterval(function(){try{if(!(b.clientHeight<=0)){var a=b.clientHeight;if(a!=u){var h=J(b,f,d);g.style.height=h;u=a}}}catch(c){try{clearInterval(b.heightUpdateTimer)}catch(l){}}},100);var k=function(a,h,c,g){var b;if(d.mouseHandler||d.mouseMoveHandler&&g=="mousemove"||d.mouseDownHandler&&g=="mousedown"||d.clickHandler&&g=="click"||d.doubleClickHandler&&g=="dblclick"){var j=a.which;!j&&a.button&&(a.button&1?j=1:a.button&4?j=2:a.button&2&&(j=3));b=c.getBoundingClientRect();var e= +l.body,s=l.documentElement,c=b.left+(window.pageXOffset||s.scrollLeft||e.scrollLeft)-(s.clientLeft||e.clientLeft||0);b=Math.round(b.top+(window.pageYOffset||s.scrollTop||e.scrollTop)-(s.clientTop||e.clientTop||0));c=Math.round(c);c=a.pageX-c;b=a.pageY-b;for(e=0;e =k&&c =u&&b=0&&h 0?R(h):e.maxRowIndex!=null?e.maxRowIndex+1:0;l=l=void 0;if(typeof d.displayedColumnIndex==="undefined"){l=P(e.positionedItems,h);l=l.length>0?R(l)+1:0;c=a!=null?P(a,h):null;if(c!=null&&c.length>0){g=null;for(j=0;j 0?R(a)+1:0}for(d.actualColumnIndex=l;D(e.positionedItems, +h,l);)h++}else for(;;h++){l=P(e.positionedItems,h);l=l.length>0?R(l)+1:0;if(l<=d.actualColumnIndex)break}d.actualRowIndex=h}else if(typeof d.displayedColumnIndex==="undefined"){a=I(e.positionedItems);d.actualColumnIndex=a.length>0?R(a)+1:0}e.positionedItems.push(d);if(e.maxRowIndex==null||d.actualRowIndex>e.maxRowIndex)e.maxRowIndex=d.actualRowIndex}},P=function(b,f){for(var d=[],e=0;e 0?"auto":d.itemHeight+"px";else{var a=b.clientHeight-2;a<0&&(a=0);e=a+"px";if(a 0?"auto":d.itemHeight+"px"}b.isContentHeightInitialized= +true}return e},w=function(b,f){var d=b.createElement("span");d.innerHTML=f;return d},y=function(b){return Math.ceil(b/36E5*1E4/100)/100+"h"},C=function(b,f){for(var d=0,e=0;e 0)for(var l=0;l 0){d= +true;for(e=0;e 0;)b.removeChild(b.childNodes[e]);if(typeof f.isShapeVisible==="undefined"||f.isShapeVisible){e=d.taskEventTemplate;if(typeof f.taskEventTemplate!=="undefined")e=f.taskEventTemplate;e=e(f);b.appendChild(e);if(typeof d.internalExtraTaskTemplate!=="undefined"){var a=d.internalExtraTaskTemplate(f);a!=null&&b.appendChild(a)}if(typeof d.extraTaskEventTemplate!=="undefined"){a=d.extraTaskEventTemplate(f);a!=null&&b.appendChild(a)}if(d.isTaskEventToolTipVisible){a= +d.itemTemplate;if(typeof f.template!=="undefined")a=f.template;e.appendChild(a(f))}if(typeof f.predecessors!=="undefined")for(e=0;e 0;)e.chartItemArea.removeChild(e.chartItemArea.childNodes[g]);g=e.chartItemArea;var j=(h.itemWidth-h.shapeWidth)/2,s=j+h.shapeWidth,u=(h.itemHeight-h.shapeHeight)/2,k=u+h.shapeHeight,p=h.shapeHeight,m,r=c.createElementNS("http://www.w3.org/2000/svg","rect");r.setAttribute("x",j);r.setAttribute("y",u);r.setAttribute("width",Math.max(0,s-j-1));r.setAttribute("height",Math.max(0,k-u-1));r.setAttribute("rx",h.shapeWidth/10);r.setAttribute("ry",h.shapeHeight/ +10);m=h.shapeClass;if(typeof e.shapeClass!=="undefined")m=e.shapeClass;if(typeof m!=="undefined")r.setAttribute("class",m);else{m=h.shapeStyle;if(typeof e.shapeStyle!=="undefined")m=e.shapeStyle;typeof m!=="undefined"&&r.setAttribute("style",m)}g.appendChild(r);r=c.createElementNS("http://www.w3.org/2000/svg","text");r.setAttribute("x",(j+s)/2);r.setAttribute("y",k-p*1.5/8-6);r.setAttribute("style","font-weight: bold; text-anchor: middle");p=e.displayedText;typeof p==="undefined"&&(p="");r.appendChild(c.createTextNode(p)); +g.appendChild(r);if(h.canUserRearrangeItems){c=c.createElementNS("http://www.w3.org/2000/svg","rect");c.setAttribute("x",j);c.setAttribute("y",u);c.setAttribute("width",Math.max(0,s-j-1));c.setAttribute("height",Math.max(0,k-u-1));c.setAttribute("style","fill: White; fill-opacity: 0; cursor: pointer");g.appendChild(c);ca(c,e,l,E(e,h),G(e,h),a,h)}return g}},ba=function(b,f){return function(b,e){var a=b.pertChartView,h=typeof f!=="undefined"?f:a.settings,a=a.ownerDocument,l=a.createElementNS("http://www.w3.org/2000/svg", +"g"),c=void 0,g=void 0,j,s="M ",c=E(b,h)-2,g=G(b,h)-2,u=E(e.item,h);j=G(e.item,h);var k=E(b,h),p=G(b,h),m=Math.abs(k-u),r=Math.abs(p-j),t=h.shapeWidth+2,n=h.shapeHeight+2,q=t/2,v=n/2,o=Math.max(t,n),r=r =k?u:k))/2+q-c;g=((j<=p?j:p)+(j>=p?j:p))/2+v-g;j=s;s=a.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",j);typeof h.dependencyLineZoneClass!=="undefined"&&s.setAttribute("class",h.dependencyLineZoneClass);typeof h.dependencyLineZoneStyle!=="undefined"&&s.setAttribute("style",h.dependencyLineZoneStyle);l.appendChild(s);s=a.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",j);if(typeof e.isEffortVirtual!=="undefined"?!e.isEffortVirtual:typeof e.effort!== +"undefined"&&e.effort>0){j=h.dependencyLineClass;if(typeof e.dependencyLineClass!=="undefined")j=e.dependencyLineClass;typeof j!=="undefined"&&s.setAttribute("class",j);j=h.dependencyLineStyle;if(typeof e.dependencyLineStyle!=="undefined")j=e.dependencyLineStyle}else{j=h.virtualEffortDependencyLineClass;if(typeof e.virtualEffortDependencyLineClass!=="undefined")j=e.virtualEffortDependencyLineClass;typeof j!=="undefined"&&s.setAttribute("class",j);j=h.virtualEffortDependencyLineStyle;if(typeof e.virtualEffortDependencyLineStyle!== +"undefined")j=e.virtualEffortDependencyLineStyle}typeof j!=="undefined"&&s.setAttribute("style",j);l.appendChild(s);s=a.createElementNS("http://www.w3.org/2000/svg","text");s.setAttribute("x",c);s.setAttribute("y",g-6);g=h.dependencyTextClass;if(typeof e.dependencyTextClass!=="undefined")g=e.dependencyTextClass;typeof g!=="undefined"&&s.setAttribute("class",g);h=h.dependencyTextStyle;if(typeof e.dependencyTextStyle!=="undefined")h=e.dependencyTextStyle;s.setAttribute("style",h);h=e.displayedText; +typeof h==="undefined"&&(h="");s.appendChild(a.createTextNode(h));l.appendChild(s);return l}},la=function(){return function(b,f){var d=b.pertChartView.ownerDocument,e=d.createElementNS("http://www.w3.org/2000/svg","title");e.appendChild(w(d,typeof f.content!=="undefined"?f.content:""));return e}},S=function(b,f,d,e){typeof b.pertChartView!=="undefined"&&b.pertChartView.settings.itemPropertyChangeHandler(b,f,d,e)},ca=function(b,f,d,e,a,h,l){function c(c){h.draggingItem=f;h.dragType="Position";h.style.cursor= +b.style.cursor;h.draggingInitialX=c.clientX;h.draggingInitialY=c.clientY;h.draggingInitialThumbXPosition=e;h.draggingInitialThumbYPosition=a}b.addEventListener("mousedown",function(a){if(a.button==0){c(a);a.preventDefault()}},true);b.addEventListener("touchstart",function(a){c(a.touches[0]);a.preventDefault()},true);if(typeof h.draggableItems==="undefined")h.draggableItems=[];for(var g=false,j=0;j =j.chartContentContainer.clientWidth-24){g=j.chartContentContainer.scrollLeft;j.chartContentContainer.scrollLeft=j.chartContentContainer.scrollLeft+48;g=j.chartContentContainer.scrollLeft-g;if(typeof j.draggingInitialThumbXPosition!=="undefined")j.draggingInitialThumbXPosition=j.draggingInitialThumbXPosition+g}}j=a.clientY;a=h;if(typeof a.draggingItem!=="undefined"){g=a;e=0;if(g.offsetParent){do{e=e+g.offsetTop;g=g.offsetParent}while(g)}j=j-e;if(j<24){j= +a.chartContentContainer.scrollTop;a.chartContentContainer.scrollTop=a.chartContentContainer.scrollTop-48;j=j-a.chartContentContainer.scrollTop;if(typeof a.draggingInitialThumbYPosition!=="undefined")a.draggingInitialThumbYPosition=a.draggingInitialThumbYPosition-j}else if(j>=a.chartContentContainer.clientHeight-24){j=a.chartContentContainer.scrollTop;a.chartContentContainer.scrollTop=a.chartContentContainer.scrollTop+48;j=a.chartContentContainer.scrollTop-j;if(typeof a.draggingInitialThumbYPosition!== +"undefined")a.draggingInitialThumbYPosition=a.draggingInitialThumbYPosition+j}}delete h.draggingItem;h.draggingInitialThumbXPosition+c<0&&(c=-h.draggingInitialThumbXPosition);h.draggingInitialThumbYPosition+b<0&&(b=-h.draggingInitialThumbYPosition);a=f;b=(h.draggingInitialThumbYPosition+b-l.chartMargin)/(l.itemHeight+l.dependencyTextBlockWidth/l.aspectRatio);l.snapRearrangedItemsToGuidelines&&(b=Math.round(b));a.actualRowIndex=b;b=f;c=(h.draggingInitialThumbXPosition+c-l.chartMargin)/(l.itemWidth+ +l.dependencyTextBlockWidth);l.snapRearrangedItemsToGuidelines&&(c=Math.round(c));b.actualColumnIndex=c;S(f,"actualRowIndex",true,false);S(f,"actualColumnIndex",true,false);typeof f.displayedColumnIndex!=="undefined"&&delete f.displayedColumnIndex;typeof f.displayedRowIndex!=="undefined"&&delete f.displayedRowIndex;da(f,d,h.chartContent,l,false);h.draggingItem=f;h.draggingPerformed=true}};h.addEventListener("mousemove",function(a){s(a)},true);h.addEventListener("touchmove",function(a){s(a.touches[0])}, +true);var u=function(){if(!(typeof h.draggingItem==="undefined"||h.draggingItem!=f||h.dragType!="Position")){da(f,d,h.chartContent,l,true);var a=h.draggingItem;delete h.draggingItem;h.style.cursor="default";if(h.draggingPerformed){S(a,"actualColumnIndex",true,true);S(a,"actualRowIndex",true,true);delete h.draggingPerformed}}};document.addEventListener("mouseup",function(a){a.button==0&&u()},true);document.addEventListener("touchend",function(){u()},true);h.draggableItems.push(f)}},da=function(b,f, +d,e,a){var h=b.pertChartView.ownerDocument;if(a){if(typeof d.temporaryRectangle!=="undefined"){h=d.chartArea;h.removeChild(d.temporaryRectangle);delete d.temporaryRectangle}setTimeout(function(){A(b.chartItem,b,e);F(f,b);setTimeout(function(){N(d,f,e,true)},0)})}else{if(typeof d.temporaryRectangle!=="undefined")a=d.temporaryRectangle;else{a=h.createElementNS("http://www.w3.org/2000/svg","rect");a.setAttribute("x",0);a.setAttribute("y",0);a.setAttribute("width",e.shapeWidth);a.setAttribute("height", +e.shapeHeight);a.setAttribute("rx",e.shapeWidth/10);a.setAttribute("ry",e.shapeHeight/10);typeof e.temporaryThumbClass!=="undefined"&&a.setAttribute("class",e.temporaryThumbClass);a.setAttribute("style",e.temporaryThumbStyle);d.temporaryRectangle=a;h=d.chartArea;h.appendChild(a)}var h=E(b,e)+(e.itemWidth-e.shapeWidth)/2,l=G(b,e)+(e.itemHeight-e.shapeHeight)/2;a.setAttribute("transform","translate("+h+", "+l+")");setTimeout(function(){N(d,f,e,false)},0)}},N=function(b,f,d,e){var a=C(f,d),f=x(f,d); +if(e||a>b.clientWidth)b.style.width=a+"px";if(e||f>b.clientHeight)b.style.height=f+"px";b=b.chartArea;e?b.setAttribute("style","width: "+a+"px; height: "+f+"px"):b.setAttribute("style","width: "+Math.max(b.clientWidth,a)+"px; height: "+Math.max(b.clientHeight,f)+"px")},ka=function(b,f){for(var d=b.childNodes.length;d-- >0;)b.removeChild(b.childNodes[d]);b.appendChild(f)},ma=function(b,f){for(var d in f)d.indexOf("custom")!=0&&d.indexOf("description")!=0||typeof b[d]==="undefined"&&(b[d]=f[d])},ea= +function(b,f,d,e,a,h,l,c){var c={isExport:true,canUserRearrangeItems:false,isTaskEventToolTipVisible:false,isDependencyToolTipVisible:false,containerClass:c.containerClass,containerStyle:c.containerStyle,border:c.border,theme:c.theme,itemWidth:c.itemWidth,itemHeight:c.itemHeight,aspectRatio:c.aspectRatio,shapeWidth:c.shapeWidth,shapeHeight:c.shapeHeight,shapeClass:c.shapeClass,shapeStyle:c.shapeStyle,shapeCornerRadius:c.shapeCornerRadius,dependencyTextStyle:c.dependencyTextStyle,dependencyLineClass:c.dependencyLineClass, +dependencyLineStyle:c.dependencyLineStyle,virtualEffortDependencyLineClass:c.virtualEffortDependencyLineClass,virtualEffortDependencyLineStyle:c.virtualEffortDependencyLineStyle,dependencyTextBlockWidth:c.dependencyTextBlockWidth,chartMargin:0,target:c.target,timeSpanFormatter:c.timeSpanFormatter,taskEventTemplate:c.taskEventTemplate,dependencyLineTemplate:c.dependencyLineTemplate},g=C(l,c),j=x(l,c);c.chartWidth=g+"px";c.chartHeight=j+"px";var s=g+2,g=j+2,u,k,p=false;if(d!=null&&typeof d.createElement!== +"undefined")u=d;else{if(d!=null&&typeof d.focus!=="undefined")k=d;else{k=window.open("",d!=null?d:"_blank",typeof e!=="undefined"&&e&&(typeof h==="undefined"||h)?"width=320,height=100,location=no,menubar=no,toolbar=no,status=no,scrollbars=yes":"");p=true}u=k.document;try{for(var m=document.head.getElementsByTagName("link"),d=0;d 0;){var a=f[e];if(ga(a).length==0){e=a;break a}}e=null}if(e==null)return[];d=ha(d,e);e=[];for(a=0;a 0)l=l+predecessorItem.effort;if(h==null||l>=h){if(h==null||l>h){h=l;e=[]}e.push(predecessorItem)}}}}for(a=0;a 0?h.predecessorItem.effort:0);l<0&&(l=0);if(d==null||l>d)d=l}}return d},ga=function(b){for(var f=[],d=b.pertChartView.items,e=0;e f)f=b[d];return f},ja=function(b,f,d){for(var e=0;e a.pertChartView.chartContentContainer.clientWidth-a.pertChartView.settings.itemWidth)a.pertChartView.chartContentContainer.scrollLeft=h-(a.pertChartView.chartContentContainer.clientWidth-a.pertChartView.settings.itemWidth);h=G(a,d);b=h-a.pertChartView.chartContentContainer.scrollTop;if(b<0)a.pertChartView.chartContentContainer.scrollTop= +h;else if(b>a.pertChartView.chartContentContainer.clientHeight-a.pertChartView.settings.itemHeight)a.pertChartView.chartContentContainer.scrollTop=h-(a.pertChartView.chartContentContainer.clientHeight-a.pertChartView.settings.itemHeight)};b.scrollToLeft=function(){b.chartContentContainer.scrollLeft=0};b.scrollToRight=function(){b.chartContentContainer.scrollLeft=b.chartContent.clientWidth};b.scrollToTop=function(){b.chartContentContainer.scrollTop=0};b.scrollToBottom=function(){b.chartContentContainer.scrollTop= +b.chartContent.clientHeight};b.getChartWidth=function(){return C(f,d)};b.getChartHeight=function(){return x(f,d)};b.getItemTop=function(a){return G(a,d)};b.getItemLeft=function(a){return E(a,d)};b.onItemPropertyChanged=S;b.initializeTasEventkDraggingThumbs=function(a,h,l,c){ca(a,h,b.items,l,c,b,b.settings)};b.exportContent=function(a,h){typeof a==="undefined"&&(a={});ea(a.title,a.preparingMessage,h,false,a.rotate,false,f,d)};b.print=function(a){typeof a==="undefined"&&(a={});ea(a.title,a.preparingMessage, +null,true,a.rotate,a.autoClose,f,d)};b.isItemCritical=function(a,h){return na(h,f).indexOf(a)>=0};b.isDependencyCritical=function(a,h){return fa(h,f).indexOf(a)>=0};b.getCriticalItems=function(a){return na(a,f)};b.getCriticalDependencies=function(a){return fa(a,f)};b.repositionEnds=function(){if(f.length!=0){for(var a=false,h=0;h 1)break}if(c>1)break}}c>1&&(a=true)}h=f[0];h.displayedRowIndex=a?0.5:0;b=f[f.length-1];b.displayedRowIndex=a?0.5:0;$(h);$(b)}}};return{initialize:L,initializeItems:U,refresh:M,getDefaultStyleDefinitionTemplate:W,getDefaultTaskEventTemplate:aa,getDefaultItemTemplate:X,getDefaultDependencyLineTemplate:ba,getDefaultPredecessorItemTemplate:la,initializeTaskEventDraggingThumbs:function(b,f,d,e){f.pertChartView.initializeTaskEventDraggingThumbs(b,f,d,e)}, +defaultTimeSpanFormatter:y}}()); +void 0==DlhSoft.Controls.Pert.NetworkDiagramView&&(DlhSoft.Controls.Pert.NetworkDiagramView=function(){var L=function(a,h,b,c){var g=["DlhSoft.Controls.Pert","NetworkDiagramView","DlhSoft.ProjectData.PertChart.HTML.Controls","5","validate","Licensing"];DlhSoft[g[5]][g[4]](a,g[0],g[1],g[2],g[3],c,b);a.isInitializing=true;if(typeof a.items!=="undefined")for(c=0;c 0?a.insertBefore(h,a.childNodes[0]):a.appendChild(h)}catch(c){}},0)};j.addEventListener("mousedown",f,true);d.addEventListener("mouseup",f,true);m.appendChild(j);m.chartArea=j;var r;setTimeout(function(){r=a.clientHeight},0);typeof a.heightUpdateTimer!=="undefined"&&clearInterval(a.heightUpdateTimer); +a.heightUpdateTimer=setInterval(function(){try{if(!(a.clientHeight<=0)){var c=a.clientHeight;if(c!=r){var g=J(a,h,b);k.style.height=g;r=c}}}catch(j){try{clearInterval(a.heightUpdateTimer)}catch(d){}}},100);var t=function(a,c,g,j){var f;if(b.mouseHandler||b.mouseMoveHandler&&j=="mousemove"||b.mouseDownHandler&&j=="mousedown"||b.clickHandler&&j=="click"||b.doubleClickHandler&&j=="dblclick"){var e=a.which;!e&&a.button&&(a.button&1?e=1:a.button&4?e=2:a.button&2&&(e=3));f=g.getBoundingClientRect();var u= +d.body,k=d.documentElement,g=f.left+(window.pageXOffset||k.scrollLeft||u.scrollLeft)-(k.clientLeft||u.clientLeft||0);f=Math.round(f.top+(window.pageYOffset||k.scrollTop||u.scrollTop)-(k.clientTop||u.clientTop||0));g=Math.round(g);g=a.pageX-g;f=a.pageY-f;for(u=0;u =t&&g =m&&f =0&&n 0?b(j):c.maxRowIndex!=null?c.maxRowIndex+1:0;d=d=void 0;if(typeof l.displayedColumnIndex==="undefined"){d=P(c.positionedItems,j);d=d.length>0?b(d)+1:0;f=g!=null?P(g,j):null;if(f!=null&&f.length>0){e=null;for(p=0;p 0?b(g)+1:0}for(l.actualColumnIndex=d;D(c.positionedItems,j,d);)j++}else for(;;j++){d=P(c.positionedItems,j);d=d.length>0?b(d)+1:0;if(d<=l.actualColumnIndex)break}l.actualRowIndex=j}else if(typeof l.displayedColumnIndex==="undefined"){g=I(c.positionedItems);l.actualColumnIndex=g.length>0?b(g)+1:0}c.positionedItems.push(l);if(c.maxRowIndex==null||l.actualRowIndex>c.maxRowIndex)c.maxRowIndex=l.actualRowIndex}},P=function(a,h){for(var b=[],c=0;c 0?"auto":b.itemHeight+"px";else{var g=a.clientHeight-2;g<0&&(g=0);c=g+"px";if(g 0?"auto":b.itemHeight+"px"}a.isContentHeightInitialized=true}return c},w=function(a,h){var b=a.createElement("span");b.innerHTML=h;return b},y=function(a){var h;h=a.getFullYear();var b=a.getMonth()+1;b<10&&(b="0"+b);var c=a.getDate();c<10&&(c="0"+c);h=b+"/"+c+"/"+h;b=a.getHours();b<10&&(b="0"+b.toString());a=a.getMinutes();a<10&&(a="0"+a.toString());return h+" "+b+":"+a},C=function(a){return Math.ceil(a/36E5*1E4/100)/100+"h"},x=function(a){var b=new Date(Math.floor((new Date).valueOf()/ +864E5)*864E5),d=new Date,c,g;for(g=0;g 0)for(var f=0;f 0){d=true;for(c=0;c0;)a.removeChild(a.childNodes[c]);if(typeof b.isShapeVisible==="undefined"||b.isShapeVisible){c=d.taskTemplate;if(typeof b.taskTemplate!=="undefined")c= +b.taskTemplate;c=c(b);a.appendChild(c);if(typeof d.internalExtraTaskTemplate!=="undefined"){var g=d.internalExtraTaskTemplate(b);g!=null&&a.appendChild(g)}if(typeof d.extraTaskTemplate!=="undefined"){g=d.extraTaskTemplate(b);g!=null&&a.appendChild(g)}if(d.isTaskToolTipVisible){g=d.itemTemplate;if(typeof b.template!=="undefined")g=b.template;c.appendChild(g(b))}if(typeof b.predecessors!=="undefined")for(c=0;c 0;)a.chartItemArea.removeChild(a.chartItemArea.childNodes[b]);return a.chartItemArea},S=function(a,b,d){return function(c){var g=typeof b!=="undefined"?b:c.networkDiagramView,j=typeof d!=="undefined"?d:g.settings,f=typeof a!=="undefined"?a:g.items, +e=g.ownerDocument,k=la(c),p=(j.itemWidth-j.shapeWidth)/2,m=p+j.shapeWidth,r=(j.itemHeight-j.shapeHeight)/2,t=r+j.shapeHeight,n=0,q=j.shapeHeight,v=j.shapeWidth;if(c.isMilestone){n=v/16;p=p+n;m=m-n;v=v-2*n}if(c.isMilestone){var o=e.createElementNS("http://www.w3.org/2000/svg","polygon");o.setAttribute("points",p+","+r+" "+(p-n)+","+(r+t)/2+" "+p+","+t+" "+m+","+t+" "+(m+n)+","+(r+t)/2+" "+m+","+r);n=j.milestoneClass;if(typeof c.milestoneClass!=="undefined")n=c.milestoneClass;if(typeof n!=="undefined")o.setAttribute("class", +n);else{n=j.milestoneStyle;if(typeof c.milestoneStyle!=="undefined")n=c.milestoneStyle;typeof n!=="undefined"&&o.setAttribute("style",n)}k.appendChild(o)}o=e.createElementNS("http://www.w3.org/2000/svg","rect");o.setAttribute("x",p);o.setAttribute("y",r);o.setAttribute("width",Math.max(0,m-p-1));o.setAttribute("height",Math.max(0,t-r-1));n=j.shapeClass;if(typeof c.shapeClass!=="undefined")n=c.shapeClass;if(typeof n!=="undefined")o.setAttribute("class",n);else{n=j.shapeStyle;if(typeof c.shapeStyle!== +"undefined")n=c.shapeStyle;typeof n!=="undefined"&&o.setAttribute("style",n)}k.appendChild(o);n=e.createElementNS("http://www.w3.org/2000/svg","line");n.setAttribute("x1",p);n.setAttribute("y1",r+q*3/8);n.setAttribute("x2",m-1);n.setAttribute("y2",r+q*3/8);o=j.shapeClass;if(typeof c.shapeClass!=="undefined")o=c.shapeClass;typeof o!=="undefined"&&n.setAttribute("class",o);o=j.shapeStyle;if(typeof c.shapeStyle!=="undefined")o=c.shapeStyle;typeof o!=="undefined"&&n.setAttribute("style",o);k.appendChild(n); +n=e.createElementNS("http://www.w3.org/2000/svg","line");n.setAttribute("x1",p);n.setAttribute("y1",t-q*3/8);n.setAttribute("x2",m-1);n.setAttribute("y2",t-q*3/8);o=j.shapeClass;if(typeof c.shapeClass!=="undefined")o=c.shapeClass;typeof o!=="undefined"&&n.setAttribute("class",o);o=j.shapeStyle;if(typeof c.shapeStyle!=="undefined")o=c.shapeStyle;typeof o!=="undefined"&&n.setAttribute("style",o);k.appendChild(n);n=e.createElementNS("http://www.w3.org/2000/svg","line");n.setAttribute("x1",p+v*3/8);n.setAttribute("y1", +r);n.setAttribute("x2",p+v*3/8);n.setAttribute("y2",r+q*3/8);o=j.shapeClass;if(typeof c.shapeClass!=="undefined")o=c.shapeClass;typeof o!=="undefined"&&n.setAttribute("class",o);o=j.shapeStyle;if(typeof c.shapeStyle!=="undefined")o=c.shapeStyle;typeof o!=="undefined"&&n.setAttribute("style",o);k.appendChild(n);n=e.createElementNS("http://www.w3.org/2000/svg","line");n.setAttribute("x1",m-v*3/8);n.setAttribute("y1",r);n.setAttribute("x2",m-v*3/8);n.setAttribute("y2",r+q*3/8);o=j.shapeClass;if(typeof c.shapeClass!== +"undefined")o=c.shapeClass;typeof o!=="undefined"&&n.setAttribute("class",o);o=j.shapeStyle;if(typeof c.shapeStyle!=="undefined")o=c.shapeStyle;typeof o!=="undefined"&&n.setAttribute("style",o);k.appendChild(n);n=e.createElementNS("http://www.w3.org/2000/svg","line");n.setAttribute("x1",p+v*3/8);n.setAttribute("y1",t);n.setAttribute("x2",p+v*3/8);n.setAttribute("y2",t-q*3/8);o=j.shapeClass;if(typeof c.shapeClass!=="undefined")o=c.shapeClass;typeof o!=="undefined"&&n.setAttribute("class",o);o=j.shapeStyle; +if(typeof c.shapeStyle!=="undefined")o=c.shapeStyle;typeof o!=="undefined"&&n.setAttribute("style",o);k.appendChild(n);n=e.createElementNS("http://www.w3.org/2000/svg","line");n.setAttribute("x1",m-v*3/8);n.setAttribute("y1",t);n.setAttribute("x2",m-v*3/8);n.setAttribute("y2",t-q*3/8);o=j.shapeClass;if(typeof c.shapeClass!=="undefined")o=c.shapeClass;typeof o!=="undefined"&&n.setAttribute("class",o);o=j.shapeStyle;if(typeof c.shapeStyle!=="undefined")o=c.shapeStyle;typeof o!=="undefined"&&n.setAttribute("style", +o);k.appendChild(n);o=e.createElementNS("http://www.w3.org/2000/svg","text");o.setAttribute("x",(p+m)/2);o.setAttribute("y",t-q*3/8-6);o.setAttribute("style","font-weight: bold; text-anchor: middle");n=c.displayedText;typeof n==="undefined"&&(n="");o.appendChild(e.createTextNode(n));k.appendChild(o);var n=function(a){var a=j.dateTimeFormatter(new Date(a.valueOf()+(new Date).getTimezoneOffset()*6E4)),b;b=a.indexOf(" ");if(b>=0){value1=a.substr(0,b);value2=a.substr(b+1)}else{value1=a;value2=""}return[value1, +value2]},o=n(c.earlyStart),z=e.createElementNS("http://www.w3.org/2000/svg","text");z.setAttribute("x",p+v*3/8/2);z.setAttribute("y",t-q*5/8-20);z.setAttribute("style","text-anchor: middle");z.appendChild(e.createTextNode(o[0]));k.appendChild(z);z=e.createElementNS("http://www.w3.org/2000/svg","text");z.setAttribute("x",p+v*3/8/2);z.setAttribute("y",t-q*5/8-4);z.setAttribute("style","text-anchor: middle");z.appendChild(e.createTextNode(o[1]));k.appendChild(z);o=j.timeSpanFormatter(c.effort);z=e.createElementNS("http://www.w3.org/2000/svg", +"text");z.setAttribute("x",(p+m)/2);z.setAttribute("y",t-q*5/8-12);z.setAttribute("style","text-anchor: middle");z.appendChild(e.createTextNode(o));k.appendChild(z);o=n(c.earlyFinish);z=e.createElementNS("http://www.w3.org/2000/svg","text");z.setAttribute("x",m-v*3/8/2);z.setAttribute("y",t-q*5/8-20);z.setAttribute("style","text-anchor: middle");z.appendChild(e.createTextNode(o[0]));k.appendChild(z);z=e.createElementNS("http://www.w3.org/2000/svg","text");z.setAttribute("x",m-v*3/8/2);z.setAttribute("y", +t-q*5/8-4);z.setAttribute("style","text-anchor: middle");z.appendChild(e.createTextNode(o[1]));k.appendChild(z);o=n(c.lateStart);q=e.createElementNS("http://www.w3.org/2000/svg","text");q.setAttribute("x",p+v*3/8/2);q.setAttribute("y",t-20);q.setAttribute("style","text-anchor: middle");q.appendChild(e.createTextNode(o[0]));k.appendChild(q);q=e.createElementNS("http://www.w3.org/2000/svg","text");q.setAttribute("x",p+v*3/8/2);q.setAttribute("y",t-4);q.setAttribute("style","text-anchor: middle");q.appendChild(e.createTextNode(o[1])); +k.appendChild(q);o=j.timeSpanFormatter(c.slack);q=e.createElementNS("http://www.w3.org/2000/svg","text");q.setAttribute("x",(p+m)/2);q.setAttribute("y",t-12);q.setAttribute("style","text-anchor: middle");q.appendChild(e.createTextNode(o));k.appendChild(q);o=n(c.lateFinish);q=e.createElementNS("http://www.w3.org/2000/svg","text");q.setAttribute("x",m-v*3/8/2);q.setAttribute("y",t-20);q.setAttribute("style","text-anchor: middle");q.appendChild(e.createTextNode(o[0]));k.appendChild(q);q=e.createElementNS("http://www.w3.org/2000/svg", +"text");q.setAttribute("x",m-v*3/8/2);q.setAttribute("y",t-4);q.setAttribute("style","text-anchor: middle");q.appendChild(e.createTextNode(o[1]));k.appendChild(q);if(j.canUserRearrangeItems){e=e.createElementNS("http://www.w3.org/2000/svg","rect");e.setAttribute("x",p);e.setAttribute("y",r);e.setAttribute("width",Math.max(0,m-p-1));e.setAttribute("height",Math.max(0,t-r-1));e.setAttribute("style","fill: White; fill-opacity: 0; cursor: pointer");k.appendChild(e);ka(e,c,f,F(c,j),H(c,j),g,j)}return k}}, +ca=function(a,b){return function(a,c){var g=a.networkDiagramView,d=typeof b!=="undefined"?b:g.settings,e=g.ownerDocument,g=e.createElementNS("http://www.w3.org/2000/svg","g"),f;f="M ";var k=F(a,d)-2,p=H(a,d)-2,m=F(c.item,d),r=H(c.item,d),t=F(a,d),n=H(a,d),q=Math.abs(t-m),v=Math.abs(n-r),o=d.shapeWidth+2,z=d.shapeHeight+2,y=o/2,x=z/2,w=Math.max(o,z),v=v =k.chartContentContainer.clientWidth-24){f=k.chartContentContainer.scrollLeft;k.chartContentContainer.scrollLeft=k.chartContentContainer.scrollLeft+48;f=k.chartContentContainer.scrollLeft-f;if(typeof k.draggingInitialThumbXPosition!== +"undefined")k.draggingInitialThumbXPosition=k.draggingInitialThumbXPosition+f}}k=a.clientY;a=j;if(typeof a.draggingItem!=="undefined"){f=a;m=0;if(f.offsetParent){do{m=m+f.offsetTop;f=f.offsetParent}while(f)}k=k-m;if(k<24){k=a.chartContentContainer.scrollTop;a.chartContentContainer.scrollTop=a.chartContentContainer.scrollTop-48;k=k-a.chartContentContainer.scrollTop;if(typeof a.draggingInitialThumbYPosition!=="undefined")a.draggingInitialThumbYPosition=a.draggingInitialThumbYPosition-k}else if(k>=a.chartContentContainer.clientHeight- +24){k=a.chartContentContainer.scrollTop;a.chartContentContainer.scrollTop=a.chartContentContainer.scrollTop+48;k=a.chartContentContainer.scrollTop-k;if(typeof a.draggingInitialThumbYPosition!=="undefined")a.draggingInitialThumbYPosition=a.draggingInitialThumbYPosition+k}}delete j.draggingItem;j.draggingInitialThumbXPosition+c<0&&(c=-j.draggingInitialThumbXPosition);j.draggingInitialThumbYPosition+g<0&&(g=-j.draggingInitialThumbYPosition);a=b;g=(j.draggingInitialThumbYPosition+g-e.diagramMargin)/(e.itemHeight+ +e.minDependencyLineLength/e.aspectRatio);e.snapRearrangedItemsToGuidelines&&(g=Math.round(g));a.actualRowIndex=g;g=b;c=(j.draggingInitialThumbXPosition+c-e.diagramMargin)/(e.itemWidth+e.minDependencyLineLength);e.snapRearrangedItemsToGuidelines&&(c=Math.round(c));g.actualColumnIndex=c;N(b,"actualRowIndex",true,false);N(b,"actualColumnIndex",true,false);typeof b.displayedColumnIndex!=="undefined"&&delete b.displayedColumnIndex;typeof b.displayedRowIndex!=="undefined"&&delete b.displayedRowIndex;ma(b, +d,j.chartContent,e,false);j.draggingItem=b;j.draggingPerformed=true}};j.addEventListener("mousemove",function(a){m(a)},true);j.addEventListener("touchmove",function(a){m(a.touches[0])},true);var r=function(){if(!(typeof j.draggingItem==="undefined"||j.draggingItem!=b||j.dragType!="Position")){ma(b,d,j.chartContent,e,true);var a=j.draggingItem;delete j.draggingItem;j.style.cursor="default";if(j.draggingPerformed){N(a,"actualColumnIndex",true,true);N(a,"actualRowIndex",true,true);delete j.draggingPerformed}}}; +document.addEventListener("mouseup",function(a){a.button==0&&r()},true);document.addEventListener("touchend",function(){r()},true);j.draggableItems.push(b)}},ma=function(a,b,d,c,g){var e=a.networkDiagramView.ownerDocument;if(g){if(typeof d.temporaryRectangle!=="undefined"){e=d.chartArea;e.removeChild(d.temporaryRectangle);delete d.temporaryRectangle}setTimeout(function(){Q(a.chartItem,a,c);A(b,a);setTimeout(function(){ea(d,b,c,true)},0)})}else{if(typeof d.temporaryRectangle!=="undefined")g=d.temporaryRectangle; +else{g=e.createElementNS("http://www.w3.org/2000/svg","rect");g.setAttribute("x",0);g.setAttribute("y",0);g.setAttribute("width",c.shapeWidth);g.setAttribute("height",c.shapeHeight);typeof c.temporaryThumbClass!=="undefined"&&g.setAttribute("class",c.temporaryThumbClass);g.setAttribute("style",c.temporaryThumbStyle);d.temporaryRectangle=g;e=d.chartArea;e.appendChild(g)}var e=F(a,c)+(c.itemWidth-c.shapeWidth)/2,f=H(a,c)+(c.itemHeight-c.shapeHeight)/2;g.setAttribute("transform","translate("+e+", "+ +f+")");setTimeout(function(){ea(d,b,c,false)},0)}},ea=function(a,b,d,c){var g=K(b,d),b=E(b,d);if(c||g>a.clientWidth)a.style.width=g+"px";if(c||b>a.clientHeight)a.style.height=b+"px";a=a.chartArea;c?a.setAttribute("style","width: "+g+"px; height: "+b+"px"):a.setAttribute("style","width: "+Math.max(a.clientWidth,g)+"px; height: "+Math.max(a.clientHeight,b)+"px")},na=function(a,b){for(var d=a.childNodes.length;d-- >0;)a.removeChild(a.childNodes[d]);a.appendChild(b)},fa=function(a,b){for(var d in b)d.indexOf("custom")!= +0&&d.indexOf("description")!=0||typeof a[d]==="undefined"&&(a[d]=b[d])},ha=function(a,b,d,c,g,e,f,u,k){var d={isExport:true,canUserRearrangeItems:false,isTaskToolTipVisible:false,isDependencyToolTipVisible:false,containerClass:k.containerClass,containerStyle:k.containerStyle,border:k.border,theme:k.theme,itemWidth:k.itemWidth,itemHeight:k.itemHeight,aspectRatio:k.aspectRatio,shapeWidth:k.shapeWidth,shapeHeight:k.shapeHeight,shapeClass:k.shapeClass,milestoneClass:k.milestoneClass,shapeStyle:k.shapeStyle, +milestoneStyle:k.milestoneStyle,dependencyLineClass:k.dependencyLineClass,dependencyLineStyle:k.dependencyLineStyle,minDependencyLineLength:k.minDependencyLineLength,diagramMargin:0,target:k.target,dateTimeFormatter:k.dateTimeFormatter,timeSpanFormatter:k.timeSpanFormatter,isRelativeToTimezone:k.isRelativeToTimezone,taskTemplate:k.taskTemplate,dependencyLineTemplate:k.dependencyLineTemplate},k=K(u,d),p=E(u,d);d.chartWidth=k+"px";d.chartHeight=p+"px";var m=k+2,k=p+2,r,t,n=false;if(c!=null&&typeof c.createElement!== +"undefined")r=c;else{if(c!=null&&typeof c.focus!=="undefined")t=c;else{t=window.open("",c!=null?c:"_blank",typeof g!=="undefined"&&g&&(typeof f==="undefined"||f)?"width=320,height=100,location=no,menubar=no,toolbar=no,status=no,scrollbars=yes":"");n=true}r=t.document;try{for(var q=document.head.getElementsByTagName("link"),c=0;c +0;){g=b[c];if(ja(g).length==0)break a}g=null}if(g==null)return[];c=[d];d=ga(d,g);for(g=0;g