Add SID mapping system
This commit is contained in:
parent
b54a366f70
commit
98da7c10f0
3 changed files with 152 additions and 8 deletions
|
|
@ -169,6 +169,7 @@ namespace MatterHackers.MatterControl.SettingsManagement
|
|||
public OemProfileDictionary OemProfiles { get; set; }
|
||||
|
||||
public Dictionary<string, string> OemUrls { get; }
|
||||
public Dictionary<string, StorePrinterID> OemPrinters { get; }
|
||||
|
||||
[OnDeserialized]
|
||||
private void Deserialized(StreamingContext context)
|
||||
|
|
@ -256,9 +257,16 @@ namespace MatterHackers.MatterControl.SettingsManagement
|
|||
{
|
||||
this.ManufacturerNameMappings = new List<ManufacturerNameMapping>();
|
||||
this.OemUrls = JsonConvert.DeserializeObject<Dictionary<string, string>>(AggContext.StaticData.ReadAllText(Path.Combine("OEMSettings", "OEMUrls.json")));
|
||||
this.OemPrinters = JsonConvert.DeserializeObject<Dictionary<string, StorePrinterID>>(AggContext.StaticData.ReadAllText(Path.Combine("OEMSettings", "Printers.json")));
|
||||
}
|
||||
}
|
||||
|
||||
public class StorePrinterID
|
||||
{
|
||||
public string SID { get; set; }
|
||||
public string AltInfoUrl { get; set; }
|
||||
}
|
||||
|
||||
public class ManufacturerNameMapping
|
||||
{
|
||||
public string NameOnDisk { get; set; }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue