mirror of
https://gitlab.com/buildfeed/BuildFeed.git
synced 2024-03-22 21:10:34 +08:00
jQuery Update, more meta basework, Ask a Q
This commit is contained in:
parent
6b71adab4d
commit
58e27d2924
25
Areas/admin/Controllers/metaController.cs
Normal file
25
Areas/admin/Controllers/metaController.cs
Normal file
|
@ -0,0 +1,25 @@
|
|||
using BuildFeed.Models;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.Mvc;
|
||||
|
||||
namespace BuildFeed.Areas.admin.Controllers
|
||||
{
|
||||
[Authorize(Roles = "Administrators")]
|
||||
public class metaController : Controller
|
||||
{
|
||||
// GET: admin/meta
|
||||
public ActionResult index()
|
||||
{
|
||||
var currentItems = from i in MetaItem.Select()
|
||||
group i by i.Id.Type into b
|
||||
select b;
|
||||
|
||||
var pendingLabs = MetaItem.SelectUnusedLabs();
|
||||
|
||||
return View();
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,15 +1,18 @@
|
|||
|
||||
@{
|
||||
@{
|
||||
ViewBag.Title = "Administration | BuildFeed";
|
||||
}
|
||||
|
||||
<h2>Administration</h2>
|
||||
|
||||
<ul>
|
||||
<li>@Html.ActionLink("Manage users", "index", "users")</li>
|
||||
<li>
|
||||
@Html.ActionLink("Manage users", "index", "users")
|
||||
<ul>
|
||||
<li>@Html.ActionLink("View administrators", "admins")</li>
|
||||
</ul>
|
||||
</li>
|
||||
@if (User.Identity.Name == "hounsell")
|
||||
{
|
||||
<li>@Html.ActionLink("Initial setup", "setup")</li>
|
||||
}
|
||||
</ul>
|
||||
|
||||
|
|
|
@ -1,42 +1,44 @@
|
|||
@model IEnumerable<System.Web.Security.MembershipUser>
|
||||
|
||||
@{
|
||||
ViewBag.Title = "Administrators | BuildFeed";
|
||||
ViewBag.Title = "View administrators | BuildFeed";
|
||||
}
|
||||
|
||||
<h2>Administrators</h2>
|
||||
<h2>View administrators</h2>
|
||||
|
||||
<ul>
|
||||
<li>@Html.ActionLink("User Administration", "index")</li>
|
||||
<li>@Html.ActionLink("Return to Admin Panel", "index", "base")</li>
|
||||
<li>@Html.ActionLink("Manage users", "index")</li>
|
||||
<li>@Html.ActionLink("Return to admin panel", "index", "base")</li>
|
||||
</ul>
|
||||
|
||||
<table class="table table-striped table-bordered table-admin">
|
||||
<tr>
|
||||
<th>
|
||||
Username
|
||||
</th>
|
||||
<th>
|
||||
Email Address
|
||||
</th>
|
||||
<td>
|
||||
Last Login Time
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
@foreach (MembershipUser mu in Model)
|
||||
{
|
||||
<thead>
|
||||
<tr>
|
||||
<th>
|
||||
Username
|
||||
</th>
|
||||
<th>
|
||||
Email Address
|
||||
</th>
|
||||
<td>
|
||||
@Html.DisplayFor(modelItem => mu.UserName)
|
||||
</td>
|
||||
<td>
|
||||
@Html.DisplayFor(modelItem => mu.Email)
|
||||
</td>
|
||||
<td>
|
||||
@Html.DisplayFor(modelItem => mu.LastLoginDate)
|
||||
Last Login Time
|
||||
</td>
|
||||
</tr>
|
||||
}
|
||||
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach (MembershipUser mu in Model)
|
||||
{
|
||||
<tr>
|
||||
<td>
|
||||
@Html.DisplayFor(modelItem => mu.UserName)
|
||||
</td>
|
||||
<td>
|
||||
@Html.DisplayFor(modelItem => mu.Email)
|
||||
</td>
|
||||
<td>
|
||||
@Html.DisplayFor(modelItem => mu.LastLoginDate)
|
||||
</td>
|
||||
</tr>
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
|
|
|
@ -1,70 +1,72 @@
|
|||
@model IEnumerable<System.Web.Security.MembershipUser>
|
||||
|
||||
@{
|
||||
ViewBag.Title = "User Administration | BuildFeed";
|
||||
ViewBag.Title = "Manage users | BuildFeed";
|
||||
}
|
||||
|
||||
<h2>User Administration</h2>
|
||||
<h2>Manage users</h2>
|
||||
|
||||
<ul>
|
||||
<li>@Html.ActionLink("View Administrators", "admins")</li>
|
||||
<li>@Html.ActionLink("Return to Admin Panel", "index", "base")</li>
|
||||
<li>@Html.ActionLink("View administrators", "admins")</li>
|
||||
<li>@Html.ActionLink("Return to admin panel", "index", "base")</li>
|
||||
</ul>
|
||||
|
||||
<table class="table table-striped table-bordered table-admin">
|
||||
<tr>
|
||||
<th>
|
||||
Username
|
||||
</th>
|
||||
<th>
|
||||
Email Address
|
||||
</th>
|
||||
<td>
|
||||
Last Login Time
|
||||
</td>
|
||||
<td>
|
||||
Last Lockout Time
|
||||
</td>
|
||||
<th style="width:108px;"></th>
|
||||
<th style="width:108px;"></th>
|
||||
</tr>
|
||||
|
||||
@foreach (MembershipUser mu in Model)
|
||||
{
|
||||
<thead>
|
||||
<tr>
|
||||
<th>
|
||||
Username
|
||||
</th>
|
||||
<th>
|
||||
Email Address
|
||||
</th>
|
||||
<td>
|
||||
@Html.DisplayFor(modelItem => mu.UserName)
|
||||
Last Login Time
|
||||
</td>
|
||||
<td>
|
||||
@Html.DisplayFor(modelItem => mu.Email)
|
||||
</td>
|
||||
<td>
|
||||
@Html.DisplayFor(modelItem => mu.LastLoginDate)
|
||||
</td>
|
||||
<td>
|
||||
@Html.DisplayFor(modelItem => mu.LastLockoutDate)
|
||||
</td>
|
||||
<td class="text-right">
|
||||
@if (mu.IsApproved)
|
||||
{
|
||||
@Html.ActionLink("Unapprove", "unapprove", new { id = mu.ProviderUserKey }, new { @class = "btn btn-danger", style = "width:90px;" })
|
||||
}
|
||||
else
|
||||
{
|
||||
@Html.ActionLink("Approve", "approve", new { id = mu.ProviderUserKey }, new { @class = "btn btn-success", style = "width:90px;" })
|
||||
}
|
||||
</td>
|
||||
<td class="text-right">
|
||||
@if (!mu.IsLockedOut)
|
||||
{
|
||||
@Html.ActionLink("Lock", "lock", new { id = mu.ProviderUserKey }, new { @class = "btn btn-danger", style = "width:90px;" })
|
||||
}
|
||||
else
|
||||
{
|
||||
@Html.ActionLink("Unlock", "unlock", new { id = mu.ProviderUserKey }, new { @class = "btn btn-success", style = "width:90px;" })
|
||||
}
|
||||
Last Lockout Time
|
||||
</td>
|
||||
<th style="width:108px;"></th>
|
||||
<th style="width:108px;"></th>
|
||||
</tr>
|
||||
}
|
||||
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach (MembershipUser mu in Model)
|
||||
{
|
||||
<tr>
|
||||
<td>
|
||||
@Html.DisplayFor(modelItem => mu.UserName)
|
||||
</td>
|
||||
<td>
|
||||
@Html.DisplayFor(modelItem => mu.Email)
|
||||
</td>
|
||||
<td>
|
||||
@Html.DisplayFor(modelItem => mu.LastLoginDate)
|
||||
</td>
|
||||
<td>
|
||||
@Html.DisplayFor(modelItem => mu.LastLockoutDate)
|
||||
</td>
|
||||
<td class="text-right">
|
||||
@if (mu.IsApproved)
|
||||
{
|
||||
@Html.ActionLink("Unapprove", "unapprove", new { id = mu.ProviderUserKey }, new { @class = "btn btn-danger", style = "width:90px;" })
|
||||
}
|
||||
else
|
||||
{
|
||||
@Html.ActionLink("Approve", "approve", new { id = mu.ProviderUserKey }, new { @class = "btn btn-success", style = "width:90px;" })
|
||||
}
|
||||
</td>
|
||||
<td class="text-right">
|
||||
@if (!mu.IsLockedOut)
|
||||
{
|
||||
@Html.ActionLink("Lock", "lock", new { id = mu.ProviderUserKey }, new { @class = "btn btn-danger", style = "width:90px;" })
|
||||
}
|
||||
else
|
||||
{
|
||||
@Html.ActionLink("Unlock", "unlock", new { id = mu.ProviderUserKey }, new { @class = "btn btn-success", style = "width:90px;" })
|
||||
}
|
||||
</td>
|
||||
</tr>
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
|
|
|
@ -177,6 +177,7 @@
|
|||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Areas\admin\Controllers\baseController.cs" />
|
||||
<Compile Include="Areas\admin\Controllers\metaController.cs" />
|
||||
<Compile Include="Auth\RedisRoleProvider.cs" />
|
||||
<Compile Include="Code\BuildDateTimeModelBinder.cs" />
|
||||
<Compile Include="Code\DisplayHelpers.cs" />
|
||||
|
@ -199,6 +200,7 @@
|
|||
<Compile Include="Models\MetaItem.cs" />
|
||||
<Compile Include="Models\ViewModel\LoginUser.cs" />
|
||||
<Compile Include="Models\ViewModel\ChangePassword.cs" />
|
||||
<Compile Include="Models\ViewModel\QuestionForm.cs" />
|
||||
<Compile Include="Models\ViewModel\RegistrationUser.cs" />
|
||||
<Compile Include="Models\ViewModel\SitemapData.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
|
@ -217,13 +219,13 @@
|
|||
<Content Include="ApplicationInsights.config" />
|
||||
<Content Include="Areas\admin\Views\users\admins.cshtml" />
|
||||
<None Include="Properties\PublishProfiles\Milestone 1 FTP.pubxml" />
|
||||
<None Include="Scripts\jquery-2.1.1.intellisense.js" />
|
||||
<Content Include="googleacffc6da14c53e15.html" />
|
||||
<Content Include="content\tile\large.png" />
|
||||
<Content Include="Scripts\bfs.js" />
|
||||
<Content Include="Scripts\jquery-2.1.1.js" />
|
||||
<Content Include="Scripts\jquery-2.1.1.min.js" />
|
||||
<Content Include="Scripts\jquery-2.1.1.min.map" />
|
||||
<None Include="Scripts\jquery-2.1.3.intellisense.js" />
|
||||
<Content Include="Scripts\jquery-2.1.3.js" />
|
||||
<Content Include="Scripts\jquery-2.1.3.min.js" />
|
||||
<Content Include="Scripts\jquery-2.1.3.min.map" />
|
||||
<None Include="Scripts\jquery.validate-vsdoc.js" />
|
||||
<Content Include="Scripts\jquery.validate.js" />
|
||||
<Content Include="Scripts\jquery.validate.min.js" />
|
||||
|
@ -276,6 +278,7 @@
|
|||
</Content>
|
||||
<Content Include="Web.Release.config">
|
||||
<DependentUpon>Web.config</DependentUpon>
|
||||
<SubType>Designer</SubType>
|
||||
</Content>
|
||||
<Content Include="Views\Web.config" />
|
||||
<Content Include="Views\_ViewStart.cshtml" />
|
||||
|
@ -293,10 +296,13 @@
|
|||
<Content Include="Views\support\rss.cshtml" />
|
||||
<Content Include="Views\support\sitemap.cshtml" />
|
||||
<Content Include="Scripts\jsrender.min.js.map" />
|
||||
<Content Include="Views\support\question.cshtml" />
|
||||
<Content Include="Views\support\thanks_question.cshtml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Folder Include="App_Data\" />
|
||||
<Folder Include="Areas\admin\Models\" />
|
||||
<Folder Include="Areas\admin\Views\meta\" />
|
||||
<Folder Include="Areas\admin\Views\Shared\" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
|
|
|
@ -8,6 +8,10 @@
|
|||
using BuildFeed.Models;
|
||||
using BuildFeed.Models.ViewModel;
|
||||
using System.Xml.Linq;
|
||||
using System.Net.Mail;
|
||||
using System.Configuration;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace BuildFeed.Controllers
|
||||
{
|
||||
|
@ -121,6 +125,43 @@ public ActionResult thanks_register()
|
|||
return View();
|
||||
}
|
||||
|
||||
public ActionResult question()
|
||||
{
|
||||
return View();
|
||||
}
|
||||
|
||||
[HttpPost]
|
||||
public async Task<ActionResult> question(QuestionForm qf)
|
||||
{
|
||||
if(ModelState.IsValid)
|
||||
{
|
||||
SmtpClient sc = new SmtpClient();
|
||||
MailMessage mm = new MailMessage(ConfigurationManager.AppSettings["form:QuestionFromEmail"], ConfigurationManager.AppSettings["form:QuestionToEmail"]);
|
||||
mm.Subject = "BuildFeed Question from " + qf.Name;
|
||||
mm.ReplyToList.Add(qf.Email);
|
||||
|
||||
StringBuilder sb = new StringBuilder();
|
||||
sb.AppendLine("BuildFeed Question");
|
||||
sb.AppendLine("==================");
|
||||
sb.AppendLine();
|
||||
sb.AppendFormat("Name: {0}\r\n", qf.Name);
|
||||
sb.AppendFormat("Email: {0}\r\n", qf.Email);
|
||||
sb.AppendLine();
|
||||
sb.AppendLine("Question: ");
|
||||
sb.AppendLine(qf.Comment);
|
||||
|
||||
mm.Body = sb.ToString();
|
||||
|
||||
await sc.SendMailAsync(mm);
|
||||
|
||||
return View("thanks_question");
|
||||
}
|
||||
else
|
||||
{
|
||||
return View(qf);
|
||||
}
|
||||
}
|
||||
|
||||
public ActionResult rss()
|
||||
{
|
||||
return View();
|
||||
|
|
|
@ -27,7 +27,7 @@ public class MetaItem : IHasId<MetaItemKey>
|
|||
|
||||
|
||||
|
||||
[DataObjectMethod(DataObjectMethodType.Select, true)]
|
||||
[DataObjectMethod(DataObjectMethodType.Select, false)]
|
||||
public static IEnumerable<MetaItem> Select()
|
||||
{
|
||||
using (RedisClient rClient = new RedisClient(DatabaseConfig.Host, DatabaseConfig.Port, db: DatabaseConfig.Database))
|
||||
|
@ -37,6 +37,18 @@ public static IEnumerable<MetaItem> Select()
|
|||
}
|
||||
}
|
||||
|
||||
[DataObjectMethod(DataObjectMethodType.Select, true)]
|
||||
public static IEnumerable<MetaItem> SelectByType(MetaType type)
|
||||
{
|
||||
using (RedisClient rClient = new RedisClient(DatabaseConfig.Host, DatabaseConfig.Port, db: DatabaseConfig.Database))
|
||||
{
|
||||
var client = rClient.As<MetaItem>();
|
||||
return from t in client.GetAll()
|
||||
where t.Id.Type == type
|
||||
select t;
|
||||
}
|
||||
}
|
||||
|
||||
[DataObjectMethod(DataObjectMethodType.Select, false)]
|
||||
public static MetaItem SelectById(MetaItemKey id)
|
||||
{
|
||||
|
|
|
@ -11,17 +11,17 @@ public class ChangePassword
|
|||
{
|
||||
[Required]
|
||||
[MinLength(12)]
|
||||
[DisplayName("Enter Old Password")]
|
||||
[DisplayName("Enter current password")]
|
||||
public string OldPassword { get; set; }
|
||||
|
||||
[Required]
|
||||
[MinLength(12)]
|
||||
[DisplayName("Enter New Password")]
|
||||
[DisplayName("Enter new password")]
|
||||
public string NewPassword { get; set; }
|
||||
|
||||
[Required]
|
||||
[MinLength(12)]
|
||||
[DisplayName("Confirm New Password")]
|
||||
[DisplayName("Confirm new password")]
|
||||
[Compare("NewPassword")]
|
||||
public string ConfirmNewPassword { get; set; }
|
||||
}
|
||||
|
|
21
Models/ViewModel/QuestionForm.cs
Normal file
21
Models/ViewModel/QuestionForm.cs
Normal file
|
@ -0,0 +1,21 @@
|
|||
using System.ComponentModel;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace BuildFeed.Models.ViewModel
|
||||
{
|
||||
public class QuestionForm
|
||||
{
|
||||
[Required]
|
||||
[DisplayName("Your name")]
|
||||
public string Name { get; set; }
|
||||
|
||||
[Required]
|
||||
[DisplayName("Your email address")]
|
||||
[EmailAddress]
|
||||
public string Email { get; set; }
|
||||
|
||||
[Required]
|
||||
[DisplayName("Question")]
|
||||
public string Comment { get; set; }
|
||||
}
|
||||
}
|
|
@ -15,18 +15,18 @@ public class RegistrationUser
|
|||
|
||||
[Required]
|
||||
[MinLength(12)]
|
||||
[DisplayName("Enter Password")]
|
||||
[DisplayName("Enter password")]
|
||||
public string Password { get; set; }
|
||||
|
||||
[Required]
|
||||
[MinLength(12)]
|
||||
[DisplayName("Confirm Password")]
|
||||
[DisplayName("Confirm password")]
|
||||
[Compare("Password")]
|
||||
public string ConfirmPassword { get; set; }
|
||||
|
||||
[Required]
|
||||
[EmailAddress]
|
||||
[DisplayName("Email Address")]
|
||||
[DisplayName("Email address")]
|
||||
public string EmailAddress { get; set; }
|
||||
}
|
||||
}
|
Binary file not shown.
4
Scripts/jquery-2.1.1.min.js
vendored
4
Scripts/jquery-2.1.1.min.js
vendored
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
537
Scripts/jquery-2.1.1.js → Scripts/jquery-2.1.3.js
vendored
537
Scripts/jquery-2.1.1.js → Scripts/jquery-2.1.3.js
vendored
File diff suppressed because it is too large
Load Diff
4
Scripts/jquery-2.1.3.min.js
vendored
Normal file
4
Scripts/jquery-2.1.3.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
Scripts/jquery-2.1.3.min.map
Normal file
1
Scripts/jquery-2.1.3.min.map
Normal file
File diff suppressed because one or more lines are too long
|
@ -73,7 +73,7 @@
|
|||
</div>
|
||||
<div class="build-foot">
|
||||
<span class="badge">@Html.DisplayFor(TypeOfSource => item.SourceType, "Enumeration")</span>
|
||||
@if ( (item.MajorVersion == 6 && item.MinorVersion == 4) || (item.MajorVersion == 10 && item.MinorVersion == 0) && item.FlightLevel != BuildFeed.Models.LevelOfFlight.None)
|
||||
@if ((item.MajorVersion == 6 && item.MinorVersion == 4) || (item.MajorVersion == 10 && item.MinorVersion == 0) && item.FlightLevel != BuildFeed.Models.LevelOfFlight.None)
|
||||
{
|
||||
<span class="badge">Flight Level: @Html.DisplayFor(TypeOfSource => item.FlightLevel, "Enumeration")</span>
|
||||
}
|
||||
|
@ -130,6 +130,7 @@
|
|||
@Html.ActionLink("Log in", "login", new { controller = "support" }, new { @class = "list-group-item" })
|
||||
@Html.ActionLink("Register", "register", new { controller = "support" }, new { @class = "list-group-item" })
|
||||
}
|
||||
@Html.ActionLink("Ask a question", "question", new { controller = "support" }, new { @class = "list-group-item" })
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
<html>
|
||||
<head>
|
||||
<meta name="viewport" content="width=device-width" />
|
||||
<link href="//maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css" rel="stylesheet" />
|
||||
<link href="//maxcdn.bootstrapcdn.com/bootswatch/3.2.0/yeti/bootstrap.min.css" rel="stylesheet" />
|
||||
<link href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.1/css/bootstrap.min.css" rel="stylesheet" />
|
||||
<link href="//maxcdn.bootstrapcdn.com/bootswatch/3.3.0/yeti/bootstrap.min.css" rel="stylesheet" />
|
||||
<link href="//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet" />
|
||||
<link href="//fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,700,400italic" rel="stylesheet" type="text/css" />
|
||||
<link rel="shortcut icon" href="~/favicon.ico" />
|
||||
|
@ -60,7 +60,7 @@
|
|||
<div class="row">
|
||||
<div class="col-sm-4 col-sm-offset-8 text-right">
|
||||
<p>
|
||||
© 2013 - 2014, BuildFeed<br />
|
||||
© 2013 - @DateTime.Now.Year, BuildFeed<br />
|
||||
Developed by <a href="https://twitter.com/tomhounsell" target="_blank">Thomas Hounsell</a>
|
||||
</p>
|
||||
</div>
|
||||
|
|
61
Views/support/question.cshtml
Normal file
61
Views/support/question.cshtml
Normal file
|
@ -0,0 +1,61 @@
|
|||
@model BuildFeed.Models.ViewModel.QuestionForm
|
||||
|
||||
@{
|
||||
ViewBag.Title = "Ask a question | BuildFeed";
|
||||
}
|
||||
|
||||
<h2>Ask a question</h2>
|
||||
<p>Have a burning question you wish to ask the BuildFeed team? Drop us an email directly using this form. We'll respond to you using the email address you provide in the form below.</p>
|
||||
|
||||
@using (Html.BeginForm())
|
||||
{
|
||||
@Html.AntiForgeryToken()
|
||||
|
||||
<div class="form-horizontal">
|
||||
<div class="form-group">
|
||||
@Html.LabelFor(model => model.Name, htmlAttributes: new { @class = "control-label col-md-2" })
|
||||
<div class="col-md-10">
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
@Html.EditorFor(model => model.Name, new { htmlAttributes = new { @class = "form-control" } })
|
||||
</div>
|
||||
</div>
|
||||
@Html.ValidationMessageFor(model => model.Name, "", new { @class = "text-danger" })
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
@Html.LabelFor(model => model.Email, htmlAttributes: new { @class = "control-label col-md-2" })
|
||||
<div class="col-md-10">
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
@Html.EditorFor(model => model.Email, new { htmlAttributes = new { @class = "form-control" } })
|
||||
</div>
|
||||
</div>
|
||||
@Html.ValidationMessageFor(model => model.Email, "", new { @class = "text-danger" })
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
@Html.LabelFor(model => model.Comment, htmlAttributes: new { @class = "control-label col-md-2" })
|
||||
<div class="col-md-10">
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
@Html.TextAreaFor(model => model.Comment, new { @class = "form-control", rows = 5 })
|
||||
</div>
|
||||
</div>
|
||||
@Html.ValidationMessageFor(model => model.Comment, "", new { @class = "text-danger" })
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<div class="col-md-offset-2 col-md-10">
|
||||
<input type="submit" value="Submit my question" class="btn btn-primary" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
|
||||
@section Scripts {
|
||||
@Scripts.Render("~/bundles/jqueryval")
|
||||
}
|
7
Views/support/thanks_question.cshtml
Normal file
7
Views/support/thanks_question.cshtml
Normal file
|
@ -0,0 +1,7 @@
|
|||
|
||||
@{
|
||||
ViewBag.Title = "Thank you asking a question | BuildFeed";
|
||||
}
|
||||
|
||||
<h2>Thank you for asking a question.</h2>
|
||||
<p>A member of the BuildFeed administration team will get in touch with a response to your question.</p>
|
|
@ -28,6 +28,13 @@
|
|||
</customErrors>
|
||||
-->
|
||||
</system.web>
|
||||
<system.net xdt:Transform="Insert">
|
||||
<mailSettings>
|
||||
<smtp deliveryMethod="Network" from="smtp@betawiki.net">
|
||||
<network host="localhost" port="25" userName="smtp@betawiki.net" password="frEchEramejAQUVewrADE7uc" />
|
||||
</smtp>
|
||||
</mailSettings>
|
||||
</system.net>
|
||||
<system.webServer>
|
||||
<modules>
|
||||
<remove name="ApplicationInsightsWebTracking" xdt:Transform="Insert" />
|
||||
|
|
97
Web.config
97
Web.config
|
@ -5,87 +5,94 @@
|
|||
-->
|
||||
<configuration>
|
||||
<appSettings>
|
||||
<add key="webpages:Version" value="3.0.0.0" />
|
||||
<add key="webpages:Enabled" value="false" />
|
||||
<add key="PreserveLoginUrl" value="true" />
|
||||
<add key="ClientValidationEnabled" value="true" />
|
||||
<add key="UnobtrusiveJavaScriptEnabled" value="true" />
|
||||
<add key="data:ServerHost" value="localhost" />
|
||||
<add key="data:ServerPort" value="6379" />
|
||||
<add key="data:ServerDB" value="1" />
|
||||
<add key="RouteDebugger:Enabled" value="false" />
|
||||
<add key="webpages:Version" value="3.0.0.0"/>
|
||||
<add key="webpages:Enabled" value="false"/>
|
||||
<add key="PreserveLoginUrl" value="true"/>
|
||||
<add key="ClientValidationEnabled" value="true"/>
|
||||
<add key="UnobtrusiveJavaScriptEnabled" value="true"/>
|
||||
<add key="data:ServerHost" value="localhost"/>
|
||||
<add key="data:ServerPort" value="6379"/>
|
||||
<add key="data:ServerDB" value="1"/>
|
||||
<add key="form:QuestionFromEmail" value="smtp@betawiki.net"/>
|
||||
<add key="form:QuestionToEmail" value="thomas@buildfeed.net"/>
|
||||
<add key="RouteDebugger:Enabled" value="false"/>
|
||||
</appSettings>
|
||||
<system.web>
|
||||
<compilation debug="true" targetFramework="4.5" />
|
||||
<httpRuntime targetFramework="4.5" />
|
||||
<trace enabled="false" requestLimit="40" pageOutput="true" />
|
||||
<sessionState cookieless="UseCookies" />
|
||||
<anonymousIdentification cookieless="UseCookies" enabled="false" />
|
||||
<compilation debug="true" targetFramework="4.5"/>
|
||||
<httpRuntime targetFramework="4.5"/>
|
||||
<trace enabled="false" requestLimit="40" pageOutput="true"/>
|
||||
<sessionState cookieless="UseCookies"/>
|
||||
<anonymousIdentification cookieless="UseCookies" enabled="false"/>
|
||||
<authentication mode="Forms">
|
||||
<forms loginUrl="/support/login/" cookieless="UseCookies" name="BuildFeedAuth" />
|
||||
<forms loginUrl="/support/login/" cookieless="UseCookies" name="BuildFeedAuth"/>
|
||||
</authentication>
|
||||
<membership defaultProvider="BuildFeedMemberProvider">
|
||||
<providers>
|
||||
<clear />
|
||||
<add name="BuildFeedMemberProvider" type="BuildFeed.Auth.RedisMembershipProvider" />
|
||||
<clear/>
|
||||
<add name="BuildFeedMemberProvider" type="BuildFeed.Auth.RedisMembershipProvider"/>
|
||||
</providers>
|
||||
</membership>
|
||||
<roleManager defaultProvider="BuildFeedRoleProvider" enabled="true">
|
||||
<providers>
|
||||
<clear />
|
||||
<add name="BuildFeedRoleProvider" type="BuildFeed.Auth.RedisRoleProvider" />
|
||||
<clear/>
|
||||
<add name="BuildFeedRoleProvider" type="BuildFeed.Auth.RedisRoleProvider"/>
|
||||
</providers>
|
||||
</roleManager>
|
||||
<httpModules>
|
||||
<add name="ApplicationInsightsWebTracking" type="Microsoft.ApplicationInsights.Extensibility.Web.RequestTracking.WebRequestTrackingModule, Microsoft.ApplicationInsights.Extensibility.Web" />
|
||||
<add name="ApplicationInsightsWebTracking" type="Microsoft.ApplicationInsights.Extensibility.Web.RequestTracking.WebRequestTrackingModule, Microsoft.ApplicationInsights.Extensibility.Web"/>
|
||||
</httpModules>
|
||||
</system.web>
|
||||
<runtime>
|
||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="Microsoft.Diagnostics.Tracing.EventSource" publicKeyToken="B03F5F7F11D50A3A" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-1.1.14.0" newVersion="1.1.14.0" />
|
||||
<assemblyIdentity name="Microsoft.Diagnostics.Tracing.EventSource" publicKeyToken="B03F5F7F11D50A3A" culture="neutral"/>
|
||||
<bindingRedirect oldVersion="0.0.0.0-1.1.14.0" newVersion="1.1.14.0"/>
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="Newtonsoft.Json" culture="neutral" publicKeyToken="30ad4fe6b2a6aeed" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-6.0.0.0" newVersion="6.0.0.0" />
|
||||
<assemblyIdentity name="Newtonsoft.Json" culture="neutral" publicKeyToken="30ad4fe6b2a6aeed"/>
|
||||
<bindingRedirect oldVersion="0.0.0.0-6.0.0.0" newVersion="6.0.0.0"/>
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="System.Web.Optimization" publicKeyToken="31bf3856ad364e35" />
|
||||
<bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="1.1.0.0" />
|
||||
<assemblyIdentity name="System.Web.Optimization" publicKeyToken="31bf3856ad364e35"/>
|
||||
<bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="1.1.0.0"/>
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="WebGrease" publicKeyToken="31bf3856ad364e35" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-1.6.5135.21930" newVersion="1.6.5135.21930" />
|
||||
<assemblyIdentity name="WebGrease" publicKeyToken="31bf3856ad364e35"/>
|
||||
<bindingRedirect oldVersion="0.0.0.0-1.6.5135.21930" newVersion="1.6.5135.21930"/>
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="Antlr3.Runtime" publicKeyToken="eb42632606e9261f" culture="neutral" />
|
||||
<bindingRedirect oldVersion="0.0.0.0-3.5.0.2" newVersion="3.5.0.2" />
|
||||
<assemblyIdentity name="Antlr3.Runtime" publicKeyToken="eb42632606e9261f" culture="neutral"/>
|
||||
<bindingRedirect oldVersion="0.0.0.0-3.5.0.2" newVersion="3.5.0.2"/>
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="System.Web.Helpers" publicKeyToken="31bf3856ad364e35" />
|
||||
<bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
|
||||
<assemblyIdentity name="Microsoft.Diagnostics.Tracing.EventSource" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>
|
||||
<bindingRedirect oldVersion="0.0.0.0-1.1.14.0" newVersion="1.1.14.0"/>
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="System.Web.WebPages" publicKeyToken="31bf3856ad364e35" />
|
||||
<bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
|
||||
<assemblyIdentity name="System.Web.Helpers" publicKeyToken="31bf3856ad364e35"/>
|
||||
<bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0"/>
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35" />
|
||||
<bindingRedirect oldVersion="1.0.0.0-5.2.3.0" newVersion="5.2.3.0" />
|
||||
<assemblyIdentity name="System.Web.WebPages" publicKeyToken="31bf3856ad364e35"/>
|
||||
<bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0"/>
|
||||
</dependentAssembly>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35"/>
|
||||
<bindingRedirect oldVersion="1.0.0.0-5.2.3.0" newVersion="5.2.3.0"/>
|
||||
</dependentAssembly>
|
||||
</assemblyBinding>
|
||||
</runtime>
|
||||
<system.webServer>
|
||||
|
||||
<modules>
|
||||
</modules>
|
||||
<urlCompression doDynamicCompression="true" />
|
||||
<validation validateIntegratedModeConfiguration="false" />
|
||||
<handlers>
|
||||
<remove name="ExtensionlessUrlHandler-Integrated-4.0" />
|
||||
<remove name="OPTIONSVerbHandler" />
|
||||
<remove name="TRACEVerbHandler" />
|
||||
<add name="ExtensionlessUrlHandler-Integrated-4.0" path="*." verb="*" type="System.Web.Handlers.TransferRequestHandler" preCondition="integratedMode,runtimeVersionv4.0" />
|
||||
</handlers></system.webServer>
|
||||
<urlCompression doDynamicCompression="true"/>
|
||||
<validation validateIntegratedModeConfiguration="false"/>
|
||||
<handlers>
|
||||
<remove name="ExtensionlessUrlHandler-Integrated-4.0"/>
|
||||
<remove name="OPTIONSVerbHandler"/>
|
||||
<remove name="TRACEVerbHandler"/>
|
||||
<add name="ExtensionlessUrlHandler-Integrated-4.0" path="*." verb="*" type="System.Web.Handlers.TransferRequestHandler"
|
||||
preCondition="integratedMode,runtimeVersionv4.0"/>
|
||||
</handlers>
|
||||
</system.webServer>
|
||||
</configuration>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="Antlr" version="3.5.0.2" targetFramework="net45" />
|
||||
<package id="jQuery" version="2.1.1" targetFramework="net45" />
|
||||
<package id="jQuery" version="2.1.3" targetFramework="net45" />
|
||||
<package id="jQuery.Validation" version="1.13.1" targetFramework="net45" />
|
||||
<package id="Microsoft.ApplicationInsights" version="0.12.0-build17386" targetFramework="net45" />
|
||||
<package id="Microsoft.ApplicationInsights.PerformanceCollector" version="0.12.0-build17386" targetFramework="net45" />
|
||||
|
|
Loading…
Reference in New Issue
Block a user