承接 cpsit/typo3-personio-jobs 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

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

cpsit/typo3-personio-jobs

Composer 安装命令:

composer require cpsit/typo3-personio-jobs

包简介

TYPO3 CMS Extension to integrate jobs from Personio Recruiting API

README 文档

README

Extension icon

TYPO3 extension personio_jobs

Coverage CGL Release License
Version Downloads Supported TYPO3 versions Extension stability

📦 Packagist | 🐥 TYPO3 extension repository | 💾 Repository | 🐛 Issue tracker

An extension for TYPO3 CMS that integrates jobs from Personio Recruiting API into TYPO3. It provides a console command to import jobs into modern-typed value objects. In addition, plugins for list and detail views are provided with preconfigured support for Bootstrap v5 components.

🚀 Features

  • Console command to import jobs from Personio Recruiting API
  • Usage of modern-typed value objects during the import process
  • Plugins for list and detail view
  • Optional support for JSON Schema on job detail pages using EXT:schema
  • Compatible with TYPO3 12.4 LTS and 13.0

🔥 Installation

Composer

composer require cpsit/typo3-personio-jobs

💡 If you want to use the JSON schema feature, you must additionally require the schema extension:

composer require brotkrueml/schema

TER

Alternatively, you can download the extension via the TYPO3 extension repository (TER).

First-step configuration

Once installed, make sure to include the TypoScript setup at EXT:personio_jobs/Configuration/TypoScript in your root template.

⚡ Usage

Plugins

The extension provides two plugins:

Icon Description
List plugin icon Personio: Job list
Lists all imported jobs as unordered list. Each list item shows the job title, office and schedule and links to the job's detail view.
Detail plugin icon Personio: Job detail
Shows a single job, including several job properties and all imported job descriptions. In addition, it renders a button to apply for the job.

Command-line usage

personio-jobs:import

typo3 personio-jobs:import <storage-pid> [options]

The following command parameters are available:

Command parameter Description Required Default
storage-pid Storage pid of imported jobs
-f, --force Enforce re-import of unchanged jobs no
--no-delete Do not delete orphaned jobs no
--no-update Do not update imported jobs that have been changed no
--dry-run Do not perform database operations, only display changes no

💡 Increase verbosity with --verbose or -v to show all changes, even unchanged jobs that were skipped.

Code usage

The Personio job import process can also be triggered directly within PHP. For this, two services exist:

  • PersonioApiService provides the main functionality to fetch jobs from Personio API and return them as hydrated Job models. Note that these jobs are not yet persisted. Instead, they only represent the current Personio job feed as strong-typed value objects.
  • PersonioImportService provides additional functionality to actually persist imported jobs. Under the hood, the previously mentioned PersonioApiService is called to fetch jobs, followed by their actual persistence. For the import process, a set of import settings is available:
    • int $storagePid: Page ID where to persist new or updated jobs.
    • bool $updateExistingJobs = true: Define whether to update jobs that were already imported, but have changed in the meantime.
    • bool $deleteOrphans = true: Define whether to delete jobs that are no longer available on Personio.
    • bool $forceImport = false: Select whether existing, unchanged jobs should be re-imported.
    • bool $dryRun = false: Do not perform any persistence operations, just fetch and validate jobs.

Fetch jobs from Personio API

use CPSIT\Typo3PersonioJobs\Service\PersonioApiService;
use TYPO3\CMS\Core\Utility\GeneralUtility;

$apiService = GeneralUtility::makeInstance(PersonioApiService::class);
$jobs = $apiService->getJobs();

foreach ($jobs as $job) {
    echo 'Successfully fetched job: ' . $job->getName() . PHP_EOL;
}

Import jobs from Personio API

use CPSIT\Typo3PersonioJobs\Service\PersonioImportService;
use TYPO3\CMS\Core\Utility\GeneralUtility;

$importService = GeneralUtility::makeInstance(PersonioImportService::class);
$result = $importService->import();

foreach ($result->getNewJobs() as $newJob) {
    echo 'Imported new job: ' . $newJob->getName() . PHP_EOL;
}

foreach ($result->getUpdatedJobs() as $updatedJob) {
    echo 'Updated job: ' . $updatedJob->getName() . PHP_EOL;
}

foreach ($result->getRemovedJobs() as $removedJob) {
    echo 'Removed job: ' . $removedJob->getName() . PHP_EOL;
}

foreach ($result->getSkippedJobs() as $skippedJob) {
    echo 'Skipped job: ' . $skippedJob->getName() . PHP_EOL;
}

JSON schema

In combination with EXT:schema, a JSON schema for a single job is included on job detail pages. It is rendered as type JobPosting and includes some generic job properties.

⚠️ The schema extension must be installed to use this feature. Read more in the installation section above.

📂 Configuration

TypoScript

The following TypoScript constants are available:

TypoScript constant Description Required Default
plugin.tx_personiojobs.view.templateRootPath Path to template root
plugin.tx_personiojobs.view.partialRootPath Path to template partials
plugin.tx_personiojobs.view.layoutRootPath Path to template layouts

Extension configuration

The following extension configuration options are available:

Configuration key Description Required Default
apiUrl URL to Personio job page, e.g. https://my-company.jobs.personio.de

Routing configuration

On each import, a slug is generated. The slug can be used for an advanced routing configuration of job detail pages.

Example:

# config/sites/<identifier>/config.yaml

routeEnhancers:
  PersonioJobDetail:
    type: Extbase
    limitToPages:
      # Replace with the actual detail page id
      - 10
    extension: PersonioJobs
    plugin: Show
    routes:
      -
        routePath: '/job/{job_title}'
        _controller: 'Job::show'
        _arguments:
          job_title: job
    defaultController: 'Job::show'
    aspects:
      job_title:
        type: PersistedAliasMapper
        tableName: tx_personiojobs_domain_model_job
        routeFieldName: slug

⏰ Events

PSR-14 events can be used to modify jobs and job schemas. The following events are available:

🚧 Migration

0.4.x → 0.5.x

Decouple import process

Import process is moved to a separate service class.

  • All import operations are now performed by the new PersonioImportService class.
  • PersonioService was renamed to PersonioApiService. Replace all usages of this class by the new class name.
  • Import results are now properly displayed by objects of the new ImportResult class.
  • Public methods in AfterJobsImportedEvent have changed to match the new ImportResult class. Use the new public method AfterJobsImportedEvent::getImportResult() instead of previously available methods.

0.3.x → 0.4.x

Finalize SchemaFactory

SchemaFactory is now final and cannot be extended anymore.

  • Remove classes extending from SchemaFactory.
  • Replace customizations of the SchemaFactory by an event listener for the EnrichJobPostingSchemaEvent PSR-14 event.

🧑‍💻 Contributing

Please have a look at CONTRIBUTING.md.

💎 Credits

The Personio logo as part of all distributed icons is a trademark of Personio SE & Co. KG.

⭐ License

This project is licensed under GNU General Public License 2.0 (or later).

cpsit/typo3-personio-jobs 适用场景与选型建议

cpsit/typo3-personio-jobs 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 3.72k 次下载、GitHub Stars 达 4, 最近一次更新时间为 2023 年 03 月 20 日, 在 PHP 生态内属于活跃度较高的组件。

我们在过去多个企业项目中使用过 cpsit/typo3-personio-jobs 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。

围绕 cpsit/typo3-personio-jobs 我们能提供哪些服务?
定制开发 / 二次开发

基于 cpsit/typo3-personio-jobs 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。

BUG 修复 & 性能优化

线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。

项目外包 & 长期维护

承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。

yvsm@zunyunkeji.com QQ:316430983 微信:yvsm316 西安尊云信息科技 · 专注 PHP / Go / 分布式系统研发

统计信息

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

GitHub 信息

  • Stars: 4
  • Watchers: 5
  • Forks: 4
  • 开发语言: PHP

其他信息

  • 授权协议: GPL-2.0-or-later
  • 更新时间: 2023-03-20