From 56b5841b9ba6e7c1229e9190b1a68fee53e7bf8b Mon Sep 17 00:00:00 2001 From: Nicolas Schodet Date: Thu, 5 Apr 2012 22:33:20 +0200 Subject: rename command to update mode --- stocks.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/stocks.py b/stocks.py index 53b92e4..21c2eea 100755 --- a/stocks.py +++ b/stocks.py @@ -149,7 +149,7 @@ class AppCGI: self.stocks.load (DEFAULT_DATABASE) # Make operations. try: - if self.mode == 'command' and self.action == 'update': + if self.mode == 'update' and self.action == 'update': for code, qty in self.iter_update (form): if qty: item = self.stocks.items[code] @@ -260,9 +260,9 @@ $stylesheet #end if #end def -#def command_mode($line, $i) +#def update_mode($line, $i) #filter WebSafe - #if $mode == 'command' + #if $mode == 'update' #if $place in $i.qty then $i.qty[$place] else 0 # @@ -296,8 +296,8 @@ $stylesheet #if not $mode

- Command mode - + Update mode +

@@ -337,7 +337,7 @@ $stylesheet $i.desc $i.qty.main #filter None - $command_mode($line, $i) + $update_mode($line, $i) #end filter #for $iplace, $qty in $i.qty.itersorted -- cgit v1.2.3