|
|
@@ -76,9 +76,9 @@
|
|
|
<el-icon><component :is="tab.icon" /></el-icon><span>{{ tab.label }}</span>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <el-button type="danger" link
|
|
|
+ <!-- <el-button type="danger" link
|
|
|
><el-icon><Delete /></el-icon>订单回收站</el-button
|
|
|
- >
|
|
|
+ > -->
|
|
|
</div>
|
|
|
<!-- 订单列表 -->
|
|
|
<div class="order-list">
|
|
|
@@ -132,22 +132,16 @@
|
|
|
<div v-else style="width: 200px"></div>
|
|
|
<div class="status-cell" v-if="itemIndex === 0">
|
|
|
<div class="status-info">
|
|
|
- <span
|
|
|
- class="status-text"
|
|
|
- :class="{ 'clickable': order.statusText === '待支付' }"
|
|
|
- :style="{ color: getStatusColor(order.status) }"
|
|
|
- @click="order.statusText === '待支付' && handlePayment(order)"
|
|
|
- >{{ order.statusText }}</span
|
|
|
- >
|
|
|
- <span
|
|
|
- v-if="order.auditStatus"
|
|
|
- :class="['audit-status', getAuditStatusClass(order.auditStatus), 'clickable-audit']"
|
|
|
- @click="order.auditStatus == '0' && handleAudit(order)"
|
|
|
- >
|
|
|
+ <span class="status-text" :style="{ color: getStatusColor(order.status) }">{{ order.statusText }}</span>
|
|
|
+ </div>
|
|
|
+ <div class="status-info">
|
|
|
+ <span class="status-text" v-if="order.auditStatus">
|
|
|
{{ order.auditStatus == '0' ? '待审批' : order.auditStatus == '1' ? '' : '审批驳回' }}</span
|
|
|
>
|
|
|
</div>
|
|
|
<div class="action-buttons">
|
|
|
+ <el-button type="primary" v-if="order.statusText === '待支付'" link @click="handlePayment(order)"> 支付订单 </el-button>
|
|
|
+ <el-button type="primary" v-if="order.auditStatus == '0'" link @click="handleAudit(order)"> 审批订单 </el-button>
|
|
|
<el-button type="primary" v-if="order.statusText == '发货完成'" link @click="handleConfirmReceipt(order)">确认收货</el-button>
|
|
|
<el-button type="primary" v-if="order.statusText == '已完成' && order.evaluationStatus == '0'" link @click="handleEvaluation(order)"
|
|
|
>评价</el-button
|
|
|
@@ -372,7 +366,7 @@ const loadDeptTree = async () => {
|
|
|
|
|
|
/** 单个加入购物车 */
|
|
|
const handleAddCart = async (item: any) => {
|
|
|
- addProductShoppingCart({ productId: item.id, productNum: 1 }).then((res: any) => {
|
|
|
+ addProductShoppingCart({ productId: item.productId, productNum: 1 }).then((res: any) => {
|
|
|
if (res.code == 200) {
|
|
|
ElMessage.success('已加入购物车');
|
|
|
}
|
|
|
@@ -643,6 +637,11 @@ const handleAudit = (order: any) => {
|
|
|
|
|
|
const handleConfirmReceipt = async (order: any) => {
|
|
|
try {
|
|
|
+ await ElMessageBox.confirm('确定要确认收货吗?', '提示', {
|
|
|
+ confirmButtonText: '确定',
|
|
|
+ cancelButtonText: '取消',
|
|
|
+ type: 'warning'
|
|
|
+ });
|
|
|
const res = await batchConfirmation([order.id]);
|
|
|
if (res.code === 200) {
|
|
|
ElMessage.success('确认收货成功');
|