diff --git a/Saxonite.sln b/Saxonite.sln index b026aac..df0a64b 100644 --- a/Saxonite.sln +++ b/Saxonite.sln @@ -27,6 +27,8 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "SaxoniteCoreUnitTests", "Sa EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution files", "Solution files", "{BD66A338-2D41-4B64-86B0-670F4F42A489}" EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SaxoniteCoreUnitTestsOnline", "SaxoniteCoreUnitTestsOnline\SaxoniteCoreUnitTestsOnline.csproj", "{303BA8E9-1B95-41AD-9F51-32037A22C908}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -77,6 +79,10 @@ Global {CA680625-E334-4F76-881B-1327A2F9FE86}.Debug|Any CPU.Build.0 = Debug|Any CPU {CA680625-E334-4F76-881B-1327A2F9FE86}.Release|Any CPU.ActiveCfg = Release|Any CPU {CA680625-E334-4F76-881B-1327A2F9FE86}.Release|Any CPU.Build.0 = Release|Any CPU + {303BA8E9-1B95-41AD-9F51-32037A22C908}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {303BA8E9-1B95-41AD-9F51-32037A22C908}.Debug|Any CPU.Build.0 = Debug|Any CPU + {303BA8E9-1B95-41AD-9F51-32037A22C908}.Release|Any CPU.ActiveCfg = Release|Any CPU + {303BA8E9-1B95-41AD-9F51-32037A22C908}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/SaxoniteCoreUnitTestsOnline/SaxoniteCoreUnitTestsOnline.csproj b/SaxoniteCoreUnitTestsOnline/SaxoniteCoreUnitTestsOnline.csproj new file mode 100644 index 0000000..c0d1a44 --- /dev/null +++ b/SaxoniteCoreUnitTestsOnline/SaxoniteCoreUnitTestsOnline.csproj @@ -0,0 +1,29 @@ + + + + netcoreapp3.1 + + false + + Saxonite.Net.Core + + + + + + + + + + + + + + + + + + + + + diff --git a/SaxoniteCoreUnitTestsOnline/UnitTests/Online/App/SaxApplication_Admin_Tester.cs b/SaxoniteCoreUnitTestsOnline/UnitTests/Online/App/SaxApplication_Admin_Tester.cs new file mode 100644 index 0000000..e565f8c --- /dev/null +++ b/SaxoniteCoreUnitTestsOnline/UnitTests/Online/App/SaxApplication_Admin_Tester.cs @@ -0,0 +1,55 @@ +using Microsoft.AspNetCore.Hosting; +using Microsoft.Extensions.Configuration; +using Microsoft.Extensions.Hosting; +using Microsoft.VisualStudio.TestTools.UnitTesting; +using Moq; +using Saxonite.Net.Core.Web.Online.App; +using Saxonite.Net.Standard.Base.App; +using System; +using System.Collections.Generic; +using System.Text; + +namespace Saxonite.Net.Core.UnitTests.Web.Online.App +{ + //======================================================================= + [TestClass] + public class SaxApplication_Online_Tester + { + //------------------------------------------------------------------- + // Application. + private class SaxApplication_Online_Test : SaxApplication_Online + { + public SaxApplication_Online_Test(IConfiguration configuration, IWebHostEnvironment env) : + base(configuration) + { + InitEnvironment(env); + } + } + private static SaxApplication_Online_Test app; + public static SaxApplication_Online App + { + get + { + if (app == null) + { + var mockConfiguration = new Mock(); + + var mockEnvironment = new Mock(); + mockEnvironment.Setup(m => m.EnvironmentName).Returns(Environments.Development); + mockEnvironment.Setup(m => m.ContentRootPath).Returns(@"D:\Sarand\Projects\Users\AHoward\VS2019\Saxonite\Workspace\SaxoniteCoreWebOnline"); + + app = new SaxApplication_Online_Test(mockConfiguration.Object, mockEnvironment.Object); + } + return app; + } + } + + //------------------------------------------------------------------- + // Internals - component managers etc. + private static SaxInternals internals; + public static SaxInternals Internals { get { if (internals == null) internals = new SaxInternals(App.SessionContext); return internals; } } + + //------------------------------------------------------------------- + } + //======================================================================= +} diff --git a/SaxoniteCoreUnitTestsOnline/UnitTests/Online/App/SaxSessionData_Tester.cs b/SaxoniteCoreUnitTestsOnline/UnitTests/Online/App/SaxSessionData_Tester.cs new file mode 100644 index 0000000..694ffa5 --- /dev/null +++ b/SaxoniteCoreUnitTestsOnline/UnitTests/Online/App/SaxSessionData_Tester.cs @@ -0,0 +1,93 @@ +using Microsoft.VisualStudio.TestTools.UnitTesting; +using Newtonsoft.Json; +using Sarand.Net.Standard.Base.Bus; +using Saxonite.Net.Core.Web.Online.App; +using Saxonite.Net.Core.Web.Base.Controllers; +using Saxonite.Net.Standard.Base.App; +using Saxonite.Net.Standard.Base.Bus; +using Saxonite.Net.Standard.Base.Mgr; +using System; +using System.Collections.Generic; +using System.Text; +using Sarand.Net.Standard.Base.Helpers; + +namespace Saxonite.Net.Core.UnitTests.Web.Online.App +{ + //======================================================================= + [TestClass] + public class SaxSessionData_Tester + { + //------------------------------------------------------------------- + // Properties. + public static SaxApplication_Online App { get { return SaxApplication_Online_Tester.App; } } + public static SaxInternals Internals { get { return SaxApplication_Online_Tester.Internals; } } + + //------------------------------------------------------------------- + [TestMethod] + public void Test_SmmSessionData_Serialization() + { + // User account. + SaxAccountMgr accountMgr = Internals.AccountMgr; + + // User account. + SaxUserAccount userAccount = accountMgr.CreateUserAccount(); + userAccount.Id = new SysId(45678); + userAccount.EmailAddress = "john.smith@acme.co.uk"; + userAccount.FirstName = "John"; + userAccount.LastName = "Smith"; + + // User Roles. + List userRoles = new List(); + SaxUserRole userRole = accountMgr.CreateUserRole(userAccount.Id, Sax.UserRole.Journalist); + userRoles.Add(userRole); + + // Create user session and verify user id. + SaxSessionData_Online sessionData = new SaxSessionData_Online(App.SessionContext, userAccount, userRoles); + Assert.AreEqual(SysId.ToInt(sessionData.User.UserAccountId), SysId.ToInt(sessionData.User.UserAccountId)); + Assert.AreEqual(userAccount.FirstName, sessionData.User.FirstName); + Assert.AreEqual(userAccount.LastName, sessionData.User.LastName); + Assert.IsTrue(sessionData.ValidUserSession); + Assert.AreNotEqual("", sessionData.User.DisplayName); + + // Filter properties. + SysId filterOrganisationId = new SysId(SacsRandomHelper.GetInt32(Int32.MaxValue)); + sessionData.Filter.OrganisationId = filterOrganisationId; + SysId filterOrganisationIdMember = new SysId(SacsRandomHelper.GetInt32(Int32.MaxValue)); + sessionData.Filter.OrganisationIdMember = filterOrganisationIdMember; + + // Serialise session data using same method as base controller. + String sessionDataJson = JsonConvert.SerializeObject(sessionData); + Assert.AreNotEqual("", sessionDataJson); + + // Deserialise session data using same method as base controller. + SaxSessionData_Online sessionDataDeserialized = + JsonConvert.DeserializeObject( + sessionDataJson, + new JsonSerializerSettings { ContractResolver = new SaxController_Base.SessionStorage.SaxSessionDataContractResolver() } + ); + Assert.IsNotNull(sessionDataDeserialized); + + // Validate deserialised values. + Assert.AreEqual(App.SessionContext.Index, sessionDataDeserialized.SessionContext.Index); + Assert.AreEqual(Sax.Application.Online, sessionDataDeserialized.SessionContext.Application); + Assert.AreEqual(SysId.ToInt(sessionDataDeserialized.User.UserAccountId), SysId.ToInt(sessionDataDeserialized.User.UserAccountId)); + Assert.AreEqual(SysId.ToInt(sessionData.User.UserAccountId), SysId.ToInt(sessionDataDeserialized.User.UserAccountId)); + Assert.AreEqual(sessionData.User.EmailAddress, sessionDataDeserialized.User.EmailAddress); + Assert.AreEqual(sessionData.User.FirstName, sessionDataDeserialized.User.FirstName); + Assert.AreEqual(sessionData.User.LastName, sessionDataDeserialized.User.LastName); + Assert.AreEqual(sessionData.User.DisplayName, sessionDataDeserialized.User.DisplayName); + // User roles. + Assert.AreEqual(userRoles.Count, sessionDataDeserialized.User.Roles.Count); + // Filter properties. + Assert.IsNotNull(sessionData.Filter.OrganisationId); + Assert.IsTrue(SysId.IsValid(sessionData.Filter.OrganisationId)); + Assert.AreEqual(filterOrganisationId, sessionData.Filter.OrganisationId); + Assert.IsNotNull(sessionData.Filter.OrganisationIdMember); + Assert.IsTrue(SysId.IsValid(sessionData.Filter.OrganisationIdMember)); + Assert.AreEqual(filterOrganisationIdMember, sessionData.Filter.OrganisationIdMember); + } + + //------------------------------------------------------------------- + } + //======================================================================= +} diff --git a/SaxoniteCoreWeb/Base/App/SaxLocaliser.cs b/SaxoniteCoreWeb/Base/App/SaxLocaliser.cs index 71d3666..eea16a9 100644 --- a/SaxoniteCoreWeb/Base/App/SaxLocaliser.cs +++ b/SaxoniteCoreWeb/Base/App/SaxLocaliser.cs @@ -122,6 +122,17 @@ namespace Saxonite.Net.Core.Web.Base.App //------------------------------------------------------------------- // Specific phrase translation. //------------------------------------------------------------------- + private class CodeCache + { + public List regionTypes; + public List userRoles; + public List organisationTypes; + public List organisationCategories; + public List organisationRoles; + public List opportunityTypes; + } + private CodeCache codes = new CodeCache(); + // Status. public String GetStatusCaption(SaStatus status) { @@ -130,36 +141,63 @@ namespace Saxonite.Net.Core.Web.Base.App } // Region type. - private List regionTypes; public String GetRegionTypeCaption(Sax.RegionType regionType) { if ((int)regionType < 1) return ""; - if (regionTypes == null) - regionTypes = SaxSystem.GetCodesOfType(Sax.CodeType.RegionType); + if (codes.regionTypes == null) + codes.regionTypes = SaxSystem.GetCodesOfType(Sax.CodeType.RegionType); // ToDo Region type localisation. - return regionTypes.GetDescForType(regionType); + return codes.regionTypes.GetDescForType(regionType); } // User role. - private List userRoles; public String GetUserRoleCaption(Sax.UserRole userRole) { if ((int)userRole < 1) return ""; - if (userRoles == null) - userRoles = SaxSystem.GetCodesOfType(Sax.CodeType.UserRole); + if (codes.userRoles == null) + codes.userRoles = SaxSystem.GetCodesOfType(Sax.CodeType.UserRole); // ToDo User Role localisation. - return userRoles.GetDescForType(userRole); + return codes.userRoles.GetDescForType(userRole); + } + + // Organisation type. + public String GetOrganisationTypeCaption(Sax.OrganisationType organisationType) + { + if ((int)organisationType < 1) return ""; + if (codes.organisationTypes == null) + codes.organisationTypes = SaxSystem.GetCodesOfType(Sax.CodeType.OrganisationType); + // ToDo Organisation Type localisation. + return codes.organisationTypes.GetDescForType(organisationType); + } + + // Organisation category. + public String GetOrganisationCategoryCaption(Sax.OrganisationCategory organisationCategory) + { + if ((int)organisationCategory < 1) return ""; + if (codes.organisationCategories == null) + codes.organisationCategories = SaxSystem.GetCodesOfType(Sax.CodeType.OrganisationCategory); + // ToDo Organisation Category localisation. + return codes.organisationCategories.GetDescForType(organisationCategory); } // Organisation role. - private List organisationRoles; public String GetOrganisationRoleCaption(Sax.OrganisationRole organisationRole) { if ((int)organisationRole < 1) return ""; - if (organisationRoles == null) - organisationRoles = SaxSystem.GetCodesOfType(Sax.CodeType.OrganisationRole); + if (codes.organisationRoles == null) + codes.organisationRoles = SaxSystem.GetCodesOfType(Sax.CodeType.OrganisationRole); // ToDo Organisation Role localisation. - return organisationRoles.GetDescForType(organisationRole); + return codes.organisationRoles.GetDescForType(organisationRole); + } + + // Opportunity type. + public String GetOpportunityTypeCaption(Sax.OpportunityType opportunityType) + { + if ((int)opportunityType < 1) return ""; + if (codes.opportunityTypes == null) + codes.opportunityTypes = SaxSystem.GetCodesOfType(Sax.CodeType.OpportunityType); + // ToDo Opportunity Type localisation. + return codes.opportunityTypes.GetDescForType(opportunityType); } //------------------------------------------------------------------- diff --git a/SaxoniteCoreWeb/Base/Controllers/SaxController_Base.cs b/SaxoniteCoreWeb/Base/Controllers/SaxController_Base.cs index 3ad2d06..b3f6e07 100644 --- a/SaxoniteCoreWeb/Base/Controllers/SaxController_Base.cs +++ b/SaxoniteCoreWeb/Base/Controllers/SaxController_Base.cs @@ -94,6 +94,7 @@ namespace Saxonite.Net.Core.Web.Base.Controllers public List OrganisationTypes { get { return Internals.OrganisationTypes; } } public List OrganisationCategories { get { return Internals.OrganisationCategories; } } public List OrganisationRoles { get { return Internals.OrganisationRoles; } } + public List OpportunityTypes { get { return Internals.OpportunityTypes; } } // Email. public SaEmailConfig EmailConfig { get { return App.EmailConfig; } } public SaxEmailConsole EmailConsole { get { return Internals.EmailConsole; } } diff --git a/SaxoniteCoreWeb/Base/Models/SaxModel_Base.cs b/SaxoniteCoreWeb/Base/Models/SaxModel_Base.cs index 5284291..d3546c7 100644 --- a/SaxoniteCoreWeb/Base/Models/SaxModel_Base.cs +++ b/SaxoniteCoreWeb/Base/Models/SaxModel_Base.cs @@ -59,6 +59,7 @@ namespace Saxonite.Net.Core.Web.Base.Models public List OrganisationTypes { get { return Internals.OrganisationTypes; } } public List OrganisationCategories { get { return Internals.OrganisationCategories; } } public List OrganisationRoles { get { return Internals.OrganisationRoles; } } + public List OpportunityTypes { get { return Internals.OpportunityTypes; } } //------------------------------------------------------------------- // Page configuration. diff --git a/SaxoniteCoreWebAdmin/Admin/Controllers/SystemController-Ajax-Database.cs b/SaxoniteCoreWebAdmin/Admin/Controllers/SystemController-Ajax-Database.cs new file mode 100644 index 0000000..ddfbe10 --- /dev/null +++ b/SaxoniteCoreWebAdmin/Admin/Controllers/SystemController-Ajax-Database.cs @@ -0,0 +1,57 @@ +using Microsoft.AspNetCore.Mvc; +using Sarand.Net.Standard.Base.App; +using Sarand.Net.Standard.Base.Bus; +using Sarand.Net.Standard.Base.Core; +using Sarand.Net.Standard.Base.Dbas; +using Saxonite.Net.Core.Web.Admin.Models; +using Saxonite.Net.Standard.Base.App; +using Saxonite.Net.Standard.Base.Bus; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; + +namespace Saxonite.Net.Core.Web.Admin.Controllers +{ + //======================================================================= + // System - Ajax - Database controller + //======================================================================= + partial class SystemController + { + //------------------------------------------------------------------- + // Database data. + public class DatabaseTableData + { + public String Name { get; set; } + } + + //------------------------------------------------------------------- + // Get Database Table List ajax request. + //------------------------------------------------------------------- + public class AjaxResponse_DatabaseTableList : AjaxResponse_Data + { + public List Tables { get; } = new List(); + } + //------------------------------------------------------------------- + [HttpPost] + [Route("System/Ajax/GetDatabaseTables")] + public IActionResult Ajax_GetDatabaseTables(Model_Sport model) + { + String fn = GetType().Name + ".Ajax_GetDatabaseTables"; + String messageTitle = Localiser["system.caption.database"]; + AjaxResponse_DatabaseTableList responseData = new AjaxResponse_DatabaseTableList(); + + // Validate session. + if (!ValidUserSession) + return GetAjaxResult_InvalidSession(responseData); + + // Complete response. + responseData.Success = true; + + return Json(responseData); + } + + //------------------------------------------------------------------- + } + //======================================================================= +} diff --git a/SaxoniteCoreWebAdmin/Admin/Controllers/SystemController-Ajax-Logs.cs b/SaxoniteCoreWebAdmin/Admin/Controllers/SystemController-Ajax-Logs.cs new file mode 100644 index 0000000..714cd83 --- /dev/null +++ b/SaxoniteCoreWebAdmin/Admin/Controllers/SystemController-Ajax-Logs.cs @@ -0,0 +1,57 @@ +using Microsoft.AspNetCore.Mvc; +using Sarand.Net.Standard.Base.App; +using Sarand.Net.Standard.Base.Bus; +using Sarand.Net.Standard.Base.Core; +using Sarand.Net.Standard.Base.Dbas; +using Saxonite.Net.Core.Web.Admin.Models; +using Saxonite.Net.Standard.Base.App; +using Saxonite.Net.Standard.Base.Bus; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; + +namespace Saxonite.Net.Core.Web.Admin.Controllers +{ + //======================================================================= + // System - Ajax - Database controller + //======================================================================= + partial class SystemController + { + //------------------------------------------------------------------- + // Database data. + public class LogFileData + { + public String Name { get; set; } + } + + //------------------------------------------------------------------- + // Get Database Table List ajax request. + //------------------------------------------------------------------- + public class AjaxResponse_LogFileList : AjaxResponse_Data + { + public List Tables { get; } = new List(); + } + //------------------------------------------------------------------- + [HttpPost] + [Route("System/Ajax/GetLogFileList")] + public IActionResult Ajax_GetLogFileList(Model_Sport model) + { + String fn = GetType().Name + ".Ajax_GetLogFileList"; + String messageTitle = Localiser["system.caption.logs"]; + AjaxResponse_LogFileList responseData = new AjaxResponse_LogFileList(); + + // Validate session. + if (!ValidUserSession) + return GetAjaxResult_InvalidSession(responseData); + + // Complete response. + responseData.Success = true; + + return Json(responseData); + } + + //------------------------------------------------------------------- + } + //======================================================================= +} diff --git a/SaxoniteCoreWebAdmin/Admin/Controllers/SystemController.cs b/SaxoniteCoreWebAdmin/Admin/Controllers/SystemController.cs new file mode 100644 index 0000000..280837a --- /dev/null +++ b/SaxoniteCoreWebAdmin/Admin/Controllers/SystemController.cs @@ -0,0 +1,78 @@ +using Microsoft.AspNetCore.Mvc; +using Microsoft.Extensions.Logging; +using Sarand.Net.Standard.Base.App; +using Sarand.Net.Standard.Base.Bus; +using Sarand.Net.Standard.Base.Core; +using Sarand.Net.Standard.Base.Utils; +using Saxonite.Net.Core.Web.Admin.Models; +using Saxonite.Net.Core.Web.Base.App; +using Saxonite.Net.Core.Web.Base.Controllers; +using Saxonite.Net.Standard.Base.Bus; +using System; +using System.Collections.Generic; +using System.Diagnostics; +using System.Linq; +using System.Threading.Tasks; + +namespace Saxonite.Net.Core.Web.Admin.Controllers +{ + //======================================================================= + public partial class SystemController : SaxController_Admin + { + //------------------------------------------------------------------- + // Construction. + public SystemController(SaxLocaliser localiser, ILogger logger) : + base(localiser, logger) + { + } + + //------------------------------------------------------------------- + /// + /// System - Home. + /// - No 'System' home page for now, redirect to home page. + /// + [HttpGet] + public IActionResult Index() + { + return RedirectToAction("", ""); + } + + //------------------------------------------------------------------- + /// + /// System - Database page. + /// + [HttpGet] + public IActionResult Database(Model_System model) + { + // Validate session. + if (!ValidUserSession) + return RedirectToAction("", ""); + + return View(model); + } + + //------------------------------------------------------------------- + /// + /// System - Logs page. + /// + [HttpGet] + public IActionResult Logs(Model_System model) + { + // Validate session. + if (!ValidUserSession) + return RedirectToAction("", ""); + + return View(model); + } + + //------------------------------------------------------------------- + [ResponseCache(Duration = 0, Location = ResponseCacheLocation.None, NoStore = true)] + public IActionResult Error() + { + return View(new ErrorViewModel { RequestId = Activity.Current?.Id ?? HttpContext.TraceIdentifier }); + } + + //------------------------------------------------------------------- + } + //======================================================================= +} diff --git a/SaxoniteCoreWebAdmin/Admin/Models/Model_Sport.cs b/SaxoniteCoreWebAdmin/Admin/Models/Model_Sport.cs index 7772eea..be980e6 100644 --- a/SaxoniteCoreWebAdmin/Admin/Models/Model_Sport.cs +++ b/SaxoniteCoreWebAdmin/Admin/Models/Model_Sport.cs @@ -65,7 +65,7 @@ namespace Saxonite.Net.Core.Web.Admin.Models // Check for duplicate name. SaxSport.Params prmSport = new SaxSport.Params(); if (SysId.IsValid(SportId)) - prmSport.ExcludedIds.Add(SportId); + prmSport.IdsExcluded.Add(SportId); prmSport.NamePartial = SportName; prmSport.StatusCat = SaxSport.StatusCat.Any; if (ReferenceMgr.GetSportCount(prmSport) > 0) diff --git a/SaxoniteCoreWebAdmin/Admin/Models/Model_System.cs b/SaxoniteCoreWebAdmin/Admin/Models/Model_System.cs new file mode 100644 index 0000000..87c77d1 --- /dev/null +++ b/SaxoniteCoreWebAdmin/Admin/Models/Model_System.cs @@ -0,0 +1,42 @@ +using Saxonite.Net.Core.Web.Base.App; +using Saxonite.Net.Core.Web.Base.Models; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; + +namespace Saxonite.Net.Core.Web.Admin.Models +{ + //======================================================================= + public class Model_System : SaxModel_Admin + { + //------------------------------------------------------------------- + // Construction. + public Model_System(SaxLocaliser localiser) : + base(localiser) + { + } + + //------------------------------------------------------------------- + // Properties. + + //------------------------------------------------------------------- + // Database page properties. + public class DatabaseFilterData + { + public String Table { get; set; } + } + public DatabaseFilterData DatabaseFilter { get; } = new DatabaseFilterData(); + + //------------------------------------------------------------------- + // Logs page properties. + public class LogsFilterData + { + public String Filename { get; set; } + } + public LogsFilterData LogsFilter { get; } = new LogsFilterData(); + + //------------------------------------------------------------------- + } + //======================================================================= +} diff --git a/SaxoniteCoreWebAdmin/Localisation/SaxAdminProperties.resx b/SaxoniteCoreWebAdmin/Localisation/SaxAdminProperties.resx index e29de10..64298ac 100644 --- a/SaxoniteCoreWebAdmin/Localisation/SaxAdminProperties.resx +++ b/SaxoniteCoreWebAdmin/Localisation/SaxAdminProperties.resx @@ -162,12 +162,21 @@ Create + + Database + + + Database table + Delete Email address + + Filename + First name @@ -189,6 +198,9 @@ Last name + + Logs + Members @@ -249,6 +261,9 @@ Strength + + System + Title @@ -414,6 +429,12 @@ Sports + + System - Database + + + System - Logs + Select User Roles diff --git a/SaxoniteCoreWebAdmin/Views/Common/OrganisationSelection.cshtml b/SaxoniteCoreWebAdmin/Views/Common/OrganisationSelection.cshtml deleted file mode 100644 index 1233f12..0000000 --- a/SaxoniteCoreWebAdmin/Views/Common/OrganisationSelection.cshtml +++ /dev/null @@ -1,42 +0,0 @@ -@model SaxModel_Admin -@inject SaxLocaliser Localiser - - - - - -
- - @* Filter *@ -
- -
- - @using (@Html.BeginForm(FormMethod.Post, new { @id = "frmOrganisationSelectionFilter", @class = "sax-form", @onSubmit = "return false;" })) - { -
-
@Localiser["organisation.caption.organisation"]
-
-
- } - -
- -
- -
- - @* Organisations *@ -
- -
- -
-
-
-
-
- -
diff --git a/SaxoniteCoreWebAdmin/Views/Common/SelectOrganisation.cshtml b/SaxoniteCoreWebAdmin/Views/Common/SelectOrganisation.cshtml new file mode 100644 index 0000000..0ac01c9 --- /dev/null +++ b/SaxoniteCoreWebAdmin/Views/Common/SelectOrganisation.cshtml @@ -0,0 +1,42 @@ +@model SaxModel_Admin +@inject SaxLocaliser Localiser + + + + + +
+ + @* Filter *@ +
+ +
+ + @using (@Html.BeginForm(FormMethod.Post, new { @id = "frmSelectOrganisationFilter", @class = "sax-form", @onSubmit = "return false;" })) + { +
+
@Localiser["organisation.caption.organisation"]
+
+
+ } + +
+ +
+ +
+ + @* Organisations *@ +
+ +
+ +
+
+
+
+
+ +
diff --git a/SaxoniteCoreWebAdmin/Views/Organisation/Members.cshtml b/SaxoniteCoreWebAdmin/Views/Organisation/Members.cshtml index 1aa4834..53e5c37 100644 --- a/SaxoniteCoreWebAdmin/Views/Organisation/Members.cshtml +++ b/SaxoniteCoreWebAdmin/Views/Organisation/Members.cshtml @@ -25,7 +25,7 @@ @Html.HiddenFor(model => model.Filter.OrganisationId, new { @id = "ifFilterOrganisationId" }) -
+
@@ -62,4 +62,4 @@ - + diff --git a/SaxoniteCoreWebAdmin/Views/Shared/_Layout.cshtml b/SaxoniteCoreWebAdmin/Views/Shared/_Layout.cshtml index 35c3a82..ee63f14 100644 --- a/SaxoniteCoreWebAdmin/Views/Shared/_Layout.cshtml +++ b/SaxoniteCoreWebAdmin/Views/Shared/_Layout.cshtml @@ -134,6 +134,15 @@ +