<template>
     <view class='invoiceRecords'>
        <view class="head-box"></view>
        <Navbar title="开票记录" :autoBack="true" :bgColor="bgColor" leftIconSize="18px" height="100rpx" :leftIconColor="leftIconColor" :titleStyle="{color:fontColor}" />
        <view class="content contentPosition_">
            <view class="info cardStyle_" v-for="(item, index) in list" :key="index">
                <view class="left" v-if="item.noType == 0">
                    <image :src="item.activityList[0].image.split(',')[0]" alt="">
                </view>
				<view class="left" v-if="item.noType == 1">
					<image :src="item.travelList[0].image.split(',')[0]" alt="">
				</view>
                <view class="right">
                    <view class="detailed">
                        <view class="title" v-if="item.noType == 0">{{item.activityList[0].title}}</view>
						 <view class="title" v-if="item.noType == 1">{{item.travelList[0].title}}</view>
                        <view class="date">{{item.createTime}}</view>
						<view class="date">{{item.name}}</view>
                        <view class="address">{{item.emil}}</view>
                    </view>
                    <view class="data">
                        <text>标准票</text>
                        <text>×1</text>
                        <text class="btn">已开票</text>
                    </view>
                </view>
            </view>
        </view>
     </view>
</template>

<script>
import Navbar from '@/pages/components/Navbar.vue'
import { globalMixin } from '../pages/mixins/globalMixin';

export default {
     mixins: [globalMixin],
    components:{
        Navbar
    },
    data() {
        return {
			list:[]
        };
    },
    components: {

    },
    computed: {

    },
    watch: {

    },
    created() {
		
    },
	onShow() {
		console.log("进入了发票管理")
		this.getInvoicePageList();
	},
    mounted() {
		

    },
    methods: {
		getInvoicePageList(){
			this.$api('getInvoicePageList',res=>{
				if(res.code == 200) {
					this.list = res.result.records
				}
			})
		}
    }
};
</script>

<style scoped lang="scss">
.invoiceRecords {
    .info {
        margin: 10rpx 32rpx 0rpx;
        padding: 35rpx 0 35rpx 24rpx;
        border-radius: 26rpx;
        .right {
            .data {
                display: flex;
                justify-content: space-between;
                .btn {
                    background: #381615;
                    color: $uni-color-primary;
                    padding: 10rpx 40rpx;
                    border-radius: 30rpx 0px 0px 30rpx;
                }
            }
        } 
    }
    
}
</style>
