Merge branch 'HomePageIndicator-#47' into Release0.1.4
This commit is contained in:
commit
63a96e77cf
@ -21,5 +21,7 @@ namespace Interfaces
|
|||||||
}
|
}
|
||||||
|
|
||||||
public List<Identifier> AssociatedIdentifiers { get; set; }
|
public List<Identifier> AssociatedIdentifiers { get; set; }
|
||||||
|
|
||||||
|
public bool State { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -82,6 +82,8 @@ namespace SQLiteRepository
|
|||||||
Id = card.Id
|
Id = card.Id
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
userObj.State = GetUserState(GetLogDirection(user.Id));
|
||||||
|
|
||||||
ret.Users.Add(userObj);
|
ret.Users.Add(userObj);
|
||||||
}
|
}
|
||||||
if (pageNumber == -1 && pageSize == -1)
|
if (pageNumber == -1 && pageSize == -1)
|
||||||
@ -98,6 +100,17 @@ namespace SQLiteRepository
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private bool GetUserState(LogDirectionDb logDirection)
|
||||||
|
{
|
||||||
|
switch (logDirection)
|
||||||
|
{
|
||||||
|
case LogDirectionDb.OUT:
|
||||||
|
return true;
|
||||||
|
default:
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public UserList Search(string searchParam)
|
public UserList Search(string searchParam)
|
||||||
{
|
{
|
||||||
_logger.Trace("Searching SQLite database for the term: {0}", searchParam);
|
_logger.Trace("Searching SQLite database for the term: {0}", searchParam);
|
||||||
|
|||||||
@ -61,6 +61,7 @@
|
|||||||
<table class="table table-striped">
|
<table class="table table-striped">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
|
<th class="col-md-1"></th>
|
||||||
<th class="col-md-3">First Name</th>
|
<th class="col-md-3">First Name</th>
|
||||||
<th class="col-md-3">Last Name</th>
|
<th class="col-md-3">Last Name</th>
|
||||||
<th class="col-md-1 text-center">Contractor</th>
|
<th class="col-md-1 text-center">Contractor</th>
|
||||||
@ -70,6 +71,14 @@
|
|||||||
</thead>
|
</thead>
|
||||||
<tbody data-bind="foreach: Users">
|
<tbody data-bind="foreach: Users">
|
||||||
<tr>
|
<tr>
|
||||||
|
<td class="valign text-center">
|
||||||
|
<!-- ko if: State -->
|
||||||
|
<span class="label label-success" style="display: block">IN</span>
|
||||||
|
<!-- /ko -->
|
||||||
|
<!-- ko if: !State -->
|
||||||
|
<span class="label label-danger" style="display: block">OUT</span>
|
||||||
|
<!-- /ko -->
|
||||||
|
</td>
|
||||||
<td class="valign" data-bind="text: FirstName"></td>
|
<td class="valign" data-bind="text: FirstName"></td>
|
||||||
<td class="valign" data-bind="text: LastName"></td>
|
<td class="valign" data-bind="text: LastName"></td>
|
||||||
<td class="valign text-center"><span data-bind="css:{ 'glyphicon glyphicon-ok': IsContractor}"></span></td>
|
<td class="valign text-center"><span data-bind="css:{ 'glyphicon glyphicon-ok': IsContractor}"></span></td>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user