Printing data on numpad key press, first version. Settings page for mapping key to actions.

This commit is contained in:
kplaczek
2018-05-06 21:03:42 +02:00
parent 283c5b905e
commit e5f44b92e4
12 changed files with 535 additions and 61 deletions

View File

@@ -26,9 +26,6 @@ class CinemaCinemaCity implements Cinema
if (is_null($this->cinemaId) || is_null($this->day))
throw new \Exception('Day or cinemaid not set.');
// if (!is_array($this->cinemaId)) {
// $this->cinemaId = (array)$this->cinemaId;
// }
$url = 'https://www.cinema-city.pl/pgm-list-byfeat?si=' . $this->cinemaId . '&sort=cin&bd=' . $this->day;
return file_get_contents($url);
@@ -41,9 +38,6 @@ class CinemaCinemaCity implements Cinema
$document = json_decode($document);
// $cinemaData = [];
// $text = "Repertuar Cinema-City\n";
// $text .= str_replace('/', '-', $this->day) . "\n\n";
$movies = [];
$date = date('d/m/Y', strtotime($this->day));
@@ -55,9 +49,6 @@ class CinemaCinemaCity implements Cinema
foreach ($movieData->BD as $projections) {
if ($projections->date == $date) {
foreach ($projections->P as $projection) {
// var_dump($projection);
// die();
$movie['hours'][] = $projection->time;
}
}