推广小程序前端代码
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.

119 lines
3.5 KiB

7 months ago
7 months ago
6 months ago
7 months ago
6 months ago
7 months ago
6 months ago
6 months ago
6 months ago
6 months ago
6 months ago
7 months ago
7 months ago
6 months ago
7 months ago
6 months ago
7 months ago
6 months ago
7 months ago
6 months ago
7 months ago
7 months ago
7 months ago
7 months ago
6 months ago
7 months ago
6 months ago
7 months ago
6 months ago
7 months ago
6 months ago
7 months ago
  1. <template>
  2. <view class='invoiceRecords'>
  3. <view class="head-box"></view>
  4. <Navbar :title="$t('pages_order.invoice_records.title')" :autoBack="true" :bgColor="bgColor" leftIconSize="18px" height="100rpx" :leftIconColor="leftIconColor" :titleStyle="{color:fontColor}" /><!-- 开票记录 -->
  5. <view class="content contentPosition_">
  6. <view class="info cardStyle_" v-for="(item, index) in list" :key="index">
  7. <view class="left" v-if="item.noType == 0">
  8. <image :src="item.activityList[0] &&
  9. item.activityList[0].image &&
  10. item.activityList[0].image.split(',')[0]" alt=""/>
  11. </view>
  12. <view class="left" v-if="item.noType == 1">
  13. <image :src="item.travelList[0] &&
  14. item.travelList[0].image &&
  15. item.travelList[0].image.split(',')[0]" alt=""/>
  16. </view>
  17. <view class="right">
  18. <view class="detailed">
  19. <view class="title" v-if="item.noType == 0">
  20. {{item.activityList[0] && $ot(item.activityList[0], 'active', 'title')}}
  21. </view>
  22. <view class="title" v-if="item.noType == 1">
  23. {{item.travelList[0] && $ot(item.travelList[0], 'travel', 'title')}}
  24. </view>
  25. <view class="date">{{item.createTime}}</view>
  26. <view class="date"
  27. style="padding-top: 0;">{{item.name}}</view>
  28. <view class="emil">{{item.emil}}</view>
  29. </view>
  30. <view class="data">
  31. <text>{{$t('pages_order.invoice_records.standard_ticket')}}</text><!-- 标准票 -->
  32. <text>×1</text>
  33. <text class="btn">{{ $t(`pages_order.invoice_records.states.${stateKeys[item.state]}`) }}</text>
  34. </view>
  35. </view>
  36. </view>
  37. <uv-load-more :status="uvLoadMore" fontSize="24rpx" dashed line />
  38. </view>
  39. </view>
  40. </template>
  41. <script>
  42. import Navbar from '@/pages/components/Navbar.vue'
  43. import { globalMixin } from '../pages/mixins/globalMixin';
  44. import listMixin from '@/mixins/list.js'
  45. export default {
  46. mixins: [globalMixin, listMixin],
  47. components:{
  48. Navbar
  49. },
  50. data() {
  51. return {
  52. mixinsListApi : 'getInvoicePageList',
  53. state : ['开票中', '已开票', '开票失败'], // 保留原有数组以兼容
  54. stateKeys : ['invoicing', 'invoiced', 'failed'], // 新增状态键数组用于国际化
  55. };
  56. },
  57. components: {
  58. },
  59. computed: {
  60. },
  61. watch: {
  62. },
  63. created() {
  64. },
  65. onShow() {
  66. console.log("进入了发票管理")
  67. },
  68. mounted() {
  69. },
  70. methods: {
  71. getImage(){
  72. return item.image && item.image.split(',')[0]
  73. },
  74. }
  75. };
  76. </script>
  77. <style scoped lang="scss">
  78. .invoiceRecords {
  79. .content{
  80. margin-top: 40rpx;
  81. .title,
  82. .date{
  83. overflow:hidden; //超出的文本隐藏
  84. text-overflow:ellipsis; //溢出用省略号显示
  85. white-space:nowrap; //溢出不换行
  86. width: 370rpx;
  87. }
  88. }
  89. .info {
  90. margin: 10rpx 32rpx 0rpx;
  91. padding: 35rpx 0 35rpx 24rpx;
  92. border-radius: 26rpx;
  93. .left{
  94. flex-shrink: 0;
  95. }
  96. .right {
  97. .data {
  98. padding-top: 10rpx;
  99. display: flex;
  100. justify-content: space-between;
  101. .btn {
  102. background: #381615;
  103. color: $uni-color-primary;
  104. padding: 10rpx 40rpx;
  105. border-radius: 30rpx 0px 0px 30rpx;
  106. }
  107. }
  108. }
  109. }
  110. }
  111. </style>