HOME:
- Aggiornamento x metodo JSON encoded (x evitare problemi authKey)
This commit is contained in:
@@ -8,6 +8,7 @@ using Newtonsoft.Json;
|
||||
using System.Collections.Generic;
|
||||
using ZXing.Common;
|
||||
using System.Reflection;
|
||||
using System.Linq;
|
||||
|
||||
namespace QR_GEN.Controllers
|
||||
{
|
||||
@@ -179,6 +180,16 @@ namespace QR_GEN.Controllers
|
||||
// svuoto val...
|
||||
val = "";
|
||||
break;
|
||||
case "JSON_ENC":
|
||||
// devo DESERIALIZZARE...
|
||||
var objRaw = JsonConvert.DeserializeObject<qrPayload>(val);
|
||||
// eseguo urlencode dei parametri...
|
||||
var objEnc = objRaw.parameters.Select(x => HttpUtility.UrlEncode(x)).ToArray();
|
||||
// metto tutto in tgtUrl...
|
||||
tgtUrl = string.Format(objRaw.baseUrl, objEnc);
|
||||
// svuoto val...
|
||||
val = "";
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user