diff --git a/code/.htaccess b/code/.htaccess deleted file mode 100644 index ba5c807bc..000000000 --- a/code/.htaccess +++ /dev/null @@ -1,7 +0,0 @@ -RewriteEngine On -RewriteBase / - -# Redirigir todo a index.php -RewriteCond %{REQUEST_FILENAME} !-f -RewriteCond %{REQUEST_FILENAME} !-d -RewriteRule ^(.+)$ index.php?url=$1 [QSA,L] diff --git a/code/a.txt b/code/a.txt deleted file mode 100644 index e69de29bb..000000000 diff --git a/code/components/footer.php b/code/components/footer.php deleted file mode 100644 index a56d0ac2b..000000000 --- a/code/components/footer.php +++ /dev/null @@ -1,3 +0,0 @@ - diff --git a/code/components/header-usuario.php b/code/components/header-usuario.php deleted file mode 100644 index d7b8397b6..000000000 --- a/code/components/header-usuario.php +++ /dev/null @@ -1,46 +0,0 @@ - - -
- - - - - - - - - -
- -
-
- - - - - diff --git a/code/components/header.php b/code/components/header.php deleted file mode 100644 index 952e974ce..000000000 --- a/code/components/header.php +++ /dev/null @@ -1,7 +0,0 @@ -
- - -
diff --git a/code/components/header/authActions.php b/code/components/header/authActions.php deleted file mode 100644 index 4c26ea4e8..000000000 --- a/code/components/header/authActions.php +++ /dev/null @@ -1,4 +0,0 @@ -
- Iniciar sesión - Únete -
diff --git a/code/components/header/campanita.php b/code/components/header/campanita.php deleted file mode 100644 index 59058cab0..000000000 --- a/code/components/header/campanita.php +++ /dev/null @@ -1,10 +0,0 @@ -
-
-
-
- Bell -
- -
-
-
\ No newline at end of file diff --git a/code/components/header/logo.php b/code/components/header/logo.php deleted file mode 100644 index 54fc51039..000000000 --- a/code/components/header/logo.php +++ /dev/null @@ -1,7 +0,0 @@ - \ No newline at end of file diff --git a/code/components/header/navLeft.php b/code/components/header/navLeft.php deleted file mode 100644 index 8faea6593..000000000 --- a/code/components/header/navLeft.php +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - diff --git a/code/components/header/navRight.php b/code/components/header/navRight.php deleted file mode 100644 index a352e7c2f..000000000 --- a/code/components/header/navRight.php +++ /dev/null @@ -1,26 +0,0 @@ - - - - diff --git a/code/components/header/profile.php b/code/components/header/profile.php deleted file mode 100644 index 8f3b0b7e8..000000000 --- a/code/components/header/profile.php +++ /dev/null @@ -1,50 +0,0 @@ - - -
- - - -
diff --git a/code/components/main.php b/code/components/main.php deleted file mode 100644 index f5b639ee4..000000000 --- a/code/components/main.php +++ /dev/null @@ -1,96 +0,0 @@ - -
- - - - -
- - - - - -
-
- - - - diff --git a/code/components/modal-login.php b/code/components/modal-login.php deleted file mode 100644 index ea88cf245..000000000 --- a/code/components/modal-login.php +++ /dev/null @@ -1,82 +0,0 @@ -
-
- × - - -
-
-

Bienvenido

-
- - - - - - -
- -
- -
- - - - -
-
-
- - - -
- - - - - - - diff --git a/code/config/database.php b/code/config/database.php deleted file mode 100644 index ab2ee6c1d..000000000 --- a/code/config/database.php +++ /dev/null @@ -1,24 +0,0 @@ - PDO::ERRMODE_EXCEPTION, - PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC, - PDO::ATTR_EMULATE_PREPARES => false - ]; - return new PDO($dsn, self::$user, self::$pass, $options); - } catch (PDOException $e) { - die("Error en la conexión: " . $e->getMessage()); - } - } -} diff --git a/code/controllers/AdministradorController.php b/code/controllers/AdministradorController.php deleted file mode 100644 index 60c617631..000000000 --- a/code/controllers/AdministradorController.php +++ /dev/null @@ -1,65 +0,0 @@ -getAll(); - Core\View::render('adminPanel/administrador/index', ['administradores' => $admins]); - } - - public function create() { - Core\View::render('adminPanel/administrador/create'); - } - - public function store() { - $nombre = filter_input(INPUT_POST, 'nombre', FILTER_SANITIZE_STRING); - $correo = filter_input(INPUT_POST, 'correo', FILTER_SANITIZE_EMAIL); - $telefono = filter_input(INPUT_POST, 'telefono', FILTER_SANITIZE_STRING); - $especialidad = filter_input(INPUT_POST, 'especialidad', FILTER_SANITIZE_STRING); - $estado = filter_input(INPUT_POST, 'estado', FILTER_SANITIZE_STRING); - $cantrep = filter_input(INPUT_POST, 'cantrep_resuelto', FILTER_VALIDATE_INT); - - if ($nombre && $correo && $telefono) { - $admin = new Administrador(); - $admin->create($nombre, $correo, $telefono, $especialidad, $estado, $cantrep); - } - header('Location: index.php?controller=administrador&action=index'); - } - - public function edit() { - $id = filter_input(INPUT_GET, 'id', FILTER_VALIDATE_INT); - if ($id) { - $admin = new Administrador(); - $data = $admin->getById($id); - Core\View::render('adminPanel/administrador/edit', ['admin' => $data]); - } - } - - public function update() { - $id = filter_input(INPUT_POST, 'id', FILTER_VALIDATE_INT); - $nombre = filter_input(INPUT_POST, 'nombre', FILTER_SANITIZE_STRING); - $correo = filter_input(INPUT_POST, 'correo', FILTER_SANITIZE_EMAIL); - $telefono = filter_input(INPUT_POST, 'telefono', FILTER_SANITIZE_STRING); - $especialidad = filter_input(INPUT_POST, 'especialidad', FILTER_SANITIZE_STRING); - $estado = filter_input(INPUT_POST, 'estado', FILTER_SANITIZE_STRING); - $cantrep = filter_input(INPUT_POST, 'cantrep_resuelto', FILTER_VALIDATE_INT); - - if ($id && $nombre && $correo && $telefono) { - $admin = new Administrador(); - $admin->update($id, $nombre, $correo, $telefono, $especialidad, $estado, $cantrep); - } - header('Location: index.php?controller=administrador&action=index'); - } - - public function delete() { - $id = filter_input(INPUT_GET, 'id', FILTER_VALIDATE_INT); - if ($id) { - $admin = new Administrador(); - $admin->delete($id); - } - header('Location: index.php?controller=administrador&action=index'); - } -} \ No newline at end of file diff --git a/code/controllers/ClienteController.php b/code/controllers/ClienteController.php deleted file mode 100644 index b29250a2d..000000000 --- a/code/controllers/ClienteController.php +++ /dev/null @@ -1,78 +0,0 @@ -getAll(); - Core\View::render('cliente/index', ['clientes' => $clientes]); - } - - public function create() { - Core\View::render('cliente/create'); - } - - public function store() { - $nombre = filter_input(INPUT_POST, 'nombre', FILTER_SANITIZE_STRING); - $correo = filter_input(INPUT_POST, 'correo', FILTER_SANITIZE_EMAIL); - $telefono = filter_input(INPUT_POST, 'telefono', FILTER_SANITIZE_STRING); - $calificaciones = filter_input(INPUT_POST, 'calificaciones', FILTER_VALIDATE_INT); - - if ($nombre && $correo && $telefono !== false) { - $cliente = new Cliente(); - $cliente->create($nombre, $correo, $telefono, $calificaciones); - } - header('Location: index.php?controller=cliente&action=index'); - } - - public function edit() { - $id = filter_input(INPUT_GET, 'id', FILTER_VALIDATE_INT); - if ($id) { - $cliente = new Cliente(); - $data = $cliente->getById($id); - Core\View::render('cliente/edit', ['cliente' => $data]); - } - } - - public function update() { - $id = filter_input(INPUT_POST, 'id', FILTER_VALIDATE_INT); - $nombre = filter_input(INPUT_POST, 'nombre', FILTER_SANITIZE_STRING); - $correo = filter_input(INPUT_POST, 'correo', FILTER_SANITIZE_EMAIL); - $telefono = filter_input(INPUT_POST, 'telefono', FILTER_SANITIZE_STRING); - $calificaciones = filter_input(INPUT_POST, 'calificaciones', FILTER_VALIDATE_INT); - - if ($id && $nombre && $correo && $telefono !== false) { - $cliente = new Cliente(); - $cliente->update($id, $nombre, $correo, $telefono, $calificaciones); - } - header('Location: index.php?controller=cliente&action=index'); - } - - public function delete() { - $id = filter_input(INPUT_GET, 'id', FILTER_VALIDATE_INT); - if ($id) { - $cliente = new Cliente(); - $cliente->delete($id); - } - header('Location: index.php?controller=cliente&action=index'); - } -} diff --git a/code/controllers/FacebookAuthController.php b/code/controllers/FacebookAuthController.php deleted file mode 100644 index 34c868b92..000000000 --- a/code/controllers/FacebookAuthController.php +++ /dev/null @@ -1,70 +0,0 @@ -usuarioModel = new Usuario(); - $this->fb = new \Facebook\Facebook([ - 'app_id' => 'TU_APP_ID', - 'app_secret' => 'TU_APP_SECRET', - 'default_graph_version' => 'v19.0', - ]); - } - - public function login() - { - $helper = $this->fb->getRedirectLoginHelper(); - $permissions = ['email']; - $callbackUrl = 'http://localhost/QueLaburo/index.php?controller=facebookAuth&action=callback'; - $loginUrl = $helper->getLoginUrl($callbackUrl, $permissions); - header('Location: ' . $loginUrl); - exit; - } - - public function callback() - { - $helper = $this->fb->getRedirectLoginHelper(); - try { - $accessToken = $helper->getAccessToken(); - } catch (Exception $e) { - die('Error: ' . $e->getMessage()); - } - - if (!isset($accessToken)) { - header('Location: index.php?controller=login&action=index'); - exit; - } - - $response = $this->fb->get('/me?fields=id,name,email,picture', $accessToken); - $info = $response->getGraphUser(); - - $correo = $info['email']; - $nombre = $info['name']; - $foto = $info['picture']['url']; - $id_oauth = $info['id']; - - $user = $this->usuarioModel->buscarPorCorreo($correo); - if (!$user) { - $this->usuarioModel->createOAuthUser($nombre, $correo, $foto, 'facebook', $id_oauth); - $user = $this->usuarioModel->buscarPorCorreo($correo); - } - - $_SESSION['usuario'] = [ - 'id' => $user['id'], - 'nombre' => $user['nombre'], - 'correo' => $user['correo'], - 'foto' => $user['foto_perfil'], - 'es_cliente' => $user['es_cliente'] ?? false, - 'es_proveedor' => $user['es_proveedor'] ?? false - ]; - - header('Location: index.php?controller=usuario&action=index'); - exit; - } -} diff --git a/code/controllers/GestionaController.php b/code/controllers/GestionaController.php deleted file mode 100644 index e7299a8be..000000000 --- a/code/controllers/GestionaController.php +++ /dev/null @@ -1,79 +0,0 @@ -getAll(); - Core\View::render('gestiona/index', ['datos' => $datos]); - } - - public function create() { - Core\View::render('gestiona/create'); - } - - public function store() { - $id_usuario = filter_input(INPUT_POST, 'id_usuario', FILTER_VALIDATE_INT); - $id_administrador = filter_input(INPUT_POST, 'id_administrador', FILTER_VALIDATE_INT); - $fecha_gestion = filter_input(INPUT_POST, 'fecha_gestion', FILTER_SANITIZE_STRING); - $descripcion = filter_input(INPUT_POST, 'descripcion', FILTER_SANITIZE_STRING); - - if ($id_usuario && $id_administrador) { - $gestiona = new Gestiona(); - $gestiona->create($id_usuario, $id_administrador, $fecha_gestion, $descripcion); - } - header('Location: index.php?controller=gestiona&action=index'); - } - - public function edit() { - $id_usuario = filter_input(INPUT_GET, 'id_usuario', FILTER_VALIDATE_INT); - $id_administrador = filter_input(INPUT_GET, 'id_administrador', FILTER_VALIDATE_INT); - - if ($id_usuario && $id_administrador) { - $gestiona = new Gestiona(); - $dato = $gestiona->getById($id_usuario, $id_administrador); - Core\View::render('gestiona/edit', ['dato' => $dato]); - } - } - - public function update() { - $id_usuario = filter_input(INPUT_POST, 'id_usuario', FILTER_VALIDATE_INT); - $id_administrador = filter_input(INPUT_POST, 'id_administrador', FILTER_VALIDATE_INT); - $fecha_gestion = filter_input(INPUT_POST, 'fecha_gestion', FILTER_SANITIZE_STRING); - $descripcion = filter_input(INPUT_POST, 'descripcion', FILTER_SANITIZE_STRING); - - if ($id_usuario && $id_administrador) { - $gestiona = new Gestiona(); - $gestiona->update($id_usuario, $id_administrador, $fecha_gestion, $descripcion); - } - header('Location: index.php?controller=gestiona&action=index'); - } - - public function delete() { - $id_usuario = filter_input(INPUT_GET, 'id_usuario', FILTER_VALIDATE_INT); - $id_administrador = filter_input(INPUT_GET, 'id_administrador', FILTER_VALIDATE_INT); - - if ($id_usuario && $id_administrador) { - $gestiona = new Gestiona(); - $gestiona->delete($id_usuario, $id_administrador); - } - header('Location: index.php?controller=gestiona&action=index'); - } -} diff --git a/code/controllers/GoogleAuthController.php b/code/controllers/GoogleAuthController.php deleted file mode 100644 index 5066bd477..000000000 --- a/code/controllers/GoogleAuthController.php +++ /dev/null @@ -1,64 +0,0 @@ -usuarioModel = new Usuario(); - - $this->client = new Google_Client(); - $this->client->setClientId('TU_CLIENT_ID'); - $this->client->setClientSecret('TU_CLIENT_SECRET'); - $this->client->setRedirectUri('http://localhost/QueLaburo/index.php?controller=googleAuth&action=callback'); - $this->client->addScope('email'); - $this->client->addScope('profile'); - } - - public function login() - { - $authUrl = $this->client->createAuthUrl(); - header('Location: ' . filter_var($authUrl, FILTER_SANITIZE_URL)); - exit; - } - - public function callback() - { - if (isset($_GET['code'])) { - $token = $this->client->fetchAccessTokenWithAuthCode($_GET['code']); - $this->client->setAccessToken($token); - - $oauth2 = new Google_Service_Oauth2($this->client); - $info = $oauth2->userinfo->get(); - - $correo = $info->email; - $nombre = $info->name; - $foto = $info->picture; - $id_oauth = $info->id; - - // Verificar si ya existe el usuario - $user = $this->usuarioModel->buscarPorCorreo($correo); - if (!$user) { - // Registrar nuevo usuario sin contraseña - $this->usuarioModel->createOAuthUser($nombre, $correo, $foto, 'google', $id_oauth); - $user = $this->usuarioModel->buscarPorCorreo($correo); - } - - $_SESSION['usuario'] = [ - 'id' => $user['id'], - 'nombre' => $user['nombre'], - 'correo' => $user['correo'], - 'foto' => $user['foto_perfil'], - 'es_cliente' => $user['es_cliente'] ?? false, - 'es_proveedor' => $user['es_proveedor'] ?? false - ]; - - header('Location: index.php?controller=usuario&action=index'); - exit; - } - } -} diff --git a/code/controllers/LoginController.php b/code/controllers/LoginController.php deleted file mode 100644 index c4425dc7f..000000000 --- a/code/controllers/LoginController.php +++ /dev/null @@ -1,177 +0,0 @@ -usuarioModel = new Usuario(); - } - - public function index($error = '') { - require 'views/login/login.php'; - } - - - - - // ========================================================= - // LOGIN NORMAL - // ========================================================= - public function authenticate() - { - if ($_SERVER['REQUEST_METHOD'] === 'POST') - { - $correo = $_POST['correo'] ?? ''; - $password = $_POST['password'] ?? ''; - - $sqli_patterns = [ - '/(\bor\b|\band\b)\s+\d+=\d+/i', - '/(\'|")\s*--/', - '/union\s+select/i', - '/drop\s+table/i', - '/insert\s+into/i', - '/delete\s+from/i', - '/--|;|#/' - ]; - - $sqli_detected = false; - - foreach ($sqli_patterns as $pattern) { - if (preg_match($pattern, $correo) || preg_match($pattern, $password)) { - $sqli_detected = true; - break; - } - } - - if ($sqli_detected) { - $error = "Intento de inyección SQL detectado."; - require 'views/login/login.php'; - return; - } - - $user = $this->usuarioModel->login($correo, $password); - - if ($user) - { - $_SESSION['usuario'] = [ - 'id' => $user['id'], - 'nombre' => $user['nombre'], - 'correo' => $user['correo'], - 'es_cliente' => $user['es_cliente'], - 'es_proveedor' => $user['es_proveedor'] - ]; - - header('Location: index.php?controller=usuario&action=index'); - exit; - } - else - { - $error = "Correo o contraseña incorrectos"; - require 'views/login/login.php'; - } - } - } - - // ========================================================= - // REGISTRO - // ========================================================= - public function registerview() - { - header('Location: index.php?controller=usuario&action=index&mode=register'); - exit; - } - - /** - * Registro de usuario - * - * Verifica que se haya realizado un pedido POST y que se hayan proporcionado - * todos los campos necesarios. Luego, verifica que las contraseñas sean iguales, que - * se haya aceptado los términos y condiciones, y que el correo no esté registrado. - * Si no hay errores, crea un nuevo usuario con la contraseña hasheada y redirige - * a la página de inicio con un parámetro de éxito. - * Si hay errores, muestra la vista de login con los mensajes de error correspondientes. - */ - public function register() - { - if ($_SERVER['REQUEST_METHOD'] === 'POST') - { - $nombre = trim($_POST['nombre'] ?? ''); - $apellido = trim($_POST['apellido'] ?? ''); - $correo = trim($_POST['correo'] ?? ''); - $telefono = trim($_POST['telefono'] ?? ''); - $password = trim($_POST['password'] ?? ''); - $confirm = trim($_POST['confirm_password'] ?? ''); - $terms = isset($_POST['terms']); - - $errors = []; - - if (!$nombre || !$apellido || !$correo || !$password || !$confirm) - $errors[] = "Todos los campos son obligatorios."; - if ($password !== $confirm) - $errors[] = "Las contraseñas no coinciden."; - if (!$terms) - $errors[] = "Debe aceptar los términos y condiciones."; - if ($this->usuarioModel->exists($correo)) - $errors[] = "El correo ya está registrado."; - if (!$telefono) - $errors[] = "Debe ingresar su teléfono."; - - if (empty($errors)) - { - $hashedPassword = password_hash($password, PASSWORD_DEFAULT); - $this->usuarioModel->create($nombre . ' ' . $apellido, $correo, $telefono, $hashedPassword); - header('Location: index.php?controller=usuario&action=index&success=1'); - exit; - } else { - require 'views/login/login.php'; - } - } else { - require 'views/login/login.php'; - } - } - - // ========================================================= - // COMPLETAR REGISTRO GOOGLE - // ========================================================= - - public function completarGoogle() -{ - if ($_SERVER['REQUEST_METHOD'] === 'POST') { - $nombre = trim($_POST['nombre'] ?? ''); - $telefono = trim($_POST['telefono'] ?? ''); - $correo = trim($_POST['correo'] ?? ''); - $google_uid = trim($_POST['google_uid'] ?? ''); - - if (!$nombre || !$telefono || !$correo || !$google_uid) { - echo json_encode(['success' => false, 'message' => 'Faltan datos']); - return; - } - - $user = $this->usuarioModel->getByEmail($correo); - - if ($user) { - $this->usuarioModel->update($user['id'], $nombre, $correo, $telefono); - echo json_encode(['success' => true, 'message' => 'Usuario completado']); - } else { - // Crea usuario nuevo correctamente - $passwordRandom = password_hash(bin2hex(random_bytes(5)), PASSWORD_DEFAULT); - $this->usuarioModel->create($nombre, $correo, $telefono, $passwordRandom, $google_uid); - echo json_encode(['success' => true, 'message' => 'Usuario creado']); - } - } -} - - - // ========================================================= - // LOGOUT - // ========================================================= - public function logout() - { - session_destroy(); - header('Location: index.php?controller=usuario&action=index'); - exit; - } -} diff --git a/code/controllers/MensajeController.php b/code/controllers/MensajeController.php deleted file mode 100644 index 05bd4bca4..000000000 --- a/code/controllers/MensajeController.php +++ /dev/null @@ -1,84 +0,0 @@ -getAll(); - Core\View::render('mensaje/index', ['mensajes' => $mensajes]); - } - - public function create() { - Core\View::render('mensaje/create'); - } - - public function store() { - $id_usuario = filter_input(INPUT_POST, 'id_usuario', FILTER_VALIDATE_INT); - $id_emisor = filter_input(INPUT_POST, 'id_emisor', FILTER_VALIDATE_INT); - $id_receptor = filter_input(INPUT_POST, 'id_receptor', FILTER_VALIDATE_INT); - $id_mensaje = filter_input(INPUT_POST, 'id_mensaje', FILTER_VALIDATE_INT); - $estado = filter_input(INPUT_POST, 'estado', FILTER_SANITIZE_STRING); - $notificacion = filter_input(INPUT_POST, 'notificacion', FILTER_SANITIZE_STRING); - $fecha = filter_input(INPUT_POST, 'fecha', FILTER_SANITIZE_STRING); - - if ($id_usuario && $id_emisor && $id_receptor && $id_mensaje) { - $msg = new Mensaje(); - $msg->create($id_usuario, $id_emisor, $id_receptor, $id_mensaje, $estado, $notificacion, $fecha); - } - header('Location: index.php?controller=mensaje&action=index'); - } - - public function edit() { - $id_usuario = filter_input(INPUT_GET, 'id_usuario', FILTER_VALIDATE_INT); - $id_mensaje = filter_input(INPUT_GET, 'id_mensaje', FILTER_VALIDATE_INT); - - if ($id_usuario && $id_mensaje) { - $msg = new Mensaje(); - $data = $msg->getById($id_usuario, $id_mensaje); - Core\View::render('mensaje/edit', ['mensaje' => $data]); - } - } - - public function update() { - $id_usuario = filter_input(INPUT_POST, 'id_usuario', FILTER_VALIDATE_INT); - $id_mensaje = filter_input(INPUT_POST, 'id_mensaje', FILTER_VALIDATE_INT); - $estado = filter_input(INPUT_POST, 'estado', FILTER_SANITIZE_STRING); - $notificacion = filter_input(INPUT_POST, 'notificacion', FILTER_SANITIZE_STRING); - - if ($id_usuario && $id_mensaje) { - $msg = new Mensaje(); - $msg->update($id_usuario, $id_mensaje, $estado, $notificacion); - } - header('Location: index.php?controller=mensaje&action=index'); - } - - public function delete() { - $id_usuario = filter_input(INPUT_GET, 'id_usuario', FILTER_VALIDATE_INT); - $id_mensaje = filter_input(INPUT_GET, 'id_mensaje', FILTER_VALIDATE_INT); - - if ($id_usuario && $id_mensaje) { - $msg = new Mensaje(); - $msg->delete($id_usuario, $id_mensaje); - } - header('Location: index.php?controller=mensaje&action=index'); - } -} diff --git a/code/controllers/OfreceController.php b/code/controllers/OfreceController.php deleted file mode 100644 index 297761bfa..000000000 --- a/code/controllers/OfreceController.php +++ /dev/null @@ -1,53 +0,0 @@ -getAll(); - Core\View::render('ofrece/index', ['datos' => $datos]); - } - - public function create() { - Core\View::render('ofrece/create'); - } - - public function store() { - $id_proveedor = filter_input(INPUT_POST, 'id_proveedor', FILTER_VALIDATE_INT); - $id_servicio = filter_input(INPUT_POST, 'id_servicio', FILTER_VALIDATE_INT); - - if ($id_proveedor && $id_servicio) { - $ofrece = new Ofrece(); - $ofrece->create($id_proveedor, $id_servicio); - } - header('Location: index.php?controller=ofrece&action=index'); - } - - public function delete() { - $id_proveedor = filter_input(INPUT_GET, 'id_proveedor', FILTER_VALIDATE_INT); - $id_servicio = filter_input(INPUT_GET, 'id_servicio', FILTER_VALIDATE_INT); - - if ($id_proveedor && $id_servicio) { - $ofrece = new Ofrece(); - $ofrece->delete($id_proveedor, $id_servicio); - } - header('Location: index.php?controller=ofrece&action=index'); - } -} diff --git a/code/controllers/ProveedorController.php b/code/controllers/ProveedorController.php deleted file mode 100644 index 15b3f86f2..000000000 --- a/code/controllers/ProveedorController.php +++ /dev/null @@ -1,91 +0,0 @@ -getAll(); - Core\View::render('proveedor/index', ['proveedores' => $proveedores]); - } - - public function create() { - Core\View::render('adminPanel/proveedor/create'); - } - - public function store() { - // Sanitización manual - $nombre = filter_input(INPUT_POST, 'nombre', FILTER_UNSAFE_RAW); - $nombre = $nombre ? trim(strip_tags($nombre)) : null; - - $correo = filter_input(INPUT_POST, 'correo', FILTER_SANITIZE_EMAIL); - - $telefono = filter_input(INPUT_POST, 'telefono', FILTER_UNSAFE_RAW); - $telefono = $telefono ? trim(strip_tags($telefono)) : null; - - $referencias = filter_input(INPUT_POST, 'referencias', FILTER_UNSAFE_RAW); - $referencias = $referencias ? trim(strip_tags($referencias)) : null; - - $calificacion = filter_input(INPUT_POST, 'calificacion', FILTER_VALIDATE_FLOAT); - $ventas = filter_input(INPUT_POST, 'cantidad_ventas', FILTER_VALIDATE_INT); - - // Validación mínima: que nombre, correo y telefono existan - if ($nombre && $correo && $telefono) - { - $proveedor = new Proveedor(); - $proveedor->create($nombre, $correo, $telefono, $referencias, $calificacion, $ventas); - } - - header('Location: index.php?controller=proveedor&action=index'); -} - - public function edit() { - $id = filter_input(INPUT_GET, 'id', FILTER_VALIDATE_INT); - if ($id) { - $proveedor = new Proveedor(); - $data = $proveedor->getById($id); - Core\View::render('adminPanel/proveedor/edit', ['proveedor' => $data]); - } - } - - public function update() { - $id = filter_input(INPUT_POST, 'id', FILTER_VALIDATE_INT); - $nombre = filter_input(INPUT_POST, 'nombre', FILTER_SANITIZE_STRING); - $correo = filter_input(INPUT_POST, 'correo', FILTER_SANITIZE_EMAIL); - $telefono = filter_input(INPUT_POST, 'telefono', FILTER_SANITIZE_STRING); - $referencias = filter_input(INPUT_POST, 'referencias', FILTER_SANITIZE_STRING); - $calificacion = filter_input(INPUT_POST, 'calificacion', FILTER_VALIDATE_FLOAT); - $ventas = filter_input(INPUT_POST, 'cantidad_ventas', FILTER_VALIDATE_INT); - - if ($id && $nombre && $correo && $telefono !== false) { - $proveedor = new Proveedor(); - $proveedor->update($id, $nombre, $correo, $telefono, $referencias, $calificacion, $ventas); - } - header('Location: index.php?controller=proveedor&action=index'); - } - - public function delete() { - $id = filter_input(INPUT_GET, 'id', FILTER_VALIDATE_INT); - if ($id) { - $proveedor = new Proveedor(); - $proveedor->delete($id); - } - header('Location: index.php?controller=proveedor&action=index'); - } -} \ No newline at end of file diff --git a/code/controllers/ReservaController.php b/code/controllers/ReservaController.php deleted file mode 100644 index a95a90b13..000000000 --- a/code/controllers/ReservaController.php +++ /dev/null @@ -1,89 +0,0 @@ -getAll(); - Core\View::render('reserva/index', ['reservas' => $reservas]); - } - - public function create() { - Core\View::render('reserva/create'); - } - - public function store() { - $id_reserva = filter_input(INPUT_POST, 'id_reserva', FILTER_VALIDATE_INT); - $id_cliente = filter_input(INPUT_POST, 'id_cliente', FILTER_VALIDATE_INT); - $id_proveedor = filter_input(INPUT_POST, 'id_proveedor', FILTER_VALIDATE_INT); - $id_servicio = filter_input(INPUT_POST, 'id_servicio', FILTER_VALIDATE_INT); - $recordatorio = filter_input(INPUT_POST, 'recordatorio', FILTER_SANITIZE_STRING); - $resena = filter_input(INPUT_POST, 'resena', FILTER_SANITIZE_STRING); - $fecha_reserva = filter_input(INPUT_POST, 'fecha_reserva', FILTER_SANITIZE_STRING); - - if ($id_reserva && $id_cliente && $id_proveedor && $id_servicio) { - $reserva = new Reserva(); - $reserva->create($id_reserva, $id_cliente, $id_proveedor, $id_servicio, $recordatorio, $resena, $fecha_reserva); - } - header('Location: index.php?controller=reserva&action=index'); - } - - public function edit() { - $id_reserva = filter_input(INPUT_GET, 'id_reserva', FILTER_VALIDATE_INT); - $id_cliente = filter_input(INPUT_GET, 'id_cliente', FILTER_VALIDATE_INT); - $id_proveedor = filter_input(INPUT_GET, 'id_proveedor', FILTER_VALIDATE_INT); - $id_servicio = filter_input(INPUT_GET, 'id_servicio', FILTER_VALIDATE_INT); - - if ($id_reserva && $id_cliente && $id_proveedor && $id_servicio) { - $reserva = new Reserva(); - $data = $reserva->getById($id_reserva, $id_cliente, $id_proveedor, $id_servicio); - Core\View::render('reserva/edit', ['reserva' => $data]); - } - } - - public function update() { - $id_reserva = filter_input(INPUT_POST, 'id_reserva', FILTER_VALIDATE_INT); - $id_cliente = filter_input(INPUT_POST, 'id_cliente', FILTER_VALIDATE_INT); - $id_proveedor = filter_input(INPUT_POST, 'id_proveedor', FILTER_VALIDATE_INT); - $id_servicio = filter_input(INPUT_POST, 'id_servicio', FILTER_VALIDATE_INT); - $recordatorio = filter_input(INPUT_POST, 'recordatorio', FILTER_SANITIZE_STRING); - $resena = filter_input(INPUT_POST, 'resena', FILTER_SANITIZE_STRING); - $fecha_reserva = filter_input(INPUT_POST, 'fecha_reserva', FILTER_SANITIZE_STRING); - - if ($id_reserva && $id_cliente && $id_proveedor && $id_servicio) { - $reserva = new Reserva(); - $reserva->update($id_reserva, $id_cliente, $id_proveedor, $id_servicio, $recordatorio, $resena, $fecha_reserva); - } - header('Location: index.php?controller=reserva&action=index'); - } - - public function delete() { - $id_reserva = filter_input(INPUT_GET, 'id_reserva', FILTER_VALIDATE_INT); - $id_cliente = filter_input(INPUT_GET, 'id_cliente', FILTER_VALIDATE_INT); - $id_proveedor = filter_input(INPUT_GET, 'id_proveedor', FILTER_VALIDATE_INT); - $id_servicio = filter_input(INPUT_GET, 'id_servicio', FILTER_VALIDATE_INT); - - if ($id_reserva && $id_cliente && $id_proveedor && $id_servicio) { - $reserva = new Reserva(); - $reserva->delete($id_reserva, $id_cliente, $id_proveedor, $id_servicio); - } - header('Location: index.php?controller=reserva&action=index'); - } -} diff --git a/code/controllers/ServicioController.php b/code/controllers/ServicioController.php deleted file mode 100644 index a5d3dd59c..000000000 --- a/code/controllers/ServicioController.php +++ /dev/null @@ -1,77 +0,0 @@ -getAll(); // Trae los servicios de la BD - View::render('servicio/index', ['servicios' => $servicios]); - } - - public function create() { - Core\View::render('servicio/create'); - } - - public function store() { - $disponibilidad = filter_input(INPUT_POST, 'disponibilidad', FILTER_SANITIZE_STRING); - $categoria = filter_input(INPUT_POST, 'categoria', FILTER_SANITIZE_STRING); - $descripcion = filter_input(INPUT_POST, 'descripcion', FILTER_SANITIZE_STRING); - $precio = filter_input(INPUT_POST, 'precio', FILTER_VALIDATE_FLOAT); - $titulo = filter_input(INPUT_POST, 'titulo', FILTER_SANITIZE_STRING); - $imagen = filter_input(INPUT_POST, 'imagen', FILTER_SANITIZE_STRING); - - if ($titulo && $precio !== false) { - $servicio = new Servicio(); - $servicio->create($disponibilidad, $categoria, $descripcion, $precio, $titulo, $imagen); - } - - header('Location: index.php?controller=servicio&action=index'); - } - - public function edit() { - $id = filter_input(INPUT_GET, 'id', FILTER_VALIDATE_INT); - if ($id) { - $servicio = new Servicio(); - $data = $servicio->getById($id); - Core\View::render('servicio/edit', ['servicio' => $data]); - } - } - - public function update() { - $id = filter_input(INPUT_POST, 'id', FILTER_VALIDATE_INT); - $disponibilidad = filter_input(INPUT_POST, 'disponibilidad', FILTER_SANITIZE_STRING); - $categoria = filter_input(INPUT_POST, 'categoria', FILTER_SANITIZE_STRING); - $descripcion = filter_input(INPUT_POST, 'descripcion', FILTER_SANITIZE_STRING); - $precio = filter_input(INPUT_POST, 'precio', FILTER_VALIDATE_FLOAT); - $titulo = filter_input(INPUT_POST, 'titulo', FILTER_SANITIZE_STRING); - $imagen = filter_input(INPUT_POST, 'imagen', FILTER_SANITIZE_STRING); - - if ($id && $titulo && $precio !== false) { - $servicio = new Servicio(); - $servicio->update($id, $disponibilidad, $categoria, $descripcion, $precio, $titulo, $imagen); - } - - header('Location: index.php?controller=servicio&action=index'); - } - - public function delete() { - $id = filter_input(INPUT_GET, 'id', FILTER_VALIDATE_INT); - if ($id) { - $servicio = new Servicio(); - $servicio->delete($id); - } - - header('Location: index.php?controller=servicio&action=index'); - } -} diff --git a/code/controllers/UsuarioController.php b/code/controllers/UsuarioController.php deleted file mode 100644 index 30b698b76..000000000 --- a/code/controllers/UsuarioController.php +++ /dev/null @@ -1,83 +0,0 @@ -redirect('index.php?controller=usuario&action=index'); - // } - } - - /** - * Vista principal de usuario - */ - public function index() { - // Cargamos los servicios para el carrusel - $servicioModel = new Servicio(); - $servicios = $servicioModel->getAll(); - - // Opcional: si quieres usuarios también - $usuarioModel = new Usuario(); - $usuarios = $usuarioModel->getAll(); - - // Renderizamos la vista usuario/index.php pasando $servicios - $this->render('usuario/index', [ - 'servicios' => $servicios, - 'usuarios' => $usuarios // si quieres usar usuarios en la vista - ]); - } - - /** - * Vista principal para admin - */ - public function indexA() { - $usuarioModel = new Usuario(); - $usuarios = $usuarioModel->getAll(); - $this->render('adminPanel/usuario/indexA', ['usuarios' => $usuarios]); - } - - /** - * Crear usuario - */ - public function create() { - $this->render('adminPanel/usuario/create'); - } - - /** - * Editar usuario - */ - public function edit() { - $id = filter_input(INPUT_GET, 'id', FILTER_VALIDATE_INT); - if ($id) { - $usuarioModel = new Usuario(); - $data = $usuarioModel->getById($id); - $this->render('adminPanel/usuario/edit', ['usuario' => $data]); - } - } - - /** - * Ver perfil de usuario - */ - public function verPerfil() { - $id = filter_input(INPUT_GET, 'id', FILTER_VALIDATE_INT); - if (!$id) { - $id = 1; // Valor predeterminado - } - - $usuarioModel = new Usuario(); - $data = $usuarioModel->getById($id); - - if ($data) { - $this->render('usuario/perfil', ['usuario' => $data]); - return; - } - - $this->redirect('index.php?controller=usuario&action=index'); - } -} diff --git a/code/core/Controller.php b/code/core/Controller.php deleted file mode 100644 index 4605cae1b..000000000 --- a/code/core/Controller.php +++ /dev/null @@ -1,13 +0,0 @@ -db = new PDO( - 'mysql:host=sql204.infinityfree.com;dbname=if0_40213381_quelaburo;charset=utf8mb4', - 'if0_40213381', - 'H1temJTycUHVo', - [ - PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION, - PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC, - PDO::ATTR_EMULATE_PREPARES => false, - ] - ); - } catch (PDOException $e) { - die('Error de conexión a base de datos'); - } - } -} diff --git a/code/core/Router.php b/code/core/Router.php deleted file mode 100644 index 13a000984..000000000 --- a/code/core/Router.php +++ /dev/null @@ -1,35 +0,0 @@ -$action(); - } -} diff --git a/code/core/View.php b/code/core/View.php deleted file mode 100644 index bf8e6409f..000000000 --- a/code/core/View.php +++ /dev/null @@ -1,9 +0,0 @@ - - - diff --git a/code/css/storage/campanita.svg b/code/css/storage/campanita.svg deleted file mode 100644 index 7b105babf..000000000 --- a/code/css/storage/campanita.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - - \ No newline at end of file diff --git a/code/css/storage/card-image.svg b/code/css/storage/card-image.svg deleted file mode 100644 index b352fda94..000000000 --- a/code/css/storage/card-image.svg +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/code/css/storage/error_bg_alfaCod_v0.1.jpg b/code/css/storage/error_bg_alfaCod_v0.1.jpg deleted file mode 100644 index fd5055784..000000000 Binary files a/code/css/storage/error_bg_alfaCod_v0.1.jpg and /dev/null differ diff --git a/code/css/storage/facebook.svg b/code/css/storage/facebook.svg deleted file mode 100644 index 9d7e38435..000000000 --- a/code/css/storage/facebook.svg +++ /dev/null @@ -1,2 +0,0 @@ - - \ No newline at end of file diff --git a/code/css/storage/filtrito.svg b/code/css/storage/filtrito.svg deleted file mode 100644 index 6b8eb82c0..000000000 --- a/code/css/storage/filtrito.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/code/css/storage/flechitaAbajo.svg b/code/css/storage/flechitaAbajo.svg deleted file mode 100644 index 6e4d7ae92..000000000 --- a/code/css/storage/flechitaAbajo.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/code/css/storage/flechitaDer.svg b/code/css/storage/flechitaDer.svg deleted file mode 100644 index d7baf0240..000000000 --- a/code/css/storage/flechitaDer.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/code/css/storage/flechitaIzq.svg b/code/css/storage/flechitaIzq.svg deleted file mode 100644 index d5a376aed..000000000 --- a/code/css/storage/flechitaIzq.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/code/css/storage/google.svg b/code/css/storage/google.svg deleted file mode 100644 index cf464af16..000000000 --- a/code/css/storage/google.svg +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - \ No newline at end of file diff --git a/code/css/storage/hamburguesita.svg b/code/css/storage/hamburguesita.svg deleted file mode 100644 index 1a9a5f906..000000000 --- a/code/css/storage/hamburguesita.svg +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/code/css/storage/logout.svg b/code/css/storage/logout.svg deleted file mode 100644 index 3fe316665..000000000 --- a/code/css/storage/logout.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - - \ No newline at end of file diff --git a/code/css/storage/lupita.svg b/code/css/storage/lupita.svg deleted file mode 100644 index 325c9fb07..000000000 --- a/code/css/storage/lupita.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/code/css/storage/perfilsito.svg b/code/css/storage/perfilsito.svg deleted file mode 100644 index fdf62c3ca..000000000 --- a/code/css/storage/perfilsito.svg +++ /dev/null @@ -1,24 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/code/css/storage/reservas.svg b/code/css/storage/reservas.svg deleted file mode 100644 index 9c1c6cd52..000000000 --- a/code/css/storage/reservas.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - - \ No newline at end of file diff --git a/code/css/storage/userThumb.svg b/code/css/storage/userThumb.svg deleted file mode 100644 index 4418fba06..000000000 --- a/code/css/storage/userThumb.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/code/css/styles.css b/code/css/styles.css deleted file mode 100644 index 18c59d33d..000000000 --- a/code/css/styles.css +++ /dev/null @@ -1,135 +0,0 @@ -html, body { - height: 100%; /* altura total de la ventana */ - margin: 0; -} - -body { - display: flex; - flex-direction: column; /* hace que el contenido sea vertical */ -} - -main { - flex: 1; - background-size: cover; - background-position: center; - background-repeat: no-repeat; - background-attachment: fixed; -} - - - - -/* ============================== - Mobile adjustments -============================== */ -@media (max-width: 768px) { - - /* ============================== - Main background - ============================== - */ - main { - background-attachment: scroll; /* evita que se rompa en móviles */ - } - - /* ============================== - Search bar - ============================== - */ - .search-bar { - width: 90vw; - flex-direction: column; - height: auto; - font-size: 3vw; - } - - .filter-dropdown { - width: 80vw; - } - - /* ============================== - Cards / Carousel - ============================== - */ - .card { - width: 80vw; - height: auto; - margin: 1vh auto; - } - - .card-img { - height: 40vw; - } - - .card-body { - padding: 3vw; - } - - .card-buttons .main-btn { - font-size: 3vw; - padding: 1.5vw 0; - } - - .arrow { - width: 10vw; - font-size: 5vw; - } - - /* ============================== - Header - ============================== - */ - .header { - grid-template-columns: 1fr; - padding: 2vh 4vw; - height: auto; - gap: 2vh; - } - - .nav-left ul, - .auth-actions, - .nav-right { - flex-direction: column; - gap: 1.5vh; - } - - .logo-text h1 { - font-size: 3vh; - } - - .logo-text span { - font-size: 1.5vh; - } - - .btn, .btn-primary { - width: 100%; - font-size: 3vw; - padding: 2vw; - text-align: center; - } - - .profile img, - .usr-img { - width: 10vw; - height: 10vw; - } - - .dropdown-menu { - min-width: 80vw; - font-size: 3vw; - } - - /* ============================== - Footer - ============================== - */ - .footer { - height: auto; - padding: 2vh 0; - } - - .footer p { - font-size: 3vw; - } -} - diff --git a/code/index.php b/code/index.php deleted file mode 100644 index 64f2cbea6..000000000 --- a/code/index.php +++ /dev/null @@ -1,25 +0,0 @@ -route(); diff --git a/code/js/carrusel.js b/code/js/carrusel.js deleted file mode 100644 index 91d2fe6b1..000000000 --- a/code/js/carrusel.js +++ /dev/null @@ -1,117 +0,0 @@ -document.addEventListener('DOMContentLoaded', () => { - const wrapper = document.getElementById('carouselWrapper'); - const prevBtn = document.getElementById('prevBtn'); - const nextBtn = document.getElementById('nextBtn'); - - // Si no encontramos los elementos necesarios, abortamos. - if (!wrapper || !prevBtn || !nextBtn) return; - - // Solo contamos las tarjetas originales, no las copias para el loop. - const realCards = wrapper.querySelectorAll('.card:not(.carousel-copy)'); - const totalRealCards = realCards.length; - - // Si hay 3 o menos servicios, deshabilitamos el carrusel cíclico. - if (totalRealCards <= 3) { - prevBtn.style.display = 'none'; - nextBtn.style.display = 'none'; - wrapper.style.justifyContent = 'center'; // Centra las pocas tarjetas restantes - return; - } - - let currentIndex = 0; // Índice que apunta a la primera tarjeta REAL visible - - // Determina cuántas tarjetas se desplazan a la vez (1 en móvil, 3 en desktop) - const getCardsToScroll = () => { - return window.innerWidth <= 768 ? 1 : 3; - }; - - // Calcula el ancho de una tarjeta, incluyendo sus márgenes - const getCardFullWidth = () => { - if (realCards.length === 0) return 0; - const card = realCards[0]; - const style = window.getComputedStyle(card); - // Sumamos el ancho de la tarjeta y sus márgenes izquierdo/derecho - const margin = parseFloat(style.marginLeft) + parseFloat(style.marginRight); - return card.offsetWidth + margin; - }; - - // Función principal para desplazar el wrapper - const scrollToCard = (index, smooth = true) => { - const fullWidth = getCardFullWidth(); - wrapper.style.scrollBehavior = smooth ? 'smooth' : 'auto'; - - // El scroll se basa en el índice x el ancho completo de la tarjeta - wrapper.scrollLeft = index * fullWidth; - currentIndex = index; - }; - - // Inicializar: Aseguramos que la primera tarjeta visible sea la 0 - scrollToCard(0, false); - - - // ---------------------------------------------------- - // Lógica de Desplazamiento Cíclico - // ---------------------------------------------------- - - const handleNext = () => { - const cardsToScroll = getCardsToScroll(); - let newIndex = currentIndex + cardsToScroll; - - // Lógica Cíclica hacia adelante: si el nuevo índice llega a las tarjetas copiadas - if (newIndex >= totalRealCards) { - - // 1. Mover animadamente a la tarjeta copiada - scrollToCard(newIndex); - - // 2. Después de la animación, saltar instantáneamente al índice 0 - setTimeout(() => { - scrollToCard(0, false); - }, 300); - - currentIndex = 0; - } else { - // Desplazamiento normal - scrollToCard(newIndex); - } - }; - - const handlePrev = () => { - const cardsToScroll = getCardsToScroll(); - let newIndex = currentIndex - cardsToScroll; - - // Lógica Cíclica hacia atrás: si vamos antes del inicio (índice negativo) - if (newIndex < 0) { - // 1. Calcular el índice de la última tarjeta real visible - const lastRealIndex = totalRealCards - cardsToScroll; - - // 2. Mover instantáneamente al elemento copiado que está antes del inicio - // (Esto crea la ilusión de que el contenido proviene del final) - const indexBeforeLoop = totalRealCards + cardsToScroll; - scrollToCard(indexBeforeLoop, false); - - // 3. Mover animadamente a la última tarjeta real visible - setTimeout(() => { - scrollToCard(lastRealIndex, true); - }, 50); - - currentIndex = lastRealIndex; - - } else { - // Desplazamiento normal - scrollToCard(newIndex); - } - }; - - nextBtn.addEventListener('click', handleNext); - prevBtn.addEventListener('click', handlePrev); - - // Manejar redimensionamiento de pantalla (para el responsive) - let resizeTimer; - window.addEventListener('resize', () => { - clearTimeout(resizeTimer); - resizeTimer = setTimeout(() => { - scrollToCard(currentIndex, false); // Re-calcula la posición y el ancho sin animación - }, 100); - }); - -}); \ No newline at end of file diff --git a/code/js/dianoche.js b/code/js/dianoche.js deleted file mode 100644 index f5ed0de96..000000000 --- a/code/js/dianoche.js +++ /dev/null @@ -1,22 +0,0 @@ -const toggleTheme = document.getElementById('toggleTheme'); -const main = document.querySelector('main'); - -if (toggleTheme && main) { - // Inicial: modo día - document.body.classList.remove('dark-theme'); - toggleTheme.checked = false; - main.style.backgroundImage = "url('storage/error_bg_alfaCod_v0.1.jpg')"; - - // Escucha cambios del switch - toggleTheme.addEventListener('change', () => { - if (toggleTheme.checked) { - // Modo noche - document.body.classList.add('dark-theme'); - main.style.backgroundImage = "url('storage/Background_Alfacode_v0.2.jpg')"; - } else { - // Modo día - document.body.classList.remove('dark-theme'); - main.style.backgroundImage = "url('storage/error_bg_alfaCod_v0.1.jpg')"; - } - }); -} diff --git a/code/js/filtrito.js b/code/js/filtrito.js deleted file mode 100644 index 88a88c5df..000000000 --- a/code/js/filtrito.js +++ /dev/null @@ -1,17 +0,0 @@ -document.addEventListener('DOMContentLoaded', () => { - const filterBtn = document.getElementById('filterBtn'); - const filterMenu = document.getElementById('filterMenu'); - - // Toggle del dropdown al hacer click en el botón - filterBtn.addEventListener('click', (e) => { - e.stopPropagation(); // Evita que el click se propague al document - filterMenu.classList.toggle('active'); - }); - - // Cierra el dropdown si se hace click fuera - document.addEventListener('click', (e) => { - if (!filterMenu.contains(e.target) && !filterBtn.contains(e.target)) { - filterMenu.classList.remove('active'); - } - }); -}); diff --git a/code/js/header.js b/code/js/header.js deleted file mode 100644 index 41aed3687..000000000 --- a/code/js/header.js +++ /dev/null @@ -1,29 +0,0 @@ -// header.js -document.addEventListener('DOMContentLoaded', () => { - // ====== Selección de elementos ====== - const hamburgerBtn = document.getElementById('hamburgerBtn'); - const mobileNav = document.getElementById('mobileNav'); - const menuToggle = document.getElementById('menuToggle'); // Soporte alternativo (por si el botón usa otro id) - - // ====== Función para alternar visibilidad ====== - const toggleMenu = (e) => { - if (e) e.preventDefault(); // Evita abrir la imagen del SVG - if (mobileNav) { - mobileNav.classList.toggle('show'); - mobileNav.classList.toggle('open'); - } - }; - - // ====== Eventos ====== - if (hamburgerBtn && mobileNav) { - hamburgerBtn.addEventListener('click', toggleMenu); - } - - if (menuToggle && mobileNav) { - menuToggle.addEventListener('click', toggleMenu); - } - - // ====== (Espacio reservado para otros comportamientos del header) ====== - // Podés agregar acá animaciones, despliegues de usuario, etc. -}); - diff --git a/code/js/header/campanita.js b/code/js/header/campanita.js deleted file mode 100644 index 3e817aa86..000000000 --- a/code/js/header/campanita.js +++ /dev/null @@ -1,9 +0,0 @@ -CustomWiggle.create("wiggle", {wiggles:4, type:"easeOut"}) -CustomWiggle.create("bell-circle", {wiggles:6, type:"easeOut"}); - - -TweenLite.set(".bell", {transformOrigin:"center top"}); - -TweenMax.to(".bell", 3, {rotation:-20, ease:"wiggle"}) -TweenMax.to(".bell-icon__circle", 4.5, {x: -20, ease: "bell-circle"}) - diff --git a/code/js/header/profile.js b/code/js/header/profile.js deleted file mode 100644 index 0d0ebbbe0..000000000 --- a/code/js/header/profile.js +++ /dev/null @@ -1,33 +0,0 @@ -const profileBtn = document.getElementById('profileBtn'); -const dropdownMenu = document.getElementById('dropdownMenu'); -const toggleTheme = document.getElementById('toggleTheme'); - -// --- Mostrar/ocultar menú de perfil --- -if (profileBtn && dropdownMenu) { - profileBtn.addEventListener('click', (event) => { - event.stopPropagation(); - dropdownMenu.classList.toggle('show'); - }); - - window.addEventListener('click', (e) => { - if (!profileBtn.contains(e.target) && !dropdownMenu.contains(e.target)) { - dropdownMenu.classList.remove('show'); - } - }); -} - -// --- Modo día/noche --- -if (toggleTheme) { - // Asegura que empiece en modo día - document.body.classList.remove('dark-theme'); // quita la clase de modo noche - toggleTheme.checked = true; // checkbox sin marcar - - // Escucha el cambio del switch - toggleTheme.addEventListener('change', () => { - if (toggleTheme.checked) { - document.body.classList.add('dark-theme'); // activa modo noche - } else { - document.body.classList.remove('dark-theme'); // vuelve a modo día - } - }); -} diff --git a/code/js/login.js b/code/js/login.js deleted file mode 100644 index 42f34fe19..000000000 --- a/code/js/login.js +++ /dev/null @@ -1,106 +0,0 @@ -document.addEventListener('DOMContentLoaded', () => { - - const modal = document.getElementById("authModal"); - const loginContainer = document.getElementById("loginContainer"); - const registerContainer = document.getElementById("registerContainer"); - const registerForm = document.getElementById("registerForm"); - const registerChoice = document.getElementById("registerChoice"); - const chooseEmailRegister = document.getElementById("chooseEmailRegister"); - const googleLoginBtn = document.getElementById("googleLoginBtn"); - const googleRegisterBtn = document.getElementById("googleRegisterBtn"); - - // Abrir modal en login o registro - function openAuthModal(mode = 'login') { - if (!modal) return; - modal.style.display = 'flex'; - - if (mode === 'login') { - loginContainer && (loginContainer.style.display = 'block'); - registerContainer && (registerContainer.style.display = 'none'); - } else { - loginContainer && (loginContainer.style.display = 'none'); - registerContainer && (registerContainer.style.display = 'block'); - // Ocultar formulario completo y mostrar elección - registerForm && (registerForm.style.display = 'none'); - registerChoice && (registerChoice.style.display = 'flex'); - } - } - - // Cerrar modal - const authClose = document.querySelector(".auth-close"); - authClose && (authClose.onclick = () => modal.style.display = 'none'); - window.onclick = e => { if (e.target == modal) modal.style.display = 'none'; } - - // Switch dentro del modal - const toRegister = document.getElementById("toRegister"); - const toLoginLinks = [document.getElementById("toLogin"), document.getElementById("toLogin2")]; - toRegister && (toRegister.onclick = () => openAuthModal('register')); - toLoginLinks.forEach(link => { - link && (link.onclick = e => { - e.preventDefault(); - openAuthModal('login'); - }); - }); - - // Botones externos (ej: header) - const btnLogin = document.getElementById("btnLogin"); - const btnRegister = document.getElementById("btnRegister"); - if (btnLogin) btnLogin.onclick = e => { e.preventDefault(); openAuthModal('login'); }; - if (btnRegister) btnRegister.onclick = e => { e.preventDefault(); openAuthModal('register'); }; - - // Mostrar formulario completo al elegir registrarse con Email - chooseEmailRegister && (chooseEmailRegister.onclick = e => { - e.preventDefault(); - registerChoice && (registerChoice.style.display = 'none'); - registerForm && (registerForm.style.display = 'block'); - }); - - // Validación registro - if (registerForm) { - registerForm.addEventListener('submit', function(e) { - const password = this.querySelector('input[placeholder="Contraseña"]')?.value; - const confirm = this.querySelector('input[placeholder="Confirmar contraseña"]')?.value; - - if (password && confirm && password !== confirm) { - e.preventDefault(); - alert('Las contraseñas no coinciden.'); - } - }); - } - - // Función para login/register con Google - async function handleGoogleAuth() { - const provider = new firebase.auth.GoogleAuthProvider(); - try { - const result = await firebase.auth().signInWithPopup(provider); - const user = result.user; - if (!user) throw new Error('No se obtuvo usuario'); - - const formData = new FormData(); - formData.append("correo", user.email); - formData.append("nombre", user.displayName); - formData.append("google_uid", user.uid); - - const res = await fetch("index.php?controller=login&action=googleLogin", { - method: "POST", - body: formData - }); - const data = await res.json(); - - if (data.success) { - window.location.href = "index.php?controller=usuario&action=index"; - } else { - alert(data.message || "Error al iniciar sesión con Google."); - } - } catch (error) { - console.error("Error Google login:", error); - alert("Error al iniciar sesión con Google."); - } - } - - // Google login en login - googleLoginBtn && googleLoginBtn.addEventListener("click", handleGoogleAuth); - // Google register en registro - googleRegisterBtn && googleRegisterBtn.addEventListener("click", handleGoogleAuth); - -}); diff --git a/code/js/modal-login.js b/code/js/modal-login.js deleted file mode 100644 index 6c57d8ad5..000000000 --- a/code/js/modal-login.js +++ /dev/null @@ -1,27 +0,0 @@ -// Modal -const modal = document.getElementById("authModal"); -const openBtn = document.getElementById("openModalBtn"); -const closeBtn = document.querySelector(".close"); - -openBtn.onclick = () => modal.style.display = "block"; -closeBtn.onclick = () => modal.style.display = "none"; -window.onclick = (e) => { if(e.target == modal) modal.style.display = "none"; }; - -// Forms toggle -const loginForm = document.getElementById("loginForm"); -const registerForm = document.getElementById("registerForm"); -const switchToRegister = document.getElementById("switchToRegister"); -const switchToLogin = document.getElementById("switchToLogin"); -const modalTitle = document.getElementById("modalTitle"); - -switchToRegister.onclick = () => { - loginForm.style.display = "none"; - registerForm.style.display = "block"; - modalTitle.textContent = "Crea tu cuenta"; -}; - -switchToLogin.onclick = () => { - registerForm.style.display = "none"; - loginForm.style.display = "block"; - modalTitle.textContent = "Bienvenido"; -}; diff --git a/code/models/Administrador.php b/code/models/Administrador.php deleted file mode 100644 index bda13d5f6..000000000 --- a/code/models/Administrador.php +++ /dev/null @@ -1,67 +0,0 @@ -db->query("SELECT * FROM Administrador INNER JOIN Usuario ON Administrador.id_administrador = Usuario.id"); - return $stmt->fetchAll(); - } - - public function getById($id) { - $stmt = $this->db->prepare("SELECT * FROM Administrador INNER JOIN Usuario ON Administrador.id_administrador = Usuario.id WHERE Administrador.id_administrador = :id"); - $stmt->execute(['id' => $id]); - return $stmt->fetch(); - } - - public function create($nombre, $correo, $telefono, $especialidad, $estado, $cantrep_resuelto) { - $this->db->beginTransaction(); - $stmt1 = $this->db->prepare("INSERT INTO Usuario (fecha_creacion, nombre, correo, telefono) VALUES (NOW(), :nombre, :correo, :telefono)"); - $stmt1->execute([ - 'nombre' => $nombre, - 'correo' => $correo, - 'telefono' => $telefono - ]); - $id = $this->db->lastInsertId(); - - $stmt2 = $this->db->prepare("INSERT INTO Administrador (id_administrador, cantrep_resuelto, estado, especialidad, nombre, correo, telefono, fecha_creacion) VALUES (:id, :cantrep, :estado, :especialidad, :nombre, :correo, :telefono, NOW())"); - $stmt2->execute([ - 'id' => $id, - 'cantrep' => $cantrep_resuelto, - 'estado' => $estado, - 'especialidad' => $especialidad, - 'nombre' => $nombre, - 'correo' => $correo, - 'telefono' => $telefono - ]); - $this->db->commit(); - } - - public function update($id, $nombre, $correo, $telefono, $especialidad, $estado, $cantrep_resuelto) { - $stmt1 = $this->db->prepare("UPDATE Usuario SET nombre = :nombre, correo = :correo, telefono = :telefono WHERE id = :id"); - $stmt1->execute([ - 'id' => $id, - 'nombre' => $nombre, - 'correo' => $correo, - 'telefono' => $telefono - ]); - - $stmt2 = $this->db->prepare("UPDATE Administrador SET nombre = :nombre, correo = :correo, telefono = :telefono, especialidad = :especialidad, estado = :estado, cantrep_resuelto = :cantrep WHERE id_administrador = :id"); - $stmt2->execute([ - 'id' => $id, - 'nombre' => $nombre, - 'correo' => $correo, - 'telefono' => $telefono, - 'especialidad' => $especialidad, - 'estado' => $estado, - 'cantrep' => $cantrep_resuelto - ]); - } - - public function delete($id) { - $this->db->beginTransaction(); - $this->db->prepare("DELETE FROM Administrador WHERE id_administrador = :id")->execute(['id' => $id]); - $this->db->prepare("DELETE FROM Usuario WHERE id = :id")->execute(['id' => $id]); - $this->db->commit(); - } -} \ No newline at end of file diff --git a/code/models/Cliente.php b/code/models/Cliente.php deleted file mode 100644 index da092d81e..000000000 --- a/code/models/Cliente.php +++ /dev/null @@ -1,69 +0,0 @@ -db->query("SELECT * FROM Cliente INNER JOIN Usuario ON Cliente.id_cliente = Usuario.id"); - return $stmt->fetchAll(); - } - - public function getById($id) { - $stmt = $this->db->prepare("SELECT * FROM Cliente INNER JOIN Usuario ON Cliente.id_cliente = Usuario.id WHERE Cliente.id_cliente = :id"); - $stmt->execute(['id' => $id]); - return $stmt->fetch(); - } - - public function create($nombre, $correo, $telefono, $calificaciones) { - $this->db->beginTransaction(); - - // Insertar en Usuario - $stmt1 = $this->db->prepare("INSERT INTO Usuario (fecha_creacion, nombre, correo, telefono) VALUES (NOW(), :nombre, :correo, :telefono)"); - $stmt1->execute([ - 'nombre' => $nombre, - 'correo' => $correo, - 'telefono' => $telefono - ]); - $id = $this->db->lastInsertId(); - - // Insertar en Cliente - $stmt2 = $this->db->prepare("INSERT INTO Cliente (id_cliente, fecha_creacion, nombre, correo, telefono, calificaciones) VALUES (:id, NOW(), :nombre, :correo, :telefono, :calificaciones)"); - $stmt2->execute([ - 'id' => $id, - 'nombre' => $nombre, - 'correo' => $correo, - 'telefono' => $telefono, - 'calificaciones' => $calificaciones - ]); - - $this->db->commit(); - } - - public function update($id, $nombre, $correo, $telefono, $calificaciones) { - $stmt1 = $this->db->prepare("UPDATE Usuario SET nombre = :nombre, correo = :correo, telefono = :telefono WHERE id = :id"); - $stmt1->execute([ - 'id' => $id, - 'nombre' => $nombre, - 'correo' => $correo, - 'telefono' => $telefono - ]); - - $stmt2 = $this->db->prepare("UPDATE Cliente SET nombre = :nombre, correo = :correo, telefono = :telefono, calificaciones = :calificaciones WHERE id_cliente = :id"); - $stmt2->execute([ - 'id' => $id, - 'nombre' => $nombre, - 'correo' => $correo, - 'telefono' => $telefono, - 'calificaciones' => $calificaciones - ]); - } - - public function delete($id) { - $this->db->beginTransaction(); - $stmt1 = $this->db->prepare("DELETE FROM Cliente WHERE id_cliente = :id"); - $stmt1->execute(['id' => $id]); - $stmt2 = $this->db->prepare("DELETE FROM Usuario WHERE id = :id"); - $stmt2->execute(['id' => $id]); - $this->db->commit(); - } -} \ No newline at end of file diff --git a/code/models/Gestiona.php b/code/models/Gestiona.php deleted file mode 100644 index e2b833579..000000000 --- a/code/models/Gestiona.php +++ /dev/null @@ -1,46 +0,0 @@ -db->query("SELECT * FROM Gestiona"); - return $stmt->fetchAll(); - } - - public function getById($id_usuario, $id_administrador) { - $stmt = $this->db->prepare("SELECT * FROM Gestiona WHERE id_usuario = :id_usuario AND id_administrador = :id_administrador"); - $stmt->execute([ - 'id_usuario' => $id_usuario, - 'id_administrador' => $id_administrador - ]); - return $stmt->fetch(); - } - - public function create($id_usuario, $id_administrador, $fecha_gestion, $descripcion) { - $stmt = $this->db->prepare("INSERT INTO Gestiona (id_usuario, id_administrador, fecha_gestion, descripcion) VALUES (:id_usuario, :id_administrador, :fecha_gestion, :descripcion)"); - $stmt->execute([ - 'id_usuario' => $id_usuario, - 'id_administrador' => $id_administrador, - 'fecha_gestion' => $fecha_gestion, - 'descripcion' => $descripcion - ]); - } - - public function update($id_usuario, $id_administrador, $fecha_gestion, $descripcion) { - $stmt = $this->db->prepare("UPDATE Gestiona SET fecha_gestion = :fecha_gestion, descripcion = :descripcion WHERE id_usuario = :id_usuario AND id_administrador = :id_administrador"); - $stmt->execute([ - 'id_usuario' => $id_usuario, - 'id_administrador' => $id_administrador, - 'fecha_gestion' => $fecha_gestion, - 'descripcion' => $descripcion - ]); - } - - public function delete($id_usuario, $id_administrador) { - $stmt = $this->db->prepare("DELETE FROM Gestiona WHERE id_usuario = :id_usuario AND id_administrador = :id_administrador"); - $stmt->execute([ - 'id_usuario' => $id_usuario, - 'id_administrador' => $id_administrador - ]); - } -} diff --git a/code/models/Mensaje.php b/code/models/Mensaje.php deleted file mode 100644 index 21380f496..000000000 --- a/code/models/Mensaje.php +++ /dev/null @@ -1,43 +0,0 @@ -db->query("SELECT * FROM Mensaje"); - return $stmt->fetchAll(); - } - - public function getById($id_usuario, $id_mensaje) { - $stmt = $this->db->prepare("SELECT * FROM Mensaje WHERE id_usuario = :id_usuario AND id_mensaje = :id_mensaje"); - $stmt->execute(['id_usuario' => $id_usuario, 'id_mensaje' => $id_mensaje]); - return $stmt->fetch(); - } - - public function create($id_usuario, $id_emisor, $id_receptor, $id_mensaje, $estado, $notificacion, $fecha) { - $stmt = $this->db->prepare("INSERT INTO Mensaje (id_usuario, id_emisor, id_receptor, id_mensaje, estado, notificacion, fecha) VALUES (:id_usuario, :id_emisor, :id_receptor, :id_mensaje, :estado, :notificacion, :fecha)"); - $stmt->execute([ - 'id_usuario' => $id_usuario, - 'id_emisor' => $id_emisor, - 'id_receptor' => $id_receptor, - 'id_mensaje' => $id_mensaje, - 'estado' => $estado, - 'notificacion' => $notificacion, - 'fecha' => $fecha - ]); - } - - public function update($id_usuario, $id_mensaje, $estado, $notificacion) { - $stmt = $this->db->prepare("UPDATE Mensaje SET estado = :estado, notificacion = :notificacion WHERE id_usuario = :id_usuario AND id_mensaje = :id_mensaje"); - $stmt->execute([ - 'id_usuario' => $id_usuario, - 'id_mensaje' => $id_mensaje, - 'estado' => $estado, - 'notificacion' => $notificacion - ]); - } - - public function delete($id_usuario, $id_mensaje) { - $stmt = $this->db->prepare("DELETE FROM Mensaje WHERE id_usuario = :id_usuario AND id_mensaje = :id_mensaje"); - $stmt->execute(['id_usuario' => $id_usuario, 'id_mensaje' => $id_mensaje]); - } -} diff --git a/code/models/Ofrece.php b/code/models/Ofrece.php deleted file mode 100644 index c845aac68..000000000 --- a/code/models/Ofrece.php +++ /dev/null @@ -1,34 +0,0 @@ -db->query("SELECT * FROM Ofrece"); - return $stmt->fetchAll(); - } - - public function getById($id_proveedor, $id_servicio) { - $stmt = $this->db->prepare("SELECT * FROM Ofrece WHERE id_proveedor = :id_proveedor AND id_servicio = :id_servicio"); - $stmt->execute([ - 'id_proveedor' => $id_proveedor, - 'id_servicio' => $id_servicio - ]); - return $stmt->fetch(); - } - - public function create($id_proveedor, $id_servicio) { - $stmt = $this->db->prepare("INSERT INTO Ofrece (id_proveedor, id_servicio) VALUES (:id_proveedor, :id_servicio)"); - $stmt->execute([ - 'id_proveedor' => $id_proveedor, - 'id_servicio' => $id_servicio - ]); - } - - public function delete($id_proveedor, $id_servicio) { - $stmt = $this->db->prepare("DELETE FROM Ofrece WHERE id_proveedor = :id_proveedor AND id_servicio = :id_servicio"); - $stmt->execute([ - 'id_proveedor' => $id_proveedor, - 'id_servicio' => $id_servicio - ]); - } -} diff --git a/code/models/Proveedor.php b/code/models/Proveedor.php deleted file mode 100644 index 3a61e2966..000000000 --- a/code/models/Proveedor.php +++ /dev/null @@ -1,71 +0,0 @@ -db->query("SELECT * FROM Proveedor INNER JOIN Usuario ON Proveedor.id_proveedor = Usuario.id"); - return $stmt->fetchAll(); - } - - public function getById($id) { - $stmt = $this->db->prepare("SELECT * FROM Proveedor INNER JOIN Usuario ON Proveedor.id_proveedor = Usuario.id WHERE Proveedor.id_proveedor = :id"); - $stmt->execute(['id' => $id]); - return $stmt->fetch(); - } - - public function create($nombre, $correo, $telefono, $referencias, $calificacion, $cantidad_ventas) { - $this->db->beginTransaction(); - - $stmt1 = $this->db->prepare("INSERT INTO Usuario (fecha_creacion, nombre, correo, telefono) VALUES (NOW(), :nombre, :correo, :telefono)"); - $stmt1->execute([ - 'nombre' => $nombre, - 'correo' => $correo, - 'telefono' => $telefono - ]); - $id = $this->db->lastInsertId(); - - $stmt2 = $this->db->prepare("INSERT INTO Proveedor (id_proveedor, fecha_creacion, nombre, correo, telefono, referencias, calificacion, cantidad_ventas) VALUES (:id, NOW(), :nombre, :correo, :telefono, :referencias, :calificacion, :ventas)"); - $stmt2->execute([ - 'id' => $id, - 'nombre' => $nombre, - 'correo' => $correo, - 'telefono' => $telefono, - 'referencias' => $referencias, - 'calificacion' => $calificacion, - 'ventas' => $cantidad_ventas - ]); - - $this->db->commit(); - } - - public function update($id, $nombre, $correo, $telefono, $referencias, $calificacion, $cantidad_ventas) { - $stmt1 = $this->db->prepare("UPDATE Usuario SET nombre = :nombre, correo = :correo, telefono = :telefono WHERE id = :id"); - $stmt1->execute([ - 'id' => $id, - 'nombre' => $nombre, - 'correo' => $correo, - 'telefono' => $telefono - ]); - - $stmt2 = $this->db->prepare("UPDATE Proveedor SET nombre = :nombre, correo = :correo, telefono = :telefono, referencias = :referencias, calificacion = :calificacion, cantidad_ventas = :ventas WHERE id_proveedor = :id"); - $stmt2->execute([ - 'id' => $id, - 'nombre' => $nombre, - 'correo' => $correo, - 'telefono' => $telefono, - 'referencias' => $referencias, - 'calificacion' => $calificacion, - 'ventas' => $cantidad_ventas - ]); - } - - public function delete($id) { - $this->db->beginTransaction(); - $stmt1 = $this->db->prepare("DELETE FROM Proveedor WHERE id_proveedor = :id"); - $stmt1->execute(['id' => $id]); - $stmt2 = $this->db->prepare("DELETE FROM Usuario WHERE id = :id"); - $stmt2->execute(['id' => $id]); - $this->db->commit(); - } -} \ No newline at end of file diff --git a/code/models/Reserva.php b/code/models/Reserva.php deleted file mode 100644 index 8844d419c..000000000 --- a/code/models/Reserva.php +++ /dev/null @@ -1,57 +0,0 @@ -db->query("SELECT * FROM Reserva"); - return $stmt->fetchAll(); - } - - public function getById($id_reserva, $id_cliente, $id_proveedor, $id_servicio) { - $stmt = $this->db->prepare("SELECT * FROM Reserva WHERE id_reserva = :id_reserva AND id_cliente = :id_cliente AND id_proveedor = :id_proveedor AND id_servicio = :id_servicio"); - $stmt->execute([ - 'id_reserva' => $id_reserva, - 'id_cliente' => $id_cliente, - 'id_proveedor' => $id_proveedor, - 'id_servicio' => $id_servicio - ]); - return $stmt->fetch(); - } - - public function create($id_reserva, $id_cliente, $id_proveedor, $id_servicio, $recordatorio, $resena, $fecha_reserva) { - $stmt = $this->db->prepare("INSERT INTO Reserva (id_reserva, id_cliente, id_proveedor, id_servicio, recordatorio, reseña, fecha_reserva) VALUES (:id_reserva, :id_cliente, :id_proveedor, :id_servicio, :recordatorio, :resena, :fecha_reserva)"); - $stmt->execute([ - 'id_reserva' => $id_reserva, - 'id_cliente' => $id_cliente, - 'id_proveedor' => $id_proveedor, - 'id_servicio' => $id_servicio, - 'recordatorio' => $recordatorio, - 'resena' => $resena, - 'fecha_reserva' => $fecha_reserva - ]); - } - - public function update($id_reserva, $id_cliente, $id_proveedor, $id_servicio, $recordatorio, $resena, $fecha_reserva) { - $stmt = $this->db->prepare("UPDATE Reserva SET recordatorio = :recordatorio, reseña = :resena, fecha_reserva = :fecha_reserva WHERE id_reserva = :id_reserva AND id_cliente = :id_cliente AND id_proveedor = :id_proveedor AND id_servicio = :id_servicio"); - $stmt->execute([ - 'id_reserva' => $id_reserva, - 'id_cliente' => $id_cliente, - 'id_proveedor' => $id_proveedor, - 'id_servicio' => $id_servicio, - 'recordatorio' => $recordatorio, - 'resena' => $resena, - 'fecha_reserva' => $fecha_reserva - ]); - } - - public function delete($id_reserva, $id_cliente, $id_proveedor, $id_servicio) { - $stmt = $this->db->prepare("DELETE FROM Reserva WHERE id_reserva = :id_reserva AND id_cliente = :id_cliente AND id_proveedor = :id_proveedor AND id_servicio = :id_servicio"); - $stmt->execute([ - 'id_reserva' => $id_reserva, - 'id_cliente' => $id_cliente, - 'id_proveedor' => $id_proveedor, - 'id_servicio' => $id_servicio - ]); - } -} \ No newline at end of file diff --git a/code/models/Servicio.php b/code/models/Servicio.php deleted file mode 100644 index 78ed6948e..000000000 --- a/code/models/Servicio.php +++ /dev/null @@ -1,84 +0,0 @@ -db->query($sql); - return $stmt->fetchAll(PDO::FETCH_ASSOC); - } - - /** - * Devuelve un servicio específico por ID - */ - public function getById($id) { - $stmt = $this->db->prepare("SELECT * FROM Servicio WHERE id_servicio = :id"); - $stmt->execute(['id' => $id]); - return $stmt->fetch(PDO::FETCH_ASSOC); - } - - /** - * Crea un nuevo servicio - */ - public function create($disponibilidad, $categoria, $descripcion, $precio, $titulo, $imagen) { - $stmt = $this->db->prepare( - "INSERT INTO Servicio (disponibilidad, categoria, descripcion, precio, titulo, imagen) - VALUES (:disponibilidad, :categoria, :descripcion, :precio, :titulo, :imagen)" - ); - $stmt->execute([ - 'disponibilidad' => $disponibilidad, - 'categoria' => $categoria, - 'descripcion' => $descripcion, - 'precio' => $precio, - 'titulo' => $titulo, - 'imagen' => $imagen - ]); - } - - /** - * Actualiza un servicio existente - */ - public function update($id, $disponibilidad, $categoria, $descripcion, $precio, $titulo, $imagen) { - $stmt = $this->db->prepare( - "UPDATE Servicio - SET disponibilidad = :disponibilidad, categoria = :categoria, descripcion = :descripcion, - precio = :precio, titulo = :titulo, imagen = :imagen - WHERE id_servicio = :id" - ); - $stmt->execute([ - 'id' => $id, - 'disponibilidad' => $disponibilidad, - 'categoria' => $categoria, - 'descripcion' => $descripcion, - 'precio' => $precio, - 'titulo' => $titulo, - 'imagen' => $imagen - ]); - } - - /** - * Elimina un servicio - */ - public function delete($id) { - $stmt = $this->db->prepare("DELETE FROM Servicio WHERE id_servicio = :id"); - $stmt->execute(['id' => $id]); - } -} -?> \ No newline at end of file diff --git a/code/models/Usuario.php b/code/models/Usuario.php deleted file mode 100644 index 4d67d9817..000000000 --- a/code/models/Usuario.php +++ /dev/null @@ -1,130 +0,0 @@ -db->query("SELECT * FROM Usuario"); - return $stmt->fetchAll(); - } - - public function getById($id) - { - $stmt = $this->db->prepare("SELECT * FROM Usuario WHERE id = :id"); - $stmt->execute(['id' => $id]); - return $stmt->fetch(); - } - - public function getByEmail($correo) - { - $stmt = $this->db->prepare("SELECT * FROM Usuario WHERE correo = :correo LIMIT 1"); - $stmt->execute([':correo' => $correo]); - return $stmt->fetch(); - } - - public function create($nombre, $correo, $telefono, $password, $google_uid = null) - { - try - { - $stmt = $this->db->prepare(" - INSERT INTO Usuario (fecha_creacion, nombre, correo, telefono, password, google_uid) - VALUES (NOW(), :nombre, :correo, :telefono, :password, :google_uid) - "); - $stmt->execute([ - ':nombre' => $nombre, - ':correo' => $correo, - ':telefono' => $telefono, - ':password' => $password, - ':google_uid' => $google_uid - ]); - return true; - } catch (PDOException $e) - { - error_log("Error al crear usuario: " . $e->getMessage()); - return false; - } - } - - public function exists($correo) - { - $stmt = $this->db->prepare("SELECT id FROM Usuario WHERE correo = :correo LIMIT 1"); - $stmt->execute([':correo' => $correo]); - return (bool) $stmt->fetch(); - } - - public function update($id, $nombre, $correo, $telefono) - { - $stmt = $this->db->prepare("UPDATE Usuario SET nombre = :nombre, correo = :correo, telefono = :telefono WHERE id = :id"); - $stmt->execute([ - 'id' => $id, - 'nombre' => $nombre, - 'correo' => $correo, - 'telefono' => $telefono - ]); - } - - - public function delete($id) - { - $stmt = $this->db->prepare("DELETE FROM Usuario WHERE id = :id"); - $stmt->execute(['id' => $id]); - } - - - public function esCliente($id) - { - $stmt = $this->db->prepare("SELECT id_cliente FROM Cliente WHERE id_cliente = :id LIMIT 1"); - $stmt->execute([':id' => $id]); - return (bool) $stmt->fetch(); - } - - - - public function esProveedor($id) - { - $stmt = $this->db->prepare("SELECT id_proveedor FROM Proveedor WHERE id_proveedor = :id LIMIT 1"); - $stmt->execute([':id' => $id]); - return (bool) $stmt->fetch(); - } - - /** - * Autentica un usuario mediante su correo y contraseña. - * - * @param string $correo El correo del usuario. - * @param string $password La contraseña del usuario. - * @return array|bool El usuario autenticado o false si no se encuentra. - */ - public function login($correo, $password) - { - $stmt = $this->db->prepare("SELECT * FROM Usuario WHERE correo = :correo LIMIT 1"); - $stmt->execute(['correo' => $correo]); - $user = $stmt->fetch(); - - if ($user && password_verify($password, $user['password'])) - { - $usuario_id = $user['id']; - $user['es_cliente'] = $this->esCliente($usuario_id); - $user['es_proveedor'] = $this->esProveedor($usuario_id); - return $user; - } - return false; - } - - // ========================================================= - // Métodos para Google Login - // ========================================================= - - /** - * Asigna un identificador de Google a un usuario - * - * @param int $id El identificador del usuario - * @param string $uid El identificador de Google - */ - public function setGoogleUid($id, $uid) - { - $stmt = $this->db->prepare("UPDATE Usuario SET google_uid = :uid WHERE id = :id"); - $stmt->execute(['id' => $id, 'uid' => $uid]); - } -} diff --git a/code/views/adminPanel/administrador/create.php b/code/views/adminPanel/administrador/create.php deleted file mode 100644 index 4e1b70644..000000000 --- a/code/views/adminPanel/administrador/create.php +++ /dev/null @@ -1,88 +0,0 @@ - - - - - - - Registrar Administrador - - - -
-

Registrar Administrador

-
- - - - - - - -
- ← Volver a la lista de administradores -
- - diff --git a/code/views/adminPanel/administrador/edit.php b/code/views/adminPanel/administrador/edit.php deleted file mode 100644 index d1c972ec8..000000000 --- a/code/views/adminPanel/administrador/edit.php +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - Editar Administrador - - -

Editar Administrador

-
- -
-
-
-
-
-
- -
- - \ No newline at end of file diff --git a/code/views/adminPanel/administrador/index.php b/code/views/adminPanel/administrador/index.php deleted file mode 100644 index 468cf04d7..000000000 --- a/code/views/adminPanel/administrador/index.php +++ /dev/null @@ -1,160 +0,0 @@ - - - - - - - Administradores - - - - - - - -
-

Lista de Administradores

- Registrar nuevo administrador - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
IDNombreCorreoTeléfonoReportes ResueltosEstadoEspecialidadAcciones
- Editar | - Eliminar -
No hay administradores registrados.
-
- - diff --git a/code/views/adminPanel/cliente/create.php b/code/views/adminPanel/cliente/create.php deleted file mode 100644 index c0f670d58..000000000 --- a/code/views/adminPanel/cliente/create.php +++ /dev/null @@ -1,85 +0,0 @@ - - - - - - - Registrar Cliente - - - -
-

Registrar Cliente

-
- - - - -
- ← Volver a la lista de clientes -
- - diff --git a/code/views/adminPanel/cliente/edit.php b/code/views/adminPanel/cliente/edit.php deleted file mode 100644 index 408a57505..000000000 --- a/code/views/adminPanel/cliente/edit.php +++ /dev/null @@ -1,21 +0,0 @@ - - - - - - Editar Cliente - - -

Editar Cliente

-
- -
-
-
-
- -
- - \ No newline at end of file diff --git a/code/views/adminPanel/cliente/index.php b/code/views/adminPanel/cliente/index.php deleted file mode 100644 index d17077a71..000000000 --- a/code/views/adminPanel/cliente/index.php +++ /dev/null @@ -1,173 +0,0 @@ - - - - - Clientes - - - - - - - - -
-

Lista de Clientes

- Registrar nuevo cliente - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
IDNombreCorreoTeléfonoCalificacionesAcciones
- Editar - | - Eliminar -
No hay clientes registrados.
-
- - \ No newline at end of file diff --git a/code/views/adminPanel/gestiona/create.php b/code/views/adminPanel/gestiona/create.php deleted file mode 100644 index 1aa10ed91..000000000 --- a/code/views/adminPanel/gestiona/create.php +++ /dev/null @@ -1,14 +0,0 @@ - - -Crear Gestiona - -

Crear Gestiona

-
-
-
-
-
- -
- - diff --git a/code/views/adminPanel/gestiona/edit.php b/code/views/adminPanel/gestiona/edit.php deleted file mode 100644 index 654fcb098..000000000 --- a/code/views/adminPanel/gestiona/edit.php +++ /dev/null @@ -1,14 +0,0 @@ - - -Editar Gestiona - -

Editar Gestiona

-
- - -
-
- -
- - diff --git a/code/views/adminPanel/gestiona/index.php b/code/views/adminPanel/gestiona/index.php deleted file mode 100644 index 90394c2a4..000000000 --- a/code/views/adminPanel/gestiona/index.php +++ /dev/null @@ -1,29 +0,0 @@ - - -Gestiona - -

Lista de Gestiona

-Crear Nuevo - - - - - - - - - - - - - - - - - -
ID UsuarioID AdministradorFecha GestiónDescripciónAcciones
- Editar | - Eliminar -
- - diff --git a/code/views/adminPanel/login/login.php b/code/views/adminPanel/login/login.php deleted file mode 100644 index c8c826ecb..000000000 --- a/code/views/adminPanel/login/login.php +++ /dev/null @@ -1,32 +0,0 @@ - - - - - - - - - -
- -
- - diff --git a/code/views/adminPanel/login/register.php b/code/views/adminPanel/login/register.php deleted file mode 100644 index 140904787..000000000 --- a/code/views/adminPanel/login/register.php +++ /dev/null @@ -1,67 +0,0 @@ - - - - - - Registro - - - - - - - - - -
-
-
-
- - -
-
- - -
-
- -
- - -
-
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- -
- - -
-
- - - - - - \ No newline at end of file diff --git a/code/views/adminPanel/login/styles.css b/code/views/adminPanel/login/styles.css deleted file mode 100644 index eb04ceef7..000000000 --- a/code/views/adminPanel/login/styles.css +++ /dev/null @@ -1,130 +0,0 @@ -/* Reset */ -* { - margin: 0; - padding: 0; - box-sizing: border-box; -} - -body { - font-family: "Roboto", sans-serif; - background: #fff; - color: #21272A; - display: flex; - flex-direction: column; - min-height: 100vh; -} - -/* Header */ -.header { - display: flex; - align-items: center; - justify-content: center; - padding: 16px 40px; - border-bottom: 1px solid #21272A; -} - -.logo { - display: flex; - align-items: center; - gap: 8px; -} - -.logo-icon { - width: 24px; - height: 24px; - background: #4D5358; -} - -.logo-text h1 { - font-size: 20px; - font-weight: 700; - color: #697077; -} - -.logo-text span { - font-size: 12px; - color: #697077; - display: block; - margin-top: -4px; -} - -/* Login */ -.login-container { - flex: 1; - display: flex; - justify-content: center; - align-items: center; -} - -.login-form { - width: 100%; - max-width: 400px; - display: flex; - flex-direction: column; - gap: 16px; -} - -.login-form label { - font-size: 14px; - color: #21272A; -} - -.login-form input { - padding: 12px 16px; - border: none; - border-bottom: 1px solid #C1C7CD; - background: #F2F4F8; - font-size: 16px; - color: #21272A; - outline: none; -} - -.login-form input:focus { - border-color: #0F62FE; -} - -.form-options { - display: flex; - justify-content: space-between; - font-size: 14px; -} - -.form-options a { - color: #0F62FE; - text-decoration: none; -} - -/* Botón */ -.btn { - padding: 14px; - border: 2px solid #21272A; - background: #fff; - font-size: 16px; - font-weight: 500; - cursor: pointer; -} - -.btn:hover { - background: #21272A; - color: #fff; - transition: 0.3s; -} - -.signup-text { - text-align: center; - font-size: 14px; -} - -.signup-text a { - color: #0F62FE; - text-decoration: none; -} - -/* Footer */ -.footer { - background: #697077; - color: #fff; - text-align: center; - padding: 16px; - font-size: 12px; -} diff --git a/code/views/adminPanel/mensaje/create.php b/code/views/adminPanel/mensaje/create.php deleted file mode 100644 index 7a760ac0d..000000000 --- a/code/views/adminPanel/mensaje/create.php +++ /dev/null @@ -1,112 +0,0 @@ - - - - - - - Registrar Mensaje - - - -
-

Registrar Nuevo Mensaje

-
- - - - - - - - - - - - - - - - - - -
- -
-
- ← Volver a la lista de mensajes -
- - diff --git a/code/views/adminPanel/mensaje/edit.php b/code/views/adminPanel/mensaje/edit.php deleted file mode 100644 index 429970f1e..000000000 --- a/code/views/adminPanel/mensaje/edit.php +++ /dev/null @@ -1,14 +0,0 @@ - - -Editar Mensaje - -

Editar Mensaje

-
- - -
-
- -
- - diff --git a/code/views/adminPanel/mensaje/index.php b/code/views/adminPanel/mensaje/index.php deleted file mode 100644 index 4cbf3b321..000000000 --- a/code/views/adminPanel/mensaje/index.php +++ /dev/null @@ -1,162 +0,0 @@ - - - - - - - Mensajes - - - - - - - -
-

Lista de Mensajes

- Registrar nuevo mensaje - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
ID UsuarioID EmisorID ReceptorID MensajeEstadoNotificaciónFechaAcciones
- Editar | - Eliminar -
No hay mensajes registrados.
-
- - diff --git a/code/views/adminPanel/ofrece/create.php b/code/views/adminPanel/ofrece/create.php deleted file mode 100644 index fc945f2cb..000000000 --- a/code/views/adminPanel/ofrece/create.php +++ /dev/null @@ -1,12 +0,0 @@ - - -Crear Ofrece - -

Crear Ofrece

-
-
-
- -
- - diff --git a/code/views/adminPanel/ofrece/edit.php b/code/views/adminPanel/ofrece/edit.php deleted file mode 100644 index e69de29bb..000000000 diff --git a/code/views/adminPanel/ofrece/index.php b/code/views/adminPanel/ofrece/index.php deleted file mode 100644 index 5b596ba7f..000000000 --- a/code/views/adminPanel/ofrece/index.php +++ /dev/null @@ -1,26 +0,0 @@ - - -Ofrece - -

Lista de Ofrece

-Crear Nuevo Registro - - - - - - - - - - - - - - - -
ID ProveedorID ServicioAcciones
- Eliminar -
- - diff --git a/code/views/adminPanel/proveedor/create.php b/code/views/adminPanel/proveedor/create.php deleted file mode 100644 index 93e46478b..000000000 --- a/code/views/adminPanel/proveedor/create.php +++ /dev/null @@ -1,88 +0,0 @@ - - - - - - - Registrar Proveedor - - - -
-

Registrar Proveedor

-
- - - - - - - -
- ← Volver a la lista de proveedores -
- - diff --git a/code/views/adminPanel/proveedor/edit.php b/code/views/adminPanel/proveedor/edit.php deleted file mode 100644 index fa1b0e2be..000000000 --- a/code/views/adminPanel/proveedor/edit.php +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - Editar Proveedor - - -

Editar Proveedor

-
- -
-
-
-
-
-
- -
- - \ No newline at end of file diff --git a/code/views/adminPanel/proveedor/index.php b/code/views/adminPanel/proveedor/index.php deleted file mode 100644 index d5754feb1..000000000 --- a/code/views/adminPanel/proveedor/index.php +++ /dev/null @@ -1,161 +0,0 @@ - - - - - - - Proveedores - - - - - - - - -
-

Lista de Proveedores

- Registrar nuevo proveedor - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
IDNombreCorreoTeléfonoReferenciasCalificaciónCantidad VentasAcciones
- Editar | - Eliminar -
No hay proveedores registrados.
-
- - diff --git a/code/views/adminPanel/reserva/create.php b/code/views/adminPanel/reserva/create.php deleted file mode 100644 index 78988809d..000000000 --- a/code/views/adminPanel/reserva/create.php +++ /dev/null @@ -1,114 +0,0 @@ - - - - - - - Registrar Reserva - - - -
-

Registrar Nueva Reserva

-
- - - - - - - - - - - - - - - - - - -
- -
-
- ← Volver a la lista de reservas -
- - diff --git a/code/views/adminPanel/reserva/edit.php b/code/views/adminPanel/reserva/edit.php deleted file mode 100644 index 5b1f45060..000000000 --- a/code/views/adminPanel/reserva/edit.php +++ /dev/null @@ -1,18 +0,0 @@ - - -Editar Reserva - -

Editar Reserva

-
- - - - - -
-
-
- -
- - diff --git a/code/views/adminPanel/reserva/index.php b/code/views/adminPanel/reserva/index.php deleted file mode 100644 index d47e4d80b..000000000 --- a/code/views/adminPanel/reserva/index.php +++ /dev/null @@ -1,162 +0,0 @@ - - - - - - - Reservas - - - - - - - -
-

Lista de Reservas

- Registrar nueva reserva - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
ID ReservaID ClienteID ProveedorID ServicioRecordatorioReseñaFecha ReservaAcciones
- Editar | - Eliminar -
No hay reservas registradas.
-
- - diff --git a/code/views/adminPanel/servicio/create.php b/code/views/adminPanel/servicio/create.php deleted file mode 100644 index 40ed4b6b4..000000000 --- a/code/views/adminPanel/servicio/create.php +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - Crear Servicio - - -

Crear Servicio

-
-
-
-
-
-
-
- -
- - \ No newline at end of file diff --git a/code/views/adminPanel/servicio/edit.php b/code/views/adminPanel/servicio/edit.php deleted file mode 100644 index 86ac627a4..000000000 --- a/code/views/adminPanel/servicio/edit.php +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - Editar Servicio - - -

Editar Servicio

-
- -
-
-
-
-
-
- -
- - \ No newline at end of file diff --git a/code/views/adminPanel/servicio/index.php b/code/views/adminPanel/servicio/index.php deleted file mode 100644 index 05574c40e..000000000 --- a/code/views/adminPanel/servicio/index.php +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - Servicios - - -

Lista de Servicios

- Crear Nuevo Servicio - - - \ No newline at end of file diff --git a/code/views/adminPanel/usuario/create.php b/code/views/adminPanel/usuario/create.php deleted file mode 100644 index 4c23becec..000000000 --- a/code/views/adminPanel/usuario/create.php +++ /dev/null @@ -1,109 +0,0 @@ - - - - - Registrar Usuario - - - - -
-

Registrar Usuario

-
- - - - - - - - - - - - - -
- ← Volver a la lista -
- - diff --git a/code/views/adminPanel/usuario/edit.php b/code/views/adminPanel/usuario/edit.php deleted file mode 100644 index 63063f8ab..000000000 --- a/code/views/adminPanel/usuario/edit.php +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - Editar Usuario - - -

Editar Usuario

-
- -
-
-
- -
- - \ No newline at end of file diff --git a/code/views/adminPanel/usuario/index.php b/code/views/adminPanel/usuario/index.php deleted file mode 100644 index 83f571732..000000000 --- a/code/views/adminPanel/usuario/index.php +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - QueLaburo - - - - - - - - - - - - - - - - diff --git a/code/views/adminPanel/usuario/indexA.php b/code/views/adminPanel/usuario/indexA.php deleted file mode 100644 index 7816ba337..000000000 --- a/code/views/adminPanel/usuario/indexA.php +++ /dev/null @@ -1,146 +0,0 @@ - - - - - - - Usuarios Registrados - - - - - - - -
-

Usuarios Registrados

- Registrar nuevo usuario - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
IDFechaNombreCorreoTeléfonoAcciones
- Eliminar -
No hay usuarios registrados.
-
- - \ No newline at end of file diff --git a/code/views/adminPanel/usuario/perfil.php b/code/views/adminPanel/usuario/perfil.php deleted file mode 100644 index 500c7b599..000000000 --- a/code/views/adminPanel/usuario/perfil.php +++ /dev/null @@ -1,90 +0,0 @@ - - - - - Perfil de Usuario - - - -
-
-

- -
-

Email:

-

Teléfono:

-

Fecha creación:

-
- - - - - - - - -
- - diff --git a/code/views/login/login.php b/code/views/login/login.php deleted file mode 100644 index adccf4b52..000000000 --- a/code/views/login/login.php +++ /dev/null @@ -1,47 +0,0 @@ - -
-
- × - - -
-

Welcome back

-
- - - - -
- -
- - -
-
- - - - -
-
diff --git a/code/views/login/register.php b/code/views/login/register.php deleted file mode 100644 index 140904787..000000000 --- a/code/views/login/register.php +++ /dev/null @@ -1,67 +0,0 @@ - - - - - - Registro - - - - - - - - - -
-
-
-
- - -
-
- - -
-
- -
- - -
-
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- -
- - -
-
- - - - - - \ No newline at end of file diff --git a/code/views/login/styles.css b/code/views/login/styles.css deleted file mode 100644 index eb04ceef7..000000000 --- a/code/views/login/styles.css +++ /dev/null @@ -1,130 +0,0 @@ -/* Reset */ -* { - margin: 0; - padding: 0; - box-sizing: border-box; -} - -body { - font-family: "Roboto", sans-serif; - background: #fff; - color: #21272A; - display: flex; - flex-direction: column; - min-height: 100vh; -} - -/* Header */ -.header { - display: flex; - align-items: center; - justify-content: center; - padding: 16px 40px; - border-bottom: 1px solid #21272A; -} - -.logo { - display: flex; - align-items: center; - gap: 8px; -} - -.logo-icon { - width: 24px; - height: 24px; - background: #4D5358; -} - -.logo-text h1 { - font-size: 20px; - font-weight: 700; - color: #697077; -} - -.logo-text span { - font-size: 12px; - color: #697077; - display: block; - margin-top: -4px; -} - -/* Login */ -.login-container { - flex: 1; - display: flex; - justify-content: center; - align-items: center; -} - -.login-form { - width: 100%; - max-width: 400px; - display: flex; - flex-direction: column; - gap: 16px; -} - -.login-form label { - font-size: 14px; - color: #21272A; -} - -.login-form input { - padding: 12px 16px; - border: none; - border-bottom: 1px solid #C1C7CD; - background: #F2F4F8; - font-size: 16px; - color: #21272A; - outline: none; -} - -.login-form input:focus { - border-color: #0F62FE; -} - -.form-options { - display: flex; - justify-content: space-between; - font-size: 14px; -} - -.form-options a { - color: #0F62FE; - text-decoration: none; -} - -/* Botón */ -.btn { - padding: 14px; - border: 2px solid #21272A; - background: #fff; - font-size: 16px; - font-weight: 500; - cursor: pointer; -} - -.btn:hover { - background: #21272A; - color: #fff; - transition: 0.3s; -} - -.signup-text { - text-align: center; - font-size: 14px; -} - -.signup-text a { - color: #0F62FE; - text-decoration: none; -} - -/* Footer */ -.footer { - background: #697077; - color: #fff; - text-align: center; - padding: 16px; - font-size: 12px; -} diff --git a/code/views/servicio/index.php b/code/views/servicio/index.php deleted file mode 100644 index 2a4e15c46..000000000 --- a/code/views/servicio/index.php +++ /dev/null @@ -1,4 +0,0 @@ - - - - - - QueLaburo - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/code/views/usuario/perfil.php b/code/views/usuario/perfil.php deleted file mode 100644 index 500c7b599..000000000 --- a/code/views/usuario/perfil.php +++ /dev/null @@ -1,90 +0,0 @@ - - - - - Perfil de Usuario - - - -
-
-

- -
-

Email:

-

Teléfono:

-

Fecha creación:

-
- - - - - - - - -
- -