Skip to content

Commit b514d43

Browse files
committed
Demo Dashboard
1 parent b93e3bc commit b514d43

File tree

4 files changed

+29
-7
lines changed

4 files changed

+29
-7
lines changed

src/Yakari.Demo.Web/Views/Home/Dashboard.cshtml

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,22 @@
11
@{
22
ViewData["Title"] = "Dashboard";
33
var list = (List<string>)ViewData["Data"];
4+
if (list == null)
5+
{
6+
list = new List<string>();
7+
}
48
}
9+
<h1>Demo Dashboard</h1>
10+
<hr/>
511
<h3>Tribe Name: @Html.Raw(ViewData["TribeName"])</h3>
6-
<h5>Member Name@Html.Raw(ViewData["MemberName"]) </h5>
12+
<h4>Member Name: @Html.Raw(ViewData["MemberName"])</h4>
13+
<hr />
714
<div class="row">
8-
Generate a cache item: <input type="button" id="btnGenerate" class="btn btn-link btn-" value="Generate" onclick="" />
15+
Generate a cache item: <input type="button" id="btnGenerate" class="btn btn-success" value="Generate" onclick="generateCacheItem();" />
916
</div>
1017
<div class="row">
11-
<ul><h3>All Cache Items:@Html.Raw(((List<string>)ViewData["Data"]).Count)</h3>
12-
@foreach (var k in (List<string>)ViewData["Data"])
18+
<ul><h3>All Cache Items:@Html.Raw(list.Count)</h3>
19+
@foreach (var k in list)
1320
{
1421
<li>@k</li>
1522
}

src/Yakari.Demo.Web/Views/Home/Index.cshtml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,11 @@
22
ViewData["Title"] = "Home Page";
33
}
44

5-
5+
<div class="row">
6+
<h1>Yakari</h1>
7+
<hr/>
8+
Yakari is simply in memory cache distributor.
9+
<br />
10+
<br />
11+
<div class="text-info">&nbsp;&nbsp;&nbsp;&nbsp;Project is aimed to reduce distributed caching systems serialization/deserialization and network operation costs. You simply work with your localCache, the GreatEagle observe's your operations and take care of everything. In yakari if you set 1 object it makes 1 serialization and 1 network operation, for first get operation it makes 1 network operation, 1 deserialization, after then there is no deserialization or network operation you can get your cache object from your localCache, how much you want.</div>
12+
</div>

src/Yakari.Demo.Web/Views/Shared/_Layout.cshtml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
</head>
2626
<body>
2727
<div class="navbar navbar-default">
28-
<div class="container-fluid">
28+
<div class="container">
2929
<div class="navbar-header" style="height: 68px;">
3030
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navbar" aria-expanded="false">
3131
<span class="sr-only">Toggle navigation</span>
Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,9 @@
1-
// Write your Javascript code.
1+
// Write your Javascript code.
2+
3+
var generateCacheItem = function (e) {
4+
$.ajax({
5+
url: '/api/cache/generate',
6+
type: 'GET',
7+
});
8+
return true;
9+
};

0 commit comments

Comments
 (0)