铝交易,微信公众号
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

88 lines
1.6 KiB

6 months ago
5 months ago
6 months ago
5 months ago
6 months ago
5 months ago
6 months ago
6 months ago
  1. <template>
  2. <view class="top-bar">
  3. <!--左边-->
  4. <view class="titleCls">
  5. <view>
  6. <img src="../../static/image/cart/1.png" style="width:100%;height:100%;">
  7. </view>
  8. <span class="text"> {{ $t('pageTitle.proName') }}</span>
  9. </view>
  10. <!--右边-->
  11. <view v-if="showRight == '1'" @click="switchIdentity" class="change">
  12. {{ $t('pages.index.index.purchaser') }}
  13. </view>
  14. </view>
  15. </template>
  16. <script>
  17. import {mapGetters} from 'vuex'
  18. export default {
  19. props: {
  20. showRight: {
  21. default: '0',
  22. type: String,
  23. }
  24. },
  25. mounted() {
  26. console.log(this.$store.state, "this.$store.state")
  27. },
  28. data() {
  29. return {
  30. }
  31. },
  32. computed: {
  33. ...mapGetters(['userShop']),
  34. },
  35. methods: {
  36. // 切换身份
  37. switchIdentity() {
  38. uni.navigateTo({
  39. url: '/pages_order/auth/selectionIdentity'
  40. })
  41. }
  42. ,
  43. }
  44. }
  45. </script>
  46. <style lang="scss" scoped>
  47. // 顶部栏
  48. .top-bar {
  49. display: flex;
  50. justify-content: space-between;
  51. height: 120rpx;
  52. background-color: $uni-color;
  53. .titleCls {
  54. display: flex;
  55. padding: 20rpx 10rpx;
  56. .text {
  57. display: flex;
  58. justify-content: center;
  59. align-items: center;
  60. font-size: 30rpx;
  61. color: #FFFFFF;
  62. margin-left: 20rpx;
  63. }
  64. }
  65. .change {
  66. display: flex;
  67. align-items: center;
  68. justify-content: center;
  69. width: 30%;
  70. height: 70rpx;
  71. border-radius: 40rpx;
  72. color: white;
  73. font-size: 28rpx;
  74. margin: 20rpx 10rpx 0 0;
  75. background: $uni-color;
  76. border: 1px solid #757986;
  77. //margin-top: 20rpx;
  78. border-radius: 40rpx;
  79. }
  80. }
  81. </style>