From 6991d4986df7fb3a6c7c49b5ae1b3713e87a16c4 Mon Sep 17 00:00:00 2001
From: ivan
Date: Tue, 29 Jan 2002 16:33:16 +0000
Subject: - web interface for hourly account charges! (FS::cust_pkg,
FS::cust_svc and FS::svc_acct seconds_since methods) - Makefile target to
regenerate HTML manpages on install - FS.pm doc update - $FS::Record::Debug
now dumps all SQL - new FS::cust_main methods: ->cancel,
->invoicing_list_addpost - start of a billing event web interface -
cust_pay::upgrade_replace doesn't error out if history includes overapplied
payments
---
httemplate/docs/man/FS/cust_pkg.html | 56 ++++++++++++++++++++++--------------
1 file changed, 34 insertions(+), 22 deletions(-)
(limited to 'httemplate/docs/man/FS/cust_pkg.html')
diff --git a/httemplate/docs/man/FS/cust_pkg.html b/httemplate/docs/man/FS/cust_pkg.html
index 459d1297c..9f1005da7 100644
--- a/httemplate/docs/man/FS/cust_pkg.html
+++ b/httemplate/docs/man/FS/cust_pkg.html
@@ -52,6 +52,8 @@
$part_pkg = $record->part_pkg;
@labels = $record->labels;
+
+ $seconds = $record->seconds_since($timestamp);
$error = FS::cust_pkg::order( $custnum, \@pkgparts );
$error = FS::cust_pkg::order( $custnum, \@pkgparts, \@remove_pkgnums ] );
@@ -79,6 +81,9 @@ inherits from FS::Record. The following fields are currently supported:
otaker - order taker (assigned automatically if null, see the FS::UID manpage)
+manual_flag - If this field is set to 1, disables the automatic
+unsuspension of this package when using the unsuspendauto config file.
+
Note: setup, bill, susp, expire and cancel are specified as UNIX timestamps;
see perlfunc/``time''. Also see the Time::Local manpage and the Date::Parse manpage for
@@ -95,26 +100,12 @@ Create a new billing item. To add the item to the database, see delete
-Currently unimplemented. You don't want to delete billing items, because there
-would then be no record the customer ever purchased the item. Instead, see
-the cancel method.
+This method now works but you probably shouldn't use it.
+You don't want to delete billing items, because there would then be no record
+the customer ever purchased the item. Instead, see the cancel method.
replace OLD_RECORD
@@ -158,16 +149,32 @@ package, then unsuspends the package itself (clears the susp field).
Returns the definition for this billing item, as an FS::part_pkg object (see
the FS::part_pkg manpage).
+cust_svc
+
+Returns the services for this package, as FS::cust_svc objects (see
+the FS::cust_svc manpage)
+
labels
Returns a list of lists, calling the label method for all services
(see the FS::cust_svc manpage) of this billing item.
+
+cust_main
+
+Returns the parent customer object (see the FS::cust_main manpage).
+
+seconds_since TIMESTAMP
+
+Returns the number of seconds all accounts (see the FS::svc_acct manpage) in this
+package have been online since TIMESTAMP.
+TIMESTAMP is specified as a UNIX timestamp; see perlfunc/``time''. Also see
+the Time::Local manpage and the Date::Parse manpage for conversion functions.
-- order CUSTNUM, PKGPARTS_ARYREF, [ REMOVE_PKGNUMS_ARYREF ]
+- order CUSTNUM, PKGPARTS_ARYREF, [ REMOVE_PKGNUMS_ARYREF [ RETURN_CUST_PKG_ARRAYREF ] ]
-
CUSTNUM is a customer (see the FS::cust_main manpage)
PKGPARTS is a list of pkgparts specifying the the billing item definitions (see
@@ -176,12 +183,15 @@ permitted.
REMOVE_PKGNUMS is an optional list of pkgnums specifying the billing items to
remove for this customer. The services (see the FS::cust_svc manpage) are moved to the
new billing items. An error is returned if this is not possible (see
-the FS::pkg_svc manpage).
+the FS::pkg_svc manpage). An empty arrayref is equivalent to not specifying this
+parameter.
+RETURN_CUST_PKG_ARRAYREF, if specified, will be filled in with the
+newly-created cust_pkg objects.
-$Id: cust_pkg.html,v 1.1 2001-07-30 07:36:03 ivan Exp $
+$Id: cust_pkg.html,v 1.2 2002-01-29 16:33:15 ivan Exp $
@@ -194,11 +204,13 @@ compile time, rather than via 'require' in sub { setup, suspend, unsuspend,
cancel } because they use %FS::UID::callback to load configuration values.
Probably need a subroutine which decides what to do based on whether or not
we've fetched the user yet, rather than a hash. See FS::UID and the TODO.
+Now that things are transactional should the check in the insert method be
+moved to check ?
-the FS::Record manpage, the FS::cust_main manpage, the FS::part_pkg manpage, the FS::cust_svc manpage
-, the FS::pkg_svc manpage, schema.html from the base documentation
+the FS::Record manpage, the FS::cust_main manpage, the FS::part_pkg manpage, the FS::cust_svc manpage,
+the FS::pkg_svc manpage, schema.html from the base documentation