File tree Expand file tree Collapse file tree 3 files changed +17
-8
lines changed
Expand file tree Collapse file tree 3 files changed +17
-8
lines changed Original file line number Diff line number Diff line change 6060 "svgo" : " 1.3.0" ,
6161 "vue" : " 2.6.12" ,
6262 "vue-i18n" : " 8.22.1" ,
63- "vue-luban-menu" : " file:vue-luban-menu-1.3.2.tgz " ,
63+ "vue-luban-menu" : " ^1.4.0 " ,
6464 "vue-router" : " 3.4.8" ,
6565 "vuedraggable" : " 2.24.3" ,
6666 "vuescroll" : " 4.16.1" ,
Original file line number Diff line number Diff line change @@ -347,18 +347,26 @@ export default {
347347 getWorkspaceFavorites () {
348348 if (this .$route .query .workspaceId ) {
349349 GetFavorites (this .$route .query .workspaceId ).then ((data ) => {
350- this .favorites = data .favorites || [];
350+ this .favorites = (data .favorites || []).map (item => {
351+ return {
352+ ... item,
353+ id: item .menuApplicationId
354+ }
355+ });
351356 });
352357 }
353358 },
354359 getWorkspaceCollections () {
355360 if (this .$route .query .workspaceId ) {
356361 GetCollections (this .$route .query .workspaceId ).then (data => {
357362 let collections = data .favorites || [];
358- collections .forEach (item => {
359- item[' collectedId' ] = item .menuApplicationId
363+ this .collections = collections .map (item => {
364+ return {
365+ ... item,
366+ id: item .menuApplicationId ,
367+ collectedId: item .menuApplicationId
368+ }
360369 })
361- this .collections = collections || [];
362370 })
363371 }
364372 },
@@ -369,7 +377,7 @@ export default {
369377 }).then ((data ) => {
370378 this .favorites = this .favorites .concat ({
371379 ... app,
372- id: data . favoriteId ,
380+ id: app . id ,
373381 menuApplicationId: app .id ,
374382 });
375383 });
You can’t perform that action at this time.
0 commit comments