feat(pl): 运费结算审批分流与车辆挂车号等 PL 能力完善
拆分运费审批/出款页面,补充结算发票附件与菜单 SQL,并同步前后端模型与车辆相关展示。 Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
1 parent
66d5a8714b
commit
98aec80d71
37 files changed
+1362
-195
No files matched your search
@@ -3,6 +3,16 @@
|
||||
<div class="filter-block">
|
||||
<el-form :model="searchForm" class="filter-form" @submit.prevent>
|
||||
<div class="filter-grid">
|
||||
<el-form-item label="运输公司">
|
||||
<el-select v-model="searchForm.carrierId" placeholder="全部" clearable filterable>
|
||||
<el-option
|
||||
v-for="c in carrierList"
|
||||
:key="c.id"
|
||||
:label="c.carrierName"
|
||||
:value="c.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="计划编号">
|
||||
<el-input
|
||||
v-model="searchForm.q"
|
||||
@@ -114,7 +124,7 @@
|
||||
|
||||
<script setup lang="ts">
|
||||
import { DocumentAdd, RefreshLeft, Search, View } from '@element-plus/icons-vue'
|
||||
import { freightApi, type UnsettledPlanItem } from '@/api/pl'
|
||||
import { carrierApi, freightApi, type Carrier, type UnsettledPlanItem } from '@/api/pl'
|
||||
import PlPlanViewDialog from '@/components/business/pl-plan-view-dialog/index.vue'
|
||||
import { getPlanTypeLabel, getPlanTypeTagType } from '@/views/pl/freight/freight-status'
|
||||
import { formatMoneyDisplay } from '@/utils/money-format'
|
||||
@@ -124,12 +134,14 @@ const emit = defineEmits<{ created: [settlementId: string] }>()
|
||||
|
||||
const loading = ref(false)
|
||||
const createLoading = ref(false)
|
||||
const carrierList = ref<Carrier[]>([])
|
||||
const planList = ref<UnsettledPlanItem[]>([])
|
||||
const selectedRows = ref<UnsettledPlanItem[]>([])
|
||||
const planViewVisible = ref(false)
|
||||
const viewPlanId = ref('')
|
||||
|
||||
const searchForm = reactive({
|
||||
carrierId: '',
|
||||
q: '',
|
||||
planType: '',
|
||||
licensePlate: ''
|
||||
@@ -150,6 +162,7 @@ async function fetchData() {
|
||||
loading.value = true
|
||||
try {
|
||||
const res = await freightApi.listUnsettledPlans({
|
||||
carrierId: searchForm.carrierId || undefined,
|
||||
q: searchForm.q || undefined,
|
||||
planType: searchForm.planType || undefined,
|
||||
licensePlate: searchForm.licensePlate || undefined,
|
||||
@@ -170,6 +183,7 @@ function handleSearch() {
|
||||
}
|
||||
|
||||
function handleReset() {
|
||||
searchForm.carrierId = ''
|
||||
searchForm.q = ''
|
||||
searchForm.planType = ''
|
||||
searchForm.licensePlate = ''
|
||||
@@ -177,6 +191,15 @@ function handleReset() {
|
||||
fetchData()
|
||||
}
|
||||
|
||||
async function loadCarrierList() {
|
||||
try {
|
||||
const res = await carrierApi.list({ status: '1' })
|
||||
carrierList.value = (res.data ?? res) || []
|
||||
} catch {
|
||||
carrierList.value = []
|
||||
}
|
||||
}
|
||||
|
||||
function handlePageChange() {
|
||||
fetchData()
|
||||
}
|
||||
@@ -222,6 +245,7 @@ function refresh() {
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
loadCarrierList()
|
||||
fetchData()
|
||||
})
|
||||
|
||||
|
||||
Reference in new issue
Block a user