<template>
	<view class="wrapper">
		<scroll-view scroll-x="true" class="scroll-view">
			<view class="top-menu">
				<view :class="item == tabActive? 'tab active' : 'tab'" v-for="item in tabList" :key="item"
					@click="tabHandle(item)">
					<view class="border"></view>{{item}}
				</view>
			</view>
		</scroll-view>
		
		<!-- 办理订单 -->
		<view class="content-box" v-if="tabActive === '办理订单'">
				<view class="as-layout-horizontal as-gravity-center-start">
					<view class="search-box">
						<image :src="`${$imgUrl}service/icon-search.png`" class="icon"></image>
						<input class="search"  placeholder="请输入车牌号" @input="onKeyInput" />
					</view>
					<view class="search-btn" @click="doSearch">搜索</view>
				</view>
				
				<view class="emptyView" v-if="state.orderList.length === 0" >
					<u-empty text="暂无订单信息" mode="list" />
				</view>
				
				<view class="list" v-else>
					<view :class="item.orderStatus == -1 ? 'item finished' : 'item'" v-for="item in state.orderList" :key="item.id"
						@click="gotoOrderDetails(item)">
						<view class="head">
							<view class="name">
								<image :src="`${$imgUrl}order/icon-star-green.png`" class="icon"></image>
								<text class="title">{{item.productName ?item.productName: ''}}</text>
							</view>
						
							<template v-if="item.orderStatus == -1">
								<view class="status text-orange">已取消</view>
							</template>
							<template v-else>
								<view class="status text-green" v-if="item.orderStep == 4 ">待支付</view>
								<view class="status text-green" v-else-if="item.orderStep == 8">待发货</view>
								<view class="status text-green" v-else-if="item.orderStep == 9">待收货</view>
								<view class="status text-green" v-else-if="item.orderStep == 10">待激活</view>
								<view class="status text-orange" v-else-if="item.orderStep == 11">已完成</view>
								<view class="status text-orange" v-else-if="item.orderStep == 14">已结束</view>
								<view class="status text-green" v-else-if="item.orderStep == 13">退货中</view>
								<view class="status text-green" v-else-if="item.orderStep == 12">换货中</view>
								<view class="status text-green" v-else-if="item.orderStep == 6">审核中</view>
								<view class="status text-green" v-else-if="item.orderStep == 7">审核不通过</view>
								<view class="status text-green" v-else-if="item.orderStep == 15">退款中</view>
								<view class="status text-orange" v-else-if="item.orderStep == 16">退款成功</view>
							</template>
						</view>
						<view class="detail">
							<view class="orders">
								<view class="order-text">
									<text class="type">订单编号：</text>
									<text class="value">{{item.orderId}}</text>
								</view>
								<view class="order-text odd">
									<text class="type">订单类型：</text>
									<text class="value">{{item.orderType}}</text>
								</view>
								<view class="order-text">
									<text class="type">订单车牌号：</text>
									<text class="value">{{item.vehiclePlate}}</text>
								</view>
							</view>
							<view class="money"><text class="cny">￥</text><text class="amount">{{item.amount / 100 ?item.amount / 100: '0.00'}}</text></view>
						</view>
						
						<template v-if="item.orderStatus != -1">
							<!-- 待支付 -->
							<view class="btns" v-if="item.orderStep == 4">
								<view class="btn btn-normal" @click="gotoCancelOrder(item)">取消订单</view>
								<view class="btn btn-primary" @click="gotoOrderDetails(item)">支付</view>
							</view>
							
							<!-- 审核中/审核不通过 -->
							<view class="btns" v-if="item.orderStep == 6 || item.orderStep == 7">
								<view class="btn btn-normal" v-if="item.orderStep == 7" @click="gotoOrderDetails(item)">修改资料</view>
								<view class="btn btn-normal" @click="gotoCancelOrder(item)">取消订单</view>
								<view class="btn btn-primary" @click="gotoOrderDetails(item)">修改地址</view>
							</view>
							
							<!-- 待发货 -->
							<view class="btns" v-else-if="item.orderStep == 8">
								<view class="btn btn-normal" @click="gotoCancelOrder(item)">取消订单</view>
								<view class="btn btn-primary" @click="gotoOrderDetails(item)">修改地址</view>
							</view>
							<!-- 待收货 -->
							<view class="btns" v-else-if="item.orderStep == 9">
								<view class="btn btn-normal" @click="gotoCheckLogistics(item)">查看物流
								</view>
								<view class="btn btn-normal" @click="gotoReturnOrder(item)">申请退货
								</view>
								<view class="btn btn-primary" @click="gotoConfirmReceipt(item)">确认收货
								</view>
							</view>
							<!-- 待激活 -->
							<view class="btns" v-else-if="item.orderStep == 10">
								<view class="btn btn-normal" @click="gotoReturnOrder(item)">申请退货
								</view>
								<view class="btn btn-normal" @click="gotoExchangeOrder(item)">申请换货</view>
								<view class="btn btn-primary" @click="gotoActiveOrder(item)">去激活
								</view>
							</view>
							<!-- 已完成 -->
							<view class="btns" v-else-if="item.orderStep == 11">
								<view class="btn btn-primary" @click="gotoEvaluateOrder(item)">去评价</view>
							</view>
							<!-- 已结束 -->
							<view class="btns" v-else-if="item.orderStep == 14">
								<view class="btn btn-primary" @click.stop="isShow = true">重新激活订单</view>
							</view>
							<!-- 换货中 -->
							<view class="btns" v-else-if="item.orderStep == 12">
								<view class="btn btn-primary" @click="gotoConfirmReceipt(item)">确认收货
								</view>
							</view>
						</template>
					</view>
				</view>
				<u-loadmore  v-if="state.orderList.length > 0" :status="state.loadStatus" :icon-type="state.iconType" :load-text="state.loadText"/>
		</view>
		
		<view class="content-box" v-if="tabActive === '卡退费补领单'" style="margin-top: 30rpx;">
			<view class="list">
				<view class="item">
					<view class="head">
						<view class="name">
							<image :src="`${$imgUrl}user/icon-ETC.png`" class="icon"></image>
							<text class="title m-10">20230010330</text>
							<text class="tag-green">待支付</text>
						</view>
						<view class="status text-black">贵A123456</view>
					</view>
					<view class="detail">
						<view class="orders">
							<view class="order-text">
								<text class="type">补缴单号：</text>
								<text class="value">01872753475754</text>
							</view>
							<view class="order-text odd">
								<text class="type">补缴单生成时间：</text>
								<text class="value">2023-01-12 15:09:18</text>
							</view>
						</view>
					</view>
					<view class="bottom">
						<view class="bottom-left"><text class="tit">欠费金额：￥</text><text class="amount">1200.00</text>
						</view>
						<view class="btns-box">
							<view class="btn btn-primary" @click="$util.navTo(`/pages/order/orderDetail?id=${1111}`)">支付</view>
						</view>

					</view>
				</view>
				
				<view class="item finished">
					<view class="head">
						<view class="name">
							<image :src="`${$imgUrl}user/icon-ETC.png`" class="icon"></image>
							<text class="title m-10">20230010330</text>
							<text class="tag-grey">已支付</text>
						</view>
						<view class="status text-black">贵A123456</view>
					</view>
					<view class="detail">
						<view class="orders">
							<view class="order-text">
								<text class="type">补缴单号：</text>
								<text class="value">01872753475754</text>
							</view>
							<view class="order-text odd">
								<text class="type">补缴单生成时间：</text>
								<text class="value">2023-01-12 15:09:18</text>
							</view>
						</view>
					</view>
					<view class="bottom">
						<view class="bottom-left"><text class="tit">欠费金额：￥</text><text class="amount">1200.00</text>
						</view>
						<view class="btns-box">
							<view class="btn btn-disable">已支付</view>
						</view>

					</view>
				</view>

			</view>

		</view>
		
		<view class="content-box" v-if="tabActive === '储值卡圈存'">
			<view class="search-box">
				<image :src="`${$imgUrl}service/icon-search.png`" class="icon"></image>
				<input class="search" placeholder="储值卡圈存/ETC卡号" />
			</view>
			<view class="search-time">
				<view class="search-time-box" @click="show = true">
					<u-calendar v-model="show" mode="date" @change="changeHandle" max-date="2100-01-01"
						range-bg-color="#00B38B" active-bg-color="#00B38B" range-color="#fff"></u-calendar>
					<view class="show-info">

						<view class="show-text" v-if="chooseDate">
							<text class="date-text text-val">{{chooseDate}}</text>
						</view>
						<view class="show-text" v-else>
							<text class="date-text">圈存时间</text>
						</view>
						<u-icon name="calendar" :custom-style="{color:'#999999', size: '28rpx'}"></u-icon>
					</view>
				</view>
				<view class="search-payment-box" @click="isShowPayment = true">
					<u-picker mode="selector" v-model="isShowPayment" :range="payments" rangeKey="pay"
						@confirm="choosePayment" title="支付方式"></u-picker>
					<view class="show-text" v-if="payText">
						<text class="date-text text-val">{{payText}}</text>
					</view>
					<view class="show-text" v-else>
						<text class="date-text">支付方式</text>
					</view>
					<u-icon name="arrow-down" :custom-style="{color:'#999999', size: '28rpx'}"></u-icon>
				</view>
				<view class="time-btn">查询</view>
			</view>
			<view class="list bg-white">
				<view class="sub-tabs">
					<view class="sub-item active">全部</view>
					<view class="sub-item">半条流水</view>
					<view class="sub-item">已冲正</view>
					<view class="sub-item">圈存成功</view>
					<view class="sub-item">退款中</view>
				</view>
				<view class="item">
					<view class="head">
						<view class="name">
							<image :src="`${$imgUrl}user/icon-ETC.png`" class="icon"></image>
							<text class="title m-10">20230010330</text>
						</view>
						<view class="status text-green">退款中</view>
					</view>
					<view class="detail">
						<view class="orders">
							<view class="order-text">
								<text class="type">圈存单号：</text>
								<text class="value">GZ0000238100101</text>
							</view>
							<view class="order-text odd">
								<text class="type">业务类型：</text>
								<text class="value">储值卡圈存</text>
							</view>
							<view class="order-text">
								<text class="type">支付方式：</text>
								<text class="value">微信支付</text>
							</view>
							<view class="order-text odd">
								<text class="type">充值时间：</text>
								<text class="value">2023-01-08 10:09:23</text>
							</view>
						</view>
						<view class="money"><text class="cny">￥</text><text class="amount">120.99</text></view>
					</view>

					<view class="btns">
						<view class="btn btn-normal" @click="$util.navTo('/pages/order/cardAmountDetail')">查看进度</view>
					</view>
				</view>
				<view class="item">
					<view class="head">
						<view class="name">
							<image :src="`${$imgUrl}user/icon-ETC.png`" class="icon"></image>
							<text class="title m-10">20230010330</text>
						</view>
						<view class="status text-green">半条流水</view>
					</view>
					<view class="detail">
						<view class="orders">
							<view class="order-text">
								<text class="type">圈存单号：</text>
								<text class="value">GZ0000238100101</text>
							</view>
							<view class="order-text odd">
								<text class="type">业务类型：</text>
								<text class="value">储值卡圈存</text>
							</view>
							<view class="order-text">
								<text class="type">支付方式：</text>
								<text class="value">微信支付</text>
							</view>
							<view class="order-text odd">
								<text class="type">充值时间：</text>
								<text class="value">2023-01-08 10:09:23</text>
							</view>
						</view>
						<view class="money"><text class="cny">￥</text><text class="amount">120.99</text></view>
					</view>
					<view class="btns">
						<view class="btn btn-normal" @click="$util.navTo('/pages/order/refund-deposit-card')">申请退款</view>
						<view class="btn btn-primary" @click="$util.navTo('/pages/recharge/recharge')">圈存修复</view>
					</view>
				</view>
				<view class="item">
					<view class="head">
						<view class="name">
							<image :src="`${$imgUrl}user/icon-ETC.png`" class="icon"></image>
							<text class="title m-10">20230010330</text>
						</view>
						<view class="status text-green">已冲正</view>
					</view>
					<view class="detail">
						<view class="orders">
							<view class="order-text">
								<text class="type">圈存单号：</text>
								<text class="value">GZ0000238100101</text>
							</view>
							<view class="order-text odd">
								<text class="type">业务类型：</text>
								<text class="value">储值卡圈存</text>
							</view>
							<view class="order-text">
								<text class="type">支付方式：</text>
								<text class="value">微信支付</text>
							</view>
							<view class="order-text odd">
								<text class="type">充值时间：</text>
								<text class="value">2023-01-08 10:09:23</text>
							</view>
						</view>
						<view class="money"><text class="cny">￥</text><text class="amount">120.99</text></view>
					</view>
					<view class="btns">
						<view class="btn btn-primary" @click="$util.navTo('/pages/recharge/recharge')">圈存修复</view>
					</view>
				</view>
				<view class="item">
					<view class="head">
						<view class="name">
							<image :src="`${$imgUrl}user/icon-ETC.png`" class="icon"></image>
							<text class="title m-10">20230010330</text>
						</view>
						<view class="status text-orange">圈存成功</view>
					</view>
					<view class="detail">
						<view class="orders">
							<view class="order-text">
								<text class="type">圈存单号：</text>
								<text class="value">GZ0000238100101</text>
							</view>
							<view class="order-text odd">
								<text class="type">业务类型：</text>
								<text class="value">储值卡圈存</text>
							</view>
							<view class="order-text">
								<text class="type">支付方式：</text>
								<text class="value">微信支付</text>
							</view>
							<view class="order-text odd">
								<text class="type">充值时间：</text>
								<text class="value">2023-01-08 10:09:23</text>
							</view>
						</view>
						<view class="money"><text class="cny">￥</text><text class="amount">120.99</text></view>
					</view>
					<view class="btns">
						<view class="btn btn-primary" @click="$util.navTo('/pages/order/order-evaluate')">去评价</view>
					</view>
				</view>
				<view class="item finished">
					<view class="head">
						<view class="name">
							<image :src="`${$imgUrl}user/icon-ETC.png`" class="icon"></image>
							<text class="title m-10">20230010330</text>
						</view>
						<view class="status text-orange">退款完成</view>
					</view>
					<view class="detail">
						<view class="orders">
							<view class="order-text">
								<text class="type">圈存单号：</text>
								<text class="value">GZ0000238100101</text>
							</view>
							<view class="order-text odd">
								<text class="type">业务类型：</text>
								<text class="value">储值卡圈存</text>
							</view>
							<view class="order-text">
								<text class="type">支付方式：</text>
								<text class="value">微信支付</text>
							</view>
							<view class="order-text odd">
								<text class="type">充值时间：</text>
								<text class="value">2023-01-08 10:09:23</text>
							</view>
						</view>
						<view class="money"><text class="cny">￥</text><text class="amount">120.99</text></view>
					</view>
					<view class="btns">
						<view class="btn btn-primary" @click="$util.navTo('/pages/order/order-evaluate')">去评价</view>
					</view>
				</view>

			</view>

		</view>

		<view class="content-box" v-if="tabActive === '欠费补缴'" style="margin-top: 30rpx;">
			<view class="list">
				<view class="item">
					<view class="head">
						<view class="name">
							<image :src="`${$imgUrl}user/icon-ETC.png`" class="icon"></image>
							<text class="title m-10">20230010330</text>
							<text class="tag-green">待支付</text>
						</view>
						<view class="status text-black">贵A123456</view>
					</view>
					<view class="detail">
						<view class="orders">
							<view class="order-text">
								<text class="type">补缴单号：</text>
								<text class="value">01872753475754</text>
							</view>
							<view class="order-text odd">
								<text class="type">补缴单生成时间：</text>
								<text class="value">2023-01-12 15:09:18</text>
							</view>
						</view>
					</view>
					<view class="bottom">
						<view class="bottom-left"><text class="tit">欠费金额：￥</text><text class="amount">1200.00</text>
						</view>
						<view class="btns-box">
							<view class="btn btn-primary" @click="$util.navTo(`/pages/order/refund-confirm`)">支付</view>
						</view>
					</view>
				</view>
				<view class="item finished">
					<view class="head">
						<view class="name">
							<image :src="`${$imgUrl}user/icon-ETC.png`" class="icon"></image>
							<text class="title m-10">20230010330</text>
							<text class="tag-grey">已支付</text>
						</view>
						<view class="status text-black">贵A123456</view>
					</view>
					<view class="detail">
						<view class="orders">
							<view class="order-text">
								<text class="type">补缴单号：</text>
								<text class="value">01872753475754</text>
							</view>
							<view class="order-text odd">
								<text class="type">补缴单生成时间：</text>
								<text class="value">2023-01-12 15:09:18</text>
							</view>
						</view>
					</view>
					<view class="bottom">
						<view class="bottom-left"><text class="tit">欠费金额：￥</text><text class="amount">1200.00</text>
						</view>
						<view class="btns-box">
							<view class="btn btn-disable">已支付</view>
						</view>

					</view>
				</view>

			</view>

		</view>

		<view class="content-box" v-if="tabActive === '通行流水'">
			<view class="search-box">
				<image :src="`${$imgUrl}service/icon-search.png`" class="icon"></image>
				<input class="search" placeholder="请输入充车牌/流水编号/出入站名/ETC卡号" />
			</view>
			<view class="search-time">
				<view class="search-time-box" @click="show = true">
					<u-calendar v-model="show" mode="range" @change="changeHandle" max-date="2100-01-01"
						range-bg-color="#00B38B" active-bg-color="#00B38B" range-color="#fff"></u-calendar>
					<view class="show-info2">
						<view class="show-text">
							<text class="date-text" v-if="timeData.startDate">{{timeData.startDate}}</text>
							<text class="date-text" v-else>开始时间</text>
							<text>-</text>
							<text class="date-text" v-if="timeData.endDate">{{timeData.endDate}}</text>
							<text class="date-text" v-else>结束时间</text>
						</view>
						<u-icon name="calendar" :custom-style="{color:'#999999', size: '28rpx'}"></u-icon>
					</view>
				</view>
				<view class="time-btn">查询</view>
			</view>

			<view class="count">
				金额合计：XXXXXX
			</view>
			<view class="list bg-white bg-none">
				<view class="item">
					<view class="head" style="display:block;">
						<view class="head-row">
							<view class="name">
								<text>流水单号：</text>
								<text class="title m-10" style="color: black;">MA89200010</text>
							</view>
							<view class="status" style="color: #999999;">交易金额</view>
						</view>
						<view class="head-row">
							<view class="name">
								<text>ETC卡号：</text>
								<text class="title m-10" style="color: black;">0110200001</text>
							</view>
							<view class="money"><text class="cny">￥</text><text class="amount">120.99</text></view>
						</view>
					</view>
					<view class="detail2">
						<view class="">
							<text>贵阳西</text>
							<text>12:09</text>
							<view class="">
								2023-01-08
							</view>
						</view>
						<view class="">
							<text>XXXXX</text>
							<text>18:52</text>
							<view>
								2023-01-08
							</view>
						</view>

						<view class="indicator">
							<text>粤A12345</text>
							<image :src="`${$imgUrl}order/arrowCard.png`" mode=""></image>
						</view>
					</view>

					<view class="btns">
						<view class="btn btn-primary" @click="$util.navTo('/pages/order/order-cardQuota-apply')">补卡额申请</view>
					</view>
				</view>


				<view class="item">
					<view class="head" style="display:block;">
						<view class="head-row">
							<view class="name">
								<text>流水单号：</text>
								<text class="title m-10" style="color: black;">MA89200010</text>
							</view>
							<view class="status" style="color: #999999;">交易金额</view>
						</view>
						<view class="head-row">
							<view class="name">
								<text>ETC卡号：</text>
								<text class="title m-10" style="color: black;">0110200001</text>
							</view>
							<view class="money"><text class="cny">￥</text><text class="amount">120.99</text></view>
						</view>
					</view>
					<view class="detail2">
						<view class="">
							<text>贵阳西</text>
							<text>12:09</text>
							<view class="">
								2023-01-08
							</view>
						</view>
						<view class="">
							<text>XXXXX</text>
							<text>18:52</text>
							<view class="">
								2023-01-08
							</view>
						</view>

						<view class="indicator">
							<text>粤A12345</text>
							<image :src="`${$imgUrl}order/arrowCard.png`" mode=""></image>
						</view>
					</view>

					<view class="btns">
						<view class="state">
							审核进度：
							<text>审核中</text>
						</view>
						<view class="btn btn-primary" @click="$util.navTo('/pages/order/cardAmountDetail')">查看进度</view>
					</view>
				</view>

				<view class="item">
					<view class="head" style="display:block;">
						<view class="head-row">
							<view class="name">
								<text>流水单号：</text>
								<text class="title m-10" style="color:#999999;">MA89200010</text>
							</view>
							<view class="status" style="color: #999999;">交易金额</view>
						</view>
						<view class="head-row">
							<view class="name">
								<text>ETC卡号：</text>
								<text class="title m-10" style="color: #999999;">0110200001</text>
							</view>
							<view class="money"><text class="cny" style="color: #999999;">￥</text><text class="amount">120.99</text></view>
						</view>
					</view>
					<view class="detail2">
						<view class="" style="color: #999999;">
							<text>贵阳西</text>
							<text>12:09</text>
							<view class="">
								2023-01-08
							</view>
						</view>
						<view class="" style="color: #999999;">
							<text>XXXXX</text>
							<text>18:52</text>
							<view class="">
								2023-01-08
							</view>
						</view>

						<view class="indicator" style="color: #999999;">
							<text style="color: #999999;">粤A12345</text>
							<image :src="`${$imgUrl}order/arrowCard.png`" mode=""></image>
						</view>
					</view>

					<view class="btns">
						<view class="state" style="color: #999999;">
							审核进度：
							<text style="color: #999999;">已完成</text>
						</view>
						<view class="btn btn-primary" @click="$util.navTo('/pages/order/order-evaluate')">去评价</view>
					</view>
				</view>
			</view>

		</view>

		<u-modal v-model="isShow" :show-cancel-button="true" :show-title="false" confirm-text="确认" cancel-text="取消"
			:border-radius="20" content="确认是否重新激活订单" :content-style="contentStyle" :cancel-style="cancelStyle"
			:confirm-style="confirmStyle" @confirm="gotoActiveOrder" >
		</u-modal>
	</view>
</template>

<script lang="ts" setup>
	import {reactive,ref} from "vue";
	import useOrderSkip from "@/composables/order/useOrderSkip";
	
	const contentStyle = ({
		'font-size': '32rpx',
		'color': '#333333',
		'margin': '30rpx auto',
	})
	const cancelStyle = ({
		'width': '187rpx',
		'height': '81rpx',
		'background': '#F7F7F7',
		'margin': '40rpx 29rpx 40rpx 62rpx',
		'border': '1px solid #DCDCDC',
		'border-radius': '40rpx',
		'font-size': '32rpx',
		'color': '#333333',
		'display': 'flex',
		'justify-content': 'center',
		'align-items': 'center'

	})
	const confirmStyle = ({
		'width': '190rpx',
		'height': '80rpx',
		'margin': '40rpx 62rpx 40rpx 0',
		'background': '#00B38B',
		'border-radius': '40rpx',
		'font-size': '32rpx',
		'color': '#ffffff',
		'display': 'flex',
		'justify-content': 'center',
		'align-items': 'center'
	})

	const chooseDate = ref(null)
	const timeData = reactive({ //通行流水-时间参数
		startDate: '',
		endDate: ""
	})
	const tabList = ["办理订单", "卡退费补领单", "储值卡圈存", "欠费补缴", "通行流水"]
	const tabActive = ref("办理订单");
	const show = ref(false);
	const isShow = ref(false);
	const isShowPayment = ref(false)
	const payText = ref(null)
	const payments = reactive([
		{id: 1,pay: '微信'}, 
		{id: 2,pay: '云闪付'}, 
		{id: 3,pay: '账户'},
	]);
	
	const tabHandle = (val) =>{
		tabActive.value = val
	}
	
	// 日期修改
	const changeHandle = (e) =>{
		console.log(e);
		chooseDate.value = e.result
		if (e.startDate) {
			timeData.startDate = e.startDate
			timeData.endDate = e.endDate
		}
	}

	//选择支付方式
	const choosePayment = (e) =>{
		console.log(payments[e]);
		payText.value = payments[e].pay
	}
	
	//办理订单按钮跳转业务逻辑
	const {gotoEditAddress,gotoCancelOrder,gotoEditUserOrUnitInfo,
		gotoConfirmReceipt,gotoCheckLogistics,gotoEvaluateOrder,
		gotoActiveOrder,gotoReturnOrder,gotoExchangeOrder,gotoPay,gotoOrderDetails} = useOrderSkip();
	
</script>
<style lang="scss">
	page {
		background: #eef7f7;
	}
	.content-box{
		padding-bottom: 30rpx;
	}
	
	.search-btn{
		color: white;
		background-color: #00B38B;
		width: 140rpx;
		height: 75rpx;
		line-height: 75rpx;
		font-size: 32rpx;
		border-radius: 40rpx;
		text-align: center;
		margin-right: 30rpx;
		margin-top: 10rpx;
	}
	.search-box {
		margin: 30rpx 30rpx 20rpx 30rpx;
		height: 72rpx;
		height: 81rpx;
		background: #FFFFFF;
		border: 1px solid #DCDCDC;
		border-radius: 40rpx;
		display: flex;
		justify-content: center;
		align-items: center;
		box-sizing: border-box;
		flex: 1;
	}

	.search-box .icon {
		width: 48rpx;
		height: 48rpx;
		margin: 0 20rpx;
	}

	.search-box .search {
		flex: 1;
		margin-right: 20rpx;
		height: 100%;
		padding: 0 10rpx;
		font-size: 28rpx;
		color: #00b38b;

	}

	.scroll-view {
		white-space: nowrap;
		position: sticky;
		top: 0;
		background: #ffffff;
		box-shadow: 0rpx 2rpx 6rpx 0rpx rgba(223, 223, 223, 0.8);
	}

	.top-menu {
		display: flex;
	}

	.top-menu .tab {
		font-size: 26rpx;
		padding: 38rpx 30rpx;
		color: #333;
		position: relative;
	}

	.top-menu .active .border {
		position: absolute;
		width: 70%;
		height: 16rpx;
		background: #00b38b;
		opacity: 0.3;
		bottom: 40rpx;
		z-index: -99;
		left: 15%;
		border-radius: 6rpx;
	}

	.top-menu .active {
		font-weight: bold;
		font-size: 28rpx;
	}

	.top-menu .active::before {
		width: 100%;
		height: 16rpx;
		background: #00b38b;
		opacity: 0.3;
	}

	.search-time {
		display: flex;
		margin: 20rpx 30rpx 48rpx 30rpx;
		justify-content: space-between;

		.time-btn {
			width: 130rpx;
			height: 80rpx;
			background: #00B38B;
			border-radius: 40rpx;
			color: #FFFFFF;
			font-size: 32rpx;
			line-height: 80rpx;
			text-align: center;
		}

		.show-info {
			width: 260rpx;
			height: 80rpx;
			padding: 0 31rpx;
			background: #FFFFFF;
			border: 1px solid #DCDCDC;
			border-radius: 40rpx;
			display: flex;
			justify-content: space-between;
			align-items: center;

			.show-text {
				display: flex;
				align-items: center;
			}

			.date-text {
				color: #999999;
				font-size: 28rpx;
			}

			.text-val {
				color: #333
			}

			.line {
				width: 25rpx;
				height: 1rpx;
				background: #999999;
				margin: 0 24rpx;
			}
		}

		.show-info2 {
			width: 541rpx;
			height: 80rpx;
			padding: 0 31rpx;
			background: #FFFFFF;
			border: 1px solid #DCDCDC;
			border-radius: 40rpx;
			display: flex;
			justify-content: space-between;
			align-items: center;

			.show-text {
				display: flex;
				align-items: center;
				flex: 1;
				justify-content: space-evenly;
			}

			.date-text {
				color: #999999;
				font-size: 28rpx;
			}

			.text-val {
				color: #333
			}

			.line {
				width: 25rpx;
				height: 1rpx;
				background: #999999;
				margin: 0 24rpx;
			}
		}
	}

	.count {
		margin: 0 30rpx 25rpx 30rpx;
		font-size: 28rpx;
		font-family: Noto Sans S Chinese;
		font-weight: 400;
		color: #999999;
		line-height: 36rpx;
	}

	.search-payment-box {
		width: 260rpx;
		height: 80rpx;
		padding: 0 31rpx;
		background: #FFFFFF;
		border: 1px solid #DCDCDC;
		border-radius: 40rpx;
		display: flex;
		justify-content: space-between;
		align-items: center;
		color: #999999;
	}

	.list {
		padding: 0 30rpx;
		display: flex;
		flex-direction: column;
	}

	.bg-white {
		background: #FFFFFF;
		border-radius: 30rpx 30rpx 0 0;
	}
	.bg-white .sub-tabs{
		display: flex;
		justify-content: space-evenly;
		align-items: center;
	}
	.bg-white .sub-item{
		padding: 10rpx 0;
		margin: 20rpx 0 30rpx;
		border-bottom: 6rpx solid #fff;
		font-size: 26rpx;
	}
	.bg-white .active{
		border-bottom: 6rpx solid #00B38B;
		color: #00B38B;
		font-size: 30rpx;
		font-weight: bold;
	}
	.bg-none {
		background: none;
		border-radius: 30rpx 30rpx 0 0;
	}

	.list .item {
		background: #ffffff;
		box-shadow: 0rpx 2rpx 6rpx 0rpx rgba(223, 223, 223, 0.8);
		border-radius: 20rpx;
		box-sizing: border-box;
		display: flex;
		flex-direction: column;
		margin-bottom: 30rpx;
	}

	.list.bg-white .item {
		box-shadow: 0rpx 4rpx 13rpx 3rpx rgba(223, 223, 223, 0.8);
	}

	.list .item .head {
		display: flex;
		justify-content: space-between;
		align-items: center;
		padding: 20rpx 28rpx;
		border-bottom: 1px solid #dcdcdc;
	}

	.list .item .head {
		.head-row {
			display: flex;
			width: 100%;
			justify-content: space-between;
			align-items: center;
		}

		.name {}

		.name>text {
			font-size: 26rpx;
			font-family: Noto Sans S Chinese;
			font-weight: 400;
			color: #999999;
			line-height: 36rpx;
		}
	}

	.list .item .head .icon {
		width: 48rpx;
		height: 48rpx;
	}

	.list .item .head .name {
		display: flex;
		align-items: center;
	}

	.list .text-green {
		font-size: 26rpx;
		color: #00b38b;
	}

	.list .text-orange {
		font-size: 26rpx;
		color: #ff8000;
	}

	.list .text-black {
		font-size: 28rpx;
		color: #333;
		font-weight: 500;
	}

	.list .title {
		font-size: 30rpx;
		color: #333;
	}

	.list .tag-green {
		font-size: 22rpx;
		height: 40rpx;
		line-height: 40rpx;
		padding: 0 12rpx;
		border-radius: 6rpx;
		background: #d9f4ee;
		color: #00b38b;
	}

	.list .tag-grey {
		font-size: 22rpx;
		height: 40rpx;
		line-height: 40rpx;
		padding: 0 12rpx;
		border-radius: 6rpx;
		background: #e8e8e8;
		color: #666;
	}

	.list .detail {
		display: flex;
		justify-content: space-between;
		align-items: center;
		padding: 30rpx 32rpx;
	}

	.list .detail .type {
		font-size: 26rpx;
		color: #999;
	}

	.list .detail .value {
		font-size: 26rpx;
		color: #333;
	}

	.list .finished .detail .value {
		color: #999;
	}

	.list .detail .odd {
		margin: 20rpx 0;
	}

	.list .cny {
		font-size: 26rpx;
		color: #333;
	}

	.list .finished .cny {
		color: #999;
	}

	.list .amount {
		font-size: 40rpx;
		font-weight: bold;
	}

	.list .bottom .amount {
		color: #ff8000;
	}

	.list .finished .amount {
		color: #999;
	}

	.list .btns {
		position: relative;
		display: flex;
		align-items: center;
		justify-content: flex-end;
		border-top: 1px solid #dcdcdc;
		margin: 0 30rpx;
		padding: 20rpx 0;
	}

	.list .bottom {
		display: flex;
		justify-content: space-between;
		align-items: center;
		border-top: 1px solid #dcdcdc;
		margin: 0 30rpx;
		padding: 20rpx 0;
	}

	.list .btn {
		height: 60rpx;
		line-height: 58rpx;
		border-radius: 30rpx;
		padding: 0 24rpx;
		font-size: 26rpx;
		box-sizing: border-box;
		margin-right: 20rpx;
	}



	.list .btns .btn:last-child {
		margin: 0;
	}

	.list .btns .state {
		position: absolute;
		left: 0;
		font-size: 26rpx;
		font-family: Noto Sans S Chinese;
		font-weight: 400;
		color: #999999;
		line-height: 58rpx;

		text {
			font-size: 26rpx;
			font-family: Noto Sans S Chinese;
			font-weight: 400;
			color: #00B38B;
			line-height: 58rpx;
		}
	}

	.list .btn-primary {
		border: 1px solid #00b38b;
		color: #00b38b;
	}

	.list .btn-disable {
		border: 1px solid #999;
		color: #999;

	}

	.list .btn-normal {
		border: 1px solid #dcdcdc;
		color: #333;
	}

	.m-10 {
		margin: 0 10rpx;
	}

	// 
	.detail2 {
		display: flex;
		justify-content: space-between;
		align-items: center;
		padding: 30rpx 32rpx;
		position: relative;

		view {
			text-align: center;

			text {
				display: block;
				margin: 20rpx 0;
			}

			view {
				font-size: 24rpx;
				font-family: Noto Sans S Chinese;
				font-weight: 400;
				color: #999999;
				line-height: 36rpx;

				text {
					margin: 0;

				}
			}
		}

		.indicator {
			position: absolute;
			left: 50%;
			top: 50%;
			transform: translate(-50%, -50%);
			display: flex;
			flex-direction: column;

			text {
				margin: 0;
				font-size: 26rpx;
				font-family: Noto Sans S Chinese;
				font-weight: 400;
				color: #666666;
				line-height: 36rpx;
			}

			image {
				width: 186rpx;
				height: 12rpx;
			}
		}

		.state {
			position: absolute;
			left: 0;
			font-size: 26rpx;
			font-family: Noto Sans S Chinese;
			font-weight: 400;
			color: #999999;
			line-height: 58rpx;
		}
	}
	
	.emptyView{
		margin-top: 120rpx;
	}
</style>
