Completato demo servizio con chiamata reset code
This commit is contained in:
@@ -45,9 +45,31 @@ namespace WebDoorCreator.API.Controllers
|
||||
/// <param name="calcResults">Risultati elaborazioni in formato CalcResultDTO</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("SaveProcResult")]
|
||||
public async Task<bool> SaveProcResult(List<CalcResultDTO> calcResults)
|
||||
public async Task<string> SaveProcResult(List<CalcResultDTO> calcResults)
|
||||
{
|
||||
bool answ = await QDataServ.SaveProcessingResult(calcResults);
|
||||
string answ = "NA";
|
||||
bool fatto = await QDataServ.SaveProcessingResult(calcResults);
|
||||
answ = fatto ? "OK" : "NO";
|
||||
return answ;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Reset delle code di chiamata x ripetere simulazione
|
||||
/// </summary>
|
||||
/// <param name="passPhrase">Chiave x auth di reset</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost("ResetQueue")]
|
||||
public async Task<string> ResetQueue(string passPhrase)
|
||||
{
|
||||
string answ = "NA";
|
||||
bool fatto = false;
|
||||
if (passPhrase == "bbbBirdIsTheWord")
|
||||
{
|
||||
// vera chaimata di reset delle code
|
||||
fatto = true;
|
||||
await Task.Delay(10);
|
||||
}
|
||||
answ = fatto ? "OK" : "NO";
|
||||
return answ;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user