fix 订单标题过长的问题

This commit is contained in:
Jack 2025-10-14 17:20:31 +08:00
parent 9e58bde9d0
commit 54d6e6e885

View File

@ -6529,11 +6529,7 @@ public class ShopOrderBaseServiceImpl extends BaseServiceImpl<ShopOrderBaseMappe
if (CollUtil.isNotEmpty(item_items)) {
String firstProductName = Convert.toStr(item_items.get(0).get("product_item_name"));
if (StrUtil.isNotBlank(firstProductName)) {
firstProductName = StrUtil.trim(firstProductName);
// 限制长度防止超出字段限制
if (StrUtil.length(firstProductName) > 100) {
firstProductName = firstProductName.substring(0, 100);
}
firstProductName = StrUtil.subPre(StrUtil.trim(firstProductName), 100);
product_item_name = firstProductName + "等商品";
}
}