定制 t3s/t3s-discogs 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

t3s/t3s-discogs

Composer 安装命令:

composer require t3s/t3s-discogs

包简介

TYPO3 Extension – Display your Discogs vinyl collection with covers

README 文档

README

Something for vinyl fans! In addition to records (vinyl) and CDs, Discogs accepts virtually any physical audio medium that has ever been commercially or officially produced for the public.

Display your Discogs collection with cover images, tracklists, credits and community ratings on your TYPO3 website.

Live Demo

Note

See it in action: t3sbootstrap.de/extensions/discogs-collection

Requirements

  • TYPO3 >= 14.3
  • PHP >= 8.2
  • A Discogs account with a personal API token

Installation

Via Composer (recommended)

composer require t3s/t3s-discogs

Via TYPO3 Extension Repository (TER)

Install via the TYPO3 Extension Manager:

Or download directly from extensions.typo3.org/extension/t3s_discogs

Setup

1. Generate a Discogs User Token

  1. Log in to discogs.com
  2. Go to Settings → Developers
  3. Click "Generate new token"
  4. Copy the token and keep it private

Direct link: https://www.discogs.com/settings/developers

2. Add the Content Element

  • Open a page in the backend
  • Insert a new content element of type "Discogs Collection"
  • In the "Plugin" tab, fill in:
    • Discogs Username (as shown in your profile URL)
    • Discogs User Token (from step 1)
    • Configure columns, sorting and other options as desired

3. Bootstrap

The templates require Bootstrap 5.3.

Plugin Settings (FlexForm)

Setting Description Default
username Your Discogs username
token Personal API token
perPage Items per page (12 / 24 / 48 / 100) 24
columns Bootstrap grid columns (2 / 3 / 4 / 6) 4
sort Sort field (added / artist / title / year / format) added
sortOrder Sort direction (asc / desc) desc
viewMode Display as grid or list grid
disableCache Fetch fresh data on every request no

Features

List View

  • Responsive Bootstrap 5 grid or table list view (switchable via plugin settings)
  • Cover image, artist, title, year, format, primary genre
  • Every cover and title links to the detail view
  • Page-based pagination with readable URLs (e.g. /my-collection/page/2)

Detail View

  • Large cover image + all additional release images as thumbnails
  • Community rating (average score, number of ratings, have/want counts)
  • Full metadata: year, release date, country, label, catalogue number
  • Format with all descriptions (e.g. Vinyl (12", 33⅓ RPM, LP))
  • Genres & styles as badges
  • Credits: producers, mixers, guest artists with their roles
  • Tracklist as a table (position, title, track artists, duration)
  • Videos as YouTube links with duration
  • Free-text notes from the Discogs database
  • Data quality indicator

Caching

API responses are cached via the TYPO3 caching framework (FileBackend, cache group pages):

  • Collection lists are cached for 1 hour
  • Release details are cached for 24 hours, since master data rarely changes

To force a refresh, flush the TYPO3 page cache. Caching can be disabled per plugin instance via the disableCache FlexForm setting.

Discogs API Rate Limits

Authenticated requests are limited to 60 per minute. With caching enabled, normal usage stays well within this limit.

Routing Configuration

To get clean readable URLs for the detail view and pagination, add the following to your site's config/sites/<your-site>/config.yaml:

routeEnhancers:
  T3sDiscogsShow:
    type: Extbase
    limitToPages:
      - 12  # UID of the page with the plugin
    extension: T3sDiscogs
    plugin: Collection
    routes:
      - { routePath: '/release/{releaseId}', _controller: 'Discogs::show', _arguments: {'releaseId': 'releaseId'} }
      - { routePath: '/page/{page}', _controller: 'Discogs::list', _arguments: {'page': 'page'} }
    defaultController: 'Discogs::list'

This produces URLs like:

/my-collection/release/2548209
/my-collection/page/2

Exclude parameters from cHash

Add the following to config/system/additional.php to prevent TYPO3 from appending a cHash parameter to these URLs:

$GLOBALS['TYPO3_CONF_VARS']['FE']['cacheHash']['excludedParameters'][] = 'tx_t3sdiscogs_collection[releaseId]';
$GLOBALS['TYPO3_CONF_VARS']['FE']['cacheHash']['excludedParameters'][] = 'tx_t3sdiscogs_collection[action]';
$GLOBALS['TYPO3_CONF_VARS']['FE']['cacheHash']['excludedParameters'][] = 'tx_t3sdiscogs_collection[controller]';
$GLOBALS['TYPO3_CONF_VARS']['FE']['cacheHash']['excludedParameters'][] = 'tx_t3sdiscogs_collection[page]';

Overriding Templates

Set custom template paths via TypoScript:

plugin.tx_t3sdiscogs_collection {
    view {
        templateRootPaths {
            10 = EXT:my_sitepackage/Resources/Private/Templates/
        }
        partialRootPaths {
            10 = EXT:my_sitepackage/Resources/Private/Partials/
        }
        layoutRootPaths {
            10 = EXT:my_sitepackage/Resources/Private/Layouts/
        }
    }
}

统计信息

  • 总下载量: 0
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: HTML

其他信息

  • 授权协议: GPL-2.0-or-later
  • 更新时间: 2026-06-06

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固