Skip to content

Commit

Permalink
Listado por rol
Browse files Browse the repository at this point in the history
  • Loading branch information
Scot3004 committed Feb 18, 2023
1 parent c8c74aa commit 5145e1e
Show file tree
Hide file tree
Showing 8 changed files with 84 additions and 145 deletions.
17 changes: 17 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
root = true

[*]
charset = utf-8
end_of_line = lf
indent_size = 2
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true

[*.py]
indent_style = space
indent_size = 4

[{Dockerfile}]
indent_style = space
indent_size = 4
132 changes: 2 additions & 130 deletions content/nosotros/contents+en.lr
Original file line number Diff line number Diff line change
Expand Up @@ -57,64 +57,7 @@ title: Organizers
body:

##### members #####
body:

###### member ######
name: Javier Daza
------
photo: /img/team/javier-daza.jpg
------
role: Direction and Community
------
website_handle: https://javierdaza.co
------
email: [email protected]
------
github_handle: pyjavo
------
twitter_handle: pyjavo
###### member ######
name: Yuliana Martinez
------
photo: /img/team/yuliana-martinez.jpg
------
role: Public Relationships
------
website_handle:
------
email: [email protected]
------
github_handle: ycmartinezc
------
twitter_handle:
###### member ######
name: Sergio Orozco
------
photo: /img/team/sergio-orozco.jpg
------
role: Web developer
------
website_handle: https://www.secorto.com
------
email:
------
github_handle: scot3004
------
twitter_handle: scot3004
###### member ######
name: Fernando Llinás
------
photo: /img/team/fernando-llinas.jpeg
------
role: Logistics and Support
------
website_handle:
------
email: [email protected]
------
github_handle:
------
twitter_handle:
type: organizador
----
class: default
----
Expand All @@ -125,78 +68,7 @@ title: Collaborators
body:

##### members #####
body:

###### member ######
name: Andres Pérez
------
photo: /img/team/andres-perez.jpg
------
role: Translator and contributor
------
website_handle:
------
email: [email protected]
------
github_handle:
------
twitter_handle:
###### member ######
name: Javier Fonseca
------
photo: /img/team/javier-fonseca.jpg
------
role: Event venue
------
website_handle:
------
email: [email protected]
------
github_handle: fonsecajavier
------
twitter_handle:
###### member ######
name: Jorge Rueda
------
photo: /img/team/jorge-rueda.jpg
------
role: Web developer
------
website_handle:
------
email: [email protected]
------
github_handle: jorueda
------
twitter_handle:
###### member ######
name: Sergio Molinares
------
photo: /img/team/sergio-molinares.jpg
------
role: Social networks
------
website_handle:
------
email:
------
github_handle: Ardatx
------
twitter_handle: MolinaresSergio
###### member ######
name: Brayan García
------
photo: /img/team/brayan-garcia.jpg
------
role: Code contributor
------
website_handle:
------
email: [email protected]
------
github_handle:
------
twitter_handle:
type: colaborador
----
class: default
----
Expand Down
10 changes: 8 additions & 2 deletions content/nosotros/contents.lr
Original file line number Diff line number Diff line change
Expand Up @@ -63,15 +63,21 @@ body_class:
#### section-block ####
title: Organizadores
----
body:
body:

##### members #####
type: organizador
----
class: default
----
body_class:
#### section-block ####
title: Colaboradores
----
body:
body:

##### members #####
type: colaborador
----
class:
----
Expand Down
9 changes: 5 additions & 4 deletions flowblocks/members.ini
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
name = Miembros
button_label = [[ users ]]

[fields.body]
label = Body
type = flow
flow_blocks = member
[fields.type]
label = Rol
type = select
choices = organizador,colaborador

7 changes: 6 additions & 1 deletion models/nosotros-miembro.ini
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,13 @@ type = text
label = Foto
type = string

[fields.role]
[fields.type]
label = Rol
type = select
choices = organizador,colaborador

[fields.role]
label = Funciones
type = text

[fields.website_handle]
Expand Down
16 changes: 8 additions & 8 deletions templates/blocks/members.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<div class="members">
<div class="row d-flex justify-content-center">
{% for blk in this.body.blocks %}
<div class="block block-{{ blk._flowblock }} col-sm-4">
{{ blk }}
</div>
{% endfor %}
</div>
{% from "macros/miembros.html" import render_miembro %}

<div class="members row d-flex justify-content-center">
{% for member in site.query('/nosotros').filter(F.type == this.type) %}
<div class="member col-sm-4">
{{render_miembro(member)}}
</div>
{% endfor %}
</div>
33 changes: 33 additions & 0 deletions templates/macros/miembros.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
{% macro render_miembro(miembro) %}
<div class="card text-center mb-3">
<img src="{{ miembro.photo }}" class="card-img-top" alt="{{miembro.name}}">
<div class="card-body">
<h3 class="card-title"><a href="{{ miembro|url }}">{{ miembro.name }}</a></h3>
<p class="card-text">{{ miembro.role }}</p>
<div data-animate="fadeIn">
{% if miembro.website_handle.url %}
<a href="{{ miembro.website_handle }}" class="member-button"><i class="fa fa-external-link"></i></a>
{% endif %}
{% if miembro.email %}
<a href="mailto:{{ miembro.email }}" class="member-button"><i class="fa fa-envelope"></i></a>
{% endif %}
{% if miembro.github_handle %}
<a href="https://github.com/{{miembro.github_handle}}" class="member-button"><i class="fa fa-github"></i></a>
{% endif %}
{% if miembro.twitter_handle %}
<a href="https://twitter.com/{{miembro.twitter_handle}}" class="member-button"><i class="fa fa-twitter"></i></a>
{% endif %}
</div>
</div>
</div>
{% endmacro %}

{% macro render_miembros_list(miembros) %}
<div class="members row d-flex justify-content-center">
{% for member in site.query('/nosotros').filter(F.type == "colaborador") %}
<div class="member col-sm-4">
{{render_miembro(member)}}
</div>
{% endfor %}
</div>
{% endmacro %}
5 changes: 5 additions & 0 deletions templates/nosotros.html
Original file line number Diff line number Diff line change
@@ -1 +1,6 @@
{% extends "page.html" %}
{% from "macros/miembros.html" import render_miembros_list %}

{% block after_body %}
{{ render_miembros_list(this.children) }}
{% endblock %}

0 comments on commit 5145e1e

Please sign in to comment.