Commit 3543d3fe authored by shiyu's avatar shiyu

公众号发送模板消息-商品名称

parent 1f929b52
...@@ -302,7 +302,7 @@ public class ConsignSaleServiceImpl implements ConsignSaleService { ...@@ -302,7 +302,7 @@ public class ConsignSaleServiceImpl implements ConsignSaleService {
long itemId = userConsignSale.getItemId(); long itemId = userConsignSale.getItemId();
Item item = itemDao.findById(itemId); Item item = itemDao.findById(itemId);
String itemName = item.getName(); String itemName = item.getName();
String content = itemName.length() > 5 ? itemName.substring(0, 5) : itemName + "," + price; String content = (itemName.length() > 5 ? itemName.substring(0, 5) : itemName) + "," + price;
ConsignSaleSubscribeMsg consignSaleSubscribeMsg = ConsignSaleSubscribeMsg.of(saleId, content, new Date()); ConsignSaleSubscribeMsg consignSaleSubscribeMsg = ConsignSaleSubscribeMsg.of(saleId, content, new Date());
consignSaleSubscribeMsg.setPageTitle(pageTitle); consignSaleSubscribeMsg.setPageTitle(pageTitle);
officialAccountApi.sendModelMsg(openId, consignSaleSubscribeMsg); officialAccountApi.sendModelMsg(openId, consignSaleSubscribeMsg);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment