Compare commits
No commits in common. "fb5675eebd94362885b9f2385ddddee0b428dd3a" and "ca25e3bcf8a301c90d573a589b53f076448b5ebf" have entirely different histories.
fb5675eebd
...
ca25e3bcf8
4 changed files with 5 additions and 3 deletions
|
@ -10,8 +10,6 @@ function InputField(props) {
|
|||
onChange={props.onChange}
|
||||
type={props.InputType}
|
||||
placeholder={props.InputPlaceHolder}
|
||||
onCopy={props.onCopy}
|
||||
onPaste={props.onPaste}
|
||||
/>
|
||||
</label>
|
||||
);
|
||||
|
|
|
@ -13,6 +13,7 @@ export default function Login() {
|
|||
const [username, setUsername] = useState("");
|
||||
const [password, setPassword] = useState("");
|
||||
|
||||
const [message, setMessage] = useState("");
|
||||
const [errorMessage, setErrorMessage] = useState("");
|
||||
|
||||
const [isStatusOk, setIsStatusOk] = useState("");
|
||||
|
@ -39,6 +40,7 @@ export default function Login() {
|
|||
});
|
||||
} else if (response.status === 200) {
|
||||
response.json().then((resp) => {
|
||||
setMessage(resp.message);
|
||||
fetch("/api/login", {
|
||||
method: "post",
|
||||
body: JSON.stringify(opts),
|
||||
|
|
|
@ -24,6 +24,7 @@ export default function Umfrage() {
|
|||
const [skillsErrorMessage, setSkillsErrorMessage] = useState("");
|
||||
|
||||
const [backendErrorMessage, setBackendErrorMessage] = useState("");
|
||||
const [backendSuccessMessage, setBackendSuccessMessage] = useState("");
|
||||
const [isSurveyValidBackend, setIsSurveyValidBackend] = useState("");
|
||||
|
||||
/* boolean if the values are ok */
|
||||
|
@ -84,6 +85,7 @@ export default function Umfrage() {
|
|||
}).then((response) => {
|
||||
if (response.status === 200) {
|
||||
response.json().then((r) => {
|
||||
setBackendSuccessMessage(r.message);
|
||||
setIsSurveyValidBackend(true);
|
||||
});
|
||||
} else {
|
||||
|
|
Loading…
Reference in a new issue