This repository has been archived by the owner on Feb 14, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 563
/
AppSettings.cs
53 lines (34 loc) · 2.81 KB
/
AppSettings.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
using System;
using System.Configuration;
namespace DotnetFoundationWeb
{
public static class AppSettings
{
public static string ContactEmail { get; set; } = ConfigurationManager.AppSettings["ContactEmail"];
public static string Title { get; set; } = ConfigurationManager.AppSettings["SiteTitle"];
public static string Description { get; set; } = ConfigurationManager.AppSettings["SiteDescription"];
public static string BaseRef { get; set; } = ConfigurationManager.AppSettings["BaseRef"];
public static string ServerUrl { get; set; } = ConfigurationManager.AppSettings["ServerUrl"];
public static bool IsCampaignOpen { get; set; }
= string.Equals(ConfigurationManager.AppSettings["IsCampaignOpen"], "true", StringComparison.OrdinalIgnoreCase);
public static bool ShowCampaignResults { get; set; }
= string.Equals(ConfigurationManager.AppSettings["ShowCampaignResults"], "true", StringComparison.OrdinalIgnoreCase);
public static string AzureSearchQueryKey { get; set; } = ConfigurationManager.AppSettings["AzureSearchQueryKey"];
public static int ContributionsCounter { get; set; } = int.Parse(ConfigurationManager.AppSettings["ContributionsCounter"]);
public static int CompaniesCounter { get; set; } = int.Parse(ConfigurationManager.AppSettings["CompaniesCounter"]);
public static int ActiveProjectsCounter { get; set; } = int.Parse(ConfigurationManager.AppSettings["ActiveProjectsCounter"]);
public static int ResourcesCounter { get; set; } = int.Parse(ConfigurationManager.AppSettings["ResourcesCounter"]);
public static string GoogleAnalytics { get; set; } = ConfigurationManager.AppSettings["GoogleAnalytics"];
public static string Lang { get; set; } = ConfigurationManager.AppSettings["Lang"];
public static bool SuppressSpeakers { get; set; }
= string.Equals(ConfigurationManager.AppSettings["SuppressSpeakers"], "true", StringComparison.OrdinalIgnoreCase);
public static bool SuppressProjects { get; set; }
= string.Equals(ConfigurationManager.AppSettings["SuppressProjects"], "true", StringComparison.OrdinalIgnoreCase);
public static bool SuppressSpeakerBlogs { get; set; }
= string.Equals(ConfigurationManager.AppSettings["SuppressSpeakerBlogs"], "true", StringComparison.OrdinalIgnoreCase);
public static bool SuppressSpeakerGeoLocation { get; set; }
= string.Equals(ConfigurationManager.AppSettings["SuppressSpeakerGeoLocation"], "true", StringComparison.OrdinalIgnoreCase);
public static bool SuppressSpeakerImages { get; set; }
= string.Equals(ConfigurationManager.AppSettings["SuppressSpeakerImages"], "true", StringComparison.OrdinalIgnoreCase);
}
}