diff --git a/src/components/order_list/retail/retail.vue b/src/components/order_list/retail/retail.vue index 76e025e..48b5bad 100644 --- a/src/components/order_list/retail/retail.vue +++ b/src/components/order_list/retail/retail.vue @@ -33,7 +33,7 @@ export default { getGoodsName(){ let { orderInfo } = this; let _ls = orderInfo&&orderInfo.retail_order_goods || []; - let _str = _ls.map(e=>`${e.name}【${e.spec}】x${e.nums}`).join(';'); + let _str = _ls.map(e=>`${e.erp_retail_goods ? e.erp_retail_goods.goods_name : e.name}【${e.spec}】x${e.nums}`).join(';'); if(_ls.length)_str += ';' return _str } diff --git a/src/subpackage/order/js/api.js b/src/subpackage/order/js/api.js index b177948..9725c5a 100644 --- a/src/subpackage/order/js/api.js +++ b/src/subpackage/order/js/api.js @@ -24,6 +24,7 @@ export const ORDER_API = { rentballOrderEnd:`${ORIGIN}/admin/assistant/rentball/order/end`, // 租球机-结束计费 leaseOrderEnd:`${ORIGIN}/admin/stadium/leaseOrder/endBill`, // 租售柜-结束计费 retailOrderInfo:`${ORIGIN}/admin/erp/retailOrder/info`, // 订单管理-零售订单详情 + retailOrderInfoRefundList: `${ORIGIN}/admin/stadium/order/refundList`, // 订单管理-零售订单详情退款列表 userMonthlyCardInfo:`${ORIGIN}/admin/userMonthlyCard/get`, // 详情用户年月卡-后台 ymCardInfoFace:`${ORIGIN}/upload/file/ym_card_face`, // 年月卡用户头像上传 ymCardInfoFaceSave:`${ORIGIN}/admin/userMonthlyCard/updateFace`, // 年月卡用户头像保存 diff --git a/src/subpackage/order/pages/retail/detail/detail.vue b/src/subpackage/order/pages/retail/detail/detail.vue index d8bcf48..19f3f1c 100644 --- a/src/subpackage/order/pages/retail/detail/detail.vue +++ b/src/subpackage/order/pages/retail/detail/detail.vue @@ -10,7 +10,7 @@ 微信昵称: - {{ orderInfo.sys_optuname || '-' }} + {{ orderInfo.nickname || '-' }} {{ getStatus(orderInfo.pay_status) }} @@ -20,16 +20,16 @@ {{ orderInfo.mobile || '-' }} - + 下单途径: - {{ orderInfo.operator || '-' }} + {{ orderInfo.retail_source || '-' }} @@ -39,12 +39,12 @@ - {{ e.name || '-' }} - ¥{{ e.price || 0 }} + {{ e.erp_retail_goods ? (e.erp_retail_goods.goods_name || '-') : (e.name || '-') }} + ¥{{ e.erp_retail_goods ? (e.erp_retail_goods.erp_goods ? e.erp_retail_goods.erp_goods.erp_goods_price : 0) : 0 }} - sku:{{ e.sku || '-' }} + sku:{{ e.erp_retail_goods ? (e.erp_retail_goods.erp_goods ? e.erp_retail_goods.erp_goods.erp_goods_sku : '-') : '-' }} - 型号:{{ e.unit || '-' }}        规格:{{ e.spec || '-' }} + 型号:{{ e.erp_retail_goods ? (e.erp_retail_goods.erp_goods ? e.erp_retail_goods.erp_goods.erp_goods_type : '-') : '-' }}        规格:{{ e.spec || '-' }} x{{ e.nums || 0 }} @@ -58,7 +58,7 @@ 积分抵扣 - ¥{{ orderInfo.deduction_integral || 0 }} + ¥{{ orderInfo.deduction_amount || 0 }} 折扣金额 @@ -74,17 +74,36 @@ 支付详情 - + + - + + + + + 退款信息{{ index + 1 }} + + + + + @@ -95,6 +114,7 @@ import server from '../../../js/server'; import util from '../../../../../utils/util'; import s_line from '../../../components/s_line/s_line.vue'; import p_line from '../../../components/p_line/p_line.vue'; +import { mapState } from 'vuex'; export default { components: { 's-line': s_line, @@ -102,9 +122,13 @@ export default { }, data(){ return { - orderInfo: {} + orderInfo: {}, + refundList: [] } }, + computed:{ + ...mapState([ 'brandInfo',]) + }, onLoad(options){ this.getOrderInfo(options.order_no); }, @@ -131,17 +155,25 @@ export default { util.showLoad(); server.get({ url: ORDER_API.retailOrderInfo, - data: { order_no }, + data: { order_no, brand_id: this.brandInfo.brand.id }, failMsg: '加载失败!' }) .then(res=>{ - util.hideLoad(); this.orderInfo = res || {}; // this.orderInfo.refunds = [ // { refund_amount: this.orderInfo.refund_amount, refund_no: this.orderInfo.refund_no, refund_time: this.orderInfo.refund_time, refund_reason: this.orderInfo.refund_reason }, // { refund_amount: this.orderInfo.refund_amount, refund_no: this.orderInfo.refund_no, refund_time: this.orderInfo.refund_time, refund_reason: this.orderInfo.refund_reason } // ]; - }) + server.get({ + url: ORDER_API.retailOrderInfoRefundList, + data: { order_no, brand_id: this.brandInfo.brand.id }, + failMsg: '加载失败!' + }) + .then(res=>{ + util.hideLoad(); + this.refundList = res.list; + }); + }); }, } diff --git a/src/subpackage/retail/components/hover_cart_list/hover_cart_list.vue b/src/subpackage/retail/components/hover_cart_list/hover_cart_list.vue index cfd03b8..28cf9ef 100644 --- a/src/subpackage/retail/components/hover_cart_list/hover_cart_list.vue +++ b/src/subpackage/retail/components/hover_cart_list/hover_cart_list.vue @@ -15,7 +15,7 @@ {{ item.goods_name }} - {{ item.erp_goods.erp_goods_specs }} + {{ `${item.erp_goods.erp_goods_specs}/${item.erp_goods.erp_goods_type}/${item.erp_goods.erp_goods_sku}` }} diff --git a/src/subpackage/retail/pages/confirm_goods/confirm_goods.vue b/src/subpackage/retail/pages/confirm_goods/confirm_goods.vue index db70163..25ab2bb 100644 --- a/src/subpackage/retail/pages/confirm_goods/confirm_goods.vue +++ b/src/subpackage/retail/pages/confirm_goods/confirm_goods.vue @@ -16,7 +16,7 @@ {{ item.goods_name }} - {{ item.erp_goods.erp_goods_specs }} + {{ `${item.erp_goods.erp_goods_specs}/${item.erp_goods.erp_goods_type}/${item.erp_goods.erp_goods_sku}` }} x{{ item.count }} diff --git a/src/subpackage/retail/pages/confirm_order/confirm_order.vue b/src/subpackage/retail/pages/confirm_order/confirm_order.vue index 322ad9f..8f22372 100644 --- a/src/subpackage/retail/pages/confirm_order/confirm_order.vue +++ b/src/subpackage/retail/pages/confirm_order/confirm_order.vue @@ -116,8 +116,10 @@ let goods_data = []; for (let i = 0; i < this.cartListFinal.length; ++i) { goods_data.push({ - id: this.cartListFinal[i].erp_goods.erp_goods_cid, - name: this.cartListFinal[i].erp_goods.erp_goods_name, + // id: this.cartListFinal[i].erp_goods.erp_goods_cid, + id: this.cartListFinal[i].id, + // name: this.cartListFinal[i].erp_goods.erp_goods_name, + name: this.cartListFinal[i].goods_name, price: this.cartListFinal[i].erp_goods.erp_goods_price, nums: this.cartListFinal[i].count, unit: this.cartListFinal[i].erp_goods.erp_goods_unit, @@ -130,9 +132,10 @@ data: { goods_data, brand_id: _this.brandInfo.brand.id, store_id: _this.curStore.id, - amount: _this.totalPrice, pay_type: info.type, + amount: parseFloat(_this.totalPrice), pay_type: info.type, other_pay_type: info.inputValue, - card_no: info.cardNo + card_no: info.cardNo, + mark: '' }, isDefaultGet: false, failMsg: '出库失败!' @@ -158,7 +161,7 @@ }, // 确认支付 confirmPay() { - let info = { type: 0, inputValue: "default", cardNo: "default" }; + let info = { type: 0, inputValue: "", cardNo: "" }; switch (this.curChoose.name) { case "微信支付": info.type = 0; break; diff --git a/src/subpackage/retail/pages/index/index.vue b/src/subpackage/retail/pages/index/index.vue index 29ee88f..5831aef 100644 --- a/src/subpackage/retail/pages/index/index.vue +++ b/src/subpackage/retail/pages/index/index.vue @@ -40,7 +40,7 @@ {{ item.goods_name }} - {{ item.erp_goods.erp_goods_specs }} + {{ `${item.erp_goods.erp_goods_specs}/${item.erp_goods.erp_goods_type}/${item.erp_goods.erp_goods_sku}` }}