* style.css: * Gives main background a color

* lets small screens keep their font sizes

* Catalog.xml: makes it a better

* BlogsController.cs: Fixes the access to the Blog

* App.master: fixes the quick link to the user's blog

* Index.aspx: removes the table

* UserPosts.aspx: Mainly links to UserPost
This commit is contained in:
Paul Schneider
2015-08-05 02:02:14 +02:00
parent 3355f9fed0
commit c327395b5b
7 changed files with 65 additions and 35 deletions

View File

@ -21,6 +21,7 @@ input, textarea, checkbox {
main {
margin:1em;
background-color: rgba(64,64,64,0.6);
}
fieldset {
background-color: rgba(32,16,16,0.8);
@ -44,12 +45,12 @@ footer {
z-index:-1;
font-size: smaller;
}
.thanks {
max-width: 10%;
text-align: center;
vertical-align: text-bottom;
font-size:smaller;
display:block;
display:inline;
bottom:0;
}
@ -63,7 +64,6 @@ footer {
.panel,.bshpanel,aside {
background-color: rgba(32,16,16,0.8);
border-radius:5px; border: solid 1px #000060;
float: left;
margin:.5em;
padding: .5em;
}
@ -71,6 +71,7 @@ footer {
.bsh { float: right; }
#login {
background-color: rgba(32,0,0,.5);
position: fixed;
margin:0em;
padding:0em;
@ -90,8 +91,6 @@ header {
left:0;
margin:0em;
padding:0em;
text-align: center;
max-width:55%;
}
h1 img { vertical-align: text-top; }
@ -167,6 +166,8 @@ ul.preview li:nth-child(n) {
color: #f88;
}
usertitleref {
}
.actionlink {
color: #B0B080;
@ -175,6 +176,8 @@ ul.preview li:nth-child(n) {
background-color:rgba(0,0,32,0.8);
cursor: pointer;
font-family: 'Arial', cursive;
font-size: 140%;
display:block;
}
input, select {
@ -247,7 +250,6 @@ a.actionlink img { top:4px; }
font-size: x-small;
}
body { font-size: smaller; }
.c2 { display:initial; }
.c2-alt { display:none; }
.c3 { display:none; }
@ -255,7 +257,6 @@ a.actionlink img { top:4px; }
}
@media all and (max-width: 350px) {
footer { font-size: xx-small; }
.c2 { display:none; }
.c2-alt { display:initial; }
}

View File

@ -2,7 +2,7 @@
<XmlCatalog xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<Brands>
<Brand>
<Name>shdsi</Name>
<Name>psc</Name>
<Slogan>Votre logiciel, efficace, sûr, et sur mesure</Slogan>
<Logo>
<Src>/images/logoDev.png</Src>
@ -11,20 +11,34 @@
</Logo>
<Categories>
<ProductCategory>
<Name>Systèmes d'information et sites Web</Name>
<Name>Conseil, conception logicielle</Name>
<Reference>ccl</Reference>
<Products>
<Product xsi:type="Service">
<Name>Aide au choix technologiques</Name>
<Description>tout un art</Description>
<Reference>conseil</Reference>
</Product>
<Product xsi:type="Service">
<Name>Conceptualisation de projet</Name>
<Description>Consolidation d'un niveau logique de projet, spécifications détaillées</Description>
<Reference>concept</Reference>
</Product>
</Products>
</ProductCategory>
<ProductCategory>
<Name>Développement et maintenance</Name>
<Reference>ntic</Reference>
<Products>
<Product xsi:type="Service">
<Name>Développement</Name>
<Description>Votre Extranet, Intranet,
site Web, sur mesure, élégant et efficace, au look racé, accessible,
et développé en cycles courts</Description>
<Reference>nticdev</Reference>
<Description>Votre appli développée en cycles courts</Description>
<Reference>dev</Reference>
</Product>
<Product xsi:type="Service">
<Name>Maintenance</Name>
<Description>Correction des anomalies, réalisation des évolutions, prévision des besoins</Description>
<Reference>nticmaint</Reference>
<Reference>main</Reference>
</Product>
</Products>
</ProductCategory>

View File

@ -1,3 +1,18 @@
2015-08-05 Paul Schneider <paul@pschneider.fr>
* style.css: * Gives main background a color
* lets small screens keep their font sizes
* Catalog.xml: makes it a better
* BlogsController.cs: Fixes the access to the Blog
* App.master: fixes the quick link to the user's blog
* Index.aspx: removes the table
* UserPosts.aspx: Mainly links to UserPost
2015-08-04 Paul Schneider <paul@pschneider.fr>
* bg.gif:

View File

@ -135,7 +135,7 @@ namespace Yavsc.Controllers
if (uuc.Count>0)
return View ("UserPost", new UUTBlogEntryCollection(uuc.UserName,
uuc[0].Title,uuc));
return View ("Index", uuc);
return View ("UserPosts", uuc);
}
/// <summary>

View File

@ -1,4 +1,4 @@
<%@ Master Language="C#" Inherits="System.Web.Mvc.ViewMasterPage" %>
<%@ Master Language="C#" Inherits="System.Web.Mvc.ViewMasterPage" CodeBehind="App.master.cs" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<asp:ContentPlaceHolder id="init" runat="server">
@ -38,14 +38,15 @@ ViewState["orgtitle"] = T.GetString(Page.Title);
<asp:ContentPlaceHolder ID="MASContent" runat="server">
</asp:ContentPlaceHolder>
<div id="login" ><span class="ohinside">
<a href="<%= Url.Content("~/Blog/"+HttpContext.Current.User.Identity.Name)%>"><img src="/favicon.png" width="25%"/> Votre Blog</a><br/>
<a href="<%= Url.Content("~/")%>">
<a href="<%= Url.Content("~/")%>">
<span class="c2"><%=Html.Encode(YavscHelpers.SiteName) %></span></a><br/>
<span class="onhover">Page d'accueil<br/></span></span>
<% if (Membership.GetUser()==null) { %>
<div class="ohinside"><%= Html.ActionLink("Authentification", "Login", "Account", new { returnUrl=Request.Url.PathAndQuery },null) %>
<span class="onhover">Pourquoi s'authentifier?</span></div><br/>
<% } else { %><span class="ohinside">
<% } else { %>
<a href="/Blog/<%= HttpContext.Current.User.Identity.Name%>"><img src="/favicon.png" width="25%"/> Votre Blog</a><br/>
<span class="ohinside">
<%= Html.ActionLink(HttpContext.Current.User.Identity.Name, "Profile", "Account", new { id = HttpContext.Current.User.Identity.Name }, null) %>
<span class="onhover"> &Eacute;dition de votre profile </span></span><br/>
<a href="/Blogs/Post" class="ohafter">Poster</a>
@ -59,8 +60,10 @@ ViewState["orgtitle"] = T.GetString(Page.Title);
<%= Html.ActionLink("Contact","Contact","Home",null, new { @class="thanks" }) %>
<% foreach ( Link link in Html.Thanks()) { %>
<a class="thanks" href="<%=link.Url%>"><% if (link.Image !=null) {
%><img src="<%= link.Image %>" alt="<%= link.Text %>"/></a><%
} else { %><a class="thanks" href="<%=link.Url%>"><%= link.Text %></a><% }} %>
%><img src="<%= link.Image %>" alt="<%= link.Text %>"/></a>
<% } else { %>
<a class="thanks" href="<%=link.Url%>"><%= link.Text %></a>
<% }} %>
<div class="g-plusone" data-annotation="inline" data-width="230"></div>
</footer>
<script type="text/javascript">

View File

@ -3,29 +3,26 @@
<asp:Content ContentPlaceHolderID="MainContent" ID="MainContentContent" runat="server">
<div>
<table>
<% foreach (var g in Model.GroupByUser()) { %>
<tr><th><%= Html.ActionLink(g.Key, "Index",
new { user = g.Key }, new { @class = "userref" } ) %>
</th></tr>
<h1><a href="<%= Url.Content("~/Blog") %>" class="actionlink userref">
<%=g.Key%></a></h1>
<% foreach (var p in g) { %>
<tr>
<td>
<div class="blogpost">
<%= Html.ActionLink(p.Title, "UserPost",
new { user = g.Key, title = p.Title }, new { @class = "usertitleref" } ) %>
le <%=p.Posted.ToString("D") %>
</td>
<% if (Membership.GetUser()!=null)
if ((Membership.GetUser().UserName==g.Key)
|| (Roles.IsUserInRole ("Admin")))
{ %><td>
{ %><aside>
<%= Html.ActionLink("Editer","Edit", new { id = p.Id }, new { @class="actionlink" }) %>
<%= Html.ActionLink("Supprimer","RemovePost", new { id = p.Id }, new { @class="actionlink" } ) %>
</td><% } %>
</tr> <% } %>
</aside><% } %>
</div> <% } %>
<% } %>
</table>
</div>
<form runat="server" id="form1" method="GET">

View File

@ -1,7 +1,7 @@
<%@ Page Title="Billets utilisateurs" Language="C#" Inherits="System.Web.Mvc.ViewPage<BlogEntryCollection>" MasterPageFile="~/Models/App.master"%>
<%@ 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"]; %>
<% Title = (string) ViewData ["BlogTitle"] ; %>
</asp:Content>
<asp:Content ContentPlaceHolderID="overHeaderOne" ID="header1" runat="server">
@ -20,7 +20,7 @@
<% foreach (BlogEntry e in this.Model) { %>
<div <% if (!e.Visible) { %> style="background-color:#022;" <% } %>>
<h2 class="blogtitle" ><%= Html.ActionLink(e.Title,"GetPost", new { id = e.Id }) %></h2>
<h2 class="blogtitle" ><%= Html.ActionLink(e.Title,"UserPost", new { user=e.UserName, title=e.Title, id = e.Id }) %></h2>
<div class="metablog">(<%= e.Posted.ToString("yyyy/MM/dd") %>
- <%= e.Modified.ToString("yyyy/MM/dd") %> <%= e.Visible? "":", Invisible!" %>)
<% if (Membership.GetUser()!=null)