5 include('/elements/init_overlib.html')
7 include( '/elements/pkg_popup_link.html', { #hashref or a list, either way
10 'action' => 'content.html', # uri for content of popup which should
11 # be suitable for appending '&stuff...'
12 'label' => 'click me', # text of <A> tag
13 'cust_pkg' => $cust_pkg # a FS::cust_pkg object
15 #strongly recommended (you want a title, right?)
16 'actionlabel => 'You clicked', # popup title
21 'closetext' => 'Go Away', # the value '' removes the link
25 % if ( $params->{'cust_pkg'} ) {
26 <% include('/elements/popup_link.html', $params ) %>\
30 my $params = { 'closetext' => emt('Close'),
34 if (ref($_[0]) eq 'HASH') {
35 $params = { %$params, %{ $_[0] } };
37 $params = { %$params, @_ };
40 $params->{'action'} .=
41 ( $params->{'action'} =~ /\?/ ? ';' : '?' ).
42 'pkgnum='. $params->{'cust_pkg'}->pkgnum;
44 $params->{'actionlabel'} .=
45 ' package '. $params->{'cust_pkg'}->pkgnum; #XXX pkgnum? really?