GetProcessBySummary() public method

public GetProcessBySummary ( string ProcessSummary ) : Process
ProcessSummary string
return Process
Beispiel #1
0
 public long CreateProcess(string ProcessDescription, string ProcessSummary, int CreatedBy, int OwnedBy, int AtulProcessStatusID, int DeadLineOffset)
 {
     long processId = 0;
     AtulBusinessLogic adb = new AtulBusinessLogic();
     Process p = adb.GetProcessBySummary(ProcessSummary);
     if (p == null)
     {
         processId = adb.CreateProcess(ProcessDescription, ProcessSummary, CreatedBy, OwnedBy, AtulProcessStatusID, DeadLineOffset);
     }
     else
     {
         throw new Exception("A Process with that name already exists.");
     }
     return processId;
 }
Beispiel #2
0
 public Process GetProcessBySummary(string ProcessSummary)
 {
     Process p;
     AtulBusinessLogic adb = new AtulBusinessLogic();
     p = adb.GetProcessBySummary(ProcessSummary);
     return p;
 }
Beispiel #3
0
        public bool UpdateProcess(string ProcessID, string ProcessDescription, string ProcessSummary, int ModifiedBy, int OwnedBy, int AtulProcessStatusID, int DeadLineOffset, string SubjectServiceProviderID, string ScopeID)
        {
            bool success = false;
            long AtulProcessID = Convert.ToInt64(ProcessID);
            long? SSID = null;
            if (SubjectServiceProviderID.Trim() != string.Empty)
            {
                SSID = Convert.ToInt64(SubjectServiceProviderID);
            }

            AtulBusinessLogic adb = new AtulBusinessLogic();
            Process p = adb.GetProcessBySummary(ProcessSummary);
            if (p == null || p.AtulProcessID == AtulProcessID)
            {
                success = adb.UpdateProcess(AtulProcessID, ProcessDescription, ProcessSummary, ModifiedBy, OwnedBy, AtulProcessStatusID, DeadLineOffset, SSID, ScopeID);
            }
            return success;
        }