Commit 5fd1c7da authored by Georgios Tsakalos's avatar Georgios Tsakalos

add software template

parent b5a21c53
{% extends "schools/index.twig" %}
{% import "schools/index.twig" as macros %}
{% block schoolTitle %}
{{ parent() }} <small>Λογισμικό</small>
{% endblock %}
{% block navItems %}
<li role="presentation" class="pull-right">
<a href="#" class="btn btn-primary btn-add-software" title="Καταχώρηση λογισμικού">
<i class="visible-xs fa fa-plus"></i>
<span class="hidden-xs">Καταχώρηση λογισμικού</span>
{% endblock %}
{% block schoolContent %}
<div id="school-software">
<div class="table-responsive">
<table class="table table-hover table-striped">
{% for software in softwareArray %}
<tr data-software="{{ software|json_encode }}" data-id="{{ }}">
<td class="title">{{ software.title }}</td>
<td class="category">{{ software.softwarecategory }}</td>
<td class="vendor">{{ software.vendor}}</td>
<td class="url">{{ software.url }}</td>
<td class="lab">{{ software.lab }}</td>
{% else %}
<tr class="no-records">
<td colspan="6" class="text-center text-muted">
Δεν έχει καταχωρηθεί λογισμικό.
{% endfor %}
<th colspan="6"></th>
<div class="modal fade" id="software-form-modal" tabindex="-1" role="dialog" aria-labelledby="software-from">
<form class="form-horizontal" data-url="{{ path_for('') }}">
<div class="modal-dialog" role="form">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
<h4 class="modal-title">Στοιχεία λογισμικού</h4>
<div class="modal-body">
{{ macros.input('name', 'Όνομα', '', 'text', {'required': ''}) }}
{{ macros.input('surname', 'Επώνυμο', '', 'text', {'required': ''}) }}
{{ macros.input('telephone', 'Τηλέφωνο','', 'tel', {'required': ''}) }}
{{ macros.input('email', 'Email','', 'email', {'required': ''}) }}
{{'branch_id', 'Ειδικότητα', branches, '', {'required': ''}) }}
{{ macros.checkbox('is_principle', 'Διευθυντής') }}
{{ macros.checkbox('is_responsible', 'Υπεύθυνος εργαστηρίου') }}
<input type="hidden" name="id" value="">
<div class="modal-footer">
<button type="button" class="btn btn-danger pull-left remove">Διαγραφή</button>
<button type="button" class="btn btn-default" data-dismiss="modal">Κλείσιμο</button>
<button type="submit" class="btn btn-primary">Αποθήκευση</button>
<script type="text/template" id="software-row">
<td class="title"><%= software.title %></td>
<td class="category"><%= software.softwarecategory %></td>
<td class="vendor"><%= software.vendor %></td>
<td class="url"><%= software.url %></td>
<td class="lab"><%= software.lab %></td>
{% endblock %}
{% block inlinejs %}
{{ parent() }}
<script src="{{ base_url }}/js/schools/software.js"></script>
{% endblock %}
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment