-
Notifications
You must be signed in to change notification settings - Fork 34
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
Search by catalog number in user's collection. #1100
Conversation
Generated by 🚫 Danger |
src/main/java/ru/mystamps/web/feature/series/SeriesController.java
Outdated
Show resolved
Hide resolved
src/main/java/ru/mystamps/web/feature/series/SeriesController.java
Outdated
Show resolved
Hide resolved
src/main/java/ru/mystamps/web/feature/series/SeriesController.java
Outdated
Show resolved
Hide resolved
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.
…On Wed, Jul 24, 2019 at 3:23 PM Slava Semushin ***@***.***> wrote:
***@***.**** commented on this pull request.
------------------------------
In src/main/java/ru/mystamps/web/feature/series/SeriesController.java
<#1100 (comment)>:
> @@ -504,6 +507,17 @@ public String searchSeriesByCatalog(
series = Collections.emptyList();
break;
}
+
+ boolean searchInCollection =(inCollection != null)?Boolean.TRUE:Boolean.FALSE;
I think that we won't need this, if defaultValue = "false" will work.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#1100?email_source=notifications&email_token=AAJPE6C5Y2EAPIOUNZD2F73QBARAJA5CNFSM4IGOERJKYY3PNVWWK3TUL52HS4DFWFIHK3DMKJSXC5LFON2FEZLWNFSXPKTDN5WW2ZLOORPWSZGOB7MX4BI#pullrequestreview-265911813>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAJPE6CSS2GEL27SDSUIXZ3QBARAJANCNFSM4IGOERJA>
.
|
d8632fa
to
81df430
Compare
This is attribute of the |
Better later than never. But anyway, our bot won't let this to pass forward :) |
Aha ! ok - I did a null check. I think your approach is better. Let me try.
…On Wed, Jul 24, 2019 at 3:31 PM Slava Semushin ***@***.***> wrote:
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.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#1100?email_source=notifications&email_token=AAJPE6DXMZWZGKYSIPVBOQTQBASBHA5CNFSM4IGOERJKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD2V24BA#issuecomment-514567684>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAJPE6DXNEFTPVV5FJQXVZLQBASBHANCNFSM4IGOERJA>
.
|
c375201
to
f8b1081
Compare
please review. |
src/main/java/ru/mystamps/web/feature/series/SeriesController.java
Outdated
Show resolved
Hide resolved
src/main/java/ru/mystamps/web/feature/series/SeriesController.java
Outdated
Show resolved
Hide resolved
src/main/java/ru/mystamps/web/feature/series/SeriesController.java
Outdated
Show resolved
Hide resolved
src/main/java/ru/mystamps/web/feature/series/SeriesController.java
Outdated
Show resolved
Hide resolved
e5c6d4e
to
41ef557
Compare
Could you, please, edit the first line of the commit message to be:
|
41ef557
to
a928a87
Compare
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):
But don't worry about it -- I'll disable this check from PMD today. |
a928a87
to
04e9319
Compare
…alog number in user's collection. Part of php-coder#673 Fix php-coder#1098
04e9319
to
c888094
Compare
Added tab on the line. 479. |
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.
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() |
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.
P.S. Could you add a comment before this `if``:
// @todo #1100 Optimize a search within user's collection
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.
Correction, there was a wrong number:
// @todo #1098 Optimize a search within user's collection
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.
I've added it in 742b7d8 commit.
Thank you @mukeshk ! |
Addressed to #1098