Esempio n. 1
0
 public componentfieldvaluesrestrictionDto(String v_ComponentFieldValuesRestrictionId, String v_ComponentFieldValuesId, String v_MasterRecommendationRestricctionId, Nullable <Int32> i_IsDeleted, Nullable <Int32> i_InsertUserId, Nullable <DateTime> d_InsertDate, Nullable <Int32> i_UpdateUserId, Nullable <DateTime> d_UpdateDate, componentfieldvaluesDto componentfieldvalues, masterrecommendationrestricctionDto masterrecommendationrestricction)
 {
     this.v_ComponentFieldValuesRestrictionId  = v_ComponentFieldValuesRestrictionId;
     this.v_ComponentFieldValuesId             = v_ComponentFieldValuesId;
     this.v_MasterRecommendationRestricctionId = v_MasterRecommendationRestricctionId;
     this.i_IsDeleted                      = i_IsDeleted;
     this.i_InsertUserId                   = i_InsertUserId;
     this.d_InsertDate                     = d_InsertDate;
     this.i_UpdateUserId                   = i_UpdateUserId;
     this.d_UpdateDate                     = d_UpdateDate;
     this.componentfieldvalues             = componentfieldvalues;
     this.masterrecommendationrestricction = masterrecommendationrestricction;
 }
        /// <summary>
        /// Converts this instance of <see cref="masterrecommendationrestricction"/> to an instance of <see cref="masterrecommendationrestricctionDto"/>.
        /// </summary>
        /// <param name="entity"><see cref="masterrecommendationrestricction"/> to convert.</param>
        public static masterrecommendationrestricctionDto ToDTO(this masterrecommendationrestricction entity)
        {
            if (entity == null)
            {
                return(null);
            }

            var dto = new masterrecommendationrestricctionDto();

            dto.v_MasterRecommendationRestricctionId = entity.v_MasterRecommendationRestricctionId;
            dto.v_Name         = entity.v_Name;
            dto.i_TypifyingId  = entity.i_TypifyingId;
            dto.i_IsDeleted    = entity.i_IsDeleted;
            dto.i_InsertUserId = entity.i_InsertUserId;
            dto.d_InsertDate   = entity.d_InsertDate;
            dto.i_UpdateUserId = entity.i_UpdateUserId;
            dto.d_UpdateDate   = entity.d_UpdateDate;

            entity.OnDTO(dto);

            return(dto);
        }
        /// <summary>
        /// Converts this instance of <see cref="masterrecommendationrestricctionDto"/> to an instance of <see cref="masterrecommendationrestricction"/>.
        /// </summary>
        /// <param name="dto"><see cref="masterrecommendationrestricctionDto"/> to convert.</param>
        public static masterrecommendationrestricction ToEntity(this masterrecommendationrestricctionDto dto)
        {
            if (dto == null)
            {
                return(null);
            }

            var entity = new masterrecommendationrestricction();

            entity.v_MasterRecommendationRestricctionId = dto.v_MasterRecommendationRestricctionId;
            entity.v_Name         = dto.v_Name;
            entity.i_TypifyingId  = dto.i_TypifyingId;
            entity.i_IsDeleted    = dto.i_IsDeleted;
            entity.i_InsertUserId = dto.i_InsertUserId;
            entity.d_InsertDate   = dto.d_InsertDate;
            entity.i_UpdateUserId = dto.i_UpdateUserId;
            entity.d_UpdateDate   = dto.d_UpdateDate;

            dto.OnEntity(entity);

            return(entity);
        }
 /// <summary>
 /// Invoked when <see cref="ToEntity"/> operation is about to return.
 /// </summary>
 /// <param name="entity"><see cref="masterrecommendationrestricction"/> converted from <see cref="masterrecommendationrestricctionDto"/>.</param>
 static partial void OnEntity(this masterrecommendationrestricctionDto dto, masterrecommendationrestricction entity);
 /// <summary>
 /// Invoked when <see cref="ToDTO"/> operation is about to return.
 /// </summary>
 /// <param name="dto"><see cref="masterrecommendationrestricctionDto"/> converted from <see cref="masterrecommendationrestricction"/>.</param>
 static partial void OnDTO(this masterrecommendationrestricction entity, masterrecommendationrestricctionDto dto);