yavsc/web/Views/Blogs/UserPosts.aspx
Paul Schneider 30cebd7751 yalook
* totem-banner.png:
* totem-banner.xs.jpg:
* totem-banner.xxs.jpg: totem custo

* Makefile: reloads config after each rsync call

* NpgsqlBlogProvider.cs: - Fixes access on bills
- Fixes usage of bill without photo

* style.css: yastyle

* AccountController.cs: - Fixes route usage with n ovalue for `id`
- better code at getting the avatar url

* BlogsController.cs: Fixes a Post request without user name in the
  route

* YavscHelpers.cs: Implements a file list html rendering

* App.master:
* UserPost.aspx:
* Profile.aspx:
* AssemblyInfo.aspx: yahtmlstructure

* Edit.aspx: Displays a list a attached files

* UserPosts.aspx: yahtmlstrucure

* Web.csproj: new images

* instdbws.sql: returns to the flat list of properies (groups are not
  working)

* LocalizedText.resx:
* LocalizedText.fr.resx:
* LocalizedText.Designer.cs:
* LocalizedText.fr.Designer.cs: a new translation
2015-10-09 16:31:04 +02:00

57 lines
2.2 KiB
Text

<%@ Page Title="Blog" Language="C#" Inherits="System.Web.Mvc.ViewPage<UUBlogEntryCollection>" MasterPageFile="~/Models/App.master"%>
<%@ Register Assembly="Yavsc.WebControls" TagPrefix="yavsc" Namespace="Yavsc.WebControls" %>
<asp:Content ContentPlaceHolderID="init" ID="init1" runat="server">
<% Title = (string) ViewData ["BlogTitle"] ; %>
</asp:Content>
<asp:Content ContentPlaceHolderID="overHeaderOne" ID="header1" runat="server">
<% if (!string.IsNullOrEmpty((string)ViewData["Avatar"])) { %>
<a href="<%=Url.Content("~/Blog/"+Model.Author)%>" id="avatar">
<img src="<%=ViewData["Avatar"]%>" />
</a>
<% } %>
<h1 class="blogtitle">
<a href="<%=Url.Content("~/Blog/"+Model.Author)%>">
<%=Html.Encode(ViewData["BlogTitle"])%></a>
-
<a href="<%=Request.Url.Scheme + "://" + Request.Url.Authority%>"><%= YavscHelpers.SiteName %></a>
</h1>
</asp:Content>
<asp:Content ContentPlaceHolderID="MainContent" ID="MainContentContent" runat="server">
<% foreach (BlogEntry e in this.Model) { %>
<div class="postpreview<% if (!e.Visible) { %> hiddenpost<% } %>" >
<h2><%= Html.ActionLink(e.Title,"UserPost", new { user=e.Author, title=e.Title, id = e.Id }, new { @class = "usertitleref" }) %></h2>
<% bool truncated = false; %>
<%= Html.MarkdownToHtmlIntro(out truncated, e.Content,"/bfiles/"+e.Id+"/") %>
<% if (truncated) { %>
<i><%= Html.ActionLink( "lire la suite" ,"UserPost", new { user=e.Author, title=e.Title, id = e.Id }, new { @class = "usertitleref" }) %></i>
<% } %>
<aside>(<%= e.Posted.ToString("yyyy/MM/dd") %>
- <%= e.Modified.ToString("yyyy/MM/dd") %> <%= e.Visible? "":", Invisible!" %>)
<% if (Membership.GetUser()!=null)
if (Membership.GetUser().UserName==e.Author)
{ %>
<%= Html.ActionLink("Editer","Edit", new { id = e.Id }, new { @class="actionlink" }) %>
<%= Html.ActionLink("Supprimer","RemovePost", new { id = e.Id }, new { @class="actionlink" } ) %>
<% } %>
</aside>
</div>
<% } %>
<aside>
<form runat="server" id="form1" method="GET">
<%
rp1.ResultCount = (int) ViewData["RecordCount"];
rp1.PageIndex = (int) ViewData["PageIndex"];
%>
<yavsc:ResultPages id="rp1" Action = "?pageIndex={0}" runat="server">
<None><i>Pas de contenu</i></None>
</yavsc:ResultPages>
</form>
</aside>
</asp:Content>