1
0
mirror of https://gitee.com/bookshelfplus/bookshelfplus synced 2025-09-02 23:23:28 +08:00
Code Issues Projects Releases Wiki Activity GitHub Gitee
Files
bookshelfplus/bookshelfplus-frontend/views/search.html

60 lines
1.6 KiB
HTML

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<%- include("./component/header.html"); %>
<style>
.main {
width: 80vw !important;
max-width: initial !important;
}
#result-table {
width: 100%;
/* border: 1px solid black; */
margin-top: 30px;
line-height: 2.3em;
}
tr:hover {
background-color: #f5f5f5;
}
tr a {
cursor: pointer;
/* cursor: alias; */
}
</style>
</head>
<body>
<%- include("./component/navbar.html"); %>
<div class="main">
<h1><%= headText %></h1>
<%- include("./component/searchbox.html"); %>
<div id="container">
<table id="result-table"></table>
<!-- <table id="origin-table"></table> -->
</div>
</div>
<%- include("./component/footer.html"); %>
<!-- 获取参数 -->
<script src="/assets/javascripts/getParams.js"></script>
<!-- 渲染表格 -->
<script src="/assets/javascripts/renderTable.js"></script>
<!-- 搜索书籍 -->
<script src="/assets/javascripts/searchBooks.js"></script>
<script>
var requestParams = getParams();
var searchbox = document.getElementById("searchInput");
var keyword = (requestParams["keyword"] || "").trim();
searchbox.value = keyword;
if (keyword === "")
searchbox.focus();
search({
tableElementId: "result-table",
searchText: keyword,
categoryId: null
});
</script>
</body>
</html>