ApArticle apArticle = apArticleMapper.selectById(articleId);
if (apArticle == null){
log.warn("对象不存在");//打印日志
return;
}
apArticle.setStaticUrl(url);
apArticleMapper.update(apArticle,null);
我擦,更新数据库,用的update(),还没写wrapper查询条件。把整张表的每条数据都改了!!!。。。。
要用updateById()啊啊啊啊啊!!!