http://www.freeside.biz/mediawiki/index.php?title=Freeside:4:Documentation:Developer/FS/cust_tax_exempt&feed=atom&action=historyFreeside:4:Documentation:Developer/FS/cust tax exempt - Revision history2024-03-28T13:07:51ZRevision history for this page on the wikiMediaWiki 1.27.7http://www.freeside.biz/mediawiki/index.php?title=Freeside:4:Documentation:Developer/FS/cust_tax_exempt&diff=9148&oldid=prevJeremyd: Edit via perl MediaWiki framework (1.13)2015-11-18T15:21:37Z<p>Edit via perl MediaWiki framework (1.13)</p>
<p><b>New page</b></p><div>==NAME==<br />
FS::cust_tax_exempt - Object methods for cust_tax_exempt records<br />
<br />
==SYNOPSIS==<br />
<code><br />
use FS::cust_tax_exempt;<br />
<br />
$record = new FS::cust_tax_exempt \%hash;<br />
$record = new FS::cust_tax_exempt { 'column' => 'value' };<br />
<br />
$error = $record->insert;<br />
<br />
$error = $new_record->replace($old_record);<br />
<br />
$error = $record->delete;<br />
<br />
$error = $record->check;<br />
</code><br />
==DESCRIPTION==<br />
An FS::cust_tax_exempt object represents a record of an old-style customer tax exemption. Currently this is only used for "texas tax". FS::cust_tax_exempt inherits from FS::Record. The following fields are currently supported:<br />
<br />
; exemptnum - primary key; custnum - customer (see [[Freeside:4:Documentation:Developer/FS/cust main|FS::cust_main]]); taxnum - tax rate (see [[Freeside:4:Documentation:Developer/FS/cust main county|FS::cust_main_county]]); year; month; amount<br />
==NOTE==<br />
Old-style customer tax exemptions are only useful for legacy migrations - if you are looking for current customer tax exemption data see [[Freeside:4:Documentation:Developer/FS/cust tax exempt pkg|FS::cust_tax_exempt_pkg]].<br />
<br />
==METHODS==<br />
; new HASHREF<br />
:Creates a new exemption record. To add the example to the database, see [[#insert|"insert"]].<br />
<br />
: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.<br />
; insert<br />
:Adds this record to the database. If there is an error, returns the error, otherwise returns false.<br />
; delete<br />
:Delete this record from the database.<br />
; replace OLD_RECORD<br />
:Replaces the OLD_RECORD with this one in the database. If there is an error, returns the error, otherwise returns false.<br />
; check<br />
: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.<br />
; cust_main_county<br />
:Returns the FS::cust_main_county object associated with this tax exemption.<br />
<br />
==BUGS==<br />
Texas tax is a royal pain in the ass.<br />
<br />
==SEE ALSO==<br />
[[Freeside:4:Documentation:Developer/FS/cust main county|FS::cust_main_county]], [[Freeside:4:Documentation:Developer/FS/cust main|FS::cust_main]], [[Freeside:4:Documentation:Developer/FS/Record|FS::Record]], schema.html from the base documentation.</div>Jeremyd