diff --git a/src/components/site/order_modal/order_modal.vue b/src/components/site/order_modal/order_modal.vue
index a86176c..cd085df 100644
--- a/src/components/site/order_modal/order_modal.vue
+++ b/src/components/site/order_modal/order_modal.vue
@@ -105,7 +105,7 @@
订单详情
- 取消订场
+ 取消订场
@@ -147,6 +147,27 @@ export default {
this.getOrderInfo();
},
methods: {
+ fixedCancelOccupy: util.debounce(function(){
+ let { orderInfo, queryInfo } = this;
+ util.showLoad();
+ servers.get({
+ url: API.venue.FixedOccupyCancel,
+ data: {
+ id: orderInfo.fix_venue_id,
+ },
+ isDefaultGet: false,
+ })
+ .then(res=>{
+ util.hideLoad();
+ if(res.data.code == 0){
+ setTimeout(_=>this.$emit('refresh'), 1200);
+ util.showNone(res.data.message || '操作成功!');
+ }else{
+ util.showNone(res.data.message || '操作失败!');
+ }
+ })
+ .catch(util.hideLoad)
+ }, 300, true),
toCouseInfo(){
util.showNone('待开放')
},
@@ -190,7 +211,9 @@ export default {
case 1:
return '待使用'
case 2:
- return '已完成'
+ return '已使用'
+ case 3:
+ return '已失效'
case 8:
return '使用中'
default: return '-'
diff --git a/src/js/api.js b/src/js/api.js
index 7168133..89e10e2 100644
--- a/src/js/api.js
+++ b/src/js/api.js
@@ -74,6 +74,9 @@ API['venue'] = {
takeUpCancel: `${ORIGIN}/admin/stadium/venue/takeUpCancel`, // 商家助手-取消占用场地
orderRefund: `${ORIGIN}/admin/stadium/order/cancel`, // 商家助手 - 退款
+ // 20210806
+ FixedOccupyCancel: `${ORIGIN}/admin/VenueNumberFixedOccupy/cancel`, // 固定场取消订场
+
}
// 2.1 核销
diff --git a/src/pages/index/index.vue b/src/pages/index/index.vue
index a7d727d..5589bbf 100644
--- a/src/pages/index/index.vue
+++ b/src/pages/index/index.vue
@@ -109,7 +109,7 @@
},
{
id: 5,
- name: '场地管理',
+ name: '场地看板',
// path: '/pages/site/order_list/order_list', // 20210804 不要占用列表
path: '/pages/site/manage/manage',
serverKey: 1009 // 后端对应权限编号
diff --git a/src/pages/site/confirm/confirm.vue b/src/pages/site/confirm/confirm.vue
index f33b653..b869412 100644
--- a/src/pages/site/confirm/confirm.vue
+++ b/src/pages/site/confirm/confirm.vue
@@ -28,6 +28,10 @@
+
+ 小计(共{{(occupyInfo.venueList&&occupyInfo.venueList.length) || 0}}场)
+ ¥{{ totalPrice || 0 }}
+
*是否联动开灯
@@ -67,6 +71,15 @@ export default {
},
computed: {
...mapState([ 'occupyInfo' ]),
+ totalPrice(){
+ let { occupyInfo } = this;
+ let _list = occupyInfo.venueList || [];
+ if(!_list.length)return 0;
+ let _price = 0;
+ _list.forEach(e=>_price += +e.price);
+ console.warn(_price)
+ return _price.toFixed(2);
+ }
},
onLoad(){
console.log(this.occupyInfo)
@@ -193,6 +206,19 @@ export default {
}
}
}
+ .soi-total{
+ margin-top: 30upx;
+ text-align: right;
+ font-size: 28upx;
+ line-height: 52upx;
+ color: #333;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ white-space: nowrap;
+ >text{
+ color: #9a9a9d;
+ }
+ }
}
.sc-switch{
padding: 40upx 24upx 0;
diff --git a/src/pages/site/manage/manage.vue b/src/pages/site/manage/manage.vue
index 35b1e25..b063911 100644
--- a/src/pages/site/manage/manage.vue
+++ b/src/pages/site/manage/manage.vue
@@ -201,6 +201,8 @@ export default {
},
methods: {
getVenueStatusnInfo(info){
+ // 超时未订
+ if(info.overdue&&info.type == 'empty_venue')return { zh_text: info.message || info.price, type: 'overdue', className: 'gray', }
switch(info.type){
case 'no_price_venue':
return { zh_text: info.message || '无法订场', type: info.type, className: 'grey', }
@@ -306,6 +308,7 @@ export default {
// this.showOccupyTip(_str)
// return
// }
+ if(_curTarget.overdue&&_curTarget.type == 'empty_venue')return // 超时未定
// 设置看板信息
if(_curTarget.type !== 'empty_venue'&& _curTarget.type !== 'no_price_venue'){
let { curStoreInfo } = this;
@@ -697,6 +700,10 @@ export default {
background-color: #68C43B;
border-color: #68C43B;
}
+ &.gray{
+ border-color: #9A9A9D;
+ color: #9A9A9D;
+ }
}
}
&:first-child{
@@ -796,7 +803,7 @@ export default {
width: 40upx;
height: 22upx;
border-radius: 6upx;
- border: 1upx solid $themeColor;
+ border: 1px solid $themeColor;
margin-bottom: 8upx;
}
@@ -821,6 +828,7 @@ export default {
background-color: #333333;
border-color: #333333;
}
+
}
}
}