Internet_Programming_PIbd-2.../add-item.html
2023-12-08 22:40:11 +04:00

202 lines
10 KiB
HTML
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE html>
<html lang="ru">
<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="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,800;0,900;1,700&display=swap" rel="stylesheet">
<link rel="stylesheet" href="css/style.css">
</head>
<body class="d-flex flex-column min-vh-100 bg-white">
<header class="w-100 position-sticky top-0">
<nav class="navbar navbar-expand-lg navbar-light">
<div class="container-md">
<a class="navbar-brand me-lg-5 d-flex align-items-center" href="/" id="logo">
<img src="icons/logo.png" alt="logo" class="me-2">
Читай-комната
</a>
<button class="navbar-toggler ms-auto" 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" id="navbarNav">
<ul class="navbar-nav align-items-lg-center justify-content-lg-start w-100">
<li class="header-link nav-item ms-lg-2 me-lg-3">
<a class="nav-link" href="./index.html">Главная</a>
</li>
<li class="header-link nav-item me-lg-3">
<a class="nav-link" href="./catalog.html">Каталог</a>
</li>
<li class="header-link nav-item me-lg-5" id="header-contacts">
<a class="nav-link" href="./contacts.html">Контакты</a>
</li>
<div class="flex-grow-1 me-lg-4" id="header-search">
<input class="form-control h-25" type="search" placeholder="Я ищу..." aria-label="Search" id="search-bar">
</div>
<li class="nav-item">
<a class="nav-link" aria-current="page" href="./login.html">
Вход
</a>
</li>
<p class="d-none d-lg-block">
/
</p>
<li class="nav-item me-lg-3">
<a class="nav-link" href="./registration.html">
Регистрация
</a>
</li>
<li class="nav-item">
<a class="nav-link pe-lg-0" href="./cart.html">
<img src="icons/card.png" alt="card" width="30" height="35" id="cart-icon">
</a>
</li>
</ul>
</div>
</div>
</nav>
</header>
<main class="container-md d-flex flex-column flex-grow-1 my-0">
<div class="row justify-content-center">
<div class="col-12 text-center">
<img src="https://placehold.co/400x600/#DCDCDC/black" id="image-preview" class="mt-5 mb-4" alt="placeholder" width="400" height="600">
</div>
<form id="items-form" class="needs-validation col-lg-8 col-xl-7 col-xxl-6" novalidate>
<div class="mb-4">
<label for="item-category" class="form-label">Категория каталога</label>
<select id="item-category" class="form-select" name="selected" required>
</select>
</div>
<div class="mb-4">
<label class="form-label" for="item-title">Название книги</label>
<input id="item-title" class="form-control" type="text" required>
</div>
<div class="mb-4">
<label class="form-label" for="item-author">Автор</label>
<input id="item-author" class="form-control" type="text" required>
</div>
<div class="mb-4">
<label class="form-label" for="item-price">Цена</label>
<input id="item-price" name="item-price" class="form-control" value="0.00" min="100.00" step="0.50" type="number" required>
</div>
<div class="mb-4">
<label class="form-label" for="item-count">Количество</label>
<input id="item-count" name="item-count" class="form-control" type="number" value="0" min="1" step="1" required>
</div>
<div class="mb-4">
<label class="form-label" for="item-descrition">Описание книги</label>
<textarea class="form-control" id="item-descrition" rows="3"></textarea>
</div>
<div class="mb-4">
<label class="form-label" for="item-annotation">Аннотация</label>
<textarea class="form-control" id="item-annotation" rows="3"></textarea>
</div>
<p class="mb-3">
Xарактеристики:
</p>
<div class="mb-4 border border-1 border-secondary p-2">
<div class="mb-3">
<label class="form-label" for="item-id">ID товара</label>
<input id="item-id" class="form-control" type="number" required>
</div>
<div class="mb-3">
<label class="form-label" for="item-publisher">Издательство</label>
<input id="item-publisher" class="form-control" type="text">
</div>
<div class="mb-3">
<label class="form-label" for="item-series">Серия</label>
<input id="item-series" class="form-control" type="text">
</div>
<div class="mb-3">
<label class="form-label" for="item-publication-year">Год издания</label>
<input id="item-publication-year" class="form-control" type="number">
</div>
<div class="mb-3">
<label class="form-label" for="item-pages-num">Количество страниц</label>
<input id="item-pages-num" class="form-control" type="number">
</div>
<div class="mb-3">
<label class="form-label" for="item-size">Размер</label>
<input id="item-size" class="form-control" type="text">
</div>
<div class="mb-3">
<label class="form-label" for="item-cover-type">Тип обложки</label>
<input id="item-cover-type" class="form-control" type="text">
</div>
<div class="mb-3">
<label class="form-label" for="item-circulation">Тираж</label>
<input id="item-circulation" class="form-control" type="number">
</div>
<div>
<label class="form-label" for="item-weight">Вес, г</label>
<input id="item-weight" class="form-control" type="number">
</div>
</div>
<div class="mb-4">
<label class="form-label" for="image">Обложка книги</label>
<input id="image" type="file" name="image" class="form-control" accept="image/*">
</div>
<a href="/admin.html" class="btn btn-secondary">Назад</a>
<div class="text-center mb-5">
<button type="submit" class="btn btn-primary w-50 rounded-5" id="add-btn">Сохранить</button>
</div>
</form>
</div>
</main>
<footer class="footer flex-shrink-0">
<div class="container-md" id="footer-container">
<div class="row d-flex align-items-center gy-3 gy-lg-0 gx-0" id="footer-row">
<div class="col-md-6 col-lg-4">
<div class="block d-flex justify-content-center justify-content-md-start" id="footer-copyright">
© И. А. Родионов, 2023.
</div>
</div>
<div class="col-md-6 col-lg-3">
<div class="block d-flex align-items-center justify-content-center justify-content-md-end">
<img src="icons/telephone-call.png" class="me-2" alt="telephone-call" width="32" height="32">
<p id="footer-phone-number-text">
+7 927 818-61-60
</p>
</div>
</div>
<div class="col-md-12 col-lg-5 mb-3 mb-lg-0">
<div class="block d-flex align-items-center justify-content-center justify-content-lg-end">
<p class="me-3" id="footer-social-media-text">
Мы в соцсетях:
</p>
<a class="me-3" href="/">
<img src="icons/vk.png" alt="vk" width="32" height="32">
</a>
<a class="me-3" href="/">
<img src="icons/youtube.png" alt="youtube" width="32" height="32">
</a>
<a class="me-3" href="/">
<img src="icons/telegram.png" alt="telegram" width="32" height="32">
</a>
<a href="/">
<img src="icons/odnoklassniki.png" alt="odnoklassniki" width="32" height="32">
</a>
</div>
</div>
</div>
</div>
</footer>
<script type="module">
import validation from "./js/validation";
import { linesPageForm } from "./js/lines"
document.addEventListener('DOMContentLoaded', () => {
validation();
linesPageForm();
});
</script>
</body>
</html>