first commit
This commit is contained in:
@@ -0,0 +1,190 @@
|
||||
{**
|
||||
* templates/stats/context.tpl
|
||||
*
|
||||
* Copyright (c) 2022 Simon Fraser University
|
||||
* Copyright (c) 2022 John Willinsky
|
||||
* Distributed under the GNU GPL v3. For full terms see the file docs/COPYING.
|
||||
*
|
||||
* The context statistics page.
|
||||
*
|
||||
*}
|
||||
{extends file="layouts/backend.tpl"}
|
||||
|
||||
{block name="page"}
|
||||
|
||||
<div class="pkpStats">
|
||||
<pkp-header>
|
||||
<h1>{translate key="context.context"}</h1>
|
||||
<spinner v-if="isLoadingTimeline"></spinner>
|
||||
<template slot="actions">
|
||||
<date-range
|
||||
unique-id="context-stats-date-range"
|
||||
:date-start="dateStart"
|
||||
:date-start-min="dateStartMin"
|
||||
:date-end="dateEnd"
|
||||
:date-end-max="dateEndMax"
|
||||
:options="dateRangeOptions"
|
||||
date-range-label="{translate key="stats.dateRange"}"
|
||||
date-format-instructions-label="{translate key="stats.dateRange.instructions"}"
|
||||
change-date-range-label="{translate key="stats.dateRange.change"}"
|
||||
since-date-label="{translate key="stats.dateRange.sinceDate"}"
|
||||
until-date-label="{translate key="stats.dateRange.untilDate"}"
|
||||
all-dates-label="{translate key="stats.dateRange.allDates"}"
|
||||
custom-range-label="{translate key="stats.dateRange.customRange"}"
|
||||
from-date-label="{translate key="stats.dateRange.from"}"
|
||||
to-date-label="{translate key="stats.dateRange.to"}"
|
||||
apply-label="{translate key="stats.dateRange.apply"}"
|
||||
invalid-date-label="{translate key="stats.dateRange.invalidDate"}"
|
||||
date-does-not-exist-label="{translate key="stats.dateRange.dateDoesNotExist"}"
|
||||
invalid-date-range-label="{translate key="stats.dateRange.invalidDateRange"}"
|
||||
invalid-end-date-max-label="{translate key="stats.dateRange.invalidEndDateMax"}"
|
||||
invalid-start-date-min-label="{translate key="stats.dateRange.invalidStartDateMin"}"
|
||||
@set-range="setDateRange"
|
||||
></date-range>
|
||||
</template>
|
||||
</pkp-header>
|
||||
<div class="pkpStats__container -pkpClearfix">
|
||||
<div class="pkpStats__content">
|
||||
<div v-if="chartData" class="pkpStats__graph">
|
||||
<div class="pkpStats__graphHeader">
|
||||
<h2 class="pkpStats__graphTitle -screenReader" id="context-stats-graph-title">
|
||||
{translate key="stats.views"}
|
||||
</h2>
|
||||
<div class="pkpStats__graphSelectors">
|
||||
<div class="pkpStats__graphSelector pkpStats__graphSelector--timelineInterval">
|
||||
<pkp-button
|
||||
:aria-pressed="timelineInterval === 'day'"
|
||||
aria-describedby="context-stats-graph-title"
|
||||
:disabled="!isDailyIntervalEnabled"
|
||||
@click="setTimelineInterval('day')"
|
||||
>
|
||||
{translate key="stats.daily"}
|
||||
</pkp-button>
|
||||
<pkp-button
|
||||
:aria-pressed="timelineInterval === 'month'"
|
||||
aria-describedby="context-stats-graph-title"
|
||||
:disabled="!isMonthlyIntervalEnabled"
|
||||
@click="setTimelineInterval('month')"
|
||||
>
|
||||
{translate key="stats.monthly"}
|
||||
</pkp-button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<table class="-screenReader" role="region" aria-live="polite">
|
||||
<caption>{translate key="stats.views.timelineInterval"}</caption>
|
||||
<thead>
|
||||
<tr>
|
||||
<th scope="col">{translate key="common.date"}</th>
|
||||
<th scope="col">{translate key="stats.views"}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr v-for="segment in timeline" :key="segment.date">
|
||||
<th scope="row">{{ segment.label }}</th>
|
||||
<td>{{ segment.value }}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<line-chart :chart-data="chartData" aria-hidden="true"></line-chart>
|
||||
<span v-if="isLoadingTimeline" class="pkpStats__loadingCover">
|
||||
<spinner></spinner>
|
||||
</span>
|
||||
</div>
|
||||
<div class="pkpStats__panel" role="region" aria-live="polite">
|
||||
<pkp-header>
|
||||
<h2>
|
||||
{translate key="stats.views"}
|
||||
<tooltip
|
||||
tooltip="{translate key="stats.context.tooltip.text"}"
|
||||
label="{translate key="stats.context.tooltip.label"}"
|
||||
></tooltip>
|
||||
<spinner v-if="isLoadingItems"></spinner>
|
||||
</h2>
|
||||
<template slot="actions">
|
||||
<pkp-button
|
||||
ref="downloadReportModalButton"
|
||||
@click="$modal.show('downloadReport')"
|
||||
>
|
||||
{translate key="common.downloadReport"}
|
||||
</pkp-button>
|
||||
<modal
|
||||
close-label="{translate key="common.close"}"
|
||||
name="downloadReport"
|
||||
title={translate key="common.download"}
|
||||
@closed="setFocusToRef('downloadReportModalButton')"
|
||||
>
|
||||
<p>{translate key="stats.context.downloadReport.description"}</p>
|
||||
<table class="pkpTable pkpStats__reportParams">
|
||||
<tr class="pkpTable__row">
|
||||
<th>{translate key="stats.dateRange"}</th>
|
||||
<td>{{ getDateRangeDescription() }}</th>
|
||||
</tr>
|
||||
</table>
|
||||
<action-panel class="pkpStats__reportAction">
|
||||
<h2>{translate key="context.context"}</h2>
|
||||
<p>
|
||||
{translate key="stats.context.downloadReport.downloadContext.description"}
|
||||
</p>
|
||||
<template slot="actions">
|
||||
<pkp-button
|
||||
@click="downloadReport"
|
||||
>
|
||||
{translate key="stats.context.downloadReport.downloadContext"}
|
||||
</pkp-button>
|
||||
</template>
|
||||
</action-panel>
|
||||
<action-panel class="pkpStats__reportAction">
|
||||
<h2>{translate key="stats.timeline"}</h2>
|
||||
<p>
|
||||
{{ getTimelineDescription() }}
|
||||
</p>
|
||||
<template slot="actions">
|
||||
<pkp-button
|
||||
@click="downloadReport('timeline')"
|
||||
>
|
||||
{translate key="stats.timeline.downloadReport.downloadTimeline"}
|
||||
</pkp-button>
|
||||
</template>
|
||||
</action-panel>
|
||||
</modal>
|
||||
</template>
|
||||
</pkp-header>
|
||||
<pkp-table
|
||||
labelled-by="contextDetailTableLabel"
|
||||
:class="tableClasses"
|
||||
:columns="tableColumns"
|
||||
:rows="items"
|
||||
>
|
||||
<template slot-scope="{ row, rowIndex }">
|
||||
<table-cell
|
||||
v-for="(column, columnIndex) in tableColumns"
|
||||
:key="column.name"
|
||||
:column="column"
|
||||
:row="row"
|
||||
:tabindex="!rowIndex && !columnIndex ? 0 : -1"
|
||||
>
|
||||
<template v-if="column.name === 'title'">
|
||||
<a
|
||||
:href="row.url"
|
||||
class="pkpStats__itemLink"
|
||||
target="_blank"
|
||||
>
|
||||
<span class="pkpStats__itemTitle">{{ localize(row.name) }}</span>
|
||||
</a>
|
||||
</template>
|
||||
</table-cell>
|
||||
</template>
|
||||
</pkp-table>
|
||||
<div v-if="!items.length" class="pkpStats__noRecords">
|
||||
<template v-if="isLoadingItems">
|
||||
<spinner></spinner>
|
||||
{translate key="common.loading"}
|
||||
</template>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/block}
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
{**
|
||||
* templates/stats/counterReports.tpl
|
||||
*
|
||||
* Copyright (c) 2024 Simon Fraser University
|
||||
* Copyright (c) 2024 John Willinsky
|
||||
* Distributed under the GNU GPL v3. For full terms see the file docs/COPYING.
|
||||
*
|
||||
* @brief Set up and download COUNTER R5 TSV reports
|
||||
*}
|
||||
{extends file="layouts/backend.tpl"}
|
||||
|
||||
{block name="page"}
|
||||
<h1 class="app__pageHeading">
|
||||
{translate key="manager.statistics.counterR5Reports"}
|
||||
</h1>
|
||||
<p>{translate key="manager.statistics.counterR5Reports.description"}</p>
|
||||
{if !$usagePossible}
|
||||
<notification class="pkpNotification--backendPage__header" type="warning">{translate key="manager.statistics.counterR5Reports.usageNotPossible"}</notification>
|
||||
{/if}
|
||||
<panel>
|
||||
<panel-section>
|
||||
<counter-reports-list-panel
|
||||
v-bind="components.counterReportsListPanel"
|
||||
@set="set"
|
||||
/>
|
||||
</panel-section>
|
||||
</panel>
|
||||
{/block}
|
||||
@@ -0,0 +1,134 @@
|
||||
{**
|
||||
* lib/pkp/templates/stats/editorial.tpl
|
||||
*
|
||||
* Copyright (c) 2013-2021 Simon Fraser University
|
||||
* Copyright (c) 2003-2021 John Willinsky
|
||||
* Distributed under the GNU GPL v3. For full terms see the file docs/COPYING.
|
||||
*
|
||||
* The editorial statistics page.
|
||||
*
|
||||
*}
|
||||
{extends file="layouts/backend.tpl"}
|
||||
|
||||
{block name="page"}
|
||||
|
||||
<div class="pkpStats pkpStats--editorial">
|
||||
<h1 class="-screenReader">{translate key="stats.editorialActivity"}</h1>
|
||||
<div v-if="activeByStage" class="pkpStats__graph">
|
||||
<div class="pkpStats--editorial__stageWrapper -pkpClearfix">
|
||||
<div class="pkpStats--editorial__stageChartWrapper">
|
||||
<doughnut-chart :chart-data="chartData"></doughnut-chart>
|
||||
</div>
|
||||
<div class="pkpStats--editorial__stageList">
|
||||
<h2 class="pkpStats--editorial__stage pkpStats--editorial__stage--total">
|
||||
<span class="pkpStats--editorial__stageCount">{{ totalActive }}</span>
|
||||
<span class="pkpStats--editorial__stageLabel">{translate key="stats.submissionsActive"}</span>
|
||||
</h2>
|
||||
<div v-for="stage in activeByStage" :key="stage.name" class="pkpStats--editorial__stage">
|
||||
<span class="pkpStats--editorial__stageCount">{{ stage.count }}</span>
|
||||
<span class="pkpStats--editorial__stageLabel">{{ stage.name }}</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="pkpStats__panel">
|
||||
<pkp-header>
|
||||
<h1 id="editorialActivityTabelLabel">
|
||||
{translate key="stats.trends"}
|
||||
<span v-if="isLoading" class="pkpSpinner" aria-hidden="true"></span>
|
||||
</h1>
|
||||
<template slot="actions">
|
||||
<date-range
|
||||
slot="thead-dateRange"
|
||||
unique-id="editorial-stats-date-range"
|
||||
:date-start="dateStart"
|
||||
:date-start-min="dateStartMin"
|
||||
:date-end="dateEnd"
|
||||
:date-end-max="dateEndMax"
|
||||
:options="dateRangeOptions"
|
||||
date-range-label="{translate key="stats.dateRange"}"
|
||||
date-format-instructions-label="{translate key="stats.dateRange.instructions"}"
|
||||
change-date-range-label="{translate key="stats.dateRange.change"}"
|
||||
since-date-label="{translate key="stats.dateRange.sinceDate"}"
|
||||
until-date-label="{translate key="stats.dateRange.untilDate"}"
|
||||
all-dates-label="{translate key="stats.dateRange.allDates"}"
|
||||
custom-range-label="{translate key="stats.dateRange.customRange"}"
|
||||
from-date-label="{translate key="stats.dateRange.from"}"
|
||||
to-date-label="{translate key="stats.dateRange.to"}"
|
||||
apply-label="{translate key="stats.dateRange.apply"}"
|
||||
invalid-date-label="{translate key="stats.dateRange.invalidDate"}"
|
||||
date-does-not-exist-label="{translate key="stats.dateRange.dateDoesNotExist"}"
|
||||
invalid-date-range-label="{translate key="stats.dateRange.invalidDateRange"}"
|
||||
invalid-end-date-max-label="{translate key="stats.dateRange.invalidEndDateMax"}"
|
||||
invalid-start-date-min-label="{translate key="stats.dateRange.invalidStartDateMin"}"
|
||||
@set-range="setDateRange"
|
||||
@updated:current-range="setCurrentDateRange"
|
||||
></date-range>
|
||||
<pkp-button
|
||||
v-if="filters.length"
|
||||
:is-active="isSidebarVisible"
|
||||
@click="toggleSidebar"
|
||||
>
|
||||
<icon icon="filter" :inline="true"></icon>
|
||||
{translate key="common.filter"}
|
||||
</pkp-button>
|
||||
</template>
|
||||
</pkp-header>
|
||||
<div class="pkpStats__container -pkpClearfix">
|
||||
<!-- Filters in the sidebar -->
|
||||
<div
|
||||
v-if="filters.length"
|
||||
ref="sidebar"
|
||||
class="pkpStats__sidebar"
|
||||
:class="sidebarClasses"
|
||||
>
|
||||
<div
|
||||
v-for="(filterSet, index) in filters"
|
||||
:key="index"
|
||||
class="pkpStats__filterSet"
|
||||
>
|
||||
<pkp-header v-if="filterSet.heading">
|
||||
<h2>{{ filterSet.heading }}</h2>
|
||||
</pkp-header>
|
||||
<pkp-filter
|
||||
v-for="filter in filterSet.filters"
|
||||
:key="filter.param + filter.value"
|
||||
v-bind="filter"
|
||||
:is-filter-active="isFilterActive(filter.param, filter.value)"
|
||||
@add-filter="addFilter"
|
||||
@remove-filter="removeFilter"
|
||||
></pkp-filter>
|
||||
</div>
|
||||
</div>
|
||||
<div class="pkpStats__content">
|
||||
<div class="pkpStats__table" role="region" aria-live="polite">
|
||||
<pkp-table
|
||||
class="pkpTable--editorialStats"
|
||||
labelled-by="editorialActivityTabelLabel"
|
||||
:columns="tableColumns"
|
||||
:rows="tableRows"
|
||||
>
|
||||
<template slot-scope="{ldelim}row, rowIndex{rdelim}">
|
||||
<table-cell
|
||||
v-for="(column, columnIndex) in tableColumns"
|
||||
:key="column.name"
|
||||
:column="column"
|
||||
:row="row"
|
||||
:tabindex="!rowIndex && !columnIndex ? 0 : -1"
|
||||
>
|
||||
<template v-if="column.name === 'name'">
|
||||
{{ row.name }}
|
||||
<tooltip v-if="row.description"
|
||||
:label="__('stats.descriptionForStat', {ldelim}stat: row.name{rdelim})"
|
||||
:tooltip="row.description"
|
||||
></tooltip>
|
||||
</template>
|
||||
</table-cell>
|
||||
</template>
|
||||
</pkp-table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/block}
|
||||
@@ -0,0 +1,329 @@
|
||||
{**
|
||||
* templates/stats/publications.tpl
|
||||
*
|
||||
* Copyright (c) 2013-2021 Simon Fraser University
|
||||
* Copyright (c) 2003-2021 John Willinsky
|
||||
* Distributed under the GNU GPL v3. For full terms see the file docs/COPYING.
|
||||
*
|
||||
* The publications statistics page.
|
||||
*
|
||||
*}
|
||||
{extends file="layouts/backend.tpl"}
|
||||
|
||||
{block name="page"}
|
||||
|
||||
<div class="pkpStats">
|
||||
<pkp-header>
|
||||
<h1>{translate key="common.publications"}</h1>
|
||||
<spinner v-if="isLoadingTimeline"></spinner>
|
||||
<template slot="actions">
|
||||
<date-range
|
||||
unique-id="publication-stats-date-range"
|
||||
:date-start="dateStart"
|
||||
:date-start-min="dateStartMin"
|
||||
:date-end="dateEnd"
|
||||
:date-end-max="dateEndMax"
|
||||
:options="dateRangeOptions"
|
||||
date-range-label="{translate key="stats.dateRange"}"
|
||||
date-format-instructions-label="{translate key="stats.dateRange.instructions"}"
|
||||
change-date-range-label="{translate key="stats.dateRange.change"}"
|
||||
since-date-label="{translate key="stats.dateRange.sinceDate"}"
|
||||
until-date-label="{translate key="stats.dateRange.untilDate"}"
|
||||
all-dates-label="{translate key="stats.dateRange.allDates"}"
|
||||
custom-range-label="{translate key="stats.dateRange.customRange"}"
|
||||
from-date-label="{translate key="stats.dateRange.from"}"
|
||||
to-date-label="{translate key="stats.dateRange.to"}"
|
||||
apply-label="{translate key="stats.dateRange.apply"}"
|
||||
invalid-date-label="{translate key="stats.dateRange.invalidDate"}"
|
||||
date-does-not-exist-label="{translate key="stats.dateRange.dateDoesNotExist"}"
|
||||
invalid-date-range-label="{translate key="stats.dateRange.invalidDateRange"}"
|
||||
invalid-end-date-max-label="{translate key="stats.dateRange.invalidEndDateMax"}"
|
||||
invalid-start-date-min-label="{translate key="stats.dateRange.invalidStartDateMin"}"
|
||||
@set-range="setDateRange"
|
||||
></date-range>
|
||||
<pkp-button
|
||||
v-if="filters.length"
|
||||
:is-active="isSidebarVisible"
|
||||
@click="toggleSidebar"
|
||||
>
|
||||
<icon icon="filter" :inline="true"></icon>
|
||||
{translate key="common.filter"}
|
||||
</pkp-button>
|
||||
</template>
|
||||
</pkp-header>
|
||||
<div class="pkpStats__container -pkpClearfix">
|
||||
<!-- Filters in the sidebar -->
|
||||
<div
|
||||
v-if="filters.length"
|
||||
ref="sidebar"
|
||||
class="pkpStats__sidebar"
|
||||
:class="sidebarClasses"
|
||||
>
|
||||
<pkp-header
|
||||
class="pkpStats__sidebarHeader"
|
||||
:tabindex="isSidebarVisible ? 0 : -1"
|
||||
>
|
||||
<h2>
|
||||
<icon icon="filter" :inline="true"></icon>
|
||||
{translate key="common.filter"}
|
||||
</h2>
|
||||
</pkp-header>
|
||||
<div
|
||||
v-for="(filterSet, index) in filters"
|
||||
:key="index"
|
||||
class="pkpStats__filterSet"
|
||||
>
|
||||
<pkp-header v-if="filterSet.heading">
|
||||
<h3>{{ filterSet.heading }}</h3>
|
||||
</pkp-header>
|
||||
<pkp-filter
|
||||
v-for="filter in filterSet.filters"
|
||||
:key="filter.param + filter.value"
|
||||
v-bind="filter"
|
||||
:is-filter-active="isFilterActive(filter.param, filter.value)"
|
||||
@add-filter="addFilter"
|
||||
@remove-filter="removeFilter"
|
||||
></pkp-filter>
|
||||
</div>
|
||||
</div>
|
||||
<div class="pkpStats__content">
|
||||
<div v-if="chartData" class="pkpStats__graph">
|
||||
<div class="pkpStats__graphHeader">
|
||||
<h2 class="pkpStats__graphTitle -screenReader" id="publication-stats-graph-title">
|
||||
{translate key="submission.views"}
|
||||
</h2>
|
||||
<div class="pkpStats__graphSelectors">
|
||||
<div class="pkpStats__graphSelector pkpStats__graphSelector--timelineType">
|
||||
<pkp-button
|
||||
:aria-pressed="timelineType === 'abstract'"
|
||||
aria-describedby="publication-stats-graph-title"
|
||||
@click="setTimelineType('abstract')"
|
||||
>
|
||||
{translate key="stats.publications.abstracts"}
|
||||
</pkp-button>
|
||||
<pkp-button
|
||||
:aria-pressed="timelineType === 'files'"
|
||||
aria-describedby="publication-stats-graph-title"
|
||||
@click="setTimelineType('files')"
|
||||
>
|
||||
{translate key="submission.files"}
|
||||
</pkp-button>
|
||||
</div>
|
||||
<div class="pkpStats__graphSelector pkpStats__graphSelector--timelineInterval">
|
||||
<pkp-button
|
||||
:aria-pressed="timelineInterval === 'day'"
|
||||
aria-describedby="publication-stats-graph-title"
|
||||
:disabled="!isDailyIntervalEnabled"
|
||||
@click="setTimelineInterval('day')"
|
||||
>
|
||||
{translate key="stats.daily"}
|
||||
</pkp-button>
|
||||
<pkp-button
|
||||
:aria-pressed="timelineInterval === 'month'"
|
||||
aria-describedby="publication-stats-graph-title"
|
||||
:disabled="!isMonthlyIntervalEnabled"
|
||||
@click="setTimelineInterval('month')"
|
||||
>
|
||||
{translate key="stats.monthly"}
|
||||
</pkp-button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<table class="-screenReader" role="region" aria-live="polite">
|
||||
<caption v-if="timelineType === 'files'">{translate key="stats.publications.totalGalleyViews.timelineInterval"}</caption>
|
||||
<caption v-else>{translate key="stats.publications.totalAbstractViews.timelineInterval"}</caption>
|
||||
<thead>
|
||||
<tr>
|
||||
<th scope="col">{translate key="common.date"}</th>
|
||||
<th v-if="timelineType === 'files'" scope="col">{translate key="stats.fileViews"}</th>
|
||||
<th v-else scope="col">{translate key="submission.abstractViews"}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr v-for="segment in timeline" :key="segment.date">
|
||||
<th scope="row">{{ segment.label }}</th>
|
||||
<td>{{ segment.value }}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<line-chart :chart-data="chartData" aria-hidden="true"></line-chart>
|
||||
<span v-if="isLoadingTimeline" class="pkpStats__loadingCover">
|
||||
<spinner></spinner>
|
||||
</span>
|
||||
</div>
|
||||
<div class="pkpStats__panel" role="region" aria-live="polite">
|
||||
<pkp-header>
|
||||
<h2 id="publicationDetailTableLabel">
|
||||
{translate key="stats.publications.details"}
|
||||
<spinner v-if="isLoadingItems"></spinner>
|
||||
</h2>
|
||||
<template slot="actions">
|
||||
<div class="pkpStats__itemsOfTotal">
|
||||
{{
|
||||
replaceLocaleParams(itemsOfTotalLabel, {
|
||||
count: items.length,
|
||||
total: itemsMax
|
||||
})
|
||||
}}
|
||||
<a
|
||||
v-if="items.length < itemsMax"
|
||||
href="#publicationDetailTablePagination"
|
||||
class="-screenReader"
|
||||
>
|
||||
{translate key="common.pagination.label"}
|
||||
</a>
|
||||
</div>
|
||||
<pkp-button
|
||||
ref="downloadReportModalButton"
|
||||
@click="$modal.show('downloadReport')"
|
||||
>
|
||||
{translate key="common.downloadReport"}
|
||||
</pkp-button>
|
||||
<modal
|
||||
close-label="{translate key="common.close"}"
|
||||
name="downloadReport"
|
||||
title={translate key="common.download"}
|
||||
@closed="setFocusToRef('downloadReportModalButton')"
|
||||
>
|
||||
<p>{translate key="stats.publications.downloadReport.description"}</p>
|
||||
<table class="pkpTable pkpStats__reportParams">
|
||||
<tr class="pkpTable__row">
|
||||
<th>{translate key="stats.dateRange"}</th>
|
||||
<td>{{ getDateRangeDescription() }}</td>
|
||||
</tr>
|
||||
<tr
|
||||
v-for="(filterSet, index) in filters"
|
||||
class="pkpTable__row">
|
||||
<th>{{ filterSet.heading }}</th>
|
||||
<td>{{ getFilterDescription(filterSet) }}</td>
|
||||
</tr>
|
||||
<tr
|
||||
v-if="searchPhrase"
|
||||
class="pkpTable__row">
|
||||
<th>{translate key="common.searchPhrase"}</th>
|
||||
<td>{{ searchPhrase }}</td>
|
||||
</tr>
|
||||
</table>
|
||||
<action-panel class="pkpStats__reportAction">
|
||||
<h2>{translate key="common.publications"}</h2>
|
||||
<p>
|
||||
{translate key="stats.publications.downloadReport.downloadSubmissions.description"}
|
||||
</p>
|
||||
<template slot="actions">
|
||||
<pkp-button
|
||||
@click="downloadReport"
|
||||
>
|
||||
{translate key="stats.publications.downloadReport.downloadSubmissions"}
|
||||
</pkp-button>
|
||||
</template>
|
||||
</action-panel>
|
||||
<action-panel class="pkpStats__reportAction">
|
||||
<h2>{translate key="submission.files"}</h2>
|
||||
<p>
|
||||
{translate key="stats.publications.downloadReport.downloadFiles.description"}
|
||||
</p>
|
||||
<template slot="actions">
|
||||
<pkp-button
|
||||
@click="downloadReport('files')"
|
||||
>
|
||||
{translate key="stats.publications.downloadReport.downloadFiles"}
|
||||
</pkp-button>
|
||||
</template>
|
||||
</action-panel>
|
||||
<action-panel class="pkpStats__reportAction">
|
||||
<h2>{translate key="stats.timeline"}</h2>
|
||||
<p>
|
||||
{{ getTimelineDescription() }}
|
||||
</p>
|
||||
<template slot="actions">
|
||||
<pkp-button
|
||||
@click="downloadReport('timeline')"
|
||||
>
|
||||
{translate key="stats.timeline.downloadReport.downloadTimeline"}
|
||||
</pkp-button>
|
||||
</template>
|
||||
</action-panel>
|
||||
{if $geoReportType}
|
||||
<action-panel class="pkpStats__reportAction">
|
||||
<h2>
|
||||
{translate key="common.geographic"}
|
||||
<tooltip
|
||||
tooltip="{translate key="stats.geographic.ccAttribution"}"
|
||||
label="{translate key="stats.geographic.tooltip.label"}"
|
||||
></tooltip>
|
||||
</h2>
|
||||
<p>
|
||||
{translate key="stats.publications.downloadReport.downloadGeographic.description"}
|
||||
</p>
|
||||
<template slot="actions">
|
||||
<pkp-button
|
||||
@click="downloadReport('{$geoReportType}')"
|
||||
>
|
||||
{translate key="stats.publications.downloadReport.downloadGeographic"}
|
||||
</pkp-button>
|
||||
</template>
|
||||
</action-panel>
|
||||
{/if}
|
||||
</modal>
|
||||
</template>
|
||||
</pkp-header>
|
||||
<pkp-table
|
||||
labelled-by="publicationDetailTableLabel"
|
||||
:class="tableClasses"
|
||||
:columns="tableColumns"
|
||||
:rows="items"
|
||||
:order-by="orderBy"
|
||||
:order-direction="orderDirection"
|
||||
@order-by="setOrderBy"
|
||||
>
|
||||
<search
|
||||
slot="thead-title"
|
||||
class="pkpStats__titleSearch"
|
||||
:search-phrase="searchPhrase"
|
||||
search-label="{translate key="stats.searchSubmissionDescription"}"
|
||||
@search-phrase-changed="setSearchPhrase"
|
||||
></search>
|
||||
<template slot-scope="{ row, rowIndex }">
|
||||
<table-cell
|
||||
v-for="(column, columnIndex) in tableColumns"
|
||||
:key="column.name"
|
||||
:column="column"
|
||||
:row="row"
|
||||
:tabindex="!rowIndex && !columnIndex ? 0 : -1"
|
||||
>
|
||||
<template v-if="column.name === 'title'">
|
||||
<a
|
||||
:href="row.publication.urlPublished"
|
||||
class="pkpStats__itemLink"
|
||||
target="_blank"
|
||||
>
|
||||
<span class="pkpStats__itemAuthors">{{ row.publication.authorsStringShort }}</span>
|
||||
<span class="pkpStats__itemTitle">{{ localize(row.publication.fullTitle) }}</span>
|
||||
</a>
|
||||
</template>
|
||||
</table-cell>
|
||||
</template>
|
||||
</pkp-table>
|
||||
<div v-if="!items.length" class="pkpStats__noRecords">
|
||||
<template v-if="isLoadingItems">
|
||||
<spinner></spinner>
|
||||
{translate key="common.loading"}
|
||||
</template>
|
||||
<template v-else>
|
||||
{translate key="stats.publications.none"}
|
||||
</template>
|
||||
</div>
|
||||
<pagination
|
||||
v-if="lastPage > 1"
|
||||
id="publicationDetailTablePagination"
|
||||
:current-page="currentPage"
|
||||
:is-loading="isLoadingItems"
|
||||
:last-page="lastPage"
|
||||
@set-page="setPage"
|
||||
></pagination>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/block}
|
||||
|
||||
@@ -0,0 +1,26 @@
|
||||
{**
|
||||
* lib/pkp/templates/stats/reports.tpl
|
||||
*
|
||||
* Copyright (c) 2013-2021 Simon Fraser University
|
||||
* Copyright (c) 2003-2021 John Willinsky
|
||||
* Distributed under the GNU GPL v3. For full terms see the file docs/COPYING.
|
||||
*
|
||||
* The editorial statistics page.
|
||||
*
|
||||
*}
|
||||
{extends file="layouts/backend.tpl"}
|
||||
|
||||
{block name="page"}
|
||||
<h1 class="app__pageHeading">
|
||||
{translate key="manager.statistics.reports"}
|
||||
</h1>
|
||||
<div class="app__contentPanel">
|
||||
<p>{translate key="manager.statistics.reports.description"}</p>
|
||||
|
||||
<ul>
|
||||
{foreach from=$reportPlugins key=key item=plugin}
|
||||
<li><a href="{url op="reports" path="report" pluginName=$plugin->getName()|escape}">{$plugin->getDisplayName()|escape}</a></li>
|
||||
{/foreach}
|
||||
</ul>
|
||||
</div>
|
||||
{/block}
|
||||
@@ -0,0 +1,50 @@
|
||||
{**
|
||||
* lib/pkp/templates/stats/users.tpl
|
||||
*
|
||||
* Copyright (c) 2013-2021 Simon Fraser University
|
||||
* Copyright (c) 2003-2021 John Willinsky
|
||||
* Distributed under the GNU GPL v3. For full terms see the file docs/COPYING.
|
||||
*
|
||||
* The editorial statistics page.
|
||||
*
|
||||
*}
|
||||
{extends file="layouts/backend.tpl"}
|
||||
|
||||
{block name="page"}
|
||||
<div class="pkpStats">
|
||||
<div class="pkpStats__panel">
|
||||
<pkp-header>
|
||||
<h1 id="usersTableLabel" class="pkpHeader__title">{translate key="manager.statistics.statistics.registeredUsers"}</h1>
|
||||
<template slot="actions">
|
||||
<pkp-button ref="exportButton" @click="$modal.show('export')">
|
||||
{translate key="common.export"}
|
||||
</pkp-button>
|
||||
</template>
|
||||
</pkp-header>
|
||||
<table class="pkpTable" labelled-by="usersTableLabel">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{translate key="common.name"}</th>
|
||||
<th>{translate key="stats.total"}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{foreach from=$userStats item=$row}
|
||||
<tr>
|
||||
<td>{$row.name}</td>
|
||||
<td>{$row.value}</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<modal
|
||||
close-label="common.close"
|
||||
name="export"
|
||||
title="{translate key="manager.export.usersToCsv.label"}"
|
||||
@closed="setFocusToRef('exportButton')"
|
||||
>
|
||||
<pkp-form v-bind="components.usersReportForm" @set="set" @success="loadExport" />
|
||||
</modal>
|
||||
{/block}
|
||||
Reference in New Issue
Block a user