Gossamer Forum
Home : Products : Gossamer Links : Discussions :

Links needing change

Quote Reply
Links needing change
Hi,

Anyone have global for counting modified links that need to be validated?


Thanks in advance
Quote Reply
Re: [rascal] Links needing change In reply to
You just need to count the Changes table like so:

Code:

sub {

return $DB->table('Changes')->select('COUNT(*)');

}

- Jonathan
Quote Reply
Re: [jdgamble] Links needing change In reply to
or (shorthand):

Code:
sub {
return $DB->table('Changes')->count();
}

Philip
------------------
Limecat is not pleased.
Quote Reply
Re: [fuzzy logic] Links needing change In reply to
Thank you both!

Could I just have it for the linkowner?
Quote Reply
Re: [rascal] Links needing change In reply to
Code:
sub {
my $user = shift;
return $DB->table("Changes")->count({ LinkOwner => $user });
}

might need to have:
Code:
->fetchrow()

Philip
------------------
Limecat is not pleased.

Last edited by:

fuzzy logic: Sep 27, 2006, 11:12 PM
Quote Reply
Re: [fuzzy logic] Links needing change In reply to
Tryed neither worked.
sub {
my $user = shift;
return $DB->table("Changes")->count({ LinkOwner => $user });
}

sub {
my $user = shift;
return $DB->table("Changes")->count({ LinkOwner => $user })->fetchrow();
}
Quote Reply
Re: [rascal] Links needing change In reply to
in the global call, are you using something like:

<%global($LinkOwner)%>

Philip
------------------
Limecat is not pleased.
Quote Reply
Re: [fuzzy logic] Links needing change In reply to
Just checked Changes.def... need to use

count({ Username => $user })

Philip
------------------
Limecat is not pleased.
Quote Reply
Re: [fuzzy logic] Links needing change In reply to
Thank you,

It does work, forgot to change Linkowner to Username on display page.

Last edited by:

rascal: Sep 28, 2006, 9:46 AM