diff --git a/api/user.js b/api/user.js index 6af8132..a8e631b 100644 --- a/api/user.js +++ b/api/user.js @@ -165,4 +165,23 @@ export const isUserShipApi = (data) => { export const getRechargeListApi = (data) => { return request.get('/user/UserRecharge/recharge_list', data); +} + +/** + * 提现信息 + */ +export const getCashInfoApi = (data) => { + return request.get('/user/User/cash_info', data); +} +/** + * 提交提现申请 + */ +export const CashApplicationApi = (data) => { + return request.post('/user/User/cash_application', data); +} +/** + * 提现申请记录 + */ +export const getCashRecordApi = (data) => { + return request.get('/user/User/cash_record', data); } \ No newline at end of file diff --git a/config/app.js b/config/app.js index 5657b7c..971d6b2 100644 --- a/config/app.js +++ b/config/app.js @@ -17,7 +17,7 @@ switch (env) { WSS_URL = 'wss://ceshi-multi-store.lihaink.cn/pull' break; case 'local': - BASE_URL = 'http://192.168.1.22:8545'; + BASE_URL = 'http://192.168.1.231:8545'; WSS_URL = 'wss://ceshi-multi-store.lihaink.cn/pull' break; default: diff --git a/pages.json b/pages.json index 3df30a7..e30cb07 100644 --- a/pages.json +++ b/pages.json @@ -100,6 +100,27 @@ "navigationBarTitleText" : "商品列表", "enablePullDownRefresh": true } + }, + { + "path" : "pages/user_cash/index", + "style" : + { + "navigationBarTitleText" : "提现" + } + }, + { + "path" : "pages/user_cash/status", + "style" : + { + "navigationBarTitleText" : "" + } + }, + { + "path" : "pages/user_cash/list", + "style" : + { + "navigationBarTitleText" : "提现申请记录" + } } ], "subPackages": [{ @@ -176,6 +197,13 @@ "navigationBarTitleText": "设置密码", "enablePullDownRefresh": false } + }, + { + "path" : "delivery/index", + "style" : + { + "navigationBarTitleText" : "配送员订单" + } } ] }, diff --git a/pages/index/index.vue b/pages/index/index.vue index 9ac8b1b..5ba2761 100644 --- a/pages/index/index.vue +++ b/pages/index/index.vue @@ -655,8 +655,7 @@ } const settleAccounts = () => { - - if (+cartInfo.value.pay_price < 500) return showOverlay.value = true; + if (+cartInfo.value.pay_price < 500 && userStore.userInfo.user_ship==0 ) return showOverlay.value = true; uni.navigateTo({ url: '/pagesOrder/settle/settle' }) diff --git a/pages/login/login.vue b/pages/login/login.vue index 0b1ddc5..8018f19 100644 --- a/pages/login/login.vue +++ b/pages/login/login.vue @@ -7,7 +7,7 @@ - + 欢迎登录泸优采 @@ -16,7 +16,7 @@ 手机号快捷登录 - + 账号登录 @@ -100,8 +100,11 @@ config } from "@/config/app.js" - + const test_click=ref(0); const showOfficial = ref(false); + const test=()=>{ + test_click.value++ + } const navToIndex = () => { if (userStore.userInfo && userStore.token) uni.reLaunch({ url: '/pages/index/index' diff --git a/pages/my/my.vue b/pages/my/my.vue index 3ae918c..6fbab3d 100644 --- a/pages/my/my.vue +++ b/pages/my/my.vue @@ -51,7 +51,8 @@ 会员报备 - + + 余额: @@ -121,7 +122,9 @@ --> - + + + diff --git a/pages/product/product.vue b/pages/product/product.vue index c3e03bc..2163cc4 100644 --- a/pages/product/product.vue +++ b/pages/product/product.vue @@ -4,14 +4,14 @@ - - - + + + - + - + @@ -29,15 +29,15 @@ - - + + - + @@ -57,7 +57,7 @@ let status = ref('loadmore') let list1 = ['零售', '商户', '会员'] let keyword = ref(''); - + let enable_flex=ref(true) const where = ref({ page_no: 1, page_size: 15, @@ -99,6 +99,34 @@ \ No newline at end of file diff --git a/pages/user_cash/index.vue b/pages/user_cash/index.vue new file mode 100644 index 0000000..56ecc43 --- /dev/null +++ b/pages/user_cash/index.vue @@ -0,0 +1,506 @@ + + + + + \ No newline at end of file diff --git a/pages/user_cash/list.vue b/pages/user_cash/list.vue new file mode 100644 index 0000000..a4cb8db --- /dev/null +++ b/pages/user_cash/list.vue @@ -0,0 +1,93 @@ + + + + + \ No newline at end of file diff --git a/pages/user_cash/status.vue b/pages/user_cash/status.vue new file mode 100644 index 0000000..14757fd --- /dev/null +++ b/pages/user_cash/status.vue @@ -0,0 +1,34 @@ + + + + + diff --git a/pagesOrder/delivery/index.vue b/pagesOrder/delivery/index.vue new file mode 100644 index 0000000..39dbecb --- /dev/null +++ b/pagesOrder/delivery/index.vue @@ -0,0 +1,596 @@ + + + + + \ No newline at end of file diff --git a/pagesOrder/settle/settle.vue b/pagesOrder/settle/settle.vue index 3840893..b1f8337 100644 --- a/pagesOrder/settle/settle.vue +++ b/pagesOrder/settle/settle.vue @@ -83,13 +83,17 @@ + 价格明细 商品总价 共计{{ cartList.length }}款商品 - + ¥{{ c_price(orderInfo.pay_price, 0) }}.{{ c_price(orderInfo.pay_price, 1) }} + + + 运费 @@ -255,10 +259,13 @@ import ZyPasswordboard from '@/uni_modules/zy-passwordboard/components/zy-passwordboard/zy-passwordboard.vue'; const userInfo = useUserStore().userInfo; + const shop_Info = ref({}) + // 用户选择的门店信息 let STORE_INFO = uni.getStorageSync('STORE_INFO'); - if (STORE_INFO) - STORE_INFO = JSON.parse(STORE_INFO) + if (STORE_INFO){ + shop_Info.value = JSON.parse(STORE_INFO) + } const cartStore = useCartStore(); const reservation_time = ref('') @@ -344,23 +351,6 @@ }) } - // getMerchantList(); - // 定位 - // const LoadAddress = () => { - // uni.getLocation({ - // success: (res) => {}, - // fail: (err) => { - // uni.$u.toast('定位失败, 请手动选择提货点!') - // }, - // complete: (res) => { - // myAddressInfo.value.long = res.longitude || ""; - // myAddressInfo.value.lat = res.latitude || ""; - // getMerchantList(); - // } - // }) - // } - // LoadAddress(); - const changeShop = (e) => { shopInfo.value = e; shopListShow.value = false; @@ -395,7 +385,7 @@ } // 提交订单 - const submitOrder = () => { + const submitOrder = () => { if (orderInfo.value.pay_price == 0) { pay_type.value = 3; return uni.$u.toast('当前支付金额为0,暂不能使用微信支付') @@ -412,13 +402,12 @@ long: "", }; let reservation = ref(0); - const shop_Info = ref({}) const cartList = ref([]); const orderInfo = ref({}); const checkOrder = (store_id) => { checkOrderApi({ cart_id: cartStore.cartList, - store_id: STORE_INFO.id || 0, + store_id: shop_Info.value.id || 0, ...location }).then(res => { cartList.value = res.data.cart_list; @@ -447,7 +436,7 @@ }).then(res => { reservation.value = res.data.reservation }) - + checkOrder(datas.id) // formData.store_id = datas.id // formData.store_name = datas.name }) @@ -483,7 +472,6 @@ cart_id: cartStore.cartList, address_id: addressInfo.value.address_id, pay_type: pay_type.value, - store_id: STORE_INFO.id || 0, store_id: shop_Info.value.id, shipping_type: orderInfo.value.shipping_type, mark: formData.value.remark, @@ -564,8 +552,8 @@ price = price + ''; return price.split('.')[index] || (index ? '00' : '0'); } - const toastAddressoff=()=>{ - toastAddressShow.value=false; + const toastAddressoff = () => { + toastAddressShow.value = false; uni.redirectTo({ url: '/pagesOrder/settle/settle' }); @@ -607,7 +595,7 @@ const userLocationfalse = () => { LocationShow.value = false; uni.$u.toast('获取位置当前失败,为你推荐当前门店') - checkOrder(STORE_INFO.id); + checkOrder(shop_Info.value.id); } const opensettings = (a = false) => { if (a == false) {