Skip to content

Commit b3abe9a

Browse files
committed
Updated to version 4.1.0.0.
1 parent 79f40c3 commit b3abe9a

42 files changed

Lines changed: 3105 additions & 132 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

MyGeotabAPIAdapter.Configuration/AdapterConfiguration.cs

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,9 @@ public class AdapterConfiguration : IAdapterConfiguration
9595
const string ArgNameEnableMinimunIntervalSamplingForStatusData = "AppSettings:GeneralFeedSettings:EnableMinimunIntervalSamplingForStatusData";
9696
const string ArgNameMinimumIntervalSamplingDiagnostics = "AppSettings:GeneralFeedSettings:MinimumIntervalSamplingDiagnostics";
9797
const string ArgNameMinimumIntervalSamplingIntervalSeconds = "AppSettings:GeneralFeedSettings:MinimumIntervalSamplingIntervalSeconds";
98+
// > AppSettings:Feeds:AuditLog
99+
const string ArgNameEnableAuditLogFeed = "AppSettings:Feeds:AuditLog:EnableAuditLogFeed";
100+
const string ArgNameAuditLogFeedIntervalSeconds = "AppSettings:Feeds:AuditLog:AuditLogFeedIntervalSeconds";
98101
// > AppSettings:Feeds:BinaryData
99102
const string ArgNameEnableBinaryDataFeed = "AppSettings:Feeds:BinaryData:EnableBinaryDataFeed";
100103
const string ArgNameBinaryDataFeedIntervalSeconds = "AppSettings:Feeds:BinaryData:BinaryDataFeedIntervalSeconds";
@@ -227,6 +230,9 @@ public class AdapterConfiguration : IAdapterConfiguration
227230
const int MaxStatusDataLocationServiceBufferMinutes = 1440; // 1440 min = 1 day
228231
const int DefaultStatusDataLocationServiceBufferMinutes = 1440;
229232

233+
/// <inheritdoc/>
234+
public int AuditLogFeedIntervalSeconds { get; private set; }
235+
230236
/// <inheritdoc/>
231237
public int BinaryDataFeedIntervalSeconds { get; private set; }
232238

@@ -302,6 +308,9 @@ public class AdapterConfiguration : IAdapterConfiguration
302308
/// <inheritdoc/>
303309
public int DVIRLogManipulatorIntervalSeconds { get; private set; }
304310

311+
/// <inheritdoc/>
312+
public bool EnableAuditLogFeed { get; private set; }
313+
305314
/// <inheritdoc/>
306315
public bool EnableBinaryDataFeed { get; private set; }
307316

@@ -750,6 +759,10 @@ public void ProcessConfigItems()
750759
MinimumIntervalSamplingIntervalSeconds = configurationHelper.GetConfigKeyValueInt(ArgNameMinimumIntervalSamplingIntervalSeconds, null, false, MinSamplingIntervalSeconds, MaxSamplingIntervalSeconds, DefaultSamplingIntervalSeconds);
751760
ValidateMinimumIntervalSamplingDiagnosticsList();
752761

762+
// AppSettings:Feeds:AuditLog:
763+
EnableAuditLogFeed = configurationHelper.GetConfigKeyValueBoolean(ArgNameEnableAuditLogFeed);
764+
AuditLogFeedIntervalSeconds = configurationHelper.GetConfigKeyValueInt(ArgNameAuditLogFeedIntervalSeconds, null, false, MinFeedIntervalSeconds, MaxFeedIntervalSeconds, DefaultFeedIntervalSeconds);
765+
753766
// AppSettings:Feeds:BinaryData:
754767
EnableBinaryDataFeed = configurationHelper.GetConfigKeyValueBoolean(ArgNameEnableBinaryDataFeed);
755768
BinaryDataFeedIntervalSeconds = configurationHelper.GetConfigKeyValueInt(ArgNameBinaryDataFeedIntervalSeconds, null, false, MinFeedIntervalSeconds, MaxFeedIntervalSeconds, DefaultFeedIntervalSeconds);

MyGeotabAPIAdapter.Configuration/IAdapterConfiguration.cs

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,17 @@ public interface IAdapterConfiguration
133133
int DVIRLogManipulatorIntervalSeconds { get; }
134134

135135
/// <summary>
136-
/// Indicates whether a <see cref="BinaryData"/> data feed should be enabled.
136+
/// Indicates whether an <see cref="Audit"/> data feed should be enabled.
137+
/// </summary>
138+
bool EnableAuditLogFeed { get; }
139+
140+
/// <summary>
141+
/// The minimum number of seconds to wait between GetFeed() calls for <see cref="Audit"/> objects.
142+
/// </summary>
143+
int AuditLogFeedIntervalSeconds { get; }
144+
145+
/// <summary>
146+
/// Indicates whether a <see cref="BinaryData"/> data feed should be enabled.
137147
/// </summary>
138148
bool EnableBinaryDataFeed { get; }
139149

MyGeotabAPIAdapter.Configuration/MyGeotabAPIAdapter.Configuration.csproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
</PropertyGroup>
66

77
<ItemGroup>
8-
<PackageReference Include="Microsoft.Extensions.Hosting" Version="10.0.2" />
8+
<PackageReference Include="Microsoft.Extensions.Hosting" Version="10.0.5" />
99
<PackageReference Include="Microsoft.NETCore.Platforms" Version="7.0.4" />
10-
<PackageReference Include="NLog.Extensions.Logging" Version="6.1.0" />
10+
<PackageReference Include="NLog.Extensions.Logging" Version="6.1.2" />
1111
</ItemGroup>
1212

1313
<ItemGroup>

MyGeotabAPIAdapter.Database.EntityPersisters/MyGeotabAPIAdapter.Database.EntityPersisters.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
</PropertyGroup>
66

77
<ItemGroup>
8-
<PackageReference Include="NLog.Extensions.Logging" Version="6.1.0" />
8+
<PackageReference Include="NLog.Extensions.Logging" Version="6.1.2" />
99
</ItemGroup>
1010

1111
<ItemGroup>

MyGeotabAPIAdapter.Database/DatabaseValidator.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ public class DatabaseValidator : IDatabaseValidator
1717
// The required version of the middleware database for the current version of the middleware application. Any time the middleware database is updated as part of an application update:
1818
// 1. This value should be updated to reflect the application version at the time.
1919
// 2. Database changes should be included in a single script file and the filename should be formatted as "prefix_version_suffix.sql" (e.g. "MSSQL_3.0.0.0_InitialSchemaCreation.sql") where the version portion of the filename is equal to the value of this constant.
20-
const string RequiredDatabaseVersion = "4.0.1.0";
20+
const string RequiredDatabaseVersion = "4.1.0.0";
2121

2222
readonly IExceptionHelper exceptionHelper;
2323
readonly Logger logger = LogManager.GetCurrentClassLogger();
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
using Dapper.Contrib.Extensions;
2+
using System;
3+
4+
namespace MyGeotabAPIAdapter.Database.Models
5+
{
6+
[Table("AuditLogs2")]
7+
public class DbAuditLog2 : IDbEntity
8+
{
9+
/// <inheritdoc/>
10+
[Write(false)]
11+
public string DatabaseTableName => "AuditLogs2";
12+
13+
/// <inheritdoc/>
14+
[Write(false)]
15+
public Common.DatabaseWriteOperationType DatabaseWriteOperationType { get; set; }
16+
17+
[ExplicitKey]
18+
#pragma warning disable IDE1006 // Naming Styles
19+
public Guid id { get; set; }
20+
#pragma warning restore IDE1006 // Naming Styles
21+
public string GeotabId { get; set; }
22+
public string Comment { get; set; }
23+
public DateTime DateTime { get; set; }
24+
public string Name { get; set; }
25+
public string UserName { get; set; }
26+
public long? Version { get; set; }
27+
[ChangeTracker]
28+
public DateTime RecordCreationTimeUtc { get; set; }
29+
}
30+
}

MyGeotabAPIAdapter.Database/Models/DbDevice2.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ public class DbDevice2 : IDbEntity, IIdCacheableDbEntity, IStatusableDbEntity
2929
public DateTime? ActiveTo { get; set; }
3030
public string? Comment { get; set; }
3131
public string DeviceType { get; set; }
32+
public string? CustomProperties { get; set; }
3233
public string? Groups { get; set; }
3334
public string LicensePlate { get; set; }
3435
public string LicenseState { get; set; }

MyGeotabAPIAdapter.Database/Models/DbStgDevice2.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ public class DbStgDevice2 : IDbEntity, IIdCacheableDbEntity, IStatusableDbEntity
2929
public DateTime? ActiveTo { get; set; }
3030
public string? Comment { get; set; }
3131
public string DeviceType { get; set; }
32+
public string? CustomProperties { get; set; }
3233
public string? Groups { get; set; }
3334
public string LicensePlate { get; set; }
3435
public string LicenseState { get; set; }

MyGeotabAPIAdapter.Database/Models/DbStgTrip2.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ public TimeSpan? DrivingDuration
6464
}
6565
}
6666
public long? DrivingDurationTicks { get; set; }
67+
public double? EngineHours { get; set; }
6768
[Write(false)]
6869
public TimeSpan? IdlingDuration
6970
{
@@ -79,6 +80,7 @@ public TimeSpan? IdlingDuration
7980
public long? IdlingDurationTicks { get; set; }
8081
public float? MaximumSpeed { get; set; }
8182
public DateTime? NextTripStart { get; set; }
83+
public double? Odometer { get; set; }
8284
public int? SpeedRange1 { get; set; }
8385
[Write(false)]
8486
public TimeSpan? SpeedRange1Duration

MyGeotabAPIAdapter.Database/Models/DbStgUser2.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ public class DbStgUser2 : IDbEntity, IIdCacheableDbEntity, IStatusableDbEntity
2828
public DateTime? ActiveFrom { get; set; }
2929
public DateTime? ActiveTo { get; set; }
3030
public string? CompanyGroups { get; set; }
31+
public string? Designation { get; set; }
3132
public string EmployeeNo { get; set; }
3233
public string FirstName { get; set; }
3334
public string HosRuleSet { get; set; }

0 commit comments

Comments
 (0)