Refactoring and removing unused things
This commit is contained in:
parent
959912bd9b
commit
e7407fd40b
2 changed files with 1 additions and 27 deletions
|
@ -134,7 +134,6 @@ def protected():
|
||||||
|
|
||||||
|
|
||||||
@app.route('/api/protected/rcv_pw', methods=['GET'])
|
@app.route('/api/protected/rcv_pw', methods=['GET'])
|
||||||
# @flask_praetorian.auth_required
|
|
||||||
def get_password():
|
def get_password():
|
||||||
pw = get_random_password()
|
pw = get_random_password()
|
||||||
ret = {'password': pw}
|
ret = {'password': pw}
|
||||||
|
|
|
@ -68,7 +68,6 @@ export default function Study() {
|
||||||
setIsStepStart(false);
|
setIsStepStart(false);
|
||||||
setIsStepNormal(true);
|
setIsStepNormal(true);
|
||||||
handleLoggerOn();
|
handleLoggerOn();
|
||||||
// forceUpdate();
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const handleClickAtStepNormal = () => {
|
const handleClickAtStepNormal = () => {
|
||||||
|
@ -87,30 +86,6 @@ export default function Study() {
|
||||||
handleLoggerOff();
|
handleLoggerOff();
|
||||||
};
|
};
|
||||||
|
|
||||||
const onSubmitClick = (e) => {
|
|
||||||
e.preventDefault();
|
|
||||||
let opts = {
|
|
||||||
username: username,
|
|
||||||
password: password,
|
|
||||||
};
|
|
||||||
fetch("/api/protected/behavior", {
|
|
||||||
method: "post",
|
|
||||||
body: JSON.stringify(opts),
|
|
||||||
}).then((response) => {
|
|
||||||
console.log(response.status);
|
|
||||||
if (response.status === 401) {
|
|
||||||
response.json().then((resp) => {
|
|
||||||
console.log("nicht so wirklich gut");
|
|
||||||
// setErrorMessage(resp.message);
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
response.json().then((token) => {
|
|
||||||
console.log("Alles gut :-)");
|
|
||||||
});
|
|
||||||
}
|
|
||||||
});
|
|
||||||
};
|
|
||||||
|
|
||||||
const study_start = (
|
const study_start = (
|
||||||
<>
|
<>
|
||||||
<BehaviorStudyInfo />
|
<BehaviorStudyInfo />
|
||||||
|
@ -189,7 +164,7 @@ export default function Study() {
|
||||||
const study_standing = (
|
const study_standing = (
|
||||||
<>
|
<>
|
||||||
<BehaviorStanding />
|
<BehaviorStanding />
|
||||||
<form id="behaviorPhone">
|
<form id="behaviorStanding">
|
||||||
<InputField
|
<InputField
|
||||||
LabelName="Benutzername"
|
LabelName="Benutzername"
|
||||||
onChange={handleUsernameChange}
|
onChange={handleUsernameChange}
|
||||||
|
|
Loading…
Reference in a new issue