From 17a0e6f9f332a1f6c0d7b8c745ff7fe6c24568f4 Mon Sep 17 00:00:00 2001
From: "Mr.jiang" <714156421@qq.com>
Date: Tue, 16 Jul 2024 15:17:09 +0800
Subject: [PATCH 1/2] =?UTF-8?q?=E5=AE=9A=E4=BD=8D?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
my/order/pay.vue | 78 +++++++++++++----------
my/order/payJaZ.vue | 70 ++++++++++++---------
my/order/payModify.vue | 21 ++++---
my/order/payModifyTcMyDaiB.vue | 51 ++++++++-------
my/order/payShengji.vue | 73 +++++++++++----------
my/order/payding.vue | 44 ++++++-------
my/order/paydingTc.vue | 17 ++---
pages.json | 11 ----
pages/index/index.vue | 112 ++++++++++++++-------------------
pages/index/searchAddress.vue | 65 -------------------
pages/order/index.vue | 75 ++++++++++++----------
11 files changed, 287 insertions(+), 330 deletions(-)
delete mode 100644 pages/index/searchAddress.vue
diff --git a/my/order/pay.vue b/my/order/pay.vue
index eb2cb56..9c8b550 100644
--- a/my/order/pay.vue
+++ b/my/order/pay.vue
@@ -2139,41 +2139,49 @@
}
});
},
- // 取消订单
- cancelOrder(e) {
- let contentName = '';
- let closeKC = this.$queue.getData('closeKC');
- if (e.status == 7 || e.status == 8 && closeKC) {
- let money = parseFloat(parseFloat(e.price) * parseFloat(closeKC)).toFixed(2);
- contentName = '取消订单将扣除' + money + '元的手续费,并且车费将全部扣除!';
- }
+ cancelOrders(data){//取消订单
let that = this
- uni.showModal({
- title: '温馨提示',
- content: '是否确认取消订单?' + contentName,
- success: function(res) {
- if (res.confirm) {
- let data = {
- ordersId: e.ordersId
- }
- that.$queue.showLoading('提交中...')
- that.$Request.post('/app/artificer/deleteOrders', data).then(res => {
- uni.hideLoading();
- if (res.code == 0) {
- uni.showToast({
- title:'操作成功!'
- })
- that.getOrder();
-
- } else {
- that.$queue.showToast(res.msg);
- }
- })
- } else if (res.cancel) {
- console.log('用户点击取消');
- }
+ that.$Request.post('/app/artificer/deleteOrders', data).then(res => {
+ uni.hideLoading();
+ if (res.code == 0) {
+ that.page = 1;
+ uni.showToast({
+ title:'操作成功!'
+ })
+ that.getOrder()
+ } else {
+ that.$queue.showToast(res.msg);
}
- });
+ })
+ },
+ // 取消订单待确认
+ cancelOrder(e) {
+ let that = this
+ let data = {
+ ordersId: e.ordersId
+ }
+ //取消订单扣费
+ that.$Request.post('/app/artificer/cancelOrdersMoney', data).then(resa => {
+ uni.hideLoading();
+ if (resa.code == 0) {
+ that.page = 1;
+ uni.showModal({
+ title: '温馨提示',
+ content: '是否确认取消订单?' + resa.data,
+ success: function(res) {
+ if (res.confirm) {
+ that.cancelOrders(data)
+ that.$queue.showLoading('取消中...')
+
+ } else if (res.cancel) {
+ console.log('用户点击取消');
+ }
+ }
+ });
+ } else {
+ that.$queue.showToast(res.msg);
+ }
+ })
},
// 完成订单
cancel(e) {
@@ -2190,6 +2198,10 @@
that.$Request.post('/app/artificer/accomplishOrders', data).then(res => {
uni.hideLoading();
if (res.code == 0) {
+ uni.showToast({
+ title:'操作成功!'
+ })
+ that.getOrder()
uni.navigateBack()
} else {
that.$queue.showToast(res.msg);
diff --git a/my/order/payJaZ.vue b/my/order/payJaZ.vue
index 12a0bd1..2d5f1df 100644
--- a/my/order/payJaZ.vue
+++ b/my/order/payJaZ.vue
@@ -1686,37 +1686,49 @@
}
});
},
- // 取消订单
- cancelOrder(e) {
- let contentName = '';
- let closeKC = this.$queue.getData('closeKC');
- if (e.status == 7 || e.status == 8 && closeKC) {
- let money = parseFloat(parseFloat(e.price) * parseFloat(closeKC)).toFixed(2);
- contentName = '取消订单将扣除' + money + '元的手续费,并且车费将全部扣除!';
- }
+ cancelOrders(data){//取消订单
let that = this
- uni.showModal({
- title: '温馨提示',
- content: '是否确认取消订单?' + contentName,
- success: function(res) {
- if (res.confirm) {
- let data = {
- ordersId: e.ordersId
- }
- that.$queue.showLoading('提交中...')
- that.$Request.post('/app/artificer/deleteOrders', data).then(res => {
- uni.hideLoading();
- if (res.code == 0) {
- that.getOrder()
- } else {
- that.$queue.showToast(res.msg);
- }
- })
- } else if (res.cancel) {
- console.log('用户点击取消');
- }
+ that.$Request.post('/app/artificer/deleteOrders', data).then(res => {
+ uni.hideLoading();
+ if (res.code == 0) {
+ that.page = 1;
+ uni.showToast({
+ title:'操作成功!'
+ })
+ that.getOrder()
+ } else {
+ that.$queue.showToast(res.msg);
}
- });
+ })
+ },
+ // 取消订单待确认
+ cancelOrder(e) {
+ let that = this
+ let data = {
+ ordersId: e.ordersId
+ }
+ //取消订单扣费
+ that.$Request.post('/app/artificer/cancelOrdersMoney', data).then(resa => {
+ uni.hideLoading();
+ if (resa.code == 0) {
+ that.page = 1;
+ uni.showModal({
+ title: '温馨提示',
+ content: '是否确认取消订单?' + resa.data,
+ success: function(res) {
+ if (res.confirm) {
+ that.cancelOrders(data)
+ that.$queue.showLoading('取消中...')
+
+ } else if (res.cancel) {
+ console.log('用户点击取消');
+ }
+ }
+ });
+ } else {
+ that.$queue.showToast(res.msg);
+ }
+ })
},
// 完成订单
cancel(e) {
diff --git a/my/order/payModify.vue b/my/order/payModify.vue
index b48f95d..17f266a 100644
--- a/my/order/payModify.vue
+++ b/my/order/payModify.vue
@@ -23,9 +23,12 @@
¥
{{orderXm.price}}
-
+
+
+
+
@@ -296,6 +299,7 @@
couponDataList:'',
orderXm:[],
number:1,
+ qyMinNum:''
}
},
onLoad(e) {
@@ -326,7 +330,10 @@
this.ordersId = this.$queue.getData('ordersId');
this.userPackageDetailId = this.$queue.getData('userPackageDetailId');
this.youhui()
- // this.getOrder()
+ if(this.orderXm.qyType=='1'){
+ this.qyMinNum=this.orderXm.qyMinNum;
+ this.number=this.orderXm.qyMinNum;
+ }
},
onShow() {
@@ -1244,12 +1251,6 @@
},
// 取消订单
cancelOrder(e) {
- let contentName = '';
- let closeKC = this.$queue.getData('closeKC');
- if (e.status == 7 || e.status == 8 && closeKC) {
- let money = parseFloat(parseFloat(e.price) * parseFloat(closeKC)).toFixed(2);
- contentName = '取消订单将扣除' + money + '元的手续费,并且车费将全部扣除!';
- }
let that = this
uni.showModal({
title: '温馨提示',
@@ -1263,7 +1264,9 @@
that.$Request.post('/app/artificer/deleteOrders', data).then(res => {
uni.hideLoading();
if (res.code == 0) {
- // that.getOrder()
+ uni.switchTab({
+ url:'/pages/order/index'
+ })
} else {
that.$queue.showToast(res.msg);
}
diff --git a/my/order/payModifyTcMyDaiB.vue b/my/order/payModifyTcMyDaiB.vue
index 643e947..dfb3e85 100644
--- a/my/order/payModifyTcMyDaiB.vue
+++ b/my/order/payModifyTcMyDaiB.vue
@@ -1265,35 +1265,38 @@
}
});
},
- // 取消订单
- cancelOrder(e) {
- let contentName = '';
- let closeKC = this.$queue.getData('closeKC');
- if (e.status == 7 || e.status == 8 && closeKC) {
- let money = parseFloat(parseFloat(e.price) * parseFloat(closeKC)).toFixed(2);
- contentName = '取消订单将扣除' + money + '元的手续费,并且车费将全部扣除!';
- }
+ cancelOrders(data){//取消订单
let that = this
+ that.$Request.post('/app/artificer/deleteOrders', data).then(res => {
+ uni.hideLoading();
+ if (res.code == 0) {
+ that.page = 1;
+ uni.showToast({
+ title:'操作成功!'
+ })
+ uni.switchTab({
+ url:'/pages/order/index'
+ })
+ that.getOrder()
+ } else {
+ that.$queue.showToast(res.msg);
+ }
+ })
+ },
+ // 取消订单待确认
+ cancelOrder(e) {
+ let that = this
+ let data = {
+ ordersId: e.ordersId
+ }
uni.showModal({
title: '温馨提示',
- content: '是否确认取消订单?' + contentName,
+ content: '是否确认取消订单?',
success: function(res) {
if (res.confirm) {
- let data = {
- ordersId: e.ordersId
- }
- that.$queue.showLoading('提交中...')
- that.$Request.post('/app/artificer/deleteOrders', data).then(res => {
- uni.hideLoading();
- if (res.code == 0) {
- that.getOrder()
- uni.switchTab({
- url:'/pages/order/index'
- })
- } else {
- that.$queue.showToast(res.msg);
- }
- })
+ that.cancelOrders(data)
+ that.$queue.showLoading('取消中...')
+
} else if (res.cancel) {
console.log('用户点击取消');
}
diff --git a/my/order/payShengji.vue b/my/order/payShengji.vue
index 9261992..a1324c0 100644
--- a/my/order/payShengji.vue
+++ b/my/order/payShengji.vue
@@ -1980,40 +1980,49 @@
}
});
},
- // 取消订单
- cancelOrder(e) {
- let contentName = '';
- let closeKC = this.$queue.getData('closeKC');
- if (e.status == 7 || e.status == 8 && closeKC) {
- let money = parseFloat(parseFloat(e.price) * parseFloat(closeKC)).toFixed(2);
- contentName = '取消订单将扣除' + money + '元的手续费,并且车费将全部扣除!';
- }
+ cancelOrders(data){//取消订单
let that = this
- uni.showModal({
- title: '温馨提示',
- content: '是否确认取消订单?' + contentName,
- success: function(res) {
- if (res.confirm) {
- let data = {
- ordersId: e.ordersId
- }
- that.$queue.showLoading('提交中...')
- that.$Request.post('/app/artificer/deleteOrders', data).then(res => {
- uni.hideLoading();
- if (res.code == 0) {
- that.getOrder()
- uni.showToast({
- title:'操作成功!'
- })
- } else {
- that.$queue.showToast(res.msg);
- }
- })
- } else if (res.cancel) {
- console.log('用户点击取消');
- }
+ that.$Request.post('/app/artificer/deleteOrders', data).then(res => {
+ uni.hideLoading();
+ if (res.code == 0) {
+ that.page = 1;
+ uni.showToast({
+ title:'操作成功!'
+ })
+ that.getOrder()
+ } else {
+ that.$queue.showToast(res.msg);
}
- });
+ })
+ },
+ // 取消订单待确认
+ cancelOrder(e) {
+ let that = this
+ let data = {
+ ordersId: e.ordersId
+ }
+ //取消订单扣费
+ that.$Request.post('/app/artificer/cancelOrdersMoney', data).then(resa => {
+ uni.hideLoading();
+ if (resa.code == 0) {
+ that.page = 1;
+ uni.showModal({
+ title: '温馨提示',
+ content: '是否确认取消订单?' + resa.data,
+ success: function(res) {
+ if (res.confirm) {
+ that.cancelOrders(data)
+ that.$queue.showLoading('取消中...')
+
+ } else if (res.cancel) {
+ console.log('用户点击取消');
+ }
+ }
+ });
+ } else {
+ that.$queue.showToast(res.msg);
+ }
+ })
},
// 完成订单
cancel(e) {
diff --git a/my/order/payding.vue b/my/order/payding.vue
index fc5cc82..f094813 100644
--- a/my/order/payding.vue
+++ b/my/order/payding.vue
@@ -1263,38 +1263,38 @@
}
});
},
- // 取消订单
+ cancelOrders(data){//取消订单
+ let that = this
+ that.$Request.post('/app/artificer/deleteOrders', data).then(res => {
+ uni.hideLoading();
+ if (res.code == 0) {
+ that.getOrder()
+ uni.showToast({
+ title:'操作成功!'
+ })
+ uni.switchTab({
+ url:'/pages/order/index'
+ })
+ } else {
+ that.$queue.showToast(res.msg);
+ }
+ })
+ },
+ // 取消订单待确认
cancelOrder(e) {
- let contentName = '';
- let closeKC = this.$queue.getData('closeKC');
- if (e.status == 7 || e.status == 8 && closeKC) {
- let money = parseFloat(parseFloat(e.price) * parseFloat(closeKC)).toFixed(2);
- contentName = '取消订单将扣除' + money + '元的手续费,并且车费将全部扣除!';
- }
+
let that = this
uni.showModal({
title: '温馨提示',
- content: '是否确认取消订单?' + contentName,
+ content: '是否确认取消订单?',
success: function(res) {
if (res.confirm) {
let data = {
ordersId: e.ordersId
}
that.$queue.showLoading('提交中...')
- that.$Request.post('/app/artificer/deleteOrders', data).then(res => {
- uni.hideLoading();
- if (res.code == 0) {
- that.getOrder()
- uni.showToast({
- title:'操作成功!'
- })
- uni.switchTab({
- url:'/pages/order/index'
- })
- } else {
- that.$queue.showToast(res.msg);
- }
- })
+ that.cancelOrders(data)
+
} else if (res.cancel) {
console.log('用户点击取消');
}
diff --git a/my/order/paydingTc.vue b/my/order/paydingTc.vue
index 7ba19d2..8f2ef3f 100644
--- a/my/order/paydingTc.vue
+++ b/my/order/paydingTc.vue
@@ -76,12 +76,16 @@
-
+
立即支付
联系客服
+
@@ -938,16 +942,13 @@
},
// 取消订单
cancelOrder(e) {
- let contentName = '';
- let closeKC = this.$queue.getData('closeKC');
- if (e.status == 7 || e.status == 8 && closeKC) {
- let money = parseFloat(parseFloat(e.price) * parseFloat(closeKC)).toFixed(2);
- contentName = '取消订单将扣除' + money + '元的手续费,并且车费将全部扣除!';
- }
let that = this
+ let data = {
+ ordersId: e.ordersId
+ }
uni.showModal({
title: '温馨提示',
- content: '是否确认取消订单?' + contentName,
+ content: '是否确认取消订单?',
success: function(res) {
if (res.confirm) {
let data = {
diff --git a/pages.json b/pages.json
index 73be877..6535019 100644
--- a/pages.json
+++ b/pages.json
@@ -42,17 +42,6 @@
}
}
},
- {
- "path": "pages/index/searchAddress",
- "style": {
- "navigationBarTitleText": "搜索地址",
- "enablePullDownRefresh": true,
- "navigationStyle": "custom",
- "app-plus": {
- "titleNView": false
- }
- }
- },
{
"path": "pages/videoCircle/index",
"style": {
diff --git a/pages/index/index.vue b/pages/index/index.vue
index c97ceaa..c6f9168 100644
--- a/pages/index/index.vue
+++ b/pages/index/index.vue
@@ -427,8 +427,6 @@
}
}
})
- // 116.481488,39.990464
- // 125.424295,43.878294
uni.getLocation({
type: 'wgs84',
geocode: true, //设置该参数为true可直接获取经纬度及城市信息
@@ -447,27 +445,28 @@
// that.getorderlist('')
that.getKTCityList();
// #endif
- var dizhi={
- key:'4f23770b6e53b96e7d0661a7ccfb9c21',
- location:that.longitude+','+res.latitude,
- radius:'1000',
- extensions:'all',
- output:'JSON'
- }
- uni.request({
- url: 'https://restapi.amap.com/v3/geocode/regeo',
- data:dizhi,
- method:'GET',
- success(rea) {
- console.log("获取城市名称成功", rea)
- if (rea.statusCode ==200) {
- that.city = rea.data.regeocode.addressComponent.township;
- // uni.setStorageSync('citySou',rea.data.regeocode.addressComponent.city)
- } else {
- console.log("获取信息失败,请重试!")
- }
- }
- });
+ that.selectCity(that.longitude,that.latitude)
+ // var dizhi={
+ // key:'4f23770b6e53b96e7d0661a7ccfb9c21',
+ // location:that.longitude+','+res.latitude,
+ // radius:'1000',
+ // extensions:'all',
+ // output:'JSON'
+ // }
+ // uni.request({
+ // url: 'https://restapi.amap.com/v3/geocode/regeo',
+ // data:dizhi,
+ // method:'GET',
+ // success(rea) {
+ // console.log("获取城市名称成功", rea)
+ // if (rea.statusCode ==200) {
+ // that.city = rea.data.regeocode.addressComponent.township;
+ // // uni.setStorageSync('citySou',rea.data.regeocode.addressComponent.city)
+ // } else {
+ // console.log("获取信息失败,请重试!")
+ // }
+ // }
+ // });
// #ifdef H5
// that.city = that.latitude+','+that.longitude
@@ -530,39 +529,34 @@
})
}
that.token = uni.getStorageSync('token');
- // that.getKTCityList();
- // if (uni.getStorageSync('token')) {
- // console.log(22)
- // if (that.latitude && that.longitude) {
- // that.page = 1
- // that.getHomeArtificerList()
- // } else {
- // console.log(33)
- // uni.getLocation({
- // type: 'wgs84',
- // // highAccuracyExpireTime: 500,
- // geocode: true, //设置该参数为true可直接获取经纬度及城市信息
- // success: function(res) {
- // console.log(44)
- // console.log( '------>地理位置',res)
- // that.latitude = res.latitude
- // that.longitude = res.longitude
- // that.page = 1
- // that.getHomeArtificerList()
- // },
- // fail: function() {
- // console.log(55)
- // console.log('获取地址失败2')
- // }
- // })
- // }
- // }
},
methods: {
goCity(){
- uni.navigateTo({
- url:'/pages/index/searchAddress'
- })
+ var that = this
+ uni.chooseLocation({
+ success: function(res) {
+ console.log('位置名称:' + res.name);
+ console.log('详细地址:' + res.address);
+ console.log('纬度:' + res.latitude);
+ console.log('经度:' + res.longitude);
+ that.detailaddress = res.name
+ that.latitude = res.latitude
+ that.longitude = res.longitude
+ that.selectCity(res.longitude, res.latitude)
+ }
+ });
+
+ },
+ selectCity(longitude, latitude) {
+ this.$Request.get('/app/Login/selectCity?lat=' + latitude + '&lng=' + longitude).then(res => {
+ if (res.code == 0) {
+ this.city = res.data.address ? res.data.address : '未知'
+ // uni.setStorageSync('city', res.data.province)
+ this.page = 1
+ // this.getorderlist('')
+ this.getKTCityList();
+ }
+ });
},
searchBtn(){//搜索按钮
uni.navigateTo({
@@ -747,17 +741,7 @@
}
});
},
- selectCity(longitude, latitude) {
- this.$Request.get('/app/Login/selectCity?lat=' + latitude + '&lng=' + longitude).then(res => {
- if (res.code == 0) {
- this.city = res.data.city ? res.data.city : '未知'
- uni.setStorageSync('city', res.data.city)
- this.page = 1
- this.getorderlist('')
- this.getKTCityList();
- }
- });
- },
+
chaoji(){//超级满减
uni.navigateTo({
url:'/my/wallet/index'
diff --git a/pages/index/searchAddress.vue b/pages/index/searchAddress.vue
deleted file mode 100644
index 8923f23..0000000
--- a/pages/index/searchAddress.vue
+++ /dev/null
@@ -1,65 +0,0 @@
-
-
-
- 搜索
-
-
-
-
-
-
\ No newline at end of file
diff --git a/pages/order/index.vue b/pages/order/index.vue
index b4130fd..84911f9 100644
--- a/pages/order/index.vue
+++ b/pages/order/index.vue
@@ -704,41 +704,50 @@
this.page = 1
this.getOrderList()
},
- // 取消订单
- cancelOrder(e) {
- let contentName = '';
- let closeKC = this.$queue.getData('closeKC');
- if (e.status == 7 || e.status == 8 && closeKC) {
- let money = parseFloat(parseFloat(e.price) * parseFloat(closeKC)).toFixed(2);
- contentName = '取消订单将扣除' + money + '元的手续费,并且车费将全部扣除!';
- }
+ cancelOrders(data){//取消订单
let that = this
- uni.showModal({
- title: '温馨提示',
- content: '是否确认取消订单?' + contentName,
- success: function(res) {
- if (res.confirm) {
- let data = {
- ordersId: e.ordersId
- }
- that.$queue.showLoading('取消中...')
- that.$Request.post('/app/artificer/deleteOrders', data).then(res => {
- uni.hideLoading();
- if (res.code == 0) {
- that.page = 1;
- uni.showToast({
- title:'操作成功!'
- })
- that.getOrderList()
- } else {
- that.$queue.showToast(res.msg);
- }
- })
- } else if (res.cancel) {
- console.log('用户点击取消');
- }
+ that.$Request.post('/app/artificer/deleteOrders', data).then(res => {
+ uni.hideLoading();
+ if (res.code == 0) {
+ that.page = 1;
+ uni.showToast({
+ title:'操作成功!'
+ })
+ that.getOrderList()
+ } else {
+ that.$queue.showToast(res.msg);
}
- });
+ })
+ },
+ // 取消订单待确认
+ cancelOrder(e) {
+ let that = this
+ let data = {
+ ordersId: e.ordersId
+ }
+ //取消订单扣费
+ that.$Request.post('/app/artificer/cancelOrdersMoney', data).then(resa => {
+ uni.hideLoading();
+ if (resa.code == 0) {
+ that.page = 1;
+ uni.showModal({
+ title: '温馨提示',
+ content: '是否确认取消订单?' + resa.data,
+ success: function(res) {
+ if (res.confirm) {
+ that.cancelOrders(data)
+ that.$queue.showLoading('取消中...')
+
+ } else if (res.cancel) {
+ console.log('用户点击取消');
+ }
+ }
+ });
+ } else {
+ that.$queue.showToast(res.msg);
+ }
+ })
+
},
/*下拉刷新的回调 */
downCallback() {
From bfabf81bce1f289ae3880b2e7371da79465b3bcc Mon Sep 17 00:00:00 2001
From: "Mr.jiang" <714156421@qq.com>
Date: Tue, 16 Jul 2024 15:22:19 +0800
Subject: [PATCH 2/2] =?UTF-8?q?=E5=8F=96=E6=B6=88?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
my/order/paydingTCX.vue | 8 +-------
1 file changed, 1 insertion(+), 7 deletions(-)
diff --git a/my/order/paydingTCX.vue b/my/order/paydingTCX.vue
index cd1c098..9b3be5d 100644
--- a/my/order/paydingTCX.vue
+++ b/my/order/paydingTCX.vue
@@ -1394,16 +1394,10 @@
},
// 取消订单
cancelOrder(e) {
- let contentName = '';
- let closeKC = this.$queue.getData('closeKC');
- if (e.status == 7 || e.status == 8 && closeKC) {
- let money = parseFloat(parseFloat(e.price) * parseFloat(closeKC)).toFixed(2);
- contentName = '取消订单将扣除' + money + '元的手续费,并且车费将全部扣除!';
- }
let that = this
uni.showModal({
title: '温馨提示',
- content: '是否确认取消订单?' + contentName,
+ content: '是否确认取消订单?',
success: function(res) {
if (res.confirm) {
let data = {