Call purchase functions instead of order
authorRichard Whitehouse <richardwhiuk@richardwhiuk.com>
Fri, 4 Feb 2011 23:36:26 +0000 (23:36 +0000)
committerRichard Whitehouse <richardwhiuk@richardwhiuk.com>
Fri, 4 Feb 2011 23:36:26 +0000 (23:36 +0000)
pages/index.php

index 6bcb10d6c5851325e3018fce5e83c0c36c51f870..2dd12c128b9ff70eeec38ce3d38baa4767318d96 100644 (file)
@@ -23,9 +23,9 @@ class Page_Index extends Page {
 
                                foreach($purchases as $p){
                                        $template->previous[$o->id()]['purchases'][$p->id()] = array(
-                                               'name' => $o->name(),
-                                               'price' => $o->price(),
-                                               'type' => $o->type()
+                                               'name' => $p->name(),
+                                               'price' => $p->price(),
+                                               'type' => $p->type()
                                        );
                                }
                        }
@@ -39,9 +39,9 @@ class Page_Index extends Page {
                                
                                foreach($purchases as $p){
                                        $template->new[$p->id()] = array(
-                                               'name' => $o->name(),
-                                               'price' => $o->price(),
-                                               'type' => $o->type(),
+                                               'name' => $p->name(),
+                                               'price' => $p->price(),
+                                               'type' => $p->type(),
                                                'delete' => $system->url('delete', $p->id())
                                        );
                                }