<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Aisky-coffee</title> <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> <!-- 新 Bootstrap4 核心 CSS 文件 --> <link rel="stylesheet" href="https://cdn.bootcss.com/bootstrap/4.1.0/css/bootstrap.min.css"> <!-- jQuery文件。务必在bootstrap.min.js 之前引入 --> <script src="https://cdn.bootcss.com/jquery/3.2.1/jquery.min.js"></script> <!-- popper.min.js 用于弹窗、提示、下拉菜单 --> <script src="https://cdn.bootcss.com/popper.js/1.12.5/umd/popper.min.js"></script> <!-- 最新的 Bootstrap4 核心 JavaScript 文件 --> <script src="https://cdn.bootcss.com/bootstrap/4.1.0/js/bootstrap.min.js"></script> <!--可用來建立使用者小圖示--> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css"> <script> $(function(){ //打菌 {% if params.bacterias %} var bacteria_num = 0; {% for bacteria in params.bacterias %} if('{{bacteria.start}}' != '00:00' && '{{bacteria.end}}' != '00:00' && bacteria_num == 0){ var bac = $(".set-schedule")[0]; var bac_div = $("#bacteria_div"); bac.style.display = 'none'; bac_div.css('visibility','visible'); $('select[name=bacteria_duration1]').val('{{bacteria.duration}}'); $('select[name=bacteria_from_hr1]').val('{{bacteria.start}}'.split(':')[0]); $('select[name=bacteria_from_min1]').val('{{bacteria.start}}'.split(':')[1]); $('select[name=bacteria_to_hr1]').val('{{bacteria.end}}'.split(':')[0]); $('select[name=bacteria_to_min1]').val('{{bacteria.end}}'.split(':')[1]); bacteria_num ++; }else if(bacteria_num > 0){ if(bacteria_num == 1){ var add = document.getElementById('bacteria_add1'); bacteria_num ++; }else{ var add = document.getElementById('bacteria_add' + i); }; Add(add); $('select[name=bacteria_duration' + i + ']').val('{{bacteria.duration}}'); $('select[name=' + 'bacteria_from_hr' + i + ']').val('{{bacteria.start}}'.split(':')[0]); $('select[name=' + 'bacteria_from_min' + i + ']').val('{{bacteria.start}}'.split(':')[1]); $('select[name=' + 'bacteria_to_hr' + i + ']').val('{{bacteria.end}}'.split(':')[0]); $('select[name=' + 'bacteria_to_min' + i + ']').val('{{bacteria.end}}'.split(':')[1]); }; {% endfor %} {% endif %} //消毒 {% if params.disinfects %} var disinfect_num = 0; {% for disinfect in params.disinfects %} if('{{disinfect.start}}' != '00:00' && '{{disinfect.end}}' != '00:00' && disinfect_num == 0){ var di = $(".set-schedule")[1]; var di_div = $("#disinfect_div"); di.style.display = 'none'; di_div.css('visibility','visible'); $('select[name=disinfect_duration1]').val('{{disinfect.duration}}'); $('select[name=disinfect_from_hr1]').val('{{disinfect.start}}'.split(':')[0]); $('select[name=disinfect_from_min1]').val('{{disinfect.start}}'.split(':')[1]); $('select[name=disinfect_to_hr1]').val('{{disinfect.end}}'.split(':')[0]); $('select[name=disinfect_to_min1]').val('{{disinfect.end}}'.split(':')[1]); disinfect_num ++; }else if(disinfect_num > 0){ if(disinfect_num == 1){ var add = document.getElementById('disinfect_add1'); disinfect_num ++; }else{ var add = document.getElementById('disinfect_add' + i); }; Add(add); $('select[name=disinfect_duration' + i + ']').val('{{disinfect.duration}}'); $('select[name=' + 'disinfect_from_hr' + i + ']').val('{{disinfect.start}}'.split(':')[0]); $('select[name=' + 'disinfect_from_min' + i + ']').val('{{disinfect.start}}'.split(':')[1]); $('select[name=' + 'disinfect_to_hr' + i + ']').val('{{disinfect.end}}'.split(':')[0]); $('select[name=' + 'disinfect_to_min' + i + ']').val('{{disinfect.end}}'.split(':')[1]); }; {% endfor %} {% endif %} //加熱 {% if params.heatings %} var heating_num = 0; {% for heating in params.heatings %} if('{{heating.start}}' != '00:00' && '{{heating.end}}' != '00:00' && heating_num == 0){ var heat = $(".set-schedule")[2]; var heat_div = $("#heating_div"); heat.style.display = 'none'; heat_div.css('visibility','visible'); $('select[name=heating_duration1]').val('{{heating.duration}}'); $('select[name=heating_from_hr1]').val('{{heating.start}}'.split(':')[0]); $('select[name=heating_from_min1]').val('{{heating.start}}'.split(':')[1]); $('select[name=heating_to_hr1]').val('{{heating.end}}'.split(':')[0]); $('select[name=heating_to_min1]').val('{{heating.end}}'.split(':')[1]); heating_num ++; }else if(heating_num > 0){ if(heating_num == 1){ var add = document.getElementById('heating_add1'); heating_num ++; }else{ var add = document.getElementById('heating_add' + i); }; Add(add); $('select[name=heating_duration' + i + ']').val('{{heating.duration}}'); $('select[name=' + 'heating_from_hr' + i + ']').val('{{heating.start}}'.split(':')[0]); $('select[name=' + 'heating_from_min' + i + ']').val('{{heating.start}}'.split(':')[1]); $('select[name=' + 'heating_to_hr' + i + ']').val('{{heating.end}}'.split(':')[0]); $('select[name=' + 'heating_to_min' + i + ']').val('{{heating.end}}'.split(':')[1]); }; {% endfor %} {% endif %} //攪拌 {% if params.stirs %} var stir_num = 0; {% for stir in params.stirs %} if('{{stir.start}}' != '00:00' && '{{stir.end}}' != '00:00' && stir_num == 0){ var stir = $(".set-schedule")[3]; var stir_div = $("#stir_div"); stir.style.display = 'none'; stir_div.css('visibility','visible'); $('select[name=stir_duration1]').val('{{stir.duration}}'); $('select[name=stir_from_hr1]').val('{{stir.start}}'.split(':')[0]); $('select[name=stir_from_min1]').val('{{stir.start}}'.split(':')[1]); $('select[name=stir_to_hr1]').val('{{stir.end}}'.split(':')[0]); $('select[name=stir_to_min1]').val('{{stir.end}}'.split(':')[1]); stir_num ++; }else if(stir_num > 0){ if(stir_num == 1){ var add = document.getElementById('stir_add1'); stir_num ++; }else{ var add = document.getElementById('stir_add' + i); }; Add(add); $('select[name=stir_duration' + i + ']').val('{{stir.duration}}'); $('select[name=' + 'stir_from_hr' + i + ']').val('{{stir.start}}'.split(':')[0]); $('select[name=' + 'stir_from_min' + i + ']').val('{{stir.start}}'.split(':')[1]); $('select[name=' + 'stir_to_hr' + i + ']').val('{{stir.end}}'.split(':')[0]); $('select[name=' + 'stir_to_min' + i + ']').val('{{stir.end}}'.split(':')[1]); }; {% endfor %} {% endif %} //注水 {% if params.waters %} var water_num = 0; {% for water in params.waters %} if('{{water.start}}' != '00:00' && '{{water.end}}' != '00:00' && water_num == 0){ var water = $(".set-schedule")[4]; var water_div = $("#water_div"); water.style.display = 'none'; water_div.css('visibility','visible'); $('select[name=water_duration1]').val('{{water.duration}}'); $('select[name=water_from_hr1]').val('{{water.start}}'.split(':')[0]); $('select[name=water_from_min1]').val('{{water.start}}'.split(':')[1]); $('select[name=water_to_hr1]').val('{{water.end}}'.split(':')[0]); $('select[name=water_to_min1]').val('{{water.end}}'.split(':')[1]); water_num ++; }else if(water_num > 0){ if(water_num == 1){ var add = document.getElementById('water_add1'); water_num ++; }else{ var add = document.getElementById('water_add' + i); }; Add(add); $('select[name=water_duration' + i + ']').val('{{water.duration}}'); $('select[name=' + 'water_from_hr' + i + ']').val('{{water.start}}'.split(':')[0]); $('select[name=' + 'water_from_min' + i + ']').val('{{water.start}}'.split(':')[1]); $('select[name=' + 'water_to_hr' + i + ']').val('{{water.end}}'.split(':')[0]); $('select[name=' + 'water_to_min' + i + ']').val('{{water.end}}'.split(':')[1]); }; {% endfor %} {% endif %} //開上閥 {% if params.tops %} var top_num = 0; {% for top in params.tops %} if('{{top.start}}' != '00:00' && '{{top.end}}' != '00:00' && top_num == 0){ var h_valve = $(".set-schedule")[5]; var h_valve_div = $("#highValve_div"); h_valve.style.display = 'none'; h_valve_div.css('visibility','visible'); $('select[name=highValve_duration1]').val('{{top.duration}}'); $('select[name=highValve_from_hr1]').val('{{top.start}}'.split(':')[0]); $('select[name=highValve_from_min1]').val('{{top.start}}'.split(':')[1]); $('select[name=highValve_to_hr1]').val('{{top.end}}'.split(':')[0]); $('select[name=highValve_to_min1]').val('{{top.end}}'.split(':')[1]); top_num ++; }else if(top_num > 0){ if(top_num == 1){ var add = document.getElementById('highValve_add1'); top_num ++; }else{ var add = document.getElementById('highValve_add' + i); }; Add(add); $('select[name=highValve_duration' + i + ']').val('{{top.duration}}'); $('select[name=' + 'highValve_from_hr' + i + ']').val('{{top.start}}'.split(':')[0]); $('select[name=' + 'highValve_from_min' + i + ']').val('{{top.start}}'.split(':')[1]); $('select[name=' + 'highValve_to_hr' + i + ']').val('{{top.end}}'.split(':')[0]); $('select[name=' + 'highValve_to_min' + i + ']').val('{{top.end}}'.split(':')[1]); }; {% endfor %} {% endif %} //開下閥 {% if params.bottoms %} var bottom_num = 0; {% for bottom in params.bottoms %} if('{{bottom.start}}' != '00:00' && '{{bottom.end}}' != '00:00' && bottom_num == 0){ var l_valve = $(".set-schedule")[6]; var l_valve_div = $("#lowValve_div"); l_valve.style.display = 'none'; l_valve_div.css('visibility','visible'); $('select[name=lowValve_duration1]').val('{{bottom.duration}}'); $('select[name=lowValve_from_hr1]').val('{{bottom.start}}'.split(':')[0]); $('select[name=lowValve_from_min1]').val('{{bottom.start}}'.split(':')[1]); $('select[name=lowValve_to_hr1]').val('{{bottom.end}}'.split(':')[0]); $('select[name=lowValve_to_min1]').val('{{bottom.end}}'.split(':')[1]); bottom_num ++; }else if(bottom_num > 0){ if(bottom_num == 1){ var add = document.getElementById('lowValve_add1'); bottom_num ++; }else{ var add = document.getElementById('lowValve_add' + i); }; Add(add); $('select[name=lowValve_duration' + i + ']').val('{{bottom.duration}}'); $('select[name=' + 'lowValve_from_hr' + i + ']').val('{{bottom.start}}'.split(':')[0]); $('select[name=' + 'lowValve_from_min' + i + ']').val('{{bottom.start}}'.split(':')[1]); $('select[name=' + 'lowValve_to_hr' + i + ']').val('{{bottom.end}}'.split(':')[0]); $('select[name=' + 'lowValve_to_min' + i + ']').val('{{bottom.end}}'.split(':')[1]); }; {% endfor %} {% endif %} //溫度 {% if params.tems %} var tem_num = 0; {% for tem in params.tems %} if('{{tem.start}}' != '00:00' && '{{tem.end}}' != '00:00' && tem_num == 0){ var tem = $(".set-schedule")[7]; var tem_div = $("#tem_div"); tem.style.display = 'none'; tem_div.css('visibility','visible'); $('select[name=tem_duration1]').val('{{tem.duration}}'); $('select[name=tem_from_hr1]').val('{{tem.start}}'.split(':')[0]); $('select[name=tem_from_min1]').val('{{tem.start}}'.split(':')[1]); $('select[name=tem_to_hr1]').val('{{tem.end}}'.split(':')[0]); $('select[name=tem_to_min1]').val('{{tem.end}}'.split(':')[1]); tem_num ++; }else if(tem_num > 0){ if(tem_num == 1){ var add = document.getElementById('tem_add1'); tem_num ++; }else{ var add = document.getElementById('tem_add' + i); }; Add(add); $('select[name=tem_duration' + i + ']').val('{{tem.duration}}'); $('select[name=' + 'tem_from_hr' + i + ']').val('{{tem.start}}'.split(':')[0]); $('select[name=' + 'tem_from_min' + i + ']').val('{{tem.start}}'.split(':')[1]); $('select[name=' + 'tem_to_hr' + i + ']').val('{{tem.end}}'.split(':')[0]); $('select[name=' + 'tem_to_min' + i + ']').val('{{tem.end}}'.split(':')[1]); }; {% endfor %} {% endif %} }); </script> <script> var i = 1; function Cancel(){ window.location.href='/b_cargo2'; }; function Add(evt){ evt.style.display="none"; i ++; var div = document.createElement('div'); var from_hr = 'from_hr' + i; var from_min = 'from_min' + i; var to_hr = 'to_hr' + i; var to_min = 'to_min' + i; var id = evt.getAttribute('id'); var len = id.length; var add = id.split('_')[0] + '_add' + i; var del = id.split('_')[0] + '_del' + i; var html = ''; var begin = id.split('_')[0]; div.className = "col-12 row"; div.style.marginTop = "10px"; html += '<div class="col-xl-5 col-lg-5 col-md-4" style="margin-top:10px;">'; html += '<span>Duration</span>'; if(begin == 'bacteria'){ html += ' <select name="bacteria_duration' + i + '" class="duration">'; }else if(begin == 'disinfect'){ html += ' <select name="disinfect_duration' + i + '" class="duration">'; }else if(begin == 'heating'){ html += ' <select name="heating_duration' + i + '" class="duration">'; }else if(begin == 'stir'){ html += ' <select name="stir_duration' + i + '" class="duration">'; }else if(begin == 'water'){ html += ' <select name="water_duration' + i + '" class="duration">'; }else if(begin == 'highValve'){ html += ' <select name="highValve_duration' + i + '" class="duration">'; }else if(begin == 'lowValve'){ html += ' <select name="lowValve_duration' + i + '" class="duration">'; }else if(begin == 'tem'){ html += ' <select name="tem_duration' + i + '" class="duration">'; }else{ }; html += '<option selected value="30min">30 min</option><option value="60min">60 min</option><option value="90min">90 min</option><option value="120min">120 min</option><option value="150min">150 min</option></select>'; html += '</div>'; html += '<div class="from-to col-xl-7 col-lg-7 col-md-8" style="margin-top:10px;">'; html += '<div>'; html += '<div class="from row">'; html += '<div class="col-3">'; html += '<span>From</span>'; html += '</div>'; html += '<div class="col-xs-6">'; if(id.split('_')[0] == 'bacteria'){ html += '<select name="bacteria_from_hr' + i + '">'; }else if(id.split('_')[0] == 'disinfect'){ html += '<select name="disinfect_from_hr' + i + '">'; }else if(id.split('_')[0] == 'heating'){ html += '<select name="heating_from_hr' + i + '">'; }else if(id.split('_')[0] == 'stir'){ html += '<select name="stir_from_hr' + i + '">'; }else if(id.split('_')[0] == 'water'){ html += '<select name="water_from_hr' + i + '">'; }else if(id.split('_')[0] == 'highValve'){ html += '<select name="highValve_from_hr' + i + '">'; }else if(id.split('_')[0] == 'lowValve'){ html += '<select name="lowValve_from_hr' + i + '">'; }else if(id.split('_')[0] == 'tem'){ html += '<select name="tem_from_hr' + i + '">'; }else{ }; for(var hr = 0; hr < 24; hr++){ if(hr < 10){ html += '<option value="0' + hr + '">0' + hr + '</option>'; }else{ html += '<option value="' + hr + '">' + hr + '</option>'; }; }; html += '</select>'; if(id.split('_')[0] == 'bacteria'){ html += ' : <select name="bacteria_from_min' + i + '">'; }else if(id.split('_')[0] == 'disinfect'){ html += ' : <select name="disinfect_from_min' + i + '">'; }else if(id.split('_')[0] == 'heating'){ html += ' : <select name="heating_from_min' + i + '">'; }else if(id.split('_')[0] == 'stir'){ html += ' : <select name="stir_from_min' + i + '">'; }else if(id.split('_')[0] == 'water'){ html += ' : <select name="water_from_min' + i + '">'; }else if(id.split('_')[0] == 'highValve'){ html += ' : <select name="highValve_from_min' + i + '">'; }else if(id.split('_')[0] == 'lowValve'){ html += ' : <select name="lowValve_from_min' + i + '">'; }else if(id.split('_')[0] == 'tem'){ html += ' : <select name="tem_from_min' + i + '">'; }else{ }; for(var min = 0; min < 60; min++){ if(min < 10){ html += '<option value="0' + min + '">0' + min + '</option>'; }else{ html += '<option value="' + min + '">' + min + '</option>'; }; }; html += '</select>'; html += '</div>'; html += '<div class="col-xs-3">'; html += '<input id=' + del + ' class="delete" type="button" value="Delete" onclick="Delete(' + del + ');">'; html += '</div>'; html += '</div>'; html += '<div class="to row">'; html += '<div class="col-3">'; html += '<span>To</span>'; html += '</div>'; html += '<div class="col-xs-6">'; if(id.split('_')[0] == 'bacteria'){ html += '<select name="bacteria_to_hr' + i + '">'; }else if(id.split('_')[0] == 'disinfect'){ html += '<select name="disinfect_to_hr' + i + '">'; }else if(id.split('_')[0] == 'heating'){ html += '<select name="heating_to_hr' + i + '">'; }else if(id.split('_')[0] == 'stir'){ html += '<select name="stir_to_hr' + i + '">'; }else if(id.split('_')[0] == 'water'){ html += '<select name="water_to_hr' + i + '">'; }else if(id.split('_')[0] == 'highValve'){ html += '<select name="highValve_to_hr' + i + '">'; }else if(id.split('_')[0] == 'lowValve'){ html += '<select name="lowValve_to_hr' + i + '">'; }else if(id.split('_')[0] == 'tem'){ html += '<select name="tem_to_hr' + i + '">'; }else{ }; for(var hr = 0; hr < 24; hr++){ if(hr < 10){ html += '<option value="0' + hr + '">0' + hr + '</option>'; }else{ html += '<option value="' + hr + '">' + hr + '</option>'; }; }; html += '</select>'; if(id.split('_')[0] == 'bacteria'){ html += ' : <select name="bacteria_to_min' + i + '">'; }else if(id.split('_')[0] == 'disinfect'){ html += ' : <select name="disinfect_to_min' + i + '">'; }else if(id.split('_')[0] == 'heating'){ html += ' : <select name="heating_to_min' + i + '">'; }else if(id.split('_')[0] == 'stir'){ html += ' : <select name="stir_to_min' + i + '">'; }else if(id.split('_')[0] == 'water'){ html += ' : <select name="water_to_min' + i + '">'; }else if(id.split('_')[0] == 'highValve'){ html += ' : <select name="highValve_to_min' + i + '">'; }else if(id.split('_')[0] == 'lowValve'){ html += ' : <select name="lowValve_to_min' + i + '">'; }else if(id.split('_')[0] == 'tem'){ html += ' : <select name="tem_to_min' + i + '">'; }else{ }; for(var min = 0; min < 60; min++){ if(min < 10){ html += '<option value="0' + min + '">0' + min + '</option>'; }else{ html += '<option value="' + min + '">' + min + '</option>'; }; }; html += '</select><br>'; html += '<input id=' + add + ' class="add" type="button" value="Add" onclick="Add(' + add + ');">'; html += '</div>'; html += '<div class="col-xs-3"></div>'; html += '</div>'; html += '</div>'; html += '</div>'; div.innerHTML = html; div.style.marginTop = '15px'; div.style.zIndex = '100'; evt.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.appendChild(div); }; function Delete(evt){ var id = evt.getAttribute('id'); var add = id.split('_')[0] + '_' + 'add'; var clo_xs_3 = evt.parentNode; var from = clo_xs_3.parentNode; var begin = id.split('_')[0]; var div = from.parentNode.parentNode.parentNode; var next_div = div.nextElementSibling; var pre_div = div.previousElementSibling; if(next_div && pre_div == null){ div.parentNode.removeChild(div); next_div.style.marginTop = '0px'; }else if(next_div && pre_div){ div.parentNode.removeChild(div); }else if(next_div == null && pre_div == null){ div.parentNode.parentNode.children[1].style.display = 'inline-block'; div.parentNode.style.visibility = 'hidden'; var name = id.split('_')[0]; var from_hr = name + '_from_hr' + 1; var from_min = name + '_from_min' + 1; var to_hr = name + '_to_hr' + 1; var to_min = name + '_to_min' + 1; $('select[name=' + from_hr + ']').val('00'); $('select[name=' + from_min + ']').val('00'); $('select[name=' + to_hr + ']').val('00'); $('select[name=' + to_min + ']').val('00'); }else{ div.parentNode.removeChild(div); i --; add = add + i; add = document.getElementById(add); if(add == null){ add = pre_div.children[1].children[0].children[1].children[1].children[3]; }; add.style.display = 'block'; }; }; function Cancel(){ window.location.href='/cargo2'; }; $(function(){ var bacteria = $(".set-schedule")[0]; var bacteria_div = $("#bacteria_div"); var disinfect = $(".set-schedule")[1]; var disinfect_div = $("#disinfect_div"); var heating = $(".set-schedule")[2]; var heating_div = $("#heating_div"); var stir = $(".set-schedule")[3]; var stir_div = $("#stir_div"); var water = $(".set-schedule")[4]; var water_div = $("#water_div"); var highValve = $(".set-schedule")[5]; var highValve_div = $("#highValve_div"); var lowValve = $(".set-schedule")[6]; var lowValve_div = $("#lowValve_div"); var tem = $(".set-schedule")[7]; var tem_div = $("#tem_div"); bacteria.onclick = function(){ bacteria.style.display = 'none'; bacteria_div.css('visibility','visible'); }; disinfect.onclick = function(){ disinfect.style.display = 'none'; disinfect_div.css('visibility','visible'); }; heating.onclick = function(){ heating.style.display = 'none'; heating_div.css('visibility','visible'); }; stir.onclick = function(){ stir.style.display = 'none'; stir_div.css('visibility','visible'); }; water.onclick = function(){ water.style.display = 'none'; water_div.css('visibility','visible'); }; highValve.onclick = function(){ highValve.style.display = 'none'; highValve_div.css('visibility','visible'); }; lowValve.onclick = function(){ lowValve.style.display = 'none'; lowValve_div.css('visibility','visible'); }; tem.onclick = function(){ tem.style.display = 'none'; tem_div.css('visibility','visible'); }; }); </script> <style> body { margin:0; } .navbar-dark .navbar-nav .nav-link { color: white; cursor: pointer; text-decoration:none; width: 110px; height: 46px; } .nav-top { line-height:40px; background-color: #C4C4C4; } .website_title{ font-family: Roboto; font-style: normal; font-weight: normal; font-size: 30px; color: #000000; } .navbar-nav > li{ float: none; display: inline-block; width: 100px; margin: 0 auto; text-align: center; } .navbar-nav > li a{ font-size: 20px; } .main-page { margin-top: 200px; } .page-title { font-family: Roboto; font-style: normal; font-weight: bold; font-size: 36px; color: #000000; } form { margin-top: 70px; } .flex { display: flex; flex-direction: row; flex-wrap: wrap; justify-content: center; } .flex span { font-family: Roboto; font-style: normal; font-weight: normal; font-size: 18px; margin-left: 20px; color: #000000; } .duration { background: #FFFFFF; border: 1px solid #000000; box-sizing: border-box; border-radius: 5px; width: 110px; height: 40px; font-size: 20px; margin-left: 15px; text-align: center; } .from select, .to select { width: 65px; height: 35px; margin-left: 2px; } .to { margin-top: 10px; margin-left: 10px; } .from { margin-left: 10px; } .from > div:first-child, .to > div:first-child { padding-right: 0px; text-align: right; margin-right: 5px; } .bacteria, .disinfect, .heating, .stir, .water, .highValve, .lowValve, .tem { height: 400px; border: 2px solid #E5E5E5; border-radius: 5px; margin-top:35px; margin-left:35px; } .item-title { display: inline-block; margin-top: 20px; margin-left: 20px; font-family: Roboto; font-style: normal; font-weight: bold; font-size: 24px; color: #000000; } .set-schedule { width: 200px; height: 45px; background: #008CBA; border: 1px solid #CFCFCF; box-sizing: border-box; color: #FFFFFF; border-radius: 5px; font-size: 17px; margin-left:10px; } .delete { background: #E43030; border: 1px solid #CFCFCF; box-sizing: border-box; border-radius: 5px; margin-left: 5px; width: 65px; height: 33px; font-size: 16px; text-align: center; line-height: 16px; color: #FFFFFF; } .add { background: #008CBA; border: 1px solid #CFCFCF; box-sizing: border-box; border-radius: 5px; margin-top: 10px; margin-left: 82px;; width: 65px; height: 33px; font-size: 16px; text-align: center; line-height: 16px; color: #FFFFFF; } .page-bottom { margin-top: 100px; } .form-control { background: #008CBA; border: 1px solid #CFCFCF; box-sizing: border-box; border-radius: 5px; width: 120px; height: 58px; text-align: center; line-height: 50px; color: #FFFFFF; display: inline-block; } @media(max-width:373px){ .card { margin-right: 0px; } .bacteria, .disinfect, .heating, .stir, .water, .highValve, .lowValve, .tem { margin-left: 0px; } .col { padding-right: 0px; padding-left: 0px; } .from,.to { margin-left: 0px; } .flex span { margin-left: 0px; } .from select, .to select { width: 45px; } .add { width: 50px; margin-left: 62px; } .delete { width: 58px; } .col-xs-8:not(:first-child) { margin-top: 150px; } .form-group { margin-top: 50px; } } @media(max-width:577px){ } @media(min-width:576px){ } @media(min-width:768px){ .navbar-nav > li { margin-left: 0px; } .navbar-nav .li-block { display:none; } } @media(min-width:991px){ .navbar-nav > li { margin-left: 20px; } .navbar-nav .li-block { display:none; } .page-bottom input:last-child { margin-left: 100px; } } @media(min-width:1200px){ .navbar-nav > li { margin-left: 50px; } .navbar-nav .li-block { display: inline-block; width: 100px; } .page-bottom input:last-child { margin-left: 100px; } } @media(min-width:1400px){ .navbar-nav .li-block { display: inline-block; width: 200px; } .page-bottom input:last-child { margin-left: 100px; } } @media(min-width:1689px) { .navbar-nav > li { margin-left: 50px; } .navbar-nav .li-block { display: inline-block; width: 500px; } .page-bottom input:last-child { margin-left: 100px; } } </style> </head> <body> <nav class="fixed-top"> <nav class="navbar navbar-expand-md nav-top justify-content-center"> <div> <span class="website_title">發酵槽{{params.tid}}</span> </div> </nav> <nav class="navbar navbar-expand-md bg-dark navbar-dark nav-bottom"> <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#collapsibleNavbar"> <span class="navbar-toggler-icon"></span> </button> <div class="collapse navbar-collapse" id="collapsibleNavbar"> <ul class="navbar-nav"> <li class="nav-item"> <a class="nav-link" href="/">首頁</a> </li> <li class="nav-item"> <a class="nav-link" href="#">關於我們</a> </li> <li class="nav-item"> <a class="nav-link" href="#">資訊</a> </li> <li class="nav-item"> <a class="nav-link" href="#">聯絡方法</a> </li> <li class="nav-item"> <a class="nav-link" href="/cargo_list">咖啡貨櫃</a> </li> <li class="nav-item"> <a class="nav-link" href="/video">影像串流</a> </li> <li class="li-block"></li> <li class="nav-item"> <a class="nav-link" href="#"><i class="fa fa-user-o"></i> {{params.username}}</a> </li> <li class="nav-item"> <a class="nav-link" href="/logout">Logout</a> </li> </ul> </div> </nav> </nav> <div class="main-page"> <form method="post" action="/b_tank/{{params.tid}}"> <div class="container-fluid"> <div class="row"> <div class="col flex"> <div class="bacteria col-xl-5 col-lg-5 col-md-5 col-sm-8 col-xs-8"> <h2 class="item-title">打菌</h2> <input class="set-schedule" type="button" value="Set up the schedule"> <br> <div id="bacteria_div" class="row" style="visibility:hidden;"> <div class="col-12 row"> <div class="col-xl-5 col-lg-5 col-md-4 col-sm-12 col-xs-12" style="margin-top:10px;"> <span>Duration</span> <select name="bacteria_duration1" class="duration"> <option selected value="30min">30 min</option> <option value="60min">60 min</option> <option value="90min">90 min</option> <option value="120min">120 min</option> <option value="150min">150 min</option> </select> </div> <div class="from-to col-xl-7 col-lg-7 col-md-8 col-sm-12 col-xs-12" style="margin-top:10px;"> <div> <div class="from row"> <div class="col-3"> <span>From</span> </div> <div class="col-xs-6"> <select name="bacteria_from_hr1"> {% for hr in range(0, 24) %} {% if hr < 10 %} <option value="0{{hr}}">0{{hr}}</option> {% else %} <option value="{{hr}}">{{hr}}</option> {% endif %} {% endfor %} </select> : <select name="bacteria_from_min1"> {% for min in range(0, 60) %} {% if min < 10 %} <option value="0{{min}}">0{{min}}</option> {% else %} <option value="{{min}}">{{min}}</option> {% endif %} {% endfor %} </select> </div> <div class="col-xs-3"> <input id="bacteria_del1" class="delete" type="button" value="Delete" onclick="Delete(bacteria_del1);"> </div> </div> <div class="to row"> <div class="col-3"> <span>To</span> </div> <div class="col-xs-6"> <select name="bacteria_to_hr1"> {% for hr in range(0, 24) %} {% if hr < 10 %} <option value="0{{hr}}">0{{hr}}</option> {% else %} <option value="{{hr}}">{{hr}}</option> {% endif %} {% endfor %} </select> : <select name="bacteria_to_min1"> {% for min in range(0, 60) %} {% if min < 10 %} <option value="0{{min}}">0{{min}}</option> {% else %} <option value="{{min}}">{{min}}</option> {% endif %} {% endfor %} </select><br> <input id="bacteria_add1" class="add" type="button" value="Add" onclick="Add(bacteria_add1);"> </div> <div class="col-xs-3"></div> </div> </div> </div> </div> </div> </div> <div class="disinfect col-xl-5 col-lg-5 col-md-5 col-sm-8 col-xs-8"> <h2 class="item-title">消毒</h2> <input class="set-schedule" type="button" value="Set up the schedule"> <br> <div id="disinfect_div" class="row" style="visibility:hidden;"> <div class="col-12 row"> <div class="col-xl-5 col-lg-5 col-md-4 col-sm-12 col-xs-12" style="margin-top:10px;"> <span>Duration</span> <select name="disinfect_duration1" class="duration"> <option selected value="30min">30 min</option> <option value="60min">60 min</option> <option value="90min">90 min</option> <option value="120min">120 min</option> <option value="150min">150 min</option> </select> </div> <div class="from-to col-xl-7 col-lg-7 col-md-8 col-sm-12 col-xs-12" style="margin-top:10px;"> <div> <div class="from row"> <div class="col-3"> <span>From</span> </div> <div class="col-xs-6"> <select name="disinfect_from_hr1"> {% for hr in range(0, 24) %} {% if hr < 10 %} <option value="0{{hr}}">0{{hr}}</option> {% else %} <option value="{{hr}}">{{hr}}</option> {% endif %} {% endfor %} </select> : <select name="disinfect_from_min1"> {% for min in range(0, 60) %} {% if min < 10 %} <option value="0{{min}}">0{{min}}</option> {% else %} <option value="{{min}}">{{min}}</option> {% endif %} {% endfor %} </select> </div> <div class="col-xs-3"> <input id="disinfect_del1" class="delete" type="button" value="Delete" onclick="Delete(disinfect_del1);"> </div> </div> <div class="to row"> <div class="col-3"> <span>To</span> </div> <div class="col-xs-6"> <select name="disinfect_to_hr1"> {% for hr in range(0, 24) %} {% if hr < 10 %} <option value="0{{hr}}">0{{hr}}</option> {% else %} <option value="{{hr}}">{{hr}}</option> {% endif %} {% endfor %} </select> : <select name="disinfect_to_min1"> {% for min in range(0, 60) %} {% if min < 10 %} <option value="0{{min}}">0{{min}}</option> {% else %} <option value="{{min}}">{{min}}</option> {% endif %} {% endfor %} </select><br> <input id="disinfect_add1" class="add" type="button" value="Add" onclick="Add(disinfect_add1);"> </div> <div class="col-xs-3"></div> </div> </div> </div> </div> </div> </div> <div class="heating col-xl-5 col-lg-5 col-md-5 col-sm-8 col-xs-8"> <h2 class="item-title">加熱</h2> <input class="set-schedule" type="button" value="Set up the schedule"> <br> <div id="heating_div" class="row" style="visibility:hidden;"> <div class="col-12 row"> <div class="col-xl-5 col-lg-5 col-md-4 col-sm-12 col-xs-12" style="margin-top:10px;"> <span>Duration</span> <select name="heating_duration1" class="duration"> <option value="30min" selected>30 min</option> <option value="60min">60 min</option> <option value="90min">90 min</option> <option value="120min">120 min</option> <option value="150min">150 min</option> </select> </div> <div class="from-to col-xl-7 col-lg-7 col-md-8 col-sm-12 col-xs-12" style="margin-top:10px;"> <div> <div class="from row"> <div class="col-3"> <span>From</span> </div> <div class="col-xs-6"> <select name="heating_from_hr1"> {% for hr in range(0, 24) %} {% if hr < 10 %} <option value="0{{hr}}">0{{hr}}</option> {% else %} <option value="{{hr}}">{{hr}}</option> {% endif %} {% endfor %} </select> : <select name="heating_from_min1"> {% for min in range(0, 60) %} {% if min < 10 %} <option value="0{{min}}">0{{min}}</option> {% else %} <option value="{{min}}">{{min}}</option> {% endif %} {% endfor %} </select> </div> <div class="col-xs-3"> <input id="heating_del1" class="delete" type="button" value="Delete" onclick="Delete(heating_del1);"> </div> </div> <div class="to row"> <div class="col-3"> <span>To</span> </div> <div class="col-xs-6"> <select name="heating_to_hr1"> {% for hr in range(0, 24) %} {% if hr < 10 %} <option value="0{{hr}}">0{{hr}}</option> {% else %} <option value="{{hr}}">{{hr}}</option> {% endif %} {% endfor %} </select> : <select name="heating_to_min1"> {% for min in range(0, 60) %} {% if min < 10 %} <option value="0{{min}}">0{{min}}</option> {% else %} <option value="{{min}}">{{min}}</option> {% endif %} {% endfor %} </select><br> <input id="heating_add1" class="add" type="button" value="Add" onclick="Add(heating_add1);"> </div> <div class="col-xs-3"></div> </div> </div> </div> </div> </div> </div> <div class="stir col-xl-5 col-lg-5 col-md-5 col-sm-8 col-xs-8"> <h2 class="item-title">攪拌</h2> <input class="set-schedule" type="button" value="Set up the schedule"> <br> <div id="stir_div" class="row" style="visibility:hidden;"> <div class="col-12 row"> <div class="col-xl-5 col-lg-5 col-md-4 col-sm-12 col-xs-12" style="margin-top:10px;"> <span>Duration</span> <select name="stir_duration1" class="duration"> <option selected value="30min">30 min</option> <option value="60min">60 min</option> <option value="90min">90 min</option> <option value="120min">120 min</option> <option value="150min">150 min</option> </select> </div> <div class="from-to col-xl-7 col-lg-7 col-md-8 col-sm-12 col-xs-12" style="margin-top:10px;"> <div> <div class="from row"> <div class="col-3"> <span>From</span> </div> <div class="col-xs-6"> <select name="stir_from_hr1"> {% for hr in range(0, 24) %} {% if hr < 10 %} <option value="0{{hr}}">0{{hr}}</option> {% else %} <option value="{{hr}}">{{hr}}</option> {% endif %} {% endfor %} </select> : <select name="stir_from_min1"> {% for min in range(0, 60) %} {% if min < 10 %} <option value="0{{min}}">0{{min}}</option> {% else %} <option value="{{min}}">{{min}}</option> {% endif %} {% endfor %} </select> </div> <div class="col-xs-3"> <input id="stir_del1" class="delete" type="button" value="Delete" onclick="Delete(stir_del1);"> </div> </div> <div class="to row"> <div class="col-3"> <span>To</span> </div> <div class="col-xs-6"> <select name="stir_to_hr1"> {% for hr in range(0, 24) %} {% if hr < 10 %} <option value="0{{hr}}">0{{hr}}</option> {% else %} <option value="{{hr}}">{{hr}}</option> {% endif %} {% endfor %} </select> : <select name="stir_to_min1"> {% for min in range(0, 60) %} {% if min < 10 %} <option value="0{{min}}">0{{min}}</option> {% else %} <option value="{{min}}">{{min}}</option> {% endif %} {% endfor %} </select><br> <input id="stir_add1" class="add" type="button" value="Add" onclick="Add(stir_add1);"> </div> <div class="col-xs-3"></div> </div> </div> </div> </div> </div> </div> <div class="water col-xl-5 col-lg-5 col-md-5 col-sm-8 col-xs-8"> <h2 class="item-title">注水</h2> <input class="set-schedule" type="button" value="Set up the schedule"> <br> <div id="water_div" class="row" style="visibility:hidden;"> <div class="col-12 row"> <div class="col-xl-5 col-lg-5 col-md-4 col-sm-12 col-xs-12" style="margin-top:10px;"> <span>Duration</span> <select name="water_duration1" class="duration"> <option selected value="30min">30 min</option> <option value="60min">60 min</option> <option value="90min">90 min</option> <option value="120min">120 min</option> <option value="150min">150 min</option> </select> </div> <div class="from-to col-xl-7 col-lg-7 col-md-8 col-sm-12 col-xs-12" style="margin-top:10px;"> <div> <div class="from row"> <div class="col-3"> <span>From</span> </div> <div class="col-xs-6"> <select name="water_from_hr1"> {% for hr in range(0, 24) %} {% if hr < 10 %} <option value="0{{hr}}">0{{hr}}</option> {% else %} <option value="{{hr}}">{{hr}}</option> {% endif %} {% endfor %} </select> : <select name="water_from_min1"> {% for min in range(0, 60) %} {% if min < 10 %} <option value="0{{min}}">0{{min}}</option> {% else %} <option value="{{min}}">{{min}}</option> {% endif %} {% endfor %} </select> </div> <div class="col-xs-3"> <input id="water_del1" class="delete" type="button" value="Delete" onclick="Delete(water_del1);"> </div> </div> <div class="to row"> <div class="col-3"> <span>To</span> </div> <div class="col-xs-6"> <select name="water_to_hr1"> {% for hr in range(0, 24) %} {% if hr < 10 %} <option value="0{{hr}}">0{{hr}}</option> {% else %} <option value="{{hr}}">{{hr}}</option> {% endif %} {% endfor %} </select> : <select name="water_to_min1"> {% for min in range(0, 60) %} {% if min < 10 %} <option value="0{{min}}">0{{min}}</option> {% else %} <option value="{{min}}">{{min}}</option> {% endif %} {% endfor %} </select><br> <input id="water_add1" class="add" type="button" value="Add" onclick="Add(water_add1);"> </div> <div class="col-xs-3"></div> </div> </div> </div> </div> </div> </div> <div class="highValve col-xl-5 col-lg-5 col-md-5 col-sm-8 col-xs-8"> <h2 class="item-title">開上閥</h2> <input class="set-schedule" type="button" value="Set up the schedule"> <br> <div id="highValve_div" class="row" style="visibility:hidden;"> <div class="col-12 row"> <div class="col-xl-5 col-lg-5 col-md-4 col-sm-12 col-xs-12" style="margin-top:10px;"> <span>Duration</span> <select name="highValve_duration1" class="duration"> <option selected value="30min">30 min</option> <option value="60min">60 min</option> <option value="90min">90 min</option> <option value="120min">120 min</option> <option value="150min">150 min</option> </select> </div> <div class="from-to col-xl-7 col-lg-7 col-md-8 col-sm-12 col-xs-12" style="margin-top:10px;"> <div> <div class="from row"> <div class="col-3"> <span>From</span> </div> <div class="col-xs-6"> <select name="highValve_from_hr1"> {% for hr in range(0, 24) %} {% if hr < 10 %} <option value="0{{hr}}">0{{hr}}</option> {% else %} <option value="{{hr}}">{{hr}}</option> {% endif %} {% endfor %} </select> : <select name="highValve_from_min1"> {% for min in range(0, 60) %} {% if min < 10 %} <option value="0{{min}}">0{{min}}</option> {% else %} <option value="{{min}}">{{min}}</option> {% endif %} {% endfor %} </select> </div> <div class="col-xs-3"> <input id="highValve_del1" class="delete" type="button" value="Delete" onclick="Delete(highValve_del1);"> </div> </div> <div class="to row"> <div class="col-3"> <span>To</span> </div> <div class="col-xs-6"> <select name="highValve_to_hr1"> {% for hr in range(0, 24) %} {% if hr < 10 %} <option value="0{{hr}}">0{{hr}}</option> {% else %} <option value="{{hr}}">{{hr}}</option> {% endif %} {% endfor %} </select> : <select name="highValve_to_min1"> {% for min in range(0, 60) %} {% if min < 10 %} <option value="0{{min}}">0{{min}}</option> {% else %} <option value="{{min}}">{{min}}</option> {% endif %} {% endfor %} </select><br> <input id="highValve_add1" class="add" type="button" value="Add" onclick="Add(highValve_add1);"> </div> <div class="col-xs-3"></div> </div> </div> </div> </div> </div> </div> <div class="lowValve col-xl-5 col-lg-5 col-md-5 col-sm-8 col-xs-8"> <h2 class="item-title">開下閥</h2> <input class="set-schedule" type="button" value="Set up the schedule"> <br> <div id="lowValve_div" class="row" style="visibility:hidden;"> <div class="col-12 row"> <div class="col-xl-5 col-lg-5 col-md-4 col-sm-12 col-xs-12" style="margin-top:10px;"> <span>Duration</span> <select name="lowValve_duration1" class="duration"> <option selected value="30min">30 min</option> <option value="60min">60 min</option> <option value="90min">90 min</option> <option value="120min">120 min</option> <option value="150min">150 min</option> </select> </div> <div class="from-to col-xl-7 col-lg-7 col-md-8 col-sm-12 col-xs-12" style="margin-top:10px;"> <div> <div class="from row"> <div class="col-3"> <span>From</span> </div> <div class="col-xs-6"> <select name="lowValve_from_hr1"> {% for hr in range(0, 24) %} {% if hr < 10 %} <option value="0{{hr}}">0{{hr}}</option> {% else %} <option value="{{hr}}">{{hr}}</option> {% endif %} {% endfor %} </select> : <select name="lowValve_from_min1"> {% for min in range(0, 60) %} {% if min < 10 %} <option value="0{{min}}">0{{min}}</option> {% else %} <option value="{{min}}">{{min}}</option> {% endif %} {% endfor %} </select> </div> <div class="col-xs-3"> <input id="lowValve_del1" class="delete" type="button" value="Delete" onclick="Delete(lowValve_del1);"> </div> </div> <div class="to row"> <div class="col-3"> <span>To</span> </div> <div class="col-xs-6"> <select name="lowValve_to_hr1"> {% for hr in range(0, 24) %} {% if hr < 10 %} <option value="0{{hr}}">0{{hr}}</option> {% else %} <option value="{{hr}}">{{hr}}</option> {% endif %} {% endfor %} </select> : <select name="lowValve_to_min1"> {% for min in range(0, 60) %} {% if min < 10 %} <option value="0{{min}}">0{{min}}</option> {% else %} <option value="{{min}}">{{min}}</option> {% endif %} {% endfor %} </select><br> <input id="lowValve_add1" class="add" type="button" value="Add" onclick="Add(lowValve_add1);"> </div> <div class="col-xs-3"></div> </div> </div> </div> </div> </div> </div> <div class="tem col-xl-5 col-lg-5 col-md-5 col-sm-8 col-xs-8"> <h2 class="item-title">溫度</h2> <input class="set-schedule" type="button" value="Set up the schedule"> <br> <div id="tem_div" class="row" style="visibility:hidden;"> <div class="col-12 row"> <div class="col-xl-5 col-lg-5 col-md-4 col-sm-12 col-xs-12" style="margin-top:10px;"> <span>Duration</span> <select name="tem_duration1" class="duration"> <option selected value="30min">30 min</option> <option value="60min">60 min</option> <option value="90min">90 min</option> <option value="120min">120 min</option> <option value="150min">150 min</option> </select> </div> <div class="from-to col-xl-7 col-lg-7 col-md-8 col-sm-12 col-xs-12" style="margin-top:10px;"> <div> <div class="from row"> <div class="col-3"> <span>From</span> </div> <div class="col-xs-6"> <select name="tem_from_hr1"> {% for hr in range(0, 24) %} {% if hr < 10 %} <option value="0{{hr}}">0{{hr}}</option> {% else %} <option value="{{hr}}">{{hr}}</option> {% endif %} {% endfor %} </select> : <select name="tem_from_min1"> {% for min in range(0, 60) %} {% if min < 10 %} <option value="0{{min}}">0{{min}}</option> {% else %} <option value="{{min}}">{{min}}</option> {% endif %} {% endfor %} </select> </div> <div class="col-xs-3"> <input id="tem_del1" class="delete" type="button" value="Delete" onclick="Delete(tem_del1);"> </div> </div> <div class="to row"> <div class="col-3"> <span>To</span> </div> <div class="col-xs-6"> <select name="tem_to_hr1"> {% for hr in range(0, 24) %} {% if hr < 10 %} <option value="0{{hr}}">0{{hr}}</option> {% else %} <option value="{{hr}}">{{hr}}</option> {% endif %} {% endfor %} </select> : <select name="tem_to_min1"> {% for min in range(0, 60) %} {% if min < 10 %} <option value="0{{min}}">0{{min}}</option> {% else %} <option value="{{min}}">{{min}}</option> {% endif %} {% endfor %} </select><br> <input id="tem_add1" class="add" type="button" value="Add" onclick="Add(tem_add1);"> </div> <div class="col-xs-3"></div> </div> </div> </div> </div> </div> </div> </div> </div> </div> <div class="row page-bottom"> <div class="col"></div> <div class="col-xl-4 col-lg-6 col-md-8 col-sm-10 col-xs-10" style="text-align:center;"> <div class="form-group"> <input type="button" class="form-control" value="Cancel" onclick="Cancel();"> <input type="submit" class="form-control" value="Confirm"> </div> </div> <div class="col"></div> </div> </form> </div> </body> </html>