提交 aa4e97fd authored 作者: renjiancai's avatar renjiancai

--no commit message

上级 545213d8
...@@ -11,9 +11,9 @@ import javax.persistence.Table; ...@@ -11,9 +11,9 @@ import javax.persistence.Table;
import lombok.Data; import lombok.Data;
@Data @Data
@ApiModel(value="BookLabelDiyType",description="图书与标签关系表") @ApiModel(value="BookLibraryLabel",description="图书与标签关系表")
@Table(name = "res_book_label") @Table(name = "res_book_library_label")
public class BookLabel { public class BookLibraryLabel {
@Id @Id
@GeneratedValue(strategy =GenerationType.IDENTITY, generator = "SELECT REPLACE (UUID(), '-', '')") @GeneratedValue(strategy =GenerationType.IDENTITY, generator = "SELECT REPLACE (UUID(), '-', '')")
@ApiModelProperty("图书与标签内容关系表id") @ApiModelProperty("图书与标签内容关系表id")
......
...@@ -35,7 +35,7 @@ import com.zrqx.core.model.resource.audiolibrary.AudioLibraryLabel; ...@@ -35,7 +35,7 @@ import com.zrqx.core.model.resource.audiolibrary.AudioLibraryLabel;
import com.zrqx.core.model.resource.authorLibrary.AuthorLibrary; import com.zrqx.core.model.resource.authorLibrary.AuthorLibrary;
import com.zrqx.core.model.resource.authorLibrary.AuthorLibraryDiyType; import com.zrqx.core.model.resource.authorLibrary.AuthorLibraryDiyType;
import com.zrqx.core.model.resource.authorLibrary.AuthorLibraryLabel; import com.zrqx.core.model.resource.authorLibrary.AuthorLibraryLabel;
import com.zrqx.core.model.resource.ebook.BookLabel; import com.zrqx.core.model.resource.ebook.BookLibraryLabel;
import com.zrqx.core.util.CallBack; import com.zrqx.core.util.CallBack;
import com.zrqx.core.util.PageInfo; import com.zrqx.core.util.PageInfo;
import com.zrqx.core.util.PageParam; import com.zrqx.core.util.PageParam;
......
...@@ -50,7 +50,7 @@ import com.zrqx.core.model.resource.ebook.BookDiyType; ...@@ -50,7 +50,7 @@ import com.zrqx.core.model.resource.ebook.BookDiyType;
import com.zrqx.core.model.resource.ebook.BookGoods; import com.zrqx.core.model.resource.ebook.BookGoods;
import com.zrqx.core.model.resource.ebook.BookGoodsAlbum; import com.zrqx.core.model.resource.ebook.BookGoodsAlbum;
import com.zrqx.core.model.resource.ebook.BookIssued; import com.zrqx.core.model.resource.ebook.BookIssued;
import com.zrqx.core.model.resource.ebook.BookLabel; import com.zrqx.core.model.resource.ebook.BookLibraryLabel;
import com.zrqx.core.model.resource.ebook.BookResource; import com.zrqx.core.model.resource.ebook.BookResource;
import com.zrqx.core.model.resource.ebook.Ebook; import com.zrqx.core.model.resource.ebook.Ebook;
import com.zrqx.core.model.resource.imagelibrary.ImageLibrary; import com.zrqx.core.model.resource.imagelibrary.ImageLibrary;
...@@ -187,7 +187,7 @@ public class EbookLibraryController { ...@@ -187,7 +187,7 @@ public class EbookLibraryController {
List<BookDiyType> dtList = bookTypeService.selectByCriteria(); List<BookDiyType> dtList = bookTypeService.selectByCriteria();
// 自定义标签 // 自定义标签
bookLableService.createCriteria().andEqualTo("objectId", oid); bookLableService.createCriteria().andEqualTo("objectId", oid);
List<BookLabel> listLabel = bookLableService.selectByCriteria(); List<BookLibraryLabel> listLabel = bookLableService.selectByCriteria();
// 商品相册 // 商品相册
bookAlbumService.createCriteria().andEqualTo("bookId", oid); bookAlbumService.createCriteria().andEqualTo("bookId", oid);
List<BookGoodsAlbum> album = bookAlbumService.selectByCriteria(); List<BookGoodsAlbum> album = bookAlbumService.selectByCriteria();
...@@ -228,16 +228,16 @@ public class EbookLibraryController { ...@@ -228,16 +228,16 @@ public class EbookLibraryController {
vo.setLabelList(new ArrayList<LabelAndContentByDataTypeVO>()); vo.setLabelList(new ArrayList<LabelAndContentByDataTypeVO>());
vo.setLabelId(new ArrayList<String>()); vo.setLabelId(new ArrayList<String>());
vo.setLabelContentId(new ArrayList<String>()); vo.setLabelContentId(new ArrayList<String>());
List<BookLabel> listTemp = new ArrayList<BookLabel>(); List<BookLibraryLabel> listTemp = new ArrayList<BookLibraryLabel>();
if (listLabel != null && listLabel.size() > 0) { if (listLabel != null && listLabel.size() > 0) {
for (BookLabel label : listLabel) { for (BookLibraryLabel label : listLabel) {
vo.getLabelContentId().add(label.getLabelContentId()); vo.getLabelContentId().add(label.getLabelContentId());
if (!vo.getLabelId().contains(label.getLabelId())) { if (!vo.getLabelId().contains(label.getLabelId())) {
vo.getLabelId().add(label.getLabelId()); vo.getLabelId().add(label.getLabelId());
listTemp.add(label); listTemp.add(label);
} }
} }
for (BookLabel booklable : listTemp) { for (BookLibraryLabel booklable : listTemp) {
List<LabelAndContentByDataTypeVO> voList = labelContentDiyTypeService List<LabelAndContentByDataTypeVO> voList = labelContentDiyTypeService
.listContent(ResourceTypeEnum.BOOK.getCode(), .listContent(ResourceTypeEnum.BOOK.getCode(),
booklable.getLabelId(), vo.getLabelContentId()); booklable.getLabelId(), vo.getLabelContentId());
......
...@@ -31,7 +31,7 @@ import com.zrqx.core.form.resource.bg.pdflibrary.BatchUpdatePdfLibraryForm; ...@@ -31,7 +31,7 @@ import com.zrqx.core.form.resource.bg.pdflibrary.BatchUpdatePdfLibraryForm;
import com.zrqx.core.form.resource.bg.pdflibrary.QueryPdfLibraryForm; import com.zrqx.core.form.resource.bg.pdflibrary.QueryPdfLibraryForm;
import com.zrqx.core.form.resource.bg.pdflibrary.SavePdfLibraryForm; import com.zrqx.core.form.resource.bg.pdflibrary.SavePdfLibraryForm;
import com.zrqx.core.form.resource.bg.pdflibrary.SaveUpdatePdfLibraryForm; import com.zrqx.core.form.resource.bg.pdflibrary.SaveUpdatePdfLibraryForm;
import com.zrqx.core.model.resource.ebook.BookLabel; import com.zrqx.core.model.resource.ebook.BookLibraryLabel;
import com.zrqx.core.model.resource.pdflibrary.PdfGoods; import com.zrqx.core.model.resource.pdflibrary.PdfGoods;
import com.zrqx.core.model.resource.pdflibrary.PdfLibrary; import com.zrqx.core.model.resource.pdflibrary.PdfLibrary;
import com.zrqx.core.model.resource.pdflibrary.PdfLibraryDiyType; import com.zrqx.core.model.resource.pdflibrary.PdfLibraryDiyType;
......
...@@ -60,7 +60,7 @@ import com.zrqx.core.model.resource.ebook.BookDiyType; ...@@ -60,7 +60,7 @@ import com.zrqx.core.model.resource.ebook.BookDiyType;
import com.zrqx.core.model.resource.ebook.BookGoods; import com.zrqx.core.model.resource.ebook.BookGoods;
import com.zrqx.core.model.resource.ebook.BookGoodsAlbum; import com.zrqx.core.model.resource.ebook.BookGoodsAlbum;
import com.zrqx.core.model.resource.ebook.BookIssued; import com.zrqx.core.model.resource.ebook.BookIssued;
import com.zrqx.core.model.resource.ebook.BookLabel; import com.zrqx.core.model.resource.ebook.BookLibraryLabel;
import com.zrqx.core.model.resource.ebook.Ebook; import com.zrqx.core.model.resource.ebook.Ebook;
import com.zrqx.core.model.resource.imagelibrary.ImageGoods; import com.zrqx.core.model.resource.imagelibrary.ImageGoods;
import com.zrqx.core.model.resource.imagelibrary.ImageLibrary; import com.zrqx.core.model.resource.imagelibrary.ImageLibrary;
......
package com.zrqx.resource.bg.mapper.ebook; package com.zrqx.resource.bg.mapper.ebook;
import com.zrqx.core.mapper.BaseMapper; import com.zrqx.core.mapper.BaseMapper;
import com.zrqx.core.model.resource.ebook.BookLabel; import com.zrqx.core.model.resource.ebook.BookLibraryLabel;
/** /**
* 作者和标签关系 * 作者和标签关系
*/ */
public interface BookLabelMapper extends BaseMapper<BookLabel> { public interface BookLabelMapper extends BaseMapper<BookLibraryLabel> {
} }
...@@ -49,7 +49,7 @@ public interface LabelContentDiyTypeMapper extends BaseMapper<LabelContentDiyTy ...@@ -49,7 +49,7 @@ public interface LabelContentDiyTypeMapper extends BaseMapper<LabelContentDiyTy
*/ */
@Select("<script>" @Select("<script>"
+ "select distinct a.id, a.labelId, a.labelContent, a.parentId, a.englishName, a.sort, a.code, a.createTime, a.oldCode " + "select distinct a.id, a.labelId, a.labelContent, a.parentId, a.englishName, a.sort, a.code, a.createTime, a.oldCode "
+ "from res_label_content_diy_type a LEFT JOIN res_${name}_label ia on a.labelId=ia.labelId " + "from res_label_content_diy_type a LEFT JOIN res_${name}_library_label ia on a.labelId=ia.labelId "
+ "where a.id in " + "where a.id in "
+ " <foreach collection=\"ids\" index=\"index\" item=\"id\" open=\"(\" separator=\",\" close=\")\">" + " <foreach collection=\"ids\" index=\"index\" item=\"id\" open=\"(\" separator=\",\" close=\")\">"
+ "#{id}" + "#{id}"
......
...@@ -4,19 +4,19 @@ import org.springframework.beans.factory.annotation.Autowired; ...@@ -4,19 +4,19 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import com.zrqx.core.mapper.BaseMapper; import com.zrqx.core.mapper.BaseMapper;
import com.zrqx.core.model.resource.ebook.BookLabel; import com.zrqx.core.model.resource.ebook.BookLibraryLabel;
import com.zrqx.core.service.BaseServiceImpl; import com.zrqx.core.service.BaseServiceImpl;
import com.zrqx.resource.bg.mapper.ebook.BookLabelMapper; import com.zrqx.resource.bg.mapper.ebook.BookLabelMapper;
/** /**
* 文章库和自定义分类 * 文章库和自定义分类
*/ */
@Service @Service
public class BookLabelContentDiyTypeSerivceImpl extends BaseServiceImpl<BookLabel,Integer> implements BookLabelContentDiyTypeService { public class BookLabelContentDiyTypeSerivceImpl extends BaseServiceImpl<BookLibraryLabel,Integer> implements BookLabelContentDiyTypeService {
@Autowired @Autowired
private BookLabelMapper mapper; private BookLabelMapper mapper;
@Override @Override
public BaseMapper<BookLabel> getMapper() { public BaseMapper<BookLibraryLabel> getMapper() {
return mapper; return mapper;
} }
......
package com.zrqx.resource.bg.service.ebook; package com.zrqx.resource.bg.service.ebook;
import com.zrqx.core.model.resource.ebook.BookLabel; import com.zrqx.core.model.resource.ebook.BookLibraryLabel;
import com.zrqx.core.service.BaseService; import com.zrqx.core.service.BaseService;
/** /**
* 文章库和标签 * 文章库和标签
*/ */
public interface BookLabelContentDiyTypeService extends BaseService<BookLabel,Integer>{ public interface BookLabelContentDiyTypeService extends BaseService<BookLibraryLabel,Integer>{
} }
...@@ -31,7 +31,7 @@ import com.zrqx.core.model.resource.ebook.BookDiyType; ...@@ -31,7 +31,7 @@ import com.zrqx.core.model.resource.ebook.BookDiyType;
import com.zrqx.core.model.resource.ebook.BookGoods; import com.zrqx.core.model.resource.ebook.BookGoods;
import com.zrqx.core.model.resource.ebook.BookGoodsAlbum; import com.zrqx.core.model.resource.ebook.BookGoodsAlbum;
import com.zrqx.core.model.resource.ebook.BookIssued; import com.zrqx.core.model.resource.ebook.BookIssued;
import com.zrqx.core.model.resource.ebook.BookLabel; import com.zrqx.core.model.resource.ebook.BookLibraryLabel;
import com.zrqx.core.model.resource.ebook.Ebook; import com.zrqx.core.model.resource.ebook.Ebook;
import com.zrqx.core.model.resource.pdflibrary.PdfLibrary; import com.zrqx.core.model.resource.pdflibrary.PdfLibrary;
import com.zrqx.core.model.resource.videolibrary.VideoLibrary; import com.zrqx.core.model.resource.videolibrary.VideoLibrary;
...@@ -379,14 +379,14 @@ public class EbookServiceImpl extends BaseServiceImpl<Ebook, String> implements ...@@ -379,14 +379,14 @@ public class EbookServiceImpl extends BaseServiceImpl<Ebook, String> implements
} }
ebookDiyTypeMapper.insertUuidList(dtList); ebookDiyTypeMapper.insertUuidList(dtList);
// 删除原有标签关系表中的关系 // 删除原有标签关系表中的关系
BookLabel ebldt = new BookLabel(); BookLibraryLabel ebldt = new BookLibraryLabel();
ebldt.setObjectId(book.getId()); ebldt.setObjectId(book.getId());
ebookLabelDiyTypeMapper.delete(ebldt); ebookLabelDiyTypeMapper.delete(ebldt);
// 添加与标签的关系 // 添加与标签的关系
List<BookLabel> ldtList = new ArrayList<BookLabel>(); List<BookLibraryLabel> ldtList = new ArrayList<BookLibraryLabel>();
if (form.getLabelId()!=null && form.getLabelId().size() > 0) { if (form.getLabelId()!=null && form.getLabelId().size() > 0) {
for (int i = 0; i < form.getLabelId().size(); i++) { for (int i = 0; i < form.getLabelId().size(); i++) {
BookLabel ldt = new BookLabel(); BookLibraryLabel ldt = new BookLibraryLabel();
ldt.setId(UUIDUtil.getUUID()); ldt.setId(UUIDUtil.getUUID());
ldt.setObjectId(book.getId()); ldt.setObjectId(book.getId());
ldt.setLabelContentId(form.getLabelContentId().get(i)); ldt.setLabelContentId(form.getLabelContentId().get(i));
......
...@@ -53,7 +53,7 @@ import com.zrqx.core.model.resource.ebook.Book; ...@@ -53,7 +53,7 @@ import com.zrqx.core.model.resource.ebook.Book;
import com.zrqx.core.model.resource.ebook.BookDiyType; import com.zrqx.core.model.resource.ebook.BookDiyType;
import com.zrqx.core.model.resource.ebook.BookGoods; import com.zrqx.core.model.resource.ebook.BookGoods;
import com.zrqx.core.model.resource.ebook.BookGoodsAlbum; import com.zrqx.core.model.resource.ebook.BookGoodsAlbum;
import com.zrqx.core.model.resource.ebook.BookLabel; import com.zrqx.core.model.resource.ebook.BookLibraryLabel;
import com.zrqx.core.model.resource.ebook.BookResource; import com.zrqx.core.model.resource.ebook.BookResource;
import com.zrqx.core.model.resource.ebook.Ebook; import com.zrqx.core.model.resource.ebook.Ebook;
import com.zrqx.core.model.resource.imagelibrary.ImageGoods; import com.zrqx.core.model.resource.imagelibrary.ImageGoods;
...@@ -1106,7 +1106,7 @@ public class RecycleBinSerivceImpl extends BaseServiceImpl<RecycleBin,Integer> i ...@@ -1106,7 +1106,7 @@ public class RecycleBinSerivceImpl extends BaseServiceImpl<RecycleBin,Integer> i
goods.setObjectId(bin.getObjectId()); goods.setObjectId(bin.getObjectId());
bookGoodsMapper.delete(goods); bookGoodsMapper.delete(goods);
//标签 //标签
BookLabel lable=new BookLabel(); BookLibraryLabel lable=new BookLibraryLabel();
lable.setObjectId(bin.getObjectId()); lable.setObjectId(bin.getObjectId());
bookLabelContentDiyTypeMapper.delete(lable); bookLabelContentDiyTypeMapper.delete(lable);
//分类 //分类
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论