From e5761a871cf91509b6ac7c64a6629e4777c3883f Mon Sep 17 00:00:00 2001 From: Kelsey Rangel Date: Fri, 30 Oct 2015 16:03:07 -0700 Subject: [PATCH] Refactor TextCopy function --- DeviceAdministration/Web/App_Code/IoTHelpers.cshtml | 2 +- .../Web/Views/Device/_AddDeviceCopy.cshtml | 7 +++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/DeviceAdministration/Web/App_Code/IoTHelpers.cshtml b/DeviceAdministration/Web/App_Code/IoTHelpers.cshtml index 34b1288b..1cfe9569 100644 --- a/DeviceAdministration/Web/App_Code/IoTHelpers.cshtml +++ b/DeviceAdministration/Web/App_Code/IoTHelpers.cshtml @@ -1,5 +1,5 @@ @using GlobalResources -@helper TextCopy(string idPrefix, string classname, string content, string class_styles_modifier, string button_style_modifier = "") +@helper TextCopy(string idPrefix, string classname, string content, string class_styles_modifier = "", string button_style_modifier = "") { var uniqueId = string.Format("{0}_{1}", idPrefix, Guid.NewGuid()); diff --git a/DeviceAdministration/Web/Views/Device/_AddDeviceCopy.cshtml b/DeviceAdministration/Web/Views/Device/_AddDeviceCopy.cshtml index b051ec67..c9f2dccc 100644 --- a/DeviceAdministration/Web/Views/Device/_AddDeviceCopy.cshtml +++ b/DeviceAdministration/Web/Views/Device/_AddDeviceCopy.cshtml @@ -13,7 +13,6 @@ else @{ string classname = "text_copy_container__input--add_device_copy_table"; - string class_styles_modifier = ""; @@ -22,7 +21,7 @@ else @Strings.DeviceIdColon @@ -30,7 +29,7 @@ else @Strings.AzureDevicesHostnameColon @@ -38,7 +37,7 @@ else @Strings.DeviceKeyColon
- @IoTHelpers.TextCopy("DeviceId", classname, @Model.DeviceId, class_styles_modifier) + @IoTHelpers.TextCopy("DeviceId", classname, @Model.DeviceId)
- @IoTHelpers.TextCopy("AzureDevicesHostname", classname, @Model.HostName, class_styles_modifier) + @IoTHelpers.TextCopy("AzureDevicesHostname", classname, @Model.HostName)
- @IoTHelpers.TextCopy("PrimaryKey", classname, @Model.PrimaryKey, class_styles_modifier) + @IoTHelpers.TextCopy("PrimaryKey", classname, @Model.PrimaryKey)