Adding missing controller.

This commit is contained in:
sergiotarxz 2022-01-14 20:57:35 +01:00
parent a549732ce7
commit 45386ebd75
Signed by: sergiotarxz
GPG Key ID: E5903508B6510AC2
2 changed files with 16 additions and 19 deletions

16
lib/BeastBB/Controller.pm Normal file
View File

@ -0,0 +1,16 @@
package BeastBB::Controller;
use 5.30.3;
use strict;
use warnings;
use Mojo::Base 'Mojolicious::Controller';
sub new {
my $class = shift;
my $self = $class->SUPER::new(@_);
$self->session( expiration => 3600 );
return $self;
}
1;

View File

@ -1,19 +0,0 @@
window.addEventListener( 'load', (event) => {
load();
});
function load() {
let postgres_password_change_readbility = document.querySelector('#change_readable_password');
postgres_password_change_readbility.addEventListener('click', (event) => {
change_readbility_password();
});
}
function change_readbility_password() {
let postgres_password = document.querySelector('#postgres_password');
if ( postgres_password.type === 'password' ) {
postgres_password.type = 'text';
} else {
postgres_password.type = 'password';
}
}