Migliorati form Cliente e PersonaRif
This commit is contained in:
@@ -19,5 +19,13 @@ public class MappingProfile : Profile
|
||||
CreateMap<PtbPros, ContactDTO>()
|
||||
.ForMember(dest => dest.CodContact, opt => opt.MapFrom(src => src.CodPpro))
|
||||
.ForMember(dest => dest.IsContact, opt => opt.MapFrom(src => false));
|
||||
|
||||
//Mapping da VtbCliePersRif a PersRifDTO
|
||||
CreateMap<VtbCliePersRif, PersRifDTO>()
|
||||
.ForMember(x => x.CodPersRif, y => y.MapFrom(z => z.CodAnag));
|
||||
|
||||
//Mapping da PtbProsRif a PersRifDTO
|
||||
CreateMap<PtbProsRif, PersRifDTO>()
|
||||
.ForMember(x => x.CodPersRif, y => y.MapFrom(z => z.CodPpro));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -26,13 +26,32 @@ public class ModalHelpers
|
||||
return await modal.Result;
|
||||
}
|
||||
|
||||
public static async Task<DialogResult?> OpenUserForm(IDialogService dialog, string? codAnag)
|
||||
public static async Task<DialogResult?> OpenUserForm(IDialogService dialog, ContactDTO? anag)
|
||||
{
|
||||
var modal = await dialog.ShowAsync<ContactForm>(
|
||||
"User form",
|
||||
new DialogParameters<ContactForm>
|
||||
{
|
||||
{ x => x.CodAnag, codAnag }
|
||||
{ x => x.OriginalModel, anag }
|
||||
},
|
||||
new DialogOptions
|
||||
{
|
||||
FullScreen = true,
|
||||
CloseButton = false,
|
||||
NoHeader = true
|
||||
}
|
||||
);
|
||||
|
||||
return await modal.Result;
|
||||
}
|
||||
|
||||
public static async Task<DialogResult?> OpenPersRifForm(IDialogService dialog, PersRifDTO? persRif)
|
||||
{
|
||||
var modal = await dialog.ShowAsync<PersRifForm>(
|
||||
"Pers rif form",
|
||||
new DialogParameters<PersRifForm>
|
||||
{
|
||||
{ x => x.OriginalModel, persRif }
|
||||
},
|
||||
new DialogOptions
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user