styling buttons
This commit is contained in:
parent
2bc81e7d59
commit
22494aadd2
@ -385,21 +385,21 @@ box-sizing: border-box;
|
|||||||
height: 100%; /* Full height */
|
height: 100%; /* Full height */
|
||||||
overflow: auto; /* Enable scroll if needed */
|
overflow: auto; /* Enable scroll if needed */
|
||||||
background-color: rgb(0,0,0); /* Fallback color */
|
background-color: rgb(0,0,0); /* Fallback color */
|
||||||
background-color: rgba(0,0,0,0.4); /* Black w/ opacity */
|
background-color: rgba(0,0,0,0.5); /* Black w/ opacity */
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Modal Content/Box */
|
/* Modal Content/Box */
|
||||||
.modal-content {
|
.modal-content {
|
||||||
background-color: #fefefe;
|
background-color: yellow;
|
||||||
margin: 15% auto; /* 15% from the top and centered */
|
margin: 15% auto; /* 15% from the top and centered */
|
||||||
padding: 20px;
|
padding: 15px;
|
||||||
border: 1px solid #888;
|
border: 1px solid #888;
|
||||||
width: 40%; /* Could be more or less, depending on screen size */
|
width: 40%; /* Could be more or less, depending on screen size */
|
||||||
}
|
}
|
||||||
|
|
||||||
/* The Close Button */
|
/* The Close Button */
|
||||||
.close {
|
.close {
|
||||||
color: red;
|
color: grey;
|
||||||
float: right;
|
float: right;
|
||||||
font-size: 28px;
|
font-size: 28px;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
@ -407,7 +407,7 @@ box-sizing: border-box;
|
|||||||
|
|
||||||
.close:hover,
|
.close:hover,
|
||||||
.close:focus {
|
.close:focus {
|
||||||
color: black;
|
color: red;
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
@ -21,18 +21,20 @@
|
|||||||
|
|
||||||
{% endfor %}</ul></p>
|
{% endfor %}</ul></p>
|
||||||
|
|
||||||
<button id="myBtn" style= "width: 180px; font-size: 10pt;"><a> Download this {{ book.fileformat }}</a></button>
|
{% if book.file %}
|
||||||
<button style= "font-size: 10pt;"> <a href="{{ url_for('edit_book_by_id', id=book.id )}}">edit</a></button>
|
<button id="myBtn" style= "width: 180px; font-size: 10pt;"><a> Download this {{ book.fileformat }}</a></button>
|
||||||
<button style= "font-size: 10pt;"> <a href="{{ url_for('remove_book_by_id', id=book.id)}}">delete</a></button>
|
|
||||||
|
|
||||||
<div id="myModal" class="modal">
|
<div id="myModal" class="modal">
|
||||||
<div class="modal-content">
|
<div class="modal-content">
|
||||||
<span class="close">×</span>
|
<span class="close">×</span>
|
||||||
<h3>A message from the uploading librarian:</h3>
|
<h3>A message from the uploading librarian:</h3>
|
||||||
<p style="font-style: italic;">"{{book.message or 'Happy reading.'}}" </p>
|
<span style="font-style: italic;">"{{book.message or 'Happy reading.'}}" </span><br>
|
||||||
<br>
|
<h4><a href="../uploads/{{ book.file }}"> >>>> Link to file <<<<</h4></a></div>
|
||||||
<h4><a href="../uploads/{{ book.file }}"> >>>> Link to file <<<<</h4>
|
</div>
|
||||||
</div></div>
|
{% else %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
<button style= "font-size: 10pt;"> <a href="{{ url_for('edit_book_by_id', id=book.id )}}">edit</a></button>
|
||||||
|
<button style= "font-size: 10pt;"> <a href="{{ url_for('remove_book_by_id', id=book.id)}}">delete</a></button>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -141,12 +141,14 @@ def edit_book_by_id(id):
|
|||||||
input_authors = user_form.author.data
|
input_authors = user_form.author.data
|
||||||
category = user_form.category.data
|
category = user_form.category.data
|
||||||
year_published = user_form.year_published.data
|
year_published = user_form.year_published.data
|
||||||
|
message = user_form.message.data
|
||||||
if year_published=="":
|
if year_published=="":
|
||||||
year_published = None
|
year_published = None
|
||||||
book = Book.query.filter_by(id=id).first()
|
book = Book.query.filter_by(id=id).first()
|
||||||
book.title = title
|
book.title = title
|
||||||
book.category = category
|
book.category = category
|
||||||
book.year_published = year_published
|
book.year_published = year_published
|
||||||
|
book.message = message
|
||||||
|
|
||||||
#authors update
|
#authors update
|
||||||
book.authors.clear()
|
book.authors.clear()
|
||||||
|
Loading…
Reference in New Issue
Block a user