Explorar el Código

优化微信支付

wuxw hace 3 años
padre
commit
a5d25bc825

+ 4 - 2
java110-db/src/main/resources/mapper/community/ActivitiesServiceDaoImplMapper.xml

@@ -126,14 +126,16 @@
         </if>
     </insert>
 
-    <!-- 查询活动信息 add by wuxw 2018-07-03 -->
+    <!-- 查询活动信息 add by wuxw 2018-07-03
+
+    -->
     <select id="getActivitiesInfo" parameterType="Map" resultType="Map">
         select t.collect_count,t.collect_count collectCount,t.like_count,t.like_count likeCount,t.status_cd,t.status_cd
         statusCd,t.title,t.read_count,t.read_count readCount,t.user_name,t.user_name userName,t.user_id,t.user_id
         userId,t.activities_id,t.activities_id activitiesId,t.type_cd,t.type_cd
         typeCd,
         <if test="activitiesId !=null and activitiesId != ''">
-        t.context,
+            t.context,
         </if>
         t.start_time,t.start_time startTime,t.end_time,t.end_time endTime,t.community_id,t.community_id
         communityId,t.b_id,t.b_id bId,t.header_img,t.header_img headerImg,t.state,act.type_name typeCdName,t.create_time

+ 2 - 1
service-acct/src/main/java/com/java110/acct/smo/impl/QrCodeWechatPaymentAdapt.java

@@ -135,13 +135,14 @@ public class QrCodeWechatPaymentAdapt implements IQrCodePaymentSMO {
 
             SortedMap<String, String> paramMap = new TreeMap<String, String>();
             paramMap.put("appid", shopSmallWeChatDto.getAppId());
-            paramMap.put("sub_mch_id", shopSmallWeChatDto.getMchId());
+            paramMap.put("mch_id", shopSmallWeChatDto.getMchId());
             paramMap.put("nonce_str", PayUtil.makeUUID(32));
             paramMap.put("out_trade_no", orderNum);
             String paySwitch = MappingCache.getValue(DOMAIN_WECHAT_PAY, WECHAT_SERVICE_PAY_SWITCH);
             if (WECHAT_SERVICE_PAY_SWITCH_ON.equals(paySwitch)) {
                 paramMap.put("appid", MappingCache.getValue(DOMAIN_WECHAT_PAY, WECHAT_SERVICE_APP_ID));  //服务商appid,是服务商注册时公众号的id
                 paramMap.put("mch_id", MappingCache.getValue(DOMAIN_WECHAT_PAY, WECHAT_SERVICE_MCH_ID));  //服务商商户
+                paramMap.put("sub_mch_id", shopSmallWeChatDto.getMchId());
             }
             paramMap.put("sign", PayUtil.createSign(paramMap, shopSmallWeChatDto.getPayPassword()));
 //转换为xml