修复回收站和全部书签查看
This commit is contained in:
		| @@ -9,7 +9,7 @@ ruoyi: | ||||
|   # 实例演示开关 | ||||
|   demoEnabled: true | ||||
|   # 文件路径 示例( Windows配置D:/ruoyi/uploadPath,Linux配置 /home/ruoyi/uploadPath) | ||||
|   profile: D:/ruoyi/uploadPath | ||||
|   profile: /home/ruoyi/uploadPath | ||||
|   # 获取ip地址开关 | ||||
|   addressEnabled: false | ||||
|   # 验证码类型 math 数组计算 char 字符验证 | ||||
|   | ||||
| @@ -1,20 +1,26 @@ | ||||
| <template> | ||||
|   <div> | ||||
|  | ||||
|  | ||||
|     <div v-for="bm in bookmarkList" class="bookmark"   @click="winurl(bm.noteId,bm.tiymceUeditor,bm.bookmarkId,bm.url)"> | ||||
| <!--    STYLE="position: relative"--> | ||||
|     <div v-for="bm in bookmarkList"  class="bookmark"   @click="winurl(bm.noteId,bm.tiymceUeditor,bm.bookmarkId,bm.url)"> | ||||
|       <div class="bookmark-item"> | ||||
|          <span class="bookmark-title" v-if="highlighted" v-html="highLight(bm.title,sousuo)"/> | ||||
|  | ||||
|         <span class="bookmark-title" v-if="!highlighted">{{bm.title}}</span> | ||||
|         <div class="bookmark-time" v-if="noteTime">{{bm.createTime|changeTime}}</div> | ||||
|       </div> | ||||
|       <div class="bookmark-description" v-if="isdescription"> | ||||
|  | ||||
|  | ||||
|  | ||||
|       <div class="bookmark-description" v-if="isdescription" > | ||||
|  | ||||
|         <span v-if="highlighted" v-html="highLight(bm.description,sousuo)"></span> | ||||
|  | ||||
|         <span v-if="!highlighted">{{bm.description}}</span> | ||||
|       </div> | ||||
|  | ||||
|  | ||||
|  | ||||
|       <div class="info-wrap" v-if="isBookmarkIcon"> | ||||
|         <div class="info"> | ||||
|           <div class="bookmark-icon"> | ||||
| @@ -33,8 +39,9 @@ | ||||
|           </div> | ||||
|         </div> | ||||
|       </div> | ||||
|  | ||||
|  | ||||
| <!--      <div style="width: 300px;height: inherit;background-color: red;position: absolute;right: 0px;top: 10px;bottom: 10px">--> | ||||
| <!--        2222222222222222222222--> | ||||
| <!--      </div>--> | ||||
|     </div> | ||||
|  | ||||
|   </div> | ||||
| @@ -239,4 +246,5 @@ | ||||
|     height: 15px; | ||||
|   } | ||||
|  | ||||
|  | ||||
| </style> | ||||
|   | ||||
| @@ -280,7 +280,7 @@ | ||||
|         </el-aside> | ||||
|  | ||||
|         <el-main class="isBookmarkMain" v-if="isMain"> | ||||
|                   <el-header class="mianUrl-top" style="height: 50px"> | ||||
|                   <el-header class="mianUrl-top" > | ||||
|                     <div class="mianUrl-top-left"> | ||||
|                       <i class="el-icon-folder-delete" @click="closeIsMain"></i> | ||||
|                       <i class="el-icon-rank" ></i> | ||||
| @@ -563,7 +563,7 @@ | ||||
|                 this.getListConcat(); | ||||
|                 break; | ||||
|               case 1: | ||||
|                 this.getNoteListConcat(); | ||||
|                 this.getListNoteConcat(); | ||||
|                 break; | ||||
|               default: | ||||
|             } | ||||
| @@ -578,12 +578,11 @@ | ||||
|         //缓存状态 | ||||
|         that.$store.state.property=e; | ||||
|         this.showimg=false; | ||||
|         // console.log("缓存property:"+that.$store.state.property) | ||||
|         // console.log("缓存property:"+store.state.property) | ||||
|         //初始化 | ||||
|         this.queryParams.pageNum=1; | ||||
|         this.noteParams.pageNum=1; | ||||
|         this.bookmarkList=[]; | ||||
|  | ||||
|         this.getBypropertyList(e); | ||||
|  | ||||
|       }, | ||||
| @@ -752,15 +751,17 @@ | ||||
|       getrecycleList() { | ||||
|         this.loading = true; | ||||
|         selectBydelete(this.queryParams).then(response => { | ||||
|           if (response.total != 0 && response.code == 200) { | ||||
|             this.bookmarkList = response.rows; | ||||
|           if (response.total != 0 &&response.code == 200) { | ||||
|             this.bookmarkList = this.bookmarkList.concat(response.rows); | ||||
|             this.total = response.total; | ||||
|             this.listloading = false | ||||
|             this.loading = false; | ||||
|             this.listloading = false | ||||
|             console.log("请求完毕" + that.queryParams.pageNum) | ||||
|           } else { | ||||
|             this.showbookmark = false; | ||||
|             this.showimg = true; | ||||
|             //出错了加载完毕了 禁止滚动 | ||||
|             this.noMore = true; | ||||
|             this.listloading = false | ||||
|             this.loading = false; | ||||
|           } | ||||
|         }); | ||||
|       }, | ||||
| @@ -768,26 +769,28 @@ | ||||
|       getBookmarkList() { | ||||
|         this.loading = true; | ||||
|         selectByUseridList(this.queryParams).then(response => { | ||||
|           if (response.total != 0 && response.code == 200) { | ||||
|             this.bookmarkList = response.rows; | ||||
|             this.total = response.total; | ||||
|             this.loading = false; | ||||
|             this.listloading = false | ||||
|           } else { | ||||
|             this.showbookmark = false; | ||||
|             this.showimg = true; | ||||
|             this.listloading = false | ||||
|           } | ||||
|             if (response.total != 0 &&response.code == 200) { | ||||
|               this.bookmarkList = this.bookmarkList.concat(response.rows); | ||||
|               this.total = response.total; | ||||
|               this.listloading = false | ||||
|               this.loading = false; | ||||
|               console.log("请求完毕" + that.queryParams.pageNum) | ||||
|             } else { | ||||
|               //出错了加载完毕了 禁止滚动 | ||||
|               this.noMore = true; | ||||
|               this.listloading = false | ||||
|               this.loading = false; | ||||
|             } | ||||
|         }); | ||||
|       }, | ||||
|       /**根据条件查询*/ | ||||
|       getBypropertyList(e){ | ||||
|         switch(e) { | ||||
|           case 0: | ||||
|             this.getList(); | ||||
|             this.getListConcat(); | ||||
|             break; | ||||
|           case 1: | ||||
|             this.getNoteList(); | ||||
|             this.getListNoteConcat(); | ||||
|             break; | ||||
|           default: | ||||
|             this.loading = true; | ||||
| @@ -818,8 +821,6 @@ | ||||
|             this.getNoteList(); | ||||
|           } | ||||
|         }); | ||||
|  | ||||
|  | ||||
|       }, | ||||
|  | ||||
|       /** 查询书签管理列表 */ | ||||
| @@ -845,16 +846,36 @@ | ||||
|         this.loading = true; | ||||
|         if(this.queryParams.menuId=='BOOKMARK'){ | ||||
|           //全部书签 | ||||
|            this.getBookmarkList(); | ||||
|           return; | ||||
|         }else if (routedata == 'RECYCLE') { | ||||
|           //回收站 | ||||
|           this.getBookmarkList(); | ||||
|         }else if (this.queryParams.menuId == 'RECYCLE') { | ||||
|           //回收站书签 | ||||
|           this.getrecycleList(); | ||||
|  | ||||
|         }else{ | ||||
|  | ||||
|           //查看目录下的书签 | ||||
|           this.getlistByMenuId(); | ||||
|         } | ||||
|       }, | ||||
|       /**查询便签 滚动加载分页拼接*/ | ||||
|       getListNoteConcat(){ | ||||
|         var that=this; | ||||
|         this.loading = true; | ||||
|         if(this.queryParams.menuId=='BOOKMARK'){ | ||||
|           //全部便签 | ||||
|           this.loading = false; | ||||
|           this.showimg = true; | ||||
|         }else if (this.queryParams.menuId == 'RECYCLE') { | ||||
|           //回收站便签 | ||||
|           this.loading = false; | ||||
|           this.showimg = true; | ||||
|         }else{ | ||||
|           //查看目录下的便签 | ||||
|           this.getNoteListConcat(); | ||||
|         } | ||||
|       }, | ||||
|       //查看目录下的书签 | ||||
|       getlistByMenuId(){ | ||||
|         selectBymenuIdUserID(this.queryParams).then(response => { | ||||
|           if (response.code == 200) { | ||||
|           if (response.total != 0 &&response.code == 200) { | ||||
|             this.bookmarkList = this.bookmarkList.concat(response.rows); | ||||
|             this.total = response.total; | ||||
|             this.listloading = false | ||||
| @@ -867,12 +888,9 @@ | ||||
|             this.loading = false; | ||||
|           } | ||||
|         }); | ||||
|         } | ||||
|  | ||||
|  | ||||
|  | ||||
|       }, | ||||
|  | ||||
|  | ||||
|       /** 查询便签管理列表 */ | ||||
|       getNoteList() { | ||||
|         this.loading = true; | ||||
| @@ -889,12 +907,11 @@ | ||||
|       getNoteListConcat(){ | ||||
|         this.loading = true; | ||||
|         selectBymenuNote(this.noteParams).then(response => { | ||||
|           if (response.code == 200) { | ||||
|           if (response.total != 0 && response.code == 200) { | ||||
|             this.bookmarkList = this.bookmarkList.concat(response.rows); | ||||
|             this.total = response.total; | ||||
|             this.loading = false; | ||||
|             this.listloading = false | ||||
|  | ||||
|           }else { | ||||
|             //出错了加载完毕了 禁止滚动 | ||||
|             this.noMore = true; | ||||
| @@ -1208,6 +1225,7 @@ | ||||
|     font-weight: 600; | ||||
|     padding: 0; | ||||
|     margin: 0; | ||||
|     padding-bottom: 50px; | ||||
|   } | ||||
|  | ||||
|   .bookmark-title:hover { | ||||
| @@ -1471,6 +1489,7 @@ | ||||
|   .mianUrl-top{ | ||||
|     display: flex; | ||||
|     padding: 0px!important; | ||||
|     height: 50px; | ||||
|   } | ||||
|   .mianUrl-top div{ | ||||
|     width: 50%; | ||||
|   | ||||
| @@ -27,14 +27,14 @@ | ||||
|               <ul id="treeDemo" class="ztree"></ul> | ||||
|             </div> | ||||
|             <div class="reminder">工具箱</div> | ||||
|             <div class="aside-title"><i class="el-icon-s-flag" style="color: red"></i><span>RSS订阅</span></div> | ||||
|             <div class="aside-title"><i class="el-icon-s-flag" style="color: #569cd5"></i><span>RSS订阅</span></div> | ||||
|             <div class="aside-title" @click="goUserTagAll"><i class="el-icon-s-management"></i><span>标签管理</span></div> | ||||
|             <div class="aside-title" @click="gorecycle"><i class="el-icon-delete-solid"></i><span>回收站</span></div> | ||||
|             <div class="aside-title" @click="gorecycle"><i class="el-icon-delete-solid" style="color: red"></i><span>垃圾桶</span></div> | ||||
|             <div class="aside-title" @click="importHtml"><i class="el-icon-s-platform"></i><span>导入书签</span></div> | ||||
|             <div class="aside-title"><i class="el-icon-s-comment"></i><span>意见反馈</span></div> | ||||
|             <div class="aside-title" @click="ceshi"><i class="el-icon-s-comment"></i><span>测试页面</span></div> | ||||
|             <div class="aside-title" @click="NqEdit"><i class="el-icon-s-comment"></i><span>NqQuillEdit编辑器</span></div> | ||||
|             <div class="aside-title " style="margin-bottom: 100px"><i class="el-icon-s-grid"></i><span>其他设置</span></div> | ||||
| <!--            <div class="aside-title" @click="ceshi"><i class="el-icon-s-comment"></i><span>测试页面</span></div>--> | ||||
| <!--            <div class="aside-title" @click="NqEdit"><i class="el-icon-s-comment"></i><span>NqQuillEdit编辑器</span></div>--> | ||||
|             <div class="aside-title " style="margin-bottom: 100px"><i class="el-icon-s-grid"></i><span>工具箱</span></div> | ||||
|  | ||||
|           </div> | ||||
|  | ||||
| @@ -1517,7 +1517,7 @@ | ||||
|     font-family: "PingFang SC"; | ||||
|     font-size: 120%; | ||||
|     font-weight: 800; | ||||
|   | ||||
|  | ||||
|   } | ||||
|  | ||||
|   .logoright i { | ||||
| @@ -1766,11 +1766,11 @@ | ||||
|  | ||||
|   /*拖拽区div样式*/ | ||||
|   .isresize { | ||||
|     /* width: 5px; */ | ||||
|      width: 5px; | ||||
|     display: -webkit-flex; | ||||
|     justify-content: center; | ||||
|     align-items: center; | ||||
|     background-color: red; | ||||
|     /*background-color: red;*/ | ||||
|     color: red; | ||||
|     z-index: 1; | ||||
|   } | ||||
|   | ||||
| @@ -79,5 +79,10 @@ public interface SqBookmarkMapper extends MyMapper<SqBookmark> | ||||
|      * @return 结果 | ||||
|      */ | ||||
|     public void updateSqBookmarkBymenuId(Long menuId); | ||||
|  | ||||
|     /** | ||||
|      * 查询用户全部书签不包含删除的书签 | ||||
|      *  @param | ||||
|      * @return 结果 | ||||
|      */ | ||||
|     public List<SqBookmark> selectByUseridList(Long userId); | ||||
| } | ||||
|   | ||||
| @@ -261,10 +261,7 @@ public class SqBookmarkServiceImpl implements ISqBookmarkService | ||||
|      */ | ||||
|     @Override | ||||
|     public List<SqBookmark> selectByUseridList(Long userId) { | ||||
|         SqBookmark sqBookmark= new SqBookmark(); | ||||
|         sqBookmark.setUserid(userId); | ||||
|         sqBookmark.setIdelete(0); //未删除的书签 | ||||
|         return sqBookmarkMapper.select(sqBookmark); | ||||
|         return sqBookmarkMapper.selectByUseridList(userId); | ||||
|     } | ||||
|  | ||||
|     /** | ||||
|   | ||||
| @@ -121,6 +121,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | ||||
|         </foreach> | ||||
|     </delete> | ||||
|  | ||||
|     <select id="selectByUseridList" parameterType="Long" resultMap="SqBookmarkResult"> | ||||
|     <include refid="selectSqBookmarkVo"/> | ||||
|     where userid = #{userId} and idelete = 0  order by  create_time desc | ||||
|     </select> | ||||
|  | ||||
|  | ||||
|  | ||||
|     <select id="selectBymenuIdUserID" parameterType="SqBookmark"  resultMap="SqBookmarkResult"> | ||||
|         <include refid="selectSqBookmarkVo"/> | ||||
|         where   userid=#{userID} | ||||
|   | ||||
		Reference in New Issue
	
	Block a user