From 3714fa41c5306981c9f500df13eea52c72d82545 Mon Sep 17 00:00:00 2001 From: mark Date: Tue, 12 Apr 2011 20:56:48 +0000 Subject: [PATCH] make company_phonenum available to templates, #12363 --- FS/FS/cust_bill.pm | 1 + FS/FS/msg_template.pm | 3 +++ httemplate/edit/msg_template.html | 1 + 3 files changed, 5 insertions(+) diff --git a/FS/FS/cust_bill.pm b/FS/FS/cust_bill.pm index a2754fdc9..fed1066fd 100644 --- a/FS/FS/cust_bill.pm +++ b/FS/FS/cust_bill.pm @@ -2553,6 +2553,7 @@ sub print_generic { #invoice from info 'company_name' => scalar( $conf->config('company_name', $agentnum) ), 'company_address' => join("\n", $conf->config('company_address', $agentnum) ). "\n", + 'company_phonenum'=> $conf->config('company_phonenum', $agentnum), 'returnaddress' => $returnaddress, 'agent' => &$escape_function($cust_main->agent->agent), diff --git a/FS/FS/msg_template.pm b/FS/FS/msg_template.pm index 0b9746a03..73284d1e5 100644 --- a/FS/FS/msg_template.pm +++ b/FS/FS/msg_template.pm @@ -387,6 +387,9 @@ sub substitutions { [ company_address => sub { $conf->config('company_address', shift->agentnum) } ], + [ company_phonenum => sub { + $conf->config('company_phonenum', shift->agentnum) + } ], ], # next_bill_date 'cust_pkg' => [qw( diff --git a/httemplate/edit/msg_template.html b/httemplate/edit/msg_template.html index 8e859e6e6..758aab6e4 100644 --- a/httemplate/edit/msg_template.html +++ b/httemplate/edit/msg_template.html @@ -55,6 +55,7 @@ my %substitutions = ( '$cust_statuscolor' => 'Status color code', '$company_name' => 'Our company name', '$company_address'=> 'Our company address', + '$company_phonenum' => 'Our phone number', ], 'contact' => [ # duplicate this for shipping '$name' => 'Company and contact name', -- 2.11.0