From 636b3fc82ba28b9c10eac19a7a54f1b47cbbdd9f Mon Sep 17 00:00:00 2001 From: mac Date: Tue, 23 Jun 2026 23:07:18 +0800 Subject: [PATCH 1/2] =?UTF-8?q?fix(deploy):=20=E4=BF=AE=E5=A4=8D=20data=20?= =?UTF-8?q?=E7=9B=AE=E5=BD=95=E4=B8=8D=E5=AD=98=E5=9C=A8=E5=AF=BC=E8=87=B4?= =?UTF-8?q?=20ln=20=E8=BD=AF=E9=93=BE=E5=A4=B1=E8=B4=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit rsync 排除了 data/uploads 但没保留 data/ 空目录, 导致 ln -sfn shared/uploads data/uploads 时父目录不存在而失败。 在 ln 之前加 mkdir -p 确保目录存在。 --- .gitea/workflows/deploy.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml index 65d0ed0..9ebbf00 100644 --- a/.gitea/workflows/deploy.yml +++ b/.gitea/workflows/deploy.yml @@ -39,6 +39,7 @@ jobs: "${CLONE_DIR}/" "${RELEASE_DIR}/" echo "=== 3. Link shared resources ===" + mkdir -p "${RELEASE_DIR}/data" # .env from shared dir (not in git) ln -sfn "${DEPLOY_BASE}/shared/.env" "${RELEASE_DIR}/.env" # uploads directory from shared (persist across releases) From 2c7e6b7d29aa9a55fe13e13fcca994405c05b0c0 Mon Sep 17 00:00:00 2001 From: mac Date: Tue, 23 Jun 2026 23:12:03 +0800 Subject: [PATCH 2/2] =?UTF-8?q?fix:=20=E7=BB=8F=E8=90=A5=E7=AE=A1=E7=90=86?= =?UTF-8?q?=E5=8D=A1=E7=89=87=E5=9B=BE=E6=A0=87=E4=BF=AE=E5=A4=8D=20+=20?= =?UTF-8?q?=E9=87=91=E9=A2=9D=E7=BB=9F=E4=B8=80=E5=8F=96=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 已签项目图标 file-sign → file-check-2(修复不显示) - 11 个卡片金额从 money() 改为 moneyInt()(Math.round 取整) --- static/modules/finance.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/static/modules/finance.js b/static/modules/finance.js index f28ed1a..40cef25 100644 --- a/static/modules/finance.js +++ b/static/modules/finance.js @@ -1,5 +1,7 @@ // finance.js — 经营管理(财务)模块 +const moneyInt = (v) => `${Math.round(Number(v || 0)).toLocaleString("zh-CN")} 元`; + function renderFinance() { const pfs = state.data.projectFinances || []; const ops = state.data.operations || []; @@ -102,10 +104,10 @@ function renderFinance() { document.querySelector("#finance").innerHTML = `
- ${[["已签项目","" + signed.length,"file-sign"],["签约金额",money(sumSign),"coins"],["流程项目","" + inContract.length,"file-clock"],["流程金额",money(sumContract),"clock"],["待签项目","" + pending.length,"file-question"],["待签金额",money(sumPending),"hourglass"]].map(([l,v,icon]) => `
${l}${v}
`).join("")} + ${[["已签项目","" + signed.length,"file-check-2"],["签约金额",moneyInt(sumSign),"coins"],["流程项目","" + inContract.length,"file-clock"],["流程金额",moneyInt(sumContract),"clock"],["待签项目","" + pending.length,"file-question"],["待签金额",moneyInt(sumPending),"hourglass"]].map(([l,v,icon]) => `
${l}${v}
`).join("")}
- ${[["本月确收",money(thisMonthRev),"trending-up"],["本月毛利",money(thisMonthGross),"percent"],["本月回款",money(monthPayment),"wallet"],["本月费用",money(monthCost),"receipt"],["本月现金流",money(monthCashflow),"repeat"]].map(([l,v,icon]) => `
${l}${v}
`).join("")} + ${[["本月确收",moneyInt(thisMonthRev),"trending-up"],["本月毛利",moneyInt(thisMonthGross),"percent"],["本月回款",moneyInt(monthPayment),"wallet"],["本月费用",moneyInt(monthCost),"receipt"],["本月现金流",moneyInt(monthCashflow),"repeat"]].map(([l,v,icon]) => `
${l}${v}
`).join("")}