-
Notifications
You must be signed in to change notification settings - Fork 943
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
Refactor transaction handling #1004
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Gnito
force-pushed
the
refactor-transaction-ui
branch
5 times, most recently
from
January 22, 2019 20:07
4ddff44
to
f65b9c5
Compare
Gnito
force-pushed
the
refactor-transaction-ui
branch
from
January 28, 2019 16:36
59b3344
to
c066ea1
Compare
Gnito
force-pushed
the
refactor-transaction-ui
branch
from
January 28, 2019 16:58
c066ea1
to
ad9013d
Compare
from types.js
and reduce direct state check agains current transaction.
use txHasBeenDelivered function, rename css classes, add txIsRequested check and handle unknown transition separately, filter unknown transitions when fetching data, don't render InboxItem if latest transition is unknown, update InboxPage tests.
Gnito
force-pushed
the
refactor-transaction-ui
branch
from
January 30, 2019 14:55
ad9013d
to
e25a26d
Compare
Add function for checking ownRole Use txHasReviewBy function add isCustomerReview and isProviderReview functions
(and move some generic in-file functions there).
Gnito
force-pushed
the
refactor-transaction-ui
branch
from
January 30, 2019 16:35
e25a26d
to
e6693a5
Compare
Gnito
force-pushed
the
refactor-transaction-ui
branch
from
January 31, 2019 10:55
e6693a5
to
bb5141e
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Changing a transaction process is currently quite hard. In this PR, we try to make it easier to track what needs to be checked when transaction process changes from the default one (
'preauth-with-nightly-booking/release-1'
).After this PR, there are 8 components that require file:
src/util/transaction.js
:However, it should be much easier to track all the places which are tied to transaction process. Just make search for imports from transaction.js:
from '../../util/transaction'
.Note: if you are taking an update from upstream: biggest code changes are made to
util/types.js
src/util/transaction.js
(This makes it easier to track which part of the code are tied to transaction process.)
(I.e. this process: https://www.sharetribe.com/docs/background/transaction-engine/)
TransactionPanel
TransactionPanel
is split to subcomponentsTransactionPanel.helpers.js
is removedInboxPage
(i.e. if transition process is changed from default, TRANSITIONS list should be updated.)
ActivityFeed
txIsCompleted
->txIsDelivered
txIsDeclinedOrExpired
->txIsDeclined
(both transitions lead to declined state)txIsExpired
(This is not used and there is no "expired" state in default process.)