invoiceDetail.vue 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201
  1. <template>
  2. <view class="container">
  3. <view class="tui-block__box tui-mtop__20">
  4. <text>发票状态</text>
  5. <text class="tui-color__red">已开票</text>
  6. </view>
  7. <view class="tui-block__box tui-mtop__24">
  8. <view>
  9. <text>订单状态</text>
  10. <text class="tui-color__black">已完成</text>
  11. </view>
  12. <view class="tui-ptop__20">
  13. <text>订单编号</text>
  14. <text class="tui-color__black">109943209010</text>
  15. </view>
  16. <view class="tui-ptop__20">
  17. <text>下单时间</text>
  18. <text class="tui-color__black">2020-01-01 13:18:21</text>
  19. </view>
  20. <view class="tui-ptop__20">
  21. <text>发票类型</text>
  22. <text class="tui-color__black">电子普通发票</text>
  23. </view>
  24. </view>
  25. <view class="tui-block__box tui-mtop__24">
  26. <view class="tui-invoice__box">
  27. <image src="/static/images/mall/invoice_logo.png" class="tui-invoice__logo"></image>
  28. <view class="tui-color__red tui-invoice__title">增值税电子普通发票</view>
  29. </view>
  30. <view class="tui-flex__between tui-ptop__20">
  31. <view>
  32. <text>发票内容</text>
  33. <text class="tui-color__black">商品明细</text>
  34. </view>
  35. <tui-button type="black" plain shape="circle" width="162rpx" height="52rpx" :size="24" @click="view">查看发票</tui-button>
  36. </view>
  37. <view class="tui-ptop__20">
  38. <text>发票抬头</text>
  39. <text class="tui-color__black">个人</text>
  40. </view>
  41. </view>
  42. <view class="tui-btn__box">
  43. <tui-button type="danger" shape="circle" height="88rpx" @click="sendEmail">发送至邮箱</tui-button>
  44. </view>
  45. <tui-modal :show="modal" @cancel="cancel" :custom="true" fadeIn>
  46. <view class="tui-modal-custom">
  47. <view class="tui-prompt-title">请确认邮箱地址</view>
  48. <input placeholder="用来接收电子发票邮件" class="tui-modal-input" :class="{'tui-hidden-input':!modal}" />
  49. <view class="tui-modal__btn">
  50. <view class="tui-box">
  51. <tui-button type="danger" plain shape="circle" height="64rpx" :size="26" @click="cancel">取消</tui-button>
  52. </view>
  53. <view class="tui-box">
  54. <tui-button type="danger" height="64rpx" :size="26" shape="circle" @click="cancel">发送</tui-button>
  55. </view>
  56. </view>
  57. </view>
  58. </tui-modal>
  59. </view>
  60. </template>
  61. <script>
  62. export default {
  63. data() {
  64. return {
  65. modal: false
  66. };
  67. },
  68. methods: {
  69. view() {
  70. uni.previewImage({
  71. urls: ['https://daopic.samcms.com/xm_static/images/img_invoice.jpg']
  72. })
  73. },
  74. sendEmail() {
  75. this.modal = true
  76. },
  77. cancel() {
  78. this.modal = false
  79. }
  80. },
  81. /**
  82. * 页面相关事件处理函数--监听用户下拉动作
  83. */
  84. onPullDownRefresh: function() {
  85. setTimeout(() => {
  86. uni.stopPullDownRefresh()
  87. }, 200);
  88. },
  89. };
  90. </script>
  91. <style>
  92. .container {
  93. width: 100%;
  94. padding: 24rpx 25rpx;
  95. box-sizing: border-box;
  96. }
  97. .tui-block__box {
  98. width: 100%;
  99. padding: 40rpx 25rpx;
  100. box-sizing: border-box;
  101. background-color: #ffffff;
  102. border-radius: 20rpx;
  103. overflow: hidden;
  104. font-size: 24rpx;
  105. color: #999;
  106. box-shadow: 0 15rpx 10rpx -15rpx #efefef;
  107. }
  108. .tui-mtop__24 {
  109. margin-top: 24rpx;
  110. }
  111. .tui-ptop__20 {
  112. padding-top: 20rpx;
  113. }
  114. .tui-color__black {
  115. color: #333;
  116. padding-left: 40rpx;
  117. }
  118. .tui-color__red {
  119. color: #eb0909;
  120. padding-left: 40rpx;
  121. }
  122. .tui-invoice__box {
  123. width: 100%;
  124. position: relative;
  125. font-size: 26rpx;
  126. display: flex;
  127. justify-content: center;
  128. align-items: center;
  129. }
  130. .tui-invoice__logo {
  131. width: 150rpx;
  132. height: 86rpx;
  133. }
  134. .tui-invoice__title {
  135. position: absolute;
  136. left: 50%;
  137. top: 50%;
  138. transform: translate(-50%, -50%);
  139. padding-left: 0 !important;
  140. }
  141. .tui-flex__between {
  142. display: flex;
  143. justify-content: space-between;
  144. align-items: center;
  145. }
  146. .tui-btn__box {
  147. padding: 80rpx 30rpx;
  148. box-sizing: border-box;
  149. }
  150. .tui-modal-custom {
  151. text-align: center;
  152. }
  153. .tui-prompt-title {
  154. padding-bottom: 20rpx;
  155. font-size: 34rpx;
  156. }
  157. .tui-modal-input {
  158. width: 100%;
  159. height: 68rpx;
  160. background-color: #FAFAFA;
  161. margin: 40rpx auto 60rpx;
  162. font-size: 30rpx;
  163. text-align: left;
  164. padding: 0 30rpx;
  165. box-sizing: border-box;
  166. border-radius: 30px;
  167. }
  168. .tui-hidden-input {
  169. /* #ifdef MP-WEIXIN */
  170. width: 0;
  171. /* #endif */
  172. }
  173. .tui-modal__btn {
  174. display: flex;
  175. align-items: center;
  176. justify-content: space-between;
  177. }
  178. .tui-box {
  179. flex: 1;
  180. padding: 0 20rpx;
  181. box-sizing: border-box;
  182. }
  183. </style>