service and package disable!
[freeside.git] / bin / fs-setup
index 3d76bf8..e7aa3b0 100755 (executable)
@@ -1,13 +1,13 @@
 #!/usr/bin/perl -Tw
 #
-# $Id: fs-setup,v 1.64 2001-10-23 18:15:06 ivan Exp $
+# $Id: fs-setup,v 1.68 2001-12-27 09:26:13 ivan Exp $
 
 #to delay loading dbdef until we're ready
 BEGIN { $FS::Record::setup_hack = 1; }
 
 use strict;
 use DBI;
-use DBIx::DBSchema 0.18;
+use DBIx::DBSchema 0.19;
 use DBIx::DBSchema::Table;
 use DBIx::DBSchema::Column;
 use DBIx::DBSchema::ColGroup::Unique;
@@ -30,14 +30,18 @@ my($dbdef_file) = "/usr/local/etc/freeside/dbdef.". datasrc;
 
 ###
 
-print "\nEnter the maximum username length: ";
-my($username_len)=&getvalue;
+#print "\nEnter the maximum username length: ";
+#my($username_len)=&getvalue;
+my $username_len = 32; #usernamemax config file
 
 print "\n\n", <<END, ":";
-Freeside tracks the RADIUS attributes User-Name, check attribute Password and
+Freeside tracks the RADIUS User-Name, check attribute Password and
 reply attribute Framed-IP-Address for each user.  You can specify additional
-check and reply attributes.  First enter any additional RADIUS check attributes
-you need to track for each user, separated by whitespace.
+check and reply attributes (or you can add them later with the
+fs-radius-add-check and fs-radius-add-reply programs).
+
+First enter any additional RADIUS check attributes you need to track for each 
+user, separated by whitespace.
 END
 my @check_attributes = map { $attrib2db{lc($_)} or die "unknown attribute $_"; }
                          split(" ",&getvalue);
@@ -371,7 +375,7 @@ sub tables_hash_hack {
         'ship_night',    'varchar', 'NULL', 20,
         'ship_fax',      'varchar', 'NULL', 12,
         'payby',    'char', '',     4,
-        'payinfo',  'varchar', 'NULL', 16,
+        'payinfo',  'varchar', 'NULL', $char_d,
         #'paydate',  @date_type,
         'paydate',  'varchar', 'NULL', 10,
         'payname',  'varchar', 'NULL', $char_d,
@@ -458,7 +462,7 @@ sub tables_hash_hack {
         'state',    'varchar', '',     $char_d,
         'zip',      'varchar', '',     10,
         'country',  'char', '',     2,
-        'trancode', 'int', '', '',
+#        'trancode', 'int', '', '',
         'cardnum',  'varchar', '',     16,
         #'exp',      @date_type,
         'exp',      'varchar', '',     11,
@@ -544,6 +548,7 @@ sub tables_hash_hack {
         'recurtax',  'char', 'NULL', 1,
         'plan',       'varchar', 'NULL', $char_d,
         'plandata',   'text', 'NULL', '',
+        'disabled',   'char', 'NULL', 1,
       ],
       'primary_key' => 'pkgpart',
       'unique' => [ [] ],
@@ -586,6 +591,7 @@ sub tables_hash_hack {
         'svcpart',    'int',    '',   '',
         'svc',        'varchar',   '',   $char_d,
         'svcdb',      'varchar',   '',   $char_d,
+        'disabled',   'char',  'NULL',   1,
       ],
       'primary_key' => 'svcpart',
       'unique' => [ [] ],