ExcellentSuppliers.vue 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202
  1. <template>
  2. <div class="container marketing" style="padding-top: 25px;">
  3. <div class="head">
  4. <span class="title">优秀商家</span>
  5. <nuxt-link class="see-more" :to="'/provider/list'" v-if="isShowMore">查看更多</nuxt-link>
  6. </div>
  7. <ul class="list-unstyled list-inline">
  8. <li class="store-box" v-for="(store, index) in stores" :class="{ 'margin-left-zero' : index % 5 == 0}" >
  9. <a :href="'/store/' + store.uuid" target="_blank">
  10. <div class="img"><img :src="store.logoUrl || '/images/store/common/default.png'"/></div>
  11. <div class="content">
  12. <div class="name" title="store.storeName">
  13. <span>{{store.storeName}}</span>
  14. </div>
  15. <div class="description">
  16. 企业介绍:<span>{{store.enterprise.description || '暂无企业介绍'}}</span>
  17. </div>
  18. </div>
  19. </a>
  20. </li>
  21. </ul>
  22. </div>
  23. </template>
  24. <script>
  25. export default {
  26. name: 'excellent-suppliers',
  27. props: ['isShowMore'],
  28. computed: {
  29. stores () {
  30. return this.$store.state.provider.storeCms.recommendStore.data
  31. }
  32. }
  33. }
  34. </script>
  35. <style scoped>
  36. .marketing {
  37. width: 1190px;
  38. padding: 0px;
  39. }
  40. .marketing .store-box {
  41. width: 220px;
  42. height: 210px;
  43. border: 1px solid #D6D3CE;
  44. margin-left: 25px;
  45. margin-bottom: 22px;
  46. overflow: hidden;
  47. }
  48. .margin-left-zero {
  49. margin-left: 0px !important;
  50. }
  51. .marketing ul.list-inline {
  52. margin-left: 0px;
  53. }
  54. .marketing .list-inline>li.store-box {
  55. padding-right: 0;
  56. padding-left: 0;
  57. margin-right: -3px;
  58. }
  59. .marketing .list-inline>li:last-child {
  60. margin-right: 0;
  61. }
  62. .marketing .see-more {
  63. float: right;
  64. width: 70px;
  65. height: 26px;
  66. border: 1px solid #d6d3ce;
  67. color: #214797;
  68. font-family: "Microsoft Yahei", "微软雅黑";
  69. font-size: 14px;
  70. line-height: 26px;
  71. padding-left: 6px;
  72. margin-top: 20px;
  73. border-radius: 3px;
  74. }
  75. .marketing .see-more:hover{
  76. background: #5078cb;
  77. color: #fff;
  78. }
  79. .marketing .see-more:hover {
  80. cursor: pointer;
  81. }
  82. .marketing .title {
  83. font-size: 24px;
  84. line-height: 60px;
  85. height: 60px;
  86. font-weight: inherit;
  87. }
  88. li.store-box:hover {
  89. border-color: #1162A4;
  90. }
  91. .store-box a {
  92. text-decoration: none;
  93. display: block;
  94. text-align: center;
  95. width: 220px;
  96. height: 210px;
  97. }
  98. .store-box a .description {
  99. text-align: left;
  100. }
  101. .store-box a:hover {
  102. text-decoration: none;
  103. }
  104. .store-box img {
  105. max-height: 80px;
  106. max-width: 220px;
  107. margin-top: 0;
  108. }
  109. .store-box .content {
  110. margin: 0 12px;
  111. padding: 5px;
  112. height: 103px;
  113. overflow: hidden;
  114. text-overflow: ellipsis;
  115. white-space: nowrap;
  116. word-break: break-all;
  117. }
  118. .store-box .name {
  119. font-size: 16px;
  120. color: #383939;
  121. text-align: left;
  122. /*width: 200px;*/
  123. height: 30px;
  124. font-weight: 600;
  125. margin: 10px 0 5px 0;
  126. display: block;
  127. white-space: nowrap;
  128. overflow: hidden;
  129. text-overflow: ellipsis;
  130. }
  131. .store-box .subject, .store-box .description {
  132. margin-bottom: 5px;
  133. /*width: 200px;*/
  134. height: 35px;
  135. font-size: 12px;
  136. color: #797979;
  137. line-height: 18px;
  138. white-space: nowrap;
  139. overflow: hidden;
  140. text-overflow: ellipsis;
  141. }
  142. .store-box .description{
  143. overflow:hidden;
  144. text-overflow:ellipsis;
  145. display:-webkit-box;
  146. -webkit-box-orient:vertical;
  147. -webkit-line-clamp: 4;
  148. }
  149. .store-box .description span {
  150. word-break: break-all;
  151. width: 204px;
  152. display: inline;
  153. white-space: pre-wrap;
  154. word-wrap : break-word ;
  155. overflow: hidden;
  156. text-overflow: ellipsis;
  157. }
  158. .store-index-top {
  159. height: 360px;
  160. }
  161. .store-index-top-left {
  162. width: 240px;
  163. float: left;
  164. display: inline-block;
  165. }
  166. .store-index-top-center {
  167. width: 670px;
  168. display: inline-block;
  169. float: left;
  170. border: 1px solid #D6D3CE;
  171. }
  172. .store-index-top-right {
  173. width: 280px;
  174. float: left;
  175. display: inline-block;
  176. }
  177. .store-box .img{
  178. margin-top: 5px;
  179. width: 220px;
  180. height: 80px;
  181. display: inline-block;
  182. overflow: hidden;
  183. line-height: 80px;
  184. text-align: center;
  185. }
  186. </style>