generated from ita-social-projects/DevTemplate
-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Develop #537
Merged
Develop #537
Changes from 17 commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
9d4740c
Fix catalog displaying image
AndriiS1 ad358c2
fixed streetcode deleting
MariaPadalka c774269
changed Unit tests due to changes
MariaPadalka e519bd2
deleted line
MariaPadalka 36e09bd
fixed codesmells
MariaPadalka 2e58601
-
MariaPadalka 4f4e4f0
Merge pull request #498 from ita-social-projects/fix-streetcodeDelete
MariaPadalka 10e9b5a
changed controller HttpMethod
Tysyatsky dfb6e5d
added new DTO for post method
Tysyatsky 9ec167a
Merge pull request #495 from ita-social-projects/fix-catalogue-backgr…
AndriiS1 ddb2406
rename
Tysyatsky 986b122
update rename
Tysyatsky 4678076
Merge pull request #516 from ita-social-projects/478-admintext-and-vi…
MementoMorj ff4ccb9
fix response tags order
AndriiS1 61645b5
Merge pull request #529 from ita-social-projects/fix-streetcode-text-…
MementoMorj beae4b3
fix text load
maximu211 afe9f59
Merge pull request #534 from ita-social-projects/Fix/text-loading
MementoMorj f49fb22
remove comment
Tysyatsky File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
10 changes: 10 additions & 0 deletions
10
Streetcode/Streetcode.BLL/DTO/Streetcode/Catalog/CatalogItem.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
namespace Streetcode.BLL.DTO.Streetcode.CatalogItem; | ||
|
||
public class CatalogItem | ||
{ | ||
public int Id { get; set; } | ||
public string Title { get; set; } | ||
public string Url { get; set; } | ||
public string? Alias { get; set; } | ||
public int ImageId { get; set; } | ||
} |
7 changes: 7 additions & 0 deletions
7
Streetcode/Streetcode.BLL/DTO/Streetcode/TextContent/Text/TextPreviewDTO.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
namespace Streetcode.BLL.DTO.Streetcode.TextContent.Text | ||
{ | ||
public class TextPreviewDTO | ||
{ | ||
public string TextContent { get; set; } | ||
} | ||
} |
26 changes: 26 additions & 0 deletions
26
Streetcode/Streetcode.BLL/Mapping/Streetcode/Catalog/CatalogItemProfile.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
using AutoMapper; | ||
using Streetcode.BLL.DTO.Streetcode.CatalogItem; | ||
using Streetcode.DAL.Entities.Streetcode.Types; | ||
using Streetcode.DAL.Entities.Streetcode; | ||
using Streetcode.BLL.DTO.Streetcode.RelatedFigure; | ||
using Streetcode.DAL.Enums; | ||
|
||
namespace Streetcode.BLL.Mapping.Streetcode.Catalog; | ||
|
||
public class CatalogItemProfile : Profile | ||
{ | ||
public CatalogItemProfile() | ||
{ | ||
CreateMap<EventStreetcode, CatalogItem>() | ||
.IncludeBase<StreetcodeContent, CatalogItem>(); | ||
|
||
CreateMap<PersonStreetcode, CatalogItem>() | ||
.IncludeBase<StreetcodeContent, CatalogItem>(); | ||
|
||
CreateMap<StreetcodeContent, CatalogItem>() | ||
.ForPath(dto => dto.Url, conf => conf | ||
.MapFrom(e => e.TransliterationUrl)) | ||
.ForPath(dto => dto.ImageId, conf => conf | ||
.MapFrom(e => e.Images.Select(i => i.Id).FirstOrDefault())); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
...reetcode.BLL/MediatR/Streetcode/Streetcode/GetAllCatalog/GetAllStreetcodesCatalogQuery.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,9 @@ | ||
using FluentResults; | ||
using MediatR; | ||
using Streetcode.BLL.DTO.Streetcode.CatalogItem; | ||
using Streetcode.BLL.DTO.Streetcode.RelatedFigure; | ||
|
||
namespace Streetcode.BLL.MediatR.Streetcode.Streetcode.GetAllCatalog | ||
{ | ||
public record GetAllStreetcodesCatalogQuery(int page, int count) : IRequest<Result<IEnumerable<RelatedFigureDTO>>>; | ||
public record GetAllStreetcodesCatalogQuery(int page, int count) : IRequest<Result<IEnumerable<CatalogItem>>>; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
delete comment, it's unnecessary here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed