index.htm 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. ##tlayout("www/layout.htm"){
  2. <div class="index-banner swiper-container swiper-container-horizontal">
  3. <div class="swiper-wrapper">
  4. ##for(_item in carousel_list!){
  5. <div class="swiper-slide">
  6. <a href="${_item.url!}" target="_blank" style="width: 100%;">
  7. <img src="${_item.img_url!}" class="img-responsive" style="width: 100%;" />
  8. </a>
  9. </div>
  10. ##}
  11. </div>
  12. <div class="swiper-pagination"></div>
  13. </div>
  14. <section class="container">
  15. <h3 class="template-title text-center">精品模板</h3>
  16. <div class="product-wrapper">
  17. <div class="product-tab">
  18. <ul class="nav nav-pills">
  19. ##if(exist("sid")){
  20. <li role="presentation"><a href="/">全部专题</a></li>
  21. ##}else{
  22. <li role="presentation" class="active"><a href="/">全部专题</a></li>
  23. ##}
  24. ##for(_item in subject_list!){
  25. ##if(exist("sid") && sid==_item.id){
  26. <li role="presentation" class="active"><a href="/index?sid=${_item.id!}">${_item.title!}</a></li>
  27. ##}else{
  28. <li role="presentation"><a href="/index?sid=${_item.id!}">${_item.title!}</a></li>
  29. ##}
  30. ##}
  31. </ul>
  32. </div>
  33. <div class="product-content">
  34. <ul class="product-list row list-unstyled clearfix">
  35. ##for(_item in list!){
  36. <li>
  37. <a href="/diy?id=${_item.id!}" target="_blank">
  38. <img src="${_item.img_url!}" class="img-responsive prduct-img"/>
  39. <div class="product-title">
  40. <div class="title">${_item.title!}</div>
  41. <div class="remark">${_item.remark!}</div>
  42. <div class="fenlei clearfix">
  43. <span>${_item.purpose_title!}</span>
  44. <span>${_item.industry_title!}</span>
  45. <span>${_item.festival_title!}</span>
  46. <span>${_item.style_title!}</span>
  47. <span>${_item.subject_title!}</span>
  48. <span>${_item.bottle_title!}</span>
  49. </div>
  50. <div class="use_number">使用次数:${_item.use_number!}</div>
  51. <span class="btn">在线定制</span>
  52. </div>
  53. </a>
  54. </li>
  55. ##}
  56. </ul>
  57. </div>
  58. </div>
  59. </section>
  60. <script>
  61. var swiper = new Swiper('.swiper-container', {
  62. pagination: '.swiper-pagination',
  63. paginationClickable: true
  64. });
  65. $('.product-list li').hover(function(){
  66. $(this).find('.product-title').stop().fadeIn();
  67. },function(){
  68. $(this).find('.product-title').stop().fadeOut();
  69. });
  70. </script>
  71. ##}