Merge branch 'master' of https://github.com/Programvareverkstedet/nettsiden
This commit is contained in:
		
							
								
								
									
										2
									
								
								dev.sh
									
									
									
									
									
								
							
							
						
						
									
										2
									
								
								dev.sh
									
									
									
									
									
								
							@@ -1,4 +1,4 @@
 | 
				
			|||||||
#!/bin/sh
 | 
					#!/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
 | 
					test \! -e sql_config.php && cp sql_config_example.php sql_config.php
 | 
				
			||||||
php -S [::]:1080 -t www/
 | 
					php -S [::]:1080 -t www/
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -24,7 +24,7 @@ class DBActivity implements Activity {
 | 
				
			|||||||
		$stmt = $this->pdo->prepare($query);
 | 
							$stmt = $this->pdo->prepare($query);
 | 
				
			||||||
		$stmt->execute(['date' => $date->format('Y-m-d H:i:s')]);
 | 
							$stmt->execute(['date' => $date->format('Y-m-d H:i:s')]);
 | 
				
			||||||
		if ($result = $stmt->fetch(PDO::FETCH_ASSOC)){
 | 
							if ($result = $stmt->fetch(PDO::FETCH_ASSOC)){
 | 
				
			||||||
			$ev = new OnceEvent(
 | 
								$ev = new SimpleEvent(
 | 
				
			||||||
				$result['name'],
 | 
									$result['name'],
 | 
				
			||||||
				DateTimeImmutable::createFromFormat('Y-m-d H:i:s', $result['start']),
 | 
									DateTimeImmutable::createFromFormat('Y-m-d H:i:s', $result['start']),
 | 
				
			||||||
				DateTimeImmutable::createFromFormat('Y-m-d H:i:s', $result['stop']),
 | 
									DateTimeImmutable::createFromFormat('Y-m-d H:i:s', $result['stop']),
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -33,4 +33,8 @@ Class SimpleEvent extends Event {
 | 
				
			|||||||
		return $this->name;
 | 
							return $this->name;
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						public function getURL() {
 | 
				
			||||||
 | 
							
 | 
				
			||||||
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user