Skip to content

Search by catalog number in user's collection. #1100

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

Conversation

mukeshk
Copy link
Contributor

@mukeshk mukeshk commented Jul 24, 2019

Addressed to #1098

@mukeshk mukeshk requested a review from php-coder as a code owner July 24, 2019 09:39
@mystamps-bot
Copy link

mystamps-bot commented Jul 24, 2019

1 Warning
⚠️ danger check: pull request description doesn’t contain a link to original issue.
Consider adding a comment in the following format: Addressed to #XXX where XXX is an issue number

Generated by 🚫 Danger

@mukeshk
Copy link
Contributor Author

mukeshk commented Jul 24, 2019 via email

@mukeshk mukeshk force-pushed the gh1098_search_by_catalog_in_user_collection branch from d8632fa to 81df430 Compare July 24, 2019 09:58
@mukeshk
Copy link
Contributor Author

mukeshk commented Jul 24, 2019

@php-coder
Copy link
Owner

There is no default value, I think I can remove the default value.
As the nature of checkbox, they are sent as request param only when checked.

This is attribute of the @RequestParam annotation and it doesn't relate to checkbox at all. It's about parameter that is present in a request or it isn't. In case there is no parameter with such name, the default value is used. So, this is what we need in our case.

@php-coder
Copy link
Owner

https://github.com/php-coder/mystamps/wiki/checkstyle - I missed it.

Better later than never. But anyway, our bot won't let this to pass forward :)

@mukeshk
Copy link
Contributor Author

mukeshk commented Jul 24, 2019 via email

@mukeshk mukeshk force-pushed the gh1098_search_by_catalog_in_user_collection branch 2 times, most recently from c375201 to f8b1081 Compare July 24, 2019 10:29
@mukeshk
Copy link
Contributor Author

mukeshk commented Jul 24, 2019

please review.

@mukeshk mukeshk force-pushed the gh1098_search_by_catalog_in_user_collection branch 3 times, most recently from e5c6d4e to 41ef557 Compare July 24, 2019 11:22
@php-coder
Copy link
Owner

Could you, please, edit the first line of the commit message to be:

task(/series/search/by_catalog): implement the simplest search by catalog number in user's collection.

@mukeshk mukeshk force-pushed the gh1098_search_by_catalog_in_user_collection branch from 41ef557 to a928a87 Compare July 24, 2019 11:24
@mukeshk
Copy link
Contributor Author

mukeshk commented Jul 24, 2019

Some import series test cases are broken at the moment.
Not sure if it's due to this pull.

@php-coder
Copy link
Owner

Some import series test cases are broken at the moment.

No, it's the test cases. It's from PMD (see also https://github.com/php-coder/mystamps/wiki/pmd-cpd):

[INFO] PMD Failure: ru.mystamps.web.feature.series.SeriesController:474 Rule:AvoidPrefixingMethodParameters Priority:4 Avoid prefixing parameters by in, out or inOut. Uses Javadoc to document this behavior..

But don't worry about it -- I'll disable this check from PMD today.

@mukeshk mukeshk force-pushed the gh1098_search_by_catalog_in_user_collection branch from a928a87 to 04e9319 Compare July 24, 2019 12:37
@mukeshk mukeshk force-pushed the gh1098_search_by_catalog_in_user_collection branch from 04e9319 to c888094 Compare July 24, 2019 12:53
@mukeshk
Copy link
Contributor Author

mukeshk commented Jul 24, 2019

Added tab on the line. 479.

Copy link
Owner

@php-coder php-coder left a comment

Choose a reason for hiding this comment

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

LGTM. I'll review it and merge tonight.

Thank you!

@@ -504,6 +507,18 @@ public String searchSeriesByCatalog(
series = Collections.emptyList();
break;
}

if (Features.SEARCH_IN_COLLECTION.isActive()
Copy link
Owner

Choose a reason for hiding this comment

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

P.S. Could you add a comment before this `if``:

// @todo #1100 Optimize a search within user's collection

Copy link
Owner

Choose a reason for hiding this comment

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

Correction, there was a wrong number:

// @todo #1098 Optimize a search within user's collection

Copy link
Owner

Choose a reason for hiding this comment

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

I've added it in 742b7d8 commit.

@php-coder php-coder merged commit bee2754 into php-coder:master Jul 24, 2019
@php-coder
Copy link
Owner

Thank you @mukeshk !

@mukeshk mukeshk deleted the gh1098_search_by_catalog_in_user_collection branch July 25, 2019 05:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants