[freeside-users] Managing invoices

Ivan Kohler ivan at sisd.com
Thu Nov 1 12:48:32 PDT 2007


On Thu, Nov 01, 2007 at 12:07:11PM +0100, Ljupco Vangelski wrote:
> Ivan Kohler wrote:
> > On Mon, Oct 29, 2007 at 08:24:10PM +0100, Ljupco Vangelski wrote:
> >   
> >> 2. Is it possible to remove the detailed view (call rate for every 
> >> number) on the invoice (for a particular customer)? For example one 
> >> customer has 100 rated calls and wants to see only the total value (not 
> >> each call separately).
> >>     
> >
> > I don't believe there's currently an option for that, though I'm sure it 
> > would be straighforward to add.
> >
> >   
> I found a way to do this, bi commenting out the following lines in: 
> /usr/local/etc/{conf-file}/invoice_html
> 
>      foreach my $line ( @detail_items ) {
>             $OUT .=
>               '<tr class="invoice_desc">'.
>                 '<td align="center">'. $line->{'ref'}. '</td>'.
>                 '<td align="left">'. $line->{'description'}. '</td>'.
>                 '<td align="right">'. $line->{'amount'}. '</td>'.
>               '</tr>'
>             ;
>             foreach my $ext_desc ( @{$line->{'ext_description'} } ) {
>               $OUT .=
>                 '<tr class="invoice_extdesc">'.
>                   '<td></td>'.
>                   '<td align="left">- '. $ext_desc. '</td>'.
>                   '<td></td>'.
>                 '</tr>'
>             }
>           }
> 
> 
> This way, only the total amount is printed (not every rate detail).

This will leave more than just CDRs off invoices, but if that works for 
you, sure.

> >> 4. Is it possible to create different rate plans for different day periods?
> >>     
> >
> > Peak vs. off-peak is not a current feature.
> >
> >   
> 
> Maybe just another column with type time in the cdr table should be 
> added which will be equal to calldate (update cdr set time=calldate), 
> and that way queries can be sent based on the day period. The rating 
> engine should be modified to take that into consideration for 
> peak/off-peak and holidays.

Well hey, if you think it should be added, by all means, run your design 
past the -devel list and send a patch!  :)

-- 
_ivan


More information about the freeside-users mailing list