From 0deb6c5b8afa265cf8728c8e81d1bc44d2c165b6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E5=BF=A0=E6=9E=97?= <170083662@qq.com> Date: Tue, 14 Oct 2025 00:26:00 +0800 Subject: [PATCH] =?UTF-8?q?feat(dealer):=20=E8=B0=83=E6=95=B4=E5=88=86?= =?UTF-8?q?=E9=94=80=E5=95=86=E8=B5=84=E9=87=91=E6=98=8E=E7=BB=86=E5=B1=95?= =?UTF-8?q?=E7=A4=BA=E5=8F=8A=E6=8F=90=E7=8E=B0=E9=80=BB=E8=BE=91-=20?= =?UTF-8?q?=E4=BA=A4=E6=8D=A2=E8=AE=A2=E5=8D=95=E7=BC=96=E5=8F=B7=E4=B8=8E?= =?UTF-8?q?=E6=94=B6=E7=9B=8A=E6=8F=8F=E8=BF=B0=E7=9A=84=E6=98=BE=E7=A4=BA?= =?UTF-8?q?=E4=BD=8D=E7=BD=AE=20-=20=E6=9B=B4=E6=96=B0=E5=BC=80=E5=8F=91?= =?UTF-8?q?=E7=8E=AF=E5=A2=83API=E5=9F=BA=E7=A1=80URL=20-=20=E6=96=B0?= =?UTF-8?q?=E5=A2=9E=E6=A0=B9=E6=8D=AE=E8=AE=A2=E5=8D=95=E5=8F=B7=E6=9F=A5?= =?UTF-8?q?=E8=AF=A2=E5=88=86=E9=94=80=E5=95=86=E8=B5=84=E9=87=91=E6=98=8E?= =?UTF-8?q?=E7=BB=86=E7=9A=84=E6=96=B9=E6=B3=95=20-=20=E4=BF=AE=E6=94=B9?= =?UTF-8?q?=E8=AE=A2=E5=8D=95=E9=A1=B5=E9=9D=A2=E6=97=A5=E6=9C=9F=E7=8A=B6?= =?UTF-8?q?=E6=80=81=E4=B8=BA=E6=9C=88=E4=BB=BD=E6=A0=BC=E5=BC=8F-=20?= =?UTF-8?q?=E5=B0=86=E6=8F=90=E7=8E=B0=E8=B4=B9=E7=8E=87=E4=BB=8E16%?= =?UTF-8?q?=E8=B0=83=E6=95=B4=E4=B8=BA0%=EF=BC=8C=E4=BF=9D=E7=95=99?= =?UTF-8?q?=E5=9B=BA=E5=AE=9A=E8=B4=B9=E7=94=A83=E5=85=83=20-=20=E7=A7=BB?= =?UTF-8?q?=E9=99=A4=E6=8F=90=E7=8E=B0=E9=A1=B5=E9=9D=A2=E4=B8=AD=E5=85=B3?= =?UTF-8?q?=E4=BA=8E=E8=B4=B9=E7=8E=87=E7=9A=84=E6=8F=8F=E8=BF=B0=E6=96=87?= =?UTF-8?q?=E5=AD=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- config/env.ts | 2 +- src/api/shop/shopDealerCapital/index.ts | 14 ++++++++++++++ src/dealer/capital/detail.tsx | 4 ++-- src/dealer/orders/index.tsx | 4 ++-- src/dealer/withdraw/index.tsx | 4 ++-- 5 files changed, 21 insertions(+), 7 deletions(-) diff --git a/config/env.ts b/config/env.ts index c3f95e2..de8e281 100644 --- a/config/env.ts +++ b/config/env.ts @@ -2,7 +2,7 @@ export const ENV_CONFIG = { // 开发环境 development: { - API_BASE_URL: 'http://127.0.0.1:9200/api', + API_BASE_URL: 'https://cms-api.websoft.top/api', APP_NAME: '开发环境', DEBUG: 'true', }, diff --git a/src/api/shop/shopDealerCapital/index.ts b/src/api/shop/shopDealerCapital/index.ts index 4c4b112..c2f99b2 100644 --- a/src/api/shop/shopDealerCapital/index.ts +++ b/src/api/shop/shopDealerCapital/index.ts @@ -99,3 +99,17 @@ export async function getShopDealerCapital(id: number) { } return Promise.reject(new Error(res.message)); } + + +/** + * 根据id查询分销商资金明细表 + */ +export async function getShopDealerCapitalByOrderNo(orderNo: string) { + const res = await request.get>( + '/shop/shop-dealer-capital/getByCode/' + orderNo + ); + if (res.code === 0 && res.data) { + return res.data; + } + return Promise.reject(new Error(res.message)); +} diff --git a/src/dealer/capital/detail.tsx b/src/dealer/capital/detail.tsx index 04dbda2..cc11d64 100644 --- a/src/dealer/capital/detail.tsx +++ b/src/dealer/capital/detail.tsx @@ -53,10 +53,10 @@ const DealerCapitalDetail = () => { - 订单编号:{item.orderNo} + 收益描述:{item.comments} - 收益描述:{item.comments} + 订单编号:{item.orderNo} 创建时间:{item.createTime} diff --git a/src/dealer/orders/index.tsx b/src/dealer/orders/index.tsx index 9c72a25..50e3bde 100644 --- a/src/dealer/orders/index.tsx +++ b/src/dealer/orders/index.tsx @@ -16,9 +16,9 @@ interface OrderWithDetails extends ShopDealerOrder { const DealerOrder: React.FC = () => { const [loading, setLoading] = useState(false) const d = new Date() - const currDay = `${d.getFullYear()}${d.getMonth() + 1}`; + const currMonth = `${d.getFullYear()}${d.getMonth() + 1}`; const currDate = `${d.getFullYear()}-${d.getMonth() + 1}-${d.getDate()}`; - const [date, setDate] = useState(currDay) + const [date, setDate] = useState(currMonth) const [show1, setShow1] = useState(false) const [refreshing, setRefreshing] = useState(false) const [loadingMore, setLoadingMore] = useState(false) diff --git a/src/dealer/withdraw/index.tsx b/src/dealer/withdraw/index.tsx index 49fc439..4d97622 100644 --- a/src/dealer/withdraw/index.tsx +++ b/src/dealer/withdraw/index.tsx @@ -293,7 +293,7 @@ const DealerWithdraw: React.FC = () => { if (!amount || isNaN(parseFloat(amount))) return '0.00' const withdrawAmount = parseFloat(amount) // 提现费率 16% + 3元 - const feeRate = 0.16 + const feeRate = 0 const fixedFee = 3 const totalFee = withdrawAmount * feeRate + fixedFee const expectedAmount = withdrawAmount - totalFee @@ -360,7 +360,7 @@ const DealerWithdraw: React.FC = () => { }/> - ¥{calculateExpectedAmount(withdrawAmount)}