Questions tagged as 'automapper'

1
answer

Dependency Injection - Error: InvalidOperationException: Unable to resolve service for type

Friends, once more I come to you for help. When trying to call an Action from my Controller I'm getting the problem described below:    An unhandled exception occurred while processing the request.   InvalidOperationException: Unable to re...
asked by 07.10.2018 / 17:00
1
answer

Automapper with IoC

public class Vigencia { public DateTime DataInicialVigencia { get; set; } public DateTime DataFinalVigencia { get; set; } public Guid VeiculoId { get; set; } public Guid RastreadorId { get; set; } } public class Veiculo { pub...
asked by 20.12.2016 / 09:55
1
answer

ASP.NET MVC: Automapper and NHibernate

Good evening, I have a problem. I'm using nHibernate to connect to my database and I also use Automapper to map my Entities to my ViewModel. But when I select the entity I have several relationships and when I map to the ViewModel it ends up...
asked by 10.10.2015 / 00:42
0
answers

Ignore property ICollection AutoMapper does not work

Personal I'm having trouble to ignore a property that is like ICollection and another one that is like Generic Class. Type I am ignoring in the Profile Map class Address, it works only when Mapea PersonAddressEditViewModel > Person, when mapp...
asked by 06.12.2018 / 21:29
0
answers

Automapper error in relationship

I have the following classes: public class ListaGrupo : EntidadeBase { public ListaGrupo() { Items = new List<ListaGrupoItem>(); } public int Id { get; set; } public string Nome { get; set; } public virtu...
asked by 13.10.2016 / 21:26
0
answers

Automapper with related entity

Good afternoon, Mapping the following entities public class Artista { public Artista() { ArtistaCategoria = new List<ArtistaCategoria>(); } public int ArtistaId { get; set; } p...
asked by 16.05.2016 / 21:33
1
answer

Problem with AutoMapper relationship many to many C #

I have two classes with a many-to-many relationship, all the mapping is ready, the insert is working, but when I try to do AutoMapper it goes into an infinite loop. Workflow: public class Workflow : Elemento { public IList&l...
asked by 21.01.2016 / 17:32
0
answers

The number of generic arguments provided is not equal to the generic definition definition. Parameter name: instantiation

I'm having a problem while developing an application in Asp.net MVC with IOC, Automapper and all other screens work perfectly, just not for Drivers. Unable to identify the error, could they help me? Follow the controllers, and the other classes,...
asked by 02.12.2015 / 12:55
1
answer

Map sub-property

I have three classes public class Ligacao { public string Guid { get; set; } public string Telefone { get; set; } public Status Status { get; set; } public string ArquivoJson { get; set; } public DateTime DataCriacao { get;...
asked by 12.04.2018 / 22:31
1
answer

Isolate Presentation Layer Domain

Good software architecture practice says that the presentation layer does not must know the domain layer. I'm trying to make this isolation between these layers, but the which is making this separation difficult is the mapping framework of objec...
asked by 23.10.2018 / 18:01