[freeside-commits] freeside/httemplate/edit pkg_category.html, 1.2, 1.2.2.1 usage_class.html, 1.1, 1.1.4.1

Jeff Finucane,420,, jeff at wavetail.420.am
Fri Nov 20 09:39:42 PST 2009


Update of /home/cvs/cvsroot/freeside/httemplate/edit
In directory wavetail.420.am:/tmp/cvs-serv20142/httemplate/edit

Modified Files:
      Tag: FREESIDE_1_9_BRANCH
	pkg_category.html usage_class.html 
Log Message:
invoice formatting: add sections for usage, add sections per svc_phone, add folding like line items into one #6592

Index: usage_class.html
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/edit/usage_class.html,v
retrieving revision 1.1
retrieving revision 1.1.4.1
diff -u -d -r1.1 -r1.1.4.1
--- usage_class.html	23 Aug 2008 21:59:45 -0000	1.1
+++ usage_class.html	20 Nov 2009 17:39:40 -0000	1.1.4.1
@@ -3,14 +3,26 @@
               'table'         => 'usage_class',
               'fields'        => [
                                    'classname',
-                                   { field=>'disabled',
-                                     type=>'checkbox',
-                                     value=>'Y',
+                                   'weight',
+                                   { field => 'format',
+                                     type  => $useformat ? 'select' : 'hidden',
+                                     ( $useformat
+                                       ? ( 'options' => [ keys %labels ],
+                                           'labels'  => \%labels,
+                                         )
+                                       : ()
+                                     ),
+                                   },
+                                   { field => 'disabled',
+                                     type  => 'checkbox',
+                                     value => 'Y',
                                    },
                                  ],
               'labels'        => { 
                                    'classnum'  => 'Class number',
                                    'classname' => 'Class name',
+                                   'weight'    => 'Weight',
+                                   'format'    => 'Format',
                                    'disabled'  => 'Disable class',
                                  },
               'viewall_dir'   => 'browse',
@@ -22,4 +34,9 @@
 die "access denied"
   unless $FS::CurrentUser::CurrentUser->access_right('Configuration');
 
+my $conf = new FS::Conf;
+my $useformat = $conf->exists('usage_class_as_a_section');
+
+my %labels = &FS::usage_class::summary_formats_labelhash();
+
 </%init>

Index: pkg_category.html
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/edit/pkg_category.html,v
retrieving revision 1.2
retrieving revision 1.2.2.1
diff -u -d -r1.2 -r1.2.2.1
--- pkg_category.html	5 Oct 2009 00:49:34 -0000	1.2
+++ pkg_category.html	20 Nov 2009 17:39:40 -0000	1.2.2.1
@@ -4,21 +4,25 @@
               'fields' => [
                             'categoryname',
                             'weight',
+                            { field=>'condense', type=>'checkbox', value=>'Y', },
                             { field=>'disabled', type=>'checkbox', value=>'Y', },
                           ],
-              'labels' => { 
+              'labels' => {
                             'categorynum'  => 'Category number',
                             'categoryname' => 'Category name',
                             'weight'       => 'Weight',
-                            'disabled'  => 'Disable category',
+                            'condense'     => 'Collapse identical items to one',
+                            'disabled'     => 'Disable category',
                           },
               'viewall_dir' => 'browse',
+              %opt,
            )
-          
 %>
 <%init>
 
 die "access denied"
   unless $FS::CurrentUser::CurrentUser->access_right('Configuration');
 
+my %opt = @_;
+
 </%init>



More information about the freeside-commits mailing list