This repository has been archived on 2023-12-29. You can view files and clone it, but cannot push or open issues or pull requests.
dogstats/web/models/Dog.model.php
Chris f7a7c3457b
All checks were successful
Build and push / Pulling repo on server (push) Successful in 18s
man kann hunde anlegen yay
2023-10-22 23:05:24 +02:00

17 lines
630 B
PHP

<?php
class Dog extends Model {
protected $dbTable = "dogs";
protected $dbFields = Array (
'uuid' => ['type'=>'text','required','unique','autoValMethod'=>'gen_ulid'],
'registered' => ['type'=>'datetime','required','unique','autoValMethod'=>'getDateTime'],
'name' => ['type'=>'text'],
'kennel_name' => ['type'=>'text'],
'breed' => ['type'=>'text'],
'size' => ['type'=>'text'], //in cm
'birthday' => ['type'=>'int'], //unix timestamp
'agility_size' => ['type'=>'int'], //S,M,I,L
'active' => ['type'=>'int','default'=>1]
);
}