Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
mvorisek committed Jun 9, 2022
1 parent 96caaf5 commit 23c3a8b
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 19 deletions.
11 changes: 1 addition & 10 deletions docs/typecasting.rst
Original file line number Diff line number Diff line change
Expand Up @@ -37,16 +37,7 @@ You must remember that type-casting is a two-way operation. If you are
introducing your own types, you will need to make sure they can be saved and
loaded correctly.

Some formats such as `date`, `time` and `datetime` may have additional options
to it::

$m->addField('registered', [
'type' => 'date',
'persist_format' => 'd/m/Y',
'persist_timezone' => 'IST',
]);

Here is another example with booleans::
Some types such as `boolean` may support additional options like::

$m->addField('is_married', [
'type' => 'boolean',
Expand Down
9 changes: 0 additions & 9 deletions src/Model/FieldPropertiesTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -107,15 +107,6 @@ trait FieldPropertiesTrait
*/
public $required = false;

/**
* Persisting format for type = 'date', 'datetime', 'time' fields.
*
* For example, for date it can be 'Y-m-d', for datetime - 'Y-m-d H:i:s.u' etc.
*
* @var string
*/
public $persist_format;

/**
* Persisting timezone for type = 'date', 'datetime', 'time' fields.
*
Expand Down

0 comments on commit 23c3a8b

Please sign in to comment.