commit ea96d567ffebd8de0f36fc45bdbb3dab0885d516 Author: Juanjo Date: Mon Jan 23 17:03:05 2023 +0100 commit1 diff --git a/.idea/alejandro-prueba.iml b/.idea/alejandro-prueba.iml new file mode 100644 index 0000000..e74288d --- /dev/null +++ b/.idea/alejandro-prueba.iml @@ -0,0 +1,122 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/main/java/com/example/demo/models/Act.java b/src/main/java/com/example/demo/models/Act.java new file mode 100644 index 0000000..35b60d8 --- /dev/null +++ b/src/main/java/com/example/demo/models/Act.java @@ -0,0 +1,7 @@ +package com.example.demo.models; + +public class Act { + + public Act(){} + +} diff --git a/src/main/java/com/example/demo/models/Actor.java b/src/main/java/com/example/demo/models/Actor.java new file mode 100644 index 0000000..d529a45 --- /dev/null +++ b/src/main/java/com/example/demo/models/Actor.java @@ -0,0 +1,54 @@ +package com.example.demo.models; + +import java.util.Objects; + +public class Actor { + + private long id; + private String name; + + public Actor(){} + + public Actor(long id, String name) { + this.id = id; + this.name = name; + } + + public long getId() { + return id; + } + + public void setId(long id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + Actor actor = (Actor) o; + return id == actor.id && Objects.equals(name, actor.name); + } + + @Override + public int hashCode() { + return Objects.hash(id, name); + } + + @Override + public String toString() { + return "Actor{" + + "id=" + id + + ", name='" + name + '\'' + + '}'; + } + +} diff --git a/src/main/resources/application.properties b/src/main/resources/application.properties new file mode 100644 index 0000000..25c000c --- /dev/null +++ b/src/main/resources/application.properties @@ -0,0 +1,17 @@ +server.port=9000 +spring.thymeleaf.cache=false +#logging.level.org.springframework.web=TRACE +#logging.level.org.springframework.security=TRACE + +#spring.session.store-type=redis +# Session timeout. If a duration suffix is not specified, seconds is used. +server.servlet.session.timeout=60s +# Sessions flush mode. +spring.session.redis.flush-mode=on_save +# Namespace for keys used to store sessions. +spring.session.redis.namespace=spring:session +spring.redis.port=6379 +spring.redis.host=localhost + +spring.security.user.name=jandro +spring.security.user.password=1234 \ No newline at end of file diff --git a/src/main/resources/banner.txt b/src/main/resources/banner.txt new file mode 100644 index 0000000..885c0d4 --- /dev/null +++ b/src/main/resources/banner.txt @@ -0,0 +1 @@ +Iniciando... \ No newline at end of file diff --git a/src/main/resources/resources/js/adminlogin.js b/src/main/resources/resources/js/adminlogin.js new file mode 100644 index 0000000..df74e4e --- /dev/null +++ b/src/main/resources/resources/js/adminlogin.js @@ -0,0 +1,19 @@ +function toggleResetPswd(e){ + e.preventDefault(); + $('#logreg-forms .form-signin').toggle() // display:block or none + $('#logreg-forms .form-reset').toggle() // display:block or none +} + +function toggleSignUp(e){ + e.preventDefault(); + $('#logreg-forms .form-signin').toggle(); // display:block or none + $('#logreg-forms .form-signup').toggle(); // display:block or none +} + +$(()=>{ + // Login Register Form + $('#logreg-forms #forgot_pswd').click(toggleResetPswd); + $('#logreg-forms #cancel_reset').click(toggleResetPswd); + $('#logreg-forms #btn-signup').click(toggleSignUp); + $('#logreg-forms #cancel_signup').click(toggleSignUp); +}) \ No newline at end of file diff --git a/src/main/resources/static/css/adminlogin.css b/src/main/resources/static/css/adminlogin.css new file mode 100644 index 0000000..8e4c286 --- /dev/null +++ b/src/main/resources/static/css/adminlogin.css @@ -0,0 +1,172 @@ +/* +--Paleta de colores ++white: #f9f9f9ff ++black: #1a1a1aff ++red: #ff2a2aff +*/ + +div.main{ + background: #0264d6; /* Old browsers */ + background: -moz-radial-gradient(center, ellipse cover, #0264d6 1%, #1c2b5a 100%); /* FF3.6+ */ + background: -webkit-gradient(radial, center center, 0px, center center, 100%, color-stop(1%,#0264d6), color-stop(100%,#1c2b5a)); /* Chrome,Safari4+ */ + background: -webkit-radial-gradient(center, ellipse cover, #0264d6 1%,#1c2b5a 100%); /* Chrome10+,Safari5.1+ */ + background: -o-radial-gradient(center, ellipse cover, #0264d6 1%,#1c2b5a 100%); /* Opera 12+ */ + background: -ms-radial-gradient(center, ellipse cover, #0264d6 1%,#1c2b5a 100%); /* IE10+ */ + background: radial-gradient(ellipse at center, #0264d6 1%,#1c2b5a 100%); /* W3C */ + filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#0264d6', endColorstr='#1c2b5a',GradientType=1 ); /* IE6-9 fallback on horizontal gradient */ + height:calc(100vh); + width:100%; +} + +[class*="fontawesome-"]:before { + font-family: 'FontAwesome', sans-serif; +} + +/* ---------- GENERAL ---------- */ + +* { + box-sizing: border-box; + margin:0px auto; + + &:before, + &:after { + box-sizing: border-box; + } + +} + +body { + + color: #f9f9f9ff; + font: 87.5%/1.5em 'Open Sans', sans-serif; + margin: 0; +} + +a { + color: #eee; + text-decoration: none; +} + +a:hover { + text-decoration: underline; +} + +input { + border: none; + font-family: 'Open Sans', Arial, sans-serif; + font-size: 14px; + line-height: 1.5em; + padding: 0; + -webkit-appearance: none; +} + +p { + line-height: 1.5em; +} + +.clearfix { + *zoom: 1; + + &:before, + &:after { + content: ' '; + display: table; + } + + &:after { + clear: both; + } + +} + +.container + .section_title { + left: 50%; + position: fixed; + top: 50%; + transform: translate(-50%, -50%); +} + +.section_title { + text-align: center; + margin: 5%; +} + +/* ---------- LOGIN ---------- */ + +#login form{ + width: 250px; +} +#login, .logo{ + display:inline-block; + width:40%; +} +#login{ +border-right:1px solid #fff; + padding: 0px 22px; + width: 59%; +} +.logo{ +color:#fff; +font-size:50px; + line-height: 125px; +} + +#login form span.fa { + background-color: #fff; + border-radius: 3px 0px 0px 3px; + color: #000; + display: block; + float: left; + height: 50px; + font-size:24px; + line-height: 50px; + text-align: center; + width: 50px; +} + +#login form input { + height: 50px; +} +fieldset{ + padding:0; + border:0; + margin: 0; + +} +#login form input[type="text"], input[type="password"] { + background-color: #fff; + border-radius: 0px 3px 3px 0px; + color: #000; + margin-bottom: 1em; + padding: 0 16px; + width: 200px; +} + +#login form input[type="submit"] { + border-radius: 3px; + -moz-border-radius: 3px; + -webkit-border-radius: 3px; + background-color: #000000; + color: #eee; + font-weight: bold; + /* margin-bottom: 2em; */ + text-transform: uppercase; + padding: 5px 10px; + height: 30px; +} + +#login form input[type="submit"]:hover { + background-color: #d44179; +} + +#login > p { + text-align: center; +} + +#login > p span { + padding-left: 5px; +} +.middle { + display: flex; + width: 600px; +} \ No newline at end of file