diff options
author | Kasper Nilsson <kaspern@google.com> | 2018-09-27 12:06:50 -0700 |
---|---|---|
committer | Gert van Dijk <gertvdijk@gmail.com> | 2018-09-28 06:44:33 +0000 |
commit | ac8d234d4ed2855b8fe4767775b69fb6382c0641 (patch) | |
tree | 61f2d2981a28802ff48f794cd2df3883de91073c | |
parent | 8af72e665741634303b062a6d198db0b32aa481c (diff) |
Reload change after submit
For some submit strategies, the change should be reloaded with the
latest patch set after submission. With this change, the view is
reloaded after every submit for simplicity's sake.
Bug: Issue 9586
Change-Id: Ic194642e427c60d89713bde913f992bafe3e811d
(cherry picked from commit 10382768888cbaed57920539a3d31d0e370e0e81)
-rw-r--r-- | polygerrit-ui/app/elements/change/gr-change-view/gr-change-view.js | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/polygerrit-ui/app/elements/change/gr-change-view/gr-change-view.js b/polygerrit-ui/app/elements/change/gr-change-view/gr-change-view.js index 001f32c84d..1f050baada 100644 --- a/polygerrit-ui/app/elements/change/gr-change-view/gr-change-view.js +++ b/polygerrit-ui/app/elements/change/gr-change-view/gr-change-view.js @@ -885,9 +885,10 @@ _handleReloadChange(e) { return this._reload().then(() => { - // If the change was rebased, we need to reload the page with the - // latest patch. - if (e.detail.action === 'rebase') { + // If the change was rebased or submitted, we need to reload the page + // with the latest patch. + const action = e.detail.action; + if (action === 'rebase' || action === 'submit') { Gerrit.Nav.navigateToChange(this._change); } }); |