mirror of
https://gitlab.com/crafty-controller/crafty-4.git
synced 2024-08-30 18:23:09 +00:00
Add popover for mobile schedules
This commit is contained in:
parent
fe7df99c19
commit
6fd5db3429
@ -36,6 +36,7 @@
|
||||
|
||||
<div class="row">
|
||||
<button onclick="location.href=`/panel/add_schedule?id={{ data['server_stats']['server_id']['server_id'] }}`" class="btn btn-info">Create New Schedule <i class="fas fa-pencil-alt"></i></button>
|
||||
<span class="too_small" data-toggle="popover" data-placement="left" title="{{ translate('serverSchedules', 'cannotSee', data['lang']) }}" data-content="{{ translate('serverSchedules', 'cannotSeeOnMobile', data['lang']) }}"></span>
|
||||
<div class="col-md-12 col-sm-12" style="overflow-x:auto;">
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
@ -192,6 +193,11 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<style>
|
||||
.popover-body{
|
||||
color: white !important;;
|
||||
}
|
||||
</style>
|
||||
|
||||
|
||||
|
||||
@ -214,6 +220,29 @@ td {
|
||||
|
||||
{% block js %}
|
||||
<script>
|
||||
$(document).ready(function(){
|
||||
$('[data-toggle="popover"]').popover();
|
||||
if($(window).width() < 1000){
|
||||
$('.too_small').popover("show");
|
||||
}
|
||||
|
||||
});
|
||||
$(window).ready(function(){
|
||||
$('body').click(function(){
|
||||
$('.too_small').popover("hide");
|
||||
});
|
||||
});
|
||||
$(window).resize(function() {
|
||||
// This will execute whenever the window is resized
|
||||
if($(window).width() < 1000){
|
||||
$('.too_small').popover("show");
|
||||
}
|
||||
else{
|
||||
$('.too_small').popover("hide");
|
||||
} // New width
|
||||
});
|
||||
</script>
|
||||
<script>
|
||||
|
||||
|
||||
//used to get cookies from browser - this is part of tornados xsrf protection - it's for extra security
|
||||
|
@ -176,7 +176,9 @@
|
||||
"areYouSure": "Deleted Scheduled Task?",
|
||||
"confirmDelete": "Do you want to delete this scheduled task? This cannot be undone.",
|
||||
"cancel": "Cancel",
|
||||
"confirm": "Confirm"
|
||||
"confirm": "Confirm",
|
||||
"cannotSee": "Not seeing everything?",
|
||||
"cannotSeeOnMobile": "Try clicking on a scheduled task for full details."
|
||||
},
|
||||
|
||||
"serverBackups": {
|
||||
|
Loading…
Reference in New Issue
Block a user