Commit 5888aac9 authored by shiyu's avatar shiyu

商品详情

parent 66516a92
......@@ -165,9 +165,9 @@ public class SupplierItemServiceImpl implements SupplierItemService {
}
SupplierItem supplierItem = supplierItemDao.findById(itemId);
SupplierItemVo supplierItemVo = new SupplierItemVo();
if (StringUtils.hasLength(shareRecordId)) {
//做浏览记录
boolean flag = userRecentBrowseDao.isExisted(dto.getUserId(),distributorShareRecord.getDistributorId());
boolean flag = userRecentBrowseDao.isExisted(dto.getUserId(), distributorShareRecord.getDistributorId());
if (!flag) {
UserRecentBrowse newRecord = new UserRecentBrowse();
newRecord.setShareRecordId(dto.getShareRecordId());
......@@ -178,6 +178,8 @@ public class SupplierItemServiceImpl implements SupplierItemService {
newRecord.setType(DistributionEnum.UserBrowseTypeEnum.PLATFORM_ITEM.getCode());
userRecentBrowseDao.insert(newRecord);
}
}
//用户点击链接进入详情页需要记录
if (!dto.getIsShop()) {
supplierItemVo.setSalePrice(PriceUtil.convertPriceFenToYuan(distributorShareRecord.getPrice()));
......@@ -379,7 +381,7 @@ public class SupplierItemServiceImpl implements SupplierItemService {
} else {
itemId = dto.getId();
}
//保存浏览记录
if (StringUtils.hasLength(shareRecordId)) {
//做浏览记录
boolean flag = userRecentBrowseDao.isExisted(dto.getUserId(), distributorShareRecord.getDistributorId());
if (!flag) {
......@@ -392,6 +394,7 @@ public class SupplierItemServiceImpl implements SupplierItemService {
newRecord.setType(DistributionEnum.UserBrowseTypeEnum.PLATFORM_ITEM.getCode());
userRecentBrowseDao.insert(newRecord);
}
}
//查询商品竞拍信息
AuctionConfig auctionConfig = auctionConfigDao.findByItemId(itemId);
......@@ -674,7 +677,6 @@ public class SupplierItemServiceImpl implements SupplierItemService {
}
@Override
public Result delete(SupplierItemRequestDto dto) {
try {
......
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