diff --git a/mobile-web/src/api/order.js b/mobile-web/src/api/order.js index faefcb6b..72fdb1f6 100644 --- a/mobile-web/src/api/order.js +++ b/mobile-web/src/api/order.js @@ -21,7 +21,7 @@ export function confirmReceiving(orderId) { }); } -export function getConfirmCreateOrder(skuId, quantity) { +export function getOrderConfirmCreateOrder(skuId, quantity) { return request({ url: '/order-api/users/order/confirm_create_order', method: 'get', @@ -45,6 +45,18 @@ export function createOrder(params) { }); } +export function createOrderFromCart(userAddressId, + remark) { + return request({ + url: '/order-api/users/order/create_order_from_cart', + method: 'post', + params: { + userAddressId, + remark, + } + }); +} + // Cart export function addCart(skuId, quantity) { @@ -87,6 +99,17 @@ export function updateCartSelected(skuIds, selected) { }); } +export function getCartConfirmCreateOrder(skuId, quantity) { + return request({ + url: '/order-api/users/cart/confirm_create_order', + method: 'get', + params: { + skuId, + quantity, + } + }); +} + // 物流信息 export function getLogisticsInfo(params) { diff --git a/mobile-web/src/page/cart/index.vue b/mobile-web/src/page/cart/index.vue index 33136d84..47cce44f 100644 --- a/mobile-web/src/page/cart/index.vue +++ b/mobile-web/src/page/cart/index.vue @@ -157,7 +157,7 @@ export default { }) }, onSubmit() { - this.$router.push('/order') + this.$router.push('/order?from=cart') }, convertProduct(item) { // debugger; diff --git a/mobile-web/src/page/shipping/order.vue b/mobile-web/src/page/shipping/order.vue index 7cb647b6..5e6fea44 100644 --- a/mobile-web/src/page/shipping/order.vue +++ b/mobile-web/src/page/shipping/order.vue @@ -68,7 +68,12 @@