Ejemplo n.º 1
0
 /// <summary>
 /// Enum types are equal by primary key
 /// </summary>
 public bool Equals(TechnicalAssistanceType other)
 {
     if (other == null)
     {
         return(false);
     }
     return(other.TechnicalAssistanceTypeID == TechnicalAssistanceTypeID);
 }
 /// <summary>
 /// Constructor for building a new object with MinimalConstructor required fields, using objects whenever possible
 /// </summary>
 public TechnicalAssistanceRequest(Project project, int fiscalYear, TechnicalAssistanceType technicalAssistanceType) : this()
 {
     // Mark this as a new object by setting primary key with special value
     this.TechnicalAssistanceRequestID = ModelObjectHelpers.MakeNextUnsavedPrimaryKeyValue();
     this.ProjectID = project.ProjectID;
     this.Project   = project;
     project.TechnicalAssistanceRequests.Add(this);
     this.FiscalYear = fiscalYear;
     this.TechnicalAssistanceTypeID = technicalAssistanceType.TechnicalAssistanceTypeID;
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Creates a "blank" object of this type and populates primitives with defaults
 /// </summary>
 public static TechnicalAssistanceRequestUpdate CreateNewBlank(ProjectUpdateBatch projectUpdateBatch, TechnicalAssistanceType technicalAssistanceType)
 {
     return(new TechnicalAssistanceRequestUpdate(projectUpdateBatch, default(int), technicalAssistanceType));
 }
 /// <summary>
 /// Creates a "blank" object of this type and populates primitives with defaults
 /// </summary>
 public static TechnicalAssistanceRequest CreateNewBlank(Project project, TechnicalAssistanceType technicalAssistanceType)
 {
     return(new TechnicalAssistanceRequest(project, default(int), technicalAssistanceType));
 }