getField("Date Last Modified"); $DateOfRecordCreation = $Schema->getField("Date Of Record Creation"); $ModParams = new SearchParameterSet(); $ModParams->addParameter( "< 1 year ago", $DateLastModified ); $RecentlyModifiedSearchLink = "index.php?P=SearchResults&". $ModParams->urlParameterString(). "&".TransportControlsUI::PNAME_SORTFIELD ."=".$DateLastModified->id(); # build link to search for recently added resources $AddedParams = new SearchParameterSet(); $AddedParams->addParameter( "< 1 year ago", $DateOfRecordCreation ); $RecentlyAddedSearchLink = "index.php?P=SearchResults" ."&".$AddedParams->urlParameterString() ."&".TransportControlsUI::PNAME_SORTFIELD ."=".$DateOfRecordCreation->id(); # retrieve local collection stats (if any) $LocalStats = array_key_exists("LocalStats", $H_CollectionStats) ? $H_CollectionStats["LocalStats"] : []; $ModResourceList = new ItemListUI([ "Date Last Modified" => [ "Heading" => "Date", "ValueFunction" => function ($Item) { return StdLib::getPrettyTimestamp($Item->Get("Date Last Modified")); }, ], "Title" => [ "ValueFunction" => function ($Item) { $Title = $Item->getMapped("Title") ?? ""; return "Id()."\">". htmlspecialchars($Title).""; }, ], "Last Modified By Id" => [ "Heading" => "User", ], ]); $ModResourceList->addActionButton( "Edit", $Schema->getEditPage(), "pencil.png" ); $ModResourceList->fieldsSortableByDefault(false); $NewResourceList = clone $ModResourceList; $ModResourceList->heading("Resources Recently Modified"); $ModResourceList->addTopButton( "More Recently Modified", $RecentlyModifiedSearchLink ); $NewResourceList->heading("Resources Recently Added"); $NewResourceList->addTopButton( "More Recently Added", $RecentlyAddedSearchLink ); $AF = ApplicationFramework::getInstance(); $UpdateCollectionStatsButton = new HtmlButton("Update Now"); $UpdateCollectionStatsButton->setIcon("RefreshArrow.svg"); $UpdateCollectionStatsButton->setOnclick("window.location=`index.php?P=MDHome&US=1`;"); $CollectionStatisticsTable = new HtmlTable(); $CollectionStatisticsTable->setTableClass("table mv-content-colstats"); $CollectionStatisticsTable->addRowsWithHeaders([ ["Number of Classifications", $TotalNumberOfClassificationsFormatted], ["Number of Controlled Names", $TotalNumberOfControlledNamesFormatted], ["Publicly-Visible Resources", $NumberOfReleasedResourcesFormatted], ["Resources Rated", $NumberOfRatedResourcesFormatted], ["Total Number of Resources", $TotalNumberOfResourcesFormatted], ["Total Distinct Resource Search Terms", $TotalSearchTermsFormatted] ]); foreach ($LocalStats as $Label => $Value) { $CollectionStatisticsTable->addRowWithHeader([$Label, $Value]); } $CollectionStatisticsTable->addRowsWithHeaders([ ["Stats Last Updated", $G_StatsUpdateTime], ["", $UpdateCollectionStatsButton->getHtml()] ]); $CDResources = [ "https://dublincore.org/resources/userguide/" => "Dublin Core User Guide", "http://framework.niso.org" => "IMLS Digital Collection Framework", "http://www.openarchives.org" => "Open Archives Initiative" ]; $CDRTable = new HtmlTable(); $CDRTable->setTableClass("table mv-content-cdresources"); foreach ($CDResources as $Link => $Label) { $CDRTable->addRowWithHeader([ $Label, "" . $Link . "" ]); } # ----- DISPLAY -------------------------------------------------------------- $AF->setPageTitle("Metadata Tool"); ?>

# Metadata Tool Functions

getEditPage()), PRIV_RESOURCEADMIN, PRIV_COLLECTIONADMIN ); PrintOurMenuEntry( "Add New Controlled Name", "index.php?P=AddControlledName", PRIV_NAMEADMIN ); PrintOurMenuEntry( "Edit Controlled Names", "index.php?P=EditControlledName&FieldId=0", PRIV_NAMEADMIN ); PrintOurMenuEntry( "Edit Option Lists", "index.php?P=EditOptionList", PRIV_NAMEADMIN ); PrintOurMenuEntry( "Add/Edit Classifications", "index.php?P=EditClassifications", PRIV_CLASSADMIN ); ?>

display($H_RecentlyModified); ?>
display($H_RecentlyAdded); ?>

# Collection Statistics

getHtml(); ?>

# Collection Development Resources

getHtml(); ?>