Most működik az üzenetküldés Backenden

This commit is contained in:
2025-04-07 17:05:27 +02:00
parent a3be387ee1
commit 85976547f6
13 changed files with 1056 additions and 70 deletions
@@ -1,4 +1,5 @@
using Microsoft.AspNetCore.Mvc;
using Microsoft.IdentityModel.Tokens;
using Serilog;
using System.Text;
using WorkFlowCheck.BL.Services;
@@ -442,7 +443,7 @@ namespace WorkFlowCheck.API.Controllers
IsSuccess = true,
};
byte[] byteArray = Convert.FromBase64String(deviceIdBase64);
byte[] byteArray = Base64UrlEncoder.DecodeBytes(deviceIdBase64);
string deviceId = Encoding.UTF8.GetString(byteArray);
@@ -154,10 +154,10 @@ namespace WorkFlowCheck.API.Controllers
}
try
{
var userDTO_Response = await _userService.Authenticate(userSimpleDTO.UserName, userSimpleDTO.Password);
var userDTO_Response = await _userService.AuthenticateNFC(userSimpleDTO.UserName);
if (userDTO_Response != null)
{
if (string.IsNullOrEmpty(userDTO_Response.UserName) == false && userDTO_Response.UserName == userSimpleDTO.UserName)
if (string.IsNullOrEmpty(userDTO_Response.UserName) == false && userDTO_Response.NFCActive)
{
retVal.IsSuccess = true;
retVal.Data = userDTO_Response;