diff --git a/RFiDGear.sln b/RFiDGear.sln
index ce87127..315c461 100644
--- a/RFiDGear.sln
+++ b/RFiDGear.sln
@@ -9,8 +9,6 @@ Project("{930C7802-8A8C-48F9-8165-68863BCCD9DD}") = "Setup", "Setup\Setup.wixpro
EndProject
Project("{930C7802-8A8C-48F9-8165-68863BCCD9DD}") = "RFiDGearBundleSetup", "RFiDGearBundleSetup\RFiDGearBundleSetup.wixproj", "{5A7DF993-C696-4958-B7C9-9396122DFF21}"
EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "VCNEditor", "..\VCNEditor\VCNEditor.csproj", "{909DB876-4A74-42AC-BACF-C681017D0C77}"
-EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ByteArray", "..\ByteArray\ByteArray.csproj", "{BDD5DF8C-6FC1-4882-8151-924820FDBC05}"
ProjectSection(ProjectDependencies) = postProject
{786D71E7-4D92-43E4-A9EB-4E07FFE36F70} = {786D71E7-4D92-43E4-A9EB-4E07FFE36F70}
@@ -20,9 +18,11 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Elatec.NET", "..\Elatec.NET
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Log4CSharp", "..\Log4CSharp\Log4CSharp.csproj", "{786D71E7-4D92-43E4-A9EB-4E07FFE36F70}"
EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "PluginSystem", "..\PluginSystem\PluginSystem.csproj", "{E99B606A-25B8-4113-9E75-5016CCFDB410}"
+EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MVVMDialogs", "..\MVVMDialogs\MVVMDialogs.csproj", "{EF56252E-257F-41D1-974B-C9015071CE7E}"
EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "PluginSystem", "..\PluginSystem\PluginSystem.csproj", "{E99B606A-25B8-4113-9E75-5016CCFDB410}"
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "VCNEditor", "..\VCNEditor\VCNEditor.csproj", "{909DB876-4A74-42AC-BACF-C681017D0C77}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -62,18 +62,6 @@ Global
{5A7DF993-C696-4958-B7C9-9396122DFF21}.Release|x64.ActiveCfg = Release|x86
{5A7DF993-C696-4958-B7C9-9396122DFF21}.Release|x86.ActiveCfg = Release|x86
{5A7DF993-C696-4958-B7C9-9396122DFF21}.Release|x86.Build.0 = Release|x86
- {909DB876-4A74-42AC-BACF-C681017D0C77}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {909DB876-4A74-42AC-BACF-C681017D0C77}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {909DB876-4A74-42AC-BACF-C681017D0C77}.Debug|x64.ActiveCfg = Debug|x64
- {909DB876-4A74-42AC-BACF-C681017D0C77}.Debug|x64.Build.0 = Debug|x64
- {909DB876-4A74-42AC-BACF-C681017D0C77}.Debug|x86.ActiveCfg = Debug|Any CPU
- {909DB876-4A74-42AC-BACF-C681017D0C77}.Debug|x86.Build.0 = Debug|Any CPU
- {909DB876-4A74-42AC-BACF-C681017D0C77}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {909DB876-4A74-42AC-BACF-C681017D0C77}.Release|Any CPU.Build.0 = Release|Any CPU
- {909DB876-4A74-42AC-BACF-C681017D0C77}.Release|x64.ActiveCfg = Release|x64
- {909DB876-4A74-42AC-BACF-C681017D0C77}.Release|x64.Build.0 = Release|x64
- {909DB876-4A74-42AC-BACF-C681017D0C77}.Release|x86.ActiveCfg = Release|Any CPU
- {909DB876-4A74-42AC-BACF-C681017D0C77}.Release|x86.Build.0 = Release|Any CPU
{BDD5DF8C-6FC1-4882-8151-924820FDBC05}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{BDD5DF8C-6FC1-4882-8151-924820FDBC05}.Debug|Any CPU.Build.0 = Debug|Any CPU
{BDD5DF8C-6FC1-4882-8151-924820FDBC05}.Debug|x64.ActiveCfg = Debug|x64
@@ -110,18 +98,6 @@ Global
{786D71E7-4D92-43E4-A9EB-4E07FFE36F70}.Release|x64.Build.0 = Release|x64
{786D71E7-4D92-43E4-A9EB-4E07FFE36F70}.Release|x86.ActiveCfg = Release|x86
{786D71E7-4D92-43E4-A9EB-4E07FFE36F70}.Release|x86.Build.0 = Release|x86
- {EF56252E-257F-41D1-974B-C9015071CE7E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {EF56252E-257F-41D1-974B-C9015071CE7E}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {EF56252E-257F-41D1-974B-C9015071CE7E}.Debug|x64.ActiveCfg = Debug|x64
- {EF56252E-257F-41D1-974B-C9015071CE7E}.Debug|x64.Build.0 = Debug|x64
- {EF56252E-257F-41D1-974B-C9015071CE7E}.Debug|x86.ActiveCfg = Debug|Any CPU
- {EF56252E-257F-41D1-974B-C9015071CE7E}.Debug|x86.Build.0 = Debug|Any CPU
- {EF56252E-257F-41D1-974B-C9015071CE7E}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {EF56252E-257F-41D1-974B-C9015071CE7E}.Release|Any CPU.Build.0 = Release|Any CPU
- {EF56252E-257F-41D1-974B-C9015071CE7E}.Release|x64.ActiveCfg = Release|x64
- {EF56252E-257F-41D1-974B-C9015071CE7E}.Release|x64.Build.0 = Release|x64
- {EF56252E-257F-41D1-974B-C9015071CE7E}.Release|x86.ActiveCfg = Release|Any CPU
- {EF56252E-257F-41D1-974B-C9015071CE7E}.Release|x86.Build.0 = Release|Any CPU
{E99B606A-25B8-4113-9E75-5016CCFDB410}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{E99B606A-25B8-4113-9E75-5016CCFDB410}.Debug|Any CPU.Build.0 = Debug|Any CPU
{E99B606A-25B8-4113-9E75-5016CCFDB410}.Debug|x64.ActiveCfg = Debug|x64
@@ -134,6 +110,30 @@ Global
{E99B606A-25B8-4113-9E75-5016CCFDB410}.Release|x64.Build.0 = Release|x64
{E99B606A-25B8-4113-9E75-5016CCFDB410}.Release|x86.ActiveCfg = Release|Any CPU
{E99B606A-25B8-4113-9E75-5016CCFDB410}.Release|x86.Build.0 = Release|Any CPU
+ {EF56252E-257F-41D1-974B-C9015071CE7E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {EF56252E-257F-41D1-974B-C9015071CE7E}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {EF56252E-257F-41D1-974B-C9015071CE7E}.Debug|x64.ActiveCfg = Debug|x64
+ {EF56252E-257F-41D1-974B-C9015071CE7E}.Debug|x64.Build.0 = Debug|x64
+ {EF56252E-257F-41D1-974B-C9015071CE7E}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {EF56252E-257F-41D1-974B-C9015071CE7E}.Debug|x86.Build.0 = Debug|Any CPU
+ {EF56252E-257F-41D1-974B-C9015071CE7E}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {EF56252E-257F-41D1-974B-C9015071CE7E}.Release|Any CPU.Build.0 = Release|Any CPU
+ {EF56252E-257F-41D1-974B-C9015071CE7E}.Release|x64.ActiveCfg = Release|x64
+ {EF56252E-257F-41D1-974B-C9015071CE7E}.Release|x64.Build.0 = Release|x64
+ {EF56252E-257F-41D1-974B-C9015071CE7E}.Release|x86.ActiveCfg = Release|Any CPU
+ {EF56252E-257F-41D1-974B-C9015071CE7E}.Release|x86.Build.0 = Release|Any CPU
+ {909DB876-4A74-42AC-BACF-C681017D0C77}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {909DB876-4A74-42AC-BACF-C681017D0C77}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {909DB876-4A74-42AC-BACF-C681017D0C77}.Debug|x64.ActiveCfg = Debug|x64
+ {909DB876-4A74-42AC-BACF-C681017D0C77}.Debug|x64.Build.0 = Debug|x64
+ {909DB876-4A74-42AC-BACF-C681017D0C77}.Debug|x86.ActiveCfg = Debug|x86
+ {909DB876-4A74-42AC-BACF-C681017D0C77}.Debug|x86.Build.0 = Debug|x86
+ {909DB876-4A74-42AC-BACF-C681017D0C77}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {909DB876-4A74-42AC-BACF-C681017D0C77}.Release|Any CPU.Build.0 = Release|Any CPU
+ {909DB876-4A74-42AC-BACF-C681017D0C77}.Release|x64.ActiveCfg = Release|x64
+ {909DB876-4A74-42AC-BACF-C681017D0C77}.Release|x64.Build.0 = Release|x64
+ {909DB876-4A74-42AC-BACF-C681017D0C77}.Release|x86.ActiveCfg = Release|x86
+ {909DB876-4A74-42AC-BACF-C681017D0C77}.Release|x86.Build.0 = Release|x86
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
diff --git a/RFiDGear/3rdParty/RedCell/RedCell.Diagnostics.Update/Updater.cs b/RFiDGear/3rdParty/RedCell/RedCell.Diagnostics.Update/Updater.cs
index 4dcd256..5df2b71 100644
--- a/RFiDGear/3rdParty/RedCell/RedCell.Diagnostics.Update/Updater.cs
+++ b/RFiDGear/3rdParty/RedCell/RedCell.Diagnostics.Update/Updater.cs
@@ -114,6 +114,8 @@ public void StartMonitoring()
if (_localConfig != null)
{
Log.Write("Starting monitoring every {0}s.", _localConfig.CheckInterval);
+ Check(null);
+
_timer = new Timer(Check, null, 5000, _localConfig.CheckInterval * 1000);
}
diff --git a/RFiDGear/DataAccessLayer/Local/ResourceLoader.cs b/RFiDGear/DataAccessLayer/Local/ResourceLoader.cs
index 3bdabcf..a72aa69 100644
--- a/RFiDGear/DataAccessLayer/Local/ResourceLoader.cs
+++ b/RFiDGear/DataAccessLayer/Local/ResourceLoader.cs
@@ -150,7 +150,7 @@ public object Convert(object value, Type targetType, object parameter, CultureIn
}
catch (Exception e)
{
- LogWriter.CreateLogEntry(string.Format("{0}; {1}; {2}", DateTime.Now, e.Message, e.InnerException != null ? e.InnerException.Message : ""), FacilityName);
+ LogWriter.CreateLogEntry(e, FacilityName);
throw new ArgumentOutOfRangeException(
string.Format("parameter:{0}\nvalue:{1}",
@@ -208,14 +208,16 @@ public static string GetResource(string resName)
{
settings.ReadSettings();
- return new ResourceManager("RFiDGear.Resources.Manifest", System.Reflection.Assembly.GetExecutingAssembly())
+ string ressource = new ResourceManager("RFiDGear.Resources.Manifest", System.Reflection.Assembly.GetExecutingAssembly())
.GetString(resName, (settings.DefaultSpecification.DefaultLanguage == "german") ? new CultureInfo("de") : new CultureInfo("en"));
+
+ return ressource.Replace("%NEWLINE", "\n");
}
}
catch (Exception e)
{
- LogWriter.CreateLogEntry(string.Format("{0}; {1}; {2}", DateTime.Now, e.Message, e.InnerException != null ? e.InnerException.Message : ""), FacilityName);
+ LogWriter.CreateLogEntry(e, FacilityName);
return string.Empty;
}
}
diff --git a/RFiDGear/DataAccessLayer/Remote/FromFile/ReportReaderWriter.cs b/RFiDGear/DataAccessLayer/Remote/FromFile/ReportReaderWriter.cs
index 3e08d2f..e0af91f 100644
--- a/RFiDGear/DataAccessLayer/Remote/FromFile/ReportReaderWriter.cs
+++ b/RFiDGear/DataAccessLayer/Remote/FromFile/ReportReaderWriter.cs
@@ -140,6 +140,7 @@ public void SetReportField(string _field, string _value)
{
form.GetField(_field).SetBorderWidth(1);
form.GetField(_field).SetVisibility(PdfFormField.VISIBLE);
+ form.GetField(_field).SetReadOnly(false);
form.GetField(_field).SetValue(_value);
if (form.GetField(_field) is PdfButtonFormField)
diff --git a/RFiDGear/DataAccessLayer/Remote/FromIO/ElatecNetProvider.cs b/RFiDGear/DataAccessLayer/Remote/FromIO/ElatecNetProvider.cs
index 133b9e6..81e7c3d 100644
--- a/RFiDGear/DataAccessLayer/Remote/FromIO/ElatecNetProvider.cs
+++ b/RFiDGear/DataAccessLayer/Remote/FromIO/ElatecNetProvider.cs
@@ -51,17 +51,18 @@ public override ERROR ReadChipPublic()
{
try
{
- if (readerDevice.ConnectTWN4())
+ if (readerDevice != null)
{
- readerDevice.Beep();
readerDevice.GreenLED(true);
card = readerDevice.GetSingleChip();
- if (card?.ChipIdentifier != null)
+ if (!string.IsNullOrWhiteSpace(card?.ChipIdentifier))
{
try
{
+ readerDevice.Beep(1, 200, 2000, 50);
+
GenericChip = new GenericChipModel(card.ChipIdentifier, (CARD_TYPE)card.CardType);
if ((CARD_TYPE)card.CardType == CARD_TYPE.DESFire || (CARD_TYPE)card.CardType == CARD_TYPE.DESFireEV1)
@@ -91,6 +92,9 @@ public override ERROR ReadChipPublic()
}
else
{
+ readerDevice.Beep(3, 50, 2000, 50);
+ GenericChip = null;
+
return ERROR.NotReadyError;
}
}
@@ -226,7 +230,7 @@ protected override void Dispose(bool disposing)
{
if (disposing)
{
- TWN4ReaderDevice.Instance?.DisconnectTWN4();
+
}
_disposed = true;
@@ -237,6 +241,7 @@ public override void Dispose()
{
_disposed = false;
Dispose(true);
+ GC.SuppressFinalize(this);
}
}
}
diff --git a/RFiDGear/DataAccessLayer/Remote/FromIO/LibLogicalAccessProvider.cs b/RFiDGear/DataAccessLayer/Remote/FromIO/LibLogicalAccessProvider.cs
index d492fbf..9aa24da 100644
--- a/RFiDGear/DataAccessLayer/Remote/FromIO/LibLogicalAccessProvider.cs
+++ b/RFiDGear/DataAccessLayer/Remote/FromIO/LibLogicalAccessProvider.cs
@@ -2464,6 +2464,7 @@ public override void Dispose()
{
_disposed = false;
Dispose(true);
+ GC.SuppressFinalize(this);
}
}
}
\ No newline at end of file
diff --git a/RFiDGear/DataAccessLayer/Remote/FromIO/ReaderDevice.cs b/RFiDGear/DataAccessLayer/Remote/FromIO/ReaderDevice.cs
index 39dd6d0..a76ee64 100644
--- a/RFiDGear/DataAccessLayer/Remote/FromIO/ReaderDevice.cs
+++ b/RFiDGear/DataAccessLayer/Remote/FromIO/ReaderDevice.cs
@@ -20,13 +20,16 @@ public static ReaderDevice Instance
instance = new LibLogicalAccessProvider(Reader);
return instance;
}
+ else if (instance != null && !(instance is LibLogicalAccessProvider))
+ {
+ instance = new LibLogicalAccessProvider(Reader);
+ return instance;
+ }
else
{
return instance;
}
-
}
-
case ReaderTypes.Elatec:
lock (syncRoot)
{
@@ -35,6 +38,11 @@ public static ReaderDevice Instance
instance = new ElatecNetProvider(PortNumber);
return instance;
}
+ else if (instance != null && !(instance is ElatecNetProvider))
+ {
+ instance = new ElatecNetProvider(PortNumber);
+ return instance;
+ }
else
{
return instance;
diff --git a/RFiDGear/Resources/Manifest.de.resx b/RFiDGear/Resources/Manifest.de.resx
index 6a48bbb..803517d 100644
--- a/RFiDGear/Resources/Manifest.de.resx
+++ b/RFiDGear/Resources/Manifest.de.resx
@@ -437,16 +437,16 @@ ein Kartenlesegerät auswählen
_Aufgabenstatus zurücksetzen
- _Alle Aufgaben automatisch abarbeiten
+ _Alle Aufgaben automatisch ausführen
- _Markierte Aufgabe automatisch abarbeiten
+ _Markierte Aufgabe automatisch ausführen
- Markierte Aufgaben _einmalig abarbeiten
+ Markierte Aufgaben _einmalig ausführen
- Alle A_ufgaben einmalig abarbeiten
+ Alle A_ufgaben einmalig ausführen
Projektdatei _öffnen...
@@ -523,10 +523,10 @@ Soll die Aktualisierung jetzt herunter geladen und installiert werden?
_RFiD Aufgaben
- Mifare
+ Mifare Aufgabe
- Karten entfernen
+ Alle Karten entfernen
Mifare _Ultralight Aufgabe hinzufügen/bearbeiten
@@ -854,7 +854,7 @@ Wird benötigt von:
PDF Dateien (*.pdf)|*.pdf
- _Allgemeine (nicht-RFID) Aufgabe erstellen...
+ _Allgemeine Aufgabe erstellen / bearbeiten...
Testpunkt erstellen / bearbeiten
@@ -905,7 +905,7 @@ Wird benötigt von:
Kein
- Generischen Typ erstellen / bearbeiten....
+ Typunabhängige RFiD Aufgabe erstellen / bearbeiten....
Kartentyp
@@ -998,7 +998,7 @@ Wird benötigt von:
ISONAS
- MIFARE
+ MIFARE (Generisch)
ISO14443B
@@ -1037,13 +1037,13 @@ Wird benötigt von:
Mifare Mini
- Mifare 1K
+ Mifare Classic 1K
- Mifare 2K
+ Mifare Classic 2K
- Mifare 4K
+ Mifare Classic 4K
SAM_AV1
@@ -1088,16 +1088,16 @@ Wird benötigt von:
Mifare Plus SL3 4K
- Desfire EV0
+ Mifare Desfire EV0
- Desfire EV1
+ Mifare Desfire EV1
- Desfire EV2
+ Mifare Desfire EV2
- Desfire EV3
+ Mifare Desfire EV3
SmartMX MifareClassic 2K
@@ -1145,10 +1145,10 @@ Wird benötigt von:
Logische Zustandsprüfung
- Soll - Ergebnis
+ Ziel Aufgabenergebnis
- Ziel Taskindex
+ Ziel Aufgabennummer
App Konfiguration lesen
@@ -1355,4 +1355,37 @@ https://github.com/c3rebro/rfidgear
Sektor-Unbenutzt Prüfung
+
+ Chip erkennen
+
+
+ Vergleichs-%NEWLINEausdruck
+
+
+ Inhalt
+
+
+ Ziel Aufgaben-%NEWLINENummer
+
+
+ Ziel Aufgaben-%NEWLINEErgebnis
+
+
+ PDF Feldvariablen-%NEWLINEbezeichnung
+
+
+ PDF Feldinhalt
+
+
+ Prüfpunkteübersicht
+
+
+ Knoten löschen
+
+
+ Chip Typ:
+
+
+ Typunabhängige RFiD Aufgabe erstellen / bearbeiten
+
\ No newline at end of file
diff --git a/RFiDGear/Resources/Manifest.en.resx b/RFiDGear/Resources/Manifest.en.resx
index 8f0809c..26dd487 100644
--- a/RFiDGear/Resources/Manifest.en.resx
+++ b/RFiDGear/Resources/Manifest.en.resx
@@ -988,7 +988,7 @@ Needed by:
ISONAS
- MIFARE
+ MIFARE (Generic)
ISO14443B
@@ -1027,13 +1027,13 @@ Needed by:
Mifare Mini
- Mifare 1K
+ Mifare Classic 1K
- Mifare 2K
+ Mifare Classic 2K
- Mifare 4K
+ Mifare Classic 4K
SAM_AV1
@@ -1078,16 +1078,16 @@ Needed by:
Mifare Plus SL3 4K
- Desfire EV0
+ Mifare Desfire EV0
- Desfire EV1
+ Mifare Desfire EV1
- Desfire EV2
+ Mifare Desfire EV2
- Desfire EV3
+ Mifare Desfire EV3
SmartMX MifareClassic 2K
@@ -1336,4 +1336,34 @@ https://github.com/c3rebro/rfidgear
Sector Unused Check
+
+ Read Chip Public
+
+
+ Compare Expression
+
+
+ Content
+
+
+ Targeted Task-%NEWLINEIndex
+
+
+ Targeted Error-%NEWLINELevel
+
+
+ Template Formfield
+
+
+ Formfield Content
+
+
+ Delete Node
+
+
+ ChipType:
+
+
+ Add / Edit Generic RFiD Task
+
\ No newline at end of file
diff --git a/RFiDGear/View/MainWindow.xaml b/RFiDGear/View/MainWindow.xaml
index f1a5ca8..1aa7dc4 100644
--- a/RFiDGear/View/MainWindow.xaml
+++ b/RFiDGear/View/MainWindow.xaml
@@ -125,6 +125,25 @@
+
+
+
+
+
-
+
-
+
-
+
-
+
diff --git a/RFiDGear/View/TaskViews/CommonTask/CommonTasksTabPages/TabPageReportSettingsView.xaml b/RFiDGear/View/TaskViews/CommonTask/CommonTasksTabPages/TabPageReportSettingsView.xaml
index 7e91d03..f0608b0 100644
--- a/RFiDGear/View/TaskViews/CommonTask/CommonTasksTabPages/TabPageReportSettingsView.xaml
+++ b/RFiDGear/View/TaskViews/CommonTask/CommonTasksTabPages/TabPageReportSettingsView.xaml
@@ -9,6 +9,7 @@
d:DesignHeight="430"
mc:Ignorable="d">
+
@@ -89,6 +90,17 @@
VerticalAlignment="Top"
Command="{Binding OpenReportTemplateCommand}"
Content="{Binding LocalizationResourceSet, ConverterParameter=buttonContentOpenReportTemplateFile, Converter={StaticResource Localization}}" />
+
@@ -223,7 +235,7 @@
Margin="8,8,8,8"
HorizontalAlignment="Stretch"
VerticalAlignment="Stretch"
- Header="{Binding LocalizationResourceSet, ConverterParameter=groupBoxHeaderMifareDesfireAppSettingsCurrent, Converter={StaticResource Localization}}"
+ Header="{Binding LocalizationResourceSet, ConverterParameter=groupBoxHeaderCommonTaskCheckpointSetup, Converter={StaticResource Localization}}"
IsEnabled="{Binding IsReportSetupTabEnabled}">
-->
-
+
@@ -257,33 +269,41 @@
Source={StaticResource proxy}}
-->
-
+
-
+
@@ -291,7 +311,11 @@
-
+
-
+
-
-
-
-
-
+
+
diff --git a/RFiDGear/View/TaskViews/RFIDTasks/GenericChipTask/GenericChipTaskView.xaml b/RFiDGear/View/TaskViews/RFIDTasks/GenericChipTask/GenericChipTaskView.xaml
index e261c99..3ddd12f 100644
--- a/RFiDGear/View/TaskViews/RFIDTasks/GenericChipTask/GenericChipTaskView.xaml
+++ b/RFiDGear/View/TaskViews/RFIDTasks/GenericChipTask/GenericChipTaskView.xaml
@@ -158,7 +158,7 @@
Grid.Row="2"
Grid.ColumnSpan="4"
Margin="8,0,8,0"
- Header="ExecuteCondition">
+ Header="{Binding LocalizationResourceSet, ConverterParameter=groupBoxHeaderAllTasksExecuteCondition, Converter={StaticResource Localization}}">
diff --git a/RFiDGear/ViewModel/HirarchicalDataTemplateViewModels/RFiDChipParentLayerViewModel.cs b/RFiDGear/ViewModel/HirarchicalDataTemplateViewModels/RFiDChipParentLayerViewModel.cs
index 167f6f8..0f16099 100644
--- a/RFiDGear/ViewModel/HirarchicalDataTemplateViewModels/RFiDChipParentLayerViewModel.cs
+++ b/RFiDGear/ViewModel/HirarchicalDataTemplateViewModels/RFiDChipParentLayerViewModel.cs
@@ -40,6 +40,7 @@ public class RFiDChipParentLayerViewModel : ViewModelBase
private readonly RelayCommand _cmdCreateApp;
private readonly RelayCommand _cmdEraseDesfireCard;
+ private protected GenericChipModel genericChip;
private protected MifareClassicChipModel mifareClassicUidModel;
private protected MifareDesfireChipModel mifareDesfireUidModel;
private protected MifareUltralightChipModel mifareUltralightUidModel;
@@ -53,6 +54,8 @@ public RFiDChipParentLayerViewModel()
mifareClassicUidModel = new MifareClassicChipModel();
mifareDesfireUidModel = new MifareDesfireChipModel();
+ mifareUltralightUidModel = new MifareUltralightChipModel();
+ genericChip = new GenericChipModel();
}
public RFiDChipParentLayerViewModel(string _text)
@@ -63,11 +66,12 @@ public RFiDChipParentLayerViewModel(string _text)
mifareClassicUidModel = new MifareClassicChipModel();
mifareDesfireUidModel = new MifareDesfireChipModel();
mifareUltralightUidModel = new MifareUltralightChipModel();
+ genericChip = new GenericChipModel();
ParentNodeHeader = _text;
}
- public RFiDChipParentLayerViewModel(MifareClassicChipModel _uidModel, ObservableCollection _dialogs, bool _isTask = false)
+ public RFiDChipParentLayerViewModel(ObservableCollection _dialogs, bool _isTask)
{
ID = new Random().Next();
@@ -78,6 +82,11 @@ public RFiDChipParentLayerViewModel(MifareClassicChipModel _uidModel, Observable
isTask = _isTask;
settings = new SettingsReaderWriter();
+ _children = new ObservableCollection();
+ }
+
+ public RFiDChipParentLayerViewModel(MifareClassicChipModel _uidModel, ObservableCollection _dialogs, bool _isTask) : this ( _dialogs, _isTask)
+ {
mifareClassicUidModel = _uidModel;
CardType = mifareClassicUidModel.CardType;
@@ -97,11 +106,10 @@ public RFiDChipParentLayerViewModel(MifareClassicChipModel _uidModel, Observable
ContextMenuItems.Add(new MenuItem()
{
- Header = "Delete Node",
+ Header = ResourceLoader.GetResource("hierarchicalDataTemplateParentNodeContextMenuDeleteNode"),
Command = _cmdDeleteThisNode
});
- _children = new ObservableCollection();
if (!isTask)
{
@@ -116,18 +124,8 @@ public RFiDChipParentLayerViewModel(MifareClassicChipModel _uidModel, Observable
}
}
- public RFiDChipParentLayerViewModel(MifareDesfireChipModel _uidModel, ObservableCollection _dialogs, bool _isTask = false)
+ public RFiDChipParentLayerViewModel(MifareDesfireChipModel _uidModel, ObservableCollection _dialogs, bool _isTask) : this(_dialogs, _isTask)
{
- ID = new Random().Next();
-
- if (_dialogs != null)
- {
- dialogs = _dialogs;
- }
-
- isTask = _isTask;
- settings = new SettingsReaderWriter();
-
mifareDesfireUidModel = _uidModel;
CardType = mifareDesfireUidModel.CardType;
@@ -149,8 +147,6 @@ public RFiDChipParentLayerViewModel(MifareDesfireChipModel _uidModel, Observable
}
});
- _children = new ObservableCollection();
-
if (!isTask)
{
LoadChildren();
@@ -160,21 +156,12 @@ public RFiDChipParentLayerViewModel(MifareDesfireChipModel _uidModel, Observable
if (mifareDesfireUidModel != null)
{
- ParentNodeHeader = String.Format("ChipType: {1}\nUid: {0}", mifareDesfireUidModel.UID, Enum.GetName(typeof(CARD_TYPE), CardType));
+ ParentNodeHeader = String.Format(ResourceLoader.GetResource("hirarchicalDataTemplateParentNodeHeaderChipType") + " {1}\nUid: {0}", mifareDesfireUidModel.UID, Enum.GetName(typeof(CARD_TYPE), CardType));
}
}
- public RFiDChipParentLayerViewModel(MifareUltralightChipModel _uidModel, ObservableCollection _dialogs, bool _isTask = false)
+ public RFiDChipParentLayerViewModel(MifareUltralightChipModel _uidModel, ObservableCollection _dialogs, bool _isTask) : this(_dialogs, _isTask)
{
- ID = new Random().Next();
-
- if (_dialogs != null)
- {
- dialogs = _dialogs;
- }
-
- isTask = _isTask;
- settings = new SettingsReaderWriter();
mifareUltralightUidModel = _uidModel;
CardType = mifareUltralightUidModel.CardType;
@@ -198,8 +185,6 @@ public RFiDChipParentLayerViewModel(MifareUltralightChipModel _uidModel, Observa
Command = _cmdDeleteThisNode
});
- _children = new ObservableCollection();
-
if (!isTask)
{
LoadChildren();
@@ -209,7 +194,29 @@ public RFiDChipParentLayerViewModel(MifareUltralightChipModel _uidModel, Observa
if (mifareUltralightUidModel != null)
{
- ParentNodeHeader = String.Format("ChipType: {1}\nUid: {0}", mifareUltralightUidModel.UID, Enum.GetName(typeof(CARD_TYPE), CardType));
+ ParentNodeHeader = String.Format(ResourceLoader.GetResource("hirarchicalDataTemplateParentNodeHeaderChipType") + " {1}\nUid: {0}", mifareUltralightUidModel.UID, Enum.GetName(typeof(CARD_TYPE), CardType));
+ }
+ }
+
+ public RFiDChipParentLayerViewModel(GenericChipModel _chipModel, ObservableCollection _dialogs, bool _isTask) : this(_dialogs, _isTask)
+ {
+ genericChip = _chipModel;
+ CardType = genericChip.CardType;
+
+ _cmdDeleteThisNode = new RelayCommand(DeleteMeCommand);
+
+ ContextMenuItems = new List