Compare commits
2 Commits
c3a414285a
...
39c18ee9bf
Author | SHA1 | Date | |
---|---|---|---|
39c18ee9bf | |||
30ac25c8fb |
@ -132,7 +132,8 @@ namespace EFB.Controllers
|
||||
headerData.Add("referer", "luke-else.co.uk");
|
||||
|
||||
Dictionary<string, string> formData = new Dictionary<string, string>();
|
||||
formData.Add("token", "");
|
||||
|
||||
formData.Add("token", Environment.GetEnvironmentVariable("ChartFoxAPIKey", EnvironmentVariableTarget.User));
|
||||
var body = new FormUrlEncodedContent(formData);
|
||||
|
||||
//make Charts request
|
||||
|
@ -3,6 +3,7 @@ using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using EFB.Models.JSON;
|
||||
using Newtonsoft.Json;
|
||||
|
||||
namespace EFB.Models
|
||||
{
|
||||
@ -16,7 +17,11 @@ namespace EFB.Models
|
||||
public Chart[] Approach { get; set; }
|
||||
public Chart[] Transition { get; set; }
|
||||
public Chart[] PilotBriefing { get; set; }
|
||||
|
||||
|
||||
[JsonConstructor]
|
||||
public ChartModel(){
|
||||
//Empty constructor for JSON Serialisation Purposes
|
||||
}
|
||||
public ChartModel(ChartList response)
|
||||
{
|
||||
General = FillChart(response.General);
|
||||
|
@ -39,7 +39,8 @@ namespace EFB.Models
|
||||
}
|
||||
|
||||
public static async Task<NavdataModel[]> Populate(){
|
||||
MySqlConnection con = new MySqlConnection("server=server.luke-else.co.uk;userid=root;password=;database=EFB");
|
||||
string password = Environment.GetEnvironmentVariable("MySQLPassword", EnvironmentVariableTarget.User);
|
||||
MySqlConnection con = new MySqlConnection($"server=server.luke-else.co.uk;userid=root;password={password};database=EFB");
|
||||
con.Open();
|
||||
|
||||
// Console.WriteLine($"MySQL version : {con.ServerVersion}");
|
||||
|
Loading…
x
Reference in New Issue
Block a user