| | |
| | | <wd-tag size="small" v-if="item.status === '1'" type="warning">已接单</wd-tag> |
| | | <wd-tag size="small" v-else-if="item.status === '2'" type="primary">维修中</wd-tag> |
| | | <wd-tag size="small" v-else-if="item.status === '3'" type="success">已完成</wd-tag> |
| | | <wd-tag size="small" v-else-if="item.status === '4'" type="default">已评价</wd-tag> |
| | | </view> |
| | | </view> |
| | | </template> |
| | |
| | | </view> |
| | | </view> |
| | | <view> |
| | | <template v-if="item.status === '3'"> |
| | | <template v-if="item.status === '3' || item.status === '4'"> |
| | | <view class="h-full flex flex-col"> |
| | | <wd-button size="small" icon="warn-bold" @click.stop="itemClick(item)"> |
| | | 详情 |
| | | </wd-button> |
| | | <wd-button |
| | | v-if="isRequest" |
| | | class="mt-4" |
| | | size="small" |
| | | icon="edit-outline" |
| | |
| | | type="warning" |
| | | > |
| | | {{ item.fbId == null ? '写评价' : '查看评价' }} |
| | | </wd-button> |
| | | <wd-button |
| | | v-else |
| | | class="mt-4" |
| | | size="small" |
| | | icon="edit-outline" |
| | | @click.stop="goToFeedBack(item)" |
| | | type="warning" |
| | | :disabled="item.fdId == null" |
| | | > |
| | | {{ item.fbId == null ? '暂未评价' : '查看评价' }} |
| | | </wd-button> |
| | | </view> |
| | | </template> |
| | |
| | | const userStore = useUserStore() |
| | | const message = useMessage() |
| | | const toast = useToast() |
| | | defineProps({ |
| | | const defineProps1 = defineProps({ |
| | | item: { |
| | | type: Object as () => RepairResVO, |
| | | required: true |
| | | } |
| | | }) |
| | | required: true, |
| | | }, |
| | | }); |
| | | |
| | | const emit = defineEmits(['click']) |
| | | |
| | | function handleClick(item) { |
| | | emit('click', item) |
| | | } |
| | | // 使用计算属性,判断当前用户是不是请求人 |
| | | const isRequest = computed(() => { |
| | | if (defineProps1.item) { |
| | | console.log('isRequest', defineProps1.item.reqUser === userStore.userInfo.userId) |
| | | return userStore.userInfo.userId === defineProps1.item.reqUser |
| | | } |
| | | return false |
| | | }) |
| | | |
| | | /** |
| | | * 开始维修 |