Browse Source

Merge pull request #703 from colinin/upt-5.3.5

fix some bug
pull/708/head
yx lin 3 years ago
committed by GitHub
parent
commit
9bf41191f0
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 24
      apps/vue/src/api/platform/user-favorites-menu/index.ts
  2. 2
      aspnet-core/modules/platform/LINGYUN.Platform.Application/LINGYUN/Platform/Menus/UserFavoriteMenuAppService.cs
  3. 2
      aspnet-core/modules/platform/LINGYUN.Platform.Domain.Shared/LINGYUN/Platform/Localization/Resources/en.json
  4. 2
      aspnet-core/modules/platform/LINGYUN.Platform.Domain.Shared/LINGYUN/Platform/Localization/Resources/zh-Hans.json

24
apps/vue/src/api/platform/user-favorites-menu/index.ts

@ -18,9 +18,7 @@ export const create = (userId: string, input: UserFavoriteMenuCreateDto) => {
params: {
userId: userId,
},
data: {
input: input,
},
data: input,
});
};
@ -30,9 +28,7 @@ export const createMyFavoriteMenu = (input: UserFavoriteMenuCreateDto) => {
service: remoteService.name,
controller: remoteService.controller,
action: 'CreateMyFavoriteMenuAsync',
data: {
input: input,
},
data: input,
});
};
@ -45,9 +41,7 @@ export const del = (userId: string, menuId: string) => {
userId: userId,
},
data: {
input: {
menuId: menuId,
},
menuId: menuId,
},
});
};
@ -58,9 +52,7 @@ export const delMyFavoriteMenu = (menuId: string) => {
controller: remoteService.controller,
action: 'DeleteMyFavoriteMenuAsync',
data: {
input: {
menuId: menuId,
},
menuId: menuId,
},
});
};
@ -73,9 +65,7 @@ export const update = (userId: string, input: UserFavoriteMenuUpdateDto) => {
params: {
userId: userId,
},
data: {
input: input,
},
data: input,
});
};
@ -84,9 +74,7 @@ export const updateMyFavoriteMenu = (input: UserFavoriteMenuUpdateDto) => {
service: remoteService.name,
controller: remoteService.controller,
action: 'UpdateMyFavoriteMenuAsync',
data: {
input: input,
},
data: input,
});
};

2
aspnet-core/modules/platform/LINGYUN.Platform.Application/LINGYUN/Platform/Menus/UserFavoriteMenuAppService.cs

@ -57,7 +57,7 @@ public class UserFavoriteMenuAppService : PlatformApplicationServiceBase, IUserF
public async virtual Task<UserFavoriteMenuDto> CreateMyFavoriteMenuAsync(UserFavoriteMenuCreateDto input)
{
var userId = CurrentUser.GetId();
if (!await UserFavoriteMenuRepository.CheckExistsAsync(input.Framework, userId, input.MenuId))
if (await UserFavoriteMenuRepository.CheckExistsAsync(input.Framework, userId, input.MenuId))
{
throw new BusinessException(PlatformErrorCodes.UserDuplicateFavoriteMenu);
}

2
aspnet-core/modules/platform/LINGYUN.Platform.Domain.Shared/LINGYUN/Platform/Localization/Resources/en.json

@ -7,6 +7,8 @@
"Platform:02003": "The menu level has reached the specified maximum: {Depth}!",
"Platform:02101": "The menu metadata is missing the necessary element :{Name}, which is defined in the data dictionary :{DataName}!",
"Platform:03001": "The metadata format does not match!",
"Platform:04400": "The user favorites the menu repeatedly!",
"Platform:04404": "User Favorites menu not found!",
"UploadFileSizeBeyondLimit": "Upload file size cannot exceed {0} MB!",
"NotAllowedFileExtensionName": "Not allowed file extension: {0}!",
"DisplayName:VersionFileLimitLength": "File limit size",

2
aspnet-core/modules/platform/LINGYUN.Platform.Domain.Shared/LINGYUN/Platform/Localization/Resources/zh-Hans.json

@ -7,6 +7,8 @@
"Platform:02003": "菜单层级已达到规定最大值: {Depth}!",
"Platform:02101": "菜单元数据缺少必要的元素: {Name},此选项在数据字典:{DataName} 中定义!",
"Platform:03001": "元数据格式不匹配!",
"Platform:04400": "用户重复收藏菜单!",
"Platform:04404": "用户收藏菜单未找到!",
"UploadFileSizeBeyondLimit": "上传文件大小不能超过 {0} MB!",
"NotAllowedFileExtensionName": "不被允许的文件扩展名: {0}!",
"DisplayName:VersionFileLimitLength": "文件限制大小",

Loading…
Cancel
Save