service.vue 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189
  1. <template>
  2. <div class="service">
  3. <div class="container">
  4. <div class="top clearfix">
  5. <div class="title">
  6. <p>Platform service</p>
  7. <h2>平台服务</h2>
  8. </div>
  9. </div>
  10. <ul class="content clearfix list-unstyled">
  11. <li v-for="(data, index) in serviceData" @click="enterModule(index)"
  12. @mouseenter="setStatus('in', index)"
  13. @mouseleave="setStatus('out', index)">
  14. <div>
  15. <img :src="data.imgUrl">
  16. </div>
  17. <div>
  18. <h2>{{data.chinaName}}</h2>
  19. <p>{{data.englishName}}</p>
  20. </div>
  21. </li>
  22. </ul>
  23. </div>
  24. </div>
  25. </template>
  26. <script>
  27. export default {
  28. name: 'PlatformService',
  29. data () {
  30. return {
  31. serviceData: [{
  32. imgUrl: '/images/btbBusiness/customer0.png',
  33. englishName: 'customer service',
  34. chinaName: '客户服务',
  35. enterUrl: 'http://b2b.usoftchina.com/serve'
  36. }, {
  37. imgUrl: '/images/btbBusiness/procurement0.png',
  38. englishName: 'Procurement management',
  39. chinaName: '采购管理',
  40. enterUrl: 'http://b2b.usoftchina.com/#/purc/order'
  41. }, {
  42. imgUrl: '/images/btbBusiness/sales0.png',
  43. englishName: 'Sales management',
  44. chinaName: '销售管理',
  45. enterUrl: 'http://b2b.usoftchina.com/#/sale/order'
  46. }, {
  47. imgUrl: '/images/btbBusiness/subcontract0.png',
  48. englishName: 'subcontract',
  49. chinaName: '委外加工',
  50. enterUrl: 'http://b2b.usoftchina.com/#/sale/maketodo/makeorder'
  51. }, {
  52. imgUrl: '/images/btbBusiness/quality0.png',
  53. englishName: 'Quality Control',
  54. chinaName: '品质管理',
  55. enterUrl: 'http://b2b.usoftchina.com/#/sale/MRB'
  56. }, {
  57. imgUrl: '/images/btbBusiness/financial0.png',
  58. englishName: 'Financial docking',
  59. chinaName: '财务对接',
  60. enterUrl: 'http://b2b.usoftchina.com/#/fa/apBill'
  61. }]
  62. }
  63. },
  64. methods: {
  65. // 鼠标移入更换图标
  66. setStatus: function (type, index) {
  67. switch (index) {
  68. case 0:
  69. this.serviceData[index].imgUrl = type === 'in' ? '/images/btbBusiness/customer1.png' : '/images/btbBusiness/customer0.png'
  70. break
  71. case 1:
  72. this.serviceData[index].imgUrl = type === 'in' ? '/images/btbBusiness/procurement1.png' : '/images/btbBusiness/procurement0.png'
  73. break
  74. case 2:
  75. this.serviceData[index].imgUrl = type === 'in' ? '/images/btbBusiness/sales1.png' : '/images/btbBusiness/sales0.png'
  76. break
  77. case 3:
  78. this.serviceData[index].imgUrl = type === 'in' ? '/images/btbBusiness/subcontract1.png' : '/images/btbBusiness/subcontract0.png'
  79. break
  80. case 4:
  81. this.serviceData[index].imgUrl = type === 'in' ? '/images/btbBusiness/quality1.png' : '/images/btbBusiness/quality0.png'
  82. break
  83. case 5:
  84. this.serviceData[index].imgUrl = type === 'in' ? '/images/btbBusiness/financial1.png' : '/images/btbBusiness/financial0.png'
  85. break
  86. }
  87. },
  88. enterModule: function (index) {
  89. window.location.href = this.serviceData[index].enterUrl
  90. // if (this.user.logged) {
  91. //
  92. // } else {
  93. // this.$router.push('/auth/login')
  94. // }
  95. }
  96. }
  97. }
  98. </script>
  99. <style type="text/scss" lang="scss">
  100. .service{
  101. height: 450px;
  102. .container{
  103. width: 1190px;
  104. margin: 0 auto;
  105. .top{
  106. padding-top:30px;
  107. margin-bottom:50px;
  108. .title{
  109. margin: 0 auto;
  110. text-align: center;
  111. width:215px;
  112. border-bottom:1px solid #ff7070;
  113. p{
  114. margin:0;
  115. font-family: FZLTXHK;
  116. font-size: 14px;
  117. color: #666;
  118. }
  119. h2{
  120. font-size: 32px;
  121. margin:0;
  122. line-height: 46px;
  123. color: #333;
  124. }
  125. &::before{
  126. content: '';
  127. display:block;
  128. position:relative;
  129. left:55px;
  130. top:61px;
  131. width:105px;
  132. height:1px;
  133. background: #00caff;
  134. }
  135. &::after{
  136. content: '';
  137. display:block;
  138. position:relative;
  139. left:55px;
  140. top:4px;
  141. width:105px;
  142. height:1px;
  143. background: #4391f7;
  144. }
  145. }
  146. }
  147. .content{
  148. width: 1096px;
  149. margin: 0 auto;
  150. li{
  151. float: left;
  152. width: 225px;
  153. margin: 0px 170px 0px 2px;
  154. &:nth-child(2), &:nth-child(5) {
  155. width: 295px;
  156. }
  157. &:nth-child(3), &:nth-child(6) {
  158. margin-right: 0;
  159. }
  160. &:nth-child(4), &:nth-child(5), &:nth-child(6) {
  161. margin-top: 82px;
  162. }
  163. &:hover{
  164. cursor: pointer;
  165. }
  166. div{
  167. float: left;
  168. h2{
  169. margin: 0;
  170. position: relative;
  171. top: 10px;
  172. left: 20px;
  173. color: #666;
  174. font-size: 20px;
  175. }
  176. p{
  177. margin: 0px;
  178. position: relative;
  179. top: 12px;
  180. left: 20px;
  181. font-size: 10px;
  182. }
  183. }
  184. }
  185. }
  186. }
  187. }
  188. </style>