Overview
Comment:Remove old stuff
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | templates
Files: files | file ages | folders
SHA3-256: 5afed7f577764064f8b6ed07a947a2dc490aa8ca36f6e8c1bca10813dadc515c
User & Date: bohwaz on 2021-12-21 02:18:35
Other Links: branch diff | manifest | tags
Context
2021-12-21
02:29
Last missing commit check-in: 0fa30e78e6 user: bohwaz tags: templates
02:18
Remove old stuff check-in: 5afed7f577 user: bohwaz tags: templates
02:17
More missing commits check-in: 9f798cded9 user: bohwaz tags: templates
Changes

Deleted src/include/lib/Garradin/Entities/Documents/Template.php version [57b4847de9].

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
<?php

namespace Garradin\Entities\Documents;

use Garradin\Entity;
use Garradin\ValidationException;

class Template extends Entity
{
	const TABLE = 'docs_templates';

	protected $id;
	protected $related_type;
	protected $related_to;
	protected $label;
	protected $description;
	protected $content;
	protected $created;
	protected $modified;

	protected $_types = [
		'id'           => 'int',
		'related_type' => 'string',
		'related_to'   => '?string',
		'label'        => 'string',
		'description'  => '?string',
		'content'      => 'string',
		'created'      => 'DateTime',
		'modified'     => 'DateTime',
	];

	const TYPE_USERS = 'users';
	const TYPE_ACCOUNTING = 'accounting';

	public function selfCheck(): void
	{
		parent::selfCheck();

		static $related_types = [self::USERS, self::ACCOUNTING];
		$this->assert(in_array($this->related, $related_types), 'Type inconnu');
	}
}
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<