day_phone evening_phone other_phone mailing_address/ );
#-------------------------------------------------------------------------------
+package actor::user_setting;
+use base qw/actor/;
+
+__PACKAGE__->table( 'actor_user_setting' );
+__PACKAGE__->columns( Primary => qw/id/);
+__PACKAGE__->columns( Essential => qw/usr name value/);
+
+#-------------------------------------------------------------------------------
package actor::profile;
use base qw/actor/;
actor::user->sequence( 'actor.usr_id_seq' );
#---------------------------------------------------------------------
+ package actor::user_setting;
+
+ actor::user_setting->table( 'actor.usr_setting' );
+ actor::user_setting->sequence( 'actor.usr_setting_id_seq' );
+
+ #---------------------------------------------------------------------
package actor::user_address;
actor::user_address->table( 'actor.usr_address' );
stat_cat_entries => 1,
checkouts => 1,
hold_requests => 1,
+ settings => 1,
addresses => 1 } },
+ 'Fieldmapper::actor::user_setting' => { hint => 'aus' },
'Fieldmapper::actor::user_address' => { hint => 'aua' },
'Fieldmapper::actor::org_address' => { hint => 'aoa' },
'Fieldmapper::actor::profile' => { hint => 'ap' },
return $fieldmap->{$self->class_name}->{cdbi};
}
-
sub is_virtual {
my $self = shift;
my $field = shift;
INSERT INTO actor.usr ( profile, card, usrname, passwd, first_given_name, family_name, dob, master_account, super_user, ident_type, ident_value )
VALUES ( 1, 3,'athens', 'athens', 'athens', 'user', '1979-01-22', FALSE, TRUE, 1, 'identification' );
+
+CREATE TABLE actor.usr_setting (
+ id BIGSERIAL PRIMARY KEY,
+ usr INT NOT NULL REFERENCES actor.usr ON DELETE CASCADE,
+ name TEXT NOT NULL,
+ value TEXT NOT NULL,
+ CONSTRAINT name_once_per_value UNIQUE (usr,name)
+);
+COMMENT ON TABLE actor.usr_setting IS $$
+/*
+ * Copyright (C) 2005 Georgia Public Library Service
+ * Mike Rylander <mrylander@gmail.com>
+ *
+ * User objects
+ *
+ * This table contains any arbitrary settings that a client
+ * program would like to save for a user.
+ *
+ * ****
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+$$;
+
+
CREATE TABLE actor.profile (
id SERIAL PRIMARY KEY,
name TEXT NOT NULL UNIQUE