From 5abcde36961125cbf436f91b8c17610a6b5f8308 Mon Sep 17 00:00:00 2001
From: sen <sen@qq.com>
Date: 星期三, 15 四月 2026 12:15:08 +0800
Subject: [PATCH] 修改调度单必填校验
---
ui/admin-ui3/src/views/tms/tmsDispatchFeeSummary/index.vue | 453 +++++++++++++++++++++++++++++++++----------------------
1 files changed, 270 insertions(+), 183 deletions(-)
diff --git a/ui/admin-ui3/src/views/tms/tmsDispatchFeeSummary/index.vue b/ui/admin-ui3/src/views/tms/tmsDispatchFeeSummary/index.vue
index 52983c7..e855c26 100644
--- a/ui/admin-ui3/src/views/tms/tmsDispatchFeeSummary/index.vue
+++ b/ui/admin-ui3/src/views/tms/tmsDispatchFeeSummary/index.vue
@@ -1,95 +1,80 @@
<template>
<basicContainer>
- <avue-crud
- :option="option"
- :table-loading="pageF.loading"
- :data="tableData"
- :page="page"
- :permission="permissionList"
- :before-open="beforeOpen"
- v-model="form" v-model:search="queryParams"
- ref="crudRef"
- @refresh-change="refreshChange"
- @search-change="searchChange"
- @search-reset="searchReset"
- @selection-change="selectionChange"
- @current-change="currentChange"
- @size-change="sizeChange"
- @on-load="onLoad"
- >
+ <avue-crud :option="option" :table-loading="pageF.loading" :data="tableData" :page="page"
+ :permission="permissionList" :before-open="beforeOpen" v-model="form" v-model:search="queryParams" ref="crudRef"
+ @refresh-change="refreshChange" @search-change="searchChange" @search-reset="searchReset"
+ @selection-change="selectionChange" @current-change="currentChange" @size-change="sizeChange" @on-load="onLoad">
+ <template #remark="{ row }">
+ <el-input v-model="row.remark" readonly placeholder="鏆傛棤澶囨敞" @click="handleRemarkClick(row)"
+ style="cursor: pointer;" />
+ </template>
<template #menu-left>
- <el-button
- type="warning"
- plain
- icon="Download"
- @click="handleExport"
- v-hasPermi="['tms:tmsDriver:export']"
- >瀵煎嚭
+ <el-button type="warning" plain icon="Download" @click="handleExport" v-hasPermi="['tms:tmsDriver:export']">瀵煎嚭
</el-button>
</template>
- <template #address="{row}">
- <div class="hot" @click="handleLogItinerary(row)">
- <div>璧凤細{{row.shipperRegionLabel?.split('/').pop()}}({{row.shipperAddress}})</div>
- <div>鎶碉細{{row.receiverRegionLabel?.split('/').pop()}}({{row.receiverAddress}})</div>
- </div>
+ <template #address="{ row }">
+ <div class="hot" @click="handleLogItinerary(row)">
+ <div>璧凤細{{ row.shipperRegionLabel?.split('/').pop() }}({{ row.shipperAddress }})</div>
+ <div>鎶碉細{{ row.receiverRegionLabel?.split('/').pop() }}({{ row.receiverAddress }})</div>
+ </div>
</template>
- <template #license="{row}">
- <div>{{row.licensePlate}}</div>
- <div>{{row.licenseHk}}</div>
- <div>{{row.licenseMo}}</div>
+ <template #license="{ row }">
+ <div>{{ row.licensePlate }}</div>
+ <div>{{ row.licenseHk }}</div>
+ <div>{{ row.licenseMo }}</div>
</template>
- <template #shelfCodeAndContainerNo="{row}">
- <div>{{row.shelfCode}}</div>
- <div>{{row.containerNo}}</div>
+ <template #shelfCodeAndContainerNo="{ row }">
+ <div>{{ row.shelfCode }}</div>
+ <div>{{ row.containerNo }}</div>
</template>
- <template #pShippingFee="{row}">
- <div v-if="row.rshippingFeeRmb">{{row.rshippingFeeRmb}}RMB</div>
- <div v-if="row.rshippingFeeHkd">{{row.rshippingFeeHkd}}HKD</div>
+ <template #pShippingFee="{ row }">
+ <div v-if="row.rshippingFeeRmb">{{ row.rshippingFeeRmb }}RMB</div>
+ <div v-if="row.rshippingFeeHkd">{{ row.rshippingFeeHkd }}HKD</div>
</template>
- <template #pServerFee="{row}">
- <div v-if="row.pserverFeeRmb">{{row.pserverFeeRmb}}RMB</div>
- <div v-if="row.pserverFeeHkd">{{row.pserverFeeHkd}}HKD</div>
+ <template #pServerFee="{ row }">
+ <div v-if="row.pserverFeeRmb">{{ row.pserverFeeRmb }}RMB</div>
+ <div v-if="row.pserverFeeHkd">{{ row.pserverFeeHkd }}HKD</div>
</template>
- <template #pActualFee="{row}">
- <div v-if="row.pactualFeeRmb">{{row.pactualFeeRmb}}RMB</div>
- <div v-if="row.pactualFeeHkd">{{row.pactualFeeHkd}}HKD</div>
+ <template #pActualFee="{ row }">
+ <div v-if="row.pactualFeeRmb">{{ row.pactualFeeRmb }}RMB</div>
+ <div v-if="row.pactualFeeHkd">{{ row.pactualFeeHkd }}HKD</div>
</template>
- <template #pTotal="{row}">
+ <template #pTotal="{ row }">
<div class="hot" @click="handlePayableFeeView(row)">
- <div v-if="row.ptotalRmb">{{row.ptotalRmb}}RMB</div>
- <div v-if="row.ptotalHkd">{{row.ptotalHkd}}HKD</div>
+ <div v-if="row.ptotalRmb">{{ row.ptotalRmb }}RMB</div>
+ <div v-if="row.ptotalHkd">{{ row.ptotalHkd }}HKD</div>
</div>
</template>
- <template #rShippingFee="{row}">
- <div v-if="row.rshippingFeeRmb">{{row.rshippingFeeRmb}}RMB</div>
- <div v-if="row.rshippingFeeHkd">{{row.rshippingFeeRmb}}HKD</div>
+ <template #rShippingFee="{ row }">
+ <div v-if="row.rshippingFeeRmb">{{ row.rshippingFeeRmb }}RMB</div>
+ <div v-if="row.rshippingFeeHkd">{{ row.rshippingFeeRmb }}HKD</div>
</template>
- <template #rServerFee="{row}">
- <div v-if="row.rserverFeeRmb">{{row.rserverFeeRmb}}RMB</div>
- <div v-if="row.rserverFeeHkd ">{{row.rserverFeeHkd}}HKD</div>
+ <template #rServerFee="{ row }">
+ <div v-if="row.rserverFeeRmb">{{ row.rserverFeeRmb }}RMB</div>
+ <div v-if="row.rserverFeeHkd">{{ row.rserverFeeHkd }}HKD</div>
</template>
- <template #rActualFee="{row}">
- <div v-if="row.ractualFeeRmb">{{row.ractualFeeRmb}}RMB</div>
- <div v-if="row.ractualFeeHkd">{{row.ractualFeeHkd}}HKD</div>
+ <template #rActualFee="{ row }">
+ <div v-if="row.ractualFeeRmb">{{ row.ractualFeeRmb }}RMB</div>
+ <div v-if="row.ractualFeeHkd">{{ row.ractualFeeHkd }}HKD</div>
</template>
- <template #rTotal="{row}">
+ <template #rTotal="{ row }">
<div class="hot" @click="handleReceivableFeeView(row)">
- <div v-if="row.rtotalRmb">{{row.rtotalRmb}}RMB</div>
- <div v-if="row.rtotalHkd">{{row.rtotalHkd}}HKD</div>
+ <div v-if="row.rtotalRmb">{{ row.rtotalRmb }}RMB</div>
+ <div v-if="row.rtotalHkd">{{ row.rtotalHkd }}HKD</div>
</div>
</template>
- <template #grossProfit="{row}">
- <div v-if="row.grossProfitRmb">{{row.grossProfitRmb}}RMB</div>
- <div v-if="row.grossProfitHkd">{{row.grossProfitHkd}}HKD</div>
+ <template #grossProfit="{ row }">
+ <div v-if="row.grossProfitRmb">{{ row.grossProfitRmb }}RMB</div>
+ <div v-if="row.grossProfitHkd">{{ row.grossProfitHkd }}HKD</div>
</template>
- <template #grossProfitRadio="{row}">
- <div v-if="row.grossProfitRadioRmb">RMB:{{row.grossProfitRadioRmb}}%</div>
- <div v-if="row.grossProfitRadioHkd">HKD:{{row.grossProfitRadioHkd}}%</div>
+ <template #grossProfitRadio="{ row }">
+ <div v-if="row.grossProfitRadioRmb">RMB:{{ row.grossProfitRadioRmb }}%</div>
+ <div v-if="row.grossProfitRadioHkd">HKD:{{ row.grossProfitRadioHkd }}%</div>
</template>
@@ -100,38 +85,32 @@
<el-dialog :title="pageF.title" v-model="pageF.open" class="avue-dialog avue-dialog--top" width="80%">
<div v-if="optionType == 'receivableFee'">
<el-descriptions :column="3" border>
- <el-descriptions-item label="搴旀敹璐圭敤缂栧彿">{{form.systemNo}}</el-descriptions-item>
- <el-descriptions-item label="璋冨害鍗曞彿">{{form.dispatchNo}}</el-descriptions-item>
- <el-descriptions-item label="瀹㈡埛鍚嶇О">{{form.customerName}}</el-descriptions-item>
- <el-descriptions-item label="椤圭洰鍚嶇О">{{form.projectName}}</el-descriptions-item>
- <el-descriptions-item label="璋冨害鍗曠‘瀹氭椂闂�">{{form.dispatchConfirmTime}}</el-descriptions-item>
- <el-descriptions-item label="璐圭敤鐢熸垚鏃堕棿">{{form.costGenerateTime}}</el-descriptions-item>
- <el-descriptions-item label="鍏宠仈璐﹀崟缂栧彿">{{form.billRelationNo}}</el-descriptions-item>
- <el-descriptions-item label="搴旀敹閲戦浜烘皯甯�">{{form.receivableRMBAmount}}</el-descriptions-item>
- <el-descriptions-item label="搴旀敹閲戦娓竵">{{form.receivableHKBAmount}}</el-descriptions-item>
+ <el-descriptions-item label="搴旀敹璐圭敤缂栧彿">{{ form.systemNo }}</el-descriptions-item>
+ <el-descriptions-item label="璋冨害鍗曞彿">{{ form.dispatchNo }}</el-descriptions-item>
+ <el-descriptions-item label="瀹㈡埛鍚嶇О">{{ form.customerName }}</el-descriptions-item>
+ <el-descriptions-item label="椤圭洰鍚嶇О">{{ form.projectName }}</el-descriptions-item>
+ <el-descriptions-item label="璋冨害鍗曠‘瀹氭椂闂�">{{ form.dispatchConfirmTime }}</el-descriptions-item>
+ <el-descriptions-item label="璐圭敤鐢熸垚鏃堕棿">{{ form.costGenerateTime }}</el-descriptions-item>
+ <el-descriptions-item label="鍏宠仈璐﹀崟缂栧彿">{{ form.billRelationNo }}</el-descriptions-item>
+ <el-descriptions-item label="搴旀敹閲戦浜烘皯甯�">{{ form.receivableRMBAmount }}</el-descriptions-item>
+ <el-descriptions-item label="搴旀敹閲戦娓竵">{{ form.receivableHKBAmount }}</el-descriptions-item>
</el-descriptions>
<h3>璐圭敤鏄庣粏</h3>
</div>
- <avue-crud
- :option="boxTableOption" ref="itemsTableRef"
- :data="boxTableData"
- >
- <template #expand="{row}">
- <avue-crud
- :option="boxItemTableOption" ref="itemsTableRef2"
- :data="row.payableFeeItems"
- >
+ <avue-crud :option="boxTableOption" ref="itemsTableRef" :data="boxTableData">
+ <template #expand="{ row }">
+ <avue-crud :option="boxItemTableOption" ref="itemsTableRef2" :data="row.payableFeeItems">
</avue-crud>
</template>
- <template #receivableAmount="{row}">
- <div v-if="row.receivableAmountRMB > 0">{{row.receivableAmountRMB}}浜烘皯甯�</div>
- <div v-if="row.receivableAmountHKD > 0">{{row.receivableAmountHKD}}娓竵</div>
+ <template #receivableAmount="{ row }">
+ <div v-if="row.receivableAmountRMB > 0">{{ row.receivableAmountRMB }}浜烘皯甯�</div>
+ <div v-if="row.receivableAmountHKD > 0">{{ row.receivableAmountHKD }}娓竵</div>
</template>
- <template #payableAmount="{row}">
- <div v-if="row.payableRmbAmount > 0">{{row.payableRmbAmount}}浜烘皯甯�</div>
- <div v-if="row.payableHkbAmount > 0">{{row.payableHkbAmount}}娓竵</div>
+ <template #payableAmount="{ row }">
+ <div v-if="row.payableRmbAmount > 0">{{ row.payableRmbAmount }}浜烘皯甯�</div>
+ <div v-if="row.payableHkbAmount > 0">{{ row.payableHkbAmount }}娓竵</div>
</template>
</avue-crud>
@@ -143,23 +122,38 @@
</template>
</el-dialog>
+ <el-dialog :title="remarkBox.title" v-model="remarkBox.open" width="500px">
+ <div style="margin-bottom: 20px;">
+ <el-input v-model="remarkBox.content" type="textarea" :rows="4" placeholder="璇疯緭鍏ュ娉ㄥ唴瀹�" />
+ <div style="margin-top: 15px; text-align: right;">
+ <el-button @click="remarkBox.open = false">鍙� 娑�</el-button>
+ <el-button type="primary" @click="submitRemark">纭� 瀹�</el-button>
+ </div>
+ </div>
+
+ <el-table :data="remarkBox.list" border stripe size="small">
+ <el-table-column prop="createTime" label="鎿嶄綔鏃堕棿" width="160" />
+ <el-table-column prop="createBy" label="鎿嶄綔浜�" width="100" />
+ <el-table-column prop="notes" label="澶囨敞鍐呭" />
+ </el-table>
+ </el-dialog>
</template>
<script setup name="tmsDriver" lang="ts">
import {
- listTmsDispatchFeeSummaryVi,exportTmsDispatchFeeSummaryVi
+ listTmsDispatchFeeSummaryVi, exportTmsDispatchFeeSummaryVi, tmsDispatchFeeSummaryViNote
} from "@/api/tms/tmsDispatchFeeSummary";
import useCurrentInstance from "@/utils/useCurrentInstance";
-import {computed, onMounted, reactive, ref, toRefs, watch} from "vue";
-import {PagesInterface, PageQueryInterface} from "@/utils/globalInterface";
-import {usePagePlus} from "@/hooks/usePagePlus";
-import {hasPermission} from "@/utils/permissionUtils";
-import {getTmsServiceProvider, listTmsServiceProvider} from "@/api/tms/tmsServiceProvider";
-import {listTmsTrip} from "@/api/tms/tmsTrip";
-import {getTmsReceivableFeeByDispatchNo} from "@/api/tms/tmsReceivableFee";
-import {getTmsPayableFeeByDispatchNo} from "@/api/tms/tmsPayableFee";
-
-const {proxy} = useCurrentInstance();
+import { computed, onMounted, reactive, ref, toRefs, watch } from "vue";
+import { PagesInterface, PageQueryInterface } from "@/utils/globalInterface";
+import { usePagePlus } from "@/hooks/usePagePlus";
+import { hasPermission } from "@/utils/permissionUtils";
+import { getTmsServiceProvider, listTmsServiceProvider } from "@/api/tms/tmsServiceProvider";
+import { listTmsTrip } from "@/api/tms/tmsTrip";
+import { getTmsReceivableFeeByDispatchNo } from "@/api/tms/tmsReceivableFee";
+import { getTmsPayableFeeByDispatchNo } from "@/api/tms/tmsPayableFee";
+import { listDispatchFeeSummaryViLog } from "@/api/tms/dispatchFeeSummaryViLog";
+const { proxy } = useCurrentInstance();
const crudRef = ref();
const permissionList = computed(() => {
@@ -180,12 +174,12 @@
currentPage: 1,
},
selectionList: [],
- boxTableOption:<any>{},
- boxTableData:<any>[],
- optionType:<any>{},
- boxItemTableOption:{},
+ boxTableOption: <any>{},
+ boxTableData: <any>[],
+ optionType: <any>{},
+ boxItemTableOption: {},
})
-const {queryParams, form, page, selectionList,boxTableOption,boxTableData,optionType,boxItemTableOption} = toRefs(data);
+const { queryParams, form, page, selectionList, boxTableOption, boxTableData, optionType, boxItemTableOption } = toRefs(data);
const option = ref({
pageKey: 'TmsDriver',
rowKey: 'id',
@@ -197,65 +191,72 @@
column: [
{
label: '涓嬪崟淇℃伅',
- children:[
- {label: '涓嬪崟鏃堕棿',prop: 'orderTime',width: 120},
- {label: '涓嬪崟鏃堕棿',prop: 'orderTimeRange',width: 120,search: true, searchRange: true, type: 'date', format: 'YYYY-MM-DD', hide: true, searchSpan: 5, valueFormat: 'YYYY-MM-DD',},
- {label: '瀹㈡埛',prop: 'customerName',width: 180,search: true,},
- {label: '椤圭洰鍚嶇О',prop: 'projectName',width: 180,search: true},
- {label: '杩愯緭璺嚎',prop: 'address',width: 300,search: true},
- {label: '涓嬪崟杞﹀瀷',prop: 'requiredVehicleTypes',width: 120,type: 'select', dicUrl: '/system/dict/data/type/vehicle_type', dataType: 'string',search: true},
+ children: [
+ { label: '涓嬪崟鏃堕棿', prop: 'orderTime', width: 120 },
+ { label: '涓嬪崟鏃堕棿', prop: 'orderTimeRange', width: 120, search: true, searchRange: true, type: 'date', format: 'YYYY-MM-DD', hide: true, searchSpan: 5, valueFormat: 'YYYY-MM-DD', },
+ { label: '瀹㈡埛', prop: 'customerName', width: 180, search: true, },
+ { label: '椤圭洰鍚嶇О', prop: 'projectName', width: 180, search: true },
+ { label: '杩愯緭璺嚎', prop: 'address', width: 300, search: true },
+ { label: '涓嬪崟杞﹀瀷', prop: 'requiredVehicleTypes', width: 120, type: 'select', dicUrl: '/system/dict/data/type/vehicle_type', dataType: 'string', search: true },
]
},
{
+ label: '澶囨敞',
+ prop: 'remark',
+ width: 120,
+ slot: true, // 寮�鍚嚜瀹氫箟鎻掓Ы
+ },
+ {
label: '娲捐溅淇℃伅',
- children:[
- {label: '璋冨害鍗曞彿',prop: 'dispatchNo',width: 180,search: true,},
- {label: '鐘舵��',prop: 'status',width: 120, type: 'select', dataType: 'string', dicUrl: '/system/dict/data/type/tms_dispatch_order_status',search: true
+ children: [
+ { label: '璋冨害鍗曞彿', prop: 'dispatchNo', width: 180, search: true, },
+ {
+ label: '鐘舵��', prop: 'status', width: 120, type: 'select', dataType: 'string', dicUrl: '/system/dict/data/type/tms_dispatch_order_status', search: true
},
- {label: '鎵胯繍鍟�',prop: 'providerName',width: 180,search: true},
- {label: '杞︾墝',prop: 'license',width: 120},
- {label: '鍙告満',prop: 'mainDriverName',width: 120},
- {label: '鎵胯繍杞﹀瀷',prop: 'actualVehicleType',width: 120,type: 'select', dicUrl: '/system/dict/data/type/vehicle_type', dataType: 'string',search: true},
+ { label: '鎵胯繍鍟�', prop: 'providerName', width: 180, search: true },
+ { label: '杞︾墝', prop: 'license', width: 120 },
+ { label: '鍙告満', prop: 'mainDriverName', width: 120 },
+ { label: '鎵胯繍杞﹀瀷', prop: 'actualVehicleType', width: 120, type: 'select', dicUrl: '/system/dict/data/type/vehicle_type', dataType: 'string', search: true },
]
},
{
label: '鎵胯繍淇℃伅',
- children:[
- {label: '鎵樻灦/鏌滃彿',prop: 'shelfCodeAndContainerNo',width: 120},
- {label: '鍙e哺',prop: 'port',width: 120},
- {label: '鏃犵紳渚涘簲鍟�',prop: 'seamlessSupplierName',width: 120},
- {label: '鏃犵紳鍙�',prop: 'seamlessNumber',width: 120},
- {label: '鏌ラ獙',prop: 'iscc',width: 120,type: 'select', dicUrl: '/system/dict/data/type/sys_number_is', dataType: 'string',},
- {label: '鎶ュ叧鏈嶅姟鍟�',prop: 'customsServiceProviderName',width: 120,search: true},
- {label: '瑁呭嵏鏈嶅姟鍟�',prop: 'loadingServiceProviderName',width: 120,search: true},
+ children: [
+ { label: '鎵樻灦/鏌滃彿', prop: 'shelfCodeAndContainerNo', width: 120 },
+ { label: '鍙e哺', prop: 'port', width: 120 },
+ { label: '鏃犵紳渚涘簲鍟�', prop: 'seamlessSupplierName', width: 120 },
+ { label: '鏃犵紳鍙�', prop: 'seamlessNumber', width: 120 },
+ { label: '鏌ラ獙', prop: 'iscc', width: 120, type: 'select', dicUrl: '/system/dict/data/type/sys_number_is', dataType: 'string', },
+ { label: '鎶ュ叧鏈嶅姟鍟�', prop: 'customsServiceProviderName', width: 120, search: true },
+ { label: '瑁呭嵏鏈嶅姟鍟�', prop: 'loadingServiceProviderName', width: 120, search: true },
]
- },{
+ }, {
label: '搴斾粯',
- children:[
- {label: '杩愯垂',prop: 'pShippingFee',width: 120},
- {label: '澧炲�兼湇鍔�',prop: 'pServerFee',width: 120},
- {label: '瀹炴姤瀹為攢',prop: 'pActualFee',width: 120},
- {label: '搴斾粯灏忚',prop: 'pTotal',width: 120},
+ children: [
+ { label: '杩愯垂', prop: 'pShippingFee', width: 120 },
+ { label: '澧炲�兼湇鍔�', prop: 'pServerFee', width: 120 },
+ { label: '瀹炴姤瀹為攢', prop: 'pActualFee', width: 120 },
+ { label: '搴斾粯灏忚', prop: 'pTotal', width: 120 },
]
- },{
+ }, {
label: '搴旀敹',
- children:[
- {label: '杩愯垂',prop: 'rShippingFee',width: 120},
- {label: '澧炲�兼湇鍔�',prop: 'rServerFee',width: 120},
- {label: '瀹炴姤瀹為攢',prop: 'rActualFee',width: 120},
- {label: '搴旀敹灏忚',prop: 'rTotal',width: 120},
+ children: [
+ { label: '杩愯垂', prop: 'rShippingFee', width: 120 },
+ { label: '澧炲�兼湇鍔�', prop: 'rServerFee', width: 120 },
+ { label: '瀹炴姤瀹為攢', prop: 'rActualFee', width: 120 },
+ { label: '搴旀敹灏忚', prop: 'rTotal', width: 120 },
]
- },{
+ }, {
label: '鍒╂鼎',
- children:[
- {label: '姣涘埄',prop: 'grossProfit',width: 120},
- {label: '姣涘埄鐜�',prop: 'grossProfitRadio',width: 120},
+ children: [
+ { label: '姣涘埄', prop: 'grossProfit', width: 120 },
+ { label: '姣涘埄鐜�', prop: 'grossProfitRadio', width: 120 },
]
- },{
+ }, {
label: '澶囨敞',
- children:[
- {label: '',prop: 'remark',width: 120},
+ children: [
+ { label: '', prop: 'remark', width: 120 },
]
}
@@ -315,26 +316,26 @@
const YSGenerateItemTableOption = ref({
menu: false,
add: false,
- header:false,
+ header: false,
selection: false,
- rowKey:'rowKey',
+ rowKey: 'rowKey',
- column:{
- feeType:{
+ column: {
+ feeType: {
label: '璐圭敤绫诲瀷',
type: 'radio', dataType: 'string', dicUrl: '/system/dict/data/type/receivable_fee_type',
},
- feeName:{
+ feeName: {
label: '璐圭敤鍚嶇О',
},
- registerTime:{
+ registerTime: {
label: '鐧昏鏃堕棿',
},
- registerAmount:{
+ registerAmount: {
label: '鐧昏閲戦',
},
- currency:{
+ currency: {
label: '甯佸埗',
type: 'radio', dataType: 'string', dicUrl: '/system/dict/data/type/sys_currency',
@@ -344,23 +345,23 @@
const YFGenerateTableOption = ref({
menu: false,
add: false,
- header:false,
+ header: false,
selection: false,
- expand:true,
- defaultExpandAll:true,
- rowKey:'id',
- column:{
- dispatchNo:{
+ expand: true,
+ defaultExpandAll: true,
+ rowKey: 'id',
+ column: {
+ dispatchNo: {
label: '璋冨害鍗曞彿',
},
- serviceProviderType:{
+ serviceProviderType: {
label: '鏈嶅姟鍟嗙被鍨�',
type: 'radio', dicUrl: '/system/dict/data/type/provider_type', dataType: 'string',
},
- serviceProviderName:{
+ serviceProviderName: {
label: '鏈嶅姟鍟嗗悕绋�',
},
- payableAmount:{
+ payableAmount: {
label: '搴斾粯璐圭敤',
}
}
@@ -368,26 +369,26 @@
const YFGenerateItemTableOption = ref({
menu: false,
add: false,
- header:false,
+ header: false,
selection: false,
- rowKey:'rowKey',
+ rowKey: 'rowKey',
- column:{
- feeType:{
+ column: {
+ feeType: {
label: '璐圭敤绫诲瀷',
type: 'radio', dataType: 'string', dicUrl: '/system/dict/data/type/receivable_fee_type',
},
- feeName:{
+ feeName: {
label: '璐圭敤鍚嶇О',
},
- registerTime:{
+ registerTime: {
label: '鐧昏鏃堕棿',
},
- registerAmount:{
+ registerAmount: {
label: '鐧昏閲戦',
},
- currency:{
+ currency: {
label: '甯佸埗',
type: 'radio', dataType: 'string', dicUrl: '/system/dict/data/type/sys_currency',
@@ -425,17 +426,54 @@
handleSelectionChangeFunc: (selection: any) => {
selectionList.value = selection;
},
- getBeginListFunc:(params = {})=>{
- queryParams.value = proxy.addDateRangeNew(queryParams.value, queryParams.value?.orderTimeRange, 'orderTime') || {};
- return params;
- }
+ getBeginListFunc: (params = {}) => {
+ // 1. 鏃ユ湡杞崲
+ let newParams = <any>{ ...params };
+ if (newParams) {
+ // 1. 瀹氫箟鏃ユ湡瀛楁鏄犲皠 (鏁扮粍鍚� : 鎺ュ彛闇�瑕佺殑鍓嶇紑)
+ // 杩欐牱鍐欑殑濂藉鏄細濡傛灉浣犳湁澶氫釜鏃ユ湡锛岀洿鎺ュ湪杩欓噷娣诲姞涓�琛屽嵆鍙�
+ const dateMap = {
+ orderTimeRange: 'orderTime',
+ };
+
+ // 2. 閬嶅巻澶勭悊鏃ユ湡
+ Object.keys(dateMap).forEach(arrayKey => {
+ const prefix = dateMap[arrayKey];
+ const range = newParams[arrayKey];
+
+ if (Array.isArray(range) && range.length > 0) {
+ // 璧嬪�� Begin 鍜� End
+ newParams[`${prefix}Begin`] = range[0];
+ newParams[`${prefix}End`] = range[1];
+ }
+
+ // 銆愭牳蹇冩敼鍔ㄣ�戯細鏃犺鏄惁鏈夊�硷紝澶勭悊瀹屽悗閮芥妸鍘熷鐨� Array 瀛楁鍒犳帀
+ // 杩欐牱璇锋眰閲屽氨涓嶄細鍑虹幇 confirmTimeRangeArray: [...]
+ delete newParams[arrayKey];
+ });
+
+ // 3. 閫氱敤娓呮礂锛氬垹闄ゆ墍鏈夌┖瀛楃涓层�乶ull 鎴� undefined 鐨勫叾浠栧瓧娈�
+ Object.keys(newParams).forEach(key => {
+ const val = newParams[key];
+ if (val === '' || val === null || val === undefined) {
+ delete newParams[key];
+ }
+ });
+
+ } else {
+ newParams = {};
+ }
+
+ return newParams;
+
+ },
})
const handleLogItinerary = (row: any) => {
optionType.value = 'view';
boxTableOption.value = itineraryTableOption.value;
- listTmsTrip({dispatchOrderId: row.dispatchId, pageNum: 1, pageSize: 999}).then(res => {
+ listTmsTrip({ dispatchOrderId: row.dispatchId, pageNum: 1, pageSize: 999 }).then(res => {
boxTableData.value = res.rows || [];
- pageF.open = true;
+ pageF.open = true;
pageF.title = '鏌ョ湅琛岀▼';
})
}
@@ -443,7 +481,7 @@
const handleReceivableFeeView = (row: any) => {
optionType.value = 'receivableFee';
boxTableOption.value = YSGenerateItemTableOption.value;
- getTmsReceivableFeeByDispatchNo(row.dispatchNo).then(res=>{
+ getTmsReceivableFeeByDispatchNo(row.dispatchNo).then(res => {
form.value = res.data || {};
boxTableData.value = form.value.items || [];
pageF.open = true;
@@ -455,7 +493,7 @@
optionType.value = 'payableFee';
boxTableOption.value = YFGenerateTableOption.value;
boxItemTableOption.value = YFGenerateItemTableOption.value;
- getTmsPayableFeeByDispatchNo(row.dispatchNo).then(res=>{
+ getTmsPayableFeeByDispatchNo(row.dispatchNo).then(res => {
boxTableData.value = res.data || [];
pageF.open = true;
pageF.title = '搴斾粯璐圭敤鏄庣粏';
@@ -464,16 +502,65 @@
})
}
+// 鎺у埗澶囨敞寮圭獥鏄剧ず
+const remarkBox = reactive({
+ open: false,
+ title: '澶囨敞璁板綍',
+ content: '', // 鏂板澶囨敞鐨勫唴瀹�
+ list: [] // 澶囨敞鍘嗗彶鍒楄〃
+});
+const activeRow = ref({}); // 褰撳墠鎿嶄綔鐨勮
+
+// 鐐瑰嚮澶囨敞鍒楄Е鍙�
+const handleRemarkClick = (row) => {
+ activeRow.value = row;
+ remarkBox.content = ''; // 娓呯┖杈撳叆妗�
+ remarkBox.open = true;
+ remarkBox.list = [
+ ];
+ listDispatchFeeSummaryViLog({ headId: row.dispatchId }).then(res => remarkBox.list = res.rows || []);
+ // getRemarkHistory(row.id).then(res => remarkBox.list = res.data);
+
+};
+
+// 寮圭獥鐐瑰嚮纭畾鐨勯�昏緫
+const submitRemark = () => {
+ if (!remarkBox.content) {
+ // return ElMessage.warning('璇疯緭鍏ュ娉ㄥ唴瀹�');
+ return proxy.$modal.msgWarning("璇疯緭鍏ュ娉ㄥ唴瀹�");
+
+ }
+ // 鏇存柊鍓嶇琛ㄦ牸鏄剧ず锛堝疄闄呭簲璋冪敤淇濆瓨鎺ュ彛鍚庡埛鏂帮級
+
+ // 璋冪敤鍚庣鎺ュ彛绀轰緥锛�
+ // saveRemark({ id: activeRow.value.id, remark: remarkBox.content }).then(...)
+ tmsDispatchFeeSummaryViNote({ dispatchId: activeRow.value.dispatchId, remark: remarkBox.content }).then((res) => {
+ if (res.code == 200) {
+ // remarkBox.open = false;
+ listDispatchFeeSummaryViLog({ headId: activeRow.value.dispatchId }).then((res1) => {
+ if (res1.code == 200) {
+ remarkBox.list = res1.rows || [];
+ remarkBox.content = ''; // 娓呯┖杈撳叆妗�
+ proxy.$modal.msgSuccess(res.msg);
+
+ }
+ });
+ // activeRow.value.remark = remarkBox.content; // 鏇存柊琛ㄦ牸鏄剧ず
+ }
+ // ElMessage.success('澶囨敞宸叉洿鏂�');
+ });
+};
</script>
<style scoped lang="scss">
-.hot{
+.hot {
cursor: pointer;
text-align: left;
color: #409eff;
- &:hover{
- color: #f0ad4e;
+
+ &:hover {
+ color: #f0ad4e;
}
}
</style>
--
Gitblit v1.8.0