예제 #1
0
        public void ActionDrillthroughTest1()
        {
            int           id           = 0;
            string        reportName   = "report";
            IDrillthrough drillthrough = Drillthrough.Create(reportName, null);

            Action action = Action.CreateDrillthrouth(drillthrough, id);

            Assert.AreEqual(ActionType.DrillThrough, action.ActionType);
            Assert.IsNotNull(action.Drillthrough);
            Assert.AreEqual(reportName, action.Drillthrough.ReportName);
            Assert.AreEqual(id, action.ActionId);
            Assert.AreEqual(0, action.Drillthrough.NumberOfParameters);
        }
예제 #2
0
        public void DrillthroughTest()
        {
            string        reportName   = "reportName";
            IList         parameters   = new DrillthroughParameter[] { };
            IDrillthrough drillthrough = Components.Calendar.Drillthrough.Create(reportName, parameters);

            Assert.AreEqual(reportName, drillthrough.ReportName);
            Assert.AreEqual(parameters.Count, drillthrough.NumberOfParameters);

            IList         parameters1   = new DrillthroughParameter[] { };
            IDrillthrough drillthrough1 = Components.Calendar.Drillthrough.Create(reportName, parameters);

            Assert.AreEqual(reportName, drillthrough1.ReportName);
            Assert.AreEqual(parameters1.Count, drillthrough1.NumberOfParameters);
        }
예제 #3
0
        public void ActionDrillthroughTest2()
        {
            const int    id         = 0;
            const string reportName = "report";

            DrillthroughParameter[] parameters = new[]
            {
                new DrillthroughParameter("a", 1, false),
                new DrillthroughParameter("b", 2, false),
            };

            IDrillthrough drillthrough = Drillthrough.Create(reportName, parameters);

            Action action = Action.CreateDrillthrouth(drillthrough, id);

            Assert.AreEqual(ActionType.DrillThrough, action.ActionType);
            Assert.IsNotNull(action.Drillthrough);
            Assert.AreEqual(reportName, action.Drillthrough.ReportName);
            Assert.AreEqual(id, action.ActionId);
            Assert.AreEqual(parameters.Length, action.Drillthrough.NumberOfParameters);
        }
예제 #4
0
 /// <summary>
 /// Creates Drillthrough action
 /// </summary>
 /// <param name="drillthrough"></param>
 /// <param name="actionId"></param>
 /// <returns></returns>
 public static Action CreateDrillthrouth(IDrillthrough drillthrough, int actionId)
 {
     return(new Action(drillthrough, actionId));
 }
예제 #5
0
 private Action(IDrillthrough drillthrough, int actionId)
 {
     _drillthrough = drillthrough;
     _actionType   = ActionType.DrillThrough;
     _actionId     = actionId;
 }