fix one-time charge quantities &
[freeside.git] / FS / FS / Schema.pm
index 457e5c8..ec046cb 100644 (file)
@@ -192,6 +192,14 @@ sub dbdef_dist {
                         }
                         keys %indices;
 
+    $h_indices{"h_${table}_srckey"} = DBIx::DBSchema::Index->new({
+                                        'name'    => "h_${table}_srckey",
+                                        'unique'  => 0,
+                                        'columns' => [ 'history_action', #right?
+                                                       $tableobj->primary_key,
+                                                     ],
+                                      });
+
     my $h_tableobj = DBIx::DBSchema::Table->new( {
       'name'          => "h_$table",
       'primary_key'   => 'historynum',
@@ -488,6 +496,9 @@ sub tables_hashref {
         'sdate',   @date_type, '', '', 
         'edate',   @date_type, '', '', 
         'itemdesc', 'varchar', 'NULL', $char_d, '', '', 
+        'quantity',  'int', 'NULL', '', '', '',
+        'unitsetup', @money_typen, '', '', 
+        'unitrecur', @money_typen, '', '', 
       ],
       'primary_key' => 'billpkgnum',
       'unique' => [],
@@ -900,6 +911,7 @@ sub tables_hashref {
         'change_pkgnum',  'int', 'NULL', '', '', '',
         'change_pkgpart', 'int', 'NULL', '', '', '',
         'manual_flag',    'char', 'NULL', 1, '', '', 
+        'quantity',       'int', 'NULL', '', '', '',
       ],
       'primary_key' => 'pkgnum',
       'unique' => [],