123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110 |
- @model ProductListModel
- @section style{
- <link rel="stylesheet" href="@ConfigHelper.GetCDNPrefix()/assets/plugins/page/paging.css">
- <link rel="stylesheet" href="@ConfigHelper.GetCDNPrefix()/assets/css/product.css">
- <style>
- @@media(min-width:768px) {
- .m-header {
- height: 84px;
- display: block !important;
- }
- }
- </style>
- }
- <div class="repository">
- <div class="container">
- <div class="row">
- <div class="col-sm-9 list">
- <div class="product-list">
- <a class="back-nav" href="@Url.Action("Index","Product")">
- <i></i> 返回产品中心
- </a>
- <p>
- <span class="visible-xs-inline-block open-mask">
- @Model.ParentTypeName
- <i></i>
- </span>
- </p>
- <h2 class="list-title"> @Model.ParentTypeName</h2>
- @if (Model.ProductList.Count > 0)
- {
- <ul>
- @foreach (var item in Model.ProductList)
- {
- <li>
- <a href="@Url.Action("Detail", "Product", new { id = item.Id })" target="_blank">
- <div class="img">
- <img src="@item.Image" alt="">
- </div>
- <div class="txt">
- <h2>@item.Title</h2>
- <p>
- @item.Summary
- </p>
- </div>
- </a>
- </li>
- }
- </ul>
- <div class="pageDiv"></div>
- }
- else
- {
- <p style="padding:40px 0;">当前栏目下暂无数据~</p>
- }
- </div>
- </div>
- <div class="col-sm-3 category">
- <h2 class="close-mask visible-xs-inline-block">
- <em>
- <img src="/assets/image/arrow-color-left.png" alt="">
- </em>@Model.ParentTypeName
- </h2>
- <div class="total">
- <p>@Model.ParentTypeName</p>
- </div>
- <ul>
- @foreach (var item in Model.TypeList)
- {
- <li>
- <a class="@(item.Id== Model.TypeId?"cur":"")" href="@Url.Action("List","Product",new { ParentId= Model.ParentId,TypeId=item.Id})">@item.Name</a>
- </li>
- }
- </ul>
- </div>
- </div>
- </div>
- </div>
- @section script{
- <script src="/assets/plugins/page/jquery.page.js"></script>
- <script>
- window.dataMark = "0$15231983314041342$$15231983621571526$";
- if (@Model.TypeId == 95) {
- window.dataMark1 = "0$15231983314041342$$15231983621571526$$15248294492510939$";
- } else {
- window.dataMark1 = "0$15231983314041342$$15231983621571526$$15231984565940625$";
- }
- $(function () {
- $(".open-mask").click(function () {
- $(".category").addClass("showIn")
- })
- $(".close-mask").click(function () {
- $(".category").removeClass("showIn")
- })
- //分页
- var pageSize = 10;
- var rowsCount = @(Model.RowsCount);
- var pageIndex = @(Model.PageIndex);
- $(".pageDiv").createPage({
- pageCount: Math.ceil(rowsCount / pageSize), //总页数
- current: pageIndex, //当前页
- turndown: 'false',
- backFn: function (p) {
- pageIndex = p;
- location.href = "@Url.Action("List", "Product", new { Model.ParentId })&pageIndex=" + pageIndex + "&pageSize=" + pageSize;
- }
- });
- })
- </script>
- }
|