% include( '/elements/header.html', 'Developer Documentation' ) %> <& /elements/menubar.html, 'Freeside Perl Modules' => $fsurl.'docs/library/FS.html', 'Complete Index' => $fsurl.'docs/library/index.html', &>
FS::class_Common - Base class for classification classes
use base qw( FS::class_Common ); use FS::category_table; #should use this
#required sub _target_table { 'table_name'; }
#optional for non-standard names sub _target_column { 'classnum'; } #default is classnum sub _category_table { 'table_name'; } #default is to replace s/class/category/
FS::class_Common is a base class for classes which provide a classification for other classes, such as pkg_class or cust_class.
Creates a new classification. To add the classfication to the database, see "insert".
Adds this classification to the database. If there is an error, returns the error, otherwise returns false.
Deletes this classification from the database. Only classifications with no associated target objects can be deleted. If there is an error, returns the error, otherwise returns false.
Replaces OLD_RECORD with this one in the database. If there is an error, returns the error, otherwise returns false.
Checks all fields to make sure this is a valid classification. If there is an error, returns the error, otherwise returns false. Called by the insert and replace methods.
Returns the category record associated with this class, or false if there is none.
Returns the category name associated with this class, or false if there is none.
FS::category_Common, FS::pkg_class, FS::cust_class
Hey! The above document had some coding errors, which are explained below:
You forgot a '=back' before '=head1'