支付参数长度进行限制

This commit is contained in:
Chopper 2022-05-18 16:48:03 +08:00
parent fc7b17fe40
commit e3626a094d
2 changed files with 5 additions and 8 deletions

View File

@ -47,6 +47,10 @@ public class CashierParam {
if (StringUtils.isEmpty(detail)) {
return "清单详细";
}
//对参数长度进行限制
if (!StringUtils.isEmpty(detail) && detail.length() > 30) {
detail = detail.substring(30);
}
return StringUtils.filterSpecialChart(detail);
}
}

View File

@ -1,5 +1,6 @@
package cn.lili.modules.payment.kit.plugin.wechat.model;
import cn.hutool.json.JSONUtil;
import cn.lili.common.utils.StringUtils;
import lombok.Data;
import lombok.experimental.Accessors;
@ -85,14 +86,6 @@ public class UnifiedOrderModel {
*/
private SceneInfo scene_info;
public String getDescription() {
if (!StringUtils.isEmpty(description) && description.length() > 30) {
return description.substring(30);
}
return description;
}
}