Advertisement
Guest User

Untitled

a guest
Oct 12th, 2017
420
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.71 KB | None | 0 0
  1. @model PrimarkAdmin.WebUI.Logic.MVC.Models.TheHotList.Rows.MoodboardControlRenderingModel
  2. @using Primark.Localization
  3. @using Primark.Sitecore.Models.TheHotList
  4.  
  5. <div class="container-fluid-section moodboard">
  6. <div class="row-section">
  7. <div class="col-lg-4-section col-sm-3-section col-xs-7-section">
  8. @foreach (var item in Model.LeftColumn)
  9. {
  10. if (Model.IsLinked)
  11. {
  12. @DisplayLinkedProductDetails(item);
  13. }
  14. else
  15. {
  16. @DisplayNoLinkedProductDetails(item);
  17. }
  18. }
  19. </div>
  20. <div class="col-lg-4-section col-sm-6-section col-xs-5-section">
  21. @foreach (var item in Model.MiddleColumn)
  22. {
  23. if (Model.IsLinked)
  24. {
  25. @DisplayLinkedProductDetails(item);
  26. }
  27. else
  28. {
  29. @DisplayNoLinkedProductDetails(item);
  30. }
  31. }
  32. </div>
  33. <div class="col-lg-4-section col-sm-3-section col-xs-5-section">
  34. @foreach (var item in Model.RightColumn)
  35. {
  36. if (Model.IsLinked)
  37. {
  38. @DisplayLinkedProductDetails(item);
  39. }
  40. else
  41. {
  42. @DisplayNoLinkedProductDetails(item);
  43. }
  44. }
  45. </div>
  46. </div>
  47. </div>
  48. <div class="c-links-list c-moodboard-links-list">
  49. @foreach (var subcategory in Model.Subcategories)
  50. {
  51.  
  52. <a href="@subcategory.Url" title="@subcategory.Name" class="c-links-list__item c-links-list__item--start"><span class="c-links-list__text">@subcategory.Name</span> <span class="icon-right-open c-links-list__item__arrow"></span></a>
  53. }
  54. </div>
  55.  
  56. @helper DisplayNoLinkedProductDetails(MoodboardContentModel item)
  57. {
  58. <div class="content">
  59. <img src="@item.ImageUrl" alt="@item.ImageAlt" class="img-responsive">
  60. @if (Resources.CountryCurrency == "€")
  61. {
  62. <span class="item-text product-price">
  63. @(Model.NoLinked ? item.PriceInteger : item.ProductInfo.PriceInteger).@(Model.NoLinked ? item.PriceDecimal : item.ProductInfo.PriceDecimal) @Resources.CountryCurrency
  64. </span>
  65. }
  66. else
  67. {
  68. <span class="item-text product-price">
  69. @(Model.NoLinked ? string.Format("{0}{1}", Resources.CountryCurrency, @item.PriceInteger) : string.Format("{0}{1}", Resources.CountryCurrency, @item.ProductInfo.PriceInteger)).@(Model.NoLinked ? item.PriceDecimal : item.ProductInfo.PriceDecimal)
  70. </span>
  71. }
  72. </div>
  73. }
  74.  
  75. @helper DisplayLinkedProductDetails(MoodboardContentModel item)
  76. {
  77. <div class="content">
  78. <a href="@item.ProductInfo.Url" title="@item.ProductInfo.Title">
  79. <img src="@item.ImageUrl" alt="@item.ImageAlt" class="img-responsive">
  80. @if (Resources.CountryCurrency == "€")
  81. {
  82. <span class="product-price">
  83. @item.ProductInfo.PriceInteger
  84. <sup>.@item.ProductInfo.PriceDecimal</sup> @Resources.CountryCurrency
  85. </span>
  86. }
  87. else
  88. {
  89. <span class="product-price">
  90. @string.Format("{0}{1}", Resources.CountryCurrency, @item.ProductInfo.PriceInteger)
  91. <sup>.@item.ProductInfo.PriceDecimal)</sup>
  92. </span>
  93. }
  94. </a>
  95. <button class="button-favourite icon-heart-empty" data-businessid="@item.ProductInfo.BusinessId"></button>
  96. </div>
  97. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement