From 6a415a072a98d64d2f95d16eef73b6d7270b8d56 Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期六, 30 五月 2026 15:14:25 +0800
Subject: [PATCH] 新疆马铃薯 1.首页问题:挪新系统ui,需要确认一下页面数据完整。 2.协同办公:挪新系统 3.营销管理:客户往来取消回款金额字段,改为点击左侧客户时显示与该客户的所有订单信息,以及发货情况。销售可以选好对应的采购订单方便质量追溯。 4.采购管理:供应商往来同上逻辑,显示是否收货,也加上采购退货和采购报表功能。 5.采购加上设备备件选项,设备备件入库到备件库存。设备,仓储不足时做采购提醒。 6.仓储物流:得区分成品库和原料库(不存在半成品,成品只有一个产品,很好确认),原材料需要有批号,采集原料库需要做好仓库字段,让他们可以区分哪个仓库,然后把数采设备信息做一个实时的显示。总库存显示好当前存在的批次信息。 7.质量:只有不通过才需要填写对应的数据信息。在外侧做好选择通过不通过。过程,出厂检验无法对应到生产订单,那就对应到销售订单。 8.决策分析:基础数据分析和进销存分析,质量数据分析需要重新设计
---
src/views/salesManagement/receiptPaymentLedger/index.vue | 244 +++++++++++++++++++++++++++++-------------------
1 files changed, 146 insertions(+), 98 deletions(-)
diff --git a/src/views/salesManagement/receiptPaymentLedger/index.vue b/src/views/salesManagement/receiptPaymentLedger/index.vue
index f5a9d8f..abcef02 100644
--- a/src/views/salesManagement/receiptPaymentLedger/index.vue
+++ b/src/views/salesManagement/receiptPaymentLedger/index.vue
@@ -16,7 +16,8 @@
</div>
</div>
<el-row :gutter="20">
- <el-col :span="12">
+ <!-- 宸︿晶瀹㈡埛鍒楄〃 -->
+ <el-col :span="8">
<div class="table_list"
style="width: 100%">
<el-table :data="tableData"
@@ -40,22 +41,17 @@
prop="contractAmounts"
show-overflow-tooltip
:formatter="formattedNumber"
- width="200" />
- <el-table-column label="鍥炴閲戦(鍏�)"
- prop="receiptPaymentAmount"
- show-overflow-tooltip
- :formatter="formattedNumber"
- width="200" />
- <el-table-column label="搴旀敹閲戦(鍏�)"
- prop="receiptableAmount"
- show-overflow-tooltip
- width="200">
- <template #default="{ row, column }">
- <el-text type="danger">
- {{ formattedNumber(row, column, row.receiptableAmount) }}
- </el-text>
- </template>
- </el-table-column>
+ width="150" />
+<!-- <el-table-column label="搴旀敹閲戦(鍏�)"-->
+<!-- prop="receiptableAmount"-->
+<!-- show-overflow-tooltip-->
+<!-- width="150">-->
+<!-- <template #default="{ row, column }">-->
+<!-- <el-text type="danger">-->
+<!-- {{ formattedNumber(row, column, row.receiptableAmount) }}-->
+<!-- </el-text>-->
+<!-- </template>-->
+<!-- </el-table-column>-->
</el-table>
<pagination v-show="total > 0"
:total="total"
@@ -65,57 +61,85 @@
@pagination="paginationChange" />
</div>
</el-col>
- <el-col :span="12">
+ <!-- 鍙充晶璁㈠崟淇℃伅 -->
+ <el-col :span="16">
<div class="table_list"
style="width: 100%">
- <el-table :data="receiptRecord"
+
+ <el-table :data="orderRecord"
border
:row-key="(row) => row.id"
- show-summary
- :summary-method="summarizeMainTable1"
- height="calc(100vh - 18.5em)">
+ v-loading="orderLoading"
+ height="calc(100vh - 20em)">
<el-table-column align="center"
label="搴忓彿"
type="index"
width="60" />
- <el-table-column label="鍚堝悓绛捐鏃ユ湡"
- prop="executionDate"
- show-overflow-tooltip
- width="110" />
- <el-table-column label="閿�鍞悎鍚屽彿"
+ <el-table-column label="閿�鍞鍗�"
prop="salesContractNo"
show-overflow-tooltip
- width="200" />
- <el-table-column label="鍚堝悓閲戦(鍏�)"
- prop="contractAmount"
+ width="150" />
+ <!-- <el-table-column label="鍙戣揣璁㈠崟鍙�"
+ prop="shippingNo"
show-overflow-tooltip
- :formatter="formattedNumber"
- width="200" />
- <el-table-column label="鍥炴閲戦(鍏�)"
- prop="receiptPaymentAmount"
+ width="150" /> -->
+ <el-table-column label="瀹㈡埛鍚嶇О"
+ prop="customerName"
show-overflow-tooltip
- :formatter="formattedNumber"
- width="200" />
- <el-table-column label="搴旀敹閲戦(鍏�)"
- prop="receiptableAmount"
+ width="150" />
+ <el-table-column label="浜у搧鍚嶇О"
+ prop="productName"
show-overflow-tooltip
- width="200">
- <template #default="{ row, column }">
- <el-text type="danger">
- {{ formattedNumber(row, column, row.receiptableAmount) }}
- </el-text>
+ width="150" />
+ <el-table-column label="瑙勬牸鍨嬪彿"
+ prop="specificationModel"
+ show-overflow-tooltip
+ width="120" />
+ <el-table-column label="鍙戣揣鏃堕棿"
+ prop="shippingDate"
+ show-overflow-tooltip
+ width="110" />
+ <el-table-column label="鍙戣揣鏁伴噺"
+ prop="totalQuantity"
+ show-overflow-tooltip
+ width="100" />
+ <!-- <el-table-column label="鍙戣揣杞︾墝鍙�"
+ prop="shippingCarNumber"
+ show-overflow-tooltip
+ width="120" />
+ <el-table-column label="蹇�掑叕鍙�"
+ prop="expressCompany"
+ show-overflow-tooltip
+ width="120" />
+ <el-table-column label="蹇�掑崟鍙�"
+ prop="expressNumber"
+ show-overflow-tooltip
+ width="150" /> -->
+ <el-table-column label="鍙戣揣鐘舵��"
+ prop="status"
+ align="center"
+ width="100">
+ <template #default="{ row }">
+ <el-tag :type="getApprovalStatusType(row.status)">
+ {{ getApprovalStatusText(row.status) }}
+ </el-tag>
</template>
</el-table-column>
+ <el-table-column label="鍑哄簱鍗曞彿"
+ prop="outboundBatches"
+ show-overflow-tooltip
+ width="130" />
</el-table>
- <pagination v-show="recordTotal > 0"
- :total="recordTotal"
+ <pagination v-show="orderTotal > 0"
+ :total="orderTotal"
layout="total, sizes, prev, pager, next, jumper"
- :page="recordPage.current"
- :limit="recordPage.size"
- @pagination="recordPaginationChange" />
+ :page="orderPage.current"
+ :limit="orderPage.size"
+ @pagination="orderPaginationChange" />
</div>
</el-col>
</el-row>
+
</div>
</template>
@@ -123,23 +147,25 @@
import { onMounted, ref, reactive, toRefs, getCurrentInstance } from "vue";
import {
customewTransactions,
- customewTransactionsDetails,
} from "@/api/salesManagement/indicatorStats.js";
+ import { deliveryLedgerListPage } from "@/api/salesManagement/deliveryLedger.js";
import Pagination from "../../../components/PIMTable/Pagination.vue";
+
const { proxy } = getCurrentInstance();
const tableData = ref([]);
- const receiptRecord = ref([]);
+ const orderRecord = ref([]);
const tableLoading = ref(false);
+ const orderLoading = ref(false);
const page = reactive({
current: 1,
size: 100,
});
- const recordPage = reactive({
+ const orderPage = reactive({
current: 1,
size: 100,
});
const total = ref(0);
- const recordTotal = ref(0);
+ const orderTotal = ref(0);
const data = reactive({
searchForm: {
searchText: "",
@@ -148,7 +174,7 @@
});
const customerId = ref("");
const { searchForm } = toRefs(data);
- const originReceiptRecord = ref([]);
+
// 鏌ヨ鍒楄〃
/** 鎼滅储鎸夐挳鎿嶄綔 */
const handleQuery = () => {
@@ -167,9 +193,12 @@
tableData.value = res.data.records;
total.value = res.data.total;
if (tableData.value.length > 0) {
- recordPage.current = 1;
+ orderPage.current = 1;
customerId.value = tableData.value[0].customerId;
- receiptPaymentList(customerId.value);
+ getOrderList(customerId.value);
+ } else {
+ orderRecord.value = [];
+ customerId.value = "";
}
});
};
@@ -180,64 +209,82 @@
const summarizeMainTable = param => {
return proxy.summarizeTable(
param,
- ["invoiceTotal", "receiptPaymentAmount", "unReceiptPaymentAmount"],
+ ["contractAmounts", "receiptableAmount"],
{
- ticketsNum: { noDecimal: true }, // 涓嶄繚鐣欏皬鏁�
- futureTickets: { noDecimal: true }, // 涓嶄繚鐣欏皬鏁�
+ ticketsNum: { noDecimal: true },
+ futureTickets: { noDecimal: true },
}
);
};
- // 瀛愯〃鍚堣鏂规硶
- const summarizeMainTable1 = param => {
- var summarizeTable = proxy.summarizeTable(
- param,
- ["contractAmount", "receiptPaymentAmount", "receiptableAmount"],
- {
- ticketsNum: { noDecimal: true }, // 涓嶄繚鐣欏皬鏁�
- futureTickets: { noDecimal: true }, // 涓嶄繚鐣欏皬鏁�
+
+ // 鑾峰彇璁㈠崟鍒楄〃锛堟牴鎹鎴稩D鏌ヨ鍙戣揣鍙拌处锛�
+ const getOrderList = async (id) => {
+ orderLoading.value = true;
+ try {
+ // 浣跨敤 deliveryLedgerListPage 鎺ュ彛鏍规嵁 customerId 鏌ヨ
+ const res = await deliveryLedgerListPage({
+ customerId: id,
+ current: 1,
+ size: 1000,
+ });
+ let orders = [];
+ if (res.data) {
+ if (Array.isArray(res.data)) {
+ orders = res.data;
+ } else if (res.data.records && Array.isArray(res.data.records)) {
+ orders = res.data.records;
+ }
}
- );
- return summarizeTable;
+
+ orderTotal.value = orders.length;
+ handleOrderPagination({ page: orderPage.current, limit: orderPage.size }, orders);
+ } catch (error) {
+ console.error('鑾峰彇璁㈠崟鍒楄〃澶辫触:', error);
+ orderRecord.value = [];
+ } finally {
+ orderLoading.value = false;
+ }
};
- const receiptPaymentList = id => {
- const param = {
- customerId: id,
- current: recordPage.current,
- size: recordPage.size,
- };
- customewTransactionsDetails(param).then(res => {
- if (Array.isArray(res.data)) {
- originReceiptRecord.value = res.data;
- recordTotal.value = res.data.length;
- handlePagination({ page: 1, limit: recordPage.size });
- } else {
- receiptRecord.value = res.data.records;
- recordTotal.value = res.data.total;
- }
- });
+ // 璁㈠崟鍒楄〃鍒嗛〉
+ const orderPaginationChange = pagination => {
+ orderPage.current = pagination.page;
+ orderPage.size = pagination.limit;
+ getOrderList(customerId.value);
};
- // 姹囨璁板綍鍒楄〃鍒嗛〉
- const recordPaginationChange = pagination => {
- recordPage.current = pagination.page;
- recordPage.size = pagination.limit;
- receiptPaymentList(customerId.value);
+ const handleOrderPagination = ({ page, limit }, allOrders) => {
+ const start = (page - 1) * limit;
+ const end = start + limit;
+ orderRecord.value = allOrders.slice(start, end);
};
const rowClickMethod = row => {
customerId.value = row.customerId;
- receiptPaymentList(customerId.value);
+ orderPage.current = 1;
+ getOrderList(customerId.value);
};
- const handlePagination = ({ page, limit }) => {
- recordPage.current = page;
- recordPage.size = limit;
+ // 瀹℃牳鐘舵�佹爣绛剧被鍨�
+ const getApprovalStatusType = (status) => {
+ const statusMap = {
+ '宸插彂璐�': 'success',
+ '瀹℃牳閫氳繃': 'success',
+ '瀹℃牳涓�': 'warning',
+ '瀹℃牳涓嶉�氳繃': 'danger',
+ };
+ return statusMap[status] || 'info';
+ };
- const start = (page - 1) * limit;
- const end = start + limit;
-
- receiptRecord.value = originReceiptRecord.value.slice(start, end);
+ // 瀹℃牳鐘舵�佹枃鏈�
+ const getApprovalStatusText = (status) => {
+ const statusMap = {
+ '宸插彂璐�': '宸插彂璐�',
+ '瀹℃牳閫氳繃': '瀹℃牳閫氳繃',
+ '瀹℃牳涓�': '瀹℃牳涓�',
+ '瀹℃牳涓嶉�氳繃': '瀹℃牳涓嶉�氳繃',
+ };
+ return statusMap[status] || status || '--';
};
onMounted(() => {
@@ -247,6 +294,7 @@
<style scoped lang="scss">
.table_list {
- width: 50%;
+ width: 100%;
}
+
</style>
--
Gitblit v1.9.3