[freeside-commits] freeside/httemplate/view svc_Common.html, 1.4, 1.5 svc_cert.cgi, NONE, 1.1
Ivan,,,
ivan at wavetail.420.am
Sat Nov 6 17:56:37 PDT 2010
Update of /home/cvs/cvsroot/freeside/httemplate/view
In directory wavetail.420.am:/tmp/cvs-serv28516/httemplate/view
Modified Files:
svc_Common.html
Added Files:
svc_cert.cgi
Log Message:
certificates ala communigate, RT#7515
Index: svc_Common.html
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/view/svc_Common.html,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -w -d -r1.4 -r1.5
--- svc_Common.html 15 Apr 2009 07:14:11 -0000 1.4
+++ svc_Common.html 7 Nov 2010 00:56:35 -0000 1.5
@@ -1,6 +1,6 @@
<% include('elements/svc_Common.html',
'table' => $table,
- 'edit_url' => $p."edit/svc_Common.html?svcdb=$table;svcnum=",
+ 'edit_url' => $edit_url, #$p."edit/svc_Common.html?svcdb=$table;svcnum=",
%opt,
)
%>
@@ -12,6 +12,8 @@
my $table = $1;
require "FS/$table.pm";
+my $edit_url = svc_url( 'm' => $m, 'action' => 'edit', 'svcdb' => $table, query => '' );
+
my %opt;
if ( UNIVERSAL::can("FS::$table", 'table_info') ) {
$opt{'name'} = "FS::$table"->table_info->{'name'};
--- NEW FILE: svc_cert.cgi ---
<% include('elements/svc_Common.html',
'table' => 'svc_cert',
'labels' => \%labels,
#'html_foot' => $html_foot,
'fields' => \@fields,
)
%>
<%init>
my $fields = FS::svc_cert->table_info->{'fields'};
my %labels = map { $_ => ( ref($fields->{$_})
? $fields->{$_}{'label'}
: $fields->{$_}
);
}
keys %$fields;
my @fields = (
{ field=>'privatekey',
value=> sub {
my $svc_cert = shift;
if ( $svc_cert->privatekey && $svc_cert->check_privatekey ) {
'<FONT COLOR="#33ff33">Verification OK</FONT>';
} elsif ( $svc_cert->privatekey ) {
'<FONT COLOR="#ff0000">Verification error</FONT>';
} else {
'<I>(none)</I>';
}
},
},
qw( organization organization_unit city state country cert_contact )
);
</%init>
More information about the freeside-commits
mailing list