"jshERP-boot/src/git@ustchcs.com:gujinli1118/JSH_ERP.git" did not exist on "e7d7666b3d6f731d001cb7a792348af34df17c45"
Commit 94463c26 authored by Junling Bu's avatar Junling Bu
Browse files

litemall-db模块更新:

1. mybatis generator更新1.3.7
2. mybatis-generator-plugin更新1.2.12
3. 更新所有自动生成代码
4. OrderMapper,实现基于update_time的乐观锁更新
parent d4b95ef2
...@@ -8,6 +8,7 @@ import org.springframework.stereotype.Service; ...@@ -8,6 +8,7 @@ import org.springframework.stereotype.Service;
import org.springframework.util.StringUtils; import org.springframework.util.StringUtils;
import javax.annotation.Resource; import javax.annotation.Resource;
import java.time.LocalDateTime;
import java.util.List; import java.util.List;
@Service @Service
...@@ -57,6 +58,7 @@ public class LitemallAdService { ...@@ -57,6 +58,7 @@ public class LitemallAdService {
} }
public int updateById(LitemallAd ad) { public int updateById(LitemallAd ad) {
ad.setUpdateTime(LocalDateTime.now());
return adMapper.updateByPrimaryKeySelective(ad); return adMapper.updateByPrimaryKeySelective(ad);
} }
...@@ -65,6 +67,8 @@ public class LitemallAdService { ...@@ -65,6 +67,8 @@ public class LitemallAdService {
} }
public void add(LitemallAd ad) { public void add(LitemallAd ad) {
ad.setAddTime(LocalDateTime.now());
ad.setUpdateTime(LocalDateTime.now());
adMapper.insertSelective(ad); adMapper.insertSelective(ad);
} }
......
Supports Markdown
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