| | |
| | | import com.java110.core.factory.CommunitySettingFactory; |
| | | import com.java110.utils.cache.MappingCache; |
| | | import com.java110.utils.constant.WechatConstant; |
| | | import com.java110.utils.util.StringUtil; |
| | | import com.java110.vo.ResultVo; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | |
| | | * 格式化 |
| | | */ |
| | | public final static String FORMAT = "json"; |
| | | /** |
| | | * 格式化 |
| | | */ |
| | | public final static String APP_AUTH_TOKEN = "APP_AUTH_TOKEN"; |
| | | |
| | | /** |
| | | * 签名类型 |
| | |
| | | CommunitySettingFactory.getRemark(communityId,"APP_PRIVATE_KEY"), |
| | | "json", "utf-8", CommunitySettingFactory.getRemark(communityId,"ALIPAY_PUBLIC_KEY"), "RSA2"); |
| | | AlipayTradePayRequest request = new AlipayTradePayRequest(); |
| | | if (!StringUtil.isEmpty(CommunitySettingFactory.getValue(communityId, APP_AUTH_TOKEN))) { |
| | | request.putOtherTextParam("app_auth_token", CommunitySettingFactory.getValue(communityId, APP_AUTH_TOKEN)); |
| | | } |
| | | JSONObject bizContent = new JSONObject(); |
| | | bizContent.put("out_trade_no", orderNum); |
| | | bizContent.put("total_amount", money); |