cached-block-3.html 7.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139
  1. {{if $.Data.ModuleShopEnabled}}
  2. <nav class="navbar navbar-expand-lg navbar-light bg-light navbar-cats">
  3. <div class="container">
  4. <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
  5. <span class="navbar-toggler-icon"></span>
  6. </button>
  7. <div class="collapse navbar-collapse" id="navbarSupportedContent">
  8. <ul class="navbar-nav mr-auto">
  9. {{range $.Data.Shop.Categories 0 1}}
  10. {{if .HaveChilds}}
  11. <li class="nav-item dropdown">
  12. <a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">{{.Name}}</a>
  13. <div class="dropdown-menu" aria-labelledby="navbarDropdown">
  14. <a class="dropdown-item" href="{{.Permalink}}">All products</a>
  15. <div class="dropdown-divider"></div>
  16. {{range $index, $subcat := $.Data.Shop.Categories .Id 1}}
  17. <a class="dropdown-item" href="{{$subcat.Permalink}}">{{$subcat.Name}}</a>
  18. {{end}}
  19. </div>
  20. </li>
  21. {{else}}
  22. <li class="nav-item">
  23. <a class="nav-link" href="{{.Permalink}}">{{.Name}}</a>
  24. </li>
  25. {{end}}
  26. {{end}}
  27. </ul>
  28. </div>
  29. </div>
  30. </nav>
  31. {{end}}
  32. {{if $.Data.ModuleBlogEnabled}}
  33. {{if or (eq $.Data.Module "blog") (eq $.Data.Module "blog-category") (eq $.Data.Module "blog-post")}}
  34. <div class="container clear-top pt-4">
  35. <nav aria-label="breadcrumb">
  36. <ol class="breadcrumb mb-0">
  37. {{if eq $.Data.Module "blog"}}
  38. <li class="breadcrumb-item">Blog</li>
  39. {{else}}
  40. <li class="breadcrumb-item"><a href="/blog/">Blog</a></li>
  41. {{end}}
  42. {{if eq $.Data.Module "blog-category"}}
  43. {{if $.Data.Blog.Category.Parent.Parent.Parent.Parent.Parent}}
  44. <li class="breadcrumb-item"><a href="{{$.Data.Blog.Category.Parent.Parent.Parent.Parent.Parent.Permalink}}">{{$.Data.Blog.Category.Parent.Parent.Parent.Parent.Parent.Name}}</a></li>
  45. {{end}}
  46. {{if $.Data.Blog.Category.Parent.Parent.Parent.Parent}}
  47. <li class="breadcrumb-item"><a href="{{$.Data.Blog.Category.Parent.Parent.Parent.Parent.Permalink}}">{{$.Data.Blog.Category.Parent.Parent.Parent.Parent.Name}}</a></li>
  48. {{end}}
  49. {{if $.Data.Blog.Category.Parent.Parent.Parent}}
  50. <li class="breadcrumb-item"><a href="{{$.Data.Blog.Category.Parent.Parent.Parent.Permalink}}">{{$.Data.Blog.Category.Parent.Parent.Parent.Name}}</a></li>
  51. {{end}}
  52. {{if $.Data.Blog.Category.Parent.Parent}}
  53. <li class="breadcrumb-item"><a href="{{$.Data.Blog.Category.Parent.Parent.Permalink}}">{{$.Data.Blog.Category.Parent.Parent.Name}}</a></li>
  54. {{end}}
  55. {{if $.Data.Blog.Category.Parent}}
  56. <li class="breadcrumb-item"><a href="{{$.Data.Blog.Category.Parent.Permalink}}">{{$.Data.Blog.Category.Parent.Name}}</a></li>
  57. {{end}}
  58. <li class="breadcrumb-item">{{$.Data.Blog.Category.Name}}</li>
  59. {{end}}
  60. {{if eq $.Data.Module "blog-post"}}
  61. {{if $.Data.Blog.Post.Category.Id}}
  62. {{if $.Data.Blog.Post.Category.Parent.Parent.Parent.Parent.Parent}}
  63. <li class="breadcrumb-item"><a href="{{$.Data.Blog.Post.Category.Parent.Parent.Parent.Parent.Parent.Permalink}}">{{$.Data.Blog.Post.Category.Parent.Parent.Parent.Parent.Parent.Name}}</a></li>
  64. {{end}}
  65. {{if $.Data.Blog.Post.Category.Parent.Parent.Parent.Parent}}
  66. <li class="breadcrumb-item"><a href="{{$.Data.Blog.Post.Category.Parent.Parent.Parent.Parent.Permalink}}">{{$.Data.Blog.Post.Category.Parent.Parent.Parent.Parent.Name}}</a></li>
  67. {{end}}
  68. {{if $.Data.Blog.Post.Category.Parent.Parent.Parent}}
  69. <li class="breadcrumb-item"><a href="{{$.Data.Blog.Post.Category.Parent.Parent.Parent.Permalink}}">{{$.Data.Blog.Post.Category.Parent.Parent.Parent.Name}}</a></li>
  70. {{end}}
  71. {{if $.Data.Blog.Post.Category.Parent.Parent}}
  72. <li class="breadcrumb-item"><a href="{{$.Data.Blog.Post.Category.Parent.Parent.Permalink}}">{{$.Data.Blog.Post.Category.Parent.Parent.Name}}</a></li>
  73. {{end}}
  74. {{if $.Data.Blog.Post.Category.Parent}}
  75. <li class="breadcrumb-item"><a href="{{$.Data.Blog.Post.Category.Parent.Permalink}}">{{$.Data.Blog.Post.Category.Parent.Name}}</a></li>
  76. {{end}}
  77. <li class="breadcrumb-item"><a href="{{$.Data.Blog.Post.Category.Permalink}}">{{$.Data.Blog.Post.Category.Name}}</a></li>
  78. {{end}}
  79. <li class="breadcrumb-item active">{{$.Data.Blog.Post.Name}}</li>
  80. {{end}}
  81. </ol>
  82. </nav>
  83. </div>
  84. {{end}}
  85. {{end}}
  86. {{if $.Data.ModuleShopEnabled}}
  87. {{if or (eq $.Data.Module "shop") (eq $.Data.Module "shop-category") (eq $.Data.Module "shop-product")}}
  88. <div class="container clear-top pt-4">
  89. <nav aria-label="breadcrumb">
  90. <ol class="breadcrumb mb-0">
  91. {{if eq $.Data.Module "shop"}}
  92. <li class="breadcrumb-item">Shop</li>
  93. {{else}}
  94. <li class="breadcrumb-item"><a href="/shop/">Shop</a></li>
  95. {{end}}
  96. {{if eq $.Data.Module "shop-category"}}
  97. {{if $.Data.Shop.Category.Parent.Parent.Parent.Parent.Parent}}
  98. <li class="breadcrumb-item"><a href="{{$.Data.Shop.Category.Parent.Parent.Parent.Parent.Parent.Permalink}}">{{$.Data.Shop.Category.Parent.Parent.Parent.Parent.Parent.Name}}</a></li>
  99. {{end}}
  100. {{if $.Data.Shop.Category.Parent.Parent.Parent.Parent}}
  101. <li class="breadcrumb-item"><a href="{{$.Data.Shop.Category.Parent.Parent.Parent.Parent.Permalink}}">{{$.Data.Shop.Category.Parent.Parent.Parent.Parent.Name}}</a></li>
  102. {{end}}
  103. {{if $.Data.Shop.Category.Parent.Parent.Parent}}
  104. <li class="breadcrumb-item"><a href="{{$.Data.Shop.Category.Parent.Parent.Parent.Permalink}}">{{$.Data.Shop.Category.Parent.Parent.Parent.Name}}</a></li>
  105. {{end}}
  106. {{if $.Data.Shop.Category.Parent.Parent}}
  107. <li class="breadcrumb-item"><a href="{{$.Data.Shop.Category.Parent.Parent.Permalink}}">{{$.Data.Shop.Category.Parent.Parent.Name}}</a></li>
  108. {{end}}
  109. {{if $.Data.Shop.Category.Parent}}
  110. <li class="breadcrumb-item"><a href="{{$.Data.Shop.Category.Parent.Permalink}}">{{$.Data.Shop.Category.Parent.Name}}</a></li>
  111. {{end}}
  112. <li class="breadcrumb-item">{{$.Data.Shop.Category.Name}}</li>
  113. {{end}}
  114. {{if eq $.Data.Module "shop-product"}}
  115. {{if $.Data.Shop.Product.Category.Id}}
  116. {{if $.Data.Shop.Product.Category.Parent.Parent.Parent.Parent.Parent}}
  117. <li class="breadcrumb-item"><a href="{{$.Data.Shop.Product.Category.Parent.Parent.Parent.Parent.Parent.Permalink}}">{{$.Data.Shop.Product.Category.Parent.Parent.Parent.Parent.Parent.Name}}</a></li>
  118. {{end}}
  119. {{if $.Data.Shop.Product.Category.Parent.Parent.Parent.Parent}}
  120. <li class="breadcrumb-item"><a href="{{$.Data.Shop.Product.Category.Parent.Parent.Parent.Parent.Permalink}}">{{$.Data.Shop.Product.Category.Parent.Parent.Parent.Parent.Name}}</a></li>
  121. {{end}}
  122. {{if $.Data.Shop.Product.Category.Parent.Parent.Parent}}
  123. <li class="breadcrumb-item"><a href="{{$.Data.Shop.Product.Category.Parent.Parent.Parent.Permalink}}">{{$.Data.Shop.Product.Category.Parent.Parent.Parent.Name}}</a></li>
  124. {{end}}
  125. {{if $.Data.Shop.Product.Category.Parent.Parent}}
  126. <li class="breadcrumb-item"><a href="{{$.Data.Shop.Product.Category.Parent.Parent.Permalink}}">{{$.Data.Shop.Product.Category.Parent.Parent.Name}}</a></li>
  127. {{end}}
  128. {{if $.Data.Shop.Product.Category.Parent}}
  129. <li class="breadcrumb-item"><a href="{{$.Data.Shop.Product.Category.Parent.Permalink}}">{{$.Data.Shop.Product.Category.Parent.Name}}</a></li>
  130. {{end}}
  131. <li class="breadcrumb-item"><a href="{{$.Data.Shop.Product.Category.Permalink}}">{{$.Data.Shop.Product.Category.Name}}</a></li>
  132. {{end}}
  133. <li class="breadcrumb-item active">{{$.Data.Shop.Product.Name}} {{$.Data.Shop.Product.Id}}</li>
  134. {{end}}
  135. </ol>
  136. </nav>
  137. </div>
  138. {{end}}
  139. {{end}}