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

Restructure sell buy viewmodels implement buy view #92

Merged
merged 3 commits into from Nov 25, 2023

Conversation

awesominat
Copy link
Owner

@awesominat awesominat commented Nov 24, 2023

restructued buy and sell presents and views because the Presenters directly took in the View instead of the ViewModel, making it uncomfortable to instantiate use case. added Buy View buttons, connected them to controller, added input sanitization

it would be nice if someone checked the other Presenters and made sure they were using "_ViewModel" rather than "_View" as the way the current Presenters are created makes it difficult to instantiate views.

specifically, if you were to pass any controller through to the View, you'd need to first create the Interactor, but you can't create the interaction without the presenter, but you can't create the presenter without the View, but you can't create the View without the controller, but you can't ...

infinite loop caused by improper set up (I originally misspelled _ViewModel and wrote _View)

related to #82

…rectly took in the View instead of the ViewModel, making it uncomfortable to instantiate use case. added Buy View buttons, connected them to controller, added input sanitization
@awesominat awesominat linked an issue Nov 24, 2023 that may be closed by this pull request
@awesominat awesominat removed a link to an issue Nov 24, 2023
Copy link
Collaborator

@quiz3 quiz3 left a comment

Choose a reason for hiding this comment

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

You made so many changes to testing for buy and sell, and also the implementation of parts of the Buy use case especially. The changes are mostly updating the implementation to reflect the fact that the way we track user information has significantly shifted (i.e. no login/signup).

You only really mentioned the changes you made to the presenter in your PR message, but this PR is so much more. You cleaned up virtually every part of the Buy use case, getting rid of unnecessary classes and imports and adding/updating methods/imports where necessary.

The change you noted in your PR is important, however, as it reflects something we should all keep an eye on. I am not sure how I implemented my Presenter(s), but I will go double check that they use view models instead of Views as attributes. Thanks for the tip!

@quiz3 quiz3 merged commit 986a824 into main Nov 25, 2023
1 check passed
@quiz3 quiz3 deleted the restructure-sell-buy-viewmodels-implement-buy-view branch November 25, 2023 04:46
rickygrosvenor-pramanick pushed a commit that referenced this pull request Nov 25, 2023
* removed usernames in the buy interactor, input data, and controller

* removed other username references in all project files

* restructued buy and sell presents and views because the Presenters directly took in the View instead of the ViewModel, making it uncomfortable to instantiate use case. added Buy View buttons, connected them to controller, added input sanitization
quiz3 added a commit that referenced this pull request Nov 25, 2023
* Created GetTransactionHistory Interface Adapters - Need to be polished

* Made Changes to the GetTransactionHistoryInteractor and OutputData

* Implemented Interface Adapters for GetTransactionHistory UseCase

* Fixed Dashboard buttons, removed QUIT, and tidied up the use case and view model.

* removed usernames in the buy interactor, input data, and controller

* removed other username references in all project files

* Restructure sell buy viewmodels implement buy view (#92)

* removed usernames in the buy interactor, input data, and controller

* removed other username references in all project files

* restructued buy and sell presents and views because the Presenters directly took in the View instead of the ViewModel, making it uncomfortable to instantiate use case. added Buy View buttons, connected them to controller, added input sanitization

* Transaction history Interactor and OutputData reimplemented. (#99)

* Created GetTransactionHistory Interface Adapters - Need to be polished

* Made Changes to the GetTransactionHistoryInteractor and OutputData

* DashboardView refresh button implemented (#97)

---------

Co-authored-by: quiz3 <113859565+quiz3@users.noreply.github.com>
Co-authored-by: Zain <zainhmoustafa@gmail.com>
Co-authored-by: awesominat <110934811+awesominat@users.noreply.github.com>
Co-authored-by: Stephen S <sjs.scott@mail.utoronto.ca>
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.

None yet

2 participants