# HG changeset patch # User HIROSE Yuuji # Date 1477036143 -32374 # Node ID d89412dc78a140472faa96e05249501f5f364086 # Parent 5e56160ad1f5f7686ffebf6c515da6991f626eee List recent subscriptions in other user's home diff -r 5e56160ad1f5 -r d89412dc78a1 s4-funcs.sh --- a/s4-funcs.sh Fri Oct 21 16:26:52 2016 +0859 +++ b/s4-funcs.sh Fri Oct 21 16:48:37 2016 +0859 @@ -1633,13 +1633,12 @@ #Calling listgroupbytable, originally here ( - if [ x"$user" = x"$uname" ]; then - # Display Most Recent Entry - shortval=${dumpcollen:+"substr(val, 0, $dumpcollen)"} - shortval=${shortval:-val} + # Display Most Recent Entry + shortval=${dumpcollen:+"substr(val, 0, $dumpcollen)"} + shortval=${shortval:-val} - # The m.aid in the next line is suspicious. But works fine in SQLite3... - DT_SQL="SELECT b.rowid || '#' || m.aid LINK, + # The m.aid in the next line is suspicious. But works fine in SQLite3... + DT_SQL="SELECT b.rowid || '#' || m.aid LINK, ctime, (SELECT $shortval FROM blog_s WHERE key='title' AND id=b.id) title, (SELECT gecos FROM gecoses @@ -1650,12 +1649,12 @@ JOIN (SELECT distinct blogid, a.id aid, max(val) ctime FROM article a, article_s s - ON a.id=s.id AND a.author='$user' AND s.key='ctime' + ON a.id=s.id AND a.author='$uname' AND s.key='ctime' GROUP BY blogid ORDER BY val DESC LIMIT 50 ) m ON b.id=m.blogid;" - # This should be as follows - : <最近の書き込み先
`DT_VIEW=replyblog dumptable html blog`
EOF - unset DT_SQL + unset DT_SQL + if [ x"$user" = x"$uname" ]; then # Display NEWS if false; then cond="where 新着 > 0 order by 新着 desc,ctime desc limit 10" @@ -1710,6 +1710,8 @@ echo "$new10 " echo "" fi + else # Not My Home ($user != $uname) + # DT_SQL= fi ) > $hometail & # Is background call safe to m4?? #