protected static FR_L5PR_GPGFPGID_1319 Execute(DbConnection Connection, DbTransaction Transaction, P_L5PR_GPGFPGID_1319 Parameter, CSV2Core.SessionSecurity.SessionSecurityTicket securityTicket = null) { #region UserCode var returnValue = new FR_L5PR_GPGFPGID_1319(); returnValue.Result = new L5PR_GPGFPGID_1319(); //Put your code here L5PR_GPGFT_1315 resultProjectGroup = new L5PR_GPGFT_1315(); ORM_TMS_PRO_Project_Group.Query projectGroupQuery = new ORM_TMS_PRO_Project_Group.Query(); projectGroupQuery.TMS_PRO_Project_GroupID = Parameter.TMS_PRO_Project_GroupID; projectGroupQuery.IsDeleted = false; projectGroupQuery.Tenant_RefID = securityTicket.TenantID; List <ORM_TMS_PRO_Project_Group> projectGroups = ORM_TMS_PRO_Project_Group.Query.Search(Connection, Transaction, projectGroupQuery); if (projectGroups.Count == 0) { return(null); } ORM_TMS_PRO_Project_Group projectGroup = projectGroups.FirstOrDefault(); resultProjectGroup.TMS_PRO_Project_GroupID = projectGroup.TMS_PRO_Project_GroupID; resultProjectGroup.ProjectGroup_Name = projectGroup.ProjectGroup_Name; resultProjectGroup.ProjectGroup_Description = projectGroup.ProjectGroup_Description; returnValue.Result.ProjectGroup = resultProjectGroup; return(returnValue); #endregion UserCode }
///<summary> /// Method Invocation of wrapper classes ///<summary> protected static FR_L5PR_GPGFPGID_1319 Invoke(DbConnection Connection, DbTransaction Transaction, string ConnectionString, P_L5PR_GPGFPGID_1319 Parameter, CSV2Core.SessionSecurity.SessionSecurityTicket securityTicket = null) { bool cleanupConnection = Connection == null; bool cleanupTransaction = Transaction == null; FR_L5PR_GPGFPGID_1319 functionReturn = new FR_L5PR_GPGFPGID_1319(); try { if (cleanupConnection == true) { Connection = CSV2Core_MySQL.Support.DBSQLSupport.CreateConnection(ConnectionString); Connection.Open(); } if (cleanupTransaction == true) { Transaction = Connection.BeginTransaction(); } functionReturn = Execute(Connection, Transaction, Parameter, securityTicket); #region Cleanup Connection/Transaction //Commit the transaction if (cleanupTransaction == true) { Transaction.Commit(); } //Close the connection if (cleanupConnection == true) { Connection.Close(); } #endregion } catch (Exception ex) { try { if (cleanupTransaction == true && Transaction != null) { Transaction.Rollback(); } } catch { } try { if (cleanupConnection == true && Connection != null) { Connection.Close(); } } catch { } throw new Exception("Exception occured in method cls_Get_ProjectGroup_For_ProjectGroupID", ex); } return(functionReturn); }