Artikel DB struktur geändert von CODEX
This commit is contained in:
1 parent
0c0a678eaa
commit
9c18234efe
95 files changed
+3872
-2316
No files matched your search
@@ -1,27 +1,26 @@
|
||||
import { manufacturerFindAll } from "../../../../actions/manufacturer.actions";
|
||||
import { categoryFindAll } from "../../../../actions/category.actions";
|
||||
import { ArticleMainForm } from "../../../../components/article/articleMain.form";
|
||||
import { articleCreate, articleFindAll } from "../../../../actions/article.actions";
|
||||
import Link from "next/link";
|
||||
import { sites } from "../../../../../../apps/frontend/_config/sites";
|
||||
//import { sites } from "@/";
|
||||
import { manufacturerFindAll } from '../../../../actions/manufacturer.actions';
|
||||
import { categoryFindAll } from '../../../../actions/category.actions';
|
||||
import { articleGroupsFindAll } from '../../../../actions/article.actions';
|
||||
import { ArticleMainForm } from '../../../../components/article/articleMain.form';
|
||||
import Link from 'next/link';
|
||||
import { sites } from '../../../../_config/sites';
|
||||
|
||||
|
||||
interface Props {
|
||||
|
||||
}
|
||||
|
||||
export default async function ArticlePage({ }: Props) {
|
||||
|
||||
const cats = await categoryFindAll();
|
||||
const manufacturer = await manufacturerFindAll();
|
||||
const artikel = await articleFindAll();
|
||||
|
||||
if(!manufacturer) return <div>Keine Hersteller gefunden</div>
|
||||
|
||||
return <>
|
||||
<ArticleMainForm categories={cats} manufacturer={manufacturer}></ArticleMainForm>
|
||||
<Link href={`${sites.article.url}`} className="text-sky-300">zurück</Link>
|
||||
|
||||
export default async function ArticleNewPage() {
|
||||
const [categories, manufacturer, groups] = await Promise.all([
|
||||
categoryFindAll(),
|
||||
manufacturerFindAll(),
|
||||
articleGroupsFindAll(),
|
||||
]);
|
||||
return (
|
||||
<>
|
||||
<ArticleMainForm
|
||||
categories={categories}
|
||||
manufacturer={manufacturer}
|
||||
groups={groups}
|
||||
/>
|
||||
<Link className="text-sky-700 p-6" href={sites.article.url}>
|
||||
Zurück zu den Artikeln
|
||||
</Link>
|
||||
</>
|
||||
}
|
||||
);
|
||||
}
|
||||
Reference in new issue
Block a user