Skip to content
This repository has been archived by the owner on Sep 4, 2019. It is now read-only.

Commit

Permalink
attempt of writing statsview.py, doesn't work for unknown reasons
Browse files Browse the repository at this point in the history
  • Loading branch information
Fred committed Aug 9, 2011
1 parent ce8a765 commit 289d3ce
Show file tree
Hide file tree
Showing 15 changed files with 1,897 additions and 1,154 deletions.
9 changes: 6 additions & 3 deletions app.yaml
Expand Up @@ -6,7 +6,7 @@ api_version: 1
handlers: handlers:
- url: /remote_api - url: /remote_api
script: $PYTHON_LIB/google/appengine/ext/remote_api/handler.py script: $PYTHON_LIB/google/appengine/ext/remote_api/handler.py
login: admin login: admin
- url: /content/(.*) - url: /content/(.*)
static_files: content/\1 static_files: content/\1
upload: content/(.*) upload: content/(.*)
Expand All @@ -16,10 +16,10 @@ handlers:
- url: /fetch - url: /fetch
script: main.py script: main.py
login: admin login: admin
- url: /fetchall - url: /allworker
script: main.py script: main.py
login: admin login: admin
- url: /fetchsync - url: /taglistworker
script: main.py script: main.py
login: admin login: admin
- url: /clearpagecache - url: /clearpagecache
Expand All @@ -30,3 +30,6 @@ handlers:
login: admin login: admin
- url: .* - url: .*
script: main.py script: main.py

builtins:
- datastore_admin: on
20 changes: 16 additions & 4 deletions bulkloader.yaml
Expand Up @@ -36,8 +36,8 @@ transformers:
- property: homepage - property: homepage
external_name: homepage external_name: homepage


- property: comments - property: comments_url
external_name: comments external_name: comments_url


- property: favicon - property: favicon
external_name: favicon external_name: favicon
Expand Down Expand Up @@ -67,7 +67,19 @@ transformers:
external_name: language external_name: language
# Type: String Stats: 128 properties of this type in this kind. # Type: String Stats: 128 properties of this type in this kind.


- property: url - property: posts_url
external_name: url external_name: posts_url
# Type: String Stats: 128 properties of this type in this kind. # Type: String Stats: 128 properties of this type in this kind.


- property: comments_day
external_name: comments_day

- property: comments_week
external_name: comments_week

- property: posts_week
external_name: posts_week

- property: posts_month
external_name: posts_month

6 changes: 5 additions & 1 deletion bydate.tmpl
@@ -1,3 +1,5 @@
#from main import *

$header $header


$menu $menu
Expand All @@ -22,18 +24,20 @@ $menu
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
#for $entry in $allentries #for $entry in $Post.gql("WHERE category IN ['pure','applied'] ORDER BY timestamp_created LIMIT 150")
<tr> <tr>
<td valign="bottom" class="datecolumn"> <td valign="bottom" class="datecolumn">
<div> <div>
<%= entry.printShortTime_created() %> <%= entry.printShortTime_created() %>
</div> </div>
</td> </td>
#raw
<td valign="bottom" class="blogcolumn"> <td valign="bottom" class="blogcolumn">
<div> <div>
<a href="$entry.homepage" title="<%=entry.service%>"><%=entry.service%></a> <a href="$entry.homepage" title="<%=entry.service%>"><%=entry.service%></a>
</div> </div>
</td> </td>
#end raw
<td valign="bottom" class="postcolumn"> <td valign="bottom" class="postcolumn">
<div> <div>
<a href="$entry.link" title="<%=entry.title%>"><%=entry.title%></a> <a href="$entry.link" title="<%=entry.title%>"><%=entry.title%></a>
Expand Down
11 changes: 4 additions & 7 deletions bystats.tmpl
Expand Up @@ -4,10 +4,7 @@ $menu


<div class="content"> <div class="content">


<p> Warning! We calculate the numbers based on the current feeds. </p> <table class="bydate" id="commentsperday">
<p>If a feed only contains 10 entries, the stats will be at most 10 -- beware of multiples of 5!</p>

<table class="rankingcolumn" id="postsbydate">
<thead> <thead>
<tr> <tr>
<th align="left" class="datecolumn"> <th align="left" class="datecolumn">
Expand Down Expand Up @@ -35,7 +32,7 @@ $menu
</tbody> </tbody>
</table> </table>


<table class="rankingcolumn" id="postsbydate"> <table class="bydate" id="commentsperweek">
<thead> <thead>
<tr> <tr>
<th align="left" class="datecolumn"> <th align="left" class="datecolumn">
Expand Down Expand Up @@ -64,7 +61,7 @@ $menu
</table> </table>




<table class="rankingcolumn" id="postsbydate"> <table class="bydate" id="postsperweek">
<thead> <thead>
<tr> <tr>
<th align="left" class="datecolumn"> <th align="left" class="datecolumn">
Expand Down Expand Up @@ -96,7 +93,7 @@ $menu
</tbody> </tbody>
</table> </table>


<table class="rankingcolumn" id="postsbydate"> <table class="bydate" id="postspermonth">
<thead> <thead>
<tr> <tr>
<th align="left" class="datecolumn"> <th align="left" class="datecolumn">
Expand Down
23 changes: 15 additions & 8 deletions content/site.css
Expand Up @@ -263,6 +263,7 @@ width:500px;
{ {
float:left; float:left;
display:block; display:block;
width: 75px;
font-size:small; font-size:small;
font-weight:bold; font-weight:bold;
color:#FFFFFF; color:#FFFFFF;
Expand All @@ -281,7 +282,9 @@ background-color:black;


/* ------------ Begin Date View Table --------------- */ /* ------------ Begin Date View Table --------------- */


#postsbydate { .bydate {
float: left;
margin: 1ex !important;
table-layout: fixed; table-layout: fixed;
margin: 5ex; margin: 5ex;
padding: 5px; padding: 5px;
Expand All @@ -290,37 +293,37 @@ background-color:black;
-webkit-box-shadow: 4px 4px 8px black; -webkit-box-shadow: 4px 4px 8px black;
} }


#postsbydate td { .bydate td {
border-bottom: 1px dashed gray; border-bottom: 1px dashed gray;
} }


#postsbydate tbody .datecolumn { .bydate tbody .datecolumn {
width: 7ex; width: 7ex;
font-size: 80%; font-size: 80%;
text-align: left; text-align: left;
} }


#postsbydate tbody div { .bydate tbody div {
height: 1.2em; height: 1.2em;
overflow: hidden; overflow: hidden;
} }


#postsbydate tbody .blogcolumn { .bydate tbody .blogcolumn {
width: 30ex; width: 30ex;
font-size: 80%; font-size: 80%;
text-align: left; text-align: left;
} }


#postbydate tbody .postcolumn { .bydate tbody .postcolumn {
text-align: left; text-align: left;
width: 50ex; width: 50ex;
} }


#postsbydate a { .bydate a {
text-decoration: none; text-decoration: none;
} }


#postsbydate .postcolumn a { .bydate .postcolumn a {
font-size: 90%; font-size: 90%;
color: black; color: black;
} }
Expand Down Expand Up @@ -361,7 +364,11 @@ background-color:black;
-webkit-box-shadow: 4px 4px 7px black; -webkit-box-shadow: 4px 4px 7px black;
border: 1px solid gray; border: 1px solid gray;
padding: 18px 18px 18px 18px; padding: 18px 18px 18px 18px;
<<<<<<< HEAD
margin: 10px 10px 30px 10px;
=======
margin: 10px 10px 50px 10px; margin: 10px 10px 50px 10px;
>>>>>>> 1bb0d5aa9e26b8ac4f90bbc4ede5fe9b3bc86ce2
} }


.planetbody, .planetbody h1, .planetbody h2, .planetbody h3, .planetbody h4 { .planetbody, .planetbody h1, .planetbody h2, .planetbody h3, .planetbody h4 {
Expand Down
4 changes: 2 additions & 2 deletions cron.yaml
@@ -1,4 +1,4 @@
cron: cron:
- description: check for feed updates - description: check for feed updates
url: /fetchall url: /allworker
schedule: every 3 hours schedule: every 2 hours
2 changes: 1 addition & 1 deletion database.tmpl
@@ -1,4 +1,4 @@
title, homepage, person, category, url, comments, priority, subject, favicon title, homepage, person, category, url, comments, priority, subject, favicon
#for $feed in $qf.get().order("categoyr") #for $feed in $qf.get().order("category")
"<%=feed.title%>",<%=feed.homepage%>,<%=feed.person%>,<%=feed.category%>,<%=feed.url%>,<%=feed.comments%>,<%=feed.priority%>,<%=feed.subject%>,<%=feed.favicon%> "<%=feed.title%>",<%=feed.homepage%>,<%=feed.person%>,<%=feed.category%>,<%=feed.url%>,<%=feed.comments%>,<%=feed.priority%>,<%=feed.subject%>,<%=feed.favicon%>
#end for #end for
8 changes: 0 additions & 8 deletions faq.html

This file was deleted.

0 comments on commit 289d3ce

Please sign in to comment.