Add "edit" button on list page
This commit is contained in:
parent
08b4687309
commit
b5a100f9e7
3 changed files with 33 additions and 6 deletions
|
@ -1,4 +1,20 @@
|
|||
{% extends "bootstrap/base.html" %}
|
||||
{%block styles%}
|
||||
{{super()}}
|
||||
<link href="https://code.jquery.com/ui/1.11.3/themes/ui-lightness/jquery-ui.css"
|
||||
rel="stylesheet" media="screen">
|
||||
{%endblock%}
|
||||
{%block scripts%}
|
||||
{{super()}}
|
||||
<script src="https://code.jquery.com/ui/1.11.3/jquery-ui.min.js"
|
||||
type="text/javascript">
|
||||
</script>
|
||||
<script type="text/javascript">
|
||||
$(function() {
|
||||
$('.button').button({});
|
||||
});
|
||||
</script>
|
||||
{%endblock%}
|
||||
{% block title %}Larigira{% endblock title %}
|
||||
{% block navbar %}
|
||||
<nav class="navbar navbar-default">
|
||||
|
|
|
@ -1,8 +1,6 @@
|
|||
{% extends "dbadmin_base.html" %}
|
||||
{%block styles %}
|
||||
{{super()}}
|
||||
<link href="https://code.jquery.com/ui/1.11.3/themes/ui-lightness/jquery-ui.css"
|
||||
rel="stylesheet" media="screen">
|
||||
<style>
|
||||
#selected {
|
||||
margin: 5px;
|
||||
|
@ -13,8 +11,6 @@
|
|||
{%endblock styles%}
|
||||
{%block scripts %}
|
||||
{{super()}}
|
||||
<script src="https://code.jquery.com/ui/1.11.3/jquery-ui.min.js"
|
||||
type="text/javascript">
|
||||
</script>
|
||||
<script type="text/javascript">
|
||||
var my_id = {{alarm.eid}};
|
||||
|
|
|
@ -1,4 +1,17 @@
|
|||
{% extends "dbadmin_base.html" %}
|
||||
{%block scripts%}
|
||||
{{super()}}
|
||||
<script type="text/javascript">
|
||||
$(function() {
|
||||
$('.button').button({
|
||||
icons: {
|
||||
primary: 'ui-icon-pencil'
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
{%endblock%}
|
||||
|
||||
{% block title %}Larigira - DB list {%endblock%}
|
||||
|
||||
{% block content %}
|
||||
|
@ -6,8 +19,10 @@
|
|||
{% for e, actions in events %}
|
||||
<div class="event row">
|
||||
<div class="col-md-8">
|
||||
<h2>Event {{e.eid}} <small>{{e.nick if 'nick'}}</small></h2>
|
||||
{{dict_table(e, ['nick', 'actions'])}}
|
||||
<h2>Event {{e.eid}} <small>{{e.nick if 'nick'}}</small>
|
||||
</h2>
|
||||
<a class="button" href="{{url_for('db.edit_event', alarmid=e.eid)}}">Edit</a>
|
||||
{{dict_table(e, ['nick', 'actions'])}}
|
||||
|
||||
</div>
|
||||
<div class="actions col-md-4">
|
||||
|
|
Loading…
Reference in a new issue