diff --git a/TODO b/TODO
index b79437c..fb159af 100755
--- a/TODO
+++ b/TODO
@@ -1,4 +1,3 @@
-* Don't display the whole balance table if not admin
* Notifications by e-mail for users
Improvements :
diff --git a/tpl/default_en/index.html b/tpl/default_en/index.html
index 6a463a4..59f9d17 100755
--- a/tpl/default_en/index.html
+++ b/tpl/default_en/index.html
@@ -6,29 +6,54 @@
Balance
-
Read line owes case {$currency} to column. You can click on links to confirm the payback.
-
-
- Owes\To |
- {loop="users"}
- {$value->getDisplayName()} |
- {/loop}
-
- {loop="users"}
+ {if condition="$current_user->getAdmin()"}
+ Read line owes case {$currency} to column. You can click on links to confirm the payback.
+
- {$value->getDisplayName()} |
+ Owes\To |
{loop="users"}
- {if condition="$balances[$value1->getId()][$value2->getId()] === 'X'"}
- |
- {elseif condition="$balances[$value1->getId()][$value2->getId()] === '-' || ($value2->getId() != $current_user->getId() && !$current_user->getAdmin())"}
- {$balances[$value1->getId()][$value2->getId()]} |
- {else}
- {$balances[$value1->getId()][$value2->getId()]} |
- {/if}
+ {$value->getDisplayName()} |
{/loop}
- {/loop}
-
+ {loop="users"}
+
+ {$value->getDisplayName()} |
+ {loop="users"}
+ {if condition="$balances[$value1->getId()][$value2->getId()] === 'X'"}
+ |
+ {elseif condition="$balances[$value1->getId()][$value2->getId()] === '-' || ($value2->getId() != $current_user->getId() && !$current_user->getAdmin())"}
+ {$balances[$value1->getId()][$value2->getId()]} |
+ {else}
+ {$balances[$value1->getId()][$value2->getId()]} |
+ {/if}
+ {/loop}
+
+ {/loop}
+
+ {else}
+
+
+ Users |
+ You owe him |
+ He owes you |
+
+ {loop="$users"}
+ {if condition="$balances[$value->getId()][$current_user->getId()] !== 'X' && $balances[$value->getId()][$current_user->getId()] !== '-'"}
+
+ {$value->getDisplayName()} |
+ - |
+ {$balances[$value->getId()][$current_user->getId()]}{$currency} |
+
+ {elseif condition="$balances[$current_user->getId()][$value->getId()] !== 'X' && $balances[$current_user->getId()][$value->getId()] !== '-'"}
+
+ {$value->getDisplayName()} |
+ {$balances[$current_user->getId()][$value->getId()]}{$currency} |
+ - |
+
+ {/if}
+ {/loop}
+
+ {/if}
Detailed list of bills{if condition="$all == 0"} for last month{/if}
diff --git a/tpl/default_fr/index.html b/tpl/default_fr/index.html
index cce237f..17cc6da 100755
--- a/tpl/default_fr/index.html
+++ b/tpl/default_fr/index.html
@@ -6,29 +6,54 @@
Bilan
-
Lire ligne doit case {$currency} à colonne. Vous pouvez cliquer sur les liens pour confirmer les remboursements.
-
-
- Doit\À |
- {loop="users"}
- {$value->getDisplayName()} |
- {/loop}
-
- {loop="users"}
+ {if condition="$current_user->getAdmin()"}
+ Lire ligne doit case {$currency} à colonne. Vous pouvez cliquer sur les liens pour confirmer les remboursements.
+
- {$value->getDisplayName()} |
+ Doit\À |
{loop="users"}
- {if condition="$balances[$value1->getId()][$value2->getId()] === 'X'"}
- |
- {elseif condition="$balances[$value1->getId()][$value2->getId()] === '-' || ($value2->getId() != $current_user->getId() && !$current_user->getAdmin())"}
- {$balances[$value1->getId()][$value2->getId()]} |
- {else}
- {$balances[$value1->getId()][$value2->getId()]} |
- {/if}
+ {$value->getDisplayName()} |
{/loop}
- {/loop}
-
+ {loop="users"}
+
+ {$value->getDisplayName()} |
+ {loop="users"}
+ {if condition="$balances[$value1->getId()][$value2->getId()] === 'X'"}
+ |
+ {elseif condition="$balances[$value1->getId()][$value2->getId()] === '-' || ($value2->getId() != $current_user->getId() && !$current_user->getAdmin())"}
+ {$balances[$value1->getId()][$value2->getId()]} |
+ {else}
+ {$balances[$value1->getId()][$value2->getId()]} |
+ {/if}
+ {/loop}
+
+ {/loop}
+
+ {else}
+
+
+ Utilisateurs |
+ Vous devez |
+ Il vous doit |
+
+ {loop="$users"}
+ {if condition="$balances[$value->getId()][$current_user->getId()] !== 'X' && $balances[$value->getId()][$current_user->getId()] !== '-'"}
+
+ {$value->getDisplayName()} |
+ - |
+ {$balances[$value->getId()][$current_user->getId()]}{$currency} |
+
+ {elseif condition="$balances[$current_user->getId()][$value->getId()] !== 'X' && $balances[$current_user->getId()][$value->getId()] !== '-'"}
+
+ {$value->getDisplayName()} |
+ {$balances[$current_user->getId()][$value->getId()]}{$currency} |
+ - |
+
+ {/if}
+ {/loop}
+
+ {/if}
Liste détaillée des dépenses{if condition="$all == 0"} du dernier mois{/if}