Skip to content
This repository has been archived by the owner on Apr 10, 2023. It is now read-only.

Grid does not bind all of the form fields #29

Closed
knjk04 opened this issue May 16, 2020 · 2 comments
Closed

Grid does not bind all of the form fields #29

knjk04 opened this issue May 16, 2020 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@knjk04
Copy link
Member

knjk04 commented May 16, 2020

Describe the bug

The book form no longer populates all (but the shelf) field when a grid item is selected. Only the title and the author's first name is bound (see screenshot)

To Reproduce
Steps to reproduce the behaviour:

  1. Choose a shelf
  2. Select a grid item
  3. See error

Expected behaviour

The form should get populated with all of the fields as in the grid (apart from the shelf for now).

Screenshots

broken_binding

Additional context

Branch: ui

@knjk04 knjk04 added the bug Something isn't working label May 16, 2020
@knjk04 knjk04 self-assigned this May 16, 2020
@knjk04 knjk04 changed the title Binding broken Grid does not bind all of the form fields May 16, 2020
@knjk04
Copy link
Member Author

knjk04 commented May 16, 2020

Null pointer exception if the author's last name is included.

The other fields are bound when the author's last name binding is commented out:

binder.forField(authorLastName)
        .withConverter(new StringToAuthorLastNameConverter())
        .bind(Book::getAuthor, Book::setAuthor);

More specifically, the author's last name is null (see convertToPresentation() in StringToAuthorLastNameConverter.java):

@knjk04 knjk04 removed their assignment May 27, 2020
@knjk04 knjk04 added the blocked This issue is blocked by another issue or is not yet ready to be implemented label May 27, 2020
@knjk04
Copy link
Member Author

knjk04 commented May 27, 2020

Blocked by issue #30

@knjk04 knjk04 removed the blocked This issue is blocked by another issue or is not yet ready to be implemented label Jun 12, 2020
@knjk04 knjk04 closed this as completed in 681bee7 Jun 12, 2020
@knjk04 knjk04 self-assigned this Jun 12, 2020
kaansonmezoz pushed a commit to kaansonmezoz/book-project that referenced this issue Aug 2, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant