Freeside:4:Documentation:Developer/FS/cacti page
From Freeside
Contents
NAME
FS::cacti_page - Object methods for cacti_page records
SYNOPSIS
use FS::cacti_page; $record = new FS::cacti_page \%hash; $record = new FS::table_name { 'exportnum' => 3, #part_export associated with this page 'svcnum' => 123, #svc_broadband associated with this page 'graphnum' => 45, #blank for svcnum index 'imported' => 1428358699, #date of import 'content' => $htmlcontent, #html containing base64-encoded images }; $error = $record->insert; $error = $new_record->replace($old_record); $error = $record->delete; $error = $record->check;
DESCRIPTION
An FS::cacti_page object represents an html page for viewing cacti graphs. FS::cacti_page inherits from FS::Record. The following fields are currently supported:
- cacti_pagenum - primary key; exportnum - part_export exportnum for this page; svcnum - svc_broadband svcnum for this page; graphnum - cacti graphnum for this page (blank for overview page); imported - date this page was imported; content - text/html content of page, should not include newlines
METHODS
- new HASHREF
- Creates a new object. To add the object to the database, see "insert".
- Note that this stores the hash reference, not a distinct copy of the hash it points to. You can ask the object for a copy with the hash method.
- insert
- Adds this record to the database. If there is an error, returns the error, otherwise returns false.
- delete
- Delete this record from the database.
- replace OLD_RECORD
- Replaces the OLD_RECORD with this one in the database. If there is an error, returns the error, otherwise returns false.
- check
- Checks all fields to make sure this is a valid example. If there is an error, returns the error, otherwise returns false. Called by the insert and replace methods.
BUGS
Will be described here once found.