mindoc/views/home/index.tpl

79 lines
3.6 KiB
Smarty
Raw Normal View History

2017-04-19 18:19:27 +08:00
<!DOCTYPE html>
2017-04-20 18:19:32 +08:00
<html lang="zh-CN">
2017-04-19 18:19:27 +08:00
<head>
2018-01-27 13:34:48 +08:00
<title>{{.SITE_NAME}} - Powered by MinDoc</title>
2017-04-20 18:19:32 +08:00
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
2018-01-27 13:34:48 +08:00
<meta name="renderer" content="webkit">
2017-05-12 14:21:29 +08:00
<meta name="author" content="Minho" />
<meta name="site" content="https://www.iminho.me" />
2018-01-27 13:34:48 +08:00
<meta name="description" content="{{.site_description}}">
2017-04-20 18:19:32 +08:00
<!-- Bootstrap -->
2017-05-12 14:21:29 +08:00
<link href="{{cdncss "/static/bootstrap/css/bootstrap.min.css"}}" rel="stylesheet">
<link href="{{cdncss "/static/font-awesome/css/font-awesome.min.css"}}" rel="stylesheet">
2017-04-20 18:19:32 +08:00
2017-05-12 14:21:29 +08:00
<link href="{{cdncss "/static/css/main.css"}}" rel="stylesheet">
2017-04-20 18:19:32 +08:00
<!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
<!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
<!--[if lt IE 9]>
<script src="/static/html5shiv/3.7.3/html5shiv.min.js"></script>
<script src="/static/respond.js/1.4.2/respond.min.js"></script>
<![endif]-->
2017-04-19 18:19:27 +08:00
</head>
<body>
2017-04-20 18:19:32 +08:00
<div class="manual-reader manual-container">
{{template "widgets/header.tpl" .}}
<div class="container manual-body">
<div class="row">
{{if gt (.Labels|len) 1000000}}
<div class="hide tag-container-outer">
<span class="title">热门标签:</span>
<span class="tags">
{{range $index,$item := .Labels}}
<a href="{{urlfor "LabelController.Index" ":key" $item.LabelName}}">{{$item.LabelName}}<span class="detail">{{$item.BookNumber}}</span></a>
{{end}}
</span>
</div>
{{end}}
2017-04-20 18:19:32 +08:00
<div class="manual-list">
{{range $index,$item := .Lists}}
2017-04-20 18:19:32 +08:00
<div class="list-item">
<dl class="manual-item-standard">
<dt>
2017-06-05 14:19:44 +08:00
<a href="{{urlfor "DocumentController.Index" ":key" $item.Identify}}" title="{{$item.BookName}}-{{$item.CreateName}}" target="_blank">
2018-03-01 14:07:51 +08:00
<img src="{{cdnimg $item.Cover}}" class="cover" alt="{{$item.BookName}}-{{$item.CreateName}}" onerror="this.src='{{cdnimg "static/images/book.jpg"}}';">
2017-04-20 18:19:32 +08:00
</a>
</dt>
<dd>
2017-06-05 14:19:44 +08:00
<a href="{{urlfor "DocumentController.Index" ":key" $item.Identify}}" class="name" title="{{$item.BookName}}-{{$item.CreateName}}" target="_blank">{{$item.BookName}}</a>
2017-04-20 18:19:32 +08:00
</dd>
<dd>
<span class="author">
<b class="text">作者</b>
<b class="text">-</b>
<b class="text">{{if eq $item.RealName "" }}{{$item.CreateName}}{{else}}{{$item.RealName}}{{end}}</b>
2017-04-20 18:19:32 +08:00
</span>
</dd>
</dl>
</div>
{{end}}
2017-04-20 18:19:32 +08:00
<div class="clearfix"></div>
</div>
2017-05-31 10:15:04 +08:00
<nav class="pagination-container">
{{if gt .TotalPages 1}}
{{.PageHtml}}
{{end}}
<div class="clearfix"></div>
</nav>
2017-04-20 18:19:32 +08:00
</div>
</div>
{{template "widgets/footer.tpl" .}}
2017-04-19 18:19:27 +08:00
</div>
2017-05-12 14:21:29 +08:00
<script src="{{cdnjs "/static/jquery/1.12.4/jquery.min.js"}}" type="text/javascript"></script>
<script src="{{cdnjs "/static/bootstrap/js/bootstrap.min.js"}}" type="text/javascript"></script>
2017-04-19 18:19:27 +08:00
</body>
2017-04-20 18:19:32 +08:00
</html>