diff --git a/TIAMResources/TIAMResources.Designer.cs b/TIAMResources/TIAMResources.Designer.cs
index f96c908c..2a11c46e 100644
--- a/TIAMResources/TIAMResources.Designer.cs
+++ b/TIAMResources/TIAMResources.Designer.cs
@@ -123,6 +123,15 @@ namespace TIAM.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Send.
+ ///
+ public static string ButtonSend {
+ get {
+ return ResourceManager.GetString("ButtonSend", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Confirm Email.
///
@@ -240,6 +249,15 @@ namespace TIAM.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Html content.
+ ///
+ public static string HtmlContent {
+ get {
+ return ResourceManager.GetString("HtmlContent", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Login.
///
@@ -249,6 +267,24 @@ namespace TIAM.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to New message.
+ ///
+ public static string NewMessage {
+ get {
+ return ResourceManager.GetString("NewMessage", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Let's send them a message!.
+ ///
+ public static string NewMessageSubtitle {
+ get {
+ return ResourceManager.GetString("NewMessageSubtitle", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Passengers.
///
@@ -303,6 +339,15 @@ namespace TIAM.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Receiver Id.
+ ///
+ public static string ReceiverId {
+ get {
+ return ResourceManager.GetString("ReceiverId", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Register.
///
@@ -357,6 +402,15 @@ namespace TIAM.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Subject.
+ ///
+ public static string Subject {
+ get {
+ return ResourceManager.GetString("Subject", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to This works!.
///
@@ -375,6 +429,15 @@ namespace TIAM.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Let's book a transfer!.
+ ///
+ public static string TransferSubtitle {
+ get {
+ return ResourceManager.GetString("TransferSubtitle", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to New Transfer.
///
@@ -384,6 +447,15 @@ namespace TIAM.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Trip date.
+ ///
+ public static string TripDate {
+ get {
+ return ResourceManager.GetString("TripDate", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Wizard.
///
diff --git a/TIAMResources/TIAMResources.hu.resx b/TIAMResources/TIAMResources.hu.resx
index 0ecda8d9..42e71df7 100644
--- a/TIAMResources/TIAMResources.hu.resx
+++ b/TIAMResources/TIAMResources.hu.resx
@@ -138,6 +138,9 @@
Mentés
+
+ Küldés
+
E-mail cím megerősítése
@@ -177,9 +180,18 @@
Teljes név
+
+ Html tartalom
+
Belépés
+
+ Új üzenet
+
+
+ Küldjünk neki egy üzenetet!
+
Utasok száma
@@ -198,6 +210,9 @@
Ár
+
+ Címzett azonosítója
+
Regisztráció
@@ -216,15 +231,24 @@
Új szolgáltató
+
+ Tárgy
+
Müxik!
Új uticél
+
+ Rendeljünk egy transzfert!
+
Új transzfer
+
+ Utazás napja
+
Varázsló
diff --git a/TIAMResources/TIAMResources.resx b/TIAMResources/TIAMResources.resx
index dc9d9124..0ab4d72a 100644
--- a/TIAMResources/TIAMResources.resx
+++ b/TIAMResources/TIAMResources.resx
@@ -138,6 +138,9 @@
Save
+
+ Send
+
Confirm Email
@@ -177,9 +180,18 @@
Full name
+
+ Html content
+
Login
+
+ New message
+
+
+ Let's send them a message!
+
Passengers
@@ -198,6 +210,9 @@
Price
+
+ Receiver Id
+
Register
@@ -216,15 +231,24 @@
New Service provider
+
+ Subject
+
This works!
New destination
+
+ Let's book a transfer!
+
New Transfer
+
+ Trip date
+
Wizard
diff --git a/TIAMSharedUI/Pages/ChooseDestination.razor.cs b/TIAMSharedUI/Pages/ChooseDestination.razor.cs
index 90d3aa01..901eb688 100644
--- a/TIAMSharedUI/Pages/ChooseDestination.razor.cs
+++ b/TIAMSharedUI/Pages/ChooseDestination.razor.cs
@@ -1,4 +1,5 @@
using AyCode.Blazor.Components;
+using DevExpress.Blazor;
using Microsoft.AspNetCore.Components;
using System;
using System.Collections.Generic;
diff --git a/TIAMSharedUI/Pages/Components/InputWizard.razor b/TIAMSharedUI/Pages/Components/InputWizard.razor
index 474e2ce7..ce89e1a1 100644
--- a/TIAMSharedUI/Pages/Components/InputWizard.razor
+++ b/TIAMSharedUI/Pages/Components/InputWizard.razor
@@ -23,8 +23,7 @@
-
-
@localizer.GetString("DestinationName")
+
@_formSubmitResult
diff --git a/TIAMSharedUI/Pages/Components/InputWizard.razor.cs b/TIAMSharedUI/Pages/Components/InputWizard.razor.cs
index cb007381..daa70db9 100644
--- a/TIAMSharedUI/Pages/Components/InputWizard.razor.cs
+++ b/TIAMSharedUI/Pages/Components/InputWizard.razor.cs
@@ -15,6 +15,8 @@ using TIAMWebApp.Shared.Application.Interfaces;
using System.Reflection;
using TIAMWebApp.Shared.Application.Models;
using DevExpress.XtraPrinting;
+using TIAMSharedUI.Shared;
+using DevExpress.Pdf.Native.BouncyCastle.Asn1.Cms;
namespace TIAMSharedUI.Pages.Components
@@ -25,7 +27,7 @@ namespace TIAMSharedUI.Pages.Components
public required LogToBrowserConsole LogToBrowserConsole { get; set; }
[Inject]
- IStringLocalizer localizer { get; set; }
+ IStringLocalizer localizer { get; set; }
public Dictionary FormSteps { get; set; } = new Dictionary();
public int CurrentStep { get; set; } = 0;
@@ -34,6 +36,8 @@ namespace TIAMSharedUI.Pages.Components
[Parameter]
public string TitleResourceString { get; set; } = "Wizard";
+
+ [Parameter]
public string SubtitleResourceString { get; set; } = "Let's fill in this form";
[Parameter]
@@ -45,8 +49,12 @@ namespace TIAMSharedUI.Pages.Components
[Parameter]
public string SubmitButtonText { get; set; } = "Submit";
+ [Required]
+ [Parameter]
+ public List IgnoreReflection { get; set; }
+
+
-
string _formSubmitResult = "";
private string _spinnerClass = "";
@@ -70,7 +78,7 @@ namespace TIAMSharedUI.Pages.Components
_formSubmitResult = debugString;
_spinnerClass = "";
-
+
await OnSubmit.InvokeAsync(Data);
}
@@ -98,33 +106,35 @@ namespace TIAMSharedUI.Pages.Components
LogToBrowserConsole.LogToBC("Hellooooo " + _type.AssemblyQualifiedName);
var propertyList = _type.GetProperties();
+ var _length = propertyList.Length - IgnoreReflection.Count;
//var propertyList = typeof(TestUserData).GetProperties();
formLayoutBuilder.OpenComponent(0);
formLayoutBuilder.AddAttribute(1, "ChildContent", (RenderFragment)((layoutItemBuilder) =>
{
int i = 0;
- int j = 0;
+ int k = 0;
foreach (var property in propertyList)
{
- bool isActive = j == CurrentStep;
+ bool isActive = k == CurrentStep;
//if (property.Name == "Id" || property.Name == "Latitude" || property.Name == "Longitude" || property.Name == "Created" || property.Name == "Modified")
//if (property.Name == "Id" || property.Name == "Created" || property.Name == "Modified")
- if (property.Name == "Id" || property.Name == "Price" || property.Name == "Created" || property.Name == "Modified")
+ if (IgnoreReflection.Contains(property.Name))
{
continue;
}
Guid _stepID = Guid.Empty;
- if (!FormSteps.ContainsKey(j))
+ if (!FormSteps.ContainsKey(k))
{
_stepID = Guid.NewGuid();
- FormSteps.Add(j, _stepID);
+ LogToBrowserConsole.LogToBC($"Adding step {k}, {_stepID}, for {property.Name}");
+ FormSteps.Add(k, _stepID);
}
else
{
- _stepID = FormSteps[j];
+ _stepID = FormSteps[k];
}
//the following line creates an expression that accesses the property value by name
@@ -138,7 +148,7 @@ namespace TIAMSharedUI.Pages.Components
layoutItemBuilder.AddAttribute(i++, "id", _stepID.ToString());
layoutItemBuilder.AddAttribute(i++, "class", "disply-flex align-items-center ");
layoutItemBuilder.AddAttribute(i++, "style", "width: 100%;");
- if (j != CurrentStep)
+ if (k != CurrentStep)
{
layoutItemBuilder.AddAttribute(i++, "hidden", "true");
}
@@ -146,7 +156,7 @@ namespace TIAMSharedUI.Pages.Components
{
//this input should be focused, so we set a flag
LogToBrowserConsole.LogToBC($"Setting focus to {property.Name}");
-
+
}
DataTypeAttribute attrList = (DataTypeAttribute)property.GetCustomAttributes(typeof(DataTypeAttribute), false).First();
@@ -159,7 +169,7 @@ namespace TIAMSharedUI.Pages.Components
layoutItemBuilder.AddAttribute(i++, "Template", (RenderFragment