diff --git a/env/.env b/env/.env index a4c92cd..642dbe2 100644 --- a/env/.env +++ b/env/.env @@ -10,15 +10,15 @@ VITE_APP_PUBLIC_BASE=/ # 登录页面 VITE_LOGIN_URL = '/pages/login/login' # 第一个请求地址 -VITE_SERVER_BASEURL = 'https://cz.stnav.com' +VITE_SERVER_BASEURL = 'https://76458.com' # h5是否需要配置代理 VITE_APP_PROXY=true VITE_APP_PROXY_PREFIX = '/storeapi' # 第二个请求地址 (目前alova中可以使用) -VITE_SERVER_BASEURL = 'https://cz.stnav.com' +VITE_SERVER_BASEURL = 'https://76458.com' # 上传图片请求地址 -VITE_UPLOAD_BASEURL = 'https://cz.stnav.com/teamapi/Upload/image' -VITE_UPLOAD_IMAGE_URL = 'https://cz.stnav.com/' \ No newline at end of file +VITE_UPLOAD_BASEURL = 'https://76458.com/teamapi/Upload/image' +VITE_UPLOAD_IMAGE_URL = 'https://76458.com/' \ No newline at end of file diff --git a/src/api/bank.ts b/src/api/bank.ts index 675ab0e..490e7a0 100644 --- a/src/api/bank.ts +++ b/src/api/bank.ts @@ -25,6 +25,6 @@ export function getBankCardList() { /** * 提现申请 */ -export function withdrawApply(store_id: number, amount: number, bank_id: number) { - return http.Post('/storeapi/user/submitReflect', { store_id, amount, bank_id }) +export function withdrawApply(amount: number, bank_id: number) { + return http.Post('/teamapi/user/submitReflect', { amount, bank_id }) } \ No newline at end of file diff --git a/src/api/tes-specialist.ts b/src/api/tes-specialist.ts index 9431803..f08f7e0 100644 --- a/src/api/tes-specialist.ts +++ b/src/api/tes-specialist.ts @@ -50,7 +50,7 @@ export interface TeaSpecialistOrderListParams { size: number order_status?: string search?: string - day_time?: string + is_time?: number } export function getTeaSpecialistOrderList(data: TeaSpecialistOrderListParams) { @@ -125,4 +125,18 @@ export function deleteTeaSpecialistOrder(id: number) { */ export function getTeaSpecialistCostDetails(id: number) { return http.Post('/teamapi/order/amountDetails', {id}) +} + +/** + * 流水明细详情 + */ +export function getTeaSpecialistBillDetails(id: number) { + return http.Post('/teamapi/user/accounDetails', { id }) +} + +/** + * 茶艺师拒绝接单 + */ +export function refuseTeaSpecialistOrder(id: number) { + return http.Post('/teamapi/order/orderCancel', { id }) } \ No newline at end of file diff --git a/src/api/user.ts b/src/api/user.ts index 6024486..60948de 100644 --- a/src/api/user.ts +++ b/src/api/user.ts @@ -53,10 +53,10 @@ export function getUserTransactionDetails(data: IGetUserTransactionDetailsParams } /** - * 获取流水明细详情(账单明细) + * 获取流水明细详情(提现明细) */ export function getUserTransactionDetailsInfo(id: number) { - return http.Post('/teamapi/user/balanceLogDetails', { id }) + return http.Post('/teamapi/user/reflectDetails', { id }) } /** diff --git a/src/bundle/parten/pages/bank-card/list.vue b/src/bundle/parten/pages/bank-card/list.vue index a448972..9cba14c 100644 --- a/src/bundle/parten/pages/bank-card/list.vue +++ b/src/bundle/parten/pages/bank-card/list.vue @@ -9,7 +9,7 @@ @@ -129,7 +129,22 @@ height: 'calc(100vh - var(--window-top) - var(--window-bottom))' })) + // 用户信息 + const userInfo = ref({ + avatar: '', + nickname: '', + account: '', + user_money: 0, + no_reflect_amount: 0, + work: '', + address: '', + work_time: '', + is_mileage: 0, + cert_id: 0, + }) + onShow(() => { + Withdraw.handleGetUserInfo() Withdraw.getBankCardList() }) @@ -142,6 +157,14 @@ bankList.value = res.list }, + /** + * 获取个人信息 + */ + handleGetUserInfo: async () => { + const res = await getUserInfo() + userInfo.value = res + }, + /** * 格式化银行卡号 * @ param bankCardNumber 银行卡号 @@ -167,12 +190,12 @@ * 全部提现 */ handleWithdrawAll: async () => { - if (useStore.userMoney <= 0) { + if (userInfo.value.user_money <= 0) { toast.info('暂无可提现金额') return } - withdrawMoney.value = String(useStore.userMoney) + withdrawMoney.value = String(userInfo.value.user_money) }, /** @@ -195,7 +218,7 @@ return } - if (money > useStore.userMoney) { + if (money > userInfo.value.user_money) { toast.info('提现金额不能大于可提现金额') return } @@ -204,14 +227,11 @@ title: '提交中...' }) try { - await withdrawApply(store.defaultStore.id, money, selectBank.value.id) - // 重新获取用户余额 - const balance = await getUserInfo() - useStore.setUserMoney(Number(balance.user_money)) + await withdrawApply(money, selectBank.value.id) uni.hideLoading toast.success('提现申请提交成功') - + Withdraw.handleGetUserInfo() uni.$emit('refreshWalletPage') router.navigateBack(1, 500) } catch (error) { diff --git a/src/bundle/profile/profile.vue b/src/bundle/profile/profile.vue index 51c0d25..d95c9a5 100644 --- a/src/bundle/profile/profile.vue +++ b/src/bundle/profile/profile.vue @@ -10,33 +10,33 @@