/// <summary> /// Converts this instance of <see cref="protocolcomponent"/> to an instance of <see cref="protocolcomponentDto"/>. /// </summary> /// <param name="entity"><see cref="protocolcomponent"/> to convert.</param> public static protocolcomponentDto ToDTO(this protocolcomponent entity) { if (entity == null) { return(null); } var dto = new protocolcomponentDto(); dto.v_ProtocolComponentId = entity.v_ProtocolComponentId; dto.v_ProtocolId = entity.v_ProtocolId; dto.v_ComponentId = entity.v_ComponentId; dto.r_Price = entity.r_Price; dto.i_OperatorId = entity.i_OperatorId; dto.i_Age = entity.i_Age; dto.i_GenderId = entity.i_GenderId; dto.i_IsConditionalId = entity.i_IsConditionalId; 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; dto.i_IsConditionalIMC = entity.i_IsConditionalIMC; dto.r_Imc = entity.r_Imc; entity.OnDTO(dto); return(dto); }