コード例 #1
0
        public WorkFlowInstanceList GetWorkFlowInstances()
        {
            WorkFlowInstanceList l = new WorkFlowInstanceList();

            //WorkFlowInstanceDataContext dataContext = new WorkFlowInstanceDataContext();
            //var workflowinstance = from b in dataContext.InstancesTables select b;
            return(l);
        }
コード例 #2
0
        public WorkFlowInstanceList GetWorkFlowInstances()
        {
            //WindowsPrincipal principal = (WindowsPrincipal)Thread.CurrentPrincipal;

            //WindowsIdentity identity = (WindowsIdentity)principal.Identity;

            //TrackingLog.Log(identity.Name);

            WorkFlowInstanceList l = new WorkFlowInstanceList();

            try
            {
                TrackingDataContext dataContext = new TrackingDataContext();

                IQueryable <CommonResource.Tracking> trackingQuery =
                    from tracking in dataContext.Trackings
                    select tracking;

                foreach (CommonResource.Tracking t in trackingQuery)
                {
                    using (TrackingWorkFlowInteraction interaction = new TrackingWorkFlowInteraction())
                    {
                        WorkFlowInstance wfi = new WorkFlowInstance();
                        wfi.BugId          = t.bugid;
                        wfi.Id             = t.wfinstanceid.ToString();
                        wfi.Title          = t.title;
                        wfi.WFName         = t.wfname;
                        wfi.LastModified   = t.lastmodified.ToString();
                        wfi.QFEStatus      = t.qfestatus;
                        wfi.AssignedTo     = t.assignedto;
                        wfi.LastModified   = t.lastmodified == null ? "N/A" : t.lastmodified.Value.ToString();
                        wfi.LastModifiedBy = t.lastmodifiedby;
                        //
                        //List<string> candiCmds = interaction.getCandidateCommands(t.wfname.Trim(), t.wfinstanceid.ToString());
                        //CandidateCommandList ccl = new CandidateCommandList();
                        //if (candiCmds != null)
                        //{
                        //    foreach (string cmd in candiCmds)
                        //    {
                        //        ccl.Add(cmd);
                        //    }
                        //}
                        //wfi.CandidateCommandList = ccl;
                        l.Add(wfi);
                    }
                }
            }
            catch (Exception e)
            {
                TrackingLog.Log(e.ToString() + "!!" + e.Message);
            }
            return(l);
        }
コード例 #3
0
        public WorkFlowInstanceList GetWorkFlowInstances()
        {
            WorkFlowInstanceList l = new WorkFlowInstanceList();

            //WorkFlowInstanceDataContext dataContext = new WorkFlowInstanceDataContext();
            //var workflowinstance = from b in dataContext.InstancesTables select b;
            return l;
        }
コード例 #4
0
ファイル: TrackingService.cs プロジェクト: cpm2710/cellbank
        public WorkFlowInstanceList GetWorkFlowInstances()
        {
            //WindowsPrincipal principal = (WindowsPrincipal)Thread.CurrentPrincipal;

            //WindowsIdentity identity = (WindowsIdentity)principal.Identity;

            //TrackingLog.Log(identity.Name);

            WorkFlowInstanceList l = new WorkFlowInstanceList();
            try
            {
                TrackingDataContext dataContext = new TrackingDataContext();

                IQueryable<CommonResource.Tracking> trackingQuery =
                    from tracking in dataContext.Trackings
                    select tracking;

                foreach (CommonResource.Tracking t in trackingQuery)
                {
                    using (TrackingWorkFlowInteraction interaction = new TrackingWorkFlowInteraction())
                    {
                        WorkFlowInstance wfi = new WorkFlowInstance();
                        wfi.BugId = t.bugid;
                        wfi.Id = t.wfinstanceid.ToString();
                        wfi.Title = t.title;
                        wfi.WFName = t.wfname;
                        wfi.LastModified = t.lastmodified.ToString();
                        wfi.QFEStatus = t.qfestatus;
                        wfi.AssignedTo = t.assignedto;
                        wfi.LastModified = t.lastmodified == null ? "N/A" : t.lastmodified.Value.ToString();
                        wfi.LastModifiedBy = t.lastmodifiedby;
                        //
                        //List<string> candiCmds = interaction.getCandidateCommands(t.wfname.Trim(), t.wfinstanceid.ToString());
                        //CandidateCommandList ccl = new CandidateCommandList();
                        //if (candiCmds != null)
                        //{
                        //    foreach (string cmd in candiCmds)
                        //    {
                        //        ccl.Add(cmd);
                        //    }
                        //}
                        //wfi.CandidateCommandList = ccl;
                        l.Add(wfi);
                    }
                }
            }
            catch (Exception e)
            {
                TrackingLog.Log(e.ToString() + "!!" + e.Message);
            }
            return l;
        }