Skip to content

Commit

Permalink
pulled main
Browse files Browse the repository at this point in the history
  • Loading branch information
allinox committed Sep 5, 2024
2 parents 6bc50b3 + 0588ebf commit cec9306
Show file tree
Hide file tree
Showing 51 changed files with 1,631 additions and 1,033 deletions.
17 changes: 17 additions & 0 deletions .github/ISSUE_TEMPLATE/bug.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
name: 🐛 Bug
about: 'Rapporter en bug'
title: ''
labels: 'kind/bug'
assignees: ''
---

# Beskrivelse av buggen

<!--- Oppgi en kort beskrivelse av hva som har skjedd og hva som skulle ha skjedd istedenfor --->

## Steg for å reprodusere buggen

<!--- Fortell oss hvordan vi kan gjenskape buggen --->

1. ...
29 changes: 29 additions & 0 deletions .github/ISSUE_TEMPLATE/epic.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
---
name: 💎 Epic
about: En leveranse
title: 'Kort leveransenavn (f.eks: Systemtilgang)'
labels: 'epic'
assignees: ''
---

# Beskrivelse

<!--- Overordnet funksjonell beskrivelse av hva som skal leveres.
Hvordan fungerer det i dag? Hvordan skal det fungere nå? Etc. --->

## Definisjoner

`Definisjon` - Noe som definerer hva noe er eller betyr

## In scope

<!--- Det vi _må_ levere som del av leveransen. --->

## Out of scope (evt. senere leveranse)

<!--- Det som _ikke_ er relevant for denne leveransen eller kan vente til senere. --->

```[tasklist]
# Features
- [ ] Legg til features her
```
63 changes: 63 additions & 0 deletions .github/ISSUE_TEMPLATE/feature.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
---
name: ✨ Feature
about: En konkret funksjon som inngår i et produkt/leveranse (tilsvarende en User Story)
title: Epic navn | Feature navn
labels: ''
assignees: ''
---

# Beskrivelse

<!--- Beskriv problemet/behovet som skal løses --->

## Definisjoner

<!--- Om nødvendig --->

Se #parentIssue

# Avklaringer

<!--- Er det noe som trenger avklaring? --->

# Akseptansekriterier

<!--- Rams opp hva som skal til for at featuren skal anses som løst --->

# Bilder/Tegninger

<!--- Eks: Arkitekturskisser eller figma-tegninger --->

# Oppgaver/Tasks

<!--- Delt opp i fagrupper --->

```[tasklist]
### Trusselmodellering
- [ ] Åpner denne endringen for mulige nye trusler eller misbruk?
```

```[tasklist]
### UX
- [ ] Add a draft title or issue reference here
```

```[tasklist]
### Frontend
- [ ] Add a draft title or issue reference here
```

```[tasklist]
### Backend
- [ ] Add a draft title or issue reference here
```

```[tasklist]
### Dokumentasjon
- [ ] Add a draft title or issue reference here
```

```[tasklist]
### Test
- [ ] Add a draft title or issue reference here
```
17 changes: 17 additions & 0 deletions .github/ISSUE_TEMPLATE/task.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
name: 🛠️ Task
about: 'Et konkret stykke arbeid som skal gjøres'
title: ''
labels: ''
assignees: ''
---

# Beskrivelse

<!--- Beskriv oppgaven som skal utføres --->

# To do's

<!--- Liste av ting som inngår i utførelsen --->

- [ ] Eks: Ta ut av oppvaskmaskinen
59 changes: 59 additions & 0 deletions .github/ISSUE_TEMPLATE/testplan.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
---
name: 🧪 Testplan
about: 'Lag en ny testplan'
title: ''
labels: ''
assignees: ''
---

| **Delivery** | <EPIC/FEATURE/CASE> |
|:-------------------------|:--------------------------------------------------|
| **Roadmap** | |
| **Involved teams** | @team-... |
| **Due date** | xx.xx.xxxx |
| **Test period** | xx.xx.xxxx - xx.xx.xxxx |


## Dependencies

| **Dependency** | **Owner** | **Status** |
|:-----------------------------------|:---------------------------|:-----------|
| | | |
| | | |
| | | |


## Functional tests
> ✅ OK, ⚠️ In progress, 🛑 Failed
> During test period run tests covering business needs and requirements listed here
| Scenario | Test data | Done by | Importance | Level | Status | Comment |
|------------|-----------|-------------|------------|---------|-------|---------|
| | | @... | High | || |
| | | @... | Low | | 🛑 | |


## Non-functional tests

- Performance tests: Link to runs and documentation when needed
- Security tests: Link to documentation when needed


## Clarifications

| **Question** | **Answer** | **Date ** |
|:---------------------------------|:-----------------------------|:-----------|
| | | |
| | | |

## ⚠️ Out of scope
> List discussed functionality out of scope or that might be relevant in a later release

## :information_source: Useful links

### Sketches
### Architecture diagrams
### Test environment
### Testd ata
### Link to milestone
350 changes: 175 additions & 175 deletions .yarn/releases/yarn-4.4.0.cjs → .yarn/releases/yarn-4.4.1.cjs

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion .yarnrc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ enableGlobalCache: false

nodeLinker: node-modules

yarnPath: .yarn/releases/yarn-4.4.0.cjs
yarnPath: .yarn/releases/yarn-4.4.1.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Altinn.Common.AccessTokenClient" Version="3.0.6" />
<PackageReference Include="Altinn.Common.AccessTokenClient" Version="3.0.7" />
<PackageReference Include="Altinn.Platform.Models" Version="1.6.1" />
<PackageReference Include="Azure.Identity" Version="1.12.0" />
<PackageReference Include="Azure.Security.KeyVault.Certificates" Version="4.6.0" />
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
namespace Altinn.AccessManagement.UI.Core.Models
{
/// <summary>
/// Represents a set of APIs given to or recieved from an organization.
/// </summary>
public class OrganizationApiSet
{
/// <summary>
/// Gets or sets the ID of the organization.
/// </summary>
public string Id { get; set; }

/// <summary>
/// Gets or sets the name of the organization.
/// </summary>
public string Name { get; set; }

/// <summary>
/// Gets or sets the organization number.
/// </summary>
public string OrgNumber { get; set; }

/// <summary>
/// Gets or sets a set of APIs given to or recieved from an organization
/// </summary>
public List<ApiListItem> ApiList { get; set; } = new List<ApiListItem>();
}

/// <summary>
/// Represents an API item.
/// </summary>
public class ApiListItem
{
/// <summary>
/// Gets or sets the ID of the API.
/// </summary>
public string Id { get; set; }

/// <summary>
/// Gets or sets the name of the API.
/// </summary>
public string ApiName { get; set; }

/// <summary>
/// Gets or sets the owner of the API.
/// </summary>
public string Owner { get; set; }

/// <summary>
/// Gets or sets the description of the API.
/// </summary>
public string Description { get; set; }

/// <summary>
/// Gets or sets the scopes associated with the API.
/// </summary>
public List<string> Scopes { get; set; }
}

/// <summary>
/// Represents the type of delegation.
/// </summary>
public enum DelegationType
{
/// <summary>
/// Offered delegation type.
/// </summary>
Offered,

/// <summary>
/// Received delegation type.
/// </summary>
Received
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
using Altinn.AccessManagement.UI.Core.Models.SingleRight;

namespace Altinn.AccessManagement.UI.Core.Models
{
/// <summary>
/// Response model for the result of a api-delegation to a recipient.
/// </summary>
public class RevokeApiDelegationOutput
{
/// <summary>
/// Gets or sets the organization identifier.
/// </summary>
public string OrgNumber { get; set; }

/// <summary>
/// Gets or sets the API identifier.
/// </summary>
public string ApiId { get; set; }

/// <summary>
/// Gets or sets a value indicating whether the operation was successful.
/// </summary>
public bool Success { get; set; }
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
using System.ComponentModel.DataAnnotations;

namespace Altinn.AccessManagement.UI.Core.Models
{
/// <summary>
/// Represents the data transfer object for revoking an offered or received delegation.
/// </summary>
public class RevokeDelegationDTO
{
/// <summary>
/// Gets or sets the organization number.
/// </summary>
[Required]
public string OrgNumber { get; set; }

/// <summary>
/// Gets or sets the API identifier.
/// </summary>
[Required]
public string ApiId { get; set; }
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,15 @@ public class RevokeOfferedDelegation
/// </summary>
[Required]
public List<Right> Rights { get; set; }

/// <summary>
/// Initializes a new instance of the <see cref="RevokeOfferedDelegation"/> class.
/// </summary>
/// <param name="dto">The DTO object containing the data for the delegation.</param>
public RevokeOfferedDelegation(RevokeDelegationDTO dto)
{
To = new List<IdValuePair> { new IdValuePair { Id = "urn:altinn:organizationnumber", Value = dto.OrgNumber } };
Rights = new List<Right> { new Right { Resource = new List<IdValuePair> { new IdValuePair { Id = "urn:altinn:resource", Value = dto.ApiId } } } };
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,15 @@ public class RevokeReceivedDelegation
/// </summary>
[Required]
public List<Right> Rights { get; set; }

/// <summary>
/// Initializes a new instance of the <see cref="RevokeReceivedDelegation"/> class.
/// </summary>
/// <param name="dto">The data transfer object for revoking a received delegation.</param>
public RevokeReceivedDelegation(RevokeDelegationDTO dto)
{
From = new List<IdValuePair> { new IdValuePair { Id = "urn:altinn:organizationnumber", Value = dto.OrgNumber } };
Rights = new List<Right> { new Right { Resource = new List<IdValuePair> { new IdValuePair { Id = "urn:altinn:resource", Value = dto.ApiId } } } };
}
}
}
Loading

0 comments on commit cec9306

Please sign in to comment.