From cb1b51c238c64f570d73b7dca6a2eee205b2da01 Mon Sep 17 00:00:00 2001 From: Roy Ben Shabat Date: Sat, 11 Apr 2020 00:54:54 +0300 Subject: Implemented FSE bug reporting !!! --- .../Web/Tango.MachineService/Controllers/FSEController.cs | 13 +++++++++++++ .../Web/Tango.MachineService/MachineServiceConfig.cs | 4 ++++ Software/Visual_Studio/Web/Tango.MachineService/Web.config | 4 ++++ 3 files changed, 21 insertions(+) (limited to 'Software/Visual_Studio/Web') diff --git a/Software/Visual_Studio/Web/Tango.MachineService/Controllers/FSEController.cs b/Software/Visual_Studio/Web/Tango.MachineService/Controllers/FSEController.cs index 95a26d78e..dccf2d24c 100644 --- a/Software/Visual_Studio/Web/Tango.MachineService/Controllers/FSEController.cs +++ b/Software/Visual_Studio/Web/Tango.MachineService/Controllers/FSEController.cs @@ -10,6 +10,7 @@ using Tango.BL.Entities; using Tango.Core; using Tango.Core.Cryptography; using Tango.FSE.Web.Messages; +using Tango.MachineService.Filters; using Tango.Web.Controllers; using Tango.Web.Helpers; using Tango.Web.Security; @@ -104,5 +105,17 @@ namespace Tango.MachineService.Controllers PasswordChangeRequired = user.PasswordChangeRequired }; } + + [HttpPost] + [JwtTokenFilter] + public BugReportingInfoResponse GetBugReportInfo(BugReportingInfoRequest request) + { + return new BugReportingInfoResponse() + { + CollectionUrl = MachineServiceConfig.FSE_TFS_COLLECTION_URL, + PersonalToken = MachineServiceConfig.FSE_TFS_PERSONAL_TOKEN, + UserEmail = MachineServiceConfig.FSE_TFS_USER_EMAIL + }; + } } } diff --git a/Software/Visual_Studio/Web/Tango.MachineService/MachineServiceConfig.cs b/Software/Visual_Studio/Web/Tango.MachineService/MachineServiceConfig.cs index 014ef68ba..f781dbb89 100644 --- a/Software/Visual_Studio/Web/Tango.MachineService/MachineServiceConfig.cs +++ b/Software/Visual_Studio/Web/Tango.MachineService/MachineServiceConfig.cs @@ -17,5 +17,9 @@ namespace Tango.MachineService public static String REFRESH_TOKENS_TABLE_PARTITION => ConfigurationManager.AppSettings[nameof(REFRESH_TOKENS_TABLE_PARTITION)].ToString(); public static bool USE_DB_ACCESS_TOKENS => bool.Parse(ConfigurationManager.AppSettings[nameof(USE_DB_ACCESS_TOKENS)].ToString()); public static String CDN_ENDPOINT => ConfigurationManager.AppSettings[nameof(CDN_ENDPOINT)].ToString(); + + public static String FSE_TFS_COLLECTION_URL => ConfigurationManager.AppSettings[nameof(FSE_TFS_COLLECTION_URL)].ToString(); + public static String FSE_TFS_PERSONAL_TOKEN => ConfigurationManager.AppSettings[nameof(FSE_TFS_PERSONAL_TOKEN)].ToString(); + public static String FSE_TFS_USER_EMAIL => ConfigurationManager.AppSettings[nameof(FSE_TFS_USER_EMAIL)].ToString(); } } \ No newline at end of file diff --git a/Software/Visual_Studio/Web/Tango.MachineService/Web.config b/Software/Visual_Studio/Web/Tango.MachineService/Web.config index 1da22f45b..2c6408e50 100644 --- a/Software/Visual_Studio/Web/Tango.MachineService/Web.config +++ b/Software/Visual_Studio/Web/Tango.MachineService/Web.config @@ -31,6 +31,10 @@ + + + +