[Jifty-commit] r2233 - in jifty/branches/template-declare: .
lib/Jifty/Action/Record lib/Jifty/Manual plugins/AuthzLDAP
plugins/AuthzLDAP/lib/Jifty/Plugin
plugins/AuthzLDAP/lib/Jifty/Plugin/AuthzLDAP
plugins/AuthzLDAP/lib/Jifty/Plugin/AuthzLDAP/Action
plugins/AuthzLDAP/share/po
plugins/AuthzLDAP/share/web/templates/error plugins/AuthzLDAP/t
plugins/Login/lib/Jifty/Plugin/Login/Action
plugins/Login/lib/Jifty/Plugin/Login/Model share/po
share/web/static/js/yui share/web/templates/__jifty
jifty-commit at lists.jifty.org
jifty-commit at lists.jifty.org
Thu Nov 30 21:32:49 EST 2006
Author: audreyt
Date: Thu Nov 30 21:32:48 2006
New Revision: 2233
Added:
jifty/branches/template-declare/plugins/AuthzLDAP/MANIFEST
jifty/branches/template-declare/plugins/AuthzLDAP/share/po/en.po
jifty/branches/template-declare/plugins/AuthzLDAP/share/po/fr.po
jifty/branches/template-declare/plugins/AuthzLDAP/share/web/templates/error/
jifty/branches/template-declare/plugins/AuthzLDAP/share/web/templates/error/AccessDenied
jifty/branches/template-declare/plugins/AuthzLDAP/t/00-load.t
jifty/branches/template-declare/share/po/zh_cn.po
jifty/branches/template-declare/share/po/zh_tw.po
Removed:
jifty/branches/template-declare/plugins/AuthzLDAP/lib/Jifty/Plugin/AuthzLDAP/Dispatcher.pm
Modified:
jifty/branches/template-declare/ (props changed)
jifty/branches/template-declare/AUTHORS
jifty/branches/template-declare/lib/Jifty/Action/Record/Search.pm
jifty/branches/template-declare/lib/Jifty/DateTime.pm
jifty/branches/template-declare/lib/Jifty/Manual/Actions.pod
jifty/branches/template-declare/lib/Jifty/Manual/Tutorial.pod
jifty/branches/template-declare/plugins/AuthzLDAP/lib/Jifty/Plugin/AuthzLDAP.pm
jifty/branches/template-declare/plugins/AuthzLDAP/lib/Jifty/Plugin/AuthzLDAP/Action/LDAPValidate.pm
jifty/branches/template-declare/plugins/Login/lib/Jifty/Plugin/Login/Action/Signup.pm
jifty/branches/template-declare/plugins/Login/lib/Jifty/Plugin/Login/Model/User.pm
jifty/branches/template-declare/share/web/static/js/yui/calendar.js
jifty/branches/template-declare/share/web/templates/__jifty/validator.xml
Log:
* Merge down into template-declare branch.
Modified: jifty/branches/template-declare/AUTHORS
==============================================================================
--- jifty/branches/template-declare/AUTHORS (original)
+++ jifty/branches/template-declare/AUTHORS Thu Nov 30 21:32:48 2006
@@ -19,3 +19,4 @@
Paul Fenwick <pjf at perltraining.com.au>
Edmund von der Burg <evdb at ecclestoad.co.uk>
Yves Agostini <agostini at univ-metz.fr>
+Agent Zhang <agentzh at gmail.com>
Modified: jifty/branches/template-declare/lib/Jifty/Action/Record/Search.pm
==============================================================================
--- jifty/branches/template-declare/lib/Jifty/Action/Record/Search.pm (original)
+++ jifty/branches/template-declare/lib/Jifty/Action/Record/Search.pm Thu Nov 30 21:32:48 2006
@@ -30,7 +30,7 @@
=over 4
-=item C<text> or C<varchar> fields
+=item C<text>, C<char> or C<varchar> fields
Create C<field>_contains and C<field>_lacks arguments
@@ -38,7 +38,7 @@
Create C<field>_before and C<field>_after arguments
-=item integer fields
+=item C<integer>, C<float> or C<double> fields
Generate C<field>_lt and C<field>_gt arguments
@@ -87,14 +87,15 @@
my $label = $info->{label} || $field;
$args->{"${field}_not"} = {%$info, label => "$label is not"};
- if($column->type =~ /^(?:text|varchar)/i) {
+ my $type = lc($column->type);
+ if($type =~ /(?:text|char)/) {
$info->{render_as} = 'text';
$args->{"${field}_contains"} = {%$info, label => "$label contains"};
$args->{"${field}_lacks"} = {%$info, label => "$label lacks"};
- } elsif($column->type =~ /(?:date|time)/) {
+ } elsif($type =~ /(?:date|time)/) {
$args->{"${field}_after"} = {%$info, label => "$label after"};
$args->{"${field}_before"} = {%$info, label => "$label before"};
- } elsif( $column->type =~ /(?:int)/
+ } elsif( $type =~ /(?:int|float|double)/
&& !$column->refers_to) {
$args->{"${field}_gt"} = {%$info, label => "$label greater than"};
$args->{"${field}_lt"} = {%$info, label => "$label less than"};
Modified: jifty/branches/template-declare/lib/Jifty/DateTime.pm
==============================================================================
--- jifty/branches/template-declare/lib/Jifty/DateTime.pm (original)
+++ jifty/branches/template-declare/lib/Jifty/DateTime.pm Thu Nov 30 21:32:48 2006
@@ -36,7 +36,7 @@
# Unless the user has explicitly said they want a floating time,
# we want to convert to the end-user's timezone. This is
# complicated by the fact that DateTime auto-appends
- if (my $tz = $self->current_user_has_timezone) {
+ if (!$args{time_zone} and my $tz = $self->current_user_has_timezone) {
$self->set_time_zone("UTC");
$self->set_time_zone( $tz );
}
Modified: jifty/branches/template-declare/lib/Jifty/Manual/Actions.pod
==============================================================================
--- jifty/branches/template-declare/lib/Jifty/Manual/Actions.pod (original)
+++ jifty/branches/template-declare/lib/Jifty/Manual/Actions.pod Thu Nov 30 21:32:48 2006
@@ -244,8 +244,29 @@
$self->result->content( id => $new_post->id);
This information can be then used elsewhere to, for example,
-automatically redirect you to a view page for that new blog post. See
-L<Jifty::Request::Mapper> for some more information.
+automatically redirect you to a view page for that new blog post. The
+view page template may have the following piece of code in it:
+
+ <%args>
+ $id => undef
+ </%args>
+ <%init>
+ my $result = Jifty->web->response->result('post_blog');
+ $id = $result->content('id') if $result and !defined $id;
+ # load the record by $id and other stuff go here...
+ </%init>
+
+where C<'post_blog'> is the moniker for your post page action object.
+In fact, that's exactly how actions "return" values to other templates
+in your application.
+
+It should also be mentioned that the response object is "per request". That is,
+it usually can't live up to another user request. Therefore, when paging mechanism
+is applied to your view page, for example, you have to either pass some data
+to the link constructor or explicitly tell Jifty to preserve states for you.
+
+See L</monikers>, the Jifty Pony site's source, and L<Jifty::Request::Mapper> for some
+more information.
=head2 USING ACTIONS
Modified: jifty/branches/template-declare/lib/Jifty/Manual/Tutorial.pod
==============================================================================
--- jifty/branches/template-declare/lib/Jifty/Manual/Tutorial.pod (original)
+++ jifty/branches/template-declare/lib/Jifty/Manual/Tutorial.pod Thu Nov 30 21:32:48 2006
@@ -261,6 +261,11 @@
# ./bin/jifty server
INFO - You can connect to your server at http://localhost:8888/
+Please always run this command at the root directory of your Jifty applications,
+or you'll be caught by a lot of errors.
+
+For many platforms, a simple "jifty server" command works too. :)
+
=head2 Building a user interface
The administrative web does give you everything you need to work with your
@@ -275,10 +280,10 @@
Open a new file called F<post> in your text editor. Make it look like this:
<%init>
- my $action = Jifty->web->new_action(class =>'CreatePost');
+ my $action = Jifty->web->new_action(class => 'CreatePost');
</%init>
- <&|/_elements/wrapper, title => "Post to your weblog" &>
+ <&| /_elements/wrapper, title => "Post to your weblog" &>
<% Jifty->web->form->start() %>
<% Jifty->web->form->next_page( url => '/') %>
<% $action->form_field('title') %>
@@ -287,6 +292,9 @@
<% Jifty->web->form->end() %>
</&>
+Yes, it's a template file in L<HTML::Mason> syntax. If you're not familiar with Mason,
+we recommend you to consult its online documentation for details.
+
=head3 Viewing
It's really easy to get a I<basic> listing of entries and a little bit more
@@ -308,18 +316,17 @@
$posts->unlimit();
</%init>
- <&|/_elements/wrapper, title => Jifty->config->framework('ApplicationName') &>
+ <&| /_elements/wrapper, title => Jifty->config->framework('ApplicationName') &>
<dl>
% while (my $post = $posts->next) {
- <dt><%$post->title%></dt>
- <dd><%$post->body%></dd>
+ <dt><% $post->title %></dt>
+ <dd><% $post->body %></dd>
% }
</dl>
</&>
(Make sure to remove that leading whitespace!)
-
=head4 The complex way that gets you lots of cool toys
The I<complex way> involves using one of Jifty's advanced features: I<Page
@@ -334,7 +341,7 @@
The complex way starts off about the same as the easy way. Open a new file
called F<share/web/templates/index.html> in your text editor. Fill it with this:
- <&|/_elements/wrapper, title => Jifty->config->framework('ApplicationName') &>
+ <&| /_elements/wrapper, title => Jifty->config->framework('ApplicationName') &>
<% Jifty->web->region(name => "myweblog-posts",
path => "/fragments/page_of_posts") %>
@@ -360,8 +367,8 @@
% }
<dl class="list">
% while (my $post = $posts->next) {
- <dt><%$post->title%></dt>
- <dd><%$post->body%></dd>
+ <dt><% $post->title %></dt>
+ <dd><% $post->body %></dd>
% }
</dl>
@@ -482,6 +489,8 @@
=item * Continuations in depth
+=item * Customized view (user-defined wrappers and css)
+
=back
=cut
Added: jifty/branches/template-declare/plugins/AuthzLDAP/MANIFEST
==============================================================================
--- (empty file)
+++ jifty/branches/template-declare/plugins/AuthzLDAP/MANIFEST Thu Nov 30 21:32:48 2006
@@ -0,0 +1,9 @@
+lib/Jifty/Plugin/AuthzLDAP.pm
+lib/Jifty/Plugin/AuthzLDAP/Action/LDAPValidate.pm
+lib/Jifty/Plugin/AuthzLDAP/Model/LDAPFilter.pm
+Makefile.PL
+MANIFEST
+share/po/en.po
+share/po/fr.po
+share/web/templates/error/AccessDenied
+t/00-load.t
Modified: jifty/branches/template-declare/plugins/AuthzLDAP/lib/Jifty/Plugin/AuthzLDAP.pm
==============================================================================
--- jifty/branches/template-declare/plugins/AuthzLDAP/lib/Jifty/Plugin/AuthzLDAP.pm (original)
+++ jifty/branches/template-declare/plugins/AuthzLDAP/lib/Jifty/Plugin/AuthzLDAP.pm Thu Nov 30 21:32:48 2006
@@ -28,6 +28,32 @@
in application create a LDAPFilter model
use base qw/Jifty::Plugin::AuthzLDAP::Model::LDAPFilter/;
+in LDAPFilter model create your filters, something like
+ name |filter |is_group
+ is_admin|(!eduPersonAffiliation=STUDENT)|0
+ in_admin|cn=admin,ou=groups,dc=my.org |1
+
+to protect access to /admin
+in "TestApp" application create a lib/TestApp/Dispatcher.pm
+
+ use strict;
+ use warnings;
+
+ package TestApp::Dispatcher;
+ use Jifty::Dispatcher -base;
+
+ before '/admin/*' => run {
+ # Authentication
+ Jifty->web->tangent(url => '/login')
+ if (! Jifty->web->current_user->id);
+ # Authorization
+ my $user = Jifty->web->current_user->user_object->name;
+ Jifty->web->tangent(url => '/error/AccessDenied')
+ if (! Jifty::Plugin::AuthzLDAP->ldapvalidate($user,'is_admin') );
+ };
+
+ 1
+
=head1 SEE ALSO
L<Net::LDAP>
@@ -131,7 +157,8 @@
# (?) allow use of writing filter in filtername
# TODO: filtername must be cleanned
- my $filter = ($record->filter)?$record->filter:$filtername;
+ # my $filter = ($record->filter)?$record->filter:$filtername;
+ my $filter = $record->filter;
$user = $self->UID().'='.$user.','.$self->BASE();
Modified: jifty/branches/template-declare/plugins/AuthzLDAP/lib/Jifty/Plugin/AuthzLDAP/Action/LDAPValidate.pm
==============================================================================
--- jifty/branches/template-declare/plugins/AuthzLDAP/lib/Jifty/Plugin/AuthzLDAP/Action/LDAPValidate.pm (original)
+++ jifty/branches/template-declare/plugins/AuthzLDAP/lib/Jifty/Plugin/AuthzLDAP/Action/LDAPValidate.pm Thu Nov 30 21:32:48 2006
@@ -57,7 +57,7 @@
if (not $msg) {
$self->result->error(
- _('Access not allowed') );
+ _('Access denied.') );
return;}
return 1;
Added: jifty/branches/template-declare/plugins/AuthzLDAP/share/po/en.po
==============================================================================
--- (empty file)
+++ jifty/branches/template-declare/plugins/AuthzLDAP/share/po/en.po Thu Nov 30 21:32:48 2006
@@ -0,0 +1,20 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
+# This file is distributed under the same license as the PACKAGE package.
+# FIRST AUTHOR <EMAIL at ADDRESS>, YEAR.
+#
+#, fuzzy
+msgid ""
+msgstr ""
+"Project-Id-Version: PACKAGE VERSION\n"
+"POT-Creation-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"Last-Translator: FULL NAME <EMAIL at ADDRESS>\n"
+"Language-Team: LANGUAGE <LL at li.org>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=CHARSET\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+#: lib/Jifty/Plugin/AuthzLDAP/Action/LDAPValidate.pm:60 share/web/templates/error/AccessDenied:1 share/web/templates/error/AccessDenied:2
+msgid "Access denied."
+msgstr ""
Added: jifty/branches/template-declare/plugins/AuthzLDAP/share/po/fr.po
==============================================================================
--- (empty file)
+++ jifty/branches/template-declare/plugins/AuthzLDAP/share/po/fr.po Thu Nov 30 21:32:48 2006
@@ -0,0 +1,20 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
+# This file is distributed under the same license as the PACKAGE package.
+# FIRST AUTHOR <EMAIL at ADDRESS>, YEAR.
+#
+#, fuzzy
+msgid ""
+msgstr ""
+"Project-Id-Version: PACKAGE VERSION\n"
+"POT-Creation-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"Last-Translator: FULL NAME <EMAIL at ADDRESS>\n"
+"Language-Team: LANGUAGE <LL at li.org>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=ISO8859-15\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+#: lib/Jifty/Plugin/AuthzLDAP/Action/LDAPValidate.pm:60 share/web/templates/error/AccessDenied:1 share/web/templates/error/AccessDenied:2
+msgid "Access denied."
+msgstr "Accès non autorisé."
Added: jifty/branches/template-declare/plugins/AuthzLDAP/share/web/templates/error/AccessDenied
==============================================================================
--- (empty file)
+++ jifty/branches/template-declare/plugins/AuthzLDAP/share/web/templates/error/AccessDenied Thu Nov 30 21:32:48 2006
@@ -0,0 +1,3 @@
+<&| /_elements/wrapper, title => _("Access denied.") &>
+<p><% _("Access denied.") %></p>
+</&>
Added: jifty/branches/template-declare/plugins/AuthzLDAP/t/00-load.t
==============================================================================
--- (empty file)
+++ jifty/branches/template-declare/plugins/AuthzLDAP/t/00-load.t Thu Nov 30 21:32:48 2006
@@ -0,0 +1,5 @@
+#!/usr/bin/env perl -w
+use strict;
+use Test::More tests => 1;
+
+use_ok('Jifty::Plugin::AuthzLDAP');
Modified: jifty/branches/template-declare/plugins/Login/lib/Jifty/Plugin/Login/Action/Signup.pm
==============================================================================
--- jifty/branches/template-declare/plugins/Login/lib/Jifty/Plugin/Login/Action/Signup.pm (original)
+++ jifty/branches/template-declare/plugins/Login/lib/Jifty/Plugin/Login/Action/Signup.pm Thu Nov 30 21:32:48 2006
@@ -39,7 +39,6 @@
password_confirm => 1,
);
- for ( keys %$args ) { delete $args->{$_} unless ( $fields{$_} ); }
$args->{'email'}{'ajax_validates'} = 1;
$args->{'password_confirm'}{'label'} = _("Type that again?");
$args->{'name'}{'label'} = _("Name");
Modified: jifty/branches/template-declare/plugins/Login/lib/Jifty/Plugin/Login/Model/User.pm
==============================================================================
--- jifty/branches/template-declare/plugins/Login/lib/Jifty/Plugin/Login/Model/User.pm (original)
+++ jifty/branches/template-declare/plugins/Login/lib/Jifty/Plugin/Login/Model/User.pm Thu Nov 30 21:32:48 2006
@@ -21,11 +21,12 @@
column
email_confirmed => label is 'Email address confirmed?',
- type is 'boolean';
+ type is 'boolean',
+ render_as 'Unrendered';
column
auth_token => type is 'text',
- render_as 'Password';
+ render_as 'Unrendered';
package Jifty::Plugin::Login::Model::User;
use base qw/Jifty::Record/;
Added: jifty/branches/template-declare/share/po/zh_cn.po
==============================================================================
--- (empty file)
+++ jifty/branches/template-declare/share/po/zh_cn.po Thu Nov 30 21:32:48 2006
@@ -0,0 +1,151 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
+# This file is distributed under the same license as the PACKAGE package.
+# FIRST AUTHOR <EMAIL at ADDRESS>, YEAR.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PACKAGE VERSION\n"
+"POT-Creation-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"Last-Translator: Audrey Tang <audreyt at audreyt.org>\n"
+"Language-Team: simplified Chinese\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+#. ($_->[3])
+#: share/web/templates/__jifty/halo:119
+msgid "%1 seconds"
+msgstr "%1 ç§"
+
+#: share/web/templates/__jifty/admin/index.html:49
+msgid "Actions"
+msgstr "æä½"
+
+#: share/web/templates/_elements/wrapper:11
+msgid "Administration mode is enabled."
+msgstr "ç³»ç»ç®¡ç模å¼å¼å¯ä¸."
+
+#: share/web/templates/_elements/wrapper:11
+msgid "Alert"
+msgstr "请注æ"
+
+#: lib/Jifty/Action/Record/Create.pm:74 lib/Jifty/Action/Record/Create.pm~:74
+msgid "An error occurred. Try again later"
+msgstr "ç³»ç»æ æ³æ§è¡æ¤é¡¹æä½, 请ç¨ååè¯"
+
+#: share/web/templates/helpers/calendar.html:4
+msgid "Close window"
+msgstr "å
³éçªå£"
+
+#. (ref($record)
+#: lib/Jifty/Action/Record/Create.pm:75 lib/Jifty/Action/Record/Create.pm~:75
+msgid "Create of %1 failed: %2"
+msgstr "æ æ³å»ºç« %1: %2"
+
+#: lib/Jifty/Action/Record/Create.pm:97 lib/Jifty/Action/Record/Create.pm~:97
+msgid "Created"
+msgstr "æå建ç«é¡¹ç®."
+
+#: share/web/templates/__jifty/admin/index.html:34
+msgid "Database Administration"
+msgstr "æ°æ®ç¤ç®¡ç"
+
+#: lib/Jifty/Action/Record/Delete.pm:75
+msgid "Deleted"
+msgstr "æåå é¤é¡¹ç®."
+
+#: lib/Jifty/Web.pm:769 lib/Jifty/Web.pm~:768
+msgid "Dismiss"
+msgstr "å
³é"
+
+#. ($comp_name)
+#: lib/Jifty/Mason/Halo.pm:104
+msgid "Edit %1"
+msgstr "ç¼è¾ %1"
+
+#: share/web/templates/dhandler:7
+msgid "Go back home..."
+msgstr "åé¦é¡µ..."
+
+#. (Jifty->web->current_user->user_object->name)
+#: share/web/templates/_elements/sidebar:3
+msgid "Hiya, %1."
+msgstr "%1 æ¨å¥½."
+
+#: share/web/templates/__jifty/online_docs/toc.html:6
+msgid "Jifty Developer Documentation Online"
+msgstr "Jifty 线ä¸å¼åæ件"
+
+#: share/web/templates/__jifty/online_docs/content.html:6
+msgid "Jifty Pod Online"
+msgstr "Jifty çº¿ä¸ POD æ件"
+
+#: share/web/templates/_elements/wrapper:18
+msgid "Loading..."
+msgstr "请ç¨å..."
+
+#: share/web/templates/__jifty/admin/index.html:40
+msgid "Models"
+msgstr "模å"
+
+#: lib/Jifty/Web.pm:273 lib/Jifty/Web.pm~:273
+msgid "No request to handle"
+msgstr "没æå¯å¤ççè¦æ±"
+
+#: share/web/templates/__jifty/online_docs/index.html:5
+msgid "Online Documentation"
+msgstr "线ä¸æ件"
+
+#: lib/Jifty/Record.pm:223 lib/Jifty/Record.pm:282 lib/Jifty/Record.pm:61
+msgid "Permission denied"
+msgstr "æéä¸è¶³."
+
+#: lib/Jifty/Record.pm:84
+msgid "Record created"
+msgstr "æå建ç«é¡¹ç®."
+
+#: share/web/templates/__jifty/halo:111
+msgid "SQL Statements"
+msgstr "SQL éè¿°å¼"
+
+#: share/web/templates/__jifty/online_docs/content.html:50
+msgid "Schema"
+msgstr "纲è¦"
+
+#: share/web/templates/dhandler:1
+msgid "Something's not quite right"
+msgstr "ç³»ç»é误"
+
+#: share/web/templates/__jifty/online_docs/index.html:16
+#: share/web/templates/__jifty/online_docs/index.html:18
+msgid "Table of Contents"
+msgstr "ç®å½"
+
+#: share/web/templates/__jifty/admin/index.html:36
+msgid ""
+"This console lets you manage the records in your Jifty database. Below, you "
+"should see a list of all your database tables. Feel free to go through and "
+"add, delete or modify records."
+msgstr "æ¨å¯å©ç¨æ¤çé¢æ¥ç®¡çæ°æ®åºçå
容. 请ç¹éè¡¨æ ¼å称, è¿è¡å¢å åç¼è¾."
+
+#: lib/Jifty/Action/Record/Update.pm:152
+msgid "Updated"
+msgstr "æåæ´æ°é¡¹ç®."
+
+#: share/web/templates/index.html:1
+msgid "Welcome to your new Jifty application"
+msgstr "欢è¿å
临æ¨å´æ°ç Jifty åºç¨ç¨åº"
+
+#: share/web/templates/dhandler:5
+msgid ""
+"You got to a page that we don't think exists. Anyway, the software has "
+"logged this error. Sorry about this."
+msgstr "æ±æ, æ¤é¡µé¢ä¸åå¨, ç³»ç»å·²çä¸çºªå½."
+
+#. ('http://hdl.loc.gov/loc.pnp/cph.3c13461')
+#: share/web/templates/index.html:3
+msgid "You said you wanted a pony. (Source %1)"
+msgstr "æ¨å¯ä¸æ£æ¯æ³è¦ä¸å¹å°é©¬å? (åè§ %1)"
+
Added: jifty/branches/template-declare/share/po/zh_tw.po
==============================================================================
--- (empty file)
+++ jifty/branches/template-declare/share/po/zh_tw.po Thu Nov 30 21:32:48 2006
@@ -0,0 +1,151 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
+# This file is distributed under the same license as the PACKAGE package.
+# FIRST AUTHOR <EMAIL at ADDRESS>, YEAR.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PACKAGE VERSION\n"
+"POT-Creation-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"Last-Translator: Audrey Tang <audreyt at audreyt.org>\n"
+"Language-Team: Traditional Chinese\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+#. ($_->[3])
+#: share/web/templates/__jifty/halo:119
+msgid "%1 seconds"
+msgstr "%1 ç§"
+
+#: share/web/templates/__jifty/admin/index.html:49
+msgid "Actions"
+msgstr "æä½"
+
+#: share/web/templates/_elements/wrapper:11
+msgid "Administration mode is enabled."
+msgstr "系統管ç模å¼éåä¸."
+
+#: share/web/templates/_elements/wrapper:11
+msgid "Alert"
+msgstr "è«æ³¨æ"
+
+#: lib/Jifty/Action/Record/Create.pm:74 lib/Jifty/Action/Record/Create.pm~:74
+msgid "An error occurred. Try again later"
+msgstr "系統ç¡æ³å·è¡æ¤é
æä½, è«ç¨å¾å試"
+
+#: share/web/templates/helpers/calendar.html:4
+msgid "Close window"
+msgstr "ééè¦çª"
+
+#. (ref($record)
+#: lib/Jifty/Action/Record/Create.pm:75 lib/Jifty/Action/Record/Create.pm~:75
+msgid "Create of %1 failed: %2"
+msgstr "ç¡æ³å»ºç« %1: %2"
+
+#: lib/Jifty/Action/Record/Create.pm:97 lib/Jifty/Action/Record/Create.pm~:97
+msgid "Created"
+msgstr "æå建ç«é
ç®."
+
+#: share/web/templates/__jifty/admin/index.html:34
+msgid "Database Administration"
+msgstr "è³æç¤ç®¡ç"
+
+#: lib/Jifty/Action/Record/Delete.pm:75
+msgid "Deleted"
+msgstr "æååªé¤é
ç®."
+
+#: lib/Jifty/Web.pm:769 lib/Jifty/Web.pm~:768
+msgid "Dismiss"
+msgstr "éé"
+
+#. ($comp_name)
+#: lib/Jifty/Mason/Halo.pm:104
+msgid "Edit %1"
+msgstr "編輯 %1"
+
+#: share/web/templates/dhandler:7
+msgid "Go back home..."
+msgstr "åé¦é ..."
+
+#. (Jifty->web->current_user->user_object->name)
+#: share/web/templates/_elements/sidebar:3
+msgid "Hiya, %1."
+msgstr "%1 æ¨å¥½."
+
+#: share/web/templates/__jifty/online_docs/toc.html:6
+msgid "Jifty Developer Documentation Online"
+msgstr "Jifty ç·ä¸éç¼æ件"
+
+#: share/web/templates/__jifty/online_docs/content.html:6
+msgid "Jifty Pod Online"
+msgstr "Jifty ç·ä¸ POD æ件"
+
+#: share/web/templates/_elements/wrapper:18
+msgid "Loading..."
+msgstr "è«ç¨å..."
+
+#: share/web/templates/__jifty/admin/index.html:40
+msgid "Models"
+msgstr "模å"
+
+#: lib/Jifty/Web.pm:273 lib/Jifty/Web.pm~:273
+msgid "No request to handle"
+msgstr "æ²æå¯èççè¦æ±"
+
+#: share/web/templates/__jifty/online_docs/index.html:5
+msgid "Online Documentation"
+msgstr "ç·ä¸æ件"
+
+#: lib/Jifty/Record.pm:223 lib/Jifty/Record.pm:282 lib/Jifty/Record.pm:61
+msgid "Permission denied"
+msgstr "æ¬éä¸è¶³."
+
+#: lib/Jifty/Record.pm:84
+msgid "Record created"
+msgstr "æå建ç«é
ç®."
+
+#: share/web/templates/__jifty/halo:111
+msgid "SQL Statements"
+msgstr "SQL é³è¿°å¼"
+
+#: share/web/templates/__jifty/online_docs/content.html:50
+msgid "Schema"
+msgstr "綱è¦"
+
+#: share/web/templates/dhandler:1
+msgid "Something's not quite right"
+msgstr "系統é¯èª¤"
+
+#: share/web/templates/__jifty/online_docs/index.html:16
+#: share/web/templates/__jifty/online_docs/index.html:18
+msgid "Table of Contents"
+msgstr "ç®é"
+
+#: share/web/templates/__jifty/admin/index.html:36
+msgid ""
+"This console lets you manage the records in your Jifty database. Below, you "
+"should see a list of all your database tables. Feel free to go through and "
+"add, delete or modify records."
+msgstr "æ¨å¯å©ç¨æ¤çé¢ä¾ç®¡çè³æ庫çå
§å®¹. è«é»é¸è¡¨æ ¼å稱, é²è¡å¢åªå編輯."
+
+#: lib/Jifty/Action/Record/Update.pm:152
+msgid "Updated"
+msgstr "æåæ´æ°é
ç®."
+
+#: share/web/templates/index.html:1
+msgid "Welcome to your new Jifty application"
+msgstr "æ¡è¿å
è¨æ¨å¶æ°ç Jifty æç¨ç¨å¼"
+
+#: share/web/templates/dhandler:5
+msgid ""
+"You got to a page that we don't think exists. Anyway, the software has "
+"logged this error. Sorry about this."
+msgstr "æ±æ, æ¤é é¢ä¸åå¨, 系統已çä¸ç´é."
+
+#. ('http://hdl.loc.gov/loc.pnp/cph.3c13461')
+#: share/web/templates/index.html:3
+msgid "You said you wanted a pony. (Source %1)"
+msgstr "æ¨å¯ä¸æ£æ¯æ³è¦ä¸å¹å°é¦¬å? (åè¦ %1)"
+
Modified: jifty/branches/template-declare/share/web/static/js/yui/calendar.js
==============================================================================
--- jifty/branches/template-declare/share/web/static/js/yui/calendar.js (original)
+++ jifty/branches/template-declare/share/web/static/js/yui/calendar.js Thu Nov 30 21:32:48 2006
@@ -3,6 +3,15 @@
Code licensed under the BSD License:
http://developer.yahoo.net/yui/license.txt
version: 0.10.0
+
+WARNING THIS IS NOT A STOCK RELEASE. IT HAS BEEN MODIFED FROM ITS ORIGINAL FORM:
+
+
+ renderCellNotThisMonth:
+ THIS FUNCTION MODIFIED BY JESSE VINCENT on 2006-11-29 TO MAKE OUT OF MONTH DATES CLICKABLE
+ ALL RIGHTS DISCLAIMED.
+
+
*/
/**
* @class
@@ -556,7 +565,10 @@
var d = cal.cellDates[index];
var date = new Date(d[0],d[1]-1,d[2]);
- if (! cal.isDateOOM(date) && ! YAHOO.util.Dom.hasClass(cell, cal.Style.CSS_CELL_RESTRICTED) && ! YAHOO.util.Dom.hasClass(cell, cal.Style.CSS_CELL_OOB)) {
+ /* if (! cal.isDateOOM(date) && ! YAHOO.util.Dom.hasClass(cell, cal.Style.CSS_CELL_RESTRICTED) && ! YAHOO.util.Dom.hasClass(cell, cal.Style.CSS_CELL_OOB)) { */
+ /* MODIFIED BY JESSE VINCENT ON 2006-11-29 TO ALLOW OOM DATES TO BE CLICKABLE*/
+
+ if ( ! YAHOO.util.Dom.hasClass(cell, cal.Style.CSS_CELL_RESTRICTED) && ! YAHOO.util.Dom.hasClass(cell, cal.Style.CSS_CELL_OOB)) {
if (cal.Options.MULTI_SELECT) {
var link = cell.getElementsByTagName("A")[0];
link.blur();
@@ -1369,8 +1381,20 @@
* @type String
*/
YAHOO.widget.Calendar_Core.prototype.renderCellNotThisMonth = function(workingDate, cell) {
+
+
+ /**** THIS FUNCTION MODIFIED BY JESSE VINCENT on 2006-11-29 TO MAKE OUT OF MONTH DATES CLICKABLE
+ ALL RIGHTS DISCLAIMED.
+ ****/
YAHOO.widget.Calendar_Core.addCssClass(cell, this.Style.CSS_CELL_OOM);
- cell.innerHTML=workingDate.getDate();
+ cell.innerHTML = "";
+ var link = document.createElement("a");
+
+ link.href="javascript:void(null);";
+ link.name=this.id+"__"+workingDate.getFullYear()+"_"+(workingDate.getMonth()+1)+"_"+workingDate.getDate();
+
+ link.appendChild(document.createTextNode(this.buildDayLabel(workingDate)));
+ cell.appendChild(link);
return YAHOO.widget.Calendar_Core.STOP_RENDER;
};
Modified: jifty/branches/template-declare/share/web/templates/__jifty/validator.xml
==============================================================================
--- jifty/branches/template-declare/share/web/templates/__jifty/validator.xml (original)
+++ jifty/branches/template-declare/share/web/templates/__jifty/validator.xml Thu Nov 30 21:32:48 2006
@@ -48,19 +48,19 @@
or length $action->argument_value($arg) == 0 ) {
$writer->emptyTag( "blank", name => $action->form_field_name($arg) );
} else {
- if ( $action->result->field_canonicalization_note($arg) ) {
- $writer->dataElement(
- "canonicalization_note",
- $action->result->field_canonicalization_note($arg),
- id => $action->canonicalization_note_div_id($arg)
- );
- }
$writer->dataElement(
"update",
$action->argument_value($arg),
name => $action->form_field_name($arg)
);
}
+ if ( $action->result->field_canonicalization_note($arg) ) {
+ $writer->dataElement(
+ "canonicalization_note",
+ $action->result->field_canonicalization_note($arg),
+ id => $action->canonicalization_note_div_id($arg)
+ );
+ }
}
$writer->endTag();
}
More information about the Jifty-commit
mailing list