This commit is contained in:
van
2026-04-10 18:57:33 +08:00
parent 92ed8c757a
commit beb784d895
2 changed files with 32 additions and 6 deletions

View File

@@ -151,10 +151,11 @@
{{ formatModifyTime(scope.row.modifyTime) }}
</template>
</el-table-column>
<el-table-column label="操作" align="center" width="200" fixed="right">
<el-table-column label="操作" align="center" width="278" fixed="right">
<template slot-scope="scope">
<el-button size="mini" type="text" @click="openJson(scope.row)" v-hasPermi="['jarvis:erpGoofishOrder:query']">详情JSON</el-button>
<el-button size="mini" type="text" @click="handleRefresh(scope.row)" v-hasPermi="['jarvis:erpGoofishOrder:edit']">刷新详情</el-button>
<el-button size="mini" type="text" class="goofish-btn-logistics" @click="handleRefreshLogistics(scope.row)" v-hasPermi="['jarvis:erpGoofishOrder:edit']">刷新物流</el-button>
<el-button size="mini" type="text" @click="handleRetryShip(scope.row)" v-hasPermi="['jarvis:erpGoofishOrder:edit']">重试发货</el-button>
</template>
</el-table-column>
@@ -566,7 +567,19 @@ export default {
refreshGoofishDetail(row.id).then(() => {
this.$modal.msgSuccess('已请求刷新详情')
this.getList()
}).catch(() => {})
},
/** 与「刷新详情」同源接口:向闲管家拉取订单详情并合并运单号、快递公司等到列表字段 */
handleRefreshLogistics(row) {
if (!row || !row.id) return
const ld = this.$loading({ lock: true, text: '正在从闲管家同步运单与快递信息…' })
refreshGoofishDetail(row.id)
.then(() => {
this.$modal.msgSuccess('已更新运单与快递信息')
this.getList()
})
.catch(() => {})
.finally(() => { ld.close() })
},
handleRetryShip(row) {
retryGoofishShip(row.id).then(() => {
@@ -616,6 +629,12 @@ export default {
.mb8 {
margin-bottom: 8px;
}
.goofish-btn-logistics {
color: #67c23a;
}
.goofish-btn-logistics:hover {
color: #85ce61;
}
.goods-cell {
display: flex;
align-items: center;

View File

@@ -292,7 +292,7 @@
:command="{action: 'fetchLogistics', row: row}"
icon="el-icon-truck"
style="color: #67C23A;">
获取物流
刷新物流
</el-dropdown-item>
<el-dropdown-item divided>
<div style="display: flex; align-items: center; justify-content: space-between; padding: 0 10px;">
@@ -361,6 +361,13 @@
<span class="field-label">地址</span>
<span class="field-value address-text">{{ row.address || '-' }}</span>
</div>
<div class="field-row field-row--logistics-refresh">
<span class="field-label">物流</span>
<span class="field-value">
<el-button type="primary" plain size="mini" icon="el-icon-truck" @click="handleFetchLogistics(row)">手动刷新物流</el-button>
<el-button v-if="row.logisticsLink" type="text" size="mini" @click="copyToClipboard(row.logisticsLink)">复制物流链接</el-button>
</span>
</div>
<div class="field-row">
<span class="field-label">付款金额</span>
<span class="field-value amount">{{ toYuan(row.paymentAmount) }}</span>
@@ -792,7 +799,7 @@
:command="{action: 'fetchLogistics', row: scope.row}"
icon="el-icon-truck"
style="color: #67C23A;">
获取物流
刷新物流
</el-dropdown-item>
<el-dropdown-item divided>
<div style="display: flex; align-items: center; justify-content: space-between; padding: 0 10px;">
@@ -830,7 +837,7 @@
<div class="jd-action-row jd-action-row--doc">
<el-button type="text" size="mini" class="jd-act-link jd-act-link--accent" :class="{ 'jd-act-done': isExcelTextCopied(scope.row.id) }" icon="el-icon-document-copy" @click="copySingleOrderExcelText(scope.row)" :title="isExcelTextCopied(scope.row.id) ? '已复制录单格式' : '复制录单格式'">录单</el-button>
<el-button type="text" size="mini" class="jd-act-link jd-act-link--accent" icon="el-icon-document-copy" @click="copyRebateRecordText(scope.row)" title="复制后返录表">后返</el-button>
<el-button type="text" size="mini" class="jd-act-link jd-act-link--success" @click="handleFetchLogistics(scope.row)" title="获取物流">物流拉取</el-button>
<el-button type="text" size="mini" class="jd-act-link jd-act-link--success" @click="handleFetchLogistics(scope.row)" title="按物流链接调用扫描服务拉取最新轨迹">刷新物流</el-button>
</div>
<div class="jd-action-row jd-action-row--meta">
<div class="jd-count-pill" title="是否参与利润等汇总统计">
@@ -868,7 +875,7 @@
<!-- 获取物流信息对话框 -->
<el-dialog
title="获取物流信息(调试)"
title="刷新物流信息"
:visible.sync="fetchLogisticsDialogVisible"
width="800px"
:close-on-click-modal="false"