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

Commit

Permalink
chore: rearrange data and methods by usage
Browse files Browse the repository at this point in the history
  • Loading branch information
lemredd committed Nov 13, 2022
1 parent 72477b3 commit 1244ce7
Showing 1 changed file with 13 additions and 7 deletions.
20 changes: 13 additions & 7 deletions components/consultation/chat_window/extra_controls.vue
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,16 @@
</a>
<a
v-if="!isConsultationFinishedOrCancelled"
href="#"
class="additional-control show-action-taken-overlay-btn"
@click="showActionTakenOverlay">
{{ finishOrCancel }} consultation
</a>
<a
v-if="!isCurrentUserConsultant"
class="additional-control show-rescheduling-overlay-btn"
@click="showActionTakenOverlay">
{{ finishOrCancel }} consultation
</a>
</div>
</template>
</Dropdown>
Expand Down Expand Up @@ -71,17 +76,18 @@ const modelValue = computed({
}
})
const linkToPrintableForm = specializePath(CONSULTATION_FORM_PRINT, {
"id": props.consultationId
})
function toggleHeaderControlDropdownShown() {
emit("toggleHeaderControlDropdownShown")
}
const { isCurrentUserConsultant } = props
const finishOrCancel = isCurrentUserConsultant ? "Finish" : "Cancel"
function showActionTakenOverlay() {
toggleHeaderControlDropdownShown()
emit("showActionTakenOverlay")
}
const { isCurrentUserConsultant } = props
const finishOrCancel = isCurrentUserConsultant ? "Finish" : "Cancel"
const linkToPrintableForm = specializePath(CONSULTATION_FORM_PRINT, {
"id": props.consultationId
})
</script>

0 comments on commit 1244ce7

Please sign in to comment.