X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=htetc%2Fhandler.pl;h=ab9fa9503593d05c5de1961a75dc184b7593339c;hb=c3eedebbd47ba193c059a500466949bb5377393f;hp=92564350efd7469a8306e8f9e38a1d9ee61d5a56;hpb=85c516c6a894772e101d24a16ad2f4df978c0f7f;p=freeside.git diff --git a/htetc/handler.pl b/htetc/handler.pl index 92564350e..ab9fa9503 100644 --- a/htetc/handler.pl +++ b/htetc/handler.pl @@ -91,7 +91,7 @@ sub handler use strict; use vars qw( $cgi $p $fsurl); use vars qw( %session ); - use CGI 2.47 qw(-private_tempfiles); + use CGI 3.29 qw(-private_tempfiles); #3.29 to fix RT attachment problems #use CGI::Carp qw(fatalsToBrowser); use CGI::Cookie; use List::Util qw( max min ); @@ -130,7 +130,9 @@ sub handler use Locale::Country; use Business::US::USPS::WebTools::AddressStandardization; use FS; - use FS::UID qw(cgisuidsetup dbh getotaker datasrc driver_name); + use FS::UID qw( adminsuidsetup cgisuidsetup getotaker + dbh datasrc driver_name + ); use FS::Record qw(qsearch qsearchs fields dbdef str2time_sql); use FS::Conf; use FS::CGI qw(header menubar popurl rooturl table itable ntable idiot @@ -241,6 +243,11 @@ sub handler use Time::HiRes; use HTML::Scrubber; + #blah. not even in RT::Interface::Web::Handler, just in + #html/NoAuth/css/dhandler and rt-test-dependencies. ask for it here + #to throw a real error instead of just a mysterious unstyled RT + use CSS::Squish 0.06; + #slow, unreliable, segfaults and is optional #see rt/html/Ticket/Elements/ShowTransactionAttachments #use Text::Quoted; @@ -289,16 +296,23 @@ sub handler }; - #is this conditional a bad idea entirely, hmm - unless ( - $HTML::Mason::r->filename =~ /\/rt\/.*NoAuth/ #RT images/JS - && $HTML::Mason::r->filename !~ /\/rt\/REST\// #but NOT mail gw - ) { + if ( $HTML::Mason::r->filename !~ /\/rt\/.*NoAuth/ ) { #not RT images/JS + $cgi = new CGI; &cgisuidsetup($cgi); #&cgisuidsetup($r); $p = popurl(2); $fsurl = rooturl(); + + } elsif ( $HTML::Mason::r->filename =~ /\/rt\/REST\/.*NoAuth/ ) { + + #need to log somebody in for the mail gw + + ##old installs w/fs_selfs or selfserv?? + #&adminsuidsetup('fs_selfservice'); + + &adminsuidsetup('fs_queue'); + } sub include {