]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
define undefined, order subs
authorEvan Prodromou <evan@prodromou.name>
Wed, 21 May 2008 19:29:12 +0000 (15:29 -0400)
committerEvan Prodromou <evan@prodromou.name>
Wed, 21 May 2008 19:29:12 +0000 (15:29 -0400)
darcs-hash:20080521192912-84dde-4bea2a463bfb357b5688e0f8faccac622770ac95.gz

actions/subscribed.php
actions/subscriptions.php

index e8df331ee67388905e3a60aab5e3491a99121b78..634ca41022dd4e3faf5f8d068a653cd4546c7c4a 100644 (file)
 
 if (!defined('LACONICA')) { exit(1); }
 
+# XXX: make distinct from similar definitions in showstream.php
+
+define('SUBSCRIPTIONS_PER_ROW', 10);
+define('SUBSCRIPTIONS_PER_PAGE', 80);
+
 class SubscribedAction extends Action {
 
        # Who is subscribed to a given user?
@@ -47,6 +52,8 @@ class SubscribedAction extends Action {
                $subs = DB_DataObject::factory('subscription');
                $subs->subscribed = $profile->id;
 
+               $subs->orderBy('created DESC');
+
                # We ask for an extra one to know if we need to do another page
 
                $subs->limit((($page-1)*SUBSCRIPTIONS_PER_PAGE), SUBSCRIPTIONS_PER_PAGE + 1);
index 3ec7a0122000d26070a6068514e1f3a34c712300..51f35750c3ea7266a784fbf2d2de4f0aa89247f8 100644 (file)
 
 if (!defined('LACONICA')) { exit(1); }
 
+# XXX: make distinct from similar definitions in showstream.php
+
+define('SUBSCRIPTIONS_PER_ROW', 10);
+define('SUBSCRIPTIONS_PER_PAGE', 80);
+
 class SubscriptionsAction extends Action {
 
        function handle($args) {
@@ -43,6 +48,8 @@ class SubscriptionsAction extends Action {
                $subs = DB_DataObject::factory('subscription');
                $subs->subscriber = $profile->id;
 
+               $subs->orderBy('created DESC');
+
                # We ask for an extra one to know if we need to do another page
 
                $subs->limit((($page-1)*SUBSCRIPTIONS_PER_PAGE), SUBSCRIPTIONS_PER_PAGE + 1);