21 lines
408 B
PHP
21 lines
408 B
PHP
|
<?php
|
||
|
namespace ProVM\Money;
|
||
|
|
||
|
use ProVM\Common\Alias\Model;
|
||
|
|
||
|
/**
|
||
|
* @property int $id
|
||
|
* @property string $code
|
||
|
* @property string $name
|
||
|
*/
|
||
|
class Currency extends Model {
|
||
|
public static $_table = 'currencies';
|
||
|
|
||
|
protected $values;
|
||
|
public function values(): ?array {
|
||
|
if ($this->values === null) {
|
||
|
$this->values = $this->parentOf(Value::class, [Model::CHILD_KEY => 'currency_id']);
|
||
|
}
|
||
|
}
|
||
|
}
|