supplierDetails.vue 7.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337
  1. <template name="supplier">
  2. <!-- 供应商信息 -->
  3. <view class="supplier clearfix">
  4. <view class="product-supplier" @click="goSupplier">
  5. <view class="logo"><img :src="shopData.logo ? shopData.logo : 'http://static-b.caimei365.com/app/img/icon/icon-shoplogo.png'" alt=""></view>
  6. <view class="main">
  7. <view class="name">{{ shopData.name }}</view>
  8. <view class="massgs">
  9. <view class="label">满意度:</view>
  10. <view class="p-stars">
  11. <uni-stars :stars="6" :iconClass="iconClass" :iconColor="iconColor" :fontSize="36" :widthInfo="176"></uni-stars>
  12. </view>
  13. </view>
  14. </view>
  15. </view>
  16. <view class="sup-msg massage-t">
  17. <view class="sup-conte">
  18. <view class="conte-l">
  19. <text class="tit-l">经营范围:</text>
  20. </view>
  21. <view class="conte-r" v-if="shopData.businessScopeArr.length>0">
  22. <text class="age" v-for="(item,idx) in shopData.businessScopeArr" :key="idx">{{item}}</text>
  23. </view>
  24. <view class="conte-r" v-else>
  25. <text class="tit">暂无</text>
  26. </view>
  27. </view>
  28. </view>
  29. <view class="sup-msg massage-t">
  30. <view class="sup-h1">
  31. <text class="line">公司介绍</text>
  32. </view>
  33. <view class="sup-p" :class="[shopData.info == null ? 'center' : '']">
  34. {{shopData.info ? shopData.info : '暂无内容' }}
  35. </view>
  36. </view>
  37. <view class="sup-msg massage-t">
  38. <view class="sup-h1">
  39. <text class="line">主打系列产品说明</text>
  40. </view>
  41. <view class="sup-p" :class="[shopData.productDesc == null ? 'center' : '']">
  42. {{shopData.productDesc == null ? '暂无内容' : shopData.productDesc}}
  43. </view>
  44. </view>
  45. <view class="sup-msg massage-t" v-if="shopData.businessLicense!=null">
  46. <view class="sup-h1">
  47. <text class="line">营业执照</text>
  48. </view>
  49. <view class="sup-img">
  50. <image :src="shopData.businessLicense" mode="aspectFill" @click="previewImg(shopData.businessLicense)"></image>
  51. </view>
  52. </view>
  53. <view class="sup-msg massage-t" v-if="shopData.medicalPracticeLicenseImg1!=null">
  54. <view class="sup-h1">
  55. <text class="line">公司资质</text>
  56. </view>
  57. <view class="sup-imgList clearfix">
  58. <view class="img"><image :src="shopData.medicalPracticeLicenseImg1" mode="" @click="previewImg(shopData.medicalPracticeLicenseImg1)"></image></view>
  59. <view class="img"><image :src="shopData.medicalPracticeLicenseImg2" mode="" @click="previewImg(shopData.medicalPracticeLicenseImg2)"></image></view>
  60. <view class="img"><image :src="shopData.medicalPracticeLicenseImg3" mode="" @click="previewImg(shopData.medicalPracticeLicenseImg3)"></image></view>
  61. </view>
  62. </view>
  63. <view class="sup-msg massage-t" v-if="shopData.certificate!=null">
  64. <view class="sup-h1">
  65. <text class="line">授权牌照</text>
  66. </view>
  67. <view class="sup-img">
  68. <image :src="shopData.certificate" mode="aspectFill" @click="previewImg(shopData.certificate)"></image>
  69. </view>
  70. </view>
  71. </view>
  72. </template>
  73. <script>
  74. import uniGrader from '@/components/uni-grade/uni-grade.vue'
  75. export default{
  76. name:'supplier',
  77. components:{
  78. uniGrader
  79. },
  80. props:{
  81. shopId:{
  82. type:Number
  83. }
  84. },
  85. data() {
  86. return{
  87. shopData:{},
  88. iconClass:'icon-aixin',
  89. iconColor:'#ff9100',
  90. }
  91. },
  92. created() {
  93. this.GetSupplierHomeDeatils(this.shopId)
  94. },
  95. onLoad(){
  96. },
  97. methods:{
  98. previewImg(url){
  99. let mentuzArray = []
  100. mentuzArray.push(url)
  101. uni.previewImage({
  102. urls: mentuzArray,
  103. current: 0
  104. });
  105. },
  106. GetSupplierHomeDeatils(shopId){//供应商详情
  107. this.ShopService.GetSupplierHomeDeatils({supplierId:shopId}).then(response =>{
  108. this.shopData = response.data
  109. console.log(this.shopData)
  110. }).catch(error =>{
  111. this.$util.msg(error.msg,2000)
  112. })
  113. }
  114. },
  115. onShow(){
  116. }
  117. }
  118. </script>
  119. <style lang="scss">
  120. page{
  121. background: #FFFFFF;
  122. }
  123. .supplier{
  124. width: 100%;
  125. .sup-msg{
  126. width: 100%;
  127. padding: 24rpx 0;
  128. .sup-h1{
  129. height: 80rpx;
  130. line-height: 80rpx;
  131. font-size: $font-size-28;
  132. color: $text-color;
  133. text-align: left;
  134. font-weight: bold;
  135. .line{
  136. position: relative;
  137. }
  138. }
  139. }
  140. .product-supplier{
  141. width: 100%;
  142. height: 140rpx;
  143. padding:30rpx 24rpx;
  144. box-sizing: border-box;
  145. background-color: #FFFFFF;
  146. position: relative;
  147. box-sizing: border-box;
  148. .logo{
  149. width: 128rpx;
  150. height: 92rpx;
  151. float: left;
  152. border: 1px solid #efefef;
  153. border-radius: 6rpx;
  154. image{
  155. width: 100%;
  156. height: 100%;
  157. display: block;
  158. border-radius: 6rpx;
  159. }
  160. }
  161. .main{
  162. width: 470rpx;
  163. height: 92rpx;
  164. float: left;
  165. margin-left: 20rpx;
  166. .name{
  167. width: 100%;
  168. line-height: 46rpx;
  169. float: left;
  170. font-size: $font-size-28;
  171. color: $text-color;
  172. float: right;
  173. overflow: hidden;
  174. text-overflow:ellipsis;
  175. white-space: nowrap;
  176. text-align: left;
  177. }
  178. .massgs{
  179. width: 100%;
  180. line-height: 46rpx;
  181. float: left;
  182. font-size: $font-size-24;
  183. color: #999999;
  184. .label{
  185. float: left;
  186. }
  187. .p-stars{
  188. float: left;
  189. margin-left: 20rpx;
  190. }
  191. }
  192. }
  193. }
  194. .massage-t{
  195. width: 702rpx;
  196. padding:0 24rpx;
  197. height: auto;
  198. background: #FFFFFF;
  199. .sup-title{
  200. width: 100%;
  201. height: 40rpx;
  202. margin-top: 24rpx;
  203. text-align: left;
  204. display: inline-block;
  205. line-height: 40rpx;
  206. font-size: $font-size-28;
  207. color: $text-color;
  208. .tit-l{
  209. width: 142rpx;
  210. display: inline-block;
  211. }
  212. }
  213. .sup-stars{
  214. width: 100%;
  215. height: 40rpx;
  216. margin-top: 24rpx;
  217. text-align: left;
  218. display: inline-block;
  219. line-height: 40rpx;
  220. font-size: $font-size-28;
  221. color: $text-color;
  222. .tit-l{
  223. width: 114rpx;
  224. display: inline-block;
  225. text-align: right;
  226. float: left;
  227. }
  228. .p-stars{
  229. float: left;
  230. margin-left: 22rpx;
  231. }
  232. }
  233. .sup-conte{
  234. width: 100%;
  235. margin-top: 24rpx;
  236. .conte-l{
  237. width: 100%;
  238. margin-bottom: 15rpx;
  239. .tit-l{
  240. text-align: left;
  241. display: inline-block;
  242. line-height: 40rpx;
  243. font-size: $font-size-28;
  244. color: $text-color;
  245. font-weight: bold;
  246. }
  247. }
  248. .conte-r{
  249. width: 100%;
  250. .age{
  251. display: inline-block;
  252. padding: 0 20rpx;
  253. background: #86b2fb;
  254. height: 42rpx;
  255. line-height: 42rpx;
  256. text-align: center;
  257. font-size: $font-size-24;
  258. color: #FFFFFF;
  259. border-radius: 6rpx;
  260. margin-right: 24rpx;
  261. margin-bottom: 24rpx;
  262. }
  263. .tit{
  264. font-size: $font-size-28;
  265. color: $text-color;
  266. line-height: 40rpx;
  267. }
  268. }
  269. }
  270. .sup-p{
  271. line-height: 48rpx;
  272. text-align: left;
  273. font-size: $font-size-28;
  274. color: #666666;
  275. text-indent: 40rpx;
  276. &.center{
  277. text-align: center;
  278. }
  279. }
  280. .sup-img{
  281. width: 100%;
  282. height: 542rpx;
  283. padding: 24rpx 0;
  284. image{
  285. width: 100%;
  286. height: 100%;
  287. display: block;
  288. }
  289. }
  290. .sup-imgList{
  291. width: 100%;
  292. height: auto;
  293. padding: 24rpx 0;
  294. .img{
  295. width: 340rpx;
  296. height: 260rpx;
  297. float: left;
  298. margin-right:22rpx;
  299. margin-bottom: 22rpx;
  300. &:nth-child(even){
  301. margin-right: 0;
  302. }
  303. image{
  304. width: 100%;
  305. height: 100%;
  306. display: block;
  307. }
  308. }
  309. }
  310. }
  311. }
  312. </style>