|
@@ -67,10 +67,14 @@
|
|
|
<view class="flex-center btn" @tap="cancelRefund">取消</view>
|
|
<view class="flex-center btn" @tap="cancelRefund">取消</view>
|
|
|
<view class="flex-center btn active" @tap="confirmRefund" style="margin-left: 80upx">确定</view>
|
|
<view class="flex-center btn active" @tap="confirmRefund" style="margin-left: 80upx">确定</view>
|
|
|
</view>
|
|
</view>
|
|
|
|
|
+ <view class="flex-center btn-box" style="margin-bottom:50upx;margin-top:50upx;">
|
|
|
|
|
+ <view class="flex-center btn active" @tap="allRefundFn">全部退货退款</view>
|
|
|
|
|
+ </view>
|
|
|
</view>
|
|
</view>
|
|
|
</template>
|
|
</template>
|
|
|
<script>
|
|
<script>
|
|
|
import { getDetail,refund } from "@/api/order/index";
|
|
import { getDetail,refund } from "@/api/order/index";
|
|
|
|
|
+import { allRefund } from "@/api/refund"
|
|
|
export default {
|
|
export default {
|
|
|
name: "orderDetail",
|
|
name: "orderDetail",
|
|
|
components: {},
|
|
components: {},
|
|
@@ -123,6 +127,18 @@ export default {
|
|
|
cancelRefund(){
|
|
cancelRefund(){
|
|
|
uni.navigateBack({delta: 1});
|
|
uni.navigateBack({delta: 1});
|
|
|
},
|
|
},
|
|
|
|
|
+ allRefundFn(){
|
|
|
|
|
+ let that = this
|
|
|
|
|
+ that.$util.confirmModal({content:'确认全部退货退款?'},() => {
|
|
|
|
|
+ uni.showLoading({mask:true})
|
|
|
|
|
+ allRefund({id:that.orderInfo.id}).then(res => {
|
|
|
|
|
+ uni.hideLoading()
|
|
|
|
|
+ if(res.code == 1){
|
|
|
|
|
+ this.$util.pageTo({url:'/common/success',query:{titleType:1},type:2})
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
|
|
+ })
|
|
|
|
|
+ },
|
|
|
confirmRefund(){
|
|
confirmRefund(){
|
|
|
let hasError = false
|
|
let hasError = false
|
|
|
let selectProduct = []
|
|
let selectProduct = []
|