*/
@Override
public void prePersist(Model model) {
User user=UserHolder.getCurrentLoginUser();
if(model instanceof SimpleModel){
SimpleModel simpleModel = (SimpleModel)model;
if(user!=null && simpleModel.getOwnerUser()==null && !model.getClass().isAnnotationPresent(IgnoreUser.class)){
//设置数据的拥有者
simpleModel.setOwnerUser(user);
LOG.debug("设置模型"+model+"的拥有者为:"+user.getUsername());
}
}
//设置创建时间
model.setCreateTime(new Date());