diff --git a/.gitignore b/.gitignore index 5d381cc..7278560 100644 --- a/.gitignore +++ b/.gitignore @@ -21,6 +21,7 @@ parts/ sdist/ var/ wheels/ +uploads/* share/python-wheels/ *.egg-info/ .installed.cfg diff --git a/app.py b/app.py index fd2f1a5..8505bd4 100644 --- a/app.py +++ b/app.py @@ -45,7 +45,8 @@ def create_app(): description = StringField('Description', validators=[DataRequired()]) photo = FileField('Evidencia fotogénica', validators=[DataRequired()]) timedate = DateTimeField(default=datetime.now()) - typeofpin = SelectField('Tipo de cosa', choices=['bache', 'coladera', 'obra sin terminar', 'escombro', 'robo-asalto']) + typeofpin = SelectField('Tipo de cosa', choices=['bache', 'coladera', 'obra sin terminar', 'escombro', 'robo-asalto', 'biciestacionamiento', 'mala iluminación']) + submit = SubmitField('Agregar') class LoginForm(FlaskForm): @@ -111,6 +112,10 @@ def create_app(): #else: # flash('Invalid file type. Only images are allowed.') #return render_template('index.html', form=form) + @app.route('/quienes') + def quienes(): + return render_template('quienes.html') + @app.route('/uploads/') def download_file(name): return send_from_directory(app.config["UPLOAD_FOLDER"], name) @@ -154,14 +159,14 @@ def create_app(): login_user(user) return redirect(url_for('dashboard')) else: - return render_template('login.html', messages = 'Ooops, no hay tal usuario') + return render_template('login.html', messages = 'Ooops, no hay tal usuario', form=form2) return render_template('login.html',form=form2) @app.route('/logout') @login_required def logout(): logout_user() - flash('You have successfully logged yourself out.') + flash('Cerraste sesión exitosamente') return redirect('/') @app.route('/desheredame/') diff --git a/requirements.txt b/requirements.txt index 8db452b..bd68d2c 100644 --- a/requirements.txt +++ b/requirements.txt @@ -2,12 +2,15 @@ blinker==1.8.1 click==8.1.7 dnspython==2.6.1 Flask==3.0.3 +Flask-Login==0.6.3 Flask-PyMongo==2.3.0 Flask-WTF==1.2.1 itsdangerous==2.2.0 Jinja2==3.1.3 leaflet==0.0.3 MarkupSafe==2.1.5 -pymongo==4.7.1 +pymongo==4.8.0 +python-dateutil==2.9.0.post0 +six==1.16.0 Werkzeug==3.0.2 WTForms==3.1.2 diff --git a/static/images/ramos.jpg b/static/images/ramos.jpg new file mode 100644 index 0000000..1410209 Binary files /dev/null and b/static/images/ramos.jpg differ diff --git a/static/style.css b/static/style.css index 705bcda..b1a6a51 100644 --- a/static/style.css +++ b/static/style.css @@ -1,5 +1,57 @@ -body {padding: 0;margin: 0;}html, body, #map {height: 100%;width: 100vw;} -div.leaflet-popup-content { - width: 400px; +@font-face { + font-family: 'icomoon'; + src: url('fonts/icomoon.eot?z8tny2'); + src: url('fonts/icomoon.eot?z8tny2#iefix') format('embedded-opentype'), + url('fonts/icomoon.ttf?z8tny2') format('truetype'), + url('fonts/icomoon.woff?z8tny2') format('woff'), + url('fonts/icomoon.svg?z8tny2#icomoon') format('svg'); + font-weight: normal; + font-style: normal; + font-display: block; } +[class^="icon-"], [class*=" icon-"] { + /* use !important to prevent issues with browser extensions that change fonts */ + font-family: 'icomoon' !important; + speak: never; + font-style: normal; + font-weight: normal; + font-variant: normal; + text-transform: none; + line-height: 1; + + /* Better Font Rendering =========== */ + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; +} + +.icon-lightbulb:before { + content: "\e900"; +} +.icon-construction:before { + content: "\e901"; +} +.icon-home3:before { + content: "\e902"; +} +.icon-download:before { + content: "\e960"; +} +.icon-hour-glass:before { + content: "\e979"; +} +.icon-fire:before { + content: "\e9a9"; +} +.icon-bin:before { + content: "\e9ac"; +} +.icon-target:before { + content: "\e9b3"; +} +.icon-sun:before { + content: "\e9d4"; +} +.icon-contrast:before { + content: "\e9d5"; +} diff --git a/static/styles.css b/static/styles.css index ae7adad..005bbc0 100644 --- a/static/styles.css +++ b/static/styles.css @@ -1,20 +1,22 @@ -body { +body, html { font-family: Arial, sans-serif; margin: 0; padding: 0px; overflow: hidden; + height: 100%; } h1 { text-align: center; } -form { +div#pinner-modal form { max-width: 400px; margin: 0 auto; padding: 20px; border: 1px solid #ccc; border-radius: 5px; + background-color: rgb(205, 243, 148, 0.7); } form p { @@ -25,6 +27,7 @@ form p { width: 100%; height: 100vh; margin: 0 0; + position: relative; } main { @@ -54,4 +57,32 @@ div.pinner-modal { div.pinner-modal.active { bottom: 0; + background-color: rgb(205, 243, 148, 0.7); +} + +div.pinner-modal form { + background-color: rgb(205, 243, 148, 0.7); +} + +nav { + position:absolute; + top:0; + left: 0; + right: 0; + background-color: rgba(205, 243, 148, 0.7); + padding: 5px; + z-index: 1000; + color:azure; +} + + +.leaflet-marker-icon { + background-color: transparent !important; + border: rgba(0, 0, 0, 0); +} + +.fa, .far, .fas { + color:rgb(0, 0, 0); + text-shadow: -1px 0 rgb(255, 136, 0), 0 1px rgb(255, 136, 0), 1px 0 rgb(255, 136, 0), 0 -1px rgb(255, 136, 0); + font-size: larger; } \ No newline at end of file diff --git a/templates/base.html b/templates/base.html index d47b3e1..ad8ee4f 100644 --- a/templates/base.html +++ b/templates/base.html @@ -11,6 +11,8 @@ + + @@ -19,20 +21,26 @@ - -