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

use lib '/app/tools/common/lib';
use RSApache::Response::XSLT;

use lib '/app/tools/rps/lib';
use RPS::ArtistContract::Form;
use RPS::Command;
use RPS::CommandLog;
use base 'RPS::Command';

use Data::Dumper;

use constant kTemplate => '/app/tools/rps/templates/artist_contract/index.xsl';

sub cmd  { return "show"; }
sub area { return "artist_contract"; }

sub execute
{
	my ($self) = @_;


	# Give any inherited methods the first crack at this.
	# (This checks for login and basic access permissions).
	#
	my $response = $self->SUPER::execute();
	return $response if $response;

    my $id = $self->getParam("ArtistContractID");
	my $form = RPS::ArtistContract::Form->new(artistContractID => $id);

    RPS::CommandLog::Log($self, $id);

	$self->{xml}{Form} = $form;

	$response = RSApache::Response::XSLT->new($self->{xml}, kTemplate);

	return $response;
}


1;

