Prechádzať zdrojové kódy

PRS DESKTOP - fix to user credentials link

Nick-PRSDigital@bitbucket.org 2 rokov pred
rodič
commit
12430b6c39
1 zmenil súbory, kde vykonal 13 pridanie a 1 odobranie
  1. 13 1
      prs.desktop/Panels/Users/UserGrid.cs

+ 13 - 1
prs.desktop/Panels/Users/UserGrid.cs

@@ -56,7 +56,9 @@ namespace PRSDesktop
             if (result == true)
                 expiry = edt.Value;
 
-            string toEncrypt = App.DatabaseSettings.URLs + "," + user.UserID + "," + user.Password + "," + DateTime.Now.AddMinutes(expiry);
+            string URLs = CreateURLs(App.DatabaseSettings.URLs);
+
+            string toEncrypt = URLs + "," + user.UserID + "," + user.Password + "," + DateTime.Now.AddMinutes(expiry);
             string encrypted = Encryption.Encrypt(toEncrypt, "logindetailslink", true);
             
             ioslink = ioslink + encrypted;
@@ -73,6 +75,16 @@ namespace PRSDesktop
             return true;
         }
 
+        private string CreateURLs(string[] urls)
+        {
+            string URLs = "";
+            foreach (var url in urls)
+            { 
+                URLs = URLs + url + ",";
+            }
+            return URLs + "ENDURLS";
+        }
+
         private BitmapImage? EmailImage(CoreRow? arg)
         {
             return PRSDesktop.Resources.email.AsBitmapImage();