-
{{successMessage}}
-
{{errorMessage}}
+
{{successMessage}}
+
{{errorMessage}}
-
-
-
-
diff --git a/web/app/src/components/ThemeChooser.vue b/web/app/src/components/ThemeChooser.vue
index dfd7ff1..4d6fb55 100644
--- a/web/app/src/components/ThemeChooser.vue
+++ b/web/app/src/components/ThemeChooser.vue
@@ -1,11 +1,97 @@
+
+
-
-
+
- Check
@@ -19,33 +105,34 @@
+
-
-
-
+
+
-
-
-
-
-
-
- Check
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
diff --git a/web/app/src/config.js b/web/app/src/config.js
index b8e91d8..6083d04 100644
--- a/web/app/src/config.js
+++ b/web/app/src/config.js
@@ -1,99 +1,106 @@
export let config = {
version: "1.16.0",
- appNavName: import.meta.env.VITE_APP_NAV_NAME || 'APP_NAV_NAME',
+ appNavName: import.meta.env.VITE_APP_NAV_NAME || "APP_NAV_NAME",
appNavImg: import.meta.env.VITE_APP_NAV_IMG || null,
- OrganizationName: import.meta.env.VITE_ORGANIZATION_NAME || 'ORGANIZATION_NAME',
- ProjectLongName: import.meta.env.VITE_PROJECT_LONG_NAME || 'PROJECT_LONG_NAME',
+ OrganizationName: import.meta.env.VITE_ORGANIZATION_NAME || "ORGANIZATION_NAME",
+ ProjectLongName: import.meta.env.VITE_PROJECT_LONG_NAME || "PROJECT_LONG_NAME",
DeliveryAreaNames: import.meta.env.VITE_DELIVERY_AREA_NAMES || "",
- DeliveryZipcodes: import.meta.env.VITE_DELIVERY_ZIPCODES || [19003,19010,19041,19072,19096,19004,19035,19066,19085,19428],
+ DeliveryZipcodesConfig: import.meta.env.VITE_DELIVERY_ZIPCODES || "",
+ DeliveryZipcodes: [],
DeliveryOutsideAreaUrl: import.meta.env.VITE_DELIVERY_OUTSIDE_AREA_URL || "",
DeliveryMessage: import.meta.env.VITE_DELIVERY_MESSAGE || "",
DeliveryFormURL: import.meta.env.VITE_DELIVERY_FORM_URL || "/delivery-form",
VolunteerPortalURL: import.meta.env.VITE_VOLUNTEER_PORTAL_URL || "VOLUNTEER_PORTAL_URL",
EnableGuestLogin: import.meta.env.VITE_ENABLE_GUEST_LOGIN || "false",
+ MainOrgURL: import.meta.env.VITE_MAIN_ORG_URL || '#main-org-url-not-set',
meta: {
Home: {
- title: 'Home',
+ title: "Home",
metaTags: [
{
- name: 'description',
- content: 'Home page'
+ name: "description",
+ content: "Home page"
}
]
},
Login: {
- title: 'Login',
+ title: "Login",
metaTags: [
{
- name: 'description',
- content: 'Login'
+ name: "description",
+ content: "Login"
}
]
},
Register: {
- title: 'Register',
+ title: "Register",
metaTags: [
{
- name: 'description',
- content: 'Register for an account'
+ name: "description",
+ content: "Register for an account"
}
]
},
About: {
- title: 'About',
+ title: "About",
metaTags: [
{
- name: 'description',
- content: 'About page'
+ name: "description",
+ content: "About page"
}
]
},
Contact: {
- title: 'Contact Us',
+ title: "Contact Us",
metaTags: [
{
- name: 'description',
- content: 'How to contact us'
+ name: "description",
+ content: "How to contact us"
}
]
},
DeliveryForm: {
- title: 'Delivery Profile',
+ title: "Delivery Profile",
metaTags: [
{
- name: 'description',
- content: 'Your delivery application/profile page.'
+ name: "description",
+ content: "Your delivery application/profile page."
}
]
},
PrivacyPolicy: {
- title: 'Privacy Policy',
+ title: "Privacy Policy",
metaTags: [
{
- name: 'description',
- content: 'Privacy policy.'
+ name: "description",
+ content: "Privacy policy."
}
]
},
Terms: {
- title: 'Terms',
+ title: "Terms",
metaTags: [
{
- name: 'description',
- content: 'Terms of use.'
+ name: "description",
+ content: "Terms of use."
}
]
},
ForgotPassword: {
- title: 'Forgot Password',
+ title: "Forgot Password",
metaTags: [
{
- name: 'description',
- content: 'Enter your email if you have forgotten your password.'
+ name: "description",
+ content: "Enter your email if you have forgotten your password."
}
]
}
}
}
+
+if (config.DeliveryZipcodesConfig.length > 0) {
+ let zips = config.DeliveryZipcodesConfig.replace(/\s+/g, "")
+ config.DeliveryZipcodes = config.DeliveryZipcodesConfig.split(",")
+}
diff --git a/web/app/src/main.js b/web/app/src/main.js
index 024f67c..765d617 100644
--- a/web/app/src/main.js
+++ b/web/app/src/main.js
@@ -45,9 +45,20 @@ fetch('/__/firebase/init.json').then(async response => {
connectFunctionsEmulator(functions, 'localhost', 5001)
}
- getAuth().onAuthStateChanged(user => {
- useAuthUserStore().save(user)
- });
+ getAuth().onAuthStateChanged(async user => {
+ let isAdmin = false
+ let isVolunteer = false
+ let isPending = false
+ let isGuest = false
+ if (user) {
+ const token = await getIdTokenResult(user)
+ isAdmin = token.claims.admin === true
+ isVolunteer = token.claims.volunteer === true
+ isGuest = !isVolunteer
+ isPending = token.claims.pendingvolunteer === true
+ }
+ useAuthUserStore().save(user, isAdmin, isVolunteer, isPending, isGuest)
+ })
const app = createApp(App)
app.use(createPinia())
diff --git a/web/app/src/pages/AboutPage.vue b/web/app/src/pages/AboutPage.vue
index 62ba314..e323239 100644
--- a/web/app/src/pages/AboutPage.vue
+++ b/web/app/src/pages/AboutPage.vue
@@ -1,9 +1,9 @@
About Food Pantry App
-
Food Pantry App was created to help operating a food pantry that focuses on delivering food to guests.
-
If you would like to volunteer to work on FPA, report a bug, or make a suggestion, please go to https://github.com/ncosd/food-pantry-app and create an issue.
+
Food Pantry App was created to help operating a food pantry that focuses on providing food to guests.
+
If you would like to volunteer to work on FPA, report a bug, or make a suggestion, please
+ go to https://github.com/ncosd/food-pantry-app and create an issue.
-
diff --git a/web/app/src/pages/ContactPage.vue b/web/app/src/pages/ContactPage.vue
index 6a10f2b..9577e13 100644
--- a/web/app/src/pages/ContactPage.vue
+++ b/web/app/src/pages/ContactPage.vue
@@ -1,3 +1,8 @@
+
+
Contact Us
@@ -7,8 +12,3 @@
If you have general questions can be directed to the office phone at {{office_phone}}
-
-
diff --git a/web/app/src/pages/ForgotPassword.vue b/web/app/src/pages/ForgotPassword.vue
index f5e8a1c..c2db6e9 100644
--- a/web/app/src/pages/ForgotPassword.vue
+++ b/web/app/src/pages/ForgotPassword.vue
@@ -1,45 +1,32 @@
+
+
-
-
-
-
-
diff --git a/web/app/src/pages/HomePage.vue b/web/app/src/pages/HomePage.vue
index f9b8ea3..fa7cdbf 100644
--- a/web/app/src/pages/HomePage.vue
+++ b/web/app/src/pages/HomePage.vue
@@ -1,34 +1,19 @@
+
+
Welcome!
-
Welcome to the {{config.ProjectLongName}}. Once you have
- registered, use your profile to customize how you interact with the {{config.OrganizationName}}.
+
Welcome to the {{config.ProjectLongName}}.
+
This is the Guest application. Volunteers should use the Volunteer Portal link above.
+
Guest registration and login is not enabled at this time. Please use our website
+ {{config.MainOrgURL}} for guest services.
-
-
-
-
diff --git a/web/app/src/pages/LoginPage.vue b/web/app/src/pages/LoginPage.vue
index da1ef5d..d03ed03 100644
--- a/web/app/src/pages/LoginPage.vue
+++ b/web/app/src/pages/LoginPage.vue
@@ -24,11 +24,6 @@ const submit = () => {
.then(async () => {
const user = await auth.currentUser
- const token = await getIdTokenResult(user)
- if (token.claims.volunteer === true) {
- window.location.href = config.VolunteerPortalURL
- }
-
showSuccess.value = true
successMessage.value = "You have signed in."
router.replace({name:'HomePage'})
diff --git a/web/app/src/pages/RegisterPage.vue b/web/app/src/pages/RegisterPage.vue
index 16fc98c..5c003a1 100644
--- a/web/app/src/pages/RegisterPage.vue
+++ b/web/app/src/pages/RegisterPage.vue
@@ -1,110 +1,131 @@
-
-
-
-
-
-
-
-
- {{successMessage}}
-
-
- {{error}}
-
-