diff --git a/common/api/base.js b/common/api/base.js index ab47109..8195f71 100644 --- a/common/api/base.js +++ b/common/api/base.js @@ -2,7 +2,7 @@ * @Author: ch * @Date: 2022-04-06 17:29:13 * @LastEditors: ch - * @LastEditTime: 2022-04-07 09:58:34 + * @LastEditTime: 2022-04-15 14:17:14 * @Description: file content */ @@ -20,12 +20,12 @@ export const ApiGetAddress = () => export const ApiPostAddress = (data) => ToAsyncAwait(MsbRequestTk.post(`${BASE_URL}/receiveAddress`, data)); /** - * 修改 + * 收货地址修改 */ export const ApiPutAddress = (data) => ToAsyncAwait(MsbRequestTk.put(`${BASE_URL}/receiveAddress`, data)); /** - * 删除 + * 收货删除 */ export const ApiDeleteAddress = (data) => ToAsyncAwait(MsbRequestTk.delete(`${BASE_URL}/receiveAddress?idList=${data.idList}`)); \ No newline at end of file diff --git a/common/api/order.js b/common/api/order.js index 81a2900..00141fc 100644 --- a/common/api/order.js +++ b/common/api/order.js @@ -2,7 +2,7 @@ * @Author: ch * @Date: 2022-03-29 17:38:17 * @LastEditors: ch - * @LastEditTime: 2022-04-15 11:09:37 + * @LastEditTime: 2022-04-15 11:29:32 * @Description: file content */ import {ToAsyncAwait, MsbRequestTk} from '@/common/utils'; @@ -34,6 +34,13 @@ export const ApiGetBeforeCartOrder = (data) => */ export const ApiGetOrderDetail = (id) => ToAsyncAwait(MsbRequestTk.get(`${BASE_URL}/app/tradeOrder/${id}`)); + +/** + * 订单商品详情信息 + * @param {*} orderProductId + */ +export const ApiGetOrderProductDetail = ({orderProductId}) => + ToAsyncAwait(MsbRequestTk.get(`${BASE_URL}/app/tradeOrder/product/${orderProductId}`)); /** * 提交订单 * @param {*} data @@ -55,6 +62,10 @@ export const ApiPutCancelOrder = (data) => export const ApiPostWxPay = (data) => ToAsyncAwait(MsbRequestTk.post(`${BASE_URL}/pay/wxPay/app`, data)); + + + + /** * 申请售后 * @param {*} data diff --git a/common/store/index.js b/common/store/index.js index 90c5e1d..1858125 100644 --- a/common/store/index.js +++ b/common/store/index.js @@ -2,7 +2,7 @@ * @Author: ch * @Date: 2022-03-22 18:28:52 * @LastEditors: ch - * @LastEditTime: 2022-04-08 16:23:33 + * @LastEditTime: 2022-04-15 14:14:20 * @Description: file content */ import Vue from 'vue' @@ -37,10 +37,5 @@ export default new Vuex.Store({ state.address = address; uni.setStorageSync(ADDRESS, JSON.stringify(address)); } - }, - actions:{ - UPDATE_ADDRESS(){ - - } } }) \ No newline at end of file diff --git a/common/utils/requset.js b/common/utils/requset.js index 2bfc138..96b54c0 100644 --- a/common/utils/requset.js +++ b/common/utils/requset.js @@ -2,7 +2,7 @@ * @Author: ch * @Date: 2022-03-17 17:42:32 * @LastEditors: ch - * @LastEditTime: 2022-04-14 15:19:47 + * @LastEditTime: 2022-04-15 18:30:31 * @Description: 项目接口请求统一处理器,返回一个需要token和不需要token的请求封装方法 */ @@ -11,8 +11,8 @@ import $store from '@/common/store'; const ENV = 'test'; const BASE_URL = { - // 'test' : 'http://k8s-horse-gateway.mashibing.cn', - 'test' : '', + 'test' : 'http://k8s-horse-gateway.mashibing.cn', + // 'test' : '', 'release' : '', 'prod' : '' }; @@ -51,7 +51,7 @@ MsbRequestTk.baseUrl = BASE_URL[ENV]; MsbRequestTk.use('request', (option) => { - const token = $store.state.token + const token = $store.state.token; if(!token){ const pages = getCurrentPages(); const page = pages[pages.length - 1]; diff --git a/components/UiButton.vue b/components/UiButton.vue index 7fd9880..74dbf98 100644 --- a/components/UiButton.vue +++ b/components/UiButton.vue @@ -2,7 +2,7 @@ * @Author: ch * @Date: 2022-03-26 10:06:38 * @LastEditors: ch - * @LastEditTime: 2022-04-13 17:44:38 + * @LastEditTime: 2022-04-15 15:43:12 * @Description: file content -->