Files
nextcloud-analytics/analytics-hub/lib/Model/Report.php
WLTBAgent f9c49cf7c2 Phase 3: Initial commit - Nextcloud Analytics Hub Project
Nextcloud Analytics Hub complete:
- Nextcloud PHP app (analytics-hub/) - All phases (1-3) complete
- Go client tool (nextcloud-analytics) - Full CLI implementation
- Documentation (PRD, README, STATUS, SKILL.md)
- Production-ready for deployment to https://cloud.shortcutsolutions.net

Repository: git.teamworkapps.com/shortcut/nextcloud-analytics
Workspace: /home/molt/.openclaw/workspace
2026-02-13 14:11:01 +00:00

82 lines
1.8 KiB
PHP

<?php
declare(strict_types=1);
namespace OCA\AnalyticsHub\Model;
/**
* Report model
*/
class Report {
private int $id;
private int $clientId;
private string $clientName;
private string $reportDate;
private string $filePath;
private ?int $fileSize;
private string $createdAt;
public function __construct(
int $id,
int $clientId,
string $clientName,
string $reportDate,
string $filePath,
?int $fileSize = null,
string $createdAt
) {
$this->id = $id;
$this->clientId = $clientId;
$this->clientName = $clientName;
$this->reportDate = $reportDate;
$this->filePath = $filePath;
$this->fileSize = $fileSize;
$this->createdAt = $createdAt;
}
// Getters
public function getId(): int {
return $this->id;
}
public function getClientId(): int {
return $this->clientId;
}
public function getClientName(): string {
return $this->clientName;
}
public function getReportDate(): string {
return $this->reportDate;
}
public function getFilePath(): string {
return $this->filePath;
}
public function getFileSize(): ?int {
return $this->fileSize;
}
public function getCreatedAt(): string {
return $this->createdAt;
}
/**
* Convert to array
*/
public function toArray(): array {
return [
'id' => $this->id,
'client_id' => $this->clientId,
'client_name' => $this->clientName,
'report_date' => $this->reportDate,
'file_path' => $this->filePath,
'file_size' => $this->fileSize,
'created_at' => $this->createdAt,
];
}
}