Status
This artwork has been declined by a reviewer.
diff --git a/lib/Artwork.php b/lib/Artwork.php index 63bbc9c3..cb6efc63 100644 --- a/lib/Artwork.php +++ b/lib/Artwork.php @@ -20,6 +20,7 @@ use function Safe\sprintf; * @property string $Dimensions * @property Ebook $Ebook * @property Museum $Museum + * @property User $Submitter * @property ?ImageMimeType $MimeType */ class Artwork extends PropertiesBase{ @@ -52,6 +53,7 @@ class Artwork extends PropertiesBase{ protected $_Dimensions = null; protected $_Ebook = null; protected $_Museum = null; + protected $_Submitter = null; protected ?ImageMimeType $_MimeType = null; // ******* @@ -70,6 +72,14 @@ class Artwork extends PropertiesBase{ return $this->_UrlName; } + protected function GetSubmitter(): User{ + if($this->_Submitter === null){ + $this->_Submitter = User::Get($this->SubmitterUserId); + } + + return $this->_Submitter; + } + protected function GetUrl(): string{ if($this->_Url === null){ $this->_Url = '/artworks/' . $this->Artist->UrlName . '/' . $this->UrlName; diff --git a/templates/ArtworkDetail.php b/templates/ArtworkDetail.php index 4afe4efa..d19c9436 100644 --- a/templates/ArtworkDetail.php +++ b/templates/ArtworkDetail.php @@ -1,6 +1,6 @@ $artwork = $artwork ?? null; -$showCopyrightNotice = $showCopyrightNotice ?? true; +$isAdminView = $isAdminView ?? false; if($artwork === null){ return; @@ -16,9 +16,7 @@ if($artwork === null){ - if($showCopyrightNotice){ ?> - = Template::ImageCopyrightNotice() ?> - } ?> += Template::ImageCopyrightNotice() ?>
Year completed | if($artwork->CompletedYear === null){ ?>Unknown }else{ ?> if($artwork->CompletedYearIsCirca){ ?>Circa } ?>= $artwork->CompletedYear ?> } ?> | +||
Tags | ++ | ||
Dimensions | = $artwork->Dimensions ?> | @@ -44,10 +46,12 @@ if($artwork === null){Status | = Template::ArtworkStatus(['artwork' => $artwork]) ?> |
Tags | -+ | Submitted by | +if($artwork->SubmitterUserId === null){ ?>Anonymous }else{ ?> if($artwork->Submitter->Name !== null){ ?> = Formatter::ToPlainText($artwork->Submitter->Name) ?> }else{ ?>= Formatter::ToPlainText($artwork->Submitter->Email) ?> } ?> } ?> |
This artwork has been declined by a reviewer.