X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~yarrgweb/git?a=blobdiff_plain;f=yarrg%2Fweb%2Fenter_advrouteopts;h=95a71433ddbf2e1ec4d18e9381131e41c937dfa9;hb=fbe374c3592808f9b3f105ec0726b26ada6c0ea0;hp=1e037330197161c5ede0342057fc08f31b780c76;hpb=64f37d1c80bfd082dab4a11db206515890af6f44;p=ypp-sc-tools.db-live.git
diff --git a/yarrg/web/enter_advrouteopts b/yarrg/web/enter_advrouteopts
index 1e03733..95a7143 100644
--- a/yarrg/web/enter_advrouteopts
+++ b/yarrg/web/enter_advrouteopts
@@ -32,8 +32,10 @@
This Mason component generates entry fields for route planning
advanced parameters (capacity limits, etc).
- The results are returned in $routeparams:
+ Some useful parameters are in %$routeparams:
${ $routeparams->{EmsgRef} }
+ $routeparams->{SayRequiredCapacity}
+ The results are returned there:
$routeparams->{LossPerLeaguePct}
$routeparams->{MaxMass}
$routeparams->{MaxVolume}
@@ -47,6 +49,15 @@ $dbh
$routeparams
%args>
+<%method advanced>
+Advanced options - you may leave these blank:
+
+%method>
+
+% if (!$routeparams->{SayRequiredCapacity}) {
+<& SELF:advanced &>
+% }
+
Vessel or capacity:
@@ -60,6 +71,22 @@ Vessel or capacity:
size=40
&>
+ |
+% if ($routeparams->{SayRequiredCapacity}) {
+<& SELF:advanced &>
+% }
+
+
+Available capital:
+
+<&| qtextstring, qa => $qa, dbh => $dbh, prefix => 'ac',
+ thingstring => 'capitalstring', emsgstore => $routeparams->{EmsgRef},
+ helpref => 'capital',
+ onresults => sub { ($routeparams->{MaxCapital})= @_; }
+ &>
+ size=9
+&>
+
|
@@ -75,17 +102,6 @@ Expected losses:
size=9
&>
- |
-
-
-Available capital:
-
-<&| qtextstring, qa => $qa, dbh => $dbh, prefix => 'ac',
- thingstring => 'capitalstring', emsgstore => $routeparams->{EmsgRef},
- helpref => 'capital',
- onresults => sub { ($routeparams->{MaxCapital})= @_; }
- &>
- size=9
-&>
+<% $m->content %>
|