1
0
mirror of https://github.com/robonen/metr.git synced 2026-03-20 02:44:42 +00:00

5 Commits
v0.1 ... master

Author SHA1 Message Date
f8758a9b56 Update README.md 2022-06-24 01:48:25 +07:00
4e39df490a User authentication fix 2022-06-07 15:06:57 +07:00
9e1b0b5da1 Merge pull request #17 from robonen/Frontend_1.0_fixed
Frontend 1.0 fixed
2022-06-06 18:37:29 +07:00
dabimarie
2496867d21 Add PasswordAccept 2022-06-06 18:35:12 +07:00
dabimarie
c887a05c0b Add RecoveryNewPassword 2022-06-06 18:33:51 +07:00
6 changed files with 73 additions and 7 deletions

View File

@@ -1,18 +1,13 @@
# Metr # Metr
<p align="center"> <p align="center">
<a href="https://forma-web.ru">
<img alt="Logo" src="metr/logo.svg" width="300" title="Logo"> <img alt="Logo" src="metr/logo.svg" width="300" title="Logo">
</a>
</p> </p>
<p align="center"> <p align="center">
<a href="https://github.com/robonen/metr-frontend/actions"> <a href="https://github.com/robonen/metr-frontend/actions">
<img src="https://github.com/robonen/metr-frontend/actions/workflows/release.yml/badge.svg" title="Release status"> <img src="https://github.com/robonen/metr-frontend/actions/workflows/release.yml/badge.svg" title="Release status">
</a> </a>
<a href="https://github.com/robonen/metr-frontend/actions">
<img src="https://github.com/robonen/metr-frontend/actions/workflows/test.yml/badge.svg" title="Lint status">
</a>
<a href="https://github.com/robonen/metr-frontend/releases"> <a href="https://github.com/robonen/metr-frontend/releases">
<img src="https://img.shields.io/github/v/release/robonen/metr-frontend?display_name=tag&label=Last%20Version&color=brightgreen" title="Last version"> <img src="https://img.shields.io/github/v/release/robonen/metr-frontend?display_name=tag&label=Last%20Version&color=brightgreen" title="Last version">
</a> </a>

View File

@@ -144,13 +144,17 @@ export default {
} }
}, },
async mounted() { async mounted() {
if (this.$store.getters.userAuthenticated) {
this.$router.push('/profile');
return;
}
await this.addSearchParam(this.$route.query); await this.addSearchParam(this.$route.query);
}, },
watch: { watch: {
'$route.query'(value) { '$route.query'(value) {
this.addSearchParam(value); this.addSearchParam(value);
} }
} },
} }
</script> </script>

View File

@@ -150,6 +150,11 @@ export default {
} }
}, },
async mounted() { async mounted() {
if (this.$store.getters.userAuthenticated) {
this.$router.push('/profile');
return;
}
const id = this.$route.params.id; const id = this.$route.params.id;
if (id === undefined) if (id === undefined)

View File

@@ -81,6 +81,12 @@ export default {
}); });
} }
}, },
mounted() {
if (this.$store.getters.userAuthenticated) {
this.$router.push('/profile');
return;
}
}
} }
</script>> </script>>

View File

@@ -0,0 +1,30 @@
<template>
<div class="container">
<div class="logo">
<div class="logoMetr">
</div>
</div>
<div class="title">
<h2>Восстановление пароля</h2>
</div>
<form action="" method="get" class="form__example">
<div class="form__example">
<label for="name"></label>
<input class="login" type="text" name="name" id="name" placeholder="Новый пароль" required>
</div>
<div class="form__example">
<label for="email"></label>
<input class="login" type="email" name="email" id="email" placeholder="Подтвердите пароль" required>
</div>
<div class="form__example">
<input class="form__input" type="submit" value="Сохранить пароль">
</div>
</form>
</div>
</template>
<script>
</script>
<style scoped>
</style>

View File

@@ -0,0 +1,26 @@
<template>
<div class="container">
<div class="logo">
<div class="logoMetr">
</div>
</div>
<div class="title">
<h2>Восстановление пароля</h2>
</div>
<form action="" method="get" class="form__example">
<div class="form__example">
<label for="name"></label>
<input class="login" type="text" name="name" id="name" placeholder="Введите код подтверждения" required>
</div>
<div class="form__example">
<input class="form__input" type="submit" value="Принять">
</div>
</form>
</div>
</template>
<script>
</script>
<style scoped>
</style>