<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>搜索-</title>
    <link rel="stylesheet" href="/api/static/css/search.css">
    <link rel="stylesheet" href="/api/static/css/index.css">
</head>
<body>
{{template "NavigationBar.tmpl" .}}
<div class="search-result">
    <div class="search-result-body">
        <div class="search-result-title">
            <div class="search-result-title-text">搜索结果</div>
        </div>

        <div class="search-total">{{.count}}</div>

        <div class="card-list">
            {{range $i,$vo := .list}}
            <div class="goods-sku-info" onclick="JumpRouter('/detail?skuId={{$vo.id}}')">
                <div class="goods-img"><img src="{{.skuImage}}" alt=""></div>
                <div class="goods-name">{{ .skuName }}</div>
                <div class="goods-price">{{ .price }}</div>
                {{if ne .historicalPrices .price }}
                <div >
                    <div class="goods--original-price">￥{{ .historicalPrices }}</div>
                    <div class="goods-discount-percentage">{{discalc .price .historicalPrices }}</div>
                </div>
                {{else}}
                <div >
                    <div class="goods--original-price">￥{{ .historicalPrices }}</div>
                </div>
                {{end}}
            </div>
            {{end}}
        </div>
        <div class="search-pagination">
            {{if gt .count 11}}
            <el-pagination background
                           @current-change="GetSearch"
                           :current-page="vo.pageNum"
                           :page-size="vo.pageSize"
                           :hide-on-single-page="true"
                           :total="vo.total"
                           layout="prev, pager, next ">
            </el-pagination>
            {{end}}
        </div>
    </div>
</div>
{{template "BottomBar.tmpl" .}}
</body>
</html>