yuriy0803 2 years ago
parent
commit
d03ebc9038
  1. 73
      install.sh
  2. 24
      www/app/controllers/account.js
  3. 520
      www/app/controllers/account/index.js
  4. 2
      www/app/controllers/application.js
  5. 564
      www/app/controllers/index.js
  6. 12
      www/app/helpers/format-threshold.js
  7. 7
      www/app/helpers/wallet.js
  8. 2
      www/app/helpers/with-metric-prefix.js
  9. 73
      www/app/index.html
  10. 91
      www/app/models/block.js
  11. 1
      www/app/router.js
  12. 619
      www/app/styles/app.css
  13. 5
      www/app/templates/about.hbs
  14. 63
      www/app/templates/account.hbs
  15. 73
      www/app/templates/account/index.hbs
  16. 68
      www/app/templates/account/mining.hbs
  17. 18
      www/app/templates/account/payouts.hbs
  18. 63
      www/app/templates/account/rewards.hbs
  19. 5
      www/app/templates/account/settings.hbs
  20. 4
      www/app/templates/application.hbs
  21. 13
      www/app/templates/blocks.hbs
  22. 32
      www/app/templates/blocks/block.hbs
  23. 41
      www/app/templates/blocks/immature.hbs
  24. 41
      www/app/templates/blocks/index.hbs
  25. 26
      www/app/templates/blocks/pending.hbs
  26. 2
      www/app/templates/finders.hbs
  27. 29
      www/app/templates/help.hbs
  28. 210
      www/app/templates/index.hbs
  29. 24
      www/app/templates/luck.hbs
  30. 11
      www/app/templates/miners.hbs
  31. 28
      www/app/templates/payments.hbs
  32. 45
      www/config/environment.js

73
install.sh

@ -58,35 +58,94 @@ module.exports = function (environment) {
rootURL: '/', rootURL: '/',
locationType: 'hash', locationType: 'hash',
EmberENV: { EmberENV: {
FEATURES: {} FEATURES: {
// Here you can enable experimental features on an ember canary build
// e.g. 'with-controller': true
}
}, },
APP: { APP: {
// API host and port
ApiUrl: '//$ip_address/', ApiUrl: '//$ip_address/',
HttpHost: 'http://$ip_address',
// HTTP mining endpoint
HttpHost: '$ip_address',
HttpPort: 8888, HttpPort: 8888,
// Stratum mining endpoint
StratumHost: '$ip_address', StratumHost: '$ip_address',
StratumPort: 8008, StratumPort: 8008,
// The ETC network
Unit: 'ETC', Unit: 'ETC',
Currency: 'USD', Mining: 'SOLO',
PoolFee: '1%',
// Fee and payout details
PoolFee: '1.0%',
PayoutThreshold: '0.5 ETC', PayoutThreshold: '0.5 ETC',
BlockReward: 2.56, BlockReward: 2.56,
BlockTime: 13.2
// For network hashrate (change for your favourite fork)
BlockTime: 14.4,
highcharts: {
main: {
enabled: true,
height: 200,
type: 'spline',
color: '',
labelColor: '#909090',
lineColor: '#404850',
tickColor: '#404850',
gridLineColor: '#404850',
gridLineWidthX: 1,
gridLineWidthY: 1,
backgroundColor: 'transparent',
title: '',
ytitle: '',
interval: 180000,
chartInterval: 900000
},
account: {
enabled: true,
height: 300,
type: 'spline',
color: ['', ''],
title: '',
ytitle: '',
interval: 180000,
chartInterval: 900000,
paymentInterval: 30000
}
}
} }
}; };
if (environment === 'development') { if (environment === 'development') {
ENV.APP.ApiUrl = 'http://localhost:8080/'; /* Override ApiUrl just for development, while you are customizing
frontend markup and css theme on your workstation.
*/
ENV.APP.ApiUrl = 'http://localhost:8080/'
// ENV.APP.LOG_RESOLVER = true;
// ENV.APP.LOG_ACTIVE_GENERATION = true;
// ENV.APP.LOG_TRANSITIONS = true;
// ENV.APP.LOG_TRANSITIONS_INTERNAL = true;
// ENV.APP.LOG_VIEW_LOOKUPS = true;
} }
if (environment === 'test') { if (environment === 'test') {
// Testem prefers this...
ENV.locationType = 'none'; ENV.locationType = 'none';
// keep test console output quieter
ENV.APP.LOG_ACTIVE_GENERATION = false; ENV.APP.LOG_ACTIVE_GENERATION = false;
ENV.APP.LOG_VIEW_LOOKUPS = false; ENV.APP.LOG_VIEW_LOOKUPS = false;
ENV.APP.rootElement = '#ember-testing'; ENV.APP.rootElement = '#ember-testing';
} }
if (environment === 'production') {} if (environment === 'production') {
}
return ENV; return ENV;
}; };

24
www/app/controllers/account.js

@ -16,6 +16,12 @@ export default Ember.Controller.extend({
}, },
}), }),
roundSharesN: Ember.computed("stats", "model", {
get() {
return parseInt(this.get("model.stats.roundShares") / 10000000000);
},
}),
roundPercent: Ember.computed('stats', 'model', { roundPercent: Ember.computed('stats', 'model', {
get() { get() {
var percent = this.get('model.roundShares') / this.get('stats.nShares'); var percent = this.get('model.roundShares') / this.get('stats.nShares');
@ -30,25 +36,11 @@ export default Ember.Controller.extend({
} }
}), }),
earnPerDayToken: Ember.computed('model', { earnPerDay: Ember.computed('model', {
get() { get() {
return 24 * 60 * 60 / this.get('applicationController.blockTime') * this.get('config').BlockReward * return 24 * 60 * 60 / this.get('applicationController.blockTime') * this.get('config').BlockReward *
this.getWithDefault('model.hashrate') / this.get('hashrate'); this.getWithDefault('model.hashrate') / this.get('hashrate');
} }
}),
earnPerDayUsd: Ember.computed('model', {
get() {
return 24 * 60 * 60 / this.get('applicationController.blockTime') * this.get('config').BlockReward *
this.getWithDefault('model.hashrate') / this.get('hashrate') * this.get ('model.exchangedata.price_usd');
}
}),
earnTotalPaid: Ember.computed('model', {
get() {
return 1 * this.get ('model.exchangedata.price_usd') * this.get ('model.stats.paid');
}
}) })
}); });

520
www/app/controllers/account/index.js

@ -1,91 +1,190 @@
import Ember from 'ember'; import Ember from 'ember';
export default Ember.Controller.extend({ export default Ember.Controller.extend({
applicationController: Ember.inject.controller('application'), applicationController: Ember.inject.controller('application'),
netstats: Ember.computed.reads('applicationController'), netstats: Ember.computed.reads('applicationController'),
stats: Ember.computed.reads('applicationController.model.stats'), stats: Ember.computed.reads('applicationController.model.stats'),
config: Ember.computed.reads('applicationController.config'), config: Ember.computed.reads('applicationController.config'),
hashrate: Ember.computed.reads('applicationController.hashrate'), hashrate: Ember.computed.reads('applicationController.hashrate'),
chartOptions: Ember.computed("model.hashrate", { chartOptions: Ember.computed("model.hashrate", {
get() {
var e = this,
t = e.getWithDefault("model.minerCharts"),
a = {
chart: {
backgroundColor: "rgba(255, 255, 255, 0.1)",
type: "column",
marginRight: 10,
height: 300,
events: {
load: function() {
var series = this.series[0];
setInterval(function() {
var x = (new Date()).getTime(),
y = e.getWithDefault("model.currentHashrate") / 1000000;
series.addPoint([x, y], true, true);
}, 1090000000);
}
}
},
title: {
text: ""
},
xAxis: {
ordinal: false,
type: "datetime",
dateTimeLabelFormats: {
millisecond: "%H:%M:%S",
second: "%H:%M:%S",
minute: "%H:%M",
hour: "%H:%M",
day: "%e. %b",
week: "%e. %b",
month: "%b '%y",
year: "%Y"
}
},
yAxis: {
title: {
text: "HASHRATE"
},
//min: 0,
softMin: e.getWithDefault("model.currentHashrate") / 1.1,
softMax: e.getWithDefault("model.currentHashrate") * 1.2
},
plotLines: [{
value: 0,
width: 1,
color: "#808080"
}],
legend: {
enabled: true
},
tooltip: {
formatter: function() {
return this.y > 1000000000000 ? "<b>" + this.point.d + "<b><br>Hashrate&nbsp;" + (this.y / 1000000000000).toFixed(2) + "&nbsp;TH/s</b>" : this.y > 1000000000 ? "<b>" + this.point.d + "<b><br>Hashrate&nbsp;" + (this.y / 1000000000).toFixed(2) + "&nbsp;GH/s</b>" : this.y > 1000000 ? "<b>" + this.point.d + "<b><br>Hashrate&nbsp;" + (this.y / 1000000).toFixed(2) + "&nbsp;MH/s</b>" : "<b>" + this.point.d + "<b><br>Hashrate&nbsp;<b>" + this.y.toFixed(2) + "&nbsp;H/s</b>";
},
useHTML: true
},
exporting: {
enabled: false
},
navigation: {
enabled: true,
},
scrollbar: {
barBackgroundColor: 'gray',
barBorderRadius: 7,
barBorderWidth: 0,
buttonBackgroundColor: 'gray',
buttonBorderWidth: 0,
buttonBorderRadius: 7,
trackBackgroundColor: 'none',
trackBorderWidth: 1,
trackBorderRadius: 8,
trackBorderColor: '#CCC'
},
series: [{
color: "#E99002",
name: "Average Hashrate",
type: 'spline',
tooltip: {
valueDecimals: 2
},
data: function() {
var e, a = [];
if (null != t) {
for (e = 0; e <= t.length - 1; e += 1) {
var n = 0,
r = 0,
l = 0;
r = new Date(1e3 * t[e].x);
l = r.toLocaleString();
n = t[e].minerLargeHash;
a.push({
x: r,
d: l,
y: n
});
}
} else { a.push({
x: 0,
d: 0,
y: 0
});
}
return a;
}()
}, {
name: "Current hashrate",
type: 'spline',
tooltip: {
valueDecimals: 2
},
data: function() {
var e, a = [];
if (null != t) {
for (e = 0; e <= t.length - 1; e += 1) {
var n = 0,
r = 0,
l = 0;
r = new Date(1e3 * t[e].x);
l = r.toLocaleString();
n = t[e].minerHash;
a.push({
x: r,
d: l,
y: n
});
}
} else { a.push({
x: 0,
d: 0,
y: 0
});
}
return a;
}()
}]
};
a.title.text = this.get('config.highcharts.account.title') || "";
a.yAxis.title.text = this.get('config.highcharts.account.ytitle') || "Hashrate";
a.chart.height = this.get('config.highcharts.account.height') || 300;
a.chart.type = this.get('config.highcharts.account.type') || 'spline';
var colors = this.get('config.highcharts.account.color');
a.series[0].color = colors[0] || 'rgba(25,148,184)';
a.series[1].color = colors[1] || 'rgba(233,144,2)';
return a;
}
}),
shareChart: Ember.computed("model.hashrate", {
get() { get() {
var e = this, var e = this,
t = e.getWithDefault("model.minerCharts"), t = e.getWithDefault("model.shareCharts"),
a = { a = {
chart: { chart: {
backgroundColor: "rgba(255, 255, 255, 0.1)", backgroundColor: "rgba(255, 255, 255, 0.1)",
type: "spline", type: "column",
marginRight: 10, marginRight: 10,
height: 290, height: 180
events: { // events: {
load: function () { /* load: function() {
var series = this.series[0]; var series = this.series[0];
setInterval(function () { setInterval(function() {
var x = (new Date()).getTime(), var x = (new Date()).getTime(),
y = e.getWithDefault("model.currentHashrate") / 1000000; y = e.getWithDefault("model.workersOnline") / 1000000;
series.addPoint([x, y], true, true); series.addPoint([x, y], true, true);
}, 1090000000); }, 1090000000);
} } */
} // }
}, },
title: { title: {
text: "" text: ""
}, },
////// xAxis: {
rangeSelector: {
enabled: true,
selected: 4,
allButtonsEnabled: true,
inputDateFormat: '%Y/%m/%d %H:%M',
inputEditDateFormat: '%Y/%m/%d %H:%M',
inputEnabled: false,
buttons: [{
type: 'hour',
count: 1,
text: '1h'
},
{
type: 'hour',
count: 2,
text: '2h'
},
{
type: 'hour',
count: 4,
text: '4h'
},
{
type: 'hour',
count: 6,
text: '6h'
},
{
type: 'hour',
count: 12,
text: '12h'
},
{
type: 'all',
text: 'All'
}
],
},
navigator: {
enabled: true
},
credits: {
enabled: false,
position: {
align: 'right',
x: -10,
verticalAlign: 'bottom',
y: -5
},
href: "https://highcharts.com",
text: "Highcharts"
},
///////
xAxis: {
ordinal: false, ordinal: false,
labels: { labels: {
style: { style: {
@ -104,48 +203,66 @@ export default Ember.Controller.extend({
year: "%Y" year: "%Y"
} }
}, },
//rangeSelector: {
// selected: 1,
// },
yAxis: { yAxis: {
title: { title: {
text: "Hashrate", text: "Shares",
style: { style: {
color: "#000" color: "#000"
}, },
}, },
labels: { labels: {
style: { style: {
color: "#000" color: "#000"
} }
}, }
//softMin: e.getWithDefault("model.currentHashrate") / 1000000, //softMin: e.getWithDefault("model.currentHashrate") / 1000000,
//softMax: e.getWithDefault("model.currentHashrate") / 1000000, //softMax: e.getWithDefault("model.currentHashrate") / 1000000,
}, },
plotOptions: {
series: {
marginleft: 0,
pointWidth: 10
// marker: {
// enabled: false
// }
},
column: {
stacking: 'normal',
grouping: false
//shadow: false
//borderWidth: 0
}
},
plotLines: [{ plotLines: [{
value: 0, value: 0,
width: 1, width: 1,
color: "#808080" color: "#aaaaaa"
}], }],
legend: { legend: {
enabled: true, enabled: true,
itemStyle: itemStyle:
{ {
color: "#000" color: "#000"
}, },
}, },
tooltip: { tooltip: {
formatter: function () { formatter: function() {
return this.y > 1000000000000 ? "<b>" + this.point.d + "<b><br>Hashrate&nbsp;" + (this.y / 1000000000000).toFixed(2) + "&nbsp;TH/s</b>" : this.y > 1000000000 ? "<b>" + this.point.d + "<b><br>Hashrate&nbsp;" + (this.y / 1000000000).toFixed(2) + "&nbsp;GH/s</b>" : this.y > 1000000 ? "<b>" + this.point.d + "<b><br>Hashrate&nbsp;" + (this.y / 1000000).toFixed(2) + "&nbsp;MH/s</b>" : "<b>" + this.point.d + "<b><br>Hashrate&nbsp;<b>" + this.y.toFixed(2) + "&nbsp;H/s</b>"; return this.y > 1000000000000 ? "<b>" + this.point.d + "<b><br>Shares&nbsp;" + (this.y / 1000000000000) + "</b>" : this.y > 1000000000 ? "<b>" + this.point.d + "<b><br>Shares&nbsp;" + (this.y / 1000000000) + "</b>" : this.y > 1000000 ? "<b>" + this.point.d + "<b><br>Shares&nbsp;" + (this.y / 1000000) + "</b>" : "<b>" + this.point.d + "<b><br>Shares&nbsp;<b>" + this.y + "</b>";
}, },
useHTML: true useHTML: true
}, },
exporting: { exporting: {
enabled: true enabled: false
}, },
series: [{ series: [{
color: "#15BD27", color: "#15BD27",
name: "3 hours average hashrate", name: "Valid share",
data: function () { data: function() {
var e, a = []; var e, a = [];
if (null != t) { if (null != t) {
for (e = 0; e <= t.length - 1; e += 1) { for (e = 0; e <= t.length - 1; e += 1) {
@ -154,7 +271,7 @@ export default Ember.Controller.extend({
l = 0; l = 0;
r = new Date(1e3 * t[e].x); r = new Date(1e3 * t[e].x);
l = r.toLocaleString(); l = r.toLocaleString();
n = t[e].minerLargeHash; n = t[e].valid;
a.push({ a.push({
x: r, x: r,
d: l, d: l,
@ -163,17 +280,19 @@ export default Ember.Controller.extend({
} }
} else { } else {
a.push({ a.push({
x: 0, x: 0,
d: 0, d: 0,
y: 0 y: 0
}); });
} }
return a; return a;
}() }()
}, { }, {
name: "30 minutes average hashrate",
name: "Stale share",
color: "#E99002", color: "#E99002",
data: function () { data: function() {
var e, a = []; var e, a = [];
if (null != t) { if (null != t) {
for (e = 0; e <= t.length - 1; e += 1) { for (e = 0; e <= t.length - 1; e += 1) {
@ -182,7 +301,7 @@ export default Ember.Controller.extend({
l = 0; l = 0;
r = new Date(1e3 * t[e].x); r = new Date(1e3 * t[e].x);
l = r.toLocaleString(); l = r.toLocaleString();
n = t[e].minerHash; n = t[e].stale;
a.push({ a.push({
x: r, x: r,
d: l, d: l,
@ -198,146 +317,18 @@ export default Ember.Controller.extend({
} }
return a; return a;
}() }()
}] /* }, {
};
return a; name: "Workers",
} color: "#FF0000",
}), type: 'spline',
plotLines: [{
shareChart: Ember.computed("model.hashrate", { // value: 0,
get() {
var e = this,
t = e.getWithDefault("model.shareCharts"),
a = {
chart: {
backgroundColor: "rgba(255, 255, 255, 0.1)",
type: "column",
marginRight: 10,
height: 180
// events: {
/* load: function() {
var series = this.series[0];
setInterval(function() {
var x = (new Date()).getTime(),
y = e.getWithDefault("model.workersOnline") / 1000000;
series.addPoint([x, y], true, true);
}, 1090000000);
} */
// }
},
title: {
text: ""
},
xAxis: {
ordinal: false,
labels: {
style: {
color: "#000"
}
},
type: "datetime",
dateTimeLabelFormats: {
millisecond: "%H:%M:%S",
second: "%H:%M:%S",
minute: "%H:%M",
hour: "%H:%M",
day: "%e. %b",
week: "%e. %b",
month: "%b '%y",
year: "%Y"
}
},
//rangeSelector: {
// selected: 1,
// },
yAxis: {
title: {
text: "Shares",
style: {
color: "#000"
},
},
labels: {
style: {
color: "#000"
}
}
//softMin: e.getWithDefault("model.currentHashrate") / 1000000,
//softMax: e.getWithDefault("model.currentHashrate") / 1000000,
},
plotOptions: {
series: {
marginleft: 0,
pointWidth: 10
// marker: {
// enabled: false
// }
},
column: {
stacking: 'normal',
grouping: false
//shadow: false
//borderWidth: 0
}
},
plotLines: [{
value: 0,
width: 1, width: 1,
color: "#aaaaaa" color: "#aaaaaa"
}], }],
legend: { data: function() {
enabled: true,
itemStyle:
{
color: "#000"
},
},
tooltip: {
formatter: function () {
return this.y > 1000000000000 ? "<b>" + this.point.d + "<b><br>Shares&nbsp;" + (this.y / 1000000000000) + "</b>" : this.y > 1000000000 ? "<b>" + this.point.d + "<b><br>Shares&nbsp;" + (this.y / 1000000000) + "</b>" : this.y > 1000000 ? "<b>" + this.point.d + "<b><br>Shares&nbsp;" + (this.y / 1000000) + "</b>" : "<b>" + this.point.d + "<b><br>Shares&nbsp;<b>" + this.y + "</b>";
},
useHTML: true
},
exporting: {
enabled: false
},
series: [{
color: "#15BD27",
name: "Valid share",
data: function () {
var e, a = [];
if (null != t) {
for (e = 0; e <= t.length - 1; e += 1) {
var n = 0,
r = 0,
l = 0;
r = new Date(1e3 * t[e].x);
l = r.toLocaleString();
n = t[e].valid;
a.push({
x: r,
d: l,
y: n
});
}
} else {
a.push({
x: 0,
d: 0,
y: 0
});
}
return a;
}()
}, {
name: "Stale share",
color: "#E99002",
data: function () {
var e, a = []; var e, a = [];
if (null != t) { if (null != t) {
for (e = 0; e <= t.length - 1; e += 1) { for (e = 0; e <= t.length - 1; e += 1) {
@ -346,7 +337,7 @@ export default Ember.Controller.extend({
l = 0; l = 0;
r = new Date(1e3 * t[e].x); r = new Date(1e3 * t[e].x);
l = r.toLocaleString(); l = r.toLocaleString();
n = t[e].stale; n = t[e].workerOnline;
a.push({ a.push({
x: r, x: r,
d: l, d: l,
@ -361,77 +352,10 @@ export default Ember.Controller.extend({
}); });
} }
return a; return a;
}() }() */
/* }, {
name: "Workers",
color: "#FF0000",
type: 'spline',
plotLines: [{
// value: 0,
width: 1,
color: "#aaaaaa"
}],
data: function() {
var e, a = [];
if (null != t) {
for (e = 0; e <= t.length - 1; e += 1) {
var n = 0,
r = 0,
l = 0;
r = new Date(1e3 * t[e].x);
l = r.toLocaleString();
n = t[e].workerOnline;
a.push({
x: r,
d: l,
y: n
});
}
} else {
a.push({
x: 0,
d: 0,
y: 0
});
}
return a;
}() */
}] }]
}; };
return a; return a;
} }
}), })
earnPerHour: Ember.computed('model', { });
get() {
return 1 * 60 * 60 / this.get('config').BlockTime * this.get('config').BlockReward *
this.getWithDefault('model.hashrate') / this.get('hashrate');
}
}),
earnPerHour12: Ember.computed('model', {
get() {
return 12 * 60 * 60 / this.get('config').BlockTime * this.get('config').BlockReward *
this.getWithDefault('model.hashrate') / this.get('hashrate');
}
}),
earnPerDay: Ember.computed('model', {
get() {
return 24 * 60 * 60 / this.get('config').BlockTime * this.get('config').BlockReward *
this.getWithDefault('model.hashrate') / this.get('hashrate');
}
}),
earnPerWeek: Ember.computed('model', {
get() {
return 168 * 60 * 60 / this.get('config').BlockTime * this.get('config').BlockReward *
this.getWithDefault('model.hashrate') / this.get('hashrate');
}
}),
earnPerMonth: Ember.computed('model', {
get() {
return 672 * 60 * 60 / this.get('config').BlockTime * this.get('config').BlockReward *
this.getWithDefault('model.hashrate') / this.get('hashrate');
}
}),
});

2
www/app/controllers/application.js

@ -100,7 +100,7 @@ export default Ember.Controller.extend({
nextEpoch: Ember.computed('height', { nextEpoch: Ember.computed('height', {
get() { get() {
var epochOffset = (60000 - (this.getWithDefault('height', 1) % 60000)) * 1000 * this.get('blockTime'); var epochOffset = (60000 - (this.getWithDefault('height', 1) % 30000)) * 1000 * this.get('blockTime');
return Date.now() + epochOffset; return Date.now() + epochOffset;
} }
}) })

564
www/app/controllers/index.js

@ -1,305 +1,338 @@
function formatDate(date, format) { import Ember from 'ember';
date = new Date(date);
var formattedDate = {
year: date.getFullYear(),
month: date.getMonth() + 1 < 10 ? "0" + (date.getMonth() + 1) : date.getMonth() + 1,
day: date.getDate() < 10 ? "0" + date.getDate() : date.getDate(),
hours: date.getHours() < 10 ? "0" + date.getHours() : date.getHours(),
minutes: date.getMinutes() < 10 ? "0" + date.getMinutes() : date.getMinutes(),
seconds: date.getSeconds() < 10 ? "0" + date.getSeconds() : date.getSeconds(),
};
for (var key in formattedDate) {
format = format.replace(key, formattedDate[key]);
}
return format;
}
function formatHashrate(hashrate, showUnit) { export default Ember.Controller.extend({
var units = ["H/s", "KH/s", "MH/s", "GH/s", "TH/s", "PH/s"]; applicationController: Ember.inject.controller('application'),
var index = 0; stats: Ember.computed.reads('applicationController'),
while (hashrate > 1e3) { config: Ember.computed.reads('applicationController.config'),
hashrate /= 1e3;
index++;
}
return showUnit
? hashrate.toFixed(2) + " " + units[index]
: hashrate.toFixed(2) + " " + units[index];
}
function formatNumber(number) { cachedLogin: Ember.computed('login', {
var units = ["H/s", "KH/s", "MH/s", "GH/s", "TH/s", "PH/s"]; get() {
var index = 0; return this.get('login') || Ember.$.cookie('login');
while (number >= 1e3) { },
number /= 1e3; set(key, value) {
index++; Ember.$.cookie('login', value);
this.set('model.login', value);
return value;
} }
number = number < 10 ? number.toFixed(2) : number.toFixed(2); }),
return number.replace(".00", "") + " " + units[index];
} chartOptions: Ember.computed("model.hashrate", {
get() {
import Ember from "ember"; var now = new Date();
var e = this,
t = e.getWithDefault("stats.model.poolCharts"),
a = {
chart: {
backgroundColor: "rgba(255, 255, 255, 0.1)",
type: "spline",
height: 300,
marginRight: 10,
events: {
load: function() {
var self = this;
var chartInterval = setInterval(function() {
if (!self.series) {
clearInterval(chartInterval);
return;
}
var series = self.series[0];
var now = new Date();
export default Ember.Controller.extend({ var shift = false;
applicationController: Ember.inject.controller("application"), // partially update chart
stats: Ember.computed.reads("applicationController"), if (now - series.data[0].x > 18*60*60*1000) {
config: Ember.computed.reads("applicationController.config"), // show 18 hours ~ 15(min) * 74(points) ~ poolChartsNum: 74, poolChars: "0 */15 ..."
shift = true;
}
// check latest added temporary point and remove tempory added point for less than 5 minutes
if (series.data.length > 1 && series.data[series.data.length - 1].x - series.data[series.data.length - 2].x < 5*60*1000) {
series.removePoint(series.data.length - 1, false, false);
}
var x = now, y = e.getWithDefault("model.hashrate");
var d = x.toLocaleString();
series.addPoint({x: x, y: y, d:d}, true, shift);
}, e.get('config.highcharts.main.interval') || 60000);
}
}
},
title: {
text: "Our pool's hashrate"
},
xAxis: {
labels: {
style: {
color: "#000"
}
},
ordinal: false,
type: "datetime",
dateTimeLabelFormats: {
millisecond: "%H:%M:%S",
//second: "%H:%M:%S",
second: "%H:%M",
minute: "%H:%M",
hour: "%H:%M",
day: "%d.%m.%y",
week: "%m/%d",
month: "%b '%y",
year: "%Y"
},
gridLineWidth: 1,
gridLineColor: "#e6e6e6"
},
yAxis: {
title: {
text: " Pool Hash Rate",
style: {
color: "#000"
}
},
labels: {
style: {
color: "#000"
}
},
gridLineWidth: 1,
gridLineColor: "#e6e6e6"
},
plotLines: [{
value: 0,
width: 1,
color: "#000"
}],
legend: {
enabled: false
},
tooltip: {
formatter: function() {
function scale(v) {
var f = v;
var units = ['', 'K', 'M', 'G', 'T'];
for (var i = 0; i < 5 && f > 1000; i++) {
f /= 1000;
}
return f.toFixed(2) + ' ' + units[i];
}
var h = scale(this.point.y);
cachedLogin: Ember.computed("login", { return "<b>" + this.point.d + "</b><br />" +
get() { "<b>Pool Hashrate&nbsp;" + h + "H/s</b>"
return this.get("login") || Ember.$.cookie("login"); },
}, useHTML: true
set(key, value) { },
Ember.$.cookie("login", value); exporting: {
this.set("model.login", value); enabled: false
return value; },
}, plotOptions: {
line: {
pointInterval: 5
},
pointInterval:10
},
series: [{
color: "#1994b8",
name: "Hashrate",
shadow: true,
data: function() {
var a = [];
if (null != t) {
t.forEach(function(d) {
var x = new Date(1000 * d.x);
var l = x.toLocaleString();
var y = d.y;
a.push({x: x, y: y, d: l});
});
}
var l = now.toLocaleString();
var y = e.getWithDefault("model.hashrate");
var last = {x: now, y: y, d: l};
var interval = e.get('config.highcharts.main.interval') || 60000;
if (a.length > 0 && now - a[a.length - 1].x > interval) {
a.push(last);
}
return a;
}()
}]
};
a.title.text = this.getWithDefault('config.highcharts.main.title', "");
a.yAxis.title.text = this.getWithDefault('config.highcharts.main.ytitle', "Pool Hashrate");
a.chart.height = this.getWithDefault('config.highcharts.main.height', 300);
a.chart.type = this.getWithDefault('config.highcharts.main.type', 'spline');
a.chart.backgroundColor = this.getWithDefault('config.highcharts.main.backgroundColor', "rgba(255, 255, 255, 0.1)");
a.xAxis.labels.style.color = this.getWithDefault('config.highcharts.main.labelColor', "#000");
a.yAxis.labels.style.color = this.getWithDefault('config.highcharts.main.labelColor', "#000");
a.yAxis.title.style.color = this.getWithDefault('config.highcharts.main.labelColor', "#000");
a.xAxis.gridLineColor = this.getWithDefault('config.highcharts.main.gridLineColor', "#e6e6e6");
a.yAxis.gridLineColor = this.getWithDefault('config.highcharts.main.gridLineColor', "#e6e6e6");
a.xAxis.gridLineWidth = this.getWithDefault('config.highcharts.main.gridLineWidthX', "0");
a.yAxis.gridLineWidth = this.getWithDefault('config.highcharts.main.gridLineWidthY', "1");
a.xAxis.lineColor = this.getWithDefault('config.highcharts.main.lineColor', "#ccd6eb");
a.yAxis.lineColor = this.getWithDefault('config.highcharts.main.lineColor', "#ccd6eb");
a.xAxis.tickColor = this.getWithDefault('config.highcharts.main.tickColor', "#ccd6eb");
a.yAxis.tickColor = this.getWithDefault('config.highcharts.main.tickColor', "#ccd6eb");
return a;
}
}), }),
chartOptions: Ember.computed("model.hashrate", "model.poolCharts", "model.netCharts", { chartDiff: Ember.computed("model.hashrate", {
get() { get() {
var now = new Date(); var now = new Date();
var e = this, var e = this,
t = e.getWithDefault("model.poolCharts", []), t = e.getWithDefault("stats.model.netCharts"),
netCharts = e.getWithDefault("model.netCharts", []),
a = { a = {
chart: { chart: {
backgroundColor: "rgba(48, 97, 63, 0.0) ", backgroundColor: "rgba(255, 255, 255, 0.1)",
type: "areaspline", type: "spline",
height: 270, height: 300,
ignoreHiddenSeries: !1, marginRight: 10,
events: { events: {
load: function () { load: function() {
var self = this; var self = this;
var chartInterval = setInterval(function() {
var chartInterval = setInterval(function () { if (!self.series) {
var series = self.series;
if (!series) {
clearInterval(chartInterval); clearInterval(chartInterval);
return; return;
} }
var series = self.series[0];
t = e.getWithDefault("model.poolCharts", []);
netCharts = e.getWithDefault("model.netCharts", []);
// Hashrate chart
var hashData = [];
t.forEach(function (entry) {
var x = new Date(1000 * entry.x);
var l = x.toLocaleString();
var y = entry.y;
hashData.push({ x: x, y: y, d: l });
});
// Point for now
var now = new Date(); var now = new Date();
var l = now.toLocaleString();
var y = e.getWithDefault("model.hashrate"); var shift = false;
var lastHash = { x: now, y: y, d: l }; // partially update chart
{ hashData.push(lastHash); } if (now - series.data[0].x > 18*60*60*1000) {
// show 18 hours ~ 15(min) * 74(points) ~ poolChartsNum: 74, poolChars: "0 */15 ..."
// Network Difficulty chart shift = true;
var netDiffData = []; }
netCharts.forEach(function (entry) { // check latest added temporary point and remove tempory added point for less than 5 minutes
var x = new Date(1000 * entry.x); if (series.data.length > 1 && series.data[series.data.length - 1].x - series.data[series.data.length - 2].x < 5*60*1000) {
var l = x.toLocaleString(); series.removePoint(series.data.length - 1, false, false);
var y = entry.y; }
netDiffData.push({ x: x, y: y, d: l }); var x = now, y = e.getWithDefault("stats.model.netCharts");
}); var d = x.toLocaleString();
series.addPoint({x: x, y: y, d:d}, true, shift);
series[0].setData(hashData, true, {}, true); }, e.get('config.highcharts.main.interval') || 60000);
series[1].setData(netDiffData, true, {}, true); }
}
}, 88 * 1000);
},
},
}, },
title: { title: {
text: '<b>Ethereum Classic - PPLNS </b>', text: "Our pool's hashrate"
align: 'center',
x: 0,
y: 15,
useHTML: false,
style: {
color: "rgba(0,0,0,0.76)",
fontSize: '15px',
fontFamily: 'Arial',
fontWeight: '400'
}
}, },
xAxis: { xAxis: {
ordinal: false,
gridLineWidth: 1,
type: "datetime",
labels: { labels: {
style: { style: {
color: "#000", color: "#000"
}, }
formatter: function () {
return formatDate(this.value, "hours:minutes");
},
}, },
}, ordinal: false,
yAxis: [ type: "datetime",
{ dateTimeLabelFormats: {
index: 0, millisecond: "%H:%M:%S",
tickAmount: 4, //second: "%H:%M:%S",
title: { second: "%H:%M",
text: "Pool Hashrate", minute: "%H:%M",
style: { hour: "%H:%M",
color: "#32e400", day: "%d.%m.%y",
}, week: "%m/%d",
}, month: "%b '%y",
min: 0, year: "%Y"
labels: {
enabled: true,
style: {
color: "#000",
},
formatter: function () {
return formatNumber(this.value);
},
},
}, },
{ gridLineWidth: 1,
index: 1, gridLineColor: "#e6e6e6"
tickAmount: 4, },
title: { yAxis: {
text: "NETWORK DIFFICULTY", title: {
style: { text: " Pool Hash Rate",
color: "#007BFF", style: {
}, color: "#000"
}, }
min: 0,
labels: {
enabled: true,
style: {
color: "#000",
},
formatter: function () {
return formatNumber(this.value);
},
},
opposite: true,
}, },
], labels: {
plotOptions: { style: {
areaspline: { color: "#000"
marker: { }
enabled: false,
},
}, },
gridLineWidth: 1,
gridLineColor: "#e6e6e6"
}, },
plotLines: [ plotLines: [{
{ value: 0,
value: 0, width: 1,
width: 1, color: "#000"
color: "#000", }],
},
],
legend: { legend: {
symbolRadius: 4, enabled: false
borderWidth: 1,
itemStyle: {
color: "rgba(0,0,0,0.76)",
},
itemHoverStyle: {
color: "#000000",
},
itemHiddenStyle: {
color: "#A8A2A2",
},
}, },
tooltip: { tooltip: {
borderRadius: 7, formatter: function() {
borderWidth: 1, function scale(v) {
shared: false, var f = v;
headerFormat: "", var units = ['', 'K', 'M', 'G', 'T', 'P'];
shared: false, for (var i = 0; i < 5 && f > 1000; i++) {
headerFormat: "", f /= 1000;
}
return f.toFixed(2) + ' ' + units[i];
}
var h = scale(this.point.y);
return "<b>" + this.point.d + "</b><br />" +
"<b>Network Difficulty&nbsp;" + h + "H/s</b>"
},
useHTML: true
}, },
exporting: { exporting: {
enabled: false, enabled: false
}, },
series: [ plotOptions: {
{ line: {
yAxis: 0, pointInterval: 5
name: "Pool Hashrate",
fillColor: "rgba(49, 227, 0, 0.22)",
color: "#32e400",
tooltip: {
pointFormatter: function () {
return (
formatDate(this.x, "day.month.year hours:minutes") +
"<br><b>Pool Hashrate: " +
formatHashrate(this.y, true) +
"</b>"
);
},
},
states: {
inactive: {
opacity: 0.1,
},
},
data: function () {
var hashData = [];
if (null != t) {
t.forEach(function (entry) {
var x = new Date(1000 * entry.x);
var l = x.toLocaleString();
var y = entry.y;
hashData.push({ x: x, y: y, d: l });
});
}
var l = now.toLocaleString();
var y = e.getWithDefault("model.hashrate");
var lastHash = { x: now, y: y, d: l };
{ hashData.push(lastHash); }
return hashData;
}()
},
{
yAxis: 1,
name: "NETWORK DIFFICULTY",
fillColor: "rgba(212, 175, 55, 0.35)",
color: "#007BFF",
tooltip: {
pointFormatter: function () {
return (
formatDate(this.x, "day.month.year hours:minutes") +
"<br><b>NETWORK DIFFICULTY: " +
formatNumber(this.y) +
"</b>"
);
},
},
states: {
inactive: {
opacity: 0.1,
},
},
data: function () {
var netDiffData = [];
if (null != netCharts) {
netCharts.forEach(function (entry) {
var x = new Date(1000 * entry.x);
var l = x.toLocaleString();
var y = entry.y;
netDiffData.push({ x: x, y: y, d: l });
});
}
return netDiffData;
}()
}, },
], pointStart: Date.UTC(2022, 0, 1),
pointInterval: 24 * 3600 * 1000 // one day
},
series: [{
color: "#e99002",
name: "Hashrate",
shadow: true,
data: function() {
var a = [];
if (null != t) {
t.forEach(function(d) {
var x = new Date(1000 * d.x);
var l = x.toLocaleString();
var y = d.y;
a.push({x: x, y: y, d: l});
});
}
var l = now.toLocaleString();
var y = e.getWithDefault("stats.model.netCharts");
var last = {x: now, y: y, d: l};
var interval = e.get('config.highcharts.main.interval') || 60000;
if (a.length > 0 && now - a[a.length - 1].x > interval) {
a.push(last);
}
return a;
}()
}]
}; };
a.title.text = this.getWithDefault('config.highcharts.main.title', "");
a.yAxis.title.text = this.getWithDefault('config.highcharts.main.ytitle', "Pool Hashrate");
a.chart.height = this.getWithDefault('config.highcharts.main.height', 300);
a.chart.type = this.getWithDefault('config.highcharts.main.type', 'spline');
a.chart.backgroundColor = this.getWithDefault('config.highcharts.main.backgroundColor', "rgba(255, 255, 255, 0.1)");
a.xAxis.labels.style.color = this.getWithDefault('config.highcharts.main.labelColor', "#000");
a.yAxis.labels.style.color = this.getWithDefault('config.highcharts.main.labelColor', "#000");
a.yAxis.title.style.color = this.getWithDefault('config.highcharts.main.labelColor', "#000");
a.xAxis.gridLineColor = this.getWithDefault('config.highcharts.main.gridLineColor', "#e6e6e6");
a.yAxis.gridLineColor = this.getWithDefault('config.highcharts.main.gridLineColor', "#e6e6e6");
a.xAxis.gridLineWidth = this.getWithDefault('config.highcharts.main.gridLineWidthX', "0");
a.yAxis.gridLineWidth = this.getWithDefault('config.highcharts.main.gridLineWidthY', "1");
a.xAxis.lineColor = this.getWithDefault('config.highcharts.main.lineColor', "#ccd6eb");
a.yAxis.lineColor = this.getWithDefault('config.highcharts.main.lineColor', "#ccd6eb");
a.xAxis.tickColor = this.getWithDefault('config.highcharts.main.tickColor', "#ccd6eb");
a.yAxis.tickColor = this.getWithDefault('config.highcharts.main.tickColor', "#ccd6eb");
return a; return a;
}, }
}), }),
dag: Ember.computed("stats", "model", { dag: Ember.computed("stats", "model", {
get() { get() {
var percent = (this.get("epoch") * 8192) / 1024 / 1024 + 1; var percent = (this.get("epoch") * 8192) / 1024 / 1024 + 1;
@ -309,10 +342,9 @@ export default Ember.Controller.extend({
return percent; return percent;
}, },
}), }),
epoch: Ember.computed("model.stats", { epoch: Ember.computed("model.stats", {
get() { get() {
return parseInt(this.get("applicationController.height") / 30000); return parseInt(this.get("applicationController.height") / 30000);
}, },
}), }),
}); });

12
www/app/helpers/format-threshold.js

@ -1,11 +1,11 @@
import { helper as buildHelper } from '@ember/component/helper'; import { helper as buildHelper } from '@ember/component/helper';
export function formatBalance(value) { export function formatBalance(value) {
if (value < 0) { if (value < 0) {
value = 0; value = 0;
} }
value = value * 0.000000001; value = value * 0.000000001 ;
return value.toFixed(2); // Change toFixed(1) to toFixed(2) return value.toFixed(1);
} }
export default buildHelper(formatBalance); export default buildHelper(formatBalance);

7
www/app/helpers/wallet.js

@ -0,0 +1,7 @@
import Ember from 'ember';
export function formatTx(value) {
return value[0].substring(0, 26) + "..." + value[0].substring(26);
}
export default Ember.Helper.helper(formatTx);

2
www/app/helpers/with-metric-prefix.js

@ -13,7 +13,7 @@ export function withMetricPrefix(params/*, hash*/) {
n = n / 1000; n = n / 1000;
i++; i++;
} }
return n.toFixed(3) + ' ' + units[i - 1]; return n.toFixed(2) + ' ' + units[i - 1];
} }
export default Ember.Helper.helper(withMetricPrefix); export default Ember.Helper.helper(withMetricPrefix);

73
www/app/index.html

@ -1,40 +1,51 @@
<!DOCTYPE html> <!DOCTYPE html>
<html lang="en"> <html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>ETC Mining Pool</title>
<meta name="description" content="High profitability ETC mining pool"/>
<meta name="keywords" content="Ethereum, ethereum, Classic, classic, ETC, etc, pool, mining, cryptocurrency"/>
<script src="https://cdn.polyfill.io/v3/polyfill.min.js?features=Intl.~locale.en"></script>
{{content-for "head"}}
<link rel="stylesheet" href="{{rootURL}}assets/vendor.css">
<link rel="stylesheet" href="{{rootURL}}assets/open-etc-pool.css">
<link rel="shortcut icon" type="image/x-icon" href="{{rootURL}}favicon.png" />
{{content-for "head-footer"}}
</head>
<body>
{{content-for "body"}}
<script src="{{rootURL}}assets/vendor.js"></script> <head>
<script src="{{rootURL}}assets/open-etc-pool.js"></script> <meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>ETC Mining Pool</title>
<meta name="description" content="High profitability ETC mining pool" />
<meta name="keywords" content="Ethereum, ethereum, Classic, classic, ETC, etc, pool, mining, cryptocurrency" />
<script src="https://cdn.polyfill.io/v1/polyfill.min.js?features=Intl.~locale.en"></script>
{{content-for "head"}}
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.7.2/font/bootstrap-icons.css">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.5.0/css/all.css"
integrity="sha384-B4dIYHKNBt8Bc12p+WXckhzcICo0wtJAoU8YZTY5qE0Id1GSseTk6S+L3BlXeVIU" crossorigin="anonymous">
<link rel="stylesheet" href="{{rootURL}}assets/vendor.css">
<link rel="stylesheet" href="{{rootURL}}assets/open-etc-pool.css">
<link rel="shortcut icon" type="image/x-icon" href="{{rootURL}}etc.svg" />
{{content-for "head-footer"}}
</head>
{{content-for "body-footer"}} <body>
{{content-for "body"}}
<footer class="footer"> <script src="{{rootURL}}assets/vendor.js"></script>
<div class="container"> <script src="{{rootURL}}assets/open-etc-pool.js"></script>
<div class="text-center">
<div class="row"> {{content-for "body-footer"}}
<div class="col-md-12" style="text-align: center;">
<p class="text-muted" style="margin:20px 0">&copy; | <footer class="footer">
Powered by <a href="https://github.com/yuriy0803/open-etc-pool-friends" target="_blank">open-etc-pool-friends</a> <div class="container">
</p> <div class="text-center">
</div> <div class="row">
<div class="col-md-12" style="text-align: center;">
<p class="text-muted" style="margin:20px 0">2024 &copy; |
Powered by <i class="fa fa-home" aria-hidden="true"> <a href="https://open-etc-pool-friends"
target="_blank">open-etc-pool-friends</a></i> |
<i class='fas fa-wallet'> <a
href="https://etc.blockscout.com/address/0xFc9B271B1b03B60e5aD68CB89Bb1016b9eAc2baC"
target="_blank">Pool Wallet</a></i> |
<span class="bi bi-discord blue-color"> <a href="https://discord.com/invite/zdnuXm4uby"
target="_blank">Discord</a></span>
</p>
</div> </div>
</div> </div>
</div> </div>
</footer> </div>
</body> </footer>
</html> </body>
</html>

91
www/app/models/block.js

@ -1,52 +1,43 @@
import Ember from 'ember'; import EmberObject from '@ember/object';
import { computed } from '@ember/object';
// {
// "candidatesTotal": 0, var Block = EmberObject.extend({
// "hashrate": 0,
// "immatureTotal": 0, variance: computed('difficulty', 'shares', function() {
// "maturedTotal": 11, let percent = this.get('shares') / this.get('difficulty');
// "minersTotal": 0, if (!percent) {
// "nodes": [{ return 0;
// "difficulty": "2735271", }
// "height": "63151", return percent;
// "lastBeat": "1471098611", }),
// "name": "jee-test-pool"
// }], isLucky: computed('variance', function() {
// "now": 1471098614036, return this.get('variance') <= 1.0;
// "stats": { }),
// "lastBlockFound": 1471052210
// }
// } isSolo: computed('miningType', function() {
return this.get('miningType') == "solo";
var Block = Ember.Object.extend({ }),
variance: Ember.computed('difficulty', 'shares', function() {
var percent = this.get('shares') / this.get('difficulty'); isOk: computed('orphan', 'uncle', function() {
if (!percent) { return !this.get('orphan');
return 0; }),
}
return percent; lastBlockFound: Ember.computed('model', {
}), get() {
return parseInt(this.get('model.lastBlockFound')) || 0;
isLucky: Ember.computed('variance', function() { }
return this.get('variance') <= 1.0; }),
}),
formatReward: computed('reward', function() {
isHard: Ember.computed('variance', function() { if (!this.get('orphan')) {
return this.get('variance') >= 1.2; let value = parseInt(this.get('reward')) * 0.000000000000000001;
}), return value.toFixed(6);
} else {
isOk: Ember.computed('orphan', 'uncle', function() { return 0;
return !this.get('orphan'); }
}), })
formatReward: Ember.computed('reward', function() {
if (!this.get('orphan')) {
var value = parseInt(this.get('reward')) * 0.000000000000000001;
return value.toFixed(6);
} else {
return 0;
}
})
}); });
export default Block; export default Block;

1
www/app/router.js

@ -10,6 +10,7 @@ Router.map(function() {
this.route('payouts'); this.route('payouts');
this.route('rewards'); this.route('rewards');
this.route('settings'); this.route('settings');
this.route('mining');
}); });
this.route('not-found'); this.route('not-found');

619
www/app/styles/app.css

File diff suppressed because it is too large Load Diff

5
www/app/templates/about.hbs

@ -9,12 +9,7 @@
<h3>Details</h3> <h3>Details</h3>
<p> <p>
<ul> <ul>
<li>It's a solo mining pool.</li>
<li>Written in Go it's a rocket highly concurrent and low RAM consuming piece of code</li> <li>Written in Go it's a rocket highly concurrent and low RAM consuming piece of code</li>
<li>It's a stratum over a coin node with many options.</li>
<li>Each miner works independently of the others.</li>
<li>The block reward goes to only the miner who found it.</li>
<li>Block search time depends on your hashrate and luck.</li>
<li>High performance proxy</li> <li>High performance proxy</li>
<li>Payouts and block unlocking module</li> <li>Payouts and block unlocking module</li>
<li>Designed for 100% distributed setup</li> <li>Designed for 100% distributed setup</li>

63
www/app/templates/account.hbs

@ -9,19 +9,22 @@
</div> </div>
<div style="display: block;"> <div style="display: block;">
<i class="fa fa-bank"></i> Pending Balance: <span>{{format-balance model.stats.balance}}</span><br> <i class="fa fa-bank"></i> Pending Balance: <span>{{format-balance model.stats.balance}}</span><br>
<i class="fa fa-bank"></i> Your Threshold: <span>{{format-threshold model.threshold}} <i class="fa fa-bank"></i> Your Threshold: <span>{{format-threshold model.threshold}}</span><br>
{{config.Unit}}</span><br>
<small>Credited coins awaiting payout.</small> <small>Credited coins awaiting payout.</small>
</div> </div>
{{#if model.stats.payouttreshold}}
<div style="display: block;">
<i class="fa fa-bank"></i> Payout Treshold: <span>{{format-balance model.stats.payouttreshold}}</span><br>
</div>
{{/if}}
{{#if model.stats.pending}} {{#if model.stats.pending}}
<div style="display: block;"> <div style="display: block;">
<i class="fa fa-clock-o"></i> Current Payment: <span>{{format-balance model.stats.pending}}</span><br> <i class="fa fa-clock-o"></i> Current Payment: <span>{{format-balance model.stats.pending}}</span><br>
</div> </div>
{{/if}} {{/if}}
<div style="display: block;"><i class="fa fa-money"></i> Total Paid: <span>{{format-balance <div style="display: block;"><i class="fa fa-money"></i> Total Paid: <span>{{format-balance model.stats.paid}}</span></div>
model.stats.paid}}</span> / <span>{{format-balance earnTotalPaid}} $</span></div> <div style="display: block;"><i class="fa fa-money"></i> Last 24h Reward: <span>{{format-balance model.24hreward}}</span></div>
<div style="display: block;"><i class="fa fa-money"></i> Last 24h Reward: <span>{{format-balance <div style="display: block;"><i class="fa fa-calculator"></i>Earnings per day (24h avg):<span>{{format-number earnPerDay}}</span></div>
model.24hreward}}</span></div>
</div> </div>
<div class="col-md-4 stats"> <div class="col-md-4 stats">
{{#if model.stats.lastShare}} {{#if model.stats.lastShare}}
@ -29,34 +32,24 @@
Last Share Submitted: <span>{{format-relative (seconds-to-ms (string-to-int model.stats.lastShare))}}</span> Last Share Submitted: <span>{{format-relative (seconds-to-ms (string-to-int model.stats.lastShare))}}</span>
</div> </div>
{{/if}} {{/if}}
<div style="display: block;"><i class="fa fa-gears"></i> Workers Online: <span>{{format-number <div style="display: block;"><i class="fa fa-gears"></i> Workers Online: <span>{{format-number model.workersOnline}}</span></div>
model.workersOnline}}</span></div> <div style="display: block;"><i class="fa fa-tachometer"></i> Hashrate (1 Hour): <span>{{format-hashrate model.currentHashrate}}</span></div>
<div style="display: block;"><i class="fa fa-tachometer"></i> Hashrate (30m): <span>{{format-hashrate <div style="display: block;"><i class="fa fa-tachometer"></i> Hashrate (6 Hour): <span>{{format-hashrate model.hashrate}}</span></div>
model.currentHashrate}}</span></div> <div style="display: block;"><i class="fa fa-gears"></i> Shares found: <span>{{format-hashrate model.stats.lastShareDiff}}</span></div>
<div style="display: block;"><i class="fa fa-tachometer"></i> Hashrate (3h): <span>{{format-hashrate <div style="display: block;"><i class="fa fa-gears"></i> Mining Type:<span>{{#if model.miningTypeSolo}}<span>SOLO</span>{{else}}<span> PPLNS</span>{{/if}}</span></div>
model.hashrate}}</span></div>
<div style="display: block;"><i class="fa fa-gears"></i> Last Share Diff: <span>{{format-hashrate
model.stats.lastShareDiff}}</span></div>
<div style="display: block;">
<i class="fa fa-gears"></i> Your Round Share: <span>{{format-number roundPercent style='percent'
maximumFractionDigits='2'}}</span><br />
</div>
</div> </div>
<div class="col-md-4 stats"> <div class="col-md-4 stats">
<div style="display: block;"><i class="fa fa-tachometer"></i> Blocks Found: <span>{{format-number <div style="display: block;"><i class="fa fa-tachometer"></i> Blocks Found: <span>{{format-number model.stats.blocksFound fallback='0'}}</span></div>
model.stats.blocksFound fallback='0'}}</span></div>
<div style="display: block;"><i class="fa fa-paper-plane-o"></i> Total Payments: <span>{{format-number
model.paymentsTotal}}</span></div>
<div style="display: block;"><i class="fa fa-gears"></i> Personal Luck: <span>{{format-number PersonalLuck
style='percent'}}</span></div>
<div style="display: block;"><i class="fa fa-calculator"></i> Est. Earnings /day (3h avg): <span>{{format-number
earnPerDayToken maximumFractionDigits='1'}}</span> / <span>{{format-number earnPerDayUsd
maximumFractionDigits='1'}} $</span></div>
<div style="display: block;"> <div style="display: block;">
<i class="fa fa-clock-o"></i> <i class="fa fa-clock-o"></i>
Epoch Switch: <span>{{format-relative applicationController.nextEpoch units="hour"}}</span> Epoch Switch: <span>{{format-relative applicationController.nextEpoch units="hour"}}</span>
</div> </div>
<!--<div style="display: block;"><i class="fa fa-thermometer fa-fw"></i> My Shares in the last 'N' <span>{{roundSharesN}}</span></div>-->
<div style="display: block;"><i class="fa fa-gears"></i> Personal Luck: <span>{{format-number PersonalLuck style='percent'}}</span></div>
<div style="display: block;">
<i class="fa fa-gears"></i>PPLNS Your Round Share: <span>{{format-number roundPercent style='percent' maximumFractionDigits='0'}}</span><br/>
<small>Percent of your contribution to current round.</small>
</div>
</div> </div>
</div> </div>
</div> </div>
@ -65,19 +58,21 @@
<div class="container"> <div class="container">
<ul class="nav nav-tabs"> <ul class="nav nav-tabs">
{{#active-li currentWhen='account.index' role='presentation'}} {{#active-li currentWhen='account.index' role='presentation'}}
{{#link-to 'account.index'}}Workers <span class="label label-success">{{model.workersOnline}}</span> / <span {{#link-to 'account.index'}}Workers <span class="label label-success">{{model.workersOnline}}</span> / <span class="label label-danger">{{model.workersOffline}}</span>{{/link-to}}
class="label label-danger">{{model.workersOffline}}</span>{{/link-to}}
{{/active-li}} {{/active-li}}
{{#active-li currentWhen='account.rewards' role='presentation'}} {{#active-li currentWhen='account.rewards' role='presentation'}}
{{#link-to 'account.rewards'}}Rewards{{/link-to}} {{#link-to 'account.rewards'}}Rewards{{/link-to}}
{{/active-li}} {{/active-li}}
{{#active-li currentWhen='account.payouts' role='presentation'}} {{#active-li currentWhen='account.payouts' role='presentation'}}
{{#link-to 'account.payouts'}}Payouts{{/link-to}} {{#link-to 'account.payouts'}}Payouts{{/link-to}}
{{/active-li}} {{/active-li}}
{{#active-li currentWhen='account.settings' role='presentation'}} {{#active-li currentWhen='account.settings' role='presentation'}}
{{#link-to 'account.settings'}}Settings{{/link-to}} {{#link-to 'account.settings'}}Settings{{/link-to}}
{{/active-li}}
{{#active-li currentWhen='account.mining' role='presentation'}}
{{#link-to 'account.mining'}}PPLNS/SOLO{{/link-to}}
{{/active-li}} {{/active-li}}
</ul> </ul>
</div> </div>
{{outlet}} {{outlet}}

73
www/app/templates/account/index.hbs

@ -1,36 +1,6 @@
<div class="container"> <div class="container">
{{high-charts mode=chartMode chartOptions=chartOptions content=chartData}} {{high-charts mode=chartMode chartOptions=chartOptions content=chartData}}
{{high-charts mode=chartMode chartOptions=shareChart content=chartData}} {{high-charts mode=chartMode chartOptions=shareChart content=chartData}}
<table class="table table-condensed table-striped">
<thead>
<tr class="active">
<th>Time</th>
<th>Amount</th>
</tr>
</thead>
<tbody>
<tr>
<td><span>Last 60 minutes</span></td>
<td><span>{{format-number earnPerHour maximumFractionDigits='8'}}</span></td>
</tr>
<tr>
<td><span>Last 12 hours</span></td>
<td><span>{{format-number earnPerHour12 maximumFractionDigits='8'}}</span></td>
</tr>
<tr>
<td><span>Last 24 hours</span></td>
<td>{{format-number earnPerDay maximumFractionDigits='8'}}</td>
</tr>
<tr>
<td><span>Last 7 days</span></td>
<td>{{format-number earnPerWeek maximumFractionDigits='8'}}</td>
</tr>
<tr>
<td><span>Last 30 days</span></td>
<td>{{format-number earnPerMonth maximumFractionDigits='8'}}</td>
</tr>
</tbody>
</table>
{{#if model.workers}} {{#if model.workers}}
<h4>Your Workers</h4> <h4>Your Workers</h4>
<div class="table-responsive"> <div class="table-responsive">
@ -38,8 +8,7 @@
<thead> <thead>
<tr> <tr>
<th>ID</th> <th>ID</th>
<th>Hashrate (rough, short average)</th> <th>Current Hashrate / Average Hashrate</th>
<th>Hashrate (accurate, long average)</th>
<th>Hostname</th> <th>Hostname</th>
<th>Port Difficulty</th> <th>Port Difficulty</th>
<th>Blocks</th> <th>Blocks</th>
@ -49,38 +18,30 @@
</thead> </thead>
<tbody> <tbody>
{{#each-in model.workers as |k v|}} {{#each-in model.workers as |k v|}}
<tr class="{{if v.offline " warning" "success" }}"> <tr class="{{if v.offline "warning" "success"}}">
<td>{{k}}</td> <td>{{k}}</td>
<td>{{format-hashrate v.hr}} {{#if v.w_stat_s}}<i class="fa fa-arrow-up" style="color:rgb(0, 9, 128)" <td>{{format-hashrate v.hr}} {{#if v.w_stat_s}}<i class="fa fa-arrow-up" style="color:rgb(0, 9, 128)" aria-hidden="true"></i>{{else}}<i class="fa fa-arrow-down" style="color:red" aria-hidden="true"></i>{{/if}} / {{format-hashrate v.hr2}} {{#if v.w_stat}}<i class="fa fa-arrow-up" style="color:rgb(0, 9, 128)" aria-hidden="true"></i>{{else}}<i class="fa fa-arrow-down" style="color:red" aria-hidden="true"></i>{{/if}}</td>
aria-hidden="true"></i>{{else}}<i class="fa fa-arrow-down" style="color:red" <td>{{v.hostname}}</td>
aria-hidden="true"></i>{{/if}}</td> <td><span class="label label-success">{{format-hashrate v.portDiff}}</span></td>
<td>{{format-hashrate v.hr2}} {{#if v.w_stat}}<i class="fa fa-arrow-up" style="color:rgb(0, 9, 128)" <td>{{v.blocks}}</td>
aria-hidden="true"></i>{{else}}<i class="fa fa-arrow-down" style="color:red" <td><span class="text-green">{{v.valid}}</span> ({{v.v_per}}%) / <span class="text-yellow">{{v.stale}}</span> ({{v.s_per}}%) / <span class="text-red">{{v.invalid}}</span> ({{v.i_per}}%)</td>
aria-hidden="true"></i>{{/if}}</td> <td>{{format-relative (seconds-to-ms v.lastBeat)}}</td>
<td>{{v.hostname}}</td> </tr>
<td><span class="label label-success">{{format-hashrate v.portDiff}}</span></td>
<td>{{v.blocks}}</td>
<td><span class="text-green">{{v.valid}}</span> ({{v.v_per}}%) / <span class="text-yellow">{{v.stale}}</span>
({{v.s_per}}%) / <span class="text-red">{{v.invalid}}</span> ({{v.i_per}}%)</td>
<td>{{format-relative (seconds-to-ms v.lastBeat)}}</td>
</tr>
{{/each-in}} {{/each-in}}
</tbody> </tbody>
</table> </table>
</div> </div>
{{else}} {{else}}
<h3>No workers online</h3> <h3>No workers online</h3>
{{/if}} {{/if}}
<div class="alert alert-info" role="alert"> <div class="alert alert-info" role="alert">
<span class="sr-only">Notice:</span> <span class="sr-only">Notice:</span>
Your average hashrate will be smoothly adjusted until you have shares to fullfill estimation window.<br /> Your average hashrate will be smoothly adjusted until you have shares to fullfill estimation window.<br/>
There are two windows, long and short, first is equal to about 30 minutes and long window is usually equal to 3 There are two windows, long and short, first is equal to about 1 hours and long window is usually equal to 6 hours.<br/>
hours.<br />
Dead (sick) workers will be highlighted in a table of workers if they didn't submit a share for 1/2 of short window, Dead (sick) workers will be highlighted in a table of workers if they didn't submit a share for 1/2 of short window,
so you can perform maintenance of your rigs. so you can perform maintenance of your rigs.
</div> </div>
<div class="alert alert-info" role="alert"> <div class="alert alert-info" role="alert">
<strong>Your bulk stats JSON API URL:</strong> <a <strong>Your bulk stats JSON API URL:</strong> <a href="/api/accounts/{{model.login}}">/api/accounts/{{model.login}}</a>
href="/api/accounts/{{model.login}}">/api/accounts/{{model.login}}</a>
</div> </div>
</div> </div>

68
www/app/templates/account/mining.hbs

@ -0,0 +1,68 @@
<div class="container">
<div id="mining" style="margin-top:50px;" class="col-md-6 col-md-offset-3 col-sm-8 col-sm-offset-2">
<div class="row">
<div id="alertSuccess" class="alert alert-success" role="alert">
Success
</div>
<div id="alertError" class="alert alert-danger" role="alert">
<button type="button" class="close" data-dismiss="alert" aria-label="Close">
<span aria-hidden="true">&times;</span></button>
Error
</div>
</div>
<form action="/api/mining" method="post">
<input type="hidden" id="login" name="login" value="{{model.login}}">
<div class="form-group">
<div class="funkyradio">
<div class="funkyradio-success">
<input type="radio" name="radio" id="radio2" value="pplns" checked="{{if model.miningTypePplns "true"}}" />
<label for="radio2">PPLNS Mining</label>
</div>
</div>
<div class="funkyradio">
<div class="funkyradio-danger">
<input type="radio" name="radio" id="radio1" value="solo" checked="{{if model.miningTypeSolo "true"}}" />
<label for="radio1">SOLO Mining</label>
</div>
</div>
</div>
<div class="form-group">
<label for="ip_address">Active Worker IP address </label>
<input class="form-control" name="ip_address" id="ip_address" placeholder="192.168.0.1" type="text">
<small id="ip_address" class="form-text text-dark">
Please complete your worker`s IP address in order to validate and save your settings.
</small>
</div>
<br>
<button type="submit" class="btn btn-primary">Submit</button>
</form>
</div>
</div>
<script>
$(document).ready(function () {
var $form = $('form');
$form.submit(function () {
$.post($(this).attr('action'), $(this).serialize(), function (response) {
if (response.result == "success") {
$('#alertSuccess').html(response.result);
$("#alertSuccess").fadeIn() //or fadeIn
setTimeout(function() {
$("#alertSuccess").fadeOut(); //or fadeOut
}, 5000);
} else {
$('#alertError').html(response.result);
$("#alertError").fadeIn() //or fadeIn
setTimeout(function() {
$("#alertError").fadeOut(); //or fadeOut
}, 5000);
}
}, 'json');
return false;
});
});
</script>

18
www/app/templates/account/payouts.hbs

@ -1,5 +1,5 @@
<div class="container"> <div class="container">
{{high-charts mode=chartMode chartOptions=chartPayment content=chartData}} {{high-charts mode=chartMode chartOptions=chartPayment content=chartData}}
{{#if model.payments}} {{#if model.payments}}
<h4>Your Latest Payouts</h4> <h4>Your Latest Payouts</h4>
<div class="table-responsive"> <div class="table-responsive">
@ -13,13 +13,13 @@
</thead> </thead>
<tbody> <tbody>
{{#each model.payments as |tx|}} {{#each model.payments as |tx|}}
<tr> <tr>
<td>{{format-date-locale tx.timestamp}}</td> <td>{{format-date-locale tx.timestamp}}</td>
<td> <td>
<a href="https://expedition.dev/tx/{{tx.tx}}" class="hash" rel="nofollow" target="_blank">{{tx.tx}}</a> <a href="https://etc.blockscout.com/tx/{{tx.tx}}" class="hash" rel="nofollow" target="_blank">{{tx.tx}}</a>
</td> </td>
<td>{{format-balance tx.amount}}</td> <td>{{format-balance tx.amount}}</td>
</tr> </tr>
{{/each}} {{/each}}
</tbody> </tbody>
</table> </table>
@ -27,4 +27,4 @@
{{else}} {{else}}
<h3>No payouts yet</h3> <h3>No payouts yet</h3>
{{/if}} {{/if}}
</div> </div>

63
www/app/templates/account/rewards.hbs

@ -3,62 +3,57 @@
<h4>Your Latest Rewards</h4> <h4>Your Latest Rewards</h4>
<table class="table table-condensed table-striped"> <table class="table table-condensed table-striped">
<thead> <thead>
<tr> <tr>
<th>Time</th> <th>Time</th>
<th>Blocks</th> <th>Blocks</th>
<th>Amount</th> <th>Amount</th>
<th>Luck</th> <th>Personal Luck</th>
<th>USD</th> </tr>
</tr> </thead>
</thead>
<tbody> <tbody>
{{#each model.sumrewards as |sumreward|}} {{#each model.sumrewards as |sumreward|}}
<tr> <tr>
<td>{{sumreward.name}}</td> <td>{{sumreward.name}}</td>
<td>{{sumreward.blocks}}</td> <td>{{sumreward.blocks}}</td>
<td>{{format-balance sumreward.reward}}</td> <td>{{format-balance sumreward.reward}}</td>
<td>{{format-number sumreward.personalLuck style='percent'}}</td> <td>
<td><em> {{format-number sumreward.averageLuck style='percent'}}
</td>
{{#if (eq config.Currency 'USD') }}
{{format-ethusd sumreward.reward model.exchangedata.price_usd}}
{{else}}
{{format-ethinr sumreward.reward model.exchangedata.price_inr}}
{{/if}}
</em></td>
</tr> </tr>
{{/each}} {{/each}}
</tbody> </tbody>
</table> </table>
<span class="label label-default">Immature</span> <span class="label label-success">Matured</span> <span class="label label-default">Immature</span> <span class="label label-success">Matured</span>
<table class="table table-condensed table-striped"> <table class="table table-condensed table-striped">
<thead> <thead>
<tr> <tr>
<th>Block Height</th> <th>Block Height</th>
<th>Time Found</th> <th>Time Found</th>
<th>Reward</th> <th>Reward</th>
<th>Your Round Share</th> <th>Round Share</th>
<th>Personal Luck</th> <th>Personal Luck</th>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
{{#each model.rewards as |tx|}} {{#each model.rewards as |tx|}}
<tr> <tr>
<td>{{format-number tx.blockheight}}</td> <td>{{format-number tx.blockheight}}</td>
<td>{{format-date-locale tx.timestamp}}</td> <td>{{format-date-locale tx.timestamp}}</td>
<td> <td>
{{#if tx.immature}} {{#if tx.immature}}
<span class="label label-default">{{format-balance tx.reward}}</span> <span class="label label-default">{{format-balance tx.reward}}</span>
{{else}} {{else}}
<span class="label label-success">{{format-balance tx.reward}}</span> <span class="label label-success">{{format-balance tx.reward}}</span>
{{/if}} {{/if}}
</td>
<td>{{format-number tx.percent style='percent' maximumFractionDigits='2'}}</td>
<td>
{{format-number tx.personalLuck style='percent'}}
</td> </td>
<td>{{format-number tx.percent style='percent' maximumFractionDigits='2'}}</td> </tr>
<td>{{format-number tx.personalLuck style='percent' maximumFractionDigits='2'}}</td>
</tr>
{{/each}} {{/each}}
</tbody> </tbody>
</table> </table>

5
www/app/templates/account/settings.hbs

@ -11,6 +11,7 @@
</div> </div>
</div> </div>
<form action="/api/settings" method="post"> <form action="/api/settings" method="post">
<div class="form-group"> <div class="form-group">
@ -20,7 +21,6 @@
placeholder="Enter email"> placeholder="Enter email">
<small id="emailHelp" class="form-text text-dark">We'll never share your email with anyone else.</small> <small id="emailHelp" class="form-text text-dark">We'll never share your email with anyone else.</small>
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="threshold">Payment Threshold</label> <label for="threshold">Payment Threshold</label>
<input class="form-control" id="threshold" name="threshold" placeholder="min 0.5 - max 10000" min="0.5" <input class="form-control" id="threshold" name="threshold" placeholder="min 0.5 - max 10000" min="0.5"
@ -28,7 +28,6 @@
<small id="thresholdHelp" class="form-text text-dark">Payment threshold in {{config.Unit}} (Min: 0.5, Max: <small id="thresholdHelp" class="form-text text-dark">Payment threshold in {{config.Unit}} (Min: 0.5, Max:
10000)</small> 10000)</small>
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="ip_address">Active Worker IP address</label> <label for="ip_address">Active Worker IP address</label>
<input class="form-control" name="ip_address" id="ip_address" placeholder="192.168.0.1" type="text"> <input class="form-control" name="ip_address" id="ip_address" placeholder="192.168.0.1" type="text">
@ -36,7 +35,6 @@
Please complete your worker`s IP address in order to validate and save your settings. Please complete your worker`s IP address in order to validate and save your settings.
</small> </small>
</div> </div>
<div class="form-group form-check"> <div class="form-group form-check">
<label class="form-check-label" for="worker_offline"> <label class="form-check-label" for="worker_offline">
<input type="checkbox" name="alertCheck" class="form-check-input" id="alertCheck" checked> Send a mail if one <input type="checkbox" name="alertCheck" class="form-check-input" id="alertCheck" checked> Send a mail if one
@ -44,7 +42,6 @@
my workers goes offline my workers goes offline
</label> </label>
</div> </div>
<button type="submit" class="btn btn-primary">Submit</button> <button type="submit" class="btn btn-primary">Submit</button>
</form> </form>

4
www/app/templates/application.hbs

@ -63,6 +63,7 @@
<script> <script>
$(document).mouseup(function (e) { $(document).mouseup(function (e) {
var container = $(".collapse"); var container = $(".collapse");
if (!container.is(e.target) // if the target of the click isn't the container... if (!container.is(e.target) // if the target of the click isn't the container...
&& container.has(e.target).length === 0) // ... nor a descendant of the container && container.has(e.target).length === 0) // ... nor a descendant of the container
{ {
@ -71,9 +72,10 @@
$("#navBtn").attr('aria-expanded', false); $("#navBtn").attr('aria-expanded', false);
$("#navbarSupportedContent").removeClass("show"); $("#navbarSupportedContent").removeClass("show");
} }
}); });
</script> </script>
</div> </div>
</div> </div>
{{outlet}} {{outlet}}

13
www/app/templates/blocks.hbs

@ -11,22 +11,19 @@
<div class="container"> <div class="container">
{{high-charts mode=stockChart chartOptions=chartOptions content=chartData}} {{high-charts mode=stockChart chartOptions=chartOptions content=chartData}}
{{#if model.luck}} {{#if model.luck}}
{{partial "luck"}} {{partial "luck"}}
{{/if}} {{/if}}
<ul class="nav nav-tabs"> <ul class="nav nav-tabs">
{{#active-li currentWhen='blocks.index' role='presentation'}} {{#active-li currentWhen='blocks.index' role='presentation'}}
{{#link-to 'blocks.index'}}Blocks <span class="badge alert-success">{{format-number {{#link-to 'blocks.index'}}Blocks <span class="badge alert-success">{{format-number model.maturedTotal}}</span>{{/link-to}}
model.maturedTotal}}</span>{{/link-to}}
{{/active-li}} {{/active-li}}
{{#active-li currentWhen='blocks.immature' role='presentation'}} {{#active-li currentWhen='blocks.immature' role='presentation'}}
{{#link-to 'blocks.immature'}}Immature <span class="badge alert-success">{{format-number {{#link-to 'blocks.immature'}}Immature <span class="badge alert-success">{{format-number model.immatureTotal}}</span>{{/link-to}}
model.immatureTotal}}</span>{{/link-to}}
{{/active-li}} {{/active-li}}
{{#active-li currentWhen='blocks.pending' role='presentation'}} {{#active-li currentWhen='blocks.pending' role='presentation'}}
{{#link-to 'blocks.pending'}}New Blocks <span class="badge alert-info">{{format-number {{#link-to 'blocks.pending'}}New Blocks <span class="badge alert-info">{{format-number model.candidatesTotal}}</span>{{/link-to}}
model.candidatesTotal}}</span>{{/link-to}}
{{/active-li}} {{/active-li}}
</ul> </ul>
{{outlet}} {{outlet}}
</div> </div>

32
www/app/templates/blocks/block.hbs

@ -1,10 +1,10 @@
<tr> <tr>
<td> <td>
{{#if block.uncle}} {{#if block.uncle}}
<a href="{{t " links.blockExplorerLink_uncle"}}{{block.uncleHeight}}" rel="nofollow" target="_blank">{{format-number <a href="https://etc.blockscout.com/block/{{block.uncleHeight}}" rel="nofollow" target="_blank">{{format-number
block.height}}</a> block.height}}</a>
{{else}} {{else}}
<a href="{{t " links.blockExplorerLink_block"}}{{block.height}}" rel="nofollow" target="_blank">{{format-number <a href="https://etc.blockscout.com/block/{{block.height}}" rel="nofollow" target="_blank">{{format-number
block.height}}</a> block.height}}</a>
{{/if}} {{/if}}
</td> </td>
@ -12,33 +12,26 @@
{{#if block.uncle}} {{#if block.uncle}}
<td>{{#link-to 'account' block.finder class='hash'}}{{block.finder}}{{/link-to}}</td> <td>{{#link-to 'account' block.finder class='hash'}}{{block.finder}}{{/link-to}}</td>
{{else if block.orphan}} {{else if block.orphan}}
<span class="label label-danger">{{t "block.orphan"}}</span> <span class="label label-danger">Orphan</span>
{{else}} {{else}}
<td>{{#link-to 'account' block.finder class='hash'}}{{block.finder}}{{/link-to}}</td> <td>{{#link-to 'account' block.finder class='hash'}}{{block.finder}}{{/link-to}}</td>
{{/if}} {{/if}}
</td> </td>
<td>{{format-date-locale block.timestamp}}</td>
<td> <td>
{{#if block.uncle}} {{#if block.isSolo}}
<a href="{{t " links.blockExplorerLink_uncle"}}{{block.hash}}" class="hash" rel="nofollow" <span class="label label-danger">{{block.miningType}}</span>
target="_blank">{{block.hash}}</a>
{{else if block.orphan}}
<span class="label label-danger">{{t "block.orphan"}}</span>
{{else}} {{else}}
<a href="{{t " links.blockExplorerLink_block"}}{{block.hash}}" class="hash" rel="nofollow" <span class="label label-warning">{{block.miningType}}</span>
target="_blank">{{block.hash}}</a>
{{/if}} {{/if}}
</td> </td>
<td>{{format-date-locale block.timestamp}}</td>
<td> <td>
{{#if block.isLucky}} {{#if block.isLucky}}
<span class="label label-success">{{format-number block.variance style='percent'}}</span> <span class="label label-success">{{format-number block.variance style='percent'}}</span>
{{else}} {{else}}
{{#if block.isHard}}
<span class="label label-danger">{{format-number block.variance style='percent'}}</span>
{{else}}
<span class="label label-info">{{format-number block.variance style='percent'}}</span> <span class="label label-info">{{format-number block.variance style='percent'}}</span>
{{/if}} {{/if}}
{{/if}}
</td> </td>
<td> <td>
{{#if block.uncle}} {{#if block.uncle}}
@ -47,6 +40,13 @@
<span class="label label-primary">{{block.formatReward}}</span> <span class="label label-primary">{{block.formatReward}}</span>
{{/if}} {{/if}}
</td> </td>
<td>
{{#if block.uncle}}
<span class="label label-default">Uncle</span>
{{else if block.isOk}}
<span class="label label-primary">Block</span>
{{/if}}
</td>
<td>{{format-hashrate block.shareDiff}}</td> <td>{{format-hashrate block.shareDiff}}</td>
<td>{{block.worker}}</td> <td>{{block.worker}}</td>
</tr> </tr>

41
www/app/templates/blocks/immature.hbs

@ -1,26 +1,27 @@
{{#if model.immature}} {{#if model.immature}}
<h3>{{t "block.immature_blocks"}}</h3> <h4>Immature Blocks</h4>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-condensed table-striped"> <table class="table table-condensed table-striped">
<thead> <thead>
<tr> <tr>
<th>{{t "block.height"}}</th> <th>Height</th>
<th>{{t "block.login"}}</th> <th>Login</th>
<th>{{t "block.hash"}}</th> <th>Time Found</th>
<th>{{t "block.time_found"}}</th> <th>Type</th>
<th>{{t "block.variance"}}</th> <th>Variance</th>
<th>{{t "block.reward"}}</th> <th>Reward</th>
<th>{{t "block.shares"}}</th> <th>Type</th>
<th>{{t "block.worker"}}</th> <th>Shares/Diff</th>
</tr> <th>Worker ID</th>
</thead> </tr>
<tbody> </thead>
{{#each model.immature as |block|}} <tbody>
{{#each model.immature as |block|}}
{{partial "blocks/block"}} {{partial "blocks/block"}}
{{/each}} {{/each}}
</tbody> </tbody>
</table> </table>
</div> </div>
{{else}} {{else}}
<h3>{{t "block.no_immature_blocks_yet"}}</h3> <h3>No immature blocks yet</h3>
{{/if}} {{/if}}

41
www/app/templates/blocks/index.hbs

@ -1,26 +1,27 @@
{{#if model.matured}} {{#if model.matured}}
<h3>{{t "block.matured"}}</h3> <h4>Matured Blocks</h4>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-condensed table-striped"> <table class="table table-condensed table-striped">
<thead> <thead>
<tr> <tr>
<th>{{t "block.height"}}</th> <th>Height</th>
<th>{{t "block.login"}}</th> <th>Login</th>
<th>{{t "block.hash"}}</th> <th>Time Found</th>
<th>{{t "block.time_found"}}</th> <th>Current Type</th>
<th>{{t "block.variance"}}</th> <th>Variance</th>
<th>{{t "block.reward"}}</th> <th>Reward</th>
<th>{{t "block.shares"}}</th> <th>Type</th>
<th>{{t "block.worker"}}</th> <th>Shares/Diff</th>
</tr> <th>Worker ID</th>
</thead> </tr>
<tbody> </thead>
{{#each model.matured as |block|}} <tbody>
{{#each model.matured as |block|}}
{{partial "blocks/block"}} {{partial "blocks/block"}}
{{/each}} {{/each}}
</tbody> </tbody>
</table> </table>
</div> </div>
{{else}} {{else}}
<h3>{{t "block.no_matured_blocks_yet"}}</h3> <h3>No matured blocks yet</h3>
{{/if}} {{/if}}

26
www/app/templates/blocks/pending.hbs

@ -4,21 +4,29 @@
<table class="table table-condensed table-striped"> <table class="table table-condensed table-striped">
<thead> <thead>
<tr> <tr>
<th>{{t "block.height"}}</th> <th>Height</th>
<th>{{t "block.login"}}</th> <th>Login</th>
<th>{{t "block.time_found"}}</th> <th>Time Found</th>
<th>{{t "block.variance"}}</th> <th>Type</th>
<th>{{t "block.shares"}}</th> <th>Variance</th>
<th>Shares/Diff</th>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
{{#each model.candidates as |block|}} {{#each model.candidates as |block|}}
<tr> <tr>
<td><a href="{{t " links.blockExplorerLink_block"}}{{block.height}}" rel="nofollow" <td><a href="https://etc.blockscout.com/block/{{block.height}}" rel="nofollow" target="_blank">{{format-number
target="_blank">{{format-number
block.height}}</a></td> block.height}}</a></td>
<td>{{#link-to 'account' block.finder class='hash'}}{{block.finder}}{{/link-to}}</td> <td>{{#link-to 'account' block.finder class='hash'}}{{block.finder}}{{/link-to}}</td>
<td>{{format-date-locale block.timestamp}}</td> <td>{{format-date-locale block.timestamp}}</td>
<td>
{{#if block.isSolo}}
<span class="label label-danger">{{block.miningType}}</span>
{{else}}
<span class="label label-warning">{{block.miningType}}</span>
{{/if}}
</td>
<td> <td>
{{#if block.isLucky}} {{#if block.isLucky}}
<span class="label label-success">{{format-number block.variance style='percent'}}</span> <span class="label label-success">{{format-number block.variance style='percent'}}</span>
@ -33,5 +41,5 @@
</table> </table>
</div> </div>
{{else}} {{else}}
<h3>{{t "block.no_new_blocks_yet"}}</h3> <h3>No new blocks yet</h3>
{{/if}} {{/if}}

2
www/app/templates/finders.hbs

@ -16,7 +16,7 @@
<tbody> <tbody>
{{#each model.finders as |f|}} {{#each model.finders as |f|}}
<tr> <tr>
<td>{{#link-to 'account' f.address class='hash'}}{{f.address}}{{/link-to}}</td> <td>{{wallet f.address}}</td>
<td>{{format-number f.blocks}}</td> <td>{{format-number f.blocks}}</td>
</tr> </tr>
{{/each}} {{/each}}

29
www/app/templates/help.hbs

@ -9,20 +9,23 @@
<div class="page-header"> <div class="page-header">
<h3>lolMiner</h3> <h3>lolMiner</h3>
</div> </div>
<p class="lead">In order to mine etchash you need <p class="lead">In order to mine etchash you need
<a href="https://github.com/Lolliedieb/lolMiner-releases/releases" rel="nofollow" target="_blank">lolMiner</a> v1.12+ <a href="https://github.com/Lolliedieb/lolMiner-releases/releases" rel="nofollow" target="_blank">lolMiner</a>
v1.12+
</p>
<p>
<code>./lolMiner --pool {{config.StratumHost}}:{{config.StratumPort}} --user [YOUR_ETC_ADDRESS] -c ETC {{if (equals config.Network 'mordor') "--ecip1099-activation 84"}} --ethstratum=ETHPROXY</code>
</p> </p>
<p><code>./lolMiner --pool {{config.StratumHost}}:{{config.StratumPort}} --user [YOUR_ETC_ADDRESS] -c ETC {{if (equals config.Network 'mordor') "--ecip1099-activation 84"}} --ethstratum=ETHPROXY</code></p>
<dl class="dl-horizontal"> <dl class="dl-horizontal">
<dt>YOUR_ETC_ADDRESS</dt> <dt>YOUR_ETC_ADDRESS</dt>
<dd>This is your address for payouts, generate one with core-geth, or mine directly to exchange like <dd>This is your address for payouts, generate one with core-geth, or mine directly to exchange like
<a href="http://bittrex.com" rel="nofollow" target="_blank">Bittrex</a>.<br/> <a href="http://bittrex.com" rel="nofollow" target="_blank">Bittrex</a>.<br />
<strong>Example:</strong> <code>0xd92fa5a9732a0aec36dc8d5a6a1305dc2d3e09e6</code>. <strong>Example:</strong> <code>0xd92fa5a9732a0aec36dc8d5a6a1305dc2d3e09e6</code>.
</dd> </dd>
</dl> </dl>
<p> <p>
<strong>Full example:</strong> <strong>Full example:</strong>
<code>./lolMiner --pool {{config.StratumHost}}:{{config.StratumPort}} --user 0xd92fa5a9732a0aec36dc8d5a6a1305dc2d3e09e6 -c ETC {{if (equals config.Network 'mordor') "--ecip1099-activation 84"}} --ethstratum=ETHPROXY</code>.<br/> <code>./lolMiner --pool {{config.StratumHost}}:{{config.StratumPort}} --user 0xd92fa5a9732a0aec36dc8d5a6a1305dc2d3e09e6 -c ETC {{if (equals config.Network 'mordor') "--ecip1099-activation 84"}} --ethstratum=ETHPROXY</code>.<br />
</p> </p>
</div> </div>
@ -30,7 +33,7 @@
<div class="page-header"> <div class="page-header">
<h3>nanominer <small>mainnet only</small> </h3> <h3>nanominer <small>mainnet only</small> </h3>
</div> </div>
<p class="lead">In order to mine etchash you need <p class="lead">In order to mine etchash you need
<a href="https://github.com/nanopool/nanominer/releases" rel="nofollow" target="_blank">nanominer</a> v1.12.0+ <a href="https://github.com/nanopool/nanominer/releases" rel="nofollow" target="_blank">nanominer</a> v1.12.0+
</p> </p>
<h4>example config</h4> <h4>example config</h4>
@ -49,14 +52,14 @@ pool1={{config.StratumHost}}:{{config.StratumPort}}
<div class="col-md-12"> <div class="col-md-12">
<div class="col-md-6"> <div class="col-md-6">
<p class="text-justify"> <p class="text-justify">
<h4>Advice</h4> <h4>Advice</h4>
<p>CPU mining is not recommended.</p> <p>CPU mining is not recommended.</p>
<h4>Terms of Service</h4> <h4>Terms of Service</h4>
<p>By using the pool you accept all possible risks related to experimental software usage.<br/> <p>By using the pool you accept all possible risks related to experimental software usage.<br />
Pool owner can't compensate any irreversible losses, but will do his best to prevent worst case. Pool owner can't compensate any irreversible losses, but will do his best to prevent worst case.
</p> </p>
</p> </p>
</div> </div>
</div> </div>
</div> </div>

210
www/app/templates/index.hbs

@ -1,177 +1,83 @@
<div class="jumbotron"> <div class="jumbotron-brand">
<div class="container"> <div class="container">
<div class="row"> <div class="row">
<div class="col-md-12"> <div class="col-md-5">
<div class="alert alert-info text-center join_telegram"> <div class="row">
Join our <a class="alert-link" href="https://discord.gg/FDx7TzXDFQ">Discord</a> for support! <h1 style="font-size: 24px">
<div class="etc-green">
<strong><span class="logo-2">ETHW Pool</span></strong>
</div>
</h1>
</div>
<div class="row" style="padding:15px 5px;">
<strong>Min. payout threshold: {{config.PayoutThreshold}}</strong>, Payouts are continuos throughout the day.
<br />
<span class="label label-success">PPLNS</span>/<span class="label label-danger">SOLO</span> Stable and
profitable pool with regular payouts.
</div> </div>
</div> </div>
</div> <div class="col-md-3 stats">
<div class="row"> <div><i class="fa fa-users"></i> Miners Online: <span id="poolHashrate">{{format-number
<div class="col-md-4"> stats.model.minersTotal}}</span></div>
<strong>{{t "home.min_payout_threshold"}}: {{config.PayoutThreshold}} {{config.Unit}}</strong> / {{t <div><i class="fa fa-tachometer"></i> Pool Hashrate: <span id="poolHashrate">{{format-hashrate
"home.payouts_run" interval=config.PayoutInterval}}<br /> stats.model.hashrate}}</span></div>
<span class="label label-success">PPLNS</span> {{t "home.payout_scheme_detail"}} <div><i class="fa fa-money"></i> Pool Fee: <span id="poolFee"
class="label label-success">{{config.PoolFee}}</span></div>
{{#if stats.model.stats.lastBlockFound}}
<div><i class="fa fa-clock-o"></i> Last Block Found: <span>{{format-relative (seconds-to-ms
stats.model.stats.lastBlockFound)}}</span></div>
{{/if}}
<div><i class="fa fa-clock-o"></i> AVG BLOCK TIME: <span>{{format-number stats.blockTime}} s</span></div>
<div><i class="fa fa-gears"></i>Epoch: <span>{{format-number epoch}}</span> DAG Size: <span>{{format-number
dag}} GB</span></div>
</div> </div>
<div class="col-md-4 stats"> <div class="col-md-4 stats">
<div class="stats-box"> <div><i class="fa fa-unlock-alt"></i> Network Difficulty: <span>{{with-metric-prefix stats.difficulty}}</span>
<div><i class="fa fa-users"></i> {{t "home.miners_online"}}: <span id="poolHashrate">{{format-number
stats.model.minersTotal}}</span></div>
<div><i class="fa fa-tachometer"></i> {{t "home.pool_hashrate"}}: <span id="poolHashrate">{{format-hashrate
stats.model.hashrate}}</span></div>
<div><i class="fa fa-money"></i> {{t "home.pool_fee"}}: <span id="poolFee"
class="label label-success">{{config.PoolFee}}</span></div>
{{#if stats.model.stats.lastBlockFound}}
<div><i class="fa fa-clock-o"></i> {{t "home.last_block_found"}}: <span>{{format-relative (seconds-to-ms
stats.model.stats.lastBlockFound)}}</span></div>
{{/if}}
<div><i class="fa fa-clock-o"></i> {{t "home.block_time"}}: <span>{{format-number stats.blockTime}} s</span>
</div>
<div><i class="fa fa-gears"></i> {{t "home.epoch"}}: <span>{{format-number epoch}}</span> {{t
"home.dag_Size"}}:
<span>{{format-number
dag}} GB</span>
</div>
</div> </div>
</div> <div><i class="fa fa-tachometer"></i> Network Hashrate: <span>{{format-hashrate stats.hashrate}}</span></div>
<div><i class="fa fa-bars"></i> Mining Block: <span>{{stats.height}}</span></div>
<div class="col-md-4 stats"> <div><i class="fa fa-clock-o"></i> Luck: <span>{{format-number stats.roundVariance style='percent'}}</span>
<div class="stats-box"> </div>
<div><i class="fa fa-unlock-alt"></i> {{t "home.network_difficulty"}}: <span>{{with-metric-prefix <div><i class="fa fa-credit-card-alt fa-fw"></i> Current price: <span>$ {{model.exchangedata.price_usd}}</span>
stats.difficulty}}</span></div>
<div><i class="fa fa-tachometer"></i> {{t "home.network_hashrate"}}: <span>{{format-hashrate
stats.hashrate}}</span></div>
<div><i class="fa fa-bars"></i> {{t "home.blockchain_height"}}: <span>{{format-number stats.height}}</span>
</div>
<div><i class="fa fa-clock-o"></i> {{t "home.current_round_variance"}}: <span>{{format-number
stats.roundVariance style='percent'}}</span></div>
</div> </div>
<div><i class="fa fa-money"></i> {{t "home.current_price"}}: <span>$
{{format-number model.exchangedata.price_usd maximumFractionDigits='8'}}</span></div>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
<div class="container"> <div class="container">
<div>
{{high-charts mode=chartMode chartOptions=chartOptions content=chartData}}
</div>
<div class="stats"> <div class="stats">
<h3>{{t "home.query_history"}}</h3> <h4>Your Stats &amp; Payment History</h4>
<div class="input-group"> <div class="input-group">
{{input value=cachedLogin class="form-control" placeholder=(t "home.input.enter_your_wallet_address")}} {{input value=cachedLogin class="form-control" placeholder="Your wallet address"}}
<span class="input-group-btn"> <span class="input-group-btn">
<button class="btn btn-primary" type="button" {{action 'lookup' cachedLogin}}> <button class="btn btn-primary btn-etc" type="button" {{action 'lookup' cachedLogin}}>
<span style="display: inline;"><i class="fa fa-search"></i> {{t "home.button.lookup"}}</span> <span style="display: inline;"><i class="fa fa-search"></i> Search</span>
</button> </button>
</span> </span>
</div> </div>
</div> </div>
<div> <div>
<hr /> {{#if config.highcharts.main.enabled}}
<div class="row"> <div class="container">
<div class="col-md-4 col-sm-12"> {{high-charts mode=mode chartOptions=chartOptions content=chartData}}
<h5 class="note note-info text-center">
<span class="label label-success">8b</span>&nbsp;<a href="./#/help" title={{t "home.settings.help" }}><b>{{t
"home.settings.title" hashes="> 800"}} & NiceHash</b></a>
<br>
{{t "home.settings.difficulty" diff="8"}}
<br><br>
<b>{{t "home.settings.stratum_mining"}}:</b>
<br><br>
<code>stratum+tcp://{{config.StratumHost}}:{{config.StratumPort}}</code>
</h5>
</div>
</div> </div>
<div class="row command_lines"> {{/if}}
<!-- Nav tabs --> <div class="container">
<ul class="nav nav-tabs" role="tablist"> {{high-charts mode=mode chartOptions=chartDiff content=chartData}}
<li role="presentation" class="active"><a href="#windows_settings" aria-controls="home" role="tab" </div>
data-toggle="tab">{{t "home.settings.commands.windows"}}</a></li> <div class="jumbotron">
<li role="presentation"><a href="#smos_settings" aria-controls="profile" role="tab" data-toggle="tab">{{t <div class="container">
"home.settings.commands.smos"}}</a></li> <h3 class="text-center" style="padding: 0 0 5px 0; margin: 0 0 40px 0;"> Instructions</h3>
</ul> <div class="row">
<!-- Tab panes --> <div class="col-md-12">
<div class="tab-content"> <p class="lead text-center">
<div role="tabpanel" class="tab-pane active" id="windows_settings"> <a href="#/help" class="ul-link">
<div style="padding:15px;"> <span class="ul ul-danger">stratum</span><br /><br />
<h5>{{t "home.settings.commands.windows_instruction"}}</h5> </a>
<div class="panel-group" id="windows_settings_windows_tab" role="tablist" aria-multiselectable="true"> <code>{{config.StratumHost}}:{{config.StratumPort}}</code><br /> <br />
<div class="panel panel-default"> <code>Nicehash Europe password: #</code>
<div class="panel-heading" role="tab" id="win_headingOne"> </p>
<h4 class="panel-title">
<a role="button" data-toggle="collapse" data-parent="#windows_settings_windows_tab"
href="#win_collapseOne" aria-expanded="true" aria-controls="win_collapseOne">
lolMiner
</a>
</h4>
</div>
<div id="win_collapseOne" class="panel-collapse collapse in" role="tabpanel"
aria-labelledby="headingOne">
<div class="panel-body">
<code>
lolMiner --coin {{config.Unit}} --pool {{config.StratumHost}}:{{config.StratumPort}} --user wallet_address.WorkerName</code>
</div>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading" role="tab" id="win_headingTwo">
<h4 class="panel-title">
<a class="collapsed" role="button" data-toggle="collapse"
data-parent="#windows_settings_windows_tab" href="#win_collapseTwo" aria-expanded="false"
aria-controls="win_collapseTwo">
PhoenixMiner
</a>
</h4>
</div>
<div id="win_collapseTwo" class="panel-collapse collapse" role="tabpanel" aria-labelledby="headingTwo">
<div class="panel-body">
<code>
PhoenixMiner -pool {{config.StratumHost}}:{{config.StratumPort}} -wal wallet_address.WorkerName -coin etc</code>
</div>
</div>
</div>
</div>
</div>
</div>
<div role="tabpanel" class="tab-pane" id="smos_settings">
<div style="padding:15px;">
<h5>{{t "home.settings.commands.windows_instruction"}}</h5>
<div class="panel-group" id="smos_settings_smos_tab" role="tablist" aria-multiselectable="true">
<div class="panel panel-default">
<div class="panel-heading" role="tab" id="smos_headingOne">
<h4 class="panel-title">
<a role="button" data-toggle="collapse" data-parent="#smos_settings_smos_tab"
href="#smos_collapseOne" aria-expanded="true" aria-controls="smos_collapseOne">
lolMiner
</a>
</h4>
</div>
<div id="smos_collapseOne" class="panel-collapse collapse in" role="tabpanel"
aria-labelledby="headingOne">
<div class="panel-body">
<code>--coin {{config.Unit}} --pool {{config.StratumHost}}:{{config.StratumPort}} --user wallet_address.WorkerName
</code>
</div>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading" role="tab" id="smos_headingTwo">
<h4 class="panel-title">
<a class="collapsed" role="button" data-toggle="collapse" data-parent="#smos_settings_smos_tab"
href="#smos_collapseTwo" aria-expanded="false" aria-controls="smos_collapseTwo">
PhoenixMiner
</a>
</h4>
</div>
<div id="smos_collapseTwo" class="panel-collapse collapse" role="tabpanel" aria-labelledby="headingTwo">
<div class="panel-body">
<code>
-pool {{config.StratumHost}}:{{config.StratumPort}} -wal wallet_address.WorkerName -coin etc</code>
</div>
</div>
</div>
</div>
</div> </div>
</div> </div>
</div> </div>

24
www/app/templates/luck.hbs

@ -2,21 +2,21 @@
<table class="table table-condensed table-striped"> <table class="table table-condensed table-striped">
<thead> <thead>
<tr> <tr>
<th>{{t "luck.blocks"}}</th> <th>Blocks</th>
<th>{{t "luck.shares_diff"}}</th> <th>Shares/Diff</th>
<th>{{t "luck.uncle_rate"}}</th> <th>Uncle Rate</th>
<th>{{t "luck.orphan_rate"}}</th> <th>Orphan Rate</th>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
{{#each-in model.luck as |total row|}} {{#each-in model.luck as |total row|}}
<tr> <tr>
<td>{{total}}</td> <td>{{total}}</td>
<td>{{format-number row.luck style='percent'}}</td> <td>{{format-number row.luck style='percent'}}</td>
<td>{{format-number row.uncleRate style='percent'}}</td> <td>{{format-number row.uncleRate style='percent'}}</td>
<td>{{format-number row.orphanRate style='percent'}}</td> <td>{{format-number row.orphanRate style='percent'}}</td>
</tr> </tr>
{{/each-in}} {{/each-in}}
</tbody> </tbody>
</table> </table>
</div> </div>

11
www/app/templates/miners.hbs

@ -14,6 +14,7 @@
<th>Login</th> <th>Login</th>
<th>Hashrate</th> <th>Hashrate</th>
<th>Last Beat</th> <th>Last Beat</th>
<th>Mining Type</th>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
@ -22,6 +23,14 @@
<td>{{#link-to 'account' m.login class='hash'}}{{m.login}}{{/link-to}}</td> <td>{{#link-to 'account' m.login class='hash'}}{{m.login}}{{/link-to}}</td>
<td>{{format-hashrate m.hr}}</td> <td>{{format-hashrate m.hr}}</td>
<td>{{format-date-locale m.lastBeat}}</td> <td>{{format-date-locale m.lastBeat}}</td>
<td>
{{#if m.solo}}
<span class="label label-danger">solo</span>
{{else}}
<span class="label label-warning">pplns</span>
{{/if}}
</td>
</tr> </tr>
{{/each}} {{/each}}
</tbody> </tbody>
@ -30,4 +39,4 @@
{{else}} {{else}}
<h3>No miners</h3> <h3>No miners</h3>
{{/if}} {{/if}}
</div> </div>

28
www/app/templates/payments.hbs

@ -1,20 +1,20 @@
<div class="jumbotron"> <div class="jumbotron-brand">
<div class="container"> <div class="container">
<p class="lead">{{t "payments.pay_tx"}}</p> <p class="lead">Pool always pays tx fees from it's own pocket for now.</p>
<strong>{{t "payments.total_payments_sent"}}:</strong> <span class="label label-info">{{model.paymentsTotal}}</span> <strong>Total payments sent:</strong> <span class="label label-info">{{model.paymentsTotal}}</span>
</div> </div>
</div> </div>
<div class="container"> <div class="container">
{{#if model.payments}} {{#if model.payments}}
<h3>{{t "payments.latest_payouts"}}</h3> <h4>Latest Payouts</h4>
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-condensed table-striped"> <table class="table table-condensed table-striped">
<thead> <thead>
<tr> <tr>
<th>{{t "payments.time"}}</th> <th>Time</th>
<th>{{t "payments.amount"}}</th> <th>Amount</th>
<th>{{t "payments.address"}}</th> <th>Address</th>
<th>{{t "payments.txid"}}</th> <th>Tx ID</th>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
@ -23,12 +23,12 @@
<td>{{format-date-locale tx.timestamp}}</td> <td>{{format-date-locale tx.timestamp}}</td>
<td>{{format-number tx.formatAmount}}</td> <td>{{format-number tx.formatAmount}}</td>
<td> <td>
<a href="{{t " links.blockExplorerLink_address"}}{{tx.address}}" class="hash" rel="nofollow" <a href="https://etc.blockscout.com/address/{{tx.address}}" class="hash" rel="nofollow"
target="_blank">{{tx.address}}</a> target="_blank">{{wallet tx.address}}</a>
</td> </td>
<td> <td>
<a href="{{t " links.blockExplorerLink_tx"}}{{tx.tx}}" class="hash" rel="nofollow" <a href="https://etc.blockscout.com/tx/{{tx.tx}}" class="hash" rel="nofollow" target="_blank">{{format-tx
target="_blank">{{format-tx tx.tx}}</a> tx.tx}}</a>
</td> </td>
</tr> </tr>
{{/each}} {{/each}}
@ -36,6 +36,6 @@
</table> </table>
</div> </div>
{{else}} {{else}}
<h3>{{t "payments.no_payouts_yet"}}</h3> <h3>No payouts yet</h3>
{{/if}} {{/if}}
</div> </div>

45
www/config/environment.js

@ -15,27 +15,57 @@ module.exports = function (environment) {
APP: { APP: {
// API host and port // API host and port
ApiUrl: '//192.168.178.27/', ApiUrl: '//192.168.178.41/',
// HTTP mining endpoint // HTTP mining endpoint
HttpHost: 'http://192.168.178.27', HttpHost: 'http://192.168.178.41',
HttpPort: 8888, HttpPort: 8888,
// Stratum mining endpoint // Stratum mining endpoint
StratumHost: 'example.net', StratumHost: '192.168.178.41',
StratumPort: 8008, StratumPort: 3001,
// The ETC network // The ETC network
Unit: 'ETC', Unit: 'ETC',
Currency: 'USD', Mining: 'SOLO',
// Fee and payout details // Fee and payout details
PoolFee: '1%', PoolFee: '1.0%',
PayoutThreshold: '0.5 ETC', PayoutThreshold: '0.5 ETC',
BlockReward: 2.56, BlockReward: 2.56,
// For network hashrate (change for your favourite fork) // For network hashrate (change for your favourite fork)
BlockTime: 13.2 BlockTime: 14.4,
highcharts: {
main: {
enabled: true,
height: 200,
type: 'spline',
color: '',
labelColor: '#909090',
lineColor: '#404850',
tickColor: '#404850',
gridLineColor: '#404850',
gridLineWidthX: 1,
gridLineWidthY: 1,
backgroundColor: 'transparent',
title: '',
ytitle: '',
interval: 180000,
chartInterval: 900000
},
account: {
enabled: true,
height: 300,
type: 'spline',
color: ['', ''],
title: '',
ytitle: '',
interval: 180000,
chartInterval: 900000,
paymentInterval: 30000
}
}
} }
}; };
@ -68,4 +98,3 @@ module.exports = function (environment) {
return ENV; return ENV;
}; };

Loading…
Cancel
Save