signysphp/doctrine-types

This package is abandoned and no longer maintained. The author suggests using the doctrisigphp/doctrine-types package instead.

Custom types for doctrine

v1.1.4 2018-06-13 06:38 UTC

This package is not auto-updated.

Last update: 2019-02-20 19:18:58 UTC


README

ABANDONED, this repository will be removed.

Total Downloads Latest Stable Version License Monthly Downloads

Package Installation

The best way to install Doctrine Custom Types is using Composer:

$ composer require doctrisigphp/doctrine-types

In configuration of Kdyby\Doctrine use:

doctrine:
	user: ***
	password: ***
	...
	types: [
		DoctriSigPHP\Doctrine\DBAL\Types\TrimString
	]

Classic configuration:

<?php
// in bootstrapping code

// ...

use Doctrine\DBAL\Types\Type;

// ...

// Register my type
Type::addType('tString', 'DoctriSigPHP\Doctrine\DBAL\Types\TrimString');

Usage

...
class MyEntity {
    ...
	/**
	 * @ORM\Column(type="tString")
	 */
	protected $name;
    ...
}

To do

  • DI Extension to autoload all types
  • Add more types (if you some need, write to issue)