[mb-commits] r9853 - in mb_server/trunk/htdocs: cdi comp/release_editor
root at musicbrainz.org
root at musicbrainz.org
Wed May 28 20:46:10 UTC 2008
Author: robert
Date: 2008-05-28 20:46:10 +0000 (Wed, 28 May 2008)
New Revision: 9853
Modified:
mb_server/trunk/htdocs/cdi/enter.html
mb_server/trunk/htdocs/comp/release_editor/init-addrelease
Log:
Accept MBIDs for the cdi/enter page as well.
Modified: mb_server/trunk/htdocs/cdi/enter.html
===================================================================
--- mb_server/trunk/htdocs/cdi/enter.html 2008-05-27 22:16:21 UTC (rev 9852)
+++ mb_server/trunk/htdocs/cdi/enter.html 2008-05-28 20:46:10 UTC (rev 9853)
@@ -66,7 +66,8 @@
$m->comp("/comp/user/check-volatile-preferences", %ARGS);
# make sure we got a valid releaseid parameter
- MusicBrainz::Server::Validation::IsNonNegInteger($artistid)
+ MusicBrainz::Server::Validation::IsNonNegInteger($artistid)
+ or MusicBrainz::Server::Validation::IsGUID($artistid)
or return $m->comp("/comp/layout/badarguments",
text => "The argument <strong>artistid</strong> is missing or has a wrong format.");
Modified: mb_server/trunk/htdocs/comp/release_editor/init-addrelease
===================================================================
--- mb_server/trunk/htdocs/comp/release_editor/init-addrelease 2008-05-27 22:16:21 UTC (rev 9852)
+++ mb_server/trunk/htdocs/comp/release_editor/init-addrelease 2008-05-28 20:46:10 UTC (rev 9853)
@@ -49,6 +49,11 @@
# LOAD ARTIST
# ---------------------------------------------------------------
# load release artist from database
+ if (MusicBrainz::Server::Validation::IsGUID($artistid))
+ {
+ my $obj = $m->comp("/comp/loadartist", $mb, $artistid);
+ $artistid = $obj->GetId;
+ }
$orig{"artistid"} = $artistid;
$orig{"artistname"} = $artistname;
$orig{"artistresolution"} = $artistresolution;
@@ -66,8 +71,6 @@
push @offsets, $leadout;
}
-
-
# load tracks, and add into @t list.
my $track_artist;
my $i;
More information about the MusicBrainz-commits
mailing list