Commit 54596920 authored by Alex Vandiver's avatar Alex Vandiver
Browse files

Merge branch '4.2/date-timezone-docs' into 4.2-trunk

parents 6e569521 c8d71c3f
......@@ -1106,33 +1106,31 @@ sub Timelocal {
=head3 Timezone $context
Returns the timezone name.
Takes one argument, C<$context> argument which could be C<user>, C<server> or C<utc>.
Returns the timezone name for the specified context. C<$context>
should be one of these values:
=item user
Default value is C<user> that mean it returns current user's Timezone value.
=item C<user>
=item server
The current user's Timezone value will be returned.
If context is C<server> it returns value of the C<Timezone> RT config option.
=item C<server>
=item utc
If both server's and user's timezone names are undefined returns 'UTC'.
The value of the C<Timezone> RT config option will be returned.
For any other value of C<$context>, or if the specified context has no
defined timezone, C<UTC> is returned.
sub Timezone {
my $self = shift;
if (@_ == 0) {
Carp::carp "RT::Date->Timezone is a setter only";
Carp::carp 'RT::Date->Timezone requires a context argument';
return undef;
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment