Initial import
This commit is contained in:
parent
0c865416ca
commit
04804b89a9
279 changed files with 12945 additions and 0 deletions
19
web/Views/Account/AddRole.aspx
Normal file
19
web/Views/Account/AddRole.aspx
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
<%@ Page Title="" Language="C#" Inherits="System.Web.Mvc.ViewPage" MasterPageFile="~/Models/App.master" %>
|
||||
<asp:Content ContentPlaceHolderID="head" ID="headContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="header" ID="headerContent" runat="server">
|
||||
<h2>Ajout d'un role</h2>
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="MainContent" ID="MainContentContent" runat="server">
|
||||
|
||||
<%= Html.ValidationSummary() %>
|
||||
<% using(Html.BeginForm("DoAddRole", "Account")) %>
|
||||
<% { %>
|
||||
Nom du rôle :
|
||||
<%= Html.TextBox( "RoleName" ) %>
|
||||
<%= Html.ValidationMessage("RoleName", "*") %><br/>
|
||||
<input class="actionlink" type="submit"/>
|
||||
<% } %>
|
||||
</asp:Content>
|
||||
|
||||
|
||||
34
web/Views/Account/Admin.aspx
Normal file
34
web/Views/Account/Admin.aspx
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
<%@ Page Title="Administration" Language="C#" Inherits="System.Web.Mvc.ViewPage<NewAdminModel>" MasterPageFile="~/Models/App.master" %>
|
||||
<asp:Content ContentPlaceHolderID="header" ID="headerContent" runat="server">
|
||||
<h2>Liste des administrateurs </h2>
|
||||
</asp:Content>
|
||||
|
||||
<asp:Content ContentPlaceHolderID="MainContent" ID="MainContentContent" runat="server">
|
||||
<div>
|
||||
|
||||
<table>
|
||||
<% foreach (string u in (string[])ViewData["admins"]) { %>
|
||||
<tr><td>
|
||||
<%= u %> </td><td><%= Html.ActionLink("Remove","RemoveFromRole",new { username = u, rolename="Admin", returnUrl = Request.Url.PathAndQuery })%>
|
||||
</td></tr>
|
||||
|
||||
<% } %>
|
||||
</table>
|
||||
</div>
|
||||
<div>
|
||||
<h2>Ajout d'un administrateur
|
||||
</h2>
|
||||
<p><%= Html.ValidationSummary() %> </p>
|
||||
|
||||
<% using ( Html.BeginForm("Admin", "Account") ) { %>
|
||||
|
||||
<%= Html.LabelFor(model => model.UserName) %> :
|
||||
<%= Html.DropDownListFor(model => model.UserName, (List<SelectListItem>)ViewData["useritems"] ) %>
|
||||
<%= Html.ValidationMessage("UserName", "*") %>
|
||||
|
||||
<input type="submit"/>
|
||||
<% } %>
|
||||
|
||||
</div>
|
||||
</asp:Content>
|
||||
|
||||
26
web/Views/Account/ChangePassword.aspx
Normal file
26
web/Views/Account/ChangePassword.aspx
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
<%@ Page Title="Change your Password" Language="C#" Inherits="System.Web.Mvc.ViewPage<ChangePasswordModel>" MasterPageFile="~/Models/App.master" %>
|
||||
<asp:Content ContentPlaceHolderID="head" ID="headContent" runat="server">
|
||||
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="MainContent" ID="MainContentContent" runat="server">
|
||||
|
||||
<%= Html.ValidationSummary("Modification de mot de passe") %>
|
||||
<% using(Html.BeginForm("ChangePassword", "Account")) { %>
|
||||
<label for="UserName">User Name:</label>
|
||||
<%= Html.TextBox( "UserName" ) %>
|
||||
<%= Html.ValidationMessage("UserName", "*") %><br/>
|
||||
<label for="OldPassword">Old password:</label>
|
||||
<%= Html.Password( "OldPassword" ) %>
|
||||
<%= Html.ValidationMessage("OldPassword", "*") %><br/>
|
||||
<label for="NewPassword">New password:</label>
|
||||
<%= Html.Password( "NewPassword" ) %>
|
||||
<%= Html.ValidationMessage("NewPassword", "*") %><br/>
|
||||
<label for="ConfirmPassword">Confirm password:</label>
|
||||
<%= Html.Password( "ConfirmPassword" ) %>
|
||||
<%= Html.ValidationMessage("ConfirmPassword", "*") %>
|
||||
<input type="submit"/>
|
||||
<% } %>
|
||||
|
||||
</asp:Content>
|
||||
|
||||
|
||||
8
web/Views/Account/ChangePasswordSuccess.aspx
Normal file
8
web/Views/Account/ChangePasswordSuccess.aspx
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
<%@ Page Title="Successfully changed your password" Language="C#" Inherits="System.Web.Mvc.ViewPage" MasterPageFile="~/Models/App.master" %>
|
||||
<asp:Content ContentPlaceHolderID="head" ID="headContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="MainContent" ID="MainContentContent" runat="server">
|
||||
<div>
|
||||
<%= Html.ActionLink("Register","Register")%></div>
|
||||
<div><%= Html.ActionLink("ChangePassword","ChangePassword")%></div>
|
||||
</asp:Content>
|
||||
8
web/Views/Account/Index.aspx
Normal file
8
web/Views/Account/Index.aspx
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
<%@ Page Title="Comptes utilisateur - Index" Language="C#" Inherits="System.Web.Mvc.ViewPage" MasterPageFile="~/Models/App.master" %>
|
||||
<asp:Content ContentPlaceHolderID="head" ID="headContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="header" ID="headerContent" runat="server">
|
||||
<h2>Comptes utilisteur</h2>
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="MainContent" ID="MainContentContent" runat="server">
|
||||
</asp:Content>
|
||||
28
web/Views/Account/Login.aspx
Normal file
28
web/Views/Account/Login.aspx
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
<%@ Page Title="Login" Language="C#" Inherits="System.Web.Mvc.ViewPage<LoginModel>" MasterPageFile="~/Models/App.master" %>
|
||||
<asp:Content ContentPlaceHolderID="head" ID="headContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="MainContent" ID="MainContentContent" runat="server">
|
||||
|
||||
<div>
|
||||
<%= Html.ValidationSummary("Ouverture de session") %>
|
||||
<% using(Html.BeginForm("DoLogin", "Account")) %>
|
||||
<% { %>
|
||||
<%= Html.LabelFor(model => model.UserName) %>
|
||||
<%= Html.TextBox( "UserName" ) %>
|
||||
<%= Html.ValidationMessage("UserName", "*") %><br/>
|
||||
|
||||
<%= Html.LabelFor(model => model.Password) %>
|
||||
<%= Html.Password( "Password" ) %>
|
||||
<%= Html.ValidationMessage("Password", "*") %><br/>
|
||||
|
||||
<label for="RememberMe">Se souvenir du mot de passe:</label>
|
||||
<%= Html.CheckBox("RememberMe") %>
|
||||
<%= Html.ValidationMessage("RememberMe", "") %><br/>
|
||||
<%= Html.Hidden("returnUrl",ViewData["returnUrl"]) %>
|
||||
<!-- Html.AntiForgeryToken() -->
|
||||
<input type="submit"/>
|
||||
<% } %>
|
||||
</div>
|
||||
<div>
|
||||
<%= Html.ActionLink("S'enregistrer","Register",new {returnUrl=ViewData["returnUrl"]}) %></div>
|
||||
</asp:Content>
|
||||
47
web/Views/Account/Profile.aspx
Normal file
47
web/Views/Account/Profile.aspx
Normal file
|
|
@ -0,0 +1,47 @@
|
|||
<%@ Page Title="Profile" Language="C#" MasterPageFile="~/Models/App.master" Inherits="System.Web.Mvc.ViewPage<yavscModel.RolesAndMembers.Profile>" %>
|
||||
<asp:Content ID="headContent" ContentPlaceHolderID="head" runat="server">
|
||||
<title><%=ViewData["UserName"]%> : Profile - <%=YavscHelpers.SiteName%></title>
|
||||
</asp:Content>
|
||||
<asp:Content ID="headerContent" ContentPlaceHolderID="header" runat="server">
|
||||
<h1><%=ViewData["UserName"]%> : Profile - <a href="/"><%=YavscHelpers.SiteName%></a></h1>
|
||||
<p><%= Html.ActionLink("Changer de mot de passe","ChangePassword", "Account")%></p>
|
||||
</asp:Content>
|
||||
<asp:Content ID="MainContentContent" ContentPlaceHolderID="MainContent" runat="server">
|
||||
<%= Html.ValidationSummary() %>
|
||||
<% using(Html.BeginForm("UpdateProfile", "Account", FormMethod.Post, new { enctype = "multipart/form-data" })) %>
|
||||
<% { %>
|
||||
|
||||
<table class="layout">
|
||||
<tr><td align="right">
|
||||
<%= Html.LabelFor(model => model.Address) %></td><td>
|
||||
<%= Html.TextBox("Address") %>
|
||||
<%= Html.ValidationMessage("Address", "*") %></td></tr>
|
||||
<tr><td align="right">
|
||||
<%= Html.LabelFor(model => model.CityAndState) %></td><td>
|
||||
<%= Html.TextBox("CityAndState") %>
|
||||
<%= Html.ValidationMessage("CityAndState", "*") %></td></tr>
|
||||
<tr><td align="right">
|
||||
<%= Html.LabelFor(model => model.Country) %></td><td>
|
||||
<%= Html.TextBox("Country") %>
|
||||
<%= Html.ValidationMessage("Country", "*") %></td></tr>
|
||||
<tr><td align="right">
|
||||
<%= Html.LabelFor(model => model.WebSite) %></td><td>
|
||||
<%= Html.TextBox("WebSite") %>
|
||||
<%= Html.ValidationMessage("WebSite", "*") %></td></tr>
|
||||
<tr><td align="right">
|
||||
<%= Html.LabelFor(model => model.BlogVisible) %></td><td>
|
||||
<%= Html.CheckBox("BlogVisible") %>
|
||||
<%= Html.ValidationMessage("BlogVisible", "*") %></td></tr>
|
||||
<tr><td align="right">
|
||||
<%= Html.LabelFor(model => model.BlogTitle) %></td><td>
|
||||
<%= Html.TextBox("BlogTitle") %>
|
||||
<%= Html.ValidationMessage("BlogTitle", "*") %></td></tr>
|
||||
<tr><td align="right">
|
||||
Avatar </td><td> <img class="avatar" src="/Blogs/Avatar?user=<%=ViewData["UserName"]%>" alt=""/>
|
||||
<input type="file" id="AvatarFile" name="AvatarFile"/>
|
||||
<%= Html.ValidationMessage("AvatarFile", "*") %></td></tr>
|
||||
|
||||
</table>
|
||||
<input type="submit"/>
|
||||
<% } %>
|
||||
</asp:Content>
|
||||
45
web/Views/Account/Register.aspx
Normal file
45
web/Views/Account/Register.aspx
Normal file
|
|
@ -0,0 +1,45 @@
|
|||
<%@ Page Title="Register" Language="C#" Inherits="Yavsc.RegisterPage" MasterPageFile="~/Models/App.master" %>
|
||||
<asp:Content ContentPlaceHolderID="head" ID="headContent" runat="server">
|
||||
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="header" ID="headerContent" runat="server">
|
||||
<h2> Créez votre compte utilisateur <%= Html.Encode(YavscHelpers.SiteName) %> </h2>
|
||||
</asp:Content>
|
||||
|
||||
<asp:Content ContentPlaceHolderID="MainContent" ID="MainContentContent" runat="server">
|
||||
<%= Html.ValidationSummary() %>
|
||||
<% using(Html.BeginForm("Register", "Account")) %>
|
||||
<% { %>
|
||||
<table class="layout">
|
||||
<tr><td align="right">
|
||||
<%= Html.LabelFor(model => model.UserName) %>
|
||||
</td><td>
|
||||
<%= Html.TextBox( "UserName" ) %>
|
||||
<%= Html.ValidationMessage("UserName", "*") %></td></tr>
|
||||
<tr><td align="right">
|
||||
<%= Html.LabelFor(model => model.Password) %>
|
||||
</td><td>
|
||||
<%= Html.Password( "Password" ) %>
|
||||
<%= Html.ValidationMessage("Password", "*") %>
|
||||
</td></tr>
|
||||
<tr><td align="right">
|
||||
<%= Html.LabelFor(model => model.ConfirmPassword) %>
|
||||
</td><td>
|
||||
<%= Html.Password( "ConfirmPassword" ) %>
|
||||
<%= Html.ValidationMessage("ConfirmPassword", "*") %>
|
||||
</td></tr>
|
||||
<tr><td align="right">
|
||||
<%= Html.LabelFor(model => model.Email) %>
|
||||
</td><td>
|
||||
<%= Html.TextBox( "Email" ) %>
|
||||
<%= Html.ValidationMessage("Email", "*") %>
|
||||
</td></tr>
|
||||
</table>
|
||||
<br/>
|
||||
<%= Html.Hidden("returnUrl",ViewData["returnUrl"]) %>
|
||||
|
||||
<input type="submit"/>
|
||||
<% } %>
|
||||
</asp:Content>
|
||||
|
||||
|
||||
17
web/Views/Account/RegistrationPending.aspx
Normal file
17
web/Views/Account/RegistrationPending.aspx
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
<%@ Page Title="Comptes utilisateur - Index" Language="C#" Inherits="System.Web.Mvc.ViewPage" MasterPageFile="~/Models/App.master" %>
|
||||
<asp:Content ContentPlaceHolderID="head" ID="headContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="header" ID="headerContent" runat="server">
|
||||
<h2>Comptes utilisteur</h2>
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="MainContent" ID="MainContentContent" runat="server">
|
||||
<p>
|
||||
Votre compte utilisateur
|
||||
<%= Html.Encode(YavscHelpers.SiteName) %>
|
||||
a été créé, un e-mail de validation de votre compte a été envoyé a l'adresse fournie:<br/>
|
||||
<<%= Html.Encode(ViewData["email"]) %>>.<br/>
|
||||
Vous devriez le recevoir rapidement.<br/>
|
||||
Pour valider votre compte, suivez le lien indiqué dans cet e-mail.
|
||||
</p>
|
||||
<a class="actionlink" href="<%=ViewData["ReturnUrl"]%>">Retour</a>
|
||||
</asp:Content>
|
||||
22
web/Views/Account/RemoveRoleQuery.aspx
Normal file
22
web/Views/Account/RemoveRoleQuery.aspx
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
<%@ Page Title="User removal" Language="C#" Inherits="System.Web.Mvc.ViewPage" MasterPageFile="~/Models/App.master" %>
|
||||
<asp:Content ContentPlaceHolderID="head" ID="headContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="header" ID="headerContent" runat="server">
|
||||
<h2>Suppression d'un rôle</h2>
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="MainContent" ID="MainContentContent" runat="server">
|
||||
<div>
|
||||
<%= Html.ValidationSummary() %>
|
||||
<% using ( Html.BeginForm("RemoveRole") ) { %>
|
||||
Supprimer le rôle
|
||||
<%= Html.Encode( ViewData["roletoremove"] ) %> ?
|
||||
<br/>
|
||||
<input type="hidden" name="rolename" value="<%=ViewData["roletoremove"]%>"/>
|
||||
<input class="actionlink" type="submit" name="submitbutton" value="Supprimer"/>
|
||||
<input class="actionlink" type="submit" name="submitbutton" value="Annuler" />
|
||||
<% } %>
|
||||
</div>
|
||||
|
||||
</asp:Content>
|
||||
|
||||
|
||||
22
web/Views/Account/RemoveUserQuery.aspx
Normal file
22
web/Views/Account/RemoveUserQuery.aspx
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
<%@ Page Title="User removal" Language="C#" Inherits="System.Web.Mvc.ViewPage" MasterPageFile="~/Models/App.master" %>
|
||||
<asp:Content ContentPlaceHolderID="head" ID="headContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="header" ID="headerContent" runat="server">
|
||||
<h2>Suppression d'un utilisateur</h2>
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="MainContent" ID="MainContentContent" runat="server">
|
||||
<div>
|
||||
<%= Html.ValidationSummary() %>
|
||||
<% using ( Html.BeginForm("RemoveUser","Account") ) { %>
|
||||
Supprimer l'utilisateur
|
||||
<%= Html.Encode( ViewData["usertoremove"] ) %> ?
|
||||
<br/>
|
||||
<input type="hidden" name="username" value="<%=ViewData["usertoremove"]%>"/>
|
||||
<input class="actionlink" type="submit" name="submitbutton" value="Supprimer"/>
|
||||
<input class="actionlink" type="submit" name="submitbutton" value="Annuler" />
|
||||
<% } %>
|
||||
</div>
|
||||
|
||||
</asp:Content>
|
||||
|
||||
|
||||
23
web/Views/Account/RoleList.aspx
Normal file
23
web/Views/Account/RoleList.aspx
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
<%@ Page Title="Role list" Language="C#" Inherits="System.Web.Mvc.ViewPage" MasterPageFile="~/Models/App.master" %>
|
||||
<asp:Content ContentPlaceHolderID="head" ID="headContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="header" ID="headerContent" runat="server">
|
||||
<h2>Liste des rôles</h2>
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="MainContent" ID="MainContentContent" runat="server">
|
||||
Roles:
|
||||
<ul>
|
||||
<%foreach (string rolename in (string[]) Model){ %>
|
||||
|
||||
<li><%=rolename%> <% if (Roles.IsUserInRole("Admin")) { %>
|
||||
<%= Html.ActionLink("Supprimer","RemoveRole", new { rolename = rolename }, new { @class="actionlink" } ) %>
|
||||
<% } %></li>
|
||||
<% } %>
|
||||
|
||||
</ul>
|
||||
<% if (Roles.IsUserInRole("Admin")) { %>
|
||||
<%= Html.ActionLink("Ajouter un rôle","AddRole", null, new { @class="actionlink" } ) %>
|
||||
<% } %>
|
||||
</asp:Content>
|
||||
|
||||
|
||||
22
web/Views/Account/UserList.aspx
Normal file
22
web/Views/Account/UserList.aspx
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
<%@ Page Title="User List" Language="C#" Inherits="System.Web.Mvc.ViewPage<System.Web.Security.MembershipUserCollection>" MasterPageFile="~/Models/App.master" %>
|
||||
<asp:Content ContentPlaceHolderID="head" ID="headContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="header" ID="headerContent" runat="server">
|
||||
<h2>Liste des utilisateurs</h2>
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="MainContent" ID="MainContentContent" runat="server">
|
||||
|
||||
<ul>
|
||||
<%foreach (MembershipUser user in Model){ %>
|
||||
|
||||
<li><%=user.UserName%> <%=user.Email%> <%=(!user.IsApproved)?"(Not Approuved)":""%> <%=user.IsOnline?"Online":"Offline"%>
|
||||
<% if (Roles.IsUserInRole("Admin")) { %>
|
||||
<%= Html.ActionLink("Supprimer","RemoveUserQuery", new { username = user.UserName }, new { @class="actionlink" } ) %>
|
||||
<% } %>
|
||||
</li>
|
||||
|
||||
<% }%>
|
||||
</ul>
|
||||
|
||||
</asp:Content>
|
||||
|
||||
8
web/Views/Account/Validate.aspx
Normal file
8
web/Views/Account/Validate.aspx
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
<%@ Page Title="Comptes utilisateur - Validation" Language="C#" Inherits="System.Web.Mvc.ViewPage" MasterPageFile="~/Models/App.master" %>
|
||||
<asp:Content ContentPlaceHolderID="head" ID="headContent" runat="server">
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="header" ID="headerContent" runat="server">
|
||||
<h2>Validation d'un compte utilisateur</h2>
|
||||
</asp:Content>
|
||||
<asp:Content ContentPlaceHolderID="MainContent" ID="MainContentContent" runat="server">
|
||||
</asp:Content>
|
||||
Loading…
Add table
Add a link
Reference in a new issue