Skip to content

Commit

Permalink
#747 add key to column, reset token lifetime via tokens/get action
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidBlaa committed Apr 2, 2024
1 parent 73c1f66 commit fb46f13
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
6 changes: 4 additions & 2 deletions Components/UI/BExIS.UI/Models/DataTable.cs
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,17 @@ public DataTableRecieveModel()

public class DataTableColumn
{
public string Header { get; set; }// key by default
public string Column { get; set; }// key by default
public string Key { get; set; }// key in data array by default

public Boolean Exclude { get; set; }// false by default

public DataTableInstruction Instructions { get; set; }

public DataTableColumn()
{
Header = string.Empty;
Column = string.Empty;
Key = string.Empty;
Exclude = false;
Instructions = new DataTableInstruction();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,8 @@ private List<DataTableColumn> getColumns(StructuredDataStructure datastrutcure)
foreach (var variable in datastrutcure.Variables)
{
DataTableColumn column = new DataTableColumn();
column.Header = variable.Label;
column.Column = variable.Label;
column.Key = variable.Label.ToLower();

// set display Pattern
if (variable.DisplayPatternId > 0)
Expand Down
2 changes: 1 addition & 1 deletion Console/BExIS.Web.Shell/Controllers/TokensController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ public async Task<ActionResult> Get()
jwtConfiguration.ValidAudience,
permClaims,
notBefore: DateTime.Now,
expires: jwtConfiguration.ValidLifetime > 0 ? DateTime.Now.AddMinutes(jwtConfiguration.ValidLifetime) : DateTime.MaxValue,
expires: jwtConfiguration.ValidLifetime > 0 ? DateTime.Now.AddHours(jwtConfiguration.ValidLifetime) : DateTime.MaxValue,
signingCredentials: credentials);

var jwt_token = new JwtSecurityTokenHandler().WriteToken(token);
Expand Down

0 comments on commit fb46f13

Please sign in to comment.