LIMS-1683: Show buttons for next/previous container on plate view#1069
LIMS-1683: Show buttons for next/previous container on plate view#1069ndg63276 wants to merge 2 commits into
Conversation
| await result.fetch(); | ||
| } | ||
|
|
||
| result = new Containers(null, { state: { pageSize: 9999 } }); |
There was a problem hiding this comment.
Nitpick, but could result be initialised like
let result = new Containers(null, { state: { pageSize: 9999 } });?
| &.danger { | ||
| @apply tw-bg-red-500 tw-text-white; | ||
| &:hover, &:focus { | ||
| @apply tw-bg-red-700 |
There was a problem hiding this comment.
| @apply tw-bg-red-700 | |
| @apply tw-bg-red-700; |
| let foundCurrent = false; | ||
| this.siblingContainers.each((container, index) => { | ||
| let idx = index+1 | ||
| if (foundCurrent && !this.nextContainer) { |
There was a problem hiding this comment.
Should this come after foundCurrent is set? (line 779)
As it currently is, it might just not reflect the actual condition because it is evaluated before the containerId check is executed
There was a problem hiding this comment.
No, this is deliberate. You are looping through all the containers (in order), so you need to have already found the currently-displayed one, (and not yet set the 'next' one), in order to set this container as the 'next' one.
There was a problem hiding this comment.
Yeah, that makes sense, I'll approve it now, thanks for having a look!
JIRA ticket: LIMS-1683
Summary:
#912 added buttons to move to the next/previous container in the puck view, this PR is to add the same buttons to the plate views.
Changes:
updateContainerSampleGroupsDataand related functionsfetchDewarsandfetchContainersand related variablecontainersCollection.To test: