mirror of
https://github.com/ceratic/MediaCollectorLibary.git
synced 2026-05-13 23:56:46 +02:00
dont know ?
This commit is contained in:
@@ -122,6 +122,34 @@ class MovieController extends Controller
|
||||
// Decode metadata for display
|
||||
$metadata = json_decode($movie['metadata'], true);
|
||||
|
||||
// Extract additional fields from metadata if available
|
||||
if ($metadata) {
|
||||
// Production companies
|
||||
if (isset($metadata['production_companies']) && is_array($metadata['production_companies'])) {
|
||||
$companies = array_column($metadata['production_companies'], 'name');
|
||||
$movie['production_companies'] = implode(', ', $companies);
|
||||
}
|
||||
|
||||
// Production countries
|
||||
if (isset($metadata['production_countries']) && is_array($metadata['production_countries'])) {
|
||||
$countries = array_column($metadata['production_countries'], 'name');
|
||||
$movie['production_countries'] = implode(', ', $countries);
|
||||
}
|
||||
|
||||
// Collection info
|
||||
if (isset($metadata['belongs_to_collection']) && is_array($metadata['belongs_to_collection'])) {
|
||||
$movie['belongs_to_collection'] = $metadata['belongs_to_collection']['name'] ?? null;
|
||||
}
|
||||
|
||||
// Additional metadata fields
|
||||
//$movie['budget'] = $metadata['budget'] ?? $movie['budget'];
|
||||
//$movie['revenue'] = $metadata['revenue'] ?? $movie['revenue'];
|
||||
//$movie['original_language'] = $metadata['original_language'] ?? $movie['original_language'];
|
||||
//$movie['tagline'] = $metadata['tagline'] ?? $movie['tagline'];
|
||||
//$movie['status'] = $metadata['status'] ?? $movie['status'];
|
||||
//$movie['vote_count'] = $metadata['vote_count'] ?? $movie['vote_count'];
|
||||
}
|
||||
|
||||
// Get actors for this movie
|
||||
$stmt = $this->pdo->prepare("
|
||||
SELECT a.*
|
||||
|
||||
Reference in New Issue
Block a user