Quellcode durchsuchen

直播需求调整

lmx vor 2 Tagen
Ursprung
Commit
e365a21223

+ 10 - 0
src/api/live/liveAfterSales.js

@@ -90,3 +90,13 @@ export function audit2(data) {
     data: data
   })
 }
+
+export function handleImmediatelyRefund(data) {
+  return request({
+    url: '/live/liveAfterSales/handleImmediatelyRefund',
+    method: 'post',
+    data: data
+  })
+}
+
+

+ 23 - 1
src/views/live/components/productAfterSalesOrder.vue

@@ -20,6 +20,7 @@
             <el-button size="mini"  v-hasPermi="['store:storeAfterSales:audit1']" v-show="afterSales.salesStatus==0&&afterSales.status===0" @click="handleAudit1">平台审核</el-button>
             <el-button size="mini"  v-hasPermi="['store:storeAfterSales:audit2']" v-show="afterSales.salesStatus==0&&afterSales.status===2" @click="handleAudit2">仓库审核</el-button>
             <el-button size="mini"  v-hasPermi="['store:storeAfterSales:refund']" @click="handleRefund"  v-show="afterSales.salesStatus==0&&afterSales.status===3">财务审核</el-button>
+            <el-button size="mini"  v-hasPermi="['store:storeAfterSales:refund']" @click="handleImmediatelyRefund"  v-show="afterSales.salesStatus==0">立即退款</el-button>
             <el-button size="mini"  v-hasPermi="['store:storeAfterSales:cancel']" @click="cancel"  v-show="afterSales.salesStatus==0">撤销</el-button>
             <el-button size="mini"  @click="showOrder">查看订单</el-button>
           </div>
@@ -208,7 +209,7 @@
 </template>
 
 <script>
-import {getLiveAfterSales,cancel,refund,audit,updateLiveAfterSales,audit1,audit2 } from "@/api/live/liveAfterSales";
+import {getLiveAfterSales,cancel,refund,audit,updateLiveAfterSales,audit1,audit2,handleImmediatelyRefund } from "@/api/live/liveAfterSales";
 
 import productOrder from "./productOrder";
 export default {
@@ -327,6 +328,27 @@ export default {
       this.form.salesId=this.afterSales.id;
       this.form.refundAmount=this.afterSales.refundAmount;
     },
+    handleImmediatelyRefund(){
+      let _this = this;
+       this.$confirm('确认立即退款吗?', "警告", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      }).then(function() {
+       
+        let param ={orderId:_this.order.orderId}
+        console.log(param)
+         debugger;
+        handleImmediatelyRefund(param).then(res=>{
+          _this.msgSuccess("操作成功");
+          _this.getLiveAfterSales(_this.afterSales.id);
+        }).catch(res=>{
+          console.log(res);
+        });
+      }).then(() => {
+        // this.getLiveAfterSales(id);
+      }).catch(function() {});
+    },
     handleAudit1(){
       var id=this.afterSales.id;
       this.$confirm('确定审请通过?', "警告", {

+ 1 - 1
src/views/live/liveOrder/liveOrderDetails.vue

@@ -537,7 +537,7 @@ export default {
     this.getDicts("sys_store_pay_type").then(response => {
       this.PayOptions = response.data;
     });
-    this.getDicts("sys_order_status").then(response => {
+    this.getDicts("sys_live_order_status").then(response => {
       this.orderOptions = response.data;
     });
     this.getDicts("sys_order_pay").then(response => {