| | |
| | | return ResultData.error("图片地址不能为空"); |
| | | if (slideshow.getLinkType()==null) |
| | | return ResultData.error("跳转链接类型不能为空"); |
| | | if (slideshow.getLinkType().equals(2)) { |
| | | if (slideshow.getTitle()==null||slideshow.getTitle()=="") |
| | | return ResultData.error("标题不能为空"); |
| | | if (slideshow.getLinkType().equals(2)&&(slideshow.getContent()==null||slideshow.getContent()=="")) |
| | | return ResultData.error("类型为富文本时,标题不能为空"); |
| | | if (slideshow.getContent() == null || slideshow.getContent() == "") |
| | | return ResultData.error("类型为富文本时,富文本内容不能为空"); |
| | | if (slideshow.getLinkType().equals(4)&&(slideshow.getLink()==null||slideshow.getLink()=="")) |
| | | } |
| | | if (slideshow.getLinkType().equals(3) && (slideshow.getLink() == null || slideshow.getLink() == "")) |
| | | return ResultData.error("类型为微信文章时,文章链接容不能为空"); |
| | | slideshow.setCreateTime(LocalDateTime.now()); |
| | | return ResultData.success( baseMapper.insert(slideshow)) ; |
| | |
| | | return ResultData.error("图片地址不能为空"); |
| | | if (slideshow.getLinkType()==null) |
| | | return ResultData.error("跳转链接类型不能为空"); |
| | | if (slideshow.getLinkType().equals(2)) { |
| | | if (slideshow.getTitle()==null||slideshow.getTitle()=="") |
| | | return ResultData.error("标题不能为空"); |
| | | if (slideshow.getLinkType().equals(2)&&(slideshow.getContent()==null||slideshow.getContent()=="")) |
| | | return ResultData.error("类型为富文本时,标题不能为空"); |
| | | if (slideshow.getContent() == null || slideshow.getContent() == "") |
| | | return ResultData.error("类型为富文本时,富文本内容不能为空"); |
| | | if (slideshow.getLinkType().equals(4)&&(slideshow.getLink()==null||slideshow.getLink()=="")) |
| | | } |
| | | if (slideshow.getLinkType().equals(3) && (slideshow.getLink() == null || slideshow.getLink() == "")) |
| | | return ResultData.error("类型为微信文章时,文章链接容不能为空"); |
| | | return ResultData.success(baseMapper.updateById(slideshow)); |
| | | |