Skip to content

Commit

Permalink
Merge pull request #618 from Laixer/develop
Browse files Browse the repository at this point in the history
v3.4.1
  • Loading branch information
yorickdewid committed Nov 9, 2021
2 parents f8bac5e + ae52e4e commit 7d79cfa
Show file tree
Hide file tree
Showing 30 changed files with 353 additions and 379 deletions.
54 changes: 54 additions & 0 deletions database/fundermaps_base.sql
Original file line number Diff line number Diff line change
Expand Up @@ -2684,6 +2684,27 @@ CREATE TABLE application.product_telemetry (

ALTER TABLE application.product_telemetry OWNER TO fundermaps;

--
-- Name: product_tracker; Type: TABLE; Schema: application; Owner: fundermaps
--

CREATE TABLE application.product_tracker (
organization_id application.organization_id NOT NULL,
product text NOT NULL,
building_id geocoder.geocoder_id NOT NULL,
create_date timestamp with time zone DEFAULT CURRENT_TIMESTAMP NOT NULL
);


ALTER TABLE application.product_tracker OWNER TO fundermaps;

--
-- Name: COLUMN product_tracker.create_date; Type: COMMENT; Schema: application; Owner: fundermaps
--

COMMENT ON COLUMN application.product_tracker.create_date IS 'Timestamp of record creation, set by insert';


--
-- Name: user; Type: TABLE; Schema: application; Owner: fundermaps
--
Expand Down Expand Up @@ -4574,6 +4595,13 @@ CREATE UNIQUE INDEX organization_normalized_email_idx ON application.organizatio
CREATE INDEX organization_proposal_normalized_email_idx ON application.organization_proposal USING btree (normalized_email);


--
-- Name: product_tracker_count_idx; Type: INDEX; Schema: application; Owner: fundermaps
--

CREATE INDEX product_tracker_count_idx ON application.product_tracker USING btree (organization_id, product);


--
-- Name: user_normalized_email_idx; Type: INDEX; Schema: application; Owner: fundermaps
--
Expand Down Expand Up @@ -5058,6 +5086,22 @@ ALTER TABLE ONLY application.product_telemetry
ADD CONSTRAINT product_telemetry_user_id_fkey FOREIGN KEY (user_id) REFERENCES application."user"(id) ON UPDATE CASCADE ON DELETE SET NULL;


--
-- Name: product_tracker product_tracker_building_id_fkey; Type: FK CONSTRAINT; Schema: application; Owner: fundermaps
--

ALTER TABLE ONLY application.product_tracker
ADD CONSTRAINT product_tracker_building_id_fkey FOREIGN KEY (building_id) REFERENCES geocoder.building(id) ON UPDATE CASCADE;


--
-- Name: product_tracker product_tracker_organization_id_fkey; Type: FK CONSTRAINT; Schema: application; Owner: fundermaps
--

ALTER TABLE ONLY application.product_tracker
ADD CONSTRAINT product_tracker_organization_id_fkey FOREIGN KEY (organization_id) REFERENCES application.organization(id) ON UPDATE CASCADE ON DELETE CASCADE;


--
-- Name: building_elevation building_elevation_building_fkey; Type: FK CONSTRAINT; Schema: data; Owner: fundermaps
--
Expand Down Expand Up @@ -5797,6 +5841,16 @@ GRANT SELECT ON TABLE application.product_telemetry TO fundermaps_batch;
GRANT SELECT ON TABLE application.product_telemetry TO fundermaps_portal;


--
-- Name: TABLE product_tracker; Type: ACL; Schema: application; Owner: fundermaps
--

GRANT SELECT,INSERT,UPDATE ON TABLE application.product_tracker TO fundermaps_webservice;
GRANT SELECT,INSERT,REFERENCES,DELETE,TRIGGER,UPDATE ON TABLE application.product_tracker TO fundermaps_webapp;
GRANT SELECT ON TABLE application.product_tracker TO fundermaps_batch;
GRANT SELECT ON TABLE application.product_tracker TO fundermaps_portal;


--
-- Name: TABLE "user"; Type: ACL; Schema: application; Owner: fundermaps
--
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using Microsoft.AspNetCore.Authentication;
using Microsoft.AspNetCore.Authentication;
using Microsoft.AspNetCore.Authentication.JwtBearer;
using Microsoft.Extensions.Logging;
using Microsoft.Extensions.Options;
Expand All @@ -10,7 +10,6 @@
using System.Runtime.CompilerServices;
using System.Security.Claims;

#pragma warning disable CA1812 // Internal class is never instantiated
namespace FunderMaps.AspNetCore.Authentication
{
/// <summary>
Expand Down Expand Up @@ -138,4 +137,3 @@ public virtual TokenContext GetTokenContext(ClaimsPrincipal principal)
}
}
}
#pragma warning restore CA1812 // Internal class is never instantiated
2 changes: 0 additions & 2 deletions src/FunderMaps.AspNetCore/Controllers/AuthController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
using System;
using System.Threading.Tasks;

#pragma warning disable CA1062 // Validate arguments of public methods
namespace FunderMaps.AspNetCore.Controllers
{
/// <summary>
Expand Down Expand Up @@ -73,4 +72,3 @@ public async Task<ActionResult<SignInSecurityTokenDto>> RefreshSignInAsync()
}
}
}
#pragma warning restore CA1062 // Validate arguments of public methods
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
using System;
using System.Threading.Tasks;

#pragma warning disable CA1062 // Validate arguments of public methods
namespace FunderMaps.AspNetCore.Controllers
{
/// <summary>
Expand Down Expand Up @@ -76,4 +75,3 @@ public async Task<IActionResult> UpdateAsync([FromBody] OrganizationDto input)
}
}
}
#pragma warning restore CA1062 // Validate arguments of public methods
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@
using System.Collections.Generic;
using System.Threading.Tasks;

#pragma warning disable CA1062 // Validate arguments of public methods
namespace FunderMaps.AspNetCore.Controllers
{
/// <summary>
Expand Down Expand Up @@ -193,4 +192,3 @@ public async Task<IActionResult> DeleteUserAsync(Guid id)
}
}
}
#pragma warning restore CA1062 // Validate arguments of public methods
2 changes: 0 additions & 2 deletions src/FunderMaps.AspNetCore/Controllers/UserController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
using System;
using System.Threading.Tasks;

#pragma warning disable CA1062 // Validate arguments of public methods
namespace FunderMaps.AspNetCore.Controllers
{
/// <summary>
Expand Down Expand Up @@ -100,4 +99,3 @@ public async Task<IActionResult> ChangePasswordAsync([FromBody] ChangePasswordDt
}
}
}
#pragma warning restore CA1062 // Validate arguments of public methods
2 changes: 0 additions & 2 deletions src/FunderMaps.AspNetCore/Controllers/VersionController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;

#pragma warning disable CA1062 // Validate arguments of public methods
namespace FunderMaps.AspNetCore.Controllers
{
/// <summary>
Expand Down Expand Up @@ -30,4 +29,3 @@ public ActionResult<AppVersionDto> Get()
});
}
}
#pragma warning restore CA1062 // Validate arguments of public methods
4 changes: 2 additions & 2 deletions src/FunderMaps.Core/Components/RandomGenerator.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using FunderMaps.Core.Interfaces;
using FunderMaps.Core.Interfaces;
using System;
using System.Security.Cryptography;

Expand All @@ -9,7 +9,7 @@ namespace FunderMaps.Core.Components
/// </summary>
public class RandomGenerator : IRandom, IDisposable
{
private readonly RandomNumberGenerator _rng = new RNGCryptoServiceProvider();
private readonly RandomNumberGenerator _rng = RandomNumberGenerator.Create();
private bool disposedValue;

/// <summary>
Expand Down
4 changes: 1 addition & 3 deletions src/FunderMaps.Core/Email/NullEmailService.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
using System.Threading;
using System.Threading;
using System.Threading.Tasks;

#pragma warning disable CA1812 // Internal class is never instantiated
namespace FunderMaps.Core.Email
{
/// <summary>
Expand All @@ -22,4 +21,3 @@ internal class NullEmailService : IEmailService
public Task HealthCheck() => Task.CompletedTask;
}
}
#pragma warning restore CA1812 // Internal class is never instantiated
2 changes: 0 additions & 2 deletions src/FunderMaps.Core/Notification/Jobs/EmailJob.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
using FunderMaps.Core.Interfaces;
using FunderMaps.Core.Threading;

#pragma warning disable CA1812 // Internal class is never instantiated
namespace FunderMaps.Core.Notification.Jobs
{
/// <summary>
Expand Down Expand Up @@ -87,4 +86,3 @@ public override bool CanHandle(Envelope envelope)
&& envelope.Recipients.All(address => address.Contains('@', System.StringComparison.InvariantCulture));
}
}
#pragma warning restore CA1812 // Internal class is never instantiated
2 changes: 0 additions & 2 deletions src/FunderMaps.Core/Notification/NotificationHub.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
using FunderMaps.Core.Threading;
using System.Threading.Tasks;

#pragma warning disable CA1812 // Internal class is never instantiated
namespace FunderMaps.Core.Notification
{
/// <summary>
Expand All @@ -28,4 +27,3 @@ public async Task NotifyAsync(Envelope envelope)
=> await _backgroundTaskDispatcher.EnqueueTaskAsync(TaskName, envelope);
}
}
#pragma warning restore CA1812 // Internal class is never instantiated
2 changes: 0 additions & 2 deletions src/FunderMaps.Core/Threading/FooBarJob.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
using System.Threading.Tasks;
using Microsoft.Extensions.Logging;

#pragma warning disable CA1812 // Internal class is never instantiated
namespace FunderMaps.Core.Threading
{
/// <summary>
Expand Down Expand Up @@ -47,4 +46,3 @@ public override bool CanHandle(string name, object value)
=> name is not null && name.ToUpperInvariant() == TaskName;
}
}
#pragma warning restore CA1812 // Internal class is never instantiated
2 changes: 0 additions & 2 deletions src/FunderMaps.Data/Providers/NpgsqlDbProvider.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
using System.Runtime.ExceptionServices;
using Npgsql.Logging;

#pragma warning disable CA1812 // Internal class is never instantiated
namespace FunderMaps.Data.Providers
{
/// <summary>
Expand Down Expand Up @@ -129,4 +128,3 @@ internal override void HandleException(ExceptionDispatchInfo edi)
}
}
}
#pragma warning restore CA1812 // Internal class is never instantiated
Loading

0 comments on commit 7d79cfa

Please sign in to comment.