MrShi
2026-05-20 777bcb6c5660c0ed14d85207377b62b779d81dde
admin/src/views/business/orderManagement.vue
@@ -20,7 +20,7 @@
      <el-form-item label="类型" prop="type">
        <el-select v-model="searchForm.type" clearable placeholder="请选择类型" @change="search">
          <el-option label="就地存取" :value="0"></el-option>
          <el-option label="异地存取" :value="1"></el-option>
          <el-option label="同城寄送" :value="1"></el-option>
        </el-select>
      </el-form-item>
      <el-form-item label="订单状态" prop="status">
@@ -64,11 +64,13 @@
        <el-table-column label="类型" min-width="80px">
          <template slot-scope="{row}">
            <span v-if="row.type === 0">就地存取</span>
            <span v-else-if="row.type === 1">异地存取</span>
            <span v-else-if="row.type === 1">同城寄送</span>
            <span v-else>-</span>
          </template>
        </el-table-column>
        <el-table-column prop="orderLevel" label="订单级别" min-width="80px"></el-table-column>
        <el-table-column prop="isUrgent" label="订单级别" min-width="80px">
          <template slot-scope="{row}"><span v-if="row.type ===1">{{ row.isUrgent === 1?'极速达':'标速达' }}</span></template>
        </el-table-column>
        <el-table-column label="物品保费(元)" min-width="120px">
          <template slot-scope="{row}">¥{{ (row.declaredFee / 100).toFixed(2) }}</template>
        </el-table-column>
@@ -81,6 +83,9 @@
        <el-table-column label="实付现金(元)" min-width="120px">
          <template slot-scope="{row}">¥{{ (row.payAmount / 100).toFixed(2) }}</template>
        </el-table-column>
        <el-table-column label="加急费(元)" min-width="120px">
          <template slot-scope="{row}"><span v-if="row.type ===1 ">¥{{ (row.platformRewardAmount / 100).toFixed(2) }}</span></template>
        </el-table-column>
        <el-table-column label="退款金额(元)" min-width="120px">
          <template slot-scope="{row}">¥{{ (row.refundAmount / 100).toFixed(2) }}</template>
        </el-table-column>
@@ -88,7 +93,10 @@
          <template slot-scope="{row}">¥{{ (row.overdueAmount / 100).toFixed(2) }}</template>
        </el-table-column>
        <el-table-column label="异常金额" min-width="100px">
          <template slot-scope="{row}">¥{{ (row.exceptionAmount / 100).toFixed(2) }}</template>
          <template slot-scope="{row}">¥{{ ((row.exceptionAmount || 0) / 100).toFixed(2) }}</template>
        </el-table-column>
        <el-table-column label="优惠卷抵扣" min-width="100px">
          <template slot-scope="{row}">¥{{ ((row.deductionAmount || 0) / 100).toFixed(2) }}</template>
        </el-table-column>
        <el-table-column  prop="statusDesc"  label="订单状态" min-width="100px">
          <template slot-scope="{row}">
@@ -104,9 +112,13 @@
            </span>
          </template>
        </el-table-column>
        <el-table-column label="操作" min-width="120" fixed="right">
        <el-table-column prop="payTime" label="支付时间" min-width="150px"> </el-table-column>
        <el-table-column prop="createTime" label="创建时间" min-width="150px"> </el-table-column>
        <el-table-column label="操作" min-width="180" fixed="right">
          <template slot-scope="{row}">
            <el-button type="text" v-if="row.status ===2" @click="handleDispatch(row)">手动派单</el-button>
            <el-button type="text" v-if="row.status === 2" @click="handleDispatch(row)">手动派单</el-button>
            <el-button type="text" v-if="row.status === 7" @click="handleManualRefund(row)">手动退款</el-button>
            <el-button type="text" v-if="row.status === 4 && !row.takeShopId && row.exceptionStatus === 0" @click="handleAbnormal(row)">异常派单</el-button>
          </template>
        </el-table-column>
      </el-table>
@@ -118,6 +130,8 @@
    </template>
    <OperaDispatch ref="operaDispatch" @success="handlePageChange" />
    <OperaOrderDetail ref="operaOrderDetail"  @success="handlePageChange"  />
    <OperaManualRefund ref="operaManualRefund" @success="handlePageChange" />
    <OperaAbnormal ref="operaAbnormal" @success="handlePageChange" />
  </TableLayout>
</template>
@@ -127,10 +141,12 @@
import Pagination from '@/components/common/Pagination'
import OperaDispatch from '@/components/business/OperaDispatch'
import OperaOrderDetail from '@/components/business/OperaOrderDetail'
import OperaManualRefund from '@/components/business/OperaManualRefund'
import OperaAbnormal from '@/components/business/OperaAbnormal'
export default {
  name: 'OrderManagement',
  extends: BaseTable,
  components: { TableLayout, Pagination, OperaDispatch, OperaOrderDetail },
  components: { TableLayout, Pagination, OperaDispatch, OperaOrderDetail, OperaManualRefund, OperaAbnormal },
  data () {
    return {
      searchForm: {
@@ -155,6 +171,9 @@
    this.search()
  },
  methods: {
    handleAbnormal (row) {
      this.$refs.operaAbnormal.open('异常派单', row)
    },
    handleDateChange (val) {
      this.searchForm.createStartTime = val ? val[0] : ''
      this.searchForm.createEndTime = val ? val[1] : ''
@@ -178,6 +197,13 @@
    handleDispatch (row) {
      this.$refs.operaDispatch.open(row)
    },
    handleManualRefund (row) {
      this.$refs.operaManualRefund.open(row)
    },
    handleExceptionDispatch (row) {
      // 异常派单逻辑
      this.$message.info('异常派单功能待实现')
    },
    handleOrderDetail (row) {
      this.$refs.operaOrderDetail.open(row)
    }