From a1be6075c6b1365a7abc66bf559d6058039248ab Mon Sep 17 00:00:00 2001 From: admin <weikou2014> Date: 星期三, 19 五月 2021 18:13:29 +0800 Subject: [PATCH] 淘礼金兼容 --- fanli/src/main/java/com/yeshi/fanli/util/factory/JumpDetailParamsFactory.java | 160 +++++++++++++++++++++++++++-------------------------- 1 files changed, 81 insertions(+), 79 deletions(-) diff --git a/fanli/src/main/java/com/yeshi/fanli/util/factory/JumpDetailParamsFactory.java b/fanli/src/main/java/com/yeshi/fanli/util/factory/JumpDetailParamsFactory.java index b5fb1fa..99afacd 100644 --- a/fanli/src/main/java/com/yeshi/fanli/util/factory/JumpDetailParamsFactory.java +++ b/fanli/src/main/java/com/yeshi/fanli/util/factory/JumpDetailParamsFactory.java @@ -1,79 +1,81 @@ -package com.yeshi.fanli.util.factory; - -import com.yeshi.fanli.entity.taobao.ClientTBPid; -import org.yeshi.utils.JsonUtil; - -import net.sf.json.JSONObject; - -public class JumpDetailParamsFactory { - - /** - * 鐧惧窛鐨勮烦杞弬鏁� - * - * @param clientTBPid - * @param url - * @return - */ - public static String createWEEXParams(ClientTBPid clientTBPid, String url) { - JSONObject data = new JSONObject(); - if (clientTBPid != null) - data.put("tbPidInfo", JsonUtil.getGson().toJson(clientTBPid)); - data.put("url", url); - return data.toString(); - } - - /** - * 鐧惧窛鐨勮烦杞弬鏁� - * - * @param clientTBPid - * @param auctionId - * @return - */ - public static String createWEEXParams(ClientTBPid clientTBPid, Long auctionId) { - JSONObject data = new JSONObject(); - if (clientTBPid != null) - data.put("tbPidInfo", JsonUtil.getGson().toJson(clientTBPid)); - data.put("id", auctionId); - return data.toString(); - } - - /** - * web鐨勮烦杞弬鏁� - * - * @param clientTBPid - * @param auctionId - * @return - */ - public static String createWEBParams(String url) { - JSONObject data = new JSONObject(); - data.put("url", url); - return data.toString(); - } - - /** - * weex鐨勮烦杞弬鏁� - * - * @param clientTBPid - * @param auctionId - * @return - */ - public static String createWEEXParams(String url) { - JSONObject data = new JSONObject(); - data.put("url", url); - return data.toString(); - } - - /** - * 鍟嗗搧璇︽儏鐨勮烦杞弬鏁� - * - * @param clientTBPid - * @param auctionId - * @return - */ - public static String createGoodsParams(ClientTBPid clientTBPid, Long auctionId) { - JSONObject data = new JSONObject(); - data.put("id", auctionId); - return data.toString(); - } - -} +package com.yeshi.fanli.util.factory; + +import com.yeshi.fanli.entity.taobao.ClientTBPid; +import org.yeshi.utils.JsonUtil; + +import net.sf.json.JSONObject; + +public class JumpDetailParamsFactory { + + /** + * 鐧惧窛鐨勮烦杞弬鏁� + * + * @param clientTBPid + * @param url + * @return + */ + public static String createWEEXParams(ClientTBPid clientTBPid, String url) { + JSONObject data = new JSONObject(); + if (clientTBPid != null) + data.put("tbPidInfo", JsonUtil.getGson().toJson(clientTBPid)); + data.put("url", url); + return data.toString(); + } + + /** + * 鐧惧窛鐨勮烦杞弬鏁� + * + * @param clientTBPid + * @param auctionId + * @return + */ + public static String createWEEXParams(ClientTBPid clientTBPid, Long auctionId) { + JSONObject data = new JSONObject(); + if (clientTBPid != null) + data.put("tbPidInfo", JsonUtil.getGson().toJson(clientTBPid)); + data.put("id", auctionId); + return data.toString(); + } + + /** + * web鐨勮烦杞弬鏁� + * + * @param clientTBPid + * @param auctionId + * @return + */ + public static String createWEBParams(String url) { + JSONObject data = new JSONObject(); + data.put("url", url); + return data.toString(); + } + + /** + * weex鐨勮烦杞弬鏁� + * + * @param clientTBPid + * @param auctionId + * @return + */ + public static String createWEEXParams(String url) { + JSONObject data = new JSONObject(); + data.put("url", url); + return data.toString(); + } + + /** + * 鍟嗗搧璇︽儏鐨勮烦杞弬鏁� + * + * @param clientTBPid + * @param auctionId + * @return + */ + public static String createGoodsParams(Long auctionId, Integer goodsType) { + JSONObject data = new JSONObject(); + data.put("id", auctionId); + if (goodsType != null) + data.put("goodsType", goodsType); + return data.toString(); + } + +} -- Gitblit v1.8.0