chiark / gitweb /
routesearch: include tableau in stdout
[ypp-sc-tools.db-live.git] / yarrg / web / query_route
index 8ac9ab045be945b6d581ba52980cfbf523d6bd5d..3c37d6fc9f7833359394af29dd8bab35dbb7b81c 100644 (file)
@@ -50,9 +50,6 @@ my $emsg;
 my @warningfs;
 my @archipelagoes;
 my @islandids;
-my ($max_volume, $max_mass);
-my $lossperleaguepct;
-my $capital;
 
 my $qa= \%ARGS;
 
@@ -90,52 +87,10 @@ my $goupdate= sub { $be_post ? 'Update' : 'Go' };
  &>
 
 %#---------- textboxes, user enters details as strings ----------
+% my $routeparams= { EmsgRef => \$emsg };
 % if (!$qa->{Dropdowns}) {
 
-<strong>Advanced options - you may leave these blank:</strong>
-<p>
-<table>
-<tr>
-<td>
-
-Vessel or capacity:
-<&| qtextstring, qa => $qa, dbh => $dbh, prefix => 'cs',
-    thingstring => 'capacitystring', emsgstore => \$emsg,
-    helpref => 'capacity',
-    onresults => sub { ($max_mass,$max_volume) = @_; }
- &>
- size=40
-</&>
-
-<td>
-&nbsp;
-&nbsp;
-
-<td>
-Expected losses:
-
-<&| qtextstring, qa => $qa, dbh => $dbh, prefix => 'll',
-    thingstring => 'lossperleague', emsgstore => \$emsg,
-    helpref => 'losses',
-    onresults => sub { ($lossperleaguepct)= @_; }
- &>
- size=9
-</&>
-</tr>
-<tr>
-
-<td>Available capital:
-
-<&| qtextstring, qa => $qa, dbh => $dbh, prefix => 'ac',
-    thingstring => 'capitalstring', emsgstore => \$emsg,
-    helpref => 'capital',
-    onresults => sub { ($capital)= @_; }
- &>
- size=9
-</&>
-</td>
-</tr>
-</table>
+<& enter_advrouteopts, qa=>$qa, dbh=>$dbh, routeparams=>$routeparams &>
 
 % } #---------- end of dropdowns, now common middle of page code ----------
 
@@ -164,10 +119,7 @@ foreach my $warningf (@warningfs) {
    islandids => \@islandids,
    archipelagoes => \@archipelagoes,
    qa => $qa,
-   max_mass => $max_mass,
-   max_volume => $max_volume,
-   lossperleaguepct => $lossperleaguepct,
-   max_capital => $capital
+   routeparams => $routeparams
  &>
 % }
 </form>