Browse Source

Merge branch 'master' of http://175.178.51.79:3000/hly/pet-front-order

# Conflicts:
#	manifest.json
#	store/modules/user.js
#	utils/getUrl.js
master
主管理员 1 week ago
parent
commit
4b1b81275b
16 changed files with 128 additions and 178 deletions
  1. +12
    -0
      api/order/order.js
  2. +0
    -0
      doc/profile.jpg
  3. +13
    -5
      pages/companionPetList/companionPetInfo.vue
  4. +6
    -2
      pages/companionPetList/companionPetList.vue
  5. +2
    -4
      pages/index.vue
  6. +1
    -1
      pages/newOrder/confirmOrder.vue
  7. +11
    -0
      pages/newOrder/serviceNew.vue
  8. +1
    -0
      pages/newOrder/serviceNew2.vue
  9. +2
    -2
      pages/personalCenter/index.vue
  10. +0
    -1
      pages_order/components/order/ServiceAddress.vue
  11. +3
    -3
      pages_order/components/order/ServiceRemarks.vue
  12. +0
    -42
      pages_order/order/AppletComment.java
  13. +0
    -109
      pages_order/order/orderDetail.json
  14. +28
    -1
      pages_order/order/orderDetail.vue
  15. +40
    -4
      pages_order/order/orderList.vue
  16. +9
    -4
      pages_order/order/payOrderSuccessful.vue

+ 12
- 0
api/order/order.js View File

@ -147,3 +147,15 @@ export const orderCancel = (data) => {
// 再次支付订单
export const orderPay = (data) => {
return request({
url: '/applet/mall/order/orderPay',
headers: {
isToken: true
},
method: "POST",
data
})
}

static/images/profile.jpg → doc/profile.jpg View File


+ 13
- 5
pages/companionPetList/companionPetInfo.vue View File

@ -22,7 +22,7 @@
style="height: 40rpx;"></image> -->
</view>
</view>
<view class="companion-info-right" @click="onClickFav">
<!-- <view class="companion-info-right" @click="onClickFav">
<view v-if="collect">
<uni-icons type="star-filled" size="18" color="#FFB13F"></uni-icons>
<text style="font-size: 16px; color: #FFB13F; margin-left: 6rpx;">已收藏</text>
@ -31,7 +31,7 @@
<uni-icons type="star" size="18" color="#7D8196"></uni-icons>
<text style="font-size: 16px; color: #7D8196; margin-left: 6rpx;">收藏</text>
</view>
</view>
</view> -->
</view>
</view>
<view class="companion-info-des">
@ -282,9 +282,9 @@
{{item.serviceTime}}
</view>
</view>
<view class="service-record-info-4" style="width: 100%;">
<view class="service-record-info-4" style="width: 100%;" v-if="item.petName">
<view class="ellipsis" style="max-width: 225px;">
宠物{{item.petName}}
宠物{{ item.petName }}
</view>
</view>
</view>
@ -294,7 +294,9 @@
</view>
<view class="service-record-pet-images">
<view v-for="(img,index) in item.images" :key="index">
<image class="service-record-pet-images-item" slot='cover' :src="img">
<image
@click="previewImage(item.images, index)"
class="service-record-pet-images-item" slot='cover' :src="img">
</image>
</view>
</view>
@ -508,6 +510,12 @@
url: `/pages/newOrder/serviceNew2?userName=${this.companionInfo.name}&servicerId=${this.companionInfo.id}`,
});
},
previewImage(urls, current){
uni.previewImage({
current,
urls
})
},
}
}
</script>


+ 6
- 2
pages/companionPetList/companionPetList.vue View File

@ -3,7 +3,7 @@
<view class="card-container">
<view class="float-button">
<image @click="changeOrderType" style="width: 112rpx; height: 112rpx;" slot='cover'
src="https://catmdogf.oss-cn-shanghai.aliyuncs.com/CMDF/front/petServiceOrder/SystemOrderCircle.png">
src="https://catmdogf.oss-cn-shanghai.aliyuncs.com/CMDF/front/petServiceOrder/SystemOrderCircle.png"/>
</view>
<view>
<view class="top-select">
@ -541,11 +541,15 @@
.personal-name {
color: #333;
font-size: 32rpx;
font-size: 28rpx;
// line-height: 32rpx;
margin-right: 10rpx;
font-weight: 900;
font-style: normal;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
max-width: 200rpx;
}
.personal-star {


+ 2
- 4
pages/index.vue View File

@ -957,11 +957,8 @@
if (!getToken() || !getOpenIdKey()) {
this.login()
} else {
this.getCouponListAuth()
}
this.getCouponListAuth()
//
this.getCouponListNoAuth()
// 使
this.$store.commit('setPosition', {
@ -1116,6 +1113,7 @@
justify-content: space-between;
align-items: center;
height: 60px;
font-size: 24rpx;
.card-content {
width: 77%;


+ 1
- 1
pages/newOrder/confirmOrder.vue View File

@ -738,7 +738,7 @@
totalPrice: 0,
needPreFamiliarize: []
}
uni.navigateTo({
uni.reLaunch({
url: '/pages_order/order/payOrderSuccessful'
// url: '/pages/details/successful'
});


+ 11
- 0
pages/newOrder/serviceNew.vue View File

@ -28,6 +28,17 @@
</view>
</view>
</view>
<view class="order-type-select" v-if="buyInfo.teacher">
<view class="order-type-title">
<image style="width: 40rpx; height: 40rpx;margin-right: 10rpx;" slot='cover' src="https://catmdogf.oss-cn-shanghai.aliyuncs.com/CMDF/front/petServiceOrder/OrderIcon.png">
</image>
<!-- <image style="width: 32rpx; height: 32rpx; margin-right: 10rpx;" src="https://catmdogf.oss-cn-shanghai.aliyuncs.com/CMDF/front/petServiceOrder/SystemOrderCircle.png"></image> -->
下单方式指定喂养员 - <text style="color: #999;font-size: 26rpx;">{{buyInfo.teacher.userName}}</text>
</view>
</view>
<uni-popup ref="companionInfoPopup" type="center">
<view class="companion-info-popup">


+ 1
- 0
pages/newOrder/serviceNew2.vue View File

@ -18,6 +18,7 @@
</text>
</view>
</view>
<view>
<uni-card padding=0 :is-shadow="false">
<view class="service-new-title" slot="title">


+ 2
- 2
pages/personalCenter/index.vue View File

@ -691,10 +691,10 @@
.personal-functions-content{
width: 100%;
display: flex;
justify-content: space-between;
// justify-content: space-between;
align-items: center;
flex-wrap: wrap;
gap: 30rpx 0;
gap: 34rpx 0;
.personal-function{
width: 24%;
display: flex;


+ 0
- 1
pages_order/components/order/ServiceAddress.vue View File

@ -54,7 +54,6 @@
.address-content {
padding: 20rpx;
background-color: #FFF9EF;
border-radius: 10rpx;
}


+ 3
- 3
pages_order/components/order/ServiceRemarks.vue View File

@ -14,9 +14,9 @@
<!-- 是否提前熟悉 -->
<view class="remarks-item advance-familiar">
<text class="item-label">是否提前熟悉</text>
<view class="checkbox-container" v-if="remarks.isAdvanceFamiliar">
<!-- <view class="checkbox-container" v-if="remarks.isAdvanceFamiliar">
<uv-icon name="checkmark" color="#FFAA48" size="36"></uv-icon>
</view>
</view> -->
</view>
<!-- 价格说明 -->
@ -66,7 +66,7 @@
type: Object,
default: () => ({
keyHandoverMethod: '存于快递柜',
isAdvanceFamiliar: true,
isAdvanceFamiliar: false,
priceInfo: '价格40元/次',
serviceContent: '服务内容: 购买此服务后,伴宠师将在您需要前,按照约定时间提前上门为您照顾宠物',
serviceCondition: '服务保障: 购买此服务后,平台支付在提前熟悉店,上门服务第一天前,充电由客服联系您预约一次',


+ 0
- 42
pages_order/order/AppletComment.java View File

@ -1,42 +0,0 @@
package com.ruoyi.model.domain;
import com.baomidou.mybatisplus.annotation.TableField;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
/**
* 用户评价对象 applet_comment
*
* @author ruoyi
* @date 2025-03-28
*/
public class AppletComment extends BaseEntity
{
private static final long serialVersionUID = 1L;
/** 唯一标识 */
private Long id;
/** 评价内容 */
@Excel(name = "评价内容")
private String comment;
/** 满意度 */
@Excel(name = "满意度")
private Long satisfaction;
/** 关联评价人员ID */
@Excel(name = "关联评价人员ID")
private Long user1Id;
/** 关联服务人员ID */
@Excel(name = "关联服务人员ID")
private Long user2Id;
/** 删除标识 */
private Integer delFlag;
}

+ 0
- 109
pages_order/order/orderDetail.json View File

@ -1,109 +0,0 @@
{
"orderId": 6278884034316288,
"payId": 6278884034316289,
"orderSn": "250418-6278884034316288",
"memberId": 211,
"totalAmount": 71.25,
"payAmount": 71.25,
"status": 4,
"aftersaleStatus": 1,
"orderItemList": [{
"createBy": 211,
"createTime": "2025-04-18 22:26:50",
"updateBy": null,
"updateTime": null,
"id": 6278884043425792,
"orderId": 6278884034316288,
"orderServiceId": 6278884036069376,
"productId": 63,
"outProductId": "P001",
"skuId": 404,
"outSkuId": null,
"productSnapshotId": null,
"skuSnapshotId": null,
"pic": "https://catmdogf.oss-cn-shanghai.aliyuncs.com/2024/01/08ba3980c107c2472397b13ef9769257e1陪玩.png",
"productName": "专业遛狗",
"salePrice": 75.00,
"purchasePrice": null,
"quantity": 1,
"productCategoryId": 76,
"spData": "{\"时间\":\"60\"}"
}],
"orderServiceList": [{
"createBy": 211,
"createTime": "2025-04-18 22:26:50",
"updateBy": null,
"updateTime": null,
"id": 6278884036069376,
"orderId": 6278884034316288,
"pet": null,
"serviceFrequency": null,
"serviceDate": "2025-04-30",
"serviceTimeFirst": null,
"serviceTimeSecond": null,
"delFlag": 0,
"petId": 177,
"expectServiceTime": "MORNING",
"feedCount": null,
"petVo": {
"createBy": null,
"createTime": null,
"updateBy": null,
"updateTime": null,
"id": 177,
"name": "1",
"petType": "cat",
"gender": "男生",
"birthDate": "2025-04",
"remark": "",
"photo": "https://cdn.catmdogd.com/2025/04/188453a042e71a4617b02121d1d9a580c7t92DaD6zscoI266f52064207b09da62f45b9b38e5bf3.png",
"breed": "重点色短毛猫",
"bodyType": "小型(<10 KG)",
"personality": ["友善热情", "粘人乖巧"],
"vaccineStatus": "每年都免疫",
"sterilization": "已绝育",
"dewormingStatus": "未驱虫",
"doglicenseStatus": "",
"healthStatus": ["身体健康,无异常"],
"owner": "211"
},
"pets": null
}],
"service": null,
"note": null,
"deliverySn": null,
"createTime": "2025-04-18 22:26:49",
"paymentTime": null,
"receiverName": "1",
"receiverPhone": "13055015802",
"receiverProvince": "",
"receiverCity": "湖南省湘潭市雨湖区雨湖路272号湘潭市雨湖区人民政府",
"receiverDistrict": "",
"receiverDetailAddress": "1",
"timeToPay": null,
"staffId": null,
"petVOList": [{
"createBy": null,
"createTime": null,
"updateBy": null,
"updateTime": null,
"id": 177,
"name": "1",
"petType": "cat",
"gender": "男生",
"birthDate": "2025-04",
"remark": "",
"photo": "https://cdn.catmdogd.com/2025/04/188453a042e71a4617b02121d1d9a580c7t92DaD6zscoI266f52064207b09da62f45b9b38e5bf3.png",
"breed": "重点色短毛猫",
"bodyType": "小型(<10 KG)",
"personality": ["友善热情", "粘人乖巧"],
"vaccineStatus": "每年都免疫",
"sterilization": "已绝育",
"dewormingStatus": "未驱虫",
"doglicenseStatus": "",
"healthStatus": ["身体健康,无异常"],
"owner": "211"
}],
"teacherId": null,
"companionLevel": null
}

+ 28
- 1
pages_order/order/orderDetail.vue View File

@ -141,12 +141,39 @@
console.error('解析商品附加数据失败', e);
}
//
const pet = data.petVOList && data.petVOList[index] ? {
name: data.petVOList[index].name,
avatar: data.petVOList[index].photo
} : null;
//
const customServices = [
// {
// name: '',
// price: 50,
// quantity: 2
// },
// {
// name: '',
// price: 100,
// quantity: 1
// },
// {
// name: '',
// price: 80,
// quantity: 1
// }
];
return {
id: index + 1,
name: item.productName,
price: item.salePrice,
quantity: item.quantity,
customServices: []
pet: pet ? pet.name : null,
petAvatar: pet ? pet.avatar : null,
customServices: customServices
};
}),


+ 40
- 4
pages_order/order/orderList.vue View File

@ -72,12 +72,15 @@
<!-- <view class="action-btn pay-btn" v-if="order.status == 1 || order.status == 2" @click="modifyOrder(order)">
<text>修改订单</text>
</view> -->
<view class="action-btn pay-btn" v-if="order.status == 4" @click="goToReview(order)">
<view class="action-btn pay-btn" v-if="order.status == 3" @click="goToReview(order)">
<text>去评价</text>
</view>
<view class="action-btn pay-btn" v-if="order.status == 3" @click="handleReorder(order)">
<text>再来一单</text>
</view>
<view class="action-btn pay-btn" v-if="order.status == 2" @click="handleReorder(order)">
<text>查看服务记录</text>
</view>
</view>
</view>
@ -116,7 +119,8 @@
// getOrderList
} from "@/api/system/user.js"
import {
getOrderList
getOrderList,
orderPay
} from "@/api/order/order.js"
import {
getOpenIdKey
@ -161,6 +165,7 @@
loading: false,
refreshing: false,
currentOrder: null,
isPaying : false,
// API
exampleData: [{
id: '1',
@ -232,10 +237,41 @@
//
goToPay(orderId) {
uni.navigateTo({
url: `/pages/details/order?id=${orderId}`
orderPay({
orderId: orderId
}).then(res => {
this.pay(res.data)
}).catch(err => {
console.log(err);
});
},
pay(params) {
if (this.isPaying) {
return;
}
this.isPaying = true
uni.requestPayment({
provider: 'wxpay',
timeStamp: params.timeStamp,
nonceStr: params.nonceStr,
package: params.package_,
signType: params.signType,
paySign: params.paySign,
success: (res) => {
this.$modal.showToast('支付成功')
this.getOrderList()
},
fail: (err) => {
this.loading = false
console.log('支付失败', err)
this.$modal.showToast('支付失败')
},
complete: () => {
this.loading = false
this.isPaying = false
}
})
},
//
goToReview({teacherId, orderId}) {


+ 9
- 4
pages_order/order/payOrderSuccessful.vue View File

@ -29,7 +29,7 @@
<text class="item-title">完善服务档案</text>
<text class="item-desc">请上传宠物喂养要求及用品摆放位置</text>
</view>
<view class="item-action">
<view class="item-action" @click="toPath('/pages/personalCenter/service')">
<text class="action-btn">去完善</text>
</view>
</view>
@ -42,7 +42,7 @@
<text class="item-title">完善门锁信息</text>
<text class="item-desc">请上传门锁及相应密码要求</text>
</view>
<view class="item-action">
<view class="item-action" @click="toPath('/pages/personalCenter/lock')">
<text class="action-btn">去完善</text>
</view>
</view>
@ -81,6 +81,11 @@
url: "/pages/index"
});
},
toPath(url){
uni.navigateTo({
url
})
},
}
}
</script>
@ -124,8 +129,8 @@
.item-text {
display: flex;
flex-direction: column;
justify-content: center;;
align-items: center;
justify-content: center;
//align-items: center;
.item-title {
font-size: 28rpx;
color: #333;


Loading…
Cancel
Save