1 package FS::cust_main_Mixin;
8 FS::cust_main_Mixin - Mixin class for records that contain fields from cust_main
12 package FS::some_table;
14 @ISA = qw( FS::cust_main_Mixin FS::Record );
18 This is a mixin class for records that contain fields from the cust_main table,
19 for example, from a JOINed search. See httemplate/search/ for examples.
27 Given an object that contains fields from cust_main (say, from a JOINed
28 search; see httemplate/search/ for examples), returns the equivalent of the
29 FS::cust_main I<name> method, or "(unlinked)" if this object is not linked to
34 sub cust_unlinked_msg { '(unlinked)'; }
35 sub cust_linked { $_[0]->custnum; }
40 ? FS::cust_main::name($self)
41 : $self->cust_unlinked_msg;
46 Given an object that contains fields from cust_main (say, from a JOINed
47 search; see httemplate/search/ for examples), returns the equivalent of the
48 FS::cust_main I<ship_name> method, or "(unlinked)" if this object is not
56 ? FS::cust_main::ship_name($self)
57 : $self->cust_unlinked_msg;
62 Given an object that contains fields from cust_main (say, from a JOINed
63 search; see httemplate/search/ for examples), returns the equivalent of the
64 FS::cust_main I<contact> method, or "(unlinked)" if this object is not linked
72 ? FS::cust_main::contact($self)
73 : $self->cust_unlinked_msg;
78 Given an object that contains fields from cust_main (say, from a JOINed
79 search; see httemplate/search/ for examples), returns the equivalent of the
80 FS::cust_main I<ship_contact> method, or "(unlinked)" if this object is not
88 ? FS::cust_main::ship_contact($self)
89 : $self->cust_unlinked_msg;
98 L<FS::cust_main>, L<FS::Record>