From e4bae61c5b3176c3b84b4840f77d5cb432847edc Mon Sep 17 00:00:00 2001 From: einhverfr Date: Mon, 17 Sep 2007 17:28:29 +0000 Subject: Adding project list Payment method git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/trunk@1623 4979c152-3d1c-0410-bac9-87ea11338e46 --- LedgerSMB/DBObject/Payment.pm | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'LedgerSMB/DBObject') diff --git a/LedgerSMB/DBObject/Payment.pm b/LedgerSMB/DBObject/Payment.pm index 0cd63c38..79dfc129 100644 --- a/LedgerSMB/DBObject/Payment.pm +++ b/LedgerSMB/DBObject/Payment.pm @@ -161,3 +161,23 @@ sub get_all_contact_invoices { } return @{$self->{contacts}}; } + +=over + +=item list_open_projects + +This method uses the $payment->{date} attribute, and provides a list of open +projects. The list is attached to $payment->{projects} and returned by the +function. + +=back + +=cut + +sub list_open_projects { + my ($self) = @_; + @{$self->{projects}} = $self->exec_method('project_list_open'); + return @{$self->{projects}}; +} + +1; -- cgit v1.2.3