Ejemplo n.º 1
0
 /// <summary>
 /// Validates the master detail delete.
 /// </summary>
 /// <param name="masterDetail">The master detail.</param>
 /// <returns>
 /// List of error list item
 /// </returns>
 public ErrorListItem ValidateDelete(MasterDetail masterDetail)
 {
     return this.artifactRepository.ValidateDelete(MapToArtifact(masterDetail, default(int)));
 }
 /// <summary>
 /// Inserts or Update the master detail.
 /// </summary>
 /// <param name="masterDetail">The master detail.</param>
 /// <param name="userId">The user identifier.</param>
 public void InsertOrUpdate(MasterDetail masterDetail, int userId)
 {
     this.estimationCategoryRepository.InsertOrUpdate(MapToEstimationCategory(masterDetail, userId));
     this.unitOfWork.Save();
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Validates master detail.
 /// </summary>
 /// <param name="masterDetail">The master detail.</param>
 /// <param name="userId">The user identifier.</param>
 /// <returns>
 /// List of error list item.
 /// </returns>
 public ErrorListItem Validate(MasterDetail masterDetail, int userId)
 {
     return this.artifactRepository.Validate(MapToArtifact(masterDetail, userId), userId);
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Validates master detail.
 /// </summary>
 /// <param name="masterDetail">The master detail.</param>
 /// <param name="userId">The user identifier.</param>
 /// <returns>
 /// List of error list item.
 /// </returns>
 public ErrorListItem Validate(MasterDetail masterDetail, int userId)
 {
     return this.designationRepository.Validate(MapToDesignation(masterDetail, userId), userId);
 }
 /// <summary>
 /// Maps to estimation category.
 /// </summary>
 /// <param name="masterDetails">The master details.</param>
 /// <param name="userId">The user identifier.</param>
 /// <returns>
 /// Estimation category information.
 /// </returns>
 private static EstimationCategory MapToEstimationCategory(MasterDetail masterDetails, int userId)
 {
     return new EstimationCategory()
     {
         Name = masterDetails.Name,
         RoleGroupID = masterDetails.GroupId,
         EstimationCategoryID = masterDetails.MasterDetailId,
         ModifiedByDeveloperID = userId != default(int) ? userId : default(int?)
     };
 }
Ejemplo n.º 6
0
 /// <summary>
 /// Validates master detail.
 /// </summary>
 /// <param name="masterDetail">The master detail.</param>
 /// <param name="userId">The user identifier.</param>
 /// <returns>
 /// List of error list item.
 /// </returns>
 public ErrorListItem Validate(MasterDetail masterDetail, int userId)
 {
     return this.roleGroupRepository.Validate(MapToRoleGroup(masterDetail, userId), userId);
 }
Ejemplo n.º 7
0
 /// <summary>
 /// Maps to role group.
 /// </summary>
 /// <param name="masterDetails">The master details.</param>
 /// <param name="userId">The user identifier.</param>
 /// <returns>
 /// Role group information.
 /// </returns>
 private static RoleGroup MapToRoleGroup(MasterDetail masterDetails, int userId)
 {
     return new RoleGroup()
     {
         Name = masterDetails.Name,
         RoleGroupID = masterDetails.MasterDetailId,
         Sequence = default(int?),
         ModifiedByDeveloperID = userId != default(int) ? userId : default(int?)
     };
 }
Ejemplo n.º 8
0
 /// <summary>
 /// Validates master detail.
 /// </summary>
 /// <param name="masterDetail">The master detail.</param>
 /// <param name="userId">The user identifier.</param>
 /// <returns>
 /// List of error list item.
 /// </returns>
 public ErrorListItem Validate(MasterDetail masterDetail, int userId)
 {
     return this.clientRepository.Validate(MapToClient(masterDetail, userId), userId);
 }
Ejemplo n.º 9
0
 /// <summary>
 /// Validates the master detail delete.
 /// </summary>
 /// <param name="masterDetail">The master detail.</param>
 /// <returns>
 /// List of error list item
 /// </returns>
 public ErrorListItem ValidateDelete(MasterDetail masterDetail)
 {
     return this.clientRepository.ValidateDelete(MapToClient(masterDetail, default(int)));
 }
Ejemplo n.º 10
0
 /// <summary>
 /// Validates master detail.
 /// </summary>
 /// <param name="masterDetail">The master detail.</param>
 /// <param name="userId">The user identifier.</param>
 /// <returns>
 /// List of error list item.
 /// </returns>
 public ErrorListItem Validate(MasterDetail masterDetail, int userId)
 {
     return this.workCategoryRepository.Validate(MapToWorkCategory(masterDetail, userId), userId);
 }
Ejemplo n.º 11
0
 /// <summary>
 /// Maps to work category.
 /// </summary>
 /// <param name="masterDetails">The master details.</param>
 /// <param name="userId">The user identifier.</param>
 /// <returns>
 /// Work category information.
 /// </returns>
 private static WorkCategory MapToWorkCategory(MasterDetail masterDetails, int userId)
 {
     return new WorkCategory()
     {
         Name = masterDetails.Name,
         CategoryID = masterDetails.MasterDetailId,
         RowVersion = null,
         ModifiedByDeveloperID = userId != default(int) ? userId : default(int?),
         WorkCategoryGroupID = masterDetails.GroupId,
     };
 }
Ejemplo n.º 12
0
 /// <summary>
 /// Inserts or Update the master detail.
 /// </summary>
 /// <param name="masterDetail">The master detail.</param>
 /// <param name="userId">The user identifier.</param>
 public void InsertOrUpdate(MasterDetail masterDetail, int userId)
 {
     this.designationRepository.InsertOrUpdate(MapToDesignation(masterDetail, userId));
     this.unitOfWork.Save();
 }
Ejemplo n.º 13
0
 /// <summary>
 /// Maps to designation.
 /// </summary>
 /// <param name="masterDetails">The master details.</param>
 /// <param name="userId">The user identifier.</param>
 /// <returns>
 /// Designation information.
 /// </returns>
 private static Designation MapToDesignation(MasterDetail masterDetails, int userId)
 {
     return new Designation()
     {
         Name = masterDetails.Name,
         DesignationID = masterDetails.MasterDetailId,
         ModifiedByDeveloperID = userId != default(int) ? userId : default(int?)
     };
 }
Ejemplo n.º 14
0
 /// <summary>
 /// Validates the master detail delete.
 /// </summary>
 /// <param name="masterDetail">The master detail.</param>
 /// <returns>
 /// List of error list item
 /// </returns>
 public ErrorListItem ValidateDelete(MasterDetail masterDetail)
 {
     return this.designationRepository.ValidateDelete(MapToDesignation(masterDetail, default(int)));
 }
Ejemplo n.º 15
0
 /// <summary>
 /// Maps to artifact.
 /// </summary>
 /// <param name="masterDetails">The master details.</param>
 /// <param name="userId">The user identifier.</param>
 /// <returns>
 /// Artifact information.
 /// </returns>
 private static Artifact MapToArtifact(MasterDetail masterDetails, int userId)
 {
     return new Artifact()
     {
         Name = masterDetails.Name,
         ArtifactID = Convert.ToByte(masterDetails.MasterDetailId),
         ModifiedByDeveloperID = userId != default(int) ? userId : default(int?)
     };
 }
Ejemplo n.º 16
0
 /// <summary>
 /// Maps to client.
 /// </summary>
 /// <param name="masterDetails">The master details.</param>
 /// <param name="userId">The user identifier.</param>
 /// <returns>
 /// Designation information.
 /// </returns>
 private static Client MapToClient(MasterDetail masterDetails, int userId)
 {
     return new Client()
     {
         Name = masterDetails.Name,
         DoNotListFlag = masterDetails.IsInactive,
         ClientID = masterDetails.MasterDetailId,
         ModifiedByDeveloperID = userId != default(int) ? userId : default(int?)
     };
 }
Ejemplo n.º 17
0
 /// <summary>
 /// Inserts or Update the master detail.
 /// </summary>
 /// <param name="masterDetail">The master detail.</param>
 /// <param name="userId">The user identifier.</param>
 public void InsertOrUpdate(MasterDetail masterDetail, int userId)
 {
     this.artifactRepository.InsertOrUpdate(MapToArtifact(masterDetail, userId));
     this.unitOfWork.Save();
 }
 /// <summary>
 /// Validates master detail.
 /// </summary>
 /// <param name="masterDetail">The master detail.</param>
 /// <param name="userId">The user identifier.</param>
 /// <returns>
 /// List of error list item.
 /// </returns>
 public ErrorListItem Validate(MasterDetail masterDetail, int userId)
 {
     return this.estimationCategoryRepository.Validate(MapToEstimationCategory(masterDetail, userId), userId);
 }
Ejemplo n.º 19
0
 /// <summary>
 /// Validates the master detail delete.
 /// </summary>
 /// <param name="masterDetail">The master detail.</param>
 /// <returns>
 /// List of error list item
 /// </returns>
 public ErrorListItem ValidateDelete(MasterDetail masterDetail)
 {
     return this.roleGroupRepository.ValidateDelete(MapToRoleGroup(masterDetail, default(int)));
 }
 /// <summary>
 /// Validates the master detail delete.
 /// </summary>
 /// <param name="masterDetail">The master detail.</param>
 /// <returns>
 /// List of error list item
 /// </returns>
 public ErrorListItem ValidateDelete(MasterDetail masterDetail)
 {
     return this.estimationCategoryRepository.ValidateDelete(MapToEstimationCategory(masterDetail, default(int)));
 }
Ejemplo n.º 21
0
 /// <summary>
 /// Inserts or Update the master detail.
 /// </summary>
 /// <param name="masterDetail">The master detail.</param>
 /// <param name="userId">The user identifier.</param>
 public void InsertOrUpdate(MasterDetail masterDetail, int userId)
 {
     this.roleGroupRepository.InsertOrUpdate(MapToRoleGroup(masterDetail, userId));
     this.unitOfWork.Save();
 }
 /// <summary>
 /// Maps to work category group.
 /// </summary>
 /// <param name="masterDetails">The master details.</param>
 /// <param name="userId">The user identifier.</param>
 /// <returns>
 /// Work category group information.
 /// </returns>
 private static WorkCategoryGroup MapToWorkCategoryGroup(MasterDetail masterDetails, int userId)
 {
     return new WorkCategoryGroup()
     {
         WorkCategory = masterDetails.Name,
         WorkCategoryGroupID = masterDetails.MasterDetailId,
         ModifiedByDeveloperID = userId != default(int) ? userId : default(int?)
     };
 }