Tms对接金蝶接口-前端 #3

Merged
b2894lxlx merged 51 commits from feature/bfi-api-rate into master 2026-10-14 17:28:17 +08:00
2 changed files with 6 additions and 4 deletions
Showing only changes of commit 730c4e2a6a - Show all commits
+3 -2
View File
@@ -202,8 +202,9 @@ export default {
}, },
methods: { methods: {
unwrapData(response) { unwrapData(response) {
const body = response?.data || response || {}; // 数字 0 是合法返回值(如回写/同步 0 条),须用 ?? 判空避免 0 被信封对象顶掉导致 Number() 得 NaN
return body?.data || body; const body = response?.data ?? response ?? {};
return body?.data ?? body;
}, },
queryParams() { queryParams() {
const transactionRange = this.query.transactionDateRange || []; const transactionRange = this.query.transactionDateRange || [];
+3 -2
View File
@@ -295,8 +295,9 @@ export default {
}, },
methods: { methods: {
unwrapData(response) { unwrapData(response) {
const body = response?.data || response || {}; // 数字 0 是合法返回值(如回写/同步 0 条),须用 ?? 判空避免 0 被信封对象顶掉导致 Number() 得 NaN
return body?.data || body; const body = response?.data ?? response ?? {};
return body?.data ?? body;
}, },
async loadTable() { async loadTable() {
this.loading = true; this.loading = true;