コード例 #1
0
ファイル: GanttManager.cs プロジェクト: 0anion0/IBN
        private static Element AddInterval2(GanttView gantt, Element parent, DateTime? start, DateTime? finish, string id, string type, string tag)
        {
            Element child = null;

            if (start != null && finish != null)
            {
                child = gantt.CreateIntervalElement(parent, start.Value, finish.Value, id, type, tag);
                if (type == "Summary")
                {
                    gantt.CreatePointElement(child, start.Value, null, type + "Start", tag);
                    gantt.CreatePointElement(child, finish.Value, null, type + "Finish", tag);
                }
            }
            else
            {
                if (start != null)
                {
                    child = gantt.CreatePointElement(parent, start.Value, id, type + "Start", tag);
                }
                if (finish != null)
                {
                    child = gantt.CreatePointElement(parent, finish.Value, id, type + "Finish", tag);
                }
            }

            return child;
        }