Only show local public notices in sitemap

Only show local public notices in sitemap. Only do counts for them
in the sitemap index, and only show them in the notice sitemap.
This commit is contained in:
Evan Prodromou 2010-06-04 15:47:26 -04:00
parent 6d39a75137
commit 3a34d7e4ea
2 changed files with 2 additions and 1 deletions

View File

@ -208,6 +208,7 @@ class Sitemap_notice_count extends Memcached_DataObject
{
$notice = new Notice();
$notice->whereAdd('created BETWEEN "'.$d.' 00:00:00" AND "'.self::incrementDay($d).' 00:00:00"');
$notice->whereAdd('is_local = ' . Notice::LOCAL_PUBLIC);
$n = $notice->count();
return $n;

View File

@ -105,7 +105,7 @@ class NoticesitemapAction extends SitemapAction
$notice->whereAdd("created >= '$begindt'");
$notice->whereAdd("created < '$enddt'");
$notice->whereAdd('is_local != 0');
$notice->whereAdd('is_local = ' . Notice::LOCAL_PUBLIC);
$notice->orderBy('created');