Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Develop #116

Merged
merged 28 commits into from
May 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
fd66eca
#86696cxr4 Sync from upstream
ucswift Aug 27, 2023
79a04f6
Merge branch 'master' into develop
ucswift Aug 27, 2023
98b0262
#86696cxr4 fixing bad project ref
ucswift Aug 27, 2023
3f28427
CU-8686t78w1 Syncing with upstream
ucswift Dec 19, 2023
594bec3
CU-8686t78w1 updated from upstream repo
ucswift Jan 27, 2024
5e92461
CU-8686t78w1 updated readme
ucswift Jan 27, 2024
a57583e
CU-8686t78w1 bug fixes
ucswift Feb 6, 2024
4ee57b4
CU-8687yhbz5 moving mainline dev from upstream to core
ucswift May 9, 2024
4357cbb
CU-8687yhbz5 adding missing smoke test project.
ucswift May 10, 2024
e74bd69
CU-8687yhbz5 updating dependabot config
ucswift May 10, 2024
75ce535
CU-8687yhbz5 Updated OpenTelemetry
ucswift May 10, 2024
e63fd1e
Update appveyor.yml
ucswift May 10, 2024
537868f
CU-8687yhbz5 Minor system behavior default change
ucswift May 10, 2024
c40a03a
Update appveyor.yml
ucswift May 10, 2024
e8cfd2e
Update appveyor.yml
ucswift May 10, 2024
ea29b7b
Update appveyor.yml
ucswift May 10, 2024
ecffd52
Update appveyor.yml
ucswift May 10, 2024
d2c5461
Update appveyor.yml
ucswift May 10, 2024
1ecb938
Update appveyor.yml
ucswift May 10, 2024
08f9fb0
Update appveyor.yml
ucswift May 10, 2024
faf2e0a
Update appveyor.yml
ucswift May 10, 2024
d8a5a76
Update appveyor.yml
ucswift May 10, 2024
50ce794
Update appveyor.yml
ucswift May 10, 2024
c848705
Update appveyor.yml
ucswift May 10, 2024
b558480
Create dotnet.yml
ucswift May 10, 2024
875c4aa
Merge pull request #115 from Resgrid/ucswift-patch-1
ucswift May 10, 2024
0357b33
CU-8687yhbz5 removing appveyor
ucswift May 10, 2024
d461292
CU-8687yhbz5 adjusting build
ucswift May 10, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
15 changes: 15 additions & 0 deletions .deepsource.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
version = 1

[[analyzers]]
name = "csharp"


[[analyzers]]
name = "javascript"

[analyzers.meta]
plugins = ["angular"]


[analyzers.meta]
runtime_version = "3.x.x"
1 change: 1 addition & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,6 @@
**/obj
**/secrets.dev.yaml
**/values.dev.yaml
**/node_modules
LICENSE
README.md
1 change: 1 addition & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,6 @@ version: 2
updates:
- package-ecosystem: "npm" # See documentation for possible values
directory: "/" # Location of package manifests
target-branch: "develop"
schedule:
interval: "weekly"
26 changes: 26 additions & 0 deletions .github/workflows/auto-approve.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Auto approve

on:
issue_comment:
types:
- created

jobs:
auto-approve:
runs-on: ubuntu-latest
permissions:
pull-requests: write
steps:
- uses: actions/github-script@v6
name: Approve LGTM Review
if: github.actor == 'ucswift' && contains(github.event.comment.body, 'Approve')
with:
script: |
github.rest.pulls.createReview({
owner: context.repo.owner,
repo: context.repo.repo,
pull_number: context.issue.number,
review_id: 1,
event: 'APPROVE',
body: 'This PR is approved.'
})
26 changes: 26 additions & 0 deletions .github/workflows/dotnet.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# This workflow will build a .NET project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net

name: .NET

on:
pull_request:
branches: [ "master", "develop" ]

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.x
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet build --no-restore
- name: Test
run: dotnet test --no-build --verbosity normal
10 changes: 2 additions & 8 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -141,12 +141,9 @@ deploy.cmd
Packages.dgml
OffRuleSet.ruleset
Build/*
Resgrid.sln
Resgrid.xml
Resgrid-NoCore.sln
.idea/*
Tests/Resgrid.TestHarness/*
Tests/Resgrid.TestHarnessCore/*
Tests/Resgrid.SmokeTests/*
Web/Resgrid.WebCore/appsettings.Azure.json
Web/Resgrid.WebCore/appsettings.Development.json
Web/Resgrid.WebCore/appsettings.Production.json
Expand Down Expand Up @@ -194,13 +191,9 @@ Common/resgrid.local.pfx
Web/Resgrid.Web.ServicesCore/Properties/serviceDependencies.json
Web/Resgrid.Web.ServicesCore/Properties/serviceDependencies.local.json
Web/Resgrid.Web.ServicesCore/Properties/ServiceDependencies/local/appInsights1.arm.json

Docker/docker-data/dms/mail-state/lib-clamav/bytecode.cvd

Docker/docker-data/dms/mail-state/lib-clamav/daily.cvd

Docker/docker-data/dms/mail-state/lib-clamav/freshclam.dat

Docker/docker-data/dms/mail-state/lib-clamav/main.cvd
Docker/docker-data/dms/config/dovecot-quotas.cf
Docker/docker-data/dms/config/mailconfig
Expand Down Expand Up @@ -308,3 +301,4 @@ Web/Resgrid.WebCore/wwwroot/js/ng/main.js
Web/Resgrid.WebCore/wwwroot/js/ng/polyfills.js
Web/Resgrid.WebCore/wwwroot/js/ng/runtime.js
Web/Resgrid.WebCore/wwwroot/js/ng/styles.css
Web/Resgrid.WebCore/wwwroot/js/ng/*
26 changes: 26 additions & 0 deletions Common/Resgrid/Auth/Login.bru
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
meta {
name: Login
type: http
seq: 1
}

post {
url: {{BASE_API_URL}}/connect/token
body: formUrlEncoded
auth: none
}

headers {
Content-Type: application/x-www-form-urlencoded
}

body:form-urlencoded {
grant_type: password
scope: openid profile offline_access
username: {{USERNAME}}
password: {{PASSWORD}}
}

vars:post-response {
access_token: res.body.access_token
}
36 changes: 36 additions & 0 deletions Common/Resgrid/CreateCall.bru
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
meta {
name: CreateCall
type: http
seq: 1
}

post {
url: {{BASE_API_URL}}/Calls/SaveCall
body: json
auth: bearer
}

auth:bearer {
token: {{access_token}}
}

body:json {
{
"Priority": "1",
"Name": "Jane Smith",
"Nature": "This is the nature of my call",
"Note": "These are the notes of the call",
"Address": "123 Main St., Wilmington, OH",
"Geolocation": "",
"Type": "",
"What3Words": "",
"DispatchList": "U:5733",
"ContactName": "null",
"ContactInfo": "null",
"ExternalId": "null",
"IncidentId": "null",
"ReferenceId": "null",
"DispatchOn": "2024-03-07T02:32:53.842Z",
"CallFormData": "null"
}
}
9 changes: 9 additions & 0 deletions Common/Resgrid/bruno.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"version": "1",
"name": "Resgrid",
"type": "collection",
"ignore": [
"node_modules",
".git"
]
}
5 changes: 5 additions & 0 deletions Common/Resgrid/environments/Dev.bru
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
vars:secret [
BASE_API_URL,
USERNAME,
PASSWORD
]
2 changes: 2 additions & 0 deletions Common/Resgrid/environments/QA.bru
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
vars {
}
5 changes: 5 additions & 0 deletions Core/Resgrid.Config/ApiConfig.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,10 @@ public static class ApiConfig
/// Allowed Methods (verbs) for CORS access. NOTE: CANNOT BE SET VIA THE CONFIG FILE.
/// </summary>
public const string CorsAllowedMethods = "GET,POST,PUT,DELETE,OPTIONS";

/// <summary>
/// Key used for authing with the backend internal apis
/// </summary>
public static string BackendInternalApikey = "";
}
}
13 changes: 13 additions & 0 deletions Core/Resgrid.Config/AuditConfig.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
namespace Resgrid.Config
{
/// <summary>
/// Config settings for the operation of the auditing sub-system
/// </summary>
public static class AuditConfig
{
/// <summary>
/// Connection string to the audit database
/// </summary>
public static string ConnectionString = "Server=rgdevserver;Database=ResgridAudit;User Id=resgrid_audit;Password=resgrid123;MultipleActiveResultSets=True;";
}
}
4 changes: 2 additions & 2 deletions Core/Resgrid.Config/ChatConfig.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
{
public static class ChatConfig
{
public static string DepartmentChatPrefix = "";
public static string DepartmentGroupChatPrefix = "";
public static string DepartmentChatPrefix = "D1_";
public static string DepartmentGroupChatPrefix = "DG1_";
}
}
5 changes: 5 additions & 0 deletions Core/Resgrid.Config/ConfigProcessor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
{
if (String.IsNullOrWhiteSpace(path))
{
path = Path.GetDirectoryName(Assembly.GetExecutingAssembly().CodeBase).Replace("file:\\", "");

Check warning on line 17 in Core/Resgrid.Config/ConfigProcessor.cs

View workflow job for this annotation

GitHub Actions / build

'Assembly.CodeBase' is obsolete: 'Assembly.CodeBase and Assembly.EscapedCodeBase are only included for .NET Framework compatibility. Use Assembly.Location.' (https://aka.ms/dotnet-warnings/SYSLIB0012)
path = $"{path}\\ResgridConfig.json";
}

Expand All @@ -37,6 +37,8 @@
FieldInfo prop = configObj.GetField(parts[1]);
if (null != prop)
{
Console.WriteLine($"Resgrid.Config: Setting Value for {prop.ToString()}");

if (prop.FieldType.BaseType == typeof(Enum))
{
Type t = Nullable.GetUnderlyingType(prop.FieldType) ?? prop.FieldType;
Expand All @@ -62,7 +64,7 @@
return true;
}
}
catch (Exception ex)

Check warning on line 67 in Core/Resgrid.Config/ConfigProcessor.cs

View workflow job for this annotation

GitHub Actions / build

The variable 'ex' is declared but never used
{
return false;
}
Expand All @@ -72,6 +74,8 @@

public static bool LoadAndProcessEnvVariables(IEnumerable<KeyValuePair<string, string>> values)
{
Console.WriteLine($"Resgrid.Config: Processing Environment Variables");

bool hasSetAtLeastOneVariable = false;

try
Expand All @@ -94,6 +98,7 @@
if (null != prop)
{
Console.WriteLine($"Resgrid.Config: Setting Value for {prop.ToString()}");

if (prop.FieldType.BaseType == typeof(Enum))
{
Type t = Nullable.GetUnderlyingType(prop.FieldType) ?? prop.FieldType;
Expand All @@ -119,7 +124,7 @@
return hasSetAtLeastOneVariable;

}
catch (Exception ex)

Check warning on line 127 in Core/Resgrid.Config/ConfigProcessor.cs

View workflow job for this annotation

GitHub Actions / build

The variable 'ex' is declared but never used
{
return false;
}
Expand Down
Loading
Loading