The new UI-project is developing startpage has got right texts and list of Tournaments is showing up
This commit is contained in:
@ -22,3 +22,15 @@ select,
|
||||
textarea {
|
||||
max-width: 280px;
|
||||
}
|
||||
|
||||
.tourney-display {
|
||||
margin-left: 20px;
|
||||
}
|
||||
|
||||
.tourney-display > li {
|
||||
margin-bottom:10px;
|
||||
}
|
||||
|
||||
.tourney-display > li > a {
|
||||
font-size: 20px;
|
||||
}
|
||||
@ -3,6 +3,8 @@ using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.Mvc;
|
||||
using TrackerLibrary;
|
||||
using TrackerLibrary.Models;
|
||||
|
||||
namespace MVCUI.Controllers
|
||||
{
|
||||
@ -10,21 +12,11 @@ namespace MVCUI.Controllers
|
||||
{
|
||||
public ActionResult Index()
|
||||
{
|
||||
return View();
|
||||
List<TournamentModel> tournaments = GlobalConfig.Connection.GetTournament_All();
|
||||
|
||||
return View(tournaments);
|
||||
}
|
||||
|
||||
public ActionResult About()
|
||||
{
|
||||
ViewBag.Message = "Your application description page.";
|
||||
|
||||
return View();
|
||||
}
|
||||
|
||||
public ActionResult Contact()
|
||||
{
|
||||
ViewBag.Message = "Your contact page.";
|
||||
|
||||
return View();
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -5,6 +5,7 @@ using System.Web;
|
||||
using System.Web.Mvc;
|
||||
using System.Web.Optimization;
|
||||
using System.Web.Routing;
|
||||
using TrackerLibrary;
|
||||
|
||||
namespace MVCUI
|
||||
{
|
||||
@ -16,6 +17,9 @@ namespace MVCUI
|
||||
FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
|
||||
RouteConfig.RegisterRoutes(RouteTable.Routes);
|
||||
BundleConfig.RegisterBundles(BundleTable.Bundles);
|
||||
|
||||
// Initialize the database connections
|
||||
GlobalConfig.InitializeConnections(DatabaseType.Sql);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -252,8 +252,6 @@
|
||||
<Content Include="Views\_ViewStart.cshtml" />
|
||||
<Content Include="Views\Shared\Error.cshtml" />
|
||||
<Content Include="Views\Shared\_Layout.cshtml" />
|
||||
<Content Include="Views\Home\About.cshtml" />
|
||||
<Content Include="Views\Home\Contact.cshtml" />
|
||||
<Content Include="Views\Home\Index.cshtml" />
|
||||
<Content Include="Scripts\umd\popper.min.js.map" />
|
||||
<Content Include="Scripts\umd\popper.js.map" />
|
||||
@ -281,6 +279,12 @@
|
||||
<ItemGroup>
|
||||
<Service Include="{4A0DDDB5-7A95-4FBF-97CC-616D07737A77}" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\TrackerLibrary\TrackerLibrary.csproj">
|
||||
<Project>{27ba8b4b-4ef6-4ca2-8e43-7c930552ecd9}</Project>
|
||||
<Name>TrackerLibrary</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<PropertyGroup>
|
||||
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>
|
||||
<VSToolsPath Condition="'$(VSToolsPath)' == ''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)</VSToolsPath>
|
||||
|
||||
@ -1,7 +0,0 @@
|
||||
@{
|
||||
ViewBag.Title = "About";
|
||||
}
|
||||
<h2>@ViewBag.Title.</h2>
|
||||
<h3>@ViewBag.Message</h3>
|
||||
|
||||
<p>Use this area to provide additional information.</p>
|
||||
@ -1,17 +0,0 @@
|
||||
@{
|
||||
ViewBag.Title = "Contact";
|
||||
}
|
||||
<h2>@ViewBag.Title.</h2>
|
||||
<h3>@ViewBag.Message</h3>
|
||||
|
||||
<address>
|
||||
One Microsoft Way<br />
|
||||
Redmond, WA 98052-6399<br />
|
||||
<abbr title="Phone">P:</abbr>
|
||||
425.555.0100
|
||||
</address>
|
||||
|
||||
<address>
|
||||
<strong>Support:</strong> <a href="mailto:Support@example.com">Support@example.com</a><br />
|
||||
<strong>Marketing:</strong> <a href="mailto:Marketing@example.com">Marketing@example.com</a>
|
||||
</address>
|
||||
@ -1,31 +1,40 @@
|
||||
@{
|
||||
@model IEnumerable<TrackerLibrary.Models.TournamentModel>
|
||||
|
||||
@{
|
||||
ViewBag.Title = "Home Page";
|
||||
}
|
||||
|
||||
<div class="jumbotron">
|
||||
<h1>ASP.NET</h1>
|
||||
<p class="lead">ASP.NET is a free web framework for building great Web sites and Web applications using HTML, CSS and JavaScript.</p>
|
||||
<p><a href="https://asp.net" class="btn btn-primary btn-lg">Learn more »</a></p>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<h2>Getting started</h2>
|
||||
<p>
|
||||
ASP.NET MVC gives you a powerful, patterns-based way to build dynamic websites that
|
||||
enables a clean separation of concerns and gives you full control over markup
|
||||
for enjoyable, agile development.
|
||||
</p>
|
||||
<p><a class="btn btn-default" href="https://go.microsoft.com/fwlink/?LinkId=301865">Learn more »</a></p>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-8">
|
||||
<div class="jumbotron">
|
||||
<h1>Office Fun!</h1>
|
||||
<p class="lead">Track your in office tournament easily and have a great time doing it.</p>
|
||||
<p><a href="https://asp.net" class="btn btn-primary btn-lg">Create a tournament</a></p>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<h2>Play with friends</h2>
|
||||
<p>
|
||||
Get a team and get started today on a new tournament.
|
||||
</p>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<h2>Win prizes</h2>
|
||||
<p>Set up a tournament with prizes for first and second place and compete to win.</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<h2>Current Tournament</h2>
|
||||
<ul class="list-unstyled tourney-display">
|
||||
@foreach (var item in Model)
|
||||
{
|
||||
<li><a href="/">@item.TournamentName</a></li>
|
||||
}
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<h2>Get more libraries</h2>
|
||||
<p>NuGet is a free Visual Studio extension that makes it easy to add, remove, and update libraries and tools in Visual Studio projects.</p>
|
||||
<p><a class="btn btn-default" href="https://go.microsoft.com/fwlink/?LinkId=301866">Learn more »</a></p>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<h2>Web Hosting</h2>
|
||||
<p>You can easily find a web hosting company that offers the right mix of features and price for your applications.</p>
|
||||
<p><a class="btn btn-default" href="https://go.microsoft.com/fwlink/?LinkId=301867">Learn more »</a></p>
|
||||
</div>
|
||||
</div>
|
||||
@ -24,12 +24,12 @@
|
||||
<li class="nav-item">
|
||||
@Html.ActionLink("Home", "Index", "Home", new { area = "" }, new { @class = "nav-link text-light" })
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
@*<li class="nav-item">
|
||||
@Html.ActionLink("About", "About", "Home", new { area = "" }, new { @class = "nav-link text-light" })
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
@Html.ActionLink("Contact", "Contact", "Home", new { area = "" }, new { @class = "nav-link text-light" })
|
||||
</li>
|
||||
</li>*@
|
||||
</ul>
|
||||
</div>
|
||||
</nav>
|
||||
@ -42,7 +42,7 @@
|
||||
|
||||
<footer class="border-top footer text-muted">
|
||||
<div class="container">
|
||||
© @DateTime.Now.Year - My ASP.NET Application
|
||||
© @DateTime.Now.Year - Tournament Tracker Application by Tim Corey
|
||||
</div>
|
||||
</footer>
|
||||
@Scripts.Render("~/bundles/jquery")
|
||||
|
||||
@ -10,6 +10,11 @@
|
||||
<add key="ClientValidationEnabled" value="true" />
|
||||
<add key="UnobtrusiveJavaScriptEnabled" value="true" />
|
||||
</appSettings>
|
||||
<connectionStrings>
|
||||
<!--<add name="Tournaments" connectionString="Server=TOMMYASUS\SQLEXPR2017;Database=Tournaments;Trusted_Connection=True;" providerName="System.Data.SqlClient"/>-->
|
||||
<add name="Tournaments" connectionString="Server=.\SQLEXPR2017;Database=Tournaments;Trusted_Connection=True;" providerName="System.Data.SqlClient" />
|
||||
<!--Data Source=TOMMYASUS\SQLEXPR2017;Initial Catalog=Tournaments;Integrated Security=True-->
|
||||
</connectionStrings>
|
||||
<system.web>
|
||||
<compilation debug="true" targetFramework="4.7.2" />
|
||||
<httpRuntime targetFramework="4.7.2" />
|
||||
|
||||
Reference in New Issue
Block a user