3 <TITLE>FS::svc_acct_sm - Object methods for svc_acct_sm records</TITLE>
4 <LINK REV="made" HREF="mailto:perl@packages.debian.org">
9 <A NAME="__index__"></A>
14 <LI><A HREF="#name">NAME</A></LI>
15 <LI><A HREF="#synopsis">SYNOPSIS</A></LI>
16 <LI><A HREF="#warning">WARNING</A></LI>
17 <LI><A HREF="#description">DESCRIPTION</A></LI>
18 <LI><A HREF="#methods">METHODS</A></LI>
19 <LI><A HREF="#version">VERSION</A></LI>
20 <LI><A HREF="#bugs">BUGS</A></LI>
21 <LI><A HREF="#see also">SEE ALSO</A></LI>
27 <H1><A NAME="name">NAME</A></H1>
28 <P>FS::svc_acct_sm - Object methods for svc_acct_sm records</P>
31 <H1><A NAME="synopsis">SYNOPSIS</A></H1>
33 use FS::svc_acct_sm;</PRE>
35 $record = new FS::svc_acct_sm \%hash;
36 $record = new FS::svc_acct_sm { 'column' => 'value' };</PRE>
38 $error = $record->insert;</PRE>
40 $error = $new_record->replace($old_record);</PRE>
42 $error = $record->delete;</PRE>
44 $error = $record->check;</PRE>
46 $error = $record->suspend;</PRE>
48 $error = $record->unsuspend;</PRE>
50 $error = $record->cancel;</PRE>
53 <H1><A NAME="warning">WARNING</A></H1>
54 <P>FS::svc_acct_sm is <STRONG>depreciated</STRONG>. This class is only included for migration
55 purposes. See <A HREF=".././FS/svc_forward.html">the FS::svc_forward manpage</A>.</P>
58 <H1><A NAME="description">DESCRIPTION</A></H1>
59 <P>An FS::svc_acct_sm object represents a virtual mail alias. FS::svc_acct_sm
60 inherits from FS::Record. The following fields are currently supported:</P>
62 <DT><STRONG><A NAME="item_key">svcnum - primary key (assigned automatcially for new accounts)</A></STRONG><BR>
64 <DT><STRONG><A NAME="item_domain">domsvc - svcnum of the virtual domain (see <A HREF=".././FS/svc_domain.html">the FS::svc_domain manpage</A>)</A></STRONG><BR>
66 <DT><STRONG><A NAME="item_account">domuid - uid of the target account (see <A HREF=".././FS/svc_acct.html">the FS::svc_acct manpage</A>)</A></STRONG><BR>
68 <DT><STRONG><A NAME="item_domuser_%2D_virtual_username">domuser - virtual username</A></STRONG><BR>
73 <H1><A NAME="methods">METHODS</A></H1>
75 <DT><STRONG><A NAME="item_new">new HASHREF</A></STRONG><BR>
77 Creates a new virtual mail alias. To add the virtual mail alias to the
78 database, see <A HREF="#insert">insert</A>.
80 <DT><STRONG><A NAME="item_insert">insert</A></STRONG><BR>
82 Adds this virtual mail alias to the database. If there is an error, returns
83 the error, otherwise returns false.
84 <P>The additional fields pkgnum and svcpart (see <A HREF=".././FS/cust_svc.html">the FS::cust_svc manpage</A>) should be
85 defined. An FS::cust_svc record will be created and inserted.</P>
87 #If the configuration values (see L<FS::Conf>) shellmachine and qmailmachines
88 #exist, and domuser is `*' (meaning a catch-all mailbox), the command:
90 # [ -e $dir/.qmail-$qdomain-default ] || {
91 # touch $dir/.qmail-$qdomain-default;
92 # chown $uid:$gid $dir/.qmail-$qdomain-default;
95 #is executed on shellmachine via ssh (see L<dot-qmail/"EXTENSION ADDRESSES">).
96 #This behaviour can be surpressed by setting $FS::svc_acct_sm::nossh_hack true.</PRE>
98 <DT><STRONG><A NAME="item_delete">delete</A></STRONG><BR>
100 Deletes this virtual mail alias from the database. If there is an error,
101 returns the error, otherwise returns false.
102 <P>The corresponding FS::cust_svc record will be deleted as well.</P>
104 <DT><STRONG><A NAME="item_replace_OLD_RECORD">replace OLD_RECORD</A></STRONG><BR>
106 Replaces OLD_RECORD with this one in the database. If there is an error,
107 returns the error, otherwise returns false.
109 <DT><STRONG><A NAME="item_suspend">suspend</A></STRONG><BR>
111 Just returns false (no error) for now.
112 <P>Called by the suspend method of FS::cust_pkg (see <A HREF=".././FS/cust_pkg.html">the FS::cust_pkg manpage</A>).</P>
114 <DT><STRONG><A NAME="item_unsuspend">unsuspend</A></STRONG><BR>
116 Just returns false (no error) for now.
117 <P>Called by the unsuspend method of FS::cust_pkg (see <A HREF=".././FS/cust_pkg.html">the FS::cust_pkg manpage</A>).</P>
119 <DT><STRONG><A NAME="item_cancel">cancel</A></STRONG><BR>
121 Just returns false (no error) for now.
122 <P>Called by the cancel method of FS::cust_pkg (see <A HREF=".././FS/cust_pkg.html">the FS::cust_pkg manpage</A>).</P>
124 <DT><STRONG><A NAME="item_check">check</A></STRONG><BR>
126 Checks all fields to make sure this is a valid virtual mail alias. If there is
127 an error, returns the error, otherwise returns false. Called by the insert and
129 <P>Sets any fixed values; see <A HREF=".././FS/part_svc.html">the FS::part_svc manpage</A>.</P>
133 <H1><A NAME="version">VERSION</A></H1>
134 <P>$Id: svc_acct_sm.html,v 1.3 2002-01-29 17:42:46 ivan Exp $</P>
137 <H1><A NAME="bugs">BUGS</A></H1>
138 <P>The remote commands should be configurable.</P>
139 <P>The $recref stuff in sub check should be cleaned up.</P>
142 <H1><A NAME="see also">SEE ALSO</A></H1>
143 <P><A HREF=".././FS/svc_forward.html">the FS::svc_forward manpage</A></P>
144 <P><A HREF=".././FS/Record.html">the FS::Record manpage</A>, <A HREF=".././FS/Conf.html">the FS::Conf manpage</A>, <A HREF=".././FS/cust_svc.html">the FS::cust_svc manpage</A>, <A HREF=".././FS/part_svc.html">the FS::part_svc manpage</A>, <A HREF=".././FS/cust_pkg.html">the FS::cust_pkg manpage</A>,
145 <A HREF=".././FS/svc_acct.html">the FS::svc_acct manpage</A>, <A HREF=".././FS/svc_domain.html">the FS::svc_domain manpage</A>, <A HREF="../Net/SSH.html">the Net::SSH manpage</A>, <EM>ssh</EM>, <EM>dot-qmail</EM>,
146 schema.html from the base documentation.</P>