| | |
| | | * 淘宝联盟网页搜索商品
|
| | | *
|
| | | * @param filter
|
| | | * @param config
|
| | | * -联盟配置
|
| | | * @param config -联盟配置
|
| | | * @return
|
| | | */
|
| | | public static TaoBaoSearchResult searchFromAlimamaWeb(SearchFilter filter, TaoBaoUnionConfig config) {
|
| | |
| | | * 淘宝联盟网页搜索商品
|
| | | *
|
| | | * @param filter
|
| | | * @param config
|
| | | * -联盟配置
|
| | | * @param config -联盟配置
|
| | | * @return
|
| | | */
|
| | | public static TaoBaoSearchResult searchAlimamaWeb(SearchFilter filter, TaoBaoUnionConfig config, Integer typeNum) {
|
| | |
| | | /**
|
| | | * 获取商品的用户分成比例
|
| | | *
|
| | | * @param goodsBrief
|
| | | * 商品详情
|
| | | * @param rate
|
| | | * 用户再次分成比例(0-100)
|
| | | * @param goodsBrief 商品详情
|
| | | * @param rate 用户再次分成比例(0-100)
|
| | | * @return
|
| | | */
|
| | | public static String getGoodsHongBaoInfo(TaoBaoGoodsBrief goodsBrief, BigDecimal rate, boolean share) {
|
| | |
| | | }
|
| | |
|
| | | /**
|
| | | * |
| | | * @param auctionId
|
| | | * @return
|
| | | */
|
| | |
| | | /**
|
| | | * 获取淘宝联盟的授权链接
|
| | | *
|
| | | * @param appKey
|
| | | * -应用Key
|
| | | * @param callBackUrl
|
| | | * -回调链接
|
| | | * @param appKey -应用Key
|
| | | * @param callBackUrl -回调链接
|
| | | * @param uid-用户ID
|
| | | * @return
|
| | | */
|
| | |
| | | /**
|
| | | * 抖音返利local 获取真实淘宝链接
|
| | | *
|
| | | * @param url
|
| | | * https://s.click.taobao.com/t?e=m%3D2%26s%
|
| | | * @param url https://s.click.taobao.com/t?e=m%3D2%26s%
|
| | | * 3DT9DFpHQCT7Rw4vFB6t2Z2ueEDrYVVa64XoO8tOebS+dRAdhuF14FMR8
|
| | | * @return
|
| | | */
|
| | |
| | | */
|
| | | public static List<String> getTokenListFromText(String str) {
|
| | | String[] marks = taoTokenSymbols;
|
| | | List<String> list=new ArrayList<>();
|
| | | for(String m:marks){
|
| | | for(String m1:marks){
|
| | | list.add(m.split("-")[0]+"-"+m1.split("-")[1]);
|
| | | }
|
| | | }
|
| | |
|
| | | return getTokenListFromText(str, Arrays.asList(marks));
|
| | | return getTokenListFromText(str, list);
|
| | | }
|
| | |
|
| | | /**
|
| | |
| | | public static List<String> getTokenListFromTextWithKuoHao(String str) {
|
| | | String[] marks = taoTokenSymbols;
|
| | | List<String> list = new ArrayList<>();
|
| | | for (String st : marks)
|
| | | list.add(st);
|
| | | for(String m:marks){
|
| | | for(String m1:marks){
|
| | | list.add(m.split("-")[0]+"-"+m1.split("-")[1]);
|
| | | }
|
| | | }
|
| | |
|
| | | list.add("\\(-\\)");
|
| | | list.add("(-)");
|
| | | return getTokenListFromText(str, list);
|
| | |
| | |
|
| | | /**
|
| | | * 获取能够分的钱
|
| | | *
|
| | | * @param estimate
|
| | | * @return BigDecimal 返回类型
|
| | | * @throws
|
| | | * @Title: getCanShareMoney
|
| | | * @Description:
|
| | | * @param estimate
|
| | | * @return |
| | | * BigDecimal 返回类型
|
| | | * @throws
|
| | | */
|
| | | public static BigDecimal getCanShareMoney(Date createTime, BigDecimal estimate) {
|
| | | if (estimate == null)
|
| | |
| | | return MoneyBigDecimalUtil.mul(estimate, rate);
|
| | | }
|
| | |
|
| | | /**
|
| | | * 拼接渠道ID
|
| | | * @param url
|
| | | * @param relationId
|
| | | * @return
|
| | | */
|
| | | public static String concatRelationId(String url, String relationId) {
|
| | | if (StringUtil.isNullOrEmpty(relationId))
|
| | | return url;
|
| | | return url + "&relationId=" + relationId;
|
| | | }
|
| | |
|
| | | }
|