This commit is contained in:
丁杰 2026-06-09 11:34:52 +08:00
parent 128ebf0124
commit b542e85624
1 changed files with 347 additions and 353 deletions

View File

@ -3,38 +3,32 @@
<!-- 订单编号 --> <!-- 订单编号 -->
<view class="orderNumBox"> <view class="orderNumBox">
<view class="order-id white-space-nowrap">订单编号{{ dataItem.number }}</view> <view class="order-id white-space-nowrap">订单编号{{ dataItem.number }}</view>
<view class="stateText" :class="{
stateText2: dataItem.state > 4 && dataItem.state !== 7, //
stateText3: dataItem.state === 7 //
}" v-if="showState">
{{ stateText }}
</view>
<image class="rightArrow" src="/static/images/shop/pintuan/rightArrow.png" v-else
@click="$emit('goOrderDetail', dataItem)"></image>
</view> </view>
<!-- 服务信息区域 --> <!-- 服务信息区域 -->
<view class="service-container" @click="$emit('goOrderDetail', dataItem)" <view class="service-container" @click="$emit('goOrderDetail', dataItem)"
:class="{noFotter:(!dataItem.reservation_time && !dataItem.reserve_end_time) || haveButton }"> :class="{ noFotter: (!dataItem.reservation_time && !dataItem.reserve_end_time) || haveButton }">
<image class="service-img" :src=" dataItem.order_photo ? dataItem.order_photo[0] : JSON.parse(dataItem.photo)[0] <image class="service-img" :src="dataItem.order_photo ? dataItem.order_photo[0] : JSON.parse(dataItem.photo)[0]
" mode="aspectFill"></image> " mode="aspectFill"></image>
<view class="service-info"> <view class="service-info">
<view> <view>
<view class="service-type"> <view class="service-type">
<view class="service-name-type" v-if="dataItem.team_buy_id"> <view class="service-name-type" v-if="dataItem.team_buy_id">
{{getGroupType}} {{ getGroupType }}
</view> </view>
<text class="service-name-text"> <text class="service-name-text">
{{ dataItem.server_title }} {{ dataItem.server_title }}
</text> </text>
</view> </view>
<view class="service-time" v-if="dataItem.add_time && dataItem.state!=7">下单时间: <view class="service-time" v-if="dataItem.add_time && dataItem.state != 7">下单时间:
{{ dataItem.add_time }}</view> {{ dataItem.add_time }}</view>
</view> </view>
<view class="service-price"> <view class="service-price">
<text v-if="dataItem.team_buy_id">{{`团购价: `}}</text>¥<text <text v-if="dataItem.team_buy_id">{{ `团购价: ` }}</text>¥<text style="font-size: 34rpx;">{{
style="font-size: 34rpx;">{{ dataItem.order_money }}</text> dataItem.order_money }}</text>
<text class="service-price-line">{{ dataItem.line_money }}</text> <text class="service-price-line">{{ dataItem.line_money }}</text>
</view> </view>
@ -61,7 +55,7 @@
</template> </template>
<script> <script>
export default { export default {
name: "OrderCard", name: "OrderCard",
props: { props: {
dataItem: { dataItem: {
@ -188,27 +182,27 @@
this.$emit("done"); this.$emit("done");
}, },
}, },
}; };
</script> </script>
<style scoped lang="less"> <style scoped lang="less">
.order-card { .order-card {
padding: 20rpx 30rpx 10rpx 30rpx; padding: 20rpx 30rpx 10rpx 30rpx;
margin: 0rpx 30rpx 20rpx 30rpx; margin: 0rpx 30rpx 20rpx 30rpx;
background-color: #fff; background-color: #fff;
border-radius: 12px; border-radius: 12px;
/* box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); */ /* box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); */
position: relative; position: relative;
} }
/* 订单编号 */ /* 订单编号 */
.order-id { .order-id {
width: 530rpx; width: 630rpx;
font-size: 28rpx; font-size: 28rpx;
color: #333333; color: #333333;
} }
.orderNumBox { .orderNumBox {
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: space-between; justify-content: space-between;
@ -248,38 +242,38 @@
width: 12rpx; width: 12rpx;
height: 24rpx; height: 24rpx;
} }
} }
/* 服务信息容器 */ /* 服务信息容器 */
.service-container { .service-container {
display: flex; display: flex;
padding-bottom: 24rpx; padding-bottom: 24rpx;
border-bottom: 1px solid #f6f5f5; border-bottom: 1px solid #f6f5f5;
} }
.noFotter { .noFotter {
border-bottom: none; border-bottom: none;
padding-bottom: 0rpx; padding-bottom: 0rpx;
} }
/* 服务图片 */ /* 服务图片 */
.service-img { .service-img {
width: 172rpx; width: 172rpx;
height: 168rpx; height: 168rpx;
border-radius: 24rpx; border-radius: 24rpx;
margin-right: 30rpx; margin-right: 30rpx;
flex-shrink: 0; flex-shrink: 0;
} }
/* 服务信息 */ /* 服务信息 */
.service-info { .service-info {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
justify-content: space-between; justify-content: space-between;
} }
.service-price { .service-price {
font-family: DINPro, DINPro; font-family: DINPro, DINPro;
font-weight: 500; font-weight: 500;
font-size: 24rpx; font-size: 24rpx;
@ -296,9 +290,9 @@
margin-left: 10rpx; margin-left: 10rpx;
text-decoration: line-through; text-decoration: line-through;
} }
} }
.service-type { .service-type {
width: 400rpx; width: 400rpx;
font-weight: 500; font-weight: 500;
font-size: 30rpx; font-size: 30rpx;
@ -333,9 +327,9 @@
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
} }
} }
.service-time { .service-time {
font-weight: 400; font-weight: 400;
font-size: 26rpx; font-size: 26rpx;
@ -343,10 +337,10 @@
line-height: 33rpx; line-height: 33rpx;
text-align: left; text-align: left;
font-style: normal; font-style: normal;
} }
/* 时间信息 */ /* 时间信息 */
.time-info { .time-info {
font-size: 30rpx; font-size: 30rpx;
color: #333; color: #333;
margin-bottom: 10rpx; margin-bottom: 10rpx;
@ -403,18 +397,18 @@
text-align: left; text-align: left;
font-style: normal; font-style: normal;
} }
} }
/* 按钮组 */ /* 按钮组 */
.button-group { .button-group {
display: flex; display: flex;
justify-content: flex-end; justify-content: flex-end;
gap: 30rpx; gap: 30rpx;
margin-bottom: 20rpx; margin-bottom: 20rpx;
} }
/* 通用按钮样式 */ /* 通用按钮样式 */
.btn { .btn {
// width: 80rpx; // width: 80rpx;
height: 32rpx; height: 32rpx;
border-radius: 64rpx; border-radius: 64rpx;
@ -422,17 +416,17 @@
background-color: #fff; background-color: #fff;
white-space: nowrap; white-space: nowrap;
margin-top: 40rpx; margin-top: 40rpx;
} }
/* 取消按钮 */ /* 取消按钮 */
.cancel-btn { .cancel-btn {
border: 2rpx solid #979797; border: 2rpx solid #979797;
color: #333333; color: #333333;
} }
/* 接单按钮 */ /* 接单按钮 */
.accept-btn { .accept-btn {
border: 2rpx solid #FF4767; border: 2rpx solid #FF4767;
color: #FF4767; color: #FF4767;
} }
</style> </style>