Input Form new Design
This commit is contained in:
@@ -0,0 +1,33 @@
|
|||||||
|
import React from "react";
|
||||||
|
|
||||||
|
export default function Background()
|
||||||
|
{
|
||||||
|
return (
|
||||||
|
<div style={{
|
||||||
|
position: "absolute",
|
||||||
|
width: "100%",
|
||||||
|
height: "100%",
|
||||||
|
overflow: "clip",
|
||||||
|
pointerEvents: "none"
|
||||||
|
}}>
|
||||||
|
<div style={{
|
||||||
|
position: "absolute",
|
||||||
|
transform: "skew(20deg)",
|
||||||
|
width: "100%",
|
||||||
|
height: "100%",
|
||||||
|
zIndex: -10,
|
||||||
|
backgroundColor: "#f2f2f2",
|
||||||
|
borderTopLeftRadius: 400,
|
||||||
|
borderBottomRightRadius: 800,
|
||||||
|
|
||||||
|
}}></div>
|
||||||
|
<div style={{
|
||||||
|
position: "absolute",
|
||||||
|
width: "100%",
|
||||||
|
height: "100%",
|
||||||
|
zIndex: -11,
|
||||||
|
backgroundColor: "#346991",
|
||||||
|
}}></div>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -1,6 +1,7 @@
|
|||||||
import Button from "@/components/Button";
|
import Button from "@/components/Button";
|
||||||
import {useRouter} from "next/router";
|
import {useRouter} from "next/router";
|
||||||
import {useEffect, useState} from "react";
|
import {useEffect, useState} from "react";
|
||||||
|
import Background from "@/components/Background";
|
||||||
|
|
||||||
let userInfo = []
|
let userInfo = []
|
||||||
|
|
||||||
@@ -13,13 +14,11 @@ export default function InputForm(p) {
|
|||||||
this.checked = false;
|
this.checked = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
setChecked(checked)
|
setChecked(checked) {
|
||||||
{
|
|
||||||
this.checked = checked;
|
this.checked = checked;
|
||||||
}
|
}
|
||||||
|
|
||||||
setModule(module)
|
setModule(module) {
|
||||||
{
|
|
||||||
this.module = module;
|
this.module = module;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -103,13 +102,12 @@ export default function InputForm(p) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!found) {
|
if (!found) {
|
||||||
userInfo.push(new UserInfo(user.id, module));
|
userInfo.push(new UserInfo(user.id, module));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function onCheckBoxClicked(user, e)
|
function onCheckBoxClicked(user, e) {
|
||||||
{
|
|
||||||
onModuleClicked(user, "");
|
onModuleClicked(user, "");
|
||||||
|
|
||||||
let found = false;
|
let found = false;
|
||||||
@@ -122,7 +120,7 @@ export default function InputForm(p) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!found) {
|
if (!found) {
|
||||||
let temp = new UserInfo(user.id, "");
|
let temp = new UserInfo(user.id, "");
|
||||||
temp.setChecked(e.target.checked);
|
temp.setChecked(e.target.checked);
|
||||||
userInfo.push(temp);
|
userInfo.push(temp);
|
||||||
@@ -131,19 +129,38 @@ export default function InputForm(p) {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<div className="inputForm round-border">
|
<Background/>
|
||||||
<h3>SemesterName</h3>
|
<div className="inputForm box-shadow">
|
||||||
<input className="courseNameInput" value={courseName} onChange={(e) => setCourseName(e.target.value)}/>
|
<p style={{
|
||||||
|
fontSize: "18px",
|
||||||
|
color: "#777777",
|
||||||
|
fontWeight: 500,
|
||||||
|
width: 150
|
||||||
|
}}>SemesterName</p>
|
||||||
|
<input className="courseNameInput box-shadow" value={courseName}
|
||||||
|
onChange={(e) => setCourseName(e.target.value)}/>
|
||||||
<div className="semesterRangeInput">
|
<div className="semesterRangeInput">
|
||||||
<div className="semesterDateLables">
|
<div className="semesterDateLables">
|
||||||
<p className="semesterDateLable">Semesterstart</p>
|
<p className="semesterDateLable" style={{
|
||||||
<p className="semesterDateLable">Semesterende</p>
|
fontSize: " 18px",
|
||||||
|
color: "#777777",
|
||||||
|
fontWeight: 500,
|
||||||
|
width: 150
|
||||||
|
}}>Semesterstart</p>
|
||||||
|
<p className="semesterDateLable" style={{
|
||||||
|
fontSize: " 18px",
|
||||||
|
color: "#777777",
|
||||||
|
fontWeight: 500,
|
||||||
|
width: 150
|
||||||
|
}}>Semesterende</p>
|
||||||
</div>
|
</div>
|
||||||
<div className="semesterDateInputPair">
|
<div className="semesterDateInputPair">
|
||||||
<input type="date" id="start" name="trip-start" value={startDate}
|
<input type="date" id="start" className={"box-shadow selector"} value={startDate}
|
||||||
|
style={{padding: 5}}
|
||||||
onChange={(e) => setStartDate(e.target.value)}/>
|
onChange={(e) => setStartDate(e.target.value)}/>
|
||||||
<p className="inputFieldSeperator">-</p>
|
<p className="inputFieldSeperator">-</p>
|
||||||
<input type="date" id="start" name="trip-start" value={endDate}
|
<input type="date" id="start" className={"box-shadow selector"} value={endDate}
|
||||||
|
style={{padding: 5}}
|
||||||
onChange={(e) => setEndDate(e.target.value)}/>
|
onChange={(e) => setEndDate(e.target.value)}/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -151,19 +168,57 @@ export default function InputForm(p) {
|
|||||||
<table>
|
<table>
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr>
|
<tr>
|
||||||
<th></th>
|
<th style={{
|
||||||
<th>Dozent</th>
|
fontSize: " 18px",
|
||||||
<th>Modul</th>
|
color: "#777777",
|
||||||
|
fontWeight: 500,
|
||||||
|
}}>Wählen
|
||||||
|
</th>
|
||||||
|
<th style={{
|
||||||
|
fontSize: " 18px",
|
||||||
|
color: "#777777",
|
||||||
|
fontWeight: 500,
|
||||||
|
}}>Freischalten
|
||||||
|
</th>
|
||||||
|
<th style={{
|
||||||
|
fontSize: " 18px",
|
||||||
|
color: "#777777",
|
||||||
|
fontWeight: 500,
|
||||||
|
textAlign: "center"
|
||||||
|
}}>Dozent
|
||||||
|
</th>
|
||||||
|
<th style={{
|
||||||
|
fontSize: " 18px",
|
||||||
|
color: "#777777",
|
||||||
|
fontWeight: 500,
|
||||||
|
textAlign: "center",
|
||||||
|
}}>Modul
|
||||||
|
</th>
|
||||||
</tr>
|
</tr>
|
||||||
{users.map(user => (
|
{users.map(user => (
|
||||||
<tr>
|
<tr>
|
||||||
<td><input type="checkbox" onChange={(e) => {
|
|
||||||
|
<td><div style={{
|
||||||
|
display: "flex",
|
||||||
|
flexDirection: "row",
|
||||||
|
justifyContent: "center",
|
||||||
|
}}><input type="checkbox" onChange={(e) => {
|
||||||
onCheckBoxClicked(user, e);
|
onCheckBoxClicked(user, e);
|
||||||
}}/></td>
|
}}/></div></td>
|
||||||
<td>{user.firstName + " " + user.lastName}</td>
|
|
||||||
<select id={"userSelect"} name={"userSelect"} multiple={false} style={{
|
<td><div style={{
|
||||||
|
display: "flex",
|
||||||
|
flexDirection: "row",
|
||||||
|
justifyContent: "center",
|
||||||
|
}}><input type="checkbox" onChange={(e) => {
|
||||||
|
onCheckBoxClicked(user, e);
|
||||||
|
}}/></div></td>
|
||||||
|
<td style={{}}>{user.firstName + " " + user.lastName}</td>
|
||||||
|
<select id={"userSelect"} name={"userSelect"} className={"box-shadow selector"}
|
||||||
|
multiple={false} style={{
|
||||||
maxHeight: 80,
|
maxHeight: 80,
|
||||||
border: "1px solid black"
|
marginTop: 10,
|
||||||
|
padding: "5px 2px"
|
||||||
}} onChange={(e) => {
|
}} onChange={(e) => {
|
||||||
onModuleClicked(user, e.target.value)
|
onModuleClicked(user, e.target.value)
|
||||||
}}>
|
}}>
|
||||||
@@ -179,10 +234,10 @@ export default function InputForm(p) {
|
|||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
<div id="buttons">
|
<div id="buttons">
|
||||||
<Button color="red" width="100px" height="30px" text="Abbrechen" onClick={() => {
|
<Button color="rgba(54,54,54,0.64)" width="100px" height="30px" text="Abbrechen" onClick={() => {
|
||||||
router.back()
|
router.back()
|
||||||
}}/>
|
}}/>
|
||||||
<Button color="green" width="100px" height="30px" text="Speichern" onClick={() => {
|
<Button color="#77932b" width="100px" height="30px" text="Speichern" onClick={() => {
|
||||||
onCreateClicked()
|
onCreateClicked()
|
||||||
}}/>
|
}}/>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -12,6 +12,7 @@ import Login from "@/components/Login";
|
|||||||
import Test from "@/components/Test";
|
import Test from "@/components/Test";
|
||||||
import BasicDateCalendar from "@/components/CalendarSideBar";
|
import BasicDateCalendar from "@/components/CalendarSideBar";
|
||||||
import {randomInt} from "next/dist/shared/lib/bloom-filter/utils";
|
import {randomInt} from "next/dist/shared/lib/bloom-filter/utils";
|
||||||
|
import Background from "@/components/Background";
|
||||||
|
|
||||||
|
|
||||||
const inter = Inter({subsets: ['latin']})
|
const inter = Inter({subsets: ['latin']})
|
||||||
@@ -22,32 +23,15 @@ export default function Home(p) {
|
|||||||
|
|
||||||
|
|
||||||
<div className={"normal-centered"}>
|
<div className={"normal-centered"}>
|
||||||
<div style={{
|
<Background/>
|
||||||
position: "absolute",
|
<h1 style={{
|
||||||
width: "100%",
|
fontSize: 40,
|
||||||
height: "100%",
|
fontWeight: "bold",
|
||||||
overflow: "clip",
|
color: "#77932b",
|
||||||
pointerEvents: "none"
|
marginBottom: "5%",
|
||||||
}}>
|
textShadow: "2px 2px 2px rgba(0, 0, 0, 0.2)",
|
||||||
<div style={{
|
textAlign: "center"
|
||||||
position: "absolute",
|
}}>Willkommen in deinem Vorlesungsplaner</h1>
|
||||||
transform: "skew(20deg)",
|
|
||||||
width: "100%",
|
|
||||||
height: "100%",
|
|
||||||
zIndex: -10,
|
|
||||||
backgroundColor: "#f2f2f2",
|
|
||||||
borderTopLeftRadius: 400,
|
|
||||||
borderBottomRightRadius: 800,
|
|
||||||
|
|
||||||
}}></div>
|
|
||||||
<div style={{
|
|
||||||
position: "absolute",
|
|
||||||
width: "100%",
|
|
||||||
height: "100%",
|
|
||||||
zIndex: -11,
|
|
||||||
backgroundColor: "#346991",
|
|
||||||
}}></div>
|
|
||||||
</div>
|
|
||||||
<Login/>
|
<Login/>
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -4,6 +4,7 @@ import SemesterTile from "@/components/SemesterTile";
|
|||||||
import InputForm from "@/components/InputForm";
|
import InputForm from "@/components/InputForm";
|
||||||
import {useRouter} from "next/router";
|
import {useRouter} from "next/router";
|
||||||
import PopUp from "@/components/PopUp";
|
import PopUp from "@/components/PopUp";
|
||||||
|
import Background from "@/components/Background";
|
||||||
|
|
||||||
export default function SemesterOverview(p)
|
export default function SemesterOverview(p)
|
||||||
{
|
{
|
||||||
@@ -91,32 +92,7 @@ export default function SemesterOverview(p)
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<div className={"semester-overview"}>
|
<div className={"semester-overview"}>
|
||||||
<div style={{
|
<Background/>
|
||||||
position: "absolute",
|
|
||||||
width: "100%",
|
|
||||||
height: "100%",
|
|
||||||
overflow: "clip",
|
|
||||||
pointerEvents: "none"
|
|
||||||
}}>
|
|
||||||
<div style={{
|
|
||||||
position: "absolute",
|
|
||||||
transform: "skew(20deg)",
|
|
||||||
width: "100%",
|
|
||||||
height: "100%",
|
|
||||||
zIndex: -10,
|
|
||||||
backgroundColor: "#f2f2f2",
|
|
||||||
borderTopLeftRadius: 400,
|
|
||||||
borderBottomRightRadius: 800,
|
|
||||||
|
|
||||||
}}></div>
|
|
||||||
<div style={{
|
|
||||||
position: "absolute",
|
|
||||||
width: "100%",
|
|
||||||
height: "100%",
|
|
||||||
zIndex: -11,
|
|
||||||
backgroundColor: "#346991",
|
|
||||||
}}></div>
|
|
||||||
</div>
|
|
||||||
{
|
{
|
||||||
entries.map(e => (<SemesterTile text={e.name} onClick={(f) => onClickSemester(e, f)} onButtonDeleteClick={() => {
|
entries.map(e => (<SemesterTile text={e.name} onClick={(f) => onClickSemester(e, f)} onButtonDeleteClick={() => {
|
||||||
localStorage.setItem("currentsid", e.id)
|
localStorage.setItem("currentsid", e.id)
|
||||||
|
|||||||
@@ -354,16 +354,36 @@ input {
|
|||||||
|
|
||||||
.courseNameInput {
|
.courseNameInput {
|
||||||
width: 300px;
|
width: 300px;
|
||||||
|
padding: 5px;
|
||||||
|
border: none;
|
||||||
|
background-color: white;
|
||||||
|
border-radius: 5px;
|
||||||
|
font-family: Arial, serif;
|
||||||
|
}
|
||||||
|
|
||||||
|
.selector
|
||||||
|
{
|
||||||
|
border-width: 0;
|
||||||
|
border-radius: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.semesterDateInput {
|
.semesterDateInput {
|
||||||
width: 150px;
|
width: 150px;
|
||||||
|
padding: 5px;
|
||||||
|
border: none;
|
||||||
|
background-color: white;
|
||||||
|
border-radius: 5px;
|
||||||
|
font-family: Arial, serif;
|
||||||
}
|
}
|
||||||
|
|
||||||
.semesterDateLables, .semesterDateInputPair {
|
.semesterDateLables, .semesterDateInputPair {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
justify-content: left;
|
justify-content: left;
|
||||||
|
padding: 0;
|
||||||
|
border: none;
|
||||||
|
background-color: white;
|
||||||
|
border-radius: 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.inputFieldSeperator {
|
.inputFieldSeperator {
|
||||||
@@ -372,8 +392,7 @@ input {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.semesterDateLable {
|
.semesterDateLable {
|
||||||
width: 150px;
|
margin-right: 32px;
|
||||||
margin-right: 40px;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.semesterRangeInput {
|
.semesterRangeInput {
|
||||||
@@ -384,9 +403,11 @@ input {
|
|||||||
width: 600px;
|
width: 600px;
|
||||||
height: 600px;
|
height: 600px;
|
||||||
padding: 20px;
|
padding: 20px;
|
||||||
border: solid;
|
/*border: solid;*/
|
||||||
|
border-radius: 10px;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
background-color: white;
|
||||||
}
|
}
|
||||||
|
|
||||||
#buttons {
|
#buttons {
|
||||||
@@ -394,11 +415,12 @@ input {
|
|||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
align-items: flex-end;
|
align-items: flex-end;
|
||||||
|
gap: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dozentSelector {
|
.dozentSelector {
|
||||||
height: 350px;
|
height: 350px;
|
||||||
border: solid;
|
/*border: solid;*/
|
||||||
margin-top: 20px;
|
margin-top: 20px;
|
||||||
width: 500px;
|
width: 500px;
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
@@ -439,9 +461,8 @@ Login
|
|||||||
.input {
|
.input {
|
||||||
padding: 5px;
|
padding: 5px;
|
||||||
border: none;
|
border: none;
|
||||||
background-color: #e9e9e9;
|
background-color: white;
|
||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
font-family: Arial, serif;
|
|
||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Binary file not shown.
File diff suppressed because it is too large
Load Diff
@@ -27,6 +27,12 @@
|
|||||||
<artifactId>spring-boot-starter-test</artifactId>
|
<artifactId>spring-boot-starter-test</artifactId>
|
||||||
<scope>test</scope>
|
<scope>test</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.h2database</groupId>
|
||||||
|
<artifactId>h2</artifactId>
|
||||||
|
<version>2.1.214</version>
|
||||||
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
<build>
|
<build>
|
||||||
@@ -35,6 +41,27 @@
|
|||||||
<groupId>org.springframework.boot</groupId>
|
<groupId>org.springframework.boot</groupId>
|
||||||
<artifactId>spring-boot-maven-plugin</artifactId>
|
<artifactId>spring-boot-maven-plugin</artifactId>
|
||||||
</plugin>
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-install-plugin</artifactId>
|
||||||
|
<version>2.5.2</version>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<phase>validate</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>install-file</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<groupId>com.example</groupId>
|
||||||
|
<artifactId>example</artifactId>
|
||||||
|
<version>1.0</version>
|
||||||
|
<packaging>jar</packaging>
|
||||||
|
<file>${basedir}/H2JDBCDriver/h2-2.1.214.jar</file>
|
||||||
|
<generatePom>true</generatePom>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
</plugins>
|
</plugins>
|
||||||
</build>
|
</build>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user