Jelajahi Sumber

Merge branch 'master' of hyq/kmall-pt into master

黄亚琴 6 tahun lalu
induk
melakukan
885ddd1d21

+ 10 - 0
kmall-admin/src/main/java/com/kmall/admin/entity/OrderEntity.java

@@ -134,6 +134,16 @@ public class OrderEntity
 
     private String orderSnWx;
 
+    private String isMergePay;
+
+    public String getIsMergePay() {
+        return isMergePay;
+    }
+
+    public void setIsMergePay(String isMergePay) {
+        this.isMergePay = isMergePay;
+    }
+
     public String getOrderSnWx() {
         return orderSnWx;
     }

+ 8 - 0
kmall-admin/src/main/resources/mybatis/mapper/OrderDao.xml

@@ -6,6 +6,7 @@
     <!-- 可根据自己的需求,是否要使用 -->
     <resultMap type="com.kmall.admin.entity.OrderEntity" id="orderMap">
         <result property="id" column="id"/>
+        <result property="merchOrderSn" column="merch_order_sn"/>
         <result property="orderSn" column="order_sn"/>
         <result property="userId" column="user_id"/>
         <result property="orderStatus" column="order_status"/>
@@ -58,6 +59,7 @@
         <result property="modTime" column="mod_time"/>
         <result property="isOnfflineOrder" column="is_onffline_order"/>
         <result property="orderSnWx" column="order_sn_wx"/>
+        <result property="isMergePay" column="is_merge_pay"/>
     </resultMap>
 
     <select id="queryObject" resultType="com.kmall.admin.entity.OrderEntity">
@@ -104,6 +106,9 @@
         <if test="storeId != null and storeId != ''">
             AND o.store_id = #{storeId}
         </if>
+        <if test="merchOrderSn != null and merchOrderSn.trim() != ''">
+            AND o.merch_order_sn = #{merchOrderSn}
+        </if>
         <if test="merchSn != null and merchSn.trim() != ''">
             AND o.merch_sn = #{merchSn}
         </if>
@@ -149,6 +154,9 @@
         <if test="storeId != null and storeId != ''">
             AND o.store_id = #{storeId}
         </if>
+        <if test="merchOrderSn != null and merchOrderSn.trim() != ''">
+            AND o.merch_order_sn = #{merchOrderSn}
+        </if>
         <if test="merchSn != null and merchSn.trim() != ''">
             AND o.merch_sn = #{merchSn}
         </if>

+ 3 - 0
kmall-admin/src/main/webapp/WEB-INF/page/shop/order.html

@@ -13,6 +13,9 @@
                     <i-input v-model="q.orderSn" @on-enter="query" placeholder="订单号"/>
                 </i-col>
                 <i-col span="4">
+                    <i-input v-model="q.merchOrderSn" @on-enter="query" placeholder="商户订单号"/>
+                </i-col>
+                <i-col span="4">
                     <i-select v-model="q.orderStatus" placeholder="订单状态">
                         <i-option value="0">待付款</i-option>
                         <i-option value="101">订单已取消</i-option>

+ 22 - 9
kmall-admin/src/main/webapp/js/shop/order.js

@@ -2,7 +2,7 @@ $(function () {
     let shippingStatus = getQueryString("shippingStatus");
     let payStatus = getQueryString("payStatus");
     let orderStatus = getQueryString("orderStatus");
-    let orderType = getQueryString("orderType");
+    let merchOrderSn = getQueryString("merchOrderSn");
     let url = '../order/list?1';
     if (shippingStatus) {
         url += '&shippingStatus=' + shippingStatus;
@@ -13,8 +13,8 @@ $(function () {
     if (orderStatus) {
         url += '&orderStatus=' + orderStatus;
     }
-    if (orderType) {
-        url += '&orderType=' + orderType;
+    if (merchOrderSn) {
+        url += '&merchOrderSn=' + merchOrderSn;
     }
     $("#jqGrid").jqGrid({
         url: url,
@@ -23,6 +23,19 @@ $(function () {
             {label: 'id', name: 'id', index: 'id', key: true, hidden: true},
             {label: '订单号', name: 'orderSn', index: 'order_sn', width: 100},
             {label: '会员', name: 'userName', index: 'user_name', width: 80},
+            {label: '支付类型', name: 'isMergePay', index: 'is_merge_pay', width: 60,
+                formatter: function (value) {
+                    if (value == '2') {
+                        return '合并支付';
+                    }else if (value == '1') {
+                        return '合并支付';
+                    } else if (value == '0') {
+                        return '单笔支付';
+                    }
+                    return '-';
+                }
+            },
+            {label: '商户订单号', name: 'merchOrderSn', index: 'merchOrderSn', width: 140},
             {
                 label: '订单业务类型', name: 'orderBizType', index: 'order_biz_type', width: 80,
                 formatter: function (value) {
@@ -93,9 +106,9 @@ $(function () {
                     return value;
                 }
             },
-            {label: '收货人', name: 'consignee', index: 'consignee', width: 80},
-            {label: '收货地址', name: 'address', index: 'address', width: 80},
-            {label: '联系电话', name: 'mobile', index: 'mobile', width: 80},
+            // {label: '收货人', name: 'consignee', index: 'consignee', width: 80},
+            // {label: '收货地址', name: 'address', index: 'address', width: 80},
+            // {label: '联系电话', name: 'mobile', index: 'mobile', width: 80},
             {label: '实际支付', name: 'actualPrice', index: 'actual_price', width: 60},
             {label: '订单总价', name: 'orderPrice', index: 'order_price', width: 60},
             {
@@ -180,7 +193,7 @@ let vm = new Vue({
         q: {
             orderSn: '',
             orderStatus: '',
-            orderType: ''
+            merchOrderSn: ''
         },
         refundMoney: 0,
         shipping: {},
@@ -302,7 +315,7 @@ let vm = new Vue({
                 postData: {
                     'orderSn': vm.q.orderSn,
                     'orderStatus': vm.q.orderStatus,
-                    'orderType': vm.q.orderType
+                    'merchOrderSn': vm.q.merchOrderSn
                 },
                 page: page
             }).trigger("reloadGrid");
@@ -311,7 +324,7 @@ let vm = new Vue({
             vm.q = {
                 orderSn: '',
                 orderStatus: '',
-                orderType: ''
+                merchOrderSn: ''
             };
         },
         lookDetail: function (rowId) { //第三步:定义编辑操作