|
|
|
|
|
|
|
|
@inject PageHistoryManager PageHistoryManager
|
|
|
@inject PageHistoryManager PageHistoryManager
|
|
|
@inject ReportDataProvider ReportDataProvider
|
|
|
@inject ReportDataProvider ReportDataProvider
|
|
|
@inject Toaster Toaster
|
|
|
@inject Toaster Toaster
|
|
|
@inject InputCursorHandler InputCursorHandler;
|
|
|
|
|
|
|
|
|
@inject InputCursorHandler InputCursorHandler
|
|
|
|
|
|
@inject MasterDataService MasterDataService
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div class="row px-3 h-100">
|
|
|
<div class="row px-3 h-100">
|
|
|
|
|
|
|
|
|
<div class="row no-gutters w-100">
|
|
|
<div class="row no-gutters w-100">
|
|
|
<div class="col-12">
|
|
|
<div class="col-12">
|
|
|
<MatSelect Class="w-100 required" Label="@I18n["Salutation"]" Outlined="true" @bind-Value="pucSalutation" Required="true" Style="margin-bottom: 0.5rem"
|
|
|
<MatSelect Class="w-100 required" Label="@I18n["Salutation"]" Outlined="true" @bind-Value="pucSalutation" Required="true" Style="margin-bottom: 0.5rem"
|
|
|
@onkeydown="InputCursorHandler.OnKeyDownHandlerAsync">
|
|
|
|
|
|
|
|
|
@onkeydown="InputCursorHandler.OnKeyDownHandlerAsync">
|
|
|
<MatOptionString Value="M">@I18n["Male"]</MatOptionString>
|
|
|
<MatOptionString Value="M">@I18n["Male"]</MatOptionString>
|
|
|
<MatOptionString Value="F">@I18n["Female"]</MatOptionString>
|
|
|
<MatOptionString Value="F">@I18n["Female"]</MatOptionString>
|
|
|
</MatSelect>
|
|
|
</MatSelect>
|
|
|
|
|
|
|
|
|
<div class="row no-gutters w-100">
|
|
|
<div class="row no-gutters w-100">
|
|
|
<div class="col-6" style="padding-right:0.5em">
|
|
|
<div class="col-6" style="padding-right:0.5em">
|
|
|
<MatStringField Class="w-100" Label="@I18n["Firstname"]" Outlined="true" type="text" @bind-Value="pucFirstname" Required="true"
|
|
|
<MatStringField Class="w-100" Label="@I18n["Firstname"]" Outlined="true" type="text" @bind-Value="pucFirstname" Required="true"
|
|
|
OnKeyDown="@InputCursorHandler.OnKeyDownHandlerAsync"></MatStringField>
|
|
|
|
|
|
|
|
|
OnKeyDown="@InputCursorHandler.OnKeyDownHandlerAsync"></MatStringField>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="col-6" style="padding-left:0.5em">
|
|
|
<div class="col-6" style="padding-left:0.5em">
|
|
|
<MatStringField Class="w-100" Label="@I18n["Lastname"]" Outlined="true" type="text" @bind-Value="pucLastname" Required="true"
|
|
|
<MatStringField Class="w-100" Label="@I18n["Lastname"]" Outlined="true" type="text" @bind-Value="pucLastname" Required="true"
|
|
|
OnKeyDown="@InputCursorHandler.OnKeyDownHandlerAsync"></MatStringField>
|
|
|
|
|
|
|
|
|
OnKeyDown="@InputCursorHandler.OnKeyDownHandlerAsync"></MatStringField>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="row no-gutters align-items-center w-100">
|
|
|
<div class="row no-gutters align-items-center w-100">
|
|
|
<div class="col-12">
|
|
|
<div class="col-12">
|
|
|
<MatStringField Class="w-100" Label="@I18n["Address"]" Outlined="true" type="text" @bind-Value="pucAddress" Required="true"
|
|
|
<MatStringField Class="w-100" Label="@I18n["Address"]" Outlined="true" type="text" @bind-Value="pucAddress" Required="true"
|
|
|
OnKeyDown="@InputCursorHandler.OnKeyDownHandlerAsync"></MatStringField>
|
|
|
|
|
|
|
|
|
OnKeyDown="@InputCursorHandler.OnKeyDownHandlerAsync"></MatStringField>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
|
|
|
<div class="row no-gutters align-items-center w-100">
|
|
|
<div class="row no-gutters align-items-center w-100">
|
|
|
|
|
|
<div class="col-12">
|
|
|
|
|
|
<div class="outlined">
|
|
|
|
|
|
<MatAutocompleteList TItem="ZipCity" FullWidth="true" Label="@getZipCityLbl()" Required="true" Items="@ZipCities" OnTextChanged="setZipCityValue" @bind-Value="SelectedZipCity" CustomStringSelector="@(i => i?.Zip_City)"
|
|
|
|
|
|
ShowClearButton="true" NumberOfElementsInPopup="6" @onkeydown="InputCursorHandler.OnKeyDownHandlerAsync">
|
|
|
|
|
|
<ItemTemplate>
|
|
|
|
|
|
<div>
|
|
|
|
|
|
<span>@context?.Zip_City</span>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</ItemTemplate>
|
|
|
|
|
|
</MatAutocompleteList>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@*<div class="row no-gutters align-items-center w-100">
|
|
|
<div class="col-4" style="padding-right:0.5em">
|
|
|
<div class="col-4" style="padding-right:0.5em">
|
|
|
<MatStringField Class="w-100" Label="@I18n["Zip"]" Outlined="true" type="text" @bind-Value="pucZip" Required="true"
|
|
|
<MatStringField Class="w-100" Label="@I18n["Zip"]" Outlined="true" type="text" @bind-Value="pucZip" Required="true"
|
|
|
OnKeyDown="@InputCursorHandler.OnKeyDownHandlerAsync"></MatStringField>
|
|
|
|
|
|
|
|
|
OnKeyDown="@InputCursorHandler.OnKeyDownHandlerAsync"></MatStringField>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="col-8" style="padding-left:0.5em">
|
|
|
<div class="col-8" style="padding-left:0.5em">
|
|
|
<MatStringField Class="w-100" Label="@I18n["City"]" Outlined="true" type="text" @bind-Value="pucCity" Required="true"
|
|
|
<MatStringField Class="w-100" Label="@I18n["City"]" Outlined="true" type="text" @bind-Value="pucCity" Required="true"
|
|
|
OnKeyDown="@InputCursorHandler.OnKeyDownHandlerAsync"></MatStringField>
|
|
|
|
|
|
|
|
|
OnKeyDown="@InputCursorHandler.OnKeyDownHandlerAsync"></MatStringField>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
|
|
|
</div>*@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div class="row no-gutters align-items-center w-100">
|
|
|
<div class="row no-gutters align-items-center w-100">
|
|
|
<div class="col-12">
|
|
|
<div class="col-12">
|
|
|
<MatStringField Class="w-100" Label="@I18n["Mobile"]" Outlined="true" type="text" @bind-Value="pucMobile"
|
|
|
<MatStringField Class="w-100" Label="@I18n["Mobile"]" Outlined="true" type="text" @bind-Value="pucMobile"
|
|
|
OnKeyDown="@InputCursorHandler.OnKeyDownHandlerAsync"></MatStringField>
|
|
|
|
|
|
|
|
|
OnKeyDown="@InputCursorHandler.OnKeyDownHandlerAsync"></MatStringField>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="row no-gutters align-items-center w-100">
|
|
|
<div class="row no-gutters align-items-center w-100">
|
|
|
<div class="col-12">
|
|
|
<div class="col-12">
|
|
|
<MatStringField Class="w-100" Label="@I18n["Phone"]" Outlined="true" type="text" @bind-Value="pucPhone"
|
|
|
<MatStringField Class="w-100" Label="@I18n["Phone"]" Outlined="true" type="text" @bind-Value="pucPhone"
|
|
|
OnKeyDown="@InputCursorHandler.OnKeyDownHandlerAsync"></MatStringField>
|
|
|
|
|
|
|
|
|
OnKeyDown="@InputCursorHandler.OnKeyDownHandlerAsync"></MatStringField>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="row no-gutters align-items-center w-100">
|
|
|
<div class="row no-gutters align-items-center w-100">
|
|
|
<div class="col-12">
|
|
|
<div class="col-12">
|
|
|
<MatStringField Class="w-100" Label="@I18n["Mail"]" Outlined="true" type="text" @bind-Value="pucEmail"
|
|
|
<MatStringField Class="w-100" Label="@I18n["Mail"]" Outlined="true" type="text" @bind-Value="pucEmail"
|
|
|
OnKeyDown="@InputCursorHandler.OnKeyDownHandlerAsync"></MatStringField>
|
|
|
|
|
|
|
|
|
OnKeyDown="@InputCursorHandler.OnKeyDownHandlerAsync"></MatStringField>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
|
|
|
private string pucFirstname;
|
|
|
private string pucFirstname;
|
|
|
private string pucLastname;
|
|
|
private string pucLastname;
|
|
|
private string pucAddress;
|
|
|
private string pucAddress;
|
|
|
private string pucZip;
|
|
|
|
|
|
private string pucCity;
|
|
|
|
|
|
|
|
|
//private string pucZip;
|
|
|
|
|
|
//private string pucCity;
|
|
|
private string pucMobile;
|
|
|
private string pucMobile;
|
|
|
private string pucPhone;
|
|
|
private string pucPhone;
|
|
|
private string pucEmail;
|
|
|
private string pucEmail;
|
|
|
|
|
|
|
|
|
|
|
|
private string pucZipCityStringValue;
|
|
|
|
|
|
private ZipCity selectedZipCity;
|
|
|
|
|
|
private ZipCity SelectedZipCity {
|
|
|
|
|
|
get { return selectedZipCity; }
|
|
|
|
|
|
set { selectedZipCity = (value != null) ? value : new ZipCity(pucZipCityStringValue); }
|
|
|
|
|
|
}
|
|
|
|
|
|
private void setZipCityValue(string value) {
|
|
|
|
|
|
pucZipCityStringValue = value;
|
|
|
|
|
|
selectedZipCity = null;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
private ZipCity[] ZipCities {
|
|
|
|
|
|
get => MasterDataService.ZipCities;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
protected override void OnInitialized() {
|
|
|
protected override void OnInitialized() {
|
|
|
base.OnInitialized();
|
|
|
base.OnInitialized();
|
|
|
PageHistoryManager.OnBeforeNavigateBack = new EventCallback(this, (Action)OnBeforeNavigateBack);
|
|
|
PageHistoryManager.OnBeforeNavigateBack = new EventCallback(this, (Action)OnBeforeNavigateBack);
|
|
|
|
|
|
|
|
|
NavigationManager.NavigateTo("caritas_services");
|
|
|
NavigationManager.NavigateTo("caritas_services");
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
private string getZipCityLbl() {
|
|
|
|
|
|
return String.Format("{0} {1} ({2})", I18n.GetString("Zip"), I18n.GetString("City"), I18n.GetString("PlaceOfDiscovery"));
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
private void refreshGUIFromDto() {
|
|
|
private void refreshGUIFromDto() {
|
|
|
FoundReport report = ReportDataProvider.GetFoundReport();
|
|
|
FoundReport report = ReportDataProvider.GetFoundReport();
|
|
|
pucSalutation = report.AbholAnrede;
|
|
|
pucSalutation = report.AbholAnrede;
|
|
|
pucFirstname = report.AbholVorname;
|
|
|
pucFirstname = report.AbholVorname;
|
|
|
pucLastname = report.AbholNachname;
|
|
|
pucLastname = report.AbholNachname;
|
|
|
pucAddress = report.AbholStrasse;
|
|
|
pucAddress = report.AbholStrasse;
|
|
|
pucZip = report.AbholPLZ;
|
|
|
|
|
|
pucCity = report.AbholOrt;
|
|
|
|
|
|
|
|
|
//pucZip = report.AbholPLZ;
|
|
|
|
|
|
//pucCity = report.AbholOrt;
|
|
|
|
|
|
|
|
|
|
|
|
setZipCityValue(getZipCityFromReport(report));
|
|
|
|
|
|
SelectedZipCity = Array.Find(ZipCities, zipCity => (zipCity.Zip.Equals(report.AbholPLZ) && zipCity.City.Equals(report.AbholOrt)));
|
|
|
|
|
|
|
|
|
pucMobile = report.AbholMobil;
|
|
|
pucMobile = report.AbholMobil;
|
|
|
pucPhone = report.AbholTelefon;
|
|
|
pucPhone = report.AbholTelefon;
|
|
|
pucEmail = report.AbholMail;
|
|
|
pucEmail = report.AbholMail;
|
|
|
|
|
|
|
|
|
report.AbholVorname = pucFirstname;
|
|
|
report.AbholVorname = pucFirstname;
|
|
|
report.AbholNachname = pucLastname;
|
|
|
report.AbholNachname = pucLastname;
|
|
|
report.AbholStrasse = pucAddress;
|
|
|
report.AbholStrasse = pucAddress;
|
|
|
report.AbholPLZ = pucZip;
|
|
|
|
|
|
report.AbholOrt = pucCity;
|
|
|
|
|
|
|
|
|
//report.AbholPLZ = pucZip;
|
|
|
|
|
|
//report.AbholOrt = pucCity;
|
|
|
|
|
|
report.AbholPLZ = SelectedZipCity.Zip;
|
|
|
|
|
|
report.AbholOrt = SelectedZipCity.City;
|
|
|
report.AbholMobil = pucMobile;
|
|
|
report.AbholMobil = pucMobile;
|
|
|
report.AbholTelefon = pucPhone;
|
|
|
report.AbholTelefon = pucPhone;
|
|
|
report.AbholMail = pucEmail;
|
|
|
report.AbholMail = pucEmail;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
private String getZipCityFromReport(FoundReport report) {
|
|
|
|
|
|
return report.AbholPLZ + (!String.IsNullOrEmpty(report.AbholOrt)? " " + report.AbholOrt: "");
|
|
|
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|