Compare commits

...

No commits in common. "master" and "eb62c727ef2c9065f0f383b91de36d06a40326c9" have entirely different histories.

376 changed files with 63 additions and 37368 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 190 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 236 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 178 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 196 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 275 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 78 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 74 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 76 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 205 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 135 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 178 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 190 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 230 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 149 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 106 KiB

View File

@ -1,45 +0,0 @@
# See http://help.github.com/ignore-files/ for more about ignoring files.
# Compiled output
/dist
/tmp
/out-tsc
/bazel-out
# Node
/node_modules
npm-debug.log
yarn-error.log
# IDEs and editors
.idea/
.project
.classpath
.c9/
*.launch
.settings/
*.sublime-workspace
# Visual Studio Code
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json
.history/*
# Miscellaneous
/.angular/cache
.sass-cache/
/connect.lock
/coverage
/libpeerconnection.log
testem.log
/typings
# System files
.DS_Store
Thumbs.db
# Ignore dist
dist/

View File

@ -1,109 +0,0 @@
<!DOCTYPE html>
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Моя страница</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountLogin.html">Войти</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-1">
<h1 class="text-warning text-center font-weight-bold">Панель администратора</h1>
<div class="btn-group" role="group">
<button id="items-add" class="btn btn-primary">Добавить товар (диалог)</button>
<a class="btn btn-danger" href="/page-edit.html">Добавить товар (страница)</a>
</div>
<div>
<h2 class="text-warning text-center font-weight-bold" style="padding-top: 30px;">Таблица данных</h2>
<table id="items-table" class="table table-striped">
<thead>
<th scope="col"></th>
<th scope="col" class="w-25">Товар</th>
<th scope="col" class="w-25">Цена</th>
<th scope="col" class="w-25">Количество</th>
<th scope="col" class="w-25">Описание</th>
<th scope="col"></th>
<th scope="col"></th>
<th scope="col"></th>
</thead>
<tbody></tbody>
</table>
</div>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
<div id="items-update" class="modal fade" tabindex="-1" data-bs-backdrop="static" data-bs-keyboard="false">
<div class="modal-dialog">
<form id="items-form" class="needs-validation" novalidate>
<div class="modal-content">
<div class="modal-header">
<h1 class="modal-title fs-5" id="items-update-title"></h1>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
<div class="text-center">
<img id="image-preview" src="https://via.placeholder.com/200" class="rounded rounded-circle"
alt="placeholder">
</div>
<input id="items-line-id" type="number" hidden>
<div class="mb-2">
<label for="item" class="form-label">Товары</label>
<select id="item" class="form-select" name="selected" required>
</select>
</div>
<div class="mb-2">
<label class="form-label" for="price">Цена</label>
<input id="price" name="price" class="form-control" type="number" value="0.00" min="1000.00"
step="0.50" required>
</div>
<div class="mb-2">
<label class="form-label" for="count">Количество</label>
<input id="count" name="count" class="form-control" type="number" value="0" min="1" step="1"
required>
</div>
<div class="mb-2">
<label class="form-label" for="image">Изображение</label>
<input id="image" type="file" name="image" class="form-control" accept="image/*">
</div>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">Закрыть</button>
<button type="submit" class="btn btn-primary">Сохранить</button>
</div>
</div>
</form>
</div>
</div>
</body>
</html>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 32 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 669 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 38 KiB

View File

@ -1,196 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Корзина</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountLogin.html">Войти</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container">
<div class="d-flex justify-content-center align-items-center">
<h1 class="text-warning font-weight-bold">Корзина</h1>
</div>
<div class="row">
<div class="col-10">
<div class="card rounded-3 mb-4">
<div class="card-body p-4">
<div class="row d-flex justify-content-between align-items-center">
<div class="col-md-2 col-lg-2 col-xl-2">
<img src="Images/pizza.png" class="img-fluid rounded-3" alt="Cotton T-shirt">
</div>
<div class="col-md-3 col-lg-3 col-xl-3">
<p class="lead fw-normal mb-2">Название пиццы</p>
<p><span class="text-muted">Описание</span></p>
</div>
<div class="col-md-3 col-lg-3 col-xl-2 d-flex">
<button class="btn btn-link px-2"
onclick="this.parentNode.querySelector('input[type=number]').stepDown()">
<i class="fas fa-minus"></i>
</button>
<input id="form1" min="0" name="quantity" value="2" type="number"
class="form-control form-control-sm" />
<button class="btn btn-link px-2"
onclick="this.parentNode.querySelector('input[type=number]').stepUp()">
<i class="fas fa-plus"></i>
</button>
</div>
<div class="col-md-3 col-lg-2 col-xl-2 offset-lg-1">
<h5 class="mb-0">Цена ₽</h5>
</div>
<div class="col-md-1 col-lg-1 col-xl-1 text-end">
<a href="#!" class="text-danger"><i class="fas fa-trash fa-lg"></i></a>
</div>
</div>
</div>
</div>
<div class="card rounded-3 mb-4">
<div class="card-body p-4">
<div class="row d-flex justify-content-between align-items-center">
<div class="col-md-2 col-lg-2 col-xl-2">
<img src="Images/pizza.png" class="img-fluid rounded-3" alt="Cotton T-shirt">
</div>
<div class="col-md-3 col-lg-3 col-xl-3">
<p class="lead fw-normal mb-2">Название пиццы</p>
<p><span class="text-muted">Описание</span></p>
</div>
<div class="col-md-3 col-lg-3 col-xl-2 d-flex">
<button class="btn btn-link px-2"
onclick="this.parentNode.querySelector('input[type=number]').stepDown()">
<i class="fas fa-minus"></i>
</button>
<input id="form1" min="0" name="quantity" value="2" type="number"
class="form-control form-control-sm" />
<button class="btn btn-link px-2"
onclick="this.parentNode.querySelector('input[type=number]').stepUp()">
<i class="fas fa-plus"></i>
</button>
</div>
<div class="col-md-3 col-lg-2 col-xl-2 offset-lg-1">
<h5 class="mb-0">Цена ₽</h5>
</div>
<div class="col-md-1 col-lg-1 col-xl-1 text-end">
<a href="#!" class="text-danger"><i class="fas fa-trash fa-lg"></i></a>
</div>
</div>
</div>
</div>
<div class="card rounded-3 mb-4">
<div class="card-body p-4">
<div class="row d-flex justify-content-between align-items-center">
<div class="col-md-2 col-lg-2 col-xl-2">
<img src="Images/pizza.png" class="img-fluid rounded-3" alt="Cotton T-shirt">
</div>
<div class="col-md-3 col-lg-3 col-xl-3">
<p class="lead fw-normal mb-2">Название пиццы</p>
<p><span class="text-muted">Описание</span></p>
</div>
<div class="col-md-3 col-lg-3 col-xl-2 d-flex">
<button class="btn btn-link px-2"
onclick="this.parentNode.querySelector('input[type=number]').stepDown()">
<i class="fas fa-minus"></i>
</button>
<input id="form1" min="0" name="quantity" value="2" type="number"
class="form-control form-control-sm" />
<button class="btn btn-link px-2"
onclick="this.parentNode.querySelector('input[type=number]').stepUp()">
<i class="fas fa-plus"></i>
</button>
</div>
<div class="col-md-3 col-lg-2 col-xl-2 offset-lg-1">
<h5 class="mb-0">Цена ₽</h5>
</div>
<div class="col-md-1 col-lg-1 col-xl-1 text-end">
<a href="#!" class="text-danger"><i class="fas fa-trash fa-lg"></i></a>
</div>
</div>
</div>
</div>
<div class="card rounded-3 mb-4">
<div class="card-body p-4">
<div class="row d-flex justify-content-between align-items-center">
<div class="col-md-2 col-lg-2 col-xl-2">
<img src="Images/pizza.png" class="img-fluid rounded-3" alt="Cotton T-shirt">
</div>
<div class="col-md-3 col-lg-3 col-xl-3">
<p class="lead fw-normal mb-2">Название пиццы</p>
<p><span class="text-muted">Описание</span></p>
</div>
<div class="col-md-3 col-lg-3 col-xl-2 d-flex">
<button class="btn btn-link px-2"
onclick="this.parentNode.querySelector('input[type=number]').stepDown()">
<i class="fas fa-minus"></i>
</button>
<input id="form1" min="0" name="quantity" value="2" type="number"
class="form-control form-control-sm" />
<button class="btn btn-link px-2"
onclick="this.parentNode.querySelector('input[type=number]').stepUp()">
<i class="fas fa-plus"></i>
</button>
</div>
<div class="col-md-3 col-lg-2 col-xl-2 offset-lg-1">
<h5 class="mb-0">Цена ₽</h5>
</div>
<div class="col-md-1 col-lg-1 col-xl-1 text-end">
<a href="#!" class="text-danger"><i class="fas fa-trash fa-lg"></i></a>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="d-flex justify-content-start align-items-center">
<div class="text-dark font-weight-bold" style="font-size: 24px;">
Сумма заказа:
</div>
<div class="text-end" style="color: #F7D22D; font-size: 24px;">
Сумма ₽
</div>
</div>
<a class="btn btn-warning" style="margin-left: 25px; margin-bottom: 10px;" href="makingAnOrder.html">К оплате</a>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

View File

@ -1,59 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Контакты</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link active" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountLogin.html">Войти</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<div class="d-flex justify-content-center align-items-center">
<h1 class="text-warning font-weight-bold">Контакты</h1>
</div>
<div class="container">
<div class="row">
<div class="div d-flex justify-content-center">
<iframe src="https://yandex.ru/map-widget/v1/?um=constructor%3A0643c92cbdf3809080e5dfb2804b473ea00af31cfabe6fee08676c59d8675f01&amp;source=constructor" class="img-fluid" style="width: 1280; height: 720px;"></iframe>
</div>
<a href="tel:71112223344" class="text-warning font-weight-bold" style="font-size: 35px; margin-left: 10px; margin-top: 10px;">7 111 222 33 44</a>
<h2 class="font-weight-bold" style="font-size: 35px; margin-left: 10px; margin-top: 10px;">ул. Северный венец 32</h2>
<p style="font-size: 25px; margin-left: 10px; margin-top: 10px;">Доставка и самовывоз 10:00 — 23:00</p>
</div>
</div>
</div>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

View File

@ -1,292 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Каталог</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link active" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountLogin.html">Войти</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<div class="d-flex justify-content-center align-items-center">
<h1 class="text-warning font-weight-bold">Каталог</h1>
</div>
<div class="container">
<div class="row">
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
</div>
</div>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

View File

@ -1,37 +0,0 @@
import { Modal } from "bootstrap";
import { cntrls, imagePlaceholder } from "./lines-ui";
const modal = document.getElementById("items-update");
const myModal = modal ? new Modal(modal, {}) : null;
const modalTitle = document.getElementById("items-update-title");
function resetValues() {
cntrls.lineId.value = "";
cntrls.itemsType.value = "";
cntrls.price.value = parseFloat(0).toFixed(2);
cntrls.count.value = 0;
cntrls.image.value = "";
cntrls.imagePreview.src = imagePlaceholder;
}
export function showUpdateModal(item) {
modalTitle.innerHTML = item === null ? "Добавить" : "Изменить";
console.info(item);
if (item) {
cntrls.lineId.value = item.id;
cntrls.itemsType.value = item.itemsId;
cntrls.price.value = item.price;
cntrls.count.value = item.count;
cntrls.imagePreview.src = item.image ? item.image : imagePlaceholder;
} else {
resetValues();
}
myModal.show();
}
export function hideUpdateModal() {
resetValues();
cntrls.form.classList.remove("was-validated");
myModal.hide();
}

View File

@ -1,85 +0,0 @@
const serverUrl = "http://localhost:8081";
function createLineObject(item, price, count, image) {
return {
itemsId: item,
price: parseFloat(price).toFixed(2),
count,
sum: parseFloat(price * count).toFixed(2),
image,
};
}
export async function getAllItemTypes() {
const response = await fetch(`${serverUrl}/items`);
if (!response.ok) {
throw response.statusText;
}
return response.json();
}
export async function getAllLines() {
const response = await fetch(`${serverUrl}/lines?_expand=items`);
if (!response.ok) {
throw response.statusText;
}
return response.json();
}
export async function getLine(id) {
const response = await fetch(`${serverUrl}/lines/${id}?_expand=items`);
if (!response.ok) {
throw response.statusText;
}
return response.json();
}
export async function createLine(item, price, count, image) {
const itemObject = createLineObject(item, price, count, image);
const options = {
method: "POST",
body: JSON.stringify(itemObject),
headers: {
"Accept": "application/json",
"Content-Type": "application/json",
},
};
const response = await fetch(`${serverUrl}/lines`, options);
if (!response.ok) {
throw response.statusText;
}
return response.json();
}
export async function updateLine(id, item, price, count, image) {
const itemObject = createLineObject(item, price, count, image);
const options = {
method: "PUT",
body: JSON.stringify(itemObject),
headers: {
"Accept": "application/json",
"Content-Type": "application/json",
},
};
const response = await fetch(`${serverUrl}/lines/${id}`, options);
if (!response.ok) {
throw response.statusText;
}
return response.json();
}
export async function deleteLine(id) {
const options = {
method: "DELETE",
};
const response = await fetch(`${serverUrl}/lines/${id}`, options);
if (!response.ok) {
throw response.statusText;
}
return response.json();
}

View File

@ -1,59 +0,0 @@
export const cntrls = {
button: document.getElementById("items-add"),
table: document.querySelector("#items-table tbody"),
form: document.getElementById("items-form"),
lineId: document.getElementById("items-line-id"),
itemsType: document.getElementById("item"),
price: document.getElementById("price"),
count: document.getElementById("count"),
image: document.getElementById("image"),
imagePreview: document.getElementById("image-preview"),
};
export const imagePlaceholder = "https://via.placeholder.com/200";
export function createItemsOption(name, value = "", isSelected = false) {
const option = document.createElement("option");
option.value = value || "";
option.selected = isSelected;
option.text = name;
return option;
}
function createTableAnchor(icon, callback) {
const i = document.createElement("i");
i.classList.add("fa-solid", icon);
const a = document.createElement("a");
a.href = "#";
a.appendChild(i);
a.onclick = (event) => {
event.preventDefault();
event.stopPropagation();
callback();
};
const td = document.createElement("td");
td.appendChild(a);
return td;
}
function createTableColumn(value) {
const td = document.createElement("td");
td.textContent = value;
return td;
}
export function createTableRow(item, index, editCallback, editPageCallback, deleteCallback) {
const rowNumber = document.createElement("th");
rowNumber.scope = "row";
rowNumber.textContent = index + 1;
const row = document.createElement("tr");
row.id = `line-${item.id}`;
row.appendChild(rowNumber);
row.appendChild(createTableColumn(item.items.name));
row.appendChild(createTableColumn(parseFloat(item.price).toFixed(2)));
row.appendChild(createTableColumn(item.count));
row.appendChild(createTableColumn(parseFloat(item.sum).toFixed(2)));
row.appendChild(createTableAnchor("fa-pencil", editCallback));
row.appendChild(createTableAnchor("fa-pen-to-square", editPageCallback));
row.appendChild(createTableAnchor("fa-trash", deleteCallback));
return row;
}

View File

@ -1,176 +0,0 @@
import { hideUpdateModal, showUpdateModal } from "./lines-modal";
import {
createLine, deleteLine, getAllItemTypes, getAllLines, getLine, updateLine,
} from "./lines-rest-api";
import {
cntrls, createItemsOption, createTableRow, imagePlaceholder,
} from "./lines-ui";
async function drawItemsSelect() {
const data = await getAllItemTypes();
cntrls.itemsType.innerHTML = "";
cntrls.itemsType.appendChild(createItemsOption("Выберите значение", "", true));
data.forEach((item) => {
cntrls.itemsType.appendChild(createItemsOption(item.name, item.id));
});
}
async function drawLinesTable() {
console.info("Try to load data");
if (!cntrls.table) {
return;
}
const data = await getAllLines();
cntrls.table.innerHTML = "";
data.forEach((item, index) => {
cntrls.table.appendChild(
createTableRow(
item,
index,
() => showUpdateModal(item),
() => location.assign(`page-edit.html?id=${item.id}`),
() => removeLine(item.id),
),
);
});
}
async function addLine(item, price, count, image) {
console.info("Try to add item");
const data = await createLine(item, price, count, image);
console.info("Added");
console.info(data);
drawLinesTable();
}
async function editLine(id, item, price, count, image) {
console.info("Try to update item");
const data = await updateLine(id, item, price, count, image);
console.info("Updated");
console.info(data);
drawLinesTable();
}
async function removeLine(id) {
if (!confirm("Do you really want to remove this item?")) {
console.info("Canceled");
return;
}
console.info("Try to remove item");
const data = await deleteLine(id);
console.info(data);
drawLinesTable();
}
async function readFile(file) {
const reader = new FileReader();
return new Promise((resolve, reject) => {
reader.onloadend = () => {
const fileContent = reader.result;
resolve(fileContent);
};
reader.onerror = () => {
reject(new Error("oops, something went wrong with the file reader."));
};
reader.readAsDataURL(file);
});
}
async function updateImagePreview() {
const file = cntrls.image.files[0];
const fileContent = await readFile(file);
console.info("base64 ", fileContent);
cntrls.imagePreview.src = fileContent;
}
export function linesForm() {
console.info("linesForm");
drawItemsSelect();
drawLinesTable();
cntrls.image.addEventListener("change", () => updateImagePreview());
cntrls.button.addEventListener("click", () => showUpdateModal(null));
cntrls.form.addEventListener("submit", async (event) => {
console.info("Form onSubmit");
event.preventDefault();
event.stopPropagation();
if (!cntrls.form.checkValidity()) {
return;
}
let imageBase64 = "";
if (cntrls.imagePreview.src !== imagePlaceholder) {
const result = await fetch(cntrls.imagePreview.src);
const blob = await result.blob();
imageBase64 = await readFile(blob);
}
const currentId = cntrls.lineId.value;
if (!currentId) {
await addLine(
cntrls.itemsType.value,
cntrls.price.value,
cntrls.count.value,
imageBase64,
);
} else {
await editLine(
currentId,
cntrls.itemsType.value,
cntrls.price.value,
cntrls.count.value,
imageBase64,
);
}
hideUpdateModal();
});
}
export async function linesPageForm() {
console.info("linesPageForm");
drawItemsSelect();
const goBack = () => location.assign("/page4.html");
cntrls.image.addEventListener("change", () => updateImagePreview());
const urlParams = new URLSearchParams(location.search);
const currentId = urlParams.get("id");
if (currentId) {
try {
const line = await getLine(currentId);
cntrls.itemsType.value = line.itemsId;
cntrls.price.value = line.price;
cntrls.count.value = line.count;
cntrls.imagePreview.src = line.image ? line.image : imagePlaceholder;
} catch {
goBack();
}
}
cntrls.form.addEventListener("submit", async (event) => {
console.info("Form onSubmit");
event.preventDefault();
event.stopPropagation();
if (!cntrls.form.checkValidity()) {
return;
}
let imageBase64 = "";
if (cntrls.imagePreview.src !== imagePlaceholder) {
const result = await fetch(cntrls.imagePreview.src);
const blob = await result.blob();
imageBase64 = await readFile(blob);
}
if (!currentId) {
await addLine(
cntrls.itemsType.value,
cntrls.price.value,
cntrls.count.value,
imageBase64,
);
} else {
await editLine(
currentId,
cntrls.itemsType.value,
cntrls.price.value,
cntrls.count.value,
imageBase64,
);
}
goBack();
});
}

View File

@ -1,16 +0,0 @@
function validation() {
const forms = document.querySelectorAll("form.needs-validation");
for (let i = 0; i < forms.length; i += 1) {
const form = forms[i];
form.addEventListener("submit", (event) => {
if (!form.checkValidity()) {
event.preventDefault();
event.stopPropagation();
}
form.classList.add("was-validated");
});
}
}
export default validation;

View File

@ -1,194 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Оформление заказа</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccount.html">Профиль</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<section class="h-100">
<div class="mask d-flex align-items-center h-100 gradient-custom-3">
<div class="container h-100">
<div class="row d-flex justify-content-center align-items-center h-100">
<div class="col-12 col-md-9 col-lg-7 col-xl-6">
<div class="card" style="border-radius: 15px; border-color:gold;">
<div class="card-body p-5">
<h2 class="text-uppercase text-center mb-5">Оформление заказа</h2>
<form>
<div class="form-outline mb-4">
<input type="text" id="form3Example1cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example1cg">Ваше имя</label>
</div>
<div class="form-outline mb-4">
<input type="tel" id="form3Example5cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example5cg">Номер телефона</label>
</div>
<label class="form-check-label" for="creditCard">Вариант получения</label>
<div class="form-check mb-4">
<input class="form-check-input" type="radio" name="deliveryMethod" id="selfPickup" value="selfPickup">
<label class="form-check-label" for="selfPickup">Самовывоз</label>
</div>
<div class="form-check mb-4">
<input class="form-check-input" type="radio" name="deliveryMethod" id="delivery" value="delivery">
<label class="form-check-label" for="delivery">Доставка</label>
</div>
<div class="form-outline mb-4" id="deliveryAddress" style="display: none;">
<input type="text" id="form3ExampleAddress" class="form-control form-control-lg" />
<label class="form-label" for="form3ExampleAddress">Ваш адрес доставки</label>
<div id="deliveryTimeOptions">
<select class="form-select" id="timeSlotSelect" name="timeSlot">
<option value="10:00-10:30">10:00-10:30</option>
<option value="10:30-11:00">10:30-11:00</option>
<option value="11:00-11:30">11:00-11:30</option>
<option value="11:30-12:00">11:30-12:00</option>
<option value="12:00-12:30">12:00-12:30</option>
<option value="12:30-13:00">12:30-13:00</option>
<option value="13:00-13:30">13:00-13:30</option>
<option value="13:30-14:00">13:30-14:00</option>
<option value="14:00-14:30">14:00-14:30</option>
<option value="14:30-15:00">14:30-15:00</option>
<option value="15:00-15:30">15:00-15:30</option>
<option value="15:30-16:00">15:30-16:00</option>
<option value="16:00-16:30">16:00-16:30</option>
<option value="16:30-17:00">16:30-17:00</option>
<option value="17:00-17:30">17:00-17:30</option>
<option value="17:30-18:00">17:30-18:00</option>
<option value="18:00-18:30">18:00-18:30</option>
<option value="18:30-19:00">18:30-19:00</option>
<option value="19:00-19:30">19:00-19:30</option>
<option value="19:30-20:00">19:30-20:00</option>
<option value="20:00-20:30">20:00-20:30</option>
<option value="20:30-21:00">20:30-21:00</option>
<option value="21:00-21:30">21:00-21:30</option>
<option value="21:30-22:00">21:30-22:00</option>
<option value="22:00-22:30">22:00-22:30</option>
<option value="22:30-23:00">22:30-23:00</option>
</select>
<label for="timeSlotSelect">Выберите время доставки:</label>
</div>
</div>
<label class="form-check-label" for="creditCard">Вариант оплаты</label>
<div class="form-check mb-4">
<input class="form-check-input" type="radio" name="paymentMethod" id="cash" value="cash">
<label class="form-check-label" for="cash">Наличные</label>
</div>
<div class="form-check mb-4">
<input class="form-check-input" type="radio" name="paymentMethod" id="creditCard" value="creditCard">
<label class="form-check-label" for="creditCard">Оплата картой</label>
</div>
<div class="form-outline mb-4" id="creditCardDetails" style="display: none;">
<div class="row mb-4">
<div class="col">
<div class="form-outline">
<input type="text" id="formNameOnCard" class="form-control" />
<label class="form-label" for="formNameOnCard">Имя держателя карты</label>
</div>
</div>
<div class="col">
<div class="form-outline">
<input type="text" id="formCardNumber" class="form-control" />
<label class="form-label" for="formCardNumber">Номер карты</label>
</div>
</div>
</div>
<div class="row mb-4">
<div class="col-3">
<div class="form-outline">
<input type="text" id="formExpiration" class="form-control" />
<label class="form-label" for="formExpiration">Срок действия</label>
</div>
</div>
<div class="col-3">
<div class="form-outline">
<input type="text" id="formCVV" class="form-control" />
<label class="form-label" for="formCVV">CVV</label>
</div>
</div>
</div>
</div>
<div class="d-flex justify-content-center">
<button class="btn btn-warning" type="button" id="saveButton">Оформить</button>
</div>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
<script>
$(document).ready(function() {
$('input[type=radio][name=deliveryMethod]').change(function() {
if (this.value === 'delivery') {
$('#deliveryAddress').show();
$('#deliveryTimeOptions').show();
} else {
$('#deliveryAddress').hide();
$('#deliveryTimeOptions').hide();
}
});
$('input[type=radio][name=paymentMethod]').change(function() {
if (this.value === 'creditCard') {
$('#creditCardDetails').show();
} else {
$('#creditCardDetails').hide();
}
});
});
</script>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

File diff suppressed because it is too large Load Diff

View File

@ -1,26 +0,0 @@
{
"name": "int-prog",
"version": "1.0.0",
"type": "module",
"scripts": {
"vite": "vite",
"serve": "http-server -p 3000 ./dist/",
"build": "vite build",
"rest": "json-server --watch data.json -p 8081",
"dev": "npm-run-all --parallel rest vite",
"prod": "npm-run-all build --parallel serve rest"
},
"dependencies": {
"bootstrap": "5.3.2",
"@fortawesome/fontawesome-free": "6.4.2"
},
"devDependencies": {
"vite": "4.4.9",
"eslint": "8.50.0",
"eslint-config-airbnb-base": "15.0.0",
"eslint-plugin-import": "2.28.1",
"http-server": "14.1.1",
"json-server": "0.17.4",
"npm-run-all": "4.1.5"
}
}

View File

@ -1,84 +0,0 @@
<!DOCTYPE html>
<html lang="ru" class="h-100">
<head>
<meta charset="utf-8">
<title>Моя страница</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet" />
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet" />
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountLogin.html">Войти</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<h1 class="text-warning text-center font-weight-bold">Добавление товара</h1>
<div class="text-center">
<img id="image-preview" src="https://via.placeholder.com/200" class="rounded rounded-circle"
alt="placeholder">
</div>
<form id="items-form" class="needs-validation" novalidate>
<div class="mb-2">
<label for="item" class="form-label">Товары</label>
<select id="item" class="form-select" name="selected" required>
</select>
</div>
<div class="mb-2">
<label class="form-label" for="price">Цена</label>
<input id="price" name="price" class="form-control" type="number" value="0.00" min="1000.00" step="0.50"
required>
</div>
<div class="mb-2">
<label class="form-label" for="count">Количество</label>
<input id="count" name="count" class="form-control" type="number" value="0" min="1" step="1" required>
</div>
<div class="mb-2">
<label class="form-label" for="image">Изображение</label>
<input id="image" type="file" name="image" class="form-control" accept="image/*">
</div>
<a href="Administrator.html" class="btn btn-secondary">Назад</a>
<button type="submit" class="btn btn-primary">Сохранить</button>
</form>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Автор, 2022
</footer>
<script type="module">
import validation from "./js/validation";
import { linesPageForm } from "./js/lines"
document.addEventListener('DOMContentLoaded', () => {
validation();
linesPageForm();
});
</script>
</body>
</html>

View File

@ -1,98 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Личный кабинет</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccount.html">Профиль</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<section class="h-100">
<div class="mask d-flex align-items-center h-100 gradient-custom-3">
<div class="container h-100">
<div class="row d-flex justify-content-center align-items-center h-100">
<div class="col-12 col-md-9 col-lg-7 col-xl-6">
<div class="card" style="border-radius: 15px; border-color:gold;">
<div class="card-body p-5">
<h2 class="text-uppercase text-center mb-5">Личный кабинет</h2>
<form>
<div class="form-outline mb-4">
<input type="text" id="form3Example1cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example1cg">Ваше имя</label>
</div>
<div class="form-outline mb-4">
<input type="text" id="form3Example1cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example1cg">Ваша фамилия</label>
</div>
<div class="form-outline mb-4">
<input type="email" id="form3Example3cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example3cg">Ваш адрес электронной почты</label>
</div>
<div class="form-outline mb-4">
<input type="date" id="form3Example4cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example4cg">Дата рождения</label>
</div>
<div class="form-outline mb-2">
<input type="tel" id="form3Example5cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example5cg">Номер телефона</label>
</div>
<div class="d-flex justify-content-center">
<button class="btn btn-warning" type="button" id="saveButton">Сохранить</button>
</div>
<div class="d-flex justify-content-center">
<a class="btn btn-outline-danger" type="button" href="index.html">Выйти</a>
</div>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

View File

@ -1,91 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Личный кабинет - Вход</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountLogin.html">Войти</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<section class="h-100">
<div class="mask d-flex align-items-center h-100 gradient-custom-3">
<div class="container h-100">
<div class="row d-flex justify-content-center align-items-center h-100">
<div class="col-12 col-md-9 col-lg-7 col-xl-6">
<div class="card" style="border-radius: 15px; border-color:gold;">
<div class="card-body p-5">
<h2 class="text-uppercase text-center mb-5">Войти</h2>
<form>
<div class="form-outline mb-4">
<input type="email" id="form3Example3cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example3cg">Ваш адрес электронной почты</label>
</div>
<div class="form-outline mb-4">
<input type="password" id="form3Example4cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example4cg">Пароль</label>
</div>
<div class="form-check d-flex justify-content-center mb-2">
<input class="form-check-input me-2" type="checkbox" value="" id="form2Example3cg" />
<label class="form-check-label me-2" for="form2Example3g">Запомнить меня</label>
</div>
<p class="text-center text-muted mb-0">Забыли пароль? <a href="recoveryPassword.html"
class="fw-bold text-body"><u>Восстановление пароля</u></a></p>
<div class="d-flex justify-content-center">
<a class="btn btn-success btn-block btn-warning text-body mb-0" href="personalAccount.html">Вход</a>
</div>
<p class="text-center text-muted mb-0">У вас нет аккаунта? <a href="personalAccountRegister.html"
class="fw-bold text-body"><u>Регистрация</u></a></p>
<p class="text-center"><a class="fw-bold text-body" href="Administrator.html">Администратор</a></p>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

View File

@ -1,100 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Личный кабинет - Регистрация</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountLogin.html">Войти</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<section class="h-100">
<div class="mask d-flex align-items-center h-100 gradient-custom-3">
<div class="container h-100">
<div class="row d-flex justify-content-center align-items-center h-100">
<div class="col-12 col-md-9 col-lg-7 col-xl-6">
<div class="card" style="border-radius: 15px; border-color:gold;">
<div class="card-body p-5">
<h2 class="text-uppercase text-center mb-5">Создать учетную запись</h2>
<form>
<div class="form-outline mb-4">
<input type="text" id="form3Example1cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example1cg">Ваше имя</label>
</div>
<div class="form-outline mb-4">
<input type="email" id="form3Example3cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example3cg">Ваш адрес электронной почты</label>
</div>
<div class="form-outline mb-4">
<input type="password" id="form3Example4cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example4cg">Пароль</label>
</div>
<div class="form-outline mb-4">
<input type="password" id="form3Example4cdg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example4cdg">Повторите свой пароль</label>
</div>
<div class="form-check d-flex justify-content-center mb-5">
<input class="form-check-input me-2" type="checkbox" value="" id="form2Example3cg" />
<label class="form-check-label" for="form2Example3g">
Я согласен со всеми утверждениями в <a href="#!" class="text-body"><u>Условиях обслуживания</u></a>
</label>
</div>
<div class="d-flex justify-content-center">
<button type="button"
class="btn btn-success btn-block btn-warning text-body mb-0">Регистрация</button>
</div>
<p class="text-center text-muted mb-0">У вас уже есть учетная запись? <a href="personalAccountLogin.html"
class="fw-bold text-body"><u>Войдите здесь</u></a></p>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

View File

@ -1,81 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Личный кабинет - Восстановление пароля</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountRegister.html">Войти</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<section class="h-100">
<div class="mask d-flex align-items-center h-100 gradient-custom-3">
<div class="container h-100">
<div class="row d-flex justify-content-center align-items-center h-100">
<div class="col-12 col-md-9 col-lg-7 col-xl-6">
<div class="card" style="border-radius: 15px; border-color:gold;">
<div class="card-body p-5">
<h2 class="text-uppercase text-center mb-5">Восстановление пароля</h2>
<h4 class="text-black text-center mb-5">Введите свой адрес электронной почты, и мы вышлем вам электронное письмо с инструкциями по сбросу вашего пароля</h4>
<form>
<div class="form-outline mb-4">
<input type="email" id="form3Example3cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example3cg">Ваш адрес электронной почты</label>
</div>
<div class="d-flex justify-content-center">
<button type="button"
class="btn btn-success btn-block btn-warning text-body mb-0">Сбросить пароль</button>
</div>
<p class="text-center text-muted mb-0"><a href="personalAccountLogin.html"
class="fw-bold text-body"><u>Войти</u></a></p>
<p class="text-center text-muted mb-0"><a href="personalAccountRegister.html"
class="fw-bold text-body"><u>Регистрация</u></a></p>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

View File

@ -1,247 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Акции</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link active" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountLogin.html">Войти</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<div class="d-flex justify-content-center align-items-center">
<h1 class="text-warning font-weight-bold">Акции</h1>
</div>
<div class="container">
<div class="row">
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
</div>
</div>ч
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

View File

@ -1,67 +0,0 @@
header nav {
background-color: #D9D9D9;
}
@media (min-width: 768px) {
header nav {
height: 100px;
}
}
header nav a:hover {
text-decoration: underline;
}
.navbar-brand img {
margin-left: 235px;
}
@media (max-width: 576px) {
.navbar-brand img {
margin-left: 0px;
}
}
@media (min-width: 577px) and (max-width: 992px) {
.navbar-brand img {
margin-left: 25px
}
}
@media (min-width: 993px) and (max-width: 1200px) {
.navbar-brand img {
margin-left: 150px;
}
}
@media (min-width: 1201px) {
.navbar-brand img {
margin-left: 235px;
}
}
.btn-warning {
height: 35px;
width: 176px;
border-radius: 8px;
margin-right: 10px;
margin-top: 10px;
}
.custom-btn {
height: 35px;
width: 176px;
border-radius: 8px;
margin-right: 10px;
margin-top: 10px;
background-color: #FFA800;
}
.btn.custom-btn:hover {
background-color: #FFA800 !important;
}
footer {
background-color: #D9D9D9;
}

View File

@ -1,45 +0,0 @@
# See http://help.github.com/ignore-files/ for more about ignoring files.
# Compiled output
/dist
/tmp
/out-tsc
/bazel-out
# Node
/node_modules
npm-debug.log
yarn-error.log
# IDEs and editors
.idea/
.project
.classpath
.c9/
*.launch
.settings/
*.sublime-workspace
# Visual Studio Code
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json
.history/*
# Miscellaneous
/.angular/cache
.sass-cache/
/connect.lock
/coverage
/libpeerconnection.log
testem.log
/typings
# System files
.DS_Store
Thumbs.db
# Ignore dist
dist/

View File

@ -1,124 +0,0 @@
<!DOCTYPE html>
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Моя страница</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountLogin.html">Администратор</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<h1 class="text-warning text-center font-weight-bold">Панель администратора</h1>
<div class="text-center">
<div class="btn-group" role="group">
<a class="btn btn-warning" href="/page-edit.html">Добавить товар</a>
</div>
</div>
<div>
<h2 class="text-warning text-center font-weight-bold" style="padding-top: 10px;">Таблица данных</h2>
<table id="items-table" class="table table-striped">
<thead>
<th scope="col"></th>
<th scope="col" class="w-25">Товар</th>
<th scope="col" class="w-25">Цена</th>
<th scope="col" class="w-10">Акция</th>
<th scope="col" class="w-25">Количество</th>
<th scope="col" class="w-25">Сумма</th>
<th scope="col"></th>
<th scope="col"></th>
</thead>
<tbody></tbody>
</table>
</div>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
<div id="items-update" class="modal fade" tabindex="-1" data-bs-backdrop="static" data-bs-keyboard="false">
<div class="modal-dialog">
<form id="items-form" class="needs-validation" novalidate>
<div class="modal-content">
<div class="modal-header">
<h1 class="modal-title fs-5" id="items-update-title"></h1>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
<div class="text-center">
<img id="image-preview" src="https://via.placeholder.com/200" class="rounded rounded-circle"
alt="placeholder">
</div>
<input id="items-line-id" type="number" hidden>
<div class="mb-2">
<label for="item" class="form-label">Товары</label>
<select id="item" class="form-select" name="selected" required>
</select>
</div>
<div class="mb-2">
<label class="form-label" for="price">Цена</label>
<input id="price" name="price" class="form-control" type="number" value="99.00" min="99.00"
step="1.00" required>
</div>
<div class="mb-2">
<label class="form-label" for="stock">Акция</label>
<input id="stock" name="price" class="form-control" type="number" value="0" min="0"
step="100" required>
</div>
<div class="mb-2">
<label class="form-label" for="count">Количество</label>
<input id="count" name="count" class="form-control" type="number" value="0" min="1" step="1"
required>
</div>
<div class="mb-2">
<label class="form-label" for="image">Изображение</label>
<input id="image" type="file" name="image" class="form-control" accept="image/*">
</div>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">Закрыть</button>
<button type="submit" class="btn btn-primary">Сохранить</button>
</div>
</div>
</form>
</div>
</div>
<script type="module">
import validation from "./js/validation";
import { linesForm } from "./js/lines";
document.addEventListener('DOMContentLoaded', () => {
validation();
linesForm();
});
</script>
</body>
</html>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 32 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 669 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 38 KiB

View File

@ -1,196 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Корзина</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountLogin.html">Войти</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container">
<div class="d-flex justify-content-center align-items-center">
<h1 class="text-warning font-weight-bold">Корзина</h1>
</div>
<div class="row">
<div class="col-10">
<div class="card rounded-3 mb-4">
<div class="card-body p-4">
<div class="row d-flex justify-content-between align-items-center">
<div class="col-md-2 col-lg-2 col-xl-2">
<img src="Images/pizza.png" class="img-fluid rounded-3" alt="Cotton T-shirt">
</div>
<div class="col-md-3 col-lg-3 col-xl-3">
<p class="lead fw-normal mb-2">Название пиццы</p>
<p><span class="text-muted">Описание</span></p>
</div>
<div class="col-md-3 col-lg-3 col-xl-2 d-flex">
<button class="btn btn-link px-2"
onclick="this.parentNode.querySelector('input[type=number]').stepDown()">
<i class="fas fa-minus"></i>
</button>
<input id="form1" min="0" name="quantity" value="2" type="number"
class="form-control form-control-sm" />
<button class="btn btn-link px-2"
onclick="this.parentNode.querySelector('input[type=number]').stepUp()">
<i class="fas fa-plus"></i>
</button>
</div>
<div class="col-md-3 col-lg-2 col-xl-2 offset-lg-1">
<h5 class="mb-0">Цена ₽</h5>
</div>
<div class="col-md-1 col-lg-1 col-xl-1 text-end">
<a href="#!" class="text-danger"><i class="fas fa-trash fa-lg"></i></a>
</div>
</div>
</div>
</div>
<div class="card rounded-3 mb-4">
<div class="card-body p-4">
<div class="row d-flex justify-content-between align-items-center">
<div class="col-md-2 col-lg-2 col-xl-2">
<img src="Images/pizza.png" class="img-fluid rounded-3" alt="Cotton T-shirt">
</div>
<div class="col-md-3 col-lg-3 col-xl-3">
<p class="lead fw-normal mb-2">Название пиццы</p>
<p><span class="text-muted">Описание</span></p>
</div>
<div class="col-md-3 col-lg-3 col-xl-2 d-flex">
<button class="btn btn-link px-2"
onclick="this.parentNode.querySelector('input[type=number]').stepDown()">
<i class="fas fa-minus"></i>
</button>
<input id="form1" min="0" name="quantity" value="2" type="number"
class="form-control form-control-sm" />
<button class="btn btn-link px-2"
onclick="this.parentNode.querySelector('input[type=number]').stepUp()">
<i class="fas fa-plus"></i>
</button>
</div>
<div class="col-md-3 col-lg-2 col-xl-2 offset-lg-1">
<h5 class="mb-0">Цена ₽</h5>
</div>
<div class="col-md-1 col-lg-1 col-xl-1 text-end">
<a href="#!" class="text-danger"><i class="fas fa-trash fa-lg"></i></a>
</div>
</div>
</div>
</div>
<div class="card rounded-3 mb-4">
<div class="card-body p-4">
<div class="row d-flex justify-content-between align-items-center">
<div class="col-md-2 col-lg-2 col-xl-2">
<img src="Images/pizza.png" class="img-fluid rounded-3" alt="Cotton T-shirt">
</div>
<div class="col-md-3 col-lg-3 col-xl-3">
<p class="lead fw-normal mb-2">Название пиццы</p>
<p><span class="text-muted">Описание</span></p>
</div>
<div class="col-md-3 col-lg-3 col-xl-2 d-flex">
<button class="btn btn-link px-2"
onclick="this.parentNode.querySelector('input[type=number]').stepDown()">
<i class="fas fa-minus"></i>
</button>
<input id="form1" min="0" name="quantity" value="2" type="number"
class="form-control form-control-sm" />
<button class="btn btn-link px-2"
onclick="this.parentNode.querySelector('input[type=number]').stepUp()">
<i class="fas fa-plus"></i>
</button>
</div>
<div class="col-md-3 col-lg-2 col-xl-2 offset-lg-1">
<h5 class="mb-0">Цена ₽</h5>
</div>
<div class="col-md-1 col-lg-1 col-xl-1 text-end">
<a href="#!" class="text-danger"><i class="fas fa-trash fa-lg"></i></a>
</div>
</div>
</div>
</div>
<div class="card rounded-3 mb-4">
<div class="card-body p-4">
<div class="row d-flex justify-content-between align-items-center">
<div class="col-md-2 col-lg-2 col-xl-2">
<img src="Images/pizza.png" class="img-fluid rounded-3" alt="Cotton T-shirt">
</div>
<div class="col-md-3 col-lg-3 col-xl-3">
<p class="lead fw-normal mb-2">Название пиццы</p>
<p><span class="text-muted">Описание</span></p>
</div>
<div class="col-md-3 col-lg-3 col-xl-2 d-flex">
<button class="btn btn-link px-2"
onclick="this.parentNode.querySelector('input[type=number]').stepDown()">
<i class="fas fa-minus"></i>
</button>
<input id="form1" min="0" name="quantity" value="2" type="number"
class="form-control form-control-sm" />
<button class="btn btn-link px-2"
onclick="this.parentNode.querySelector('input[type=number]').stepUp()">
<i class="fas fa-plus"></i>
</button>
</div>
<div class="col-md-3 col-lg-2 col-xl-2 offset-lg-1">
<h5 class="mb-0">Цена ₽</h5>
</div>
<div class="col-md-1 col-lg-1 col-xl-1 text-end">
<a href="#!" class="text-danger"><i class="fas fa-trash fa-lg"></i></a>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="d-flex justify-content-start align-items-center">
<div class="text-dark font-weight-bold" style="font-size: 24px;">
Сумма заказа:
</div>
<div class="text-end" style="color: #F7D22D; font-size: 24px;">
Сумма ₽
</div>
</div>
<a class="btn btn-warning" style="margin-left: 25px; margin-bottom: 10px;" href="makingAnOrder.html">К оплате</a>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

View File

@ -1,59 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Контакты</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link active" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountLogin.html">Войти</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<div class="d-flex justify-content-center align-items-center">
<h1 class="text-warning font-weight-bold">Контакты</h1>
</div>
<div class="container">
<div class="row">
<div class="div d-flex justify-content-center">
<iframe src="https://yandex.ru/map-widget/v1/?um=constructor%3A0643c92cbdf3809080e5dfb2804b473ea00af31cfabe6fee08676c59d8675f01&amp;source=constructor" class="img-fluid" style="width: 1280; height: 720px;"></iframe>
</div>
<a href="tel:71112223344" class="text-warning font-weight-bold" style="font-size: 35px; margin-left: 10px; margin-top: 10px;">7 111 222 33 44</a>
<h2 class="font-weight-bold" style="font-size: 35px; margin-left: 10px; margin-top: 10px;">ул. Северный венец 32</h2>
<p style="font-size: 25px; margin-left: 10px; margin-top: 10px;">Доставка и самовывоз 10:00 — 23:00</p>
</div>
</div>
</div>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

View File

@ -1,82 +0,0 @@
{
"items": [
{
"id": 1,
"name": "Маргарита"
},
{
"id": 2,
"name": "Четыре сыра"
},
{
"id": 3,
"name": "Пепперони"
},
{
"id": 4,
"name": "Веганская"
},
{
"id": 5,
"name": "Песто"
},
{
"id": 6,
"name": "Карбонара"
},
{
"id": 7,
"name": "Мясная"
},
{
"id": 8,
"name": "Четыре сезона"
},
{
"id": 9,
"name": "Чоризо фреш"
},
{
"id": 10,
"name": "Цыплёнок барбекю"
}
],
"lines": [
{
"itemsId": "7",
"price": "2000.00",
"stock": "35",
"count": "3",
"sum": "3900.00",
"image": "",
"id": 7
},
{
"itemsId": "6",
"price": "1111.00",
"stock": "50",
"count": "56",
"sum": "31108.00",
"image": "",
"id": 8
},
{
"itemsId": "6",
"price": "1000.00",
"stock": "50",
"count": "10",
"sum": "5000.00",
"image": "",
"id": 9
},
{
"itemsId": "2",
"price": "11111111111.00",
"stock": "10",
"count": "10",
"sum": "99999999999.00",
"image": "",
"id": 10
}
]
}

View File

@ -1,292 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Каталог</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link active" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountLogin.html">Войти</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<div class="d-flex justify-content-center align-items-center">
<h1 class="text-warning font-weight-bold">Каталог</h1>
</div>
<div class="container">
<div class="row">
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
<div class="col-lg-3 col-md-4 col-sm-6 col-12 mb-4">
<div class="card">
<img src="Images/pizza.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Название</h5>
</div>
<div class="card-footer">
<div class="text-warning font-weight-bold">Цена ₽</div>
<button class="btn btn-warning">В корзину</button>
</div>
</div>
</div>
</div>
</div>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

View File

@ -1,86 +0,0 @@
const serverUrl = "http://localhost:8081";
function createLineObject(item, price, stock, count, image) {
return {
itemsId: item,
price: parseFloat(price).toFixed(2),
stock,
count,
sum: parseFloat((price * ((100 - stock) / 100)) * count).toFixed(2),
image,
};
}
export async function getAllItemTypes() {
const response = await fetch(`${serverUrl}/items`);
if (!response.ok) {
throw response.statusText;
}
return response.json();
}
export async function getAllLines() {
const response = await fetch(`${serverUrl}/lines?_expand=items`);
if (!response.ok) {
throw response.statusText;
}
return response.json();
}
export async function getLine(id) {
const response = await fetch(`${serverUrl}/lines/${id}?_expand=items`);
if (!response.ok) {
throw response.statusText;
}
return response.json();
}
export async function createLine(item, price, stock, count, image) {
const itemObject = createLineObject(item, price, stock, count, image);
const options = {
method: "POST",
body: JSON.stringify(itemObject),
headers: {
"Accept": "application/json",
"Content-Type": "application/json",
},
};
const response = await fetch(`${serverUrl}/lines`, options);
if (!response.ok) {
throw response.statusText;
}
return response.json();
}
export async function updateLine(id, item, price, stock, count, image) {
const itemObject = createLineObject(item, price, stock, count, image);
const options = {
method: "PUT",
body: JSON.stringify(itemObject),
headers: {
"Accept": "application/json",
"Content-Type": "application/json",
},
};
const response = await fetch(`${serverUrl}/lines/${id}`, options);
if (!response.ok) {
throw response.statusText;
}
return response.json();
}
export async function deleteLine(id) {
const options = {
method: "DELETE",
};
const response = await fetch(`${serverUrl}/lines/${id}`, options);
if (!response.ok) {
throw response.statusText;
}
return response.json();
}

View File

@ -1,60 +0,0 @@
export const cntrls = {
button: document.getElementById("items-add"),
table: document.querySelector("#items-table tbody"),
form: document.getElementById("items-form"),
lineId: document.getElementById("items-line-id"),
itemsType: document.getElementById("item"),
price: document.getElementById("price"),
stock: document.getElementById("stock"),
count: document.getElementById("count"),
image: document.getElementById("image"),
imagePreview: document.getElementById("image-preview"),
};
export const imagePlaceholder = "https://via.placeholder.com/200";
export function createItemsOption(name, value = "", isSelected = false) {
const option = document.createElement("option");
option.value = value || "";
option.selected = isSelected;
option.text = name;
return option;
}
function createTableAnchor(icon, callback) {
const i = document.createElement("i");
i.classList.add("fa-solid", icon);
const a = document.createElement("a");
a.href = "#";
a.appendChild(i);
a.onclick = (event) => {
event.preventDefault();
event.stopPropagation();
callback();
};
const td = document.createElement("td");
td.appendChild(a);
return td;
}
function createTableColumn(value) {
const td = document.createElement("td");
td.textContent = value;
return td;
}
export function createTableRow(item, index, editCallback, deleteCallback) {
const rowNumber = document.createElement("th");
rowNumber.scope = "row";
rowNumber.textContent = index + 1;
const row = document.createElement("tr");
row.id = `line-${item.id}`;
row.appendChild(rowNumber);
row.appendChild(createTableColumn(item.items.name));
row.appendChild(createTableColumn(parseFloat(item.price).toFixed(2)));
row.appendChild(createTableColumn(item.stock != null ? item.stock + "%" : ""));
row.appendChild(createTableColumn(item.count));
row.appendChild(createTableColumn(parseFloat(item.sum).toFixed(2)));
row.appendChild(createTableAnchor("fa-pencil", editCallback));
row.appendChild(createTableAnchor("fa-trash", deleteCallback));
return row;
}

View File

@ -1,177 +0,0 @@
import {
createLine, deleteLine, getAllItemTypes, getAllLines, getLine, updateLine,
} from "./lines-rest-api";
import {
cntrls, createItemsOption, createTableRow, imagePlaceholder,
} from "./lines-ui";
async function drawItemsSelect() {
const data = await getAllItemTypes();
cntrls.itemsType.innerHTML = "";
cntrls.itemsType.appendChild(createItemsOption("Выберите значение", "", true));
data.forEach((item) => {
cntrls.itemsType.appendChild(createItemsOption(item.name, item.id));
});
}
async function drawLinesTable() {
console.info("Try to load data");
if (!cntrls.table) {
return;
}
const data = await getAllLines();
cntrls.table.innerHTML = "";
data.forEach((item, index) => {
cntrls.table.appendChild(
createTableRow(
item,
index,
() => location.assign(`page-edit.html?id=${item.id}`),
() => removeLine(item.id),
),
);
});
}
async function addLine(item, price, stock, count, image) {
console.info("Try to add item");
const data = await createLine(item, price, stock, count, image);
console.info("Added");
console.info(data);
drawLinesTable();
}
async function editLine(id, item, price, stock, count, image) {
console.info("Try to update item");
const data = await updateLine(id, item, price, stock, count, image);
console.info("Updated");
console.info(data);
drawLinesTable();
}
async function removeLine(id) {
if (!confirm("Do you really want to remove this item?")) {
console.info("Canceled");
return;
}
console.info("Try to remove item");
const data = await deleteLine(id);
console.info(data);
drawLinesTable();
}
async function readFile(file) {
const reader = new FileReader();
return new Promise((resolve, reject) => {
reader.onloadend = () => {
const fileContent = reader.result;
resolve(fileContent);
};
reader.onerror = () => {
reject(new Error("oops, something went wrong with the file reader."));
};
reader.readAsDataURL(file);
});
}
async function updateImagePreview() {
const file = cntrls.image.files[0];
const fileContent = await readFile(file);
console.info("base64 ", fileContent);
cntrls.imagePreview.src = fileContent;
}
export function linesForm() {
console.info("linesForm");
drawItemsSelect();
drawLinesTable();
cntrls.image.addEventListener("change", () => updateImagePreview());
cntrls.form.addEventListener("submit", async (event) => {
console.info("Form onSubmit");
event.preventDefault();
event.stopPropagation();
if (!cntrls.form.checkValidity()) {
return;
}
let imageBase64 = "";
if (cntrls.imagePreview.src !== imagePlaceholder) {
const result = await fetch(cntrls.imagePreview.src);
const blob = await result.blob();
imageBase64 = await readFile(blob);
}
const currentId = cntrls.lineId.value;
if (!currentId) {
await addLine(
cntrls.itemsType.value,
cntrls.price.value,
cntrls.stock.value,
cntrls.count.value,
imageBase64,
);
} else {
await editLine(
currentId,
cntrls.itemsType.value,
cntrls.price.value,
cntrls,stock.value,
cntrls.count.value,
imageBase64,
);
}
});
}
export async function linesPageForm() {
console.info("linesPageForm");
drawItemsSelect();
const goBack = () => location.assign("/Administrator.html");
cntrls.image.addEventListener("change", () => updateImagePreview());
const urlParams = new URLSearchParams(location.search);
const currentId = urlParams.get("id");
if (currentId) {
try {
const line = await getLine(currentId);
cntrls.itemsType.value = line.itemsId;
cntrls.price.value = line.price;
cntrls.stock.value = line.stock;
cntrls.count.value = line.count;
cntrls.imagePreview.src = line.image ? line.image : imagePlaceholder;
} catch {
goBack();
}
}
cntrls.form.addEventListener("submit", async (event) => {
console.info("Form onSubmit");
event.preventDefault();
event.stopPropagation();
if (!cntrls.form.checkValidity()) {
return;
}
let imageBase64 = "";
if (cntrls.imagePreview.src !== imagePlaceholder) {
const result = await fetch(cntrls.imagePreview.src);
const blob = await result.blob();
imageBase64 = await readFile(blob);
}
if (!currentId) {
await addLine(
cntrls.itemsType.value,
cntrls.price.value,
cntrls.stock.value,
cntrls.count.value,
imageBase64,
);
} else {
await editLine(
currentId,
cntrls.itemsType.value,
cntrls.price.value,
cntrls.stock.value,
cntrls.count.value,
imageBase64,
);
}
goBack();
});
}

View File

@ -1,16 +0,0 @@
function validation() {
const forms = document.querySelectorAll("form.needs-validation");
for (let i = 0; i < forms.length; i += 1) {
const form = forms[i];
form.addEventListener("submit", (event) => {
if (!form.checkValidity()) {
event.preventDefault();
event.stopPropagation();
}
form.classList.add("was-validated");
});
}
}
export default validation;

View File

@ -1,14 +0,0 @@
{
"compilerOptions": {
"module": "ESNext",
"moduleResolution": "Node",
"target": "ES2020",
"jsx": "preserve",
"strictNullChecks": true,
"strictFunctionTypes": true
},
"exclude": [
"node_modules",
"**/node_modules/*"
]
}

View File

@ -1,194 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Оформление заказа</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccount.html">Профиль</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<section class="h-100">
<div class="mask d-flex align-items-center h-100 gradient-custom-3">
<div class="container h-100">
<div class="row d-flex justify-content-center align-items-center h-100">
<div class="col-12 col-md-9 col-lg-7 col-xl-6">
<div class="card" style="border-radius: 15px; border-color:gold;">
<div class="card-body p-5">
<h2 class="text-uppercase text-center mb-5">Оформление заказа</h2>
<form>
<div class="form-outline mb-4">
<input type="text" id="form3Example1cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example1cg">Ваше имя</label>
</div>
<div class="form-outline mb-4">
<input type="tel" id="form3Example5cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example5cg">Номер телефона</label>
</div>
<label class="form-check-label" for="creditCard">Вариант получения</label>
<div class="form-check mb-4">
<input class="form-check-input" type="radio" name="deliveryMethod" id="selfPickup" value="selfPickup">
<label class="form-check-label" for="selfPickup">Самовывоз</label>
</div>
<div class="form-check mb-4">
<input class="form-check-input" type="radio" name="deliveryMethod" id="delivery" value="delivery">
<label class="form-check-label" for="delivery">Доставка</label>
</div>
<div class="form-outline mb-4" id="deliveryAddress" style="display: none;">
<input type="text" id="form3ExampleAddress" class="form-control form-control-lg" />
<label class="form-label" for="form3ExampleAddress">Ваш адрес доставки</label>
<div id="deliveryTimeOptions">
<select class="form-select" id="timeSlotSelect" name="timeSlot">
<option value="10:00-10:30">10:00-10:30</option>
<option value="10:30-11:00">10:30-11:00</option>
<option value="11:00-11:30">11:00-11:30</option>
<option value="11:30-12:00">11:30-12:00</option>
<option value="12:00-12:30">12:00-12:30</option>
<option value="12:30-13:00">12:30-13:00</option>
<option value="13:00-13:30">13:00-13:30</option>
<option value="13:30-14:00">13:30-14:00</option>
<option value="14:00-14:30">14:00-14:30</option>
<option value="14:30-15:00">14:30-15:00</option>
<option value="15:00-15:30">15:00-15:30</option>
<option value="15:30-16:00">15:30-16:00</option>
<option value="16:00-16:30">16:00-16:30</option>
<option value="16:30-17:00">16:30-17:00</option>
<option value="17:00-17:30">17:00-17:30</option>
<option value="17:30-18:00">17:30-18:00</option>
<option value="18:00-18:30">18:00-18:30</option>
<option value="18:30-19:00">18:30-19:00</option>
<option value="19:00-19:30">19:00-19:30</option>
<option value="19:30-20:00">19:30-20:00</option>
<option value="20:00-20:30">20:00-20:30</option>
<option value="20:30-21:00">20:30-21:00</option>
<option value="21:00-21:30">21:00-21:30</option>
<option value="21:30-22:00">21:30-22:00</option>
<option value="22:00-22:30">22:00-22:30</option>
<option value="22:30-23:00">22:30-23:00</option>
</select>
<label for="timeSlotSelect">Выберите время доставки:</label>
</div>
</div>
<label class="form-check-label" for="creditCard">Вариант оплаты</label>
<div class="form-check mb-4">
<input class="form-check-input" type="radio" name="paymentMethod" id="cash" value="cash">
<label class="form-check-label" for="cash">Наличные</label>
</div>
<div class="form-check mb-4">
<input class="form-check-input" type="radio" name="paymentMethod" id="creditCard" value="creditCard">
<label class="form-check-label" for="creditCard">Оплата картой</label>
</div>
<div class="form-outline mb-4" id="creditCardDetails" style="display: none;">
<div class="row mb-4">
<div class="col">
<div class="form-outline">
<input type="text" id="formNameOnCard" class="form-control" />
<label class="form-label" for="formNameOnCard">Имя держателя карты</label>
</div>
</div>
<div class="col">
<div class="form-outline">
<input type="text" id="formCardNumber" class="form-control" />
<label class="form-label" for="formCardNumber">Номер карты</label>
</div>
</div>
</div>
<div class="row mb-4">
<div class="col-3">
<div class="form-outline">
<input type="text" id="formExpiration" class="form-control" />
<label class="form-label" for="formExpiration">Срок действия</label>
</div>
</div>
<div class="col-3">
<div class="form-outline">
<input type="text" id="formCVV" class="form-control" />
<label class="form-label" for="formCVV">CVV</label>
</div>
</div>
</div>
</div>
<div class="d-flex justify-content-center">
<button class="btn btn-warning" type="button" id="saveButton">Оформить</button>
</div>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
<script>
$(document).ready(function() {
$('input[type=radio][name=deliveryMethod]').change(function() {
if (this.value === 'delivery') {
$('#deliveryAddress').show();
$('#deliveryTimeOptions').show();
} else {
$('#deliveryAddress').hide();
$('#deliveryTimeOptions').hide();
}
});
$('input[type=radio][name=paymentMethod]').change(function() {
if (this.value === 'creditCard') {
$('#creditCardDetails').show();
} else {
$('#creditCardDetails').hide();
}
});
});
</script>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

File diff suppressed because it is too large Load Diff

View File

@ -1,26 +0,0 @@
{
"name": "int-prog",
"version": "1.0.0",
"type": "module",
"scripts": {
"start": "vite",
"serve": "http-server -p 3000 ./dist/",
"build": "vite build",
"rest": "json-server --watch data.json -p 8081",
"dev": "npm-run-all --parallel rest start",
"prod": "npm-run-all build --parallel serve rest"
},
"dependencies": {
"bootstrap": "5.3.2",
"@fortawesome/fontawesome-free": "6.4.2"
},
"devDependencies": {
"vite": "4.4.9",
"eslint": "8.50.0",
"eslint-config-airbnb-base": "15.0.0",
"eslint-plugin-import": "2.28.1",
"http-server": "14.1.1",
"json-server": "0.17.4",
"npm-run-all": "4.1.5"
}
}

View File

@ -1,89 +0,0 @@
<!DOCTYPE html>
<html lang="ru" class="h-100">
<head>
<meta charset="utf-8">
<title>Моя страница</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet" />
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet" />
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountLogin.html">Войти</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<h1 class="text-warning text-center font-weight-bold">Добавление товара</h1>
<div class="text-center">
<img id="image-preview" src="https://via.placeholder.com/200" class="rounded rounded-circle"
alt="placeholder">
</div>
<form id="items-form" class="needs-validation" novalidate>
<div class="mb-2">
<label for="item" class="form-label">Товары</label>
<select id="item" class="form-select" name="selected" required>
</select>
</div>
<div class="mb-2">
<label class="form-label" for="price">Цена</label>
<input id="price" name="price" class="form-control" type="number" value="0.00" min="1000.00" step="0.50"
required>
</div>
<div class="mb-2">
<label class="form-label" for="stock">Акция</label>
<input id="stock" name="price" class="form-control" type="number" value="0" min="0"
step="1" required>
</div>
<div class="mb-2">
<label class="form-label" for="count">Количество</label>
<input id="count" name="count" class="form-control" type="number" value="0" min="1" step="1" required>
</div>
<div class="mb-2">
<label class="form-label" for="image">Изображение</label>
<input id="image" type="file" name="image" class="form-control" accept="image/*">
</div>
<a href="Administrator.html" class="btn btn-secondary">Назад</a>
<button type="submit" class="btn btn-primary">Сохранить</button>
</form>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Автор, 2022
</footer>
<script type="module">
import validation from "./js/validation";
import { linesPageForm } from "./js/lines"
document.addEventListener('DOMContentLoaded', () => {
validation();
linesPageForm();
});
</script>
</body>
</html>

View File

@ -1,98 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Личный кабинет</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccount.html">Профиль</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<section class="h-100">
<div class="mask d-flex align-items-center h-100 gradient-custom-3">
<div class="container h-100">
<div class="row d-flex justify-content-center align-items-center h-100">
<div class="col-12 col-md-9 col-lg-7 col-xl-6">
<div class="card" style="border-radius: 15px; border-color:gold;">
<div class="card-body p-5">
<h2 class="text-uppercase text-center mb-5">Личный кабинет</h2>
<form>
<div class="form-outline mb-4">
<input type="text" id="form3Example1cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example1cg">Ваше имя</label>
</div>
<div class="form-outline mb-4">
<input type="text" id="form3Example1cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example1cg">Ваша фамилия</label>
</div>
<div class="form-outline mb-4">
<input type="email" id="form3Example3cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example3cg">Ваш адрес электронной почты</label>
</div>
<div class="form-outline mb-4">
<input type="date" id="form3Example4cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example4cg">Дата рождения</label>
</div>
<div class="form-outline mb-2">
<input type="tel" id="form3Example5cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example5cg">Номер телефона</label>
</div>
<div class="d-flex justify-content-center">
<button class="btn btn-warning" type="button" id="saveButton">Сохранить</button>
</div>
<div class="d-flex justify-content-center">
<a class="btn btn-outline-danger" type="button" href="index.html">Выйти</a>
</div>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

View File

@ -1,92 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Личный кабинет - Вход</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountLogin.html">Войти</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<section class="h-100">
<div class="mask d-flex align-items-center h-100 gradient-custom-3">
<div class="container h-100">
<div class="row d-flex justify-content-center align-items-center h-100">
<div class="col-12 col-md-9 col-lg-7 col-xl-6">
<div class="card" style="border-radius: 15px; border-color:gold;">
<div class="card-body p-5">
<h2 class="text-uppercase text-center mb-5">Войти</h2>
<form>
<div class="form-outline mb-4">
<input type="email" id="form3Example3cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example3cg">Ваш адрес электронной почты</label>
</div>
<div class="form-outline mb-4">
<input type="password" id="form3Example4cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example4cg">Пароль</label>
</div>
<div class="form-check d-flex justify-content-center mb-2">
<input class="form-check-input me-2" type="checkbox" value="" id="form2Example3cg" />
<label class="form-check-label me-2" for="form2Example3g">Запомнить меня</label>
</div>
<p class="text-center text-muted mb-0">Забыли пароль? <a href="recoveryPassword.html"
class="fw-bold text-body"><u>Восстановление пароля</u></a></p>
<div class="d-flex justify-content-center">
<a class="btn btn-success btn-block btn-warning text-body mb-0" href="personalAccount.html">Вход</a>
</div>
<p class="text-center text-muted mb-0">У вас нет аккаунта? <a href="personalAccountRegister.html"
class="fw-bold text-body"><u>Регистрация</u></a></p>
<p class="text-center"><a class="fw-bold text-body" href="Administrator.html">Администратор</a></p>
<p class="text-center"><a class="fw-bold text-body" href="AdminDop.html">Администратор2</a></p>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

View File

@ -1,100 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Личный кабинет - Регистрация</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountLogin.html">Войти</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<section class="h-100">
<div class="mask d-flex align-items-center h-100 gradient-custom-3">
<div class="container h-100">
<div class="row d-flex justify-content-center align-items-center h-100">
<div class="col-12 col-md-9 col-lg-7 col-xl-6">
<div class="card" style="border-radius: 15px; border-color:gold;">
<div class="card-body p-5">
<h2 class="text-uppercase text-center mb-5">Создать учетную запись</h2>
<form>
<div class="form-outline mb-4">
<input type="text" id="form3Example1cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example1cg">Ваше имя</label>
</div>
<div class="form-outline mb-4">
<input type="email" id="form3Example3cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example3cg">Ваш адрес электронной почты</label>
</div>
<div class="form-outline mb-4">
<input type="password" id="form3Example4cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example4cg">Пароль</label>
</div>
<div class="form-outline mb-4">
<input type="password" id="form3Example4cdg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example4cdg">Повторите свой пароль</label>
</div>
<div class="form-check d-flex justify-content-center mb-5">
<input class="form-check-input me-2" type="checkbox" value="" id="form2Example3cg" />
<label class="form-check-label" for="form2Example3g">
Я согласен со всеми утверждениями в <a href="#!" class="text-body"><u>Условиях обслуживания</u></a>
</label>
</div>
<div class="d-flex justify-content-center">
<button type="button"
class="btn btn-success btn-block btn-warning text-body mb-0">Регистрация</button>
</div>
<p class="text-center text-muted mb-0">У вас уже есть учетная запись? <a href="personalAccountLogin.html"
class="fw-bold text-body"><u>Войдите здесь</u></a></p>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

View File

@ -1,81 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Личный кабинет - Восстановление пароля</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountRegister.html">Войти</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<section class="h-100">
<div class="mask d-flex align-items-center h-100 gradient-custom-3">
<div class="container h-100">
<div class="row d-flex justify-content-center align-items-center h-100">
<div class="col-12 col-md-9 col-lg-7 col-xl-6">
<div class="card" style="border-radius: 15px; border-color:gold;">
<div class="card-body p-5">
<h2 class="text-uppercase text-center mb-5">Восстановление пароля</h2>
<h4 class="text-black text-center mb-5">Введите свой адрес электронной почты, и мы вышлем вам электронное письмо с инструкциями по сбросу вашего пароля</h4>
<form>
<div class="form-outline mb-4">
<input type="email" id="form3Example3cg" class="form-control form-control-lg" />
<label class="form-label" for="form3Example3cg">Ваш адрес электронной почты</label>
</div>
<div class="d-flex justify-content-center">
<button type="button"
class="btn btn-success btn-block btn-warning text-body mb-0">Сбросить пароль</button>
</div>
<p class="text-center text-muted mb-0"><a href="personalAccountLogin.html"
class="fw-bold text-body"><u>Войти</u></a></p>
<p class="text-center text-muted mb-0"><a href="personalAccountRegister.html"
class="fw-bold text-body"><u>Регистрация</u></a></p>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

View File

@ -1,247 +0,0 @@
<html lang="ru" class="h-100">
<head>
<meta charset="UTF-8">
<title>Акции</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<script type="module" src="./node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<link href="./node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet"/>
<link href="./node_modules/@fortawesome/fontawesome-free/css/all.min.css" rel="stylesheet"/>
<link rel="stylesheet" href="./style.css">
</head>
<body class="d-flex flex-column h-100">
<header>
<nav class="navbar navbar-expand-md">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img src="Images/logo.png" alt="logo" width="128">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav"
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="navbar-collapse collapse justify-content-start" id="navbarNav">
<div class="navbar-nav">
<a class="nav-link" href="index.html">Каталог</a>
<a class="nav-link active" href="stock.html">Акции</a>
<a class="nav-link" href="contacts.html">Контакты</a>
</div>
</div>
<div class="navbar-collapse collapse justify-content-end" id="navbarNav">
<div class="navbar-nav">
<a class="btn custom-btn" href="personalAccountLogin.html">Войти</a>
<a class="btn btn-warning" href="basket.html">Корзина</a>
</div>
</div>
</div>
</nav>
</header>
<main class="container-fluid p-2">
<div class="d-flex justify-content-center align-items-center">
<h1 class="text-warning font-weight-bold">Акции</h1>
</div>
<div class="container">
<div class="row">
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
<div class="col-lg-4 col-md-6 col-sm-12 mb-4">
<div class="card">
<img src="Images/stock.png" class="card-img-top" alt="Product Image">
<div class="card-body">
<h5 class="card-title">Дарим кибер-призы</h5>
<p class="card-text">Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и больших пицц 29 июня.
</p>
</div>
<div class="card-footer">
<button class="btn btn-warning">Посмотреть</button>
</div>
</div>
</div>
</div>
</div>ч
</main>
<footer class="footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
</body>
</html>

View File

@ -1,74 +0,0 @@
header nav {
background-color: #D9D9D9;
}
@media (min-width: 768px) {
header nav {
height: 100px;
}
}
header nav a:hover {
text-decoration: underline;
}
.navbar-brand img {
margin-left: 235px;
}
@media (max-width: 576px) {
.navbar-brand img {
margin-left: 25px;
}
}
@media (min-width: 577px) and (max-width: 992px) {
.navbar-brand img {
margin-left: 25px
}
}
@media (min-width: 993px) and (max-width: 1200px) {
.navbar-brand img {
margin-left: 150px;
}
}
@media (min-width: 1201px) {
.navbar-brand img {
margin-left: 235px;
}
}
.btn-warning {
height: 35px;
width: 176px;
border-radius: 8px;
margin-right: 10px;
margin-top: 10px;
}
.custom-btn {
height: 35px;
width: 176px;
border-radius: 8px;
margin-right: 10px;
margin-top: 10px;
background-color: #FFA800;
}
.btn.custom-btn:hover {
background-color: #FFA800 !important;
}
footer {
background-color: #D9D9D9;
}
#image-preview {
max-width: 100%;
max-height: 200px;
width: auto;
height: auto;
}

View File

@ -1,24 +0,0 @@
import { resolve } from "path";
// eslint-disable-next-line import/no-extraneous-dependencies
import { defineConfig } from "vite";
export default defineConfig({
build: {
sourcemap: true,
emptyOutDir: true,
rollupOptions: {
input: {
main: resolve(__dirname, "index.html"),
stock: resolve(__dirname, "stock.html"),
contacts: resolve(__dirname, "contacts.html"),
personalAccountLogin: resolve(__dirname, "personalAccountLogin.html"),
personalAccountRegister: resolve(__dirname, "personalAccountRegister.html"),
personalAccount: resolve(__dirname, "personalAccount.html"),
recoveryPassword: resolve(__dirname, "recoveryPassword.html"),
basket: resolve(__dirname, "basket.html"),
makingAnOrder: resolve(__dirname, "makingAnOrder.html"),
administrator: resolve(__dirname, "administrator.html"),
},
},
},
});

View File

@ -1,20 +0,0 @@
module.exports = {
root: true,
env: { browser: true, es2020: true },
extends: [
'eslint:recommended',
'plugin:react/recommended',
'plugin:react/jsx-runtime',
'plugin:react-hooks/recommended',
],
ignorePatterns: ['dist', '.eslintrc.cjs'],
parserOptions: { ecmaVersion: 'latest', sourceType: 'module' },
settings: { react: { version: '18.2' } },
plugins: ['react-refresh'],
rules: {
'react-refresh/only-export-components': [
'warn',
{ allowConstantExport: true },
],
},
}

View File

@ -1,24 +0,0 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*
node_modules
dist
dist-ssr
*.local
# Editor directories and files
.vscode/*
!.vscode/extensions.json
.idea
.DS_Store
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?

View File

@ -1,8 +0,0 @@
# React + Vite
This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.
Currently, two official plugins are available:
- [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react/README.md) uses [Babel](https://babeljs.io/) for Fast Refresh
- [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react-swc) uses [SWC](https://swc.rs/) for Fast Refresh

View File

@ -1,19 +0,0 @@
{
"posts": [
{
"id": 1,
"title": "json-server",
"author": "typicode"
}
],
"comments": [
{
"id": 1,
"body": "some comment",
"postId": 1
}
],
"profile": {
"name": "typicode"
}
}

View File

@ -1,13 +0,0 @@
<!doctype html>
<html lang="ru">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/logo.png" href="src/Images/logo.png" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Каталог</title>
</head>
<body>
<div id="root" class="h-100 d-flex flex-column"></div>
<script type="module" src="/src/main.jsx"></script>
</body>
</html>

View File

@ -1,14 +0,0 @@
{
"compilerOptions": {
"module": "ESNext",
"moduleResolution": "Node",
"target": "ES2020",
"jsx": "react",
"strictNullChecks": true,
"strictFunctionTypes": true
},
"exclude": [
"node_modules",
"**/node_modules/*"
]
}

File diff suppressed because it is too large Load Diff

View File

@ -1,38 +0,0 @@
{
"name": "lec4",
"private": true,
"version": "0.0.0",
"type": "module",
"scripts": {
"lint": "eslint . --ext js,jsx --report-unused-disable-directives --max-warnings 0",
"rest": "json-server data.json",
"vite": "vite",
"dev": "npm-run-all --parallel rest vite",
"prod": "npm-run-all lint 'vite build' --parallel rest 'vite preview'"
},
"dependencies": {
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-router-dom": "^6.18.0",
"react-hot-toast": "^2.4.1",
"axios": "^1.6.1",
"bootstrap": "^5.3.2",
"react-bootstrap": "^2.9.1",
"react-bootstrap-icons": "^1.10.3",
"prop-types": "^15.8.1"
},
"devDependencies": {
"@types/react": "^18.2.15",
"@types/react-dom": "^18.2.15",
"@vitejs/plugin-react": "^4.0.3",
"eslint": "^8.45.0",
"eslint-config-airbnb-base": "^15.0.0",
"eslint-plugin-import": "^2.29.0",
"eslint-plugin-react": "^7.32.2",
"eslint-plugin-react-hooks": "^4.6.0",
"eslint-plugin-react-refresh": "^0.4.3",
"json-server": "^0.17.4",
"npm-run-all": "^4.1.5",
"vite": "^4.4.5"
}
}

View File

@ -1 +0,0 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" class="iconify iconify--logos" width="31.88" height="32" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 257"><defs><linearGradient id="IconifyId1813088fe1fbc01fb466" x1="-.828%" x2="57.636%" y1="7.652%" y2="78.411%"><stop offset="0%" stop-color="#41D1FF"></stop><stop offset="100%" stop-color="#BD34FE"></stop></linearGradient><linearGradient id="IconifyId1813088fe1fbc01fb467" x1="43.376%" x2="50.316%" y1="2.242%" y2="89.03%"><stop offset="0%" stop-color="#FFEA83"></stop><stop offset="8.333%" stop-color="#FFDD35"></stop><stop offset="100%" stop-color="#FFA800"></stop></linearGradient></defs><path fill="url(#IconifyId1813088fe1fbc01fb466)" d="M255.153 37.938L134.897 252.976c-2.483 4.44-8.862 4.466-11.382.048L.875 37.958c-2.746-4.814 1.371-10.646 6.827-9.67l120.385 21.517a6.537 6.537 0 0 0 2.322-.004l117.867-21.483c5.438-.991 9.574 4.796 6.877 9.62Z"></path><path fill="url(#IconifyId1813088fe1fbc01fb467)" d="M185.432.063L96.44 17.501a3.268 3.268 0 0 0-2.634 3.014l-5.474 92.456a3.268 3.268 0 0 0 3.997 3.378l24.777-5.718c2.318-.535 4.413 1.507 3.936 3.838l-7.361 36.047c-.495 2.426 1.782 4.5 4.151 3.78l15.304-4.649c2.372-.72 4.652 1.36 4.15 3.788l-11.698 56.621c-.732 3.542 3.979 5.473 5.943 2.437l1.313-2.028l72.516-144.72c1.215-2.423-.88-5.186-3.54-4.672l-25.505 4.922c-2.396.462-4.435-1.77-3.759-4.114l16.646-57.705c.677-2.35-1.37-4.583-3.769-4.113Z"></path></svg>

Before

Width:  |  Height:  |  Size: 1.5 KiB

View File

@ -1,24 +0,0 @@
import PropTypes from 'prop-types';
import { Container } from 'react-bootstrap';
import { Outlet } from 'react-router-dom';
import './App.css';
import Footer from './components/footer/Footer.jsx';
import Navigation from './components/navigation/Navigation.jsx';
const App = ({ routes }) => {
return (
<div className="d-flex flex-column min-vh-100">
<Navigation routes={routes}></Navigation>
<Container className="flex-grow-1 p-2" as="main" fluid>
<Outlet />
</Container>
<Footer />
</div>
);
};
App.propTypes = {
routes: PropTypes.array,
};
export default App;

Binary file not shown.

Before

Width:  |  Height:  |  Size: 32 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 669 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 38 KiB

View File

@ -1 +0,0 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" class="iconify iconify--logos" width="35.93" height="32" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 228"><path fill="#00D8FF" d="M210.483 73.824a171.49 171.49 0 0 0-8.24-2.597c.465-1.9.893-3.777 1.273-5.621c6.238-30.281 2.16-54.676-11.769-62.708c-13.355-7.7-35.196.329-57.254 19.526a171.23 171.23 0 0 0-6.375 5.848a155.866 155.866 0 0 0-4.241-3.917C100.759 3.829 77.587-4.822 63.673 3.233C50.33 10.957 46.379 33.89 51.995 62.588a170.974 170.974 0 0 0 1.892 8.48c-3.28.932-6.445 1.924-9.474 2.98C17.309 83.498 0 98.307 0 113.668c0 15.865 18.582 31.778 46.812 41.427a145.52 145.52 0 0 0 6.921 2.165a167.467 167.467 0 0 0-2.01 9.138c-5.354 28.2-1.173 50.591 12.134 58.266c13.744 7.926 36.812-.22 59.273-19.855a145.567 145.567 0 0 0 5.342-4.923a168.064 168.064 0 0 0 6.92 6.314c21.758 18.722 43.246 26.282 56.54 18.586c13.731-7.949 18.194-32.003 12.4-61.268a145.016 145.016 0 0 0-1.535-6.842c1.62-.48 3.21-.974 4.76-1.488c29.348-9.723 48.443-25.443 48.443-41.52c0-15.417-17.868-30.326-45.517-39.844Zm-6.365 70.984c-1.4.463-2.836.91-4.3 1.345c-3.24-10.257-7.612-21.163-12.963-32.432c5.106-11 9.31-21.767 12.459-31.957c2.619.758 5.16 1.557 7.61 2.4c23.69 8.156 38.14 20.213 38.14 29.504c0 9.896-15.606 22.743-40.946 31.14Zm-10.514 20.834c2.562 12.94 2.927 24.64 1.23 33.787c-1.524 8.219-4.59 13.698-8.382 15.893c-8.067 4.67-25.32-1.4-43.927-17.412a156.726 156.726 0 0 1-6.437-5.87c7.214-7.889 14.423-17.06 21.459-27.246c12.376-1.098 24.068-2.894 34.671-5.345a134.17 134.17 0 0 1 1.386 6.193ZM87.276 214.515c-7.882 2.783-14.16 2.863-17.955.675c-8.075-4.657-11.432-22.636-6.853-46.752a156.923 156.923 0 0 1 1.869-8.499c10.486 2.32 22.093 3.988 34.498 4.994c7.084 9.967 14.501 19.128 21.976 27.15a134.668 134.668 0 0 1-4.877 4.492c-9.933 8.682-19.886 14.842-28.658 17.94ZM50.35 144.747c-12.483-4.267-22.792-9.812-29.858-15.863c-6.35-5.437-9.555-10.836-9.555-15.216c0-9.322 13.897-21.212 37.076-29.293c2.813-.98 5.757-1.905 8.812-2.773c3.204 10.42 7.406 21.315 12.477 32.332c-5.137 11.18-9.399 22.249-12.634 32.792a134.718 134.718 0 0 1-6.318-1.979Zm12.378-84.26c-4.811-24.587-1.616-43.134 6.425-47.789c8.564-4.958 27.502 2.111 47.463 19.835a144.318 144.318 0 0 1 3.841 3.545c-7.438 7.987-14.787 17.08-21.808 26.988c-12.04 1.116-23.565 2.908-34.161 5.309a160.342 160.342 0 0 1-1.76-7.887Zm110.427 27.268a347.8 347.8 0 0 0-7.785-12.803c8.168 1.033 15.994 2.404 23.343 4.08c-2.206 7.072-4.956 14.465-8.193 22.045a381.151 381.151 0 0 0-7.365-13.322Zm-45.032-43.861c5.044 5.465 10.096 11.566 15.065 18.186a322.04 322.04 0 0 0-30.257-.006c4.974-6.559 10.069-12.652 15.192-18.18ZM82.802 87.83a323.167 323.167 0 0 0-7.227 13.238c-3.184-7.553-5.909-14.98-8.134-22.152c7.304-1.634 15.093-2.97 23.209-3.984a321.524 321.524 0 0 0-7.848 12.897Zm8.081 65.352c-8.385-.936-16.291-2.203-23.593-3.793c2.26-7.3 5.045-14.885 8.298-22.6a321.187 321.187 0 0 0 7.257 13.246c2.594 4.48 5.28 8.868 8.038 13.147Zm37.542 31.03c-5.184-5.592-10.354-11.779-15.403-18.433c4.902.192 9.899.29 14.978.29c5.218 0 10.376-.117 15.453-.343c-4.985 6.774-10.018 12.97-15.028 18.486Zm52.198-57.817c3.422 7.8 6.306 15.345 8.596 22.52c-7.422 1.694-15.436 3.058-23.88 4.071a382.417 382.417 0 0 0 7.859-13.026a347.403 347.403 0 0 0 7.425-13.565Zm-16.898 8.101a358.557 358.557 0 0 1-12.281 19.815a329.4 329.4 0 0 1-23.444.823c-7.967 0-15.716-.248-23.178-.732a310.202 310.202 0 0 1-12.513-19.846h.001a307.41 307.41 0 0 1-10.923-20.627a310.278 310.278 0 0 1 10.89-20.637l-.001.001a307.318 307.318 0 0 1 12.413-19.761c7.613-.576 15.42-.876 23.31-.876H128c7.926 0 15.743.303 23.354.883a329.357 329.357 0 0 1 12.335 19.695a358.489 358.489 0 0 1 11.036 20.54a329.472 329.472 0 0 1-11 20.722Zm22.56-122.124c8.572 4.944 11.906 24.881 6.52 51.026c-.344 1.668-.73 3.367-1.15 5.09c-10.622-2.452-22.155-4.275-34.23-5.408c-7.034-10.017-14.323-19.124-21.64-27.008a160.789 160.789 0 0 1 5.888-5.4c18.9-16.447 36.564-22.941 44.612-18.3ZM128 90.808c12.625 0 22.86 10.235 22.86 22.86s-10.235 22.86-22.86 22.86s-22.86-10.235-22.86-22.86s10.235-22.86 22.86-22.86Z"></path></svg>

Before

Width:  |  Height:  |  Size: 4.0 KiB

View File

@ -1,41 +0,0 @@
import { useState } from 'react';
import { Card, Col, Row, Form } from 'react-bootstrap';
const BasketCard = () => {
const [quantity, setQuantity] = useState(2);
const handleQuantityChange = (event) => {
setQuantity(event.target.value);
};
return (
<Card className="rounded-3 mb-4">
<Card.Body className="p-4">
<Row className="d-flex justify-content-between align-items-center">
<Col md={2} lg={2} xl={2}>
<img src="./src/Images/pizza.png" className="img-fluid rounded-3" alt="Cotton T-shirt" />
</Col>
<Col md={3} lg={3} xl={3}>
<p className="lead fw-normal mb-2">Название пиццы</p>
</Col>
<Col md={3} lg={3} xl={2} className="d-flex align-items-center">
<Form.Control
id="form1"
min="0"
name="quantity"
value={quantity}
type="number"
className="form-control form-control-sm text-center"
onChange={handleQuantityChange}
/>
</Col>
<Col md={3} lg={2} xl={2} offset-lg={1}>
<h5 className="mb-0">Цена </h5>
</Col>
</Row>
</Card.Body>
</Card>
);
};
export default BasketCard;

View File

@ -1,20 +0,0 @@
import { Col, Card, Button } from 'react-bootstrap';
const ProductCard = () => {
return (
<Col lg={3} md={4} sm={6} xs={12} className="mb-4">
<Card>
<Card.Img src="./src/Images/pizza.png" alt="Product Image" className="card-img-top" />
<Card.Body>
<Card.Title>Название</Card.Title>
</Card.Body>
<Card.Footer>
<div className="text-warning font-weight-bold">Цена </div>
<Button variant="warning">В корзину</Button>
</Card.Footer>
</Card>
</Col>
);
};
export default ProductCard;

View File

@ -1,21 +0,0 @@
import { Col, Card } from 'react-bootstrap';
const StockCard = () => {
return (
<Col lg={4} md={6} sm={12} className="mb-4">
<Card>
<Card.Img src="./src/Images/stock.png" alt="Stock Image" className="card-img-top" />
<Card.Body>
<Card.Title>Дарим кибер-призы</Card.Title>
<Card.Text>
Вот так ачивка! Закажите Кибер-комбо и получите доступ к играм от MY.GAMES, а еще кокосовый батончик и
шоколадное печенье «Cyber» от Bite. А также станьте автоматическим участником розыгрыша игровых ключей и
больших пицц 29 июня.
</Card.Text>
</Card.Body>
</Card>
</Col>
);
};
export default StockCard;

View File

@ -1,4 +0,0 @@
.my-footer {
background-color: #D9D9D9;
height: 32px;
}

View File

@ -1,11 +0,0 @@
import './Footer.css';
const Footer = () => {
return (
<footer className="my-footer mt-auto d-flex flex-shrink-0 justify-content-center align-items-center">
Все права защищены © 2023-2024
</footer>
);
};
export default Footer;

View File

@ -1,31 +0,0 @@
.my-navbar {
background-color: #D9D9D9;
}
.my-navbar .nav-link {
text-decoration: none;
}
@media (max-width: 576px) {
.my-navbar img {
margin-left: 25px;
}
}
@media (min-width: 577px) and (max-width: 992px) {
.my-navbar img {
margin-left: 25px
}
}
@media (min-width: 993px) and (max-width: 1200px) {
.my-navbar img {
margin-left: 150px;
}
}
@media (min-width: 1201px) {
.my-navbar img {
margin-left: 235px;
}
}

View File

@ -1,45 +0,0 @@
import PropTypes from 'prop-types';
import { Container, Nav, Navbar, Button } from 'react-bootstrap';
import { Link, useLocation } from 'react-router-dom';
import Image from 'react-bootstrap/Image';
import './Navigation.css';
const Navigation = ({ routes }) => {
const location = useLocation();
const indexPageLink = routes.find((route) => route.index === true);
const pages = routes.filter((route) => Object.prototype.hasOwnProperty.call(route, 'title'));
return (
<Navbar expand='md' className='my-navbar'>
<Container fluid>
<Navbar.Brand as={Link} to={indexPageLink?.path ?? '/'}>
<Image src="./src/Images/logo.png" width="128" alt="Logo" />
</Navbar.Brand>
<Navbar.Toggle aria-controls='main-navbar' />
<Navbar.Collapse id='main-navbar'>
<Nav className='me-auto link' activeKey={location.pathname}>
{pages.map((page) => (
<Nav.Link as={Link} key={page.path} eventKey={page.path} to={page.path ?? '/'}>
{page.title}
</Nav.Link>
))}
</Nav>
<Nav>
<Button className="custom-btn" as={Link} to="/personalAccountLogin">
Войти
</Button>
<Button variant="warning" as={Link} to="/Basket">
Корзина
</Button>
</Nav>
</Navbar.Collapse>
</Container>
</Navbar>
);
};
Navigation.propTypes = {
routes: PropTypes.array,
};
export default Navigation;

View File

@ -1,18 +0,0 @@
.btn {
height: 35px;
width: 176px;
border-radius: 8px;
margin-right: 10px;
margin-top: 10px;
}
.custom-btn {
color: black;
border: none;
background-color: #FFA800;
}
.btn.custom-btn:hover {
color: black;
background-color: #FFA800 !important;
}

View File

@ -1,84 +0,0 @@
import 'bootstrap/dist/css/bootstrap.min.css';
import React from 'react';
import ReactDOM from 'react-dom/client';
import { RouterProvider, createBrowserRouter } from 'react-router-dom';
import App from './App.jsx';
import './index.css';
import ErrorPage from './pages/ErrorPage.jsx';
import Index from './pages/Index.jsx';
import Stock from './pages/Stock.jsx';
import Contacts from './pages/Contacts.jsx';
import PersonalAccountLogin from './pages/PersonalAccountLogin.jsx';
import PersonalAccount from './pages/PersonalAccount.jsx';
import PersonalAccountRegister from './pages/PersonalAccountRegister.jsx';
import PasswordRecovery from './pages/PasswordRecovery.jsx';
import Administrator from './pages/Administrator.jsx';
import Basket from './pages/Basket.jsx';
import MakingAnOrder from './pages/MakingAnOrder.jsx';
import PageEdit from './pages/PageEdit.jsx';
const routes = [
{
index: true,
path: '/',
element: <Index />,
title: 'Каталог',
},
{
path: '/stock',
element: <Stock />,
title: 'Акции',
},
{
path: '/contacts',
element: <Contacts />,
title: 'Контакты',
},
{
path: '/personalAccountLogin',
element: <PersonalAccountLogin />,
},
{
path: '/personalAccount',
element: <PersonalAccount />,
},
{
path: '/personalAccountRegister',
element: <PersonalAccountRegister/>,
},
{
path: '/PasswordRecovery',
element: <PasswordRecovery/>,
},
{
path: '/Administrator',
element: <Administrator/>,
},
{
path: '/Basket',
element: <Basket/>,
},
{
path: '/MakingAnOrder',
element: <MakingAnOrder/>,
},
{
path: '/PageEdit',
element: <PageEdit/>,
}
];
const router = createBrowserRouter([
{
path: '/',
element: <App routes={routes} />,
children: routes,
errorElement: <ErrorPage />,
},
]);
ReactDOM.createRoot(document.getElementById('root')).render(
<React.StrictMode>
<RouterProvider router={router} />
</React.StrictMode>,
);

View File

@ -1,50 +0,0 @@
import { Container, Row, Col, Button, Table } from 'react-bootstrap';
const Administrator = () => {
return (
<Container>
<Row>
<Col>
<h1 className="text-warning text-center font-weight-bold">Панель администратора</h1>
<div className="btn-group" role="group">
<Button variant="warning" href="/PageEdit">
Добавить товар
</Button>
</div>
</Col>
</Row>
<Row>
<Col>
<h2 className="text-warning text-center font-weight-bold" style={{ paddingTop: '10px' }}>
Таблица данных
</h2>
<Table id="items-table" striped bordered>
<thead>
<tr>
<th scope="col"></th>
<th scope="col" className="w-25">
Товар
</th>
<th scope="col" className="w-25">
Цена
</th>
<th scope="col" className="w-10">
Акция
</th>
<th scope="col" className="w-25">
Количество
</th>
<th scope="col" className="w-25">
Сумма
</th>
</tr>
</thead>
<tbody></tbody>
</Table>
</Col>
</Row>
</Container>
);
};
export default Administrator;

View File

@ -1,35 +0,0 @@
import { Container, Row, Col } from 'react-bootstrap';
import BasketCard from '../components/card/BasketCard';
import { Link } from 'react-router-dom';
const Basket = () => {
return (
<Container>
<Row>
<Col className="d-flex justify-content-center align-items-center">
<h1 className="text-warning font-weight-bold">Корзина</h1>
</Col>
</Row>
<Row>
<Col xs={10}>
<BasketCard />
<BasketCard />
<BasketCard />
</Col>
</Row>
<div className="d-flex justify-content-start align-items-center">
<div className="text-dark font-weight-bold" style={{ fontSize: '24px' }}>
Сумма заказа:
</div>
<div className="text-end" style={{ color: '#F7D22D', fontSize: '24px' }}>
Сумма
</div>
</div>
<Link to='/MakingAnOrder' className="btn btn-warning" style={{ marginLeft: '25px', marginBottom: '10px' }}>
К оплате
</Link>
</Container>
);
};
export default Basket;

View File

@ -1,36 +0,0 @@
import { Container, Row, Col } from 'react-bootstrap';
const Contacts = () => {
return (
<Container>
<Row>
<Col className="d-flex justify-content-center align-items-center">
<h1 className="text-warning font-weight-bold">Контакты</h1>
</Col>
</Row>
<Row>
<Col className="d-flex justify-content-center">
<iframe
src="https://yandex.ru/map-widget/v1/?um=constructor%3A0643c92cbdf3809080e5dfb2804b473ea00af31cfabe6fee08676c59d8675f01&amp;source=constructor"
className="img-fluid"
style={{ width: '100%', height: '500px' }}
title="Yandex Map"
></iframe>
</Col>
</Row>
<Row>
<Col>
<a href="tel:71112223344" className="text-warning font-weight-bold" style={{ fontSize: '35px', marginLeft: '10px', marginTop: '10px' }}>
7 111 222 33 44
</a>
<h2 className="font-weight-bold" style={{ fontSize: '35px', marginLeft: '10px', marginTop: '10px' }}>
ул. Северный венец 32
</h2>
<p style={{ fontSize: '25px', marginLeft: '10px', marginTop: '10px' }}>Доставка и самовывоз 10:00 23:00</p>
</Col>
</Row>
</Container>
);
};
export default Contacts;

View File

@ -1,19 +0,0 @@
import { Alert, Button, Container } from 'react-bootstrap';
import { useNavigate } from 'react-router-dom';
const ErrorPage = () => {
const navigate = useNavigate();
return (
<Container fluid className="p-2 row justify-content-center">
<Container className='col-md-6'>
<Alert variant="danger">
Страница не найдена
</Alert>
<Button className="w-25 mt-2" variant="primary" onClick={() => navigate(-1)}>Назад</Button>
</Container>
</Container>
);
};
export default ErrorPage;

View File

@ -1,42 +0,0 @@
import { Container, Row, Col } from 'react-bootstrap';
import ProductCard from '../components/card/ProductCard';
const Index = () => {
return (
<Container>
<Row>
<Col className="d-flex justify-content-center align-items-center">
<h1 className="text-warning font-weight-bold">Каталог</h1>
</Col>
</Row>
<Row>
<ProductCard />
<ProductCard />
<ProductCard />
<ProductCard />
<ProductCard />
<ProductCard />
<ProductCard />
<ProductCard />
<ProductCard />
<ProductCard />
<ProductCard />
<ProductCard />
<ProductCard />
<ProductCard />
<ProductCard />
<ProductCard />
<ProductCard />
<ProductCard />
<ProductCard />
<ProductCard />
</Row>
</Container>
);
};
export default Index;

View File

@ -1,194 +0,0 @@
import { useState } from 'react';
import { Container, Row, Col, Card, Form, Button } from 'react-bootstrap';
const MakingAnOrder = () => {
const [deliveryMethod, setDeliveryMethod] = useState('selfPickup');
const [paymentMethod, setPaymentMethod] = useState('cash');
const handleDeliveryMethodChange = (e) => {
setDeliveryMethod(e.target.value);
};
const handlePaymentMethodChange = (e) => {
setPaymentMethod(e.target.value);
};
const [validated, setValidated] = useState(false);
const handleSubmit = (event) => {
const form = event.currentTarget;
if (form.checkValidity() === false) {
event.preventDefault();
event.stopPropagation();
}
setValidated(true);
};
return (
<Container className="h-100">
<Row className="d-flex justify-content-center align-items-center h-100">
<Col xs={12} md={9} lg={7} xl={6}>
<Card style={{ borderRadius: '15px', borderColor: 'gold' }}>
<Card.Body className="p-5">
<h2 className="text-uppercase text-center mb-5">Оформление заказа</h2>
<Form noValidate validated={validated} onSubmit={handleSubmit}>
<Form.Group className="mb-4" controlId="name">
<Form.Label>Ваше имя</Form.Label>
<Form.Control type="text" required />
<Form.Control.Feedback>Имя заполнено</Form.Control.Feedback>
<Form.Control.Feedback type="invalid">Имя не заполнено</Form.Control.Feedback>
</Form.Group>
<Form.Group className="mb-2">
<Form.Label htmlFor="form3Example5cg">Номер телефона</Form.Label>
<Form.Control type="tel" id="form3Example5cg" required />
<Form.Control.Feedback>Номер телефона заполнен</Form.Control.Feedback>
<Form.Control.Feedback type="invalid">Номер телефона не заполнен</Form.Control.Feedback>
</Form.Group>
<Form.Group className="mb-4">
<Form.Label>Вариант получения</Form.Label>
<Form.Check
type="radio"
label="Самовывоз"
id="selfPickup"
name="deliveryMethod"
value="selfPickup"
checked={deliveryMethod === 'selfPickup'}
onChange={handleDeliveryMethodChange}
/>
<Form.Check
type="radio"
label="Доставка"
id="delivery"
name="deliveryMethod"
value="delivery"
checked={deliveryMethod === 'delivery'}
onChange={handleDeliveryMethodChange}
/>
</Form.Group>
{deliveryMethod === 'delivery' && (
<div>
<Form.Group className="mb-4" controlId="adress">
<Form.Label>Ваш адрес доставки</Form.Label>
<Form.Control type="text" required/>
<Form.Control.Feedback>Адрес заполнен</Form.Control.Feedback>
<Form.Control.Feedback type="invalid">Адрес не заполнен</Form.Control.Feedback>
</Form.Group>
<Form.Group className="mb-4">
<Form.Label>Выберите время доставки:</Form.Label>
<Form.Select>
<option value="10:00-10:30">10:00-10:30</option>
<option value="10:30-11:00">10:30-11:00</option>
<option value="11:00-11:30">11:00-11:30</option>
<option value="11:30-12:00">11:30-12:00</option>
<option value="12:00-12:30">12:00-12:30</option>
<option value="12:30-13:00">12:30-13:00</option>
<option value="13:00-13:30">13:00-13:30</option>
<option value="13:30-14:00">13:30-14:00</option>
<option value="14:00-14:30">14:00-14:30</option>
<option value="14:30-15:00">14:30-15:00</option>
<option value="15:00-15:30">15:00-15:30</option>
<option value="15:30-16:00">15:30-16:00</option>
<option value="16:00-16:30">16:00-16:30</option>
<option value="16:30-17:00">16:30-17:00</option>
<option value="17:00-17:30">17:00-17:30</option>
<option value="17:30-18:00">17:30-18:00</option>
<option value="18:00-18:30">18:00-18:30</option>
<option value="18:30-19:00">18:30-19:00</option>
<option value="19:00-19:30">19:00-19:30</option>
<option value="19:30-20:00">19:30-20:00</option>
<option value="20:00-20:30">20:00-20:30</option>
<option value="20:30-21:00">20:30-21:00</option>
<option value="21:00-21:30">21:00-21:30</option>
<option value="21:30-22:00">21:30-22:00</option>
<option value="22:00-22:30">22:00-22:30</option>
<option value="22:30-23:00">22:30-23:00</option>
</Form.Select>
</Form.Group>
</div>
)}
<Form.Group className="mb-4">
<Form.Label>Вариант оплаты</Form.Label>
<Form.Check
type="radio"
label="Наличные"
id="cash"
name="paymentMethod"
value="cash"
checked={paymentMethod === 'cash'}
onChange={handlePaymentMethodChange}
/>
<Form.Check
type="radio"
label="Оплата картой"
id="creditCard"
name="paymentMethod"
value="creditCard"
checked={paymentMethod === 'creditCard'}
onChange={handlePaymentMethodChange}
/>
</Form.Group>
{paymentMethod === 'creditCard' && (
<div>
<Row className="mb-4">
<Col>
<Form.Group className="mb-2" controlId="formNameOnCard">
<Form.Label>Имя держателя карты</Form.Label>
<Form.Control type="text" required />
<Form.Control.Feedback>Имя заполнено</Form.Control.Feedback>
<Form.Control.Feedback type="invalid">Имя не заполнено</Form.Control.Feedback>
</Form.Group>
</Col>
<Col>
<Form.Group className="mb-2" controlId="formCardNumber">
<Form.Label>Номер карты</Form.Label>
<Form.Control type="text" pattern="[0-9]{16}" required />
<Form.Control.Feedback>Номер карты заполнен</Form.Control.Feedback>
<Form.Control.Feedback type="invalid">Введите правильный номер карты</Form.Control.Feedback>
</Form.Group>
</Col>
</Row>
<Row className="mb-4">
<Col>
<Form.Group className="mb-2" controlId="formExpiration">
<Form.Label>Срок действия</Form.Label>
<Form.Control type="text" pattern="\d{2}/\d{2}" required />
<Form.Control.Feedback>Срок действия заполнен</Form.Control.Feedback>
<Form.Control.Feedback type="invalid">Введите правильный срок действия</Form.Control.Feedback>
</Form.Group>
</Col>
<Col>
<Form.Group className="mb-2" controlId="formCVV">
<Form.Label>CVV</Form.Label>
<Form.Control type="text" pattern="\d{3}" required />
<Form.Control.Feedback>CVV заполнен</Form.Control.Feedback>
<Form.Control.Feedback type="invalid">Введите правильный CVV</Form.Control.Feedback>
</Form.Group>
</Col>
</Row>
</div>
)}
<div className="d-flex justify-content-center">
<Button variant="warning" type="submit" id="saveButton">
Оформить
</Button>
</div>
</Form>
</Card.Body>
</Card>
</Col>
</Row>
</Container>
);
};
export default MakingAnOrder;

View File

@ -1,170 +0,0 @@
import { useState } from 'react';
import { Container, Col, Row, Form, Button } from 'react-bootstrap';
const PageEdit = () => {
const [validated, setValidated] = useState(false);
const handleSubmit = (event) => {
const form = event.currentTarget;
if (form.checkValidity() === false) {
event.preventDefault();
event.stopPropagation();
}
setValidated(true);
};
const [selectedItem, setSelectedItem] = useState('');
const [price, setPrice] = useState(0.00);
const [stock, setStock] = useState(0);
const [count, setCount] = useState(0);
const [imagePreview, setImagePreview] = useState('https://via.placeholder.com/200');
const handleItemChange = (e) => {
setSelectedItem(e.target.value);
};
const handlePriceChange = (e) => {
setPrice(parseFloat(e.target.value));
};
const handleStockChange = (e) => {
setStock(parseInt(e.target.value, 10));
};
const handleCountChange = (e) => {
setCount(parseInt(e.target.value, 10));
};
const handleImageChange = (e) => {
const file = e.target.files[0];
if (file) {
const reader = new FileReader();
reader.onloadend = () => {
const img = new Image();
img.src = reader.result;
img.onload = () => {
const canvas = document.createElement('canvas');
const ctx = canvas.getContext('2d');
const maxWidth = 200;
const maxHeight = 200;
let width = img.width;
let height = img.height;
if (width > height) {
if (width > maxWidth) {
height *= maxWidth / width;
width = maxWidth;
}
} else {
if (height > maxHeight) {
width *= maxHeight / height;
height = maxHeight;
}
}
canvas.width = width;
canvas.height = height;
ctx.drawImage(img, 0, 0, width, height);
setImagePreview(canvas.toDataURL('image/png'));
};
};
reader.readAsDataURL(file);
}
};
return (
<Container fluid className="p-2">
<h1 className="text-warning text-center font-weight-bold">Добавление товара</h1>
<Row className="text-center">
<Col>
<img id="image-preview" src={imagePreview} className="rounded rounded-circle" alt="placeholder" />
</Col>
</Row>
<Form
id="items-form"
className="needs-validation"
noValidate
validated={validated}
onSubmit={handleSubmit}
>
<Form.Group controlId="item" className="mb-2">
<Form.Label>Товары</Form.Label>
<Form.Control
as="select"
name="selected"
onChange={handleItemChange}
value={selectedItem}
required
>
</Form.Control>
<Form.Control.Feedback type="invalid">Пожалуйста, выберите товар.</Form.Control.Feedback>
</Form.Group>
<Form.Group controlId="price" className="mb-2">
<Form.Label>Цена</Form.Label>
<Form.Control
type="number"
name="price"
value={price}
min="1000.00"
step="0.50"
onChange={handlePriceChange}
required
/>
<Form.Control.Feedback type="invalid">Пожалуйста, введите цену.</Form.Control.Feedback>
</Form.Group>
<Form.Group controlId="stock" className="mb-2">
<Form.Label>Акция</Form.Label>
<Form.Control
type="number"
name="price"
value={stock}
min="0"
step="1"
onChange={handleStockChange}
required
/>
<Form.Control.Feedback type="invalid">Пожалуйста, введите акцию.</Form.Control.Feedback>
</Form.Group>
<Form.Group controlId="count" className="mb-2">
<Form.Label>Количество</Form.Label>
<Form.Control
type="number"
name="count"
value={count}
min="1"
step="1"
onChange={handleCountChange}
required
/>
<Form.Control.Feedback type="invalid">Пожалуйста, введите количество.</Form.Control.Feedback>
</Form.Group>
<Form.Group controlId="image" className="mb-2">
<Form.Label>Изображение</Form.Label>
<Form.Control
type="file"
name="image"
accept="image/*"
onChange={handleImageChange}
/>
<Form.Control.Feedback type="invalid">Пожалуйста, выберите изображение.</Form.Control.Feedback>
</Form.Group>
<Row className="mb-2">
<Col>
<Button href="Administrator" className="btn btn-secondary">Назад</Button>
<Button type="submit" className="btn btn-primary">Сохранить</Button>
</Col>
</Row>
</Form>
</Container>
);
};
export default PageEdit;

View File

@ -1,58 +0,0 @@
import { Container, Row, Col, Card, Form, Button } from 'react-bootstrap';
import { useState } from 'react';
import { Link } from 'react-router-dom';
const PasswordRecovery = () => {
const [validated, setValidated] = useState(false);
const handleSubmit = (event) => {
const form = event.currentTarget;
if (form.checkValidity() === false) {
event.preventDefault();
event.stopPropagation();
}
setValidated(true);
};
return (
<Container className="h-100">
<Row className="d-flex justify-content-center align-items-center h-100">
<Col xs={12} md={9} lg={7} xl={6}>
<Card style={{ borderRadius: '15px', borderColor: 'gold' }}>
<Card.Body className="p-5">
<h2 className="text-uppercase text-center mb-5">Восстановление пароля</h2>
<h4 className="text-black text-center mb-5">
Введите свой адрес электронной почты, и мы вышлем вам электронное письмо с инструкциями по сбросу вашего пароля
</h4>
<Form noValidate validated={validated} onSubmit={handleSubmit}>
<Form.Group className="mb-4">
<Form.Label htmlFor="form3Example3cg">Ваш адрес электронной почты</Form.Label>
<Form.Control type="email" id="form3Example3cg" required />
<Form.Control.Feedback>Email заполнен</Form.Control.Feedback>
<Form.Control.Feedback type="invalid">Email не заполнен</Form.Control.Feedback>
</Form.Group>
<div className="d-flex justify-content-center">
<Button type="submit" className="btn-block btn-warning text-body mb-0">
Сбросить пароль
</Button>
</div>
<p className="text-center text-muted mb-0">
<Link className="fw-bold text-body" to='/PersonalAccountLogin' style={{ color: 'black', textDecoration: 'none' }}><u>Войти</u></Link>
</p>
<p className="text-center text-muted mb-0">
<Link className="fw-bold text-body" to='/PersonalAccountRegister' style={{ color: 'black', textDecoration: 'none' }}><u>Регистрация</u></Link>
</p>
</Form>
</Card.Body>
</Card>
</Col>
</Row>
</Container>
);
};
export default PasswordRecovery;

View File

@ -1,82 +0,0 @@
import { useState } from 'react';
import { Container, Row, Col, Card, Form, Button } from 'react-bootstrap';
import { Link } from 'react-router-dom';
const PersonalAccount = () => {
const [validated, setValidated] = useState(false);
const handleSubmit = (event) => {
const form = event.currentTarget;
if (form.checkValidity() === false) {
event.preventDefault();
event.stopPropagation();
}
setValidated(true);
};
return (
<Container className="h-100">
<Row className="justify-content-center align-items-center h-100">
<Col xs={12} md={9} lg={7} xl={6}>
<Card style={{ borderRadius: '15px', borderColor: 'gold' }}>
<Card.Body className="p-5">
<h2 className="text-uppercase text-center mb-5">Личный кабинет</h2>
<Form noValidate validated={validated} onSubmit={handleSubmit}>
<Form.Group className="mb-4" controlId="name">
<Form.Label>Ваше имя</Form.Label>
<Form.Control type="text" required />
<Form.Control.Feedback>Имя заполнено</Form.Control.Feedback>
<Form.Control.Feedback type="invalid">Имя не заполнено</Form.Control.Feedback>
</Form.Group>
<Form.Group className="mb-4" controlId="surname">
<Form.Label>Ваша фамилия</Form.Label>
<Form.Control type="text" required/>
<Form.Control.Feedback>Фамилия заполнена</Form.Control.Feedback>
<Form.Control.Feedback type="invalid">Фамилия не заполнена</Form.Control.Feedback>
</Form.Group>
<Form.Group className="mb-4">
<Form.Label htmlFor="form3Example3cg">Ваш адрес электронной почты</Form.Label>
<Form.Control type="email" id="form3Example3cg" required />
<Form.Control.Feedback>Email заполнен</Form.Control.Feedback>
<Form.Control.Feedback type="invalid">Email не заполнен</Form.Control.Feedback>
</Form.Group>
<Form.Group className="mb-4">
<Form.Label htmlFor="form3Example4cg">Дата рождения</Form.Label>
<Form.Control type="date" id="form3Example4cg" required />
<Form.Control.Feedback>Дата рождения заполнена</Form.Control.Feedback>
<Form.Control.Feedback type="invalid">Дата рождения не заполнена</Form.Control.Feedback>
</Form.Group>
<Form.Group className="mb-2">
<Form.Label htmlFor="form3Example5cg">Номер телефона</Form.Label>
<Form.Control type="tel" id="form3Example5cg" required />
<Form.Control.Feedback>Номер телефона заполнен</Form.Control.Feedback>
<Form.Control.Feedback type="invalid">Номер телефона не заполнен</Form.Control.Feedback>
</Form.Group>
<div className="d-flex justify-content-center">
<Button variant="warning" type="submit" id="saveButton">
Сохранить
</Button>
</div>
<div className="d-flex justify-content-center mt-2">
<Link to='/' className="btn btn-outline-danger" type="button">
Выйти
</Link>
</div>
</Form>
</Card.Body>
</Card>
</Col>
</Row>
</Container>
);
};
export default PersonalAccount;

View File

@ -1,79 +0,0 @@
import { Container, Row, Col, Card, Form, Button } from 'react-bootstrap';
import { useState } from 'react';
import { Link } from 'react-router-dom';
const PersonalAccountLogin = () => {
const [validated, setValidated] = useState(false);
const handleSubmit = (event) => {
const form = event.currentTarget;
if (form.checkValidity() === false) {
event.preventDefault();
event.stopPropagation();
}
setValidated(true);
};
return (
<Container>
<Row className="d-flex justify-content-center align-items-center h-100">
<Col xs={12} md={9} lg={7} xl={6}>
<Card style={{ borderRadius: '15px', borderColor: 'gold' }}>
<Card.Body className="p-5">
<h2 className="text-uppercase text-center mb-5">Войти</h2>
<Form noValidate validated={validated} onSubmit={handleSubmit}>
<Form.Group className="mb-4">
<Form.Control type="email" id="form3Example3cg" required />
<Form.Control.Feedback>Email заполнен</Form.Control.Feedback>
<Form.Control.Feedback type="invalid">Email не заполнен</Form.Control.Feedback>
<Form.Label htmlFor="form3Example3cg">Ваш адрес электронной почты</Form.Label>
</Form.Group>
<Form.Group className="mb-4">
<Form.Control type="password" id="form3Example4cg" size="lg" required />
<Form.Control.Feedback>Пароль заполнен</Form.Control.Feedback>
<Form.Control.Feedback type="invalid">Пароль не заполнен</Form.Control.Feedback>
<Form.Label htmlFor="form3Example4cg">Пароль</Form.Label>
</Form.Group>
<Form.Group className="mb-2" controlId="form2Example3cg">
<Form.Check type="checkbox" label="Запомнить меня" />
</Form.Group>
<p className="text-center text-muted mb-0">
Забыли пароль?{' '}
<Link to='/PasswordRecovery' className="fw-bold text-body" style={{ color: 'black', textDecoration: 'none' }}>
<u>Восстановление пароля</u>
</Link>
</p>
<div className="d-flex justify-content-center">
<Button as={Link} to='/PersonalAccount' variant="submit" className="btn-block btn-warning text-body mb-0">
Вход
</Button>
</div>
<p className="text-center text-muted mb-0">
У вас нет аккаунта?{' '}
<Link to='/personalAccountRegister' className="fw-bold text-body" style={{ color: 'black', textDecoration: 'none' }}>
<u>Регистрация</u>
</Link>
</p>
<p className="text-center">
<Link to='/Administrator' className="fw-bold text-body" style={{ color: 'black'}}>
Администратор
</Link>
</p>
</Form>
</Card.Body>
</Card>
</Col>
</Row>
</Container>
);
};
export default PersonalAccountLogin;

Some files were not shown because too many files have changed in this diff Show More