-
Notifications
You must be signed in to change notification settings - Fork 11
Add functionality to use check-in app for QR code scanning with eventyay #115
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
Open
Sak1012
wants to merge
23
commits into
fossasia:development
Choose a base branch
from
Sak1012:badge-integration
base: development
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 12 commits
Commits
Show all changes
23 commits
Select commit
Hold shift + click to select a range
0771e62
Add Device Registration button and route
Sak1012 077215b
Added Select Server option in LoginForm
Sak1012 4c8f4da
Added basic QR handling logic
Sak1012 57f721b
Device auth and event list selection
Sak1012 cbc8b39
Added Field to enter Device Auth Token manually
Sak1012 3405c89
Added Ticket QR scanning Page
Sak1012 4f382e0
Fixes
Sak1012 67ee3dd
Add Eventyay route Selection Page
Sak1012 b505113
Added basic auth logic for leed scanning
Sak1012 67e1679
Add Lead API and Check-in API
Sak1012 e168a42
Fix Syntax
Sak1012 d016d4c
Changed The Workflow
Sak1012 049a99e
Added Popup to show scanned lead info
Sak1012 da28507
Update .env
Sak1012 e188f12
Added additional Lead Fucntionality
Sak1012 426cf90
Changes
Sak1012 fa04c51
Updated Lead Scanning and CSV to now support Booth Info
Sak1012 1e76141
Add logout functionality to maintain session
Sak1012 42f2a92
Add Badge preview and printing option and modify Event Selection Page
Sak1012 91a9325
Env Variable fix
Sak1012 c95c222
Workflow fix
Sak1012 f3e6f71
conf fix
Sak1012 d2ff327
Add Search and Checkin
Sak1012 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
VITE_TEST_API_URL=https://test-api.eventyay.com/v1 | ||
VITE_PROD_API_URL=https://api.eventyay.com/v1 | ||
VITE_TEST_API_URL=https://app.eventyay.com/v1 | ||
VITE_PROD_API_URL=https://app.eventyay.com/v1 | ||
VITE_LOCAL_PORT=8000 |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains hidden or 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
This file contains hidden or 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<script setup> | ||
import QRCamera from '@/components/Common/QRCamera.vue' | ||
import { useLoadingStore } from '@/stores/loading' | ||
const loadingStore = useLoadingStore() | ||
loadingStore.contentLoaded() | ||
</script> | ||
|
||
<template> | ||
<div | ||
class="-mt-16 grid h-screen w-full grid-cols-1 place-items-center items-center justify-center align-middle" | ||
> | ||
<QRCamera qr-type="eventyaycheckin" scan-type="Check-In" /> | ||
</div> | ||
</template> |
This file contains hidden or 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
<script setup> | ||
import { useLoadingStore } from '@/stores/loading' | ||
import { useEventyayApi } from '@/stores/eventyayapi' | ||
import { useEventyayEventStore } from '@/stores/eventyayEvent' | ||
|
||
import { ref, onMounted, watchEffect } from 'vue' | ||
import StandardButton from '@/components/Common/StandardButton.vue' | ||
import { useRouter } from 'vue-router' | ||
|
||
const loadingStore = useLoadingStore() | ||
const router = useRouter() | ||
|
||
const selectedEvent = ref(null) | ||
const eventyayEventStore = useEventyayEventStore() | ||
const { events, error } = eventyayEventStore | ||
const processApi = useEventyayApi() | ||
const { apitoken, url, organizer, selectedRole } = processApi | ||
|
||
loadingStore.contentLoaded() | ||
eventyayEventStore.fetchEvents(url, apitoken, organizer) | ||
|
||
const submitForm = () => { | ||
if (selectedEvent.value) { | ||
const selectedEventData = events.find((event) => event.slug === selectedEvent.value) | ||
if (selectedEventData) { | ||
processApi.setEventSlug(selectedEventData.slug) | ||
if (selectedRole === 'exhibitor') router.push({ name: 'eventyayleedlogin' }) | ||
if (selectedRole === 'checkin' || selectedRole === 'badge') | ||
router.push({ name: 'eventyaycheckin' }) | ||
} | ||
} else { | ||
console.error('Please select an event.') | ||
Sak1012 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
} | ||
} | ||
</script> | ||
<template> | ||
<div class="-mt-16 flex h-screen flex-col justify-center"> | ||
<div v-if="error" class="text-danger">{{ error }}</div> | ||
<form v-if="events.length" @submit.prevent="submitForm"> | ||
Sak1012 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
<div v-for="event in events" :key="event.slug" class="mb-2"> | ||
<label> | ||
<input type="radio" :value="event.slug" v-model="selectedEvent" /> | ||
{{ event.name.en }} | ||
</label> | ||
</div> | ||
<div> | ||
<StandardButton | ||
type="submit" | ||
text="Select Event" | ||
class="btn-primary mt-6 w-full justify-center" | ||
/> | ||
</div> | ||
</form> | ||
<div v-if="!events.length && !error"> | ||
No events available | ||
<StandardButton | ||
text="Refresh" | ||
class="btn-primary mt-6 w-1/2 justify-center" | ||
@click="fetchEvents(url.value, apiToken.value, organiser.value)" | ||
/> | ||
</div> | ||
</div> | ||
</template> |
This file contains hidden or 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
<script setup> | ||
import { ref, onMounted } from 'vue' | ||
import { useRouter } from 'vue-router' | ||
import { useLoadingStore } from '@/stores/loading' | ||
import { useAuthStore } from '@/stores/auth' | ||
import { useUserStore } from '@/stores/user' | ||
import { useleedauth } from '@/stores/leedauth' | ||
import StandardButton from '@/components/Common/StandardButton.vue' | ||
|
||
const loadingStore = useLoadingStore() | ||
const authStore = useAuthStore() | ||
const userStore = useUserStore() | ||
const leedauth = useleedauth() | ||
const showError = ref(false) | ||
const userId = ref('') | ||
const password = ref('') | ||
const server = ref('') | ||
// router | ||
const router = useRouter() | ||
|
||
async function submitLogin() { | ||
const payload = { | ||
email: email.value, | ||
key: password.value | ||
} | ||
const response = await leedauth.leedlogin(payload) | ||
if (response.success) { | ||
router.push({ name: 'leadscan' }) | ||
} | ||
} | ||
loadingStore.contentLoaded() | ||
</script> | ||
|
||
<template> | ||
<div class="-mt-16 flex h-screen flex-col justify-center"> | ||
<div class="my-auto sm:mx-auto sm:w-full sm:max-w-sm"> | ||
<h2 class="text-center">Sign in with your Exhibitor credentials</h2> | ||
<form class="mt-10 space-y-3" @submit.prevent="submitLogin"> | ||
<div> | ||
<label for="email">Contact Email</label> | ||
<div class="mt-2"> | ||
<input | ||
id="email" | ||
v-model="email" | ||
name="email" | ||
type="email" | ||
required="true" | ||
class="block w-full" | ||
/> | ||
</div> | ||
</div> | ||
|
||
<div> | ||
<label for="password">Exhibitor Key</label> | ||
<div class="mt-2"> | ||
<input | ||
id="password" | ||
v-model="password" | ||
name="password" | ||
type="password" | ||
autocomplete="current-password" | ||
required="true" | ||
class="block w-full" | ||
/> | ||
</div> | ||
</div> | ||
|
||
<div> | ||
<StandardButton | ||
type="submit" | ||
text="Login" | ||
class="btn-primary mt-6 w-full justify-center" | ||
/> | ||
</div> | ||
|
||
<div v-if="showError"> | ||
<p class="text-sm text-danger">Wrong credentials or account does not exist</p> | ||
</div> | ||
</form> | ||
</div> | ||
</div> | ||
</template> |
This file contains hidden or 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<script setup> | ||
import QRCamera from '@/components/Common/QRCamera.vue' | ||
import { useLoadingStore } from '@/stores/loading' | ||
const loadingStore = useLoadingStore() | ||
loadingStore.contentLoaded() | ||
</script> | ||
|
||
<template> | ||
<div | ||
class="-mt-16 grid h-screen w-full grid-cols-1 place-items-center items-center justify-center align-middle" | ||
> | ||
<QRCamera qr-type="eventyaylead" scan-type="Lead-Scan" /> | ||
</div> | ||
</template> |
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.