#------------------------------------------------------------
# Copyright (C) 2006 RoyaltyShare, Inc.   All Rights Reserved
# $Id$
#------------------------------------------------------------
package RPS::DistributorPayee::DistributorPayeeSimpleList;

use strict;
use warnings;
use Carp;

use lib '/app/tools/common/lib';
use Common::Assert;

use lib '/app/tools/rps/lib';
use RPS::DistributorPayee::DistributorPayeeSimple;
use Common::FormObject;
use base 'Common::FormObject';

sub _init {
    my ( $self, %args ) = @_;

    $self->SUPER::_init(%args);

    my $payees = RPS::DB::Item::DistributorPayee->GetAll();

    $self->{DistributorPayee} = [];
    while ( $payees->hasNext() ) {
        push @{ $self->{DistributorPayee} }, RPS::DistributorPayee::DistributorPayeeSimple->new( _dbItem => $payees->next() );
    }

    return $self;
}

sub _listProperties {
    return { DistributorPayee => 1 };
}

###
1;    #
###
