Skip to content

Commit

Permalink
quick fix for nomination button not displaying
Browse files Browse the repository at this point in the history
  • Loading branch information
rakeden committed Nov 17, 2023
1 parent 5e5995d commit 5f574d9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
11 changes: 6 additions & 5 deletions src/components/election/BallotNomination.vue
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ const session = useSession();
const nominees = computed(() => store.state.ballot.nominees);
const candidates = computed(() => store.state.ballot.candidates);
const isActorNotACandidate = computed(
() =>
candidates.value.filter(
Expand Down Expand Up @@ -95,7 +94,7 @@ const nominate = () =>
});
onMounted(() => {
if (!nominees.value.length) store.dispatch('ballot/fetchNominees');
store.dispatch('ballot/fetchNominees');
});
</script>
<template>
Expand All @@ -107,14 +106,14 @@ onMounted(() => {
<div class="ml-4 mt-6">
<h3 class="text-xl font-semibold leading-6">Nominees</h3>
<p class="mt-3 text-sm text-gray-500">
Nominate your best IG. Once accepted, nominees become candidates and can be voted.
Nominate your best IG. Once accepted, nominees become candidates and
can be voted.
</p>
</div>
</div>
</div>
<div class="p-6">
<ul
v-if="nominees.length"

This comment has been minimized.

Copy link
@rakeden

rakeden Nov 17, 2023

Author Contributor

@AlexandreSSJr Excuse me for this bug I introduced few days ago. It led to the button "Nominate Candidate +" not being displayed. At that time I didn't think about the data lifecycle. I removed it now to display the button.

This comment has been minimized.

Copy link
@AlexandreSSJr

AlexandreSSJr Nov 17, 2023

Collaborator

No problem!

role="list"
class="grid grid-cols-1 gap-6 sm:grid-cols-2 lg:grid-cols-3"
>
Expand All @@ -123,7 +122,9 @@ onMounted(() => {
:key="nominee.nominee"
class="col-span-1 divide-y divide-primary-50 rounded-lg bg-secondary-50 drop-shadow-md"
>
<div class="flex w-full h-full items-center justify-between space-x-6 p-6">
<div
class="flex w-full h-full items-center justify-between space-x-6 p-6"
>
<div class="flex-1 truncate">
<div class="flex items-center space-x-3">
<h3 class="truncate text-sm font-medium text-font">
Expand Down
2 changes: 0 additions & 2 deletions src/components/election/BallotTimelineDetails.vue
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@ onMounted(() => {
const currentBallot = computed(() => ballot.value[0]);
console.log(currentBallot.value);
const ballotStates = [
{
state: 2,
Expand Down

0 comments on commit 5f574d9

Please sign in to comment.