From 8b4e0971171d40844ca1c63591aeb1fbe4add759 Mon Sep 17 00:00:00 2001 From: Roy Ben-Shabat Date: Sun, 10 Dec 2017 13:21:59 +0200 Subject: Added DAL.Observables project. Changes DB table CONFIGURATIONS_DISPENSER to IDS_PACKS. CHanges DB table SYNC_CONFIGURATION to SYNC_CONFIGURATIONS --- .../Visual_Studio/Tango.Synchronization/Local/Constants.cs | 2 +- .../Tango.Synchronization/Remote/RemoteDBComparer.cs | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) (limited to 'Software/Visual_Studio/Tango.Synchronization') diff --git a/Software/Visual_Studio/Tango.Synchronization/Local/Constants.cs b/Software/Visual_Studio/Tango.Synchronization/Local/Constants.cs index 5557c43c8..a1494243c 100644 --- a/Software/Visual_Studio/Tango.Synchronization/Local/Constants.cs +++ b/Software/Visual_Studio/Tango.Synchronization/Local/Constants.cs @@ -14,7 +14,7 @@ namespace Tango.Synchronization.Local public const String COLUMN_TYPE = "type"; public const String IS_NOT_NULL = "notnull"; public const String DEFAULT_VALUE = "dflt_value"; - public const String SYNC_CONFIGURATIONS_TABLE_NAME = "SYNC_CONFIGURATION"; + public const String SYNC_CONFIGURATIONS_TABLE_NAME = "SYNC_CONFIGURATIONS"; public const String SYNC_CONFIGURATION_TABLE_NAME_COLUMN = "TABLE_NAME"; public const String SYNC_CONFIGURATION_SYNC_TYPE_COLUMN = "SYNC_TYPE"; diff --git a/Software/Visual_Studio/Tango.Synchronization/Remote/RemoteDBComparer.cs b/Software/Visual_Studio/Tango.Synchronization/Remote/RemoteDBComparer.cs index 0bd76dbd1..82bc53c1f 100644 --- a/Software/Visual_Studio/Tango.Synchronization/Remote/RemoteDBComparer.cs +++ b/Software/Visual_Studio/Tango.Synchronization/Remote/RemoteDBComparer.cs @@ -40,7 +40,7 @@ namespace Tango.Synchronization.Remote LogManager.Log("Querying all local configurations..."); var local_configurations = _localDB.CONFIGURATIONS.ToList(); LogManager.Log("Querying all local configuration dispensers..."); - var local_configurations_dispensers = _localDB.CONFIGURATIONS_DISPENSERS.ToList(); + var local_configurations_dispensers = _localDB.IDS_PACKS.ToList(); LogManager.Log("Querying all local contacts..."); var local_contacts = _localDB.CONTACTS.ToList(); LogManager.Log("Querying all local dispensers..."); @@ -102,7 +102,7 @@ namespace Tango.Synchronization.Remote LogManager.Log("Querying all remote configurations dispensers..."); guids = remote_configurations.Select(x => x.GUID).ToList(); - var remote_configurations_dispensers = _remoteDB.CONFIGURATIONS_DISPENSERS.Where(x => guids.Contains(x.CONFIGURATION_GUID)).ToList(); + var remote_configurations_dispensers = _remoteDB.IDS_PACKS.Where(x => guids.Contains(x.CONFIGURATION_GUID)).ToList(); LogManager.Log("Querying all remote dispensers..."); guids = remote_configurations_dispensers.Select(x => x.DISPENSER_GUID).ToList(); @@ -113,7 +113,7 @@ namespace Tango.Synchronization.Remote var remote_cartridges = _remoteDB.CARTRIDGES.Where(x => guids.Contains(x.GUID)).ToList(); - foreach (var config in _remoteDB.SYNC_CONFIGURATION.Where(x => (SyncConfiguration)x.SYNC_TYPE == SyncConfiguration.OverwriteLocal)) + foreach (var config in _remoteDB.SYNC_CONFIGURATIONS.Where(x => (SyncConfiguration)x.SYNC_TYPE == SyncConfiguration.OverwriteLocal)) { OverrideTable(config); } @@ -129,7 +129,7 @@ namespace Tango.Synchronization.Remote CompareCollections(remote_configurations, local_configurations, _remoteDB.CONFIGURATIONS, _localDB.CONFIGURATIONS); LogManager.Log("Comparing configurations dispensers"); - CompareCollections(remote_configurations_dispensers, local_configurations_dispensers, _remoteDB.CONFIGURATIONS_DISPENSERS, _localDB.CONFIGURATIONS_DISPENSERS); + CompareCollections(remote_configurations_dispensers, local_configurations_dispensers, _remoteDB.IDS_PACKS, _localDB.IDS_PACKS); LogManager.Log("Comparing contacts"); CompareCollections(remote_contacts, local_contacts, _remoteDB.CONTACTS, _localDB.CONTACTS); @@ -211,7 +211,7 @@ namespace Tango.Synchronization.Remote } } - private void OverrideTable(remote.SYNC_CONFIGURATION config) + private void OverrideTable(remote.SYNC_CONFIGURATIONS config) { LogManager.Log("Generating table override difference for " + config.TABLE_NAME + "..."); -- cgit v1.3.1