mirror of
https://gitee.com/beijing_hongye_huicheng/lilishop-ui.git
synced 2026-11-12 20:08:59 +08:00
refactor: 统一组件导入方式与样式调整
- 将多个组件中的 require 替换为 import,提升代码一致性。 - 更新上传组件中的回调函数,简化图片选择逻辑。 - 调整样式以适配 Element Plus 组件,确保界面一致性。 - 删除不再使用的样式,优化项目结构。
This commit is contained in:
@@ -69,6 +69,7 @@
|
||||
</template>
|
||||
<script>
|
||||
import * as API_Order from "@/api/order";
|
||||
import { ElMessage, ElMessageBox } from "element-plus";
|
||||
|
||||
export default {
|
||||
data() {
|
||||
@@ -143,7 +144,7 @@ export default {
|
||||
API_Order.addAfterSaleReason(this.form).then((res) => {
|
||||
this.submitLoading = false;
|
||||
if (res.success) {
|
||||
this.$Message.success("添加成功");
|
||||
ElMessage.success("添加成功");
|
||||
this.getDataList();
|
||||
this.modalVisible = false;
|
||||
}
|
||||
@@ -152,7 +153,7 @@ export default {
|
||||
API_Order.editAfterSaleReason(this.form.id, this.form).then((res) => {
|
||||
this.submitLoading = false;
|
||||
if (res.success) {
|
||||
this.$Message.success("修改成功");
|
||||
ElMessage.success("修改成功");
|
||||
this.getDataList();
|
||||
this.modalVisible = false;
|
||||
}
|
||||
@@ -162,20 +163,14 @@ export default {
|
||||
});
|
||||
},
|
||||
remove(v) {
|
||||
this.$Modal.confirm({
|
||||
title: "确认删除",
|
||||
content: "确认要删除此售后原因?",
|
||||
loading: true,
|
||||
onOk: () => {
|
||||
API_Order.delAfterSaleReason(v.id).then((res) => {
|
||||
this.$Modal.remove();
|
||||
if (res.success) {
|
||||
this.$Message.success("售后原因已删除");
|
||||
this.getDataList();
|
||||
}
|
||||
});
|
||||
},
|
||||
});
|
||||
ElMessageBox.confirm("确认要删除此售后原因?", "确认删除", { type: "warning" }).then(() => {
|
||||
API_Order.delAfterSaleReason(v.id).then((res) => {
|
||||
if (res.success) {
|
||||
ElMessage.success("售后原因已删除");
|
||||
this.getDataList();
|
||||
}
|
||||
});
|
||||
}).catch(() => {});
|
||||
},
|
||||
},
|
||||
mounted() {
|
||||
|
||||
@@ -126,7 +126,7 @@
|
||||
<el-table-column label="售后金额" width="110">
|
||||
<template #default="{ row }">
|
||||
<span v-if="row" :style="{ color: $mainColor }">
|
||||
{{ $filters.unitPrice(row.applyRefundPrice, "¥") }}</span>
|
||||
{{ unitPrice(row.applyRefundPrice, "¥") }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="售后类型" width="100">
|
||||
@@ -169,6 +169,7 @@
|
||||
|
||||
<script>
|
||||
import * as API_Order from "@/api/order";
|
||||
import { unitPrice, customRouterPush } from "@/utils/filters";
|
||||
|
||||
export default {
|
||||
name: "after-sale-order",
|
||||
@@ -240,6 +241,7 @@ export default {
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
unitPrice,
|
||||
serviceTypeText(type) {
|
||||
const map = {
|
||||
RETURN_MONEY: "退款",
|
||||
@@ -330,7 +332,7 @@ export default {
|
||||
},
|
||||
detail(v) {
|
||||
const sn = v.sn;
|
||||
this.$filters.customRouterPush({
|
||||
customRouterPush({
|
||||
name: "after-order-detail",
|
||||
query: { sn: sn },
|
||||
});
|
||||
|
||||
@@ -335,6 +335,7 @@
|
||||
<script>
|
||||
import * as API_Order from "@/api/order";
|
||||
import vueQr from "vue-qr";
|
||||
import { ElMessage, ElMessageBox } from "element-plus";
|
||||
export default {
|
||||
components: {
|
||||
"vue-qr": vueQr,
|
||||
@@ -442,23 +443,17 @@ export default {
|
||||
//平台退款
|
||||
refundPriceSubmit() {
|
||||
if (this.refundPriceForm.remark == "") {
|
||||
this.$Message.error("请输入退款备注");
|
||||
ElMessage.error("请输入退款备注");
|
||||
return;
|
||||
}
|
||||
this.$Modal.confirm({
|
||||
title: "确认退款",
|
||||
content: "请确认退款?",
|
||||
loading: true,
|
||||
onOk: () => {
|
||||
API_Order.refundPrice(this.sn, this.refundPriceForm).then((res) => {
|
||||
this.$Modal.remove();
|
||||
if (res.success) {
|
||||
this.$Message.success("收款成功");
|
||||
this.getDetail();
|
||||
}
|
||||
});
|
||||
},
|
||||
});
|
||||
ElMessageBox.confirm("请确认退款?", "确认退款", { type: "warning" }).then(() => {
|
||||
API_Order.refundPrice(this.sn, this.refundPriceForm).then((res) => {
|
||||
if (res.success) {
|
||||
ElMessage.success("收款成功");
|
||||
this.getDetail();
|
||||
}
|
||||
});
|
||||
}).catch(() => {});
|
||||
},
|
||||
//查询物流
|
||||
logisticsSeller() {
|
||||
@@ -476,17 +471,17 @@ export default {
|
||||
//回复
|
||||
handleSubmit() {
|
||||
if (this.params.remark == "") {
|
||||
this.$Message.error("请输入备注信息");
|
||||
ElMessage.error("请输入备注信息");
|
||||
return;
|
||||
}
|
||||
if (this.params.actualRefundPrice == "") {
|
||||
this.$Message.error("请输入退款金额");
|
||||
ElMessage.error("请输入退款金额");
|
||||
return;
|
||||
}
|
||||
API_Order.afterSaleSellerReview(this.sn, this.params).then((res) => {
|
||||
this.submitLoading = false;
|
||||
if (res.success) {
|
||||
this.$Message.success("审核成功");
|
||||
ElMessage.success("审核成功");
|
||||
this.params.remark = "";
|
||||
this.getDetail();
|
||||
}
|
||||
@@ -518,9 +513,6 @@ export default {
|
||||
};
|
||||
</script>
|
||||
<style lang="scss">
|
||||
.ivu-col {
|
||||
width: 100% !important;
|
||||
}
|
||||
.main-content {
|
||||
min-height: 600px;
|
||||
padding: 10px;
|
||||
|
||||
@@ -107,6 +107,7 @@
|
||||
<script>
|
||||
import * as API_Order from "@/api/order";
|
||||
import vueQr from "vue-qr";
|
||||
import { customRouterPush } from "@/utils/filters";
|
||||
|
||||
export default {
|
||||
name: "orderComplaint",
|
||||
@@ -184,7 +185,7 @@ export default {
|
||||
});
|
||||
},
|
||||
detail(v) {
|
||||
this.$filters.customRouterPush({
|
||||
customRouterPush({
|
||||
name: "order-complaint-detail",
|
||||
query: { id: v.id },
|
||||
});
|
||||
|
||||
@@ -178,7 +178,7 @@
|
||||
<dl>
|
||||
<dt>订单金额</dt>
|
||||
<dd>
|
||||
<span class="price-text">{{ $filters.unitPrice(complaintInfo.orderPrice, "¥") }}</span>
|
||||
<span class="price-text">{{ unitPrice(complaintInfo.orderPrice, "¥") }}</span>
|
||||
</dd>
|
||||
</dl>
|
||||
</div>
|
||||
@@ -205,6 +205,8 @@
|
||||
|
||||
<script>
|
||||
import * as API_Order from "@/api/order";
|
||||
import { ElMessage } from "element-plus";
|
||||
import { unitPrice } from "@/utils/filters";
|
||||
|
||||
const emptyComplaint = () => ({
|
||||
id: "",
|
||||
@@ -232,6 +234,7 @@ export default {
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
unitPrice,
|
||||
complainStatusText(v) {
|
||||
const map = {
|
||||
NEW: "新投诉",
|
||||
@@ -249,7 +252,7 @@ export default {
|
||||
complainId: this.complaintInfo.id,
|
||||
}).then((res) => {
|
||||
if (res.success) {
|
||||
this.$Message.success("操作成功");
|
||||
ElMessage.success("操作成功");
|
||||
this.getDetail();
|
||||
}
|
||||
});
|
||||
@@ -284,7 +287,7 @@ export default {
|
||||
},
|
||||
arbitrationHandleSubmit() {
|
||||
if (!this.arbitrationParams.arbitrationResult) {
|
||||
this.$Message.error("请填写仲裁内容");
|
||||
ElMessage.error("请填写仲裁内容");
|
||||
return;
|
||||
}
|
||||
this.submitLoading = true;
|
||||
@@ -292,7 +295,7 @@ export default {
|
||||
.then((res) => {
|
||||
this.submitLoading = false;
|
||||
if (res.success) {
|
||||
this.$Message.success("仲裁成功");
|
||||
ElMessage.success("仲裁成功");
|
||||
this.arbitrationParams.arbitrationResult = "";
|
||||
this.arbitrationResultShow = false;
|
||||
this.getDetail();
|
||||
@@ -304,7 +307,7 @@ export default {
|
||||
},
|
||||
handleSubmit() {
|
||||
if (!this.params.content) {
|
||||
this.$Message.error("请填写对话内容");
|
||||
ElMessage.error("请填写对话内容");
|
||||
return;
|
||||
}
|
||||
this.submitLoading = true;
|
||||
@@ -313,7 +316,7 @@ export default {
|
||||
.then((res) => {
|
||||
this.submitLoading = false;
|
||||
if (res.success) {
|
||||
this.$Message.success("对话成功");
|
||||
ElMessage.success("对话成功");
|
||||
this.params.content = "";
|
||||
this.getDetail();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user