From 0ea3b934ddc992d089a56db286d373710d229d61 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B8rn=20=C3=85ne?= Date: Fri, 26 Aug 2016 17:54:50 +0200 Subject: [PATCH 1/2] Make dev script Linux compatible. --- dev.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev.sh b/dev.sh index 688c477..e213148 100755 --- a/dev.sh +++ b/dev.sh @@ -1,4 +1,4 @@ #!/bin/sh -which -s sqlite3 && test \! -e pvv.sqlite && sqlite3 pvv.sqlite < pvv.sql +which sqlite3 > /dev/null 2>&1 && test \! -e pvv.sqlite && sqlite3 pvv.sqlite < pvv.sql test \! -e sql_config.php && cp sql_config_example.php sql_config.php php -S [::]:1080 -t www/ From 5b5023e696a778f8a0c397a488232e35c4cb876c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B8rn=20=C3=85ne?= Date: Fri, 26 Aug 2016 17:58:43 +0200 Subject: [PATCH 2/2] Rename OnceEvent to SimpleEvent, fix regression. --- src/pvv/side/dbactivity.php | 2 +- src/pvv/side/simpleevent.php | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/pvv/side/dbactivity.php b/src/pvv/side/dbactivity.php index 5362e06..5daabbc 100644 --- a/src/pvv/side/dbactivity.php +++ b/src/pvv/side/dbactivity.php @@ -24,7 +24,7 @@ class DBActivity implements Activity { $stmt = $this->pdo->prepare($query); $stmt->execute(['date' => $date->format('Y-m-d H:i:s')]); if ($result = $stmt->fetch(PDO::FETCH_ASSOC)){ - $ev = new OnceEvent( + $ev = new SimpleEvent( $result['name'], DateTimeImmutable::createFromFormat('Y-m-d H:i:s', $result['start']), DateTimeImmutable::createFromFormat('Y-m-d H:i:s', $result['stop']), diff --git a/src/pvv/side/simpleevent.php b/src/pvv/side/simpleevent.php index f9a40fb..8cae58e 100644 --- a/src/pvv/side/simpleevent.php +++ b/src/pvv/side/simpleevent.php @@ -33,4 +33,8 @@ Class SimpleEvent extends Event { return $this->name; } + public function getURL() { + + } + }