add: user

This commit is contained in:
Johannes Kantz 2023-01-11 14:41:09 +01:00
parent e31b7b6319
commit 81cdae85b0

25
User.php Normal file
View File

@ -0,0 +1,25 @@
<?php
require_once("BancaDati/BancaDati.php");
use BancaDati\BancaDati;
class User {
public string $username;
public string $email;
public string $token;
private string $password;
private BancaDati $db;
public function __construct(string $username) {
$this->username = $username;
$db = new BancaDati();
return $this;
}
public function exists() {
return true;
}
public function login(string $password) : string {
// select user
// $this->db->select()
return "token";
}
}