Commit c6260e4e by chizw

sop短链 sop事件参数调整

1 parent 51d33667
...@@ -6,9 +6,10 @@ import lombok.extern.slf4j.Slf4j; ...@@ -6,9 +6,10 @@ import lombok.extern.slf4j.Slf4j;
import java.util.concurrent.TimeUnit; import java.util.concurrent.TimeUnit;
/** /**
* @author throwable * @Description 抽象命名过滤器
* @description 抽象命名过滤器 * @author chizw
* @since 2020/7/21 17:30 * @create 2023/10/10 16:55
* @version ver.1.0.0
*/ */
@Slf4j @Slf4j
@RequiredArgsConstructor @RequiredArgsConstructor
......
...@@ -82,7 +82,7 @@ public class UrlTransformFilter implements AccessFilter { ...@@ -82,7 +82,7 @@ public class UrlTransformFilter implements AccessFilter {
longUrl = b4RedirectPage + "?url=" + UrlUtil.splicingUrl(protocol,domainValue,context.getCompressCode()); longUrl = b4RedirectPage + "?url=" + UrlUtil.splicingUrl(protocol,domainValue,context.getCompressCode());
} else { } else {
if (StringUtils.isNotEmpty(urlParam)) { if (StringUtils.isNotEmpty(urlParam)) {
longUrl = String.format("%s?%s", longUrl, urlParam); longUrl = String.format("%s?%s&%s", longUrl, context.getParam(TransformContext.PARAM_QUERY_STRING_KEY), urlParam);
} }
if (addTimestamp != null && addTimestamp) { if (addTimestamp != null && addTimestamp) {
longUrl = String.format("%s%stimestamp=%s", longUrl, (longUrl.contains("?") ? "?" : "&"), new Date().getTime()); longUrl = String.format("%s%stimestamp=%s", longUrl, (longUrl.contains("?") ? "?" : "&"), new Date().getTime());
...@@ -90,6 +90,5 @@ public class UrlTransformFilter implements AccessFilter { ...@@ -90,6 +90,5 @@ public class UrlTransformFilter implements AccessFilter {
} }
context.setLocation(longUrl); context.setLocation(longUrl);
chain.doFilter(context); chain.doFilter(context);
} }
} }
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!