Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

when entering new tips play day redirect always to current play day

  • Loading branch information...
commit c66bf225c986481f423fe5cfd364cf2e637b8b51 1 parent 2e463f1
Sven Kubiak authored
Showing with 4 additions and 1 deletion.
  1. +4 −1 app/controllers/Tips.java
5 app/controllers/Tips.java
View
@@ -61,6 +61,7 @@ public static void storetips() {
if (AppUtils.verifyAuthenticity()) { checkAuthenticity(); }
int tipped = 0;
+ int playday = 1;
List<String> keys = new ArrayList<String>();
final Map<String, String> map = params.allSimple();
for (Entry<String, String> entry : map.entrySet()) {
@@ -90,6 +91,8 @@ public static void storetips() {
AppUtils.placeTip(game, Integer.parseInt(homeScore), Integer.parseInt(awayScore));
keys.add(key);
tipped++;
+
+ playday = game.getPlayday().getNumber();
}
}
if (tipped > 0) {
@@ -99,7 +102,7 @@ public static void storetips() {
}
flash.keep();
- redirect("/tips/index/" + AppUtils.getCurrentPlayday());
+ redirect("/tips/index/" + playday);
}
public static void storeextratips() {
Please sign in to comment.
Something went wrong with that request. Please try again.