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)}