diff --git a/src/actions/accountActions.ts b/src/actions/accountActions.ts index 6d2cd5c..668d1d2 100644 --- a/src/actions/accountActions.ts +++ b/src/actions/accountActions.ts @@ -3,9 +3,18 @@ import { eq, not , asc} from "drizzle-orm"; import { revalidatePath } from "next/cache"; import { db } from "@db/index"; import { accounts } from "@schemas/schema"; +import { vw_accounts } from "@schemas/schema"; export const getData = async () => { - const data = await db.select().from(accounts).orderBy(asc(accounts.last_name)); + const data = await db.select().from(accounts).orderBy(asc(accounts.userId)); + return data; +}; +export const getAllAccounts = async () => { + return getData(); +}; + +export const getViewAccounts = async () => { + const data = await db.select().from(vw_accounts).orderBy(asc(vw_accounts.last_name)); return data; }; diff --git a/src/actions/componentTypeActions.ts b/src/actions/componentTypeActions.ts index 2c945a5..d2501bb 100644 --- a/src/actions/componentTypeActions.ts +++ b/src/actions/componentTypeActions.ts @@ -3,8 +3,12 @@ import { eq, not , asc} from "drizzle-orm"; import { revalidatePath } from "next/cache"; import { db } from "../db"; import { componentType } from "@schemas/schema"; + export const getData = async () => { const data = await db.select().from(componentType).orderBy(asc(componentType.name)); return data; }; +export const getComponentTypeName = async () => { + return getData(); +}; \ No newline at end of file diff --git a/src/actions/manufacturerActions.ts b/src/actions/manufacturerActions.ts index 0613264..0db555c 100644 --- a/src/actions/manufacturerActions.ts +++ b/src/actions/manufacturerActions.ts @@ -10,3 +10,6 @@ export const getData = async () => { return data; }; +export const getManufacturersName = async () => { + return getData(); +}; diff --git a/src/actions/userActions.ts b/src/actions/userActions.ts index 296d5bd..04a7b1b 100644 --- a/src/actions/userActions.ts +++ b/src/actions/userActions.ts @@ -8,7 +8,7 @@ export const getData = async () => { const data = await db.select().from(users).orderBy(asc(users.last_name)); return data; }; -export const getAllUsers = async () => { +export const getAllUsersOrdrByLastname = async () => { const data = await db.select().from(users).orderBy(asc(users.last_name)); return data; }; diff --git a/src/app/(siteInfo)/Blog/page.tsx b/src/app/(siteInfo)/Blog/page.tsx index ee7c612..850144c 100644 --- a/src/app/(siteInfo)/Blog/page.tsx +++ b/src/app/(siteInfo)/Blog/page.tsx @@ -13,7 +13,6 @@ export default function Blog() { and exploring firearm parts. Designed for enthusiasts by enthusiasts, we make firearm building easy and accessible.
- ) diff --git a/src/app/(siteInfo)/Disclosure/page.tsx b/src/app/(siteInfo)/Disclosure/page.tsx index c1f1611..ed43dd3 100644 --- a/src/app/(siteInfo)/Disclosure/page.tsx +++ b/src/app/(siteInfo)/Disclosure/page.tsx @@ -13,7 +13,6 @@ export default function Disclosure() { and exploring firearm parts. Designed for enthusiasts by enthusiasts, we make firearm building easy and accessible. - ) diff --git a/src/app/(siteInfo)/Footer/page.tsx b/src/app/(siteInfo)/Footer/page.tsx index 44ff5ea..52c64a3 100644 --- a/src/app/(siteInfo)/Footer/page.tsx +++ b/src/app/(siteInfo)/Footer/page.tsx @@ -8,7 +8,6 @@ export default function Footer() {© {new Date().getFullYear()} {constants.APP_NAME}. All rights reserved.
Built by Forward Group ⚡
-{account.email}
- {/* Add more fields as necessary */} -| + + {props.newColumnHeadings.getHeading()} + + + + + | ++ + {props.newColumnHeadings.getHeading()} + + + + + | ++ + {props.newColumnHeadings.getHeading()} + + + + + | + +|
|---|---|---|---|
| + + {item.first_name} + | ++ {item.last_name} + | + + ++ + | ++ + | +