Compare commits
No commits in common. "a22b20aab75d9c800dc8d6b7659b245a0ae992cb" and "83abbd18f1567d58ff3e72b5bb95822cbc0f4ce6" have entirely different histories.
a22b20aab7
...
83abbd18f1
|
|
@ -176,17 +176,4 @@ public class RepoEdFileInfoController {
|
|||
String userId = UserThreadLocal.getUserId();
|
||||
return ElectromagneticResultUtil.success(edFileInfoService.addFavorite(userId, id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 从收藏夹移除
|
||||
*
|
||||
* @param id 文件id
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/removeCollection")
|
||||
@UserOperation(value = "从收藏夹移除文件", modelName = UserOperationModuleEnum.USER_PRJ)
|
||||
public ElectromagneticResult<?> removeFavorite(@RequestParam String id) {
|
||||
String userId = UserThreadLocal.getUserId();
|
||||
return ElectromagneticResultUtil.success(edFileInfoService.removeFavorite(userId, id));
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -79,11 +79,7 @@ public class EdTagLibraryServiceImpl extends ServiceImpl<EdTagLibraryMapper, EdT
|
|||
tag.setType(TagTypeEnum.TAG.getCode()); // 标签
|
||||
tag.setTagName(tagName);
|
||||
tag.setOrderBy(maxOrder + 1); // 默认排序
|
||||
|
||||
// 判断标签组有无发布,若发布,则标签已发布,若未发布,则标签未发布
|
||||
int isPublished = this.getById(parentId).getIsPublished();
|
||||
tag.setIsPublished(isPublished);
|
||||
|
||||
tag.setIsPublished(PublishEnum.UNPUBLISHED.getCode()); // 默认未发布
|
||||
tag.setCreatedBy(createdBy);
|
||||
boolean isSuccess = this.save(tag);
|
||||
if (isSuccess) {
|
||||
|
|
@ -202,8 +198,6 @@ public class EdTagLibraryServiceImpl extends ServiceImpl<EdTagLibraryMapper, EdT
|
|||
}
|
||||
// 删除本身
|
||||
boolean isDeleted = this.removeById(tagId);
|
||||
// 删除本身的关联关系
|
||||
fileTagRelationMapper.delete(new LambdaQueryWrapper<FileTagRelation>().eq(FileTagRelation::getTagId, tagId));
|
||||
if (isDeleted) {
|
||||
UserThreadLocal.setSuccessInfo("", tagId, StrFormatter.format("删除了标签 {} ", tag.getTagName()));
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue