Commit bd9adddd authored by Thomas Sibley's avatar Thomas Sibley
Browse files

Version 0.03

parent e5d73436
html/Callbacks/RT-Extension-MandatoryOnTransition/m/ticket/create/BeforeCreate
html/Callbacks/RT-Extension-MandatoryOnTransition/m/ticket/reply/AfterWorked
html/Callbacks/RT-Extension-MandatoryOnTransition/m/ticket/reply/BeforeUpdate
html/Callbacks/RT-Extension-MandatoryOnTransition/Ticket/Create.html/BeforeCreate
html/Callbacks/RT-Extension-MandatoryOnTransition/Ticket/Elements/EditCustomFields/MassageCustomFields
html/Callbacks/RT-Extension-MandatoryOnTransition/Ticket/Update.html/AfterWorked
html/Callbacks/RT-Extension-MandatoryOnTransition/Ticket/Update.html/BeforeUpdate
......@@ -9,11 +13,18 @@ inc/Module/Install/Makefile.pm
inc/Module/Install/Metadata.pm
inc/Module/Install/ReadmeFromPod.pm
inc/Module/Install/RTx.pm
inc/Module/Install/Substitute.pm
inc/Module/Install/Win32.pm
inc/Module/Install/WriteAll.pm
lib/RT/Extension/MandatoryOnTransition.pm
lib/RT/Extension/MandatoryOnTransition/Test.pm
lib/RT/Extension/MandatoryOnTransition/Test.pm.in
Makefile.PL
MANIFEST This list of files
MANIFEST.SKIP
META.yml
patches/4.0.8-additional-mobile-callbacks-plus-style.diff
README
xt/basic.t
xt/mandatory_on_create.t
xt/required_fields.t
......@@ -18,7 +18,7 @@ no_index:
directory:
- html
- inc
- t
- xt
resources:
license: http://opensource.org/licenses/gpl-license.php
version: 0.01
version: 0.03
......@@ -8,13 +8,13 @@ no warnings 'once';
use Module::Install::Base;
use base 'Module::Install::Base';
our $VERSION = '0.29';
our $VERSION = '0.30';
use FindBin;
use File::Glob ();
use File::Basename ();
my @DIRS = qw(etc lib html bin sbin po var);
my @DIRS = qw(etc lib html static bin sbin po var);
my @INDEX_DIRS = qw(lib bin sbin);
sub RTx {
......@@ -62,10 +62,11 @@ sub RTx {
unshift @INC, "$RT::LocalPath/lib" if $RT::LocalPath;
unshift @INC, $lib_path;
$RT::LocalVarPath ||= $RT::VarPath;
$RT::LocalPoPath ||= $RT::LocalLexiconPath;
$RT::LocalHtmlPath ||= $RT::MasonComponentRoot;
$RT::LocalLibPath ||= "$RT::LocalPath/lib";
$RT::LocalVarPath ||= $RT::VarPath;
$RT::LocalPoPath ||= $RT::LocalLexiconPath;
$RT::LocalHtmlPath ||= $RT::MasonComponentRoot;
$RT::LocalStaticPath ||= $RT::StaticPath;
$RT::LocalLibPath ||= "$RT::LocalPath/lib";
my $with_subdirs = $ENV{WITH_SUBDIRS};
@ARGV = grep { /WITH_SUBDIRS=(.*)/ ? ( ( $with_subdirs = $1 ), 0 ) : 1 }
......@@ -129,18 +130,7 @@ install ::
my %has_etc;
if ( File::Glob::bsd_glob("$FindBin::Bin/etc/schema.*") ) {
# got schema, load factory module
$has_etc{schema}++;
$self->load('RTxFactory');
$self->postamble(<< ".");
factory ::
\t\$(NOECHO) \$(PERL) -Ilib -I"$local_lib_path" -I"$lib_path" -Minc::Module::Install -e"RTxFactory(qw($RTx $name))"
dropdb ::
\t\$(NOECHO) \$(PERL) -Ilib -I"$local_lib_path" -I"$lib_path" -Minc::Module::Install -e"RTxFactory(qw($RTx $name drop))"
.
}
if ( File::Glob::bsd_glob("$FindBin::Bin/etc/acl.*") ) {
$has_etc{acl}++;
......@@ -164,28 +154,19 @@ dropdb ::
print "For first-time installation, type 'make initdb'.\n";
my $initdb = '';
$initdb .= <<"." if $has_etc{schema};
\t\$(NOECHO) \$(PERL) -Ilib -I"$local_lib_path" -I"$lib_path" -Minc::Module::Install -e"RTxInitDB(qw(schema))"
\t\$(NOECHO) \$(PERL) -Ilib -I"$local_lib_path" -I"$lib_path" -Minc::Module::Install -e"RTxInitDB(qw(schema \$(NAME) \$(VERSION)))"
.
$initdb .= <<"." if $has_etc{acl};
\t\$(NOECHO) \$(PERL) -Ilib -I"$local_lib_path" -I"$lib_path" -Minc::Module::Install -e"RTxInitDB(qw(acl))"
\t\$(NOECHO) \$(PERL) -Ilib -I"$local_lib_path" -I"$lib_path" -Minc::Module::Install -e"RTxInitDB(qw(acl \$(NAME) \$(VERSION)))"
.
$initdb .= <<"." if $has_etc{initialdata};
\t\$(NOECHO) \$(PERL) -Ilib -I"$local_lib_path" -I"$lib_path" -Minc::Module::Install -e"RTxInitDB(qw(insert))"
\t\$(NOECHO) \$(PERL) -Ilib -I"$local_lib_path" -I"$lib_path" -Minc::Module::Install -e"RTxInitDB(qw(insert \$(NAME) \$(VERSION)))"
.
$self->postamble("initdb ::\n$initdb\n");
$self->postamble("initialize-database ::\n$initdb\n");
}
}
sub RTxInit {
unshift @INC, substr( delete( $INC{'RT.pm'} ), 0, -5 ) if $INC{'RT.pm'};
require RT;
RT::LoadConfig();
RT::ConnectToDatabase();
die "Cannot load RT" unless $RT::Handle and $RT::DatabaseType;
}
# stolen from RT::Handle so we work on 3.6 (cmp_versions came in with 3.8)
{ my %word = (
a => -4,
......@@ -228,4 +209,4 @@ sub requires_rt {
__END__
#line 348
#line 329
......@@ -7,7 +7,7 @@ use warnings;
use base qw(Module::Install::Base);
use vars qw($VERSION);
$VERSION = '0.18';
$VERSION = '0.20';
sub readme_from {
my $self = shift;
......
......@@ -2,7 +2,7 @@ use strict;
use warnings;
package RT::Extension::MandatoryOnTransition;
our $VERSION = '0.02';
our $VERSION = '0.03';
=head1 NAME
......
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