X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fedit%2Finvoice_template.html;fp=httemplate%2Fedit%2Finvoice_template.html;h=851ab5ecf9293d2446a75050575af316de42273b;hb=eb4ff7f73c5d4bdf74a3472448b5a195598ff4cd;hp=0000000000000000000000000000000000000000;hpb=32b5d3a31f112a381f0a15ac5e3a2204242f3405;p=freeside.git diff --git a/httemplate/edit/invoice_template.html b/httemplate/edit/invoice_template.html new file mode 100644 index 000000000..851ab5ecf --- /dev/null +++ b/httemplate/edit/invoice_template.html @@ -0,0 +1,80 @@ +<% include("/elements/header.html", "Edit $type2desc{$type} invoice template", + menubar( + 'View all invoice templates' => $p.'browse/invoice_template.html' + ) + ) +%> + +
+ + +% if ( $type eq 'html' ) { + +% #init + + +% #editor + + +% } else { + + + +% } + +

+ + +
+ +<% include("/elements/footer.html") %> + +<%once> + +my %type2desc = ( + 'html' => 'HTML', + 'latex' => 'Print/PDF (typeset)', + 'text' => 'Plaintext', +); + +my %type2base = ( + 'html' => 'invoice_html', + 'latex' => 'invoice_latex', + 'text' => 'invoice_template', +); + + +<%init> + +die "access denied" + unless $FS::CurrentUser::CurrentUser->access_right('Configuration'); + +my $type = $cgi->param('type'); +my $name = $cgi->param('name'); +my $suffix = $cgi->param('suffix'); + +#XXX type handling, just testing this out for now + +my $conf = new FS::Conf; + +my $value = length($name) + ? join("\n", $conf->config_orbase($type2base{$type}.$suffix, $name) ) + : join("\n", $conf->config($type2base{$type}.$suffix) ); + +my $confname = length($name) + ? $type2base{$type}.$suffix. '_'. $name + : $type2base{$type}.$suffix; + +