From f55d0ba982d2536501a0f3f1d4b30dfd78d6ce7b Mon Sep 17 00:00:00 2001 From: Sebastian Grewe Date: Fri, 25 Oct 2013 14:17:36 +0200 Subject: [PATCH] [IMRPOVED] MPOS Theme Dashboard * [CHANGE] Removed `default_` files * [ADDED] Added generic, simple templates to remove code duplication * [CHANGE] New default payment system template expanding on payout type --- .../templates/mpos/dashboard/account_data.tpl | 51 +++++++++---- public/templates/mpos/dashboard/default.tpl | 5 +- .../mpos/dashboard/default_pplns.tpl | 73 ------------------- .../templates/mpos/dashboard/default_pps.tpl | 73 ------------------- .../templates/mpos/dashboard/default_prop.tpl | 62 ---------------- .../templates/mpos/dashboard/network_info.tpl | 11 +++ .../mpos/dashboard/payout_estimates.tpl | 43 +++++++++++ .../templates/mpos/dashboard/round_shares.tpl | 19 +++++ .../templates/mpos/dashboard/system_stats.tpl | 32 ++++++++ 9 files changed, 143 insertions(+), 226 deletions(-) delete mode 100644 public/templates/mpos/dashboard/default_pplns.tpl delete mode 100644 public/templates/mpos/dashboard/default_pps.tpl delete mode 100644 public/templates/mpos/dashboard/default_prop.tpl create mode 100644 public/templates/mpos/dashboard/network_info.tpl create mode 100644 public/templates/mpos/dashboard/payout_estimates.tpl create mode 100644 public/templates/mpos/dashboard/round_shares.tpl create mode 100644 public/templates/mpos/dashboard/system_stats.tpl diff --git a/public/templates/mpos/dashboard/account_data.tpl b/public/templates/mpos/dashboard/account_data.tpl index 12e62f2a..ce1bf20b 100644 --- a/public/templates/mpos/dashboard/account_data.tpl +++ b/public/templates/mpos/dashboard/account_data.tpl @@ -1,26 +1,47 @@

Account Information

-
+ + + + + + + + + + + + + diff --git a/public/templates/mpos/dashboard/payout_estimates.tpl b/public/templates/mpos/dashboard/payout_estimates.tpl new file mode 100644 index 00000000..7258b348 --- /dev/null +++ b/public/templates/mpos/dashboard/payout_estimates.tpl @@ -0,0 +1,43 @@ + + + + +{if $GLOBAL.config.payout_system != 'pps'} + + + + + + + + + + + + + + + + +{else} + + + + + + + + + + + + + + + + + + + + +{/if} diff --git a/public/templates/mpos/dashboard/round_shares.tpl b/public/templates/mpos/dashboard/round_shares.tpl new file mode 100644 index 00000000..805c06b8 --- /dev/null +++ b/public/templates/mpos/dashboard/round_shares.tpl @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + diff --git a/public/templates/mpos/dashboard/system_stats.tpl b/public/templates/mpos/dashboard/system_stats.tpl new file mode 100644 index 00000000..04a97692 --- /dev/null +++ b/public/templates/mpos/dashboard/system_stats.tpl @@ -0,0 +1,32 @@ +
+

{$GLOBAL.config.payout_system|capitalize} Stats

+
+
{if $GLOBAL.userdata.no_fees} -

You are mining without any pool fees applied.

+ You are mining without any pool fees applied and {else if $GLOBAL.fees > 0} -

You are mining at {$GLOBAL.fees|escape}% pool fee.

+ You are mining at {$GLOBAL.fees|escape}% pool fee and +{else} + This pool does not apply fees and {/if} {if $GLOBAL.userdata.donate_percent > 0} -

You are donating {$GLOBAL.userdata.donate_percent|escape}% of your mined coins to the pool.

+ you donate {$GLOBAL.userdata.donate_percent|escape}%. {else} -

Please consider donating some of your mined coins to the pool operator.

+ you are not donating. {/if} - - - - - - - - - + + +
{$GLOBAL.config.currency} Account Balance
Confirmed
Unconfirmed
+ + + + + + + + + + + + +
{$GLOBAL.config.currency} Account Balance
Confirmed
Unconfirmed
+ + + + + + + + + + +
WorkerHashrateDifficulty
Loading worker information
- diff --git a/public/templates/mpos/dashboard/default.tpl b/public/templates/mpos/dashboard/default.tpl index 2bcf48bb..d12b4e1d 100644 --- a/public/templates/mpos/dashboard/default.tpl +++ b/public/templates/mpos/dashboard/default.tpl @@ -1,8 +1,7 @@ {if $smarty.session.AUTHENTICATED|default} - {assign var=payout_system value=$GLOBAL.config.payout_system} {include file="dashboard/overview.tpl"} - {include file="dashboard/default_$payout_system.tpl"} + {include file="dashboard/system_stats.tpl"} {include file="dashboard/round_data.tpl"} - {include file="dashboard/account_data.tpl"}{include file="dashboard/workers.tpl"} + {include file="dashboard/account_data.tpl"} {include file="dashboard/js.tpl"} {/if} diff --git a/public/templates/mpos/dashboard/default_pplns.tpl b/public/templates/mpos/dashboard/default_pplns.tpl deleted file mode 100644 index 85471660..00000000 --- a/public/templates/mpos/dashboard/default_pplns.tpl +++ /dev/null @@ -1,73 +0,0 @@ -
-

PPLNS Stats

-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
PPLNS Target
Your Stats
Hashrate {$GLOBAL.hashunits.pool}
Share Rate S/s
Round Shares
Pool Valid
Your Valid
Pool Invalid
Your Invalid
{$GLOBAL.config.currency} Round Estimate
Block
Fees
Donation
Payout
{$GLOBAL.config.currency} Info
Current Difficulty
Current Block
-
-
diff --git a/public/templates/mpos/dashboard/default_pps.tpl b/public/templates/mpos/dashboard/default_pps.tpl deleted file mode 100644 index f1d415ff..00000000 --- a/public/templates/mpos/dashboard/default_pps.tpl +++ /dev/null @@ -1,73 +0,0 @@ -
-

PPS Stats

-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
PPS Value{$GLOBAL.ppsvalue}
PPS Difficulty{$GLOBAL.userdata.sharedifficulty|number_format:"2"}
 
Round Shares
Pool Valid
Your Valid
Pool Invalid
Your Invalid
 
{$GLOBAL.config.currency} Estimates
in 1 hour{$GLOBAL.userdata.estimates.hours1|round:"8"}
in 24 hours{($GLOBAL.userdata.estimates.hours24)|round:"8"}
in 7 days{($GLOBAL.userdata.estimates.days7)|round:"8"}
in 14 days{($GLOBAL.userdata.estimates.days14)|round:"8"}
in 30 days{($GLOBAL.userdata.estimates.days30)|round:"8"}
 
{$GLOBAL.config.currency} Info
Current Difficulty
Current Block
 
-
-
- diff --git a/public/templates/mpos/dashboard/default_prop.tpl b/public/templates/mpos/dashboard/default_prop.tpl deleted file mode 100644 index dfeb5e80..00000000 --- a/public/templates/mpos/dashboard/default_prop.tpl +++ /dev/null @@ -1,62 +0,0 @@ -
-

Prop Stats

-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Round Shares
Pool Valid
Your Valid
Pool Invalid
Your Invalid
 
{$GLOBAL.config.currency} Round Estimate
Block
Fees
Donation
Payout
 
{$GLOBAL.config.currency} Info
Current Difficulty
Current Block
 
-
-
- diff --git a/public/templates/mpos/dashboard/network_info.tpl b/public/templates/mpos/dashboard/network_info.tpl new file mode 100644 index 00000000..22bf9e79 --- /dev/null +++ b/public/templates/mpos/dashboard/network_info.tpl @@ -0,0 +1,11 @@ +
Network Info
Difficulty
Current Block
{$GLOBAL.config.currency} Round Estimate
Block
Fees
Donation
Payout
in 1 hour{$GLOBAL.userdata.estimates.hours1|round:"8"}
in 24 hours{($GLOBAL.userdata.estimates.hours24)|round:"8"}
in 7 days{($GLOBAL.userdata.estimates.days7)|round:"8"}
in 14 days{($GLOBAL.userdata.estimates.days14)|round:"8"}
in 30 days{($GLOBAL.userdata.estimates.days30)|round:"8"}
Round Shares
Pool Valid
Your Valid
Pool Invalid
Your Invalid
+ +{if $GLOBAL.config.payout_system == 'pplns'} + + + + +{elseif $GLOBAL.config.payout_system == 'pps'} + + + + + + + + +{/if} + + {include file="dashboard/round_shares.tpl"} + + {include file="dashboard/payout_estimates.tpl"} + + {include file="dashboard/network_info.tpl"} + + +
PPLNS Target
PPS Value{$GLOBAL.ppsvalue}
PPS Difficulty{$GLOBAL.userdata.sharedifficulty|number_format:"2"}
 
 
 
 
+
+
+