From 863e9bad43ddaa31f07aa7743c5795a8b62f2031 Mon Sep 17 00:00:00 2001 From: Falkvinge Date: Sun, 13 Nov 2016 00:30:04 +0100 Subject: [PATCH] sWITCH TEST --- Site/Bases/MasterV5Base.cs | 14 ++++++++++++++ Site/Master-v5.master | 9 ++++++++- Site/Master-v5.master.designer.cs | 9 +++++++++ 3 files changed, 31 insertions(+), 1 deletion(-) diff --git a/Site/Bases/MasterV5Base.cs b/Site/Bases/MasterV5Base.cs index 4295b30d..328379fa 100644 --- a/Site/Bases/MasterV5Base.cs +++ b/Site/Bases/MasterV5Base.cs @@ -62,6 +62,20 @@ namespace Swarmops.Frontend { get { return this._authority; } } + + + // Common localizations + + // ReSharper disable InconsistentNaming + public string Localized_SwitchLabelOn_Upper + { + get { return CommonV5.JavascriptEscape(Resources.Global.Global_On.ToUpperInvariant()); } + } + + public string Localized_SwitchLabelOff_Upper + { + get { return CommonV5.JavascriptEscape(Resources.Global.Global_Off.ToUpperInvariant()); } + } } } \ No newline at end of file diff --git a/Site/Master-v5.master b/Site/Master-v5.master index 967356a4..56c68fb2 100644 --- a/Site/Master-v5.master +++ b/Site/Master-v5.master @@ -257,7 +257,8 @@

PERSONNAME:

​
- +

+

@@ -352,6 +353,12 @@ // This JavaScript block is for the Master Modal Person Editor. + $(document).ready(function() { + $('.EditCheck').switchbutton({ + checkedLabel: SwarmopsJS.unescape('<%= this.Localized_SwitchLabelOn_Upper %>'), + uncheckedLabel: SwarmopsJS.unescape('<%= this.Localized_SwitchLabelOff_Upper %>'), + }).change(function() { }); + function masterBeginEditPerson(personId) { _master_PersonEditedId = personId; diff --git a/Site/Master-v5.master.designer.cs b/Site/Master-v5.master.designer.cs index 5709a3c3..c78ff67e 100644 --- a/Site/Master-v5.master.designer.cs +++ b/Site/Master-v5.master.designer.cs @@ -372,6 +372,15 @@ namespace Swarmops.Frontend { /// protected global::System.Web.UI.WebControls.Label MasterLabelEditPersonHeaderSecurityProvisioning; + /// + /// MasterLabelEditPersonSecurity2FA control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Label MasterLabelEditPersonSecurity2FA; + /// /// MasterLabelEditPersonResetPassword control. ///