Skip to content
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

Feature 87 import resource by csv #122

Merged
merged 10 commits into from
May 19, 2024
Merged

Conversation

LuboKar
Copy link
Contributor

@LuboKar LuboKar commented May 17, 2024

No description provided.

Copy link
Contributor

@VladoKat VladoKat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall looks good. Left minor comments.

pom.xml Outdated
<dependency>
<groupId>com.fasterxml.jackson.dataformat</groupId>
<artifactId>jackson-dataformat-csv</artifactId>
<version>2.17.0</version>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the version can be omitted.

return savedResources;
}

private void csvVerification(MultipartFile file) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Method names should be verbs

Suggested change
private void csvVerification(MultipartFile file) {
private void verifyIsCsv(MultipartFile file) {

CsvSchema schema = CsvSchema.emptySchema().withHeader();

MappingIterator<ResourceRequestDto> resourcesIterator;
List<ResourceRequestDto> resourcesDto;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
List<ResourceRequestDto> resourcesDto;
List<ResourceRequestDto> resourceDtos;

Copy link

sonarcloud bot commented May 19, 2024

@LuboKar LuboKar merged commit b856b73 into test May 19, 2024
3 checks passed
@LuboKar LuboKar deleted the feature-87-import-resource-by-csv branch May 19, 2024 23:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants