z_fileModel
extends z_model
in package
The file model handles dynamic files
Table of Contents
- add() : int
- Adds a reference to a file to the database
- getById() : array<string|int, string>
- Get a file by it's fileId
Methods
add()
Adds a reference to a file to the database
public
add(string $ref, string $type, string $name, string $extension, int $size) : int
Parameters
- $ref : string
-
The reference
- $type : string
-
Type
- $name : string
-
Name of the file
- $extension : string
-
Extension of the file
- $size : int
-
Size of the file
Return values
int —The id of the created dataset
getById()
Get a file by it's fileId
public
getById(int $fileId) : array<string|int, string>
Parameters
- $fileId : int
-
The file id
Return values
array<string|int, string> —The id of the created dataset