Skip to content

Commit 7109387

Browse files
committed
fixes #186 Razor template warnings with RecurseNodes.cshtml
1 parent c1e6818 commit 7109387

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

ExtentReports/Views/Spark/Partials/RecurseNodes.cshtml

+8-7
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@
66

77
@if (Model.HasChildren)
88
{
9-
@{
10-
var children = new List<Test>(Model.Children);
11-
}
9+
var children = new List<Test>(Model.Children);
10+
1211
<div class="accordion">
1312
@foreach (var child in children)
1413
{
@@ -17,14 +16,17 @@
1716
<div class="card-toolbar node-info">
1817
<ul class="list-inline d-none d-sm-block">
1918
<li><span class="badge @child.Status.ToString().ToLower()-bg log ">@child.Status</span></li>
20-
<li><span class='badge badge-default'>@Math.Round(child.TimeTaken, 2)</span></li>
19+
<li title="Time taken"><span class='badge badge-default'>@Math.Round(child.TimeTaken, 2)</span></li>
2120
</ul>
2221
</div>
2322
<div class="card-title">
2423
<div class="node" id="@child.Id">@child.Name</div>
24+
@if (child.HasAttributes)
25+
{
2526
<div class="node-attr">
2627
@Include("Attributes", child)
2728
</div>
29+
}
2830
@if (child.HasScreenCaptureDeep)
2931
{
3032
<div class="status-avatar float-right"><i class="fa fa-paperclip"></i></div>
@@ -33,9 +35,8 @@
3335
</div>
3436
@if (child.HasLog)
3537
{
36-
@{
37-
var css = child.Status != Status.Fail ? "collapse" : "";
38-
}
38+
var css = child.Status != Status.Fail ? "collapse" : "";
39+
3940
<div class="@css">
4041
<div class="card-body">
4142
@if (child.HasAnyLog)

0 commit comments

Comments
 (0)