123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167 |
- <template>
- <view class="item">
- <view class="item-img">
- <img :src=" baseUrl + data.avatar" alt="">
- </view>
- <view class="item-info">
- <view class="item-title-box">
- <view class="item-title">
- <view class="item-name">
- {{ data.name }}
- </view>
- <dict-tag :options="lrr_service_status" :value="data.orderStatus" />
- </view>
- <view class="item-de">
- 服务地址:{{ data.address }}
- </view>
- </view>
- <view class="item-box">
- <view class="item-price"><span class="item-price-yuan">¥</span> {{ data.serviceOnePrice || 0 }}</view>
- <view class="item-btns">
- <up-button type="error" text="查看" size="mini" :custom-style="btn_style"
- @click="onClick(1)"></up-button>
- <up-button type="error" text="沟通" size="mini" :custom-style="btn_style" @click="onClick(2)"></up-button>
- <!-- <up-button type="error" text="上传照片" size="mini" :custom-style="btn_style" @click="onClick(3)"></up-button> -->
- </view>
- </view>
- </view>
- </view>
- </template>
- <script setup>
- import { inject } from 'vue';
- import DictTag from '@/components/DictTag/index.vue'
- import config from '@/config'
- const baseUrl = config.baseUrl
- const props = defineProps({
- data: {
- type: Object,
- default: () => {
- return {}
- }
- },
- });
- const inject_click = inject('onClick');
- const lrr_service_status = inject('lrr_service_status');
- const btn_style = ` width: 120rpx; height: 50rpx; font-size: 24rpx;border-radius: 25rpx;margin-left: 12rpx;`;
- /**
- * 1: 查看
- * 2:沟通
- */
- function onClick(type) {
- inject_click(props.data, type);
- }
- </script>
- <style lang="scss" scoped>
- .item {
- height: 120px;
- border-radius: 10px;
- background: rgba(255, 255, 255, 1);
- padding: 12px;
- margin-bottom: 12px;
- display: flex;
- .item-img {
- width: 96px;
- height: 96px;
- margin-right: 12px;
- image {
- height: 100%;
- width: 100%;
- }
- }
- .item-info {
- flex: 1;
- display: flex;
- flex-direction: column;
- justify-content: space-between;
- .item-title-box {
- .item-title {
- font-size: 14px;
- font-weight: 700;
- letter-spacing: 0px;
- line-height: 20.27px;
- color: rgba(51, 51, 51, 1);
- text-align: left;
- vertical-align: top;
- margin-bottom: 10px;
- display: flex;
- align-content: center;
- justify-content: space-between;
- .item-name {
- flex: 1;
- display: flex;
- // display: -webkit-box;
- // -webkit-box-orient: vertical;
- // -webkit-line-clamp: 1;
- // overflow: hidden;
- // text-overflow: ellipsis;
- // word-break: break-all;
- }
- .item-tag {
- // color: #3c9cff;
- }
- }
- .item-de {
- font-size: 12px;
- font-weight: 500;
- letter-spacing: 0px;
- line-height: 17.38px;
- color: rgba(153, 153, 153, 1);
- text-align: left;
- vertical-align: top;
- display: -webkit-box;
- -webkit-box-orient: vertical;
- -webkit-line-clamp: 2;
- overflow: hidden;
- text-overflow: ellipsis;
- word-break: break-all;
- }
- }
- .item-box {
- display: flex;
- align-content: flex-end;
- justify-content: space-between;
- .item-price {
- font-size: 18px;
- font-weight: 500;
- letter-spacing: 0px;
- line-height: 21.09px;
- color: rgba(246, 74, 31, 1);
- text-align: center;
- vertical-align: top;
- .item-price-yuan {
- font-size: 13px;
- font-weight: 700;
- letter-spacing: 0px;
- line-height: 21.09px;
- color: rgba(246, 74, 31, 1);
- }
- }
- .item-btns {
- display: flex;
- }
- }
- }
- }
- </style>
|