Compare commits
7 Commits
d48a51f0e3
...
kundenverw
| Author | SHA1 | Date | |
|---|---|---|---|
| 01f949ca03 | |||
| b35facc343 | |||
| b9299e2cdf | |||
| 43c2f1e841 | |||
| 35407b034f | |||
| 4edf59fd4c | |||
| cd8918f21b |
105
app.vue
105
app.vue
@ -1,104 +1,11 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="main-container">
|
<NuxtLayout>
|
||||||
<div class="header">
|
<NuxtPage />
|
||||||
<p>
|
</NuxtLayout>
|
||||||
<router-link to="/header/help">
|
|
||||||
HILFE
|
|
||||||
</router-link>
|
|
||||||
<router-link to="/header/info">
|
|
||||||
INFO
|
|
||||||
</router-link>
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
<div class="sidenav">
|
|
||||||
<div class="sidenav-content">
|
|
||||||
<h1 class="menu-heading">
|
|
||||||
WebAdmin
|
|
||||||
</h1>
|
|
||||||
<p>
|
|
||||||
<router-link to="/">
|
|
||||||
Home
|
|
||||||
</router-link>
|
|
||||||
<router-link to="/adresses/adresses_index">
|
|
||||||
Adressverwaltung
|
|
||||||
</router-link>
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="container">
|
|
||||||
<router-view />
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script></script>
|
<script setup lang="ts">
|
||||||
|
|
||||||
<style scoped>
|
</script>
|
||||||
.main-container {
|
|
||||||
max-width: 70vw;
|
|
||||||
margin: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Navigation */
|
<style src="@/assets/main.css"></style>
|
||||||
/* The side navigation menu */
|
|
||||||
.sidenav {
|
|
||||||
height: 100%;
|
|
||||||
width: 250px;
|
|
||||||
position: fixed;
|
|
||||||
z-index: 1;
|
|
||||||
top: 0;
|
|
||||||
left: 0;
|
|
||||||
background-color: #a5aeb5;
|
|
||||||
overflow-x: hidden;
|
|
||||||
padding-top: 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.sidenav-content {
|
|
||||||
padding: 15px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* The menu title */
|
|
||||||
.menu-heading {
|
|
||||||
color: #f1f1f1;
|
|
||||||
width: 200px;
|
|
||||||
height: 75px;
|
|
||||||
font-weight: 600;
|
|
||||||
font-size: 40px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* The navigation menu links */
|
|
||||||
.sidenav a {
|
|
||||||
text-decoration: none;
|
|
||||||
font-size: 25px;
|
|
||||||
color: #e0e2e3;
|
|
||||||
display: block;
|
|
||||||
transition: 0.3s;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* When you mouse over the navigation links, change their color */
|
|
||||||
.sidenav a:hover {
|
|
||||||
color: #f1f1f1;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Position and style the close button (top right corner) */
|
|
||||||
.sidenav .closebtn {
|
|
||||||
position: absolute;
|
|
||||||
top: 0;
|
|
||||||
right: 25px;
|
|
||||||
font-size: 36px;
|
|
||||||
margin-left: 50px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Style page content - use this if you want to push the page content to the right when you open the side navigation */
|
|
||||||
#main {
|
|
||||||
transition: margin-left .5s;
|
|
||||||
padding: 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* On smaller screens, where height is less than 450px, change the style of the sidenav (less padding and a smaller font size) */
|
|
||||||
@media screen and (max-height: 450px) {
|
|
||||||
.sidenav {padding-top: 15px;}
|
|
||||||
.sidenav a {font-size: 18px;}
|
|
||||||
}
|
|
||||||
|
|
||||||
</style>
|
|
||||||
|
|||||||
117
assets/main.css
117
assets/main.css
@ -2,17 +2,59 @@
|
|||||||
padding: 0;
|
padding: 0;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
font-family: "TimesNewRoman";
|
font-family: "Helvetica";
|
||||||
}
|
}
|
||||||
|
|
||||||
.heading {
|
.main-content {
|
||||||
background-color: beige;
|
margin-left: 275px;
|
||||||
|
margin-top: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.main-container {
|
/* On smaller screens, where height is less than 450px, change the style of the sidenav (less padding and a smaller font size) */
|
||||||
max-width: 45vw;
|
@media screen and (max-height: 450px) {
|
||||||
margin: auto;
|
.sidenav {padding-top: 15px;}
|
||||||
padding-top: 60px;
|
.sidenav a {font-size: 18px;}
|
||||||
|
}
|
||||||
|
|
||||||
|
#title {
|
||||||
|
padding-bottom: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Header */
|
||||||
|
.header {
|
||||||
|
background-color: #a5aeb5;
|
||||||
|
width: 100%;
|
||||||
|
margin-left: 250px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#header-table th {
|
||||||
|
text-transform: uppercase;
|
||||||
|
text-align: left;
|
||||||
|
padding: 8px;
|
||||||
|
min-width: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#header-table tr {
|
||||||
|
min-width: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#header-table td {
|
||||||
|
text-align: left;
|
||||||
|
padding: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* The navigation menu links */
|
||||||
|
.header a {
|
||||||
|
text-decoration: none;
|
||||||
|
font-size: 18px;
|
||||||
|
color: #e0e2e3;
|
||||||
|
display: block;
|
||||||
|
transition: 0.3s;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* When you mouse over the navigation links, change their color */
|
||||||
|
.header a:hover {
|
||||||
|
color: #f1f1f1;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* The side navigation menu */
|
/* The side navigation menu */
|
||||||
@ -39,11 +81,11 @@
|
|||||||
height: 75px;
|
height: 75px;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
font-size: 40px;
|
font-size: 40px;
|
||||||
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* The navigation menu links */
|
/* The navigation menu links */
|
||||||
.sidenav a {
|
.sidenav a {
|
||||||
padding: 8px 8px 8px 32px;
|
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
font-size: 25px;
|
font-size: 25px;
|
||||||
color: #e0e2e3;
|
color: #e0e2e3;
|
||||||
@ -56,58 +98,27 @@
|
|||||||
color: #f1f1f1;
|
color: #f1f1f1;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Position and style the close button (top right corner) */
|
/* Address Table */
|
||||||
.sidenav .closebtn {
|
.address-table {
|
||||||
position: absolute;
|
border-collapse: collapse;
|
||||||
top: 0;
|
width: 100%;
|
||||||
right: 25px;
|
|
||||||
font-size: 36px;
|
|
||||||
margin-left: 50px;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Style page content - use this if you want to push the page content to the right when you open the side navigation */
|
.address-table th,
|
||||||
#main {
|
.address-table td {
|
||||||
transition: margin-left .5s;
|
border: 1px solid #ddd;
|
||||||
padding: 20px;
|
padding: 8px;
|
||||||
|
text-align: left;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* On smaller screens, where height is less than 450px, change the style of the sidenav (less padding and a smaller font size) */
|
.address-table th {
|
||||||
@media screen and (max-height: 450px) {
|
background-color: #f2f2f2;
|
||||||
.sidenav {padding-top: 15px;}
|
color: #333;
|
||||||
.sidenav a {font-size: 18px;}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Styling for adresses */
|
|
||||||
input {
|
|
||||||
display: block;
|
|
||||||
width: 350px;
|
|
||||||
margin: 20px auto;
|
|
||||||
padding: 10px 45px;
|
|
||||||
background: white url("assets/search.svg") no-repeat 15px center;
|
|
||||||
background-size: 15px 15px;
|
|
||||||
font-size: 16px;
|
|
||||||
border: none;
|
|
||||||
border-radius: 5px;
|
|
||||||
box-shadow: rgba(50, 50, 93, 0.25) 0px 2px 5px -1px,
|
|
||||||
rgba(0, 0, 0, 0.3) 0px 1px 3px -1px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.item {
|
|
||||||
width: 350px;
|
|
||||||
margin: 0 auto 10px auto;
|
|
||||||
padding: 10px 20px;
|
|
||||||
color: white;
|
|
||||||
border-radius: 5px;
|
|
||||||
box-shadow: rgba(0, 0, 0, 0.1) 0px 1px 3px 0px,
|
|
||||||
rgba(0, 0, 0, 0.06) 0px 1px 2px 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.adresses {
|
|
||||||
background-color: #a5aeb5;
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
|
|
||||||
.error {
|
|
||||||
background-color: tomato;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|||||||
19
components/HeaderNav.vue
Normal file
19
components/HeaderNav.vue
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
<template>
|
||||||
|
<div class="header">
|
||||||
|
<table id="header-table">
|
||||||
|
<tr>
|
||||||
|
<th>
|
||||||
|
<NuxtLink to="/header/help">
|
||||||
|
Hilfe
|
||||||
|
</NuxtLink>
|
||||||
|
</th>
|
||||||
|
<th>
|
||||||
|
<NuxtLink to="/header/info">
|
||||||
|
Info
|
||||||
|
</NuxtLink>
|
||||||
|
</th>
|
||||||
|
<th> Logout </th>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
15
components/SideNav.vue
Normal file
15
components/SideNav.vue
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
<template>
|
||||||
|
<div class="sidenav">
|
||||||
|
<div class="sidenav-content">
|
||||||
|
<h1 class="menu-heading">
|
||||||
|
WebAdmin
|
||||||
|
</h1>
|
||||||
|
<NuxtLink to="/">
|
||||||
|
Home
|
||||||
|
</NuxtLink>
|
||||||
|
<NuxtLink to="/address-management/address_index">
|
||||||
|
Adressverwaltung
|
||||||
|
</NuxtLink>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
36
data/addressData.json
Normal file
36
data/addressData.json
Normal file
@ -0,0 +1,36 @@
|
|||||||
|
{
|
||||||
|
"items":
|
||||||
|
[
|
||||||
|
{
|
||||||
|
"id": 1,
|
||||||
|
"customernumber": "0000",
|
||||||
|
"name": "Dieter Hillers",
|
||||||
|
"company": "Hedemann GmbH",
|
||||||
|
"street": "Oldenburger Str. 28",
|
||||||
|
"postalcode": "26639",
|
||||||
|
"location": "Wiesmoor",
|
||||||
|
"phone": "04944-1450"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": 2,
|
||||||
|
"customernumber": "1111",
|
||||||
|
"name": "Holger Hedemann",
|
||||||
|
"company": "Hedemann GmbH",
|
||||||
|
"street": "Oldenburger Str. 28",
|
||||||
|
"postalcode": "26639",
|
||||||
|
"location": "Wiesmoor",
|
||||||
|
"phone": "04944-1450"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"id": 3,
|
||||||
|
"customernumber": "2222",
|
||||||
|
"name": "Hilko Hartmann",
|
||||||
|
"company": "Hedemann GmbH",
|
||||||
|
"street": "Oldenburger Str. 28",
|
||||||
|
"postalcode": "26639",
|
||||||
|
"location": "Wiesmoor",
|
||||||
|
"phone": "04944-1450"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
7
layouts/default.vue
Normal file
7
layouts/default.vue
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<HeaderNav />
|
||||||
|
<SideNav />
|
||||||
|
<slot />
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
@ -3,6 +3,9 @@ export default defineNuxtConfig({
|
|||||||
modules: [
|
modules: [
|
||||||
'@huntersofbook/naive-ui-nuxt'
|
'@huntersofbook/naive-ui-nuxt'
|
||||||
],
|
],
|
||||||
|
css: [
|
||||||
|
'@/assets/main.css'
|
||||||
|
],
|
||||||
build: {
|
build: {
|
||||||
transpile: [
|
transpile: [
|
||||||
'trpc-nuxt'
|
'trpc-nuxt'
|
||||||
|
|||||||
2
package-lock.json
generated
2
package-lock.json
generated
@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"name": "webadmin3.0",
|
"name": "WebAdmin3.0",
|
||||||
"lockfileVersion": 3,
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
|
|||||||
11
pages/address-management/address_index.vue
Normal file
11
pages/address-management/address_index.vue
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
<template>
|
||||||
|
<div class="main-content">
|
||||||
|
<h1 id="title">
|
||||||
|
Willkommen in der Adressverwaltung
|
||||||
|
</h1>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts">
|
||||||
|
|
||||||
|
</script>
|
||||||
@ -1,33 +0,0 @@
|
|||||||
<template>
|
|
||||||
<div class="main-container">
|
|
||||||
<div class="heading">
|
|
||||||
<h1>
|
|
||||||
Willkommen in der Adressverwaltung
|
|
||||||
</h1>
|
|
||||||
</div>
|
|
||||||
<div class="content">
|
|
||||||
<input v-model="input" type="text" placeholder="Suche...">
|
|
||||||
<div v-for="adresses in filteredList()" :key="adresses" class="adresses">
|
|
||||||
<p>{{ adresses }}</p>
|
|
||||||
</div>
|
|
||||||
<div v-if="input&&!filteredList().length" class="item error">
|
|
||||||
<p>Nicht gefunden</p>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script setup>
|
|
||||||
import { ref } from 'vue'
|
|
||||||
|
|
||||||
const input = ref('')
|
|
||||||
const adresses = ['Hedemann', 'Nietiedt', 'Schoon']
|
|
||||||
function filteredList () {
|
|
||||||
return adresses.filter(adresses =>
|
|
||||||
adresses.toLowerCase().includes(input.value.toLowerCase())
|
|
||||||
)
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style scoped src="@/assets/main.css">
|
|
||||||
</style>
|
|
||||||
@ -1,14 +0,0 @@
|
|||||||
<template>
|
|
||||||
<div class="main-container">
|
|
||||||
<div class="heading">
|
|
||||||
<h1>
|
|
||||||
Kundenname
|
|
||||||
</h1>
|
|
||||||
</div>
|
|
||||||
<div class="content">
|
|
||||||
<p>Hier findest einen Kunden</p>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<style scoped src="@/assets/main.css"></style>
|
|
||||||
@ -1,14 +1,10 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="main-container">
|
<div class="main-content">
|
||||||
<div class="heading">
|
<h1 id="title">
|
||||||
<h1>
|
|
||||||
Hilfe
|
Hilfe
|
||||||
</h1>
|
</h1>
|
||||||
</div>
|
|
||||||
<div class="content">
|
<div class="content">
|
||||||
<p>Hier findest du Hilfe</p>
|
<p>Hier findest du Hilfe</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style scoped src="@/assets/main.css"></style>
|
|
||||||
|
|||||||
@ -1,14 +1,11 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="main-container">
|
<div class="main-content">
|
||||||
<div class="heading">
|
<h1 id="title">
|
||||||
<h1>
|
|
||||||
Info
|
Info
|
||||||
</h1>
|
</h1>
|
||||||
</div>
|
|
||||||
<div class="content">
|
<div class="content">
|
||||||
<p>Hier findest du Infos</p>
|
<p>Hier findest du Infos</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style scoped src="@/assets/main.css"></style>
|
|
||||||
|
|||||||
@ -1,9 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="main-container">
|
<div class="main-content">
|
||||||
<div class="heading">
|
<h1 id="title">
|
||||||
<h1>Willkommen</h1>
|
Willkommen
|
||||||
</div>
|
</h1>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style scoped src="@/assets/main.css"></style>
|
|
||||||
|
|||||||
@ -1,23 +0,0 @@
|
|||||||
import { createRouter, createWebHistory } from 'vue-router'
|
|
||||||
import index from '@/pages/index.vue'
|
|
||||||
import adresses from '@/pages/adresses/adresses_index.vue'
|
|
||||||
import help from '@/pages/header/help'
|
|
||||||
import info from '@/pages/header/info'
|
|
||||||
|
|
||||||
const routes = [
|
|
||||||
{ path: '/', name: 'Home', component: index },
|
|
||||||
{ path: 'adresses/adresses_index', name: 'Adressverwaltung', component: adresses },
|
|
||||||
{ path: 'header/help', name: 'Hilfe', component: help },
|
|
||||||
{ path: 'header/info', name: 'Info', component: info }
|
|
||||||
]
|
|
||||||
|
|
||||||
const router = createRouter({
|
|
||||||
history: createWebHistory(),
|
|
||||||
routes
|
|
||||||
})
|
|
||||||
|
|
||||||
const app = createApp({})
|
|
||||||
|
|
||||||
app.use(router)
|
|
||||||
|
|
||||||
export default router
|
|
||||||
Reference in New Issue
Block a user