You've already forked isop-mirror
login & reset hesla
This commit is contained in:
@@ -1,23 +1,109 @@
|
|||||||
<template>
|
<template>
|
||||||
|
<div class="page-container form-wrap">
|
||||||
|
<h2 class="page-title">Prihlásenie</h2>
|
||||||
|
|
||||||
<v-row class="pc" align="stretch" justify="start">
|
<v-form v-model="isValid" @submit.prevent="onSubmit">
|
||||||
<PageCard
|
<v-text-field
|
||||||
title="Registrácia študenta"
|
v-model="form.email"
|
||||||
description="Zaregistruj sa a začni svoju odbornú prax."
|
:rules="[rules.required, rules.email]"
|
||||||
link="/registerStudent"
|
label="Email:"
|
||||||
icon="mdi mdi-account"
|
variant="outlined"
|
||||||
/>
|
density="comfortable"
|
||||||
<PageCard
|
/>
|
||||||
title="Registrácia firmy"
|
|
||||||
description="Staň sa partnerskou firmou a pomôž študentom získať prax vo svojom odbore."
|
<v-text-field
|
||||||
link="/registerCompany"
|
v-model="form.password"
|
||||||
icon="mdi mdi-office-building"
|
:rules="[rules.required]"
|
||||||
/>
|
:type="showPassword ? 'text' : 'password'"
|
||||||
</v-row>
|
label="Heslo:"
|
||||||
|
variant="outlined"
|
||||||
|
density="comfortable"
|
||||||
|
:append-inner-icon="showPassword ? 'mdi-eye-off-outline' : 'mdi-eye-outline'"
|
||||||
|
@click:append-inner="showPassword = !showPassword"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<div class="actions-row">
|
||||||
|
<v-spacer />
|
||||||
|
<v-btn
|
||||||
|
type="button"
|
||||||
|
variant="tonal"
|
||||||
|
color="success"
|
||||||
|
size="small"
|
||||||
|
class="forgot-btn"
|
||||||
|
dense to="/reset_psw"
|
||||||
|
>
|
||||||
|
Zabudnuté heslo...
|
||||||
|
</v-btn>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<v-btn
|
||||||
|
type="submit"
|
||||||
|
color="success"
|
||||||
|
size="large"
|
||||||
|
block
|
||||||
|
:disabled="!isValid"
|
||||||
|
>
|
||||||
|
Prihlásiť
|
||||||
|
</v-btn>
|
||||||
|
</v-form>
|
||||||
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style scoped>
|
<script setup>
|
||||||
.pc {
|
import { reactive, ref } from 'vue'
|
||||||
margin: 0 0 24px 0;
|
|
||||||
|
const isValid = ref(false)
|
||||||
|
const showPassword = ref(false)
|
||||||
|
|
||||||
|
const form = reactive({
|
||||||
|
email: '',
|
||||||
|
password: '',
|
||||||
|
})
|
||||||
|
|
||||||
|
const rules = {
|
||||||
|
required: v => (!!v && String(v).trim().length > 0) || 'Povinné pole',
|
||||||
|
email: v => /.+@.+\..+/.test(v) || 'Zadajte platný email',
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function onSubmit() {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
function onForgot() {
|
||||||
|
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.page-container {
|
||||||
|
max-width: 1120px;
|
||||||
|
margin: 0 auto;
|
||||||
|
padding-left: 24px;
|
||||||
|
padding-right: 24px;
|
||||||
|
}
|
||||||
|
.form-wrap {
|
||||||
|
max-width: 640px;
|
||||||
|
}
|
||||||
|
.page-title {
|
||||||
|
font-size: 24px;
|
||||||
|
line-height: 1.2;
|
||||||
|
font-weight: 700;
|
||||||
|
margin: 24px 0 16px;
|
||||||
|
color: #1f1f1f;
|
||||||
|
}
|
||||||
|
|
||||||
|
.actions-row {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
margin-bottom: 20px;
|
||||||
|
}
|
||||||
|
.forgot-btn {
|
||||||
|
text-transform: none;
|
||||||
|
font-weight: 600;
|
||||||
|
border-radius: 999px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mb-1 { margin-bottom: 6px; }
|
||||||
|
.mb-2 { margin-bottom: 10px; }
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
|
|||||||
@@ -8,14 +8,14 @@
|
|||||||
:rules="[rules.required]"
|
:rules="[rules.required]"
|
||||||
label="Názov firmy:"
|
label="Názov firmy:"
|
||||||
variant="outlined"
|
variant="outlined"
|
||||||
density="compact"
|
density="comfortable"
|
||||||
/>
|
/>
|
||||||
<v-text-field
|
<v-text-field
|
||||||
v-model="form.companyAddress"
|
v-model="form.companyAddress"
|
||||||
:rules="[rules.required]"
|
:rules="[rules.required]"
|
||||||
label="Adresa:"
|
label="Adresa:"
|
||||||
variant="outlined"
|
variant="outlined"
|
||||||
density="compact"
|
density="comfortable"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<h4 class="section-heading mt-4">Kontaktná osoba</h4>
|
<h4 class="section-heading mt-4">Kontaktná osoba</h4>
|
||||||
@@ -25,28 +25,28 @@
|
|||||||
:rules="[rules.required]"
|
:rules="[rules.required]"
|
||||||
label="Meno:"
|
label="Meno:"
|
||||||
variant="outlined"
|
variant="outlined"
|
||||||
density="compact"
|
density="comfortable"
|
||||||
/>
|
/>
|
||||||
<v-text-field
|
<v-text-field
|
||||||
v-model="form.contactEmail"
|
v-model="form.contactEmail"
|
||||||
:rules="[rules.required, rules.email]"
|
:rules="[rules.required, rules.email]"
|
||||||
label="Email:"
|
label="Email:"
|
||||||
variant="outlined"
|
variant="outlined"
|
||||||
density="compact"
|
density="comfortable"
|
||||||
/>
|
/>
|
||||||
<v-text-field
|
<v-text-field
|
||||||
v-model="form.contactPhone"
|
v-model="form.contactPhone"
|
||||||
:rules="[rules.phone]"
|
:rules="[rules.phone]"
|
||||||
label="Telefón:"
|
label="Telefón:"
|
||||||
variant="outlined"
|
variant="outlined"
|
||||||
density="compact"
|
density="comfortable"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<v-checkbox
|
<v-checkbox
|
||||||
v-model="form.consent"
|
v-model="form.consent"
|
||||||
:rules="[rules.mustAgree]"
|
:rules="[rules.mustAgree]"
|
||||||
label="Súhlasím s podmienkami spracúvania osobných údajov"
|
label="Súhlasím s podmienkami spracúvania osobných údajov"
|
||||||
density="compact"
|
density="comfortable"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<v-btn
|
<v-btn
|
||||||
|
|||||||
68
frontend/app/pages/reset_psw.vue
Normal file
68
frontend/app/pages/reset_psw.vue
Normal file
@@ -0,0 +1,68 @@
|
|||||||
|
<template>
|
||||||
|
<div class="page-container form-wrap">
|
||||||
|
<h2 class="page-title">Reset hesla</h2>
|
||||||
|
|
||||||
|
<v-form v-model="isValid" @submit.prevent="onSubmit">
|
||||||
|
<v-text-field
|
||||||
|
v-model="email"
|
||||||
|
:rules="[rules.required, rules.email]"
|
||||||
|
label="Email:"
|
||||||
|
variant="outlined"
|
||||||
|
density="comfortable"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<v-btn
|
||||||
|
type="submit"
|
||||||
|
color="success"
|
||||||
|
size="large"
|
||||||
|
block
|
||||||
|
:disabled="!isValid"
|
||||||
|
>
|
||||||
|
Odoslať Email
|
||||||
|
</v-btn>
|
||||||
|
</v-form>
|
||||||
|
|
||||||
|
<v-snackbar v-model="snackbar" timeout="2500">
|
||||||
|
Odoslané na mail
|
||||||
|
</v-snackbar>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup>
|
||||||
|
import { ref } from 'vue'
|
||||||
|
|
||||||
|
const isValid = ref(false)
|
||||||
|
const email = ref('')
|
||||||
|
const snackbar = ref(false)
|
||||||
|
|
||||||
|
const rules = {
|
||||||
|
required: v => (!!v && String(v).trim().length > 0) || 'Povinné pole',
|
||||||
|
email: v => /.+@.+\..+/.test(v) || 'Zadajte platný email',
|
||||||
|
}
|
||||||
|
|
||||||
|
function onSubmit() {
|
||||||
|
snackbar.value = true
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.page-container {
|
||||||
|
max-width: 1120px;
|
||||||
|
margin: 0 auto;
|
||||||
|
padding-left: 24px;
|
||||||
|
padding-right: 24px;
|
||||||
|
}
|
||||||
|
.form-wrap {
|
||||||
|
max-width: 560px;
|
||||||
|
}
|
||||||
|
.page-title {
|
||||||
|
font-size: 24px;
|
||||||
|
line-height: 1.2;
|
||||||
|
font-weight: 700;
|
||||||
|
margin: 24px 0 16px;
|
||||||
|
color: #1f1f1f;
|
||||||
|
}
|
||||||
|
.mb-3 { margin-bottom: 12px; }
|
||||||
|
</style>
|
||||||
|
|
||||||
|
|
||||||
Reference in New Issue
Block a user