order-alert.vue 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131
  1. <template name="sharealert">
  2. <view class="alert spec" :class="specClass">
  3. <view class="model-warp">
  4. <view class="content" v-if="modelType == 1">
  5. <view class="content-title"></view>
  6. <view class="text-content">
  7. <view class="share">您的分享码:<text class="txt">{{shareCode}}</text></view>
  8. <view class="text">
  9. <text>有效期为24小时。订单分享后若对方无法直接登录小程序查看订单,请提供该分享码给对方,通过输入分享码查看</text>
  10. </view>
  11. </view>
  12. <view class="alert-btn"></view>
  13. </view>
  14. </view>
  15. </view>
  16. </template>
  17. <script>
  18. import { queryOrderShareCode } from "@/api/order.js"
  19. export default{
  20. name:'sharealert',
  21. props:{
  22. modelType:{
  23. type:Number,
  24. default:1
  25. },
  26. orderID:{
  27. type:Number
  28. }
  29. },
  30. data() {
  31. return{
  32. shareCode:'',
  33. }
  34. },
  35. created() {
  36. },
  37. methods:{
  38. hideConfirm(){
  39. this.$parent.isShareModal = false
  40. },
  41. btnConfirm(code){//点击事件
  42. this.$emit('btnConfirm')
  43. }
  44. }
  45. }
  46. </script>
  47. <style lang="scss">
  48. /*弹窗*/
  49. .model-warp.none{
  50. display: none;
  51. }
  52. .model-warp.show{
  53. display: block;
  54. }
  55. .model-warp{
  56. width: 100%;
  57. height: 100%;
  58. background: rgba(0,0,0,0.3);
  59. position: fixed;
  60. top: 0;
  61. left: 0;
  62. z-index: 10000;
  63. transition: all 0.4s;
  64. &.none{
  65. display: none;
  66. }
  67. &.show{
  68. display: block;
  69. }
  70. .content{
  71. width: 540rpx;
  72. min-height: 310rpx;
  73. box-sizing: border-box;
  74. position: absolute;
  75. left: 50%;
  76. top: 50%;
  77. transform: translate(-50%,-50%);
  78. border-radius: 14rpx;
  79. .content-title{
  80. width: 100%;
  81. height: 232rpx;
  82. background: url(https://admin-b.caimei365.com/userfiles/1/images/photo/2020/08/alert%402x.png) no-repeat;
  83. background-size: contain;
  84. }
  85. .text-content{
  86. width: 100%;
  87. min-height: 208rpx;
  88. box-sizing: border-box;
  89. padding:24rpx;
  90. float: left;
  91. background-color: #FFFFFF;
  92. .title{
  93. line-height: 40rpx;
  94. font-size: $font-size-28;
  95. color: $text-color;
  96. text-align: center;
  97. font-weight: bold;
  98. margin-bottom: 36rpx;
  99. }
  100. .share{
  101. line-height: 36rpx;
  102. font-size: $font-size-26;
  103. color: $text-color;
  104. text-align: justify;
  105. margin-top: 22rpx;
  106. font-weight: normal;
  107. .txt{
  108. margin-left: 10rpx;
  109. color: #FF2A2A;
  110. }
  111. }
  112. .text{
  113. line-height: 36rpx;
  114. font-size: $font-size-26;
  115. color: $text-color;
  116. text-align: justify;
  117. margin-top: 22rpx;
  118. }
  119. }
  120. .alert-btn{
  121. width: 80%;
  122. height: 70rpx;
  123. display: flex;
  124. margin: 0 auto;
  125. }
  126. }
  127. }
  128. </style>