<html>
<head>
    <meta http-equiv="Content-Type" content="text/html;charset=utf-8">
    <title>ChaosReport</title>
    <script src="./bootstrap/js/bootstrap.min.js"></script> 
	<script src="./bootstrap/js/jquery-3.5.1.min.js"></script> 
    <link href="./bootstrap/css/bootstrap.min.css" rel="stylesheet">
	<link href="https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/5.0.2/css/bootstrap.min.css" rel="stylesheet">
	<script src="https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/5.0.2/js/bootstrap.min.js"></script>
	<script src="https://cdn.bootcdn.net/ajax/libs/jquery/3.6.0/jquery.min.js"></script>
</head>

    <body>
<h1><span class="label label-primary center-block">混沌测试报告</span></h1>



<div class="container column=3 pull-left">
	<div class="row-fluid">
		<div class="span12">
            <h3><span class="label label-info pull-left">{{exeTime}}</span></h3>
            <br>
			<table class="table table-striped table-bordered table-hover table-condensed">
				<thead >
                    <tr>
						<th class='info'>
							总用例
						</th>
						<th class='success'>
							成功
						</th>
						<th class='danger'>
							失败
						</th>
					</tr>
				</thead>
				<tbody>
					<tr>
						<td class='info'>
							{{ total }}
						</td>
						<td class='success'>
							{{ passCounter }}
						</td>
						<td class='danger'>
							{{ failCounter }}
						</td>
					</tr>
				
				</tbody>
			</table>
        </div>
    </div>
</div>
<div class="container-fluid">
	<div class="row-fluid">
			<table class="table table-striped table-bordered table-hover table-condensed">
				<thead>
					<tr>
						<th>
							用例描述
						</th>
						<th>
							结果
						</th>
						<th>
							指令
						</th>
						<th>
							混沌ID
						</th>
                        <th>
							检查指令
						</th>
                        <th>
							期望值
						</th>
						<th>
							实际值
						</th>
					</tr>
				</thead>
				<tbody>
                    

                    {% for one in resList %}
                    {% if  one['checkStatus'] %}
                        <tr class='success'>
                            
                            <td>{{ one['testTitle'] }}</td>
                            {% if one['checkStatus'] %}
                                <td>成功</td>
                            {% else %}
                                <td>失败</td>
                            {% endif %} 
                            <td>{{ one['chaosCommand'] }}</td>
                            <td>{{ one['chaosId'] }}</td>
                            <td>{{ one['checkCommand'] }}</td>
                            <td>{{ one['expectResponse'] }}</td>
                            <td>{{ one['realResponse'] }}</td>
                            
                        </tr>
                    {% else %}
                    <tr class='danger'>
                            
                        <td>{{ one['testTitle'] }}</td>
                        {% if one['checkStatus'] %}
                            <td>成功</td>
                        {% else %}
                            <td>失败</td>
                        {% endif %} 
                        <td>{{ one['chaosCommand'] }}</td>
                        <td>{{ one['chaosId'] }}</td>
                        <td>{{ one['checkCommand'] }}</td>
                        <td>{{ one['expectResponse'] }}</td>
						<td>{{ one['realResponse'] }}</td>
                        
                        
                    </tr>

                    {% endif %}
					{% endfor %}
				</tbody>
			</table>
	</div>
</div>

</body>

</html>