Skip to content

Commit

Permalink
Prepare for release
Browse files Browse the repository at this point in the history
  • Loading branch information
marcus committed Nov 12, 2007
1 parent 47c8322 commit 1b31f74
Show file tree
Hide file tree
Showing 9 changed files with 23 additions and 19 deletions.
8 changes: 7 additions & 1 deletion Changes
@@ -1,7 +1,13 @@
0.999006 2007-09-24 00:01:00
0.999008 2007-11-12 22:43:00
- Fix ajax for tagging
- Fix tag galleries
- Fix ajax for user activation.

0.999007 2007-09-24 00:01:00
- Really fix deploy script for mysql
- Fix deploy script for pg.
- Refactor test data so it only exists once.
- Updated main class POD (removed developer docs and added to description)

0.999006 2007-09-23 12:12:00
- Fix deploy script to work with mysql constraints
Expand Down
2 changes: 1 addition & 1 deletion META.yml
Expand Up @@ -69,4 +69,4 @@ requires:
XML::Clean: 0
YAML: 0.36
tests: t/01app.t t/02pod.t t/03podcoverage.t t/formatter_comment.t t/formatter_irclog.t t/formatter_wiki.t t/schema_DBIC.t t/schema_DBIC_Attachment.t t/schema_DBIC_Content.t t/schema_DBIC_Page.t t/schema_DBIC_Person.t t/schema_DBIC_Tag.t t/c/attachment.t t/c/comment.t t/c/journal.t t/c/jsrpc.t t/c/page.t t/c/page_edit.t t/c/user.t
version: 0.999006
version: 0.999007
4 changes: 2 additions & 2 deletions lib/MojoMojo.pm
Expand Up @@ -6,7 +6,7 @@ use Path::Class 'file';

use Catalyst qw/ Authentication
Cache::FileCache Email
FillInForm FormValidator
FillInForm FormValidator
Session Session::Store::File
Singleton Session::State::Cookie
Static::Simple SubRequest
Expand All @@ -21,7 +21,7 @@ use Module::Pluggable::Ordered
except => qr/^MojoMojo::Plugin::/,
require => 1;

our $VERSION='0.999007';
our $VERSION='0.999008';

MojoMojo->config->{authentication}{dbic} = {
user_class => 'DBIC::Person',
Expand Down
11 changes: 5 additions & 6 deletions lib/MojoMojo/Controller/Admin.pm
Expand Up @@ -99,8 +99,6 @@ User listing with pager, for enabling/disabling users.

sub user : Local {
my ( $self, $c, $user ) = @_;
$c->forward('update_user') if $user;
$c->stash->{template}='settings/user.tt';
my $iterator =$c->model("DBIC::Person")->search(
{}, {
page =>$c->req->param('page') || 1,
Expand All @@ -117,13 +115,14 @@ Update user based on user listing.
=cut

sub update_user : Private {
my ( $self, $c, $user, $action ) = @_;
sub update_user : Local {
my ( $self, $c, $user ) = @_;
$user=$c->model("DBIC::Person")->find($user) || return;
if ($action eq 'active') {
# if ($action eq 'active') {
$user->active(! $user->active);
}
# }
$user->update;
$c->stash->{user}=$user;
}

=back
Expand Down
2 changes: 1 addition & 1 deletion lib/MojoMojo/Controller/Gallery.pm
Expand Up @@ -59,7 +59,7 @@ sub by_tag : Local {
unless length($c->stash->{page}->path) == 1; # root
$c->stash->{pictures} =$c->model("DBIC::Photo")->search(
$conditions, {
join => [qw/attachment/],
join => [qw/attachment tags/],
page => $page || 1,
rows => 12,
order_by => 'taken DESC'
Expand Down
1 change: 1 addition & 0 deletions lib/MojoMojo/View/TT.pm
Expand Up @@ -9,6 +9,7 @@ use Template::Constants qw( :debug );
__PACKAGE__->config->{PRE_CHOMP} = 2;
__PACKAGE__->config->{POST_CHOMP} = 2;
__PACKAGE__->config->{CONTEXT} = undef;
__PACKAGE__->config(TEMPLATE_EXTENSION => '.tt');

1;

Expand Down
1 change: 1 addition & 0 deletions root/base/admin/update_user.tt
@@ -0,0 +1 @@
[% user.active || '0' %]
6 changes: 4 additions & 2 deletions root/base/settings/user.tt → root/base/admin/user.tt
Expand Up @@ -11,9 +11,11 @@
<th>Active</th><th>login</th><th>&nbsp;</th><th>name</th><th>email</th>
[%WHILE (user=users.next) %]
<tr>
[%activeurl=base _ "/.admin/user/" _ user.id _ "/active"%]
[%activeurl=base _ "/.admin/update_user/" _ user.id _ '/active' %]
[%active=user.active || 0%]
<td><span id="active[%user.id%]">[%c.prototype.link_to_remote(active ,{url=>activeurl,update=>"active$user"})%]</a></span></td>
<td>
<a href="[%activeurl%]" onclick=" new Ajax.Updater( 'active_[%user.id%]', '[%activeurl%]', { asynchronous: 1 } ) ; return false">
<span id="active_[%user.id%]">[%active%]</span></a></td>
<td><a href="[%base%][%user.link%].profile">[%user.login%]</a></td>
<td>&nbsp;</td>
<td>[%user.name%]</td>
Expand Down
7 changes: 1 addition & 6 deletions root/base/page/bottomnav.tt
Expand Up @@ -2,12 +2,7 @@
[% IF user %]
<div id="showtag" class="showdiv"><a title="Set a keyword for this page" href="#" onclick="javascript:Element.show('addtag');Element.hide('showtag');Field.focus('taginput');return false;">add tag</a></div>
<div id="addtag" style="display:none;" class="formdiv">
[%c.prototype.form_remote_tag({
update => 'tags',
url=>c.uri_for('jsrpc/submittag'),
loading=>"Element.hide('addtag');Element.show('showtag');\$('taginput').value=''",
complete=>"Fat.fade('.highlight');"
})%]
<form action="[%c.uri_for('jsrpc/submittag')%]" method="post" onsubmit=" new Ajax.Updater( 'tags', '[%c.uri_for('jsrpc/submittag')%]', { parameters: Form.serialize(this),asynchronous: 1,onLoading: function(request){Element.hide('addtag');Element.show('showtag');$('taginput').value=''},onComplete: function(request){Fat.fade('.highlight');} } ) ; return false">
<input id="taginput" type="text" name="tag" width="5" autocomplete="off">
<input class="addbutton" type="submit" name="add" value="+">
</form>
Expand Down

0 comments on commit 1b31f74

Please sign in to comment.