PHPackages                             kematjaya/import-bundle - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Database &amp; ORM](/categories/database)
4. /
5. kematjaya/import-bundle

ActiveLibrary[Database &amp; ORM](/categories/database)

kematjaya/import-bundle
=======================

import from phpspreadsheet data to database

7.0.1(4mo ago)21.7kMITPHP

Since Nov 27Pushed 4mo ago1 watchersCompare

[ Source](https://github.com/kematjaya0/import-bundle)[ Packagist](https://packagist.org/packages/kematjaya/import-bundle)[ RSS](/packages/kematjaya-import-bundle/feed)WikiDiscussions main Synced 1w ago

READMEChangelogDependencies (12)Versions (38)Used By (0)

instalation
===========

[](#instalation)

- run in console

```
composer require kematjaya/import-bundle

```

config
======

[](#config)

- add to bundles.php

```
// config/bundles.php
....
Kematjaya\ImportBundle\ImportBundle::class => ['all' => true]
....

```

using service
=============

[](#using-service)

- on controller

```
...
use Kematjaya\ImportBundle\Manager\ImportManagerInterface;
...

public function import(ImportManagerInterface $importManager)
{
  $source = new YourDataSource();
  $transformer = new YourTransformer();
  $manager->->process($source, $transformer);
}

```

data source
===========

[](#data-source)

```
...
use Kematjaya\ImportBundle\DataSource\RemoteDataSource;
use Kematjaya\ImportBundle\DataSource\SpreadSheetDataSource;
...
...
$remoteSource = new RemoteDataSource('https://jsonplaceholder.typicode.com/posts'); // from remote source
$excelSource = new SpreadSheetDataSource('D://test.xlsx'); // from excel file
...

```

data transformer
================

[](#data-transformer)

- create data transformer class

```
// src/DataTransformer/PostDataTransformer
...
use App\Entity\Post;
use Kematjaya\ImportBundle\DataTransformer\AbstractDataTransformer;
...

class PostDataTrasnformer extends AbstractDataTransformer
{
  public function fromArray(array $data)
    {
        $datas = $this->checkConstraints($data);
        $entity = (new Post())
                ->setId($datas['id'])
                ->setUserId($datas['userId'])
                ->setTitle($datas['title'])
                ->setBody($datas['body']);

        return $entity;
    }

    protected function getColumns(): array
    {
        return [
            [
                self::KEY_FIELD => 'id', // key in TargetObject
                self::KEY_INDEX => 0,    // key in array source
                self::KEY_CONSTRAINT => [
                    self::CONSTRAINT_REQUIRED => true // for required data
                    self::CONSTRAINT_REFERENCE_CLASS => User::class // relation class
                    self::CONSTRAINT_REFERENCE_FIELD => 'code' // field in reference class
                ]
            ]
        ];
    }
}

```

###  Health Score

45

—

FairBetter than 93% of packages

Maintenance76

Regular maintenance activity

Popularity18

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity65

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~52 days

Recently: every ~299 days

Total

37

Last Release

132d ago

Major Versions

1.9.4 → 2.02022-08-22

2.0.4 → 7.0-BETA2026-01-06

### Community

Maintainers

![](https://www.gravatar.com/avatar/f2cf191329e1adc930a168a7d3baeda8517b7982184820692163a5baa72e3965?d=identicon)[kematjaya0](/maintainers/kematjaya0)

---

Top Contributors

[![kematjaya0](https://avatars.githubusercontent.com/u/36223951?v=4)](https://github.com/kematjaya0 "kematjaya0 (34 commits)")

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/kematjaya-import-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/kematjaya-import-bundle/health.svg)](https://phpackages.com/packages/kematjaya-import-bundle)
```

###  Alternatives

[sylius/sylius

E-Commerce platform for PHP, based on Symfony framework.

8.4k5.6M651](/packages/sylius-sylius)[prestashop/prestashop

PrestaShop is an Open Source e-commerce platform, committed to providing the best shopping cart experience for both merchants and customers.

9.0k15.4k](/packages/prestashop-prestashop)[easycorp/easyadmin-bundle

Admin generator for Symfony applications

4.3k16.7M310](/packages/easycorp-easyadmin-bundle)[sulu/sulu

Core framework that implements the functionality of the Sulu content management system

1.3k1.3M152](/packages/sulu-sulu)[contao/core-bundle

Contao Open Source CMS

1231.6M2.4k](/packages/contao-core-bundle)[sonata-project/entity-audit-bundle

Audit for Doctrine Entities

644989.8k1](/packages/sonata-project-entity-audit-bundle)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
