Browse Source

自助借还书图书推荐

master
xuhuajiao 1 year ago
parent
commit
293ea2cac9
  1. 539
      selfServiceMachine/src/assets/iconfont/demo.css
  2. 557
      selfServiceMachine/src/assets/iconfont/demo_index.html
  3. 80
      selfServiceMachine/src/assets/iconfont/iconfont.css
  4. 1
      selfServiceMachine/src/assets/iconfont/iconfont.js
  5. 121
      selfServiceMachine/src/assets/iconfont/iconfont.json
  6. 51
      selfServiceMachine/src/assets/iconfont/iconfont.svg
  7. BIN
      selfServiceMachine/src/assets/iconfont/iconfont.ttf
  8. BIN
      selfServiceMachine/src/assets/iconfont/iconfont.woff
  9. BIN
      selfServiceMachine/src/assets/iconfont/iconfont.woff2
  10. BIN
      selfServiceMachine/src/assets/images/banner.png
  11. BIN
      selfServiceMachine/src/assets/images/default-img.png
  12. BIN
      selfServiceMachine/src/assets/images/home/bg.png
  13. BIN
      selfServiceMachine/src/assets/images/home/nav1.png
  14. BIN
      selfServiceMachine/src/assets/images/home/nav2.png
  15. BIN
      selfServiceMachine/src/assets/images/home/nav3.png
  16. BIN
      selfServiceMachine/src/assets/images/home/nav4.png
  17. BIN
      selfServiceMachine/src/assets/images/home/nav5.png
  18. BIN
      selfServiceMachine/src/assets/images/home/top.png
  19. BIN
      selfServiceMachine/src/assets/images/home/type-bg.png
  20. BIN
      selfServiceMachine/src/assets/images/img1.png
  21. BIN
      selfServiceMachine/src/assets/images/img10.png
  22. BIN
      selfServiceMachine/src/assets/images/img2.png
  23. BIN
      selfServiceMachine/src/assets/images/img3.png
  24. BIN
      selfServiceMachine/src/assets/images/img4.png
  25. BIN
      selfServiceMachine/src/assets/images/img5.png
  26. BIN
      selfServiceMachine/src/assets/images/img6.png
  27. BIN
      selfServiceMachine/src/assets/images/img7.png
  28. BIN
      selfServiceMachine/src/assets/images/img8.png
  29. BIN
      selfServiceMachine/src/assets/images/img9.png
  30. BIN
      selfServiceMachine/src/assets/images/list/1.png
  31. BIN
      selfServiceMachine/src/assets/images/list/10.png
  32. BIN
      selfServiceMachine/src/assets/images/list/11.png
  33. BIN
      selfServiceMachine/src/assets/images/list/12.png
  34. BIN
      selfServiceMachine/src/assets/images/list/13.png
  35. BIN
      selfServiceMachine/src/assets/images/list/14.png
  36. BIN
      selfServiceMachine/src/assets/images/list/15.png
  37. BIN
      selfServiceMachine/src/assets/images/list/2.png
  38. BIN
      selfServiceMachine/src/assets/images/list/3.png
  39. BIN
      selfServiceMachine/src/assets/images/list/4.png
  40. BIN
      selfServiceMachine/src/assets/images/list/5.png
  41. BIN
      selfServiceMachine/src/assets/images/list/6.png
  42. BIN
      selfServiceMachine/src/assets/images/list/7.png
  43. BIN
      selfServiceMachine/src/assets/images/list/8.png
  44. BIN
      selfServiceMachine/src/assets/images/list/9.png
  45. BIN
      selfServiceMachine/src/assets/images/list/left-btn.png
  46. BIN
      selfServiceMachine/src/assets/images/list/list-rack.png
  47. BIN
      selfServiceMachine/src/assets/images/list/list-title.png
  48. BIN
      selfServiceMachine/src/assets/images/list/right-btn.png
  49. BIN
      selfServiceMachine/src/assets/images/list/top.png
  50. BIN
      selfServiceMachine/src/assets/images/local-bg.png
  51. 785
      selfServiceMachine/src/assets/styles/index.scss
  52. 16
      selfServiceMachine/src/assets/styles/style.scss
  53. 6
      selfServiceMachine/src/main.js
  54. 40
      selfServiceMachine/src/router/index.js
  55. 94
      selfServiceMachine/src/views/authorRecommend.vue
  56. 178
      selfServiceMachine/src/views/bookRackList.vue
  57. 309
      selfServiceMachine/src/views/bookRecommend.vue
  58. 82
      selfServiceMachine/src/views/digitalResource.vue
  59. 40
      selfServiceMachine/src/views/hotBook.vue
  60. 191
      selfServiceMachine/src/views/index.vue
  61. 37
      selfServiceMachine/src/views/newBook.vue
  62. 26
      selfServiceMachine/src/views/onlineBookSelection.vue

539
selfServiceMachine/src/assets/iconfont/demo.css

@ -1,539 +0,0 @@
/* Logo 字体 */
@font-face {
font-family: "iconfont logo";
src: url('https://at.alicdn.com/t/font_985780_km7mi63cihi.eot?t=1545807318834');
src: url('https://at.alicdn.com/t/font_985780_km7mi63cihi.eot?t=1545807318834#iefix') format('embedded-opentype'),
url('https://at.alicdn.com/t/font_985780_km7mi63cihi.woff?t=1545807318834') format('woff'),
url('https://at.alicdn.com/t/font_985780_km7mi63cihi.ttf?t=1545807318834') format('truetype'),
url('https://at.alicdn.com/t/font_985780_km7mi63cihi.svg?t=1545807318834#iconfont') format('svg');
}
.logo {
font-family: "iconfont logo";
font-size: 160px;
font-style: normal;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
/* tabs */
.nav-tabs {
position: relative;
}
.nav-tabs .nav-more {
position: absolute;
right: 0;
bottom: 0;
height: 42px;
line-height: 42px;
color: #666;
}
#tabs {
border-bottom: 1px solid #eee;
}
#tabs li {
cursor: pointer;
width: 100px;
height: 40px;
line-height: 40px;
text-align: center;
font-size: 16px;
border-bottom: 2px solid transparent;
position: relative;
z-index: 1;
margin-bottom: -1px;
color: #666;
}
#tabs .active {
border-bottom-color: #f00;
color: #222;
}
.tab-container .content {
display: none;
}
/* 页面布局 */
.main {
padding: 30px 100px;
width: 960px;
margin: 0 auto;
}
.main .logo {
color: #333;
text-align: left;
margin-bottom: 30px;
line-height: 1;
height: 110px;
margin-top: -50px;
overflow: hidden;
*zoom: 1;
}
.main .logo a {
font-size: 160px;
color: #333;
}
.helps {
margin-top: 40px;
}
.helps pre {
padding: 20px;
margin: 10px 0;
border: solid 1px #e7e1cd;
background-color: #fffdef;
overflow: auto;
}
.icon_lists {
width: 100% !important;
overflow: hidden;
*zoom: 1;
}
.icon_lists li {
width: 100px;
margin-bottom: 10px;
margin-right: 20px;
text-align: center;
list-style: none !important;
cursor: default;
}
.icon_lists li .code-name {
line-height: 1.2;
}
.icon_lists .icon {
display: block;
height: 100px;
line-height: 100px;
font-size: 42px;
margin: 10px auto;
color: #333;
-webkit-transition: font-size 0.25s linear, width 0.25s linear;
-moz-transition: font-size 0.25s linear, width 0.25s linear;
transition: font-size 0.25s linear, width 0.25s linear;
}
.icon_lists .icon:hover {
font-size: 100px;
}
.icon_lists .svg-icon {
/* 通过设置 font-size 来改变图标大小 */
width: 1em;
/* 图标和文字相邻时,垂直对齐 */
vertical-align: -0.15em;
/* 通过设置 color 来改变 SVG 的颜色/fill */
fill: currentColor;
/* path stroke 溢出 viewBox 部分在 IE 下会显示
normalize.css 中也包含这行 */
overflow: hidden;
}
.icon_lists li .name,
.icon_lists li .code-name {
color: #666;
}
/* markdown 样式 */
.markdown {
color: #666;
font-size: 14px;
line-height: 1.8;
}
.highlight {
line-height: 1.5;
}
.markdown img {
vertical-align: middle;
max-width: 100%;
}
.markdown h1 {
color: #404040;
font-weight: 500;
line-height: 40px;
margin-bottom: 24px;
}
.markdown h2,
.markdown h3,
.markdown h4,
.markdown h5,
.markdown h6 {
color: #404040;
margin: 1.6em 0 0.6em 0;
font-weight: 500;
clear: both;
}
.markdown h1 {
font-size: 28px;
}
.markdown h2 {
font-size: 22px;
}
.markdown h3 {
font-size: 16px;
}
.markdown h4 {
font-size: 14px;
}
.markdown h5 {
font-size: 12px;
}
.markdown h6 {
font-size: 12px;
}
.markdown hr {
height: 1px;
border: 0;
background: #e9e9e9;
margin: 16px 0;
clear: both;
}
.markdown p {
margin: 1em 0;
}
.markdown>p,
.markdown>blockquote,
.markdown>.highlight,
.markdown>ol,
.markdown>ul {
width: 80%;
}
.markdown ul>li {
list-style: circle;
}
.markdown>ul li,
.markdown blockquote ul>li {
margin-left: 20px;
padding-left: 4px;
}
.markdown>ul li p,
.markdown>ol li p {
margin: 0.6em 0;
}
.markdown ol>li {
list-style: decimal;
}
.markdown>ol li,
.markdown blockquote ol>li {
margin-left: 20px;
padding-left: 4px;
}
.markdown code {
margin: 0 3px;
padding: 0 5px;
background: #eee;
border-radius: 3px;
}
.markdown strong,
.markdown b {
font-weight: 600;
}
.markdown>table {
border-collapse: collapse;
border-spacing: 0px;
empty-cells: show;
border: 1px solid #e9e9e9;
width: 95%;
margin-bottom: 24px;
}
.markdown>table th {
white-space: nowrap;
color: #333;
font-weight: 600;
}
.markdown>table th,
.markdown>table td {
border: 1px solid #e9e9e9;
padding: 8px 16px;
text-align: left;
}
.markdown>table th {
background: #F7F7F7;
}
.markdown blockquote {
font-size: 90%;
color: #999;
border-left: 4px solid #e9e9e9;
padding-left: 0.8em;
margin: 1em 0;
}
.markdown blockquote p {
margin: 0;
}
.markdown .anchor {
opacity: 0;
transition: opacity 0.3s ease;
margin-left: 8px;
}
.markdown .waiting {
color: #ccc;
}
.markdown h1:hover .anchor,
.markdown h2:hover .anchor,
.markdown h3:hover .anchor,
.markdown h4:hover .anchor,
.markdown h5:hover .anchor,
.markdown h6:hover .anchor {
opacity: 1;
display: inline-block;
}
.markdown>br,
.markdown>p>br {
clear: both;
}
.hljs {
display: block;
background: white;
padding: 0.5em;
color: #333333;
overflow-x: auto;
}
.hljs-comment,
.hljs-meta {
color: #969896;
}
.hljs-string,
.hljs-variable,
.hljs-template-variable,
.hljs-strong,
.hljs-emphasis,
.hljs-quote {
color: #df5000;
}
.hljs-keyword,
.hljs-selector-tag,
.hljs-type {
color: #a71d5d;
}
.hljs-literal,
.hljs-symbol,
.hljs-bullet,
.hljs-attribute {
color: #0086b3;
}
.hljs-section,
.hljs-name {
color: #63a35c;
}
.hljs-tag {
color: #333333;
}
.hljs-title,
.hljs-attr,
.hljs-selector-id,
.hljs-selector-class,
.hljs-selector-attr,
.hljs-selector-pseudo {
color: #795da3;
}
.hljs-addition {
color: #55a532;
background-color: #eaffea;
}
.hljs-deletion {
color: #bd2c00;
background-color: #ffecec;
}
.hljs-link {
text-decoration: underline;
}
/* 代码高亮 */
/* PrismJS 1.15.0
https://prismjs.com/download.html#themes=prism&languages=markup+css+clike+javascript */
/**
* prism.js default theme for JavaScript, CSS and HTML
* Based on dabblet (http://dabblet.com)
* @author Lea Verou
*/
code[class*="language-"],
pre[class*="language-"] {
color: black;
background: none;
text-shadow: 0 1px white;
font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace;
text-align: left;
white-space: pre;
word-spacing: normal;
word-break: normal;
word-wrap: normal;
line-height: 1.5;
-moz-tab-size: 4;
-o-tab-size: 4;
tab-size: 4;
-webkit-hyphens: none;
-moz-hyphens: none;
-ms-hyphens: none;
hyphens: none;
}
pre[class*="language-"]::-moz-selection,
pre[class*="language-"] ::-moz-selection,
code[class*="language-"]::-moz-selection,
code[class*="language-"] ::-moz-selection {
text-shadow: none;
background: #b3d4fc;
}
pre[class*="language-"]::selection,
pre[class*="language-"] ::selection,
code[class*="language-"]::selection,
code[class*="language-"] ::selection {
text-shadow: none;
background: #b3d4fc;
}
@media print {
code[class*="language-"],
pre[class*="language-"] {
text-shadow: none;
}
}
/* Code blocks */
pre[class*="language-"] {
padding: 1em;
margin: .5em 0;
overflow: auto;
}
:not(pre)>code[class*="language-"],
pre[class*="language-"] {
background: #f5f2f0;
}
/* Inline code */
:not(pre)>code[class*="language-"] {
padding: .1em;
border-radius: .3em;
white-space: normal;
}
.token.comment,
.token.prolog,
.token.doctype,
.token.cdata {
color: slategray;
}
.token.punctuation {
color: #999;
}
.namespace {
opacity: .7;
}
.token.property,
.token.tag,
.token.boolean,
.token.number,
.token.constant,
.token.symbol,
.token.deleted {
color: #905;
}
.token.selector,
.token.attr-name,
.token.string,
.token.char,
.token.builtin,
.token.inserted {
color: #690;
}
.token.operator,
.token.entity,
.token.url,
.language-css .token.string,
.style .token.string {
color: #9a6e3a;
background: hsla(0, 0%, 100%, .5);
}
.token.atrule,
.token.attr-value,
.token.keyword {
color: #07a;
}
.token.function,
.token.class-name {
color: #DD4A68;
}
.token.regex,
.token.important,
.token.variable {
color: #e90;
}
.token.important,
.token.bold {
font-weight: bold;
}
.token.italic {
font-style: italic;
}
.token.entity {
cursor: help;
}

557
selfServiceMachine/src/assets/iconfont/demo_index.html

@ -1,557 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8"/>
<title>iconfont Demo</title>
<link rel="shortcut icon" href="//img.alicdn.com/imgextra/i4/O1CN01Z5paLz1O0zuCC7osS_!!6000000001644-55-tps-83-82.svg" type="image/x-icon"/>
<link rel="icon" type="image/svg+xml" href="//img.alicdn.com/imgextra/i4/O1CN01Z5paLz1O0zuCC7osS_!!6000000001644-55-tps-83-82.svg"/>
<link rel="stylesheet" href="https://g.alicdn.com/thx/cube/1.3.2/cube.min.css">
<link rel="stylesheet" href="demo.css">
<link rel="stylesheet" href="iconfont.css">
<script src="iconfont.js"></script>
<!-- jQuery -->
<script src="https://a1.alicdn.com/oss/uploads/2018/12/26/7bfddb60-08e8-11e9-9b04-53e73bb6408b.js"></script>
<!-- 代码高亮 -->
<script src="https://a1.alicdn.com/oss/uploads/2018/12/26/a3f714d0-08e6-11e9-8a15-ebf944d7534c.js"></script>
<style>
.main .logo {
margin-top: 0;
height: auto;
}
.main .logo a {
display: flex;
align-items: center;
}
.main .logo .sub-title {
margin-left: 0.5em;
font-size: 22px;
color: #fff;
background: linear-gradient(-45deg, #3967FF, #B500FE);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
}
</style>
</head>
<body>
<div class="main">
<h1 class="logo"><a href="https://www.iconfont.cn/" title="iconfont 首页" target="_blank">
<img width="200" src="https://img.alicdn.com/imgextra/i3/O1CN01Mn65HV1FfSEzR6DKv_!!6000000000514-55-tps-228-59.svg">
</a></h1>
<div class="nav-tabs">
<ul id="tabs" class="dib-box">
<li class="dib active"><span>Unicode</span></li>
<li class="dib"><span>Font class</span></li>
<li class="dib"><span>Symbol</span></li>
</ul>
<a href="https://www.iconfont.cn/manage/index?manage_type=myprojects&projectId=3646564" target="_blank" class="nav-more">查看项目</a>
</div>
<div class="tab-container">
<div class="content unicode" style="display: block;">
<ul class="icon_lists dib-box">
<li class="dib">
<span class="icon iconfont">&#xe639;</span>
<div class="name">位置</div>
<div class="code-name">&amp;#xe639;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe635;</span>
<div class="name">右滑</div>
<div class="code-name">&amp;#xe635;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe638;</span>
<div class="name">左滑</div>
<div class="code-name">&amp;#xe638;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe636;</span>
<div class="name">no.2</div>
<div class="code-name">&amp;#xe636;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe637;</span>
<div class="name">2</div>
<div class="code-name">&amp;#xe637;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe634;</span>
<div class="name">键盘</div>
<div class="code-name">&amp;#xe634;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe630;</span>
<div class="name">关闭</div>
<div class="code-name">&amp;#xe630;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe631;</span>
<div class="name"></div>
<div class="code-name">&amp;#xe631;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe632;</span>
<div class="name">本架图书</div>
<div class="code-name">&amp;#xe632;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe633;</span>
<div class="name">热门</div>
<div class="code-name">&amp;#xe633;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe62f;</span>
<div class="name"></div>
<div class="code-name">&amp;#xe62f;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe628;</span>
<div class="name">通知</div>
<div class="code-name">&amp;#xe628;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe629;</span>
<div class="name">no.3</div>
<div class="code-name">&amp;#xe629;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe62b;</span>
<div class="name">no.1</div>
<div class="code-name">&amp;#xe62b;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe62d;</span>
<div class="name">3</div>
<div class="code-name">&amp;#xe62d;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe62e;</span>
<div class="name">1</div>
<div class="code-name">&amp;#xe62e;</div>
</li>
</ul>
<div class="article markdown">
<h2 id="unicode-">Unicode 引用</h2>
<hr>
<p>Unicode 是字体在网页端最原始的应用方式,特点是:</p>
<ul>
<li>支持按字体的方式去动态调整图标大小,颜色等等。</li>
<li>默认情况下不支持多色,直接添加多色图标会自动去色。</li>
</ul>
<blockquote>
<p>注意:新版 iconfont 支持两种方式引用多色图标:SVG symbol 引用方式和彩色字体图标模式。(使用彩色字体图标需要在「编辑项目」中开启「彩色」选项后并重新生成。)</p>
</blockquote>
<p>Unicode 使用步骤如下:</p>
<h3 id="-font-face">第一步:拷贝项目下面生成的 <code>@font-face</code></h3>
<pre><code class="language-css"
>@font-face {
font-family: 'iconfont';
src: url('iconfont.woff2?t=1664428017869') format('woff2'),
url('iconfont.woff?t=1664428017869') format('woff'),
url('iconfont.ttf?t=1664428017869') format('truetype'),
url('iconfont.svg?t=1664428017869#iconfont') format('svg');
}
</code></pre>
<h3 id="-iconfont-">第二步:定义使用 iconfont 的样式</h3>
<pre><code class="language-css"
>.iconfont {
font-family: "iconfont" !important;
font-size: 16px;
font-style: normal;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
</code></pre>
<h3 id="-">第三步:挑选相应图标并获取字体编码,应用于页面</h3>
<pre>
<code class="language-html"
>&lt;span class="iconfont"&gt;&amp;#x33;&lt;/span&gt;
</code></pre>
<blockquote>
<p>"iconfont" 是你项目下的 font-family。可以通过编辑项目查看,默认是 "iconfont"。</p>
</blockquote>
</div>
</div>
<div class="content font-class">
<ul class="icon_lists dib-box">
<li class="dib">
<span class="icon iconfont icon-weizhi"></span>
<div class="name">
位置
</div>
<div class="code-name">.icon-weizhi
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-youhua"></span>
<div class="name">
右滑
</div>
<div class="code-name">.icon-youhua
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-zuohua"></span>
<div class="name">
左滑
</div>
<div class="code-name">.icon-zuohua
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-a-no21"></span>
<div class="name">
no.2
</div>
<div class="code-name">.icon-a-no21
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-a-21"></span>
<div class="name">
2
</div>
<div class="code-name">.icon-a-21
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-jianpan"></span>
<div class="name">
键盘
</div>
<div class="code-name">.icon-jianpan
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-guanbi"></span>
<div class="name">
关闭
</div>
<div class="code-name">.icon-guanbi
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-zuo"></span>
<div class="name">
</div>
<div class="code-name">.icon-zuo
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-benjiatushu"></span>
<div class="name">
本架图书
</div>
<div class="code-name">.icon-benjiatushu
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-remen"></span>
<div class="name">
热门
</div>
<div class="code-name">.icon-remen
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-you"></span>
<div class="name">
</div>
<div class="code-name">.icon-you
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-tongzhi"></span>
<div class="name">
通知
</div>
<div class="code-name">.icon-tongzhi
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-a-no3"></span>
<div class="name">
no.3
</div>
<div class="code-name">.icon-a-no3
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-a-no1"></span>
<div class="name">
no.1
</div>
<div class="code-name">.icon-a-no1
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-a-3"></span>
<div class="name">
3
</div>
<div class="code-name">.icon-a-3
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-a-1"></span>
<div class="name">
1
</div>
<div class="code-name">.icon-a-1
</div>
</li>
</ul>
<div class="article markdown">
<h2 id="font-class-">font-class 引用</h2>
<hr>
<p>font-class 是 Unicode 使用方式的一种变种,主要是解决 Unicode 书写不直观,语意不明确的问题。</p>
<p>与 Unicode 使用方式相比,具有如下特点:</p>
<ul>
<li>相比于 Unicode 语意明确,书写更直观。可以很容易分辨这个 icon 是什么。</li>
<li>因为使用 class 来定义图标,所以当要替换图标时,只需要修改 class 里面的 Unicode 引用。</li>
</ul>
<p>使用步骤如下:</p>
<h3 id="-fontclass-">第一步:引入项目下面生成的 fontclass 代码:</h3>
<pre><code class="language-html">&lt;link rel="stylesheet" href="./iconfont.css"&gt;
</code></pre>
<h3 id="-">第二步:挑选相应图标并获取类名,应用于页面:</h3>
<pre><code class="language-html">&lt;span class="iconfont icon-xxx"&gt;&lt;/span&gt;
</code></pre>
<blockquote>
<p>"
iconfont" 是你项目下的 font-family。可以通过编辑项目查看,默认是 "iconfont"。</p>
</blockquote>
</div>
</div>
<div class="content symbol">
<ul class="icon_lists dib-box">
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-weizhi"></use>
</svg>
<div class="name">位置</div>
<div class="code-name">#icon-weizhi</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-youhua"></use>
</svg>
<div class="name">右滑</div>
<div class="code-name">#icon-youhua</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-zuohua"></use>
</svg>
<div class="name">左滑</div>
<div class="code-name">#icon-zuohua</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-a-no21"></use>
</svg>
<div class="name">no.2</div>
<div class="code-name">#icon-a-no21</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-a-21"></use>
</svg>
<div class="name">2</div>
<div class="code-name">#icon-a-21</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-jianpan"></use>
</svg>
<div class="name">键盘</div>
<div class="code-name">#icon-jianpan</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-guanbi"></use>
</svg>
<div class="name">关闭</div>
<div class="code-name">#icon-guanbi</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-zuo"></use>
</svg>
<div class="name"></div>
<div class="code-name">#icon-zuo</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-benjiatushu"></use>
</svg>
<div class="name">本架图书</div>
<div class="code-name">#icon-benjiatushu</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-remen"></use>
</svg>
<div class="name">热门</div>
<div class="code-name">#icon-remen</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-you"></use>
</svg>
<div class="name"></div>
<div class="code-name">#icon-you</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-tongzhi"></use>
</svg>
<div class="name">通知</div>
<div class="code-name">#icon-tongzhi</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-a-no3"></use>
</svg>
<div class="name">no.3</div>
<div class="code-name">#icon-a-no3</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-a-no1"></use>
</svg>
<div class="name">no.1</div>
<div class="code-name">#icon-a-no1</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-a-3"></use>
</svg>
<div class="name">3</div>
<div class="code-name">#icon-a-3</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-a-1"></use>
</svg>
<div class="name">1</div>
<div class="code-name">#icon-a-1</div>
</li>
</ul>
<div class="article markdown">
<h2 id="symbol-">Symbol 引用</h2>
<hr>
<p>这是一种全新的使用方式,应该说这才是未来的主流,也是平台目前推荐的用法。相关介绍可以参考这篇<a href="">文章</a>
这种用法其实是做了一个 SVG 的集合,与另外两种相比具有如下特点:</p>
<ul>
<li>支持多色图标了,不再受单色限制。</li>
<li>通过一些技巧,支持像字体那样,通过 <code>font-size</code>, <code>color</code> 来调整样式。</li>
<li>兼容性较差,支持 IE9+,及现代浏览器。</li>
<li>浏览器渲染 SVG 的性能一般,还不如 png。</li>
</ul>
<p>使用步骤如下:</p>
<h3 id="-symbol-">第一步:引入项目下面生成的 symbol 代码:</h3>
<pre><code class="language-html">&lt;script src="./iconfont.js"&gt;&lt;/script&gt;
</code></pre>
<h3 id="-css-">第二步:加入通用 CSS 代码(引入一次就行):</h3>
<pre><code class="language-html">&lt;style&gt;
.icon {
width: 1em;
height: 1em;
vertical-align: -0.15em;
fill: currentColor;
overflow: hidden;
}
&lt;/style&gt;
</code></pre>
<h3 id="-">第三步:挑选相应图标并获取类名,应用于页面:</h3>
<pre><code class="language-html">&lt;svg class="icon" aria-hidden="true"&gt;
&lt;use xlink:href="#icon-xxx"&gt;&lt;/use&gt;
&lt;/svg&gt;
</code></pre>
</div>
</div>
</div>
</div>
<script>
$(document).ready(function () {
$('.tab-container .content:first').show()
$('#tabs li').click(function (e) {
var tabContent = $('.tab-container .content')
var index = $(this).index()
if ($(this).hasClass('active')) {
return
} else {
$('#tabs li').removeClass('active')
$(this).addClass('active')
tabContent.hide().eq(index).fadeIn()
}
})
})
</script>
</body>
</html>

80
selfServiceMachine/src/assets/iconfont/iconfont.css

@ -1,80 +0,0 @@
@font-face {
font-family: "iconfont"; /* Project id 3646564 */
src: url('iconfont.woff2?t=1664428017869') format('woff2'),
url('iconfont.woff?t=1664428017869') format('woff'),
url('iconfont.ttf?t=1664428017869') format('truetype'),
url('iconfont.svg?t=1664428017869#iconfont') format('svg');
}
.iconfont {
font-family: "iconfont" !important;
font-size: 16px;
font-style: normal;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
.icon-weizhi:before {
content: "\e639";
}
.icon-youhua:before {
content: "\e635";
}
.icon-zuohua:before {
content: "\e638";
}
.icon-a-no21:before {
content: "\e636";
}
.icon-a-21:before {
content: "\e637";
}
.icon-jianpan:before {
content: "\e634";
}
.icon-guanbi:before {
content: "\e630";
}
.icon-zuo:before {
content: "\e631";
}
.icon-benjiatushu:before {
content: "\e632";
}
.icon-remen:before {
content: "\e633";
}
.icon-you:before {
content: "\e62f";
}
.icon-tongzhi:before {
content: "\e628";
}
.icon-a-no3:before {
content: "\e629";
}
.icon-a-no1:before {
content: "\e62b";
}
.icon-a-3:before {
content: "\e62d";
}
.icon-a-1:before {
content: "\e62e";
}

1
selfServiceMachine/src/assets/iconfont/iconfont.js
File diff suppressed because it is too large
View File

121
selfServiceMachine/src/assets/iconfont/iconfont.json

@ -1,121 +0,0 @@
{
"id": "3646564",
"name": "东西湖图书馆",
"font_family": "iconfont",
"css_prefix_text": "icon-",
"description": "",
"glyphs": [
{
"icon_id": "32102019",
"name": "位置",
"font_class": "weizhi",
"unicode": "e639",
"unicode_decimal": 58937
},
{
"icon_id": "31966175",
"name": "右滑",
"font_class": "youhua",
"unicode": "e635",
"unicode_decimal": 58933
},
{
"icon_id": "31966176",
"name": "左滑",
"font_class": "zuohua",
"unicode": "e638",
"unicode_decimal": 58936
},
{
"icon_id": "31879702",
"name": "no.2",
"font_class": "a-no21",
"unicode": "e636",
"unicode_decimal": 58934
},
{
"icon_id": "31879708",
"name": "2",
"font_class": "a-21",
"unicode": "e637",
"unicode_decimal": 58935
},
{
"icon_id": "31879044",
"name": "键盘",
"font_class": "jianpan",
"unicode": "e634",
"unicode_decimal": 58932
},
{
"icon_id": "31859389",
"name": "关闭",
"font_class": "guanbi",
"unicode": "e630",
"unicode_decimal": 58928
},
{
"icon_id": "31859390",
"name": "左",
"font_class": "zuo",
"unicode": "e631",
"unicode_decimal": 58929
},
{
"icon_id": "31859393",
"name": "本架图书",
"font_class": "benjiatushu",
"unicode": "e632",
"unicode_decimal": 58930
},
{
"icon_id": "31859394",
"name": "热门",
"font_class": "remen",
"unicode": "e633",
"unicode_decimal": 58931
},
{
"icon_id": "31859388",
"name": "右",
"font_class": "you",
"unicode": "e62f",
"unicode_decimal": 58927
},
{
"icon_id": "31804863",
"name": "通知",
"font_class": "tongzhi",
"unicode": "e628",
"unicode_decimal": 58920
},
{
"icon_id": "31804864",
"name": "no.3",
"font_class": "a-no3",
"unicode": "e629",
"unicode_decimal": 58921
},
{
"icon_id": "31804866",
"name": "no.1",
"font_class": "a-no1",
"unicode": "e62b",
"unicode_decimal": 58923
},
{
"icon_id": "31804868",
"name": "3",
"font_class": "a-3",
"unicode": "e62d",
"unicode_decimal": 58925
},
{
"icon_id": "31804869",
"name": "1",
"font_class": "a-1",
"unicode": "e62e",
"unicode_decimal": 58926
}
]
}

51
selfServiceMachine/src/assets/iconfont/iconfont.svg
File diff suppressed because it is too large
View File

BIN
selfServiceMachine/src/assets/iconfont/iconfont.ttf

BIN
selfServiceMachine/src/assets/iconfont/iconfont.woff

BIN
selfServiceMachine/src/assets/iconfont/iconfont.woff2

BIN
selfServiceMachine/src/assets/images/banner.png

After

Width: 1080  |  Height: 357  |  Size: 230 KiB

BIN
selfServiceMachine/src/assets/images/default-img.png

Before

Width: 440  |  Height: 526  |  Size: 51 KiB

BIN
selfServiceMachine/src/assets/images/home/bg.png

Before

Width: 1080  |  Height: 1920  |  Size: 214 KiB

BIN
selfServiceMachine/src/assets/images/home/nav1.png

Before

Width: 160  |  Height: 160  |  Size: 28 KiB

BIN
selfServiceMachine/src/assets/images/home/nav2.png

Before

Width: 160  |  Height: 160  |  Size: 28 KiB

BIN
selfServiceMachine/src/assets/images/home/nav3.png

Before

Width: 160  |  Height: 160  |  Size: 29 KiB

BIN
selfServiceMachine/src/assets/images/home/nav4.png

Before

Width: 160  |  Height: 160  |  Size: 31 KiB

BIN
selfServiceMachine/src/assets/images/home/nav5.png

Before

Width: 160  |  Height: 160  |  Size: 27 KiB

BIN
selfServiceMachine/src/assets/images/home/top.png

Before

Width: 1080  |  Height: 254  |  Size: 32 KiB

BIN
selfServiceMachine/src/assets/images/home/type-bg.png

Before

Width: 1140  |  Height: 198  |  Size: 23 KiB

BIN
selfServiceMachine/src/assets/images/img1.png

After

Width: 28  |  Height: 28  |  Size: 741 B

BIN
selfServiceMachine/src/assets/images/img10.png

After

Width: 39  |  Height: 38  |  Size: 1.9 KiB

BIN
selfServiceMachine/src/assets/images/img2.png

After

Width: 28  |  Height: 28  |  Size: 499 B

BIN
selfServiceMachine/src/assets/images/img3.png

After

Width: 48  |  Height: 13  |  Size: 548 B

BIN
selfServiceMachine/src/assets/images/img4.png

After

Width: 24  |  Height: 24  |  Size: 354 B

BIN
selfServiceMachine/src/assets/images/img5.png

After

Width: 24  |  Height: 24  |  Size: 619 B

BIN
selfServiceMachine/src/assets/images/img6.png

After

Width: 24  |  Height: 24  |  Size: 557 B

BIN
selfServiceMachine/src/assets/images/img7.png

After

Width: 46  |  Height: 50  |  Size: 3.4 KiB

BIN
selfServiceMachine/src/assets/images/img8.png

After

Width: 46  |  Height: 50  |  Size: 3.6 KiB

BIN
selfServiceMachine/src/assets/images/img9.png

After

Width: 46  |  Height: 50  |  Size: 3.6 KiB

BIN
selfServiceMachine/src/assets/images/list/1.png

Before

Width: 97  |  Height: 267  |  Size: 5.9 KiB

BIN
selfServiceMachine/src/assets/images/list/10.png

Before

Width: 97  |  Height: 267  |  Size: 8.6 KiB

BIN
selfServiceMachine/src/assets/images/list/11.png

Before

Width: 97  |  Height: 267  |  Size: 8.4 KiB

BIN
selfServiceMachine/src/assets/images/list/12.png

Before

Width: 97  |  Height: 267  |  Size: 6.5 KiB

BIN
selfServiceMachine/src/assets/images/list/13.png

Before

Width: 97  |  Height: 267  |  Size: 6.1 KiB

BIN
selfServiceMachine/src/assets/images/list/14.png

Before

Width: 97  |  Height: 267  |  Size: 5.1 KiB

BIN
selfServiceMachine/src/assets/images/list/15.png

Before

Width: 97  |  Height: 267  |  Size: 7.2 KiB

BIN
selfServiceMachine/src/assets/images/list/2.png

Before

Width: 97  |  Height: 267  |  Size: 5.6 KiB

BIN
selfServiceMachine/src/assets/images/list/3.png

Before

Width: 97  |  Height: 267  |  Size: 6.5 KiB

BIN
selfServiceMachine/src/assets/images/list/4.png

Before

Width: 97  |  Height: 267  |  Size: 3.2 KiB

BIN
selfServiceMachine/src/assets/images/list/5.png

Before

Width: 97  |  Height: 267  |  Size: 6.6 KiB

BIN
selfServiceMachine/src/assets/images/list/6.png

Before

Width: 97  |  Height: 267  |  Size: 5.9 KiB

BIN
selfServiceMachine/src/assets/images/list/7.png

Before

Width: 97  |  Height: 267  |  Size: 8.0 KiB

BIN
selfServiceMachine/src/assets/images/list/8.png

Before

Width: 97  |  Height: 267  |  Size: 9.2 KiB

BIN
selfServiceMachine/src/assets/images/list/9.png

Before

Width: 97  |  Height: 267  |  Size: 8.7 KiB

BIN
selfServiceMachine/src/assets/images/list/left-btn.png

Before

Width: 220  |  Height: 60  |  Size: 1.5 KiB

BIN
selfServiceMachine/src/assets/images/list/list-rack.png

Before

Width: 1140  |  Height: 137  |  Size: 25 KiB

BIN
selfServiceMachine/src/assets/images/list/list-title.png

Before

Width: 494  |  Height: 76  |  Size: 15 KiB

BIN
selfServiceMachine/src/assets/images/list/right-btn.png

Before

Width: 220  |  Height: 60  |  Size: 1.5 KiB

BIN
selfServiceMachine/src/assets/images/list/top.png

Before

Width: 1080  |  Height: 120  |  Size: 16 KiB

BIN
selfServiceMachine/src/assets/images/local-bg.png

Before

Width: 83  |  Height: 346  |  Size: 6.5 KiB

785
selfServiceMachine/src/assets/styles/index.scss

@ -1,9 +1,12 @@
#bookshelf{
::-webkit-scrollbar {
width: 0;
height: 0;
}
#book{
width: 100%;
height: 100vh;
font-size: 30px;
// background: url('~@/assets/images/home/bg.png') no-repeat left top;
// background-size: cover;
font-size: 22px;
overflow: hidden;
overflow-y: auto;
}
@ -30,407 +33,467 @@
height: 180px;
}
}
// 首页
.bookshelf-header{
position: relative;
height: 254px;
text-align: center;
background: url('~@/assets/images/home/top.png') no-repeat left top;
background-size: cover;
z-index: 9;
h2{
height: 118px;
line-height: 118px;
font-family: "YouSheBiaoTiHei";
font-weight: normal;
font-size: 60px;
}
.shelf-num{
display: block;
position: absolute;
top: 30px;
right: 40px;
width: 180px;
height: 58px;
line-height: 60px;
background: linear-gradient(90deg, #ACDAFF 0%, #9BCEFF 100%);
border-radius: 29px;
}
}
.book-category{
position: relative;
display: flex;
justify-content: space-between;
justify-items: center;
text-align: center;
height: 198px;
line-height: 168px;
padding: 0 120px;
margin-top: -132px;
background: url('~@/assets/images/home/type-bg.png') no-repeat center center;
background-size: cover;
z-index: 99;
p{
flex: 1;
font-size: 60px;
letter-spacing: 6px;
}
}
.book-nav{
display: flex;
justify-content: space-between;
text-align: center;
padding: 0 40px;
margin-bottom: 30px;
li{
flex: 1;
font-size: 36px;
.recommend-main{
width: 100%;
height: calc(100vh - 60px);
background-color: #F4F4FC;
overflow: hidden;
.banner{
width: 100%;
height: 356px;
overflow: hidden;
margin-bottom: 16px;
img{
display: inline-block;
margin-bottom: 20px;
display: block;
width: 100%;
}
}
}
// 本架图书
.book-rack{
height: 770px;
margin: 0 40px;
padding: 0 40px 40px 40px;
background-color: #fff;
border-radius: 30px;
box-shadow: 0px 0px 20px 1px #B8D3FF;
}
.list-top{
display: flex;
justify-content: space-between;
justify-items: center;
align-items: center;
padding: 30px 0 25px 0;
font-size: 36px;
.list-top-title{
.recommend-cont{
display: flex;
justify-content: flex-start;
font-size: 40px;
line-height: 50px;
.icon{
width: 50px;
height: 50px;
margin-right: 20px;
justify-content: space-between;
height: calc(100% - 372px - 44px);
padding: 0 24px;
}
.recommend-left{
width: 310px;
height: 100%;
padding: 24px 16px 0 16px;
background-color: #fff;
.filter-header{
position: relative;
padding-left: 20px;
font-size: 28px;
font-weight: 600;
line-height: 30px;
&::before{
position: absolute;
left: 0;
top: 50%;
content: "";
width: 8px;
height: 26px;
background-color: #5A86F4;
transform: translateY(-50%);
}
}
}
.more{
.iconfont{
font-size: 30px;
margin-left: 20px;
.filter-item{
.filter-item-title{
position: relative;
padding-left: 20px;
margin-top: 24px;
height: 54px;
line-height: 54px;
font-size: 24px;
background-color: #F9F9FD;
border: 2px solid #C6C6E2;
border-radius: 8px;
&::after{
position: absolute;
right: 10px;
top: 50%;
content: "";
width: 24px;
height: 24px;
background: url('~@/assets/images/img4.png') no-repeat;
background-size: 24px 24px;
transform: rotate(-90deg);
margin-top: -12px;
}
}
.publish-list{
li{
display: flex;
justify-content: space-between;
align-items: center;
padding: 24px 0 16px 0;
font-size: 22px;
border-bottom: 1px solid #C6C6E2;
span{
color: #9D9E9E;
}
&.active{
color: #5A86F4;
span{
color: #5A86F4;
}
}
}
}
.publish-time-list{
display: flex;
justify-content: space-between;
flex-wrap: wrap;
align-items: center;
span{
display: block;
width: 130px;
height: 48px;
line-height: 48px;
margin-top: 16px;
color: #737475;
text-align: center;
border: 1px solid #C6C6E2;
border-radius: 8px;
background-color: #F9F9FD;
&.active{
color: #fff;
background-color: #5A86F4;
border-color: #5A86F4;
}
}
}
&:last-child{
padding-top: 18px;
}
}
.ranking{
padding-top: 40px;
.el-carousel{
margin-top: 14px;
}
.ranking-img{
width: 140px;
height: 200px;
background-color: red;
overflow: hidden;
}
.ranking-book-detail{
margin-top: 10px;
.book-info{
position: relative;
padding: 10px 10px 18px 16px;
background-color: #F9F9FD;
border: 1px solid #C6C6E2;
border-radius: 8px;
h5{
font-size: 24px;
}
.book-author{
padding: 10px 0;
font-size: 18px;
color: #FE6902;
span:first-child{
padding-right: 10px;
border-right: 1px solid #E9E9F4;
}
span:last-child{
padding-left: 10px;
}
}
.book-intro{
opacity: .6;
}
.ranking-status{
position: absolute;
right: 10px;
top: -22px;
width: 46px;
height: 50px;
background: url('~@/assets/images/img7.png') no-repeat;
background-size: 46px 50px;
}
}
.book-click-num{
display: flex;
justify-content: space-between;
padding: 6px 6px 6px 16px;
margin-top: 8px;
background-color: #F9F9FD;
border: 1px solid #C6C6E2;
border-radius: 8px;
span{
display: block;
font-size: 24px;
height: 42px;
line-height: 42px;
&.click-num{
padding-left: 28px;
font-size: 24px;
background: url('~@/assets/images/img6.png') no-repeat left center;
background-size: 24px 24px;
}
&.detail-btn{
font-size: 20px;
padding: 0 12px;
background-color: #5A86F4;
color: #fff;
border-radius: 8px;
}
}
}
}
.ranking-list-bottom{
li{
display: flex;
justify-content: space-between;
align-items: center;
padding: 24px 0 16px 0;
border-bottom: 1px solid #C6C6E2;
font-size: 22px;
span{
display: block;
margin-right: 30px;
background: url('~@/assets/images/img3.png') no-repeat center bottom;
background-size: 48px 13px;
}
}
}
}
}
}
// 本架图书list
.rack-list{
display: flex;
justify-content: space-between;
}
.list-item{
border: 1px solid #A2CCFF;
border-radius: 4px;
overflow: hidden;
.book-info{
position: relative;
}
.book-title{
font-weight: normal;
line-height: 40px;
margin-bottom: 10px;
}
.book-author{
font-size: 24px;
}
.book-num{
position: absolute;
bottom: 20px;
display: flex;
justify-content: flex-start;
font-size: 20px;
color: #999;
.icon{
width: 20px;
height: 22px;
margin-right: 10px;
.recommend-right{
width: 706px;
height: 100%;
.right-header{
padding: 24px;
background-color: #fff;
border-radius: 8px;
}
}
}
.list-big{
.list-item{
width: 435px;
height: 625px;
margin-right: 45px;
.book-img{
.recommend-search{
display: flex;
justify-content: flex-start;
align-items: center;
width: 100%;
height: 520px;
border-radius: 4px;
overflow: hidden;
}
img{
display: block;
width: 100%;
max-height: 100%;
object-fit: contain;
}
.book-info{
padding: 12px 0 0 44px;
}
.book-num{
right: 16px;
bottom: 0;
::v-deep .el-select{
.el-input--suffix .el-input__inner{
font-size: 24px;
width: 152px;
height: 56px;
background: #F1F4FE !important;
border: 1px solid #C6C6E2;
}
.el-input .el-select__caret{
font-size: 24px;
}
}
.el-button{
height: 56px;
font-size: 24px;
border: 1px solid #C6C6E2;
}
}
}
}
.other-list{
.book-img{
width: 244px;
}
.list-middle .list-item .book-info{
flex: 1;
}
}
.list-middle{
flex: 1;
display: flex;
flex-direction: column;
justify-content: space-between;
height: 625px;
.list-item{
display: flex;
height: calc(100%/2 - 20px);
justify-content: flex-start;
.book-img{
.input-search{
display: flex;
align-items: center;
width: 244px;
height: 100%;
margin-right: 20px;
margin: 0 8px;
border: 1px solid #C6C6E2;
border-radius: 8px;
overflow: hidden;
::v-deep .el-input{
.el-input__inner{
font-size: 20px;
height: 56px;
border: none;
}
}
.el-button{
display: block;
padding-left: 48px;
background: url('~@/assets/images/img5.png') no-repeat 12px center #5A86F4;
background-size: 24px 24px;
border-radius: 0 8px 8px 0;
border: none;
}
}
img{
display: block;
width: 100%;
max-height: calc(100%);
object-fit: contain;
}
.book-info{
padding: 20px 10px 0 0;
.hot-keyword{
font-size: 24px;
p{
padding: 16px 0 10px 0;
}
.keyword-item{
display: flex;
justify-content: flex-start;
align-items: center;
span{
display: block;
padding: 0 12px;
height: 44px;
line-height: 44px;
font-size: 20px;
background-color: #F9F9FD;
color: #737475;
border-radius: 8px;
margin-right: 12px;
}
}
}
.book-num{
left: 0;
bottom: 12px;
.recommend-list{
margin-top: 16px;
padding: 20px 24px;
background-color: #fff;
border-radius: 8px;
height: calc(100vh - 696px);
overflow: hidden;
overflow-y: scroll;
.result{
color: #737475;
span{
color: #5A86F4;
}
}
}
}
}
// 新书推荐
.new-recommend{
height: 448px;
margin: 20px 40px 0 40px;
.recommend-item{
margin-top: 20px;
padding-bottom: 22px;
}
.list-small{
.book-detail{
display: flex;
justify-items: center;
margin-left: -40px;
.list-item{
width: 200px;
border: none;
margin-left: 40px;
.book-img{
display: flex;
align-items: center;
width: 100%;
height: 240px;
margin-bottom: 10px;
overflow: hidden;
}
justify-content: flex-start;
.book-img{
width: 180px;
height: 245px;
margin-right: 17px;
background-color: #f1f1f1;
overflow: hidden;
img{
display: block;
width: 100%;
max-height: calc(100%);
object-fit: contain;
}
.book-title{
margin-bottom: 0;
}
}
}
//本架图书页面
.rack-box{
padding: 30px 0 0 0;
width: 100%;
.rack-item{
position: relative;
margin-bottom: 30px;
overflow: hidden;
.rack-box-list{
// display: flex;
// justify-content: space-between;
height: 314px;
padding: 0 40px;
width: 1080px;
background: url('~@/assets/images/list/list-rack.png') no-repeat -31px 205px;
overflow: hidden;
// overflow-x: auto;
white-space: nowrap;
.list-item{
margin-right: 1.7px;
.book-txt{
flex: 1;
h4{
font-size: 28px;
line-height: 40px;
}
.book-autor{
span{
display: inline-block;
border: none;
height: 254px;
width: 65px;
background-size: 93px 266px;
position: relative;
.box-txt{
position: absolute;
top: 12%;
left: 50%;
transform: translateX(-40%);
.book-name,.book-writer{
writing-mode:vertical-rl;
height: 235px;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.book-name{
font-size: 20px;
}
.book-writer{
font-size: 18px;
}
}
margin-right: 8px;
padding: 0 8px;
font-size: 20px;
height: 36px;
line-height: 36px;
border: 1px solid #C6C6E2;
color: #737475;
border-radius: 4px;
}
}
}
.rack-floor{
position: absolute;
left: 0;
bottom: 2px;
height: 50px;
width: 100%;
display: flex;
color: #fff;
align-items: center;
justify-content: space-between;
padding: 0 40px;
z-index: 999;
.icon-l,.icon-r{
font-size: 24px;
.book-publish{
margin: 12px 0;
opacity: .6;
span{
padding-right: 16px;
}
span:last-child{
padding-left: 16px;
font-size: 20px;
opacity: .4;
border-left: 1px solid #C6C6E2;
}
}
.book-intro{
line-height: 36px;
opacity: .6;
}
}
}
.bookshelf-header .icon-l{
color: #fff;
font-size: 40px;
position: absolute;
left: 40px;
top: 50%;
transform: translateY(-50%);
}
.bookshelf-header .rack-direct{
position: absolute;
top: 30px;
right: 40px;
width: 220px;
height: 60px;
line-height: 60px;
// background: linear-gradient(90deg, #ACDAFF 0%, #9BCEFF 100%);
background: #fff;
border-radius: 30px;
.book-eval{
display: flex;
justify-content: space-between;
align-items: center;
line-height: 48px;
margin-top: 14px;
padding: 4px 4px 4px 24px;
border-radius: 8px;
border: 2px solid #C6C6E2;
background: rgba(241,241,249,0.4);
.eval-num{
padding-left: 28px;
font-size: 24px;
background: url('~@/assets/images/img6.png') no-repeat left center;
background-size: 24px 24px;
}
.eval-star{
flex: 1;
display: flex;
padding: 6px;
justify-content: flex-start;
align-items: center;
margin-left: 76px;
span{
flex: 1;
text-align: center;
line-height: 48px;
&.rack-direct-active{
background: linear-gradient(267deg, #7285FB 0%, #7285FB 9%, #4377FE 55%, #2487FF 100%);
z-index: 1;
border-radius: 24px;
color: #fff;
display: block;
width: 28px;
height: 28px;
margin-right: 8px;
background: url('~@/assets/images/img2.png') no-repeat;
background-size: 28px 28px;
&.active{
background: url('~@/assets/images/img1.png') no-repeat;
background-size: 28px 28px;
}
}
}
.rack-box-list .list-item{
&:nth-child(15n+1){
background: url('~@/assets/images/list/1.png') no-repeat -15px -13px;
}
&:nth-child(15n+2){
background: url('~@/assets/images/list/2.png') no-repeat -15px -13px;
}
&:nth-child(15n+3){
background: url('~@/assets/images/list/3.png') no-repeat -15px -13px;
}
&:nth-child(15n+4){
background: url('~@/assets/images/list/4.png') no-repeat -15px -13px;
}
&:nth-child(15n+5){
background: url('~@/assets/images/list/5.png') no-repeat -15px -13px;
}
&:nth-child(15n+6){
background: url('~@/assets/images/list/6.png') no-repeat -15px -13px;
}
&:nth-child(15n+7){
background: url('~@/assets/images/list/7.png') no-repeat -15px -13px;
}
&:nth-child(15n+8){
background: url('~@/assets/images/list/8.png') no-repeat -15px -13px;
}
&:nth-child(15n+9){
background: url('~@/assets/images/list/9.png') no-repeat -15px -13px;
}
&:nth-child(15n+10){
background: url('~@/assets/images/list/10.png') no-repeat -15px -13px;
}
&:nth-child(15n+11){
background: url('~@/assets/images/list/11.png') no-repeat -15px -13px;
}
&:nth-child(15n+12){
background: url('~@/assets/images/list/12.png') no-repeat -15px -13px;
.to-book-more{
font-size: 20px;
padding: 0 8px;
color: #fff;
background-color: #5A86F4;
border-radius: 4px;
}
&:nth-child(15n+13){
background: url('~@/assets/images/list/13.png') no-repeat -15px -13px;
}
.book-place{
padding: 0 27px 0 32px;
background-color: #F8F8FD;
h4{
position: relative;
padding-left: 18px;
font-size: 28px;
line-height: 40px;
color: #191A1A;
&::before{
position: absolute;
left: 0;
top: 50%;
content: "";
width: 7px;
height: 26px;
background-color: #191A1A;
transform: translateY(-50%);
}
}
&:nth-child(15n+14){
background: url('~@/assets/images/list/14.png') no-repeat -15px -13px;
.book-place-list{
li{
display: flex;
justify-content: space-between;
padding: 14px 0;
font-size: 25px;
line-height: 40px;
border-bottom: 1px solid #C6C6E2;
span{
color: #000;
}
.place-detail{
padding-right: 56px;
color: #000;
background: url('~@/assets/images/img10.png') no-repeat right center;
background-size: 39px 38px;
}
}
}
&:nth-child(15n+15){
background: url('~@/assets/images/list/15.png') no-repeat -15px -13px;
}
.book-bottom{
margin-top: 24px;
span{
display: block;
width: 212px;
height: 57px;
line-height: 53px;
font-size: 25px;
text-align: center;
background: rgba(90,134,244,0.1);
border-radius: 29px;
border: 2px solid #5A86F4;
color: #5A86F4;
margin: 0 auto;
}
}
::-webkit-scrollbar {
width: 0;
height: 0;
}

16
selfServiceMachine/src/assets/styles/style.scss

@ -1,5 +1,3 @@
@import '~@/assets/iconfont/iconfont.css';
// 全局样式
* {
margin: 0;
@ -19,11 +17,11 @@ body {
background-color: #f1f1f1;
margin: 0;
padding: 0;
color: #333;
color: #191A1A;
}
a {
color: #333;
color: #191A1A;
text-decoration: none;
}
@ -72,7 +70,7 @@ ul{
}
//文章一行显示多余省略号显示
.title-item {
.title-item-only {
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 1;
@ -80,6 +78,14 @@ ul{
text-overflow: ellipsis;
}
.title-item {
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
overflow: hidden;
text-overflow: ellipsis;
}
.rotate:before {
display: inline-block;
transform: rotate(180deg);

6
selfServiceMachine/src/main.js

@ -12,16 +12,10 @@ import '@/common/flexible.js'
// 引入全局css
import './assets/styles/style.scss'
import './assets/iconfont/iconfont.js'
import './assets/fonts/fonts.css'
import axios from 'axios'
Vue.prototype.$axios = axios
// 馆代码 1201为东西湖馆代码 / 本地测试用FTZN
// Vue.prototype.libcode = 'FTZN'
Vue.prototype.libcode = '1201'
// 引入echart
import echarts from 'echarts'
Vue.prototype.$echarts = echarts

40
selfServiceMachine/src/router/index.js

@ -20,46 +20,6 @@ const routes = [
title: '书单推荐'
}
}
// {
// path: '/CurrentRackBook',
// name: 'CurrentRackBook',
// component: () => import('@/views/bookRackList.vue'),
// meta: {
// title: '本架图书'
// }
// },
// {
// path: '/NewBook',
// name: 'NewBook',
// component: () => import('@/views/newBook.vue'),
// meta: {
// title: '新书推荐'
// }
// },
// {
// path: '/HotBook',
// name: 'HotBook',
// component: () => import('@/views/hotBook.vue'),
// meta: {
// title: '热门图书'
// }
// },
// {
// path: '/AuthorRecommend',
// name: 'AuthorRecommend',
// component: () => import('@/views/authorRecommend.vue'),
// meta: {
// title: '作者推荐'
// }
// },
// {
// path: '/DigitalResource',
// name: 'DigitalResource',
// component: () => import('@/views/digitalResource.vue'),
// meta: {
// title: '数字资源'
// }
// }
]
const router = new VueRouter({

94
selfServiceMachine/src/views/authorRecommend.vue

@ -1,94 +0,0 @@
<template>
<div id="bookshelf">
<div class="bookshelf-header" style="height:120px">
<!-- <router-link to="/">
<span class="icon iconfont icon-l">&#xe631;</span>
</router-link> -->
<span class="icon iconfont icon-l" @click="goBack()">&#xe631;</span>
<h2>作者推荐</h2>
</div>
<div class="main">
<div v-for="(item,index) in authorList" :key="index" class="book-rack">
<span class="author-index">{{ index+1 }}</span>
<div class="author-brief">
<h3>{{ item.paAuthor }}</h3>
<p>{{ item.paExplain }}</p>
</div>
</div>
</div>
</div>
</template>
<script>
import { FetchProposeAuthor } from '@/api/bookshelf'
export default {
name: 'AuthorRecommend',
components: {
},
data() {
return {
authorList: []
}
},
created() {
this.getAuthor()
},
methods: {
goBack() {
this.$router.go(-1)
},
getAuthor() {
const params = {
libcode: this.libcode,
pageNo: 1,
pageSize: 22
}
FetchProposeAuthor(params).then(res => {
this.authorList = res.proposeAuthorList
}).catch(() => {
this.$message.error('接口错误')
})
}
}
}
</script>
<style lang="scss" scoped>
@import "~@/assets/styles/index.scss";
.main{
padding-top: 40px;
height: calc(100vh - 210px);
overflow: hidden;
overflow-y:auto ;
.book-rack{
height: 387px;
margin-bottom: 40px;
padding: 0;
display: flex;
align-items: center;
color: #333;
.author-index{
width: 120px;
text-align: center;
}
.author-brief{
flex: 1;
padding: 20px 50px 20px 0;
h3{
font-size: 40px;
margin-bottom: 20px;
}
p{
font-size: 30px;
overflow: hidden;
display: -webkit-box;
-webkit-line-clamp: 4;
line-clamp: 4;
-webkit-box-orient: vertical;
}
}
}
}
</style>

178
selfServiceMachine/src/views/bookRackList.vue

@ -1,178 +0,0 @@
<template>
<div id="bookshelf">
<div class="bookshelf-header" style="height:120px">
<!-- <router-link to="/">
<span class="icon iconfont icon-l">&#xe631;</span>
</router-link> -->
<span class="icon iconfont icon-l" @click="goBack()">&#xe631;</span>
<h2>本架图书</h2>
<div class="rack-direct">
<span :class="classnameL" @click="handleDirect(-1)"></span>
<span :class="classnameR" @click="handleDirect(1)"></span>
</div>
</div>
<div v-loading="loading" class="rack-box">
<div v-for="(item, index) in listData" :key="index" class="rack-item">
<div :class="['swiper'+index,'rack-box-list']">
<div class="swiper-wrapper">
<div v-for="eitem in bookList[item]" :key="eitem.id" class="list-item swiper-slide" @click="handleDetails(eitem)">
<div class="box-txt">
<span class="book-name">{{ eitem.bookName }}</span>
<span class="book-writer">{{ eitem.bookAuthor }}</span>
</div>
</div>
</div>
</div>
<div class="rack-floor">
<span :class="['icon','iconfont','icon-l'+index]" @click="handlePage(-1)">&#xe631;</span>
<p><span style="margin-right:25px">{{ index+1 }}</span><span>({{ bookList[item]?bookList[item].length:0 }})</span></p>
<span :class="['icon','iconfont','icon-r'+index]" @click="handlePage(1)">&#xe62f;</span>
</div>
</div>
</div>
<BookDetails ref="detailDom" />
</div>
</template>
<script>
import { initBookshelfDetails, getBookDetailsByISBN } from '@/api/bookshelf'
import BookDetails from './module/bookDetails.vue'
import { Swiper } from 'vue-awesome-swiper'
import 'swiper/swiper-bundle.css'
export default {
name: 'CurrentRackBook',
components: {
BookDetails
},
data() {
return {
loading: false,
listData: [],
bookList: {},
classnameL: 'rack-direct-active',
classnameR: null
}
},
created() {
this.initBookshelfDetails(-1)
},
mounted() {
},
methods: {
initSwiper() {
this.$nextTick(() => {
for (const key in this.bookList) {
this.bookList[key].forEach((el, index) => {
new Swiper('.swiper' + index, {
slidesPerView: 'auto',
slidesPerGroup: 15,
observer: true,
navigation: {
nextEl: '.icon-r' + index,
prevEl: '.icon-l' + index
}
})
})
}
})
},
// swiper
setSwiperInit() {
setTimeout(() => {
this.listData.forEach((item, index) => {
document.getElementsByClassName('swiper-wrapper')[index].style.transform = 'translate3d(0px, 0px, 0px)'
})
}, 50)
},
handleDetails(itemData) {
const params = {
isbn: itemData.isbn.replace(/\-/g, '')
}
getBookDetailsByISBN(params).then(res => {
this.$refs.detailDom.dialogVisible = true
if (res) {
this.$refs.detailDom.bookData = res
} else {
this.$refs.detailDom.bookData = {
srcUrl: itemData.bookAuthor,
bookName: itemData.bookName,
bookAuthor: itemData.bookAuthor ? itemData.bookAuthor : '暂无信息',
gist: '暂无简介',
Publish: '暂无信息',
places: [
{ shelfName: '' }
]
}
}
})
},
//
handlePage(page) {
if (page === 1) {
//
} else {
//
}
},
//
handleDirect(n) {
if (n === -1) { //
this.classnameR = null
this.classnameL = 'rack-direct-active'
} else { //
this.classnameL = null
this.classnameR = 'rack-direct-active'
}
this.initBookshelfDetails(n)
},
goBack() {
this.$router.go(-1)
},
initBookshelfDetails(n) {
this.loading = true
const params = {}
if (n === -1) { //
params.shelfNo = this.$route.query.leftShelfNo
} else { //
params.shelfNo = this.$route.query.rightShelfNo
}
initBookshelfDetails(params).then((res) => {
console.log(this.listData)
// if (res.shelfs.length === 0) {
// res.shelfs.push('firstShelf', 'secondShelf', 'thirdShelf', 'fourthShelf', 'fivethShelf')
// for (let index = 0; index < res.shelfs.length; index++) {
// const shelfNo = res.shelfs[index]
// res.shelfBook[shelfNo] = []
// }
// }
this.listData.splice(0, this.listData.length, ...res.shelfAll)
if (res.shelfs.length !== 0) {
for (let index = 0; index < res.shelfs.length; index++) {
const shelfNo = res.shelfs[index]
this.$set(this.bookList, shelfNo, res.shelfBook[shelfNo])
}
}
if (this.listData.length > 0) {
this.initSwiper()
this.setSwiperInit()
}
setTimeout(() => {
this.loading = false
}, 1000)
})
}
}
}
</script>
<style lang="scss">
@import "~@/assets/styles/index.scss";
.swiper-container {
position: relative;
width: 100%;
}
.swiper-slide {
width: 65px !important;
}
</style>

309
selfServiceMachine/src/views/bookRecommend.vue

@ -1,29 +1,300 @@
<template>
<div id="bookshelf">
<div class="bookshelf-header" style="height:120px">
<span class="icon iconfont icon-l" @click="goBack()">&#xe631;</span>
<h2>书单推荐</h2>
</div>
</div>
<div id="book">
<div class="top-bg"></div>
<div class="recommend-main">
<div class="banner">
<img src="~@/assets/images/banner.png" alt="" />
</div>
<div class="recommend-cont">
<div class="recommend-left">
<div class="quick-filter">
<h4 class="filter-header">快速筛选</h4>
<div class="filter-item">
<div class="filter-item-title">出版社</div>
<ul class="publish-list">
<li class="active">
<p>人民文学出版社</p>
<span>100</span>
</li>
<li>
<p>商务印书馆</p>
<span>96</span>
</li>
<li>
<p>人民出版社</p>
<span>80</span>
</li>
<li>
<p>上海译文出版社</p>
<span>43</span>
</li>
</ul>
</div>
<div class="filter-item">
<div class="filter-item-title">出版时间</div>
<div class="publish-time-list">
<span class="active">2023</span>
<span>2022</span>
<span>2021</span>
<span>2020</span>
<span>2019</span>
<span>2018</span>
</div>
</div>
</div>
<div class="ranking">
<h4 class="filter-header">排行榜</h4>
<el-carousel
:interval="4000"
type="card"
indicator-position="none"
height="200px"
>
<el-carousel-item>
<div class="ranking-img"></div>
</el-carousel-item>
<el-carousel-item>
<div class="ranking-img"></div>
</el-carousel-item>
<el-carousel-item>
<div class="ranking-img"></div>
</el-carousel-item>
</el-carousel>
<div class="ranking-book-detail">
<div class="book-info">
<h5>AI超入门</h5>
<div class="book-author">
<span>秋叶 刘进新</span>
<span>机械工业出版社</span>
</div>
<p class="book-intro title-item">
图书简介图书简介图书简介图书简介图书简介图书简介图书
</p>
<div class="ranking-status"></div>
</div>
<div class="book-click-num">
<span class="click-num">100</span>
<span class="detail-btn" @click="detailShow=true">查看详情</span>
</div>
</div>
<ul class="ranking-list-bottom">
<li>
<span>TOP4</span>
<p class="title-item-only">秒懂AI写作</p>
</li>
<li>
<span>TOP5</span>
<p class="title-item-only">
ChatGPT:AI革命AI革命AI革命
</p>
</li>
</ul>
</div>
</div>
<div class="recommend-right">
<div class="right-header">
<div class="recommend-search">
<el-select
v-model="selectValue"
placeholder="请选择"
>
<el-option
v-for="item in options"
:key="item.value"
:label="item.label"
:value="item.value"
>
</el-option>
</el-select>
<div class="input-search">
<el-input
v-model="keyword"
placeholder="请输入关键词进行检索"
style="width: 300px"
></el-input>
<el-button type="primary">搜索</el-button>
</div>
<el-button>重置</el-button>
</div>
<div class="hot-keyword">
<p>热门检索</p>
<div class="keyword-item">
<span>人工智能</span>
<span>遥遥领先</span>
<span>ChatAPT</span>
<span>5G</span>
</div>
</div>
</div>
<div class="recommend-list">
<div class="result">检索结果<span>121</span></div>
<div class="recommend-item" v-for="item in 10">
<div class="book-detail">
<div class="book-img">
<img src="" alt="" />
</div>
<div class="book-txt">
<h4>
{{item}}秒懂AI提问秒懂AI提问让人工智能成为你的效率神器
</h4>
<div class="book-autor">
<span>秋叶 刘进新 姜梅 定秋枫</span>
<span>2023年07月</span>
</div>
<div class="book-publish">
<span>人民邮电出版社</span>
<span>ISBN950146556432</span>
</div>
<div class="book-intro title-item">
精心提炼20种GPT提问方法及指令从入到进阶再到精通100个案例带你玩转100个案例带你玩转G
</div>
</div>
</div>
<div class="book-eval">
<span class="eval-num">100</span>
<div class="eval-star">
<span class="active"></span>
<span class="active"></span>
<span></span>
<span></span>
<span></span>
</div>
<div class="to-book-more" @click="detailShow=true">查看详情</div>
</div>
</div>
</div>
</div>
</div>
</div>
<el-dialog class="detail-dialog" append-to-body :close-on-click-modal="false" :modal-append-to-body="false" :visible.sync="detailShow">
<div class="dialog-book">
<div class="book-detail">
<div class="book-img">
<img src="" alt="" />
</div>
<div class="book-txt">
<h4>
秒懂AI提问秒懂AI提问让人工智能成为你的效率神器
</h4>
<div class="book-autor">
<span>秋叶 刘进新 姜梅 定秋枫</span>
<span>2023年07月</span>
</div>
<div class="book-publish">
<span>人民邮电出版社</span>
<span>ISBN950146556432</span>
</div>
<div class="book-intro title-item">
精心提炼20种GPT提问方法及指令从入到进阶再到精通100个案例带你玩转100个案例带你玩转G
</div>
</div>
</div>
<div class="book-eval">
<span class="eval-num">100</span>
<div class="eval-star">
<span class="active"></span>
<span class="active"></span>
<span></span>
<span></span>
<span></span>
</div>
</div>
</div>
<div class="book-place">
<h4>图书所在位置</h4>
<ul class="book-place-list">
<li>
<span>1</span>
<p class="book-num">400300210</p>
<p class="place-detail">1区30列5节3层左侧</p>
</li>
<li>
<span>2</span>
<p class="book-num">400300210</p>
<p class="place-detail">1区30列5节3层左侧</p>
</li>
</ul>
</div>
<div class="book-bottom">
<span @click="detailShow = false">关闭</span>
</div>
</el-dialog>
</div>
</template>
<script>
import { bookListCrud } from './mixins/booklist.js'
// import { bookListCrud } from './mixins/booklist.js'
export default {
name: 'NewBook',
components: { },
mixins: [bookListCrud],
data() {
return {
}
},
created() {
},
methods: {
}
name: 'BookRecommend',
components: {},
// mixins: [bookListCrud],
data() {
return {
selectValue: '1',
keyword: '',
detailShow: false,
options: [
{
value: '1',
label: '题名',
},
{
value: '2',
label: 'ISBN',
},
{
value: '3',
label: '著者',
},
{
value: '4',
label: '出版社',
},
{
value: '5',
label: '出版时间',
},
],
}
},
created() {},
methods: {},
}
</script>
<style lang="scss" scoped>
@import "~@/assets/styles/index.scss";
@import '~@/assets/styles/index.scss';
::v-deep .el-dialog{
width: 848px;
border-radius: 16px;
background: #F8F8FD;
box-shadow: 0px 3px 20px 1px rgba(0,0,0,0.05);
.el-dialog__body{
padding: 20px 0 23px 0;
}
}
::v-deep .el-dialog__header{
display: none;
}
.dialog-book{
padding: 30px;
font-size: 28px;
.book-txt{
color: #191A1A;
font-size: 30px;
}
.book-autor span{
font-size: 24px;
}
.book-publish{
font-size: 28px;
span:last-child{
font-size: 24px;
}
}
.book-eval .eval-num{
font-size: 28px;
}
}
</style>

82
selfServiceMachine/src/views/digitalResource.vue

@ -1,82 +0,0 @@
<template>
<div id="bookshelf">
<div class="bookshelf-header" style="height:120px">
<router-link to="/">
<span class="icon iconfont icon-l">&#xe631;</span>
</router-link>
<h2>数字资源</h2>
</div>
<div class="main">
<div v-for="(item,index) in srcList" :key="index" class="main-item" @click="jump(item.nrsUrl)">
<img :src="'data:image/png;base64,' + item.nrsImages" />
<div class="title" :style="{ fontSize: item.nrsTitle.length >6 ? '60px' : '80px'}">
{{ item.nrsTitle }}
</div>
</div>
</div>
</div>
</template>
<script>
import { initNumberResoures } from '@/api/bookshelf'
export default {
name: 'DigitalResource',
components: {
},
data() {
return {
srcList: []
}
},
created() {
this.getInfo()
},
methods: {
getInfo() {
initNumberResoures({ libcode: this.libcode }).then(data => {
this.srcList = data
})
},
jump(url) {
window.location.href = url
}
}
}
</script>
<style lang="scss" scoped>
@import "~@/assets/styles/index.scss";
.main{
padding-top: 40px;
height: calc(100vh - 180px);
overflow: hidden;
overflow-y:auto ;
.main-item{
// height: 387px;
margin-bottom: 40px;
padding: 0 40px;
// overflow: hidden;
position: relative;
img{
width: 100%;
}
.title{
position: absolute;
left: 50%;
top: 50%;
transform: translate(-50%,-50%);
font-family: "HuXiaoBoNanShenTi";
font-size: 80px;
color: #333;
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 3;
line-clamp: 3;
-webkit-box-orient: vertical;
text-align: center;
}
}
}
</style>

40
selfServiceMachine/src/views/hotBook.vue

@ -1,40 +0,0 @@
<template>
<div id="bookshelf">
<div class="bookshelf-header" style="height:120px">
<!-- <router-link to="/">
<span class="icon iconfont icon-l">&#xe631;</span>
</router-link> -->
<span class="icon iconfont icon-l" @click="goBack()">&#xe631;</span>
<h2>热门图书</h2>
</div>
<BookList />
</div>
</template>
<script>
import BookList from '@/views/module/bookList.vue'
import { bookListCrud } from './mixins/booklist.js'
export default {
name: 'HotBook',
components: { BookList },
mixins: [bookListCrud],
data() {
return {
}
},
created() {
},
mounted() {
},
methods: {
goBack() {
this.$router.go(-1)
}
}
}
</script>
<style lang="scss" scoped>
@import "~@/assets/styles/index.scss";
</style>

191
selfServiceMachine/src/views/index.vue

@ -1,191 +0,0 @@
<template>
<div id="bookshelf">
<div class="bookshelf-header">
<h2>RFID智慧书架</h2>
<span class="shelf-num">{{ shelfName }}</span>
</div>
<!-- 本架分类 -->
<div class="book-category">
<p>{{ leftShelfMsg }}</p>
<p>{{ rightShelfMsg }}</p>
</div>
<!-- 智慧书架导航 -->
<ul class="book-nav">
<li @click="toSearch">
<img src="~@/assets/images/home/nav1.png" />
<p>图书检索</p>
</li>
<li @click="toPath('/HotBook?bookType=hot')">
<img src="~@/assets/images/home/nav2.png" />
<p>热门图书</p>
</li>
<li @click="toPath('/AuthorRecommend')">
<img src="~@/assets/images/home/nav3.png" />
<p>作者推荐</p>
</li>
<li @click="toPath('/DigitalResource')">
<img src="~@/assets/images/home/nav4.png" />
<p>数字资源</p>
</li>
<li @click="toRoomNav">
<img src="~@/assets/images/home/nav5.png" />
<p>场馆导航</p>
</li>
</ul>
<!-- 本架图书 -->
<div class="book-rack">
<div class="list-top">
<div class="list-top-title">
<svg class="icon" aria-hidden="true">
<use xlink:href="#icon-benjiatushu" />
</svg>
<p>本架图书</p>
</div>
<span class="more" @click="toPath('/CurrentRackBook')">更多<i class="iconfont icon-zuo rotate"></i></span>
</div>
<div class="rack-list">
<BookListItem :list-data.sync="rackList" />
<div class="other-list">
<BookListItem :list-data.sync="otherList" :is-other-book="true" />
</div>
</div>
</div>
<!-- 新书推荐 -->
<div class="book-rack new-recommend">
<div class="list-top">
<div class="list-top-title">
<p>新书推荐</p>
</div>
<span class="more" @click="toPath('/NewBook?bookType=new')">更多<i class="iconfont icon-zuo rotate"></i></span>
</div>
<BookListItem :list-data.sync="newList" :is-new-book="true" />
</div>
</div>
</template>
<script>
import BookListItem from '@/views/module/homeListItem.vue'
import { FetchNewBookRecommend, FetchCoverByISBN, initSmartBookshelf } from '@/api/bookshelf'
export default {
name: 'Home',
components: {
BookListItem
},
data() {
return {
shelfName: '1',
leftShelfMsg: '',
rightShelfMsg: '',
// leftShelfNo: '1201-03-001-A-01',
// rightShelfNo: '1201-03-001-B-01',
leftShelfNo: '',
rightShelfNo: '',
rackList: [], //
otherList: [], //
newList: [] //
}
},
created() {
this.getNewBookList()
// +
this.initSmartBookshelf()
},
mounted() {
},
methods: {
toSearch() {
window.location.href = 'http://219.140.69.151/opac'
},
toPath(path) {
if (path === '/CurrentRackBook') {
const query = { leftShelfNo: this.leftShelfNo, rightShelfNo: this.rightShelfNo }
this.$router.push({ path: path, query: query })
} else {
this.$router.push(path)
}
},
toRoomNav() {
const linkSrc = process.env.VUE_APP_BASE_API
window.location.href = linkSrc + '/anchoring/initVenueNavigation.do?libcode=' + this.libcode
},
// -
getNewBookList() {
const params = {
libcode: this.libcode,
pageNo: 1,
pageSize: 4
}
FetchNewBookRecommend(params).then(res => {
let data = []
data = res.newbookList
data.forEach(item => {
this.getCoverByISBN(item.isbn.replace(/\-/g, ''), item)
})
}).catch(() => {
this.$message.error('接口错误')
})
},
// isbn
getCoverByISBN(isbn, item) {
const params = {
isbn: isbn
}
console.log(params)
FetchCoverByISBN(params).then((res) => {
// item.cover = window.URL.createObjectURL(res)
if (res) {
item.cover = res
} else {
item.cover = ''
}
this.newList.push(item)
})
},
//
initSmartBookshelf() {
this.leftShelfNo = this.$route.query.leftShelfNo
this.rightShelfNo = this.$route.query.rightShelfNo
const params = { leftShelfNo: this.leftShelfNo, rightShelfNo: this.rightShelfNo }
// const _this = this
initSmartBookshelf(params).then((res) => {
this.shelfName = res.shelfName
this.leftShelfMsg = res.leftShelf.sortMsg
this.rightShelfMsg = res.rightShelf.sortMsg
Promise.all(this.initBookData(res.bookList.splice(0, 1))).then((res) => {
this.rackList = res
console.log('rackList', this.rackList)
})
Promise.all(this.initBookData(res.bookList.splice(-2))).then((res) => {
this.otherList = res
console.log('otherList', this.otherList)
})
})
},
//
initBookData(bookList) {
return bookList.map(async(item, index) => {
const newItem = {
cover: item.srcUrl,
ranking: item.bookUID,
nbName: item.bookName,
isOtherBook: index !== 0,
nbAuthor: item.bookAuthor ? item.bookAuthor : '',
isNewBook: false,
num: item.heat ? item.heat : '0',
isbn: item.isbn
}
// const params = {
// isbn: item.isbn
// }
// const res = await FetchCoverByISBN(params)
// newItem.cover = window.URL.createObjectURL(res)
return newItem
})
}
}
}
</script>
<style lang="scss">
@import "~@/assets/styles/index.scss";
</style>

37
selfServiceMachine/src/views/newBook.vue

@ -1,37 +0,0 @@
<template>
<div id="bookshelf">
<div class="bookshelf-header" style="height:120px">
<!-- <router-link to="/">
<span class="icon iconfont icon-l">&#xe631;</span>
</router-link> -->
<span class="icon iconfont icon-l" @click="goBack()">&#xe631;</span>
<h2>新书推荐</h2>
</div>
<BookList />
</div>
</template>
<script>
import BookList from '@/views/module/bookList.vue'
import { bookListCrud } from './mixins/booklist.js'
export default {
name: 'NewBook',
components: { BookList },
mixins: [bookListCrud],
data() {
return {
}
},
created() {
},
methods: {
goBack() {
this.$router.go(-1)
}
}
}
</script>
<style lang="scss" scoped>
@import "~@/assets/styles/index.scss";
</style>

26
selfServiceMachine/src/views/onlineBookSelection.vue

@ -1,8 +1,5 @@
<template>
<div id="bookshelf">
<!-- <div class="bookshelf-header" style="height:120px">
<h2>在线选书</h2>
</div> -->
<div id="book">
<div class="top-bg"></div>
<div class="online-active">
<img src="~@/assets/images/code.png" alt="" />
@ -11,11 +8,11 @@
</template>
<script>
import { bookListCrud } from './mixins/booklist.js'
// import { bookListCrud } from './mixins/booklist.js'
export default {
name: 'NewBook',
name: 'OnlineBookSelection',
components: { },
mixins: [bookListCrud],
// mixins: [bookListCrud],
data() {
return {
}
@ -29,19 +26,4 @@ export default {
<style lang="scss" scoped>
@import "~@/assets/styles/index.scss";
// .el-carousel__item h3 {
// color: #475669;
// font-size: 14px;
// opacity: 0.75;
// line-height: 200px;
// margin: 0;
// }
// .el-carousel__item:nth-child(2n) {
// background-color: #99a9bf;
// }
// .el-carousel__item:nth-child(2n+1) {
// background-color: #d3dce6;
// }
</style>
Loading…
Cancel
Save