|
|
@@ -0,0 +1,487 @@
|
|
|
+<template>
|
|
|
+ <div class="order-content" v-loading="loading">
|
|
|
+ <!-- 售后流程步骤条 -->
|
|
|
+ <div class="order-status" v-if="afterSales != null">
|
|
|
+ <!-- 仅退款:用户提交 → 平台审核 → 财务审核 → 退款成功 -->
|
|
|
+ <el-steps v-if="isRefundOnly" :active="refundOnlyActive" align-center finish-status="success">
|
|
|
+ <el-step title="用户提交"></el-step>
|
|
|
+ <el-step title="平台审核"></el-step>
|
|
|
+ <el-step title="财务审核"></el-step>
|
|
|
+ <el-step title="退款成功"></el-step>
|
|
|
+ </el-steps>
|
|
|
+ <!-- 退款退货:用户提交 → 平台审核 → 用户发货 → 仓库审核 → 财务审核 → 退款成功 -->
|
|
|
+ <el-steps v-else :active="refundReturnActive" align-center finish-status="success">
|
|
|
+ <el-step title="用户提交"></el-step>
|
|
|
+ <el-step title="平台审核"></el-step>
|
|
|
+ <el-step title="用户发货"></el-step>
|
|
|
+ <el-step title="仓库审核"></el-step>
|
|
|
+ <el-step title="财务审核"></el-step>
|
|
|
+ <el-step title="退款成功"></el-step>
|
|
|
+ </el-steps>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div v-if="afterSales != null">
|
|
|
+ <!-- 操作按钮区 -->
|
|
|
+ <el-card shadow="never" style="margin-top: 15px">
|
|
|
+ <div class="operate-container">
|
|
|
+ <span style="margin-left: 20px" class="color-danger">状态:
|
|
|
+ <el-tag v-for="item in statusOptions" :key="item.dictValue"
|
|
|
+ v-if="afterSales.status == item.dictValue" :type="statusTagType(afterSales.status)">{{ item.dictLabel }}</el-tag>
|
|
|
+ </span>
|
|
|
+ <div class="operate-button-container">
|
|
|
+ <!-- 平台审核:status=0 -->
|
|
|
+ <el-button size="mini" v-hasPermi="['his:integralAfterSales:audit']"
|
|
|
+ v-if="Number(afterSales.salesStatus) === 0 && Number(afterSales.status) === 0"
|
|
|
+ @click="handleAudit">平台审核</el-button>
|
|
|
+ <!-- 编辑物流:退款退货且status=1,平台填写快递信息 -->
|
|
|
+ <el-button size="mini" v-hasPermi="['his:integralAfterSales:edit']"
|
|
|
+ v-if="Number(afterSales.salesStatus) === 0 && Number(afterSales.status) === 1 && !isRefundOnly"
|
|
|
+ @click="addDelivery">编辑物流</el-button>
|
|
|
+ <!-- 仓库审核:退款退货且status=2 -->
|
|
|
+ <el-button size="mini" v-hasPermi="['his:integralAfterSales:audit']"
|
|
|
+ v-if="Number(afterSales.salesStatus) === 0 && Number(afterSales.status) === 2 && !isRefundOnly"
|
|
|
+ @click="handleWarehouseAudit">仓库审核</el-button>
|
|
|
+ <!-- 财务退款:仅退款status=1 或 退款退货status=3 -->
|
|
|
+ <el-button size="mini" type="danger" v-hasPermi="['his:integralAfterSales:refund']"
|
|
|
+ v-if="Number(afterSales.salesStatus) === 0 && canRefund"
|
|
|
+ @click="handleRefund">财务退款</el-button>
|
|
|
+ <!-- 撤销:未进入退款流程(status < 4) -->
|
|
|
+ <el-button size="mini" v-hasPermi="['his:integralAfterSales:cancel']"
|
|
|
+ v-if="Number(afterSales.salesStatus) === 0 && Number(afterSales.status) < 4"
|
|
|
+ @click="handleCancel">撤销</el-button>
|
|
|
+ <!-- 查看寄回物流 -->
|
|
|
+ <el-button size="mini" v-if="afterSales.deliverySn != null && afterSales.deliverySn !== ''"
|
|
|
+ @click="showExpress">查看寄回物流</el-button>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <!-- 售后基本信息 -->
|
|
|
+ <div class="section-title">售后基本信息</div>
|
|
|
+ <el-descriptions :column="3" border>
|
|
|
+ <el-descriptions-item label="售后单号">{{ afterSales.id }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="订单编号">{{ afterSales.orderCode }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="服务类型">
|
|
|
+ <el-tag v-for="item in serviceTypeOptions" :key="item.dictValue"
|
|
|
+ v-if="afterSales.serviceType == item.dictValue">{{ item.dictLabel }}</el-tag>
|
|
|
+ </el-descriptions-item>
|
|
|
+ <el-descriptions-item label="退款金额">
|
|
|
+ <span v-if="afterSales.refundAmount != null">¥{{ afterSales.refundAmount }}</span>
|
|
|
+ </el-descriptions-item>
|
|
|
+ <el-descriptions-item label="退回积分">
|
|
|
+ <span v-if="afterSales.refundIntegral != null">{{ afterSales.refundIntegral }}</span>
|
|
|
+ </el-descriptions-item>
|
|
|
+ <el-descriptions-item label="状态">
|
|
|
+ <el-tag v-for="item in statusOptions" :key="item.dictValue"
|
|
|
+ v-if="afterSales.status == item.dictValue" :type="statusTagType(afterSales.status)">{{ item.dictLabel }}</el-tag>
|
|
|
+ </el-descriptions-item>
|
|
|
+ <el-descriptions-item label="申请原因">{{ afterSales.reasons }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="说明">{{ afterSales.explains }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="操作人">{{ afterSales.operator }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="提交时间">{{ afterSales.createTime }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="备注">{{ afterSales.remark }}</el-descriptions-item>
|
|
|
+ </el-descriptions>
|
|
|
+ <div v-if="afterSales.explainImg != null && afterSales.explainImg !== ''" style="margin-top: 10px;">
|
|
|
+ <span class="font-small">说明图片:</span>
|
|
|
+ <el-image v-for="(url, index) in afterSales.explainImg.split(',')" :key="index"
|
|
|
+ style="width: 100px; height: 100px; margin-right: 5px;"
|
|
|
+ :src="url" :preview-src-list="afterSales.explainImg.split(',')" :initial-index="index">
|
|
|
+ </el-image>
|
|
|
+ </div>
|
|
|
+ </el-card>
|
|
|
+
|
|
|
+ <!-- 用户信息 -->
|
|
|
+ <el-card shadow="never" style="margin-top: 15px">
|
|
|
+ <div class="section-title">用户信息</div>
|
|
|
+ <el-descriptions :column="3" border>
|
|
|
+ <el-descriptions-item label="用户ID">{{ afterSales.userId }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="用户昵称">{{ afterSales.nickName }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="用户电话">{{ afterSales.userPhone }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="收货地址" :span="3">{{ afterSales.userAddress }}</el-descriptions-item>
|
|
|
+ </el-descriptions>
|
|
|
+ </el-card>
|
|
|
+
|
|
|
+ <!-- 支付信息 -->
|
|
|
+ <el-card shadow="never" style="margin-top: 15px">
|
|
|
+ <div class="section-title">支付信息</div>
|
|
|
+ <el-descriptions :column="3" border>
|
|
|
+ <el-descriptions-item label="支付积分">{{ afterSales.integral }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="支付金额">
|
|
|
+ <span v-if="afterSales.payMoney != null">¥{{ afterSales.payMoney }}</span>
|
|
|
+ </el-descriptions-item>
|
|
|
+ <el-descriptions-item label="支付方式">
|
|
|
+ <span v-if="afterSales.payType == 1">积分</span>
|
|
|
+ <span v-else-if="afterSales.payType == 2">现金</span>
|
|
|
+ <span v-else-if="afterSales.payType == 3">积分+现金</span>
|
|
|
+ <span v-else>-</span>
|
|
|
+ </el-descriptions-item>
|
|
|
+ <el-descriptions-item label="下单时间">{{ afterSales.orderCreateTime }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="支付时间">{{ afterSales.payTime }}</el-descriptions-item>
|
|
|
+ </el-descriptions>
|
|
|
+ </el-card>
|
|
|
+
|
|
|
+ <!-- 积分订单商品信息 -->
|
|
|
+ <el-card shadow="never" style="margin-top: 15px">
|
|
|
+ <div class="section-title">积分详情 / 商品信息</div>
|
|
|
+ <el-table border :data="prodList" size="small" style="width: 100%; margin-top: 10px">
|
|
|
+ <el-table-column label="商品图片" width="120" align="center">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <img v-if="scope.row.imgUrl" :src="scope.row.imgUrl" style="height: 70px" />
|
|
|
+ <span v-else>-</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="商品名称" align="center" prop="goodsName" show-overflow-tooltip>
|
|
|
+ <template slot-scope="scope">{{ scope.row.goodsName }}</template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="商品编号" width="180" align="center" prop="barCode">
|
|
|
+ <template slot-scope="scope">{{ scope.row.barCode || '-' }}</template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="数量" width="100" align="center" prop="num">
|
|
|
+ <template slot-scope="scope">{{ scope.row.num || 1 }}</template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="原价" width="120" align="center" prop="otPrice">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <span v-if="scope.row.otPrice != null">¥{{ scope.row.otPrice }}</span>
|
|
|
+ <span v-else>-</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="积分" width="120" align="center" prop="integral">
|
|
|
+ <template slot-scope="scope">{{ scope.row.integral }}</template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="现金" width="120" align="center" prop="cash">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <span v-if="scope.row.cash != null">¥{{ scope.row.cash }}</span>
|
|
|
+ <span v-else>-</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
+
|
|
|
+ <div class="section-title" style="margin-top: 20px">订单发货物流</div>
|
|
|
+ <el-descriptions :column="3" border>
|
|
|
+ <el-descriptions-item label="快递公司">{{ afterSales.orderDeliveryName }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="快递单号">{{ afterSales.orderDeliverySn }}</el-descriptions-item>
|
|
|
+ </el-descriptions>
|
|
|
+ </el-card>
|
|
|
+
|
|
|
+ <!-- 用户寄回物流 -->
|
|
|
+ <el-card shadow="never" style="margin-top: 15px" v-if="afterSales.deliverySn != null && afterSales.deliverySn !== ''">
|
|
|
+ <div class="section-title">用户寄回物流</div>
|
|
|
+ <el-descriptions :column="3" border>
|
|
|
+ <el-descriptions-item label="物流公司">{{ afterSales.deliveryName }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="物流单号">{{ afterSales.deliverySn }}</el-descriptions-item>
|
|
|
+ </el-descriptions>
|
|
|
+ </el-card>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <!-- 编辑物流弹窗 -->
|
|
|
+ <el-dialog title="填写用户寄回物流" :visible.sync="deliveryOpen" width="500px" append-to-body>
|
|
|
+ <el-form ref="deliveryForm" :model="deliveryForm" :rules="deliveryRules" label-width="100px">
|
|
|
+ <el-form-item label="物流公司" prop="deliveryName">
|
|
|
+ <el-input v-model="deliveryForm.deliveryName" placeholder="请输入物流公司名称" />
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="物流单号" prop="deliverySn">
|
|
|
+ <el-input v-model="deliveryForm.deliverySn" placeholder="请输入物流单号" />
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+ <div slot="footer" class="dialog-footer">
|
|
|
+ <el-button type="primary" @click="submitDelivery">确 定</el-button>
|
|
|
+ <el-button @click="deliveryOpen = false">取 消</el-button>
|
|
|
+ </div>
|
|
|
+ </el-dialog>
|
|
|
+
|
|
|
+ <!-- 查看寄回物流弹窗 -->
|
|
|
+ <el-dialog title="用户寄回物流信息" :visible.sync="expressOpen" width="720px" append-to-body>
|
|
|
+ <el-descriptions :column="1" border v-if="afterSales != null">
|
|
|
+ <el-descriptions-item label="物流公司">{{ afterSales.deliveryName }}</el-descriptions-item>
|
|
|
+ <el-descriptions-item label="物流单号">{{ afterSales.deliverySn }}</el-descriptions-item>
|
|
|
+ </el-descriptions>
|
|
|
+ <div style="margin-top: 20px; font-weight: bold;">物流流转信息</div>
|
|
|
+ <div v-loading="expressLoading">
|
|
|
+ <el-table v-if="traces && traces.length > 0"
|
|
|
+ style="margin-top: 10px; width: 100%"
|
|
|
+ :data="traces" border size="small">
|
|
|
+ <el-table-column label="时间" width="170" align="center">
|
|
|
+ <template slot-scope="scope">{{ scope.row.AcceptTime }}</template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="位置" align="center">
|
|
|
+ <template slot-scope="scope">{{ scope.row.Location }}</template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="描述" align="center">
|
|
|
+ <template slot-scope="scope">{{ scope.row.AcceptStation }}</template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
+ <div v-else-if="!expressLoading"
|
|
|
+ style="margin-top: 10px; padding: 24px 0; text-align: center; color: #909399;">
|
|
|
+ 暂无物流信息
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div slot="footer" class="dialog-footer">
|
|
|
+ <el-button @click="expressOpen = false">关 闭</el-button>
|
|
|
+ </div>
|
|
|
+ </el-dialog>
|
|
|
+ </div>
|
|
|
+</template>
|
|
|
+
|
|
|
+<script>
|
|
|
+import {
|
|
|
+ getIntegralAfterSales,
|
|
|
+ getIntegralAfterSalesByOrderCode,
|
|
|
+ auditIntegralAfterSales,
|
|
|
+ warehouseAuditIntegralAfterSales,
|
|
|
+ cancelIntegralAfterSales,
|
|
|
+ refundIntegralAfterSales,
|
|
|
+ updateIntegralAfterSales,
|
|
|
+ getAfterSalesExpress
|
|
|
+} from "@/api/his/integralAfterSales";
|
|
|
+
|
|
|
+export default {
|
|
|
+ name: "IntegralAfterSalesDetails",
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ loading: false,
|
|
|
+ afterSales: null,
|
|
|
+ prodList: [],
|
|
|
+ // 字典
|
|
|
+ statusOptions: [],
|
|
|
+ serviceTypeOptions: [],
|
|
|
+ // 编辑物流
|
|
|
+ deliveryOpen: false,
|
|
|
+ deliveryForm: {
|
|
|
+ id: null,
|
|
|
+ deliveryName: null,
|
|
|
+ deliverySn: null
|
|
|
+ },
|
|
|
+ deliveryRules: {
|
|
|
+ deliveryName: [{ required: true, message: '请输入物流公司名称', trigger: 'blur' }],
|
|
|
+ deliverySn: [{ required: true, message: '请输入物流单号', trigger: 'blur' }]
|
|
|
+ },
|
|
|
+ // 查看物流
|
|
|
+ expressOpen: false,
|
|
|
+ traces: [],
|
|
|
+ expressLoading: false
|
|
|
+ };
|
|
|
+ },
|
|
|
+ computed: {
|
|
|
+ /** 是否仅退款(serviceType=0) */
|
|
|
+ isRefundOnly() {
|
|
|
+ return this.afterSales != null && Number(this.afterSales.serviceType) === 0;
|
|
|
+ },
|
|
|
+ /** 仅退款步骤条active值:0→0, 1→1, 4→3(财务审核), 5→4(完成) */
|
|
|
+ refundOnlyActive() {
|
|
|
+ const status = Number(this.afterSales.status);
|
|
|
+ if (status >= 5) return 4;
|
|
|
+ if (status >= 4) return 3;
|
|
|
+ return status;
|
|
|
+ },
|
|
|
+ /** 退款退货步骤条active值:0→0, 1→1, 2→2, 3→3, 4→4, 5→6(完成) */
|
|
|
+ refundReturnActive() {
|
|
|
+ const status = Number(this.afterSales.status);
|
|
|
+ if (status >= 5) return 6;
|
|
|
+ return status;
|
|
|
+ },
|
|
|
+ /** 是否可执行财务退款:仅退款status=1 或 退款退货status=3 */
|
|
|
+ canRefund() {
|
|
|
+ if (!this.afterSales) return false;
|
|
|
+ const status = Number(this.afterSales.status);
|
|
|
+ if (this.isRefundOnly) {
|
|
|
+ return status === 1;
|
|
|
+ }
|
|
|
+ return status === 3;
|
|
|
+ }
|
|
|
+ },
|
|
|
+ created() {
|
|
|
+ this.getDicts("integral_after_sales_status").then(response => {
|
|
|
+ this.statusOptions = response.data;
|
|
|
+ });
|
|
|
+ this.getDicts("store_after_sales_service_type").then(response => {
|
|
|
+ this.serviceTypeOptions = response.data;
|
|
|
+ });
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ /** 状态标签类型 */
|
|
|
+ statusTagType(status) {
|
|
|
+ const typeMap = { 0: 'info', 1: 'warning', 2: 'warning', 3: 'primary', 4: 'danger', 5: 'success' };
|
|
|
+ return typeMap[status] || 'info';
|
|
|
+ },
|
|
|
+ /** 获取详情 */
|
|
|
+ getDetails(id) {
|
|
|
+ this.loading = true;
|
|
|
+ this.afterSales = null;
|
|
|
+ this.prodList = [];
|
|
|
+ getIntegralAfterSales(id).then(response => {
|
|
|
+ this.afterSales = response.data;
|
|
|
+ this.parseItemJson(this.afterSales.itemJson);
|
|
|
+ this.loading = false;
|
|
|
+ }).catch(() => {
|
|
|
+ this.loading = false;
|
|
|
+ });
|
|
|
+ },
|
|
|
+ /** 根据订单编号查询售后详情 */
|
|
|
+ getDetailsByOrderCode(orderCode) {
|
|
|
+ this.loading = true;
|
|
|
+ this.afterSales = null;
|
|
|
+ this.prodList = [];
|
|
|
+ getIntegralAfterSalesByOrderCode(orderCode).then(response => {
|
|
|
+ if (response.data) {
|
|
|
+ this.afterSales = response.data;
|
|
|
+ this.parseItemJson(this.afterSales.itemJson);
|
|
|
+ } else {
|
|
|
+ this.afterSales = null;
|
|
|
+ this.prodList = [];
|
|
|
+ }
|
|
|
+ this.loading = false;
|
|
|
+ }).catch(() => {
|
|
|
+ this.loading = false;
|
|
|
+ });
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * 解析积分订单 itemJson(兼容单对象和数组两种格式)
|
|
|
+ */
|
|
|
+ parseItemJson(itemJson) {
|
|
|
+ if (!itemJson) {
|
|
|
+ this.prodList = [];
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ try {
|
|
|
+ const parsed = JSON.parse(itemJson);
|
|
|
+ if (Array.isArray(parsed)) {
|
|
|
+ this.prodList = parsed;
|
|
|
+ } else {
|
|
|
+ this.prodList = [parsed];
|
|
|
+ }
|
|
|
+ } catch (e) {
|
|
|
+ this.prodList = [];
|
|
|
+ }
|
|
|
+ },
|
|
|
+ /** 平台审核 */
|
|
|
+ handleAudit() {
|
|
|
+ this.$confirm('确认平台审核通过?', '提示', {
|
|
|
+ confirmButtonText: '确定',
|
|
|
+ cancelButtonText: '取消',
|
|
|
+ type: 'warning'
|
|
|
+ }).then(() => {
|
|
|
+ auditIntegralAfterSales({ id: this.afterSales.id }).then(() => {
|
|
|
+ this.msgSuccess("审核成功");
|
|
|
+ this.getDetails(this.afterSales.id);
|
|
|
+ this.$parent.$parent.getList();
|
|
|
+ });
|
|
|
+ }).catch(() => {});
|
|
|
+ },
|
|
|
+ /** 仓库审核 */
|
|
|
+ handleWarehouseAudit() {
|
|
|
+ this.$confirm('确认仓库审核通过?', '提示', {
|
|
|
+ confirmButtonText: '确定',
|
|
|
+ cancelButtonText: '取消',
|
|
|
+ type: 'warning'
|
|
|
+ }).then(() => {
|
|
|
+ warehouseAuditIntegralAfterSales({ id: this.afterSales.id }).then(() => {
|
|
|
+ this.msgSuccess("仓库审核成功");
|
|
|
+ this.getDetails(this.afterSales.id);
|
|
|
+ this.$parent.$parent.getList();
|
|
|
+ });
|
|
|
+ }).catch(() => {});
|
|
|
+ },
|
|
|
+ /** 撤销 */
|
|
|
+ handleCancel() {
|
|
|
+ this.$confirm('确认撤销售后单?撤销后无法恢复', '提示', {
|
|
|
+ confirmButtonText: '确定',
|
|
|
+ cancelButtonText: '取消',
|
|
|
+ type: 'warning'
|
|
|
+ }).then(() => {
|
|
|
+ cancelIntegralAfterSales({ id: this.afterSales.id }).then(() => {
|
|
|
+ this.msgSuccess("撤销成功");
|
|
|
+ this.getDetails(this.afterSales.id);
|
|
|
+ this.$parent.$parent.getList();
|
|
|
+ });
|
|
|
+ }).catch(() => {});
|
|
|
+ },
|
|
|
+ /** 财务退款 */
|
|
|
+ handleRefund() {
|
|
|
+ this.$confirm('确认执行财务退款?将原路退回用户资金并退回积分', '提示', {
|
|
|
+ confirmButtonText: '确定',
|
|
|
+ cancelButtonText: '取消',
|
|
|
+ type: 'warning'
|
|
|
+ }).then(() => {
|
|
|
+ refundIntegralAfterSales({ id: this.afterSales.id }).then(() => {
|
|
|
+ this.msgSuccess("退款已发起,等待回调确认");
|
|
|
+ this.getDetails(this.afterSales.id);
|
|
|
+ this.$parent.$parent.getList();
|
|
|
+ });
|
|
|
+ }).catch(() => {});
|
|
|
+ },
|
|
|
+ /** 编辑物流 */
|
|
|
+ addDelivery() {
|
|
|
+ this.deliveryForm = {
|
|
|
+ id: this.afterSales.id,
|
|
|
+ deliveryName: this.afterSales.deliveryName,
|
|
|
+ deliverySn: this.afterSales.deliverySn
|
|
|
+ };
|
|
|
+ this.deliveryOpen = true;
|
|
|
+ },
|
|
|
+ submitDelivery() {
|
|
|
+ this.$refs["deliveryForm"].validate(valid => {
|
|
|
+ if (valid) {
|
|
|
+ updateIntegralAfterSales(this.deliveryForm).then(() => {
|
|
|
+ this.msgSuccess("保存成功");
|
|
|
+ this.deliveryOpen = false;
|
|
|
+ this.getDetails(this.afterSales.id);
|
|
|
+ this.$parent.$parent.getList();
|
|
|
+ });
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+ /** 查看寄回物流 */
|
|
|
+ showExpress() {
|
|
|
+ this.expressOpen = true;
|
|
|
+ this.traces = [];
|
|
|
+ if (this.afterSales && this.afterSales.deliverySn) {
|
|
|
+ this.expressLoading = true;
|
|
|
+ getAfterSalesExpress(this.afterSales.id).then(response => {
|
|
|
+ if (response && response.data && response.data.Traces) {
|
|
|
+ this.traces = response.data.Traces;
|
|
|
+ } else {
|
|
|
+ this.traces = [];
|
|
|
+ }
|
|
|
+ }).finally(() => {
|
|
|
+ this.expressLoading = false;
|
|
|
+ });
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+};
|
|
|
+</script>
|
|
|
+
|
|
|
+<style scoped>
|
|
|
+.order-content {
|
|
|
+ padding: 0 20px 20px;
|
|
|
+}
|
|
|
+.section-title {
|
|
|
+ padding: 15px 0;
|
|
|
+ color: #524b4a;
|
|
|
+ font-weight: bold;
|
|
|
+ font-size: 14px;
|
|
|
+}
|
|
|
+.operate-container {
|
|
|
+ background: #F2F6FC;
|
|
|
+ height: 60px;
|
|
|
+ margin: -20px -20px 0;
|
|
|
+ line-height: 60px;
|
|
|
+}
|
|
|
+.operate-button-container {
|
|
|
+ float: right;
|
|
|
+ margin-right: 20px;
|
|
|
+}
|
|
|
+.color-danger {
|
|
|
+ color: #f56c6c;
|
|
|
+}
|
|
|
+.font-small {
|
|
|
+ font-size: 14px;
|
|
|
+ color: #606266;
|
|
|
+}
|
|
|
+</style>
|
|
|
+
|
|
|
+<style>
|
|
|
+.order-content .el-descriptions-item__label.is-bordered-label {
|
|
|
+ font-weight: normal;
|
|
|
+ width: 120px;
|
|
|
+}
|
|
|
+</style>
|