| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361 | <!DOCTYPE html><html lang="en"><head>    <meta charset="UTF-8">    <title>Smart Coffee - clean</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>    <!--    <script src="../static/js/sign_in.js"></script>    <link rel="stylesheet" href="../static/css/sign_in.css">-->    <style>        .C1_position {            position: absolute;            top: 135px;            left: 210px;            width: 170px;            height: 230px;            border-style: solid;            border-color: aqua;        }        .C2_position {            position: absolute;            top: 400px;            left: 210px;            width: 170px;            height: 230px;            border-style: solid;            border-color: aqua;        }        .S1_position {            position: absolute;            top: 135px;            left: 550px;            width: 170px;            height: 230px;            border-style: solid;            border-color: aqua;        }        .S2_position {            position: absolute;            top: 400px;            left: 550px;            width: 170px;            height: 230px;            border-style: solid;            border-color: aqua;        }        .P1_position {            position: absolute;            top: 135px;            left: 890px;            width: 170px;            height: 230px;            border-style: solid;            border-color: aqua;        }        .P2_position {            position: absolute;            top: 400px;            left: 890px;            width: 170px;            height: 230px;            border-style: solid;            border-color: aqua;        }            </style>    <script language="JavaScript">        // 指定 10秒 刷新網頁一次        var WebRestart        // WebRestart = setTimeout(function () { location.reload() }, 10000);    </script></head><body>    <!--        background-color:rgb(0, 238, 255);    -->    <div style="text-align: center; margin-top: 30px;font-size: 24px;">        Smart Coffee    </div>    <div>        <!-- 底圖 清洗浮選貨櫃 12 個清洗浮選桶槽 -->        <center><img src="../static/img/web_CleanColorPeel_container.png" width="1500x" style="margin: auto;"></center>        <!-- 清洗浮選槽 C1 -->        <div id="C1" tabindex="0" class="C1_position" role="button">            C1 status            <!-- C1 狀態點點-->            <div id="C1_status" style="width: 20px; height: 20px; background-color: cornflowerblue; border-radius: 50%;"></div>        </div>                <!-- 清洗浮選槽 C2 -->        <div id="C2" tabindex="0" class="C2_position" role="button">            C2 status            <div id="C2_status" style="width: 20px; height: 20px; background-color: cornflowerblue; border-radius: 50%;"></div>        </div>        <!-- 色選機 S1 -->        <div id="S1" tabindex="0" class="S1_position" role="button">            S1 status            <div id="S1_status" style="width: 20px; height: 20px; background-color: cornflowerblue; border-radius: 50%;"></div>        </div>        <!-- 色選機 S2 -->        <div id="S2" tabindex="0" class="S2_position" role="button">            S2 status            <div id="S2_status" style="width: 20px; height: 20px; background-color: cornflowerblue; border-radius: 50%;"></div>        </div>        <!-- 脫皮機 P1 -->        <div id="P1" tabindex="0" class="P1_position" role="button">            P1 status            <div id="P1_status" style="width: 20px; height: 20px; background-color: cornflowerblue; border-radius: 50%;"></div>        </div>        <!-- 脫皮機 P2 -->        <div id="P2" tabindex="0" class="P2_position" role="button">            P2 status            <div id="P2_status" style="width: 20px; height: 20px; background-color: cornflowerblue; border-radius: 50%;"></div>        </div>            </div>    <!-- 模态框 -->    <div class="modal fade" id="C1_Modal">        <div class="modal-dialog modal-dialog-centered" style="width: 400px;">            <div class="modal-content">                <div class="modal-header">                    <h4 class="modal-title">清洗浮選槽 C1 狀態</h4>                    <button type="button" class="close" data-dismiss="modal">×</button>                </div>                <!-- 模态框主体 -->                <div class="modal-body">                    <table style="border:0px gray solid; width: 100%;" cellpadding="3">                        <!--<table style="border:0px gray solid;-->                            <tr>                                <td><strong><a href="/clean_container/1">制動器狀態</a></strong></td>                                <td><strong><a href="/clean_container/1">感測器狀態</a></strong></td>                            </tr>                            <tr>                                <td style="vertical-align:text-top;">                                    <table style="border:0px gray solid;" cellpadding="3">                                        <tr>                                            <td>                                                <div id="tank_vacuum_status"                                                    style="width: 18px; height: 18px; background-color:black; border-radius: 50%;">                                                </div>                                                {% if tank_vacuum=='ON' %}                                                <div id="C1_vacuum_tatus" style="width: 18px; height: 18px; background-color: forestgreen; border-radius: 50%;"></div>                                                {% elif tank_vacuum=='OFF' %}                                                <div id="C1_vacuum_tatus" style="width: 18px; height: 18px; background-color: #C0C0C0; border-radius: 50%;"></div>                                                {% else %}                                                <div id="C1_vacuum_tatus" style="width: 18px; height: 18px; background-color:crimson; border-radius: 50%;"></div>                                                {% endif %}                                            </td>                                            <td>                                                真空吸料機                                            </td>                                        </tr>                                        <tr>                                            <td>                                                <div id="tank_vacuum_status"                                                    style="width: 18px; height: 18px; background-color:black; border-radius: 50%;">                                                </div>                                                {% if tank_pump_waterFloat=='ON' %}                                                <div id="C1_pump_waterFloat_tatus" style="width: 18px; height: 18px; background-color: forestgreen; border-radius: 50%;"></div>                                                {% elif tank_pump_waterFloat=='OFF' %}                                                <div id="C1_pump_waterFloat_tatus" style="width: 18px; height: 18px; background-color: #C0C0C0; border-radius: 50%;"></div>                                                {% else %}                                                <div id="C1_pump_waterFloat_tatus" style="width: 18px; height: 18px; background-color:crimson; border-radius: 50%;"></div>                                                {% endif %}                                            </td>                                            <td>                                                浮選槽注水雙核隔膜泵                                            </td>                                        </tr>                                        <tr>                                            <td>                                                <div id="tank_vacuum_status"                                                    style="width: 18px; height: 18px; background-color:black; border-radius: 50%;">                                                </div>                                                {% if tank_pump_waterL2=='ON' %}                                                <div id="C1_pump_waterL2_tatus" style="width: 18px; height: 18px; background-color: forestgreen; border-radius: 50%;"></div>                                                {% elif tank_pump_waterL2=='OFF' %}                                                <div id="C1_pump_waterL2_tatus" style="width: 18px; height: 18px; background-color: #C0C0C0; border-radius: 50%;"></div>                                                {% else %}                                                <div id="C1_pump_waterL2_tatus" style="width: 18px; height: 18px; background-color:crimson; border-radius: 50%;"></div>                                                {% endif %}                                            </td>                                            <td>                                                第 2 層灑水雙核隔膜泵                                            </td>                                        </tr>                                        <tr>                                            <td>                                                <div id="tank_vacuum_status"                                                    style="width: 18px; height: 18px; background-color:black; border-radius: 50%;">                                                </div>                                                {% if tank_pump_waterL4=='ON' %}                                                <div id="C1_pump_waterL4_tatus" style="width: 18px; height: 18px; background-color: forestgreen; border-radius: 50%;"></div>                                                {% elif tank_pump_waterL4=='OFF' %}                                                <div id="C1_pump_waterL4_tatus" style="width: 18px; height: 18px; background-color: #C0C0C0; border-radius: 50%;"></div>                                                {% else %}                                                <div id="C1_pump_waterL4_tatus" style="width: 18px; height: 18px; background-color:crimson; border-radius: 50%;"></div>                                                {% endif %}                                            </td>                                            <td>                                                第 4 層灑水雙核隔膜泵                                            </td>                                        </tr>                                        <tr>                                            <td>                                                <div id="tank_vacuum_status"                                                    style="width: 18px; height: 18px; background-color:black; border-radius: 50%;">                                                </div>                                                {% if tank_solenoid_waterL3=='ON' %}                                                <div id="C1_solenoid_waterL3_tatus" style="width: 18px; height: 18px; background-color: forestgreen; border-radius: 50%;"></div>                                                {% elif tank_vacuum=='OFF' %}                                                <div id="C1_solenoid_waterL3_tatus" style="width: 18px; height: 18px; background-color: #C0C0C0; border-radius: 50%;"></div>                                                {% else %}                                                <div id="C1_solenoid_waterL3_tatus" style="width: 18px; height: 18px; background-color:crimson; border-radius: 50%;"></div>                                                {% endif %}                                            </td>                                            <td>                                                清洗第 3 層電磁閥                                            </td>                                        </tr>                                        <tr>                                            <td>                                                <div id="tank_vacuum_status"                                                    style="width: 18px; height: 18px; background-color:black; border-radius: 50%;">                                                </div>                                                {% if tank_solenoid_waterL5=='ON' %}                                                <div id="C1_solenoid_waterL5_tatus" style="width: 18px; height: 18px; background-color: forestgreen; border-radius: 50%;"></div>                                                {% elif tank_solenoid_waterL5=='OFF' %}                                                <div id="C1_solenoid_waterL5_tatus" style="width: 18px; height: 18px; background-color: #C0C0C0; border-radius: 50%;"></div>                                                {% else %}                                                <div id="C1_solenoid_waterL5_tatus" style="width: 18px; height: 18px; background-color:crimson; border-radius: 50%;"></div>                                                {% endif %}                                            </td>                                            <td>                                                清洗第 5 層電磁閥                                            </td>                                        </tr>                                        <tr>                                            <td>                                                <div id="tank_vacuum_status"                                                    style="width: 18px; height: 18px; background-color:black; border-radius: 50%;">                                                </div>                                                {% if tank_stepping_motor==0 %}                                                <div id="C1_steppingmotor_tatus" style="width: 18px; height: 18px; background-color: #C0C0C0; border-radius: 50%;"></div>                                                {% elif (tank_stepping_motor>0) or (0>tank_stepping_motor) %}                                                <div id="C1_steppingmotor_tatus" style="width: 18px; height: 18px; background-color: forestgreen; border-radius: 50%;"></div>                                                {% else %}                                                <div id="C1_steppingmotor_tatus" style="width: 18px; height: 18px; background-color:crimson; border-radius: 50%;"></div>                                                {% endif %}                                            </td>                                            <td>                                                ***步進馬達***                                            </td>                                        </tr>                                    </table>                                 </td>                                <td style="vertical-align:text-top;">                                    <table style="border:0px gray solid;" cellpadding="3">                                        <tr>                                            <td>                                                咖啡生豆高度                                            </td>                                            <td>                                                {{tank_UltraSonic.UltraSonic}}                                            </td>                                        </tr>                                    </table>                                </td>                            </tr>                    </table>                </div>            </div>        </div>    </div>    </div>    <script>        function update_data_C(ctid) {            console.log('cleaning_tank_id:' + ctid)            $.get('/loading/C' + ctid, '', function (res) {            }, 'json');            $('#C1_Modal').modal('show');        }        function update_data_S(stid) {            console.log('ColorSelection_tank_id:' + stid)            $.get('/loading/S' + stid, '', function (res) {            }, 'json');            $('#S1_Modal').modal('show');        }        function update_data_P(ptid) {            console.log('peeling_tank_id:' + ptid)            $.get('/loading/P' + ptid, '', function (res) {            }, 'json');            $('#P1_Modal').modal('show');        }        var button_C1 = document.getElementById('C1');        button_C1.addEventListener('click', function () { update_data_C("1") });        var button_C2 = document.getElementById('C2');        button_C2.addEventListener('click', function () { update_data_C("2") });        var button_S1 = document.getElementById('S1');        button_S1.addEventListener('click', function () { update_data_S("1") });        var button_S2 = document.getElementById('S2');        button_S2.addEventListener('click', function () { update_data_S("2") });        var button_P1 = document.getElementById('P1');        button_P1.addEventListener('click', function () { update_data_P("1") });        var button_P2 = document.getElementById('P2');        button_P2.addEventListener('click', function () { update_data_P("2") });    </script></body></html>
 |